Skip to main content
The color picker allows creators to customize content to better reflect their branding and style. It is commonly used to allow the creator to change the color of backgrounds, buttons and text to better fit in with their email templates. example color picker

Compatibility

Properties

string
required
color - the type of the component
string
required
A unique internal-only identifier that is posted to an app’s plugin server to share values inputted by the creator
string
required
Creator-facing identifier that is shown in the plugin environment
string
Default color value that is pre-filled when the component first loads (e.g. "#ff0000")
boolean
Determines whether the creator must select a color before proceeding
string
Brief creator-facing explanation that clarifies the component’s purpose and usage. (256 character limit. Supports markdown: [text](url), **bold**, and *italic*)
boolean
default:"false"
When set to true, displays a “Transparent” toggle that allows creators to set the color to transparent. Defaults to false.
object array
Allows for the field to be shown conditionally. dependent on other fields. See dependencies page for more details.

Best practices

Automatic styling

When using the color picker for content blocks, alongside the settings object, Kit also shares data on the styles used within the email template - allowing your plugin to assume the styling of the email automatically, to make it feel as native as possible. Details on the style data available can be found below:
  • p
  • h1
  • h2
  • h3
  • h4
  • h5
  • h6
  • ol
  • ul
  • blockquote
  • a
  • “color”,
  • “font-family”,
  • “font-size”,
  • “font-weight”,
  • “letter-spacing”,
  • “line-height”,
  • “text-align”,
  • “text-transform”,
  • “margin-top”,
  • “margin-right”,
  • “margin-bottom”,
  • “margin-left”,
  • “padding-top”,
  • “padding-right”,
  • “padding-bottom”,
  • “padding-left”