common/app/views/fragments/items/facia_cards/contentCard.scala.html [101:185]: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @item.displayElement.filter(const(item.showDisplayElement)) match { case Some(InlineVideo(videoElement, title, fallback)) if item.cardTypes.showVideoPlayer => { @defining(VideoPlayer( videoElement, Video640, title, autoPlay = false, showControlsAtStart = false, overrideIsRatioHd = Some(false), // We only pass in the ID if this is a video or audio block, as if it's a mainMedia video, the // ID is actually pointing to the article, which is wrong. It would be nice to have the ID on the // ContentCard, but we don't for now. Annoyingly this doesn't allow us to check for if we should // play ads or if the video is expired, but as fronts change really often, this is a non-problem. embedPath = if (item.isMediaLink) item.id else None, path = if (item.isMediaLink) item.id else None )) { player => @fallback.map { fallbackImage =>
@fragments.inlineSvg("play", "icon")
@itemImage( fallbackImage.imageMedia, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} } } case Some(svg@CrosswordSvg(_)) => {
} case Some(media@InlineYouTubeMediaAtom(_,_)) => {
@youtube( media = media.youTubeAtom, displayCaption = false, displayDuration = false, playable = item.cardTypes.showYouTubeMediaAtomPlayer, posterImageOverride = media.posterImageOverride, cardStyle = Some(item.cardStyle))
} case Some(InlineVideo(_, _, Some(fallbackImage))) => {
@itemImage( fallbackImage.imageMedia, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} case Some(InlineImage(images)) => {
@item.starRating.map { rating => @starRating(rating) } @itemImage( images, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} case Some(InlineSlideshow(imageElements)) => { @defining(imageElements.take(10)) { slides =>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - common/app/views/fragments/items/facia_cards/dynamoContentCard.scala.html [106:190]: - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @item.displayElement.filter(const(item.showDisplayElement)) match { case Some(InlineVideo(videoElement, title, fallback)) if item.cardTypes.showVideoPlayer => { @defining(VideoPlayer( videoElement, Video640, title, autoPlay = false, showControlsAtStart = false, overrideIsRatioHd = Some(false), // We only pass in the ID if this is a video or audio block, as if it's a mainMedia video, the // ID is actually pointing to the article, which is wrong. It would be nice to have the ID on the // ContentCard, but we don't for now. Annoyingly this doesn't allow us to check for if we should // play ads or if the video is expired, but as fronts change really often, this is a non-problem. embedPath = if (item.isMediaLink) item.id else None, path = if (item.isMediaLink) item.id else None )) { player => @fallback.map { fallbackImage =>
@fragments.inlineSvg("play", "icon")
@itemImage( fallbackImage.imageMedia, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} } } case Some(svg@CrosswordSvg(_)) => {
} case Some(media@InlineYouTubeMediaAtom(_,_)) => {
@youtube( media = media.youTubeAtom, displayCaption = false, displayDuration = false, playable = item.cardTypes.showYouTubeMediaAtomPlayer, posterImageOverride = media.posterImageOverride, cardStyle = Some(item.cardStyle))
} case Some(InlineVideo(_, _, Some(fallbackImage))) => {
@itemImage( fallbackImage.imageMedia, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} case Some(InlineImage(images)) => {
@item.starRating.map { rating => @starRating(rating) } @itemImage( images, inlineImage = containerIndex == 0 && index < 4, widthsByBreakpoint = Some(item.mediaWidthsByBreakpoint), shouldLazyLoad = containerIndex > 2 )
} case Some(InlineSlideshow(imageElements)) => { @defining(imageElements.take(10)) { slides =>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -