feat: mode PTT continu avec activation par appui long (Phase 2.2)

- Nouveau mode PTT continu (lock) activé par appui long de 3s
- Barre de progression visuelle pendant l'appui (0-100%)
- Badge cadenas en haut à droite quand mode actif
- Animation pulsante distinctive pour mode lock
- Feedback haptique à l'activation (triple vibration)
- Désactivation par simple tap quand mode lock actif
- Indication textuelle claire de l'état (normal/lock)
- Styles responsifs mobile + accessibilité (prefers-reduced-motion)

Mode d'emploi :
- Normal : Maintenir pour parler, relâcher pour arrêter
- Lock : Maintenir 3s → mode continu → tap pour désactiver

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2026-05-23 09:34:30 +02:00
parent 3181c62e57
commit 78e9a32e12
2 changed files with 211 additions and 19 deletions
+81 -1
View File
@@ -60,6 +60,14 @@
animation: pulse-talking 1.5s ease-in-out infinite;
}
/* État: Mode lock (continu) */
.ptt-button.locked {
background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
box-shadow: 0 8px 32px rgba(220, 38, 38, 0.6),
0 0 80px rgba(220, 38, 38, 0.4);
animation: pulse-locked 2s ease-in-out infinite;
}
@keyframes pulse-talking {
0%, 100% {
transform: scale(1);
@@ -69,6 +77,19 @@
}
}
@keyframes pulse-locked {
0%, 100% {
transform: scale(1);
box-shadow: 0 8px 32px rgba(220, 38, 38, 0.6),
0 0 80px rgba(220, 38, 38, 0.4);
}
50% {
transform: scale(1.03);
box-shadow: 0 8px 40px rgba(220, 38, 38, 0.7),
0 0 100px rgba(220, 38, 38, 0.5);
}
}
/* Icône micro */
.ptt-icon {
width: 64px;
@@ -96,6 +117,49 @@
color: var(--color-text-secondary);
font-size: 0.9rem;
text-align: center;
max-width: 90%;
line-height: 1.4;
}
/* Indicateur de progression pour mode lock */
.lock-progress {
position: absolute;
bottom: 0;
left: 0;
height: 6px;
background: linear-gradient(90deg, #fbbf24, #f59e0b);
border-radius: 0 0 0 120px;
transition: width 0.05s linear;
box-shadow: 0 0 20px rgba(251, 191, 36, 0.6);
z-index: 1;
}
/* Badge mode lock */
.lock-badge {
position: absolute;
top: 20px;
right: 20px;
width: 40px;
height: 40px;
background: rgba(255, 255, 255, 0.2);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
backdrop-filter: blur(10px);
animation: lock-badge-pulse 1s ease-in-out infinite;
z-index: 2;
}
@keyframes lock-badge-pulse {
0%, 100% {
transform: scale(1);
background: rgba(255, 255, 255, 0.2);
}
50% {
transform: scale(1.1);
background: rgba(255, 255, 255, 0.3);
}
}
/* Responsive mobile */
@@ -140,11 +204,27 @@
}
}
/* Responsive mobile - badge lock */
@media (max-width: 640px) {
.lock-badge {
top: 15px;
right: 15px;
width: 36px;
height: 36px;
}
}
/* Accessibilité : désactiver effets réduits */
@media (prefers-reduced-motion: reduce) {
.ptt-button,
.ptt-button.talking {
.ptt-button.talking,
.ptt-button.locked,
.lock-badge {
animation: none;
transition: none;
}
.lock-progress {
transition: none;
}
}