Docs
Toggle Group

Toggle Group

A set of two-state buttons that can be toggled on or off.

Installation

	npx shadcn-svelte@next add toggle-group

Usage

	<script lang="ts">
  import * as ToggleGroup from "$lib/components/ui/toggle-group/index.js";
</script>
 
<ToggleGroup.Root type="single">
  <ToggleGroup.Item value="a">A</ToggleGroup.Item>
  <ToggleGroup.Item value="b">B</ToggleGroup.Item>
  <ToggleGroup.Item value="c">C</ToggleGroup.Item>
</ToggleGroup.Root>

Examples

Default

Outline

Single

Small

Large

Disabled