Skip to Content
DocumentationLabel

Label

Renders an accessible label associated with controls.

Examples

Regular

Block

When block is true, the label displays as a bordered block with padding, useful for card-style labels or form sections (e.g. with Switch and description).

API

Root

Contains the content for the label.

PropertyTypeDefaultDescription
asChildbooleanfalseChange the default rendered element for the one passed as a child, merging their props and behavior.
htmlForstring-The id of the element the label is associated with.
variant”regular""regular”The visual style of the label.
size”sm” | “md” | “lg""md”The size of the label.
blockbooleanfalseWhen true, displays the label as a block with border, padding, and full-width layout (items-start, justify-between). Useful for card-style or form section labels.
Last updated on