Skip to content

Commit a643e79

Browse files
committed
Add the 'expandedSelectorText' property to the CSSStyleRule interface.
1 parent 5238dfb commit a643e79

2 files changed

Lines changed: 13 additions & 0 deletions

File tree

css3-hierarchies/Overview.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -405,6 +405,7 @@ <h2 id=cssom><span class=secno>4. </span> CSS Object Model Modifications</h2>
405405
<pre class=idl>
406406
interface CSSStyleRule : CSSRule {
407407
attribute DOMString selectorText;
408+
<ins>readonly attribute expandedSelectorText;</ins>
408409
<ins>readonly attribute CSSRuleList cssRules;</ins>
409410
readonly attribute CSSStyleDeclaration style;
410411
};</pre>
@@ -413,6 +414,15 @@ <h2 id=cssom><span class=secno>4. </span> CSS Object Model Modifications</h2>
413414
<code>CSSRuleList</code> object for the list of CSS rules specified within
414415
the style rule.
415416

417+
<p>The <code>expandedSelectorText</code> attribute must return a
418+
<code>DOMString</code> object containing the result of replacing the
419+
&lsquo;<code class=css>&amp;</code>&rsquo; selector in the
420+
<code>selectorText</code> attribute with the
421+
<code>expandedSelectorText</code> attribute from the parent rule. If the
422+
rule has no parent rule, the <code>expandedSelectorText</code> attribute
423+
must return a <code>DOMString</code> object containing the same text as
424+
the <code>selectorText</code> attribute.
425+
416426
<h2 id=conformance><span class=secno>5. </span> Conformance</h2>
417427

418428
<h3 id=conventions><span class=secno>5.1. </span> Document Conventions</h3>

css3-hierarchies/Overview.src.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,12 +278,15 @@ <h2 id="cssom">
278278
<pre class='idl'>
279279
interface CSSStyleRule : CSSRule {
280280
attribute DOMString selectorText;
281+
<ins>readonly attribute expandedSelectorText;</ins>
281282
<ins>readonly attribute CSSRuleList cssRules;</ins>
282283
readonly attribute CSSStyleDeclaration style;
283284
};</pre>
284285

285286
<p>The <code>cssRules</code> attribute must return a <code>CSSRuleList</code> object for the list of CSS rules specified within the style rule.</p>
286287

288+
<p>The <code>expandedSelectorText</code> attribute must return a <code>DOMString</code> object containing the result of replacing the ''&amp;'' selector in the <code>selectorText</code> attribute with the <code>expandedSelectorText</code> attribute from the parent rule. If the rule has no parent rule, the <code>expandedSelectorText</code> attribute must return a <code>DOMString</code> object containing the same text as the <code>selectorText</code> attribute.</p>
289+
287290
<h2 id="conformance">
288291
Conformance</h2>
289292

0 commit comments

Comments
 (0)