CSS variable, #30000ee is read as #\30 000ee
Reported by
cyril.au...@gmail.com,
Jun 6 2016
|
||||||||||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2756.0 Safari/537.36 Example URL: Steps to reproduce the problem: 1. https://jsfiddle.net/crl/e1z3Lvc0/13/ 2. open console 3. What is the expected behavior? #30000ee What went wrong? #\30 000ee Does it occur on multiple sites: N/A Is it a problem with a plugin? N/A Did this work before? N/A Does this work in other browsers? Yes Chrome version: 53.0.2756.0 Channel: dev OS Version: 10.0 Flash Version: Shockwave Flash 22.0 r0
,
Jun 7 2016
> CSS.escape("0000ee")
"\30 000ee"
,
Jun 7 2016
https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/css/parser/CSSParserToken.cpp?l=220-221
,
Jun 7 2016
,
Jun 7 2016
Moving this nonessential bug to the next milestone. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jun 20 2016
Issue 621418 has been merged into this issue.
,
Jun 20 2016
Per the comment, were we trying to maintain compatibility with the previous implementation, other browsers, or something else entirely? This behavior is pretty surprising and doesn't allow the color picker in devtools to adjust these values.
,
Jun 21 2016
This gets worse. 'M20.8' serializes as 'M200.8' It appears that the only requirement from the spec is that the serialized value roundtrips. Firefox does a much better job of preserving the original property value.
,
Jun 22 2016
Why is this P1?
,
Jun 22 2016
It's a pretty major interop issue in a new feature. We should figure out what to do before usage increases. It's also trivially easy to run into when using custom paint.
,
Jun 23 2016
fwiw Safari also behaves differently > $0.style.cssText = '--foo: #0000ee' < "--foo: #0000ee" = $2 > $0.style.cssText < "--foo: rgb(0, 0, 238);" = $3
,
Jun 23 2016
,
Jun 24 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f commit 7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f Author: ramya.v <ramya.v@samsung.com> Date: Fri Jun 24 06:55:54 2016 CSS Variable #0000ee is read as #\30 000ee Handled HashTokenTypes seperately. BUG= 617694 Review-Url: https://codereview.chromium.org/2080723003 Cr-Commit-Position: refs/heads/master@{#401828} [modify] https://crrev.com/7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f/third_party/WebKit/LayoutTests/fast/css/variables/computed-style.html [modify] https://crrev.com/7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f/third_party/WebKit/Source/core/css/CSSMarkup.cpp [modify] https://crrev.com/7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f/third_party/WebKit/Source/core/css/CSSMarkup.h [modify] https://crrev.com/7b65d1f3c241e1e5fe2d06b8fc272dc86c1ff44f/third_party/WebKit/Source/core/css/parser/CSSParserToken.cpp
,
Jul 6 2016
This issue is Pri-1 but has already been moved once. Lowering the priority and moving to the next milestone. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jul 18 2016
Should be fixed by #13
,
Jul 18 2016
,
Jul 22 2016
Wasn't this only fixed for color?
,
Jul 22 2016
The bug report is for "CSS variable, #30000ee is read as #\30 000ee" though.
,
Jul 22 2016
That's just a symptom of the larger problem. eg. comment #8. We're not interoperable with the implementation in Firefox.
,
Jul 26 2016
Issue 631024 has been merged into this issue.
,
Aug 5 2016
I can't get the example in comment #8 reproducing? What I get here is: $0.style.cssText = "--foo: 'M20.8'" "--foo: 'M20.8'" $0.style.cssText "--foo: "M20.8";" Where does this still fail with variables?
,
Aug 10 2016
eg.
element.style.setProperty('--a', 'M20.8')
element.style.getPropertyValue('--a') -> 'M200.8'
,
Aug 26 2016
,
Nov 3 2016
I forked off the part about making this match exactly into a separate bug 661854 |
||||||||||||||
►
Sign in to add a comment |
||||||||||||||
Comment 1 by rnimmagadda@chromium.org
, Jun 7 2016Components: Platform>DevTools Blink>CSS
Labels: -Type-Compat M-52 OS-Linux OS-Mac Type-Bug
Status: Untriaged (was: Unconfirmed)