Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set default thumbnail aspect ratio to square #6970

Merged
merged 1 commit into from Feb 8, 2024

Conversation

lukashass
Copy link
Contributor

Prevents overlapping people names on /people and some other layout shifts like circles with height 0.

I also considered adding a square prop, but since all but one current ImageThumbnail usages are square or circles anyways, I decided to use !heightStyle instead.

Sadly no example screenshot since the demo environment doesn't have images atm 馃槙

@alextran1502
Copy link
Contributor

alextran1502 commented Feb 7, 2024

Hello, is there any specific component that is using this one?

How can we reproduce the overlapping people names on the people page?

@lukashass
Copy link
Contributor Author

I think you probably have to throttle your network a bit, since they overlap while the images are still loading. This happens to me quite often on a slow connection.

Once an image is loaded it sets the container height by it's own aspect ratio, but before the container had height 0.

@alextran1502 alextran1502 enabled auto-merge (squash) February 8, 2024 04:13
@alextran1502 alextran1502 merged commit abb6922 into immich-app:main Feb 8, 2024
23 of 24 checks passed
@lukashass lukashass deleted the square-thumbnails branch February 8, 2024 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants