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

[material-ui][Box] Remove component from BoxOwnProps #43384

Merged
merged 2 commits into from
Aug 20, 2024

Conversation

DiegoAndai
Copy link
Member

Fixes #34068

When this was implemented initially (#38168), an error was reported (#38274), which prompted it to be reverted.

The issue was with styled(Box), but since then, we've added the no-styled-box rule, so instead of the proposed workaround I added the following diff to the upgrade guide:

-const StyledBox = styled(Box)`
+const StyledDiv = styled('div')`
   color: white;
 `;

I also added the type cast, just in case.

@DiegoAndai DiegoAndai self-assigned this Aug 20, 2024
@DiegoAndai DiegoAndai added package: material-ui Specific to @mui/material component: Box The React component. labels Aug 20, 2024
@mui-bot
Copy link

mui-bot commented Aug 20, 2024

Netlify deploy preview

Bundle size report

No bundle size changes (Toolpad)
No bundle size changes

Generated by 🚫 dangerJS against 1d818af

Copy link
Member

@aarongarciah aarongarciah left a comment

Choose a reason for hiding this comment

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

✅ very nice

@DiegoAndai DiegoAndai merged commit c84d795 into mui:next Aug 20, 2024
22 checks passed
@DiegoAndai DiegoAndai deleted the box-typemap branch August 20, 2024 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking change component: Box The React component. package: material-ui Specific to @mui/material
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Box] Type error when too many properties exist in JSX.IntrinsicElements
3 participants