Forms
Navigation & layout
Data display & feedback
Date & time
Browse components
← All components
Color Area
2D color area. Must sit inside ColorPicker.
Install
npx shadcn@latest add https://ui.anuragroy.dev/r/color-area.jsonPreview
Loading preview…
Installation
Add the component from this site. The shadcn CLI fetches the registry JSON over HTTPS — no named registry submission required.
Terminal
npx shadcn@latest add https://ui.anuragroy.dev/r/color-area.jsonGitHub fallback if the website is down:
Terminal
npx shadcn@latest add https://raw.githubusercontent.com/anurag-roy/ui.anuragroy.dev/main/public/r/color-area.jsonUsage
Import paths follow your components.json aliases. After install, the default path is @/components/ui/color-area.
Import
import { ColorArea } from "@/components/ui/color-area"example.tsx
import { ColorArea } from "@/components/ui/color-area"import { ColorPicker } from "@/components/ui/color-picker"export function Example() { return ( <ColorPicker defaultValue="#3b82f6"> <ColorArea colorSpace="hsb" xChannel="saturation" yChannel="brightness" className="h-44 w-64" /> </ColorPicker> )}API Reference
ColorArea
React Aria ColorArea. `ColorThumb` is also exported.
| Prop | Type | Default |
|---|---|---|
| colorSpace | ColorSpace | — |
| xChannel | ColorChannel | — |
| yChannel | ColorChannel | — |
Notes
- The color family uses `react-aria-components`, not Base UI.