Skip to content

Commit 56ccf0e

Browse files
committed
Pass a 5:4 aspect ratio to containers used by tag pages to bring tag page images in line with modern designs.
1 parent 47f23d6 commit 56ccf0e

File tree

4 files changed

+165
-2
lines changed

4 files changed

+165
-2
lines changed

dotcom-rendering/src/components/DecideContainerByTrails.stories.tsx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ export default {
1818
},
1919
};
2020

21+
const ASPECT_RATIO = '5:4';
22+
2123
export const OneCardFast = () => {
2224
return (
2325
<FrontSection
@@ -29,6 +31,7 @@ export const OneCardFast = () => {
2931
trails={trails.slice(0, 1)}
3032
speed="fast"
3133
imageLoading="eager"
34+
aspectRatio={ASPECT_RATIO}
3235
/>
3336
</FrontSection>
3437
);
@@ -46,6 +49,7 @@ export const TwoCardFast = () => {
4649
trails={trails.slice(0, 2)}
4750
speed="fast"
4851
imageLoading="eager"
52+
aspectRatio={ASPECT_RATIO}
4953
/>
5054
</FrontSection>
5155
);
@@ -63,6 +67,7 @@ export const ThreeCardFast = () => {
6367
trails={trails.slice(0, 3)}
6468
speed="fast"
6569
imageLoading="eager"
70+
aspectRatio={ASPECT_RATIO}
6671
/>
6772
</FrontSection>
6873
);
@@ -80,6 +85,7 @@ export const FourCardFast = () => {
8085
trails={trails.slice(0, 4)}
8186
speed="fast"
8287
imageLoading="eager"
88+
aspectRatio={ASPECT_RATIO}
8389
/>
8490
</FrontSection>
8591
);
@@ -97,6 +103,7 @@ export const FiveCardFast = () => {
97103
trails={trails.slice(0, 5)}
98104
speed="fast"
99105
imageLoading="eager"
106+
aspectRatio={ASPECT_RATIO}
100107
/>
101108
</FrontSection>
102109
);
@@ -114,6 +121,7 @@ export const SixCardFast = () => {
114121
trails={trails.slice(0, 6)}
115122
speed="fast"
116123
imageLoading="eager"
124+
aspectRatio={ASPECT_RATIO}
117125
/>
118126
</FrontSection>
119127
);
@@ -131,6 +139,7 @@ export const SevenCardFast = () => {
131139
trails={trails.slice(0, 7)}
132140
speed="fast"
133141
imageLoading="eager"
142+
aspectRatio={ASPECT_RATIO}
134143
/>
135144
</FrontSection>
136145
);
@@ -148,6 +157,7 @@ export const EightCardFast = () => {
148157
trails={trails.slice(0, 8)}
149158
speed="fast"
150159
imageLoading="eager"
160+
aspectRatio={ASPECT_RATIO}
151161
/>
152162
</FrontSection>
153163
);
@@ -166,6 +176,7 @@ export const TwelveCardFast = () => {
166176
trails={trails.slice(0, 12)}
167177
speed="fast"
168178
imageLoading="eager"
179+
aspectRatio={ASPECT_RATIO}
169180
/>
170181
</FrontSection>
171182
);
@@ -183,6 +194,7 @@ export const OneCardSlow = () => {
183194
trails={trails.slice(0, 1)}
184195
speed="slow"
185196
imageLoading="eager"
197+
aspectRatio={ASPECT_RATIO}
186198
/>
187199
</FrontSection>
188200
);
@@ -200,6 +212,7 @@ export const TwoCardSlow = () => {
200212
trails={trails.slice(0, 2)}
201213
speed="slow"
202214
imageLoading="eager"
215+
aspectRatio={ASPECT_RATIO}
203216
/>
204217
</FrontSection>
205218
);
@@ -217,6 +230,7 @@ export const ThreeCardSlow = () => {
217230
trails={trails.slice(0, 3)}
218231
speed="slow"
219232
imageLoading="eager"
233+
aspectRatio={ASPECT_RATIO}
220234
/>
221235
</FrontSection>
222236
);
@@ -234,6 +248,7 @@ export const FourCardSlow = () => {
234248
trails={trails.slice(0, 4)}
235249
speed="slow"
236250
imageLoading="eager"
251+
aspectRatio={ASPECT_RATIO}
237252
/>
238253
</FrontSection>
239254
);
@@ -251,6 +266,7 @@ export const FiveCardSlow = () => {
251266
trails={trails.slice(0, 5)}
252267
speed="slow"
253268
imageLoading="eager"
269+
aspectRatio={ASPECT_RATIO}
254270
/>
255271
</FrontSection>
256272
);
@@ -268,6 +284,7 @@ export const SixCardSlow = () => {
268284
trails={trails.slice(0, 6)}
269285
speed="slow"
270286
imageLoading="eager"
287+
aspectRatio={ASPECT_RATIO}
271288
/>
272289
</FrontSection>
273290
);
@@ -285,6 +302,7 @@ export const SevenCardSlow = () => {
285302
trails={trails.slice(0, 7)}
286303
speed="slow"
287304
imageLoading="eager"
305+
aspectRatio={ASPECT_RATIO}
288306
/>
289307
</FrontSection>
290308
);
@@ -302,6 +320,7 @@ export const EightCardSlow = () => {
302320
trails={trails.slice(0, 8)}
303321
speed="slow"
304322
imageLoading="eager"
323+
aspectRatio={ASPECT_RATIO}
305324
/>
306325
</FrontSection>
307326
);
@@ -320,6 +339,7 @@ export const TwelveCardSlow = () => {
320339
trails={trails.slice(0, 12)}
321340
speed="slow"
322341
imageLoading="eager"
342+
aspectRatio={ASPECT_RATIO}
323343
/>
324344
</FrontSection>
325345
);

0 commit comments

Comments
 (0)