11---
22import Layout from " ../layouts/Layout.astro" ;
3- import FormattedDate from " ../components/FormattedDate.astro" ;
4- import { SITE_DESCRIPTION , SOCIAL_LINKS , BLOG_CONFIG } from " ../consts" ;
3+ import { SITE_DESCRIPTION , SOCIAL_LINKS , BLOG_CONFIG , DOMAINS } from " ../consts" ;
54import icons , { getSizedIcon } from " ../assets/icons" ;
65import { getCollection } from " astro:content" ;
76import { generateURL } from " ../utils" ;
7+ import FormattedDate from " ../components/FormattedDate.astro" ;
88
99const posts = (await getCollection (" medical" )).sort (
1010 (a , b ) => b .data .pubDate .valueOf () - a .data .pubDate .valueOf ()
1111);
1212---
1313
1414<Layout >
15- <section >
15+ <!-- Hero -->
16+ <section class =" hero" >
17+ <h1 >Cody Nguyen</h1 >
1618 <p class =" text-lg leading-relaxed max-w-prose" >
17- I like working on problems that sit between fields — software, medicine,
18- robotics, finance. Mostly building things and figuring out what's useful.
19+ { SITE_DESCRIPTION }
20+ </p >
21+ <p class =" leading-relaxed max-w-prose" >
22+ I like working on problems that sit between fields — finding where
23+ software can unlock something useful in medicine, robotics, ML, or
24+ finance.
1925 </p >
2026 <div class =" flex flex-wrap gap-4 mt-4" >
2127 {
@@ -54,24 +60,49 @@ const posts = (await getCollection("medical")).sort(
5460 </div >
5561 </section >
5662
63+ <!-- Domains -->
64+ <section >
65+ <h2 >What I Work On</h2 >
66+ <div class =" domain-grid" >
67+ {
68+ DOMAINS .map (domain => (
69+ <a
70+ href = { generateURL (` /projects#${domain .slug } ` )}
71+ class = " card group no-underline hover:no-underline"
72+ >
73+ <h4 class = " mb-2 group-hover:text-secondary transition-colors" >
74+ { domain .name }
75+ </h4 >
76+ <p class = " text-sm mb-0" >{ domain .description } </p >
77+ </a >
78+ ))
79+ }
80+ </div >
81+ </section >
82+
83+ <!-- Recent Work -->
5784 {
5885 posts .length > 0 && (
5986 <section >
60- <h3 >Projects</h3 >
87+ <div class = " flex items-baseline justify-between mb-4" >
88+ <h2 class = " mb-0" >Recent Projects</h2 >
89+ <a
90+ href = { generateURL (" /projects" )}
91+ class = " text-sm text-secondary no-underline hover:underline"
92+ >
93+ View all →
94+ </a >
95+ </div >
6196 <ul class = " blog-posts" >
62- { posts .map (post => (
97+ { posts .slice ( 0 , 5 ). map (post => (
6398 <li >
6499 <span >
65100 <i >
66101 <FormattedDate date = { post .data .pubDate } />
67102 </i >
68103 </span >
69104 <a
70- href = { generateURL (
71- ` /medical/${post .id }/ ` ,
72- undefined ,
73- true
74- )}
105+ href = { generateURL (` /medical/${post .id }/ ` , undefined , true )}
75106 >
76107 { post .data .title }
77108 </a >
@@ -82,3 +113,14 @@ const posts = (await getCollection("medical")).sort(
82113 )
83114 }
84115</Layout >
116+
117+ <style >
118+ .hero h1 {
119+ margin-bottom: 0.5rem;
120+ }
121+ .domain-grid {
122+ display: grid;
123+ grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
124+ gap: 1rem;
125+ }
126+ </style >
0 commit comments