From 55d6c1cabe095b286f8c04a95284d88cb4027849 Mon Sep 17 00:00:00 2001 From: Andrew Michael McNutt Date: Sun, 15 Sep 2024 10:06:51 -0700 Subject: [PATCH] persist selected folder --- .../src/content-modules/ComparePal.svelte | 18 +++++++------- .../src/content-modules/Manage.svelte | 24 ++++++------------- .../src/controls/FolderConfig.svelte | 6 ++--- apps/color-buddy/src/stores/config-store.ts | 4 ++++ 4 files changed, 24 insertions(+), 28 deletions(-) diff --git a/apps/color-buddy/src/content-modules/ComparePal.svelte b/apps/color-buddy/src/content-modules/ComparePal.svelte index 39a6ec1..cd10c3c 100644 --- a/apps/color-buddy/src/content-modules/ComparePal.svelte +++ b/apps/color-buddy/src/content-modules/ComparePal.svelte @@ -37,10 +37,7 @@ let showDiff = false; let colorSpace = ComparisonPal?.colorSpace || "lab"; - let selectedFolder: { isPreMade: boolean; name: string } = { - isPreMade: false, - name: "", - }; + $: selectedFolder = $configStore.selectedFolder; $: familiarPals = $examplePalStore.palettes .map((x) => x.palette) .filter((x) => selectedFolder.isPreMade && x.type === selectedFolder.name); @@ -80,7 +77,10 @@