diff options
author | Sam Atkins <atkinssj@serenityos.org> | 2021-12-03 12:32:12 +0000 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-12-09 21:30:31 +0100 |
commit | 23dc0dac88a248d4ac9b1be36212d065c7112629 (patch) | |
tree | f6757d6b2d52cc4770e49c37c520071a5c16e865 /Documentation/Patterns.md | |
parent | 000fb5a70d0a7683d232cdec90884224931a12c2 (diff) | |
download | serenity-23dc0dac88a248d4ac9b1be36212d065c7112629.zip |
LibWeb: Parse and resolve UnresolvedStyleValues
If a property is custom or contains a `var()` reference, it cannot be
parsed into a proper StyleValue immediately, so we store it as an
UnresolvedStyleValue until the property is compute. Then, at compute
time, we resolve them by expanding out any `var()` references, and
parsing the result.
The implementation here is very naive, and involves copying the
UnresolvedStyleValue's tree of StyleComponentValueRules while copying
the contents of any `var()`s it finds along the way. This is quite an
expensive operation to do every time that the style is computed.
Diffstat (limited to 'Documentation/Patterns.md')
0 files changed, 0 insertions, 0 deletions