From 9f28102a8736c9fd72f88737db5ec498645a4717 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carsten=20Gr=C3=A4f?= Date: Sun, 11 Feb 2024 08:56:53 +0100 Subject: [PATCH 1/3] TAB-485 move gitsync data to account and store in backend --- src/pages/SettingsPage.vue | 12 ++----- src/pages/SidePanelPage.vue | 23 ++++++------ src/pages/helper/SyncingSettings.vue | 35 +++++++++---------- .../persistence/GitPersistentService.ts | 4 +-- src/stores/searchStore.ts | 1 - src/stores/settingsStore.ts | 2 +- 6 files changed, 33 insertions(+), 44 deletions(-) diff --git a/src/pages/SettingsPage.vue b/src/pages/SettingsPage.vue index c697848c..d5438743 100644 --- a/src/pages/SettingsPage.vue +++ b/src/pages/SettingsPage.vue @@ -531,7 +531,7 @@ onMounted(() => { let suggestionsCounter = 0 watchEffect(() => { - console.log("watching settingsStore.activeToggles...", settingsStore.activeToggles) + //console.log("watching settingsStore.activeToggles...", settingsStore.activeToggles) devEnabled.value = settingsStore.isEnabled('dev') ddgEnabled.value = settingsStore.isEnabled('noDDG') ignoreExtensionsEnabled.value = settingsStore.isEnabled('extensionsAsTabs') @@ -575,7 +575,7 @@ watch(() => pageCapturePermissionGranted.value, (newValue, oldValue) => { }) watchEffect(() => { - console.log("***setting dark mode to ", typeof darkMode.value, darkMode.value) + //console.log("***setting dark mode to ", typeof darkMode.value, darkMode.value) switch (darkMode.value) { case "true": $q.dark.set(true) @@ -628,14 +628,6 @@ watchEffect(() => { sendMsg('detail-level-perTabset-changed', {level: detailLevelPerTabset.value}) }) -watchEffect(() => { - console.log("activeToggles watcheffect", devEnabled.value) - //settingsStore.setFeatureToggle("stats", statsEnabled.value) - //settingsStore.setFeatureToggle("dev", devEnabled.value) - // settingsStore.setFeatureToggle("noDDG", !ddgEnabled.value) - // settingsStore.setFeatureToggle("extensionsAsTabs", !ignoreExtensionsEnabled.value) -}) - watchEffect(() => { localStorage.set("layout", view.value) }) diff --git a/src/pages/SidePanelPage.vue b/src/pages/SidePanelPage.vue index 3f02aaeb..7f3fd5be 100644 --- a/src/pages/SidePanelPage.vue +++ b/src/pages/SidePanelPage.vue @@ -278,16 +278,15 @@ @@ -330,7 +329,7 @@ import {CopyToClipboardCommand} from "src/domain/commands/CopyToClipboard"; import SidePanelTabsetDescriptionPage from "pages/sidepanel/SidePanelTabsetDescriptionPage.vue"; import ShareTabsetPubliclyDialog from "components/dialogues/ShareTabsetPubliclyDialog.vue"; import MqttService from "src/services/mqtt/MqttService"; -import {SyncType, useAppStore} from "stores/appStore"; +import {SyncType} from "stores/appStore"; import {useVOnboarding, VOnboardingStep, VOnboardingWrapper} from 'v-onboarding' import {FirebaseCall} from "src/services/firebase/FirebaseCall"; import getScrollTarget = scroll.getScrollTarget; @@ -1019,6 +1018,8 @@ const tabsetSectionName = (tabset: Tabset) => { return tabset.name + (activeFolder ? " - " + activeFolder.name : "") } +const syncSource = () => LocalStorage.getItem(SYNC_GITHUB_URL) +