Skip to content

Commit 1d26cc0

Browse files
alexwizpCopilot
andauthored
[9.3] fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files (#259313) (#260411)
# Backport This will backport the following commits from `main` to `9.3`: - [fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files (#259313)](#259313) <!--- Backport version: 11.0.1 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Copilot","email":"198982749+Copilot@users.noreply.github.com"},"sourceCommit":{"committedDate":"2026-03-26T11:38:39Z","message":"fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files (#259313)\n\nCloses: https://github.com/elastic/kibana/issues/259306\n\nFixes 37 ESLint violations of `@elastic/eui/icon-accessibility-rules`\nacross 22 files — each `EuiIcon` must have a `title`, `aria-label`,\n`aria-labelledby`, or `aria-hidden={true}` if decorative.\n\n## Changes\n\n- **Typo fix** — `examples/files_example/public/components/app.tsx`:\ncorrected `arial-label` → `aria-label` on a warning status icon\n- **Decorative icons** — all other 36 instances: added\n`aria-hidden={true}` to icons that are purely decorative (inside\nlabelled buttons, alongside visible text, or as visual affordances where\nthe parent already conveys the meaning)\n\n### Example pattern applied\n\n```tsx\n// Before — no accessibility attribute\n<EuiIcon type=\"menu\" size=\"m\" />\n\n// After — explicitly decorative; parent button carries the label\n<EuiIcon type=\"menu\" size=\"m\" aria-hidden={true} />\n```\n\nAffected areas include chrome nav components, content-management sort\nselectors, sample data cards, developer toolbar indicators,\nexit-full-screen button, file picker, inspect flyout, global search bar,\nsaved objects tagging UI, AI assistant connector selector, and URL\ndrilldown variable popover.\n\n\n---\n\n💡 You can make Copilot smarter by setting up custom instructions,\ncustomizing its development environment and configuring Model Context\nProtocol (MCP) servers. Learn more [Copilot coding agent\ntips](https://gh.io/copilot-coding-agent-tips) in the docs.\n\n---------\n\nCo-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>\nCo-authored-by: alexwizp <20072247+alexwizp@users.noreply.github.com>\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Alexey Antonov <alexwizp@gmail.com>","sha":"7fce3923ef37329746bde52a220019405b73fe64","branchLabelMapping":{"^v9.4.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Project:Accessibility","release_note:skip","backport missing","💝community","backport:version","v9.4.0","v9.3.3","v9.2.8","a11y:agent-pr"],"title":"fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files","number":259313,"url":"https://github.com/elastic/kibana/pull/259313","mergeCommit":{"message":"fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files (#259313)\n\nCloses: https://github.com/elastic/kibana/issues/259306\n\nFixes 37 ESLint violations of `@elastic/eui/icon-accessibility-rules`\nacross 22 files — each `EuiIcon` must have a `title`, `aria-label`,\n`aria-labelledby`, or `aria-hidden={true}` if decorative.\n\n## Changes\n\n- **Typo fix** — `examples/files_example/public/components/app.tsx`:\ncorrected `arial-label` → `aria-label` on a warning status icon\n- **Decorative icons** — all other 36 instances: added\n`aria-hidden={true}` to icons that are purely decorative (inside\nlabelled buttons, alongside visible text, or as visual affordances where\nthe parent already conveys the meaning)\n\n### Example pattern applied\n\n```tsx\n// Before — no accessibility attribute\n<EuiIcon type=\"menu\" size=\"m\" />\n\n// After — explicitly decorative; parent button carries the label\n<EuiIcon type=\"menu\" size=\"m\" aria-hidden={true} />\n```\n\nAffected areas include chrome nav components, content-management sort\nselectors, sample data cards, developer toolbar indicators,\nexit-full-screen button, file picker, inspect flyout, global search bar,\nsaved objects tagging UI, AI assistant connector selector, and URL\ndrilldown variable popover.\n\n\n---\n\n💡 You can make Copilot smarter by setting up custom instructions,\ncustomizing its development environment and configuring Model Context\nProtocol (MCP) servers. Learn more [Copilot coding agent\ntips](https://gh.io/copilot-coding-agent-tips) in the docs.\n\n---------\n\nCo-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>\nCo-authored-by: alexwizp <20072247+alexwizp@users.noreply.github.com>\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Alexey Antonov <alexwizp@gmail.com>","sha":"7fce3923ef37329746bde52a220019405b73fe64"}},"sourceBranch":"main","suggestedTargetBranches":["9.3","9.2"],"targetPullRequestStates":[{"branch":"main","label":"v9.4.0","branchLabelMappingKey":"^v9.4.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/259313","number":259313,"mergeCommit":{"message":"fix(a11y): resolve @elastic/eui/icon-accessibility-rules violations across appex-sharedux files (#259313)\n\nCloses: https://github.com/elastic/kibana/issues/259306\n\nFixes 37 ESLint violations of `@elastic/eui/icon-accessibility-rules`\nacross 22 files — each `EuiIcon` must have a `title`, `aria-label`,\n`aria-labelledby`, or `aria-hidden={true}` if decorative.\n\n## Changes\n\n- **Typo fix** — `examples/files_example/public/components/app.tsx`:\ncorrected `arial-label` → `aria-label` on a warning status icon\n- **Decorative icons** — all other 36 instances: added\n`aria-hidden={true}` to icons that are purely decorative (inside\nlabelled buttons, alongside visible text, or as visual affordances where\nthe parent already conveys the meaning)\n\n### Example pattern applied\n\n```tsx\n// Before — no accessibility attribute\n<EuiIcon type=\"menu\" size=\"m\" />\n\n// After — explicitly decorative; parent button carries the label\n<EuiIcon type=\"menu\" size=\"m\" aria-hidden={true} />\n```\n\nAffected areas include chrome nav components, content-management sort\nselectors, sample data cards, developer toolbar indicators,\nexit-full-screen button, file picker, inspect flyout, global search bar,\nsaved objects tagging UI, AI assistant connector selector, and URL\ndrilldown variable popover.\n\n\n---\n\n💡 You can make Copilot smarter by setting up custom instructions,\ncustomizing its development environment and configuring Model Context\nProtocol (MCP) servers. Learn more [Copilot coding agent\ntips](https://gh.io/copilot-coding-agent-tips) in the docs.\n\n---------\n\nCo-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>\nCo-authored-by: alexwizp <20072247+alexwizp@users.noreply.github.com>\nCo-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>\nCo-authored-by: Alexey Antonov <alexwizp@gmail.com>","sha":"7fce3923ef37329746bde52a220019405b73fe64"}},{"branch":"9.3","label":"v9.3.3","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.2","label":"v9.2.8","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> --------- Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
1 parent 66a01d7 commit 1d26cc0

22 files changed

Lines changed: 61 additions & 33 deletions

File tree

examples/files_example/public/components/app.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ export const FilesExampleApp = ({ files, notifications }: FilesExampleAppDeps) =
8989
) : status === 'AWAITING_UPLOAD' ? (
9090
<EuiIcon type="clock" aria-label={status} />
9191
) : (
92-
<EuiIcon color="danger" type="warning" arial-label={status} />
92+
<EuiIcon color="danger" type="warning" aria-label={status} />
9393
),
9494
},
9595
{

src/core/packages/chrome/browser-internal/src/ui/header/__snapshots__/header.test.tsx.snap

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/core/packages/chrome/browser-internal/src/ui/header/header_menu_button.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export const HeaderMenuButton = forwardRef(
3434
aria-controls={props['aria-controls']}
3535
ref={props.forwardRef}
3636
>
37-
<EuiIcon type="menu" size="m" />
37+
<EuiIcon type="menu" size="m" aria-hidden={true} />
3838
</EuiHeaderSectionItemButton>
3939
);
4040
}

src/core/packages/chrome/browser-internal/src/ui/header/nav_link.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,9 @@ export function createEuiListItem({
7171
iconType: euiIconType,
7272
iconProps,
7373
icon:
74-
!euiIconType && icon ? <EuiIcon type={basePath.prepend(`/${icon}`)} size="m" /> : undefined,
74+
!euiIconType && icon ? (
75+
<EuiIcon type={basePath.prepend(`/${icon}`)} size="m" aria-hidden={true} />
76+
) : undefined,
7577
}),
7678
};
7779
}

src/core/packages/chrome/navigation/src/components/nested_secondary_menu/primary_menu_item.tsx

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,15 @@ export const PrimaryMenuItem: FC<PrimaryMenuItemProps> = ({
6969
{...props}
7070
>
7171
{children}
72-
{hasSubmenu && <EuiIcon color="textDisabled" css={arrowStyle} type="arrowRight" size="m" />}
72+
{hasSubmenu && (
73+
<EuiIcon
74+
color="textDisabled"
75+
css={arrowStyle}
76+
type="arrowRight"
77+
size="m"
78+
aria-hidden={true}
79+
/>
80+
)}
7381
</SecondaryMenu.Item>
7482
</div>
7583
);

src/platform/packages/shared/content-management/table_list_view_table/src/components/table_sort_select.tsx

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -97,13 +97,13 @@ export function TableSortSelect({
9797
label: i18nText.nameAscSort,
9898
column: 'attributes.title',
9999
direction: 'asc',
100-
append: <EuiIcon type="sortUp" />,
100+
append: <EuiIcon type="sortUp" aria-hidden={true} />,
101101
},
102102
{
103103
label: i18nText.nameDescSort,
104104
column: 'attributes.title',
105105
direction: 'desc',
106-
append: <EuiIcon type="sortDown" />,
106+
append: <EuiIcon type="sortDown" aria-hidden={true} />,
107107
},
108108
];
109109

@@ -114,7 +114,12 @@ export function TableSortSelect({
114114
column: customSortingOptions.field,
115115
label,
116116
direction,
117-
append: direction === 'asc' ? <EuiIcon type="sortUp" /> : <EuiIcon type="sortDown" />,
117+
append:
118+
direction === 'asc' ? (
119+
<EuiIcon type="sortUp" aria-hidden={true} />
120+
) : (
121+
<EuiIcon type="sortDown" aria-hidden={true} />
122+
),
118123
};
119124
})
120125
);
@@ -160,13 +165,13 @@ export function TableSortSelect({
160165
label: i18nText.updatedAtDescSort,
161166
column: 'updatedAt',
162167
direction: 'desc',
163-
append: <EuiIcon type="sortDown" />,
168+
append: <EuiIcon type="sortDown" aria-hidden={true} />,
164169
},
165170
{
166171
label: i18nText.updatedAtAscSort,
167172
column: 'updatedAt',
168173
direction: 'asc',
169-
append: <EuiIcon type="sortUp" />,
174+
append: <EuiIcon type="sortUp" aria-hidden={true} />,
170175
},
171176
]);
172177
}

src/platform/packages/shared/home/sample_data_card/src/footer/view_button.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ export const ViewButton = ({ id, name, overviewDashboard, appLinks }: Props) =>
7777
const items = sortedItems.map(({ path, label, icon, ...rest }) => {
7878
return {
7979
name: label,
80-
icon: <EuiIcon type={icon} size="m" />,
80+
icon: <EuiIcon type={icon} size="m" aria-hidden={true} />,
8181
href: addBasePath(path),
8282
onClick: getAppNavigationHandler(path),
8383
...(rest['data-test-subj'] ? { 'data-test-subj': rest['data-test-subj'] } : {}),

src/platform/packages/shared/kbn-developer-toolbar/src/toolbar_items/console_error/console_error_indicator.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ export const ConsoleErrorIndicator: React.FC = () => {
146146
</EuiNotificationBadge>
147147
</EuiToolTip>
148148
) : (
149-
<EuiIcon type={iconType} color={iconColor} size="s" />
149+
<EuiIcon type={iconType} color={iconColor} size="s" aria-hidden={true} />
150150
)}
151151
</EuiFlexItem>
152152
<EuiFlexItem

src/platform/packages/shared/kbn-developer-toolbar/src/toolbar_items/memory/memory_usage_indicator.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ export const MemoryUsageIndicator: React.FC = () => {
6060
<div>Threshold: {(warningThreshold / 1000).toFixed(1)}GB</div>
6161
{memoryInfo.leak && (
6262
<div>
63-
<EuiIcon type="warningFilled" color={'danger'} size="s" /> Potential memory leak detected
63+
<EuiIcon type="warningFilled" color={'danger'} size="s" aria-hidden={true} /> Potential
64+
memory leak detected
6465
</div>
6566
)}
6667
<div>Samples: {memoryInfo.history.length}</div>

src/platform/packages/shared/shared-ux/button/exit_full_screen/src/__snapshots__/exit_full_screen_button.test.tsx.snap

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)