Port sync, queue management and notifs.

This commit is contained in:
Paul
2021-06-21 13:28:26 +01:00
parent 3555e9a7bf
commit 0115ace3fa
20 changed files with 521 additions and 35 deletions

View File

@@ -0,0 +1,21 @@
import message from './message.mp3';
import call_join from './call_join.mp3';
import call_leave from './call_leave.mp3';
const SoundMap: { [key in Sounds]: string } = {
message,
call_join,
call_leave
}
export type Sounds = 'message' | 'call_join' | 'call_leave';
export function playSound(sound: Sounds) {
let file = SoundMap[sound];
let el = new Audio(file);
try {
el.play();
} catch (err) {
console.error('Failed to play audio file', file, err);
}
}

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.