Select
Select is part of the Forms and selection group. Dropdown value picker for one option from a finite list.
Installation
Section titled “Installation”npx bambiui add select --framework reactnpx bambiui add select --framework solidnpx bambiui add select --framework sveltenpx bambiui add select --framework vueimport { Select, SelectTrigger, SelectValuePart, SelectContent, SelectItem } from "@/components/ui/select";
export function Example() { return <Select />;}import { Select, SelectTrigger, SelectValuePart, SelectContent, SelectItem } from "~/components/ui/select";
export function Example() { return <Select />;}<script lang="ts"> import { Select, SelectTrigger, SelectValuePart, SelectContent, SelectItem } from "$lib/components/ui/select";</script>
<Select /><script setup lang="ts">import { Select, SelectTrigger, SelectValuePart, SelectContent, SelectItem } from "@/components/ui/select";</script>
<template> <Select /></template>Preview
Section titled “Preview”
Select preview should be verified in the target framework after copying the component source. Interactive behavior comes from generated public artifacts, not docs-only mock behavior.
Behavior
Section titled “Behavior”Use when the list is known and too long for radio buttons.
Generated output uses serializable data-* attributes for state and styling. Controlled components fire bambi:<event-name> events and expect application state to update externally; uncontrolled components manage local source state and still fire events.
Accessibility
Section titled “Accessibility”Use semantic labels, visible focus states, and keyboard interaction patterns appropriate for Select. Do not hide required instructions in transient UI. Verify focus movement and disabled states in the installed framework output.
Exports
Section titled “Exports”Select, SelectTrigger, SelectValuePart, SelectContent, SelectItemTokens
Section titled “Tokens”Customize tokens after installing and previewing the component. Relevant tokens include:
--bambi-background--bambi-foreground--bambi-border--bambi-ring