feat: Ajout du redimensionnement manuel du panneau de notes

- Poignée de redimensionnement avec indicateur visuel permanent (3 points)
- Largeur ajustable entre 280px et 600px
- Sauvegarde automatique de la largeur préférée
- Optimisations avec requestAnimationFrame pour la fluidité
- Overlay pendant le drag pour capturer tous les mouvements
- Indicateur change de couleur au survol (gris → violet)
This commit is contained in:
Pierre Marx
2025-09-04 16:22:09 -04:00
parent 29a4cfb410
commit d66af7d99d
4 changed files with 218 additions and 2 deletions

View File

@@ -618,6 +618,8 @@ body {
top: 60px; /* Juste sous le header */
right: -400px; /* Caché par défaut */
width: 380px;
min-width: 280px;
max-width: 600px;
height: calc(100vh - 60px);
background: white;
box-shadow: -4px 0 20px rgba(0,0,0,0.1);
@@ -628,6 +630,69 @@ body {
border-left: 1px solid #e1e4e8;
}
/* Poignée de redimensionnement */
.notes-resize-handle {
position: absolute;
left: -5px;
top: 0;
bottom: 0;
width: 10px;
cursor: col-resize;
background: linear-gradient(90deg,
transparent 0%,
transparent 30%,
rgba(209, 213, 219, 0.5) 50%,
transparent 70%,
transparent 100%);
z-index: 10;
}
.notes-resize-handle:hover {
background: linear-gradient(90deg,
transparent 0%,
rgba(102, 126, 234, 0.1) 30%,
rgba(102, 126, 234, 0.3) 50%,
rgba(102, 126, 234, 0.1) 70%,
transparent 100%);
}
.notes-resize-handle:active {
background: linear-gradient(90deg,
transparent 0%,
rgba(102, 126, 234, 0.2) 30%,
rgba(102, 126, 234, 0.5) 50%,
rgba(102, 126, 234, 0.2) 70%,
transparent 100%);
}
/* Indicateur visuel permanent - 3 points verticaux */
.notes-resize-handle::before {
content: '⋮⋮⋮';
position: absolute;
left: 50%;
top: 50%;
transform: translate(-50%, -50%) rotate(90deg);
font-size: 16px;
color: #9ca3af;
letter-spacing: -4px;
font-weight: bold;
pointer-events: none;
user-select: none;
}
.notes-resize-handle:hover::before {
color: #667eea;
}
/* Désactiver les transitions pendant le redimensionnement */
.notes-section.resizing {
transition: none !important;
}
.webview-container.resizing {
transition: none !important;
}
.notes-section.visible {
right: 0;
animation: slideInRight 0.3s ease-out;
@@ -750,7 +815,7 @@ body {
/* Ajustement de la webview quand les notes sont visibles */
.webview-container.notes-open {
margin-right: 380px;
margin-right: var(--notes-width, 380px);
transition: margin-right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}