guardian / frontend

The Guardian DotCom.
https://theguardian.com
Other
5.85k stars 555 forks source link

Add aspect ratio to frontend collection config #27621

Open Georges-GNM opened 4 days ago

Georges-GNM commented 4 days ago

What is the value of this and can you measure success?

Part of this fairground ticket

Requires this DCR PR, as well as this facia-scala-client one which adds the logic to get the aspect ratio from the collection type. Once the facia scala client PR has been approved and the update released, I'll update this branch with the latest version of the library.

Supports aspectRatio as an optional property in the frontend collection config.

Deployed to code and, after relaunching the fairground front, checked we could see the value appear in the pressed json:

image

With the DCR PR, I could also see the expected value come through (rendered here through a div inserted on the front with the following: <div>{collection.collectionType}, aspect ratio: {collection.aspectRatio}</div>

image
github-actions[bot] commented 2 days ago

Deploy build 3364 of dotcom:frontend-all to CODE

All deployment options - [Deploy build 3364 of `dotcom:frontend-all` to CODE](https://riffraff.gutools.co.uk/deployment/deployAgain?project=dotcom%3Afrontend-all&build=3364&stage=CODE&updateStrategy=MostlyHarmless&action=deploy) - [Deploy parts of build 3364 to CODE by previewing it first](https://riffraff.gutools.co.uk/preview/yaml?project=dotcom%3Afrontend-all&build=3364&stage=CODE&updateStrategy=MostlyHarmless) - [What's on CODE right now?](https://riffraff.gutools.co.uk/deployment/history?projectName=dotcom%3Afrontend-all&stage=CODE)

From guardian/actions-riff-raff.