diff --git a/client/components/app/BookShelfRow.vue b/client/components/app/BookShelfRow.vue index 6e19b9dc..97d64d86 100644 --- a/client/components/app/BookShelfRow.vue +++ b/client/components/app/BookShelfRow.vue @@ -99,6 +99,7 @@ export default { this.$store.commit('showEditModal', libraryItem) }, editEpisode({ libraryItem, episode }) { + this.$store.commit('setEpisodeTableEpisodeIds', [episode.id]) this.$store.commit('setSelectedLibraryItem', libraryItem) this.$store.commit('globals/setSelectedEpisode', episode) this.$store.commit('globals/setShowEditPodcastEpisodeModal', true) diff --git a/client/components/modals/item/EditModal.vue b/client/components/modals/item/EditModal.vue index c41e6b54..ca6094d8 100644 --- a/client/components/modals/item/EditModal.vue +++ b/client/components/modals/item/EditModal.vue @@ -196,6 +196,9 @@ export default { methods: { async goPrevBook() { if (this.currentBookshelfIndex - 1 < 0) return + // Remove focus from active input + document.activeElement?.blur?.() + var prevBookId = this.bookshelfBookIds[this.currentBookshelfIndex - 1] this.processing = true var prevBook = await this.$axios.$get(`/api/items/${prevBookId}?expanded=1`).catch((error) => { @@ -215,6 +218,9 @@ export default { }, async goNextBook() { if (this.currentBookshelfIndex >= this.bookshelfBookIds.length - 1) return + // Remove focus from active input + document.activeElement?.blur?.() + this.processing = true var nextBookId = this.bookshelfBookIds[this.currentBookshelfIndex + 1] var nextBook = await this.$axios.$get(`/api/items/${nextBookId}?expanded=1`).catch((error) => { @@ -300,4 +306,4 @@ export default { .tab.tab-selected { height: 41px; } - \ No newline at end of file + diff --git a/client/components/modals/podcast/EditEpisode.vue b/client/components/modals/podcast/EditEpisode.vue index 9702ce38..9572a36a 100644 --- a/client/components/modals/podcast/EditEpisode.vue +++ b/client/components/modals/podcast/EditEpisode.vue @@ -117,8 +117,12 @@ export default { methods: { async goPrevEpisode() { if (this.currentEpisodeIndex - 1 < 0) return + // Remove focus from active input + document.activeElement?.blur?.() + const prevEpisodeId = this.episodeTableEpisodeIds[this.currentEpisodeIndex - 1] this.processing = true + const prevEpisode = await this.$axios.$get(`/api/podcasts/${this.libraryItem.id}/episode/${prevEpisodeId}`).catch((error) => { const errorMsg = error.response && error.response.data ? error.response.data : 'Failed to fetch episode' this.$toast.error(errorMsg) @@ -134,8 +138,12 @@ export default { }, async goNextEpisode() { if (this.currentEpisodeIndex >= this.episodeTableEpisodeIds.length - 1) return + // Remove focus from active input + document.activeElement?.blur?.() + this.processing = true const nextEpisodeId = this.episodeTableEpisodeIds[this.currentEpisodeIndex + 1] + const nextEpisode = await this.$axios.$get(`/api/podcasts/${this.libraryItem.id}/episode/${nextEpisodeId}`).catch((error) => { const errorMsg = error.response && error.response.data ? error.response.data : 'Failed to fetch book' this.$toast.error(errorMsg) diff --git a/client/components/widgets/ItemSlider.vue b/client/components/widgets/ItemSlider.vue index 92639cc6..92e9fcee 100644 --- a/client/components/widgets/ItemSlider.vue +++ b/client/components/widgets/ItemSlider.vue @@ -124,6 +124,7 @@ export default { this.updateSelectionMode(false) }, editEpisode({ libraryItem, episode }) { + this.$store.commit('setEpisodeTableEpisodeIds', [episode.id]) this.$store.commit('setSelectedLibraryItem', libraryItem) this.$store.commit('globals/setSelectedEpisode', episode) this.$store.commit('globals/setShowEditPodcastEpisodeModal', true)