mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-08 06:09:58 +00:00
LibWeb: Dont try to transition custom properties
Fixes a crash introduced in dd9d6d2
This commit is contained in:
parent
8fa081cb1d
commit
cfc22a4075
Notes:
github-actions[bot]
2025-11-11 07:54:45 +00:00
Author: https://github.com/Calme1709
Commit: cfc22a4075
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6783
Reviewed-by: https://github.com/tcl3 ✅
2 changed files with 18 additions and 1 deletions
|
|
@ -1322,7 +1322,7 @@ static void compute_transitioned_properties(ComputedProperties const& style, DOM
|
||||||
auto const append_property_mapping_logical_aliases = [&](PropertyID property_id) {
|
auto const append_property_mapping_logical_aliases = [&](PropertyID property_id) {
|
||||||
if (property_is_logical_alias(property_id))
|
if (property_is_logical_alias(property_id))
|
||||||
properties_for_this_transition.append(map_logical_alias_to_physical_property(property_id, LogicalAliasMappingContext { style.writing_mode(), style.direction() }));
|
properties_for_this_transition.append(map_logical_alias_to_physical_property(property_id, LogicalAliasMappingContext { style.writing_mode(), style.direction() }));
|
||||||
else
|
else if (property_id != PropertyID::Custom)
|
||||||
properties_for_this_transition.append(property_id);
|
properties_for_this_transition.append(property_id);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
17
Tests/LibWeb/Crash/CSS/transitioned-custom-property.html
Normal file
17
Tests/LibWeb/Crash/CSS/transitioned-custom-property.html
Normal file
|
|
@ -0,0 +1,17 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<style>
|
||||||
|
#foo {
|
||||||
|
--bar: 10px;
|
||||||
|
transition: --bar 1s linear;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<div id="foo"></div>
|
||||||
|
<script>
|
||||||
|
requestAnimationFrame(() => {
|
||||||
|
requestAnimationFrame(() => {
|
||||||
|
foo.style = "--bar: 100px";
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</html>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue