mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Implement :-moz-any() as an alias of :is().
This is strictly better and more flexible, but can change specificity so have a pref in case it causes trouble. I doubt it will though, the specificity rules of :is() make more sense, and my gut feeling is that :-moz-any is not very used on the wild. Make it early-beta-or-earlier for now to minimize risk, once this is on nightly for a bit we can enable it everywhere. Differential Revision: https://phabricator.services.mozilla.com/D86696
This commit is contained in:
parent
2167a0c099
commit
73a9c57c3b
1 changed files with 6 additions and 0 deletions
|
@ -352,6 +352,12 @@ impl<'a, 'i> ::selectors::Parser<'i> for SelectorParser<'a> {
|
|||
true
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn is_is_alias(&self, function: &str) -> bool {
|
||||
static_prefs::pref!("layout.css.moz-any-is-is.enabled") &&
|
||||
function.eq_ignore_ascii_case("-moz-any")
|
||||
}
|
||||
|
||||
fn parse_non_ts_pseudo_class(
|
||||
&self,
|
||||
location: SourceLocation,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue