Repository navigation
fix(ui): name the ribbon's Project and collapse buttons for screen readers (#3052) - #3090
Conversation
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
Code reviewI found no bugs, security issues, performance problems, or AGENTS.md violations in this change. Confidence is high. The diff is one file ( Bugs: None.
Security: None. Performance: None. The added work is one string lookup per frame, and only when accessibility is on for the Project button. Quality (nits, not for this pass):
AGENTS.md: No violations.
Twins checked: Every Earlier review threads: None on this PR, so no concerns were left alone. Change sizeCompared with the base branch: the whole PR against main (merge base 9bdf3a9 to PR head 11bcfcc).
|
|
Both quality nits are left as they are: they are style only, with no change in behaviour, and the branch is frozen after approval. |
📖 Docs preview
GitHub Pages takes a minute or two to publish a new commit. Newer commits from the fork aren't published until a maintainer adds the |
Summary
The Project button and the collapse/expand button of the ribbon's tab strip are painted over
allocate_exact_size(…, Sense::click())with nowidget_info. Their accessibility nodes had the roleUnknown, and their only name was the tooltip's text, which egui'son_hover_textcopies to a node without one: "Open, save and create projects" for Project, and the collapse or expand caption (with the shortcut, when there is one) for the other.Both now declare themselves as buttons, as the tabs and scroll arrows next to them do:
The tooltips are unchanged. No new strings.
Surfaces: the ribbon is drawn by the desktop app, the browser build, and the phone when it is switched to the desktop interface; the touch interface draws its own chrome. No command, shortcut or project format changes, so nothing changes for the command line, Python, command search, the Assistant, MCP or plugins.
Testing
Two new tests in
crates/ui-egui/src/ribbon.rs, each finding the button by role and label and clicking it:the_project_button_is_named_and_opens_the_backstagethe_collapse_button_is_named_for_its_state_and_toggles_the_ribbon(both states, there and back)On the branch rebased on
9bdf3a96:cargo fmt --check, clippy onrustgis-ui-egui, nextest on the workspace without the DuckDB tests (9891 passed, 29 skipped), doctests, the layer check and the schema check all pass.UI evidence
No visible UI change.
Related issue
Closes #3052
Summary by CodeRabbit