Skip to content

Commit

Permalink
Merge pull request #19 from bside-ms/image-dimensions
Browse files Browse the repository at this point in the history
fix: layout of images in event-overview and news components
  • Loading branch information
Haliax authored Dec 31, 2024
2 parents ae9942d + 392be7b commit a3aa72b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion components/events/overview/EventOverviewEntry.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ const EventOverviewEntry = ({ event, areDisplayedOnHome }: Props): ReactElement
href={`/events/${createEventSlug(event)}`}
className="group flex cursor-pointer shadow-md transition-shadow hover:shadow-lg"
>
<div className="relative hidden min-h-[150px] w-[100px] shrink-0 min-[350px]:block min-[450px]:w-[150px]">
<div className="relative my-auto hidden size-[150px] shrink-0 min-[350px]:block">
{eventImageUrl === null ? (
<EventOverviewEntryImageFallback />
) : (
Expand Down
2 changes: 1 addition & 1 deletion components/events/overview/EventsOverview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ const EventsOverview = ({ title = '', eventsOnPage }: Props): ReactElement => {
))
) : groupByDay.length > 0 ? (
groupByDay.map(([date, events]) => (
<div key={date.toString()} className="mb-6 space-y-4">
<div key={date.toString()} className="mb-6 space-y-2.5">
<div className="bg-black px-3 py-1 font-serif font-bold text-white md:px-4 md:py-2">
{formatDate(date, 'EE dd. MMMM yy')}
</div>
Expand Down
2 changes: 1 addition & 1 deletion components/news/NewsTeaser.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const NewsTeaser = ({ news }: Props): ReactElement | null => {
<Image
src={media.url!}
alt={media.alt}
className="aspect-[3/4] size-auto object-cover transition-all group-hover:scale-105"
className="aspect-[3/3] size-auto object-cover transition-all group-hover:scale-105"
width={300}
height={300}
/>
Expand Down

0 comments on commit a3aa72b

Please sign in to comment.