Label
weekendsuperhero-io-sistine/labelUnverifiedComponent
Renders an accessible label associated with controls.
Install it
npx shadcn@latest add https://raw.githubusercontent.com/Weekendsuperhero-io/sistine/main/label.jsonSource
1"use client";23import { Label as LabelPrimitive } from "radix-ui";4import type * as React from "react";56import { cn } from "@/lib/utils";78function Label({9 className,10 required,11 children,12 ...props13}: React.ComponentProps<typeof LabelPrimitive.Root> & {14 /** Appends a destructive asterisk (folded from the glass wrapper). */15 required?: boolean;16}) {17 return (18 <LabelPrimitive.Root19 data-slot="label"20 className={cn(21 "flex items-center gap-2 text-sm leading-none font-medium select-none transition-colors duration-200 group-data-[disabled=true]:pointer-events-none group-data-[disabled=true]:opacity-50 peer-disabled:cursor-not-allowed peer-disabled:opacity-50",22 className,23 )}24 {...props}25 >26 {children}27 {required && <span className="text-destructive ml-1">*</span>}28 </LabelPrimitive.Root>29 );30}3132export { Label };
What it pulls in
npm packages
Other registry items
Files it writes
More from weekendsuperhero-io/sistine
All 71 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Accordionaccordion | weekendsuperhero-io/sistine | Components | Unverified | 5 deps · 4 files | |
| Alertalert | weekendsuperhero-io/sistine | Components | Unverified | 3 deps · 4 files | |
| Alert Dialogalert-dialog | weekendsuperhero-io/sistine | Components | Unverified | 4 deps · 4 files | |
| Auto Foregroundauto-foreground | weekendsuperhero-io/sistine | Components | Unverified | no deps | |
| Avataravatar | weekendsuperhero-io/sistine | Components | Unverified | 4 deps · 4 files | |
| Badgebadge | weekendsuperhero-io/sistine | Components | Unverified | 4 deps · 4 files | |
| Breadcrumbbreadcrumb | weekendsuperhero-io/sistine | Components | Unverified | 5 deps · 4 files | |
| Buttonbutton | weekendsuperhero-io/sistine | Components | Unverified | 4 deps · 4 files |
