import React from 'react' import styled from 'styled-components' import { Box, BoxProps, H4 } from '..' import { cssClass } from '../utils/css-class' const StyledInfoBox = styled(Box)` display: flex; align-items: center; justify-content: center; flex-direction: column; text-align: center; ` /** * @memberof InfoBox * @alias InfoBoxProps */ export type InfoBoxProps = { /** Title of an InfoBox */ title: string; /** Inner content - usually couple of {@link Text} nodes */ children: React.ReactNode; /** Optional testId */ testId?: string; } /** * @classdesc * * * * Used for all type of information like: * * > you don't have x - please add first one" * * in the system. * * ### Usage * * ```javascript * import { InfoBox, InfoBoxProps } from '@admin-bro/design-system' * ``` * * @component * @subcategory Molecules * @hideconstructor * @see {@link https://storybook.adminbro.com/?path=/story/designsystem-molecules-infobox--default Storybook} * @see InfoBoxProps * @example * return ( * * Currently there are no cars in the system * To create first click * * * ) * @section design-system */ const InfoBox: React.FC = (props) => { const { children, title, testId } = props return (

{title}

{children}
) } export { InfoBox } export default InfoBox