Re: [fxtf-drafts] [css-transforms-2] How to serialize `scale` if we only use one number?

> Suppose we are animating `scale` from "2 1" to "2 3". At the animation midpoint, should the `getComputedStyle()` output have a discontinuity with "2" instead of "2 2" ? I suggest not. Similarly, I would suggest that changing the specified value from "2" to "2 2" should not trigger a transition. Therefore I would suggest that `getComputedStyle()` always return two numbers (or three if we have a 3D scale).

Yes, I don't think it makes sense for "2" and "2 2" to be different values either in the specified or computed value space.

> For the specified value, I would suggest avoiding discontinuities by returning exactly as many numbers as were supplied. Thus my suggestion is "2" stays "2" and "2 2" stays "2 2".

I don't think discontinuities in the animated (computed) value are impacted by how we decide to serialize the specified value.

In any case, these arguments seem applicable to any property that supports continuous interpolation and has optional/implied values in it, but it's at odds with the current guidelines in CSSOM.  I would rather update those guidelines if we want to avoid discontinuities while animating, rather than deciding just for scale/translate.

-- 
GitHub Notification of comment by heycam
Please view or discuss this issue at https://github.com/w3c/fxtf-drafts/issues/313#issuecomment-435562857 using your GitHub account

Received on Saturday, 3 November 2018 05:44:35 UTC