Re: [csswg-drafts] [css-pseudo] Define ::backdrop (#7845)

> Each element in the top layer has a ::backdrop pseudo-element, for which it is the originating element.

Just to clarify, this means there is no way whatsoever to reveal a box’s backdrop unless the originating element is in the top layer. 

I’d find this more generic UA default stylesheet interesting:

~~~~ css
::backdrop {
  display: none;
}
:fullscreen::backdrop {
  display: block;
}
~~~~

On the other hand, I’m wondering whether the use case for this pseudo-element couldn‘t have been covered by something like `background-origin: viewport`. 

On the third hand, I would have preferred if backgrounds had been done with pseudo-elements and the `fill` or the `content` property from the start. 

~~~~ css
foo::background(0) {
  content: url("bg.img");
  fill: navy;
}
~~~~

-- 
GitHub Notification of comment by Crissov
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7845#issuecomment-1495393912 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 4 April 2023 05:57:48 UTC