Docs
Toggle Group
Toggle Group
A set of two-state buttons that can be toggled on or off.
Usage
vue
<script setup lang="ts">
import { ToggleGroup, ToggleGroupItem } from "wedges-vue";
</script>
<template>
<ToggleGroup type="single">
<ToggleGroupItem value="a">
A
</ToggleGroupItem>
<ToggleGroupItem value="b">
B
</ToggleGroupItem>
<ToggleGroupItem value="c">
C
</ToggleGroupItem>
</ToggleGroup>
</template>
API Reference
Props
Prop | Type | Default |
---|---|---|
as | AsTag | Component | 'div' |
asChild | boolean | false |
defaultValue | string | string[] | |
dir | 'ltr' | 'rtl' | |
disabled | boolean | false |
loop | boolean | false |
modelValue | string | string[] | |
orientation | 'horizontal' | 'vertical' | 'horizontal' |
rovingFocus | boolean | false |
size | 'sm' | 'md' | 'md' |
type | 'single' | 'multiple' | 'single' |
Emit | Description |
---|---|
update:modelValue |