diff --git a/components/Caption/Caption.js b/components/Caption/Caption.js new file mode 100644 index 0000000..2b66ce9 --- /dev/null +++ b/components/Caption/Caption.js @@ -0,0 +1,13 @@ +import styles from './Caption.module.css'; + +/** + * A reusable component for captions. + */ + +export default function Caption(ctx) { + const { children: caption, style, id } = ctx; + + return ( +
{caption}
+ ); +} diff --git a/components/Caption/Caption.module.css b/components/Caption/Caption.module.css new file mode 100644 index 0000000..4bb9a54 --- /dev/null +++ b/components/Caption/Caption.module.css @@ -0,0 +1,5 @@ +.caption { + width: 75%; + margin: .5rem 0; + line-height: 1.75; +}