Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
RhysSullivan committed Oct 18, 2024
1 parent 81724fa commit 08c3e1e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
6 changes: 3 additions & 3 deletions src/app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ export default function Home() {
<main className="flex-1 p-4">
{productCategories.map((category) => (
<div key={category.name} className="mb-8">
<h2 className="text-xl font-semibold mb-4">{category.name}</h2>
<div className="grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6 gap-4 border-b-2 pb-4">
<h2 className="mb-4 text-xl font-semibold">{category.name}</h2>
<div className="grid grid-cols-2 gap-4 border-b-2 pb-4 sm:grid-cols-3 md:grid-cols-4 lg:grid-cols-6">
{category.subcategories.map((subcategory) => (
<Link
key={subcategory.name}
Expand All @@ -18,7 +18,7 @@ export default function Home() {
<img
src={subcategory.icon}
alt={subcategory.name}
className="w-14 h-14 border mb-2 hover:bg-yellow-200"
className="mb-2 h-14 w-14 border hover:bg-yellow-200"
width={48}
height={48}
/>
Expand Down
14 changes: 7 additions & 7 deletions src/app/products/[category]/[subcategory]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,18 +40,18 @@ export default async function Page(props: {
const { subcategory, category } = await props.params;
return (
<div className="container mx-auto p-4">
<h1 className="text-sm font-bold mb-2 border-b-2">690 Products</h1>
<h1 className="mb-2 border-b-2 text-sm font-bold">690 Products</h1>
<div className="space-y-4">
{screwTypes.map((collection, index) => (
<div key={index}>
<h2 className="text-lg font-semibold mb-2 border-b-2">
<h2 className="mb-2 border-b-2 text-lg font-semibold">
{collection.name}
</h2>
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-2 ">
<div className="grid grid-cols-1 gap-2 md:grid-cols-2 lg:grid-cols-4">
{collection.items.map((item, subcategoryIndex) => (
<Link
key={subcategoryIndex}
className="flex flex-row h-full border px-4 py-2 group hover:bg-gray-100"
className="group flex h-full flex-row border px-4 py-2 hover:bg-gray-100"
href={`/products/${category}/${subcategory}/${item.name}`}
>
<div className="py-2">
Expand All @@ -60,14 +60,14 @@ export default async function Page(props: {
alt={item.name}
width={48}
height={48}
className="object-cover w-12 h-12 flex-shrink-0"
className="h-12 w-12 flex-shrink-0 object-cover"
/>
</div>
<div className="flex items-start flex-grow flex-col py-2 h-24">
<div className="flex h-24 flex-grow flex-col items-start py-2">
<div className="text-sm font-medium text-gray-700 group-hover:underline">
{item.name}
</div>
<p className="text-xs overflow-hidden">
<p className="overflow-hidden text-xs">
{item.description}
</p>
</div>
Expand Down
8 changes: 4 additions & 4 deletions src/app/products/[category]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,14 +124,14 @@ export default async function Page(props: {
<div className="space-y-4">
{adhesiveCategories.map((collection, index) => (
<div key={index}>
<h2 className="text-lg font-semibold mb-2 border-b-2">
<h2 className="mb-2 border-b-2 text-lg font-semibold">
{collection.title}
</h2>
<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-2 ">
<div className="grid grid-cols-1 gap-2 md:grid-cols-2 lg:grid-cols-4">
{collection.products.map((subcategory, subcategoryIndex) => (
<Link
key={subcategoryIndex}
className="flex flex-row h-full border px-4 py-2 group hover:bg-gray-100"
className="group flex h-full flex-row border px-4 py-2 hover:bg-gray-100"
href={`/products/${category}/${subcategory.name}`}
>
<div className="py-2">
Expand All @@ -147,7 +147,7 @@ export default async function Page(props: {
<div className="text-sm font-medium text-gray-700 group-hover:underline">
{subcategory.name}
</div>
<p className="text-xs overflow-hidden">
<p className="overflow-hidden text-xs">
{subcategory.description}
</p>
</div>
Expand Down

0 comments on commit 08c3e1e

Please sign in to comment.