From 2603c570181a6d7fae0b732070afdf1530ac6d53 Mon Sep 17 00:00:00 2001 From: Santiago Lo Coco Date: Thu, 9 May 2024 14:01:53 +0200 Subject: [PATCH] Use runes and save config in localStorage --- src/routes/timer/+page.svelte | 194 ++++++++++++++++++++-------------- 1 file changed, 117 insertions(+), 77 deletions(-) diff --git a/src/routes/timer/+page.svelte b/src/routes/timer/+page.svelte index 5e588c4..80bbad3 100644 --- a/src/routes/timer/+page.svelte +++ b/src/routes/timer/+page.svelte @@ -1,48 +1,54 @@
+ +{#if !browser} +
+{:else} + +
-

Prevent CVS

Break interval: {BREAK_INTERVAL_STORE} minutes
Mini break duration: {MINI_BREAK_DURATION_STORE} seconds
Long break duration: {LONG_BREAK_DURATION_STORE} minutes
@@ -193,18 +207,22 @@
+

Prevent CVS

+
- {#if $state !== "Ready"} + {#if timerState !== "Ready"}
-

{$state}

-

Time left until end of break: {$timeLeftDisplay}

+

{timerState}

+

Time left until end of break: {timeLeftDisplay}

{:else} -

Time left until break: {$timeLeftDisplay}

+

Time left until break: {timeLeftDisplay}

{/if}
+ +{/if}