11---
22import type { CollectionEntry } from ' astro:content'
3- import type { AstroComponentFactory } from ' astro/runtime/server/index.js '
3+ import type { RenderedClient } from ' @components/Pages/Resume/server '
44import HeadContent from ' @components/Head/index.astro'
55import Contact from ' @components/Pages/Resume/partials/Contact.astro'
66import Controls from ' @components/Pages/Resume/partials/Controls.astro'
7- import ExperienceCard from ' @components/Pages/Resume/partials/ExperienceCard.astro'
7+ import Experience from ' @components/Pages/Resume/partials/Experience.astro'
8+ import Languages from ' @components/Pages/Resume/partials/Languages.astro'
89import Persona from ' @components/Pages/Resume/partials/Persona.astro'
910import Skills from ' @components/Pages/Resume/partials/Skills.astro'
11+ import Socials from ' @components/Pages/Resume/partials/Socials.astro'
1012import Summary from ' @components/Pages/Resume/partials/Summary.astro'
1113
1214import ' @styles/index.css'
1315import ' @styles/icons.css'
14- import ' ./index.css'
15-
16- type SocialEntry = {
17- label: string
18- url: string
19- }
20- type RenderedClient = {
21- client: CollectionEntry <' clients' >
22- Content: AstroComponentFactory
23- }
2416
2517export interface Props {
2618 contactData: CollectionEntry <' contactData' >[' data' ]
@@ -39,14 +31,6 @@ const {
3931 renderedClients,
4032 resume,
4133} = Astro .props as Props
42-
43- const companyContact = contactData .company
44- const socialEntries: SocialEntry [] = [... companyContact .social ]
45- .sort ((left , right ) => left .order - right .order )
46- .map (entry => ({
47- label: entry .displayName ,
48- url: entry .url ,
49- }))
5034---
5135
5236<!doctype html >
@@ -67,105 +51,55 @@ const socialEntries: SocialEntry[] = [...companyContact.social]
6751 <div class =" md:absolute md:right-0 md:top-0" >
6852 <Controls />
6953 </div >
70- <Persona
71- givenName ={ resume .firstName }
72- familyName ={ resume .lastName }
73- title ={ resume .title }
74- />
54+
55+ <div class =" " >
56+ <Persona
57+ givenName ={ resume .firstName }
58+ familyName ={ resume .lastName }
59+ title ={ resume .title }
60+ />
61+ </div >
62+
7563 <div class =" mt-1!" >
7664 <Contact
7765 contactData ={ contactData }
78- email ={ companyContact .email }
66+ email ={ contactData . company .email }
7967 />
8068 </div >
8169 </header >
70+
8271 <main class =" space-y-8" >
83- <div class =" mb-3 border-b-2 border-trim/10" >
72+ <div class =" border-b-2 border-trim/10" >
8473 <Summary summary ={ resume .summary } />
8574 </div >
86- <section id =" experience" >
87- <h2
88- class =" text-xs font-bold tracking-widest text-primary uppercase mb-4 border-b-2 border-trim/10"
89- >
90- Experience
91- </h2 >
92- <div class =" space-y-8" >
93- {
94- renderedClients .map (({ client , Content }: RenderedClient , index : number ) => {
95- return (
96- <ExperienceCard
97- index = { index }
98- client = { client }
99- Content = { Content }
100- />
101- )
102- })
103- }
104- </div >
105- </section >
106- <section class =" mt-8" itemscope itemref =" resumeSubject" itemtype =" http://schema.org/ItemList" >
107- <h2 class =" text-xs font-bold tracking-widest text-primary uppercase mb-4 border-b-2 border-trim/10 pb-2" >Skills</h2 >
108- <div class =" grid grid-cols-1 md:grid-cols-2 gap-x-6 gap-y-4" >
109- <Skills skills ={ resume .skills } />
110- </div >
111- </section >
112- <section
113- id =" languages"
114- class =" mt-8"
115- itemscope
116- itemref =" resumeSubject"
117- itemtype =" http://schema.org/ItemList"
118- >
119- <h2 class =" text-xs font-bold tracking-widest text-primary uppercase mb-4 border-b-2 border-trim/10 pb-2" >Languages</h2 >
120- <ul class =" flex flex-wrap gap-4 text-sm font-medium text-content-offset" >
121- {
122- resume .languages .map ((language : (typeof resume .languages )[number ]) => (
123- <li
124- class = " bg-trim/5 px-3 py-1 rounded-full text-primary-offset print:bg-transparent print:p-0 print:border print:border-trim/20 print:px-2 print:py-0.5 print:rounded-md"
125- itemref = " resumeSubject"
126- itemscope
127- itemprop = " knowsAbout"
128- itemtype = " http://schema.org/knowsAbout"
129- >
130- <span itemprop = " name" >{ language } </span >
131- </li >
132- ))
133- }
134- </ul >
135- </section >
136- <section
137- id =" socialSection"
138- class =" mt-8 print:mt-6 print:hidden"
139- itemscope
140- itemref =" resumeSubject"
141- itemtype =" http://schema.org/ItemList"
142- >
143- <h2 class =" text-xs font-bold tracking-widest text-primary uppercase mb-4 border-b-2 border-trim/10 pb-2 print:border-trim/30 print:mb-3 print:pb-1" >SOCIAL</h2 >
144- {
145- socialEntries .length > 0 ? (
146- <ul id = " socialList" class = " flex flex-col md:flex-row md:flex-wrap gap-4 md:gap-8" >
147- { socialEntries .map ((entry : SocialEntry ) => (
148- <li
149- class = " text-sm"
150- itemref = " resumeSubject"
151- itemscope
152- itemprop = " sameAs"
153- itemtype = " http://schema.org/WebSite"
154- >
155- <a class = " group inline-flex items-center gap-2 hover:text-primary transition-colors text-content-offset" itemprop = " url" title = { entry .label } rel = " me" href = { entry .url } >
156- <span class = " font-bold text-content-active group-hover:text-primary transition-colors" >{ entry .label } </span >
157- <span class = " text-trim/30 select-none" >• </span >
158- <span class = " truncate" >{ entry .url .replace (/ ^ https? :\/\/ / , ' ' )} </span >
159- </a >
160- </li >
161- ))}
162- </ul >
163- ) : (
164- <p class = " text-sm text-content-offset italic" >No social profiles available.</p >
165- )
166- }
167- </section >
75+
76+ <div class =" " >
77+ <Experience renderedClients ={ renderedClients } />
78+ </div >
79+
80+ <div class =" " >
81+ <Skills skills ={ resume .skills } />
82+ </div >
83+
84+ <div class =" " >
85+ <Languages languages ={ resume .languages } />
86+ </div >
87+
88+ <div class =" " >
89+ <Socials socials ={ contactData .company .social } />
90+ </div >
16891 </main >
16992 </div >
17093 </body >
17194</html >
95+
96+ <style >
97+ {/** DO NOT ADD STYLES HERE - Use Tailwind classes on HTML elements, this are resets */}
98+ *, *::before, *::after {
99+ box-sizing: border-box;
100+ }
101+
102+ * {
103+ margin: 0;
104+ }
105+ </style >
0 commit comments