Bug 79077

Summary: Add :scope pseudo-class
Product: WebKit Reporter: Roland Steiner <rolandsteiner>
Component: CSSAssignee: Roland Steiner <rolandsteiner>
Severity: Normal CC: bronislav.klucka, dglazkov, dominicc, koivisto, macpherson, menard, morrita, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 49142    
Description Flags
Patch none

Description Roland Steiner 2012-02-20 21:34:52 PST
Add :scope pseudo-class that only matches against the contextual reference element - see http://dev.w3.org/csswg/selectors4/#scope-pseudo.
Comment 1 Roland Steiner 2012-03-02 02:54:18 PST
Created attachment 129862 [details]
Comment 2 WebKit Review Bot 2012-03-02 06:26:31 PST
Comment on attachment 129862 [details]

Clearing flags on attachment: 129862

Committed r109573: <http://trac.webkit.org/changeset/109573>
Comment 3 WebKit Review Bot 2012-03-02 06:26:36 PST
All reviewed patches have been landed.  Closing bug.
Comment 4 Bronislav Klucka 2012-03-13 14:53:20 PDT

<ul id="templ"><li></li><li></li></ul>

running on yesterday nightly chromium (19.0.1068.0, 2012-03-12) and I'm having such results

returns empty set instead of set with one UL

document.getElementById('templ').querySelectorAll(':scope li');
returns set of LI (that is fine)

document.getElementById('templ').querySelectorAll(':scope > li');
returns empty set instead of set of LI
Comment 5 Roland Steiner 2012-03-13 19:06:52 PDT
(In reply to comment #4)

:scope is not yet implemented for querySelectorAll(), but it certainly should be! I opened bug 81069 for this.