File tree 3 files changed +4
-4
lines changed
dotcom-rendering/src/components/Card 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -732,6 +732,7 @@ export const Card = ({
732
732
showTopBarMobile = { showTopBarMobile }
733
733
containerPalette = { containerPalette }
734
734
isOnwardContent = { isOnwardContent }
735
+ cardBackgroundColour = { backgroundColour }
735
736
>
736
737
< CardLink
737
738
linkTo = { linkTo }
@@ -782,7 +783,6 @@ export const Card = ({
782
783
) }
783
784
784
785
< CardLayout
785
- cardBackgroundColour = { backgroundColour }
786
786
imagePositionOnDesktop = { imagePositionOnDesktop }
787
787
imagePositionOnMobile = { imagePositionOnMobile }
788
788
minWidthInPixels = { minWidthInPixels }
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ export type GapSizes = { row: GapSize; column: GapSize };
13
13
14
14
type Props = {
15
15
children : React . ReactNode ;
16
- cardBackgroundColour : string ;
17
16
imageType : CardImageType | undefined ;
18
17
imagePositionOnDesktop : ImagePositionType ;
19
18
imagePositionOnMobile : ImagePositionType ;
@@ -173,7 +172,6 @@ const isVerticalLayout = (imagePosition: ImagePositionType) => {
173
172
174
173
export const CardLayout = ( {
175
174
children,
176
- cardBackgroundColour,
177
175
imagePositionOnDesktop,
178
176
imagePositionOnMobile,
179
177
minWidthInPixels,
@@ -199,7 +197,6 @@ export const CardLayout = ({
199
197
isVerticalLayout ( imagePositionOnDesktop ) && desktopFlexBasis ,
200
198
] }
201
199
style = { {
202
- backgroundColor : cardBackgroundColour ,
203
200
rowGap : decideGap ( gapSizes . row ) ,
204
201
columnGap : decideGap ( gapSizes . column ) ,
205
202
} }
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ import { FormatBoundary } from '../../FormatBoundary';
9
9
type Props = {
10
10
children : React . ReactNode ;
11
11
format : ArticleFormat ;
12
+ cardBackgroundColour : string ;
12
13
containerPalette ?: DCRContainerPalette ;
13
14
showTopBarDesktop ?: boolean ;
14
15
showTopBarMobile ?: boolean ;
@@ -98,6 +99,7 @@ export const CardWrapper = ({
98
99
showTopBarDesktop = true ,
99
100
showTopBarMobile = false ,
100
101
isOnwardContent = false ,
102
+ cardBackgroundColour,
101
103
} : Props ) => {
102
104
return (
103
105
< FormatBoundary format = { format } >
@@ -111,6 +113,7 @@ export const CardWrapper = ({
111
113
showTopBarMobile && mobileTopBarStyles ,
112
114
isOnwardContent && onwardContentStyles ,
113
115
] }
116
+ style = { { backgroundColor : cardBackgroundColour } }
114
117
>
115
118
{ children }
116
119
</ div >
You can’t perform that action at this time.
0 commit comments