Skip to content

[menu] Fix submenu trigger interactions#4892

Open
atomiks wants to merge 1 commit into
mui:masterfrom
atomiks:codex/menu-runtime-bugs
Open

[menu] Fix submenu trigger interactions#4892
atomiks wants to merge 1 commit into
mui:masterfrom
atomiks:codex/menu-runtime-bugs

Conversation

@atomiks
Copy link
Copy Markdown
Contributor

@atomiks atomiks commented May 22, 2026

This is part of the Codex component behavior and test coverage sweep. It fixes Menu behavior bugs found during review and adds focused test coverage for the affected paths.

Changes

  • Register Menu.SubmenuTrigger labels for typeahead.
  • Respect highlightItemOnHover={false} for submenu triggers.
  • Stop controlled-open disabled menus from accepting typeahead, item clicks, and submenu trigger interaction.
  • Run Menu.SubmenuTrigger conformance against the actual submenu trigger element.
  • Add coverage for submenu trigger typeahead, hover highlighting, disabled controlled-open menus, and conformance.

Original findings addressed

  • [P2] Menu.SubmenuTrigger ignores its label prop for typeahead.
  • [P2] highlightItemOnHover={false} is bypassed for submenu triggers.
  • [P2] Controlled-open disabled menus still accept item/typeahead interaction.
  • [P2] Menu.SubmenuTrigger conformance is effectively untested.

@atomiks atomiks added component: menu Changes related to the menu component. type: bug It doesn't behave as expected. labels May 22, 2026
@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented May 22, 2026

commit: e4b0b8e

@code-infra-dashboard
Copy link
Copy Markdown

code-infra-dashboard Bot commented May 22, 2026

Bundle size

Bundle Parsed size Gzip size
@base-ui/react 🔺+210B(+0.05%) 🔺+38B(+0.03%)

Details of bundle changes

Performance

Total duration: 1,451.98 ms +202.97 ms(+16.3%) | Renders: 50 (+0) | Paint: 2,208.58 ms +313.19 ms(+16.5%)

Test Duration Renders
Tabs mount (200 instances) 272.11 ms 🔺+46.33 ms(+20.5%) 4 (+0)
Menu mount (300 instances) 174.87 ms 🔺+37.70 ms(+27.5%) 2 (+0)
Select mount (200 instances) 175.42 ms 🔺+31.14 ms(+21.6%) 3 (+0)
Checkbox mount (500 instances) 94.34 ms 🔺+22.52 ms(+31.3%) 1 (+0)
Select open (500 options) 61.27 ms 🔺+18.78 ms(+44.2%) 14 (+0)

…and 1 more (+6 within noise) — details


Check out the code infra dashboard for more information about this PR.

@atomiks atomiks force-pushed the codex/menu-runtime-bugs branch from 5a7e3b2 to e4b0b8e Compare May 22, 2026 11:56
@netlify
Copy link
Copy Markdown

netlify Bot commented May 22, 2026

Deploy Preview for base-ui ready!

Name Link
🔨 Latest commit 5a7e3b2
🔍 Latest deploy log https://app.netlify.com/projects/base-ui/deploys/6a1042fe9b1d800008de36c3
😎 Deploy Preview https://deploy-preview-4892--base-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify
Copy link
Copy Markdown

netlify Bot commented May 22, 2026

Deploy Preview for base-ui ready!

Name Link
🔨 Latest commit e4b0b8e
🔍 Latest deploy log https://app.netlify.com/projects/base-ui/deploys/6a10447f80d9670008c4bcc9
😎 Deploy Preview https://deploy-preview-4892--base-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@atomiks atomiks marked this pull request as ready for review May 22, 2026 12:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component: menu Changes related to the menu component. type: bug It doesn't behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant