Context
Operator-reported live defect on the /examples overview (Start here) and group pages: two example cards (Community Garden Plan and Sprint Board) easily remain expanded simultaneously, and once a card such as Sprint Board is clicked, its .portal-example-more detail section stays permanently expanded even when walking across cards with Arrow keys or hovering other cards with the mouse.
The Problem
Three interacting rules in Portal.view.examples.List (apps/portal/view/examples/List.mjs) and resources/css/src/apps/portal/examples/List.css allow multiple cards to expand at once and latch clicked cards open indefinitely on desktop:
- Desktop
.neo-selected latches a clicked card open permanently (List.css:158-163, ListModel.mjs:67-82):
Portal.view.examples.List inherits disableSelection: false and selectOnFocus: false from Neo.list.Base.
- Clicking anywhere on a card—including clicking its title or
Open live ↗ link (target="_blank")—triggers ListModel#onListClick and adds .neo-selected to <li class="neo-list-item">.
- Because
.neo-list-item.neo-selected { .portal-example-more { grid-template-rows: 1fr; } } in List.css:159 is unscoped instead of restricted to touch/phone viewports (@media (max-width: 600px), (hover: none)), and because Arrow-key navigation (selectOnFocus: false) moves DOM focus without moving .neo-selected while singleSelect: true never deselects on re-click or mouse leave, that card stays expanded forever on desktop.
- Mouse-click
:focus-within keeps a clicked card open after the pointer leaves (List.css:158):
:focus-within matches mouse-click focus on <li tabindex="-1"> and <a class="neo-title">, keeping a clicked card expanded even after the pointer leaves the list, whereas :focus-visible / :has(:focus-visible) activates only on keyboard modality (Tab, Arrow keys).
- Simultaneous
:hover and keyboard focus (:focus-visible) expand two cards at once (List.css:158-174):
- Hovering Card B while Card A holds keyboard focus expands both cards unless hover and keyboard focus yield to whichever input modality acted last (pointer
mouseenter vs keyboard Tab / Arrow navigation).
- On touch/phone viewports (
max-width: 600px / hover: none), tapping an <a> launch link should also avoid latching .neo-selected, and tapping an already-open card body should toggle .neo-selected closed so a single card is never irrevokably open there either.
The Architectural Reality
apps/portal/view/examples/List.mjs (Portal.view.examples.List, extending Neo.list.Base) and resources/css/src/apps/portal/examples/List.css own card rendering and .portal-example-more disclosure across Overview, GroupPage, and SearchResults.
- Design authority:
"The cover fills the card, title and proof line stand on a scrim at its foot; the action appears on hover and focus, and under the image on touch widths" (#21119 operator-selected Full bleed contract; echoed in apps/portal/view/examples/List.mjs:202-205).
The Fix
resources/css/src/apps/portal/examples/List.css (plus plain-CSS theme build sync):
- Remove unscoped desktop
.neo-list-item.neo-selected and mouse :focus-within expansion from the base card rule.
- Under
@media (min-width: 601px) and (hover: hover):
- Expand
.portal-example-more on .neo-list-item:hover when the list is not in .portal-examples-keyboard mode.
- Expand
.portal-example-more on .neo-list-item:is(:focus-visible, :has(:focus-visible)) when .portal-examples-keyboard is active or no card in the list is :hover (&:not(:has(.neo-list-item:hover))), guaranteeing at most 1 expanded card on desktop across click, hover, Tab, and Arrow keys.
- Under
@media (max-width: 600px), (hover: none):
- Keep
.neo-list-item.neo-selected and .neo-list-item:focus-within expanding .portal-example-more (with max-width: 600px opening under the 16:9 cover as today).
apps/portal/view/examples/List.mjs:
- Add
keydown (ArrowUp, ArrowDown, ArrowLeft, ArrowRight, Tab) and delegated .neo-list-item mouseenter handling on Portal.view.examples.List to toggle 'portal-examples-keyboard' on cls so Arrow-key navigation cleanly overrides a stationary pointer hover and moving the pointer onto a card hands control back to :hover (clearing any stale selection).
- Guard card selection so clicks on
<a> links (neo-title, portal-example-open-cue, neo-github-image) do not latch .neo-selected, and tapping an already-selected card body toggles it closed.
- Whitebox E2E Verification (
test/playwright/e2e/portal/ExamplesCatalogNL.spec.mjs):
- Add real-browser assertions verifying: (a) clicking Card A (
Sprint Board) then hovering Card B (Community Garden Plan) leaves only Card B expanded (1 open), and moving the mouse to (0, 0) leaves 0 open; (b) keyboard-focusing Card A then hovering Card B leaves only Card B (1 open); (c) keeping the mouse stationary over Card B and pressing ArrowRight/Tab to Card C leaves only Card C (1 open); and (d) hovering a [Multi-window] badge then moving the pointer to (5, 5) dismisses .neo-tooltip.
Contract Ledger Matrix
| Target Surface |
Source of Authority |
Proposed Behavior |
Fallback |
Docs |
Evidence |
.portal-example-more disclosure (apps/portal/view/examples/List.mjs, resources/css/src/apps/portal/examples/List.css) |
#21119 (Full bleed) · List.mjs:202-205 |
At most one card in a list expands .portal-example-more at a time: active hover or keyboard :focus-visible on (min-width: 601px) and (hover: hover), and toggleable tap selection / focus on (max-width: 600px), (hover: none) |
Tile mode (tiles: true) renders no .portal-example-more |
JSDoc in List.mjs |
ExamplesCatalogNL.spec.mjs |
Decision Record impact: none.
Acceptance Criteria
Out of Scope
- Desktop resting caption line-clamp and opaque scrim token changes (
#21584 / PR #21585 — disjoint lines in List.css).
- Phone first-screen header/intro height (
#21598, #21591).
Avoided Traps
- Using
:focus-within unconditionally on desktop: Matches mouse clicks on <li tabindex="-1"> and <a>, leaving clicked cards open after pointer departure even without .neo-selected.
- Pure CSS
:not(:has(.neo-list-item:hover)) without keyboard-modality handoff: Leaves a card under a stationary cursor stuck open while the user navigates elsewhere with Arrow keys.
Related
Related: #21140 (filed beside #21140, which already holds 40 sub-issues), #21119, #21584.
Not good first issue / help wanted: urgent operator-reported Engine 14 Portal UX defect ahead of the 2026-11-23 cut, claimed immediately by @neo-gemini-julia.
Live latest-open + closed sweep: checked latest 20 open (62 open, red band) + open and closed search (examples card hover focus selected; Out of Scope / Avoided Traps and Full bleed contract read on #21119, diff of #21585 checked for zero hunk overlap) at 2026-11-20T17:38Z; no equivalent ticket or prior exclusion found.
A2A in-flight claim sweep: latest 30 messages across all read-states (16:46Z–17:34Z); zero competing [lane-claim] or [lane-intent] on example card detail expansion (#21584/#21585 covers resting caption line-clamp & scrim opacity; #21598 covers phone header/intro height).
MC sweep: "examples overview card detail expanded hover focus keyboard stuck", 6 results (ce471f9d), no prior mapping found.
Own-assignment sweep: 3 open (#21573, #20987, #20671), none overlapping.
Origin Session ID: fdac7b58-4686-4e42-9233-7d3e0be881f4
Retrieval Hint: "examples overview 2 card detail infos expanded Sprint Board stuck neo-selected hover focus-visible"
Context
Operator-reported live defect on the
/examplesoverview (Start here) and group pages: two example cards (Community Garden PlanandSprint Board) easily remain expanded simultaneously, and once a card such asSprint Boardis clicked, its.portal-example-moredetail section stays permanently expanded even when walking across cards with Arrow keys or hovering other cards with the mouse.The Problem
Three interacting rules in
Portal.view.examples.List(apps/portal/view/examples/List.mjs) andresources/css/src/apps/portal/examples/List.cssallow multiple cards to expand at once and latch clicked cards open indefinitely on desktop:.neo-selectedlatches a clicked card open permanently (List.css:158-163,ListModel.mjs:67-82):Portal.view.examples.ListinheritsdisableSelection: falseandselectOnFocus: falsefromNeo.list.Base.Open live ↗link (target="_blank")—triggersListModel#onListClickand adds.neo-selectedto<li class="neo-list-item">..neo-list-item.neo-selected { .portal-example-more { grid-template-rows: 1fr; } }inList.css:159is unscoped instead of restricted to touch/phone viewports (@media (max-width: 600px), (hover: none)), and because Arrow-key navigation (selectOnFocus: false) moves DOM focus without moving.neo-selectedwhilesingleSelect: truenever deselects on re-click or mouse leave, that card stays expanded forever on desktop.:focus-withinkeeps a clicked card open after the pointer leaves (List.css:158)::focus-withinmatches mouse-click focus on<li tabindex="-1">and<a class="neo-title">, keeping a clicked card expanded even after the pointer leaves the list, whereas:focus-visible/:has(:focus-visible)activates only on keyboard modality (Tab,Arrowkeys).:hoverand keyboard focus (:focus-visible) expand two cards at once (List.css:158-174):mouseentervs keyboardTab/Arrownavigation).max-width: 600px/hover: none), tapping an<a>launch link should also avoid latching.neo-selected, and tapping an already-open card body should toggle.neo-selectedclosed so a single card is never irrevokably open there either.The Architectural Reality
apps/portal/view/examples/List.mjs(Portal.view.examples.List, extendingNeo.list.Base) andresources/css/src/apps/portal/examples/List.cssown card rendering and.portal-example-moredisclosure acrossOverview,GroupPage, andSearchResults."The cover fills the card, title and proof line stand on a scrim at its foot; the action appears on hover and focus, and under the image on touch widths"(#21119operator-selectedFull bleedcontract; echoed inapps/portal/view/examples/List.mjs:202-205).The Fix
resources/css/src/apps/portal/examples/List.css(plus plain-CSS theme build sync):.neo-list-item.neo-selectedand mouse:focus-withinexpansion from the base card rule.@media (min-width: 601px) and (hover: hover):.portal-example-moreon.neo-list-item:hoverwhen the list is not in.portal-examples-keyboardmode..portal-example-moreon.neo-list-item:is(:focus-visible, :has(:focus-visible))when.portal-examples-keyboardis active or no card in the list is:hover(&:not(:has(.neo-list-item:hover))), guaranteeing at most1expanded card on desktop across click, hover,Tab, andArrowkeys.@media (max-width: 600px), (hover: none):.neo-list-item.neo-selectedand.neo-list-item:focus-withinexpanding.portal-example-more(withmax-width: 600pxopening under the 16:9 cover as today).apps/portal/view/examples/List.mjs:keydown(ArrowUp,ArrowDown,ArrowLeft,ArrowRight,Tab) and delegated.neo-list-itemmouseenterhandling onPortal.view.examples.Listto toggle'portal-examples-keyboard'onclsso Arrow-key navigation cleanly overrides a stationary pointer hover and moving the pointer onto a card hands control back to:hover(clearing any stale selection).<a>links (neo-title,portal-example-open-cue,neo-github-image) do not latch.neo-selected, and tapping an already-selected card body toggles it closed.test/playwright/e2e/portal/ExamplesCatalogNL.spec.mjs):Sprint Board) then hovering Card B (Community Garden Plan) leaves only Card B expanded (1open), and moving the mouse to(0, 0)leaves0open; (b) keyboard-focusing Card A then hovering Card B leaves only Card B (1open); (c) keeping the mouse stationary over Card B and pressingArrowRight/Tabto Card C leaves only Card C (1open); and (d) hovering a[Multi-window]badge then moving the pointer to(5, 5)dismisses.neo-tooltip.Contract Ledger Matrix
.portal-example-moredisclosure (apps/portal/view/examples/List.mjs,resources/css/src/apps/portal/examples/List.css)#21119(Full bleed) ·List.mjs:202-205.portal-example-moreat a time: active hover or keyboard:focus-visibleon(min-width: 601px) and (hover: hover), and toggleable tap selection / focus on(max-width: 600px), (hover: none)tiles: true) renders no.portal-example-moreList.mjsExamplesCatalogNL.spec.mjsDecision Record impact: none.
Acceptance Criteria
AC-1(No Stuck Card After Desktop Click): Clicking an example card or its launch/source links on desktop (1440×900) does not latch.portal-example-moreopen once the pointer leaves the card or moves to another card (0open at(0, 0),1open when hovering a sibling card).AC-2(Single-Card Mutual Exclusion Across Hover & Keyboard Focus): Hovering Card B while Card A holds keyboard focus expands only Card B (1open), and pressingArrow/Tabkeys while the pointer rests over Card B expands only the keyboard-focused card (1open).AC-3(Touch / Narrow Phone Toggle & Link Cleanliness): On390×844/ touch, tapping a card body opens its details under the cover (1open), tapping a second card switches to that card (1open), tapping the open card again closes it (0open), and tappingOpen live ↗or the title link launches without leaving a stale.neo-selectedcard.AC-4(Theme Build & Whitebox E2E):npm run build-themes -- -n -e dev -t allandtest/playwright/e2e/portal/ExamplesCatalogNL.spec.mjspass with explicit multi-modality regression coverage.Out of Scope
#21584/ PR#21585— disjoint lines inList.css).#21598,#21591).Avoided Traps
:focus-withinunconditionally on desktop: Matches mouse clicks on<li tabindex="-1">and<a>, leaving clicked cards open after pointer departure even without.neo-selected.:not(:has(.neo-list-item:hover))without keyboard-modality handoff: Leaves a card under a stationary cursor stuck open while the user navigates elsewhere with Arrow keys.Related
Related: #21140 (filed beside
#21140, which already holds 40 sub-issues), #21119, #21584.Not
good first issue/help wanted: urgent operator-reported Engine 14 Portal UX defect ahead of the2026-11-23cut, claimed immediately by@neo-gemini-julia.Live latest-open + closed sweep: checked latest 20 open (
62open, red band) + open and closed search (examples card hover focus selected;Out of Scope/Avoided TrapsandFull bleedcontract read on#21119, diff of#21585checked for zero hunk overlap) at2026-11-20T17:38Z; no equivalent ticket or prior exclusion found. A2A in-flight claim sweep: latest 30 messages across all read-states (16:46Z–17:34Z); zero competing[lane-claim]or[lane-intent]on example card detail expansion (#21584/#21585covers resting caption line-clamp & scrim opacity;#21598covers phone header/intro height). MC sweep:"examples overview card detail expanded hover focus keyboard stuck", 6 results (ce471f9d), no prior mapping found. Own-assignment sweep: 3 open (#21573,#20987,#20671), none overlapping.Origin Session ID: fdac7b58-4686-4e42-9233-7d3e0be881f4 Retrieval Hint: "examples overview 2 card detail infos expanded Sprint Board stuck neo-selected hover focus-visible"