fix: correct visual regressions and UX gaps from review

- Remove double border-top separator on evaluation-summary-section
- Add overflow: hidden to competence-card to contain header negative margins
- Replace removed --shadow-lg with --shadow-card-hover in .dragging rule
- Add htmlFor/id pairing on checkbox and label for click accessibility
- Show error toast when PDF export attempted with no observation generated

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
sebvtl728
2026-06-21 17:13:37 +02:00
parent 979d95f98e
commit 6ade968121
2 changed files with 9 additions and 5 deletions
+3 -3
View File
@@ -392,6 +392,7 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
gap: 16px; gap: 16px;
overflow: hidden;
} }
.competence-card h4 { .competence-card h4 {
@@ -476,7 +477,7 @@
background: var(--color-indigo-50); background: var(--color-indigo-50);
border-color: var(--color-indigo-500); border-color: var(--color-indigo-500);
border-style: dashed; border-style: dashed;
box-shadow: var(--shadow-lg); box-shadow: var(--shadow-card-hover);
} }
.competence-item .competence-label { .competence-item .competence-label {
@@ -710,8 +711,7 @@
/* Restructured summary and evaluation output section */ /* Restructured summary and evaluation output section */
.evaluation-summary-section { .evaluation-summary-section {
margin-top: 40px; margin-top: 40px;
border-top: 1px dashed var(--border-slate-200); padding-top: 0;
padding-top: 32px;
text-align: left; text-align: left;
} }
+6 -2
View File
@@ -696,7 +696,10 @@ ${notesFormateur}`,
const downloadPDF = useCallback(async () => { const downloadPDF = useCallback(async () => {
const textRaw = observation.trim(); const textRaw = observation.trim();
if (!textRaw) return; if (!textRaw) {
showStatus("Génère d'abord un bilan avant d'exporter le PDF.", "error");
return;
}
try { try {
showStatus("Préparation du PDF…", "info", true); showStatus("Préparation du PDF…", "info", true);
@@ -1047,6 +1050,7 @@ ${notesFormateur}`,
onDragEnd={handleDragEnd} onDragEnd={handleDragEnd}
> >
<input <input
id={`check-${item.id}`}
type="checkbox" type="checkbox"
className="competence-checkbox sel" className="competence-checkbox sel"
checked={item.checked} checked={item.checked}
@@ -1054,7 +1058,7 @@ ${notesFormateur}`,
updateItem(item.id, { checked: event.target.checked }) updateItem(item.id, { checked: event.target.checked })
} }
/> />
<label className="competence-label"> <label className="competence-label" htmlFor={`check-${item.id}`}>
<div>{item.label}</div> <div>{item.label}</div>
</label> </label>
<div <div