Products · Components
RadioGroup
A set of options where the person picks one.
Put a Radio inside it for each option.
Children: Components
Example
<RadioGroup label="Pay with" value="{{ method }}" onChange="setMethod">
<Radio value="mobile-money" label="Mobile money" />
<Radio value="bank" label="Bank account" />
</RadioGroup>export default definePage({
initialState: { method: 'mobile-money' },
mutations: {
setMethod: (_state, event: ValueEvent) => ({ method: event.detail.value }),
},
});Props
| Prop | Type | What it is |
|---|---|---|
value | string | The chosen radio's value. |
label | string | |
disabled | boolean | Dims it, and the person can't use it. Default: false. |
Events
| Event | Sends | Notes |
|---|---|---|
onChange | { value } in detail | The chosen radio's value. |
Keep reading
RadioOne option in a RadioGroup, with its value and the label people see.ListA list of rows in a card, which can load more rows as the person scrolls.ListItemOne row in a List: a title, a subtitle, an icon or picture, and a value or badge at the end.DetailRowA label and its value on one line, such as a line of a receipt.
