Skip to content

disabled default color features still output as CSS variables in DOM #43385

@via-lars

Description

@via-lars

Description

disabling color features such as default pallette by theme.json lets their values still be output in DOM by WordPress as CSS variables

Step-by-step reproduction instructions

  1.  "$schema": "https://schemas.wp.org/wp/6.0/theme.json",
     "version": 2,
     "settings": {
         "color": {
             "defaultPalette": false,
             "defaultGradients": false,
             "defaultDuotone": false
     }
     }
    

}```
2. see debugger

Screenshots, screen recording, code snippet

image

Environment info

WordPress 6.0.1

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    Global StylesAnything related to the broader Global Styles efforts, including Styles Engine and theme.json[Feature] ColorsColor management[Status] DuplicateUsed to indicate that a current issue matches an existing one and can be closed

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions