W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2015

Re: Shadow tree style isolation primitive

From: Ryosuke Niwa <rniwa@apple.com>
Date: Mon, 12 Jan 2015 17:59:37 -0800
Cc: Anne van Kesteren <annevk@annevk.nl>, "www-style@w3.org" <www-style@w3.org>, WebApps WG <public-webapps@w3.org>
Message-id: <9DBF42DF-A821-445F-9835-F74BD5A8A3D2@apple.com>
To: "Tab Atkins Jr." <jackalmage@gmail.com>

> On Jan 12, 2015, at 5:41 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
> 
> [ryosuke, your mail client keeps producing flattened replies. maybe
> send as plain-text, not HTML?]

Weird.  I'm not seeing that at all on my end.

> The style defined for <bar> *in <bar>'s setup code* (that is, in a
> <style> contained inside <bar>'s shadow tree) works automatically
> without you having to care about what <bar> is doing.  <bar> is like a
> replaced element - it has its own rendering, and you can generally
> just leave it alone to do its thing.

If that's the behavior we want, then we should simply make @isolate pierce through isolates.  You previously mentioned that:

> On Jan 12, 2015, at 1:28 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
> Alternately, say that it does work - the @isolate selector pierces
> through isolation boundaries.  Then you're still screwed, because if
> the outer page wants to isolate .example blocks, but within your
> component you use .example normally, without any isolation, whoops!
> Suddenly your .example blocks are isolated, too, and getting weird
> styles applied to them, while your own styles break since they can't
> cross the unexpected boundary.


But this same problem seems to exist in shadow DOM as well.  We can't have a <bar> inside a <foo> behave differently from ones outside <foo> since all bar elements share the same implementation.  I agree 

- R. Niwa
Received on Tuesday, 13 January 2015 02:00:14 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:27:25 UTC