-
-
Notifications
You must be signed in to change notification settings - Fork 32.3k
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
[docs][joy] Build TS versions for Menu component demos #36383
Conversation
Netlify deploy previewhttps://deploy-preview-36383--material-ui.netlify.app/ Bundle size report |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR includes changes to Typography demos. Please discard them.
Your branch includes commits that create typography TS demos and deletes them. You shouldn't have both commits in the first place. Please reset your branch to the latest master and only push commits related to Menu component demos. |
0ff2a19
to
b1b9ef7
Compare
@@ -98,15 +97,21 @@ function MenuButton({ children, menu, open, onOpen, onLeaveMenu, label, ...props | |||
placement: 'right-start', | |||
sx: { | |||
width: 288, | |||
[`& .${menuClasses.listbox}`]: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't be deleted. You can add these to the matching TS demo and run yarn docs:typescript:formatted
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
problem is menu classes does not have the listbox property
const menuClasses: MenuClasses = generateUtilityClasses('MuiMenu', [ 'root', 'expanded', 'colorPrimary', 'colorNeutral', 'colorDanger', 'colorInfo', 'colorSuccess', 'colorWarning', 'colorContext', 'variantPlain', 'variantOutlined', 'variantSoft', 'variantSolid', 'sizeSm', 'sizeMd', 'sizeLg', ]);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right. I opened a new PR to address this issue. After I get a review from another team member on the PR, I will approve this one and merge it. Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This issue is now fixed in #36520
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution! I rebased it and finalised it. Ready for merge!
zIndex: 1000, | ||
}); | ||
|
||
export default function MenuListComposition(): JSX.Element { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since it's for the docs, I think we should keep the type simpler, even if slower:
export default function MenuListComposition(): JSX.Element { | |
export default function MenuListComposition() { |
It's what the reset of the docs is doing, fixed in #38903.
Menu Part of #36367