From 7ad44544cfba12581694a4cae6b458709dc543f8 Mon Sep 17 00:00:00 2001 From: florianfederspiel Date: Wed, 25 Mar 2026 17:20:47 +0100 Subject: [PATCH] Fix #119 Fix #153 --- frontend/pages/files/index.vue | 118 +++++++++++++++++++++------------ 1 file changed, 75 insertions(+), 43 deletions(-) diff --git a/frontend/pages/files/index.vue b/frontend/pages/files/index.vue index 58f1949..5c1c7e1 100644 --- a/frontend/pages/files/index.vue +++ b/frontend/pages/files/index.vue @@ -37,6 +37,14 @@ const renameData = ref({id: null, name: '', type: ''}) const selectedFileIndex = ref(0) const draggedItem = ref(null) +const getEntryActions = (entry) => [[ + { + label: 'Umbenennen', + icon: 'i-heroicons-pencil-square', + onSelect: () => openRenameModal(entry) + } +]] + // --- Search & Debounce --- const searchString = ref(tempStore.searchStrings["files"] || '') const debouncedSearch = ref(searchString.value) @@ -289,11 +297,15 @@ const showFile = (fileId) => { }) } +const isDialogOpen = computed(() => createFolderModalOpen.value || renameModalOpen.value) + defineShortcuts({ '/': () => document.getElementById("searchinput")?.focus(), 'Enter': { - usingInput: true, + usingInput: false, handler: () => { + if (isDialogOpen.value) return + const entry = renderedFileList.value[selectedFileIndex.value] if (!entry) return if (entry.type === "file") showFile(entry.id) @@ -413,10 +425,13 @@ const syncdokubox = async () => { {{ entry.type !== 'up' ? dayjs(entry.createdAt).format("DD.MM.YY") : '-' }} - - - + + + @@ -438,11 +453,15 @@ const syncdokubox = async () => { class="group relative bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700 rounded-xl p-4 flex flex-col items-center hover:border-primary-500 transition-all cursor-pointer" @click="entry.type === 'folder' ? changeFolder(entry) : (entry.type === 'up' ? navigateUp() : showFile(entry.id))" > - - - + + + {