import * as React from 'react'; import { TRule, applyTheme } from '@cloudflare/style-container'; import { TfelaMProps } from '@cloudflare/types'; export type TClassNameProp = { className?: string; }; // //////////////////////////////////////////////////////////////////////// export type TCardProps = { id?: string; testId?: string } & TClassNameProp; export type TCardRule = TRule<{}>; export const CardTheme: TCardRule; export const CardUnstyled: React.StatelessComponent; export const Card: typeof CardUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardBlockProps = {} & TClassNameProp; export type TCardBlockRule = TRule<{}>; export const CardBlockTheme: TCardBlockRule; export const CardBlockUnstyled: React.StatelessComponent; export const CardBlock: typeof CardBlockUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardContentProps = {} & TClassNameProp & TfelaMProps; export type TCardContentRule = TRule<{}>; export const CardContentTheme: TCardContentRule; export const CardContentUnstyled: React.StatelessComponent; export const CardContent: typeof CardContentUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardControlProps = { wide?: boolean } & TClassNameProp; export type TCardControlRule = TRule<{}>; export const CardControlTheme: TCardControlRule; export const CardControlUnstyled: React.StatelessComponent; export const CardControl: typeof CardControlUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardDrawer = { id: string; name: React.ReactNode; ariaLabel: string; content: any; }; export type TCardDrawersProps = { onClick?: (id: string) => void; active?: string; drawers: TCardDrawer[]; // for an optional control to put on the left side of the toolbar controls?: any; }; export type TCardDrawersRule = TRule<{}>; export const CardDrawersTheme: TCardDrawersRule; export const CardDrawersUnstyled: React.StatelessComponent; export const CardDrawers: typeof CardDrawersUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardFooterProps = {} & TClassNameProp; export type TCardFooterRule = TRule<{}>; export const CardFooterTheme: TCardFooterRule; export const CardFooterUnstyled: React.StatelessComponent; export const CardFooter: typeof CardFooterUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardMessagesMessage = { type?: 'info' | 'success' | 'error' | 'warning'; content: any; }; export type TCardMessagesProps = { messages: TCardMessagesMessage[]; } & TClassNameProp; export type TCardMessagesRule = TRule<{}>; export const CardMessagesTheme: TCardMessagesRule; export const CardMessagesUnstyled: React.StatelessComponent; export const CardMessages: typeof CardMessagesUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardSectionProps = { status?: 'default' | 'error'; } & TClassNameProp & TfelaMProps; export type TCardSectionRule = TRule<{}>; export const CardSectionTheme: TCardSectionRule; export const CardSectionUnstyled: React.StatelessComponent; export const CardSection: typeof CardSectionUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardTitleProps = {} & TClassNameProp; export type TCardTitleRule = TRule<{}>; export const CardTitleTheme: TCardTitleRule; export const CardTitleUnstyled: React.StatelessComponent; export const CardTitle: typeof CardTitleUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardToolbarProps = { controls?: any; triggers?: | React.ReactElement[] | React.ReactElement[]; }; export type TCardToolbarRule = TRule<{}>; export const CardToolbarTheme: TCardToolbarRule; export const CardToolbarUnstyled: React.StatelessComponent; export const CardToolbar: typeof CardToolbarUnstyled; // //////////////////////////////////////////////////////////////////////// export type TCardToolbarDrawerTriggerProps = { onClick: () => void; isActive: boolean; id?: string; expandable?: boolean; ariaControls?: string; ariaExpanded?: boolean; }; export const CardToolbarDrawerTrigger: React.StatelessComponent; // //////////////////////////////////////////////////////////////////////// export type TCardToolbarLinkProps = { id?: string; href: string; children: React.ReactNode; }; export const CardToolbarLink: React.StatelessComponent;