fix: resolve TS errors and Svelte 5 state_referenced_locally warnings

- e_app_sign_in_out: type user_id/person_id as string|null (TS errors)
- archives/[archive_id]/+page.svelte: move if(browser) block to onMount
- ae_idaa_comp__archive_obj_id_edit: wrap timezone loader in onMount
- ae_idaa_comp__archive_content_obj_id_edit: wrap timezone loader in onMount
- bb/[post_id]/+page.svelte: move if(browser) block to onMount
- TODO: add completed entries, note remaining recovery_meetings warnings
This commit is contained in:
Scott Idem
2026-03-09 19:40:36 -04:00
parent 9b7832ee55
commit 206faf0c71
6 changed files with 99 additions and 93 deletions

View File

@@ -43,7 +43,7 @@
let url_user_email = $state(untrack(() => data?.url?.searchParams?.get('user_email')));
$effect(() => {
// NOTE: Sync URL params to state.
// NOTE: Sync URL params to state.
// We use untrack to prevent infinite loops if navigation triggers within this effect.
// WARNING: Ensure this doesn't clobber user-entered data during background URL updates.
untrack(() => {
@@ -57,9 +57,9 @@
let ae_promises: key_val = {};
let trigger: null | boolean = $state(null); // Use $state to ensure reactivity
let user_id = $state(null); // Use $state to ensure reactivity
let user_id: string | null = $state(null); // Use $state to ensure reactivity
let user_obj: key_val = $state({}); // Use $state to ensure reactivity
let person_id = $state(null); // Use $state to ensure reactivity
let person_id: string | null = $state(null); // Use $state to ensure reactivity
let person_obj: key_val = $state({}); // Use $state to ensure reactivity
$effect(() => {