Paging clicks only visible controls: First/Prev are mobile-only

Munchkin Big Box and Tang Garden hung 30s each on a "First Page" anchor
that exists but is invisible: BGG renders every paging control twice,
and the First/Prev pair lives only in the mobile set
(<li class="visible-xs-inline">). A desktop viewport can never click it.

Paging now selects the first VISIBLE match, and returning to page 1
closes and reopens the sub-view (which always opens on page 1) instead
of reaching for a control that isn't there. A test proves no hidden
control is ever clicked — the fake picker raises if one is.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016jXZFSTZQKzAC8fqpWSz9g
This commit is contained in:
Eric Wagoner
2026-08-05 22:41:42 -04:00
co-authored by Claude Fable 5
parent ba55863cef
commit 9283a3e980
4 changed files with 71 additions and 25 deletions
+10 -5
View File
@@ -121,11 +121,16 @@ earlier walkthrough had marked *verified*, and the parts marked
`li:has(.summary-item-thumbnail)`. Plain `listitem` also catches the
paging `<li>`s ("First", "Prev", "1", "…").
- **Paging is an AngularJS `<ul class="pagination">` of anchors**, not
buttons: `a[title="Next Page"]`, `a[title="First Page"]`, with the
parent `<li>` gaining `disabled` at the end. The numbered anchors
render twice (mobile + desktop), so step with Next rather than
clicking a number. Paging is client-side over an already-loaded list —
no request per page.
buttons: `a[title="Next Page"]`, with the parent `<li>` gaining
`disabled` at the end. Paging is client-side over an already-loaded
list — no request per page.
- **Every paging control renders TWICE**: a desktop set and a mobile set
inside `<li class="visible-xs-*">`. A selector matches both, and
`.first` may be the hidden one — Playwright then waits for it to become
visible until it times out. Always click the first *visible* match.
First/Prev exist ONLY in the mobile set, so they are unclickable on a
desktop viewport: to return to page 1, close and reopen the sub-view
(it always opens on page 1) and step forward with Next.
- **Row text is `<game name> (<version name>) (<year>)`**, and the game
name is localized (a Czech edition's row starts "Spící bohové"). Match
the version name inside its parentheses.