Skip to content

fix: keep the Pokédex arrows still while stepping through - #13

Merged
TechLuddite merged 1 commit into
mainfrom
claude/last-commit-error-9pqqkh
Aug 17, 2026
Merged

TechLuddite merged 1 commit into
mainfrom
claude/last-commit-error-9pqqkh

Conversation

@TechLuddite

Copy link
Copy Markdown
Owner

Spotted by Joseph: the ◀ ▶ arrows on the Pokédex move when you press them.

Cause

The row was [picker] [◀] [▶]. The picker is a shrink-wrapped flex item, so it is exactly as wide as the name inside it — and the arrows sit after it in the flow. Every time the name length changed, the arrows slid sideways. On a tablet that means the button is no longer under the finger that just pressed it, which is precisely the button you want to press again.

Fix

The arrows now come first in the row, anchored to the left edge, and the picker grows to the right instead. One-line reorder in src/features/Dex.jsx, plus a comment saying why the order matters so it doesn't get tidied back.

Verification

Driven in a real browser (Chromium), stepping through eight Pokémon and measuring the arrows' actual x position each time:

distinct ◀ positions distinct ▶ positions
before 4 — 144.8, 152.7, 160.5, 168.3 4 — 192.6, 200.4, 208.2, 216.0
after 1 — 48 1 — 95.7

The "before" numbers were captured by stashing the fix and re-running the same script, so the bug is confirmed rather than assumed.

Also: npm run test:run (353 tests, 8 files) and npm run build both green.

Changelog

New top entry dated 2026-08-17, credited to Joseph. Note this moves the version stamp attached to bug reports.


Generated by Claude Code

The picker is as wide as the name inside it, so with the arrows sitting
to its right they moved every time the name length changed. Stepping
Ivysaur -> Venusaur -> Charmander slid them across four different
positions, which on a tablet means the button is no longer under the
finger that just pressed it.

Arrows now come first in the row, so they are anchored to the left edge
and the picker grows to the right instead.

Measured in a browser across eight Pokemon: before, the arrows occupied
four distinct x positions; after, one.

Spotted by Joseph.

Co-authored-by: Claude <noreply@anthropic.com>
@TechLuddite
TechLuddite merged commit d42abe8 into main Aug 17, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants