Skip to content

Global Styles: Reselecting the original styles from color swatch triggers changes #70285

Open
@Rishit30G

Description

@Rishit30G

Description

Currently, when I change the style (text color, background color, link color, etc.) and then revert it back to the original by clicking on the color swatch, the review button still gets triggered—even though no actual change has occurred. While clicking the ‘Clear’ button resolves this issue for other elements, it doesn’t work for ‘Text Color’. Focus issue for Text Color: #60614.

Step-by-step reproduction instructions

  1. Open the Site Editor.
  2. Navigate to Styles > Colors.
  3. Change the Text Color using the color swatch, then click back on the original color.
  4. Notice that the Review Changes button appears, even though the color is reverted.
  5. Refresh the page.
  6. Now repeat the color switching process with Background, Links, etc.
  7. Observe that the Clear button removes the Review Changes button. However, switching back to the original color from another still triggers the Review Changes button.

Screenshots, screen recording, code snippet

Screen.Recording.2025-06-02.at.8.57.50.AM.mov

Screen.Recording.2025-06-02.at.8.58.32.AM.mov

Environment info

  • WordPress 6.8
  • Gutenberg 20.9.0
  • TT5
  • Google Chrome
  • MacOS Sequoia

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

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

No one assigned

    Labels

    Global StylesAnything related to the broader Global Styles efforts, including Styles Engine and theme.json

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions