Label

A form label that pairs with any input and dims when the field is disabled.

Installation

Copy the command below and run it in your terminal.

bunx @sivir/ui add label

Usage

Import Label and pair it with an input:

import { Label } from '$lib/sivir/components/label';
import { Input } from '$lib/sivir/components/input';

<Label for="email">Email</Label>
<Input id="email" type="email" />

Examples

Common usage patterns for Label with form fields.

With email input

With required indicator

Disabled field