Fixed issue where some image cards in samples and datasets would show gray instead of the image until you scroll.

This commit is contained in:
Jaret Burkett
2026-06-01 03:36:32 -06:00
parent f5446c0d5f
commit bd468727a6
2 changed files with 2 additions and 12 deletions

View File

@@ -221,11 +221,8 @@ const DatasetImageCard: React.FC<DatasetImageCardProps> = ({
<img
src={blobUrl}
alt={alt}
decoding="async"
onClick={onImageClick}
className={classNames('w-full h-full object-contain transition-opacity duration-300', {
'opacity-100': loaded,
'opacity-0': !loaded,
className={classNames('w-full h-full object-contain', {
'cursor-zoom-in': !!onImageClick,
})}
/>

View File

@@ -133,14 +133,7 @@ const SampleImageCard: React.FC<SampleImageCardProps> = ({
controls={false}
/>
) : blobUrl ? (
<img
src={blobUrl}
alt={alt}
decoding="async"
className={`w-full h-full object-cover transition-opacity duration-300 ${
loaded ? 'opacity-100' : 'opacity-0'
}`}
/>
<img src={blobUrl} alt={alt} className="w-full h-full object-cover" />
) : null
) : null}