mui / material-ui

Material UI: Comprehensive React component library that implements Google's Material Design. Free forever.
https://mui.com/material-ui/
MIT License
93.51k stars 32.19k forks source link

Changing dynamic jss value #12345

Closed janhoeck closed 6 years ago

janhoeck commented 6 years ago

Hello,

I want to change a value of a jss property, when a prop changes. I read this article: https://github.com/cssinjs/react-jss#dynamic-values but this won't work, as you can see in my sandbox example https://codesandbox.io/s/4qy85qrly4

Maybe anyone could help me :D Why I want to change the property of a jss key: Because I want to animate it with a transition

oliviertassinari commented 6 years ago

@janhoeck I'm closing as a duplicate of #7633

oliviertassinari commented 6 years ago

Also, we have been documenting the use case in https://material-ui.com/customization/overrides/#2-dynamic-variation-for-a-one-time-situation.