Add guard for loaded blur images

This commit is contained in:
Sam Becker 2024-02-23 16:52:17 -06:00
parent f9625f18b5
commit 7b192b003c

View File

@ -59,7 +59,7 @@ export default function ImageBlurFallback(props: ImageProps) {
imageClassName,
'relative z-10',
'transition-opacity duration-300 ease-in',
isLoading ? 'opacity-0' : 'opacity-100',
!isLoading || !showPlaceholder ? 'opacity-100' : 'opacity-0',
),
onLoad: () => {
setIsLoading(false);