Intent to prototype: CSS cascade layers (@layer at-rule)

76 views
Skip to first unread message

Emilio Cobos Álvarez

unread,
Sep 1, 2021, 2:28:04 PM9/1/21
to Mozilla
Summary / Standard: https://drafts.csswg.org/css-cascade-5/#layering

Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1699215

Platform coverage: all

Preference: layout.css.cascade-layers.enabled

DevTools bug: We need to look into whether devtools will work as is or
new stuff needs to be exposed. In particular, rule sorting is done by
Gecko so that should just work, but it might be worth providing UI to
know why a rule takes priority over another.

Other browsers: Both Chromium and WebKit are prototyping, this should
allow us to inform and evolve the spec.

web-platform-tests: This will be fully covered by WPT (though not many
tests exist just yet).

-- Emilio

Emilio Cobos Álvarez

unread,
Dec 17, 2021, 5:24:33 PM12/17/21
to Mozilla
Hi,

Since I sent the intent to prototype (below), there's been a bunch of
spec work and discussion, lots of tests written, and I think we have a
fairly complete implementation.

Tests for this are in https://wpt.fyi/results/css/css-cascade, and there
are only two categories of tests we fail (once the tests get updated for
the patches that landed today):

* Tests that test stuff that we don't implement or enable by default
(like constructable stylesheets / @property).

* Tests for one animation edge case that we fail for the regular
`revert` keyword as well and which we've shipped for a long while.

So if all goes well, I want to enable this feature by default for
Firefox 97. Let me know if there's any concern with that.

Cheers,

-- Emilio
Reply all
Reply to author
Forward
0 new messages