- Added essential configuration files including components.json, package.json, and tsconfig.json to establish the component library structure. - Introduced global styles in globals.css and layout structure in layout.tsx for consistent design application. - Implemented various UI components such as Accordion, AlertDialog, Button, Card, and more, enhancing the component library for future development. - Included utility functions and hooks to support component functionality and responsiveness. This commit sets up the groundwork for a comprehensive UI component library, facilitating a modular and scalable design system.
28 lines
676 B
TypeScript
28 lines
676 B
TypeScript
import * as React from "react"
|
|
import { cn } from "@/lib/utils"
|
|
|
|
export interface SectionLabelProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
number?: string
|
|
}
|
|
|
|
const SectionLabel = React.forwardRef<HTMLSpanElement, SectionLabelProps>(
|
|
({ className, number, children, ...props }, ref) => {
|
|
return (
|
|
<span
|
|
ref={ref}
|
|
className={cn(
|
|
"block text-[0.75rem] font-semibold uppercase tracking-[0.3em] text-[var(--moss)] mb-3",
|
|
className,
|
|
)}
|
|
{...props}
|
|
>
|
|
{number && <>{number} • </>}
|
|
{children}
|
|
</span>
|
|
)
|
|
},
|
|
)
|
|
SectionLabel.displayName = "SectionLabel"
|
|
|
|
export { SectionLabel }
|