@mentra/engine 3.2.1-dev.274 → 3.2.1-dev.277

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"settings.js","sourceRoot":"","sources":["../../src/stores/settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,WAAW,EAAC,MAAM,uBAAuB,CAAA;AACjD,OAAO,EAAC,WAAW,EAAC,MAAM,OAAO,CAAA;AACjC,OAAO,EAAc,MAAM,IAAI,GAAG,EAAS,MAAM,aAAa,CAAA;AAC9D,OAAO,EAAC,MAAM,EAAC,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAC,qBAAqB,EAAC,MAAM,oBAAoB,CAAA;AAExD,OAAO,EAAC,OAAO,EAAC,MAAM,kBAAkB,CAAA;AACxC,OAAO,EAAC,gCAAgC,EAAC,MAAM,wBAAwB,CAAA;AACvE,OAAO,EAAC,eAAe,EAAC,MAAM,WAAW,CAAA;AAEzC,OAAO,EAAC,wBAAwB,EAAE,gCAAgC,EAAC,MAAM,wBAAwB,CAAA;AAyCjG,MAAM,CAAC,MAAM,QAAQ,GAA4B;IAC/C,mCAAmC;IACnC,QAAQ,EAAE,EAAC,GAAG,EAAE,UAAU,EAAE,YAAY,EAAE,GAAG,EAAE,CAAC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAC,EAAE,aAAa;IAC1H,UAAU,EAAE,EAAC,GAAG,EAAE,YAAY,EAAE,YAAY,EAAE,GAAG,EAAE,CAAC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAC;IAC/G,qCAAqC,EAAE;QACrC,GAAG,EAAE,uCAAuC;QAC5C,0EAA0E;QAC1E,2EAA2E;QAC3E,YAAY,EAAE,GAAG,EAAE,CAAC,IAAI;QACxB,QAAQ,EAAE,IAAI;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O,iBAAiB,CAAA;IAC1B,CAAC;IACD,uBAAuB,EAAE,GAAG,EAAE;QAC5B,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;YACf,QAAQ,EAAE,kBAAkB,EAAE;YAC9B,aAAa,EAAE,IAAI;SACpB,CAAC,CAAC,CAAA;IACL,CAAC;CACF,CAAC,CAAC,CACJ,CAAA;AAED,MAAM,CAAC,MAAM,UAAU,GAAG,CAAU,GAAW,EAA+C,EAAE;IAC9F,MAAM,KAAK,GAAG,gBAAgB,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAA;IAChE,MAAM,UAAU,GAAG,gBAAgB,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,CAAA;IAChE,MAAM,QAAQ,GAAG,WAAW,CAAC,CAAC,QAAW,EAAE,EAAE,CAAC,UAAU,CAAC,GAAG,EAAE,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC,CAAA;IAC3F,OAAO,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAA;AAC1B,CAAC,CAAA","sourcesContent":["import {getTimeZone} from \"react-native-localize\"\nimport {useCallback} from \"react\"\nimport {AsyncResult, result as Res, Result} from \"typesafe-ts\"\nimport {create} from \"zustand\"\nimport {subscribeWithSelector} from \"zustand/middleware\"\n\nimport {storage} from \"../utils/storage\"\nimport {getBluetoothSettingKeysForDevice} from \"./bluetoothSettingKeys\"\nimport {useGlassesStore} from \"./glasses\"\n\nexport {MENTRA_LIVE_SETTING_KEYS, getBluetoothSettingKeysForDevice} from \"./bluetoothSettingKeys\"\n\nexport interface Setting {\n key: string\n defaultValue: () => any\n writable: boolean\n saveOnServer: boolean\n // change the key to a different key based on the indexer\n // NEVER do any network calls in the indexer (or performance will suffer greatly\n indexer?: (key: string) => string\n // optionally override the value of the setting when it's accessed\n override?: () => any\n // onWrite?: () => void\n persist: boolean\n // Pairing-identity keys are NATIVE-authoritative: the native layer writes\n // them on pairing success (handleDeviceReady) / forget and echoes them down\n // via save_setting; JS鈫抧ative they travel only in the explicit SEEDS\n // (hydration, pre-connect, post-demotion, abandon re-seed) — never the\n // change-push and never the on-connect replay, whose mid-relay snapshot can\n // overwrite a just-promoted identity. PAIRING_IDENTITY_KEYS is derived from\n // this flag so the sync exclusions can't drift from the descriptors.\n nativeAuthoritative?: true\n /**\n * Clear this setting when the build's environment changes.\n *\n * A persisted override normally outranks both the build's env and the\n * compiled default, which is right within one environment: a developer's\n * METRO_AUTO pin should survive a rebuild. It is wrong across environments,\n * where an override pinned under a dev build would silently follow the\n * install onto a store build pointed at production.\n *\n * Note this keys off the build's environment label, so it does NOT fire on a\n * TestFlight to App Store promotion: that ships the same binary with the same\n * label. Promotion is safe because the publishing lane bakes prod URLs, not\n * because this reset runs. See the resolution block in loadSettings.\n *\n * Absent means the value is never invalidated automatically.\n */\n resetOnBuildEnvChange?: true\n}\n\nexport const SETTINGS: Record<string, Setting> = {\n // feature flags / mantle settings:\n dev_mode: {key: \"dev_mode\", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true}, // deprecated\n debug_mode: {key: \"debug_mode\", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true},\n android_notification_listener_enabled: {\n key: \"android_notification_listener_enabled\",\n // Operational kill switch. The listener now runs in a guarded lightweight\n // process, so normal installs can safely capture notifications by default.\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n super_mode: {key: \"super_mode\", defaultValue: () => false, writable: true, saveOnServer: true, persist: true},\n appearance_menu_enabled: {\n key: \"appearance_menu_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n app_boot_extra_info: {\n key: \"app_boot_extra_info\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n miniapp_dev_mode: {\n key: \"miniapp_dev_mode\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enable_squircles: {\n key: \"enable_squircles\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n android_blur: {\n key: \"android_blur\",\n defaultValue: () => {\n return false\n },\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n android_inner_shadow: {\n key: \"android_inner_shadow\",\n defaultValue: () => {\n return false\n },\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n ios_glass_effect: {\n key: \"ios_glass_effect\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n ios_app_switcher_bottom_swipe: {\n key: \"ios_app_switcher_bottom_swipe\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_console: {\n key: \"debug_console\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_navigation_history: {\n key: \"debug_navigation_history\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_core_status_bar: {\n key: \"debug_core_status_bar\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Mentra Nex feature flags (off by default; toggled from Nex Developer Settings).\n // When on, the Nex display skips ASCII-only text sanitization so CJK/Chinese\n // captions render on glasses. Synced to the Bluetooth SDK via BLUETOOTH_SETTING_KEYS.\n nex_chinese_captions: {\n key: \"nex_chinese_captions\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // When on, LC3 audio received from Nex glasses is played back (Android only).\n // Local-only dev toggle: defaults off and never synced to the cloud account\n // (saveOnServer: false); persists locally so it survives app restarts.\n // Key renamed from the legacy `nex_audio_playback` so stale server/local\n // values (saved back when this was saveOnServer:true) can't re-enable it.\n nex_lc3_audio_playback: {\n key: \"nex_lc3_audio_playback\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // Select firmware-owned presentation instead of the Mentra card. Notify still\n // controls whether presentation is running on either phone platform.\n native_notifications_enabled: {\n key: \"native_notifications_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_auto_display: {\n key: \"native_notifications_auto_display\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_duration: {\n key: \"native_notifications_duration\",\n defaultValue: () => 5,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_do_not_disturb: {\n key: \"native_notifications_do_not_disturb\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n china_deployment: {\n key: \"china_deployment\",\n defaultValue: () => (process.env.EXPO_PUBLIC_DEPLOYMENT_REGION === \"china\" ? true : false),\n override: () => (process.env.EXPO_PUBLIC_DEPLOYMENT_REGION === \"china\" ? true : false),\n writable: false,\n saveOnServer: false,\n persist: true,\n },\n // Cloud V2 endpoint OVERRIDES. Empty = no override; cloudClient's resolveUrl\n // owns the full precedence (override -> env -> Metro-derived dev default).\n // The value may be an explicit URL or the METRO_AUTO sentinel (\"my dev\n // laptop\", resolved live from Metro so it survives network changes). Never\n // bake an env var or a personal LAN IP into the default here: that makes the\n // override branch always-truthy and strands devs on a stale address.\n cloud_core_url: {\n key: \"cloud_core_url\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n cloud_runtime_url: {\n key: \"cloud_runtime_url\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n cloud_url_deployment: {\n key: \"cloud_url_deployment\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n // Bookmarked Cloud V2 endpoint pairs. Each entry is {label, coreUrl,\n // runtimeUrl} — core + runtime are saved together because they are always\n // applied as a matched set (presets fill both; Save & Test verifies both).\n saved_cloud_url_pairs: {\n key: \"saved_cloud_url_pairs\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // Developer override for the ASG OTA manifest URL. null/empty = no override;\n // the normal selection applies (legacy-glasses gate, EXPO_PUBLIC_ASG_OTA_VERSION_URL,\n // glasses-reported URL, then production). See resolveOtaManifestUrl.\n ota_version_url: {\n key: \"ota_version_url\",\n defaultValue: () => null,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n saved_ota_version_urls: {\n key: \"saved_ota_version_urls\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n reconnect_on_app_foreground: {\n key: \"reconnect_on_app_foreground\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n location_tier: {key: \"location_tier\", defaultValue: () => \"\", writable: true, saveOnServer: true, persist: true},\n // Volatile bearer synced to Bluetooth for glasses-side Cloud V2 calls. The\n // key name is kept for BLE compatibility, but the value must never be loaded\n // from or saved to the legacy Cloud V1 settings store.\n core_token: {key: \"core_token\", defaultValue: () => \"\", writable: true, saveOnServer: false, persist: false},\n auth_email: {key: \"auth_email\", defaultValue: () => \"\", writable: true, saveOnServer: false, persist: true},\n // Pairing identity is per-phone, not per-account: two phones on one account\n // can be paired to different glasses, so none of these keys may sync to the\n // server (saveOnServer: false — a stale server copy resurrecting a local\n // pairing identity is exactly the desync this group's flags prevent).\n //\n // Two-phase identity: pending_wearable is the model the user last STARTED\n // pairing (written at selection, rendered as a finish-pairing card);\n // default_wearable + device_name + device_address are only promoted by the\n // native layer when pairing actually succeeds (handleDeviceReady).\n // pending_wearable persists so an abandoned selection still shows its\n // finish-pairing card after an app restart.\n pending_wearable: {\n key: \"pending_wearable\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n default_wearable: {\n key: \"default_wearable\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n device_name: {\n key: \"device_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n device_address: {\n key: \"device_address\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n project_name: {\n key: \"project_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n default_controller: {\n key: \"default_controller\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n pending_controller: {\n key: \"pending_controller\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n controller_device_name: {\n key: \"controller_device_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n controller_address: {\n key: \"controller_address\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n // ui state:\n home_background: {\n key: \"home_background\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n theme_preference: {\n key: \"theme_preference\",\n defaultValue: () => \"light\",\n // Force light mode - i mode is not complete yet\n // override: () => \"light\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enable_phone_notifications: {\n key: \"enable_phone_notifications\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n settings_access_count: {\n key: \"settings_access_count\",\n defaultValue: () => 0,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n show_advanced_settings: {\n key: \"show_advanced_settings\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n onboarding_completed: {\n key: \"onboarding_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n onboarding_live_completed: {\n key: \"onboarding_live_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n onboarding_os_completed: {\n key: \"onboarding_os_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n has_ever_activated_app: {\n key: \"has_ever_activated_app\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n\n // Bluetooth SDK settings:\n sensing_enabled: {\n key: \"sensing_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n power_saving_mode: {\n key: \"power_saving_mode\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // The Mentra App intentionally preserves Mentra Live's historical VAD-on\n // product default. Standalone public Bluetooth SDK hosts default VAD off so\n // their microphone audio remains continuous.\n voice_activity_detection_enabled: {\n key: \"voice_activity_detection_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Mentra Live center-mic loudness / \"Barrier\" gate (cs_swit type 10). Opt-in.\n loudness_gate_enabled: {\n key: \"loudness_gate_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n always_on_status_bar: {\n key: \"always_on_status_bar\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Legacy cloud/mobile setting name. Locally it maps to glasses-side Voice Activity Detection.\n bypass_vad_for_debugging: {\n key: \"bypass_vad_for_debugging\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n bypass_audio_encoding_for_debugging: {\n key: \"bypass_audio_encoding_for_debugging\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n metric_system: {\n key: \"metric_system\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n twelve_hour_time: {\n key: \"twelve_hour_time\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enforce_local_transcription: {\n key: \"enforce_local_transcription\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // LC3 audio quality setting (frame size in bytes)\n // 20 = 16kbps (low bandwidth), 40 = 32kbps (balanced), 60 = 48kbps (high quality)\n lc3_frame_size: {\n key: \"lc3_frame_size\",\n defaultValue: () => 60,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n preferred_mic: {\n key: \"preferred_mic\",\n defaultValue: () => \"auto\",\n writable: true,\n indexer: (key: string) => {\n const glasses = useSettingsStore.getState().getSetting(SETTINGS.default_wearable.key)\n if (glasses) {\n return `${key}:${glasses}`\n }\n return key\n },\n saveOnServer: true,\n persist: true,\n },\n screen_disabled: {\n key: \"screen_disabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // glasses settings:\n contextual_dashboard: {\n key: \"contextual_dashboard\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n use_native_dashboard: {\n key: \"use_native_dashboard\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n head_up_angle: {key: \"head_up_angle\", defaultValue: () => 45, writable: true, saveOnServer: true, persist: true},\n brightness: {key: \"brightness\", defaultValue: () => 50, writable: true, saveOnServer: true, persist: true},\n auto_brightness: {\n key: \"auto_brightness\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n dashboard_height: {\n key: \"dashboard_height\",\n defaultValue: () => 4,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n dashboard_depth: {\n key: \"dashboard_depth\",\n defaultValue: () => 2,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n menu_apps: {\n key: \"menu_apps\",\n defaultValue: () => null,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n calendar_events: {\n key: \"calendar_events\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n // button settings\n // Legacy persisted/cloud key; hardware behavior is now controlled by gallery_mode plus capture settings.\n button_mode: {key: \"button_mode\", defaultValue: () => \"photo\", writable: true, saveOnServer: true, persist: true},\n button_photo_size: {\n key: \"button_photo_size\",\n defaultValue: () => \"max\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n button_video_settings: {\n key: \"button_video_settings\",\n defaultValue: () => ({width: 1920, height: 1080, fps: 30}),\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n button_max_recording_time: {\n key: \"button_max_recording_time\",\n defaultValue: () => 10,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n camera_fov: {\n key: \"camera_fov\",\n defaultValue: () => ({fov: 118, roi_position: 0}),\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n media_post_processing: {\n key: \"media_post_processing\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n\n // time zone settings\n time_zone: {\n key: \"time_zone\",\n defaultValue: () => \"\",\n writable: true,\n override: () => {\n const override = useSettingsStore.getState().getSetting(SETTINGS.time_zone_override.key)\n if (override) {\n return override\n }\n return getTimeZone()\n },\n saveOnServer: true,\n persist: true,\n },\n time_zone_override: {\n key: \"time_zone_override\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // offline applets\n offline_mode: {key: \"offline_mode\", defaultValue: () => false, writable: true, saveOnServer: true, persist: true},\n // Runtime flag: coordinator flips this on when cloud STT has failed and fallback is active.\n // Native GlassesStore watches it to gate PCM 鈫?Sherpa feeding. Not user-facing.\n local_stt_fallback_active: {\n key: \"local_stt_fallback_active\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n gallery_mode: {key: \"gallery_mode\", defaultValue: () => true, writable: true, saveOnServer: true, persist: true},\n gallery_sync_explained: {\n key: \"gallery_sync_explained\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n offline_camera_running: {\n key: \"offline_camera_running\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // offline translation\n offline_translation_running: {\n key: \"offline_translation_running\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n offline_translation_source: {\n key: \"offline_translation_source\",\n defaultValue: () => \"en\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n offline_translation_target: {\n key: \"offline_translation_target\",\n defaultValue: () => \"es\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // button action settings\n default_button_action_enabled: {\n key: \"default_button_action_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n default_button_action_app: {\n key: \"default_button_action_app\",\n defaultValue: () => \"com.mentra.camera\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // notifications\n notifications_blocklist: {\n key: \"notifications_blocklist\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Cached required version from server - used to enforce updates even when offline\n cached_required_version: {\n key: \"cached_required_version\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // OTA update dismissal - stores the version code user dismissed (not persisted so resets on app restart)\n dismissed_ota_version: {\n key: \"dismissed_ota_version\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n // Contact email for feedback (persisted for Apple private relay users)\n contact_email: {\n key: \"contact_email\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n} as const\n\nexport const OFFLINE_APPLETS: string[] = [\"com.mentra.livecaptions\", \"com.mentra.camera\"]\n\n// These settings are automatically synced to the Bluetooth SDK.\n// Keep this list hardware-facing; app/UI/cloud-only preferences should stay in JS/Crust.\nexport const BLUETOOTH_SETTING_KEYS: string[] = [\n // Bluetooth settings:\n SETTINGS.sensing_enabled.key,\n SETTINGS.power_saving_mode.key,\n SETTINGS.voice_activity_detection_enabled.key,\n SETTINGS.loudness_gate_enabled.key,\n SETTINGS.lc3_frame_size.key,\n SETTINGS.preferred_mic.key,\n SETTINGS.screen_disabled.key,\n SETTINGS.auth_email.key,\n SETTINGS.core_token.key,\n // glasses settings:\n SETTINGS.contextual_dashboard.key,\n SETTINGS.head_up_angle.key,\n SETTINGS.brightness.key,\n SETTINGS.auto_brightness.key,\n SETTINGS.dashboard_height.key,\n SETTINGS.dashboard_depth.key,\n SETTINGS.menu_apps.key,\n SETTINGS.calendar_events.key,\n SETTINGS.use_native_dashboard.key,\n SETTINGS.twelve_hour_time.key,\n SETTINGS.metric_system.key,\n // button:\n SETTINGS.button_photo_size.key,\n // Legacy MentraLive native code reads the object form when syncing video settings.\n SETTINGS.button_video_settings.key,\n SETTINGS.button_max_recording_time.key,\n SETTINGS.camera_fov.key,\n // device / pairing:\n SETTINGS.pending_wearable.key,\n SETTINGS.default_wearable.key,\n SETTINGS.device_name.key,\n SETTINGS.device_address.key,\n SETTINGS.project_name.key,\n SETTINGS.default_controller.key,\n SETTINGS.pending_controller.key,\n SETTINGS.controller_device_name.key,\n SETTINGS.controller_address.key,\n // offline applets:\n SETTINGS.offline_mode.key,\n // Runtime flag flipped by LocalSttFallbackCoordinator. Native reads it from\n // GlassesStore to gate PCM 鈫?Sherpa feeding in handlePcm and to keep the\n // mic on while local STT is the active engine.\n SETTINGS.local_stt_fallback_active.key,\n SETTINGS.gallery_mode.key,\n // Mentra Nex feature flags:\n SETTINGS.nex_chinese_captions.key,\n SETTINGS.nex_lc3_audio_playback.key,\n]\n\n// Pairing identity is NATIVE-authoritative: the native layer writes it on\n// pairing success (handleDeviceReady) / forget and echoes it down via\n// save_setting; JS persists those echoes. JS鈫抧ative, identity travels ONLY in\n// the explicit full seeds (device-store hydration, pre-connect push,\n// post-demotion re-push) — never in the change-push subscription. Relaying an\n// echoed identity change back up would make the sync bidirectional with loop\n// gain 1: two identity values in flight (e.g. a boot demotion crossing a\n// native promotion) then chase each other through push鈫抋pply鈫抏cho鈫抪ush\n// forever, flapping the UI.\n//\n// Derived from the `nativeAuthoritative` descriptor flag (not maintained as a\n// parallel list) so the change-push exclusion in GlassesSettingsSync can't\n// drift from the setting declarations.\nexport const PAIRING_IDENTITY_KEYS: string[] = Object.values(SETTINGS)\n .filter((setting) => setting.nativeAuthoritative)\n .map((setting) => setting.key)\n\n// const PER_GLASSES_SETTINGS_KEYS: string[] = [SETTINGS.preferred_mic.key]\n\nexport interface SettingsState {\n // Settings values\n settings: Record<string, any>\n // Loading states\n isInitialized: boolean\n // Actions\n setSetting: (key: string, value: any, updateServer?: boolean) => AsyncResult<void, Error>\n setManyLocally: (settings: Record<string, any>) => AsyncResult<void, Error>\n getSetting: (key: string) => any\n // loadSetting: (key: string) => AsyncResult<void, Error>\n loadAllSettings: () => AsyncResult<void, Error>\n // Utility methods\n getBluetoothSettings: () => Record<string, any>\n resetAllSettingsLocally: () => void\n}\n\nconst getDefaultSettings = () =>\n Object.keys(SETTINGS).reduce((acc, key) => {\n acc[key] = SETTINGS[key].defaultValue()\n return acc\n }, {} as Record<string, any>)\n\n// Single-flight for loadAllSettings: the host fires it at module load and\n// engine.start()'s device-store hydration awaits it — without the memo the\n// second caller runs a duplicate full disk load while the first is still in\n// flight. Cleared on failure so a later call can retry.\nlet loadAllSettingsInFlight: AsyncResult<void, Error> | null = null\n\nfunction printableSettingValue(key: string, value: unknown): string {\n return key.includes(\"token\") || key.includes(\"email\") ? \"<redacted>\" : JSON.stringify(value)\n}\n\nexport const useSettingsStore = create<SettingsState>()(\n subscribeWithSelector((set, get) => ({\n settings: getDefaultSettings(),\n isInitialized: false,\n loadingKeys: new Set(),\n setSetting: (key: string, value: any, _updateServer = true): AsyncResult<void, Error> => {\n return Res.try_async(async () => {\n const setting = SETTINGS[key]\n const originalKey = key\n\n if (!setting) {\n throw new Error(`SETTINGS: SET: ${originalKey} is not a valid setting!`)\n }\n\n if (setting.indexer) {\n key = setting.indexer(originalKey)\n }\n\n if (!setting.writable) {\n throw new Error(`SETTINGS: ${originalKey} is not writable!`)\n }\n\n // Update store immediately for optimistic UI\n console.log(`SETTINGS: SET: ${key} = ${printableSettingValue(key, value)}`)\n set((state) => ({\n settings: {...state.settings, [key]: value},\n }))\n\n if (setting.persist) {\n let res = await storage.save(key, value)\n if (res.is_error()) {\n throw new Error(`SETTINGS: couldn't save setting to storage: ${res.error}`)\n }\n\n // Cloud V1 per-change server sync removed with the V1 ripout (issue\n // #3392). Settings are local-first until a V2 sync lands; the\n // saveOnServer flags are retained as intent markers for that work.\n }\n })\n },\n getSetting: (key: string) => {\n const state = get()\n const originalKey = key\n const setting = SETTINGS[originalKey]\n\n if (!setting) {\n console.error(`SETTINGS: GET: ${originalKey} is not a valid setting!`)\n return undefined\n }\n\n if (setting.override) {\n let override = setting.override()\n if (override !== undefined) {\n return override\n }\n }\n\n if (setting.indexer) {\n key = setting.indexer(originalKey)\n }\n\n // console.log(`GET SETTING: ${key} = ${state.settings[key]}`)\n\n try {\n const raw = state.settings[key] ?? SETTINGS[originalKey].defaultValue()\n return raw\n } catch (e) {\n // for dynamically created settings, we need to create a new setting in SETTINGS:\n console.log(`Failed to get setting, creating new setting:(${key}):`, e)\n SETTINGS[key] = {key: key, defaultValue: () => undefined, writable: true, saveOnServer: false, persist: true}\n return SETTINGS[key].defaultValue()\n }\n },\n // batch update many settings from the server:\n setManyLocally: (settings: Record<string, any>): AsyncResult<void, Error> => {\n return Res.try_async(async () => {\n const settingsToLoad: Record<string, any> = {}\n // if a setting should not persist, don't load it:\n for (const [key, value] of Object.entries(settings)) {\n const stg: Setting | undefined = SETTINGS[key.toLowerCase()]\n if (!stg) {\n continue\n }\n if (!stg.persist) {\n continue\n }\n settingsToLoad[key.toLowerCase()] = value\n }\n // console.log(\"SETTINGS: SET MANY LOCALLY: \", settingsToLoad)\n\n // MMKV writes are synchronous Results, not rejecting Promises. Check\n // each result before publishing the new in-memory settings.\n for (const [key, value] of Object.entries(settingsToLoad)) {\n const saved = storage.save(key, value)\n if (saved.is_error()) throw saved.error\n }\n set((state) => ({settings: {...state.settings, ...settingsToLoad}}))\n })\n },\n // loads any preferences that have been changed from the default and saved to DISK!\n loadAllSettings: (): AsyncResult<void, Error> => {\n console.log(\"SETTINGS: loadAllSettings()\")\n if (loadAllSettingsInFlight) {\n return loadAllSettingsInFlight\n }\n const inFlight = Res.try_async(async () => {\n const state = get()\n let loadedSettings: Record<string, any> = {}\n\n if (state.isInitialized) {\n return undefined\n }\n\n for (const setting of Object.values(SETTINGS)) {\n // if the settings should not persist, don't load it:\n if (!setting.persist) {\n continue\n }\n\n // load all subkeys for an indexed setting:\n if (setting?.indexer) {\n console.log(`SETTINGS: LOAD: ${setting.key} with indexer!`)\n\n let res: Result<Record<string, unknown>, Error> = storage.loadSubKeys(setting.key)\n if (res.is_error()) {\n console.log(`SETTINGS: LOAD: ${setting.key}`, res.error)\n continue\n }\n\n let subKeys: Record<string, unknown> = res.value\n console.log(`SETTINGS: LOAD: ${setting.key} subkeys are set!`, subKeys)\n loadedSettings = {...loadedSettings, ...subKeys}\n continue\n }\n\n let res = storage.load<any>(setting.key)\n if (res.is_error()) {\n console.log(`SETTINGS: LOAD: ${setting.key} is not set!`, res.error)\n // this setting isn't set from the default, so we don't load anything\n continue\n }\n // normal key:value pair:\n let value = res.value\n // res.value IS the stored value; logging value.value printed\n // \"undefined\" for every loaded setting and disguised present\n // values as missing. Redact token- and email-bearing keys: console\n // logs are uploaded in bug-report artifacts (same keys\n // diagnosticContext's SENSITIVE_SETTINGS_KEYS strips, minus an\n // import that would cycle stores <-> utils).\n console.log(`SETTINGS: LOAD: ${setting.key} = ${printableSettingValue(setting.key, value)}`)\n loadedSettings[setting.key] = value\n }\n\n // console.log(\"##############################################\")\n // console.log(loadedSettings)\n // console.log(\"##############################################\")\n\n set((state) => ({\n isInitialized: true,\n settings: {...state.settings, ...loadedSettings},\n }))\n\n // This hidden debug switch originally shipped default-off while the\n // notification-listener cold-start ANR was being investigated. Now\n // that the listener runs in its own guarded process, migrate existing\n // installs to the new default once; later explicit debug changes still\n // persist normally.\n // Reset the cloud backend override when the build's environment changes.\n //\n // cloud_core_url / cloud_runtime_url are persist:true and outrank both\n // the build's env and the compiled default (see resolveUrl in\n // cloudClient.ts). That is what we want inside one environment: a\n // developer's METRO_AUTO pin should survive a rebuild. It is wrong\n // across environments.\n //\n // The concrete case is an install that moves BETWEEN environments: an\n // internal tester running a dev build with a pinned override who then\n // installs the store build. The override outranks that build's prod\n // URLs, so without this they keep talking to dev with nothing\n // surfacing it.\n //\n // Note what this deliberately does NOT do, because the distinction is\n // easy to get backwards. TestFlight and the App Store receive the SAME\n // binary, so promotion does not change EXPO_PUBLIC_BUILD_ENV and this\n // reset never fires on it. Promotion is safe for a different reason:\n // the publishing lane bakes the selected release cloud environment, and\n // production promotes the already-tested binary. The same holds for\n // Android beta-track to production.\n //\n // The residual gap is therefore an override pinned while already on a\n // prod-labelled build, which no label comparison can see. That is a\n // deliberate limit: reaching it means typing a URL into a dev-only\n // screen, VersionInfo renders the current value, and the same screen\n // clears it.\n //\n // Comparing the baked EXPO_PUBLIC_BUILD_ENV against the last one seen\n // on this device covers those environment switches and fresh installs\n // without touching the setting write path. A reinstall needs no\n // handling: it drops the marker and the override together\n // (android:allowBackup=\"false\", and iOS deletes the container).\n const BUILD_ENV_KEY = \"settings.lastBuildEnv\"\n const buildEnv = (process.env.EXPO_PUBLIC_BUILD_ENV ?? \"dev\").trim() || \"dev\"\n const lastBuildEnv = storage.load<string>(BUILD_ENV_KEY)\n const previousBuildEnv = lastBuildEnv.is_error() ? undefined : lastBuildEnv.value\n if (previousBuildEnv !== buildEnv) {\n // Clear when there is no marker yet, not just on a recorded change.\n // The first build carrying this code meets every existing install\n // with previousBuildEnv === undefined, and those are exactly the\n // installs that may hold an override set before the pin existed --\n // the population this is here to repair. Treating \"no marker\" as a\n // fresh install would record the marker and never look again. A\n // genuinely fresh install has nothing persisted, so the clear below\n // writes each default over itself and costs nothing.\n //\n // Driven by the descriptors rather than a hardcoded key list, so a\n // setting that needs this behaviour declares it in one place and\n // cannot be missed here.\n const scoped = Object.values(SETTINGS).filter((setting) => setting.resetOnBuildEnvChange)\n console.log(\n `SETTINGS: build env ${previousBuildEnv ?? \"(none recorded)\"} -> ${buildEnv}, ` +\n `clearing ${scoped.length} build-scoped setting(s)`,\n )\n let allCleared = true\n for (const setting of scoped) {\n const cleared = await get().setSetting(setting.key, setting.defaultValue(), false)\n if (cleared.is_error()) {\n allCleared = false\n console.log(`SETTINGS: could not clear ${setting.key}:`, cleared.error)\n }\n }\n // Advance the marker only once the reset actually landed. Recording\n // it after a failed write would retire the retry and leave the stale\n // override for the life of the install; leaving it unset costs one\n // repeated attempt per launch until a write succeeds.\n if (allCleared) {\n storage.save(BUILD_ENV_KEY, buildEnv)\n }\n }\n\n // Reset existing installs once; later user/app opt-ins remain available.\n const LOUDNESS_GATE_MIGRATION_KEY = \"migration:loudness_gate_default_off_v1\"\n const loudnessGateMigrationDone = storage.load<boolean>(LOUDNESS_GATE_MIGRATION_KEY)\n if (loudnessGateMigrationDone.is_error() || !loudnessGateMigrationDone.value) {\n // updateServer: true, matching the android_blur / camera_fov migrations. The flag is\n // inert until the Cloud V2 settings sync lands, but this setting is saveOnServer, so\n // the intent recorded here is the one that should carry over.\n const result = await get().setSetting(SETTINGS.loudness_gate_enabled.key, false, true)\n if (result.is_error()) {\n console.log(\"SETTINGS: loudness gate migration failed:\", result.error)\n } else {\n storage.save(LOUDNESS_GATE_MIGRATION_KEY, true)\n }\n }\n\n const NOTIFICATION_LISTENER_MIGRATION_KEY = \"migration:android_notification_listener_default_on_v1\"\n const notificationListenerMigrationDone = storage.load<boolean>(NOTIFICATION_LISTENER_MIGRATION_KEY)\n if (notificationListenerMigrationDone.is_error() || !notificationListenerMigrationDone.value) {\n const result = await get().setSetting(SETTINGS.android_notification_listener_enabled.key, true, false)\n if (result.is_error()) {\n console.log(\"SETTINGS: notification listener migration failed:\", result.error)\n } else {\n storage.save(NOTIFICATION_LISTENER_MIGRATION_KEY, true)\n }\n }\n\n // One-time migration: force android_blur=false for existing users.\n // The setting's default is already false; this migration covers users\n // who explicitly opted into Android blur effects before we discovered\n // they're a major source of frame drops on cheap Android phones.\n // The dimezisBlurViewSdk31Plus blur each costs ~5-10ms/frame; with\n // multiple blurs on home (top fade + AppSwitcherButton x2) a low-end\n // device misses the 16ms budget consistently. Users can turn it back\n // on under Settings 鈫?Appearance once we've optimized further.\n //\n // The setSetting call also pushes to the server (saveOnServer: true)\n // so the server-stored value flips too — otherwise the next sync\n // from the user's server-stored prefs would re-enable blur.\n // Best-effort: a server failure (offline, 5xx) shouldn't block boot;\n // we still mark the migration done locally so we don't loop.\n const MIGRATION_KEY = \"migration:android_blur_default_false_v1\"\n const migrationDone = storage.load<boolean>(MIGRATION_KEY)\n if (migrationDone.is_error() || !migrationDone.value) {\n const current = get().getSetting(SETTINGS.android_blur.key)\n if (current === true) {\n const result = await get().setSetting(SETTINGS.android_blur.key, false, true)\n if (result.is_error()) {\n // Server push failed (offline / 5xx). Local storage was still\n // updated, so the user immediately gets the new behavior. The\n // server-side stale `true` will be overwritten the next time\n // the user opens Appearance settings and the auto-sync runs.\n console.log(\"SETTINGS: android_blur migration server-push failed:\", result.error)\n }\n }\n // Mark done unconditionally — even on server-push failure we don't\n // want to retry the migration on every boot. The local value is\n // already correct.\n storage.save(MIGRATION_KEY, true)\n }\n\n // The old camera default cropped the sensor to 102掳. Move existing\n // default-shaped values to the full 118掳 sensor once; named miniapp\n // requests for the 102掳 \"standard\" preset remain available.\n const CAMERA_FOV_MIGRATION_KEY = \"migration:camera_fov_full_sensor_v1\"\n const cameraFovMigrationDone = storage.load<boolean>(CAMERA_FOV_MIGRATION_KEY)\n if (cameraFovMigrationDone.is_error() || !cameraFovMigrationDone.value) {\n const current = get().getSetting(SETTINGS.camera_fov.key) as {fov?: number; roi_position?: number} | undefined\n let migrationSucceeded = true\n if (current?.fov === 102 && (current.roi_position ?? 0) === 0) {\n const result = await get().setSetting(SETTINGS.camera_fov.key, {fov: 118, roi_position: 0}, true)\n if (result.is_error()) {\n console.log(\"SETTINGS: camera FOV migration failed:\", result.error)\n migrationSucceeded = false\n }\n }\n // Unlike the blur migration above, a failed camera set may leave the\n // local value unchanged. Only mark this migration complete once the\n // desired value was applied so a transient failure retries on boot.\n if (migrationSucceeded) storage.save(CAMERA_FOV_MIGRATION_KEY, true)\n }\n })\n loadAllSettingsInFlight = inFlight\n void Promise.resolve(inFlight).then((result) => {\n if (result.is_error()) {\n loadAllSettingsInFlight = null\n }\n })\n return inFlight\n },\n getBluetoothSettings: () => {\n const state = get()\n // Device-model-filtered key set (wire v2): Mentra Live (no display) gets\n // the reduced MENTRA_LIVE_SETTING_KEYS; display glasses get the full set.\n const deviceModel = useGlassesStore.getState().deviceModel || state.getSetting(SETTINGS.default_wearable.key)\n const keys = getBluetoothSettingKeysForDevice(deviceModel, BLUETOOTH_SETTING_KEYS)\n const bluetoothSettings: Record<string, any> = {}\n for (const key of keys) {\n const value = state.getSetting(key)\n if (key === SETTINGS.core_token.key && (typeof value !== \"string\" || value.trim().length === 0)) {\n continue\n }\n bluetoothSettings[key] = value\n }\n return bluetoothSettings\n },\n resetAllSettingsLocally: () => {\n set((_state) => ({\n settings: getDefaultSettings(),\n isInitialized: true,\n }))\n },\n })),\n)\n\nexport const useSetting = <T = any>(key: string): [T, (value: T) => AsyncResult<void, Error>] => {\n const value = useSettingsStore((state) => state.getSetting(key))\n const setSetting = useSettingsStore((state) => state.setSetting)\n const setValue = useCallback((newValue: T) => setSetting(key, newValue), [key, setSetting])\n return [value, setValue]\n}\n"]}
1
+ {"version":3,"file":"settings.js","sourceRoot":"","sources":["../../src/stores/settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,WAAW,EAAC,MAAM,uBAAuB,CAAA;AACjD,OAAO,EAAC,WAAW,EAAC,MAAM,OAAO,CAAA;AACjC,OAAO,EAAc,MAAM,IAAI,GAAG,EAAS,MAAM,aAAa,CAAA;AAC9D,OAAO,EAAC,MAAM,EAAC,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAC,qBAAqB,EAAC,MAAM,oBAAoB,CAAA;AAExD,OAAO,EAAC,OAAO,EAAC,MAAM,kBAAkB,CAAA;AACxC,OAAO,EAAC,gCAAgC,EAAC,MAAM,wBAAwB,CAAA;AACvE,OAAO,EAAC,eAAe,EAAC,MAAM,WAAW,CAAA;AAEzC,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C,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,CAAA;IAChE,MAAM,QAAQ,GAAG,WAAW,CAAC,CAAC,QAAW,EAAE,EAAE,CAAC,UAAU,CAAC,GAAG,EAAE,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC,CAAA;IAC3F,OAAO,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAA;AAC1B,CAAC,CAAA","sourcesContent":["import {getTimeZone} from \"react-native-localize\"\nimport {useCallback} from \"react\"\nimport {AsyncResult, result as Res, Result} from \"typesafe-ts\"\nimport {create} from \"zustand\"\nimport {subscribeWithSelector} from \"zustand/middleware\"\n\nimport {storage} from \"../utils/storage\"\nimport {getBluetoothSettingKeysForDevice} from \"./bluetoothSettingKeys\"\nimport {useGlassesStore} from \"./glasses\"\n\nexport {MENTRA_LIVE_SETTING_KEYS, getBluetoothSettingKeysForDevice} from \"./bluetoothSettingKeys\"\n\nexport interface Setting {\n key: string\n defaultValue: () => any\n writable: boolean\n saveOnServer: boolean\n // change the key to a different key based on the indexer\n // NEVER do any network calls in the indexer (or performance will suffer greatly\n indexer?: (key: string) => string\n // optionally override the value of the setting when it's accessed\n override?: () => any\n // onWrite?: () => void\n persist: boolean\n // Pairing-identity keys are NATIVE-authoritative: the native layer writes\n // them on pairing success (handleDeviceReady) / forget and echoes them down\n // via save_setting; JS鈫抧ative they travel only in the explicit SEEDS\n // (hydration, pre-connect, post-demotion, abandon re-seed) — never the\n // change-push and never the on-connect replay, whose mid-relay snapshot can\n // overwrite a just-promoted identity. PAIRING_IDENTITY_KEYS is derived from\n // this flag so the sync exclusions can't drift from the descriptors.\n nativeAuthoritative?: true\n /**\n * Clear this setting when the build's environment changes.\n *\n * A persisted override normally outranks both the build's env and the\n * compiled default, which is right within one environment: a developer's\n * METRO_AUTO pin should survive a rebuild. It is wrong across environments,\n * where an override pinned under a dev build would silently follow the\n * install onto a store build pointed at production.\n *\n * Note this keys off the build's environment label, so it does NOT fire on a\n * TestFlight to App Store promotion: that ships the same binary with the same\n * label. Promotion is safe because the publishing lane bakes prod URLs, not\n * because this reset runs. See the resolution block in loadSettings.\n *\n * Absent means the value is never invalidated automatically.\n */\n resetOnBuildEnvChange?: true\n}\n\nexport const SETTINGS: Record<string, Setting> = {\n // feature flags / mantle settings:\n dev_mode: {key: \"dev_mode\", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true}, // deprecated\n debug_mode: {key: \"debug_mode\", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true},\n show_mentra_call_ios: {\n key: \"show_mentra_call_ios\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n android_notification_listener_enabled: {\n key: \"android_notification_listener_enabled\",\n // Operational kill switch. The listener now runs in a guarded lightweight\n // process, so normal installs can safely capture notifications by default.\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n super_mode: {key: \"super_mode\", defaultValue: () => false, writable: true, saveOnServer: true, persist: true},\n appearance_menu_enabled: {\n key: \"appearance_menu_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n app_boot_extra_info: {\n key: \"app_boot_extra_info\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n miniapp_dev_mode: {\n key: \"miniapp_dev_mode\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enable_squircles: {\n key: \"enable_squircles\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n android_blur: {\n key: \"android_blur\",\n defaultValue: () => {\n return false\n },\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n android_inner_shadow: {\n key: \"android_inner_shadow\",\n defaultValue: () => {\n return false\n },\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n ios_glass_effect: {\n key: \"ios_glass_effect\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n ios_app_switcher_bottom_swipe: {\n key: \"ios_app_switcher_bottom_swipe\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_console: {\n key: \"debug_console\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_navigation_history: {\n key: \"debug_navigation_history\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n debug_core_status_bar: {\n key: \"debug_core_status_bar\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Mentra Nex feature flags (off by default; toggled from Nex Developer Settings).\n // When on, the Nex display skips ASCII-only text sanitization so CJK/Chinese\n // captions render on glasses. Synced to the Bluetooth SDK via BLUETOOTH_SETTING_KEYS.\n nex_chinese_captions: {\n key: \"nex_chinese_captions\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // When on, LC3 audio received from Nex glasses is played back (Android only).\n // Local-only dev toggle: defaults off and never synced to the cloud account\n // (saveOnServer: false); persists locally so it survives app restarts.\n // Key renamed from the legacy `nex_audio_playback` so stale server/local\n // values (saved back when this was saveOnServer:true) can't re-enable it.\n nex_lc3_audio_playback: {\n key: \"nex_lc3_audio_playback\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // Select firmware-owned presentation instead of the Mentra card. Notify still\n // controls whether presentation is running on either phone platform.\n native_notifications_enabled: {\n key: \"native_notifications_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_auto_display: {\n key: \"native_notifications_auto_display\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_duration: {\n key: \"native_notifications_duration\",\n defaultValue: () => 5,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n native_notifications_do_not_disturb: {\n key: \"native_notifications_do_not_disturb\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n china_deployment: {\n key: \"china_deployment\",\n defaultValue: () => (process.env.EXPO_PUBLIC_DEPLOYMENT_REGION === \"china\" ? true : false),\n override: () => (process.env.EXPO_PUBLIC_DEPLOYMENT_REGION === \"china\" ? true : false),\n writable: false,\n saveOnServer: false,\n persist: true,\n },\n // Cloud V2 endpoint OVERRIDES. Empty = no override; cloudClient's resolveUrl\n // owns the full precedence (override -> env -> Metro-derived dev default).\n // The value may be an explicit URL or the METRO_AUTO sentinel (\"my dev\n // laptop\", resolved live from Metro so it survives network changes). Never\n // bake an env var or a personal LAN IP into the default here: that makes the\n // override branch always-truthy and strands devs on a stale address.\n cloud_core_url: {\n key: \"cloud_core_url\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n cloud_runtime_url: {\n key: \"cloud_runtime_url\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n cloud_url_deployment: {\n key: \"cloud_url_deployment\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n resetOnBuildEnvChange: true,\n },\n // Bookmarked Cloud V2 endpoint pairs. Each entry is {label, coreUrl,\n // runtimeUrl} — core + runtime are saved together because they are always\n // applied as a matched set (presets fill both; Save & Test verifies both).\n saved_cloud_url_pairs: {\n key: \"saved_cloud_url_pairs\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // Developer override for the ASG OTA manifest URL. null/empty = no override;\n // the normal selection applies (legacy-glasses gate, EXPO_PUBLIC_ASG_OTA_VERSION_URL,\n // glasses-reported URL, then production). See resolveOtaManifestUrl.\n ota_version_url: {\n key: \"ota_version_url\",\n defaultValue: () => null,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n saved_ota_version_urls: {\n key: \"saved_ota_version_urls\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n reconnect_on_app_foreground: {\n key: \"reconnect_on_app_foreground\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n location_tier: {key: \"location_tier\", defaultValue: () => \"\", writable: true, saveOnServer: true, persist: true},\n // Volatile bearer synced to Bluetooth for glasses-side Cloud V2 calls. The\n // key name is kept for BLE compatibility, but the value must never be loaded\n // from or saved to the legacy Cloud V1 settings store.\n core_token: {key: \"core_token\", defaultValue: () => \"\", writable: true, saveOnServer: false, persist: false},\n auth_email: {key: \"auth_email\", defaultValue: () => \"\", writable: true, saveOnServer: false, persist: true},\n // Pairing identity is per-phone, not per-account: two phones on one account\n // can be paired to different glasses, so none of these keys may sync to the\n // server (saveOnServer: false — a stale server copy resurrecting a local\n // pairing identity is exactly the desync this group's flags prevent).\n //\n // Two-phase identity: pending_wearable is the model the user last STARTED\n // pairing (written at selection, rendered as a finish-pairing card);\n // default_wearable + device_name + device_address are only promoted by the\n // native layer when pairing actually succeeds (handleDeviceReady).\n // pending_wearable persists so an abandoned selection still shows its\n // finish-pairing card after an app restart.\n pending_wearable: {\n key: \"pending_wearable\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n default_wearable: {\n key: \"default_wearable\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n device_name: {\n key: \"device_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n device_address: {\n key: \"device_address\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n project_name: {\n key: \"project_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n default_controller: {\n key: \"default_controller\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n pending_controller: {\n key: \"pending_controller\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n controller_device_name: {\n key: \"controller_device_name\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n controller_address: {\n key: \"controller_address\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n nativeAuthoritative: true,\n },\n // ui state:\n home_background: {\n key: \"home_background\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n theme_preference: {\n key: \"theme_preference\",\n defaultValue: () => \"light\",\n // Force light mode - i mode is not complete yet\n // override: () => \"light\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enable_phone_notifications: {\n key: \"enable_phone_notifications\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n settings_access_count: {\n key: \"settings_access_count\",\n defaultValue: () => 0,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n show_advanced_settings: {\n key: \"show_advanced_settings\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n onboarding_completed: {\n key: \"onboarding_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n onboarding_live_completed: {\n key: \"onboarding_live_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n onboarding_os_completed: {\n key: \"onboarding_os_completed\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n has_ever_activated_app: {\n key: \"has_ever_activated_app\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n\n // Bluetooth SDK settings:\n sensing_enabled: {\n key: \"sensing_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n power_saving_mode: {\n key: \"power_saving_mode\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // The Mentra App intentionally preserves Mentra Live's historical VAD-on\n // product default. Standalone public Bluetooth SDK hosts default VAD off so\n // their microphone audio remains continuous.\n voice_activity_detection_enabled: {\n key: \"voice_activity_detection_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Mentra Live center-mic loudness / \"Barrier\" gate (cs_swit type 10). Opt-in.\n loudness_gate_enabled: {\n key: \"loudness_gate_enabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n always_on_status_bar: {\n key: \"always_on_status_bar\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Legacy cloud/mobile setting name. Locally it maps to glasses-side Voice Activity Detection.\n bypass_vad_for_debugging: {\n key: \"bypass_vad_for_debugging\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n bypass_audio_encoding_for_debugging: {\n key: \"bypass_audio_encoding_for_debugging\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n metric_system: {\n key: \"metric_system\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n twelve_hour_time: {\n key: \"twelve_hour_time\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n enforce_local_transcription: {\n key: \"enforce_local_transcription\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // LC3 audio quality setting (frame size in bytes)\n // 20 = 16kbps (low bandwidth), 40 = 32kbps (balanced), 60 = 48kbps (high quality)\n lc3_frame_size: {\n key: \"lc3_frame_size\",\n defaultValue: () => 60,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n preferred_mic: {\n key: \"preferred_mic\",\n defaultValue: () => \"auto\",\n writable: true,\n indexer: (key: string) => {\n const glasses = useSettingsStore.getState().getSetting(SETTINGS.default_wearable.key)\n if (glasses) {\n return `${key}:${glasses}`\n }\n return key\n },\n saveOnServer: true,\n persist: true,\n },\n screen_disabled: {\n key: \"screen_disabled\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // glasses settings:\n contextual_dashboard: {\n key: \"contextual_dashboard\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n use_native_dashboard: {\n key: \"use_native_dashboard\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n head_up_angle: {key: \"head_up_angle\", defaultValue: () => 45, writable: true, saveOnServer: true, persist: true},\n brightness: {key: \"brightness\", defaultValue: () => 50, writable: true, saveOnServer: true, persist: true},\n auto_brightness: {\n key: \"auto_brightness\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n dashboard_height: {\n key: \"dashboard_height\",\n defaultValue: () => 4,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n dashboard_depth: {\n key: \"dashboard_depth\",\n defaultValue: () => 2,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n menu_apps: {\n key: \"menu_apps\",\n defaultValue: () => null,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n calendar_events: {\n key: \"calendar_events\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n // button settings\n // Legacy persisted/cloud key; hardware behavior is now controlled by gallery_mode plus capture settings.\n button_mode: {key: \"button_mode\", defaultValue: () => \"photo\", writable: true, saveOnServer: true, persist: true},\n button_photo_size: {\n key: \"button_photo_size\",\n defaultValue: () => \"max\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n button_video_settings: {\n key: \"button_video_settings\",\n defaultValue: () => ({width: 1920, height: 1080, fps: 30}),\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n button_max_recording_time: {\n key: \"button_max_recording_time\",\n defaultValue: () => 10,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n camera_fov: {\n key: \"camera_fov\",\n defaultValue: () => ({fov: 118, roi_position: 0}),\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n media_post_processing: {\n key: \"media_post_processing\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n\n // time zone settings\n time_zone: {\n key: \"time_zone\",\n defaultValue: () => \"\",\n writable: true,\n override: () => {\n const override = useSettingsStore.getState().getSetting(SETTINGS.time_zone_override.key)\n if (override) {\n return override\n }\n return getTimeZone()\n },\n saveOnServer: true,\n persist: true,\n },\n time_zone_override: {\n key: \"time_zone_override\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // offline applets\n offline_mode: {key: \"offline_mode\", defaultValue: () => false, writable: true, saveOnServer: true, persist: true},\n // Runtime flag: coordinator flips this on when cloud STT has failed and fallback is active.\n // Native GlassesStore watches it to gate PCM 鈫?Sherpa feeding. Not user-facing.\n local_stt_fallback_active: {\n key: \"local_stt_fallback_active\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n gallery_mode: {key: \"gallery_mode\", defaultValue: () => true, writable: true, saveOnServer: true, persist: true},\n gallery_sync_explained: {\n key: \"gallery_sync_explained\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n offline_camera_running: {\n key: \"offline_camera_running\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // offline translation\n offline_translation_running: {\n key: \"offline_translation_running\",\n defaultValue: () => false,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n offline_translation_source: {\n key: \"offline_translation_source\",\n defaultValue: () => \"en\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n offline_translation_target: {\n key: \"offline_translation_target\",\n defaultValue: () => \"es\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // button action settings\n default_button_action_enabled: {\n key: \"default_button_action_enabled\",\n defaultValue: () => true,\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n default_button_action_app: {\n key: \"default_button_action_app\",\n defaultValue: () => \"com.mentra.camera\",\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // notifications\n notifications_blocklist: {\n key: \"notifications_blocklist\",\n defaultValue: () => [],\n writable: true,\n saveOnServer: true,\n persist: true,\n },\n // Cached required version from server - used to enforce updates even when offline\n cached_required_version: {\n key: \"cached_required_version\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n // OTA update dismissal - stores the version code user dismissed (not persisted so resets on app restart)\n dismissed_ota_version: {\n key: \"dismissed_ota_version\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: false,\n },\n // Contact email for feedback (persisted for Apple private relay users)\n contact_email: {\n key: \"contact_email\",\n defaultValue: () => \"\",\n writable: true,\n saveOnServer: false,\n persist: true,\n },\n} as const\n\nexport const OFFLINE_APPLETS: string[] = [\"com.mentra.livecaptions\", \"com.mentra.camera\"]\n\n// These settings are automatically synced to the Bluetooth SDK.\n// Keep this list hardware-facing; app/UI/cloud-only preferences should stay in JS/Crust.\nexport const BLUETOOTH_SETTING_KEYS: string[] = [\n // Bluetooth settings:\n SETTINGS.sensing_enabled.key,\n SETTINGS.power_saving_mode.key,\n SETTINGS.voice_activity_detection_enabled.key,\n SETTINGS.loudness_gate_enabled.key,\n SETTINGS.lc3_frame_size.key,\n SETTINGS.preferred_mic.key,\n SETTINGS.screen_disabled.key,\n SETTINGS.auth_email.key,\n SETTINGS.core_token.key,\n // glasses settings:\n SETTINGS.contextual_dashboard.key,\n SETTINGS.head_up_angle.key,\n SETTINGS.brightness.key,\n SETTINGS.auto_brightness.key,\n SETTINGS.dashboard_height.key,\n SETTINGS.dashboard_depth.key,\n SETTINGS.menu_apps.key,\n SETTINGS.calendar_events.key,\n SETTINGS.use_native_dashboard.key,\n SETTINGS.twelve_hour_time.key,\n SETTINGS.metric_system.key,\n // button:\n SETTINGS.button_photo_size.key,\n // Legacy MentraLive native code reads the object form when syncing video settings.\n SETTINGS.button_video_settings.key,\n SETTINGS.button_max_recording_time.key,\n SETTINGS.camera_fov.key,\n // device / pairing:\n SETTINGS.pending_wearable.key,\n SETTINGS.default_wearable.key,\n SETTINGS.device_name.key,\n SETTINGS.device_address.key,\n SETTINGS.project_name.key,\n SETTINGS.default_controller.key,\n SETTINGS.pending_controller.key,\n SETTINGS.controller_device_name.key,\n SETTINGS.controller_address.key,\n // offline applets:\n SETTINGS.offline_mode.key,\n // Runtime flag flipped by LocalSttFallbackCoordinator. Native reads it from\n // GlassesStore to gate PCM 鈫?Sherpa feeding in handlePcm and to keep the\n // mic on while local STT is the active engine.\n SETTINGS.local_stt_fallback_active.key,\n SETTINGS.gallery_mode.key,\n // Mentra Nex feature flags:\n SETTINGS.nex_chinese_captions.key,\n SETTINGS.nex_lc3_audio_playback.key,\n]\n\n// Pairing identity is NATIVE-authoritative: the native layer writes it on\n// pairing success (handleDeviceReady) / forget and echoes it down via\n// save_setting; JS persists those echoes. JS鈫抧ative, identity travels ONLY in\n// the explicit full seeds (device-store hydration, pre-connect push,\n// post-demotion re-push) — never in the change-push subscription. Relaying an\n// echoed identity change back up would make the sync bidirectional with loop\n// gain 1: two identity values in flight (e.g. a boot demotion crossing a\n// native promotion) then chase each other through push鈫抋pply鈫抏cho鈫抪ush\n// forever, flapping the UI.\n//\n// Derived from the `nativeAuthoritative` descriptor flag (not maintained as a\n// parallel list) so the change-push exclusion in GlassesSettingsSync can't\n// drift from the setting declarations.\nexport const PAIRING_IDENTITY_KEYS: string[] = Object.values(SETTINGS)\n .filter((setting) => setting.nativeAuthoritative)\n .map((setting) => setting.key)\n\n// const PER_GLASSES_SETTINGS_KEYS: string[] = [SETTINGS.preferred_mic.key]\n\nexport interface SettingsState {\n // Settings values\n settings: Record<string, any>\n // Loading states\n isInitialized: boolean\n // Actions\n setSetting: (key: string, value: any, updateServer?: boolean) => AsyncResult<void, Error>\n setManyLocally: (settings: Record<string, any>) => AsyncResult<void, Error>\n getSetting: (key: string) => any\n // loadSetting: (key: string) => AsyncResult<void, Error>\n loadAllSettings: () => AsyncResult<void, Error>\n // Utility methods\n getBluetoothSettings: () => Record<string, any>\n resetAllSettingsLocally: () => void\n}\n\nconst getDefaultSettings = () =>\n Object.keys(SETTINGS).reduce((acc, key) => {\n acc[key] = SETTINGS[key].defaultValue()\n return acc\n }, {} as Record<string, any>)\n\n// Single-flight for loadAllSettings: the host fires it at module load and\n// engine.start()'s device-store hydration awaits it — without the memo the\n// second caller runs a duplicate full disk load while the first is still in\n// flight. Cleared on failure so a later call can retry.\nlet loadAllSettingsInFlight: AsyncResult<void, Error> | null = null\n\nfunction printableSettingValue(key: string, value: unknown): string {\n return key.includes(\"token\") || key.includes(\"email\") ? \"<redacted>\" : JSON.stringify(value)\n}\n\nexport const useSettingsStore = create<SettingsState>()(\n subscribeWithSelector((set, get) => ({\n settings: getDefaultSettings(),\n isInitialized: false,\n loadingKeys: new Set(),\n setSetting: (key: string, value: any, _updateServer = true): AsyncResult<void, Error> => {\n return Res.try_async(async () => {\n const setting = SETTINGS[key]\n const originalKey = key\n\n if (!setting) {\n throw new Error(`SETTINGS: SET: ${originalKey} is not a valid setting!`)\n }\n\n if (setting.indexer) {\n key = setting.indexer(originalKey)\n }\n\n if (!setting.writable) {\n throw new Error(`SETTINGS: ${originalKey} is not writable!`)\n }\n\n // Update store immediately for optimistic UI\n console.log(`SETTINGS: SET: ${key} = ${printableSettingValue(key, value)}`)\n set((state) => ({\n settings: {...state.settings, [key]: value},\n }))\n\n if (setting.persist) {\n let res = await storage.save(key, value)\n if (res.is_error()) {\n throw new Error(`SETTINGS: couldn't save setting to storage: ${res.error}`)\n }\n\n // Cloud V1 per-change server sync removed with the V1 ripout (issue\n // #3392). Settings are local-first until a V2 sync lands; the\n // saveOnServer flags are retained as intent markers for that work.\n }\n })\n },\n getSetting: (key: string) => {\n const state = get()\n const originalKey = key\n const setting = SETTINGS[originalKey]\n\n if (!setting) {\n console.error(`SETTINGS: GET: ${originalKey} is not a valid setting!`)\n return undefined\n }\n\n if (setting.override) {\n let override = setting.override()\n if (override !== undefined) {\n return override\n }\n }\n\n if (setting.indexer) {\n key = setting.indexer(originalKey)\n }\n\n // console.log(`GET SETTING: ${key} = ${state.settings[key]}`)\n\n try {\n const raw = state.settings[key] ?? SETTINGS[originalKey].defaultValue()\n return raw\n } catch (e) {\n // for dynamically created settings, we need to create a new setting in SETTINGS:\n console.log(`Failed to get setting, creating new setting:(${key}):`, e)\n SETTINGS[key] = {key: key, defaultValue: () => undefined, writable: true, saveOnServer: false, persist: true}\n return SETTINGS[key].defaultValue()\n }\n },\n // batch update many settings from the server:\n setManyLocally: (settings: Record<string, any>): AsyncResult<void, Error> => {\n return Res.try_async(async () => {\n const settingsToLoad: Record<string, any> = {}\n // if a setting should not persist, don't load it:\n for (const [key, value] of Object.entries(settings)) {\n const stg: Setting | undefined = SETTINGS[key.toLowerCase()]\n if (!stg) {\n continue\n }\n if (!stg.persist) {\n continue\n }\n settingsToLoad[key.toLowerCase()] = value\n }\n // console.log(\"SETTINGS: SET MANY LOCALLY: \", settingsToLoad)\n\n // MMKV writes are synchronous Results, not rejecting Promises. Check\n // each result before publishing the new in-memory settings.\n for (const [key, value] of Object.entries(settingsToLoad)) {\n const saved = storage.save(key, value)\n if (saved.is_error()) throw saved.error\n }\n set((state) => ({settings: {...state.settings, ...settingsToLoad}}))\n })\n },\n // loads any preferences that have been changed from the default and saved to DISK!\n loadAllSettings: (): AsyncResult<void, Error> => {\n console.log(\"SETTINGS: loadAllSettings()\")\n if (loadAllSettingsInFlight) {\n return loadAllSettingsInFlight\n }\n const inFlight = Res.try_async(async () => {\n const state = get()\n let loadedSettings: Record<string, any> = {}\n\n if (state.isInitialized) {\n return undefined\n }\n\n for (const setting of Object.values(SETTINGS)) {\n // if the settings should not persist, don't load it:\n if (!setting.persist) {\n continue\n }\n\n // load all subkeys for an indexed setting:\n if (setting?.indexer) {\n console.log(`SETTINGS: LOAD: ${setting.key} with indexer!`)\n\n let res: Result<Record<string, unknown>, Error> = storage.loadSubKeys(setting.key)\n if (res.is_error()) {\n console.log(`SETTINGS: LOAD: ${setting.key}`, res.error)\n continue\n }\n\n let subKeys: Record<string, unknown> = res.value\n console.log(`SETTINGS: LOAD: ${setting.key} subkeys are set!`, subKeys)\n loadedSettings = {...loadedSettings, ...subKeys}\n continue\n }\n\n let res = storage.load<any>(setting.key)\n if (res.is_error()) {\n console.log(`SETTINGS: LOAD: ${setting.key} is not set!`, res.error)\n // this setting isn't set from the default, so we don't load anything\n continue\n }\n // normal key:value pair:\n let value = res.value\n // res.value IS the stored value; logging value.value printed\n // \"undefined\" for every loaded setting and disguised present\n // values as missing. Redact token- and email-bearing keys: console\n // logs are uploaded in bug-report artifacts (same keys\n // diagnosticContext's SENSITIVE_SETTINGS_KEYS strips, minus an\n // import that would cycle stores <-> utils).\n console.log(`SETTINGS: LOAD: ${setting.key} = ${printableSettingValue(setting.key, value)}`)\n loadedSettings[setting.key] = value\n }\n\n // console.log(\"##############################################\")\n // console.log(loadedSettings)\n // console.log(\"##############################################\")\n\n set((state) => ({\n isInitialized: true,\n settings: {...state.settings, ...loadedSettings},\n }))\n\n // This hidden debug switch originally shipped default-off while the\n // notification-listener cold-start ANR was being investigated. Now\n // that the listener runs in its own guarded process, migrate existing\n // installs to the new default once; later explicit debug changes still\n // persist normally.\n // Reset the cloud backend override when the build's environment changes.\n //\n // cloud_core_url / cloud_runtime_url are persist:true and outrank both\n // the build's env and the compiled default (see resolveUrl in\n // cloudClient.ts). That is what we want inside one environment: a\n // developer's METRO_AUTO pin should survive a rebuild. It is wrong\n // across environments.\n //\n // The concrete case is an install that moves BETWEEN environments: an\n // internal tester running a dev build with a pinned override who then\n // installs the store build. The override outranks that build's prod\n // URLs, so without this they keep talking to dev with nothing\n // surfacing it.\n //\n // Note what this deliberately does NOT do, because the distinction is\n // easy to get backwards. TestFlight and the App Store receive the SAME\n // binary, so promotion does not change EXPO_PUBLIC_BUILD_ENV and this\n // reset never fires on it. Promotion is safe for a different reason:\n // the publishing lane bakes the selected release cloud environment, and\n // production promotes the already-tested binary. The same holds for\n // Android beta-track to production.\n //\n // The residual gap is therefore an override pinned while already on a\n // prod-labelled build, which no label comparison can see. That is a\n // deliberate limit: reaching it means typing a URL into a dev-only\n // screen, VersionInfo renders the current value, and the same screen\n // clears it.\n //\n // Comparing the baked EXPO_PUBLIC_BUILD_ENV against the last one seen\n // on this device covers those environment switches and fresh installs\n // without touching the setting write path. A reinstall needs no\n // handling: it drops the marker and the override together\n // (android:allowBackup=\"false\", and iOS deletes the container).\n const BUILD_ENV_KEY = \"settings.lastBuildEnv\"\n const buildEnv = (process.env.EXPO_PUBLIC_BUILD_ENV ?? \"dev\").trim() || \"dev\"\n const lastBuildEnv = storage.load<string>(BUILD_ENV_KEY)\n const previousBuildEnv = lastBuildEnv.is_error() ? undefined : lastBuildEnv.value\n if (previousBuildEnv !== buildEnv) {\n // Clear when there is no marker yet, not just on a recorded change.\n // The first build carrying this code meets every existing install\n // with previousBuildEnv === undefined, and those are exactly the\n // installs that may hold an override set before the pin existed --\n // the population this is here to repair. Treating \"no marker\" as a\n // fresh install would record the marker and never look again. A\n // genuinely fresh install has nothing persisted, so the clear below\n // writes each default over itself and costs nothing.\n //\n // Driven by the descriptors rather than a hardcoded key list, so a\n // setting that needs this behaviour declares it in one place and\n // cannot be missed here.\n const scoped = Object.values(SETTINGS).filter((setting) => setting.resetOnBuildEnvChange)\n console.log(\n `SETTINGS: build env ${previousBuildEnv ?? \"(none recorded)\"} -> ${buildEnv}, ` +\n `clearing ${scoped.length} build-scoped setting(s)`,\n )\n let allCleared = true\n for (const setting of scoped) {\n const cleared = await get().setSetting(setting.key, setting.defaultValue(), false)\n if (cleared.is_error()) {\n allCleared = false\n console.log(`SETTINGS: could not clear ${setting.key}:`, cleared.error)\n }\n }\n // Advance the marker only once the reset actually landed. Recording\n // it after a failed write would retire the retry and leave the stale\n // override for the life of the install; leaving it unset costs one\n // repeated attempt per launch until a write succeeds.\n if (allCleared) {\n storage.save(BUILD_ENV_KEY, buildEnv)\n }\n }\n\n // Reset existing installs once; later user/app opt-ins remain available.\n const LOUDNESS_GATE_MIGRATION_KEY = \"migration:loudness_gate_default_off_v1\"\n const loudnessGateMigrationDone = storage.load<boolean>(LOUDNESS_GATE_MIGRATION_KEY)\n if (loudnessGateMigrationDone.is_error() || !loudnessGateMigrationDone.value) {\n // updateServer: true, matching the android_blur / camera_fov migrations. The flag is\n // inert until the Cloud V2 settings sync lands, but this setting is saveOnServer, so\n // the intent recorded here is the one that should carry over.\n const result = await get().setSetting(SETTINGS.loudness_gate_enabled.key, false, true)\n if (result.is_error()) {\n console.log(\"SETTINGS: loudness gate migration failed:\", result.error)\n } else {\n storage.save(LOUDNESS_GATE_MIGRATION_KEY, true)\n }\n }\n\n const NOTIFICATION_LISTENER_MIGRATION_KEY = \"migration:android_notification_listener_default_on_v1\"\n const notificationListenerMigrationDone = storage.load<boolean>(NOTIFICATION_LISTENER_MIGRATION_KEY)\n if (notificationListenerMigrationDone.is_error() || !notificationListenerMigrationDone.value) {\n const result = await get().setSetting(SETTINGS.android_notification_listener_enabled.key, true, false)\n if (result.is_error()) {\n console.log(\"SETTINGS: notification listener migration failed:\", result.error)\n } else {\n storage.save(NOTIFICATION_LISTENER_MIGRATION_KEY, true)\n }\n }\n\n // One-time migration: force android_blur=false for existing users.\n // The setting's default is already false; this migration covers users\n // who explicitly opted into Android blur effects before we discovered\n // they're a major source of frame drops on cheap Android phones.\n // The dimezisBlurViewSdk31Plus blur each costs ~5-10ms/frame; with\n // multiple blurs on home (top fade + AppSwitcherButton x2) a low-end\n // device misses the 16ms budget consistently. Users can turn it back\n // on under Settings 鈫?Appearance once we've optimized further.\n //\n // The setSetting call also pushes to the server (saveOnServer: true)\n // so the server-stored value flips too — otherwise the next sync\n // from the user's server-stored prefs would re-enable blur.\n // Best-effort: a server failure (offline, 5xx) shouldn't block boot;\n // we still mark the migration done locally so we don't loop.\n const MIGRATION_KEY = \"migration:android_blur_default_false_v1\"\n const migrationDone = storage.load<boolean>(MIGRATION_KEY)\n if (migrationDone.is_error() || !migrationDone.value) {\n const current = get().getSetting(SETTINGS.android_blur.key)\n if (current === true) {\n const result = await get().setSetting(SETTINGS.android_blur.key, false, true)\n if (result.is_error()) {\n // Server push failed (offline / 5xx). Local storage was still\n // updated, so the user immediately gets the new behavior. The\n // server-side stale `true` will be overwritten the next time\n // the user opens Appearance settings and the auto-sync runs.\n console.log(\"SETTINGS: android_blur migration server-push failed:\", result.error)\n }\n }\n // Mark done unconditionally — even on server-push failure we don't\n // want to retry the migration on every boot. The local value is\n // already correct.\n storage.save(MIGRATION_KEY, true)\n }\n\n // The old camera default cropped the sensor to 102掳. Move existing\n // default-shaped values to the full 118掳 sensor once; named miniapp\n // requests for the 102掳 \"standard\" preset remain available.\n const CAMERA_FOV_MIGRATION_KEY = \"migration:camera_fov_full_sensor_v1\"\n const cameraFovMigrationDone = storage.load<boolean>(CAMERA_FOV_MIGRATION_KEY)\n if (cameraFovMigrationDone.is_error() || !cameraFovMigrationDone.value) {\n const current = get().getSetting(SETTINGS.camera_fov.key) as {fov?: number; roi_position?: number} | undefined\n let migrationSucceeded = true\n if (current?.fov === 102 && (current.roi_position ?? 0) === 0) {\n const result = await get().setSetting(SETTINGS.camera_fov.key, {fov: 118, roi_position: 0}, true)\n if (result.is_error()) {\n console.log(\"SETTINGS: camera FOV migration failed:\", result.error)\n migrationSucceeded = false\n }\n }\n // Unlike the blur migration above, a failed camera set may leave the\n // local value unchanged. Only mark this migration complete once the\n // desired value was applied so a transient failure retries on boot.\n if (migrationSucceeded) storage.save(CAMERA_FOV_MIGRATION_KEY, true)\n }\n })\n loadAllSettingsInFlight = inFlight\n void Promise.resolve(inFlight).then((result) => {\n if (result.is_error()) {\n loadAllSettingsInFlight = null\n }\n })\n return inFlight\n },\n getBluetoothSettings: () => {\n const state = get()\n // Device-model-filtered key set (wire v2): Mentra Live (no display) gets\n // the reduced MENTRA_LIVE_SETTING_KEYS; display glasses get the full set.\n const deviceModel = useGlassesStore.getState().deviceModel || state.getSetting(SETTINGS.default_wearable.key)\n const keys = getBluetoothSettingKeysForDevice(deviceModel, BLUETOOTH_SETTING_KEYS)\n const bluetoothSettings: Record<string, any> = {}\n for (const key of keys) {\n const value = state.getSetting(key)\n if (key === SETTINGS.core_token.key && (typeof value !== \"string\" || value.trim().length === 0)) {\n continue\n }\n bluetoothSettings[key] = value\n }\n return bluetoothSettings\n },\n resetAllSettingsLocally: () => {\n set((_state) => ({\n settings: getDefaultSettings(),\n isInitialized: true,\n }))\n },\n })),\n)\n\nexport const useSetting = <T = any>(key: string): [T, (value: T) => AsyncResult<void, Error>] => {\n const value = useSettingsStore((state) => state.getSetting(key))\n const setSetting = useSettingsStore((state) => state.setSetting)\n const setValue = useCallback((newValue: T) => setSetting(key, newValue), [key, setSetting])\n return [value, setValue]\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mentra/engine",
3
- "version": "3.2.1-dev.274",
3
+ "version": "3.2.1-dev.277",
4
4
  "description": "Mentra Engine — miniapp registry, WebView bridge, and miniapp store",
5
5
  "main": "build/index.js",
6
6
  "react-native": "src/index.ts",
@@ -97,13 +97,13 @@
97
97
  "registry": "https://registry.npmjs.org/"
98
98
  },
99
99
  "dependencies": {
100
- "@mentra/acs-meeting": "3.2.1-dev.274",
101
- "@mentra/glasses-media": "3.2.1-dev.274",
102
- "@mentra/bluetooth-sdk": "3.2.1-dev.274",
103
- "@mentra/cloud-client": "3.2.1-dev.274",
104
- "@mentra/cloud-protocol": "3.2.1-dev.274",
105
- "@mentra/crust": "3.2.1-dev.274",
106
- "@mentra/miniapp": "3.2.1-dev.274",
100
+ "@mentra/acs-meeting": "3.2.1-dev.277",
101
+ "@mentra/glasses-media": "3.2.1-dev.277",
102
+ "@mentra/bluetooth-sdk": "3.2.1-dev.277",
103
+ "@mentra/cloud-client": "3.2.1-dev.277",
104
+ "@mentra/cloud-protocol": "3.2.1-dev.277",
105
+ "@mentra/crust": "3.2.1-dev.277",
106
+ "@mentra/miniapp": "3.2.1-dev.277",
107
107
  "buffer": "^6.0.3",
108
108
  "events": "^3.3.0",
109
109
  "react-native-marked": "8.1.1",
@@ -12,9 +12,9 @@ export interface EngineReleaseMetadata {
12
12
  export const ENGINE_RELEASE_METADATA: Readonly<EngineReleaseMetadata> = Object.freeze({
13
13
  "schemaVersion": 1,
14
14
  "familyBaseVersion": "3.2.1",
15
- "releaseIdentity": "3.2.1-dev.274",
16
- "releaseSetId": "mentra-3.2.1-dev.274",
17
- "sourceCommit": "fbc4e9c568fd067ce99a485fe385244240136232",
18
- "otaManifestUrl": "https://github.com/Mentra-Community/MentraOS/releases/download/mentra-builds-v3.2.1/mentra-live-ota-3.2.1-dev.274.json",
19
- "otaManifestSha256": "78f6de80c6904879ea5f011c076ee99189de70e7309a515d877fddd25b789004"
15
+ "releaseIdentity": "3.2.1-dev.277",
16
+ "releaseSetId": "mentra-3.2.1-dev.277",
17
+ "sourceCommit": "2668275c49728812fea5356f6df3e78e73f1ed87",
18
+ "otaManifestUrl": "https://artifactscdn.mentraglass.com/Mentra-Community/MentraOS/releases/mentra-builds-v3.2.1/mentra-live-ota-3.2.1-dev.277.json",
19
+ "otaManifestSha256": "527d30a6400d5accdbf83e2c4316ec6e30e2b7ef1d70b6fd54e7abcec1bcc183"
20
20
  })
@@ -68,6 +68,7 @@ export interface MeetingCapability {
68
68
  export interface MeetingCapabilities {
69
69
  /** Whether this participant may end the Teams group call for everyone. Presenters only. */
70
70
  hangUpForEveryone: MeetingCapability
71
+ manageLobby?: MeetingCapability
71
72
  }
72
73
 
73
74
  export function parseMeetingCapabilities(raw: unknown): MeetingCapabilities | undefined {
@@ -75,7 +76,13 @@ export function parseMeetingCapabilities(raw: unknown): MeetingCapabilities | un
75
76
  const value = (raw as Record<string, unknown>).hangUpForEveryone
76
77
  if (!value || typeof value !== "object") return undefined
77
78
  const capability = value as Record<string, unknown>
79
+ const rawLobby = (raw as Record<string, unknown>).manageLobby
80
+ const lobby = rawLobby && typeof rawLobby === "object" ? rawLobby as Record<string, unknown> : undefined
78
81
  return {
82
+ ...(lobby ? {manageLobby: {
83
+ allowed: typeof lobby.allowed === "boolean" ? lobby.allowed : null,
84
+ reason: typeof lobby.reason === "string" && lobby.reason ? lobby.reason : null,
85
+ }} : {}),
79
86
  hangUpForEveryone: {
80
87
  allowed: typeof capability.allowed === "boolean" ? capability.allowed : null,
81
88
  reason: typeof capability.reason === "string" && capability.reason ? capability.reason : null,
@@ -377,6 +384,7 @@ type NativeModule = {
377
384
  * denied or ACS refuses — and has still left the call. Absent on natives that predate End.
378
385
  */
379
386
  endForEveryone?(): Promise<MeetingState>
387
+ admitParticipant?(participantId: string): Promise<void>
380
388
  setMuted(muted: boolean): Promise<MeetingState>
381
389
  setAudioSource(source: "glasses" | "phone"): Promise<MeetingState>
382
390
  updateVideoSource(whepUrl: string): Promise<void>
@@ -1188,6 +1196,17 @@ class AcsMeetingService {
1188
1196
  }
1189
1197
  }
1190
1198
 
1199
+ /** Admit one guest without changing call ownership or audio state. */
1200
+ async admitParticipant(packageName: string, participantId: string): Promise<void> {
1201
+ if (this.owner !== packageName) throw new Error("This miniapp does not own the active meeting")
1202
+ if (!participantId.trim()) throw new Error("A participant ID is required")
1203
+ const native = getNative()
1204
+ if (!native?.admitParticipant) throw new Error("This Mentra App build does not support admitting guests")
1205
+ const generation = this.callGeneration
1206
+ await native.admitParticipant(participantId)
1207
+ if (generation !== this.callGeneration) throw new Error("The meeting changed during admission")
1208
+ }
1209
+
1191
1210
  /**
1192
1211
  * End the Teams group call for everyone.
1193
1212
  *
@@ -1391,6 +1391,9 @@ class LocalMiniappRuntime {
1391
1391
  case MiniappRequestType.MEETING_LEAVE:
1392
1392
  void this.handleMeetingLeave(packageName, requestId)
1393
1393
  break
1394
+ case MiniappRequestType.MEETING_ADMIT:
1395
+ void this.handleMeetingAdmit(packageName, payload, requestId)
1396
+ break
1394
1397
  case MiniappRequestType.MEETING_END:
1395
1398
  void this.handleMeetingEnd(packageName, requestId)
1396
1399
  break
@@ -4860,6 +4863,19 @@ class LocalMiniappRuntime {
4860
4863
  }
4861
4864
  }
4862
4865
 
4866
+ private async handleMeetingAdmit(packageName: string, payload: Record<string, unknown>, requestId?: string): Promise<void> {
4867
+ try {
4868
+ if (typeof payload.participantId !== "string") throw new Error("A participant ID is required")
4869
+ await acsMeetingService.admitParticipant(packageName, payload.participantId)
4870
+ this.sendResult(packageName, requestId, true)
4871
+ } catch (error) {
4872
+ this.sendResult(packageName, requestId, false, undefined, {
4873
+ code: MiniappErrorCode.INTERNAL,
4874
+ message: error instanceof Error ? error.message : "Could not admit this guest",
4875
+ })
4876
+ }
4877
+ }
4878
+
4863
4879
  private async handleMeetingSetMuted(
4864
4880
  packageName: string,
4865
4881
  payload: Record<string, unknown>,
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @fileoverview Sequences a SoftAP call. Sequencing only — no sockets, no peers, no BLE.
3
3
  *
4
- * The glasses open a hotspot, the phone joins it without giving up its cellular route, and the
4
+ * The glasses open a hotspot, the host joins it while retaining cellular or Ethernet internet, and the
5
5
  * glasses publish WebRTC straight to a listener on the phone. Cloudflare is not involved at all.
6
6
  *
7
7
  * The order below is the whole point of this file, and one step in it is load-bearing:
@@ -770,7 +770,7 @@ export class SoftapCallTransport {
770
770
  const hotspot = this.requireHotspot()
771
771
  let bindAddress: string | undefined
772
772
  await this.step(generation, "scopedJoin", "SCOPED_JOIN_FAILED", async (report) => {
773
- report(`Phone joining ${hotspot.ssid}. Turn Wi-Fi on if a panel opens Teams stays on cellular.`)
773
+ report(`Joining ${hotspot.ssid}. Keep Wi-Fi on for the glasses and a separate internet connection for Teams.`)
774
774
  bindAddress = await this.deps.joinScopedNetwork(hotspot.ssid, hotspot.passphrase, report)
775
775
  softapTrace("scoped_network_joined", {bindAddress: bindAddress ?? "unknown"})
776
776
  if (bindAddress) report(`Phone is ${bindAddress} on ${hotspot.ssid}`)
@@ -1321,7 +1321,7 @@ export function createSoftapCallDeps(args: {
1321
1321
  // Android promoted in its place. Waiting for it to validate is what stopped the ACS join
1322
1322
  // from burning its whole timeout on DNS that could not resolve yet.
1323
1323
  if (subsystems.awaitValidatedDefaultNetwork) {
1324
- report?.("Waiting for this phone's mobile data to take over so Teams can connect")
1324
+ report?.("Waiting for an internet route outside the glasses hotspot so Teams can connect")
1325
1325
  try {
1326
1326
  const network = await subsystems.awaitValidatedDefaultNetwork()
1327
1327
  if (network) {
@@ -1340,7 +1340,7 @@ export function createSoftapCallDeps(args: {
1340
1340
  })
1341
1341
  }
1342
1342
  }
1343
- report?.("Binding the video receiver and joining Teams over cellular")
1343
+ report?.("Binding the video receiver and joining Teams")
1344
1344
  await subsystems.joinMeeting(packageName, {
1345
1345
  meetingUrl: args.meetingUrl,
1346
1346
  token: args.token,
@@ -53,6 +53,13 @@ export const SETTINGS: Record<string, Setting> = {
53
53
  // feature flags / mantle settings:
54
54
  dev_mode: {key: "dev_mode", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true}, // deprecated
55
55
  debug_mode: {key: "debug_mode", defaultValue: () => __DEV__, writable: true, saveOnServer: true, persist: true},
56
+ show_mentra_call_ios: {
57
+ key: "show_mentra_call_ios",
58
+ defaultValue: () => false,
59
+ writable: true,
60
+ saveOnServer: false,
61
+ persist: true,
62
+ },
56
63
  android_notification_listener_enabled: {
57
64
  key: "android_notification_listener_enabled",
58
65
  // Operational kill switch. The listener now runs in a guarded lightweight