diff --git a/client/components/app/BookShelfToolbar.vue b/client/components/app/BookShelfToolbar.vue index 5a869f7f6..54450164c 100644 --- a/client/components/app/BookShelfToolbar.vue +++ b/client/components/app/BookShelfToolbar.vue @@ -159,6 +159,7 @@ export default { } this.addSubtitlesMenuItem(items) + this.addDetailsOnHoverMenuItem(items) return items }, @@ -329,6 +330,7 @@ export default { this.addSubtitlesMenuItem(items) this.addCollapseSeriesMenuItem(items) + this.addDetailsOnHoverMenuItem(items) return items }, @@ -367,6 +369,21 @@ export default { } } }, + addDetailsOnHoverMenuItem(items) { + if (this.isBookLibrary && (!this.page || this.page === 'search')) { + if (this.settings.showDetailsOnHover) { + items.push({ + text: this.$strings.LabelHideDetailsOnHover, + action: 'hide-details-on-hover' + }) + } else { + items.push({ + text: this.$strings.LabelShowDetailsOnHover, + action: 'show-details-on-hover' + }) + } + } + }, handleSubtitlesAction(action) { if (action === 'show-subtitles') { this.settings.showSubtitles = true @@ -393,6 +410,19 @@ export default { } return false }, + handleDetailsOnHoverAction(action) { + if (action === 'show-details-on-hover') { + this.settings.showDetailsOnHover = true + this.updateShowDetailsOnHover() + return true + } + if (action === 'hide-details-on-hover') { + this.settings.showDetailsOnHover = false + this.updateShowDetailsOnHover() + return true + } + return false + }, contextMenuAction({ action }) { if (action === 'export-opml') { this.exportOPML() @@ -401,6 +431,8 @@ export default { return } else if (this.handleCollapseSeriesAction(action)) { return + } else if (this.handleDetailsOnHoverAction(action)) { + return } }, exportOPML() { @@ -423,6 +455,8 @@ export default { this.markSeriesFinished() } else if (this.handleSubtitlesAction(action)) { return + } else if (this.handleDetailsOnHoverAction(action)) { + return } }, showOpenSeriesRSSFeed() { @@ -555,6 +589,9 @@ export default { updateShowSubtitles() { this.saveSettings() }, + updateShowDetailsOnHover() { + this.saveSettings() + }, updateAuthorSort() { this.saveSettings() }, diff --git a/client/components/cards/LazyBookCard.vue b/client/components/cards/LazyBookCard.vue index 67884b47a..eefc31050 100644 --- a/client/components/cards/LazyBookCard.vue +++ b/client/components/cards/LazyBookCard.vue @@ -1,6 +1,6 @@