Skip to content

[cssom] [css-cascade] Legacy shorthands never appearing on cssText has unfortunate effects when variable references are involved. #3332

@emilio

Description

@emilio

https://drafts.csswg.org/css-cascade-4/#legacy-shorthand means that for:

<div style="page-break-after: var(--a)"></div>

The following happens:

div.style.cssText == "break-after:;"

It's a bit unfortunate, but maybe it's ok, given this is a more general issue (#2515), and these shorthands are supposed to be legacy anyway. We could fix legacy shorthands by special-casing them and saying that they serialize in this case, but that's not necessarily great, and certainly propagates the weirdness a bit more in the implementation.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions