UNPKG

antd

Version:

An enterprise-class UI design language and React components implementation

27 lines (26 loc) 646 B
"use client"; import * as React from 'react'; import { clsx } from 'clsx'; import { ConfigContext } from '../config-provider'; const CardGrid = ({ prefixCls, className, hoverable = true, ...props }) => { const { getPrefixCls } = React.useContext(ConfigContext); const prefix = getPrefixCls('card', prefixCls); const classString = clsx(`${prefix}-grid`, className, { [`${prefix}-grid-hoverable`]: hoverable }); return /*#__PURE__*/React.createElement("div", { ...props, className: classString }); }; if (process.env.NODE_ENV !== 'production') { CardGrid.displayName = 'CardGrid'; } export default CardGrid;