mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-17 07:50:04 +00:00
LibWeb: Handle calculations without a context better
This commit is contained in:
parent
c0beacbb76
commit
4408ea7c9b
Notes:
github-actions[bot]
2024-10-16 14:40:42 +00:00
Author: https://github.com/stelar7
Commit: 4408ea7c9b
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1827
4 changed files with 41 additions and 3 deletions
15
Tests/LibWeb/Text/input/css/calc-missing-context.html
Normal file
15
Tests/LibWeb/Text/input/css/calc-missing-context.html
Normal file
|
@ -0,0 +1,15 @@
|
|||
<script src="../include.js"></script>
|
||||
<script>
|
||||
test(() => {
|
||||
const testElement = document.getElementById('target');
|
||||
testElement.style = "";
|
||||
|
||||
testElement.style.transform = 'rotate(atan2(1rem, -1rem))';
|
||||
|
||||
getComputedStyle(testElement).transform;
|
||||
|
||||
println("NO CRASH");
|
||||
|
||||
});
|
||||
</script>
|
||||
<div id="target"></div>
|
Loading…
Add table
Add a link
Reference in a new issue