Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: [SCREEN READER]: flyouts must announce itself on render and manage focus #180888

Merged
merged 7 commits into from
Apr 23, 2024

Conversation

alexwizp
Copy link
Contributor

@alexwizp alexwizp commented Apr 16, 2024

Part of: https://github.com/elastic/security-team/issues/8657

Summary

This PR is a component of https://github.com/elastic/security-team/issues/8657 and addresses a part of the issue where the flyout must announce itself upon render. This issue was found to be valid for almost all flyouts in the Security Solution's code, and this PR rectifies these cases.

What was done?

  1. In accordance with EUI doc we should Use aria-labelledby={headingId} to announce the flyout to screen readers.

Screens:

a11y tree

Before:

image

After:

image

@alexwizp
Copy link
Contributor Author

/ci

@alexwizp alexwizp added release_note:skip Skip the PR/issue when compiling release notes v8.14.0 Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Defend Workflows “EDR Workflows” sub-team of Security Solution Team:Detection Rule Management Security Detection Rule Management Team Team:Detection Engine Security Solution Detection Engine Area labels Apr 16, 2024
@alexwizp alexwizp self-assigned this Apr 16, 2024
@alexwizp
Copy link
Contributor Author

/ci

@alexwizp
Copy link
Contributor Author

/ci

@alexwizp alexwizp marked this pull request as ready for review April 16, 2024 17:45
@alexwizp alexwizp requested review from a team as code owners April 16, 2024 17:45
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

@alexwizp alexwizp requested review from vitaliidm and banderror April 16, 2024 17:45
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-defend-workflows (Team:Defend Workflows)

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detection-rule-management (Team:Detection Rule Management)

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detection-engine (Team:Detection Engine)

# Conflicts:
#	x-pack/plugins/security_solution/public/management/pages/event_filters/view/components/event_filters_flyout.tsx
@banderror banderror removed their request for review April 17, 2024 09:06
@banderror banderror requested a review from nikitaindik April 17, 2024 09:06
Copy link
Contributor

@nikitaindik nikitaindik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fixes @alexwizp! I checked the code and tested it with a screen reader. LGTM!

Copy link
Contributor

@paul-tavares paul-tavares left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good (on behalf of elastic/security-defend-workflows team)

@kibana-ci
Copy link
Collaborator

💚 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
securitySolution 14.6MB 14.6MB +1.3KB

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @alexwizp

@alexwizp alexwizp merged commit b67d45b into elastic:main Apr 23, 2024
35 checks passed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Apr 23, 2024
…ge focus (elastic#180888)

Part of: elastic/security-team#8657

## Summary

This PR is a component of
elastic/security-team#8657 and addresses a
part of the issue where the flyout must announce itself upon render.
This issue was found to be valid for almost all flyouts in the Security
Solution's code, and this PR rectifies these cases.

## What was done?
1. In accordance with [EUI doc](https://eui.elastic.co/#/layout/flyout)
we should `Use aria-labelledby={headingId} to announce the flyout to
screen readers.`

## Screens:

### `a11y` tree

#### Before:
<img width="1591" alt="image"
src="https://github.com/elastic/kibana/assets/20072247/879e7cd6-22dd-4642-8b72-3da95866da9f">

#### After:

<img width="1445" alt="image"
src="https://github.com/elastic/kibana/assets/20072247/3328c6fd-b0bd-46d7-9251-b4ca3905900d">

(cherry picked from commit b67d45b)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.14

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Apr 23, 2024
…nd manage focus (#180888) (#181397)

# Backport

This will backport the following commits from `main` to `8.14`:
- [fix: [SCREEN READER]: flyouts must announce itself on render and
manage focus (#180888)](#180888)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Alexey
Antonov","email":"alexwizp@gmail.com"},"sourceCommit":{"committedDate":"2024-04-23T09:19:13Z","message":"fix:
[SCREEN READER]: flyouts must announce itself on render and manage focus
(#180888)\n\nPart of:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThis PR is a component
of\r\nhttps://github.com/elastic/security-team/issues/8657 and addresses
a\r\npart of the issue where the flyout must announce itself upon
render.\r\nThis issue was found to be valid for almost all flyouts in
the Security\r\nSolution's code, and this PR rectifies these
cases.\r\n\r\n## What was done?\r\n1. In accordance with [EUI
doc](https://eui.elastic.co/#/layout/flyout)\r\nwe should `Use
aria-labelledby={headingId} to announce the flyout to\r\nscreen
readers.`\r\n\r\n## Screens: \r\n\r\n### `a11y` tree\r\n\r\n####
Before:\r\n<img width=\"1591\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/879e7cd6-22dd-4642-8b72-3da95866da9f\">\r\n\r\n####
After:\r\n\r\n<img width=\"1445\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/3328c6fd-b0bd-46d7-9251-b4ca3905900d\">","sha":"b67d45b3d2485485fa111f814f8c80934ba1df30","branchLabelMapping":{"^v8.15.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:
SecuritySolution","Team:Defend Workflows","Team:Detection Rule
Management","Team:Detection Engine","v8.14.0","v8.15.0"],"title":"fix:
[SCREEN READER]: flyouts must announce itself on render and manage
focus","number":180888,"url":"https://github.com/elastic/kibana/pull/180888","mergeCommit":{"message":"fix:
[SCREEN READER]: flyouts must announce itself on render and manage focus
(#180888)\n\nPart of:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThis PR is a component
of\r\nhttps://github.com/elastic/security-team/issues/8657 and addresses
a\r\npart of the issue where the flyout must announce itself upon
render.\r\nThis issue was found to be valid for almost all flyouts in
the Security\r\nSolution's code, and this PR rectifies these
cases.\r\n\r\n## What was done?\r\n1. In accordance with [EUI
doc](https://eui.elastic.co/#/layout/flyout)\r\nwe should `Use
aria-labelledby={headingId} to announce the flyout to\r\nscreen
readers.`\r\n\r\n## Screens: \r\n\r\n### `a11y` tree\r\n\r\n####
Before:\r\n<img width=\"1591\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/879e7cd6-22dd-4642-8b72-3da95866da9f\">\r\n\r\n####
After:\r\n\r\n<img width=\"1445\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/3328c6fd-b0bd-46d7-9251-b4ca3905900d\">","sha":"b67d45b3d2485485fa111f814f8c80934ba1df30"}},"sourceBranch":"main","suggestedTargetBranches":["8.14"],"targetPullRequestStates":[{"branch":"8.14","label":"v8.14.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.15.0","branchLabelMappingKey":"^v8.15.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/180888","number":180888,"mergeCommit":{"message":"fix:
[SCREEN READER]: flyouts must announce itself on render and manage focus
(#180888)\n\nPart of:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThis PR is a component
of\r\nhttps://github.com/elastic/security-team/issues/8657 and addresses
a\r\npart of the issue where the flyout must announce itself upon
render.\r\nThis issue was found to be valid for almost all flyouts in
the Security\r\nSolution's code, and this PR rectifies these
cases.\r\n\r\n## What was done?\r\n1. In accordance with [EUI
doc](https://eui.elastic.co/#/layout/flyout)\r\nwe should `Use
aria-labelledby={headingId} to announce the flyout to\r\nscreen
readers.`\r\n\r\n## Screens: \r\n\r\n### `a11y` tree\r\n\r\n####
Before:\r\n<img width=\"1591\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/879e7cd6-22dd-4642-8b72-3da95866da9f\">\r\n\r\n####
After:\r\n\r\n<img width=\"1445\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/20072247/3328c6fd-b0bd-46d7-9251-b4ca3905900d\">","sha":"b67d45b3d2485485fa111f814f8c80934ba1df30"}}]}]
BACKPORT-->

Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
alexwizp added a commit that referenced this pull request Apr 25, 2024
…t must announce itself on render and manage focus (#181427)

Closes: elastic/security-team#8657

## Summary

The part about announcing the title was fixed in that PR:
#180888. This PR removed the
incorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since that
flyout overlaps the table, we should not open it with that option.

### Screen 


![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)

#### Eui documentation
https://eui.elastic.co/#/layout/flyout#without-ownfocus
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Apr 25, 2024
…t must announce itself on render and manage focus (elastic#181427)

Closes: elastic/security-team#8657

## Summary

The part about announcing the title was fixed in that PR:
elastic#180888. This PR removed the
incorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since that
flyout overlaps the table, we should not open it with that option.

### Screen

![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)

#### Eui documentation
https://eui.elastic.co/#/layout/flyout#without-ownfocus
(cherry picked from commit 482766e)
kibanamachine added a commit that referenced this pull request Apr 25, 2024
…odal flyout must announce itself on render and manage focus (#181427) (#181658)

# Backport

This will backport the following commits from `main` to `8.14`:
- [fix: [Rules &gt; Add Elastic rules][SCREEN READER]: Rule non-modal
flyout must announce itself on render and manage focus
(#181427)](#181427)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Alexey
Antonov","email":"alexwizp@gmail.com"},"sourceCommit":{"committedDate":"2024-04-25T08:11:43Z","message":"fix:
[Rules > Add Elastic rules][SCREEN READER]: Rule non-modal flyout must
announce itself on render and manage focus (#181427)\n\nCloses:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThe part about announcing the title was fixed in that
PR:\r\nhttps://github.com//pull/180888. This PR removed
the\r\nincorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since
that\r\nflyout overlaps the table, we should not open it with that
option.\r\n\r\n### Screen
\r\n\r\n\r\n![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)\r\n\r\n####
Eui
documentation\r\nhttps://eui.elastic.co/#/layout/flyout#without-ownfocus","sha":"482766e0bfcf2a2297135a3084e0286e22bed888","branchLabelMapping":{"^v8.15.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:
SecuritySolution","Feature:Rule Management","Team:Detection Rule
Management","v8.14.0","v8.15.0"],"title":"fix: [Rules > Add Elastic
rules][SCREEN READER]: Rule non-modal flyout must announce itself on
render and manage
focus","number":181427,"url":"https://github.com/elastic/kibana/pull/181427","mergeCommit":{"message":"fix:
[Rules > Add Elastic rules][SCREEN READER]: Rule non-modal flyout must
announce itself on render and manage focus (#181427)\n\nCloses:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThe part about announcing the title was fixed in that
PR:\r\nhttps://github.com//pull/180888. This PR removed
the\r\nincorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since
that\r\nflyout overlaps the table, we should not open it with that
option.\r\n\r\n### Screen
\r\n\r\n\r\n![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)\r\n\r\n####
Eui
documentation\r\nhttps://eui.elastic.co/#/layout/flyout#without-ownfocus","sha":"482766e0bfcf2a2297135a3084e0286e22bed888"}},"sourceBranch":"main","suggestedTargetBranches":["8.14"],"targetPullRequestStates":[{"branch":"8.14","label":"v8.14.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.15.0","branchLabelMappingKey":"^v8.15.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/181427","number":181427,"mergeCommit":{"message":"fix:
[Rules > Add Elastic rules][SCREEN READER]: Rule non-modal flyout must
announce itself on render and manage focus (#181427)\n\nCloses:
https://github.com/elastic/security-team/issues/8657\r\n\r\n##
Summary\r\n\r\nThe part about announcing the title was fixed in that
PR:\r\nhttps://github.com//pull/180888. This PR removed
the\r\nincorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since
that\r\nflyout overlaps the table, we should not open it with that
option.\r\n\r\n### Screen
\r\n\r\n\r\n![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)\r\n\r\n####
Eui
documentation\r\nhttps://eui.elastic.co/#/layout/flyout#without-ownfocus","sha":"482766e0bfcf2a2297135a3084e0286e22bed888"}}]}]
BACKPORT-->

Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
kpatticha pushed a commit to kpatticha/kibana that referenced this pull request Apr 26, 2024
…t must announce itself on render and manage focus (elastic#181427)

Closes: elastic/security-team#8657

## Summary

The part about announcing the title was fixed in that PR:
elastic#180888. This PR removed the
incorrect 'ownFocus = { false }' parameter for `EuiFlyout`. Since that
flyout overlaps the table, we should not open it with that option.

### Screen 


![image](https://github.com/elastic/kibana/assets/20072247/50883abb-7a76-4819-8df4-530c81d1a48c)

#### Eui documentation
https://eui.elastic.co/#/layout/flyout#without-ownfocus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release_note:skip Skip the PR/issue when compiling release notes Team:Defend Workflows “EDR Workflows” sub-team of Security Solution Team:Detection Engine Security Solution Detection Engine Area Team:Detection Rule Management Security Detection Rule Management Team Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. v8.14.0 v8.15.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants