ColorIndicator

ColorIndicator is a React component that renders a specific color in a circle. It’s often used to summarize a collection of used colors in a child component.

import { ColorIndicator } from '@wordpress/components';

View on Storybook

View source on GitHub

PropsPermalink to this section

NameDefaultDescription
colorValue Required

Background<string | number> | undefined

The color of the indicator. Any value from the CSS background property is supported.

ExamplesPermalink to this section

DefaultPermalink to this section

const Default = () => <ColorIndicator colorValue="#0073aa" />;