Skip to content
Lenso UI

ColorPicker

A shared color value for composing fields, sliders and swatches.

Usage

import { ColorPicker } from "@lenso/ui";
"use client";
import { ColorArea, ColorPicker, ColorSlider, ColorSwatch } from "@lenso/ui";import * as stylex from "@stylexjs/stylex";
const styles = stylex.create({  area: { maxWidth: "100%" },  slider: { gap: 4, paddingInline: 4 },  output: { color: "var(--muted)" },});export function Basic() {  return (    <ColorPicker defaultValue="#0485F7">      <ColorPicker.Trigger>        <ColorSwatch size="lg" />        <span>Pick a color</span>      </ColorPicker.Trigger>      <ColorPicker.Popover>        <ColorArea          aria-label="Color area"          xstyle={styles.area}          colorSpace="hsb"          xChannel="saturation"          yChannel="brightness"        >          <ColorArea.Thumb />        </ColorArea>        <ColorSlider aria-label="Hue" channel="hue" xstyle={styles.slider} colorSpace="hsb">          <span>Hue</span>          <ColorSlider.Output xstyle={styles.output} />          <ColorSlider.Track>            <ColorSlider.Thumb />          </ColorSlider.Track>        </ColorSlider>      </ColorPicker.Popover>    </ColorPicker>  );}

Examples

color picker controlled

"use client";/** Adapted from HeroUI v3.2.6. Apache-2.0. Gravity Shuffle replaces the source Iconify reference to the same icon. */import {  Button,  ColorArea,  ColorField,  ColorPicker,  ColorSlider,  ColorSwatch,  ColorSwatchPicker,  parseColor,} from "@lenso/ui";import { Shuffle } from "@gravity-ui/icons";import { useState } from "react";import * as stylex from "@stylexjs/stylex";import { styles } from "./source.stylex";const presets = [  "#ef4444",  "#f97316",  "#eab308",  "#22c55e",  "#06b6d4",  "#3b82f6",  "#8b5cf6",  "#ec4899",  "#f43f5e",];export function Controlled() {  const [color, setColor] = useState(parseColor("#325578"));  function shuffleColor() {    const hue = Math.floor(Math.random() * 360);    const saturation = 50 + Math.floor(Math.random() * 50);    const lightness = 40 + Math.floor(Math.random() * 30);    setColor(parseColor(`hsl(${hue}, ${saturation}%, ${lightness}%)`));  }  return (    <div {...stylex.props(styles.column)}>      <ColorPicker value={color} onChange={setColor}>        <ColorPicker.Trigger>          <ColorSwatch size="lg" />          <span>Pick a color</span>        </ColorPicker.Trigger>        <ColorPicker.Popover xstyle={styles.popover}>          <ColorSwatchPicker aria-label="Color presets" xstyle={styles.presets} size="xs">            {presets.map((preset) => (              <ColorSwatchPicker.Item key={preset} color={preset}>                <ColorSwatchPicker.Swatch />              </ColorSwatchPicker.Item>            ))}          </ColorSwatchPicker>          <ColorArea            aria-label="Color area"            xstyle={styles.area}            colorSpace="hsb"            xChannel="saturation"            yChannel="brightness"          >            <ColorArea.Thumb />          </ColorArea>          <div {...stylex.props(styles.hueRow)}>            <ColorSlider              aria-label="Hue slider"              channel="hue"              xstyle={styles.flex1}              colorSpace="hsb"            >              <ColorSlider.Track>                <ColorSlider.Thumb />              </ColorSlider.Track>            </ColorSlider>            <Button              isIconOnly              aria-label="Shuffle color"              size="sm"              variant="tertiary"              onClick={shuffleColor}            >              <Shuffle {...stylex.props(styles.icon)} />            </Button>          </div>          <ColorField aria-label="Color field">            <ColorField.Group variant="secondary">              <ColorField.Prefix>                <ColorSwatch size="xs" />              </ColorField.Prefix>              <ColorField.Input />            </ColorField.Group>          </ColorField>        </ColorPicker.Popover>      </ColorPicker>      <p {...stylex.props(styles.selected)}>        Selected: <span {...stylex.props(styles.medium)}>{color.toString("hex")}</span>      </p>    </div>  );}

color picker with swatches

"use client";/** Adapted from HeroUI v3.2.6. Apache-2.0. */import { ColorArea, ColorPicker, ColorSlider, ColorSwatch, ColorSwatchPicker } from "@lenso/ui";import { styles } from "./source.stylex";const presets = [  "#ef4444",  "#f97316",  "#eab308",  "#22c55e",  "#06b6d4",  "#3b82f6",  "#8b5cf6",  "#ec4899",  "#f43f5e",];export function WithSwatches() {  return (    <ColorPicker defaultValue="#F43F5E">      <ColorPicker.Trigger>        <ColorSwatch size="lg" />        <span>Brand Color</span>      </ColorPicker.Trigger>      <ColorPicker.Popover>        <ColorArea          aria-label="Color area"          xstyle={styles.area}          colorSpace="hsb"          xChannel="saturation"          yChannel="brightness"        >          <ColorArea.Thumb />        </ColorArea>        <ColorSlider aria-label="Hue slider" channel="hue" xstyle={styles.slider} colorSpace="hsb">          <ColorSlider.Label>Hue</ColorSlider.Label>          <ColorSlider.Output xstyle={styles.output} />          <ColorSlider.Track>            <ColorSlider.Thumb />          </ColorSlider.Track>        </ColorSlider>        <ColorSwatchPicker aria-label="Color presets" xstyle={styles.swatches} size="xs">          {presets.map((preset) => (            <ColorSwatchPicker.Item key={preset} color={preset}>              <ColorSwatchPicker.Swatch />            </ColorSwatchPicker.Item>          ))}        </ColorSwatchPicker>      </ColorPicker.Popover>    </ColorPicker>  );}

color picker with fields

"use client";/** Adapted from HeroUI v3.2.6. Apache-2.0. */import { ColorArea, ColorField, ColorPicker, ColorSlider, ColorSwatch } from "@lenso/ui";import { useState } from "react";import * as stylex from "@stylexjs/stylex";import { styles } from "./source.stylex";import { ColorDemoSelect } from "./source";type Space = "hsb" | "hsl" | "rgb";const channels = {  hsb: ["hue", "saturation", "brightness"],  hsl: ["hue", "saturation", "lightness"],  rgb: ["red", "green", "blue"],} as const;export function WithFields() {  const [colorSpace, setColorSpace] = useState<Space>("hsl");  return (    <ColorPicker defaultValue="hsla(220, 90%, 50%, 0.8)">      <ColorPicker.Trigger>        <ColorSwatch size="lg" />        <span>Pick a color</span>      </ColorPicker.Trigger>      <ColorPicker.Popover xstyle={styles.narrowPopover}>        <ColorArea          aria-label="Color area"          xstyle={styles.area}          colorSpace="hsb"          xChannel="saturation"          yChannel="brightness"        >          <ColorArea.Thumb />        </ColorArea>        <ColorSlider channel="hue" xstyle={styles.slider} colorSpace="hsb">          <ColorSlider.Label>Hue</ColorSlider.Label>          <ColorSlider.Output xstyle={styles.output} />          <ColorSlider.Track>            <ColorSlider.Thumb />          </ColorSlider.Track>        </ColorSlider>        <ColorDemoSelect          label="Color space"          value={colorSpace}          options={["hsb", "hsl", "rgb"]}          onChange={setColorSpace}          uppercase        />        <div {...stylex.props(styles.channelGrid)}>          {channels[colorSpace].map((channel) => (            <ColorField              key={channel}              aria-label={channel}              channel={channel}              colorSpace={colorSpace}            >              <ColorField.Group variant="secondary">                <ColorField.Input />              </ColorField.Group>            </ColorField>          ))}        </div>      </ColorPicker.Popover>    </ColorPicker>  );}

color picker with sliders

"use client";/** Adapted from HeroUI v3.2.6. Apache-2.0. */import { ColorPicker, ColorSlider, ColorSwatch } from "@lenso/ui";import { useState } from "react";import * as stylex from "@stylexjs/stylex";import { styles } from "./source.stylex";import { ColorDemoSelect } from "./source";type Space = "hsb" | "hsl" | "rgb";const channelProps = {  hsb: [    { colorSpace: "hsb", channel: "hue" },    { colorSpace: "hsb", channel: "saturation" },    { colorSpace: "hsb", channel: "brightness" },    { colorSpace: "hsb", channel: "alpha" },  ],  hsl: [    { colorSpace: "hsl", channel: "hue" },    { colorSpace: "hsl", channel: "saturation" },    { colorSpace: "hsl", channel: "lightness" },    { colorSpace: "hsl", channel: "alpha" },  ],  rgb: [    { colorSpace: "rgb", channel: "red" },    { colorSpace: "rgb", channel: "green" },    { colorSpace: "rgb", channel: "blue" },    { colorSpace: "rgb", channel: "alpha" },  ],} as const;export function WithSliders() {  const [colorSpace, setColorSpace] = useState<Space>("hsl");  return (    <ColorPicker defaultValue="hsl(219, 58%, 93%)">      <ColorPicker.Trigger>        <ColorSwatch size="lg" />        <span>Pick a color</span>      </ColorPicker.Trigger>      <ColorPicker.Popover xstyle={styles.slidersPopover}>        <ColorDemoSelect          label="Color space"          value={colorSpace}          options={["hsb", "hsl", "rgb"]}          onChange={setColorSpace}          uppercase        />        <div {...stylex.props(styles.column2)}>          {channelProps[colorSpace].map((props) => (            <ColorSlider              key={props.channel}              {...props}              aria-label={props.channel}              xstyle={styles.slider}            >              <ColorSlider.Label xstyle={styles.capitalize}>{props.channel}</ColorSlider.Label>              <ColorSlider.Output xstyle={styles.output} />              <ColorSlider.Track>                <ColorSlider.Thumb />              </ColorSlider.Track>            </ColorSlider>          ))}        </div>      </ColorPicker.Popover>    </ColorPicker>  );}

color picker custom styles

"use client";/** Adapted from HeroUI v3.2.6. Apache-2.0. */import { ColorArea, ColorPicker, ColorSlider, ColorSwatch } from "@lenso/ui";import * as stylex from "@stylexjs/stylex";import { styles } from "./source.stylex";export function CustomStyles() {  return (    <ColorPicker defaultValue="#0485F7">      <ColorPicker.Trigger xstyle={styles.trigger}>        <ColorSwatch size="lg" />        <span {...stylex.props(styles.label)}>Theme color</span>      </ColorPicker.Trigger>      <ColorPicker.Popover xstyle={styles.surface}>        <ColorArea          aria-label="Color area"          xstyle={styles.area}          colorSpace="hsb"          xChannel="saturation"          yChannel="brightness"        >          <ColorArea.Thumb />        </ColorArea>        <ColorSlider channel="hue" xstyle={styles.slider} colorSpace="hsb">          <ColorSlider.Label>Hue</ColorSlider.Label>          <ColorSlider.Output xstyle={styles.output} />          <ColorSlider.Track>            <ColorSlider.Thumb />          </ColorSlider.Track>        </ColorSlider>      </ColorPicker.Popover>    </ColorPicker>  );}

API Reference

Generated from the local public TypeScript exports. Types and callback state follow the installed native contracts, not the historical HeroUI API.

Only literal defaults in the component's parameter declaration are shown. Other defaults may depend on context or the native component.

ColorPickerRoot

({ children, xstyle, ...props }: ColorPickerRootProps): JSX.Element

packages/react/src/components/color-picker/color-picker.tsx:15

react-aria-components/ColorPicker

react-aria-components/Popover

react-aria-components/Dialog

react-aria-components/Button

PropertyTypeRequiredLocal defaultDescription
slotstring | null | undefinedNoNot declaredA slot name for the component. Slots allow the component to receive props from a parent component. An explicit `null` value indicates that the local props completely override all props received from a parent.node_modules/react-aria-components/dist/types/src/utils.d.ts:172
defaultValuestring | Color | undefinedNoNot declaredThe default value (uncontrolled).node_modules/@react-types/shared/src/inputs.d.ts:73
childrenChildrenOrFunction<ColorPickerRenderProps>YesNot declaredThe children of the component. A function may be provided to alter the children based on component state.node_modules/react-aria-components/dist/types/src/ColorPicker.d.ts:14
onChange((value: Color) => void) | undefinedNoNot declaredHandler that is called when the value changes.node_modules/@react-types/shared/src/inputs.d.ts:75
valuestring | Color | undefinedNoNot declaredThe current value (controlled).node_modules/@react-types/shared/src/inputs.d.ts:71
xstyleXStyleNoNot declaredpackages/react/src/utils/styled.tsx:7
data-slotunknownNoNot declaredpackages/react/src/utils/styled.tsx:8

Callback state: ColorPickerRenderProps & { defaultChildren: ReactNode | undefined; }

color
Color
defaultChildren
ReactNode

ColorPickerTrigger

({ xstyle, style, ...props }: StyleXProps<ButtonProps & RefAttributes<HTMLButtonElement>>): ReactElement<any, string | JSXElementConstructor<any>>

packages/react/src/components/color-picker/color-picker.tsx:29

react-aria-components/ColorPicker

react-aria-components/Popover

react-aria-components/Dialog

react-aria-components/Button

PropertyTypeRequiredLocal defaultDescription
translateundefined | "yes" | "no"NoNot declarednode_modules/@react-types/shared/src/dom.d.ts:303
hiddenundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:301
styleStyleOrFunction<ButtonRenderProps> | undefinedNoNot declaredThe inline [style](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/style) for the element. A function may be provided to compute the style based on component state.node_modules/react-aria-components/dist/types/src/utils.d.ts:132
namestring | undefinedNoNot declaredSubmitted as a pair with the button's value as part of the form data.node_modules/react-aria/dist/types/src/button/useButton.d.ts:68
formstring | undefinedNoNot declaredThe `<form>` element to associate the button with. The value of this attribute must be the id of a `<form>` in the same document. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/button#form).node_modules/react-aria/dist/types/src/button/useButton.d.ts:53
slotstring | null | undefinedNoNot declaredA slot name for the component. Slots allow the component to receive props from a parent component. An explicit `null` value indicates that the local props completely override all props received from a parent.node_modules/react-aria-components/dist/types/src/utils.d.ts:172
dirstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:299
aria-disabledundefined | false | true | "false" | "true"NoNot declaredIndicates whether the element is disabled to users of assistive technology.node_modules/react-aria/dist/types/src/button/useButton.d.ts:11
refRef<HTMLButtonElement> | undefinedNoNot declaredAllows getting a ref to the component instance. Once the component unmounts, React will set `ref.current` to `null` (or call the ref with `null` if you passed a callback ref).node_modules/@types/react/index.d.ts:301
autoFocusundefined | false | trueNoNot declaredWhether the element should receive focus on render.node_modules/@react-types/shared/src/events.d.ts:144
idstring | undefinedNoNot declaredThe element's unique identifier. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id).node_modules/@react-types/shared/src/dom.d.ts:75
langstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:300
inertundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:302
aria-controlsstring | undefinedNoNot declaredIdentifies the element (or elements) whose contents or presence are controlled by the current element.node_modules/react-aria/dist/types/src/button/useButton.d.ts:26
aria-currentundefined | false | true | "page" | "false" | "true" | "time" | "step" | "location" | "date"NoNot declaredIndicates whether this element represents the current item within a container or set of related elements.node_modules/react-aria/dist/types/src/button/useButton.d.ts:33
aria-describedbystring | undefinedNoNot declaredIdentifies the element (or elements) that describes the object.node_modules/@react-types/shared/src/dom.d.ts:51
aria-detailsstring | undefinedNoNot declaredIdentifies the element (or elements) that provide a detailed, extended description for the object.node_modules/@react-types/shared/src/dom.d.ts:57
aria-expandedundefined | false | true | "false" | "true"NoNot declaredIndicates whether the element, or another grouping element it controls, is currently expanded or collapsed.node_modules/react-aria/dist/types/src/button/useButton.d.ts:16
aria-haspopupundefined | false | true | "grid" | "listbox" | "menu" | "false" | "true" | "dialog" | "tree"NoNot declaredIndicates the availability and type of interactive popup element, such as menu or dialog, that can be triggered by an element.node_modules/react-aria/dist/types/src/button/useButton.d.ts:21
aria-labelstring | undefinedNoNot declaredDefines a string value that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:41
aria-labelledbystring | undefinedNoNot declaredIdentifies the element (or elements) that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:46
aria-pressedundefined | false | true | "mixed" | "false" | "true"NoNot declaredIndicates the current "pressed" state of toggle buttons.node_modules/react-aria/dist/types/src/button/useButton.d.ts:28
childrenChildrenOrFunction<ButtonRenderProps>NoNot declaredThe children of the component. A function may be provided to alter the children based on component state.node_modules/react-aria-components/dist/types/src/utils.d.ts:142
onFocus((e: FocusEvent<Element, Element>) => void) | undefinedNoNot declaredHandler that is called when the element receives focus.node_modules/@react-types/shared/src/events.d.ts:101
onBlur((e: FocusEvent<Element, Element>) => void) | undefinedNoNot declaredHandler that is called when the element loses focus.node_modules/@react-types/shared/src/events.d.ts:103
onKeyDown((e: KeyboardEvent) => void) | undefinedNoNot declaredHandler that is called when a key is pressed.node_modules/@react-types/shared/src/events.d.ts:94
onKeyUp((e: KeyboardEvent) => void) | undefinedNoNot declaredHandler that is called when a key is released.node_modules/@react-types/shared/src/events.d.ts:96
onAuxClickMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:322
onAuxClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:323
onClick((e: MouseEvent<FocusableElement>) => void) | undefinedNoNot declared**Not recommended โ€“ use `onPress` instead.** `onClick` is an alias for `onPress` provided for compatibility with other libraries. `onPress` provides additional event details for non-mouse interactions.node_modules/@react-types/shared/src/events.d.ts:139
onClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:321
onContextMenuMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:324
onContextMenuCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:325
onDoubleClickMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:326
onDoubleClickCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:327
onMouseDownMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:328
onMouseDownCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:329
onMouseEnterMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:330
onMouseLeaveMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:331
onMouseMoveMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:332
onMouseMoveCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:333
onMouseOutMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:334
onMouseOutCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:335
onMouseOverMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:336
onMouseOverCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:337
onMouseUpMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:338
onMouseUpCaptureMouseEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:339
onTouchCancelTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:342
onTouchCancelCaptureTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:343
onTouchEndTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:344
onTouchEndCaptureTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:345
onTouchMoveTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:346
onTouchMoveCaptureTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:347
onTouchStartTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:348
onTouchStartCaptureTouchEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:349
onPointerDownPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:352
onPointerDownCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:353
onPointerMovePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:354
onPointerMoveCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:355
onPointerUpPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:356
onPointerUpCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:357
onPointerCancelPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:358
onPointerCancelCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:359
onPointerEnterPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:360
onPointerLeavePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:361
onPointerOverPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:362
onPointerOverCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:363
onPointerOutPointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:364
onPointerOutCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:365
onGotPointerCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:366
onGotPointerCaptureCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:367
onLostPointerCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:368
onLostPointerCaptureCapturePointerEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:369
onScrollUIEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:372
onScrollCaptureUIEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:373
onWheelWheelEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:376
onWheelCaptureWheelEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:377
onAnimationStartAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:380
onAnimationStartCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:381
onAnimationEndAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:382
onAnimationEndCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:383
onAnimationIterationAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:384
onAnimationIterationCaptureAnimationEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:385
onTransitionCancelTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:388
onTransitionCancelCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:389
onTransitionEndTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:390
onTransitionEndCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:391
onTransitionRunTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:392
onTransitionRunCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:393
onTransitionStartTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:394
onTransitionStartCaptureTransitionEventHandler<HTMLButtonElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:395
valuestring | undefinedNoNot declaredThe value associated with the button's name when it's submitted with the form data.node_modules/react-aria/dist/types/src/button/useButton.d.ts:70
renderDOMRenderFunction<"button", ButtonRenderProps> | undefinedNoNot declaredOverrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if `<button>` is expected, you cannot render an `<a>`). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.node_modules/react-aria-components/dist/types/src/utils.d.ts:208
formActionstring | ((formData: FormData) => void | Promise<void>) | undefinedNoNot declaredThe URL that processes the information submitted by the button. Overrides the action attribute of the button's form owner.node_modules/react-aria/dist/types/src/button/useButton.d.ts:58
formEncTypestring | undefinedNoNot declaredIndicates how to encode the form data that is submitted.node_modules/react-aria/dist/types/src/button/useButton.d.ts:60
formMethodstring | undefinedNoNot declaredIndicates the HTTP method used to submit the form.node_modules/react-aria/dist/types/src/button/useButton.d.ts:62
formNoValidateundefined | false | trueNoNot declaredIndicates that the form is not to be validated when it is submitted.node_modules/react-aria/dist/types/src/button/useButton.d.ts:64
formTargetstring | undefinedNoNot declaredOverrides the target attribute of the button's form owner.node_modules/react-aria/dist/types/src/button/useButton.d.ts:66
typeundefined | "button" | "reset" | "submit"NoNot declaredThe behavior of the button when used in an HTML form.node_modules/react-aria/dist/types/src/button/useButton.d.ts:39
isDisabledundefined | false | trueNoNot declaredWhether the button is disabled.node_modules/react-aria/dist/types/src/button/useButton.d.ts:5
onFocusChange((isFocused: boolean) => void) | undefinedNoNot declaredHandler that is called when the element's focus status changes.node_modules/@react-types/shared/src/events.d.ts:105
onPress((e: PressEvent) => void) | undefinedNoNot declaredHandler that is called when the press is released over the target.node_modules/@react-types/shared/src/events.d.ts:119
onPressStart((e: PressEvent) => void) | undefinedNoNot declaredHandler that is called when a press interaction starts.node_modules/@react-types/shared/src/events.d.ts:121
onPressEnd((e: PressEvent) => void) | undefinedNoNot declaredHandler that is called when a press interaction ends, either over the target or when the pointer leaves the target.node_modules/@react-types/shared/src/events.d.ts:126
onPressChange((isPressed: boolean) => void) | undefinedNoNot declaredHandler that is called when the press state changes.node_modules/@react-types/shared/src/events.d.ts:128
onPressUp((e: PressEvent) => void) | undefinedNoNot declaredHandler that is called when a press is released over the target, regardless of whether it started on the target or not.node_modules/@react-types/shared/src/events.d.ts:133
preventFocusOnPressundefined | false | trueNoNot declaredWhether to prevent focus from moving to the button when pressing it. Caution, this can make the button inaccessible and should only be used when alternative keyboard interaction is provided, such as ComboBox's MenuTrigger or a NumberField's increment/decrement control.node_modules/react-aria/dist/types/src/button/useButton.d.ts:47
excludeFromTabOrderundefined | false | trueNoNot declaredWhether to exclude the element from the sequential tab order. If true, the element will not be focusable via the keyboard by tabbing. This should be avoided except in rare scenarios where an alternative means of accessing the element or its functionality via the keyboard is available.node_modules/@react-types/shared/src/dom.d.ts:85
isPendingundefined | false | trueNoNot declaredWhether the button is in a pending state. This disables press and hover events while retaining focusability, and announces the pending state to screen readers.node_modules/react-aria-components/dist/types/src/Button.d.ts:56
onHoverStart((e: HoverEvent) => void) | undefinedNoNot declaredHandler that is called when a hover interaction starts.node_modules/@react-types/shared/src/events.d.ts:110
onHoverEnd((e: HoverEvent) => void) | undefinedNoNot declaredHandler that is called when a hover interaction ends.node_modules/@react-types/shared/src/events.d.ts:112
onHoverChange((isHovering: boolean) => void) | undefinedNoNot declaredHandler that is called when the hover state changes.node_modules/@react-types/shared/src/events.d.ts:114
xstyleXStyleNoNot declaredpackages/react/src/utils/styled.tsx:7
data-slotunknownNoNot declaredpackages/react/src/utils/styled.tsx:8

Callback state: ButtonRenderProps & { defaultStyle: CSSProperties; }

isHovered
boolean
isPressed
boolean
isFocused
boolean
isFocusVisible
boolean
isDisabled
boolean
isPending
boolean
defaultStyle
CSSProperties

Callback state: ButtonRenderProps & { defaultChildren: ReactNode | undefined; }

isHovered
boolean
isPressed
boolean
isFocused
boolean
isFocusVisible
boolean
isDisabled
boolean
isPending
boolean
defaultChildren
ReactNode

Callback state: ButtonRenderProps

isHovered
boolean
isPressed
boolean
isFocused
boolean
isFocusVisible
boolean
isDisabled
boolean
isPending
boolean

Native HTML and ARIA properties (1) โ€” Property set 1

ColorPickerPopover

({ style, ...props }: StyleXProps<ComponentPropsWithRef<typeof Popover>>): JSX.Element

packages/react/src/components/color-picker/color-picker.tsx:47

react-aria-components/ColorPicker

react-aria-components/Popover

react-aria-components/Dialog

react-aria-components/Button

PropertyTypeRequiredLocal defaultDescription
maxHeightnumber | undefinedNoNot declaredThe maxHeight specified for the overlay element. By default, it will take all space up to the current viewport height.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:87
offsetnumber | undefinedNoNot declaredThe additional offset applied along the main axis between the element and its anchor element.node_modules/react-aria-components/dist/types/src/Popover.d.ts:56
translateundefined | "yes" | "no"NoNot declarednode_modules/@react-types/shared/src/dom.d.ts:303
hiddenundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:301
triggerstring | undefinedNoNot declaredThe name of the component that triggered the popover. This is reflected on the element as the `data-trigger` attribute, and can be used to provide specific styles for the popover depending on which element triggered it.node_modules/react-aria-components/dist/types/src/Popover.d.ts:20
styleStyleOrFunction<PopoverRenderProps> | undefinedNoNot declaredThe inline [style](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/style) for the element. A function may be provided to compute the style based on component state.node_modules/react-aria-components/dist/types/src/utils.d.ts:132
slotstring | null | undefinedNoNot declaredA slot name for the component. Slots allow the component to receive props from a parent component. An explicit `null` value indicates that the local props completely override all props received from a parent.node_modules/react-aria-components/dist/types/src/utils.d.ts:172
dirstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:299
refRef<HTMLElement> | undefinedNoNot declaredAllows getting a ref to the component instance. Once the component unmounts, React will set `ref.current` to `null` (or call the ref with `null` if you passed a callback ref).node_modules/@types/react/index.d.ts:301
langstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:300
inertundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:302
aria-describedbystring | undefinedNoNot declaredIdentifies the element (or elements) that describes the object.node_modules/@react-types/shared/src/dom.d.ts:51
aria-detailsstring | undefinedNoNot declaredIdentifies the element (or elements) that provide a detailed, extended description for the object.node_modules/@react-types/shared/src/dom.d.ts:57
aria-labelstring | undefinedNoNot declaredDefines a string value that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:41
aria-labelledbystring | undefinedNoNot declaredIdentifies the element (or elements) that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:46
childrenChildrenOrFunction<PopoverRenderProps>NoNot declaredThe children of the component. A function may be provided to alter the children based on component state.node_modules/react-aria-components/dist/types/src/utils.d.ts:142
onAuxClickMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:322
onAuxClickCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:323
onClickMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:320
onClickCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:321
onContextMenuMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:324
onContextMenuCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:325
onDoubleClickMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:326
onDoubleClickCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:327
onMouseDownMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:328
onMouseDownCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:329
onMouseEnterMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:330
onMouseLeaveMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:331
onMouseMoveMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:332
onMouseMoveCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:333
onMouseOutMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:334
onMouseOutCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:335
onMouseOverMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:336
onMouseOverCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:337
onMouseUpMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:338
onMouseUpCaptureMouseEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:339
onTouchCancelTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:342
onTouchCancelCaptureTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:343
onTouchEndTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:344
onTouchEndCaptureTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:345
onTouchMoveTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:346
onTouchMoveCaptureTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:347
onTouchStartTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:348
onTouchStartCaptureTouchEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:349
onPointerDownPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:352
onPointerDownCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:353
onPointerMovePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:354
onPointerMoveCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:355
onPointerUpPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:356
onPointerUpCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:357
onPointerCancelPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:358
onPointerCancelCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:359
onPointerEnterPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:360
onPointerLeavePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:361
onPointerOverPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:362
onPointerOverCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:363
onPointerOutPointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:364
onPointerOutCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:365
onGotPointerCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:366
onGotPointerCaptureCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:367
onLostPointerCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:368
onLostPointerCaptureCapturePointerEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:369
onScrollUIEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:372
onScrollCaptureUIEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:373
onWheelWheelEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:376
onWheelCaptureWheelEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:377
onAnimationStartAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:380
onAnimationStartCaptureAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:381
onAnimationEndAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:382
onAnimationEndCaptureAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:383
onAnimationIterationAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:384
onAnimationIterationCaptureAnimationEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:385
onTransitionCancelTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:388
onTransitionCancelCaptureTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:389
onTransitionEndTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:390
onTransitionEndCaptureTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:391
onTransitionRunTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:392
onTransitionRunCaptureTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:393
onTransitionStartTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:394
onTransitionStartCaptureTransitionEventHandler<HTMLDivElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:395
onOpenChange((isOpen: boolean) => void) | undefinedNoNot declaredHandler that is called when the overlay's open state changes.node_modules/react-stately/dist/types/src/overlays/useOverlayTriggerState.d.ts:7
renderDOMRenderFunction<"div", PopoverRenderProps> | undefinedNoNot declaredOverrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if `<button>` is expected, you cannot render an `<a>`). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.node_modules/react-aria-components/dist/types/src/utils.d.ts:208
placementundefined | "bottom" | "end" | "left" | "right" | "start" | "top" | "bottom left" | "bottom right" | "bottom start" | "bottom end" | "top left" | "top right" | "top start" | "top end" | "left top" | "left bottom" | "start top" | "start bottom" | "right top" | "right bottom" | "end top" | "end bottom"NoNot declaredThe placement of the element with respect to its anchor element.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:12
defaultOpenundefined | false | trueNoNot declaredWhether the overlay is open by default (uncontrolled).node_modules/react-stately/dist/types/src/overlays/useOverlayTriggerState.d.ts:5
isOpenundefined | false | trueNoNot declaredWhether the overlay is open by default (controlled).node_modules/react-stately/dist/types/src/overlays/useOverlayTriggerState.d.ts:3
containerPaddingnumber | undefinedNoNot declaredThe placement padding that should be applied between the element and its surrounding container.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:19
crossOffsetnumber | undefinedNoNot declaredThe additional offset applied along the cross axis between the element and its anchor element.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:33
shouldFlipundefined | false | trueNoNot declaredWhether the element should flip its orientation (e.g. top to bottom or left to right) when there is insufficient room for it to render completely.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:40
triggerRefRefObject<Element | null> | undefinedNoNot declaredThe ref for the element which the popover positions itself with respect to. When used within a trigger component such as DialogTrigger, MenuTrigger, Select, etc., this is set automatically. It is only required when used standalone.node_modules/react-aria-components/dist/types/src/Popover.d.ts:27
boundaryElementElement | undefinedNoNot declaredElement that that serves as the positioning boundary.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:56
arrowRefRefObject<Element | null> | undefinedNoNot declaredA ref for the popover arrow element.node_modules/react-aria/dist/types/src/overlays/usePopover.d.ts:15
scrollRefRefObject<Element | null> | undefinedNoNot declaredA ref for the scrollable region within the overlay.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:74
shouldUpdatePositionundefined | false | trueNoNot declaredWhether the overlay should update its position automatically.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:80
arrowBoundaryOffsetnumber | undefinedNoNot declaredThe minimum distance the arrow's edge should be from the edge of the overlay element.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:93
getTargetRect((target: Element) => DOMRect | null | undefined) | undefinedNoNot declaredOverrides the target element's bounding rectangle. Useful for positioning relative to a specific point such as the mouse cursor (e.g. context menus) or text selection.node_modules/react-aria/dist/types/src/overlays/useOverlayPosition.d.ts:101
onFocusWithin((e: FocusEvent) => void) | undefinedNoNot declaredHandler that is called when the target element or a descendant receives focus.node_modules/react-aria/dist/types/src/interactions/useFocusWithin.d.ts:7
onBlurWithin((e: FocusEvent) => void) | undefinedNoNot declaredHandler that is called when the target element and all descendants lose focus.node_modules/react-aria/dist/types/src/interactions/useFocusWithin.d.ts:9
onFocusWithinChange((isFocusWithin: boolean) => void) | undefinedNoNot declaredHandler that is called when the the focus within state changes.node_modules/react-aria/dist/types/src/interactions/useFocusWithin.d.ts:11
isNonModalundefined | false | trueNoNot declaredWhether the popover is non-modal, i.e. elements outside the popover may be interacted with by assistive technologies. Most popovers should not use this option as it may negatively impact the screen reader experience. Only use with components such as combobox, which are designed to handle this situation carefully.node_modules/react-aria/dist/types/src/overlays/usePopover.d.ts:30
isKeyboardDismissDisabledundefined | false | trueNoNot declaredWhether pressing the escape key to close the popover should be disabled. Most popovers should not use this option. When set to true, an alternative way to close the popover with a keyboard must be provided.node_modules/react-aria/dist/types/src/overlays/usePopover.d.ts:39
shouldCloseOnInteractOutside((element: Element) => boolean) | undefinedNoNot declaredWhen user interacts with the argument element outside of the popover ref, return true if onClose should be called. This gives you a chance to filter out interaction with elements that should not dismiss the popover. By default, onClose will always be called on interaction outside the popover ref.node_modules/react-aria/dist/types/src/overlays/usePopover.d.ts:46
isEnteringundefined | false | trueNoNot declaredWhether the popover is currently performing an entry animation.node_modules/react-aria-components/dist/types/src/Popover.d.ts:31
isExitingundefined | false | trueNoNot declaredWhether the popover is currently performing an exit animation.node_modules/react-aria-components/dist/types/src/Popover.d.ts:35
shouldSkipAnimationundefined | false | trueNoNot declaredWhether the popover should appear and disappear without an entry or exit animation. This is used by components such as PreviewTrigger to skip animations when quickly swapping between overlays.node_modules/react-aria-components/dist/types/src/Popover.d.ts:41
UNSTABLE_portalContainerElement | undefinedNoNot declaredThe container element in which the overlay portal will be placed. This may have unknown behavior depending on where it is portalled to.node_modules/react-aria-components/dist/types/src/Popover.d.ts:49
xstyleXStyleNoNot declaredpackages/react/src/utils/styled.tsx:7
data-slotunknownNoNot declaredpackages/react/src/utils/styled.tsx:8

Callback state: PopoverRenderProps & { defaultStyle: CSSProperties; }

trigger
string | null
placement
PlacementAxis | null
isEntering
boolean
isExiting
boolean
defaultStyle
CSSProperties

Callback state: PopoverRenderProps & { defaultChildren: ReactNode | undefined; }

trigger
string | null
placement
PlacementAxis | null
isEntering
boolean
isExiting
boolean
defaultChildren
ReactNode

Callback state: PopoverRenderProps

trigger
string | null
placement
PlacementAxis | null
isEntering
boolean
isExiting
boolean

Native HTML and ARIA properties (1) โ€” Property set 1

ColorPickerDialog

({ xstyle, style, ...props }: StyleXProps<ComponentPropsWithRef<typeof Dialog>>): JSX.Element

packages/react/src/components/color-picker/color-picker.tsx:66

react-aria-components/ColorPicker

react-aria-components/Popover

react-aria-components/Dialog

react-aria-components/Button

PropertyTypeRequiredLocal defaultDescription
translateundefined | "yes" | "no"NoNot declarednode_modules/@react-types/shared/src/dom.d.ts:303
hiddenundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:301
styleCSSProperties | undefinedNoNot declaredThe inline [style](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/style) for the element.node_modules/react-aria-components/dist/types/src/utils.d.ts:110
slotstring | null | undefinedNoNot declaredA slot name for the component. Slots allow the component to receive props from a parent component. An explicit `null` value indicates that the local props completely override all props received from a parent.node_modules/react-aria-components/dist/types/src/utils.d.ts:172
dirstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:299
refRef<HTMLElement> | undefinedNoNot declaredAllows getting a ref to the component instance. Once the component unmounts, React will set `ref.current` to `null` (or call the ref with `null` if you passed a callback ref).node_modules/@types/react/index.d.ts:301
idstring | undefinedNoNot declaredThe element's unique identifier. See [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id).node_modules/@react-types/shared/src/dom.d.ts:75
langstring | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:300
roleundefined | "dialog" | "alertdialog"NoNot declaredThe accessibility role for the dialog.node_modules/react-aria/dist/types/src/dialog/useDialog.d.ts:8
inertundefined | false | trueNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:302
aria-describedbystring | undefinedNoNot declaredIdentifies the element (or elements) that describes the object.node_modules/@react-types/shared/src/dom.d.ts:51
aria-detailsstring | undefinedNoNot declaredIdentifies the element (or elements) that provide a detailed, extended description for the object.node_modules/@react-types/shared/src/dom.d.ts:57
aria-labelstring | undefinedNoNot declaredDefines a string value that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:41
aria-labelledbystring | undefinedNoNot declaredIdentifies the element (or elements) that labels the current element.node_modules/@react-types/shared/src/dom.d.ts:46
childrenReactNode | ((opts: DialogRenderProps) => ReactNode)NoNot declaredChildren of the dialog. A function may be provided to access a function to close the dialog.node_modules/react-aria-components/dist/types/src/Dialog.d.ts:21
onAuxClickMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:322
onAuxClickCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:323
onClickMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:320
onClickCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:321
onContextMenuMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:324
onContextMenuCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:325
onDoubleClickMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:326
onDoubleClickCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:327
onMouseDownMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:328
onMouseDownCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:329
onMouseEnterMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:330
onMouseLeaveMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:331
onMouseMoveMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:332
onMouseMoveCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:333
onMouseOutMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:334
onMouseOutCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:335
onMouseOverMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:336
onMouseOverCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:337
onMouseUpMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:338
onMouseUpCaptureMouseEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:339
onTouchCancelTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:342
onTouchCancelCaptureTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:343
onTouchEndTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:344
onTouchEndCaptureTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:345
onTouchMoveTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:346
onTouchMoveCaptureTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:347
onTouchStartTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:348
onTouchStartCaptureTouchEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:349
onPointerDownPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:352
onPointerDownCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:353
onPointerMovePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:354
onPointerMoveCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:355
onPointerUpPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:356
onPointerUpCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:357
onPointerCancelPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:358
onPointerCancelCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:359
onPointerEnterPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:360
onPointerLeavePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:361
onPointerOverPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:362
onPointerOverCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:363
onPointerOutPointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:364
onPointerOutCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:365
onGotPointerCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:366
onGotPointerCaptureCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:367
onLostPointerCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:368
onLostPointerCaptureCapturePointerEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:369
onScrollUIEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:372
onScrollCaptureUIEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:373
onWheelWheelEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:376
onWheelCaptureWheelEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:377
onAnimationStartAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:380
onAnimationStartCaptureAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:381
onAnimationEndAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:382
onAnimationEndCaptureAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:383
onAnimationIterationAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:384
onAnimationIterationCaptureAnimationEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:385
onTransitionCancelTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:388
onTransitionCancelCaptureTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:389
onTransitionEndTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:390
onTransitionEndCaptureTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:391
onTransitionRunTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:392
onTransitionRunCaptureTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:393
onTransitionStartTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:394
onTransitionStartCaptureTransitionEventHandler<HTMLElement> | undefinedNoNot declarednode_modules/@react-types/shared/src/dom.d.ts:395
renderDOMRenderFunction<"section", undefined> | undefinedNoNot declaredOverrides the default DOM element with a custom render function. This allows rendering existing components with built-in styles and behaviors such as router links, animation libraries, and pre-styled components. Requirements: - You must render the expected element type (e.g. if `<button>` is expected, you cannot render an `<a>`). - Only a single root DOM element can be rendered (no fragments). - You must pass through props and ref to the underlying DOM element, merging with your own prop as appropriate.node_modules/react-aria-components/dist/types/src/utils.d.ts:208
xstyleXStyleNoNot declaredpackages/react/src/utils/styled.tsx:7
data-slotunknownNoNot declaredpackages/react/src/utils/styled.tsx:8

Callback state: DialogRenderProps

close
() => void

Native HTML and ARIA properties (1) โ€” Property set 1

ColorPicker

({ children, xstyle, ...props }: ColorPickerRootProps): JSX.Element

packages/react/src/components/color-picker/index.ts:16

ColorPicker.Root, ColorPicker.Trigger, ColorPicker.Popover, ColorPicker.Dialog

PropertyTypeRequiredLocal defaultDescription
slotstring | null | undefinedNoNot declaredA slot name for the component. Slots allow the component to receive props from a parent component. An explicit `null` value indicates that the local props completely override all props received from a parent.node_modules/react-aria-components/dist/types/src/utils.d.ts:172
defaultValuestring | Color | undefinedNoNot declaredThe default value (uncontrolled).node_modules/@react-types/shared/src/inputs.d.ts:73
childrenChildrenOrFunction<ColorPickerRenderProps>YesNot declaredThe children of the component. A function may be provided to alter the children based on component state.node_modules/react-aria-components/dist/types/src/ColorPicker.d.ts:14
onChange((value: Color) => void) | undefinedNoNot declaredHandler that is called when the value changes.node_modules/@react-types/shared/src/inputs.d.ts:75
valuestring | Color | undefinedNoNot declaredThe current value (controlled).node_modules/@react-types/shared/src/inputs.d.ts:71
xstyleXStyleNoNot declaredpackages/react/src/utils/styled.tsx:7
data-slotunknownNoNot declaredpackages/react/src/utils/styled.tsx:8

Callback state: ColorPickerRenderProps & { defaultChildren: ReactNode | undefined; }

color
Color
defaultChildren
ReactNode

Shared native HTML and ARIA properties

Parts with identical inherited property records share one complete table. Different native types remain separate.

Property set 1 (1)

Applies to: ColorPickerTrigger, ColorPickerPopover, ColorPickerDialog

PropertyTypeRequiredLocal defaultDescription
keyKey | null | undefinedNoNot declarednode_modules/@types/react/index.d.ts:259

HeroUI v3.2.6 is the visual and historical reference, not an API compatibility promise. HeroUI v3.2.6