[mirotalksfu] - add profile tab
هذا الالتزام موجود في:
@@ -318,6 +318,12 @@ body {
|
|||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#myProfileAvatar {
|
||||||
|
margin-top: 10px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
padding: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
.form-check-input {
|
.form-check-input {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -157,6 +157,7 @@ function initClient() {
|
|||||||
setTippy('tabRecordingBtn', 'Recording', 'top');
|
setTippy('tabRecordingBtn', 'Recording', 'top');
|
||||||
setTippy('tabRoomBtn', 'Room', 'top');
|
setTippy('tabRoomBtn', 'Room', 'top');
|
||||||
setTippy('tabVideoShareBtn', 'Video share', 'top');
|
setTippy('tabVideoShareBtn', 'Video share', 'top');
|
||||||
|
setTippy('tabProfileBtn', 'Profile', 'top');
|
||||||
setTippy('tabAspectBtn', 'Aspect', 'top');
|
setTippy('tabAspectBtn', 'Aspect', 'top');
|
||||||
setTippy('tabStylingBtn', 'Styling', 'top');
|
setTippy('tabStylingBtn', 'Styling', 'top');
|
||||||
setTippy('tabLanguagesBtn', 'Languages', 'top');
|
setTippy('tabLanguagesBtn', 'Languages', 'top');
|
||||||
@@ -815,6 +816,8 @@ function joinRoom(peer_name, room_id) {
|
|||||||
} else {
|
} else {
|
||||||
console.log('05 ----> join Room ' + room_id);
|
console.log('05 ----> join Room ' + room_id);
|
||||||
roomId.innerText = room_id;
|
roomId.innerText = room_id;
|
||||||
|
userName.innerText = peer_name;
|
||||||
|
isUserPresenter.innerText = isPresenter;
|
||||||
rc = new RoomClient(
|
rc = new RoomClient(
|
||||||
localAudio,
|
localAudio,
|
||||||
remoteAudios,
|
remoteAudios,
|
||||||
@@ -838,6 +841,7 @@ function joinRoom(peer_name, room_id) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function roomIsReady() {
|
function roomIsReady() {
|
||||||
|
myProfileAvatar.setAttribute('src', rc.genAvatarSvg(peer_name, 64));
|
||||||
BUTTONS.main.exitButton && show(exitButton);
|
BUTTONS.main.exitButton && show(exitButton);
|
||||||
BUTTONS.main.shareButton && show(shareButton);
|
BUTTONS.main.shareButton && show(shareButton);
|
||||||
BUTTONS.main.hideMeButton && show(hideMeButton);
|
BUTTONS.main.hideMeButton && show(hideMeButton);
|
||||||
@@ -1031,6 +1035,9 @@ function handleButtons() {
|
|||||||
tabAspectBtn.onclick = (e) => {
|
tabAspectBtn.onclick = (e) => {
|
||||||
rc.openTab(e, 'tabAspect');
|
rc.openTab(e, 'tabAspect');
|
||||||
};
|
};
|
||||||
|
tabProfileBtn.onclick = (e) => {
|
||||||
|
rc.openTab(e, 'tabProfile');
|
||||||
|
};
|
||||||
tabStylingBtn.onclick = (e) => {
|
tabStylingBtn.onclick = (e) => {
|
||||||
rc.openTab(e, 'tabStyling');
|
rc.openTab(e, 'tabStyling');
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -325,6 +325,7 @@ class RoomClient {
|
|||||||
let my_peer_info = peers.get(peer).peer_info;
|
let my_peer_info = peers.get(peer).peer_info;
|
||||||
console.log('07.1 ----> My Peer info', my_peer_info);
|
console.log('07.1 ----> My Peer info', my_peer_info);
|
||||||
isPresenter = window.localStorage.isReconnected === 'true' ? isPresenter : my_peer_info.peer_presenter;
|
isPresenter = window.localStorage.isReconnected === 'true' ? isPresenter : my_peer_info.peer_presenter;
|
||||||
|
this.getId('isUserPresenter').innerText = isPresenter;
|
||||||
window.localStorage.isReconnected = false;
|
window.localStorage.isReconnected = false;
|
||||||
handleRules(isPresenter);
|
handleRules(isPresenter);
|
||||||
}
|
}
|
||||||
@@ -3937,6 +3938,7 @@ class RoomClient {
|
|||||||
// Only the presenter can lock the room
|
// Only the presenter can lock the room
|
||||||
if (isPresenter || res.peerCounts == 1) {
|
if (isPresenter || res.peerCounts == 1) {
|
||||||
isPresenter = true;
|
isPresenter = true;
|
||||||
|
this.getId('isUserPresenter').innerText = isPresenter;
|
||||||
data.password = room_password;
|
data.password = room_password;
|
||||||
this.socket.emit('roomAction', data);
|
this.socket.emit('roomAction', data);
|
||||||
this.roomStatus(action);
|
this.roomStatus(action);
|
||||||
|
|||||||
@@ -161,6 +161,9 @@ access to use this app.
|
|||||||
<button id="tabVideoShareBtn" class="fab fa-youtube tablinks">
|
<button id="tabVideoShareBtn" class="fab fa-youtube tablinks">
|
||||||
<p class="tabButtonText">Media</p>
|
<p class="tabButtonText">Media</p>
|
||||||
</button>
|
</button>
|
||||||
|
<button id="tabProfileBtn" class="fas fa-user">
|
||||||
|
<p class="tabButtonText">Profile</p>
|
||||||
|
</button>
|
||||||
<button id="tabAspectBtn" class="fas fa-screwdriver-wrench tablinks">
|
<button id="tabAspectBtn" class="fas fa-screwdriver-wrench tablinks">
|
||||||
<p class="tabButtonText">Aspect</p>
|
<p class="tabButtonText">Aspect</p>
|
||||||
</button>
|
</button>
|
||||||
@@ -415,6 +418,32 @@ access to use this app.
|
|||||||
<br />
|
<br />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div id="tabProfile" class="tabcontent">
|
||||||
|
<div>
|
||||||
|
<img id="myProfileAvatar" />
|
||||||
|
</div>
|
||||||
|
<table class="settingsTable">
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<div class="title">
|
||||||
|
<i class="fa-solid fa-user"></i>
|
||||||
|
<p>Username:</p>
|
||||||
|
<p id="userName">UserName</p>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<div class="title">
|
||||||
|
<i class="fa-solid fa-user-shield"></i>
|
||||||
|
<p>Presenter:</p>
|
||||||
|
<p id="isUserPresenter">true</p>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div id="tabAspect" class="tabcontent">
|
<div id="tabAspect" class="tabcontent">
|
||||||
<br />
|
<br />
|
||||||
<div class="title">
|
<div class="title">
|
||||||
|
|||||||
المرجع في مشكلة جديدة
حظر مستخدم