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

[Bug]: MenuItem is not correctly focused when expanded within ComposedModal #16861

Closed
2 tasks done
fred104 opened this issue Jun 25, 2024 · 1 comment · Fixed by #17145
Closed
2 tasks done

[Bug]: MenuItem is not correctly focused when expanded within ComposedModal #16861

fred104 opened this issue Jun 25, 2024 · 1 comment · Fixed by #17145

Comments

@fred104
Copy link

fred104 commented Jun 25, 2024

Package

@carbon/react

Browser

Chrome

Package version

v1.60.0

React version

v18.2

Description

We are trying to use MenuButton within ComposedModal and found a strange bug. When you click the MenuButton to expand the menu, it should focus on the first menu item. However, the other button is being focused which is triggered by ComposedModal.

See the call stack below. (handleBlur and wrapFocus are from ComposedModal.)
image

Reproduction/example

https://stackblitz.com/edit/github-yzyrus?file=src%2FApp.jsx

Steps to reproduce

Click the MenuButton (Click me and you will see above button being focused!) and you will see the above button is focused. The console prints out the call stack too.

Suggested Severity

Severity 2 = User cannot complete task, and/or no workaround within the user experience of a given component.

Application/PAL

IBM SOAR

Code of Conduct

@guidari guidari moved this to ⏱ Backlog in Design System Jun 25, 2024
@2nikhiltom 2nikhiltom moved this from ⏱ Backlog to 🚦 In Review in Design System Aug 6, 2024
@2nikhiltom 2nikhiltom moved this from 🚦 In Review to ⏱ Backlog in Design System Aug 8, 2024
@2nikhiltom 2nikhiltom moved this from ⏱ Backlog to 🏗 In Progress in Design System Aug 26, 2024
@2nikhiltom 2nikhiltom moved this from 🏗 In Progress to ⏱ Backlog in Design System Sep 9, 2024
@2nikhiltom 2nikhiltom moved this from ⏱ Backlog to 🏗 In Progress in Design System Oct 7, 2024
@2nikhiltom 2nikhiltom linked a pull request Oct 9, 2024 that will close this issue
@2nikhiltom
Copy link
Contributor

2nikhiltom commented Oct 9, 2024

Closed via #17145

@github-project-automation github-project-automation bot moved this from 🏗 In Progress to ✅ Done in Design System Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants