-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Fairground] Display image as 4:5 in relevant collections #1743
Conversation
84a34fa
to
b042585
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great, nice work!
Requires the fronts tool portrait feature switch to be activated in order to see this change.
@@ -52,20 +52,20 @@ const squareStyle = ` | |||
`; | |||
|
|||
const getVariableImageContainerStyle = ({ | |||
portrait = false, | |||
shouldShowPortrait = false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
much clearer 👍
Seen on PROD (merged by @Georges-GNM 8 minutes and 37 seconds ago) Please check your changes! |
What's changed?
Part of this ticket. Displays trail and thumbnail images with a 4:5 aspect ratio for relevant collections.
Implementation note
This was made using the same pattern previously implemented for square/landscape54 images being displayed. We're at the point of having the same logic effectively being repeated three times, so it's an opportunity for a refactor, which I've started putting together, but thought that change was best left for a separate PR.
Screenshots
These examples contrast a scrollable feature collection, which uses 4:5 images, and a scrollable small, which uses landscape 5:4. The image getting displayed is the one automatically selected when adding the story to the collection (so no manual replacing/cropping of the image).
Thumbnail:
Trail image:
General
Client