sheengemologic ui
All components

Select

A single choice with a scope-aware listbox and native form participation.@gemologic/sheen · forms

Playground

<Select label="Cadence" name="cadence" options={[{ value: "live", label: "Live" }, { value: "manual", label: "Manual" }]} defaultValue="live" />

Variant matrix

Refresh cadence

Anatomy

Package
@gemologic/sheen
Source
packages/ui/src/primitives/Select.tsx
Tokens
  • --sheen-color-border-control
  • --sheen-color-bg-raised
  • --sheen-color-focus-ring

Accessibility

Role: buttonKeyboard: Tab, Space, Enter, Arrow keys, Home, End, Escape, Typeahead

Do

  • Keep option values stable across refreshes.

Do not

  • Do not use Select as an editable autocomplete.

Generated props

NameTypeDefaultDescription
label *string—Required visible label.
options *readonly SelectOption[]—Options keyed by unique nonempty strings, with labels, descriptions, and disabled flags.
valuestring | null—App-owned value; null explicitly clears selection.
defaultValuestring | null—Captured uncontrolled default restored by uncanceled form reset.
onValueChange(value: string | null) => void—Requested value changes; controlled owners may accept or reject.
namestring—Native form field name; unnamed selects do not submit.
formstring—Optional external form ID, associated with the trigger and native select.
placeholderstring—Empty-selection text, defaulting to the localized selectOption message.
descriptionstring—Supporting instructions associated with the trigger.
errorstring—Associated error text and invalid state, without automatic announcements.
disabledbooleanfalsePrevents interaction and submission.
readOnlybooleanfalseAllows inspection but rejects selection changes.
requiredbooleanfalseRequires a nonempty selection for native form submission.
Native Solid/HTML attributes remain available and are omitted from this authored-prop view.