Add support for moderating rooms. Kick user, mute all users, stop all videos.

This commit is contained in:
Håvar Aambø Fosstveit
2020-03-22 00:43:47 +01:00
parent c70740f5c7
commit 7f2f27b858
15 changed files with 515 additions and 57 deletions
+12
View File
@@ -10,6 +10,18 @@ export const loggedIn = (flag) =>
payload : { flag }
});
export const addRole = ({ role }) =>
({
type : 'ADD_ROLE',
payload : { role }
});
export const removeRole = (role) =>
({
type : 'REMOVE_ROLE',
payload : { role }
});
export const setPicture = (picture) =>
({
type : 'SET_PICTURE',
+19
View File
@@ -45,3 +45,22 @@ export const setPeerPicture = (peerId, picture) =>
type : 'SET_PEER_PICTURE',
payload : { peerId, picture }
});
export const addPeerRole = (peerId, role) =>
({
type : 'ADD_PEER_ROLE',
payload : { peerId, role }
});
export const removePeerRole = (peerId, role) =>
({
type : 'REMOVE_PEER_ROLE',
payload : { peerId, role }
});
export const setPeerKickInProgress = (peerId, flag) =>
({
type : 'SET_PEER_KICK_IN_PROGRESS',
payload : { peerId, flag }
});
+12
View File
@@ -109,4 +109,16 @@ export const toggleConsumerFullscreen = (consumerId) =>
({
type : 'TOGGLE_FULLSCREEN_CONSUMER',
payload : { consumerId }
});
export const setMuteAllInProgress = (flag) =>
({
type : 'MUTE_ALL_IN_PROGRESS',
payload : { flag }
});
export const setStopAllVideoInProgress = (flag) =>
({
type : 'STOP_ALL_VIDEO_IN_PROGRESS',
payload : { flag }
});