Streaming live at 10am (PST)

Viewport Text Fluid custom


#1

So I find this site, which can calculate the code for you. I would like my paragraph font-size goes from 12px (viewport 1024px) to 21px (viewport 2560px).

https://websemantics.uk/tools/responsive-font-calculator/

Any idea how I embed this code to webflow so it only works at my body text?

It generate the css like this:

/* 12px @ 1024px increasing to 21px @ 2560px /
@media (min-width: 1024px) {
:root {
font-size: calc(0.75rem + ((1vw - 10.24px) * 0.5859));
/
Where: * 0.5859 = 100 * font_Size_Difference / viewport_Width_Difference /
}
}
/
Prevent font scaling beyond this breakpoint */
@media (min-width: 2560px) {
:root {
font-size: 21px;
}
}