Sections
Components
- AlertBanner
- AlertDialog
- Alert
- Avatar
- Badge
- Breadcrumb
- Button
- CalendarIcon
- CellLayout
- CellLink
- Checkbox
- Collapse
- ContentSwitcher
- ControlLabel
- DatePicker
- Dialog
- Divider
- Drawer
- EmptyCell
- EmptyState
- Empty
- ErrorOverlay
- FilterBar
- FilterChips
- Flex
- GridLayout
- HumanisedDate
- Icon
- InputDuration
- InputField
- Input
- Label
- Loader
- MoreActions
- NumberInput
- OutsideClickHandler
- PageLoader
- Page
- Popconfirm
- Popover
- ProgressPie
- Progress
- RadioButtonGroup
- RadioGroup
- Radio
- RelativeTime
- Resizable
- SearchInput
- Select
- SkeletonText
- Skeleton
- Space
- SquadAvatarList
- StatusPicker
- Stepper
- Switch
- TableLight
- Tabs
- Tag
- Text
- Textarea
- Toast
- Tooltip
- TriggerSelect
- Upload
import { RadioGroup, Radio, ControlLabel } from "@/rl-ui";
<RadioGroup defaultValue="email" layout="vertical">
<ControlLabel label="Email" control={<Radio value="email" />} />
<ControlLabel label="SMS" control={<Radio value="sms" />} />
<ControlLabel label="Push" control={<Radio value="push" />} />
</RadioGroup>Examples#
Horizontal layout#
import { RadioGroup, Radio, ControlLabel } from "@/rl-ui";
<RadioGroup defaultValue="a" layout="horizontal">
<ControlLabel label="Option A" control={<Radio value="a" />} />
<ControlLabel label="Option B" control={<Radio value="b" />} />
<ControlLabel label="Option C" control={<Radio value="c" />} />
</RadioGroup>API#
| Prop | Type | Default | Description |
|---|---|---|---|
layout | "vertical" | "horizontal" | "vertical" | Item arrangement. |
value | string | — | Controlled value. |
defaultValue | string | — | Uncontrolled initial value. |
onValueChange | (value: string) => void | — | Change handler. |
disabled | boolean | false | Disable the group. |