From f68cff1df415d0987012af2bf123f8db76688111 Mon Sep 17 00:00:00 2001 From: Jannik Date: Sat, 27 Sep 2025 20:43:14 +0200 Subject: [PATCH] fix: race condition when changing view --- src/lib/components/lnv/Sidebar.svelte | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/lib/components/lnv/Sidebar.svelte b/src/lib/components/lnv/Sidebar.svelte index 15017ea..5ea4f6c 100644 --- a/src/lib/components/lnv/Sidebar.svelte +++ b/src/lib/components/lnv/Sidebar.svelte @@ -82,6 +82,7 @@ let hideSearch = $state(false); let CurrentView: Component = $state(LoadingSidebar); + let currentProps = $state({}); const modules = import.meta.glob("./sidebar/**/*.svelte"); $effect(() => { const path = @@ -97,6 +98,7 @@ } path().then((m) => { CurrentView = (m as { default: Component }).default; + currentProps = view.current.props || {}; }); }); $effect(() => { @@ -220,7 +222,7 @@ {#if routing.currentTrip} {:else} - + {/if} {#if !routing.currentTrip}