diff --git a/src/avatar.tsx b/src/avatar.tsx index dacc3b8..f4064c5 100644 --- a/src/avatar.tsx +++ b/src/avatar.tsx @@ -4,6 +4,7 @@ import "hono/jsx" import type { FC, JSX } from "hono/jsx" import { VStack, HStack } from "./stack" import { CodeExamples } from "./code" +import { cn } from "./cn" export type AvatarProps = { src: string @@ -24,7 +25,7 @@ export const Avatar: FC = (props) => { ...style, } - return {alt} + return {alt} } export const Test = () => { diff --git a/src/box.tsx b/src/box.tsx index f152a3f..68f444c 100644 --- a/src/box.tsx +++ b/src/box.tsx @@ -1,6 +1,7 @@ import "hono/jsx" import type { FC, PropsWithChildren, JSX } from "hono/jsx" import { CodeExamples } from "./code" +import { cn } from "./cn" type BoxProps = PropsWithChildren & { bg?: string @@ -18,7 +19,7 @@ export const Box: FC = ({ children, bg, color, p, class: className, st ...style, } - return
{children}
+ return
{children}
} // Common demo box colors diff --git a/src/button.tsx b/src/button.tsx index b26161d..590d046 100644 --- a/src/button.tsx +++ b/src/button.tsx @@ -4,6 +4,7 @@ import { VStack, HStack } from "./stack" import { Section } from "./section" import { H2 } from "./text" import { CodeExamples } from "./code" +import { cn } from "./cn" export type ButtonProps = JSX.IntrinsicElements["button"] & { variant?: "primary" | "secondary" | "outline" | "ghost" | "destructive" @@ -11,7 +12,7 @@ export type ButtonProps = JSX.IntrinsicElements["button"] & { } export const Button: FC = (props) => { - const { variant = "primary", size = "md", style, ...buttonProps } = props + const { variant = "primary", size = "md", style, class: className, ...buttonProps } = props const baseStyles: JSX.CSSProperties = { display: "inline-flex", @@ -74,7 +75,7 @@ export const Button: FC = (props) => { ...(style as JSX.CSSProperties), } - return