[mirotalksfu] - move full screen button
هذا الالتزام موجود في:
@@ -55,7 +55,7 @@ dev dependencies: {
|
|||||||
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
||||||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
||||||
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
||||||
* @version 1.5.72
|
* @version 1.5.73
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "mirotalksfu",
|
"name": "mirotalksfu",
|
||||||
"version": "1.5.72",
|
"version": "1.5.73",
|
||||||
"description": "WebRTC SFU browser-based video calls",
|
"description": "WebRTC SFU browser-based video calls",
|
||||||
"main": "Server.js",
|
"main": "Server.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
@@ -57,7 +57,7 @@
|
|||||||
"node": ">=18"
|
"node": ">=18"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@sentry/node": "^8.31.0",
|
"@sentry/node": "^8.32.0",
|
||||||
"axios": "^1.7.7",
|
"axios": "^1.7.7",
|
||||||
"body-parser": "1.20.3",
|
"body-parser": "1.20.3",
|
||||||
"colors": "1.4.0",
|
"colors": "1.4.0",
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ if (location.href.substr(0, 5) !== 'https') location.href = 'https' + location.h
|
|||||||
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
||||||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
||||||
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
||||||
* @version 1.5.72
|
* @version 1.5.73
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -383,6 +383,7 @@ function refreshMainButtonsToolTipPlacement() {
|
|||||||
setTippy('shareButton', 'Share room', placement);
|
setTippy('shareButton', 'Share room', placement);
|
||||||
setTippy('startRecButton', 'Start recording', placement);
|
setTippy('startRecButton', 'Start recording', placement);
|
||||||
setTippy('stopRecButton', 'Stop recording', placement);
|
setTippy('stopRecButton', 'Stop recording', placement);
|
||||||
|
setTippy('fullScreenButton', 'Toggle full screen', placement);
|
||||||
setTippy('emojiRoomButton', 'Toggle emoji reaction', placement);
|
setTippy('emojiRoomButton', 'Toggle emoji reaction', placement);
|
||||||
setTippy('chatButton', 'Toggle the chat', placement);
|
setTippy('chatButton', 'Toggle the chat', placement);
|
||||||
setTippy('pollButton', 'Toggle the poll', placement);
|
setTippy('pollButton', 'Toggle the poll', placement);
|
||||||
@@ -391,6 +392,7 @@ function refreshMainButtonsToolTipPlacement() {
|
|||||||
setTippy('whiteboardButton', 'Toggle the whiteboard', placement);
|
setTippy('whiteboardButton', 'Toggle the whiteboard', placement);
|
||||||
setTippy('snapshotRoomButton', 'Snapshot screen, window, or tab', placement);
|
setTippy('snapshotRoomButton', 'Snapshot screen, window, or tab', placement);
|
||||||
setTippy('settingsButton', 'Toggle the settings', placement);
|
setTippy('settingsButton', 'Toggle the settings', placement);
|
||||||
|
setTippy('restartICEButton', 'Restart ICE', placement);
|
||||||
setTippy('aboutButton', 'About this project', placement);
|
setTippy('aboutButton', 'About this project', placement);
|
||||||
|
|
||||||
// Bottom buttons
|
// Bottom buttons
|
||||||
@@ -1758,7 +1760,7 @@ function handleButtons() {
|
|||||||
transcription.stop();
|
transcription.stop();
|
||||||
};
|
};
|
||||||
fullScreenButton.onclick = () => {
|
fullScreenButton.onclick = () => {
|
||||||
rc.toggleFullScreen();
|
rc.toggleRoomFullScreen();
|
||||||
};
|
};
|
||||||
recordingImage.onclick = () => {
|
recordingImage.onclick = () => {
|
||||||
isRecording ? stopRecButton.click() : startRecButton.click();
|
isRecording ? stopRecButton.click() : startRecButton.click();
|
||||||
@@ -4456,7 +4458,7 @@ function showAbout() {
|
|||||||
imageUrl: image.about,
|
imageUrl: image.about,
|
||||||
customClass: { image: 'img-about' },
|
customClass: { image: 'img-about' },
|
||||||
position: 'center',
|
position: 'center',
|
||||||
title: 'WebRTC SFU v1.5.72',
|
title: 'WebRTC SFU v1.5.73',
|
||||||
html: `
|
html: `
|
||||||
<br />
|
<br />
|
||||||
<div id="about">
|
<div id="about">
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
|
||||||
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
|
||||||
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
|
||||||
* @version 1.5.72
|
* @version 1.5.73
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -29,6 +29,8 @@ const html = {
|
|||||||
userHand: 'fas fa-hand-paper pulsate',
|
userHand: 'fas fa-hand-paper pulsate',
|
||||||
pip: 'fas fa-images',
|
pip: 'fas fa-images',
|
||||||
fullScreen: 'fas fa-expand',
|
fullScreen: 'fas fa-expand',
|
||||||
|
fullScreenOn: 'fas fa-compress-alt',
|
||||||
|
fullScreenOff: 'fas fa-expand-alt',
|
||||||
snapshot: 'fas fa-camera-retro',
|
snapshot: 'fas fa-camera-retro',
|
||||||
sendFile: 'fas fa-upload',
|
sendFile: 'fas fa-upload',
|
||||||
sendMsg: 'fas fa-paper-plane',
|
sendMsg: 'fas fa-paper-plane',
|
||||||
@@ -255,6 +257,7 @@ class RoomClient {
|
|||||||
this.isMySettingsOpen = false;
|
this.isMySettingsOpen = false;
|
||||||
|
|
||||||
this._isConnected = false;
|
this._isConnected = false;
|
||||||
|
this.isDocumentOnFullScreen = false;
|
||||||
this.isVideoOnFullScreen = false;
|
this.isVideoOnFullScreen = false;
|
||||||
this.isVideoFullScreenSupported = this.isFullScreenSupported();
|
this.isVideoFullScreenSupported = this.isFullScreenSupported();
|
||||||
this.isVideoPictureInPictureSupported = document.pictureInPictureEnabled;
|
this.isVideoPictureInPictureSupported = document.pictureInPictureEnabled;
|
||||||
@@ -3271,15 +3274,46 @@ class RoomClient {
|
|||||||
// ####################################################
|
// ####################################################
|
||||||
|
|
||||||
isFullScreenSupported() {
|
isFullScreenSupported() {
|
||||||
return (
|
const fsSupported = (
|
||||||
document.fullscreenEnabled ||
|
document.fullscreenEnabled ||
|
||||||
document.webkitFullscreenEnabled ||
|
document.webkitFullscreenEnabled ||
|
||||||
document.mozFullScreenEnabled ||
|
document.mozFullScreenEnabled ||
|
||||||
document.msFullscreenEnabled
|
document.msFullscreenEnabled
|
||||||
);
|
);
|
||||||
|
if (fsSupported){
|
||||||
|
this.handleFullScreenEvents()
|
||||||
|
}
|
||||||
|
return fsSupported;
|
||||||
|
}
|
||||||
|
|
||||||
|
handleFullScreenEvents(){
|
||||||
|
document.addEventListener('fullscreenchange', (e) => {
|
||||||
|
const fullscreenElement = document.fullscreenElement;
|
||||||
|
if (!fullscreenElement) {
|
||||||
|
const fullScreenIcon = this.getId('fullScreenIcon');
|
||||||
|
fullScreenIcon.className = html.fullScreenOff;
|
||||||
|
this.isDocumentOnFullScreen = false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
toggleRoomFullScreen() {
|
||||||
|
const fullScreenIcon = this.getId('fullScreenIcon');
|
||||||
|
if (!document.fullscreenElement) {
|
||||||
|
document.documentElement.requestFullscreen();
|
||||||
|
fullScreenIcon.className = html.fullScreenOn;
|
||||||
|
this.isDocumentOnFullScreen = true;
|
||||||
|
} else {
|
||||||
|
if (document.exitFullscreen) {
|
||||||
|
document.exitFullscreen();
|
||||||
|
fullScreenIcon.className = html.fullScreenOff;
|
||||||
|
this.isDocumentOnFullScreen = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
toggleFullScreen(elem = null) {
|
toggleFullScreen(elem = null) {
|
||||||
|
if (this.isDocumentOnFullScreen) return;
|
||||||
const element = elem ? elem : document.documentElement;
|
const element = elem ? elem : document.documentElement;
|
||||||
const fullScreen = this.isFullScreen();
|
const fullScreen = this.isFullScreen();
|
||||||
fullScreen ? this.goOutFullscreen(element) : this.goInFullscreen(element);
|
fullScreen ? this.goOutFullscreen(element) : this.goInFullscreen(element);
|
||||||
|
|||||||
@@ -181,6 +181,7 @@ access to use this app.
|
|||||||
<button id="shareButton" class="hidden"><i class="fas fa-share-alt"></i></button>
|
<button id="shareButton" class="hidden"><i class="fas fa-share-alt"></i></button>
|
||||||
<button id="startRecButton" class="hidden"><i class="fas fa-record-vinyl"></i></button>
|
<button id="startRecButton" class="hidden"><i class="fas fa-record-vinyl"></i></button>
|
||||||
<button id="stopRecButton" class="hidden"><i class="fas fa-record-vinyl cr"></i></button>
|
<button id="stopRecButton" class="hidden"><i class="fas fa-record-vinyl cr"></i></button>
|
||||||
|
<button id="fullScreenButton" class="hidden"><i id="fullScreenIcon" class="fas fa-expand-alt"></i></button>
|
||||||
<button id="emojiRoomButton" class="hidden"><i class="fas fa-face-smile"></i></button>
|
<button id="emojiRoomButton" class="hidden"><i class="fas fa-face-smile"></i></button>
|
||||||
<button id="chatButton" class="hidden"><i class="fas fa-comments"></i></button>
|
<button id="chatButton" class="hidden"><i class="fas fa-comments"></i></button>
|
||||||
<button id="transcriptionButton" class="hidden"><i class="fas fa-closed-captioning"></i></button>
|
<button id="transcriptionButton" class="hidden"><i class="fas fa-closed-captioning"></i></button>
|
||||||
@@ -260,11 +261,6 @@ access to use this app.
|
|||||||
|
|
||||||
<div class="tabActions">
|
<div class="tabActions">
|
||||||
<div id="tabRoom" class="tabcontent">
|
<div id="tabRoom" class="tabcontent">
|
||||||
<button id="fullScreenButton" class="hidden btn-custom">
|
|
||||||
<i class="fas fa-expand-alt"></i>
|
|
||||||
<p>Full screen mode</p>
|
|
||||||
</button>
|
|
||||||
<br />
|
|
||||||
<button id="fileShareButton" class="hidden btn-custom">
|
<button id="fileShareButton" class="hidden btn-custom">
|
||||||
<i class="fas fa-folder-open"></i>
|
<i class="fas fa-folder-open"></i>
|
||||||
<p>File sharing</p>
|
<p>File sharing</p>
|
||||||
|
|||||||
المرجع في مشكلة جديدة
حظر مستخدم