WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
303059
Default value of custom property not recognizing by CSS Style Container Query with certain formatting
https://bugs.webkit.org/show_bug.cgi?id=303059
Summary
Default value of custom property not recognizing by CSS Style Container Query...
Rogier de Ruijter
Reported
2025-11-24 10:46:26 PST
When using a custom property with a default value it is not recognized in a style container query, when it is formatted with e.g. prettier. This does work in Chrome. In short: ``` html { /* valid */ --my-container-var: var(--my-undefined-var, "my-default-value"); /* invalid */ --my-container-var: var( --my-undefined-var, "my-default-value" ); } body { @container style(--my-container-var: "my-default-value") { --my-font: "Helvetica Neue", Helvetica, Arial, sans-serif; } } p { font-family: var(--my-font); } ```
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2025-12-01 10:06:29 PST
<
rdar://problem/165627262
>
Ahmad Saleem
Comment 2
2026-05-25 02:11:05 PDT
Pull request:
https://github.com/WebKit/WebKit/pull/65609
EWS
Comment 3
2026-05-27 03:57:48 PDT
Committed
313957@main
(2f8d1192d466): <
https://commits.webkit.org/313957@main
> Reviewed commits have been landed. Closing PR #65609 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug