Developers · Gutenberg

Color Harmony block for WordPress

Pick a base color and instantly see complementary, triadic, analogous, and other harmonic palettes. Click any swatch to copy its hex value.

Get Blockenberg

Free Gutenberg block in Blockenberg. The inspector controls and front-end behavior on this page come from this block’s source, not a shared stub.

Get Blockenberg

What it actually does

Pick a base color and instantly see complementary, triadic, analogous, and other harmonic palettes. Click any swatch to copy its hex value.

Inspector panels on this block: Content, Palette Settings. Those titles come from index.js, not from a shared template.

Where to find it

Gutenberg inserter → Developers → search “Color Harmony” (block name `blockenberg/color-harmony` in block.json). Style it in the sidebar after insert.

How to use Color Harmony block for WordPress

  1. Install Blockenberg. Install from WordPress.org and activate the plugin.
  2. Insert the block. Edit a page, click +, search for “Color Harmony”, insert it. Category: Developers.
  3. Configure inspector controls that exist on this block. Open Content. Set “Default Harmony Type”, “Swatch Size (px)”, “Show Hex Values”, “Show RGB Values”.
  4. Check the published page. The view script reads HTML data attributes: data-opts. The block editor preview may not run the same view script.

Inspector controls from this block’s code

ControlWhat the code does
Default Harmony TypeSelect control; the chosen value is saved on the block. block.json default: complementary. Saved as `defaultHarmony`.
Swatch Size (px)Numeric range control in the inspector. Range 48–140. block.json default: 80. Saved as `swatchSize`.
Show Hex ValuesOn/off toggle in the inspector. On by default. Saved as `showHex`.
Show RGB ValuesOn/off toggle in the inspector. Off by default. Saved as `showRgb`.
Show Export ButtonOn/off toggle in the inspector. On by default. Saved as `showExport`.
Accent ColorColor control in the inspector. block.json default: #6366f1. Saved as `accentColor`.
Section BackgroundColor control in the inspector. block.json default: #f8fafc. Saved as `sectionBg`.
Card BackgroundColor control in the inspector. block.json default: #ffffff. Saved as `cardBg`.
Title ColorColor control in the inspector. block.json default: #1e1b4b. Saved as `titleColor`.

What the front-end script actually does

When this is the right block

Notes from the implementation

viewScript: this folder’s frontend.js is enqueued on the front end for this block.

FAQ

How do I add the Color Harmony block in WordPress?

Install Blockenberg from WordPress.org, edit a page in the block editor, click +, and search for “Color Harmony”. It sits under Developers. After insert, open Content and set “Default Harmony Type”, “Swatch Size (px)”, “Show Hex Values”, “Show RGB Values”.

What makes Color Harmony different from other Blockenberg blocks?

Pick a base color and instantly see complementary, triadic, analogous, and other harmonic palettes. Click any swatch to copy its hex value. Inspector labels on this block include “Default Harmony Type”, “Swatch Size (px)”, “Show Hex Values”, “Show RGB Values”.

Is the Color Harmony Gutenberg block free?

Yes. Color Harmony ships inside Blockenberg. Get the plugin from WordPress.org — no paid add-on is required for this block.

Can I style Color Harmony to match my theme?

Yes. Blockenberg’s shared typography and color panels apply here, plus any block-specific style controls listed on this page (panels: Content, Palette Settings).

Related developers blocks

Get Blockenberg

Install Blockenberg from WordPress.org, then insert Color Harmony from the Gutenberg inserter.

Get Blockenberg