Radio Group


Palette
Size
Label position
Enabled
Disabled
Individual disabled


Svelte
<script lang="ts">
    let selected: string = $state("tgv");

    const options = [
        { value: "tgv", label: "TGV" },
        { value: "concorde", label: "Concorde" },
        { value: "minitel", label: "Minitel" },
        { value: "ariane", label: "Ariane" },
    ];
</script>

<RadioGroup
    bind:value={selected}
    {options}
    name="transport"
    palette="accent"
/>

API


PropTypeDefault
valuestringundefined
optionsOption[][]
namestring—
palette"accent" | "tone""accent"
size"sm" | "md" | "lg""md"
label_position"right" | "left" | "top" | "bottom""right"
disabledbooleanfalse
aria_labelstring—
Prop value
Type string
Default undefined
Prop options
Type Option[]
Default []
Prop name
Type string
Default —
Prop palette
Type "accent" | "tone"
Default "accent"
Prop size
Type "sm" | "md" | "lg"
Default "md"
Prop label_position
Type "right" | "left" | "top" | "bottom"
Default "right"
Prop disabled
Type boolean
Default false
Prop aria_label
Type string
Default —