Caption
The <Caption>
component is typically used below images or videos. They will
default to 4 columns wide unless placed inside a <Row>
component. In this
case, it will assume the full width of its containing column.
Example
Normal![Colors Colors](/static/5737718955f2cba55b78b5e66b0cc215/3cbba/design-for-ai-art.png)
This is a regular caption. It will attempt to respond to it’s container element appropriately.
Full-width![Colors Colors](/static/5737718955f2cba55b78b5e66b0cc215/3cbba/design-for-ai-art.png)
This is a full width caption. With this prop, the caption’s width will be 100% so it will fill its container.
Code
NormalFull-widthcomponents/Caption/Caption.js<Caption>This is a regular caption. It will attempt to respond to it’s containerelement appropriately.</Caption>
components/Caption/Caption.js<Caption fullWidth>This is a full width caption. With this prop, the caption’s width will be 100%so it will fill its container.</Caption>
Props
property | propType | required | default | description |
---|---|---|---|---|
children | node | |||
fullWidth | bool | Set to full width | ||
className | string | Add custom class name |