Final style.
This commit is contained in:
38
src/App.css
38
src/App.css
@ -1,38 +0,0 @@
|
||||
.App {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.App-logo {
|
||||
height: 40vmin;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.App-logo {
|
||||
animation: App-logo-spin infinite 20s linear;
|
||||
}
|
||||
}
|
||||
|
||||
.App-header {
|
||||
background-color: #282c34;
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: calc(10px + 2vmin);
|
||||
color: white;
|
||||
}
|
||||
|
||||
.App-link {
|
||||
color: #61dafb;
|
||||
}
|
||||
|
||||
@keyframes App-logo-spin {
|
||||
from {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
to {
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
@ -1,9 +0,0 @@
|
||||
import React from 'react';
|
||||
import { render, screen } from '@testing-library/react';
|
||||
import App from './App';
|
||||
|
||||
test('renders learn react link', () => {
|
||||
render(<App />);
|
||||
const linkElement = screen.getByText(/learn react/i);
|
||||
expect(linkElement).toBeInTheDocument();
|
||||
});
|
26
src/App.tsx
26
src/App.tsx
@ -1,26 +0,0 @@
|
||||
import React from 'react';
|
||||
import logo from './logo.svg';
|
||||
import './App.css';
|
||||
|
||||
function App() {
|
||||
return (
|
||||
<div className="App">
|
||||
<header className="App-header">
|
||||
<img src={logo} className="App-logo" alt="logo" />
|
||||
<p>
|
||||
Edit <code>src/App.tsx</code> and save to reload.
|
||||
</p>
|
||||
<a
|
||||
className="App-link"
|
||||
href="https://reactjs.org"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
Learn React
|
||||
</a>
|
||||
</header>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default App;
|
25
src/Assets/scss/CV.scss
Normal file
25
src/Assets/scss/CV.scss
Normal file
@ -0,0 +1,25 @@
|
||||
.card {
|
||||
@apply container p-3 bg-gray-200 rounded-md mt-8 mb-8 drop-shadow;
|
||||
}
|
||||
|
||||
.icon {
|
||||
@apply w-5 inline-block mr-2;
|
||||
}
|
||||
|
||||
.tag {
|
||||
@apply mb-2 rounded-full p-3 pt-1 pb-1 text-white shadow mr-1 prose prose-sm;
|
||||
}
|
||||
|
||||
.details {
|
||||
& > * {
|
||||
padding: 20px 0;
|
||||
}
|
||||
|
||||
& > *:first-child {
|
||||
padding-top: 0;
|
||||
}
|
||||
|
||||
& > *:last-child {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
}
|
54
src/CV.tsx
Normal file
54
src/CV.tsx
Normal file
@ -0,0 +1,54 @@
|
||||
import React, {useEffect} from 'react';
|
||||
import Header from './Components/Header';
|
||||
import './Assets/scss/CV.scss'
|
||||
import Jobs from './Components/Jobs';
|
||||
import Education from './Components/Education';
|
||||
import SideProjects from './Components/SideProjects';
|
||||
import Languages from './Components/Languages';
|
||||
import Interests from './Components/Interests';
|
||||
import Skills from './Components/Skills';
|
||||
import {Tag, TagCategory} from './Model/tag';
|
||||
import {Lang} from './Model/lang';
|
||||
import {EducationYear} from './Model/education';
|
||||
import {SideProjectCats} from './Model/side-project';
|
||||
import {JobAtCompany} from './Model/job-at-company';
|
||||
import {Interest} from './Model/interests';
|
||||
import {Profile} from './Model/profile';
|
||||
|
||||
function CV() {
|
||||
|
||||
|
||||
document.title = profile.name;
|
||||
|
||||
useEffect(() => {
|
||||
let link = document.querySelector("link[rel~='icon']");
|
||||
if (!link) {
|
||||
link = document.createElement('link');
|
||||
// @ts-ignore
|
||||
link.rel = 'icon';
|
||||
document.getElementsByTagName('head')[0].appendChild(link);
|
||||
}
|
||||
// @ts-ignore
|
||||
link.href = profile.picture
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div className="CV">
|
||||
<Header tags={tags} profile={profile}/>
|
||||
<div className="card flex divide-x divide-gray-600">
|
||||
<div className="basis-3/4 pr-2 divide-y divide-gray-400 details">
|
||||
<Jobs jobs={jobs}/>
|
||||
<Education education={ed}/>
|
||||
<SideProjects projs={projs}/>
|
||||
</div>
|
||||
<div className="basis-1/4 pl-2 divide-y divide-gray-400 details">
|
||||
<Skills tags={tags}/>
|
||||
<Languages langs={langs}/>
|
||||
<Interests interests={interests}/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export default CV;
|
17
src/Components/Education.tsx
Normal file
17
src/Components/Education.tsx
Normal file
@ -0,0 +1,17 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {AcademicCapIcon, BriefcaseIcon} from '@heroicons/react/24/outline';
|
||||
import {EducationYear} from '../Model/education';
|
||||
|
||||
function Education(props: ComponentProps<any>) {
|
||||
return (<div className="prose max-w-none">
|
||||
<h3><AcademicCapIcon className="icon"/> Formations</h3>
|
||||
{props.education.map((e: EducationYear) => <div key={e.endDate} className="mb-5">
|
||||
<div className="flex justify-between w-full"><h4 className="m-0">{e.school}</h4>
|
||||
<div>{e.endDate}</div>
|
||||
</div>
|
||||
<div>{e.name}</div>
|
||||
</div>)}
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Education;
|
43
src/Components/Header.tsx
Normal file
43
src/Components/Header.tsx
Normal file
@ -0,0 +1,43 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {CodeBracketIcon, EnvelopeIcon, PhoneIcon, UserPlusIcon} from '@heroicons/react/24/outline';
|
||||
import {getTagColor, Tag} from '../Model/tag';
|
||||
import {Profile} from '../Model/profile';
|
||||
|
||||
function Header(props: ComponentProps<any>) {
|
||||
const tags = props.tags.filter((t: Tag) => t.workThing)
|
||||
const profile: Profile = props.profile
|
||||
return (<div
|
||||
className="card flex flex-wrap-reverse">
|
||||
<div className="basis-1/4">
|
||||
<img className="w-60 rounded-full shadow-lg lg:divide-x divide-gray-600" src={profile.picture}
|
||||
/>
|
||||
</div>
|
||||
<div className="basis-2/4 prose p-3 prose-sm grow">
|
||||
<h1>{profile.name}</h1>
|
||||
<h2>{profile.title}</h2>
|
||||
<blockquote>{profile.quote}</blockquote>
|
||||
<div className="prose flex flex-wrap justify-between"> {/* Tags */}
|
||||
{tags.map((t: Tag) => <button key={t.name} className={"tag " + getTagColor(t)}>{t.name}</button>)}
|
||||
</div>
|
||||
</div>
|
||||
<div className="basis-1/4 lg:divide-y divide-gray-400 prose p-3 grow">
|
||||
<div className="text-center lg:text-left">
|
||||
<h3 className="mt-2 mb-1">Me contacter</h3>
|
||||
<div><EnvelopeIcon className="icon"/><a className="" href={"mailto:" + profile.email}>Par
|
||||
mail</a></div>
|
||||
<div><PhoneIcon className="icon"/><a className="" href={"tel:" + profile.phone}>Par
|
||||
téléphone</a></div>
|
||||
<h3 className="mt-2 mb-1">Me connaitre</h3>
|
||||
<div><UserPlusIcon className="icon"/><a className=""
|
||||
href={profile.linkedin}
|
||||
|
||||
target="_blank">Mon linkedin</a></div>
|
||||
<div><CodeBracketIcon className="icon"/><a className=""
|
||||
href={profile.source} target="_blank">Mon
|
||||
code</a></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Header;
|
14
src/Components/Interests.tsx
Normal file
14
src/Components/Interests.tsx
Normal file
@ -0,0 +1,14 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {CalendarDaysIcon, FaceSmileIcon, LanguageIcon} from '@heroicons/react/24/outline';
|
||||
import {Interest} from '../Model/interests';
|
||||
|
||||
function Interests(props: ComponentProps<any>) {
|
||||
return (<div className="prose">
|
||||
<h3><FaceSmileIcon className="icon"/> Centre d'intérets</h3>
|
||||
<ul>
|
||||
{props.interests.map((i: Interest) => <li key={i.theme}><strong>{i.theme}</strong> : {i.description}</li>)}
|
||||
</ul>
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Interests;
|
16
src/Components/Job.tsx
Normal file
16
src/Components/Job.tsx
Normal file
@ -0,0 +1,16 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {BriefcaseIcon} from '@heroicons/react/24/outline';
|
||||
|
||||
function Job(props: ComponentProps<any>) {
|
||||
return (<div className="mb-5">
|
||||
<div className="flex justify-between w-full"><h4 className="m-0">{props.jobTitle}</h4>
|
||||
<div>{props.start} - {props.end}</div>
|
||||
</div>
|
||||
<h5>{props.company}</h5>
|
||||
<ul>
|
||||
{props.tasks.map((task: string) => <li key={task}>{task}</li>)}
|
||||
</ul>
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Job;
|
14
src/Components/Jobs.tsx
Normal file
14
src/Components/Jobs.tsx
Normal file
@ -0,0 +1,14 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {BriefcaseIcon} from '@heroicons/react/24/outline';
|
||||
import Job from './Job';
|
||||
import {JobAtCompany} from '../Model/job-at-company';
|
||||
|
||||
function Jobs(props: ComponentProps<any>) {
|
||||
return (<div className="prose max-w-none">
|
||||
<h3><BriefcaseIcon className="icon"/> Expériences professionnelles</h3>
|
||||
{props.jobs.map((j: JobAtCompany) => <Job jobTitle={j.jobTitle} start={j.start} end={j.end} company={j.company} tasks={j.tasks} key={j.start}></Job>)}
|
||||
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Jobs;
|
14
src/Components/Languages.tsx
Normal file
14
src/Components/Languages.tsx
Normal file
@ -0,0 +1,14 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {CalendarDaysIcon, LanguageIcon} from '@heroicons/react/24/outline';
|
||||
import {Lang} from '../Model/lang';
|
||||
|
||||
function Languages(props: ComponentProps<any>) {
|
||||
return (<div className="prose">
|
||||
<h3><LanguageIcon className="icon"/> Langues</h3>
|
||||
<ul>
|
||||
{props.langs.map((l: Lang) => <li key={l.lang}>{l.lang} : {l.level}</li>)}
|
||||
</ul>
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Languages;
|
23
src/Components/SideProjects.tsx
Normal file
23
src/Components/SideProjects.tsx
Normal file
@ -0,0 +1,23 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {BeakerIcon} from '@heroicons/react/24/outline';
|
||||
import {SideProjectCats} from '../Model/side-project';
|
||||
|
||||
function SideProjects(props: ComponentProps<any>) {
|
||||
return (<div className="prose">
|
||||
<h3><BeakerIcon className="icon"/> Projets personnels</h3>
|
||||
{props.projs.map((proj: SideProjectCats) => {
|
||||
return (<div key={proj.category}>
|
||||
<h4>{proj.category}</h4>
|
||||
<ul>
|
||||
{proj.projects.map(p => {
|
||||
return (<li key={p.description}>
|
||||
{p.title ? <div><a href={p.url}>{p.title}</a> {p.description}</div> : <div>{p.description}</div>}
|
||||
</li>)
|
||||
})}
|
||||
</ul>
|
||||
</div>)
|
||||
})}
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default SideProjects;
|
23
src/Components/Skills.tsx
Normal file
23
src/Components/Skills.tsx
Normal file
@ -0,0 +1,23 @@
|
||||
import React, {ComponentProps} from 'react';
|
||||
import {CalendarDaysIcon, CheckBadgeIcon, LanguageIcon} from '@heroicons/react/24/outline';
|
||||
import {getTagColor, Tag, TagCategory} from '../Model/tag';
|
||||
import {forIn, groupBy, map} from 'lodash';
|
||||
|
||||
function Skills(props: ComponentProps<any>) {
|
||||
const tagsByCat = groupBy(props.tags, 'category')
|
||||
return (<div className="prose">
|
||||
<h3><CheckBadgeIcon className="icon"/> Compétences</h3>
|
||||
<div className="flex flex-wrap justify-between">
|
||||
{map(tagsByCat, (tags, cat) => {
|
||||
return (<div key={cat}>
|
||||
<h4 className="m-0 mb-1.5">{cat}</h4>
|
||||
<div>
|
||||
{tags.map((t: Tag) => <button key={t.name} className={"tag " + getTagColor(t)}>{t.name}</button>)}
|
||||
</div>
|
||||
</div>)
|
||||
})}
|
||||
</div>
|
||||
</div>);
|
||||
}
|
||||
|
||||
export default Skills;
|
5
src/Model/education.ts
Normal file
5
src/Model/education.ts
Normal file
@ -0,0 +1,5 @@
|
||||
export class EducationYear {
|
||||
endDate!: string
|
||||
school!: string
|
||||
name!: string
|
||||
}
|
4
src/Model/interests.ts
Normal file
4
src/Model/interests.ts
Normal file
@ -0,0 +1,4 @@
|
||||
export class Interest {
|
||||
theme!: string
|
||||
description!: string
|
||||
}
|
7
src/Model/job-at-company.ts
Normal file
7
src/Model/job-at-company.ts
Normal file
@ -0,0 +1,7 @@
|
||||
export class JobAtCompany {
|
||||
jobTitle!: string
|
||||
start!: string
|
||||
end!: string
|
||||
company!: string
|
||||
tasks!: string[]
|
||||
}
|
4
src/Model/lang.ts
Normal file
4
src/Model/lang.ts
Normal file
@ -0,0 +1,4 @@
|
||||
export class Lang {
|
||||
lang!: string
|
||||
level!: string
|
||||
}
|
10
src/Model/profile.ts
Normal file
10
src/Model/profile.ts
Normal file
@ -0,0 +1,10 @@
|
||||
export class Profile {
|
||||
name!: string
|
||||
title!: string
|
||||
quote!: string
|
||||
picture!: string
|
||||
email?: string
|
||||
phone?: string
|
||||
linkedin?: string
|
||||
source?: string
|
||||
}
|
10
src/Model/side-project.ts
Normal file
10
src/Model/side-project.ts
Normal file
@ -0,0 +1,10 @@
|
||||
export class SideProject {
|
||||
title?: string
|
||||
url?: string
|
||||
description!: string
|
||||
}
|
||||
|
||||
export class SideProjectCats {
|
||||
category!: string
|
||||
projects!: SideProject[];
|
||||
}
|
29
src/Model/tag.ts
Normal file
29
src/Model/tag.ts
Normal file
@ -0,0 +1,29 @@
|
||||
export function getTagColor(t: Tag) {
|
||||
switch (t.category) {
|
||||
case TagCategory.FRONT:
|
||||
return "bg-rose-500"
|
||||
case TagCategory.BACK:
|
||||
return "bg-indigo-600"
|
||||
case TagCategory.MOBILE:
|
||||
return "bg-yellow-500"
|
||||
case TagCategory.DB:
|
||||
return "bg-emerald-500"
|
||||
case TagCategory.OTHER:
|
||||
return "bg-stone-300"
|
||||
}
|
||||
};
|
||||
|
||||
export enum TagCategory {
|
||||
FRONT = 'Developpement Front',
|
||||
BACK = 'Developpement Back',
|
||||
MOBILE = 'Developpement Mobile',
|
||||
DB = 'Bases de données',
|
||||
OTHER = 'Autre'
|
||||
}
|
||||
|
||||
export class Tag {
|
||||
name: string = ""
|
||||
workThing: Boolean = true
|
||||
category!: TagCategory
|
||||
}
|
||||
|
@ -1,13 +1,3 @@
|
||||
body {
|
||||
margin: 0;
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
|
||||
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
|
||||
sans-serif;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
|
||||
code {
|
||||
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
|
||||
monospace;
|
||||
}
|
||||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
||||
|
@ -1,7 +1,7 @@
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom/client';
|
||||
import './index.css';
|
||||
import App from './App';
|
||||
import CV from './CV';
|
||||
import reportWebVitals from './reportWebVitals';
|
||||
|
||||
const root = ReactDOM.createRoot(
|
||||
@ -9,7 +9,7 @@ const root = ReactDOM.createRoot(
|
||||
);
|
||||
root.render(
|
||||
<React.StrictMode>
|
||||
<App />
|
||||
<CV />
|
||||
</React.StrictMode>
|
||||
);
|
||||
|
||||
|
@ -1 +0,0 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 841.9 595.3"><g fill="#61DAFB"><path d="M666.3 296.5c0-32.5-40.7-63.3-103.1-82.4 14.4-63.6 8-114.2-20.2-130.4-6.5-3.8-14.1-5.6-22.4-5.6v22.3c4.6 0 8.3.9 11.4 2.6 13.6 7.8 19.5 37.5 14.9 75.7-1.1 9.4-2.9 19.3-5.1 29.4-19.6-4.8-41-8.5-63.5-10.9-13.5-18.5-27.5-35.3-41.6-50 32.6-30.3 63.2-46.9 84-46.9V78c-27.5 0-63.5 19.6-99.9 53.6-36.4-33.8-72.4-53.2-99.9-53.2v22.3c20.7 0 51.4 16.5 84 46.6-14 14.7-28 31.4-41.3 49.9-22.6 2.4-44 6.1-63.6 11-2.3-10-4-19.7-5.2-29-4.7-38.2 1.1-67.9 14.6-75.8 3-1.8 6.9-2.6 11.5-2.6V78.5c-8.4 0-16 1.8-22.6 5.6-28.1 16.2-34.4 66.7-19.9 130.1-62.2 19.2-102.7 49.9-102.7 82.3 0 32.5 40.7 63.3 103.1 82.4-14.4 63.6-8 114.2 20.2 130.4 6.5 3.8 14.1 5.6 22.5 5.6 27.5 0 63.5-19.6 99.9-53.6 36.4 33.8 72.4 53.2 99.9 53.2 8.4 0 16-1.8 22.6-5.6 28.1-16.2 34.4-66.7 19.9-130.1 62-19.1 102.5-49.9 102.5-82.3zm-130.2-66.7c-3.7 12.9-8.3 26.2-13.5 39.5-4.1-8-8.4-16-13.1-24-4.6-8-9.5-15.8-14.4-23.4 14.2 2.1 27.9 4.7 41 7.9zm-45.8 106.5c-7.8 13.5-15.8 26.3-24.1 38.2-14.9 1.3-30 2-45.2 2-15.1 0-30.2-.7-45-1.9-8.3-11.9-16.4-24.6-24.2-38-7.6-13.1-14.5-26.4-20.8-39.8 6.2-13.4 13.2-26.8 20.7-39.9 7.8-13.5 15.8-26.3 24.1-38.2 14.9-1.3 30-2 45.2-2 15.1 0 30.2.7 45 1.9 8.3 11.9 16.4 24.6 24.2 38 7.6 13.1 14.5 26.4 20.8 39.8-6.3 13.4-13.2 26.8-20.7 39.9zm32.3-13c5.4 13.4 10 26.8 13.8 39.8-13.1 3.2-26.9 5.9-41.2 8 4.9-7.7 9.8-15.6 14.4-23.7 4.6-8 8.9-16.1 13-24.1zM421.2 430c-9.3-9.6-18.6-20.3-27.8-32 9 .4 18.2.7 27.5.7 9.4 0 18.7-.2 27.8-.7-9 11.7-18.3 22.4-27.5 32zm-74.4-58.9c-14.2-2.1-27.9-4.7-41-7.9 3.7-12.9 8.3-26.2 13.5-39.5 4.1 8 8.4 16 13.1 24 4.7 8 9.5 15.8 14.4 23.4zM420.7 163c9.3 9.6 18.6 20.3 27.8 32-9-.4-18.2-.7-27.5-.7-9.4 0-18.7.2-27.8.7 9-11.7 18.3-22.4 27.5-32zm-74 58.9c-4.9 7.7-9.8 15.6-14.4 23.7-4.6 8-8.9 16-13 24-5.4-13.4-10-26.8-13.8-39.8 13.1-3.1 26.9-5.8 41.2-7.9zm-90.5 125.2c-35.4-15.1-58.3-34.9-58.3-50.6 0-15.7 22.9-35.6 58.3-50.6 8.6-3.7 18-7 27.7-10.1 5.7 19.6 13.2 40 22.5 60.9-9.2 20.8-16.6 41.1-22.2 60.6-9.9-3.1-19.3-6.5-28-10.2zM310 490c-13.6-7.8-19.5-37.5-14.9-75.7 1.1-9.4 2.9-19.3 5.1-29.4 19.6 4.8 41 8.5 63.5 10.9 13.5 18.5 27.5 35.3 41.6 50-32.6 30.3-63.2 46.9-84 46.9-4.5-.1-8.3-1-11.3-2.7zm237.2-76.2c4.7 38.2-1.1 67.9-14.6 75.8-3 1.8-6.9 2.6-11.5 2.6-20.7 0-51.4-16.5-84-46.6 14-14.7 28-31.4 41.3-49.9 22.6-2.4 44-6.1 63.6-11 2.3 10.1 4.1 19.8 5.2 29.1zm38.5-66.7c-8.6 3.7-18 7-27.7 10.1-5.7-19.6-13.2-40-22.5-60.9 9.2-20.8 16.6-41.1 22.2-60.6 9.9 3.1 19.3 6.5 28.1 10.2 35.4 15.1 58.3 34.9 58.3 50.6-.1 15.7-23 35.6-58.4 50.6zM320.8 78.4z"/><circle cx="420.9" cy="296.5" r="45.7"/><path d="M520.5 78.1z"/></g></svg>
|
Before Width: | Height: | Size: 2.6 KiB |
Reference in New Issue
Block a user