This commit is contained in:
Timothy Jaeryang Baek committed 2026-12-03 01:53:04 +04:00
1 parent a1311cd03e
commit f8a5bc3c2e
1 file changed
+8 -2
+8 -2
View File
@@ -7,7 +7,7 @@
} from '$lib/utils/settings-search';
import { browser } from '$app/environment';
import { beforeNavigate } from '$app/navigation';
import { getContext, tick } from 'svelte';
import { getContext, onMount, tick } from 'svelte';
import type { Writable } from 'svelte/store';
import { toast } from 'svelte-sonner';
import { config, mobile, settings, sidebarWidth, user, visibleControls } from '$lib/stores';
@@ -37,6 +37,12 @@
// Called with the open tab whenever it changes, so the page address can follow it.
export let onTabChange: (tab: string) => void = () => {};
let modalShow = false;
// The layout mounts this on first open, already open; showing the dialog only once mounted
// lets its opening animation play then too.
let mounted = false;
onMount(() => {
mounted = true;
});
let lastShow: boolean | string | SettingsModalRequest = false;
let tabState: Record<string, unknown> | null = null;
let personalUiSettings: Record<string, any> = {};
@@ -651,7 +657,7 @@
containerClassName="p-0 [scrollbar-gutter:auto]!"
className="h-[100dvh] flex flex-col md:flex-row bg-base-0 dark:bg-base-900 border-0! overflow-hidden"
ariaLabel={$i18n.t('Settings')}
bind:show={modalShow}
show={modalShow && mounted}
onRequestClose={close}
>
<nav