jQuery Transit support for font-size property

78 Views Asked by At

I can't seem to get this plugin to transition the css property 'font-size'. I get an 'unexpected token -' error whenever I try to run it. Any thoughts? Is this property not supported by Transit?

2

There are 2 best solutions below

0
cracker On

You may want to try using

'scale(x)'

I personally have had problems transitioning font-size with jquery/javascript, and scale works great.

0
Diego Cerdan Puyol On

It should work like this:

    elem.transition({
        height: new_height,
        width: new_width,
        fontSize: "100px"
    });

You probably wrote font-size instead of fontSize. Or forgot to declare font-size in the CSS file.