diff options
| author | Adam Soltys <[email protected]> | 2024-12-26 13:55:33 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2024-12-26 13:55:33 -0800 |
| commit | 5590f9c8d87cabfae4375bd4520cb323992feca4 (patch) | |
| tree | 2eafb84fea10bea51c636a98302621ce16e667ea /src | |
| parent | 23f0335aeb26b56d835a7134227e43f8798fc3c5 (diff) | |
| download | coinos-ui-5590f9c8d87cabfae4375bd4520cb323992feca4.tar.gz coinos-ui-5590f9c8d87cabfae4375bd4520cb323992feca4.zip | |
bolt 12 type
Diffstat (limited to 'src')
| -rw-r--r-- | src/components/Payments.svelte | 2 | ||||
| -rw-r--r-- | src/routes/(app)/invoices/+page.server.ts | 7 | ||||
| -rw-r--r-- | src/routes/(app)/invoices/+page.svelte | 9 |
3 files changed, 17 insertions, 1 deletions
diff --git a/src/components/Payments.svelte b/src/components/Payments.svelte index 2d38513e..fdc6ea03 100644 --- a/src/components/Payments.svelte +++ b/src/components/Payments.svelte @@ -76,7 +76,7 @@ </div> {:else} <div class="text-secondary flex items-center gap-1"> - {#if p.type === types.lightning} + {#if p.type === types.lightning || p.types === types.bolt12} <iconify-icon icon="ph:lightning-fill" class="text-yellow-300 text-3xl" diff --git a/src/routes/(app)/invoices/+page.server.ts b/src/routes/(app)/invoices/+page.server.ts new file mode 100644 index 00000000..081d6a5b --- /dev/null +++ b/src/routes/(app)/invoices/+page.server.ts @@ -0,0 +1,7 @@ +import { auth, get } from "$lib/utils"; + +export async function load({ cookies }) { + const invoices = await get("/invoices", auth(cookies)); + console.log(invoices.length) + return { invoices }; +} diff --git a/src/routes/(app)/invoices/+page.svelte b/src/routes/(app)/invoices/+page.svelte new file mode 100644 index 00000000..ffbc550e --- /dev/null +++ b/src/routes/(app)/invoices/+page.svelte @@ -0,0 +1,9 @@ +<script> + let { data } = $props(); + let { invoices } = $derived(data); +</script> + +{invoices.length} +{#each invoices as i} + {JSON.stringify(i)} +{/each} |
