diff options
| author | Adam Soltys <[email protected]> | 2026-03-04 15:05:44 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-03-04 15:05:44 -0800 |
| commit | e6882c6a8987e23215a2538b242431ae603c7101 (patch) | |
| tree | cdfd3a29015e630ae552968195e02c835b0c3978 /src/components | |
| parent | 350a2a46aa3b48d3223b6e5c14ddc5952d260dba (diff) | |
| download | coinos-ui-e6882c6a8987e23215a2538b242431ae603c7101.tar.gz coinos-ui-e6882c6a8987e23215a2538b242431ae603c7101.zip | |
invoice page improvements
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/Account.svelte | 2 | ||||
| -rw-r--r-- | src/components/InvoiceActions.svelte | 48 | ||||
| -rw-r--r-- | src/components/LandingHeader.svelte | 2 |
3 files changed, 24 insertions, 28 deletions
diff --git a/src/components/Account.svelte b/src/components/Account.svelte index 67a359ee..e29e1765 100644 --- a/src/components/Account.svelte +++ b/src/components/Account.svelte @@ -86,7 +86,7 @@ } }; - let receiveUrl = $derived(id === user.id ? "/invoice?lnurl=true" : "/invoice"); + let receiveUrl = $derived(id === user.id ? `/invoice/lnurl` : `/invoice?aid=${id}`); let displayType = $derived( accountType === "ark" diff --git a/src/components/InvoiceActions.svelte b/src/components/InvoiceActions.svelte index 89203413..1c34d5ac 100644 --- a/src/components/InvoiceActions.svelte +++ b/src/components/InvoiceActions.svelte @@ -56,7 +56,7 @@ <div class="my-auto">{t("payments.setAmount")}</div> </button> {:else} - <a href={link} class="block"> + <a href={link} class="contents"> <button class="btn grow !w-auto"> <PhArrowSquareOutBold width="32" /> <div class="my-auto">{t("payments.openLink")}</div> @@ -73,25 +73,23 @@ <div class="flex gap-2"> - {#if aid === user.id} - <button - class="btn flex-nowrap !w-auto grow" - class:bg-base-300={type === types.lightning} - class:text-secondary={type === types.lightning} - onclick={() => { - $amountPrompt = false; - newAmount = undefined; - setType(types.lightning); - }} - > - <div class="bg-black rounded-full w-8 h-8 items-center justify-center flex"> - <div class="m-auto"> - <PhLightningFill width="24" class="text-yellow-300" /> - </div> + <button + class="btn flex-nowrap !w-auto grow" + class:bg-base-300={type === types.lightning} + class:text-secondary={type === types.lightning} + onclick={() => { + $amountPrompt = false; + newAmount = undefined; + setType(types.lightning); + }} + > + <div class="bg-black rounded-full w-8 h-8 items-center justify-center flex"> + <div class="m-auto"> + <PhLightningFill width="24" class="text-yellow-300" /> </div> - <div class="my-auto text-lg">Lightning</div> - </button> - {/if} + </div> + <div class="my-auto text-lg">Lightning</div> + </button> {#if !account?.seed && !(account?.pubkey && account?.fingerprint) && account?.type !== "ark"} <button @@ -106,11 +104,9 @@ {/if} </div> - {#if aid === user.id} - <button type="button" class="btn" onclick={toggleType}> - <img src="/images/liquid.svg" class="w-8" alt="Liquid" /> - <img src="/images/cash.png" class="w-8 my-auto" alt="Ecash" /> - <div class="my-auto">{t("payments.moreOptions")}</div> - </button> - {/if} + <button type="button" class="btn" onclick={toggleType}> + <img src="/images/liquid.svg" class="w-8" alt="Liquid" /> + <img src="/images/cash.png" class="w-8 my-auto" alt="Ecash" /> + <div class="my-auto">{t("payments.moreOptions")}</div> + </button> </div> diff --git a/src/components/LandingHeader.svelte b/src/components/LandingHeader.svelte index 1e3b3266..690f0f0e 100644 --- a/src/components/LandingHeader.svelte +++ b/src/components/LandingHeader.svelte @@ -13,7 +13,7 @@ function startNow() { const match = document.cookie.match(/(?:^|;\s*)username=([^;]*)/); - goto(match ? `/${decodeURIComponent(match[1])}` : "/login"); + goto(match ? `/${decodeURIComponent(match[1])}` : "/register"); } let header = $state(); |
