diff options
Diffstat (limited to 'src/components/Balance.svelte')
| -rw-r--r-- | src/components/Balance.svelte | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/components/Balance.svelte b/src/components/Balance.svelte index 0cc27068..91463f7e 100644 --- a/src/components/Balance.svelte +++ b/src/components/Balance.svelte @@ -1,12 +1,14 @@ <script> + import { preventDefault } from 'svelte/legacy'; + import Icon from "$comp/Icon.svelte"; import Pin from "$comp/Pin.svelte"; import { f, s, sat, sats } from "$lib/utils"; import { pin } from "$lib/store"; import { t } from "$lib/translations"; - let show; - export let user, rate, balance; + let show = $state(); + let { user, rate, balance } = $props(); </script> {#if show && user.haspin && $pin?.length !== 6} @@ -16,7 +18,7 @@ <div> {#if user.haspin && !$pin} <button - on:click|preventDefault={() => (show = true)} + onclick={preventDefault(() => (show = true))} class="flex gap-2 text-xl" > <Icon icon="eye-off" style="w-8 my-auto" /> |
