diff options
| author | Adam Soltys <[email protected]> | 2026-03-03 16:08:52 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-03-03 16:08:52 -0800 |
| commit | 8551df92b96ff69f3cda50184cb714ba30f3803d (patch) | |
| tree | b53b414d20d40d9bb9ab33764caa113c5996a262 /src/components/InvoiceTypes.svelte | |
| parent | 14fff3ba852b1d696f61a0da25aaf0e04ccd4158 (diff) | |
| download | coinos-ui-8551df92b96ff69f3cda50184cb714ba30f3803d.tar.gz coinos-ui-8551df92b96ff69f3cda50184cb714ba30f3803d.zip | |
get rid of /receive route
Diffstat (limited to 'src/components/InvoiceTypes.svelte')
| -rw-r--r-- | src/components/InvoiceTypes.svelte | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/components/InvoiceTypes.svelte b/src/components/InvoiceTypes.svelte index b518364d..489fb367 100644 --- a/src/components/InvoiceTypes.svelte +++ b/src/components/InvoiceTypes.svelte @@ -2,7 +2,6 @@ import PhLightningFill from "virtual:icons/ph/lightning-fill"; import PhXBold from "virtual:icons/ph/x-bold"; import { types } from "$lib/utils"; - import { page } from "$app/stores"; import { amountPrompt } from "$lib/store"; let { newAmount = $bindable(), @@ -14,6 +13,7 @@ setAmount, setType, activeOnly = false, + lnurlMode = false, } = $props(); let { aid, address_type, type } = $derived(invoice); @@ -60,10 +60,9 @@ <div class="flex flex-wrap gap-2"> <button class="btn flex-nowrap !w-auto grow" - class:bg-base-300={type === types.lightning && $page.url.pathname.includes("/receive")} - class:text-secondary={type === types.lightning && $page.url.pathname.includes("/receive")} - class:hidden={activeOnly && - (type !== types.lightning || !$page.url.pathname.includes("/receive"))} + class:bg-base-300={lnurlMode} + class:text-secondary={lnurlMode} + class:hidden={activeOnly && !lnurlMode} onclick={() => { if (activeOnly) toggleType(); else { @@ -97,10 +96,9 @@ <button class="btn flex-nowrap !w-auto grow" - class:bg-base-300={type === types.lightning && !$page.url.pathname.includes("/receive")} - class:text-secondary={type === types.lightning && !$page.url.pathname.includes("/receive")} - class:hidden={activeOnly && - (type !== types.lightning || $page.url.pathname.includes("/receive"))} + class:bg-base-300={type === types.lightning && !lnurlMode} + class:text-secondary={type === types.lightning && !lnurlMode} + class:hidden={activeOnly && !(type === types.lightning && !lnurlMode)} onclick={() => { if (activeOnly) toggleType(); else { |
