refactor: remplacement système de canaux statiques par canaux virtuels depuis routing

This commit is contained in:
2026-05-25 21:03:40 +02:00
parent 7037517ca2
commit 42badb1fdf
8 changed files with 252 additions and 79 deletions
+10 -6
View File
@@ -23,7 +23,8 @@ function App() {
disconnect,
switchGroup,
startTalking,
stopTalking
stopTalking,
toggleParticipantMute
} = useLiveKit();
// Charger configuration au démarrage
@@ -91,8 +92,8 @@ function App() {
console.log('🔗 Connexion LiveKit:', livekitUrl);
// Se connecter à LiveKit
await connect(livekitUrl, data.token);
// Se connecter à LiveKit avec les canaux virtuels
await connect(livekitUrl, data.token, data.virtualChannels || []);
} catch (err) {
console.error('Erreur connexion:', err);
@@ -136,8 +137,8 @@ function App() {
livekitUrl = `${window.location.protocol}//${window.location.host}/livekit`;
}
// Changer de room LiveKit
await switchGroup(livekitUrl, data.token);
// Changer de room LiveKit avec les canaux virtuels du nouveau groupe
await switchGroup(livekitUrl, data.token, data.virtualChannels || []);
// Mettre à jour l'état
setGroupId(newGroupId);
@@ -238,7 +239,10 @@ function App() {
/>
{/* Liste des participants */}
<UserList participants={participants} />
<UserList
participants={participants}
onToggleMute={toggleParticipantMute}
/>
{/* Bouton PTT principal avec VU-mètre intégré */}
<PTTButton