diff options
Diffstat (limited to 'src/routes/sent')
| -rw-r--r-- | src/routes/sent/+page.svelte | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/routes/sent/+page.svelte b/src/routes/sent/+page.svelte index f79166e4..95612a17 100644 --- a/src/routes/sent/+page.svelte +++ b/src/routes/sent/+page.svelte @@ -1,4 +1,5 @@ <script> + import { f, s, sats } from '$lib/utils'; import { scale } from 'svelte/transition'; import { Icon } from '$comp'; import { toast } from '@zerodevx/svelte-toast'; @@ -7,6 +8,12 @@ export let data; let { user } = data; + let payment = user.payments[0]; + let { amount, rate } = payment; + amount = Math.abs(amount); + + let fiat = (amount * rate) / sats; + toast.pop(0); </script> @@ -15,6 +22,10 @@ <Icon icon="check" style="mx-auto" /> </div> <h1 class="text-3xl md:text-4xl font-bold mb-6">Sent!</h1> + <h2 class="text-2xl md:text-3xl font-semibold"> + {f(fiat, user.currency)} + </h2> + <h3 class="text-secondary md:text-lg mb-6 mt-1">({s(amount)} SAT)</h3> <a href={`/${user.username}/transactions`}> <button class="bg-black text-white rounded-2xl w-20 py-3 font-bold hover:opacity-80"> {$t('invoice.done')} |
