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(ui5-menu): improve focus handling #8348

Merged
merged 12 commits into from
Feb 28, 2024
Merged

fix(ui5-menu): improve focus handling #8348

merged 12 commits into from
Feb 28, 2024

Conversation

unazko
Copy link
Contributor

@unazko unazko commented Feb 26, 2024

  • We no longer count on the ui5-responsive popover to retrieve
    the focus over ui5-menu-item opener on ui5-menu close.

  • There is a differentiation between mouse and keyboard interactions
    aimed to retrieve the focus to the opener element on ui5-menu close.

@unazko unazko changed the title refactor(ui5-menu): improve focus handling fix(ui5-menu): improve focus handling Feb 28, 2024
@unazko unazko marked this pull request as ready for review February 28, 2024 08:46
Copy link
Contributor

@vladitasev vladitasev left a comment

Choose a reason for hiding this comment

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

Let's start with the event as private, and if the stakeholders can make their story work and stick with this solution, then we'll document it in the next patch.

Question: what is the best name for the event? ui5-item-focusin or just ui5-item-focus? For me, if there is no peir focusin/focusout, then focus would be best. Correct me if I'm missing some detail here

packages/main/src/Menu.ts Show resolved Hide resolved
packages/main/src/Menu.ts Outdated Show resolved Hide resolved
packages/main/src/Menu.ts Outdated Show resolved Hide resolved
packages/main/src/Menu.ts Outdated Show resolved Hide resolved
packages/main/src/Menu.ts Show resolved Hide resolved
packages/main/src/Menu.ts Show resolved Hide resolved
packages/main/src/Menu.ts Show resolved Hide resolved
packages/main/src/Menu.ts Outdated Show resolved Hide resolved
Copy link
Member

@GerganaKremenska GerganaKremenska 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 for NavigationMenu

packages/main/src/Menu.ts Outdated Show resolved Hide resolved
@unazko unazko merged commit bd33dc5 into SAP:main Feb 28, 2024
8 checks passed
nnaydenow pushed a commit that referenced this pull request Mar 20, 2024
fix(ui5-menu): dispatch internal focus in event

- We no longer count on the ui5-responsive popover to retrieve
the focus over ui5-menu-item opener on ui5-menu close.

- There is a differentiation between mouse and keyboard interactions
aimed to retrieve the focus to the opener element on ui5-menu close.
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.

5 participants