@tanstack/cta-framework-react-cra 0.45.0 → 0.46.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/add-ons/ai/assets/src/routes/demo/ai-chat.tsx +2 -2
- package/examples/resume/README.md +82 -0
- package/examples/resume/assets/content/education/code-school.md +17 -0
- package/examples/resume/assets/content/jobs/freelance.md +13 -0
- package/examples/resume/assets/content/jobs/initech-junior.md +20 -0
- package/examples/resume/assets/content/jobs/initech-lead.md +29 -0
- package/examples/resume/assets/content/jobs/initrode-senior.md +28 -0
- package/examples/resume/assets/content-collections.ts +36 -0
- package/examples/resume/assets/public/headshot-on-white.jpg +0 -0
- package/examples/resume/assets/src/components/ResumeAssistant.tsx +193 -0
- package/examples/resume/assets/src/components/ResumeAssistantButton.tsx +20 -0
- package/examples/resume/assets/src/components/ui/badge.tsx +46 -0
- package/examples/resume/assets/src/components/ui/card.tsx +92 -0
- package/examples/resume/assets/src/components/ui/checkbox.tsx +30 -0
- package/examples/resume/assets/src/components/ui/hover-card.tsx +44 -0
- package/examples/resume/assets/src/components/ui/separator.tsx +26 -0
- package/examples/resume/assets/src/lib/resume-ai-hook.ts +21 -0
- package/examples/resume/assets/src/lib/resume-tools.ts +165 -0
- package/examples/resume/assets/src/lib/utils.ts +6 -0
- package/examples/resume/assets/src/routes/api.resume-chat.ts +110 -0
- package/examples/resume/assets/src/routes/index.tsx +220 -0
- package/examples/resume/assets/src/styles.css +138 -0
- package/examples/resume/info.json +30 -0
- package/examples/resume/package.json +27 -0
- package/package.json +2 -2
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import * as React from "react"
|
|
2
|
+
import * as SeparatorPrimitive from "@radix-ui/react-separator"
|
|
3
|
+
|
|
4
|
+
import { cn } from "@/lib/utils"
|
|
5
|
+
|
|
6
|
+
function Separator({
|
|
7
|
+
className,
|
|
8
|
+
orientation = "horizontal",
|
|
9
|
+
decorative = true,
|
|
10
|
+
...props
|
|
11
|
+
}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {
|
|
12
|
+
return (
|
|
13
|
+
<SeparatorPrimitive.Root
|
|
14
|
+
data-slot="separator-root"
|
|
15
|
+
decorative={decorative}
|
|
16
|
+
orientation={orientation}
|
|
17
|
+
className={cn(
|
|
18
|
+
"bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",
|
|
19
|
+
className
|
|
20
|
+
)}
|
|
21
|
+
{...props}
|
|
22
|
+
/>
|
|
23
|
+
)
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { Separator }
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchServerSentEvents,
|
|
3
|
+
useChat,
|
|
4
|
+
createChatClientOptions,
|
|
5
|
+
} from '@tanstack/ai-react'
|
|
6
|
+
import type { InferChatMessages } from '@tanstack/ai-react'
|
|
7
|
+
|
|
8
|
+
// Default chat options for type inference
|
|
9
|
+
const defaultChatOptions = createChatClientOptions({
|
|
10
|
+
connection: fetchServerSentEvents('/api/resume-chat'),
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
export type ResumeChatMessages = InferChatMessages<typeof defaultChatOptions>
|
|
14
|
+
|
|
15
|
+
export const useResumeChat = () => {
|
|
16
|
+
const chatOptions = createChatClientOptions({
|
|
17
|
+
connection: fetchServerSentEvents('/api/resume-chat'),
|
|
18
|
+
})
|
|
19
|
+
|
|
20
|
+
return useChat(chatOptions)
|
|
21
|
+
}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import { toolDefinition } from '@tanstack/ai'
|
|
2
|
+
import { z } from 'zod'
|
|
3
|
+
|
|
4
|
+
import { allJobs, allEducations } from 'content-collections'
|
|
5
|
+
|
|
6
|
+
// Tool definition for getting jobs by skill
|
|
7
|
+
export const getJobsBySkillToolDef = toolDefinition({
|
|
8
|
+
name: 'getJobsBySkill',
|
|
9
|
+
description:
|
|
10
|
+
'Find all jobs where the candidate used a specific technology or skill. Use this to check if the candidate has experience with particular technologies.',
|
|
11
|
+
inputSchema: z.object({
|
|
12
|
+
skill: z
|
|
13
|
+
.string()
|
|
14
|
+
.describe(
|
|
15
|
+
'The skill or technology to search for (e.g., "React", "TypeScript", "Leadership")',
|
|
16
|
+
),
|
|
17
|
+
}),
|
|
18
|
+
outputSchema: z.array(
|
|
19
|
+
z.object({
|
|
20
|
+
jobTitle: z.string(),
|
|
21
|
+
company: z.string(),
|
|
22
|
+
location: z.string(),
|
|
23
|
+
startDate: z.string(),
|
|
24
|
+
endDate: z.string().optional(),
|
|
25
|
+
summary: z.string(),
|
|
26
|
+
tags: z.array(z.string()),
|
|
27
|
+
content: z.string(),
|
|
28
|
+
}),
|
|
29
|
+
),
|
|
30
|
+
})
|
|
31
|
+
|
|
32
|
+
// Server implementation
|
|
33
|
+
export const getJobsBySkill = getJobsBySkillToolDef.server(({ skill }) => {
|
|
34
|
+
return allJobs.filter((job) =>
|
|
35
|
+
job.tags.some((tag) => tag.toLowerCase().includes(skill.toLowerCase())),
|
|
36
|
+
)
|
|
37
|
+
})
|
|
38
|
+
|
|
39
|
+
// Tool definition for getting all jobs
|
|
40
|
+
export const getAllJobsToolDef = toolDefinition({
|
|
41
|
+
name: 'getAllJobs',
|
|
42
|
+
description:
|
|
43
|
+
'Get a complete list of all work experience with full details including job titles, companies, dates, summaries, and skills. Use this to get an overview of the candidate\'s entire work history.',
|
|
44
|
+
inputSchema: z.object({}),
|
|
45
|
+
outputSchema: z.array(
|
|
46
|
+
z.object({
|
|
47
|
+
jobTitle: z.string(),
|
|
48
|
+
company: z.string(),
|
|
49
|
+
location: z.string(),
|
|
50
|
+
startDate: z.string(),
|
|
51
|
+
endDate: z.string().optional(),
|
|
52
|
+
summary: z.string(),
|
|
53
|
+
tags: z.array(z.string()),
|
|
54
|
+
content: z.string(),
|
|
55
|
+
}),
|
|
56
|
+
),
|
|
57
|
+
})
|
|
58
|
+
|
|
59
|
+
// Server implementation
|
|
60
|
+
export const getAllJobs = getAllJobsToolDef.server(() => {
|
|
61
|
+
return allJobs.map((job) => ({
|
|
62
|
+
jobTitle: job.jobTitle,
|
|
63
|
+
company: job.company,
|
|
64
|
+
location: job.location,
|
|
65
|
+
startDate: job.startDate,
|
|
66
|
+
endDate: job.endDate,
|
|
67
|
+
summary: job.summary,
|
|
68
|
+
tags: job.tags,
|
|
69
|
+
content: job.content,
|
|
70
|
+
}))
|
|
71
|
+
})
|
|
72
|
+
|
|
73
|
+
// Tool definition for getting all education
|
|
74
|
+
export const getAllEducationToolDef = toolDefinition({
|
|
75
|
+
name: 'getAllEducation',
|
|
76
|
+
description:
|
|
77
|
+
'Get a complete list of all education history including schools, programs, dates, and skills learned. Use this to understand the candidate\'s educational background.',
|
|
78
|
+
inputSchema: z.object({}),
|
|
79
|
+
outputSchema: z.array(
|
|
80
|
+
z.object({
|
|
81
|
+
school: z.string(),
|
|
82
|
+
summary: z.string(),
|
|
83
|
+
startDate: z.string(),
|
|
84
|
+
endDate: z.string().optional(),
|
|
85
|
+
tags: z.array(z.string()),
|
|
86
|
+
content: z.string(),
|
|
87
|
+
}),
|
|
88
|
+
),
|
|
89
|
+
})
|
|
90
|
+
|
|
91
|
+
// Server implementation
|
|
92
|
+
export const getAllEducation = getAllEducationToolDef.server(() => {
|
|
93
|
+
return allEducations.map((education) => ({
|
|
94
|
+
school: education.school,
|
|
95
|
+
summary: education.summary,
|
|
96
|
+
startDate: education.startDate,
|
|
97
|
+
endDate: education.endDate,
|
|
98
|
+
tags: education.tags,
|
|
99
|
+
content: education.content,
|
|
100
|
+
}))
|
|
101
|
+
})
|
|
102
|
+
|
|
103
|
+
// Tool definition for searching experience
|
|
104
|
+
export const searchExperienceToolDef = toolDefinition({
|
|
105
|
+
name: 'searchExperience',
|
|
106
|
+
description:
|
|
107
|
+
'Search for jobs by keywords in the job title, company name, summary, or content. Use this to find specific types of experience or roles.',
|
|
108
|
+
inputSchema: z.object({
|
|
109
|
+
query: z
|
|
110
|
+
.string()
|
|
111
|
+
.describe(
|
|
112
|
+
'The search query (e.g., "senior", "lead", "frontend", "startup")',
|
|
113
|
+
),
|
|
114
|
+
}),
|
|
115
|
+
outputSchema: z.array(
|
|
116
|
+
z.object({
|
|
117
|
+
jobTitle: z.string(),
|
|
118
|
+
company: z.string(),
|
|
119
|
+
location: z.string(),
|
|
120
|
+
startDate: z.string(),
|
|
121
|
+
endDate: z.string().optional(),
|
|
122
|
+
summary: z.string(),
|
|
123
|
+
tags: z.array(z.string()),
|
|
124
|
+
matchedIn: z
|
|
125
|
+
.array(z.string())
|
|
126
|
+
.describe('Which fields matched the search'),
|
|
127
|
+
}),
|
|
128
|
+
),
|
|
129
|
+
})
|
|
130
|
+
|
|
131
|
+
// Server implementation
|
|
132
|
+
export const searchExperience = searchExperienceToolDef.server(({ query }) => {
|
|
133
|
+
const lowerQuery = query.toLowerCase()
|
|
134
|
+
|
|
135
|
+
return allJobs
|
|
136
|
+
.map((job) => {
|
|
137
|
+
const matchedIn: string[] = []
|
|
138
|
+
|
|
139
|
+
if (job.jobTitle.toLowerCase().includes(lowerQuery)) {
|
|
140
|
+
matchedIn.push('job title')
|
|
141
|
+
}
|
|
142
|
+
if (job.company.toLowerCase().includes(lowerQuery)) {
|
|
143
|
+
matchedIn.push('company')
|
|
144
|
+
}
|
|
145
|
+
if (job.summary.toLowerCase().includes(lowerQuery)) {
|
|
146
|
+
matchedIn.push('summary')
|
|
147
|
+
}
|
|
148
|
+
if (job.content.toLowerCase().includes(lowerQuery)) {
|
|
149
|
+
matchedIn.push('description')
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
return { job, matchedIn }
|
|
153
|
+
})
|
|
154
|
+
.filter(({ matchedIn }) => matchedIn.length > 0)
|
|
155
|
+
.map(({ job, matchedIn }) => ({
|
|
156
|
+
jobTitle: job.jobTitle,
|
|
157
|
+
company: job.company,
|
|
158
|
+
location: job.location,
|
|
159
|
+
startDate: job.startDate,
|
|
160
|
+
endDate: job.endDate,
|
|
161
|
+
summary: job.summary,
|
|
162
|
+
tags: job.tags,
|
|
163
|
+
matchedIn,
|
|
164
|
+
}))
|
|
165
|
+
})
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { createFileRoute } from '@tanstack/react-router'
|
|
2
|
+
import { chat, maxIterations, toServerSentEventsResponse } from '@tanstack/ai'
|
|
3
|
+
import { anthropicText } from '@tanstack/ai-anthropic'
|
|
4
|
+
import { openaiText } from '@tanstack/ai-openai'
|
|
5
|
+
import { geminiText } from '@tanstack/ai-gemini'
|
|
6
|
+
import { ollamaText } from '@tanstack/ai-ollama'
|
|
7
|
+
|
|
8
|
+
import {
|
|
9
|
+
getJobsBySkill,
|
|
10
|
+
getAllJobs,
|
|
11
|
+
getAllEducation,
|
|
12
|
+
searchExperience,
|
|
13
|
+
} from '@/lib/resume-tools'
|
|
14
|
+
|
|
15
|
+
export const Route = createFileRoute('/api/resume-chat')({
|
|
16
|
+
server: {
|
|
17
|
+
handlers: {
|
|
18
|
+
POST: async ({ request }) => {
|
|
19
|
+
const requestSignal = request.signal
|
|
20
|
+
|
|
21
|
+
if (requestSignal.aborted) {
|
|
22
|
+
return new Response(null, { status: 499 })
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
const abortController = new AbortController()
|
|
26
|
+
|
|
27
|
+
try {
|
|
28
|
+
const body = await request.json()
|
|
29
|
+
const { messages } = body
|
|
30
|
+
const data = body.data || {}
|
|
31
|
+
|
|
32
|
+
const SYSTEM_PROMPT = `You are a helpful resume assistant helping recruiters and hiring managers evaluate if this candidate is a good fit for their job requirements.
|
|
33
|
+
|
|
34
|
+
CAPABILITIES:
|
|
35
|
+
1. Use getJobsBySkill to find jobs where the candidate used specific technologies or skills
|
|
36
|
+
2. Use getAllJobs to get the candidate's complete work history with all details
|
|
37
|
+
3. Use getAllEducation to get the candidate's educational background
|
|
38
|
+
4. Use searchExperience to search for specific types of roles or experience by keywords
|
|
39
|
+
|
|
40
|
+
INSTRUCTIONS:
|
|
41
|
+
- When asked about specific technologies or skills, use getJobsBySkill to find relevant experience
|
|
42
|
+
- When asked about overall experience or career progression, use getAllJobs
|
|
43
|
+
- When asked about education or training, use getAllEducation
|
|
44
|
+
- When asked about specific types of roles (e.g., "senior", "lead"), use searchExperience
|
|
45
|
+
- Be professional, concise, and helpful in your responses
|
|
46
|
+
- Provide specific details from the resume when available
|
|
47
|
+
- When calculating years of experience, consider the date ranges provided
|
|
48
|
+
- If the candidate has experience with something, highlight specific roles and time periods
|
|
49
|
+
- If the candidate lacks certain experience, be honest but constructive
|
|
50
|
+
|
|
51
|
+
CONTEXT: You are helping evaluate this candidate's qualifications for potential job opportunities.`
|
|
52
|
+
|
|
53
|
+
// Determine the best available provider
|
|
54
|
+
let provider: 'anthropic' | 'openai' | 'gemini' | 'ollama' = data.provider || 'ollama'
|
|
55
|
+
let model: string = data.model || 'mistral:7b'
|
|
56
|
+
|
|
57
|
+
// Use the first available provider with an API key, fallback to ollama
|
|
58
|
+
if (process.env.ANTHROPIC_API_KEY) {
|
|
59
|
+
provider = 'anthropic'
|
|
60
|
+
model = 'claude-haiku-4-5'
|
|
61
|
+
} else if (process.env.OPENAI_API_KEY) {
|
|
62
|
+
provider = 'openai'
|
|
63
|
+
model = 'gpt-4o'
|
|
64
|
+
} else if (process.env.GEMINI_API_KEY) {
|
|
65
|
+
provider = 'gemini'
|
|
66
|
+
model = 'gemini-2.0-flash-exp'
|
|
67
|
+
}
|
|
68
|
+
// else keep ollama as default
|
|
69
|
+
|
|
70
|
+
// Adapter factory pattern for multi-vendor support
|
|
71
|
+
const adapterConfig = {
|
|
72
|
+
anthropic: () =>
|
|
73
|
+
anthropicText((model || 'claude-haiku-4-5') as any),
|
|
74
|
+
openai: () => openaiText((model || 'gpt-4o') as any),
|
|
75
|
+
gemini: () => geminiText((model || 'gemini-2.0-flash-exp') as any),
|
|
76
|
+
ollama: () => ollamaText((model || 'mistral:7b') as any),
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
const adapter = adapterConfig[provider]()
|
|
80
|
+
|
|
81
|
+
const stream = chat({
|
|
82
|
+
adapter,
|
|
83
|
+
tools: [getJobsBySkill, getAllJobs, getAllEducation, searchExperience],
|
|
84
|
+
systemPrompts: [SYSTEM_PROMPT],
|
|
85
|
+
agentLoopStrategy: maxIterations(5),
|
|
86
|
+
messages,
|
|
87
|
+
abortController,
|
|
88
|
+
})
|
|
89
|
+
|
|
90
|
+
return toServerSentEventsResponse(stream, { abortController })
|
|
91
|
+
} catch (error: any) {
|
|
92
|
+
console.error('Resume chat error:', error)
|
|
93
|
+
if (error.name === 'AbortError' || abortController.signal.aborted) {
|
|
94
|
+
return new Response(null, { status: 499 })
|
|
95
|
+
}
|
|
96
|
+
return new Response(
|
|
97
|
+
JSON.stringify({
|
|
98
|
+
error: 'Failed to process chat request',
|
|
99
|
+
message: error.message,
|
|
100
|
+
}),
|
|
101
|
+
{
|
|
102
|
+
status: 500,
|
|
103
|
+
headers: { 'Content-Type': 'application/json' },
|
|
104
|
+
},
|
|
105
|
+
)
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
},
|
|
110
|
+
})
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { useState, useMemo } from 'react'
|
|
2
|
+
import { marked } from 'marked'
|
|
3
|
+
|
|
4
|
+
import { createFileRoute } from '@tanstack/react-router'
|
|
5
|
+
import { allJobs, allEducations } from 'content-collections'
|
|
6
|
+
import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card'
|
|
7
|
+
import { Checkbox } from '@/components/ui/checkbox'
|
|
8
|
+
import { Badge } from '@/components/ui/badge'
|
|
9
|
+
import { Separator } from '@/components/ui/separator'
|
|
10
|
+
import {
|
|
11
|
+
HoverCard,
|
|
12
|
+
HoverCardContent,
|
|
13
|
+
HoverCardTrigger,
|
|
14
|
+
} from '@/components/ui/hover-card'
|
|
15
|
+
|
|
16
|
+
import ResumeAssistant from '@/components/ResumeAssistant'
|
|
17
|
+
|
|
18
|
+
export const Route = createFileRoute('/')({
|
|
19
|
+
component: App,
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
function App() {
|
|
23
|
+
const [selectedTags, setSelectedTags] = useState<string[]>([])
|
|
24
|
+
|
|
25
|
+
// Get unique tags from all jobs
|
|
26
|
+
const allTags = useMemo(() => {
|
|
27
|
+
const tags = new Set<string>()
|
|
28
|
+
allJobs.forEach((job) => {
|
|
29
|
+
job.tags.forEach((tag) => tags.add(tag))
|
|
30
|
+
})
|
|
31
|
+
return Array.from(tags).sort()
|
|
32
|
+
}, [])
|
|
33
|
+
|
|
34
|
+
// Filter jobs based on selected tags
|
|
35
|
+
const filteredJobs = useMemo(() => {
|
|
36
|
+
if (selectedTags.length === 0) return allJobs
|
|
37
|
+
return allJobs.filter((job) =>
|
|
38
|
+
selectedTags.some((tag) => job.tags.includes(tag)),
|
|
39
|
+
)
|
|
40
|
+
}, [selectedTags])
|
|
41
|
+
|
|
42
|
+
return (
|
|
43
|
+
<>
|
|
44
|
+
<ResumeAssistant />
|
|
45
|
+
<div className="min-h-screen bg-linear-to-b from-gray-50 to-gray-100">
|
|
46
|
+
<div className="flex">
|
|
47
|
+
{/* Sidebar with filters */}
|
|
48
|
+
<div className="w-72 min-h-screen bg-white border-r shadow-sm p-8 sticky top-0">
|
|
49
|
+
<h3 className="text-lg font-semibold mb-6 text-gray-900">
|
|
50
|
+
Skills & Technologies
|
|
51
|
+
</h3>
|
|
52
|
+
<div className="space-y-4">
|
|
53
|
+
{allTags.map((tag) => (
|
|
54
|
+
<div key={tag} className="flex items-center space-x-3 group">
|
|
55
|
+
<Checkbox
|
|
56
|
+
id={tag}
|
|
57
|
+
checked={selectedTags.includes(tag)}
|
|
58
|
+
onCheckedChange={(checked) => {
|
|
59
|
+
if (checked) {
|
|
60
|
+
setSelectedTags([...selectedTags, tag])
|
|
61
|
+
} else {
|
|
62
|
+
setSelectedTags(selectedTags.filter((t) => t !== tag))
|
|
63
|
+
}
|
|
64
|
+
}}
|
|
65
|
+
className="data-[state=checked]:bg-blue-600"
|
|
66
|
+
/>
|
|
67
|
+
<label
|
|
68
|
+
htmlFor={tag}
|
|
69
|
+
className="text-sm font-medium leading-none text-gray-700 group-hover:text-gray-900 transition-colors cursor-pointer"
|
|
70
|
+
>
|
|
71
|
+
{tag}
|
|
72
|
+
</label>
|
|
73
|
+
</div>
|
|
74
|
+
))}
|
|
75
|
+
</div>
|
|
76
|
+
</div>
|
|
77
|
+
|
|
78
|
+
{/* Main content */}
|
|
79
|
+
<div className="flex-1 p-8 lg:p-12">
|
|
80
|
+
<div className="max-w-4xl mx-auto space-y-12">
|
|
81
|
+
<div className="text-center space-y-4">
|
|
82
|
+
<h1 className="text-5xl font-bold bg-linear-to-r from-gray-900 via-gray-800 to-gray-900 bg-clip-text text-transparent">
|
|
83
|
+
My Resume
|
|
84
|
+
</h1>
|
|
85
|
+
<p className="text-gray-600 text-lg">
|
|
86
|
+
Professional Experience & Education
|
|
87
|
+
</p>
|
|
88
|
+
<Separator className="mt-8" />
|
|
89
|
+
</div>
|
|
90
|
+
|
|
91
|
+
{/* Career Summary */}
|
|
92
|
+
<Card className="border-0 shadow-lg bg-white/50 backdrop-blur-sm">
|
|
93
|
+
<CardHeader>
|
|
94
|
+
<CardTitle className="text-2xl text-gray-900">
|
|
95
|
+
Career Summary
|
|
96
|
+
</CardTitle>
|
|
97
|
+
</CardHeader>
|
|
98
|
+
<CardContent>
|
|
99
|
+
<div className="flex items-center gap-8">
|
|
100
|
+
<p className="text-gray-700 flex-1 leading-relaxed">
|
|
101
|
+
I am a passionate and driven professional seeking
|
|
102
|
+
opportunities that will leverage my extensive experience
|
|
103
|
+
in frontend development while providing continuous growth
|
|
104
|
+
and learning opportunities. My goal is to contribute to
|
|
105
|
+
innovative projects that challenge me to expand my skill
|
|
106
|
+
set and make meaningful impacts through technology.
|
|
107
|
+
</p>
|
|
108
|
+
<img
|
|
109
|
+
src="/headshot-on-white.jpg"
|
|
110
|
+
alt="Professional headshot"
|
|
111
|
+
className="w-44 h-52 rounded-2xl object-cover shadow-md transition-transform hover:scale-105"
|
|
112
|
+
/>
|
|
113
|
+
</div>
|
|
114
|
+
</CardContent>
|
|
115
|
+
</Card>
|
|
116
|
+
|
|
117
|
+
{/* Work Experience */}
|
|
118
|
+
<section className="space-y-6">
|
|
119
|
+
<h2 className="text-3xl font-semibold text-gray-900">
|
|
120
|
+
Work Experience
|
|
121
|
+
</h2>
|
|
122
|
+
<div className="space-y-6">
|
|
123
|
+
{filteredJobs.map((job) => (
|
|
124
|
+
<Card
|
|
125
|
+
key={job.jobTitle}
|
|
126
|
+
className="border-0 shadow-md hover:shadow-lg transition-shadow"
|
|
127
|
+
>
|
|
128
|
+
<CardHeader>
|
|
129
|
+
<div className="flex justify-between items-start">
|
|
130
|
+
<div className="space-y-2">
|
|
131
|
+
<CardTitle className="text-xl text-gray-900">
|
|
132
|
+
{job.jobTitle}
|
|
133
|
+
</CardTitle>
|
|
134
|
+
<p className="text-blue-600 font-medium">
|
|
135
|
+
{job.company} - {job.location}
|
|
136
|
+
</p>
|
|
137
|
+
</div>
|
|
138
|
+
<Badge variant="secondary" className="text-sm">
|
|
139
|
+
{job.startDate} - {job.endDate || 'Present'}
|
|
140
|
+
</Badge>
|
|
141
|
+
</div>
|
|
142
|
+
</CardHeader>
|
|
143
|
+
<CardContent>
|
|
144
|
+
<p className="text-gray-700 mb-6 leading-relaxed">
|
|
145
|
+
{job.summary}
|
|
146
|
+
</p>
|
|
147
|
+
<div className="flex flex-wrap gap-2">
|
|
148
|
+
{job.tags.map((tag) => (
|
|
149
|
+
<HoverCard key={tag}>
|
|
150
|
+
<HoverCardTrigger>
|
|
151
|
+
<Badge
|
|
152
|
+
variant="outline"
|
|
153
|
+
className="hover:bg-gray-100 transition-colors cursor-pointer"
|
|
154
|
+
>
|
|
155
|
+
{tag}
|
|
156
|
+
</Badge>
|
|
157
|
+
</HoverCardTrigger>
|
|
158
|
+
<HoverCardContent className="w-64">
|
|
159
|
+
<p className="text-sm text-gray-600">
|
|
160
|
+
Experience with {tag} in professional
|
|
161
|
+
development
|
|
162
|
+
</p>
|
|
163
|
+
</HoverCardContent>
|
|
164
|
+
</HoverCard>
|
|
165
|
+
))}
|
|
166
|
+
</div>
|
|
167
|
+
{job.content && (
|
|
168
|
+
<div
|
|
169
|
+
className="mt-6 text-gray-700 prose prose-sm max-w-none"
|
|
170
|
+
dangerouslySetInnerHTML={{
|
|
171
|
+
__html: marked(job.content),
|
|
172
|
+
}}
|
|
173
|
+
/>
|
|
174
|
+
)}
|
|
175
|
+
</CardContent>
|
|
176
|
+
</Card>
|
|
177
|
+
))}
|
|
178
|
+
</div>
|
|
179
|
+
</section>
|
|
180
|
+
|
|
181
|
+
{/* Education */}
|
|
182
|
+
<section className="space-y-6">
|
|
183
|
+
<h2 className="text-3xl font-semibold text-gray-900">
|
|
184
|
+
Education
|
|
185
|
+
</h2>
|
|
186
|
+
<div className="space-y-6">
|
|
187
|
+
{allEducations.map((education) => (
|
|
188
|
+
<Card
|
|
189
|
+
key={education.school}
|
|
190
|
+
className="border-0 shadow-md hover:shadow-lg transition-shadow"
|
|
191
|
+
>
|
|
192
|
+
<CardHeader>
|
|
193
|
+
<CardTitle className="text-xl text-gray-900">
|
|
194
|
+
{education.school}
|
|
195
|
+
</CardTitle>
|
|
196
|
+
</CardHeader>
|
|
197
|
+
<CardContent>
|
|
198
|
+
<p className="text-gray-700 leading-relaxed">
|
|
199
|
+
{education.summary}
|
|
200
|
+
</p>
|
|
201
|
+
{education.content && (
|
|
202
|
+
<div
|
|
203
|
+
className="mt-6 text-gray-700 prose prose-sm max-w-none"
|
|
204
|
+
dangerouslySetInnerHTML={{
|
|
205
|
+
__html: marked(education.content),
|
|
206
|
+
}}
|
|
207
|
+
/>
|
|
208
|
+
)}
|
|
209
|
+
</CardContent>
|
|
210
|
+
</Card>
|
|
211
|
+
))}
|
|
212
|
+
</div>
|
|
213
|
+
</section>
|
|
214
|
+
</div>
|
|
215
|
+
</div>
|
|
216
|
+
</div>
|
|
217
|
+
</div>
|
|
218
|
+
</>
|
|
219
|
+
)
|
|
220
|
+
}
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
@import 'tailwindcss';
|
|
2
|
+
|
|
3
|
+
@plugin "tailwindcss-animate";
|
|
4
|
+
|
|
5
|
+
@custom-variant dark (&:is(.dark *));
|
|
6
|
+
|
|
7
|
+
body {
|
|
8
|
+
@apply m-0;
|
|
9
|
+
font-family:
|
|
10
|
+
-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu',
|
|
11
|
+
'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
|
|
12
|
+
-webkit-font-smoothing: antialiased;
|
|
13
|
+
-moz-osx-font-smoothing: grayscale;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
code {
|
|
17
|
+
font-family:
|
|
18
|
+
source-code-pro, Menlo, Monaco, Consolas, 'Courier New', monospace;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
:root {
|
|
22
|
+
--background: oklch(1 0 0);
|
|
23
|
+
--foreground: oklch(0.141 0.005 285.823);
|
|
24
|
+
--card: oklch(1 0 0);
|
|
25
|
+
--card-foreground: oklch(0.141 0.005 285.823);
|
|
26
|
+
--popover: oklch(1 0 0);
|
|
27
|
+
--popover-foreground: oklch(0.141 0.005 285.823);
|
|
28
|
+
--primary: oklch(0.21 0.006 285.885);
|
|
29
|
+
--primary-foreground: oklch(0.985 0 0);
|
|
30
|
+
--secondary: oklch(0.967 0.001 286.375);
|
|
31
|
+
--secondary-foreground: oklch(0.21 0.006 285.885);
|
|
32
|
+
--muted: oklch(0.967 0.001 286.375);
|
|
33
|
+
--muted-foreground: oklch(0.552 0.016 285.938);
|
|
34
|
+
--accent: oklch(0.967 0.001 286.375);
|
|
35
|
+
--accent-foreground: oklch(0.21 0.006 285.885);
|
|
36
|
+
--destructive: oklch(0.577 0.245 27.325);
|
|
37
|
+
--destructive-foreground: oklch(0.577 0.245 27.325);
|
|
38
|
+
--border: oklch(0.92 0.004 286.32);
|
|
39
|
+
--input: oklch(0.92 0.004 286.32);
|
|
40
|
+
--ring: oklch(0.871 0.006 286.286);
|
|
41
|
+
--chart-1: oklch(0.646 0.222 41.116);
|
|
42
|
+
--chart-2: oklch(0.6 0.118 184.704);
|
|
43
|
+
--chart-3: oklch(0.398 0.07 227.392);
|
|
44
|
+
--chart-4: oklch(0.828 0.189 84.429);
|
|
45
|
+
--chart-5: oklch(0.769 0.188 70.08);
|
|
46
|
+
--radius: 0.625rem;
|
|
47
|
+
--sidebar: oklch(0.985 0 0);
|
|
48
|
+
--sidebar-foreground: oklch(0.141 0.005 285.823);
|
|
49
|
+
--sidebar-primary: oklch(0.21 0.006 285.885);
|
|
50
|
+
--sidebar-primary-foreground: oklch(0.985 0 0);
|
|
51
|
+
--sidebar-accent: oklch(0.967 0.001 286.375);
|
|
52
|
+
--sidebar-accent-foreground: oklch(0.21 0.006 285.885);
|
|
53
|
+
--sidebar-border: oklch(0.92 0.004 286.32);
|
|
54
|
+
--sidebar-ring: oklch(0.871 0.006 286.286);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.dark {
|
|
58
|
+
--background: oklch(0.141 0.005 285.823);
|
|
59
|
+
--foreground: oklch(0.985 0 0);
|
|
60
|
+
--card: oklch(0.141 0.005 285.823);
|
|
61
|
+
--card-foreground: oklch(0.985 0 0);
|
|
62
|
+
--popover: oklch(0.141 0.005 285.823);
|
|
63
|
+
--popover-foreground: oklch(0.985 0 0);
|
|
64
|
+
--primary: oklch(0.985 0 0);
|
|
65
|
+
--primary-foreground: oklch(0.21 0.006 285.885);
|
|
66
|
+
--secondary: oklch(0.274 0.006 286.033);
|
|
67
|
+
--secondary-foreground: oklch(0.985 0 0);
|
|
68
|
+
--muted: oklch(0.274 0.006 286.033);
|
|
69
|
+
--muted-foreground: oklch(0.705 0.015 286.067);
|
|
70
|
+
--accent: oklch(0.274 0.006 286.033);
|
|
71
|
+
--accent-foreground: oklch(0.985 0 0);
|
|
72
|
+
--destructive: oklch(0.396 0.141 25.723);
|
|
73
|
+
--destructive-foreground: oklch(0.637 0.237 25.331);
|
|
74
|
+
--border: oklch(0.274 0.006 286.033);
|
|
75
|
+
--input: oklch(0.274 0.006 286.033);
|
|
76
|
+
--ring: oklch(0.442 0.017 285.786);
|
|
77
|
+
--chart-1: oklch(0.488 0.243 264.376);
|
|
78
|
+
--chart-2: oklch(0.696 0.17 162.48);
|
|
79
|
+
--chart-3: oklch(0.769 0.188 70.08);
|
|
80
|
+
--chart-4: oklch(0.627 0.265 303.9);
|
|
81
|
+
--chart-5: oklch(0.645 0.246 16.439);
|
|
82
|
+
--sidebar: oklch(0.21 0.006 285.885);
|
|
83
|
+
--sidebar-foreground: oklch(0.985 0 0);
|
|
84
|
+
--sidebar-primary: oklch(0.488 0.243 264.376);
|
|
85
|
+
--sidebar-primary-foreground: oklch(0.985 0 0);
|
|
86
|
+
--sidebar-accent: oklch(0.274 0.006 286.033);
|
|
87
|
+
--sidebar-accent-foreground: oklch(0.985 0 0);
|
|
88
|
+
--sidebar-border: oklch(0.274 0.006 286.033);
|
|
89
|
+
--sidebar-ring: oklch(0.442 0.017 285.786);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
@theme inline {
|
|
93
|
+
--color-background: var(--background);
|
|
94
|
+
--color-foreground: var(--foreground);
|
|
95
|
+
--color-card: var(--card);
|
|
96
|
+
--color-card-foreground: var(--card-foreground);
|
|
97
|
+
--color-popover: var(--popover);
|
|
98
|
+
--color-popover-foreground: var(--popover-foreground);
|
|
99
|
+
--color-primary: var(--primary);
|
|
100
|
+
--color-primary-foreground: var(--primary-foreground);
|
|
101
|
+
--color-secondary: var(--secondary);
|
|
102
|
+
--color-secondary-foreground: var(--secondary-foreground);
|
|
103
|
+
--color-muted: var(--muted);
|
|
104
|
+
--color-muted-foreground: var(--muted-foreground);
|
|
105
|
+
--color-accent: var(--accent);
|
|
106
|
+
--color-accent-foreground: var(--accent-foreground);
|
|
107
|
+
--color-destructive: var(--destructive);
|
|
108
|
+
--color-destructive-foreground: var(--destructive-foreground);
|
|
109
|
+
--color-border: var(--border);
|
|
110
|
+
--color-input: var(--input);
|
|
111
|
+
--color-ring: var(--ring);
|
|
112
|
+
--color-chart-1: var(--chart-1);
|
|
113
|
+
--color-chart-2: var(--chart-2);
|
|
114
|
+
--color-chart-3: var(--chart-3);
|
|
115
|
+
--color-chart-4: var(--chart-4);
|
|
116
|
+
--color-chart-5: var(--chart-5);
|
|
117
|
+
--radius-sm: calc(var(--radius) - 4px);
|
|
118
|
+
--radius-md: calc(var(--radius) - 2px);
|
|
119
|
+
--radius-lg: var(--radius);
|
|
120
|
+
--radius-xl: calc(var(--radius) + 4px);
|
|
121
|
+
--color-sidebar: var(--sidebar);
|
|
122
|
+
--color-sidebar-foreground: var(--sidebar-foreground);
|
|
123
|
+
--color-sidebar-primary: var(--sidebar-primary);
|
|
124
|
+
--color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
|
|
125
|
+
--color-sidebar-accent: var(--sidebar-accent);
|
|
126
|
+
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
|
|
127
|
+
--color-sidebar-border: var(--sidebar-border);
|
|
128
|
+
--color-sidebar-ring: var(--sidebar-ring);
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
@layer base {
|
|
132
|
+
* {
|
|
133
|
+
@apply border-border outline-ring/50;
|
|
134
|
+
}
|
|
135
|
+
body {
|
|
136
|
+
@apply bg-background text-foreground;
|
|
137
|
+
}
|
|
138
|
+
}
|