Merge branch 'hotfix/image_proxy_in_feed' into 'main'

Feed Shout Cover with imageProxy

See merge request discoursio/discoursio-webapp!87
This commit is contained in:
ilia tapazukk 2023-05-11 14:39:46 +00:00
commit 5304ff6598

View File

@ -14,6 +14,7 @@ import { FeedArticlePopup } from './FeedArticlePopup'
import { useLocalize } from '../../context/localize' import { useLocalize } from '../../context/localize'
import { getPagePath, openPage } from '@nanostores/router' import { getPagePath, openPage } from '@nanostores/router'
import { router, useRouter } from '../../stores/router' import { router, useRouter } from '../../stores/router'
import { imageProxy } from '../../utils/imageProxy'
interface ArticleCardProps { interface ArticleCardProps {
settings?: { settings?: {
@ -104,7 +105,7 @@ export const ArticleCard = (props: ArticleCardProps) => {
<Show when={!props.settings?.noimage && cover}> <Show when={!props.settings?.noimage && cover}>
<div class={styles.shoutCardCoverContainer}> <div class={styles.shoutCardCoverContainer}>
<div class={styles.shoutCardCover}> <div class={styles.shoutCardCover}>
<img src={cover || ''} alt={title || ''} loading="lazy" /> <img src={imageProxy(cover)} alt={title || ''} loading="lazy" />
</div> </div>
</div> </div>
</Show> </Show>