Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions app/routes/_app+/_marketing+/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ export default function Index() {
<img
src="/images/smiling-phone-flowers.jpg"
alt="Smiling person holding flowers and a phone"
width={2560}
height={1707}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Image aspect ratio attributes conflict with CSS class

Medium Severity

The added width={2560} and height={1707} attributes represent a 3:2 aspect ratio, but the CSS class includes aspect-square which enforces a 1:1 ratio. The CSS aspect-ratio property takes precedence over intrinsic dimensions, so these attributes won't achieve the stated goal of reserving 3:2 space during page load. The width/height values need to match the actual displayed ratio (1:1) for the layout shift prevention to work correctly.

Fix in Cursor Fix in Web

className="border-border aspect-square w-full rounded-[40px] border object-cover shadow-lg"
/>
<p className="text-muted-secondary-foreground mt-2 text-xs">
Expand Down
Loading