feat(frontend): implement string-only ID standardization and native data cleaning

Update layout.ts to clean raw data from the native bridge. Initialize events_slct.event_device_id in launcher layout. Resort device_id prioritization in launcher_background_sync.svelte.
This commit is contained in:
Scott Idem
2026-01-30 12:38:13 -05:00
parent 7a8871c51f
commit 5a2eaa8fac
4 changed files with 18 additions and 2 deletions

View File

@@ -160,6 +160,11 @@ export async function load({ fetch, params, parent, route, url }) {
// Inject native device metadata into the location state with SAFE MERGE
if (native_device_config.native_device) {
const incoming_dev = native_device_config.native_device;
// String-Only ID Vision: Ensure semantic fields use the random string ID
if (incoming_dev.event_device_id_random) incoming_dev.event_device_id = incoming_dev.event_device_id_random;
if (incoming_dev.event_id_random) incoming_dev.event_id = incoming_dev.event_id_random;
if (incoming_dev.id_random) incoming_dev.id = incoming_dev.id_random;
// 1. Recover existing user overrides from localStorage
let existing_dev = {};