-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
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
[Popper] Material/Joy exposing sx
prop?
#29604
Comments
This comment has been minimized.
This comment has been minimized.
@jpmtrabbold The Popper component of Material is defined as: So it doesn't come with any style or sx. Still, the Popper component does have a host HTML element: that developers might want to customize with the So I think that the question is about should Joy/Material wrap the Popper component with a |
sx
prop?
@oliviertassinari yep - as a workaround, I wrapped it with I believe that it should be wrapped with |
This comment has been minimized.
This comment has been minimized.
I agree with this - I'm in favor of following the principle of least surprise. If other components allow styling with
I'd rather follow the pattern we've already been using - expose the |
For context, the approach proposed by @siriwatknp is what React Toolbox tried in 2016 to solve what we try to solve with unstyled. I personally find the |
@michaldudak @oliviertassinari The way to move forward is to create a material Popper version with default styled-component (so that the consumer can pass |
Hi I am new to Open Source, can I work on this issue? |
Sure, go ahead! |
Duplicates
Latest version
Current behavior 😯
When I try to set the style of a Popper using sx, the prop is not there (at least Typescript is not showing anything).
Expected behavior 🤔
To have an sx prop on the Popper component, so I can set the style of the popper div - and to make it consistent with the other components.
Steps to reproduce 🕹
Steps:
Context 🔦
There's a popper coming out of a button that is inside an AppBar. I need to set the zIndex of that popper to at least the same zIndex as the AppBar so it appears on top of it.
Your environment 🌎
`npx @mui/envinfo`
The text was updated successfully, but these errors were encountered: