File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44 headlineBold24 ,
55 remSpace ,
66 textEgyptian17 ,
7+ textSansBold20 ,
78} from '@guardian/source/foundations' ;
89import {
910 ArticleDesign ,
@@ -73,6 +74,16 @@ const globalOlStyles = () => css`
7374 }
7475` ;
7576
77+ const hostedContentH2Styles = ( design : ArticleDesign ) => css `
78+ ${ design === ArticleDesign . HostedArticle &&
79+ `
80+ h2 {
81+ ${ textSansBold20 } ;
82+ margin-bottom: ${ remSpace [ 2 ] } ;
83+ }
84+ ` }
85+ ` ;
86+
7687const globalH3Styles = ( display : ArticleDisplay ) => css `
7788 ${ display === ArticleDisplay . NumberedList &&
7889 `
@@ -145,6 +156,7 @@ export const ArticleBody = ({
145156 const isInteractiveContent =
146157 format . design === ArticleDesign . Interactive ||
147158 format . design === ArticleDesign . Crossword ;
159+ const isHostedContent = format . design === ArticleDesign . HostedArticle ;
148160 const language = decideLanguage ( lang ) ;
149161 const languageDirection = decideLanguageDirection ( isRightToLeftLang ) ;
150162 const hasObserverPublicationTag = tags . find (
@@ -230,6 +242,7 @@ export const ArticleBody = ({
230242 css = { [
231243 `margin-top: ${ remSpace [ 3 ] } ` ,
232244 isInteractiveContent ? null : bodyPadding ,
245+ isHostedContent && hostedContentH2Styles ( format . design ) ,
233246 globalH3Styles ( format . display ) ,
234247 globalOlStyles ( ) ,
235248 globalStrongStyles ,
Original file line number Diff line number Diff line change @@ -176,22 +176,6 @@ export const HostedArticleLayout = (props: WebProps | AppProps) => {
176176 </ Island >
177177 ) }
178178 </ div >
179- < div
180- css = { [
181- grid . column . right ,
182- css `
183- grid-row : 1 ;
184- ` ,
185- ] }
186- >
187- < Caption
188- captionText = { mainMediaCaptionText }
189- format = { format }
190- isMainMedia = { true }
191- />
192-
193- { 'Onward content' }
194- </ div >
195179 < div
196180 css = { [
197181 grid . column . centre ,
@@ -248,6 +232,27 @@ export const HostedArticleLayout = (props: WebProps | AppProps) => {
248232 color = { themePalette ( '--straight-lines' ) }
249233 />
250234 </ div >
235+ < div
236+ css = { [
237+ grid . column . centre ,
238+ css `
239+ grid-row : auto;
240+
241+ ${ from . leftCol } {
242+ ${ grid . column . right }
243+ grid-row : 1 ;
244+ }
245+ ` ,
246+ ] }
247+ >
248+ < Caption
249+ captionText = { mainMediaCaptionText }
250+ format = { format }
251+ isMainMedia = { true }
252+ />
253+
254+ { 'Onward content' }
255+ </ div >
251256 </ div >
252257
253258 < div css = { [ grid . container , border ] } >
You can’t perform that action at this time.
0 commit comments