| Summary: | Serialization of CSS custom property value is incorrect for a custom string | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | kj.kim |
| Component: | CSS | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW --- | ||
| Severity: | Minor | CC: | ahmad.saleem792, amorosok, dino, kevin_neal, kj.kim, koivisto, simon.fraser, webkit-bug-importer |
| Priority: | P2 | Keywords: | BrowserCompat, InRadar |
| Version: | Safari 14 | ||
| Hardware: | Unspecified | ||
| OS: | macOS 10.15 | ||
Thank you for your filing. The appropriate engineers have been notified. It is reproducible on Safari Technology Preview 184 as well and show 'double quotes' for single quote. *** Safari Technology Preview 184 *** naked: /20210629/asset/logo.svg double quotes: "/20210629/s/assets/images/logo-alpine-group.svg" single quotes: "/20210629/s/assets/images/logo-alpine-group.svg" *** Other Browsers (Chrome Canary 122 & Firefox Nightly 122) *** naked: /20210629/asset/logo.svg double quotes: "/20210629/s/assets/images/logo-alpine-group.svg" single quotes: '/20210629/s/assets/images/logo-alpine-group.svg' |
Steps to reproduce the problem: 1. set CSS custom property with a custom string that is surrounded by single quotes, e.g., "--logo-path: '/20210629/asset/logo.svg';" 2. fetch the value via JS, e.g., getComputedStyle(document.body).getPropertyValue("--logo-path"); What is the expected behavior? returned value is '/20210629/asset/logo.svg'. What went wrong? returned value is "/20210629/asset/logo.svg". Repro: https://codepen.io/kj-kim-sfdc/pen/zYzBNyg Spec clarification: https://github.com/w3c/csswg-drafts/issues/6572#issuecomment-911910455