February 25th, 2026
Modal Refinements & Server-Side Validation Today’s focus was on heavily refining theEventDetailModal for production stability, fixing map interactions, and building the foundation for secure, server-authoritative evidence validation.
Production UI Cleanup & Modal Stability
- Singleton Guard: Rewrote
EventDetailModalas a self-contained singleton (zero props) with a module-level guard to definitively prevent the Expo Router double-mount bug. - Direct State Reads: We now read
selectedEventIdandselectedEventdirectly from Zustand, eliminating the need for an extra ConvexuseQuerysubscription and optimizing performance. - Documentation & Cleanup: Added comprehensive JSDoc detailing the data flow, singleton guard rationale, and usage rules. Cleaned up
useCalendarStorewith grouped types and updated comments in(main)/_layout.tsx. - Deprecation: Officially deprecated and deleted
EventDetailModal2(the experimental prototype) and its associated experimental components (EventDetailConditions2,EventDetailLocation2).
UI Features & Map Scroll Fix
- Verification Statuses: Added
applied,waived,percentage, andneutralstates toVerificationStatusCircle. - Circle Styling: Unified all circles to a consistent styling (
border-white/40,bg-white/5), increased the circle size tow-12/h-12, and increased the icon size to 24. Used a cursor-pointer icon for the neutral state and a percent icon for percentage. - Map Interaction Fix: Fixed a severe UI conflict where the map inside the
ScrollViewabsorbed touch events improperly. We dynamically togglescrollEnabledviaonTouchStart/onTouchEndcallbacks so the native map regains full pan/pinch control. - Waiver UI: Updated waiver subtitles with relevant penalty context.
Backend: Server-Authoritative Validators
- Condition States: Added a
ConditionStatusunion type in the backend (types/domain/commitment.ts) mirroring the frontend UI states. - Condition Interface: Extended the
Conditioninterface with optionalid,status, andverifiedAtfields for tracking specific instances. - Validator Registry: Created a pure-function validator registry at
core/verification/evidenceValidators.tsto cleanly handle verification logic securely on the server. - Core Validators:
- Implemented a
verifyTimevalidator to strictly enforce server-side clock window enforcement. - Implemented a
verifyLocationvalidator to enforce exact haversine bounds checking and GPS accuracy. - Added validator stubs for
Device,Photo, andBiometricverification types.
- Implemented a