Repository navigation
Conversation
|
@FremyCompany Can you review? Unless I'm missing something obvious, I can't see why the other serialization would be correct per the spec. |
drott
left a comment
There was a problem hiding this comment.
was opposite to the specified order.
Can you add a spec reference to the commit msg explaining the serialization order?
| valueParserTests.forEach(function (testCase) { | ||
| test(() => { | ||
| var element = document.getElementById("value-parser-test"); | ||
| element.style.fontVariationSettings = ""; |
There was a problem hiding this comment.
The last two failures in https://crbug.com/809950 were not actual failures -- they failed because the last test failed (leading to no resetting of font-variation-settings). Since they were invalid parsing tests, they relied on font-variation-settings not being set prior to the test. While the first commit fixes the test for Chrome, this would fix it for other browsers which might run into the same problem where one test fails immediately before an invalid parsing test.
There was a problem hiding this comment.
Thanks for the clarification and finding that out. Perhaps it's useful adding a comment here, like: "Reset to empty in order to allow testing to continue in case of parse errors occuring for the next test value."
There was a problem hiding this comment.
Good suggestion, I added that.
The expected computed valid of two font variation settings tests was opposite to the specified order (and per https://drafts.csswg.org/css-fonts-4/#propdef-font-variation-settings, the computed value is "as specified"). Reverse the two axis in order to match the specified order.
464fd82 to
8df67e7
Compare
This caused some tests to fail before the first commit simply due to font-variation-settings having already been set when the value shouldn't have been parsed.
8df67e7 to
1aa52b3
Compare
drott
left a comment
There was a problem hiding this comment.
Thanks for the quick changes, LGTM.
|
@drott Could you also merge this? I unfortunately do not have write access to the repo. |
|
@csnardi feel free to reach to me if you need to get something merged. I cannot grant you access, but I sure can merge your patches. Thanks for all the work you do! |
|
@emilio Thank you, will do! :) |
|
I think the spec should be updated, because the serialization of the property is not "as specified". I just took a look at the exact text we introduced:
and I agree it doesn't say you should reorder the axis names, so I'm fine with the change. |
|
@FremyCompany In the property definition box, it does say "Computed value: as specified", so I believe that would apply? |
The expected computed valid of two font variation settings tests was opposite to the specified order (and per https://drafts.csswg.org/css-fonts-4/#propdef-font-variation-settings, the computed value is "as specified"). Reverse the two axis in order to match the specified order.