Skip to content

Commit 09c2f0a

Browse files
committed
Restore behaviour for old containers
1 parent 23b9708 commit 09c2f0a

File tree

1 file changed

+33
-0
lines changed
  • dotcom-rendering/src/components/Card

1 file changed

+33
-0
lines changed

dotcom-rendering/src/components/Card/Card.tsx

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,9 +228,40 @@ const HorizontalDivider = () => (
228228
);
229229

230230
const podcastImageStyles = (
231+
imageSize: MediaSizeType,
232+
isBetaContainer: boolean,
231233
fixImageWidth: boolean,
232234
imagePositionOnDesktop: MediaPositionType,
233235
) => {
236+
if (!isBetaContainer) {
237+
switch (imageSize) {
238+
case 'small':
239+
return css`
240+
width: 69px;
241+
height: 69px;
242+
${from.tablet} {
243+
width: 98px;
244+
height: 98px;
245+
}
246+
`;
247+
248+
case 'medium':
249+
return css`
250+
width: 98px;
251+
height: 98px;
252+
${from.tablet} {
253+
width: 120px;
254+
height: 120px;
255+
}
256+
`;
257+
default:
258+
return css`
259+
width: 120px;
260+
height: 120px;
261+
`;
262+
}
263+
}
264+
234265
if (fixImageWidth) {
235266
return css`
236267
width: 69px;
@@ -1126,6 +1157,8 @@ export const Card = ({
11261157
{media.podcastImage?.src && !showKickerImage ? (
11271158
<div
11281159
css={podcastImageStyles(
1160+
mediaSize,
1161+
isBetaContainer,
11291162
!!fixImageWidth,
11301163
mediaPositionOnDesktop,
11311164
)}

0 commit comments

Comments
 (0)