refactor: factoriser le code en plusieurs fichiers (#8)
- Déplace les styles inline vers css/form.css et css/cv.css
- Crée js/main.js comme point d'entrée ES Module (type="module")
- Extrait la logique identité dans js/sections/identite.js
- Ajoute les stubs js/sections/{competences,formation,experience,hobbies}.js
- Crée les dossiers sections/{identite,competences,formation,experience,hobbies}/
avec .gitkeep et README décrivant le contenu prévu
- Met à jour index.html : liens CSS séparés, script type=module
- Met à jour README.md : avertissement ES Modules, structure des fichiers
This commit is contained in:
+90
@@ -0,0 +1,90 @@
|
||||
/* =============================================
|
||||
cv.css — Styles du rendu CV généré
|
||||
============================================= */
|
||||
|
||||
/* ── Conteneur principal du CV ── */
|
||||
.cv-container {
|
||||
background: #fff;
|
||||
color: #1a1a2e;
|
||||
border-radius: 8px;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
|
||||
margin-top: 32px;
|
||||
display: none; /* masqué par défaut, affiché après génération */
|
||||
}
|
||||
|
||||
.cv-container.visible {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* ── En-tête du CV ── */
|
||||
.cv-header {
|
||||
background: #e94560;
|
||||
color: #fff;
|
||||
padding: 32px;
|
||||
}
|
||||
|
||||
.cv-header h2 {
|
||||
font-size: 1.8rem;
|
||||
font-weight: 700;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.cv-header .cv-titre {
|
||||
font-size: 1rem;
|
||||
opacity: 0.9;
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
.cv-header .cv-contacts {
|
||||
font-size: 0.85rem;
|
||||
opacity: 0.85;
|
||||
display: flex;
|
||||
gap: 16px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
/* ── Corps du CV ── */
|
||||
.cv-body {
|
||||
padding: 28px 32px;
|
||||
}
|
||||
|
||||
.cv-section {
|
||||
margin-bottom: 28px;
|
||||
}
|
||||
|
||||
.cv-section h3 {
|
||||
font-size: 0.8rem;
|
||||
font-weight: 700;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.1em;
|
||||
color: #e94560;
|
||||
border-bottom: 2px solid #e94560;
|
||||
padding-bottom: 6px;
|
||||
margin-bottom: 14px;
|
||||
}
|
||||
|
||||
/* ── Barres de compétences ── */
|
||||
.skill-bar-container {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.skill-name {
|
||||
font-size: 0.9rem;
|
||||
margin-bottom: 4px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.skill-bar {
|
||||
height: 6px;
|
||||
background: #e0e0e0;
|
||||
border-radius: 3px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.skill-level {
|
||||
height: 100%;
|
||||
background: #e94560;
|
||||
border-radius: 3px;
|
||||
transition: width 0.4s ease;
|
||||
}
|
||||
+123
@@ -0,0 +1,123 @@
|
||||
/* =============================================
|
||||
form.css — Styles de la page et du formulaire
|
||||
============================================= */
|
||||
|
||||
*, *::before, *::after {
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
body {
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: #0f0f0f;
|
||||
color: #e0e0e0;
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, sans-serif;
|
||||
padding: 20px;
|
||||
}
|
||||
|
||||
/* ── Layout ── */
|
||||
.container {
|
||||
max-width: 520px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
header {
|
||||
text-align: center;
|
||||
margin-bottom: 32px;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-size: 2.2rem;
|
||||
font-weight: 700;
|
||||
color: #e94560;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
header p {
|
||||
color: #a0a0b0;
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
|
||||
footer {
|
||||
text-align: center;
|
||||
margin-top: 28px;
|
||||
font-size: 0.8rem;
|
||||
color: #4a4a6a;
|
||||
}
|
||||
|
||||
/* ── Card ── */
|
||||
.card {
|
||||
background: #16213e;
|
||||
border: 1px solid #2a2a4a;
|
||||
border-radius: 12px;
|
||||
padding: 32px;
|
||||
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
|
||||
}
|
||||
|
||||
/* ── Formulaire ── */
|
||||
.form-group {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
label {
|
||||
display: block;
|
||||
font-size: 0.85rem;
|
||||
color: #a0a0b0;
|
||||
margin-bottom: 6px;
|
||||
font-weight: 500;
|
||||
letter-spacing: 0.03em;
|
||||
}
|
||||
|
||||
input {
|
||||
width: 100%;
|
||||
padding: 11px 14px;
|
||||
background: #1a1a2e;
|
||||
border: 1px solid #2a2a4a;
|
||||
border-radius: 6px;
|
||||
color: #e0e0e0;
|
||||
font-size: 0.95rem;
|
||||
outline: none;
|
||||
transition: border-color 0.2s ease, box-shadow 0.2s ease;
|
||||
}
|
||||
|
||||
input::placeholder {
|
||||
color: #4a4a6a;
|
||||
}
|
||||
|
||||
input:focus {
|
||||
border-color: #e94560;
|
||||
box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.15);
|
||||
}
|
||||
|
||||
/* ── Bouton ── */
|
||||
.btn-generate {
|
||||
width: 100%;
|
||||
background: #e94560;
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 13px;
|
||||
border-radius: 6px;
|
||||
font-size: 1rem;
|
||||
font-weight: 600;
|
||||
cursor: pointer;
|
||||
margin-top: 8px;
|
||||
transition: background 0.2s ease;
|
||||
}
|
||||
|
||||
.btn-generate:hover {
|
||||
background: #f05a73;
|
||||
}
|
||||
|
||||
/* ── Message de succès ── */
|
||||
.success-message {
|
||||
display: none;
|
||||
color: #4caf50;
|
||||
text-align: center;
|
||||
padding-top: 16px;
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
Reference in New Issue
Block a user