Adjust news widget to display five articles and fix photo gallery aspect ratio

Update news widget visible count from 6 to 5 and adjust photo gallery image to use an aspect ratio of 4/3, ensuring it no longer overflows its container.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: 517dfa7b-26ac-463d-a6e1-a58c6df97188
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Event-Id: 38e2b203-009e-47ca-9973-43174b73b28f
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/f209e72a-0939-48fa-84fc-57854de71967/517dfa7b-26ac-463d-a6e1-a58c6df97188/drGbo1a
Replit-Helium-Checkpoint-Created: true
This commit is contained in:
sebastjanartic 2026-02-28 21:34:19 +00:00
parent 8b2cd02a94
commit 4c73ee8265
2 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@ interface NewsItem {
pubDate: string;
}
const VISIBLE_COUNT = 6;
const VISIBLE_COUNT = 5;
export function NewsWidget() {
const { data: news, isLoading } = useQuery<NewsItem[]>({

View File

@ -110,11 +110,11 @@ function SingleImageCarousel({
onMouseEnter={() => setPaused(true)}
onMouseLeave={() => setPaused(false)}
>
<div className="relative w-full overflow-hidden rounded-b-lg flex-1 min-h-0">
<div className="relative w-full overflow-hidden rounded-b-lg">
<img
src={images[index].large || images[index].thumb}
alt={images[index].fileName}
className="absolute inset-0 w-full h-full object-cover transition-opacity duration-500"
className="w-full aspect-[4/3] object-cover transition-opacity duration-500"
style={{ objectPosition: "center 30%" }}
loading="lazy"
data-testid="img-gallery-current"