mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 19:04:58 +00:00
When mixing calc() and var(), we're forced to delay resolving them until we're in StyleComputer. Previously we'd just skip over them. This patch handles calc() in the same pass as attr(). We reparse the calc() value after var() expansion, and then try to resolve it to a constant value if possible. If it's not possible, we leave the calc() where it is, and maybe layout can figure it out later. Note that I've only implemented resolution to integer and percentage in this commit. There are more things a calc() could resolve to, and we should implement those as well.
63 KiB
63 KiB