21 lines
505 B
TypeScript
21 lines
505 B
TypeScript
import { ImageWithTextBlock as ImageWithTextBlockType } from "@/gql/graphql";
|
|
import { ImageFigure } from "@/components/general/Image";
|
|
|
|
export function ImageWithTextBlock({
|
|
block,
|
|
}: {
|
|
block: ImageWithTextBlockType;
|
|
}) {
|
|
return (
|
|
<ImageFigure
|
|
src={block.image.url}
|
|
alt={block.image.alt ?? ""}
|
|
width={block.image.width}
|
|
height={block.image.height}
|
|
attribution={block.image.attribution}
|
|
caption={block.text}
|
|
imageFormat={block.imageFormat}
|
|
/>
|
|
);
|
|
}
|