Skip to content

Commit

Permalink
refactor(templates/hompage): updated props
Browse files Browse the repository at this point in the history
  • Loading branch information
seaerchin authored and seaerchin committed Sep 6, 2023
1 parent b337567 commit 5b57b2c
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 12 deletions.
23 changes: 17 additions & 6 deletions src/templates/homepage/InfopicLeftSection.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ const TemplateInfopicLeftSection = (
description,
button,
sectionIndex,
imageUrl,
imageAlt,
siteName,
image: imageUrl,
alt: imageAlt,
},
ref
) => {
Expand Down Expand Up @@ -94,7 +93,11 @@ const TemplateInfopicLeftSection = (
</div>
</div>
<div className={getClassNames(editorStyles, ["col", "is-half"])}>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
</div>
{/* For tablet */}
Expand Down Expand Up @@ -155,7 +158,11 @@ const TemplateInfopicLeftSection = (
"padding--bottom--xl",
])}
>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
</div>
{/* For desktop */}
Expand Down Expand Up @@ -224,7 +231,11 @@ const TemplateInfopicLeftSection = (
"padding--bottom--xl",
])}
>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
</div>
</div>
Expand Down
23 changes: 17 additions & 6 deletions src/templates/homepage/InfopicRightSection.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ const TemplateInfopicRightSection = (
description,
button,
sectionIndex,
imageUrl,
imageAlt,
siteName,
image: imageUrl,
alt: imageAlt,
},
ref
) => {
Expand Down Expand Up @@ -95,7 +94,11 @@ const TemplateInfopicRightSection = (
</div>
</div>
<div className={getClassNames(editorStyles, ["col", "is-half"])}>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
</div>
{/* For tablet */}
Expand All @@ -114,7 +117,11 @@ const TemplateInfopicRightSection = (
"padding--bottom--xl",
])}
>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
<div className={getClassNames(editorStyles, ["col", "is-half"])}>
<p
Expand Down Expand Up @@ -174,7 +181,11 @@ const TemplateInfopicRightSection = (
"padding--bottom--xl",
])}
>
<img onError={addDefaultSrc} src={loadedImageURL} alt={alt} />
<img
onError={addDefaultSrc}
src={loadedImageURL}
alt={imageAlt}
/>
</div>
<div
className={getClassNames(editorStyles, [
Expand Down

0 comments on commit 5b57b2c

Please sign in to comment.