File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { css } from '@emotion/react' ;
2- import { type ArticleFormat } from '../lib/articleFormat' ;
2+ import { ArticleDesign , type ArticleFormat } from '../lib/articleFormat' ;
33import { RightAdsPlaceholder } from './AdPlaceholder.apps' ;
44import { AdSlot } from './AdSlot.web' ;
55import { useConfig } from './ConfigContext' ;
@@ -68,7 +68,9 @@ export const MostViewedRightWithAd = ({
6868 />
6969 ) : null }
7070
71- { ! isPaidContent && ! shouldHideMostViewed ? (
71+ { ! isPaidContent &&
72+ ! shouldHideMostViewed &&
73+ format . design !== ArticleDesign . Interactive ? (
7274 < MostViewedRightWrapper
7375 maxHeightPx = { MAX_HEIGHT_PX }
7476 componentDataAttribute = { componentDataAttribute }
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ import type {
1313} from '@guardian/support-dotcom-components/dist/dotcom/types' ;
1414import type { EpicProps } from '@guardian/support-dotcom-components/dist/shared/types' ;
1515import { useEffect , useState } from 'react' ;
16+ import { grid } from '../grid' ;
1617import { getArticleCounts } from '../lib/articleCount' ;
1718import {
1819 BrazeBannersSystemPlacementId ,
@@ -57,6 +58,10 @@ type Props = {
5758
5859const slotStyles = css `
5960 color: ${ palette . neutral [ 7 ] } ;
61+ ${ grid . container } ;
62+ & > * : first-child {
63+ ${ grid . column . centre } ;
64+ }
6065` ;
6166
6267const buildReaderRevenueEpicConfig = (
Original file line number Diff line number Diff line change @@ -236,12 +236,15 @@ export const SubMeta = ({
236236 format . design === ArticleDesign . Gallery
237237 ? galleryStyles
238238 : bottomPadding ,
239- grid . container ,
240- css `
241- > * {
242- ${ grid . column . centre }
243- }
244- ` ,
239+ format . design === ArticleDesign . Interactive &&
240+ ! isDeprecatedInteractiveLayout
241+ ? css `
242+ ${ grid . container } ;
243+ > * {
244+ ${ grid . column . centre }
245+ }
246+ `
247+ : undefined ,
245248 ] }
246249 >
247250 < StraightLines
Original file line number Diff line number Diff line change @@ -84,7 +84,8 @@ export const StandardLayout = (props: WebProps | AppProps) => {
8484 const interactiveLayoutSwitchoverDate = new Date ( '2024-06-01T00:00:00Z' ) ;
8585 const publicationDate = new Date ( article . webPublicationDate ) ;
8686 const isLegacyInteractive =
87- publicationDate < interactiveLayoutSwitchoverDate ;
87+ publicationDate < interactiveLayoutSwitchoverDate &&
88+ format . design === ArticleDesign . Interactive ;
8889
8990 const showComments = article . isCommentable && ! isPaidContent ;
9091
Original file line number Diff line number Diff line change @@ -171,6 +171,7 @@ const interactiveCss: LayoutCssMap = {
171171 leftCol : `grid-row: 3 / span 2; ${ grid . column . left } ;` ,
172172 } ,
173173 body : {
174+ mobile : `${ grid . column . all } ;` ,
174175 tablet : `grid-row: 6; ${ grid . column . all } ;` ,
175176 leftCol : 'grid-row: 4;' ,
176177 } ,
Original file line number Diff line number Diff line change @@ -216,7 +216,9 @@ export const ArticleRenderer = ({
216216 css = { [
217217 commercialPosition ,
218218 spacefinderAdStyles ,
219- ! isOldInteractive && interactiveLayoutCSS ,
219+ format . design === ArticleDesign . Interactive &&
220+ ! isOldInteractive &&
221+ interactiveLayoutCSS ,
220222 ] }
221223 >
222224 { renderingTarget === 'Apps'
Original file line number Diff line number Diff line change @@ -122,6 +122,8 @@ const spacefinderAdSlotContainerStyles = css`
122122 text-align : center;
123123 display : flex;
124124 justify-content : center;
125+ // TODO: Revisit ads positioning/sizing nicely in interactive body grid
126+ width : 100% ;
125127 max-width : 620px ;
126128 margin-left : 0 ;
127129
You can’t perform that action at this time.
0 commit comments