Repository navigation
[EuiSuperSelect] Combine external labels with the selected value in the accessible name - #10039
Merged
alexwizp merged 10 commits intoOct 2, 2026
Merged
Conversation
`EuiSuperSelectControl` renders the selected option's `inputDisplay` as the button's text content, and only self-referenced the button via `aria-labelledby` when an `EuiFormRow` label was detected. A consumer-passed `aria-label`/`aria-labelledby` was spread straight onto the button, so it replaced the text content in the accessible name computation and the selected value was never announced. External labels are no longer set on the button directly: `aria-label` is rendered into a screen reader only element and the button always self-references alongside the external label id, so the accessible name becomes "<selected value>, <label>". Changelog file is named for the expected PR number and should be renamed once the PR is opened.
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
The accessibility behavior change requires human review and real screen-reader and integration validation.
Pull request overview
Updates EuiSuperSelect so external labels combine with the selected value in the accessible name.
Changes:
- Adds screen-reader-only external labels and self-referencing button IDs.
- Adds accessible-name test coverage.
- Updates snapshots and changelog documentation.
File summaries
| File | Summary |
|---|---|
packages/eui/src/components/form/super_select/super_select.test.tsx |
Tests accessible-name behavior. |
packages/eui/src/components/form/super_select/super_select_control.tsx |
Implements combined accessible names. |
packages/eui/src/components/form/super_select/__snapshots__/super_select.test.tsx.snap |
Updates rendered markup snapshot. |
packages/eui/src/components/form/super_select/__snapshots__/super_select_control.test.tsx.snap |
Updates control snapshot. |
packages/eui/src/components/color_picker/color_palette_picker/__snapshots__/color_palette_picker.test.tsx.snap |
Updates propagated control markup. |
packages/eui/changelogs/upcoming/10039.md |
Documents the accessibility fix. |
Review details
- Files reviewed: 6/6 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
weronikaolejniczak
self-requested a review
September 16, 2026 12:32
Kibana Regression Integration TestStatus: 💔 Kibana CI failed Please check Kibana CI logs for details. |
weronikaolejniczak
approved these changes
Sep 28, 2026
weronikaolejniczak
left a comment
Contributor
There was a problem hiding this comment.
LGTM but we need to prep Kibana changes and make sure CI passes
It rendered as real (non-aria-hidden) DOM content inside the button, while the external label span it was meant to precede lives outside the button. That made it show up as a dangling ", " in plain textContent assertions (e.g. Kibana Playwright toHaveText checks) wherever a label was present. The browser already inserts a space between multiple aria-labelledby idrefs, so no manual separator is needed; this also fixes the pre-existing stray-comma edge case on the form-row path when there is no selected value or placeholder. Co-Authored-By: Claude Sonnet 5 <[email protected]>
…pose-aria-label # Conflicts: # packages/release-cli/kibana-prep-commits
Contributor
Author
|
kibana-prep-commit: elastic/kibana#294177 💚 Build Succeeded |
alexwizp
enabled auto-merge (squash)
October 2, 2026 08:52
💚 Build Succeeded
History
|
💚 Build Succeeded
History
|
skynetigor
pushed a commit
to skynetigor/kibana
that referenced
this pull request
Oct 7, 2026
## Dependency updates `@elastic/eui` - v123.0.0 ⏩ v123.1.0 ## Package updates ### `@elastic/eui` [v123.1.0](https://github.com/elastic/eui/blob/main/packages/eui/changelogs/CHANGELOG_2026.md) - Removed the left color highlight from `EuiCallOut` ([elastic#10109](elastic/eui#10109)) - Updated Flyout menu height to 50px ([elastic#10103](elastic/eui#10103)) - Added new icons: `chartMix`, `chartWaffle`, `clipboardWarning`, `clockUp`, `emergencyLight`, `productCanvas`, `productElasticAgent`, `productFleet`, `productLens`, `puzzlePiece`, `shield` ([elastic#10111](elastic/eui#10111)) - Added `hasAriaDisabled` prop on `EuiSelectableListItem` and `type EuiSelectableOption` ([elastic#10090](elastic/eui#10090)) - Added refs for `EuiFlyoutHeader`, `EuiFlyoutFooter`, and the outer `EuiFlyout` scroll container. ([elastic#10105](elastic/eui#10105)) - Corrected `EuiFlyoutHeaderProps`, `EuiFlyoutFooterProps`, and `EuiFlyoutBodyProps` to describe component props instead of component types. ([elastic#10105](elastic/eui#10105)) - Updated `EuiFormRow`'s `labelAppend` to render string content with an extra-small, subdued text style. ([elastic#10067](elastic/eui#10067)) **Bug fixes** - Fixed a bug on `EuiSelectable` with `searchable={true}` that could result in an infinite loop if all search results are disabled ([elastic#10090](elastic/eui#10090)) - Fixed `EuiSuperSelect` omitting the currently selected value from its accessible name when an `aria-label` or `aria-labelledby` was passed. External labels are now combined with the selected value instead of overriding it ([elastic#10039](elastic/eui#10039)) --------- Co-authored-by: Ángeles Martínez Barrio <[email protected]> Co-authored-by: Alexey Antonov <[email protected]> Co-authored-by: Claude Sonnet 5 <[email protected]>
weronikaolejniczak
added a commit
to boriskirov/eui
that referenced
this pull request
Nov 11, 2026
…he accessible name (elastic#10039) Co-authored-by: Weronika Olejniczak <[email protected]> Co-authored-by: Claude Sonnet 5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes: elastic/kibana#290234
Closes: elastic/kibana#289551
Summary
What:
EuiSuperSelectno longer lets a consumer-passedaria-label/aria-labelledbyoverride the selected value in the control's accessible name — the two are now combined.Why: Previously, any
aria-label/aria-labelledbyreplaced the button's accessible name entirely, so a super select labelled only witharia-label="Flow target"announced as "Flow target, list box pop up collapsed, button" — screen reader users couldn't tell what was selected without opening the dropdown (WCAG 4.1.2). ~40 of Kibana's 144EuiSuperSelectusages hit this.How: External labels are rendered into a screen-reader-only
<span>and referenced by id, instead of being set directly on the button. The button always self-references alongside that label id, so its own content (the selected value) stays part of the accessible name. Precedence: consumeraria-labelledby→ consumeraria-label→EuiFormRowlabel (unchanged).Accessible name for the linked issue goes from
"Flow target"to"As destination Flow target".API Changes
No public API change — same props, corrected behavior.
aria-labelattribute on the control buttonScreenshots
No visual change — screen reader announcement only.
"Flow target, list box pop up collapsed, button""As destination Flow target, list box pop up collapsed, button"Impact Assessment
EuiScreenReaderOnly.EuiSuperSelectgiven anaria-label: a screen reader only<span>is added, the button gainsid+aria-labelledbyand losesaria-label. Three EUI snapshots updated (super_select,super_select_control,color_palette_picker).Not yet tested in Kibana — doing that next to size the downstream test churn.
Impact level: 🟡 Moderate
Release Readiness
FigmaMigration guideAdoption planQA instructions for reviewer
aria-labelset and a selected value.EuiFormRowwith alabel.Checklist before marking Ready for Review
QA: Tested docs changesaria-label,aria-labelledby, and no-label cases; updated affected snapshots.packages/eui/changelogs/upcoming/10039.mdBreaking changes: labelReviewer checklist