Sam Atkins
5534ed6715
LibWeb/CSS: Use generated code to convert between dimension units
2025-09-11 17:06:44 +01:00
Sam Atkins
b3e32445d3
LibWeb/CSS: Use generated FooUnit types instead of Foo::Type
...
I've also renamed the `m_type` and `type()` members to be `m_unit` and
`unit()` instead, to match what they actually are.
2025-09-11 17:06:44 +01:00
Sam Atkins
682e080d57
LibWeb/CSS: Use serialize_a_number() for Resolution serialization
...
As noted, the spec tells us to do something different than what is
expected by WPT, so we slightly ignore it.
2025-08-18 16:52:39 +01:00
Sam Atkins
338282f74d
LibWeb/CSS: Treat x resolution unit separately from dppx
...
Tests show that we need to preserve whether x or dppx units were used,
so the simplest way is to treat them separately.
2025-05-17 07:53:24 +01:00
Sam Atkins
443f9e5afb
LibWeb/CSS: Make dimension types serialize in resolved form
...
Some dimensions would always serialize in a canonical unit, others never
did, and others we manually would do so in their StyleValue. This
commit moves all of that into the dimension types, which means for
example that Length can apply its special rounding.
Our local serialization test now produces the same output as other
browsers. :^)
2025-05-17 07:53:24 +01:00
Timothy Flynn
93712b24bf
Everywhere: Hoist the Libraries folder to the top-level
2024-11-10 12:50:45 +01:00