Skip to content

Commit de43e6f

Browse files
committed
[css-typed-om] Throw if any transforms use non-absolute units when generating a DOMMatrix. Fixes w3c#421.
1 parent 06bdb4d commit de43e6f

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

css-typed-om/Overview.bs

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1749,9 +1749,16 @@ is a [=list=] of {{CSSTransformComponent}}s.
17491749

17501750
2. [=list/For each=] |func| in |this|’s [=values to iterate over=]:
17511751

1752-
1. Set |matrix| to the result of multiplying |matrix|
1753-
and |func|’s equivalent 4x4 transform matrix.
1754-
2. If |func|’s {{CSSTransformComponent/is2D}} internal slot is `false`,
1752+
1. Let |funcMatrix| be |func|’s equivalent 4x4 transform matrix,
1753+
as defined in [[css-transforms-1#mathematical-description]].
1754+
1755+
As the entries of such a matrix are defined relative to the ''px'' unit,
1756+
if any <<length>>s in |func| involved in generating the matrix
1757+
are not [=compatible units=] with ''px'',
1758+
[=throw=] a {{TypeError}}.
1759+
2. Set |matrix| to the result of multiplying |matrix|
1760+
and |funcMatrix|.
1761+
3. If |func|’s {{CSSTransformComponent/is2D}} internal slot is `false`,
17551762
set |is2D| to `false`.
17561763

17571764
3. Return a new {{DOMMatrix}}

0 commit comments

Comments
 (0)