File tree Expand file tree Collapse file tree 2 files changed +15
-10
lines changed
dotcom-rendering/src/components Expand file tree Collapse file tree 2 files changed +15
-10
lines changed Original file line number Diff line number Diff line change @@ -43,15 +43,8 @@ const wideIconStyles = (
43
43
}
44
44
` ;
45
45
46
- const narrowPlayIconWidth = 56 ;
46
+ export const narrowPlayIconWidth = 56 ;
47
47
const narrowStyles = css `
48
- position : absolute;
49
- /**
50
- * Subject to change. We will wait to see how fronts editors use the
51
- * headlines and standfirsts before we decide on a final position.
52
- */
53
- top : 35% ;
54
- left : calc (50% - ${ narrowPlayIconWidth / 2 } px);
55
48
width : ${ narrowPlayIconWidth } px;
56
49
height : ${ narrowPlayIconWidth } px;
57
50
display : flex;
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ import { secondsToDuration } from '../../lib/formatTime';
6
6
import { palette } from '../../palette' ;
7
7
import type { AspectRatio } from '../../types/front' ;
8
8
import { CardFooter } from '../Card/components/CardFooter' ;
9
- import { PlayIcon } from '../Card/components/PlayIcon' ;
9
+ import { narrowPlayIconWidth , PlayIcon } from '../Card/components/PlayIcon' ;
10
10
import { TrailText } from '../Card/components/TrailText' ;
11
11
import type { ResponsiveFontSize } from '../CardHeadline' ;
12
12
import { CardHeadline } from '../CardHeadline' ;
@@ -87,6 +87,16 @@ const immersiveOverlayStyles = css`
87
87
}
88
88
` ;
89
89
90
+ const playIconStyles = css `
91
+ position: absolute;
92
+ /**
93
+ * Subject to change. We will wait to see how fronts editors use the
94
+ * headlines and standfirsts before we decide on a final position.
95
+ */
96
+ to p: 35%;
97
+ left: calc(50% - ${ narrowPlayIconWidth / 2 } px);
98
+ ` ;
99
+
90
100
const videoPillStyles = css `
91
101
position: absolute;
92
102
to p: ${ space [ 2 ] } px;
@@ -183,7 +193,9 @@ export const YoutubeAtomFeatureCardOverlay = ({
183
193
</ div >
184
194
) : null }
185
195
< div className = "image-overlay" />
186
- < PlayIcon iconWidth = "narrow" />
196
+ < div css = { playIconStyles } >
197
+ < PlayIcon iconWidth = "narrow" />
198
+ </ div >
187
199
< div
188
200
css = { [
189
201
textOverlayStyles ,
You can’t perform that action at this time.
0 commit comments