import React from "react"; import { type InputPrimitiveProps } from "../../Input/index.js"; import { type PopoverPrimitiveContentProps } from "../../Popover/index.js"; interface ColorPickerPrimitiveProps extends Omit, "onChange"> { /** * Callback triggered when the open state changes. */ onOpenChange?: (open: boolean) => void; /** * Callback triggered when the value changes. */ onChange?: (value: string) => void; /** * Callback triggered when the color selection is complete. * This is called after the user has finished selecting a color. */ onChangeComplete?: (value: string) => void; /** * Optional selected value. */ value?: string; /** * If true, the color picker will be disabled. */ disabled?: boolean; /** * Popover alignment. */ align?: PopoverPrimitiveContentProps["align"]; /** * Size of the input field. * Refer to `InputPrimitiveProps["size"]` for possible values. */ size?: InputPrimitiveProps["size"]; /** * Variant of the input field. * Refer to `InputPrimitiveProps["variant"]` for possible values. */ variant?: InputPrimitiveProps["variant"]; /** * Indicates if the input field is invalid. * Refer to `InputPrimitiveProps["invalid"]` for possible values. */ invalid?: InputPrimitiveProps["invalid"]; } declare const ColorPickerPrimitive: (({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element) & { original: ({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element; originalName: string; displayName: string; } & { original: (({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element) & { original: ({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element; originalName: string; displayName: string; }; originalName: string; displayName: string; } & { createDecorator: (decorator: import("@webiny/react-composition/types.js").ComponentDecorator<(({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element) & { original: ({ align, disabled, invalid, size, variant, value, onOpenChange, onChange, onChangeComplete, ...props }: ColorPickerPrimitiveProps) => React.JSX.Element; originalName: string; displayName: string; }>) => (props: unknown) => React.JSX.Element; }; export { ColorPickerPrimitive, type ColorPickerPrimitiveProps };