diff options
| author | Adam Soltys <[email protected]> | 2024-11-29 11:38:38 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2024-11-29 11:38:38 -0800 |
| commit | 6e6a9e9aa0ab44ef9a316c0fe6ad9abb80f8d7b0 (patch) | |
| tree | 7cbae6cd5bb1cd2ed18176af2ae990839b843bbb /src/components/Amount.svelte | |
| parent | b01f143ee659fb71dfcc2d1cc21b835879ba8b55 (diff) | |
| download | coinos-ui-6e6a9e9aa0ab44ef9a316c0fe6ad9abb80f8d7b0.tar.gz coinos-ui-6e6a9e9aa0ab44ef9a316c0fe6ad9abb80f8d7b0.zip | |
strip commas on paste
Diffstat (limited to 'src/components/Amount.svelte')
| -rw-r--r-- | src/components/Amount.svelte | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/components/Amount.svelte b/src/components/Amount.svelte index 035152d1..7efafca8 100644 --- a/src/components/Amount.svelte +++ b/src/components/Amount.svelte @@ -1,13 +1,14 @@ <script> import { s, f, toFiat } from "$lib/utils"; import { fiat } from "$lib/store"; - const { amount, locale, tip, rate, currency } = $props(); + const { align, amount, locale, tip, rate, currency } = $props(); </script> {#if amount} <div> <h2 - class="text-2xl md:text-3xl font-semibold flex justify-center items-end" + class="text-2xl md:text-3xl font-semibold flex items-end" + class:justify-center={align !== "left"} > <div class="flex items-center"> <iconify-icon icon="ph:lightning-fill" class="text-yellow-300" @@ -23,7 +24,10 @@ </div> {/if} </h2> - <h3 class="flex text-secondary md:text-lg justify-center"> + <h3 + class="flex text-secondary md:text-lg" + class:justify-center={align !== "left"} + > {f(toFiat(amount, rate), currency, locale)} {#if tip} <span class="text-base"> |
