Try to use the additional new props for card

Only use imageDescription for now
This commit is contained in:
Lim Chee Aun 2023-10-04 22:40:34 +08:00
parent 5faf911b17
commit 643b6bce07

View file

@ -1551,14 +1551,17 @@ function Card({ card, instance }) {
description, description,
html, html,
providerName, providerName,
providerUrl,
authorName, authorName,
width, width,
height, height,
image, image,
imageDescription,
url, url,
type, type,
embedUrl, embedUrl,
language, language,
publishedAt,
} = card; } = card;
/* type /* type
@ -1631,7 +1634,7 @@ function Card({ card, instance }) {
width={width} width={width}
height={height} height={height}
loading="lazy" loading="lazy"
alt="" alt={imageDescription || ''}
onError={(e) => { onError={(e) => {
try { try {
e.target.style.display = 'none'; e.target.style.display = 'none';