Skip to content
This repository has been archived by the owner on Mar 12, 2020. It is now read-only.

[Artworks] Store actual artwork brick aspect ratio after layout. #688

Open
alloy opened this issue Jul 21, 2017 · 0 comments
Open

[Artworks] Store actual artwork brick aspect ratio after layout. #688

alloy opened this issue Jul 21, 2017 · 0 comments

Comments

@alloy
Copy link
Contributor

alloy commented Jul 21, 2017

We currently only use the image’s aspect ratio to do masonry layout, but sometimes the metadata below the image is shorter and sometimes taller, this may be the reason why at some point the layout can skew to either the left or the right side. Additionally we default to an aspect ratio of 1:1 when it’s missing from the payload.

We should probably register for the onLayout callback of each artwork brick and update the aspect ratio for the full brick after layout. This shouldn’t lead to already laid-out artworks to re-layout, but it will correct the layout of new artworks being paginated in, as the total aspect ratio of the columns will be correct.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant