feat(SW-3151): Added original to imageSchema and added transform to a more generic image type
Approved-by: Bianca Widstam Approved-by: Chuma Mcphoy (We Ahead) Approved-by: Matilda Landström
This commit is contained in:
@@ -7,8 +7,8 @@ import { useIntl } from 'react-intl'
|
||||
import { MaterialIcon } from '../Icons/MaterialIcon'
|
||||
import Image from '../Image'
|
||||
import ImageFallback from '../ImageFallback'
|
||||
import { Typography } from '../Typography'
|
||||
import Lightbox from '../Lightbox'
|
||||
import { Typography } from '../Typography'
|
||||
|
||||
import styles from './imageGallery.module.css'
|
||||
|
||||
@@ -16,7 +16,6 @@ export interface GalleryImage {
|
||||
src: string
|
||||
alt: string
|
||||
caption?: string | null
|
||||
smallSrc?: string | null
|
||||
}
|
||||
|
||||
type ImageGalleryProps = {
|
||||
@@ -50,7 +49,7 @@ function ImageGallery({
|
||||
}
|
||||
: { height, width: height * 1.5 }
|
||||
|
||||
if (!images || images.length === 0 || imageError) {
|
||||
if (!images?.length || imageError) {
|
||||
return <ImageFallback />
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user