@@ -21,6 +21,7 @@ import type { ResponsiveFontSize } from './CardHeadline';
2121import type { Loading } from './CardPicture' ;
2222import { FeatureCard } from './FeatureCard' ;
2323import { FrontCard } from './FrontCard' ;
24+ import type { SubtitleSize } from './LoopVideoPlayer' ;
2425import type { Alignment } from './SupportingContent' ;
2526
2627type Props = {
@@ -157,6 +158,7 @@ type BoostedSplashProperties = {
157158 supportingContentAlignment : Alignment ;
158159 liveUpdatesAlignment : Alignment ;
159160 trailTextSize : TrailTextSize ;
161+ subtitleSize : SubtitleSize ;
160162 avatarUrl ?: string ;
161163} ;
162164
@@ -187,6 +189,7 @@ const decideSplashCardProperties = (
187189 supportingContentLength >= 4 ? 'horizontal' : 'vertical' ,
188190 liveUpdatesAlignment : 'vertical' ,
189191 trailTextSize : 'regular' ,
192+ subtitleSize : 'medium' ,
190193 } ;
191194 case 'boost' :
192195 return {
@@ -202,6 +205,7 @@ const decideSplashCardProperties = (
202205 supportingContentLength >= 4 ? 'horizontal' : 'vertical' ,
203206 liveUpdatesAlignment : 'vertical' ,
204207 trailTextSize : 'regular' ,
208+ subtitleSize : 'medium' ,
205209 } ;
206210 case 'megaboost' :
207211 return {
@@ -218,6 +222,7 @@ const decideSplashCardProperties = (
218222 supportingContentAlignment : 'horizontal' ,
219223 liveUpdatesAlignment : 'horizontal' ,
220224 trailTextSize : 'large' ,
225+ subtitleSize : 'large' ,
221226 } ;
222227 case 'gigaboost' :
223228 return {
@@ -234,6 +239,7 @@ const decideSplashCardProperties = (
234239 supportingContentAlignment : 'horizontal' ,
235240 liveUpdatesAlignment : 'horizontal' ,
236241 trailTextSize : 'large' ,
242+ subtitleSize : 'large' ,
237243 } ;
238244 }
239245} ;
@@ -298,6 +304,7 @@ const SplashCardLayout = ({
298304 supportingContentAlignment,
299305 liveUpdatesAlignment,
300306 trailTextSize,
307+ subtitleSize,
301308 } = decideSplashCardProperties (
302309 card . boostLevel ?? 'default' ,
303310 card . supportingContent ?. length ?? 0 ,
@@ -347,6 +354,7 @@ const SplashCardLayout = ({
347354 trailTextSize = { trailTextSize }
348355 canPlayInline = { true }
349356 showKickerImage = { card . format . design === ArticleDesign . Audio }
357+ subtitleSize = { subtitleSize }
350358 headlinePosition = { card . showLivePlayable ? 'outer' : 'inner' }
351359 showLabsRedesign = { showLabsRedesign }
352360 enableLoopVideoCORS = { enableLoopVideoCORS }
@@ -361,6 +369,7 @@ type BoostedCardProperties = {
361369 mediaSize : MediaSizeType ;
362370 liveUpdatesPosition : Position ;
363371 supportingContentAlignment : Alignment ;
372+ subtitleSize : SubtitleSize ;
364373} ;
365374
366375/**
@@ -384,6 +393,7 @@ const decideCardProperties = (
384393 liveUpdatesPosition : 'outer' ,
385394 supportingContentAlignment :
386395 supportingContentLength >= 2 ? 'horizontal' : 'vertical' ,
396+ subtitleSize : 'medium' ,
387397 } ;
388398 case 'boost' :
389399 default :
@@ -397,6 +407,7 @@ const decideCardProperties = (
397407 liveUpdatesPosition : 'inner' ,
398408 supportingContentAlignment :
399409 supportingContentLength >= 2 ? 'horizontal' : 'vertical' ,
410+ subtitleSize : 'small' ,
400411 } ;
401412 }
402413} ;
@@ -440,6 +451,7 @@ const FullWidthCardLayout = ({
440451 mediaSize,
441452 supportingContentAlignment,
442453 liveUpdatesPosition,
454+ subtitleSize,
443455 } = decideCardProperties (
444456 card . supportingContent ?. length ?? 0 ,
445457 card . boostLevel ,
@@ -505,6 +517,7 @@ const FullWidthCardLayout = ({
505517 canPlayInline = { true }
506518 showKickerImage = { card . format . design === ArticleDesign . Audio }
507519 showLabsRedesign = { showLabsRedesign }
520+ subtitleSize = { subtitleSize }
508521 enableLoopVideoCORS = { enableLoopVideoCORS }
509522 />
510523 </ LI >
0 commit comments