generated from nhcarrigan/template
fix: persist UI preferences across navigation and sessions #48
Reference in New Issue
Block a user
Delete Branch "fix/sticky"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
localStorage("elysium_batch_size"). The chosen batch size is restored automatically on the next visit, with a graceful fallback to1for missing or unrecognisable values.sessionStorage("elysium_boss_zone"/"elysium_quest_zone"). The selected zone survives navigation within a session and resets cleanly when the session ends, defaulting to Verdant Vale if no stored value exists.Test plan
✨ This PR was created with help from Hikari~ 🌸
The previous key `${reward.type}-${amount ?? ""}` collapsed to "adventurer-" for every adventurer-unlock reward (which carries no amount), producing duplicate-key React warnings on every render tick. Because console.error is forwarded to the backend telemetry service, this caused continuous email alerts. The key now uses targetId (present on adventurer and upgrade rewards) first, falls back to amount (present on gold/essence/crystal rewards), and uses the map index only as a last resort.