GitHub

/ select

Select

@kumiki/headless/select

Svelte 5 attachments for Select — trigger / listbox / option compound with active-descendant + typeahead.

This component, layer by layer

Styled, copy-paste presets (preview). Run pnpm kumiki add to drop the source into your project, then edit freely.

Live preview

Live preview…

Install
pnpm add @kumiki/atelier
Native-like Select
<script lang="ts">
  import { Tailwind as Select } from '@kumiki/atelier/select';
  type Fruit = 'apple' | 'banana' | 'cherry';
  const items = [
    { id: 'apple',  value: 'apple',  label: 'Apple'  },
    { id: 'banana', value: 'banana', label: 'Banana' },
    { id: 'cherry', value: 'cherry', label: 'Cherry' },
  ];
  let value = $state<Fruit | null>(null);
</script>

<Select.Root {items} bind:value>
  <Select.Trigger>{value ?? 'Pick a fruit'}</Select.Trigger>
  <Select.Listbox>
    {#each items as it (it.id)}
      <Select.Option value={it}>{it.label}</Select.Option>
    {/each}
  </Select.Listbox>
</Select.Root>

/ accessibility

Accessibility

axe-core — run on every PR (LTR + RTL × every documented state).

Keyboard

No component-specific keymap. Inherits standard browser focus / activation behaviour.

Test discipline

  • axe-core — run on every PR (LTR + RTL × every documented state).
  • APG keyboard tests — Playwright, hand-written per pattern.
  • VoiceOver / NVDA — Guidepup nightly schedule.
  • Type-level required names — title / aria-label / aria-labelledby.
Read the W3C ARIA APG pattern ↗