1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 06:07:34 +00:00

LibWeb: Add Formatter for ComponentValues

This commit is contained in:
Sam Atkins 2022-04-12 12:30:48 +01:00 committed by Andreas Kling
parent fff2c35f51
commit d2b8686ae4

View file

@ -44,3 +44,11 @@ private:
Variant<Token, NonnullRefPtr<StyleFunctionRule>, NonnullRefPtr<StyleBlockRule>> m_value;
};
}
template<>
struct AK::Formatter<Web::CSS::Parser::ComponentValue> : Formatter<StringView> {
ErrorOr<void> format(FormatBuilder& builder, Web::CSS::Parser::ComponentValue const& component_value)
{
return Formatter<StringView>::format(builder, component_value.to_string());
}
};