[Webkit-unassigned] [Bug 201637] New: WebKit incorrectly ignores percentages during calc() serialization
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Sep 10 03:42:23 PDT 2019
https://bugs.webkit.org/show_bug.cgi?id=201637
Bug ID: 201637
Summary: WebKit incorrectly ignores percentages during calc()
serialization
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: CSS
Assignee: webkit-unassigned at lists.webkit.org
Reporter: emilio at crisal.io
Chrome also has this bug, see https://bugs.chromium.org/p/chromium/issues/detail?id=1002430
1. Open data:text/html,<div style="background-position: calc(0% + 0px) calc(0% + 0px)"></div>
2. Run on the terminal: getComputedStyle(document.querySelector("div")).backgroundPosition
Expected: calc(0% + 0px) calc(0% + 0px)
Actual: 0px 0px
Per https://drafts.csswg.org/css-values-4/#calc-computed-value:
> Where percentages are not resolved at computed-value time, they are not resolved in math functions, e.g. calc(100% - 100% + 1px) resolves to calc(0% + 1px), not to 1px. If there are special rules for computing percentages in a value (e.g. the height property), they apply whenever a math function contains percentages.
See also https://github.com/w3c/csswg-drafts/issues/3482, and https://bugzilla.mozilla.org/show_bug.cgi?id=1574913 which is where this came up.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190910/da3bfdfd/attachment.html>
More information about the webkit-unassigned
mailing list