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

[KeyCode, AnchorRegion, Popover] Add key navigation in AnchorRegion / Popup #1800

Merged
merged 8 commits into from
Apr 4, 2024

Conversation

dvoituron
Copy link
Collaborator

[KeyCode, AnchorRegion, Popover] Add key navigation in AnchorRegion / Popup

1. FluentKeyCode

  • Updating the FluentKeyCode component to unregister the keydown event when the component is deleted.

2. FluentAnchorRegion

  • Adding AutoFocus attribute to set whether this region should receive the focus when the component is loaded.
  • Adding FocusToNextElementAsync and FocusToOriginalElementAsync methods to move the focus to the
    next element included in this anchor region only and to the initial element that triggered the anchor region.

3. FluentPopover

  • Adding AutoFocus attribute to set whether the element should receive the focus when the component is loaded.
    If this is the case, the user cannot navigate to other elements of the page while the Popup is open.
    Default is true.

  • Adding CloseKeys attribute to set the keys that can be used to close the popover (ESC).

Demo (using only keyboard)

peek

@dvoituron dvoituron requested a review from vnbaaij April 4, 2024 13:33
@vnbaaij vnbaaij enabled auto-merge (squash) April 4, 2024 13:38
@vnbaaij vnbaaij merged commit cd29fb1 into dev Apr 4, 2024
3 checks passed
@vnbaaij vnbaaij deleted the users/dvoituron/anchor-keycodes branch April 4, 2024 13:47
vnbaaij added a commit that referenced this pull request Apr 29, 2024
… Popup (#1800)

* Draft version

* Add FluentKeyCode.DisposeAsync

* Add Popover CloseKeys

* Add Popover AutoFocus and CloseKeys to navigate in the Popup only

* Merge from dev

* Fix Unit Tests

---------

Co-authored-by: Vincent Baaij <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants