[fxtf-drafts] [css-transforms-2] Serialize `scale` if we only use one number

BorisChiou has just created a new issue for https://github.com/w3c/fxtf-drafts:

== [css-transforms-2] Serialize `scale` if we only use one number ==
The spec, [css-transforms-2] doesn't mention how to serialize the individual transforms. This may be fine but still not clear to me for the case:
```
div { 
  scale: 2;
}
console.log(window.getComputedStyle(div).scale); // serialize as "2" or "2 2"?
```
If only the X value is given, the Y value defaults to the same value, and If one or two values are given, this specifies a 2d scaling, equivalent to the `scale()` function (i.e. scale(2, 2) in the above example). However, should we serialize it as "2" or "2 2"? For now, Chrome serializes this as "2 2", but Firefox serializes this as "2", so I think this is an ambiguous part. Maybe the shorter one is preferred?

[1] https://drafts.csswg.org/css-transforms-2/#propdef-rotate


Please view or discuss this issue at https://github.com/w3c/fxtf-drafts/issues/313 using your GitHub account

Received on Friday, 2 November 2018 20:36:41 UTC