From 78c201d8d9d2f3ec07f6ea36201977846e29ccd9 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Wed, 4 Feb 2026 12:42:42 -0800 Subject: homepage design and currency toggling --- src/routes/(app)/account/[id]/+page.svelte | 55 ++++++++++++------------------ 1 file changed, 21 insertions(+), 34 deletions(-) (limited to 'src/routes/(app)/account') diff --git a/src/routes/(app)/account/[id]/+page.svelte b/src/routes/(app)/account/[id]/+page.svelte index bda81cbc..d3204a10 100644 --- a/src/routes/(app)/account/[id]/+page.svelte +++ b/src/routes/(app)/account/[id]/+page.svelte @@ -8,21 +8,24 @@ import { t } from "$lib/translations"; import { entropyToMnemonic, mnemonicToSeed } from "@scure/bip39"; import { wordlist } from "@scure/bip39/wordlists/english.js"; - import { - PUBLIC_COINOS_PUBKEY as pk, - PUBLIC_COINOS_RELAY as relay, - } from "$env/static/public"; let { data } = $props(); let { account, user } = data; - let { id, name, seed } = account; + let { id, seed } = account; + let displayType = $derived( + account.type === "ark" + ? $t("accounts.ark") + : seed + ? $t("accounts.bitcoin") + : $t("accounts.custodial"), + ); + let name = $state(account.name || displayType); let mnemonic = $state(), password = $state(); let passwordPrompt = $state(); let cancel = $state(() => (passwordPrompt = false)); let toggle = () => (passwordPrompt = !passwordPrompt); - let lud16 = $derived(`${user.username}@${$page.url.host}`); let submit = $state(async () => { toggle(); @@ -40,11 +43,6 @@ } }; - let nwc = $state(); - let revealNwc = () => - (nwc = `nostr+walletconnect://${pk}?relay=${encodeURIComponent( - relay, - )}&secret=${user.nwc}&lud16=${lud16}`);
@@ -54,6 +52,15 @@
+
+ + +
+
{#if mnemonic} @@ -69,28 +76,6 @@ >
{$t("accounts.revealMnemonic")}
- {:else if nwc} -
- {nwc} -
- - - - - {:else} - {/if} {#if seed} @@ -102,7 +87,9 @@ {/if}
-
+
-- cgit v1.2.3