[mirotalksfu] - fix prettier lint
هذا الالتزام موجود في:
@@ -1,6 +1,6 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
semi: true,
|
semi: true,
|
||||||
trailingComma: 'all',
|
trailingComma: 'es5', // Trailing commas only where valid in ES5 (objects, arrays, not function arguments)
|
||||||
singleQuote: true,
|
singleQuote: true,
|
||||||
printWidth: 120,
|
printWidth: 120,
|
||||||
tabWidth: 4,
|
tabWidth: 4,
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ class HtmlInjector {
|
|||||||
// Replace placeholders with dynamic data (OG, TITLE, etc.)
|
// Replace placeholders with dynamic data (OG, TITLE, etc.)
|
||||||
const modifiedHTML = this.cache[filePath].replace(
|
const modifiedHTML = this.cache[filePath].replace(
|
||||||
/{{(OG_[A-Z_]+)}}/g,
|
/{{(OG_[A-Z_]+)}}/g,
|
||||||
(_, key) => this.injectData[key] || '',
|
(_, key) => this.injectData[key] || ''
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!res.headersSent) {
|
if (!res.headersSent) {
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ module.exports = class Logger {
|
|||||||
console.debug(
|
console.debug(
|
||||||
'[' + this.getDateTime() + '] [' + this.appName + '] ' + msg,
|
'[' + this.getDateTime() + '] [' + this.appName + '] ' + msg,
|
||||||
util.inspect(op, options),
|
util.inspect(op, options),
|
||||||
this.timeElapsedMs,
|
this.timeElapsedMs
|
||||||
);
|
);
|
||||||
this.timeStart = Date.now();
|
this.timeStart = Date.now();
|
||||||
}
|
}
|
||||||
@@ -45,21 +45,21 @@ module.exports = class Logger {
|
|||||||
info(msg, op = '') {
|
info(msg, op = '') {
|
||||||
console.info(
|
console.info(
|
||||||
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.green(msg),
|
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.green(msg),
|
||||||
util.inspect(op, options),
|
util.inspect(op, options)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
warn(msg, op = '') {
|
warn(msg, op = '') {
|
||||||
console.warn(
|
console.warn(
|
||||||
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.yellow(msg),
|
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.yellow(msg),
|
||||||
util.inspect(op, options),
|
util.inspect(op, options)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
error(msg, op = '') {
|
error(msg, op = '') {
|
||||||
console.error(
|
console.error(
|
||||||
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.red(msg),
|
'[' + this.getDateTime() + '] [' + this.appName + '] ' + colors.red(msg),
|
||||||
util.inspect(op, options),
|
util.inspect(op, options)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -225,7 +225,7 @@ module.exports = class Room {
|
|||||||
room,
|
room,
|
||||||
host = 'localhost',
|
host = 'localhost',
|
||||||
port = 1935,
|
port = 1935,
|
||||||
inputVideoURL = 'https://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4',
|
inputVideoURL = 'https://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4'
|
||||||
) {
|
) {
|
||||||
if (!this.rtmp || !this.rtmp.enabled) {
|
if (!this.rtmp || !this.rtmp.enabled) {
|
||||||
log.debug('[startRTMPfromURL] Server is not enabled or missing the config');
|
log.debug('[startRTMPfromURL] Server is not enabled or missing the config');
|
||||||
@@ -756,13 +756,13 @@ module.exports = class Room {
|
|||||||
error: error.message,
|
error: error.message,
|
||||||
});
|
});
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Failed to create producer for peer ${peer.peer_name} with transport ID ${producerTransportId}`,
|
`Failed to create producer for peer ${peer.peer_name} with transport ID ${producerTransportId}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!peerProducer) {
|
if (!peerProducer) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Failed to create producer for peer ${peer_name} with ID ${producerTransportId} for peer ${socket_id}`,
|
`Failed to create producer for peer ${peer_name} with ID ${producerTransportId} for peer ${socket_id}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -819,7 +819,7 @@ module.exports = class Room {
|
|||||||
|
|
||||||
if (!this.router.canConsume({ producerId, rtpCapabilities })) {
|
if (!this.router.canConsume({ producerId, rtpCapabilities })) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Cannot consume producer for peer ${peer_name} with ID ${producerId} type ${type}, router validation failed`,
|
`Cannot consume producer for peer ${peer_name} with ID ${producerId} type ${type}, router validation failed`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -834,13 +834,13 @@ module.exports = class Room {
|
|||||||
error: error.message,
|
error: error.message,
|
||||||
});
|
});
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Failed to create consumer for peer ${peer_name} with transport ID ${consumer_transport_id} and producer ID ${producerId} type ${type} for peer ${socket_id}`,
|
`Failed to create consumer for peer ${peer_name} with transport ID ${consumer_transport_id} and producer ID ${producerId} type ${type} for peer ${socket_id}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!peerConsumer) {
|
if (!peerConsumer) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Consumer creation failed for peer ${peer_name} with transport ID ${consumer_transport_id} and producer ID ${producerId}`,
|
`Consumer creation failed for peer ${peer_name} with transport ID ${consumer_transport_id} and producer ID ${producerId}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -64,7 +64,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.8.54
|
* @version 1.8.55
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -427,7 +427,7 @@ function startServer() {
|
|||||||
res.setHeader('Content-Type', 'application/javascript');
|
res.setHeader('Content-Type', 'application/javascript');
|
||||||
} //...
|
} //...
|
||||||
},
|
},
|
||||||
}),
|
})
|
||||||
);
|
);
|
||||||
app.use(cors(corsOptions));
|
app.use(cors(corsOptions));
|
||||||
app.use(compression());
|
app.use(compression());
|
||||||
@@ -752,7 +752,7 @@ function startServer() {
|
|||||||
// 2. Protect room access with configuration check
|
// 2. Protect room access with configuration check
|
||||||
if (!OIDC.enabled && hostCfg.protected && !hostCfg.users_from_db) {
|
if (!OIDC.enabled && hostCfg.protected && !hostCfg.users_from_db) {
|
||||||
const roomExists = hostCfg.users.some(
|
const roomExists = hostCfg.users.some(
|
||||||
(user) => user.allowed_rooms && (user.allowed_rooms.includes(roomId) || roomList.has(roomId)),
|
(user) => user.allowed_rooms && (user.allowed_rooms.includes(roomId) || roomList.has(roomId))
|
||||||
);
|
);
|
||||||
log.debug('/join/:roomId exists from config allowed rooms', roomExists);
|
log.debug('/join/:roomId exists from config allowed rooms', roomExists);
|
||||||
return roomExists ? htmlInjector.injectHtml(views.room, res) : res.redirect('/whoAreYou/' + roomId);
|
return roomExists ? htmlInjector.injectHtml(views.room, res) : res.redirect('/whoAreYou/' + roomId);
|
||||||
@@ -840,7 +840,7 @@ function startServer() {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const isPresenter = Boolean(
|
const isPresenter = Boolean(
|
||||||
hostCfg?.presenters?.join_first || hostCfg?.presenters?.list?.includes(username),
|
hostCfg?.presenters?.join_first || hostCfg?.presenters?.list?.includes(username)
|
||||||
);
|
);
|
||||||
|
|
||||||
const token = encodeToken({ username: username, password: password, presenter: isPresenter });
|
const token = encodeToken({ username: username, password: password, presenter: isPresenter });
|
||||||
@@ -1354,7 +1354,7 @@ function startServer() {
|
|||||||
|
|
||||||
if (restApi.allowed && !restApi.allowed.slack) {
|
if (restApi.allowed && !restApi.allowed.slack) {
|
||||||
return res.end(
|
return res.end(
|
||||||
'`This endpoint has been disabled`. Please contact the administrator for further information.',
|
'`This endpoint has been disabled`. Please contact the administrator for further information.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1514,7 +1514,7 @@ function startServer() {
|
|||||||
╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═══╝ ╚══════╝╚══════╝╚═╝ ╚═╝ ╚═══╝ ╚══════╝╚═╝ ╚═╝ started...
|
╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═══╝ ╚══════╝╚══════╝╚═╝ ╚═╝ ╚═══╝ ╚══════╝╚═╝ ╚═╝ started...
|
||||||
|
|
||||||
`,
|
`,
|
||||||
'font-family:monospace',
|
'font-family:monospace'
|
||||||
);
|
);
|
||||||
|
|
||||||
if (config?.integrations?.ngrok?.enabled && config?.integrations?.ngrok?.authToken !== '') {
|
if (config?.integrations?.ngrok?.enabled && config?.integrations?.ngrok?.authToken !== '') {
|
||||||
@@ -1799,7 +1799,7 @@ function startServer() {
|
|||||||
|
|
||||||
if (room.isLobbyEnabled() && !isPresenter) {
|
if (room.isLobbyEnabled() && !isPresenter) {
|
||||||
log.debug(
|
log.debug(
|
||||||
'The user is currently waiting to join the room because the lobby is enabled, and they are not a presenter',
|
'The user is currently waiting to join the room because the lobby is enabled, and they are not a presenter'
|
||||||
);
|
);
|
||||||
room.broadCast(socket.id, 'roomLobby', {
|
room.broadCast(socket.id, 'roomLobby', {
|
||||||
peer_id: peer_id,
|
peer_id: peer_id,
|
||||||
@@ -1965,7 +1965,7 @@ function startServer() {
|
|||||||
producerTransportId,
|
producerTransportId,
|
||||||
rtpParameters,
|
rtpParameters,
|
||||||
kind,
|
kind,
|
||||||
appData.mediaType,
|
appData.mediaType
|
||||||
);
|
);
|
||||||
|
|
||||||
log.debug('Produce', {
|
log.debug('Produce', {
|
||||||
@@ -2346,7 +2346,7 @@ function startServer() {
|
|||||||
socket.room_id,
|
socket.room_id,
|
||||||
socket.id,
|
socket.id,
|
||||||
data.from_peer_name,
|
data.from_peer_name,
|
||||||
data.from_peer_uuid,
|
data.from_peer_uuid
|
||||||
);
|
);
|
||||||
if (!isPresenter) return;
|
if (!isPresenter) return;
|
||||||
}
|
}
|
||||||
@@ -2692,7 +2692,7 @@ function startServer() {
|
|||||||
Authorization: `Bearer ${config?.integrations?.deepSeek?.apiKey}`,
|
Authorization: `Bearer ${config?.integrations?.deepSeek?.apiKey}`,
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
// Extract the assistant's response
|
// Extract the assistant's response
|
||||||
@@ -2801,7 +2801,7 @@ function startServer() {
|
|||||||
'content-type': 'application/json',
|
'content-type': 'application/json',
|
||||||
'x-api-key': config?.integrations?.videoAI?.apiKey,
|
'x-api-key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data };
|
const data = { response: response.data };
|
||||||
@@ -2831,7 +2831,7 @@ function startServer() {
|
|||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data.data };
|
const data = { response: response.data.data };
|
||||||
@@ -2861,7 +2861,7 @@ function startServer() {
|
|||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data };
|
const data = { response: response.data };
|
||||||
@@ -2894,7 +2894,7 @@ function startServer() {
|
|||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data };
|
const data = { response: response.data };
|
||||||
@@ -2926,7 +2926,7 @@ function startServer() {
|
|||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data };
|
const data = { response: response.data };
|
||||||
@@ -2986,7 +2986,7 @@ function startServer() {
|
|||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
'X-Api-Key': config?.integrations?.videoAI?.apiKey,
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
const data = { response: response.data };
|
const data = { response: response.data };
|
||||||
@@ -3538,7 +3538,7 @@ function startServer() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
return response.data && response.data.message === true;
|
return response.data && response.data.message === true;
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -3669,7 +3669,7 @@ function startServer() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
log.debug('AXIOS roomExistsForUser', { room: room, exists: true });
|
log.debug('AXIOS roomExistsForUser', { room: room, exists: true });
|
||||||
return response.data && response.data.message === true;
|
return response.data && response.data.message === true;
|
||||||
@@ -3696,7 +3696,7 @@ function startServer() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
timeout: 5000, // Timeout set to 5 seconds (5000 milliseconds)
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
const allowedRooms = response.data ? response.data.message : {};
|
const allowedRooms = response.data ? response.data.message : {};
|
||||||
log.debug('AXIOS getUserAllowedRooms', allowedRooms);
|
log.debug('AXIOS getUserAllowedRooms', allowedRooms);
|
||||||
@@ -3749,7 +3749,7 @@ function startServer() {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
timeout: hostCfg.users_api_timeout || 5000,
|
timeout: hostCfg.users_api_timeout || 5000,
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
if (response.data && (response.data === true || response.data.message === true)) {
|
if (response.data && (response.data === true || response.data.message === true)) {
|
||||||
@@ -3791,7 +3791,7 @@ function startServer() {
|
|||||||
|
|
||||||
log.debug(
|
log.debug(
|
||||||
isAllowed ? 'isRoomAllowedForUser - Room allowed' : 'isRoomAllowedForUser - Room not allowed',
|
isAllowed ? 'isRoomAllowedForUser - Room allowed' : 'isRoomAllowedForUser - Room not allowed',
|
||||||
{ room, username },
|
{ room, username }
|
||||||
);
|
);
|
||||||
return isAllowed;
|
return isAllowed;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ module.exports = class ServerApi {
|
|||||||
hand: peer_hand,
|
hand: peer_hand,
|
||||||
os: os_name ? `${os_name} ${os_version}` : '',
|
os: os_name ? `${os_name} ${os_version}` : '',
|
||||||
browser: browser_name ? `${browser_name} ${browser_version}` : '',
|
browser: browser_name ? `${browser_name} ${browser_version}` : '',
|
||||||
}),
|
})
|
||||||
);
|
);
|
||||||
return {
|
return {
|
||||||
roomId: id,
|
roomId: id,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "mirotalksfu",
|
"name": "mirotalksfu",
|
||||||
"version": "1.8.54",
|
"version": "1.8.55",
|
||||||
"description": "WebRTC SFU browser-based video calls",
|
"description": "WebRTC SFU browser-based video calls",
|
||||||
"main": "Server.js",
|
"main": "Server.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ let BRAND = {
|
|||||||
},
|
},
|
||||||
about: {
|
about: {
|
||||||
imageUrl: '../images/mirotalk-logo.gif',
|
imageUrl: '../images/mirotalk-logo.gif',
|
||||||
title: '<strong>WebRTC SFU v1.8.54</strong>',
|
title: '<strong>WebRTC SFU v1.8.55</strong>',
|
||||||
html: `
|
html: `
|
||||||
<button
|
<button
|
||||||
id="support-button"
|
id="support-button"
|
||||||
|
|||||||
@@ -218,7 +218,7 @@ function genRoom() {
|
|||||||
|
|
||||||
function getUUID4() {
|
function getUUID4() {
|
||||||
return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
||||||
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16),
|
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -251,7 +251,7 @@ function isValidRoomName(input) {
|
|||||||
function adultContent() {
|
function adultContent() {
|
||||||
if (
|
if (
|
||||||
confirm(
|
confirm(
|
||||||
'18+ WARNING! ADULTS ONLY!\n\nExplicit material for viewing by adults 18 years of age or older. You must be at least 18 years old to access to this site!\n\nProceeding you are agree and confirm to have 18+ year.',
|
'18+ WARNING! ADULTS ONLY!\n\nExplicit material for viewing by adults 18 years of age or older. You must be at least 18 years old to access to this site!\n\nProceeding you are agree and confirm to have 18+ year.'
|
||||||
)
|
)
|
||||||
) {
|
) {
|
||||||
window.open('https://luvlounge.ca', '_blank');
|
window.open('https://luvlounge.ca', '_blank');
|
||||||
|
|||||||
@@ -147,14 +147,14 @@
|
|||||||
function (t) {
|
function (t) {
|
||||||
e.touchStartX = t.changedTouches[0].screenX;
|
e.touchStartX = t.changedTouches[0].screenX;
|
||||||
},
|
},
|
||||||
!1,
|
!1
|
||||||
),
|
),
|
||||||
t.addEventListener(
|
t.addEventListener(
|
||||||
'touchend',
|
'touchend',
|
||||||
function (t) {
|
function (t) {
|
||||||
(e.touchEndX = t.changedTouches[0].screenX), e.handleSwipeGesture();
|
(e.touchEndX = t.changedTouches[0].screenX), e.handleSwipeGesture();
|
||||||
},
|
},
|
||||||
!1,
|
!1
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
handleSwipeGesture: function () {
|
handleSwipeGesture: function () {
|
||||||
|
|||||||
@@ -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.8.54
|
* @version 1.8.55
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -316,26 +316,26 @@ function initClient() {
|
|||||||
setTippy(
|
setTippy(
|
||||||
'switchPushToTalk',
|
'switchPushToTalk',
|
||||||
'If Active, When SpaceBar keydown the microphone will be resumed, on keyup will be paused, like a walkie-talkie.',
|
'If Active, When SpaceBar keydown the microphone will be resumed, on keyup will be paused, like a walkie-talkie.',
|
||||||
'right',
|
'right'
|
||||||
);
|
);
|
||||||
setTippy('lobbyAcceptAllBtn', 'Accept', 'top');
|
setTippy('lobbyAcceptAllBtn', 'Accept', 'top');
|
||||||
setTippy('lobbyRejectAllBtn', 'Reject', 'top');
|
setTippy('lobbyRejectAllBtn', 'Reject', 'top');
|
||||||
setTippy(
|
setTippy(
|
||||||
'switchBroadcasting',
|
'switchBroadcasting',
|
||||||
'Broadcasting is the dissemination of audio or video content to a large audience (one to many)',
|
'Broadcasting is the dissemination of audio or video content to a large audience (one to many)',
|
||||||
'right',
|
'right'
|
||||||
);
|
);
|
||||||
setTippy(
|
setTippy(
|
||||||
'switchLobby',
|
'switchLobby',
|
||||||
'Lobby mode lets you protect your meeting by only allowing people to enter after a formal approval by a moderator',
|
'Lobby mode lets you protect your meeting by only allowing people to enter after a formal approval by a moderator',
|
||||||
'right',
|
'right'
|
||||||
);
|
);
|
||||||
setTippy('initVideoAudioRefreshButton', 'Refresh audio/video devices', 'top');
|
setTippy('initVideoAudioRefreshButton', 'Refresh audio/video devices', 'top');
|
||||||
setTippy(
|
setTippy(
|
||||||
'screenOptimizationLabel',
|
'screenOptimizationLabel',
|
||||||
'Detail: For high fidelity (screen sharing with text/graphics)<br />Motion: For high frame rate (video playback, game streaming',
|
'Detail: For high fidelity (screen sharing with text/graphics)<br />Motion: For high frame rate (video playback, game streaming',
|
||||||
'right',
|
'right',
|
||||||
true,
|
true
|
||||||
);
|
);
|
||||||
setTippy('switchPitchBar', 'Toggle audio pitch bar', 'right');
|
setTippy('switchPitchBar', 'Toggle audio pitch bar', 'right');
|
||||||
setTippy('switchSounds', 'Toggle the sounds notifications', 'right');
|
setTippy('switchSounds', 'Toggle the sounds notifications', 'right');
|
||||||
@@ -347,12 +347,12 @@ function initClient() {
|
|||||||
setTippy(
|
setTippy(
|
||||||
'switchHostOnlyRecording',
|
'switchHostOnlyRecording',
|
||||||
'Only the host (presenter) has the capability to record the meeting',
|
'Only the host (presenter) has the capability to record the meeting',
|
||||||
'right',
|
'right'
|
||||||
);
|
);
|
||||||
setTippy(
|
setTippy(
|
||||||
'switchH264Recording',
|
'switchH264Recording',
|
||||||
'Prioritize h.264 with AAC or h.264 with Opus codecs over VP8 with Opus or VP9 with Opus codecs',
|
'Prioritize h.264 with AAC or h.264 with Opus codecs over VP8 with Opus or VP9 with Opus codecs',
|
||||||
'right',
|
'right'
|
||||||
);
|
);
|
||||||
setTippy('refreshVideoFiles', 'Refresh', 'left');
|
setTippy('refreshVideoFiles', 'Refresh', 'left');
|
||||||
setTippy('switchServerRecording', 'The recording will be stored on the server rather than locally', 'right');
|
setTippy('switchServerRecording', 'The recording will be stored on the server rather than locally', 'right');
|
||||||
@@ -603,7 +603,7 @@ async function enumerateVideoDevices(stream) {
|
|||||||
}
|
}
|
||||||
if (!el) return;
|
if (!el) return;
|
||||||
await addChild(device, [el, eli]);
|
await addChild(device, [el, eli]);
|
||||||
}),
|
})
|
||||||
)
|
)
|
||||||
.then(async () => {
|
.then(async () => {
|
||||||
await stopTracks(stream);
|
await stopTracks(stream);
|
||||||
@@ -651,7 +651,7 @@ async function enumerateAudioDevices(stream) {
|
|||||||
}
|
}
|
||||||
if (!el) return;
|
if (!el) return;
|
||||||
await addChild(device, [el, eli]);
|
await addChild(device, [el, eli]);
|
||||||
}),
|
})
|
||||||
)
|
)
|
||||||
.then(async () => {
|
.then(async () => {
|
||||||
await stopTracks(stream);
|
await stopTracks(stream);
|
||||||
@@ -1476,7 +1476,7 @@ function joinRoom(peer_name, room_id) {
|
|||||||
joinRoomWithScreen,
|
joinRoomWithScreen,
|
||||||
isSpeechSynthesisSupported,
|
isSpeechSynthesisSupported,
|
||||||
transcription,
|
transcription,
|
||||||
roomIsReady,
|
roomIsReady
|
||||||
);
|
);
|
||||||
handleRoomClientEvents();
|
handleRoomClientEvents();
|
||||||
//notify ? shareRoom() : sound('joined');
|
//notify ? shareRoom() : sound('joined');
|
||||||
@@ -2359,7 +2359,7 @@ async function changeCamera(deviceId) {
|
|||||||
initStream = camStream;
|
initStream = camStream;
|
||||||
console.log(
|
console.log(
|
||||||
'04.5 ----> Success attached init cam video stream',
|
'04.5 ----> Success attached init cam video stream',
|
||||||
initStream.getVideoTracks()[0].getSettings(),
|
initStream.getVideoTracks()[0].getSettings()
|
||||||
);
|
);
|
||||||
checkInitConfig();
|
checkInitConfig();
|
||||||
camera = detectCameraFacingMode(camStream);
|
camera = detectCameraFacingMode(camStream);
|
||||||
@@ -2442,7 +2442,7 @@ function handleMediaError(mediaType, err, redirectURL = false) {
|
|||||||
popupHtmlMessage(null, image.forbidden, 'Access denied', html, 'center', redirectURL);
|
popupHtmlMessage(null, image.forbidden, 'Access denied', html, 'center', redirectURL);
|
||||||
|
|
||||||
throw new Error(
|
throw new Error(
|
||||||
`Access denied for ${mediaType} device [${err.name}]: ${errMessage} check the common getUserMedia errors: https://blog.addpipe.com/common-getusermedia-errors/`,
|
`Access denied for ${mediaType} device [${err.name}]: ${errMessage} check the common getUserMedia errors: https://blog.addpipe.com/common-getusermedia-errors/`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3014,7 +3014,7 @@ function handleKeyboardShortcuts() {
|
|||||||
userLog(
|
userLog(
|
||||||
'warning',
|
'warning',
|
||||||
'The presenter has disabled your ability to open the document PIP',
|
'The presenter has disabled your ability to open the document PIP',
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -3114,7 +3114,7 @@ function handleInputs() {
|
|||||||
Object.keys(chatInputEmoji)
|
Object.keys(chatInputEmoji)
|
||||||
.map((key) => key.replace(/([()[{*+.$^\\|?])/g, '\\$1'))
|
.map((key) => key.replace(/([()[{*+.$^\\|?])/g, '\\$1'))
|
||||||
.join('|'),
|
.join('|'),
|
||||||
'gim',
|
'gim'
|
||||||
);
|
);
|
||||||
// Replace matching patterns with corresponding emojis
|
// Replace matching patterns with corresponding emojis
|
||||||
this.value = this.value.replace(regexPattern, (match) => chatInputEmoji[match]);
|
this.value = this.value.replace(regexPattern, (match) => chatInputEmoji[match]);
|
||||||
@@ -3645,7 +3645,7 @@ function getDataTimeStringFormat() {
|
|||||||
|
|
||||||
function getUUID() {
|
function getUUID() {
|
||||||
const uuid4 = ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
const uuid4 = ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
||||||
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16),
|
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16)
|
||||||
);
|
);
|
||||||
if (window.localStorage.uuid) {
|
if (window.localStorage.uuid) {
|
||||||
return window.localStorage.uuid;
|
return window.localStorage.uuid;
|
||||||
@@ -3772,7 +3772,7 @@ function isMobile(userAgent) {
|
|||||||
|
|
||||||
function isTablet(userAgent) {
|
function isTablet(userAgent) {
|
||||||
return /(ipad|tablet|(android(?!.*mobile))|(windows(?!.*phone)(.*touch))|kindle|playbook|silk|(puffin(?!.*(IP|AP|WP))))/.test(
|
return /(ipad|tablet|(android(?!.*mobile))|(windows(?!.*phone)(.*touch))|kindle|playbook|silk|(puffin(?!.*(IP|AP|WP))))/.test(
|
||||||
userAgent,
|
userAgent
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4173,7 +4173,7 @@ async function loadPDF(pdfData, pages) {
|
|||||||
await page.render(renderContext).promise;
|
await page.render(renderContext).promise;
|
||||||
return canvas;
|
return canvas;
|
||||||
});
|
});
|
||||||
}),
|
})
|
||||||
);
|
);
|
||||||
return canvases.filter((canvas) => canvas !== null);
|
return canvases.filter((canvas) => canvas !== null);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -4191,7 +4191,7 @@ async function pdfToImage(pdfData, canvas) {
|
|||||||
new fabric.Image(await c, {
|
new fabric.Image(await c, {
|
||||||
scaleX: scale,
|
scaleX: scale,
|
||||||
scaleY: scale,
|
scaleY: scale,
|
||||||
}),
|
})
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -4368,7 +4368,7 @@ function whiteboardAction(data, emit = true) {
|
|||||||
userLog(
|
userLog(
|
||||||
'info',
|
'info',
|
||||||
`${data.peer_name} <i class="fas fa-chalkboard-teacher"></i> whiteboard action: ${data.action}`,
|
`${data.peer_name} <i class="fas fa-chalkboard-teacher"></i> whiteboard action: ${data.action}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -5085,7 +5085,7 @@ function showImageSelector() {
|
|||||||
|
|
||||||
// Create clean virtual bg Image
|
// Create clean virtual bg Image
|
||||||
createImage('initCleanVbImg', image.user, 'Remove virtual background', 'cleanVb', () =>
|
createImage('initCleanVbImg', image.user, 'Remove virtual background', 'cleanVb', () =>
|
||||||
handleVirtualBackground(null, null),
|
handleVirtualBackground(null, null)
|
||||||
);
|
);
|
||||||
// Create High Blur Image
|
// Create High Blur Image
|
||||||
createImage('initHighBlurImg', image.blurHigh, 'High Blur', 'high', () => handleVirtualBackground(20));
|
createImage('initHighBlurImg', image.blurHigh, 'High Blur', 'high', () => handleVirtualBackground(20));
|
||||||
@@ -5094,7 +5094,7 @@ function showImageSelector() {
|
|||||||
|
|
||||||
// Create transparent virtual bg Image
|
// Create transparent virtual bg Image
|
||||||
createImage('initTransparentBg', image.transparentBg, 'Transparent Virtual background', 'transparentVb', () =>
|
createImage('initTransparentBg', image.transparentBg, 'Transparent Virtual background', 'transparentVb', () =>
|
||||||
handleVirtualBackground(null, null, true),
|
handleVirtualBackground(null, null, true)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Handle file upload (common logic for file selection)
|
// Handle file upload (common logic for file selection)
|
||||||
@@ -5250,7 +5250,7 @@ async function applyVirtualBackground(videoElement, stream, blurLevel, backgroun
|
|||||||
} else if (backgroundImage) {
|
} else if (backgroundImage) {
|
||||||
videoElement.srcObject = await virtualBackground.applyVirtualBackgroundToWebRTCStream(
|
videoElement.srcObject = await virtualBackground.applyVirtualBackgroundToWebRTCStream(
|
||||||
videoTrack,
|
videoTrack,
|
||||||
backgroundImage,
|
backgroundImage
|
||||||
);
|
);
|
||||||
virtualBackgroundSelectedImage = backgroundImage;
|
virtualBackgroundSelectedImage = backgroundImage;
|
||||||
virtualBackgroundBlurLevel = null;
|
virtualBackgroundBlurLevel = null;
|
||||||
@@ -5450,7 +5450,7 @@ function showAbout() {
|
|||||||
position: 'center',
|
position: 'center',
|
||||||
imageUrl: BRAND.about?.imageUrl && BRAND.about.imageUrl.trim() !== '' ? BRAND.about.imageUrl : image.about,
|
imageUrl: BRAND.about?.imageUrl && BRAND.about.imageUrl.trim() !== '' ? BRAND.about.imageUrl : image.about,
|
||||||
customClass: { image: 'img-about' },
|
customClass: { image: 'img-about' },
|
||||||
title: BRAND.about?.title && BRAND.about.title.trim() !== '' ? BRAND.about.title : 'WebRTC SFU v1.8.54',
|
title: BRAND.about?.title && BRAND.about.title.trim() !== '' ? BRAND.about.title : 'WebRTC SFU v1.8.55',
|
||||||
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.8.54
|
* @version 1.8.55
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
@@ -223,7 +223,7 @@ class RoomClient {
|
|||||||
joinRoomWithScreen,
|
joinRoomWithScreen,
|
||||||
isSpeechSynthesisSupported,
|
isSpeechSynthesisSupported,
|
||||||
transcription,
|
transcription,
|
||||||
successCallback,
|
successCallback
|
||||||
) {
|
) {
|
||||||
this.localAudioEl = localAudioEl;
|
this.localAudioEl = localAudioEl;
|
||||||
this.remoteAudioEl = remoteAudioEl;
|
this.remoteAudioEl = remoteAudioEl;
|
||||||
@@ -475,14 +475,14 @@ class RoomClient {
|
|||||||
|
|
||||||
if (room === 'notAllowed') {
|
if (room === 'notAllowed') {
|
||||||
console.warn(
|
console.warn(
|
||||||
'00-WARNING ----> Room is Unauthorized for current user, please provide a valid room name for this user',
|
'00-WARNING ----> Room is Unauthorized for current user, please provide a valid room name for this user'
|
||||||
);
|
);
|
||||||
return this.userRoomNotAllowed();
|
return this.userRoomNotAllowed();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (room === 'unauthorized') {
|
if (room === 'unauthorized') {
|
||||||
console.warn(
|
console.warn(
|
||||||
'00-WARNING ----> Room is Unauthorized for current user, please provide a valid username and password',
|
'00-WARNING ----> Room is Unauthorized for current user, please provide a valid username and password'
|
||||||
);
|
);
|
||||||
return this.userUnauthorized();
|
return this.userUnauthorized();
|
||||||
}
|
}
|
||||||
@@ -559,7 +559,7 @@ class RoomClient {
|
|||||||
// Get Router Capabilities
|
// Get Router Capabilities
|
||||||
const routerRtpCapabilities = await this.socket.request('getRouterRtpCapabilities');
|
const routerRtpCapabilities = await this.socket.request('getRouterRtpCapabilities');
|
||||||
routerRtpCapabilities.headerExtensions = routerRtpCapabilities.headerExtensions.filter(
|
routerRtpCapabilities.headerExtensions = routerRtpCapabilities.headerExtensions.filter(
|
||||||
(ext) => ext.uri !== 'urn:3gpp:video-orientation',
|
(ext) => ext.uri !== 'urn:3gpp:video-orientation'
|
||||||
);
|
);
|
||||||
|
|
||||||
// Load device
|
// Load device
|
||||||
@@ -753,7 +753,7 @@ class RoomClient {
|
|||||||
});
|
});
|
||||||
console.log(
|
console.log(
|
||||||
`Device loaded successfully with router RTP capabilities (preferLocalCodecsOrder: ${!!this.preferLocalCodecsOrder})`,
|
`Device loaded successfully with router RTP capabilities (preferLocalCodecsOrder: ${!!this.preferLocalCodecsOrder})`,
|
||||||
device.rtpCapabilities,
|
device.rtpCapabilities
|
||||||
);
|
);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Error loading device with router RTP capabilities:', error);
|
console.error('Error loading device with router RTP capabilities:', error);
|
||||||
@@ -1015,7 +1015,7 @@ class RoomClient {
|
|||||||
'Unable to reconnect. Please check your network.',
|
'Unable to reconnect. Please check your network.',
|
||||||
'center',
|
'center',
|
||||||
false,
|
false,
|
||||||
true,
|
true
|
||||||
);
|
);
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
@@ -1675,13 +1675,13 @@ class RoomClient {
|
|||||||
// Apply blur before sending it to WebRTC stream
|
// Apply blur before sending it to WebRTC stream
|
||||||
stream = await virtualBackground.applyBlurToWebRTCStream(
|
stream = await virtualBackground.applyBlurToWebRTCStream(
|
||||||
videoTrack,
|
videoTrack,
|
||||||
virtualBackgroundBlurLevel,
|
virtualBackgroundBlurLevel
|
||||||
);
|
);
|
||||||
} else if (virtualBackgroundSelectedImage) {
|
} else if (virtualBackgroundSelectedImage) {
|
||||||
// Apply virtual background to WebRTC stream
|
// Apply virtual background to WebRTC stream
|
||||||
stream = await virtualBackground.applyVirtualBackgroundToWebRTCStream(
|
stream = await virtualBackground.applyVirtualBackgroundToWebRTCStream(
|
||||||
videoTrack,
|
videoTrack,
|
||||||
virtualBackgroundSelectedImage,
|
virtualBackgroundSelectedImage
|
||||||
);
|
);
|
||||||
} else if (virtualBackgroundTransparent) {
|
} else if (virtualBackgroundTransparent) {
|
||||||
// Apply Transparent virtual background to WebRTC stream
|
// Apply Transparent virtual background to WebRTC stream
|
||||||
@@ -1855,7 +1855,7 @@ class RoomClient {
|
|||||||
this.userLog(
|
this.userLog(
|
||||||
'error',
|
'error',
|
||||||
`Your device doesn't support the selected video quality (${videoQuality.value}), please select the another one.`,
|
`Your device doesn't support the selected video quality (${videoQuality.value}), please select the another one.`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1896,7 +1896,7 @@ class RoomClient {
|
|||||||
|
|
||||||
// Create clean virtual bg Image
|
// Create clean virtual bg Image
|
||||||
createImage('cleanVbImg', image.user, 'Remove virtual background', 'cleanVb', () =>
|
createImage('cleanVbImg', image.user, 'Remove virtual background', 'cleanVb', () =>
|
||||||
handleVirtualBackground(null, null),
|
handleVirtualBackground(null, null)
|
||||||
);
|
);
|
||||||
// Create High Blur Image
|
// Create High Blur Image
|
||||||
createImage('highBlurImg', image.blurHigh, 'High Blur', 'high', () => handleVirtualBackground(20));
|
createImage('highBlurImg', image.blurHigh, 'High Blur', 'high', () => handleVirtualBackground(20));
|
||||||
@@ -1905,7 +1905,7 @@ class RoomClient {
|
|||||||
|
|
||||||
// Create transparent virtual bg Image
|
// Create transparent virtual bg Image
|
||||||
createImage('transparentBg', image.transparentBg, 'Transparent Virtual background', 'transparentVb', () =>
|
createImage('transparentBg', image.transparentBg, 'Transparent Virtual background', 'transparentVb', () =>
|
||||||
handleVirtualBackground(null, null, true),
|
handleVirtualBackground(null, null, true)
|
||||||
);
|
);
|
||||||
|
|
||||||
// Handle file upload (common logic for file selection)
|
// Handle file upload (common logic for file selection)
|
||||||
@@ -2457,7 +2457,7 @@ class RoomClient {
|
|||||||
vp = this.createButton(this.peer_id + '__vp', html.videoPrivacy);
|
vp = this.createButton(this.peer_id + '__vp', html.videoPrivacy);
|
||||||
au = this.createButton(
|
au = this.createButton(
|
||||||
this.peer_id + '__audio',
|
this.peer_id + '__audio',
|
||||||
this.peer_info.peer_audio ? html.audioOn : html.audioOff,
|
this.peer_info.peer_audio ? html.audioOn : html.audioOff
|
||||||
);
|
);
|
||||||
au.style.cursor = 'default';
|
au.style.cursor = 'default';
|
||||||
|
|
||||||
@@ -2523,7 +2523,7 @@ class RoomClient {
|
|||||||
this.setAV(
|
this.setAV(
|
||||||
this.audioConsumers.get(this.peer_id + '___pVolume'),
|
this.audioConsumers.get(this.peer_id + '___pVolume'),
|
||||||
this.peer_id + '___pVolume',
|
this.peer_id + '___pVolume',
|
||||||
this.peer_info.peer_audio_volume,
|
this.peer_info.peer_audio_volume
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!isScreen) this.handleVP(elem.id, vp.id);
|
if (!isScreen) this.handleVP(elem.id, vp.id);
|
||||||
@@ -3065,7 +3065,7 @@ class RoomClient {
|
|||||||
this.audioConsumers.get(remotePeerId + '___pVolume'),
|
this.audioConsumers.get(remotePeerId + '___pVolume'),
|
||||||
remotePeerId + '___pVolume',
|
remotePeerId + '___pVolume',
|
||||||
remotePeerAudioVolume,
|
remotePeerAudioVolume,
|
||||||
true,
|
true
|
||||||
);
|
);
|
||||||
|
|
||||||
this.setPeerAudio(remotePeerId, remotePeerAudio);
|
this.setPeerAudio(remotePeerId, remotePeerAudio);
|
||||||
@@ -3149,7 +3149,7 @@ class RoomClient {
|
|||||||
handleAspectRatio();
|
handleAspectRatio();
|
||||||
console.log(
|
console.log(
|
||||||
'[removeConsumer - ' + consumer_kind + '] Video-element-count',
|
'[removeConsumer - ' + consumer_kind + '] Video-element-count',
|
||||||
this.videoMediaContainer.childElementCount,
|
this.videoMediaContainer.childElementCount
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4800,7 +4800,7 @@ class RoomClient {
|
|||||||
return this.userLog(
|
return this.userLog(
|
||||||
'warning',
|
'warning',
|
||||||
`The message seems too long, with a maximum of ${this.chatMessageLength} characters allowed`,
|
`The message seems too long, with a maximum of ${this.chatMessageLength} characters allowed`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4824,7 +4824,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
`Kindly refrain from spamming. Please wait ${this.chatMessageNotifyDelay / 1000} seconds before sending another message`,
|
`Kindly refrain from spamming. Please wait ${this.chatMessageNotifyDelay / 1000} seconds before sending another message`,
|
||||||
'top-end',
|
'top-end',
|
||||||
this.chatMessageNotifyDelay,
|
this.chatMessageNotifyDelay
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
this.chatMessageTimeLast = currentTime;
|
this.chatMessageTimeLast = currentTime;
|
||||||
@@ -4859,7 +4859,7 @@ class RoomClient {
|
|||||||
this.peer_id,
|
this.peer_id,
|
||||||
peer_msg,
|
peer_msg,
|
||||||
data.to_peer_id,
|
data.to_peer_id,
|
||||||
data.to_peer_name,
|
data.to_peer_name
|
||||||
);
|
);
|
||||||
this.cleanMessage();
|
this.cleanMessage();
|
||||||
|
|
||||||
@@ -4902,7 +4902,7 @@ class RoomClient {
|
|||||||
this.peer_id,
|
this.peer_id,
|
||||||
peer_msg,
|
peer_msg,
|
||||||
data.to_peer_id,
|
data.to_peer_id,
|
||||||
data.to_peer_name,
|
data.to_peer_name
|
||||||
);
|
);
|
||||||
this.cleanMessage();
|
this.cleanMessage();
|
||||||
|
|
||||||
@@ -4927,7 +4927,7 @@ class RoomClient {
|
|||||||
this.peer_id,
|
this.peer_id,
|
||||||
message,
|
message,
|
||||||
'DeepSeek',
|
'DeepSeek',
|
||||||
'DeepSeek',
|
'DeepSeek'
|
||||||
);
|
);
|
||||||
this.cleanMessage();
|
this.cleanMessage();
|
||||||
this.streamingTask(message);
|
this.streamingTask(message);
|
||||||
@@ -4958,7 +4958,7 @@ class RoomClient {
|
|||||||
this.peer_id,
|
this.peer_id,
|
||||||
peer_msg,
|
peer_msg,
|
||||||
data.to_peer_id,
|
data.to_peer_id,
|
||||||
data.to_peer_name,
|
data.to_peer_name
|
||||||
);
|
);
|
||||||
this.cleanMessage();
|
this.cleanMessage();
|
||||||
}
|
}
|
||||||
@@ -5009,7 +5009,7 @@ class RoomClient {
|
|||||||
this.peer_id,
|
this.peer_id,
|
||||||
peer_msg,
|
peer_msg,
|
||||||
to_peer_id,
|
to_peer_id,
|
||||||
toPeerName,
|
toPeerName
|
||||||
);
|
);
|
||||||
if (!this.isChatOpen) this.toggleChat();
|
if (!this.isChatOpen) this.toggleChat();
|
||||||
}
|
}
|
||||||
@@ -5029,7 +5029,7 @@ class RoomClient {
|
|||||||
data.peer_id,
|
data.peer_id,
|
||||||
data.peer_msg,
|
data.peer_msg,
|
||||||
data.to_peer_id,
|
data.to_peer_id,
|
||||||
data.to_peer_name,
|
data.to_peer_name
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!this.showChatOnMessage) {
|
if (!this.showChatOnMessage) {
|
||||||
@@ -5313,7 +5313,7 @@ class RoomClient {
|
|||||||
try {
|
try {
|
||||||
const url = new URL(input);
|
const url = new URL(input);
|
||||||
return ['.jpg', '.jpeg', '.png', '.gif', '.webp', '.bmp', '.tiff', '.svg'].some((ext) =>
|
return ['.jpg', '.jpeg', '.png', '.gif', '.webp', '.bmp', '.tiff', '.svg'].some((ext) =>
|
||||||
url.pathname.toLowerCase().endsWith(ext),
|
url.pathname.toLowerCase().endsWith(ext)
|
||||||
);
|
);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
return false;
|
return false;
|
||||||
@@ -5367,7 +5367,7 @@ class RoomClient {
|
|||||||
iframe.setAttribute('frameborder', '0');
|
iframe.setAttribute('frameborder', '0');
|
||||||
iframe.setAttribute(
|
iframe.setAttribute(
|
||||||
'allow',
|
'allow',
|
||||||
'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture',
|
'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture'
|
||||||
);
|
);
|
||||||
iframe.setAttribute('allowfullscreen', 'allowfullscreen');
|
iframe.setAttribute('allowfullscreen', 'allowfullscreen');
|
||||||
div.appendChild(iframe);
|
div.appendChild(iframe);
|
||||||
@@ -6122,7 +6122,7 @@ class RoomClient {
|
|||||||
audioStreams
|
audioStreams
|
||||||
.getTracks()
|
.getTracks()
|
||||||
.filter((track) => track.kind === 'audio')
|
.filter((track) => track.kind === 'audio')
|
||||||
.map((track) => new MediaStream([track])),
|
.map((track) => new MediaStream([track]))
|
||||||
);
|
);
|
||||||
|
|
||||||
const audioMixerTracks = audioMixerStreams.getTracks();
|
const audioMixerTracks = audioMixerStreams.getTracks();
|
||||||
@@ -6288,7 +6288,7 @@ class RoomClient {
|
|||||||
|
|
||||||
generateUUIDv4() {
|
generateUUIDv4() {
|
||||||
return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
return ([1e7] + -1e3 + -4e3 + -8e3 + -1e11).replace(/[018]/g, (c) =>
|
||||||
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16),
|
(c ^ (crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> (c / 4)))).toString(16)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -6328,7 +6328,7 @@ class RoomClient {
|
|||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/octet-stream',
|
'Content-Type': 'application/octet-stream',
|
||||||
},
|
},
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
console.log('Chunk synced successfully:', response.data);
|
console.log('Chunk synced successfully:', response.data);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -6363,7 +6363,7 @@ class RoomClient {
|
|||||||
if (rc.recording.recSyncServerRecording && rc.recording.recSyncServerToS3) {
|
if (rc.recording.recSyncServerRecording && rc.recording.recSyncServerToS3) {
|
||||||
try {
|
try {
|
||||||
const response = await axios.post(
|
const response = await axios.post(
|
||||||
`${rc.recording.recSyncServerEndpoint}/recSyncFinalize?fileName=` + rc.recServerFileName,
|
`${rc.recording.recSyncServerEndpoint}/recSyncFinalize?fileName=` + rc.recServerFileName
|
||||||
);
|
);
|
||||||
console.log('Finalized and uploaded to S3:', response.data);
|
console.log('Finalized and uploaded to S3:', response.data);
|
||||||
userLog('success', 'Recording successfully uploaded to S3.', 'top-end', 3000);
|
userLog('success', 'Recording successfully uploaded to S3.', 'top-end', 3000);
|
||||||
@@ -6567,7 +6567,7 @@ class RoomClient {
|
|||||||
`${icons.user} ${peer_name}
|
`${icons.user} ${peer_name}
|
||||||
<br /><br />
|
<br /><br />
|
||||||
<span>🔴 ${action}</span>
|
<span>🔴 ${action}</span>
|
||||||
<br />`,
|
<br />`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -6747,7 +6747,7 @@ class RoomClient {
|
|||||||
<li>Size: ${this.bytesToSize(this.fileToSend.size)}</li>
|
<li>Size: ${this.bytesToSize(this.fileToSend.size)}</li>
|
||||||
</ul>`,
|
</ul>`,
|
||||||
'all',
|
'all',
|
||||||
'all',
|
'all'
|
||||||
);
|
);
|
||||||
// send some metadata about our file to peers in the room
|
// send some metadata about our file to peers in the room
|
||||||
this.socket.emit('fileInfo', fileInfo);
|
this.socket.emit('fileInfo', fileInfo);
|
||||||
@@ -6791,7 +6791,7 @@ class RoomClient {
|
|||||||
<li>Size: ${this.bytesToSize(this.incomingFileInfo.fileSize)}</li>
|
<li>Size: ${this.bytesToSize(this.incomingFileInfo.fileSize)}</li>
|
||||||
</ul>`,
|
</ul>`,
|
||||||
'all',
|
'all',
|
||||||
'all',
|
'all'
|
||||||
);
|
);
|
||||||
receiveFileInfo.innerText = fileToReceiveInfo;
|
receiveFileInfo.innerText = fileToReceiveInfo;
|
||||||
receiveFileDiv.style.display = 'inline';
|
receiveFileDiv.style.display = 'inline';
|
||||||
@@ -7157,7 +7157,7 @@ class RoomClient {
|
|||||||
video.setAttribute('title', peer_name);
|
video.setAttribute('title', peer_name);
|
||||||
video.setAttribute(
|
video.setAttribute(
|
||||||
'allow',
|
'allow',
|
||||||
'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture',
|
'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture'
|
||||||
);
|
);
|
||||||
video.setAttribute('frameborder', '0');
|
video.setAttribute('frameborder', '0');
|
||||||
video.setAttribute('allowfullscreen', true);
|
video.setAttribute('allowfullscreen', true);
|
||||||
@@ -7477,7 +7477,7 @@ class RoomClient {
|
|||||||
: this.userLog(
|
: this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.chat} Chat not will be shown, when you receive a message`,
|
`${icons.chat} Chat not will be shown, when you receive a message`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'speechMessages':
|
case 'speechMessages':
|
||||||
@@ -7488,19 +7488,19 @@ class RoomClient {
|
|||||||
? this.userLog(
|
? this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.transcript} Transcript will be shown, when you receive a message`,
|
`${icons.transcript} Transcript will be shown, when you receive a message`,
|
||||||
'top-end',
|
'top-end'
|
||||||
)
|
)
|
||||||
: this.userLog(
|
: this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.transcript} Transcript not will be shown, when you receive a message`,
|
`${icons.transcript} Transcript not will be shown, when you receive a message`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'video_start_privacy':
|
case 'video_start_privacy':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone starts in privacy mode ${status}`,
|
`${icons.moderator} Moderator: everyone starts in privacy mode ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'audio_start_muted':
|
case 'audio_start_muted':
|
||||||
@@ -7513,42 +7513,42 @@ class RoomClient {
|
|||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't unmute themselves ${status}`,
|
`${icons.moderator} Moderator: everyone can't unmute themselves ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'video_cant_unhide':
|
case 'video_cant_unhide':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't unhide themselves ${status}`,
|
`${icons.moderator} Moderator: everyone can't unhide themselves ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'screen_cant_share':
|
case 'screen_cant_share':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't share the screen ${status}`,
|
`${icons.moderator} Moderator: everyone can't share the screen ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'chat_cant_privately':
|
case 'chat_cant_privately':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't chat privately ${status}`,
|
`${icons.moderator} Moderator: everyone can't chat privately ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'chat_cant_chatgpt':
|
case 'chat_cant_chatgpt':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't chat with ChatGPT ${status}`,
|
`${icons.moderator} Moderator: everyone can't chat with ChatGPT ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'chat_cant_deep_seek':
|
case 'chat_cant_deep_seek':
|
||||||
this.userLog(
|
this.userLog(
|
||||||
'info',
|
'info',
|
||||||
`${icons.moderator} Moderator: everyone can't chat with DeepSeek ${status}`,
|
`${icons.moderator} Moderator: everyone can't chat with DeepSeek ${status}`,
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case 'media_cant_sharing':
|
case 'media_cant_sharing':
|
||||||
@@ -8215,7 +8215,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
'To use this feature, please toggle Hide self view before',
|
'To use this feature, please toggle Hide self view before',
|
||||||
'top-end',
|
'top-end',
|
||||||
6000,
|
6000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
const videoContainer = this.getId(videoContainerId);
|
const videoContainer = this.getId(videoContainerId);
|
||||||
@@ -8540,7 +8540,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
from_peer_name + ' ' + _PEER.audioOff + ' has closed yours audio',
|
from_peer_name + ' ' + _PEER.audioOff + ' has closed yours audio',
|
||||||
'top-end',
|
'top-end',
|
||||||
10000,
|
10000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -8551,7 +8551,7 @@ class RoomClient {
|
|||||||
mediaType.audio,
|
mediaType.audio,
|
||||||
image.unmute,
|
image.unmute,
|
||||||
'Enable Microphone',
|
'Enable Microphone',
|
||||||
'Allow the presenter to enable your microphone?',
|
'Allow the presenter to enable your microphone?'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -8562,7 +8562,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
from_peer_name + ' ' + _PEER.videoOff + ' has closed yours video',
|
from_peer_name + ' ' + _PEER.videoOff + ' has closed yours video',
|
||||||
'top-end',
|
'top-end',
|
||||||
10000,
|
10000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -8572,7 +8572,7 @@ class RoomClient {
|
|||||||
mediaType.video,
|
mediaType.video,
|
||||||
image.unhide,
|
image.unhide,
|
||||||
'Enable Camera',
|
'Enable Camera',
|
||||||
'Allow the presenter to enable your camera?',
|
'Allow the presenter to enable your camera?'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -8584,7 +8584,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
from_peer_name + ' ' + _PEER.screenOff + ' has closed yours screen share',
|
from_peer_name + ' ' + _PEER.screenOff + ' has closed yours screen share',
|
||||||
'top-end',
|
'top-end',
|
||||||
10000,
|
10000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -8595,7 +8595,7 @@ class RoomClient {
|
|||||||
mediaType.screen,
|
mediaType.screen,
|
||||||
image.start,
|
image.start,
|
||||||
'Start Screen share',
|
'Start Screen share',
|
||||||
'Allow the presenter to start your screen share?',
|
'Allow the presenter to start your screen share?'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -8987,7 +8987,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
'The moderator does not allow you to chat with DeepSeek',
|
'The moderator does not allow you to chat with DeepSeek',
|
||||||
'top-end',
|
'top-end',
|
||||||
6000,
|
6000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
isDeepSeekOn = true;
|
isDeepSeekOn = true;
|
||||||
@@ -9158,7 +9158,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
peer_name + ' ' + _PEER.raiseHand + ' has raised the hand',
|
peer_name + ' ' + _PEER.raiseHand + ' has raised the hand',
|
||||||
'top-end',
|
'top-end',
|
||||||
10000,
|
10000
|
||||||
);
|
);
|
||||||
this.sound('raiseHand');
|
this.sound('raiseHand');
|
||||||
} else {
|
} else {
|
||||||
@@ -9192,7 +9192,7 @@ class RoomClient {
|
|||||||
id,
|
id,
|
||||||
`<div style="font-family: Arial, sans-serif; font-size: 14px; line-height: 1.5;">${peerInfoFormatted}</div>`,
|
`<div style="font-family: Arial, sans-serif; font-size: 14px; line-height: 1.5;">${peerInfoFormatted}</div>`,
|
||||||
'top-start',
|
'top-start',
|
||||||
true,
|
true
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -9248,7 +9248,7 @@ class RoomClient {
|
|||||||
'Geolocation',
|
'Geolocation',
|
||||||
'Geolocation requested. Please wait for confirmation...',
|
'Geolocation requested. Please wait for confirmation...',
|
||||||
6000,
|
6000,
|
||||||
'geolocation',
|
'geolocation'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -9319,13 +9319,13 @@ class RoomClient {
|
|||||||
}
|
}
|
||||||
rc.sendPeerGeoLocation(peer_id, 'geoLocationKO', `${rc.peer_name}: ${geoError}`);
|
rc.sendPeerGeoLocation(peer_id, 'geoLocationKO', `${rc.peer_name}: ${geoError}`);
|
||||||
rc.userLog('warning', geoError, 'top-end', 5000);
|
rc.userLog('warning', geoError, 'top-end', 5000);
|
||||||
},
|
}
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
rc.sendPeerGeoLocation(
|
rc.sendPeerGeoLocation(
|
||||||
peer_id,
|
peer_id,
|
||||||
'geoLocationKO',
|
'geoLocationKO',
|
||||||
`${rc.peer_name}: Geolocation is not supported by this browser`,
|
`${rc.peer_name}: Geolocation is not supported by this browser`
|
||||||
);
|
);
|
||||||
rc.userLog('warning', 'Geolocation is not supported by this browser', 'top-end', 5000);
|
rc.userLog('warning', 'Geolocation is not supported by this browser', 'top-end', 5000);
|
||||||
}
|
}
|
||||||
@@ -9430,7 +9430,7 @@ class RoomClient {
|
|||||||
img.setAttribute('style', 'cursor:pointer; padding: 2px; border-radius: 5px;');
|
img.setAttribute('style', 'cursor:pointer; padding: 2px; border-radius: 5px;');
|
||||||
img.setAttribute(
|
img.setAttribute(
|
||||||
'avatarData',
|
'avatarData',
|
||||||
avatar.avatar_id + '|' + avatar.avatar_name + '|' + avatar.preview_video_url,
|
avatar.avatar_id + '|' + avatar.avatar_name + '|' + avatar.preview_video_url
|
||||||
);
|
);
|
||||||
img.onclick = () => {
|
img.onclick = () => {
|
||||||
const avatarImages = document.querySelectorAll('.avatarImg');
|
const avatarImages = document.querySelectorAll('.avatarImg');
|
||||||
@@ -9647,7 +9647,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
'You’ve reached your quota limit for this demo account. Please consider upgrading for more features.',
|
'You’ve reached your quota limit for this demo account. Please consider upgrading for more features.',
|
||||||
6000,
|
6000,
|
||||||
'top',
|
'top'
|
||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
// ...
|
// ...
|
||||||
@@ -9754,7 +9754,7 @@ class RoomClient {
|
|||||||
}
|
}
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.streamingTask(
|
this.streamingTask(
|
||||||
`Welcome to ${BRAND.app.name}! Please Open the Chat and navigate to the ChatGPT section. Feel free to ask me any questions you have.`,
|
`Welcome to ${BRAND.app.name}! Please Open the Chat and navigate to the ChatGPT section. Feel free to ask me any questions you have.`
|
||||||
);
|
);
|
||||||
}, 2000);
|
}, 2000);
|
||||||
}
|
}
|
||||||
@@ -9785,7 +9785,7 @@ class RoomClient {
|
|||||||
task.action();
|
task.action();
|
||||||
resolve();
|
resolve();
|
||||||
}, task.delay);
|
}, task.delay);
|
||||||
}),
|
})
|
||||||
);
|
);
|
||||||
}, Promise.resolve());
|
}, Promise.resolve());
|
||||||
}
|
}
|
||||||
@@ -9967,7 +9967,7 @@ class RoomClient {
|
|||||||
return this.userLog(
|
return this.userLog(
|
||||||
'warning',
|
'warning',
|
||||||
"The provided File is not valid. Please ensure it's .mp4, webm or ogg video file",
|
"The provided File is not valid. Please ensure it's .mp4, webm or ogg video file",
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -10024,7 +10024,7 @@ class RoomClient {
|
|||||||
return this.userLog(
|
return this.userLog(
|
||||||
'warning',
|
'warning',
|
||||||
'The provided URL is not valid. Please ensure it links to an .mp4 video file',
|
'The provided URL is not valid. Please ensure it links to an .mp4 video file',
|
||||||
'top-end',
|
'top-end'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -10123,7 +10123,7 @@ class RoomClient {
|
|||||||
'warning',
|
'warning',
|
||||||
'Unable to start the RTMP stream. Please ensure the RTMP server is running. If the problem persists, contact the administrator',
|
'Unable to start the RTMP stream. Please ensure the RTMP server is running. If the problem persists, contact the administrator',
|
||||||
'top-end',
|
'top-end',
|
||||||
6000,
|
6000
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -169,7 +169,7 @@ class Transcription {
|
|||||||
console.info('This Browser support Transcription');
|
console.info('This Browser support Transcription');
|
||||||
} else {
|
} else {
|
||||||
console.warn(
|
console.warn(
|
||||||
'This browser not support Transcription, check out supported browsers: https://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API#browser_compatibility',
|
'This browser not support Transcription, check out supported browsers: https://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API#browser_compatibility'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -431,7 +431,7 @@ class Transcription {
|
|||||||
hide(transcriptionFooter);
|
hide(transcriptionFooter);
|
||||||
rc.msgPopup(
|
rc.msgPopup(
|
||||||
'info',
|
'info',
|
||||||
`${peer_name} wants to start transcriptions for this session, but your browser does not support it. Please use a Chromium-based browser like Google Chrome, Microsoft Edge, or Brave.`,
|
`${peer_name} wants to start transcriptions for this session, but your browser does not support it. Please use a Chromium-based browser like Google Chrome, Microsoft Edge, or Brave.`
|
||||||
);
|
);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ function googleTranslateElementInit() {
|
|||||||
pageLanguage: 'en',
|
pageLanguage: 'en',
|
||||||
autoDisplay: false,
|
autoDisplay: false,
|
||||||
},
|
},
|
||||||
'google_translate_element',
|
'google_translate_element'
|
||||||
);
|
);
|
||||||
|
|
||||||
const language = BRAND?.app?.language || 'en';
|
const language = BRAND?.app?.language || 'en';
|
||||||
|
|||||||
@@ -217,5 +217,5 @@ window.addEventListener(
|
|||||||
resizeTranscriptionRoom();
|
resizeTranscriptionRoom();
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
false,
|
false
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ class VirtualBackground {
|
|||||||
this.isSupported = this.checkSupport();
|
this.isSupported = this.checkSupport();
|
||||||
if (!this.isSupported) {
|
if (!this.isSupported) {
|
||||||
console.warn(
|
console.warn(
|
||||||
'⚠️ MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.',
|
'⚠️ MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -80,7 +80,7 @@ class VirtualBackground {
|
|||||||
pendingFrame.controller,
|
pendingFrame.controller,
|
||||||
pendingFrame.imageBitmap,
|
pendingFrame.imageBitmap,
|
||||||
pendingFrame.maskHandler,
|
pendingFrame.maskHandler,
|
||||||
this.lastSegmentationMask,
|
this.lastSegmentationMask
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -124,7 +124,7 @@ class VirtualBackground {
|
|||||||
// Check if the required APIs are supported
|
// Check if the required APIs are supported
|
||||||
if (!this.isSupported) {
|
if (!this.isSupported) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.',
|
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -239,7 +239,7 @@ class VirtualBackground {
|
|||||||
// Check if the required APIs are supported
|
// Check if the required APIs are supported
|
||||||
if (!this.isSupported) {
|
if (!this.isSupported) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.',
|
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -267,7 +267,7 @@ class VirtualBackground {
|
|||||||
// Check if the required APIs are supported
|
// Check if the required APIs are supported
|
||||||
if (!this.isSupported) {
|
if (!this.isSupported) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.',
|
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -302,7 +302,7 @@ class VirtualBackground {
|
|||||||
// Check if the required APIs are supported
|
// Check if the required APIs are supported
|
||||||
if (!this.isSupported) {
|
if (!this.isSupported) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.',
|
'MediaStreamTrackProcessor, MediaStreamTrackGenerator, or TransformStream is not supported in this environment.'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ describe('test-OpenRedirect', function () {
|
|||||||
res.redirect
|
res.redirect
|
||||||
.calledWith(
|
.calledWith(
|
||||||
301,
|
301,
|
||||||
'/join?room=test&roomPassword=0&name=mirotalksfu&audio=1&video=1&screen=0&hide=0¬ify=1&duration=00:00:30',
|
'/join?room=test&roomPassword=0&name=mirotalksfu&audio=1&video=1&screen=0&hide=0¬ify=1&duration=00:00:30'
|
||||||
)
|
)
|
||||||
.should.be.true();
|
.should.be.true();
|
||||||
});
|
});
|
||||||
@@ -95,7 +95,7 @@ describe('test-OpenRedirect', function () {
|
|||||||
res.redirect
|
res.redirect
|
||||||
.calledWith(
|
.calledWith(
|
||||||
301,
|
301,
|
||||||
'/join?room=test&roomPassword=0&name=mirotalksfu&audio=1&video=1&screen=0&hide=0¬ify=0&token=token',
|
'/join?room=test&roomPassword=0&name=mirotalksfu&audio=1&video=1&screen=0&hide=0¬ify=0&token=token'
|
||||||
)
|
)
|
||||||
.should.be.true();
|
.should.be.true();
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ describe('test-ServerAPI', () => {
|
|||||||
|
|
||||||
const result = serverApi.getJoinURL(data);
|
const result = serverApi.getJoinURL(data);
|
||||||
result.should.equal(
|
result.should.equal(
|
||||||
'https://example.com/join?room=room1&roomPassword=password123&name=John%20Doe&avatar=test.jpg&audio=true&video=false&screen=false&hide=false¬ify=false&duration=00:30:00&token=testToken',
|
'https://example.com/join?room=room1&roomPassword=password123&name=John%20Doe&avatar=test.jpg&audio=true&video=false&screen=false&hide=false¬ify=false&duration=00:30:00&token=testToken'
|
||||||
);
|
);
|
||||||
|
|
||||||
tokenStub.restore();
|
tokenStub.restore();
|
||||||
@@ -204,7 +204,7 @@ describe('test-ServerAPI', () => {
|
|||||||
|
|
||||||
const result = serverApi.getJoinURL({});
|
const result = serverApi.getJoinURL({});
|
||||||
result.should.equal(
|
result.should.equal(
|
||||||
'https://example.com/join?room=room1&roomPassword=false&name=User-123456&avatar=false&audio=false&video=false&screen=false&hide=false¬ify=false&duration=unlimited',
|
'https://example.com/join?room=room1&roomPassword=false&name=User-123456&avatar=false&audio=false&video=false&screen=false&hide=false¬ify=false&duration=unlimited'
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -224,7 +224,7 @@ describe('test-ServerAPI', () => {
|
|||||||
encryptStub
|
encryptStub
|
||||||
.calledWith(
|
.calledWith(
|
||||||
JSON.stringify({ username: 'user', password: 'pass', presenter: 'true' }),
|
JSON.stringify({ username: 'user', password: 'pass', presenter: 'true' }),
|
||||||
'mirotalksfu_jwt_secret',
|
'mirotalksfu_jwt_secret'
|
||||||
)
|
)
|
||||||
.should.be.true();
|
.should.be.true();
|
||||||
|
|
||||||
|
|||||||
المرجع في مشكلة جديدة
حظر مستخدم