diff --git a/src/routes/events/[event_id]/(launcher)/launcher/+layout.svelte b/src/routes/events/[event_id]/(launcher)/launcher/+layout.svelte index d9a09fa7..65b94948 100644 --- a/src/routes/events/[event_id]/(launcher)/launcher/+layout.svelte +++ b/src/routes/events/[event_id]/(launcher)/launcher/+layout.svelte @@ -17,6 +17,7 @@ import { sineIn } from 'svelte/easing'; // *** Import other supporting libraries import { liveQuery } from 'dexie'; import { Drawer, Modal } from 'flowbite-svelte'; +import { fade } from 'svelte/transition'; import { listen, idle, onIdle, restartCountdown } from 'svelte-idle'; import { @@ -122,6 +123,15 @@ $effect(() => { }); }); +// Called by backdrop click. Writes to store immediately (don't rely on effect timing). +function close_cfg() { + modal_cfg_open = false; + events_loc.update((loc) => { + if (loc.launcher) loc.launcher.hide_drawer__cfg = true; + return loc; + }); +} + // Generate a stable per-device client ID on first load and persist it. // events_loc is backed by svelte-persisted-store (localStorage) so this // survives page reloads. Without this, client_id falls back to Date.now() @@ -928,41 +938,53 @@ $effect(() => { - - - +{#if modal_cfg_open} + +
- - - Session Search - - {#if $events_slct?.event_location_id} - - - View Selected Location - - {/if} - {#if $events_slct?.event_session_id} - - - View Selected Session - - {/if} + role="presentation" + class="fixed inset-0 z-50 flex items-center justify-center bg-gray-900/60 p-4" + onclick={close_cfg} + transition:fade={{ duration: 200 }}> + + +
-
+{/if}