Skip to content

Early previewhamur is not on npm yet. The components are being built in the open, follow along on GitHub.

UIComponentsReact

Select

A button that opens a list to pick one value from.

Built on the headless Select.See its API in Docs

Rendered by React 19.3.1

select.tsx

Installation

npx shadcn@4.23.0 add https://hamur.dev/r/react/select.json

It also adds utils. The app needs its setup first: Installation.

Usage

SelectTrigger shows SelectValue; SelectContent holds SelectItems, grouped with SelectGroup and SelectLabel. Positioning, typeahead and keyboard are the headless Select's.

import {
  Select,
  SelectContent,
  SelectGroup,
  SelectItem,
  SelectLabel,
  SelectScrollDownButton,
  SelectScrollUpButton,
  SelectSeparator,
  SelectTrigger,
  SelectValue,
} from '@/components/ui/select'

Examples

API reference

The styled parts pass every prop to the headless part they wrap and add classes. The props, data attributes and keyboard are on Select's API reference.