Skip to content

[9.3] Fix @elastic/eui/require-aria-label-for-modals violations across kibana-data-discovery files (#259315)#260392

Merged
alexwizp merged 2 commits intoelastic:9.3from
alexwizp:backport/9.3/pr-259315
Mar 31, 2026
Merged

[9.3] Fix @elastic/eui/require-aria-label-for-modals violations across kibana-data-discovery files (#259315)#260392
alexwizp merged 2 commits intoelastic:9.3from
alexwizp:backport/9.3/pr-259315

Conversation

@alexwizp
Copy link
Copy Markdown
Contributor

Backport

This will backport the following commits from main to 9.3:

Questions ?

Please refer to the Backport tool documentation

…bana-data-discovery files (elastic#259315)

Closes: elastic#259304

20 `EuiPopover`, `EuiModal`, `EuiFlyout`, and `EuiWrappingPopover`
components were missing required `aria-label` props across 18 files
owned by `@elastic/kibana-data-discovery`, violating WCAG 2.2 AA
accessibility requirements.

## Changes

- **Added `aria-label` to 16 `EuiPopover` components** across
`discover`, `data_view_management`, `kbn-unified-tabs`,
`kbn-unified-field-list`, `kbn-search-response-warnings`, and
`data_view_editor`
- **Added `aria-label` to 1 `EuiModal`** (`image_preview_modal.tsx`)
- **Added `aria-label` to 1 `EuiFlyout`** (`help_flyout.tsx`)
- **Added `aria-label` to 1 `EuiWrappingPopover`**
(`use_row_header_components.tsx`)
- **Reused existing translated strings** where available (e.g.
`menuButtonLabel`, `filterAriaLabel`, `badgeText`) to avoid duplicate
copy; added new `i18n.translate()` calls only where no suitable string
existed
- **Added `i18n` imports** to the handful of files that were missing
them

Example of the pattern applied:

```tsx
// Before
<EuiPopover
  id={contextMenuPopoverId}
  isOpen={isPopoverOpen}
  ...
>

// After — reusing an already-translated nearby string
<EuiPopover
  id={contextMenuPopoverId}
  aria-label={menuButtonLabel}
  isOpen={isPopoverOpen}
  ...
>
```

`use_table_header_components.tsx` was listed in the issue but was
already compliant; no change needed there.

<!-- START COPILOT CODING AGENT TIPS -->
---

💬 Send tasks to Copilot coding agent from
[Slack](https://gh.io/cca-slack-docs) and
[Teams](https://gh.io/cca-teams-docs) to turn conversations into code.
Copilot posts an update in your thread when it's finished.

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: alexwizp <20072247+alexwizp@users.noreply.github.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
(cherry picked from commit e9d79de)

# Conflicts:
#	examples/discover_customization_examples/moon.yml
#	examples/discover_customization_examples/tsconfig.json
#	src/platform/plugins/shared/discover/public/application/main/components/layout/cascaded_documents/blocks/use_row_header_components.tsx
#	src/platform/plugins/shared/discover/public/embeddable/components/search_embeddable_inline_edit_hover_actions.tsx
@elasticmachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
dataViewEditor 43.4KB 43.6KB +121.0B
dataViewFieldEditor 102.2KB 102.3KB +118.0B
dataViewManagement 142.8KB 143.1KB +299.0B
discover 1.3MB 1.3MB +550.0B
lens 1.9MB 1.9MB +150.0B
maps 3.1MB 3.1MB +116.0B
securitySolution 10.8MB 10.8MB +120.0B
slo 996.8KB 996.9KB +120.0B
unifiedDocViewer 371.1KB 371.3KB +261.0B
total +1.8KB

History

@alexwizp alexwizp merged commit 66a01d7 into elastic:9.3 Mar 31, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants