1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 21:07:36 +00:00

LibWeb: Add DOMMatrix string constructor and set matrix value

This commit is contained in:
Bastiaan van der Plaat 2024-01-06 18:05:21 +01:00 committed by Andreas Kling
parent 903d3c92c8
commit be7538961b
15 changed files with 336 additions and 120 deletions

View file

@ -40,5 +40,29 @@
// 10. Creating a DOMMatrix with fromFloat64Array wrong amount
testPart(() => DOMMatrix.fromFloat64Array(new Float64Array([10, 20, 30, 40])));
// 11. Creating a DOMMatrix with CSS transform string
testPart(() => new DOMMatrix('translate(10px, 10px)'));
// 12. Creating a DOMMatrix with CSS transform string
testPart(() => new DOMMatrix('scale(10) translate(10px, 10px)'));
// 13. Creating a DOMMatrix with CSS transform string
testPart(() => new DOMMatrix('scale(2)'));
// 14. Creating a DOMMatrix with CSS transform string
testPart(() => new DOMMatrix('rotate(20deg) translate(10px, 10px)'));
// 15. Creating a DOMMatrix with CSS transform string with error
testPart(() => new DOMMatrix('translate(2)'));
// 16. Creating a DOMMatrix with CSS transform string with error
testPart(() => new DOMMatrix('rotate(20)'));
// 17. Creating a DOMMatrix with CSS transform string with error
testPart(() => new DOMMatrix('rotate(20px)'));
// 18. Creating a DOMMatrix with CSS transform string with error
testPart(() => new DOMMatrix('matrix(1.0, 2.0deg, 3.0, 4.0, 5.0, 6.0)'));
});
</script>