1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-25 15:45:08 +00:00

LibWeb: Generate property_initial_value() function from Properties.json

Since we have initial-value data in Properties.json already, it makes
sense to use that instead of needing to duplicate the same information
in ComputedValues.h

However, converting a StyleValue to the kind of types used in
InitialValues is non-trivial. So this may or may not actually be useful.
This commit is contained in:
Sam Atkins 2021-08-16 17:42:09 +01:00 committed by Andreas Kling
parent 38ee69adfa
commit 8995839e3f
2 changed files with 34 additions and 0 deletions

View file

@ -47,6 +47,7 @@ int main(int argc, char** argv)
#include <AK/StringView.h>
#include <AK/Traits.h>
#include <LibWeb/Forward.h>
namespace Web::CSS {
@ -73,6 +74,7 @@ PropertyID property_id_from_string(const StringView&);
const char* string_from_property_id(PropertyID);
bool is_inherited_property(PropertyID);
bool is_pseudo_property(PropertyID);
RefPtr<StyleValue> property_initial_value(PropertyID);
} // namespace Web::CSS