Skip to content

ColorPicker 颜色选择器

基础用法

禁用

三种大小

禁用透明度

清除颜色

自定义触发器

预设颜色

ColorPicker API

ColorPicker Attributes

NameDescriptionTypeDefaultVersion
allowClear允许清除选择的颜色booleanfalse
disabled禁用颜色选择器booleanfalse
disabledAlpha禁用透明度booleanfalse
format颜色格式auto | rgb | hex | hslauto
presets预设的颜色string[][]
value(v-model)颜色的值string
size输入框尺寸large | default | small

ColorPicker Events

NameDescriptionType
change颜色变化的回调(color: string) => void
clear清除的回调() => void

ColorPicker Slots

NameDescription
default自定义触发器

贡献者

lazy

变更记录

86f13 - style: 兼容下样式 on 3/13/2025
cebe3 - fix: 修复select宽度问题 on 3/13/2025
7bf1f - feat: color-picker on 3/12/2025

Released under the MIT License.