innovixx

payload color picker field

by innovixx
Custom fields
v3
^3.2.2
MIT

Overview

Summary generated from the README

Adds a colorPickerField helper that you place in a collection's fields array to give editors a color selection control in the admin panel. It accepts the usual field options such as name, label, required and admin settings. Colors are stored in HEX format. Targets Payload 3.

Features

  • Color picker field usable in any collection
  • Supports HEX color format
  • Accepts standard field options like required, label and admin position
  • Includes a self-seeding demo project for development

Use cases

  • Let editors choose a brand or theme color for each page
  • Add an accent color selector to a sidebar field in a collection

From the author

The Payload Color Picker that enables an easy color selection field for your Payload projects.

Installation

npm i @innovixx/payload-color-picker-field

41

Stars

5

Forks

7

Open Issues

6 months ago

Last Updated

0

Weekly Downloads

v2.0.4

npm Version

475.6 KB

Unpacked Size

1

Dependencies

GitHub stars

Trends appear after 7 days of data. Daily snapshots have not started yet.

npm weekly downloads

Trends appear after 7 days of data. Daily snapshots have not started yet.

Each point is npm's rolling 7-day download count.

Health Score

37/100Fair

Composite score based on GitHub activity, stars, npm downloads, publish recency, dependency count, and package size.

Badge for your README

Payload Directory health badge
Markdown
[![Payload Directory](https://payloaddirectory.dev/badge/666027944-root.svg)](https://payloaddirectory.dev/plugins/666027944-root)
HTML
<a href="https://payloaddirectory.dev/plugins/666027944-root"><img src="https://payloaddirectory.dev/badge/666027944-root.svg" alt="Payload Directory"></a>
Updated Apr 17, 2026Created Jul 13, 2023Published Dec 8, 2025

README

Payload Color Picker Field

NPM

A field for Payload that enables an easy color selection field for your Payload projects.

payload-color-picker-field-screenshot.png

Core features:

  • Add a color picker field to your Payload collections
  • Supports HEX color formats

Installation

  yarn add @innovixx/payload-color-picker-field
  # OR
  npm i @innovixx/payload-color-picker-field

Basic Usage

import type { CollectionConfig } from 'payload/types'

import { colorPickerField } from '@innovixx/payload-color-picker-field'

const Pages: CollectionConfig = {
  slug: 'pages',
  admin: {
    useAsTitle: 'title',
  },
  fields: [
    colorPickerField({
      name: 'primaryColor',
      label: 'Primary Color',
      required: true,
      admin: {
        position: 'sidebar',
        description: 'Choose a color for this page',
      },
    }),
  ],
}

export default Pages

Development

To actively develop or debug this plugin you can either work directly within the demo directory of this repo, or link your own project.

  1. Internal Demo

    This repo includes a fully working, self-seeding instance of Payload that installs the plugin directly from the source code. This is the easiest way to get started. To spin up this demo, follow these steps:

    1. First clone the repo
    2. Then, cd YOUR_PLUGIN_REPO && yarn && cd demo && yarn && yarn cleanDev
    3. Now open http://localhost:3000/admin in your browser
    4. Enter username [email protected] and password Pa$$w0rd!

    That's it! Changes made in ./src will be reflected in your demo. Keep in mind that the demo database is automatically seeded on every startup, any changes you make to the data get destroyed each time you reboot the app.

Similar plugins