@@ -1397,10 +1397,14 @@ is a [=list=] of {{CSSTransformComponent}}s.
1397
1397
attribute CSSNumericValue length;
1398
1398
};
1399
1399
1400
- [Constructor(DOMMatrixReadOnly matrix)]
1400
+ [Constructor(DOMMatrixReadOnly matrix, optional CSSMatrixComponentOptions options )]
1401
1401
interface CSSMatrixComponent : CSSTransformComponent {
1402
1402
attribute DOMMatrix matrix;
1403
1403
};
1404
+
1405
+ dictionary CSSMatrixComponentOptions {
1406
+ boolean is2D;
1407
+ };
1404
1408
</xmp>
1405
1409
1406
1410
<div algorithm="CSSTransformComponent.is2D">
@@ -1574,7 +1578,26 @@ is a [=list=] of {{CSSTransformComponent}}s.
1574
1578
Note: ''perspective()'' functions always represent 3D transforms.
1575
1579
</div>
1576
1580
1577
- Issue(366): Figure out how to define 2d vs 3d matrix.
1581
+ <div algorithm="CSSMatrixComponent()">
1582
+ The <dfn constructor for=CSSMatrixComponent>CSSMatrixComponent(|matrix|, |options|)</dfn> constructor must,
1583
+ when invoked,
1584
+ perform the following steps:
1585
+
1586
+ 1. Let |this| be a new {{CSSMatrixComponent}} object
1587
+ with its {{CSSMatrixComponent/matrix}} internal slot
1588
+ set to |matrix|.
1589
+
1590
+ 2. If |options| was passed
1591
+ and has a {{CSSMatrixComponentOptions}} field,
1592
+ set |this|’s {{CSSTransformValue/is2D}} internal slot
1593
+ to the value of that field.
1594
+
1595
+ 3. Otherwise,
1596
+ set |this|’s {{CSSTransformValue/is2D}} internal slot
1597
+ to the value of |matrix|’s {{DOMMatrixReadOnly/is2D}} internal slot.
1598
+
1599
+ 4. Return |this|.
1600
+ </div>
1578
1601
1579
1602
<div class=note>
1580
1603
Each {{CSSTransformComponent}} can correspond to
0 commit comments