LibWeb: Don't include spread distance when serializing text-shadow

We shouldn't include spread distance when serializing `text-shadow` as
it is not supported unlike `box-shadow` - to achieve this we store
whether this is a text or box shadow within the ShadowStyleValue and
serialize appropriately.
This commit is contained in:
Callum Law 2025-09-15 20:52:20 +12:00 committed by Sam Atkins
commit c3a78d2884
Notes: github-actions[bot] 2025-09-18 14:23:44 +00:00
6 changed files with 27 additions and 23 deletions

View file

@ -2169,7 +2169,7 @@ RefPtr<StyleValue const> Parser::parse_single_shadow_value(TokenStream<Component
placement = ShadowPlacement::Outer;
transaction.commit();
return ShadowStyleValue::create(color, offset_x.release_nonnull(), offset_y.release_nonnull(), blur_radius, spread_distance, placement.release_value());
return ShadowStyleValue::create(shadow_type, color, offset_x.release_nonnull(), offset_y.release_nonnull(), blur_radius, spread_distance, placement.release_value());
}
RefPtr<StyleValue const> Parser::parse_rotate_value(TokenStream<ComponentValue>& tokens)