Fix badge loading race conditions and standardize Svelte 5 param resolution
- Resolved 'untrack is not defined' ReferenceError in Badge Detail page. - Transitioned Badge, IDAA Archive, and Journal Entry pages to use page.params for robust reactivity. - Implemented fallback semantic ID lookup for Badges to handle mixed ID formats in URLs. - Added proper loading states to detail views to prevent 'No IDB record' flashes during hydration. - Systematically audited and cleaned up duplicate 'untrack' imports across all Svelte files.
This commit is contained in:
@@ -46,6 +46,7 @@
|
||||
import Archive_content_obj_id_edit from './ae_idaa_comp__archive_content_obj_id_edit.svelte';
|
||||
import Modal_media_player from './ae_idaa_comp__modal_media_player.svelte';
|
||||
import Help_tech from '$lib/app_components/e_app_help_tech.svelte';
|
||||
import { page } from '$app/state';
|
||||
|
||||
// let ae_promises: key_val = {};
|
||||
// let ae_tmp: key_val = {};
|
||||
@@ -58,7 +59,8 @@
|
||||
}
|
||||
|
||||
// For some reason data.params.archive_id (or whatever param) is not being passed to this page when loaded by a link from another page. This seems to be a bug with Svelte or SvelteKit. Hopefully fixed in a future version 5? 2024-11-06
|
||||
$idaa_slct.archive_id = ae_acct.slct.archive_id;
|
||||
// SVELTE 5 FIX: Use page.params directly for robust reactivity
|
||||
$idaa_slct.archive_id = page.params.archive_id;
|
||||
// $idaa_slct.archive_obj = ae_acct.slct.archive_obj;
|
||||
|
||||
// *** Functions and Logic
|
||||
|
||||
Reference in New Issue
Block a user