aboutsummaryrefslogtreecommitdiff
path: root/src/pages/Gear.tsx
blob: dbbcdfb67d480a89eb0bfd2b9f8a669938c4965d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import CardLink from '../components/CardLink';

import {
  dailyDrivers,
  desktopParts,
  nasParts,
  type Part,
} from '../data/gear';

function PartsGroup({ title, parts }: { title?: string; parts: Part[] }) {
  return (
    <>
      {title && <h2 className="text-2xl font-semibold my-8">{title}</h2>}
      <ul className="space-y-2">
        {parts.map((p) => (
          <li key={p.name}>
            <CardLink
              title={p.name}
              body={p.description}
              href={p.url}
              imgSrc={p.image}
            />
          </li>
        ))}
      </ul>
    </>
  );
}

export default function GearPage() {
  return (
    <>
      <title>߸ gear</title>
      <h1>Gear</h1>

      <PartsGroup parts={dailyDrivers} />

      <PartsGroup title="Desktop" parts={desktopParts} />

      <PartsGroup title="NAS" parts={nasParts} />
    </>
  );
}