LibWeb: Return unanimated font-size in ComputedProperties::font_size()

1a3da3d introduced a crash as we assumed that font-size values were
always stored in their computed forms, this isn't correct for animated
font-size values.

As a temporary workaround until we store animated font-sizes in their
computed form we will return the non-animated value - this restores the
functionality prior to 1a3da3d
This commit is contained in:
Callum Law 2025-08-27 23:13:34 +12:00 committed by Sam Atkins
commit 39dc604642
Notes: github-actions[bot] 2025-09-01 11:30:22 +00:00

View file

@ -2052,7 +2052,8 @@ WillChange ComputedProperties::will_change() const
CSSPixels ComputedProperties::font_size() const CSSPixels ComputedProperties::font_size() const
{ {
return property(PropertyID::FontSize).as_length().length().absolute_length_to_px(); // FIXME: Respect animated font-size here once we store it in computed form
return property(PropertyID::FontSize, WithAnimationsApplied::No).as_length().length().absolute_length_to_px();
} }
} }