[mirotalksfu] - improvements

هذا الالتزام موجود في:
Miroslav Pejic
2024-07-31 12:39:59 +02:00
الأصل 693ba2934a
التزام 8cf0c526da
2 ملفات معدلة مع 16 إضافات و4 حذوفات

عرض الملف

@@ -175,6 +175,7 @@
right: 0; right: 0;
bottom: 0; bottom: 0;
margin: auto; margin: auto;
transition: box-shadow 0.3s ease;
} }
.videoDefault { .videoDefault {
@@ -182,6 +183,7 @@
width: 100%; width: 100%;
height: 100%; height: 100%;
border-radius: '10px'; border-radius: '10px';
transition: box-shadow 0.3s ease;
} }
video { video {

عرض الملف

@@ -6249,12 +6249,13 @@ class RoomClient {
if ([80, 90, 100].includes(audioVolumeTmp)) audioColorTmp = 'red'; if ([80, 90, 100].includes(audioVolumeTmp)) audioColorTmp = 'red';
if (!isPitchBarEnabled) { if (!isPitchBarEnabled) {
const peerVideo = this.getName(peer_id)[0];
const peerAvatarImg = this.getId(peer_id + '__img'); const peerAvatarImg = this.getId(peer_id + '__img');
if (peerAvatarImg) { if (peerAvatarImg) {
peerAvatarImg.style.boxShadow = `0 0 20px ${audioColorTmp}`; this.applyBoxShadowEffect(peerAvatarImg, audioColorTmp, 200);
setTimeout(function () { }
peerAvatarImg.style.boxShadow = 'none'; if (peerVideo && peerVideo.classList.contains('videoCircle')) {
}, 200); this.applyBoxShadowEffect(peerVideo, audioColorTmp, 200);
} }
return; return;
} }
@@ -6277,6 +6278,15 @@ class RoomClient {
}, 200); }, 200);
} }
applyBoxShadowEffect(element, color, delay = 200) {
if (element) {
element.style.boxShadow = `0 0 20px ${color}`;
setTimeout(() => {
element.style.boxShadow = 'none';
}, delay);
}
}
// #################################################### // ####################################################
// HANDLE PEER VOLUME // HANDLE PEER VOLUME
// ################################################### // ###################################################