Closed
Description
This would allow actually resetting all properties to what they were before some arbitrary CSS was applied, e.g. in a subtree:
/* bunch of CSS here */
#vendor-controlled-section {
&, *, *::before, *::after {
all: unset; /* all `div`s in this section will be inline! 😱 */
}
}
A couple ideas for the syntax:
- Make
unset
a function that accepts which value to use for non-inherited properties;unset
would default tounset(initial)
but the above would useunset(revert)
. Maybe there's even a use case forunset(revert-layer)
? 🤔 - Add a new value named
unset-revert
. - Add a new value named
reset
. Would that be confusing / unclear what the difference is withunset
? - Add two new values named
revert-or-inherit
andinitial-or-inherit
, and makeunset
an alias for the latter.