File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
dotcom-rendering/src/components Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 11import { css } from '@emotion/react' ;
2- import { joinUrl } from '@guardian/libs' ;
2+ import { isUndefined , joinUrl } from '@guardian/libs' ;
33import {
4+ ArticleDesign ,
45 type ArticleFormat ,
56 type ArticleTheme ,
67 Pillar ,
@@ -303,6 +304,11 @@ export const OnwardsUpper = ({
303304 ? getContainerDataUrl ( pillar , editionId , ajaxUrl )
304305 : undefined ;
305306
307+ // For galleries: they already have a "more galleries" container,
308+ // so we can only allow one more onwards container
309+ const canHaveCuratedContent =
310+ format . design === ArticleDesign . Gallery ? isUndefined ( url ) : true ;
311+
306312 return (
307313 < div css = { onwardsWrapper } >
308314 { ! ! url && (
@@ -322,7 +328,7 @@ export const OnwardsUpper = ({
322328 />
323329 </ Section >
324330 ) }
325- { ! ! curatedDataUrl && ! isPaidContent && (
331+ { ! ! curatedDataUrl && ! isPaidContent && canHaveCuratedContent && (
326332 < Section
327333 fullWidth = { true }
328334 borderColour = { palette ( '--article-section-border' ) }
You can’t perform that action at this time.
0 commit comments