created:7/7/2021
updated:7/7/2021
loc
98
comments
12%
passed
6
failed
10
coverage
88%
Card
grommet-controls
3.0.2A Card-type container, all props of Box apply
Name | Description | Default | |
---|---|---|---|
ICardProps(1 properties) | |||
children | children card elements to be displayed ReactNode | - | |
BoxProps(28 properties) |
package | imports | peer |
---|---|---|
grommet ^2.15.0 | HeadingPropsHeadingBoxPropsBox | * |
react ^17.0.1 | React | * |
styled-components ^5.1.1 | ThemeContext | * |
file | imports |
---|---|
"./CardProps" | ICardPropsICardTitlePropsICardContentPropsICardActionsProps |
"./StyledCard" | StyledCard |
<ThemeContext.Consumer>
styled-components
^5.1.1<StyledCard
themeoverflow
/>StyledCard
from"./StyledCard"
<Box
alignpadgapborderflexfilldirection
/>grommet
^2.15.0<Box
directionfillbordergapflex
>grommet
^2.15.0<Heading
levelmargincolortextAligntruncateresponsive
>grommet
^2.15.0<strong/>
strong
<Box
padfillflex
/>grommet
^2.15.0
Info card
sub-title info

- config
- source
({border,align,direction,pad,imageStamp,title,level,fit,image,height,}) => (<Card><Card.CardTitleborder={border}align={align}direction={direction}pad={pad}><Box direction="row"><ImageStamp {...imageStamp} /><Heading level={level} margin="xsmall">{title}</Heading></Box><Box direction="row"><Bitcoin color="plain" /><Text>sub-title info</Text></Box></Card.CardTitle><Card.CardContent><Image fit={fit} src={image} height={`${height}`} /></Card.CardContent><Card.CardActions justify="center">{actions.map((action, index) => (<Buttonkey={`actions_${index}`}label={action.label}onClick={action.onClick}/>))}</Card.CardActions></Card>)
Card
