Select

Lets users choose one value from a popup list. Use it when space is limited or the available options do not need to remain visible.

React

Ready

Figma

React examples

Default

import {
  Select,
  SelectContent,
  SelectGroup,
  SelectItem,
  SelectLabel,
  SelectTrigger,
  SelectValue,
} from "@kela-systems/ui-components";

const cameras = {
  "north-gate": "North gate",
  perimeter: "Perimeter",
  "runway-east": "Runway east",
};

export default function SelectDefault() {
  return (
    <Select items={cameras} defaultValue="north-gate">
      <SelectTrigger aria-label="Camera" className="w-52">
        <SelectValue placeholder="Pick a camera" />
      </SelectTrigger>
      <SelectContent>
        <SelectGroup>
          <SelectLabel>Cameras</SelectLabel>
          <SelectItem value="north-gate">North gate</SelectItem>
          <SelectItem value="perimeter">Perimeter</SelectItem>
          <SelectItem value="runway-east">Runway east</SelectItem>
        </SelectGroup>
      </SelectContent>
    </Select>
  );
}

Props

Select

No props of its own. It also takes the props of Base UI's select.

SelectContent

NameDefaultDescription
size
"sm" | "default"
"default"

It also takes the props of Base UI's select.

SelectGroup

No props of its own. It also takes the props of Base UI's select.

SelectItem

No props of its own. It also takes the props of Base UI's select.

SelectLabel

No props of its own. It also takes the props of Base UI's select.

SelectScrollDownButton

No props of its own. It also takes the props of Base UI's select.

SelectScrollUpButton

No props of its own. It also takes the props of Base UI's select.

SelectSeparator

No props of its own. It also takes the props of Base UI's select.

SelectTrigger

NameDefaultDescription
size
"sm" | "default"
"default"

It also takes the props of Base UI's select.

SelectValue

No props of its own. It also takes the props of Base UI's select.

Weigh Select against these before you choose.

Read this page as Markdown

Search ARK

Find a page, a primitive or a component.