diff --git a/src/pages/projects/[slug].astro b/src/pages/projects/[slug].astro index 2b0c511..3f6784a 100644 --- a/src/pages/projects/[slug].astro +++ b/src/pages/projects/[slug].astro @@ -9,8 +9,10 @@ * prose styling (the project has no typography plugin yet). */ import { getCollection, render } from 'astro:content'; +import { Icon } from 'astro-icon/components'; import Base from '../../layouts/Base.astro'; import { DOMAIN_LABELS } from '../../lib/domains'; +import { Image } from 'astro:assets'; export async function getStaticPaths() { const projects = await getCollection('projects'); @@ -23,6 +25,11 @@ export async function getStaticPaths() { const { entry } = Astro.props; const { data } = entry; const { Content } = await render(entry); + +const dividerClass = 'border-line'; +const maxTech = 10; +const shownTech = data.tech.slice(0, maxTech); +const hiddenTech = data.tech.slice(maxTech, data.tech.length); --- ← All projects -
+
-
+

{data.title}

- {data.domains.map((d) => DOMAIN_LABELS[d]).join(', ')} · { - data.year - } + + {data.domains.map((d) => DOMAIN_LABELS[d]).join(', ')} · {data.year} +
-

{data.description}

-

- Built by{' '} - { - data.builtBy.map((person, i) => ( - - {i > 0 && ', '} - {person.url ? ( - - {person.name} - - ) : ( - person.name - )} - - )) - } -

+
+

+ {data.description} +

-
    - { - data.tech.map((t) => ( -
  • - {t} -
  • - )) - } -
- -
- - GitHub - +

+ Built by{' '} + { + data.builtBy.map((person, i) => ( + + {i > 0 && ', '} + {person.url ? ( + + {person.name} + + ) : ( + person.name + )} + + )) + } +

+
+
+ +
+ + { + data.cover && ( + <> + {`Cover +
+ + ) + } + +
+
+

Tech stack

+ +
    + { + shownTech.map((t) => ( +
  • + {t} +
  • + )) + } + { + hiddenTech.map((t) => ( + + )) + } + { + hiddenTech.length > 0 && ( + + ) + } +
+
+ +
{ - data.deploy && ( + data.deploy ? ( + <> + + GitHub + + + Live site + + + + ) : ( - Live site + GitHub ) }
- +
- { - data.cover && ( - {`Cover - ) - } +
- { - /* Contributor markdown body — needs prose styling (detail design ticket). */ - } -
+
+ + + +