Skip to content

Border allows custom color picker even when custom color is set to false in theme.json #59567

Closed

Description

@andreawetzel

Description

In theme.json having a custom color setting as false still allows the color picker for border color. The goal is to allow theme users to be able to choose from the color palette for border colors, but not have access to the color picker to choose any of the custom Hex, RGB, HSL color options

Step-by-step reproduction instructions

In theme.json, set custom color setting to false and note that the custom color option is still available in core/group block under styles > border.

  "settings": {
    "color": {
      "custom": false,

Note that I can set border color to false in theme.json settings overall or for each block, but this also removes the ability to choose from my theme's color palette as well as removing the custom color picker.

  "settings": {
    "border": {
      "radius": true,
      "color": false,
      "style": false,
      "width": false
    },

Screenshots, screen recording, code snippet

In the screenshot below, the limited color palette is shown but custom color picker is also shown for border color

Screenshot 2024-03-04 at 10 29 43 AM

Environment info

  • Tested in WP 6.4.3 and 6.5-beta3 (no Gutenberg plugin)
  • Also tested with Gutenberg Plugin v17.8.0-rc.4 +WP 6.5-beta3
  • Mac / Chrome

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

Activity

  1. added
    [Feature] ExtensibilityThe ability to extend blocks or the editing experience
    [Feature] Design ToolsTools that impact the appearance of blocks both to expand the number of tools and improve the experi
    on Mar 5, 2024
  2. annezazu commented on Mar 5, 2024

    @annezazu
    Contributor

    Thank you for opening this! Added a few more labels.

    Tested in WP 6.4.3 and 6.5-beta3 (no Gutenberg plugin)

    Because this is present in both 6.4.3 and 6.5 beta 3, I'm afraid this isn't a bug isolated to just the beta period of 6.5. We enter RC1 tomorrow where we focus on fixing bugs found during the beta period/related to the beta period. As a result, I'm not going to add this to the 6.5 board.

  3. cbravobernal commented on Mar 18, 2024

    @cbravobernal
    Contributor

    If you don't mind, I'd like to work on this feature for the March 24th Contributor table at WordCamp Torrelodones 2024.

  4. vraja-pro commented on Mar 24, 2024

    @vraja-pro

    The problem is with the redux store "core/block-editor"
    In the post editor is it not loaded and in the site editor it is loaded but without state.
    For site editor - we need to import register from @wordpress/data to packages/block-editor/src/store/index.js
    and add in line 38:

    register( store );
    
  5. vraja-pro commented on Apr 18, 2024

    @vraja-pro

    Back on this issue in Yoast contributor day, the register is done in a different file, so that was not the issue.

    • This problem is both in the block editor when editing a post and in the site editor when editing a page.
    • Testing specifically in Group block.
    • This bug is applicable for text color and background color as well.
    • Not sure why we are not using initialState when registering a store.
    • The disableCustomColors is not true to the store value in packages/components/src/color-palette/index.tsx
  6. snibe commented on Aug 12, 2025

    @snibe

    is there any update on this? we are having this issue on the latest version 6.8.2 Thanks!

  7. n8finch commented on Sep 8, 2025

    @n8finch
    Contributor

    I'll be looking into this issue this week. 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

[Feature] Design ToolsTools that impact the appearance of blocks both to expand the number of tools and improve the experi[Feature] ExtensibilityThe ability to extend blocks or the editing experience[Status] In ProgressTracking issues with work in progress[Type] BugAn existing feature does not function as intended

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions