style image blocks along with body elements
This commit is contained in:
@@ -8,7 +8,9 @@ export const ImageWithTextBlock = ({
|
||||
block: ImageWithTextBlockType;
|
||||
}) => {
|
||||
return (
|
||||
<div className={styles.imageWithTextBlock}>
|
||||
<figure
|
||||
className={`${styles.imageWithTextBlock} ${styles[block.imageFormat]}`}
|
||||
>
|
||||
<Image
|
||||
src={block.image.url}
|
||||
alt={block.image.alt ?? ""}
|
||||
@@ -18,8 +20,7 @@ export const ImageWithTextBlock = ({
|
||||
// height={0}
|
||||
// sizes="20vw"
|
||||
/>
|
||||
<div>{block.imageFormat}</div>
|
||||
{block.text && <div>{block.text}</div>}
|
||||
</div>
|
||||
{block.text && <figcaption>{block.text}</figcaption>}
|
||||
</figure>
|
||||
);
|
||||
};
|
||||
|
Reference in New Issue
Block a user