-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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] Add scrollbar to color picker demo #43672
Conversation
Netlify deploy previewhttps://deploy-preview-43672--material-ui.netlify.app/ Bundle size report |
Co-authored-by: Zeeshan Tamboli <[email protected]> Signed-off-by: sai chand <[email protected]>
@@ -58,7 +58,7 @@ function ColorDemo(props) { | |||
</Typography> | |||
</Toolbar> | |||
</AppBar> | |||
<Box component="pre" sx={{ m: 2, fontSize: 16 }}> | |||
<Box component="pre" sx={{ m: 2, fontSize: 16, overflowX: 'auto' }}> |
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.
Why not
<Box component="pre" sx={{ m: 2, fontSize: 16, overflowX: 'auto' }}> | |
<Box component="pre" sx={{ m: 2, fontSize: 16, overflow: 'auto' }}> |
like in
overflow: 'auto', |
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.
We could do this. The reason I went for overflowX
is that I haven't come across any situation that requires a scrollbar on the Y axis.
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.
Ok, we can be lazy and wait. It's more that I usually never seen X/Y overflow to be superior to the alternatives: what I found most useful is nothing, or overflow: auto
when I want to make sure a scroll container trigger.
Added scroll bar to https://deploy-preview-43672--material-ui.netlify.app/material-ui/customization/color/#playground demo, so that users can see names of colors they have selected
current demo: https://mui.com/material-ui/customization/color/#playground