feat(WEB-249): first iteration design system primitives (typography, grid)
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
import { subtitleVariants } from "./variants"
|
||||
|
||||
import type { SubtitleProps } from "./subtitle"
|
||||
|
||||
export default function Subtitle({
|
||||
children,
|
||||
className = "",
|
||||
color,
|
||||
hideEmpty = true,
|
||||
textTransform,
|
||||
}: SubtitleProps) {
|
||||
if (hideEmpty && !children) {
|
||||
return null
|
||||
}
|
||||
const classNames = subtitleVariants({
|
||||
className,
|
||||
color,
|
||||
textTransform,
|
||||
})
|
||||
return <p className={classNames}>{children}</p>
|
||||
}
|
||||
Reference in New Issue
Block a user