Skip to content

Commit 779cef3

Browse files
authored
fix: header block video microdata (#1124)
1 parent 7853757 commit 779cef3

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/blocks/Header/Header.tsx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,10 +98,13 @@ export const HeaderBlock = (props: React.PropsWithChildren<HeaderBlockFullProps>
9898
const backgroundThemed = background && getThemedValue(background, theme);
9999
const imageThemed = image && getThemedValue(image, theme);
100100
const videoThemed = video && getThemedValue(video, theme);
101-
const mediaWithMicrodata = mergeVideoMicrodata(videoThemed, {
102-
name: title,
103-
description,
104-
});
101+
const mediaWithMicrodata = mergeVideoMicrodata(
102+
{video: videoThemed, image: imageThemed},
103+
{
104+
name: title,
105+
description,
106+
},
107+
);
105108
const fullWidth = backgroundThemed?.fullWidth || backgroundThemed?.fullWidthMedia;
106109
const titleId = useUniqId();
107110

@@ -190,7 +193,6 @@ export const HeaderBlock = (props: React.PropsWithChildren<HeaderBlockFullProps>
190193
videoClassName={b('video')}
191194
imageClassName={b('image')}
192195
{...mediaWithMicrodata}
193-
image={imageThemed}
194196
/>
195197
)}
196198
</Col>

0 commit comments

Comments
 (0)