You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It looks like there is an issue with the outputted tailwind line-height classes. We have a text layer in Figma with font-size 14px and line-height 24px. The outputted tailwind classes are text-sm which is correct, and leading-normal which is (1.5 x font-size) so gives us 21px which is incorrect.
I believe the tailwind named classes (like leading-normal) are relative to the font size rather than being rems so I think the font size may need to be passed through to here perhaps?
Thanks for the response. Perhaps the order can make a difference but in the example I have it is using the leading class. I think the bug originates from an assumption in the code that leading-normal represents 1.5rem when in fact it is 1.5 x font-size
Activity
liampcollins commentedon Oct 21, 2024
I believe the tailwind named classes (like
leading-normal) are relative to the font size rather than being rems so I think the font size may need to be passed through to here perhaps?bernaferrari commentedon Oct 21, 2024
AFAIK
text-smoverrides leading (but maybe it is order dependent) but maybe I'm wrong. If you can find the exact issue I surely can fix :)liampcollins commentedon Oct 22, 2024
Thanks for the response. Perhaps the order can make a difference but in the example I have it is using the leading class. I think the bug originates from an assumption in the code that
leading-normalrepresents1.5remwhen in fact it is 1.5 xfont-size