- From: Emilio Cobos Álvarez via GitHub <sysbot+gh@w3.org>
- Date: Mon, 26 Jun 2023 17:44:13 +0000
- To: public-houdini-archive@w3.org
emilio has just created a new issue for https://github.com/w3c/css-houdini-drafts: == [css-properties-values-api] Rule validity doesn't match implementations == Implementations and tests blatantly disagree with the spec even in simple cases. https://drafts.css-houdini.org/css-properties-values-api-1/#the-syntax-descriptor says: > The [syntax](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-syntax) descriptor is required for the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule to be valid; if it’s missing, the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule is invalid. https://drafts.css-houdini.org/css-properties-values-api-1/#inherits-descriptor: > The [inherits](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-inherits) descriptor is required for the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule to be valid; if it’s missing, the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule is invalid. https://drafts.css-houdini.org/css-properties-values-api-1/#initial-value-descriptor: > If the value of the [syntax](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-syntax) descriptor is the [universal syntax definition](https://drafts.css-houdini.org/css-properties-values-api-1/#universal-syntax-definition), then the [initial-value](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-initial-value) descriptor is optional. If omitted, the [initial value](https://drafts.csswg.org/css-cascade-5/#initial-value) of the property is the [guaranteed-invalid value](https://drafts.csswg.org/css-variables-2/#guaranteed-invalid-value). > > Otherwise, if the value of the [syntax](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-syntax) descriptor is not the [universal syntax definition](https://drafts.css-houdini.org/css-properties-values-api-1/#universal-syntax-definition), the following conditions must be met for the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule to be valid: > > * The [initial-value](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-initial-value) descriptor must be present. > * The [initial-value](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-initial-value) descriptor’s value must [parse successfully](https://drafts.css-houdini.org/css-properties-values-api-1/#consume-a-syntax-definition) according to the grammar specified by the [syntax definition](https://drafts.css-houdini.org/css-properties-values-api-1/#syntax-definition). > * The [initial-value](https://drafts.css-houdini.org/css-properties-values-api-1/#descdef-property-initial-value) must be [computationally independent](https://drafts.css-houdini.org/css-properties-values-api-1/#computationally-independent). > > If the above conditions are not met, the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule is invalid. Yet both Blink (and WebKit probably by copying whatever Blink implemented) disagree with it in trivial cases. E.g. [this](https://www.software.hixie.ch/utilities/js/live-dom-viewer/saved/11822) logs 0 per spec, but `1` in WebKit and Blink. This is annoying because this affects a lot of interop 2023 tests. We have a implementation of this and as I was reviewing this to potentially enable it I found that all the tests are just broken. Am I missing something? "rule is invalid" only has one meaning in my book, which is that the whole rule should be dropped, just like an `@font-face` and the > Unknown descriptors are invalid and ignored, but do not invalidate the [@property](https://drafts.css-houdini.org/css-properties-values-api-1/#at-ruledef-property) rule. Makes me think that the spec agrees with my interpretation on what "validity" means here. I _think_ this is ultimately a spec bug, as in https://github.com/w3c/csswg-drafts/issues/1682 it was decided to be consistent for `@counter-style` and `@font-face`. cc @tabatkins @lilles @andruud Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/1098 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 26 June 2023 17:44:15 UTC