feat: add public ColorArea components, docs, and package contract

This commit is contained in:
maoyingjie
2026-10-26 23:51:31 +08:00
parent 01882160e6
commit ae364578ce
33 changed files with 2201 additions and 151 deletions
+6 -1
View File
@@ -11,7 +11,12 @@ import {
import { colorAreaBackground } from "../../src/components/color/gradient";
import { parseColor, type Color } from "../../src/components/color/value";
defineOptions({ inheritAttrs: false });
const props = defineProps<ColorModelProps & ColorAreaOptions>();
const props = withDefaults(defineProps<ColorModelProps & ColorAreaOptions>(), {
// The private picker proof uses the common saturation × brightness square;
// public ColorArea inference follows the fixed source's channel order.
xChannel: "saturation",
yChannel: "brightness",
});
const emit = defineEmits<{
"update:modelValue": [Color | null];
change: [Color | null];