From 01a1bb630e6e29b60a9f20671287913a3993e256 Mon Sep 17 00:00:00 2001 From: secondl1ght <85003930+secondl1ght@users.noreply.github.com> Date: Fri, 16 Sep 2022 23:34:58 -0600 Subject: add loading state to invoice button, improve nav button states/styles --- src/routes/[username]/receive/+page.svelte | 32 +++++++++++++++++++++++++++--- src/routes/invoice/[id]/+page.svelte | 2 +- 2 files changed, 30 insertions(+), 4 deletions(-) (limited to 'src/routes') diff --git a/src/routes/[username]/receive/+page.svelte b/src/routes/[username]/receive/+page.svelte index 699fa4bd..68cf0d83 100644 --- a/src/routes/[username]/receive/+page.svelte +++ b/src/routes/[username]/receive/+page.svelte @@ -9,6 +9,7 @@ let useFiat = true; let amountFiat = 0; let amountSats = 0; + let loading = false; $: amount = parseInt(useFiat ? Math.round(amountFiat / ($selectedRate / 100000000)) : amountSats); @@ -73,6 +74,7 @@ }; let submit = async () => { + loading = true; let id = await post('/invoice', { amount, rate: $selectedRate, @@ -171,13 +173,37 @@