Open
Bug 1299097
Opened 8 years ago
Updated 2 years ago
@counter-style lacking minimum required descriptors should still show up in the OM
Categories
(Core :: CSS Parsing and Computation, defect, P3)
Core
CSS Parsing and Computation
Tracking
()
NEW
Tracking | Status | |
---|---|---|
firefox51 | --- | affected |
People
(Reporter: sebo, Unassigned)
References
()
Details
If you create a style sheet containing an empty @counter-style rule, it is not available through the CSSStyleSheet.cssRules property in opposite to other at-rules.
I realized this when trying to fix https://github.com/LeaVerou/css3test/issues/149.
See the attached URL for a test case, where the console output is expected to look like this:
CSSRuleList [ CSSKeyframesRule, CSSCounterStyleRule, CSSCounterStyleRule ]
but what you see is this:
CSSRuleList [ CSSKeyframesRule, CSSCounterStyleRule ]
Sebastian
Comment 2•8 years ago
|
||
This was intentionally. The original CSS Counter Styles spec states that a @counter-style rule without "system" and some other descriptors is invalid, and thus should not be in the OM at all.
However, the CSSWG recently resolved in w3c/csswg-drafts#1133 to not ignore @font-face rule even when it lacks necessary descriptors, and thinks we should keep consistency on @counter-style rules as well, which means empty @counter-style rules should show up in the OM. It just shouldn't define a counter style.
Component: DOM: CSS Object Model → CSS Parsing and Computation
Flags: needinfo?(cam)
Summary: Empty @counter-style rules are ignored in CSSOM → @counter-style lacking minimum required descriptors should still show up in the OM
Updated•8 years ago
|
See Also: → https://github.com/w3c/csswg-drafts/issues/1682
Comment 3•7 years ago
|
||
The CSSWG did end up resolving to keep empty @counter-style in the OM, per the paragraph just below https://drafts.csswg.org/css-counter-styles/#typedef-symbol.
Priority: -- → P3
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•