From a52fc3fd923fec30cfdd3d804554e6fe4534c400 Mon Sep 17 00:00:00 2001 From: Fabio Di Stasio Date: Fri, 22 Dec 2023 18:48:16 +0100 Subject: [PATCH] feat: buttons to save and access to saved queryes from query tab --- src/renderer/components/TheScratchpad.vue | 3 +- src/renderer/components/TheSettingBar.vue | 2 +- src/renderer/components/WorkspaceTabQuery.vue | 57 +++++++++++++++---- src/renderer/i18n/en-US.ts | 3 +- src/renderer/stores/application.ts | 10 +++- src/renderer/stores/scratchpad.ts | 1 + 6 files changed, 58 insertions(+), 18 deletions(-) diff --git a/src/renderer/components/TheScratchpad.vue b/src/renderer/components/TheScratchpad.vue index 6e03cdd2..a87f0ac4 100644 --- a/src/renderer/components/TheScratchpad.vue +++ b/src/renderer/components/TheScratchpad.vue @@ -180,7 +180,7 @@ const { t } = useI18n(); const applicationStore = useApplicationStore(); const scratchpadStore = useScratchpadStore(); -const { connectionNotes } = storeToRefs(scratchpadStore); +const { connectionNotes, selectedTag } = storeToRefs(scratchpadStore); const { changeNotes } = scratchpadStore; const { hideScratchpad } = applicationStore; const { getConnectionName } = useConnectionsStore(); @@ -202,7 +202,6 @@ const showArchived = ref(false); const isAddModal = ref(false); const isEditModal = ref(false); const noteToEdit: Ref = ref(null); -const selectedTag = ref('all'); const selectedNote = ref(null); const noteTags: ComputedRef<{code: TagCode; name: string}[]> = computed(() => [ diff --git a/src/renderer/components/TheSettingBar.vue b/src/renderer/components/TheSettingBar.vue index 1f56236e..8a2e77da 100644 --- a/src/renderer/components/TheSettingBar.vue +++ b/src/renderer/components/TheSettingBar.vue @@ -65,7 +65,7 @@ content: t('application.note', 2) }" class="settingbar-element btn btn-link" - @click="showScratchpad" + @click="showScratchpad()" > - - {{ t('general.format') }} + +
+ + +