Closed denexapp closed 2 months ago
Feels related to https://github.com/facebook/stylex/issues/478
Yes, this is the same problem as #478. I'm on it.
@nmn Are you already making a fix for this or am I able to try my first contribution on this? 😄
Update: Made a PR for the fix, if the fix is already made on your end, feel free to close the PR 🙏
@tounsoo real gigachad
Describe the issue
Hey 👋
If I use gridTemplateRows with the value of
0fr
, this value gets replaced with0px
.There's a popular css trick, in order to smoothly open an accordeon, you may use a css transition from
gridTemplateRows: 0fr
to1fr
. This css transition breaks if 0fr is being compiled to 0px, as px can not be transitioned to fr (i think?).Expected behavior
0fr shouldn't get compiled to 0px, and should be preserved. Basically, every transitionable property should be opted out from this optimization.
Steps to reproduce
gridTemplateRows
css transition trick from0fr
to1fr
, you may use the mentioned article as an examplerepeat(1, 0fr)
torepeat(1, 1fr)
repeat(1, 0fr)
to0fr
andrepeat(1, 1fr)
to1fr
Test case
No response
Additional comments
My current workaround is to use
repeat(1, 0fr)
instead of0fr
andrepeat(1, 1fr)
insead of1fr