fix(home): Back keeps the question, and the focus finds its card by name

Opening a card left Home, and Back came back to "Doesn't matter" with a
different hero, whose card then dropped out of the Continue rail and moved
the keyboard onto its neighbour. The budget, reroll seed and seen list live
on the history entry now, and a returning list focuses the item by its
name before its place.
This commit is contained in:
2026-09-19 04:51:43 +02:00
parent 6096dd6927
commit 250e3a9f90
5 changed files with 119 additions and 16 deletions
@@ -149,6 +149,8 @@ const item = (label: string) => {
};
beforeEach(() => {
// Home keeps its question on the history entry (Back restores it): each test starts a fresh one.
window.history.replaceState(null, "");
discover.mockReset().mockResolvedValue(payload());
comfortPins.mockReset().mockResolvedValue({ items: shelf });
addComfortPin.mockReset().mockResolvedValue({ ok: true, id: 1, created: true });