RESOLVED FIXED184256
CSSOM test for serializing counter() fails
https://bugs.webkit.org/show_bug.cgi?id=184256
Summary CSSOM test for serializing counter() fails
Simon Pieters (:zcorpan)
Reported 2018-04-03 02:26:49 PDT
See: https://github.com/w3c/csswg-drafts/issues/670#issuecomment-366329393 Relevant part of the spec: https://drafts.csswg.org/cssom/#serialize-a-css-component-value > Let list be a list of CSS component values belonging to <counter>, omitting the last CSS component value if it is "decimal". Test: http://w3c-test.org/css/cssom/serialize-values.html (search for "counter") > Fail content: counter(par-num) assert_equals: content raw inline style declaration expected "counter(par-num)" but got "counter(par-num, decimal)" This test passes in Chromium canary and Firefox Nightly. It fails in WebKit TP and EdgeHTML 16 (tested in browserstack).
Attachments
Patch (3.45 KB, patch)
2021-06-08 02:11 PDT, Rob Buis
no flags
Patch (9.42 KB, patch)
2021-06-08 04:09 PDT, Rob Buis
no flags
Patch (8.62 KB, patch)
2021-06-08 04:40 PDT, Rob Buis
no flags
Patch (8.61 KB, patch)
2021-06-08 12:50 PDT, Rob Buis
ews-feeder: commit-queue-
Patch (8.61 KB, patch)
2021-06-08 13:06 PDT, Rob Buis
no flags
Radar WebKit Bug Importer
Comment 1 2018-06-13 21:32:35 PDT
Rob Buis
Comment 2 2021-06-08 02:11:08 PDT
Rob Buis
Comment 3 2021-06-08 04:09:12 PDT
Rob Buis
Comment 4 2021-06-08 04:40:10 PDT
Sam Weinig
Comment 5 2021-06-08 10:29:18 PDT
Comment on attachment 430830 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=430830&action=review > Source/WebCore/css/CSSPrimitiveValue.cpp:1085 > + if (listStyle == "decimal") > + listStyle = emptyString(); > result.append(listStyle.isEmpty() ? "" : ", ", listStyle, ')'); This seems like it would be a bit cleaner as: if (!(listStyle.empty() || listStyle == "decimal")) result.append(", ", listStyle); result.append(')'); (or something like that).
Rob Buis
Comment 6 2021-06-08 12:50:19 PDT
Rob Buis
Comment 7 2021-06-08 13:06:52 PDT
EWS
Comment 8 2021-06-08 22:07:33 PDT
Committed r278648 (238630@main): <https://commits.webkit.org/238630@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 430881 [details].
Note You need to log in before you can comment on or make changes to this bug.