Repository navigation
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 39 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
commit: |
ravisuhag
force-pushed
the
feat/menu-checkbox-radio-link-items
branch
from
October 13, 2026 07:33
de3c0ea to
1346196
Compare
1 task done
Menu.EmptyState and ContextMenu.EmptyState go back to a plain element that the app shows and hides. Menu.Status, ContextMenu.Status, and the shared item count are removed, with their docs, demos, and tests.
A filtered-out checkbox item unmounted the Base UI item, and a group switched to a fragment while filtering, which remounted its items. Both reset uncontrolled checked and radio values. The checkbox item now holds its checked state, and groups stay rendered while filtering. The empty-list styles ignore groups that have no matches.
In a searchable menu, Menu.EmptyState and ContextMenu.EmptyState render Base UI Autocomplete.Empty, a polite live region. The app still decides what it shows. An empty state with no children has no padding, so it can stay mounted.
Export the props types of CheckboxItem, RadioGroup, RadioItem, and LinkItem for Menu and ContextMenu.
Remove an unused handler argument and an unused test import.
…dio-link-items Resolve conflicts in the menu and context-menu index files, packages/react/index.tsx, and menu-misc.tsx. Keep both export lists, and keep the MenuEmptyStateProps signature from main with the Autocomplete.Empty body.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add
CheckboxItem,RadioGroup,RadioItem, andLinkItemtoMenuandContextMenu. Checkbox and radio items draw a check mark or dot before the leading icon.LinkItemrenders an<a href>and takes a router link throughrender. All four filter and keeparia-checkedin the searchable (autocomplete) mode.Rebuild
Menu.EmptyStateandContextMenu.EmptyStateon Base UIAutocomplete.Emptyin the searchable mode (a polite live region elsewhere). AddMenu.StatusandContextMenu.Status, a hidden live region that announces the match count. Items register into a small count context, because our menus filter their own children and do not passitemsto Base UI.Add data-slots for every new part, with tests and Slots tables. Update props, demos, and docs for both components.
Why it's like this: the old Ariakit menu had a
type="select"cell that drew a checkbox picture with no checked state. The Base UI migration (feat: migrate DropdownMenu to BaseUI #652) removed it and did not add CheckboxItem or RadioItem, likely because they do not plug into the Autocomplete-based searchable menu easily. LinkItem was added to Base UI two weeks before that migration.Menu.EmptyStatedates from Nov 2024 and was kept as a plain div.Breaking: small.
Menu.EmptyStateandContextMenu.EmptyStatenow show and hide on their own. They show their children only when the menu renders no items.I have followed the pull request section of the contributing guide.