[Box] doesn't apply maxWidth prop
See original GitHub issueBox doesn’t apply maxWidth prop
<Box maxWidth="xs">
Hello World
</Box>
CodeSandBox: https://codesandbox.io/s/hardcore-platform-tyfvw?file=/index.js:131-183
Mui version: v4.9.8 ✓
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (8 by maintainers)
Top Results From Across the Web
[Box] doesn't apply maxWidth prop · Issue #25771 - GitHub
Box doesn't apply maxWidth prop Hello World CodeSandBox: ... I'd expect maxWidth to be support as width is supported.
Read more >max-width - CSS: Cascading Style Sheets - MDN Web Docs
The max-width CSS property sets the maximum width of an element. It prevents the used value of the width property from becoming larger...
Read more >CSS max-width not working - Stack Overflow
If you want the border inside of the max-width, you need to set box-sizing:border-box;. – Mastrianni. Apr 26, 2014 at 10:14. Thanks @Mastrianni ......
Read more >CSS 2.1 Reference: max-width Property - Little Web Hut
The max-width property does NOT include the width of the padding, border, or margin areas. This property is specified by using a length,...
Read more >CSS max-width property - W3Schools
The max-width property defines the maximum width of an element. If the content is larger than the maximum width, it will automatically change...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@matheusmb Thanks for raising the TypeScript issue. I can reproduce it too. @mnajdova should we fix it?
Regarding native support of the breakpoint values. It could make sense. We have these props on the Dialog and Container components. We would need to do:
to have
it’s for instance supported in Tailwind: https://tailwindcss.com/docs/max-width.
Alright, thanks.