diff --git a/client/components/cards/LazyBookCard.vue b/client/components/cards/LazyBookCard.vue index d837bf90..d51ed208 100644 --- a/client/components/cards/LazyBookCard.vue +++ b/client/components/cards/LazyBookCard.vue @@ -89,7 +89,7 @@
-

{{ series }}

+

{{ seriesName }}

@@ -218,6 +218,9 @@ export default { // Only included when filtering by series or collapse series or Continue Series shelf on home page return this.mediaMetadata.series }, + seriesName() { + return this.series?.name || null + }, seriesSequence() { return this.series?.sequence || null }, diff --git a/client/components/modals/authors/EditModal.vue b/client/components/modals/authors/EditModal.vue index 40292dca..3af64249 100644 --- a/client/components/modals/authors/EditModal.vue +++ b/client/components/modals/authors/EditModal.vue @@ -33,8 +33,10 @@
- {{ $strings.ButtonQuickMatch }} + {{ $strings.ButtonRemove }}
+ {{ $strings.ButtonQuickMatch }} + {{ $strings.ButtonSave }}
@@ -91,6 +93,9 @@ export default { }, libraryProvider() { return this.$store.getters['libraries/getLibraryProvider'](this.currentLibraryId) || 'google' + }, + userCanDelete() { + return this.$store.getters['user/getUserCanDelete'] } }, methods: { @@ -100,6 +105,31 @@ export default { this.authorCopy.description = this.author.description this.authorCopy.imagePath = this.author.imagePath }, + removeClick() { + const payload = { + message: this.$getString('MessageConfirmRemoveAuthor', [this.author.name]), + callback: (confirmed) => { + if (confirmed) { + this.processing = true + this.$axios + .$delete(`/api/authors/${this.authorId}`) + .then(() => { + this.$toast.success('Author removed') + this.show = false + }) + .catch((error) => { + console.error('Failed to remove author', error) + this.$toast.error('Failed to remove author') + }) + .finally(() => { + this.processing = false + }) + } + }, + type: 'yesNo' + } + this.$store.commit('globals/setConfirmPrompt', payload) + }, async submitForm() { var keysToCheck = ['name', 'asin', 'description', 'imagePath'] var updatePayload = {} diff --git a/client/components/modals/item/tabs/Match.vue b/client/components/modals/item/tabs/Match.vue index 58c52df8..0c5d67eb 100644 --- a/client/components/modals/item/tabs/Match.vue +++ b/client/components/modals/item/tabs/Match.vue @@ -205,7 +205,7 @@ export default { processing: Boolean, libraryItem: { type: Object, - default: () => {} + default: () => { } } }, data() { @@ -305,7 +305,7 @@ export default { const filterData = this.$store.state.libraries.filterData || {} const currentGenres = filterData.genres || [] const selectedMatchGenres = this.selectedMatch.genres || [] - return [...new Set([...currentGenres ,...selectedMatchGenres])] + return [...new Set([...currentGenres, ...selectedMatchGenres])] } }, methods: { @@ -325,9 +325,9 @@ export default { } }, getSearchQuery() { - if (this.isPodcast) return `term=${this.searchTitle}` - var searchQuery = `provider=${this.provider}&fallbackTitleOnly=1&title=${this.searchTitle}` - if (this.searchAuthor) searchQuery += `&author=${this.searchAuthor}` + if (this.isPodcast) return `term=${encodeURIComponent(this.searchTitle)}` + var searchQuery = `provider=${this.provider}&fallbackTitleOnly=1&title=${encodeURIComponent(this.searchTitle)}` + if (this.searchAuthor) searchQuery += `&author=${encodeURIComponent(this.searchAuthor)}` return searchQuery }, submitSearch() { @@ -580,6 +580,7 @@ export default { .matchListWrapper { height: calc(100% - 124px); } + @media (min-width: 768px) { .matchListWrapper { height: calc(100% - 80px); diff --git a/client/components/modals/libraries/EditLibrary.vue b/client/components/modals/libraries/EditLibrary.vue index 83f37ab7..598f3bcd 100644 --- a/client/components/modals/libraries/EditLibrary.vue +++ b/client/components/modals/libraries/EditLibrary.vue @@ -20,7 +20,7 @@

{{ $strings.LabelFolders }}

folder - + close
@@ -67,10 +67,6 @@ export default { value: 'podcast', text: this.$strings.LabelPodcasts } - // { - // value: 'music', - // text: 'Music' - // } ] }, folderPaths() { @@ -110,6 +106,11 @@ export default { formUpdated() { this.$emit('update', this.getLibraryData()) }, + existingFolderInputBlurred(folder) { + if (!folder.fullPath) { + this.removeFolder(folder) + } + }, newFolderInputBlurred() { if (this.newFolderPath) { this.folders.push({ fullPath: this.newFolderPath }) @@ -149,6 +150,7 @@ export default { this.folders = this.library ? this.library.folders.map((p) => ({ ...p })) : [] this.icon = this.library ? this.library.icon : 'default' this.mediaType = this.library ? this.library.mediaType : 'book' + this.showDirectoryPicker = false } }, diff --git a/client/components/modals/libraries/EditModal.vue b/client/components/modals/libraries/EditModal.vue index 2d1ceac5..633b7646 100644 --- a/client/components/modals/libraries/EditModal.vue +++ b/client/components/modals/libraries/EditModal.vue @@ -120,7 +120,7 @@ export default { for (const key in this.libraryCopy) { if (library[key] !== undefined) { if (key === 'folders') { - this.libraryCopy.folders = library.folders.map((f) => ({ ...f })) + this.libraryCopy.folders = library.folders.map((f) => ({ ...f })).filter((f) => !!f.fullPath?.trim()) } else if (key === 'settings') { for (const settingKey in library.settings) { this.libraryCopy.settings[settingKey] = library.settings[settingKey] diff --git a/client/components/tables/BackupsTable.vue b/client/components/tables/BackupsTable.vue index a216f463..08692a4d 100644 --- a/client/components/tables/BackupsTable.vue +++ b/client/components/tables/BackupsTable.vue @@ -164,6 +164,7 @@ export default { this.$axios .$get('/api/backups') .then((data) => { + this.$emit('loaded', data.backupLocation) this.setBackups(data.backups || []) }) .catch((error) => { diff --git a/client/components/tables/podcast/EpisodesTable.vue b/client/components/tables/podcast/EpisodesTable.vue index fcfe705e..9534b34e 100644 --- a/client/components/tables/podcast/EpisodesTable.vue +++ b/client/components/tables/podcast/EpisodesTable.vue @@ -191,6 +191,7 @@ export default { } }, methods: { + submit() {}, inputUpdate() { clearTimeout(this.searchTimeout) this.searchTimeout = setTimeout(() => { diff --git a/client/package-lock.json b/client/package-lock.json index cf9491cc..25000ab0 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -1,12 +1,12 @@ { "name": "audiobookshelf-client", - "version": "2.4.3", + "version": "2.4.4", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "audiobookshelf-client", - "version": "2.4.3", + "version": "2.4.4", "license": "ISC", "dependencies": { "@nuxtjs/axios": "^5.13.6", diff --git a/client/package.json b/client/package.json index 3c90c31f..cc785926 100644 --- a/client/package.json +++ b/client/package.json @@ -1,6 +1,6 @@ { "name": "audiobookshelf-client", - "version": "2.4.3", + "version": "2.4.4", "description": "Self-hosted audiobook and podcast client", "main": "index.js", "scripts": { diff --git a/client/pages/config/backups.vue b/client/pages/config/backups.vue index ba6ff2be..614587bf 100644 --- a/client/pages/config/backups.vue +++ b/client/pages/config/backups.vue @@ -1,6 +1,12 @@