@cfxjs/react-ui
Version:
Modern and minimalist React UI library.
32 lines (31 loc) • 1.11 kB
TypeScript
import React from 'react';
import { CardColors, CardVariants } from '../utils/prop-types';
import CardFooter from './card-footer';
import CardContent from './card-content';
interface Props {
hoverable?: boolean;
shadow?: boolean;
className?: string;
width?: string;
color?: CardColors;
variant?: CardVariants;
}
declare const defaultProps: {
color: "default" | "primary" | "success" | "warning" | "error";
hoverable: boolean;
shadow: boolean;
width: string;
className: string;
variant: "solid" | "line";
};
declare type NativeAttrs = Omit<React.HTMLAttributes<any>, keyof Props>;
export declare type CardProps = Props & typeof defaultProps & NativeAttrs;
declare type MemoCardComponent<P = {}> = React.NamedExoticComponent<P> & {
Footer: typeof CardFooter;
Actions: typeof CardFooter;
Content: typeof CardContent;
Body: typeof CardContent;
};
declare type ComponentProps = Partial<typeof defaultProps> & Omit<Props, keyof typeof defaultProps> & NativeAttrs;
declare const _default: MemoCardComponent<ComponentProps>;
export default _default;