bearnie

Select

Dropdown for selecting one option.

Installation

npx bearnie add select
npx bearnie add select

Usage

import { Select } from "@/components/bearnie/select"
<Select placeholder="Select an option">
  <option value="one">Option One</option>
  <option value="two">Option Two</option>
</Select>

Examples

With label

Disabled

Grouped options

Anatomy

  • Select - The dropdown container with native options
  • SelectGroup - Native optgroup wrapper for related options

Props

Select

Prop Type Default Description
id string - Element ID for label association
name string - Form field name
placeholder string - Placeholder option text
disabled boolean false Disables the select
required boolean false Makes selection required
class string - Additional CSS classes