Skip to content

Commit

Permalink
Refactor image links in page component
Browse files Browse the repository at this point in the history
  • Loading branch information
bonifacy1 committed May 6, 2024
1 parent 01557cd commit c0667dc
Showing 1 changed file with 30 additions and 32 deletions.
62 changes: 30 additions & 32 deletions src/app/images/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,38 +2,36 @@ import Link from "next/link";

export default function Home() {
return (
<main className="flex min-h-screen flex-col items-center justify-between p-24">
<div className="mb-32 grid text-center lg:mb-0 lg:w-full lg:max-w-5xl lg:grid-cols-4 lg:text-left">
<Link
href="/images/external"
className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30"
>
<h2 className="mb-3 text-2xl font-semibold">
External Images
<span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none">
-&gt;
</span>
</h2>
<p className="m-0 max-w-[30ch] text-sm opacity-50">
Test for remote images
</p>
</Link>
<>
<Link
href="/images/external"
className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30"
>
<h2 className="mb-3 text-2xl font-semibold">
External Images
<span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none">
-&gt;
</span>
</h2>
<p className="m-0 max-w-[30ch] text-sm opacity-50">
Test for remote images
</p>
</Link>

<Link
href="/images/internal"
className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30"
>
<h2 className="mb-3 text-2xl font-semibold">
Internal Images
<span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none">
-&gt;
</span>
</h2>
<p className="m-0 max-w-[30ch] text-sm opacity-50">
Test for local images
</p>
</Link>
</div>
</main>
<Link
href="/images/internal"
className="group rounded-lg border border-transparent px-5 py-4 transition-colors hover:border-gray-300 hover:bg-gray-100 hover:dark:border-neutral-700 hover:dark:bg-neutral-800/30"
>
<h2 className="mb-3 text-2xl font-semibold">
Internal Images
<span className="inline-block transition-transform group-hover:translate-x-1 motion-reduce:transform-none">
-&gt;
</span>
</h2>
<p className="m-0 max-w-[30ch] text-sm opacity-50">
Test for local images
</p>
</Link>
</>
);
}

0 comments on commit c0667dc

Please sign in to comment.