From 328aa2be9482f77cb1cf86c5d227fdcee9981b16 Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Wed, 6 Aug 2025 15:15:52 -0500 Subject: [APP-1356] Policy update dialog (#8782) * Add blocking announcement dialog feature * WIP custom dialog * Rework dialog and add native FocusScope * Lock scroll on web, fix backdrop * Add web FocusScope * Create custom Outlet for these announcements * Clean up FocusScope native impl * Comments * Some styling fixes * Handle screen reader specifically * Clean up state, remove Portal edits * Reorg, rename * Add syncing, tests * Revert dialog updates * Revert formatting * Delete unused file * Format * Add FullWindowOverlay * remove mmkv storage in debug btn * Add debug code * fix taps passing through on iOS * Reorg * Reorg, rename everything * Complete policy update after signup * Add logger * Move context around, unmount portals on native * Move a11y prop into FocusScope * Remove useMemo * Update dates * Move debug to dev settings * Unmount web portals until policy update completed * UPdate dates --------- Co-authored-by: Samuel Newman --- src/storage/index.ts | 7 +++++++ src/storage/schema.ts | 8 ++++++++ 2 files changed, 15 insertions(+) (limited to 'src/storage') diff --git a/src/storage/index.ts b/src/storage/index.ts index 4d45134e1..4c4200510 100644 --- a/src/storage/index.ts +++ b/src/storage/index.ts @@ -66,6 +66,13 @@ export class Storage { keys.forEach(key => this.remove([...scopes, key])) } + /** + * For debugging purposes + */ + removeAll() { + this.store.clearAll() + } + /** * Fires a callback when the storage associated with a given key changes * diff --git a/src/storage/schema.ts b/src/storage/schema.ts index c05a7531d..421264ac1 100644 --- a/src/storage/schema.ts +++ b/src/storage/schema.ts @@ -1,3 +1,5 @@ +import {type ID as PolicyUpdate202508} from '#/components/PolicyUpdateOverlay/updates/202508/config' + /** * Device data that's specific to the device and does not vary based account */ @@ -13,6 +15,12 @@ export type Device = { devMode: boolean demoMode: boolean activitySubscriptionsNudged?: boolean + + /** + * Policy update overlays. New IDs are required for each new announcement. + */ + policyUpdateDebugOverride?: boolean + [PolicyUpdate202508]?: boolean } export type Account = { -- cgit 1.4.1