mirror of
https://github.com/RGBCube/serenity
synced 2025-06-28 17:12:12 +00:00
LibWeb: Support CSSRule.type
We already had the CSSRule::Type enum, but the values were not aligned with the CSSOM spec. This patch takes care of that, and then exposes the type of a CSSRule to JavaScript via the "type" attribute.
This commit is contained in:
parent
a0ba49a50a
commit
f4f850aaf2
4 changed files with 19 additions and 13 deletions
|
@ -95,8 +95,6 @@ void CSSRuleList::for_each_effective_style_rule(Function<void(CSSStyleRule const
|
|||
case CSSRule::Type::Supports:
|
||||
static_cast<CSSSupportsRule const&>(rule).for_each_effective_style_rule(callback);
|
||||
break;
|
||||
case CSSRule::Type::__Count:
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -133,8 +131,6 @@ bool CSSRuleList::evaluate_media_queries(HTML::Window const& window)
|
|||
any_media_queries_changed_match_state = true;
|
||||
break;
|
||||
}
|
||||
case CSSRule::Type::__Count:
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue