Re: [w3c/webcomponents] Shadow tree encapsulation and CSS (#804)

I don't think that :picture-in-picture, :fullscreen or :focus should automatically apply to the shadow host chain. Would be good to discuss this at the F2F next week also.

Thoughts about why:

* :focus doesn't do that (instead there is a delegatesFocus shadow root attribute to opt into this behavior)
* it doesn't make sense for :fullscreen either because of the injected stylesheet issue Emilio mentioned
* activeElement already can be present even if no element in the current document has :focus, so having that true for pictureInPictureElement or fullscreenElement is no "worse"
* Retargeting violates the principle that shadow roots should try to have observable-implementation and performance encapsulation

For :picture-in-picture specifically, I can think of:

* It could be unexpected (and is not controllable) for some developers to have retargeting result in styling of multiple contained shadow hosts that have different stylesheet contexts


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/804#issuecomment-484176225

Received on Wednesday, 17 April 2019 17:02:03 UTC