mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-10 05:12:14 +00:00
Hidden Easter-eggs leaked their trigger semantics through the JSON response: a curious user with DevTools open could read metric names (nightOwlCount, leapDayCount, etc.), i18n keys (hiddenNightOwl, hiddenLeapDay, etc.), icon names, and target values without unlocking anything. The opaque-card UI was already correct, but the wire shape spoiled the surprise. Project hidden+locked entries to a sentinel shape before serialising (achievements.hiddenCard.title key, HelpCircle icon, target 0, metric totalTakenIntakes), and drop hidden-only metric counters from the metrics block unless the matching achievement is unlocked. The iOS branch reuses the same redacted view so native clients can't short-circuit the surprise via the resolved-strings shape. Once an Easter-egg unlocks the real fields ship — the unlock IS the reveal moment. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>