Bug 248925
| Summary: | Sum & Product calculation node children should only get sorted for serialization | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Chris Dumez <cdumez> |
| Component: | CSS | Assignee: | Chris Dumez <cdumez> |
| Status: | RESOLVED FIXED | ||
| Severity: | Normal | CC: | webkit-bug-importer |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | |||
| Bug Blocks: | 175733 | ||
Chris Dumez
Sum & Product calculation node children should only get sorted for serialization, as per:
- https://drafts.csswg.org/css-values-4/#serialize-a-calculation-tree
- https://drafts.csswg.org/css-values-4/#sort-a-calculations-children
However, we were doing this eagerly after parsing the calculation value, during the simplification step:
- https://w3c.github.io/csswg-drafts/css-values/#calc-simplification
This is observable with CSS Typed OM since the following:
`CSSStyleValue.parse("width", "calc(1px + 1em)")` would get parsed as `new CSSMathSum(CSS.em(1), CSS.px(1))` instead of `new CSSMathSum(CSS.px(1), CSS.em(1))`
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Chris Dumez
Pull request: https://github.com/WebKit/WebKit/pull/7301
EWS
Committed 257573@main (e06fc205e555): <https://commits.webkit.org/257573@main>
Reviewed commits have been landed. Closing PR #7301 and removing active labels.
Radar WebKit Bug Importer
<rdar://problem/103136508>