Vue Color Pickers

3.3.3 · active · verified Sun Apr 19

Vue Color is a comprehensive collection of performant and highly customizable color picker components designed for Vue.js applications. The current stable version is 3.3.3. The library is actively maintained with regular patch releases addressing bug fixes and dependency updates, and minor versions introduce new features like additional slider components (e.g., `<HSLSliders />`, `<HSVSliders />`, `<RGBSliders />`) and dark mode support. A major rewrite to v3.0.0 moved the library to TypeScript and full Vue 3 support, while also maintaining compatibility with Vue 2.7. Key differentiators include its modular and tree-shakable design, full TypeScript typings, SSR-friendliness, and built-in accessibility and dark mode support. It uses `tinycolor2` internally for robust color parsing and conversion, allowing `v-model` to preserve the input color format.

Common errors

Warnings

Install

Imports

Quickstart

Demonstrates how to import the global styles and use the `ChromePicker` component with `v-model` in a Vue 3 Composition API setup to display and update a color value.

import { createApp } from 'vue';
import App from './App.vue';
import 'vue-color/style.css';

createApp(App).mount('#app');

// In App.vue
<template>
  <div style="padding: 20px;">
    <h1>Pick a Color</h1>
    <ChromePicker v-model="color" />
    <p style="margin-top: 20px;">Selected Color: {{ color }}</p>
  </div>
</template>

<script setup lang="ts">
import { ChromePicker } from 'vue-color';
import { ref } from 'vue';

const color = ref('#68CCCA');
</script>

view raw JSON →