diff --git a/.ladle/image.png b/.ladle/image.png new file mode 100644 index 0000000..d40dd40 Binary files /dev/null and b/.ladle/image.png differ diff --git a/src/Card.stories.tsx b/src/Card.stories.tsx new file mode 100644 index 0000000..8258aac --- /dev/null +++ b/src/Card.stories.tsx @@ -0,0 +1,12 @@ +import Card from './Card' + +export const Default = () => ( + null} + /> +) + +export const ContentOnly = () => diff --git a/src/Card.tsx b/src/Card.tsx new file mode 100644 index 0000000..0ac0315 --- /dev/null +++ b/src/Card.tsx @@ -0,0 +1,75 @@ +import { twMerge } from 'tailwind-merge' + +import Button from './Button' + +export interface CardProps { + backgroundSrc?: string + className?: string + disabled?: boolean + tags?: string[] + title?: string + + onClick?: () => void +} + +const defaultProps = { + disabled: false, + tags: [], +} + +export function Card({ + backgroundSrc, + className, + disabled, + tags, + title, + onClick, +}: CardProps) { + if (onClick) { + return ( + + ) + } + + return
hello
+} + +Card.defaultProps = defaultProps + +export default Card