mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-22 09:21:57 -05:00
772be9dec0
The CSSOM spec tells us to potentially add up to three different IDL attributes to CSSStyleDeclaration for every CSS property we support: - A camelCased attribute, where a dash indicates the next character should be uppercase - A camelCased attribute for every -webkit- prefixed property, with the first letter always being lowercase - A dashed-attribute for every property with a dash in it. Additionally, every attribute must have the CEReactions and LegacyNullToEmptyString extended attributes specified on it. Since we specify every property we support with Properties.json, we can use that file to generate the IDL file and it's implementation. We import it from the Build directory with the help of multiple import base paths. Then, we add it to CSSStyleDeclaration via the mixin functionality and inheriting the generated class in CSSStyleDeclaration. (cherry picked from commit aacf9b08ed8c4286c84145b52fa70f399ed0bdff; amended to fix tiny conflict in libweb_generators.cmake, and to change the default value of all gap-related properties from 'auto' to 'normal' since serenity does not yet have LadybirdBrowser/ladybird#2253 and cherry-picking that has a pretty long dependency tree. It's easy to update the test once that is cherry-picked) |
||
---|---|---|
.. | ||
AddNewIDLFile.md | ||
BrowsingContextsAndNavigables.md | ||
classes.png | ||
CSSGeneratedFiles.md | ||
LibWebFromLoadingToPainting.md | ||
Patterns.md | ||
ProcessArchitecture.md | ||
processes.png |