Render portrait thumbnails as squares on mobile
All checks were successful
CI / Lint (push) Successful in 32s
CI / Test (push) Successful in 56s

A bit too small otherwise
This commit is contained in:
2026-04-24 11:01:58 +01:00
parent 98dcb4f25b
commit cb4b9c6b40
2 changed files with 10 additions and 2 deletions

View File

@@ -116,7 +116,8 @@ export default class PlacePhotosCarousel extends Component {
{{#each this.photos as |photo|}} {{#each this.photos as |photo|}}
{{! template-lint-disable no-inline-styles }} {{! template-lint-disable no-inline-styles }}
<div <div
class="carousel-slide" class="carousel-slide
{{if photo.isLandscape 'landscape' 'portrait'}}"
style={{photo.style}} style={{photo.style}}
data-event-id={{photo.eventId}} data-event-id={{photo.eventId}}
> >

View File

@@ -1006,10 +1006,17 @@ abbr[title] {
flex: 0 0 auto; flex: 0 0 auto;
height: 100px; height: 100px;
width: auto; width: auto;
aspect-ratio: var(--slide-ratio, 16 / 9);
scroll-snap-align: none; scroll-snap-align: none;
} }
.carousel-slide.landscape {
aspect-ratio: var(--slide-ratio, 16 / 9);
}
.carousel-slide.portrait {
aspect-ratio: 1 / 1;
}
.carousel-placeholder { .carousel-placeholder {
display: block; display: block;
background-color: var(--hover-bg); background-color: var(--hover-bg);