From 78448894d26e4246e1c0831405b78aca6f194719 Mon Sep 17 00:00:00 2001 From: Tony Edwards Date: Thu, 30 Nov 2023 19:02:51 +0000 Subject: [PATCH] Adds hiding audio book feedback promt/toast --- pages/item/_id/_episode/index.vue | 16 ++++++++++------ pages/item/_id/index.vue | 31 +++++++++++++++++-------------- 2 files changed, 27 insertions(+), 20 deletions(-) diff --git a/pages/item/_id/_episode/index.vue b/pages/item/_id/_episode/index.vue index 9baa81f3..82029af9 100644 --- a/pages/item/_id/_episode/index.vue +++ b/pages/item/_id/_episode/index.vue @@ -398,13 +398,17 @@ export default { console.log('Local folder', JSON.stringify(localFolder)) - const startDownloadMessage = `Start download for "${this.title}" to folder ${localFolder.name}?` - const { value } = await Dialog.confirm({ - title: 'Confirm', - message: startDownloadMessage - }) - if (value) { + if (this.isLowFeedback) { this.startDownload(localFolder) + } else { + const startDownloadMessage = `Start download for "${this.title}" to folder ${localFolder.name}?` + const { value } = await Dialog.confirm({ + title: 'Confirm', + message: startDownloadMessage + }) + if (value) { + this.startDownload(localFolder) + } } }, async selectFolder() { diff --git a/pages/item/_id/index.vue b/pages/item/_id/index.vue index 25e124ae..515f6b1b 100644 --- a/pages/item/_id/index.vue +++ b/pages/item/_id/index.vue @@ -618,21 +618,24 @@ export default { } console.log('Local folder', JSON.stringify(localFolder)) - - let startDownloadMessage = `Start download for "${this.title}" with ${this.numTracks} audio track${this.numTracks == 1 ? '' : 's'} to folder ${localFolder.name}?` - if (!this.isIos && this.showRead) { - if (this.numTracks > 0) { - startDownloadMessage = `Start download for "${this.title}" with ${this.numTracks} audio track${this.numTracks == 1 ? '' : 's'} and ebook file to folder ${localFolder.name}?` - } else { - startDownloadMessage = `Start download for "${this.title}" with ebook file to folder ${localFolder.name}?` - } - } - const { value } = await Dialog.confirm({ - title: 'Confirm', - message: startDownloadMessage - }) - if (value) { + if (this.isLowFeedback) { this.startDownload(localFolder) + } else { + let startDownloadMessage = `Start download for "${this.title}" with ${this.numTracks} audio track${this.numTracks == 1 ? '' : 's'} to folder ${localFolder.name}?` + if (!this.isIos && this.showRead) { + if (this.numTracks > 0) { + startDownloadMessage = `Start download for "${this.title}" with ${this.numTracks} audio track${this.numTracks == 1 ? '' : 's'} and ebook file to folder ${localFolder.name}?` + } else { + startDownloadMessage = `Start download for "${this.title}" with ebook file to folder ${localFolder.name}?` + } + } + const { value } = await Dialog.confirm({ + title: 'Confirm', + message: startDownloadMessage + }) + if (value) { + this.startDownload(localFolder) + } } }, async startDownload(localFolder = null) {