mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-24 09:52:31 +00:00
LibWeb: Generically serialize "positional-value-list-shorthand"s
We were previously handling this ad-hoc via logic in `get_property_internal` but this didn't cover all contexts (for instance `CSSStyleProperties::serialized`. Gains us 9 more WPT tests as we now cover properties which weren't included in the previous ad-hoc approach.
This commit is contained in:
parent
9ed85ddd63
commit
927cd969b2
Notes:
github-actions[bot]
2025-07-15 13:27:25 +00:00
Author: https://github.com/Calme1709
Commit: 927cd969b2
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5386
Reviewed-by: https://github.com/AtkinsSJ ✅
14 changed files with 234 additions and 115 deletions
|
@ -638,6 +638,8 @@ void StyleComputer::for_each_property_expanding_shorthands(PropertyID property_i
|
|||
return;
|
||||
}
|
||||
|
||||
// FIXME: We should add logic in parse_css_value to parse "positional-value-list-shorthand"s as
|
||||
// ShorthandStyleValues to avoid the need for this (and assign_start_and_end_values).
|
||||
auto assign_edge_values = [&](PropertyID top_property, PropertyID right_property, PropertyID bottom_property, PropertyID left_property, CSSStyleValue const& value) {
|
||||
if (value.is_value_list()) {
|
||||
auto values = value.as_value_list().values();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue