-
Notifications
You must be signed in to change notification settings - Fork 52
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
Usage with bs-css #127
Comments
Yes. You need to use the Example: module Styles = {
open CssJs
let categoryButton = style(.[textTransform(#none), justifyContent(#flexStart)])
let icon = style(.[fontSize(px(24)), width(px(50))])
}
@react.component
let make = () => {
open MaterialUi
<Mui_StylesProvider injectFirst=true>
<Button
color=#Primary classes={Button.Classes.make(~root=Styles.categoryButton, ())} onClick=ignore>
{React.string("Hello, BS-CSS & MUI!")}
</Button>
</Mui_StylesProvider>
} Watch the button text become uppercase when you change the I made an example project which includes the binding. We will include the binding to the StylesProvider in the upcoming version. |
Thank you! |
I only used it with emotion myself. But the problem is just that JSS styles get applied after user styles as you said, so this solution probably works for all of them. |
StyleProvider is now included in version 2.1.0. |
Is it possible to use mui with bs-css? I tried to use bs-css's style function output as className for components but it seems this doesn't work well. it seems they are applied before materual ui classes so they got overriden by material ui classes
The text was updated successfully, but these errors were encountered: