({label, children, ...props}: ColorPickerProps)
| 18 | } |
| 19 | |
| 20 | export function ColorPicker({label, children, ...props}: ColorPickerProps) { |
| 21 | return ( |
| 22 | <AriaColorPicker {...props}> |
| 23 | <DialogTrigger> |
| 24 | <Button className="color-picker"> |
| 25 | <ColorSwatch /> |
| 26 | <span>{label}</span> |
| 27 | </Button> |
| 28 | <Popover hideArrow placement="bottom start" className="color-picker-dialog"> |
| 29 | {children || ( |
| 30 | <> |
| 31 | <ColorArea colorSpace="hsb" xChannel="saturation" yChannel="brightness" /> |
| 32 | <ColorSlider colorSpace="hsb" channel="hue" /> |
| 33 | <ColorField label="Hex" /> |
| 34 | </> |
| 35 | )} |
| 36 | </Popover> |
| 37 | </DialogTrigger> |
| 38 | </AriaColorPicker> |
| 39 | ); |
| 40 | } |
nothing calls this directly
no outgoing calls
no test coverage detected