feat: optimize display effect when image loading fails

This commit is contained in:
codytseng
2025-02-14 12:17:01 +08:00
parent c4b9b397a6
commit 41d46b1a13
12 changed files with 76 additions and 55 deletions

View File

@@ -48,7 +48,10 @@ export function ImageCarousel({
{images.map((image, index) => (
<CarouselItem key={index} className="xl:basis-2/3 cursor-zoom-in">
<Image
className="xl:rounded-lg"
className="xl:rounded-lg max-h-[75vh]"
classNames={{
errorPlaceholder: 'aspect-square'
}}
image={image}
onClick={(e) => handlePhotoClick(e, index)}
/>