diff --git a/package.json b/package.json index 25f6f6f..66675dc 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "build": "vite build", "preview": "vite preview", "check": "svelte-check --tsconfig ./tsconfig.json", - "deploy": "npx gh-pages -d dist" + "deploy": "npx gh-pages -d dist -b gh-pages" }, "devDependencies": { "@iconify/icons-ic": "^1.2.11", diff --git a/src/lib/CounterApp/CounterApp.svelte b/src/lib/CounterApp/CounterApp.svelte index 3b30341..fc8db9f 100644 --- a/src/lib/CounterApp/CounterApp.svelte +++ b/src/lib/CounterApp/CounterApp.svelte @@ -21,6 +21,8 @@ function save_data(data: any) { anything_changed = false; } //#endregion + +// @ts-ignore $: counters_data, (anything_changed = true); //#region variables initialize @@ -34,13 +36,14 @@ $: { if (anything_changed == false) { break $; } else { - anything_changed = + anything_changed = // @ts-ignore Array.from(counters_saved) === Array.from(counters_data) ? false : true; } } onMount(() => { if (localStorage.getItem("counters_saved") !== null) { + // @ts-ignore counters_data = Array.from(get(counters_saved)); counter_count = counters_data[counters_data.length - 1].id; } @@ -110,13 +113,11 @@ function handle_save() {
{#each counters_data as item, i (item.id)}
diff --git a/src/lib/CounterApp/components/CounterTopBar.svelte b/src/lib/CounterApp/components/CounterTopBar.svelte index 884688e..2533f2f 100644 --- a/src/lib/CounterApp/components/CounterTopBar.svelte +++ b/src/lib/CounterApp/components/CounterTopBar.svelte @@ -37,110 +37,113 @@ let dispatch = createEventDispatcher(); export let noOfCounters: number; -
-
-
- - - - - - - - Delete mode - - - - Rename mode - - - +
+
+
+
+ + + + + + + + Delete mode + + + + Rename mode + + + - - Smart mode - - - - Smart text - - - - Minus mode - + + Smart mode + + + + Smart text + + + + Minus mode + - - Edit Counters size - - - - - Show counter id - - - + + Edit Counters size + + + + + Show counter id + + + - - - Reset all - - - {#if $delete_mode} - - {:else if $Counter_size_editing} - - {:else} -
- -
- {/if} -
+ {:else if $Counter_size_editing} + + {:else} +
+ +
+ {/if} +
-
- +
+ +
diff --git a/src/lib/Home.svelte b/src/lib/Home.svelte index 735504f..1655c3e 100644 --- a/src/lib/Home.svelte +++ b/src/lib/Home.svelte @@ -1,6 +1,6 @@