From a38335836991e80286f1a4578e5f037b569d79fa Mon Sep 17 00:00:00 2001 From: Leo Vasanko Date: Tue, 21 Nov 2023 16:11:54 +0000 Subject: [PATCH] Fix direct uploads and downloads, transfer bar UI --- frontend/src/App.vue | 4 ++ frontend/src/components/DownloadButton.vue | 40 ++++++------ frontend/src/components/TransferBar.vue | 15 +++-- frontend/src/components/UploadButton.vue | 74 +++++++++++----------- frontend/src/stores/main.ts | 10 ++- 5 files changed, 81 insertions(+), 62 deletions(-) diff --git a/frontend/src/App.vue b/frontend/src/App.vue index f8ecb9a..040aa20 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -10,6 +10,10 @@
+ - diff --git a/frontend/src/stores/main.ts b/frontend/src/stores/main.ts index 7541105..853258d 100644 --- a/frontend/src/stores/main.ts +++ b/frontend/src/stores/main.ts @@ -19,6 +19,8 @@ export const useMainStore = defineStore({ cursor: '' as string, server: {} as Record, dialog: '' as '' | 'login' | 'settings', + uprogress: {} as any, + dprogress: {} as any, prefs: { gallery: false, sortListing: '' as SortOrder, @@ -89,7 +91,13 @@ export const useMainStore = defineStore({ }, focusBreadcrumb() { (document.querySelector('.breadcrumb') as HTMLAnchorElement).focus() - } + }, + cancelDownloads() { + location.reload() // FIXME + }, + cancelUploads() { + location.reload() // FIXME + }, }, getters: { sortOrder(): SortOrder { return this.query ? this.prefs.sortFiltered : this.prefs.sortListing },