[Bug 28591] [Shadow]: Figure out a good replacement for /deep/ in testing scenarios

https://www.w3.org/Bugs/Public/show_bug.cgi?id=28591

Tab Atkins Jr. <jackalmage@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jackalmage@gmail.com

--- Comment #5 from Tab Atkins Jr. <jackalmage@gmail.com> ---
(In reply to Elliott Sprehn from comment #4)
> (In reply to Anne from comment #3)
> > Note that an alternative is that we introduce .deepQuery() or some such.
> 
> deepQuery is not enough, you don't want to match a descendant selector
> across a ShadowRoot boundary since ".a .b" means something really different.
> You'd still need a special combinator to signal where the scope crossing
> should be in the selector expression.
> 
> ex.
> .panel .image
> 
> All images inside panels contained in a single scope.
> 
> .panel /deep/ .image
> 
> All images anywhere below a panel, even if they're inside a nested widget.
> 
> This is important because it maintains the "don't accidentally cross a
> boundary" principle.

Yeah, trying to move the shadow-crossing quality to the core of the method
doesn't work.  It's much less flexible, as you note, and doesn't compose with
anything else similar.  The correct approach is to just embrace the "static
profile" of selectors <http://dev.w3.org/csswg/selectors/#static-profile> and
leave /deep/ there.  (Or >>>, as it's now called.)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Tuesday, 5 May 2015 00:12:18 UTC