diff options
| author | Adam Soltys <[email protected]> | 2026-02-11 17:09:39 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-02-11 17:09:39 -0800 |
| commit | 3aa9ce1b5985397d7f568887ec6f881df13c1034 (patch) | |
| tree | 2c459692dc5315e92924de6be9f0999a835e0f54 /src/components/AppHeader.svelte | |
| parent | 8a4b0087cbfe8b43d9b43d19af6d991a646ef3d7 (diff) | |
| download | coinos-ui-3aa9ce1b5985397d7f568887ec6f881df13c1034.tar.gz coinos-ui-3aa9ce1b5985397d7f568887ec6f881df13c1034.zip | |
fix ts errors
Diffstat (limited to 'src/components/AppHeader.svelte')
| -rw-r--r-- | src/components/AppHeader.svelte | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/components/AppHeader.svelte b/src/components/AppHeader.svelte index 0ab48706..f45f4d0c 100644 --- a/src/components/AppHeader.svelte +++ b/src/components/AppHeader.svelte @@ -8,12 +8,12 @@ let { user, subject = $bindable() } = $props(); - let w = $state(); + let w: number | undefined = $state(); $effect(() => (subject = subject || user)); let bg = $derived( - $banner?.id && $banner.id === subject?.id - ? `url(${$banner.src})` + ($banner as any)?.id && ($banner as any).id === subject?.id + ? `url(${($banner as any).src})` : subject?.banner ? subject.banner.includes(":") ? `url(${subject.banner})` @@ -71,10 +71,10 @@ > <nav class="flex justify-end items-center space-x-4 p-5"> {#if user} - {#each links as { href, icon, flip, label }} + {#each links as { href, icon, label }} <a {href} data-sveltekit-preload-code="eager" aria-label={label}> <button class="btn-menu {opacity(href)}" aria-label={label}> - <iconify-icon noobserver {icon} width={w > 640 ? 32 : 24} {flip} + <iconify-icon noobserver {icon} width={(w ?? 0) > 640 ? 32 : 24} ></iconify-icon> </button> </a> |
