@@ -1133,24 +1133,27 @@ must return the result of
11331133invoking [=insert a CSS rule=] <var> rule</var>
11341134into the [=CSSRule/child CSS rules=] at <var> index</var> .
11351135
1136+
11361137The <dfn method for=CSSStyleRule>deleteRule(<var>index</var>)</dfn> method
11371138must [=remove a CSS rule=] from the [=CSSRule/child CSS rules=] at <var> index</var> .
11381139
11391140Note: Serialization of {{CSSStyleRule}} with nested rules
11401141are already well-defined by [[CSSOM]] ,
11411142via [=serialize a CSS rule=] .
11421143
1143- <div class=issue>
1144- Whether we attach .cssRules to CSSStyleRule,
1145- as described here,
1146- or to CSSStyleDeclaration
1147- (to be consistent with future work
1148- allowing `style` attributes to have nested rules)
1149- is still an open question.
1150-
1151- Also, attaching it to .style
1152- means existing code setting <code> rule.style=""</code>
1153- and expecting
1154-
1155- (<a href="https://github.com/w3c/csswg-drafts/issues/7850">Issue 7850</a> )
1156- </div>
1144+ Note: The restriction on what a [=nested style rule's=]
1145+ selector can start with
1146+ counts as a "constraint imposed by CSS"
1147+ in step 5 of [=insert a CSS rule=]
1148+ (when invoked by anything that takes [=nested style rules=] ,
1149+ not just {{CSSStyleRule}} itself).
1150+
1151+ When setting {{CSSStyleRule/selectorText}} ,
1152+ if the {{CSSStyleRule}} is a [=nested style rule=] ,
1153+ and the returned group of selectors
1154+ starts with a selector
1155+ that starts with an ident or function token,
1156+ do nothing and return.
1157+
1158+ Issue: The above paragraph will be inlined into the CSSOM algo,
1159+ rather than monkey-patched.
0 commit comments