UNPKG

@coinmeca/ui

Version:

This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).

19 lines 801 B
"use client"; import Style from "./Card.styled"; export default function Card(props) { const scale = props?.scale || 1; const padding = props?.padding || 2; const gap = props?.gap || 1; const handleMouseOver = (e) => { if (typeof props?.onHover === "function") props?.onHover(e); }; const handleClick = (e) => { if (typeof props?.onClick === "function") props?.onClick(e); }; return (<Style $scale={scale} $padding={padding} $gap={gap} $hover={typeof props?.onHover === "function" ? true : false} $event={typeof props?.onClick === "function" ? true : false} style={props?.style} onMouseOver={handleMouseOver} onClick={handleClick}> <div>{props?.children}</div> </Style>); } //# sourceMappingURL=Card.jsx.map