[Webkit-unassigned] [Bug 225209] New: CSS shorthands with var() should serialize with var()

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Apr 29 13:51:32 PDT 2021


https://bugs.webkit.org/show_bug.cgi?id=225209

            Bug ID: 225209
           Summary: CSS shorthands with var() should serialize with var()
           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: obrufau at igalia.com

Run this code:

```js
document.body.style.cssText = "--m:10px; margin:var(--m)";
document.body.style.margin;
```

**Actual**: ""
**Expected: "var(--m)"

See https://drafts.csswg.org/css-variables/#variables-in-shorthands

> while [CSSOM] defines that shorthand properties are serialized
> by appropriately concatenating the values of their corresponding longhands,
> shorthands that are specified with explicit var() functions
> must serialize to the original, var()-containing value.

-- 
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/20210429/815f6d4d/attachment.htm>


More information about the webkit-unassigned mailing list