mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-06 16:19:23 +00:00
LibWeb: Add basic implementation of @page
This doesn't support selectors, and the only descriptors for now are for margins.
This commit is contained in:
parent
1002464322
commit
aaf07ae30d
Notes:
github-actions[bot]
2025-05-15 08:54:53 +00:00
Author: https://github.com/AtkinsSJ
Commit: aaf07ae30d
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4735
27 changed files with 471 additions and 20 deletions
|
@ -27,6 +27,8 @@ RuleContext rule_context_type_for_rule(CSSRule::Type rule_type)
|
|||
return RuleContext::AtLayer;
|
||||
case CSSRule::Type::NestedDeclarations:
|
||||
return RuleContext::Style;
|
||||
case CSSRule::Type::Page:
|
||||
return RuleContext::AtPage;
|
||||
case CSSRule::Type::Property:
|
||||
return RuleContext::AtProperty;
|
||||
// Other types shouldn't be trying to create a context.
|
||||
|
@ -52,6 +54,8 @@ RuleContext rule_context_type_for_at_rule(FlyString const& name)
|
|||
return RuleContext::AtLayer;
|
||||
if (name == "property")
|
||||
return RuleContext::AtProperty;
|
||||
if (name == "page")
|
||||
return RuleContext::AtPage;
|
||||
return RuleContext::Unknown;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue