Skip to content

Commit

Permalink
Updating EuiPopover screen reader text to include mobile cues. (#6567)
Browse files Browse the repository at this point in the history
* Updating EuiPopover screen reader text to include mobile cues.
* Updating screen reader help text in EuiPopver and i18nJSON.
* Updating EuiPopover snapshots.
* Added a changelog entry.
* Edited SR text to explain close actions more clearly.
* Snapshots updated to use latest screen reader text.
  • Loading branch information
1Copenut authored Feb 1, 2023
1 parent a8de8df commit 5ccdbed
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion i18ntokens.json
Original file line number Diff line number Diff line change
Expand Up @@ -5121,7 +5121,7 @@
},
{
"token": "euiPopover.screenReaderAnnouncement",
"defString": "You are in a dialog. To close this dialog, hit escape.",
"defString": "You are in a dialog. Press Escape, or tap/click outside the dialog to close.",
"highlighting": "string",
"loc": {
"start": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ exports[`useDataGridColumnSelector columnSelector renders a toolbar button/popov
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div>
<div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ exports[`useDataGridColumnSorting columnSorting renders a toolbar button/popover
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ exports[`useDataGridKeyboardShortcuts returns a popover containing a list of key
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div>
<div
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ exports[`EuiPopover snapshot testing renders with popover contents 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div>
Hello world
Expand Down
22 changes: 11 additions & 11 deletions src/components/popover/__snapshots__/popover.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ exports[`EuiPopover props arrowChildren is rendered 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -175,7 +175,7 @@ exports[`EuiPopover props buffer 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -229,7 +229,7 @@ exports[`EuiPopover props buffer for all sides 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -296,7 +296,7 @@ exports[`EuiPopover props focusTrapProps is rendered 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -363,7 +363,7 @@ exports[`EuiPopover props isOpen renders true 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -417,7 +417,7 @@ exports[`EuiPopover props offset with arrow 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -466,7 +466,7 @@ exports[`EuiPopover props offset without arrow 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -520,7 +520,7 @@ exports[`EuiPopover props ownFocus defaults to true 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -619,7 +619,7 @@ exports[`EuiPopover props panelClassName is rendered 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -673,7 +673,7 @@ exports[`EuiPopover props panelPaddingSize is rendered 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down Expand Up @@ -728,7 +728,7 @@ exports[`EuiPopover props panelProps is rendered 1`] = `
class="emotion-euiScreenReaderOnly"
id="generated-id"
>
You are in a dialog. To close this dialog, hit escape.
You are in a dialog. Press Escape, or tap/click outside the dialog to close.
</p>
<div />
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/components/popover/popover.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ export class EuiPopover extends Component<Props, State> {
{ownFocus && (
<EuiI18n
token="euiPopover.screenReaderAnnouncement"
default="You are in a dialog. To close this dialog, hit escape."
default="You are in a dialog. Press Escape, or tap/click outside the dialog to close."
/>
)}
{popoverScreenReaderText}
Expand Down
1 change: 1 addition & 0 deletions upcoming_changelogs/6567.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Updated `EuiPopover` screen reader instructions for mobile and click behaviors

0 comments on commit 5ccdbed

Please sign in to comment.