Skip to content

Commit 846c515

Browse files
committed
Fix #3495
1 parent 852f986 commit 846c515

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

web/core/Carousel/CarouselImageItem.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,8 @@ export const CarouselImageItem = forwardRef<
170170
if (isImageWithOverlay) {
171171
return (
172172
<ImageWithOverlay
173+
ref={ref}
174+
className={`aspect-4/3 rounded-md md:aspect-video`}
173175
teaserTitle={captionTeaserTitle}
174176
//@ts-ignore:TODO
175177
title={captionTitle as PortableTextBlock[]}

web/core/ImageWithOverlay/ImageWithOverlay.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
'use client'
2-
import { Typography } from '@equinor/eds-core-react'
32
import type { PortableTextBlock } from '@portabletext/types'
43
import type { SanityImageObject } from '@sanity/image-url'
54
import { useTranslations } from 'next-intl'
@@ -9,10 +8,10 @@ import { twMerge } from 'tailwind-merge'
98
import type { DisplayModes } from '@/core/Carousel/Carousel'
109
import { getUrlFromAction } from '@/lib/helpers/getUrlFromAction'
1110
import Blocks from '../../portableText/Blocks'
12-
import { getLocaleFromName } from '../../sanity/helpers/localization'
1311
import type { ImageWithAlt, LinkData } from '../../types'
1412
import { Image } from '../Image/Image'
1513
import ResourceLink from '../Link/ResourceLink'
14+
import { Typography } from '../Typography'
1615

1716
export type ImageWithOverlayProps = {
1817
image?: SanityImageObject
@@ -114,7 +113,7 @@ export const ImageWithOverlay = forwardRef<
114113
>
115114
<div className={`pb-1 lg:pb-6`}>
116115
{title && (
117-
<Typography as='h2' variant='h4' className='text-md lg:text-lg'>
116+
<Typography as='h2' variant='h4' className='text-md lg:text-lg text-white-100'>
118117
{plainText}
119118
</Typography>
120119
)}

0 commit comments

Comments
 (0)