Skip to content
This repository has been archived by the owner on Nov 19, 2024. It is now read-only.

Changes 'Prompt' widget 'Keyboard navigation' section #6850

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/guides/v2.3/javascript-dev-guide/widgets/widget_prompt.md
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,10 @@ The prompt widget implements the following events:

## Keyboard navigation {#prompt_key_navigation}

The keyboard navigation for the alert windows is similar to the [navigation of the modal widget].
- ESC key: cancel the input and close the current prompt window (the same behavior as for the 'Cancel' button)
- ENTER key: confirm the input and close the current prompt window (the same behavior as for the 'OK' button)
- TAB key: set focus to the next focusable element (looped inside the prompt window)
- SHIFT+TAB keys combination: set focus to the previous focusable element (looped inside the prompt window)

## Code Sample

Expand Down Expand Up @@ -307,4 +310,3 @@ The keyboard navigation for the alert windows is similar to the [navigation of t
[`ui/template/modal/modal-prompt-content.html`]: {{ site.mage2bloburl }}/{{ page.guide_version }}/app/code/Magento/Ui/view/base/web/templates/modal/modal-prompt-content.html
[Magento Admin Pattern Library, the Slide-out Panels, Modal Windows, and Overlays topic.]: {{page.baseurl}}/pattern-library/containers/slideouts-modals-overlays/slideouts-modals-overalys.html#modals
[JavaScript initialization]: {{page.baseurl}}/javascript-dev-guide/javascript/js_init.html
[navigation of the modal widget]: {{page.baseurl}}/javascript-dev-guide/widgets/widget_modal.html#key_navigation