Skip to content

fix: stop a tab panel's name rule restyling every section, and update two tests for #6088 - #6167

Merged
leaf-agent merged 1 commit into
mainfrom
fix/6088-tab-name-fallout
Nov 16, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/6088-tab-name-fallout

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

#6088 (name every widget by the markup it opens with) turned three browser tests red on main in push run 43850158443. Each one passes on #6088's parent 66ce9db8f and fails from 1740bb536 on, including current main. One of the three is a real performance regression in tabs.css. The other two are tests whose premise #6088 changed on purpose. With this change, all three pass locally, along with the 43 tests in tests/browser/widgets/test_tabs.py and tests/browser/navigation/test_tabs.py.

  • test_resolving_a_thread_restyles_what_focus_marks. Resolving a thread restyled 264 elements on a page of 4 sections and 404 on a page of 24, so the cost grew with the page. Reverting Name every widget by the markup it opens with, and retire x-name #6088's stylesheets one at a time narrowed it to tabs.css. Within that file, the culprit is the nested & + * rule that sets the top margin of the block after a tab panel's name. Nesting expands & into an :is() that holds a complex selector. Written out flat, the rule matches the same elements and the test passes. On a row strip and on a side list, the following block's computed margin-block-start and --lf-frame-start are the same before and after the change, so nothing on screen changes.
  • test_the_g_chord_selects_a_visible_tab_hint. Name every widget by the markup it opens with, and retire x-name #6088 gave each tab an id (lf-tab-<panel id>) so that its panel can be aria-labelledby the tab. A go-to hint's data-lf-go-to-target uses the member's own id before aria-controls, so the hint now names lf-tab-tab-bath instead of tab-bath. The hint still selects and focuses the tab. The test now addresses the tab by its new id.
  • test_design_mode_reads_each_shape_of_control_into_the_anchor_its_routes_carry. Its "generated words stay out of the anchor" subtest relied on the queue's summary="pages" attribute being generated text. Name every widget by the markup it opens with, and retire x-name #6088 moved the summary into authored markup in the panel's <header>, so "Backup pages" is now the page's own words, and the subtest's premise no longer holds. This change removes the subtest.

A fourth new failure in that run is not part of this PR: test_a_package_feed_keeps_a_rewrite_where_a_card_would lost the end of a typed rewrite across a reload. It passes unloaded, and it is tracked separately from #3985.

Refs #3985 — automated triage

… two tests for #6088

#6088 (name every widget by the markup it opens with) turned three browser
tests red on main in push run 43850158443. Each passes on its parent
66ce9db and fails from 1740bb5.

- test_resolving_a_thread_restyles_what_focus_marks: a resolve restyled
  264 elements on a 4-section page and 404 on a 24-section one. The
  culprit is the nested `& + *` rule in tabs.css that sets the top margin
  of the block after a tab panel's name. Nesting desugars `&` into an
  :is() holding a complex selector, and Chromium then restyled every
  section when the focus mark moved. The rule is now written out flat,
  matching the same elements (computed margin and --lf-frame-start are
  unchanged on a row strip and a side list), and the count no longer
  grows with the page.
- test_the_g_chord_selects_a_visible_tab_hint: #6088 gave each tab an id
  (lf-tab-<panel id>) so its panel can be aria-labelledby it, and a go-to
  hint names its member's own id before aria-controls. The hint still
  selects and focuses the tab; the test now addresses it by that id.
- test_design_mode_reads_each_shape_of_control_into_the_anchor_its_routes_carry:
  the "generated words stay out of the anchor" subtest relied on the
  queue's `summary="pages"` attribute being generated text. #6088 made the
  summary authored markup in the panel's header, so "Backup pages" is now
  the page's own words, and the subtest's premise is gone. It is removed.

Refs #3985
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.

1 participant