import * as React from 'react'; import { type ColorControlSpace } from '../../internal/color-control'; import { type Color, type ColorChannel } from '../../lib/color'; interface ColorAreaProps extends Omit, 'color' | 'defaultValue' | 'onChange'> { /** * Selected color. Pass a `Color` or any CSS color string to control the component. * Inside a `ColorPicker` it can be left off: the control then reads and writes the * picker's color. */ value?: Color | string; /** * Color selected before any interaction, when the component is uncontrolled. * @default '#ffffff' */ defaultValue?: Color | string; /** Fires on every change, including each frame of a drag. */ onValueChange?: (value: Color) => void; /** Fires once a drag ends or a key press settles, with the color that was landed on. */ onValueCommitted?: (value: Color) => void; /** * Color space the axes operate in. Defaults to the space of the value, so a color * parsed from `hsl(...)` gives an HSL area and a hex one gives an RGB area. The * space is independent of the format you store: convert on the way out. */ colorSpace?: ColorControlSpace; /** * Channel mapped to the horizontal axis. Defaults to the first channel of the color * space that `yChannel` has not taken. */ xChannel?: ColorChannel; /** * Channel mapped to the vertical axis, increasing upwards. Defaults to the first * channel of the color space left free by `xChannel`. */ yChannel?: ColorChannel; /** * Prevent interaction and dim the area. * @default false */ disabled?: boolean; /** Name of the hidden horizontal input, used when submitting an HTML form. */ xName?: string; /** Name of the hidden vertical input, used when submitting an HTML form. */ yName?: string; /** `id` of the `
` the hidden inputs belong to, when they sit outside it. */ form?: string; /** Props for the thumb element, for styling or a test id. */ thumbProps?: React.ComponentPropsWithoutRef<'span'>; } declare function ColorArea({ value, defaultValue, onValueChange, onValueCommitted, colorSpace, xChannel: xChannelProp, yChannel: yChannelProp, disabled: disabledProp, xName, yName, form, thumbProps, className, children, 'aria-label': ariaLabel, ...props }: ColorAreaProps): React.JSX.Element; export { ColorArea }; export type { ColorAreaProps }; //# sourceMappingURL=color-area.d.ts.map