Skip to main content

SideLabel

Storybook​

Go to Story

SideLabelProps​

type SideLabelProps = Omit<ComponentProps<"label">, "label"> & object;

Defined in: src/components/SideLabel/SideLabel.tsx:12

Type Declaration​

NameTypeDescriptionDefined in
label?ReactNodeElement that describes form inputsrc/components/SideLabel/SideLabel.tsx:16
reverse?booleanShow label on right side.src/components/SideLabel/SideLabel.tsx:20
center?booleanCenter content vertically. Useful to disable centering if the label is complex and spans multiple lines. Default truesrc/components/SideLabel/SideLabel.tsx:26

SideLabel()​

function SideLabel(__namedParameters): Element;

Defined in: src/components/SideLabel/SideLabel.tsx:40

Component for creating labeled form controls like radio, checkbox or switch.

Parameters​

ParameterType
__namedParametersSideLabelProps

Returns​

Element

Example​

// Basic usage with Checkbox
<SideLabel label="Enable notifications">
<Checkbox />
</SideLabel>