- From: <bugzilla@jessica.w3.org>
- Date: Mon, 25 Mar 2013 19:26:15 +0000
- To: public-webapps-bugzilla@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=21390
Bug ID: 21390
Summary: [Shadow]: add support for styling shadowDOM contents
based on host element
Classification: Unclassified
Product: WebAppsWG
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P2
Component: Component Model
Assignee: dglazkov@chromium.org
Reporter: sorvell@chromium.org
QA Contact: public-webapps-bugzilla@w3.org
Blocks: 14978
It should be possible to style shadowDOM contents based on a selector the host
element matches.
In general, it is common to define a set of theme styles that apply if a given
ancestor selector matches. If nodes within a shadowDOM can be styled
conditionally based on the host element, then shadowDOM can easily support this
design pattern.
At a recent discussion, a ::shadow() pseudo-selector was proposed for this
purpose. It would be used in an @host rule as follows:
@host {
/* match .foo shadowDOM nodes inside host elements matching .bar */
.bar::shadow(.foo) {
...
}
}
The ::shadow() pseudo-selector should also support the :root pseudo-selector to
enable children selectors, for example:
@host {
/* match .foo shadowDOM children inside host elements matching .bar */
.bar::shadow(:root > .foo) {
...
}
}
--
You are receiving this mail because:
You are the QA Contact for the bug.
Received on Monday, 25 March 2013 19:26:17 UTC