@100mslive/roomkit-react 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{ActiveSpeakerView-H3VYXANB.js → ActiveSpeakerView-G32BDM5F.js} +6 -6
- package/dist/{HLSView-6BVBCQM7.css → ActiveSpeakerView-LW4WDBC6.css} +2 -2
- package/dist/{PinnedTrackView-QQ5FDXJX.css.map → ActiveSpeakerView-LW4WDBC6.css.map} +1 -1
- package/dist/{conference-KN6OKGDU.css → HLSView-DIQQF2PP.css} +2 -2
- package/dist/{HLSView-6BVBCQM7.css.map → HLSView-DIQQF2PP.css.map} +1 -1
- package/dist/{HLSView-3RDXRV7Y.js → HLSView-ZYNT3HJD.js} +5 -5
- package/dist/{PinnedTrackView-453PELNU.js → PinnedTrackView-GTXL2UTS.js} +6 -6
- package/dist/{PinnedTrackView-QQ5FDXJX.css → PinnedTrackView-OAA4HAID.css} +2 -2
- package/dist/{conference-KN6OKGDU.css.map → PinnedTrackView-OAA4HAID.css.map} +1 -1
- package/dist/{VirtualBackground-LHYBWUT5.js → VirtualBackground-HWU22Q6S.js} +3 -3
- package/dist/{chunk-KYYP6ZVK.js → chunk-4VY5NUK7.js} +2 -2
- package/dist/{chunk-KYYP6ZVK.js.map → chunk-4VY5NUK7.js.map} +1 -1
- package/dist/{chunk-XRJXE6UO.js → chunk-A2PNZIK7.js} +2 -2
- package/dist/{chunk-ULXGBUSC.js → chunk-BSQIN5RC.js} +2 -2
- package/dist/{chunk-7YUYZ64D.js → chunk-TEHZYXCJ.js} +457 -781
- package/dist/chunk-TEHZYXCJ.js.map +7 -0
- package/dist/chunk-ZET2HMGS.js +8331 -0
- package/dist/chunk-ZET2HMGS.js.map +7 -0
- package/dist/{ActiveSpeakerView-REZLWPPI.css → conference-LE4T3ZNF.css} +2 -2
- package/dist/{ActiveSpeakerView-REZLWPPI.css.map → conference-LE4T3ZNF.css.map} +1 -1
- package/dist/{conference-IDNRO4WK.js → conference-YHO2J3Z6.js} +11 -11
- package/dist/index.cjs.css +1 -1
- package/dist/index.cjs.css.map +1 -1
- package/dist/index.cjs.js +1383 -1641
- package/dist/index.cjs.js.map +4 -4
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.js +4 -4
- package/dist/meta.cjs.json +43 -38
- package/dist/meta.esbuild.json +129 -124
- package/dist/{transcription-BTSB7FZH.js → transcription-L6VBK75V.js} +3 -3
- package/package.json +3 -2
- package/src/Prebuilt/components/Streaming/RTMPIcon.jsx +58 -13
- package/src/TileMenu/StyledMenuTile.tsx +3 -1
- package/dist/chunk-7YUYZ64D.js.map +0 -7
- package/dist/chunk-HCAGFNXW.js +0 -8270
- package/dist/chunk-HCAGFNXW.js.map +0 -7
- /package/dist/{ActiveSpeakerView-H3VYXANB.js.map → ActiveSpeakerView-G32BDM5F.js.map} +0 -0
- /package/dist/{HLSView-3RDXRV7Y.js.map → HLSView-ZYNT3HJD.js.map} +0 -0
- /package/dist/{PinnedTrackView-453PELNU.js.map → PinnedTrackView-GTXL2UTS.js.map} +0 -0
- /package/dist/{VirtualBackground-LHYBWUT5.js.map → VirtualBackground-HWU22Q6S.js.map} +0 -0
- /package/dist/{chunk-XRJXE6UO.js.map → chunk-A2PNZIK7.js.map} +0 -0
- /package/dist/{chunk-ULXGBUSC.js.map → chunk-BSQIN5RC.js.map} +0 -0
- /package/dist/{conference-IDNRO4WK.js.map → conference-YHO2J3Z6.js.map} +0 -0
- /package/dist/{transcription-BTSB7FZH.js.map → transcription-L6VBK75V.js.map} +0 -0
@@ -17,15 +17,15 @@ import {
|
|
17
17
|
useSetAppDataByKey,
|
18
18
|
useTheme,
|
19
19
|
useUISettings
|
20
|
-
} from "./chunk-
|
20
|
+
} from "./chunk-ZET2HMGS.js";
|
21
21
|
import {
|
22
22
|
useIsFeatureEnabled
|
23
|
-
} from "./chunk-
|
23
|
+
} from "./chunk-BSQIN5RC.js";
|
24
24
|
import {
|
25
25
|
Box,
|
26
26
|
Flex,
|
27
27
|
Text
|
28
|
-
} from "./chunk-
|
28
|
+
} from "./chunk-A2PNZIK7.js";
|
29
29
|
import {
|
30
30
|
APP_DATA,
|
31
31
|
FEATURE_LIST,
|
@@ -42,7 +42,7 @@ import {
|
|
42
42
|
define_process_env_default,
|
43
43
|
init_define_process_env,
|
44
44
|
styled
|
45
|
-
} from "./chunk-
|
45
|
+
} from "./chunk-4VY5NUK7.js";
|
46
46
|
|
47
47
|
// ../../node_modules/ua-parser-js/src/ua-parser.js
|
48
48
|
var require_ua_parser = __commonJS({
|
@@ -81,18 +81,18 @@ var require_ua_parser = __commonJS({
|
|
81
81
|
}
|
82
82
|
};
|
83
83
|
var rgxMapper = function(ua, arrays) {
|
84
|
-
var i = 0,
|
84
|
+
var i = 0, j2, k2, p, q, matches, match;
|
85
85
|
while (i < arrays.length && !matches) {
|
86
86
|
var regex = arrays[i], props = arrays[i + 1];
|
87
|
-
|
88
|
-
while (
|
89
|
-
if (!regex[
|
87
|
+
j2 = k2 = 0;
|
88
|
+
while (j2 < regex.length && !matches) {
|
89
|
+
if (!regex[j2]) {
|
90
90
|
break;
|
91
91
|
}
|
92
|
-
matches = regex[
|
92
|
+
matches = regex[j2++].exec(ua);
|
93
93
|
if (!!matches) {
|
94
94
|
for (p = 0; p < props.length; p++) {
|
95
|
-
match = matches[++
|
95
|
+
match = matches[++k2];
|
96
96
|
q = props[p];
|
97
97
|
if (typeof q === OBJ_TYPE && q.length > 0) {
|
98
98
|
if (q.length === 2) {
|
@@ -121,8 +121,8 @@ var require_ua_parser = __commonJS({
|
|
121
121
|
}, strMapper = function(str, map) {
|
122
122
|
for (var i in map) {
|
123
123
|
if (typeof map[i] === OBJ_TYPE && map[i].length > 0) {
|
124
|
-
for (var
|
125
|
-
if (has(map[i][
|
124
|
+
for (var j2 = 0; j2 < map[i].length; j2++) {
|
125
|
+
if (has(map[i][j2], str)) {
|
126
126
|
return i === UNKNOWN ? undefined2 : i;
|
127
127
|
}
|
128
128
|
}
|
@@ -1279,18 +1279,18 @@ var require_ua_parser = __commonJS({
|
|
1279
1279
|
window2.UAParser = UAParser;
|
1280
1280
|
}
|
1281
1281
|
}
|
1282
|
-
var $ = typeof window2 !== UNDEF_TYPE && (window2.jQuery || window2.Zepto);
|
1283
|
-
if ($ &&
|
1282
|
+
var $2 = typeof window2 !== UNDEF_TYPE && (window2.jQuery || window2.Zepto);
|
1283
|
+
if ($2 && !$2.ua) {
|
1284
1284
|
var parser = new UAParser();
|
1285
|
-
|
1286
|
-
|
1285
|
+
$2.ua = parser.getResult();
|
1286
|
+
$2.ua.get = function() {
|
1287
1287
|
return parser.getUA();
|
1288
1288
|
};
|
1289
|
-
|
1289
|
+
$2.ua.set = function(ua) {
|
1290
1290
|
parser.setUA(ua);
|
1291
1291
|
var result = parser.getResult();
|
1292
1292
|
for (var prop in result) {
|
1293
|
-
|
1293
|
+
$2.ua[prop] = result[prop];
|
1294
1294
|
}
|
1295
1295
|
};
|
1296
1296
|
}
|
@@ -1421,12 +1421,12 @@ var require_sdp = __commonJS({
|
|
1421
1421
|
return parsed;
|
1422
1422
|
};
|
1423
1423
|
SDPUtils2.writeRtpMap = function(codec) {
|
1424
|
-
let
|
1424
|
+
let pt2 = codec.payloadType;
|
1425
1425
|
if (codec.preferredPayloadType !== void 0) {
|
1426
|
-
|
1426
|
+
pt2 = codec.preferredPayloadType;
|
1427
1427
|
}
|
1428
1428
|
const channels = codec.channels || codec.numChannels || 1;
|
1429
|
-
return "a=rtpmap:" +
|
1429
|
+
return "a=rtpmap:" + pt2 + " " + codec.name + "/" + codec.clockRate + (channels !== 1 ? "/" + channels : "") + "\r\n";
|
1430
1430
|
};
|
1431
1431
|
SDPUtils2.parseExtmap = function(line) {
|
1432
1432
|
const parts = line.substring(9).split(" ");
|
@@ -1444,17 +1444,17 @@ var require_sdp = __commonJS({
|
|
1444
1444
|
const parsed = {};
|
1445
1445
|
let kv;
|
1446
1446
|
const parts = line.substring(line.indexOf(" ") + 1).split(";");
|
1447
|
-
for (let
|
1448
|
-
kv = parts[
|
1447
|
+
for (let j2 = 0; j2 < parts.length; j2++) {
|
1448
|
+
kv = parts[j2].trim().split("=");
|
1449
1449
|
parsed[kv[0].trim()] = kv[1];
|
1450
1450
|
}
|
1451
1451
|
return parsed;
|
1452
1452
|
};
|
1453
1453
|
SDPUtils2.writeFmtp = function(codec) {
|
1454
1454
|
let line = "";
|
1455
|
-
let
|
1455
|
+
let pt2 = codec.payloadType;
|
1456
1456
|
if (codec.preferredPayloadType !== void 0) {
|
1457
|
-
|
1457
|
+
pt2 = codec.preferredPayloadType;
|
1458
1458
|
}
|
1459
1459
|
if (codec.parameters && Object.keys(codec.parameters).length) {
|
1460
1460
|
const params = [];
|
@@ -1465,7 +1465,7 @@ var require_sdp = __commonJS({
|
|
1465
1465
|
params.push(param);
|
1466
1466
|
}
|
1467
1467
|
});
|
1468
|
-
line += "a=fmtp:" +
|
1468
|
+
line += "a=fmtp:" + pt2 + " " + params.join(";") + "\r\n";
|
1469
1469
|
}
|
1470
1470
|
return line;
|
1471
1471
|
};
|
@@ -1478,13 +1478,13 @@ var require_sdp = __commonJS({
|
|
1478
1478
|
};
|
1479
1479
|
SDPUtils2.writeRtcpFb = function(codec) {
|
1480
1480
|
let lines = "";
|
1481
|
-
let
|
1481
|
+
let pt2 = codec.payloadType;
|
1482
1482
|
if (codec.preferredPayloadType !== void 0) {
|
1483
|
-
|
1483
|
+
pt2 = codec.preferredPayloadType;
|
1484
1484
|
}
|
1485
1485
|
if (codec.rtcpFeedback && codec.rtcpFeedback.length) {
|
1486
1486
|
codec.rtcpFeedback.forEach((fb) => {
|
1487
|
-
lines += "a=rtcp-fb:" +
|
1487
|
+
lines += "a=rtcp-fb:" + pt2 + " " + fb.type + (fb.parameter && fb.parameter.length ? " " + fb.parameter : "") + "\r\n";
|
1488
1488
|
});
|
1489
1489
|
}
|
1490
1490
|
return lines;
|
@@ -1612,21 +1612,21 @@ var require_sdp = __commonJS({
|
|
1612
1612
|
const mline = lines[0].split(" ");
|
1613
1613
|
description.profile = mline[2];
|
1614
1614
|
for (let i = 3; i < mline.length; i++) {
|
1615
|
-
const
|
1615
|
+
const pt2 = mline[i];
|
1616
1616
|
const rtpmapline = SDPUtils2.matchPrefix(
|
1617
1617
|
mediaSection,
|
1618
|
-
"a=rtpmap:" +
|
1618
|
+
"a=rtpmap:" + pt2 + " "
|
1619
1619
|
)[0];
|
1620
1620
|
if (rtpmapline) {
|
1621
1621
|
const codec = SDPUtils2.parseRtpMap(rtpmapline);
|
1622
1622
|
const fmtps = SDPUtils2.matchPrefix(
|
1623
1623
|
mediaSection,
|
1624
|
-
"a=fmtp:" +
|
1624
|
+
"a=fmtp:" + pt2 + " "
|
1625
1625
|
);
|
1626
1626
|
codec.parameters = fmtps.length ? SDPUtils2.parseFmtp(fmtps[0]) : {};
|
1627
1627
|
codec.rtcpFeedback = SDPUtils2.matchPrefix(
|
1628
1628
|
mediaSection,
|
1629
|
-
"a=rtcp-fb:" +
|
1629
|
+
"a=rtcp-fb:" + pt2 + " "
|
1630
1630
|
).map(SDPUtils2.parseRtcpFb);
|
1631
1631
|
description.codecs.push(codec);
|
1632
1632
|
switch (codec.name.toUpperCase()) {
|
@@ -2384,8 +2384,8 @@ var require_grammar = __commonJS({
|
|
2384
2384
|
var require_parser = __commonJS({
|
2385
2385
|
"../../node_modules/sdp-transform/lib/parser.js"(exports) {
|
2386
2386
|
init_define_process_env();
|
2387
|
-
var toIntIfInt = function(
|
2388
|
-
return String(Number(
|
2387
|
+
var toIntIfInt = function(v3) {
|
2388
|
+
return String(Number(v3)) === v3 ? Number(v3) : v3;
|
2389
2389
|
};
|
2390
2390
|
var attachProperties = function(match, location, names, rawName) {
|
2391
2391
|
if (rawName && !names) {
|
@@ -2425,8 +2425,8 @@ var require_parser = __commonJS({
|
|
2425
2425
|
media.push({ rtp: [], fmtp: [] });
|
2426
2426
|
location = media[media.length - 1];
|
2427
2427
|
}
|
2428
|
-
for (var
|
2429
|
-
var obj = grammar[type][
|
2428
|
+
for (var j2 = 0; j2 < (grammar[type] || []).length; j2 += 1) {
|
2429
|
+
var obj = grammar[type][j2];
|
2430
2430
|
if (obj.reg.test(content)) {
|
2431
2431
|
return parseReg(obj, location, content);
|
2432
2432
|
}
|
@@ -3024,7 +3024,7 @@ var Image = styled("img", {
|
|
3024
3024
|
// src/Prebuilt/components/VideoList.jsx
|
3025
3025
|
init_define_process_env();
|
3026
3026
|
import React6, { Fragment as Fragment3, useEffect as useEffect2, useState as useState5 } from "react";
|
3027
|
-
import { selectLocalPeerID as
|
3027
|
+
import { selectLocalPeerID as selectLocalPeerID4, useHMSStore as useHMSStore5, useVideoList } from "@100mslive/react-sdk";
|
3028
3028
|
|
3029
3029
|
// src/Prebuilt/components/Pagination.jsx
|
3030
3030
|
init_define_process_env();
|
@@ -3039,7 +3039,7 @@ var Pagination = ({ page, setPage, numPages }) => {
|
|
3039
3039
|
const prevPage = () => {
|
3040
3040
|
setPage(Math.max(page - 1, 0));
|
3041
3041
|
};
|
3042
|
-
return /* @__PURE__ */ React4.createElement(StyledPagination.Root, null, /* @__PURE__ */ React4.createElement(StyledPagination.Chevron, { disabled: disableLeft, onClick: prevPage }, /* @__PURE__ */ React4.createElement(ChevronLeftIcon, { width: 16, height: 16, style: { cursor: disableLeft ? "not-allowed" : "pointer" } })), /* @__PURE__ */ React4.createElement(StyledPagination.Dots, null, [...Array(numPages)].map((
|
3042
|
+
return /* @__PURE__ */ React4.createElement(StyledPagination.Root, null, /* @__PURE__ */ React4.createElement(StyledPagination.Chevron, { disabled: disableLeft, onClick: prevPage }, /* @__PURE__ */ React4.createElement(ChevronLeftIcon, { width: 16, height: 16, style: { cursor: disableLeft ? "not-allowed" : "pointer" } })), /* @__PURE__ */ React4.createElement(StyledPagination.Dots, null, [...Array(numPages)].map((_3, i) => /* @__PURE__ */ React4.createElement(StyledPagination.Dot, { key: i, active: page === i, onClick: () => setPage(i) }))), /* @__PURE__ */ React4.createElement(StyledPagination.Chevron, { disabled: disableRight, onClick: nextPage }, /* @__PURE__ */ React4.createElement(ChevronRightIcon, { width: 16, height: 16, style: { cursor: disableRight ? "not-allowed" : "pointer" } })));
|
3043
3043
|
};
|
3044
3044
|
|
3045
3045
|
// src/Prebuilt/components/ScreenshareTile.jsx
|
@@ -3125,8 +3125,8 @@ init_define_process_env();
|
|
3125
3125
|
|
3126
3126
|
// ../../node_modules/reselect/es/index.js
|
3127
3127
|
init_define_process_env();
|
3128
|
-
function defaultEqualityCheck(a,
|
3129
|
-
return a ===
|
3128
|
+
function defaultEqualityCheck(a, b2) {
|
3129
|
+
return a === b2;
|
3130
3130
|
}
|
3131
3131
|
function areArgumentsShallowlyEqual(equalityCheck, prev, next) {
|
3132
3132
|
if (prev === null || next === null || prev.length !== next.length) {
|
@@ -3496,9 +3496,9 @@ function shimGetUserMedia(window2, browserDetails) {
|
|
3496
3496
|
}
|
3497
3497
|
constraints = JSON.parse(JSON.stringify(constraints));
|
3498
3498
|
if (constraints && typeof constraints.audio === "object") {
|
3499
|
-
const remap = function(obj, a,
|
3500
|
-
if (a in obj && !(
|
3501
|
-
obj[
|
3499
|
+
const remap = function(obj, a, b2) {
|
3500
|
+
if (a in obj && !(b2 in obj)) {
|
3501
|
+
obj[b2] = obj[a];
|
3502
3502
|
delete obj[a];
|
3503
3503
|
}
|
3504
3504
|
};
|
@@ -3577,8 +3577,8 @@ function shimGetUserMedia(window2, browserDetails) {
|
|
3577
3577
|
navigator2.getUserMedia = getUserMedia_.bind(navigator2);
|
3578
3578
|
if (navigator2.mediaDevices.getUserMedia) {
|
3579
3579
|
const origGetUserMedia = navigator2.mediaDevices.getUserMedia.bind(navigator2.mediaDevices);
|
3580
|
-
navigator2.mediaDevices.getUserMedia = function(
|
3581
|
-
return shimConstraints_(
|
3580
|
+
navigator2.mediaDevices.getUserMedia = function(cs2) {
|
3581
|
+
return shimConstraints_(cs2, (c) => origGetUserMedia(c).then((stream) => {
|
3582
3582
|
if (c.audio && !stream.getAudioTracks().length || c.video && !stream.getVideoTracks().length) {
|
3583
3583
|
stream.getTracks().forEach((track) => {
|
3584
3584
|
track.stop();
|
@@ -3650,15 +3650,15 @@ function shimOnTrack(window2) {
|
|
3650
3650
|
window2.RTCPeerConnection.prototype.setRemoteDescription = function setRemoteDescription() {
|
3651
3651
|
if (!this._ontrackpoly) {
|
3652
3652
|
this._ontrackpoly = (e) => {
|
3653
|
-
e.stream.addEventListener("addtrack", (
|
3653
|
+
e.stream.addEventListener("addtrack", (te2) => {
|
3654
3654
|
let receiver;
|
3655
3655
|
if (window2.RTCPeerConnection.prototype.getReceivers) {
|
3656
|
-
receiver = this.getReceivers().find((r) => r.track && r.track.id ===
|
3656
|
+
receiver = this.getReceivers().find((r) => r.track && r.track.id === te2.track.id);
|
3657
3657
|
} else {
|
3658
|
-
receiver = { track:
|
3658
|
+
receiver = { track: te2.track };
|
3659
3659
|
}
|
3660
3660
|
const event = new Event("track");
|
3661
|
-
event.track =
|
3661
|
+
event.track = te2.track;
|
3662
3662
|
event.receiver = receiver;
|
3663
3663
|
event.transceiver = { receiver };
|
3664
3664
|
event.streams = [e.stream];
|
@@ -4240,9 +4240,9 @@ function shimGetUserMedia2(window2, browserDetails) {
|
|
4240
4240
|
navigator2.mediaDevices.getUserMedia(constraints).then(onSuccess, onError);
|
4241
4241
|
};
|
4242
4242
|
if (!(browserDetails.version > 55 && "autoGainControl" in navigator2.mediaDevices.getSupportedConstraints())) {
|
4243
|
-
const remap = function(obj, a,
|
4244
|
-
if (a in obj && !(
|
4245
|
-
obj[
|
4243
|
+
const remap = function(obj, a, b2) {
|
4244
|
+
if (a in obj && !(b2 in obj)) {
|
4245
|
+
obj[b2] = obj[a];
|
4246
4246
|
delete obj[a];
|
4247
4247
|
}
|
4248
4248
|
};
|
@@ -5337,8 +5337,8 @@ var $t = (n2, e) => {
|
|
5337
5337
|
return t;
|
5338
5338
|
};
|
5339
5339
|
var mr = (n2, e) => () => (e || n2((e = { exports: {} }).exports, e), e.exports);
|
5340
|
-
var qt = mr((
|
5341
|
-
kr.exports = { name: "@100mslive/hms-video", version: "0.9.10
|
5340
|
+
var qt = mr((Ks2, kr) => {
|
5341
|
+
kr.exports = { name: "@100mslive/hms-video", version: "0.9.10", license: "MIT", main: "dist/index.cjs.js", typings: "dist/index.d.ts", module: "dist/index.js", files: ["dist", "src"], engines: { node: ">=10" }, exports: { ".": { require: "./dist/index.cjs.js", import: "./dist/index.js", default: "./dist/index.js" } }, scripts: { prestart: "rm -rf dist && yarn types:build", start: 'concurrently "yarn dev" "yarn types"', dev: "node ../../scripts/dev", "build:only": "node ../../scripts/build", build: "yarn build:only && yarn types:build", types: "tsc -w", "types:build": "tsc -p tsconfig.json", test: "jest --maxWorkers=1", lint: "eslint -c ../../.eslintrc .", "lint:fix": "yarn lint --fix", prepare: "yarn build", size: "size-limit", analyze: "size-limit --why", format: "prettier --write src/**/*.ts" }, author: "100ms <tech-common@100ms.live>", devDependencies: { "@types/dom-screen-wake-lock": "^1.0.1", "@types/sdp-transform": "^2.4.4", "@types/ua-parser-js": "^0.7.36", "@types/uuid": "^8.3.0", "jest-canvas-mock": "^2.3.1", tslib: "^2.2.0" }, dependencies: { eventemitter2: "^6.4.7", "sdp-transform": "^2.14.1", "ua-parser-js": "^1.0.1", uuid: "^8.3.2", "webrtc-adapter": "^8.0.0" } };
|
5342
5342
|
});
|
5343
5343
|
var Se = class {
|
5344
5344
|
};
|
@@ -5418,8 +5418,8 @@ function Le(n2 = "prod", e) {
|
|
5418
5418
|
let t = "web", i = ve !== "LOCAL" && n2 === "prod" ? "prod" : "debug";
|
5419
5419
|
if (ce)
|
5420
5420
|
return Ii({ os: "web_nodejs", os_version: process.version, sdk: t, sdk_version: bi, env: i, domain: ve, framework: "node", framework_version: process.version, framework_sdk_version: e == null ? void 0 : e.sdkVersion });
|
5421
|
-
let r = oe.getOS(), s = oe.getDevice(), a = oe.getBrowser(), c = jt(`web_${r.name}`), l = r.version || "", h = jt(`${a.name}_${a.version}`),
|
5422
|
-
return s.type && (
|
5421
|
+
let r = oe.getOS(), s = oe.getDevice(), a = oe.getBrowser(), c = jt(`web_${r.name}`), l = r.version || "", h = jt(`${a.name}_${a.version}`), u2 = h;
|
5422
|
+
return s.type && (u2 = `${jt(`${s.vendor}_${s.type}`)}/${h}`), Ii({ os: c, os_version: l, sdk: t, sdk_version: bi, device_model: u2, env: i, domain: ve, framework: e == null ? void 0 : e.type, framework_version: e == null ? void 0 : e.version, framework_sdk_version: e == null ? void 0 : e.sdkVersion });
|
5423
5423
|
}
|
5424
5424
|
function jt(n2) {
|
5425
5425
|
return n2.replace(/ /g, "_");
|
@@ -5665,7 +5665,7 @@ function nt(n2, e = 300) {
|
|
5665
5665
|
};
|
5666
5666
|
}
|
5667
5667
|
var Hi = ((s) => (s.RECORDING_STATE_UPDATED = "RECORDING_STATE_UPDATED", s.BROWSER_RECORDING_STATE_UPDATED = "BROWSER_RECORDING_STATE_UPDATED", s.SERVER_RECORDING_STATE_UPDATED = "SERVER_RECORDING_STATE_UPDATED", s.RTMP_STREAMING_STATE_UPDATED = "RTMP_STREAMING_STATE_UPDATED", s.HLS_STREAMING_STATE_UPDATED = "HLS_STREAMING_STATE_UPDATED", s))(Hi || {});
|
5668
|
-
var ct = ((
|
5668
|
+
var ct = ((S2) => (S2[S2.PEER_JOINED = 0] = "PEER_JOINED", S2[S2.PEER_LEFT = 1] = "PEER_LEFT", S2[S2.AUDIO_TOGGLED = 2] = "AUDIO_TOGGLED", S2[S2.VIDEO_TOGGLED = 3] = "VIDEO_TOGGLED", S2[S2.BECAME_DOMINANT_SPEAKER = 4] = "BECAME_DOMINANT_SPEAKER", S2[S2.RESIGNED_DOMINANT_SPEAKER = 5] = "RESIGNED_DOMINANT_SPEAKER", S2[S2.STARTED_SPEAKING = 6] = "STARTED_SPEAKING", S2[S2.STOPPED_SPEAKING = 7] = "STOPPED_SPEAKING", S2[S2.ROLE_UPDATED = 8] = "ROLE_UPDATED", S2[S2.PEER_LIST = 9] = "PEER_LIST", S2[S2.NAME_UPDATED = 10] = "NAME_UPDATED", S2[S2.METADATA_UPDATED = 11] = "METADATA_UPDATED", S2))(ct || {});
|
5669
5669
|
var ie = ((c) => (c[c.TRACK_ADDED = 0] = "TRACK_ADDED", c[c.TRACK_REMOVED = 1] = "TRACK_REMOVED", c[c.TRACK_MUTED = 2] = "TRACK_MUTED", c[c.TRACK_UNMUTED = 3] = "TRACK_UNMUTED", c[c.TRACK_DESCRIPTION_CHANGED = 4] = "TRACK_DESCRIPTION_CHANGED", c[c.TRACK_DEGRADED = 5] = "TRACK_DEGRADED", c[c.TRACK_RESTORED = 6] = "TRACK_RESTORED", c))(ie || {});
|
5670
5670
|
var zt = ((r) => (r[r.POLL_CREATED = 0] = "POLL_CREATED", r[r.POLL_STARTED = 1] = "POLL_STARTED", r[r.POLL_STOPPED = 2] = "POLL_STOPPED", r[r.POLL_STATS_UPDATED = 3] = "POLL_STATS_UPDATED", r))(zt || {});
|
5671
5671
|
var fe = ((r) => (r.NONE = "none", r.LOW = "low", r.MEDIUM = "medium", r.HIGH = "high", r))(fe || {});
|
@@ -5789,819 +5789,495 @@ var Ie = ((c) => (c.Disconnected = "Disconnected", c.Connecting = "Connecting",
|
|
5789
5789
|
var me = ((t) => (t[t.Publish = 0] = "Publish", t[t.Subscribe = 1] = "Subscribe", t))(me || {});
|
5790
5790
|
|
5791
5791
|
// ../hms-video-store/dist/index.js
|
5792
|
-
import { EventEmitter2 as
|
5793
|
-
var
|
5794
|
-
|
5795
|
-
};
|
5796
|
-
var require_package = __commonJS2({
|
5797
|
-
"package.json"(exports, module) {
|
5798
|
-
module.exports = {
|
5799
|
-
version: "0.10.10",
|
5800
|
-
license: "MIT",
|
5801
|
-
main: "dist/index.cjs.js",
|
5802
|
-
module: "dist/index.js",
|
5803
|
-
typings: "dist/index.d.ts",
|
5804
|
-
files: [
|
5805
|
-
"dist",
|
5806
|
-
"src"
|
5807
|
-
],
|
5808
|
-
engines: {
|
5809
|
-
node: ">=12"
|
5810
|
-
},
|
5811
|
-
exports: {
|
5812
|
-
".": {
|
5813
|
-
require: "./dist/index.cjs.js",
|
5814
|
-
import: "./dist/index.js",
|
5815
|
-
default: "./dist/index.js"
|
5816
|
-
}
|
5817
|
-
},
|
5818
|
-
scripts: {
|
5819
|
-
prestart: "rm -rf dist && yarn types:build",
|
5820
|
-
start: 'concurrently "yarn dev" "yarn types"',
|
5821
|
-
dev: "node ../../scripts/dev",
|
5822
|
-
"build:only": "node ../../scripts/build",
|
5823
|
-
build: "yarn build:only && yarn types:build",
|
5824
|
-
types: "tsc -w",
|
5825
|
-
"types:build": "tsc -p tsconfig.json",
|
5826
|
-
format: "prettier --write src/**/*.ts",
|
5827
|
-
test: "jest --maxWorkers=1",
|
5828
|
-
"test:watch": "jest --watch",
|
5829
|
-
"test:coverage": "jest --coverage",
|
5830
|
-
lint: "eslint -c ../../.eslintrc .",
|
5831
|
-
"lint:fix": "yarn lint --fix",
|
5832
|
-
prepare: "yarn build",
|
5833
|
-
size: "size-limit",
|
5834
|
-
analyze: "size-limit --why",
|
5835
|
-
docs: "rm -rf ./docs && typedoc && rm -f ./docs/README.md && mkdir ./docs/home &&mv ./docs/modules.md ./docs/home/content.md && node ../../scripts/docs-store && npx prettier --write './docs/**/*'"
|
5836
|
-
},
|
5837
|
-
name: "@100mslive/hms-video-store",
|
5838
|
-
author: "100ms",
|
5839
|
-
sideEffects: false,
|
5840
|
-
dependencies: {
|
5841
|
-
"@100mslive/hms-video": "0.9.10",
|
5842
|
-
eventemitter2: "^6.4.7",
|
5843
|
-
immer: "^9.0.6",
|
5844
|
-
reselect: "4.0.0",
|
5845
|
-
zustand: "3.5.7"
|
5846
|
-
},
|
5847
|
-
devDependencies: {
|
5848
|
-
"ts-node": "^10.4.0",
|
5849
|
-
tslib: "^2.2.0"
|
5850
|
-
},
|
5851
|
-
description: "This is an addon to the core sdk provided by 100ms. It abstracts away the intricacies of data management and provides a flux based reactive data store where data flows in only one direction.",
|
5852
|
-
repository: {
|
5853
|
-
type: "git",
|
5854
|
-
url: "git+https://github.com/100mslive/hms-video-store.git"
|
5855
|
-
},
|
5856
|
-
keywords: [
|
5857
|
-
"video",
|
5858
|
-
"webrtc",
|
5859
|
-
"conferencing",
|
5860
|
-
"100ms"
|
5861
|
-
],
|
5862
|
-
bugs: {
|
5863
|
-
url: "https://github.com/100mslive/hms-video-store/issues"
|
5864
|
-
},
|
5865
|
-
homepage: "https://github.com/100mslive/hms-video-store#readme"
|
5866
|
-
};
|
5867
|
-
}
|
5792
|
+
import { EventEmitter2 as ys } from "eventemitter2";
|
5793
|
+
var Ut = (s, e) => () => (e || s((e = { exports: {} }).exports, e), e.exports);
|
5794
|
+
var At = Ut((Vn, vs) => {
|
5795
|
+
vs.exports = { version: "0.10.10", license: "MIT", main: "dist/index.cjs.js", module: "dist/index.js", typings: "dist/index.d.ts", files: ["dist", "src"], engines: { node: ">=12" }, exports: { ".": { require: "./dist/index.cjs.js", import: "./dist/index.js", default: "./dist/index.js" } }, scripts: { prestart: "rm -rf dist && yarn types:build", start: 'concurrently "yarn dev" "yarn types"', dev: "node ../../scripts/dev", "build:only": "node ../../scripts/build", build: "yarn build:only && yarn types:build", types: "tsc -w", "types:build": "tsc -p tsconfig.json", format: "prettier --write src/**/*.ts", test: "jest --maxWorkers=1", "test:watch": "jest --watch", "test:coverage": "jest --coverage", lint: "eslint -c ../../.eslintrc .", "lint:fix": "yarn lint --fix", prepare: "yarn build", size: "size-limit", analyze: "size-limit --why", docs: "rm -rf ./docs && typedoc && rm -f ./docs/README.md && mkdir ./docs/home &&mv ./docs/modules.md ./docs/home/content.md && node ../../scripts/docs-store && npx prettier --write './docs/**/*'" }, name: "@100mslive/hms-video-store", author: "100ms", sideEffects: false, dependencies: { "@100mslive/hms-video": "0.9.10", eventemitter2: "^6.4.7", immer: "^9.0.6", reselect: "4.0.0", zustand: "3.5.7" }, devDependencies: { "ts-node": "^10.4.0", tslib: "^2.2.0" }, description: "This is an addon to the core sdk provided by 100ms. It abstracts away the intricacies of data management and provides a flux based reactive data store where data flows in only one direction.", repository: { type: "git", url: "git+https://github.com/100mslive/hms-video-store.git" }, keywords: ["video", "webrtc", "conferencing", "100ms"], bugs: { url: "https://github.com/100mslive/hms-video-store/issues" }, homepage: "https://github.com/100mslive/hms-video-store#readme" };
|
5868
5796
|
});
|
5869
|
-
var
|
5870
|
-
(
|
5871
|
-
|
5872
|
-
|
5873
|
-
|
5874
|
-
|
5875
|
-
|
5876
|
-
|
5877
|
-
|
5878
|
-
|
5879
|
-
|
5880
|
-
(function(HMSMessageType2) {
|
5881
|
-
HMSMessageType2["CHAT"] = "chat";
|
5882
|
-
})(HMSMessageType || (HMSMessageType = {}));
|
5883
|
-
var HMSNotificationSeverity;
|
5884
|
-
(function(HMSNotificationSeverity2) {
|
5885
|
-
HMSNotificationSeverity2["INFO"] = "info";
|
5886
|
-
HMSNotificationSeverity2["ERROR"] = "error";
|
5887
|
-
})(HMSNotificationSeverity || (HMSNotificationSeverity = {}));
|
5888
|
-
var HMSNotificationTypes;
|
5889
|
-
(function(HMSNotificationTypes2) {
|
5890
|
-
HMSNotificationTypes2["PEER_JOINED"] = "PEER_JOINED";
|
5891
|
-
HMSNotificationTypes2["PEER_LEFT"] = "PEER_LEFT";
|
5892
|
-
HMSNotificationTypes2["PEER_LIST"] = "PEER_LIST";
|
5893
|
-
HMSNotificationTypes2["NEW_MESSAGE"] = "NEW_MESSAGE";
|
5894
|
-
HMSNotificationTypes2["ERROR"] = "ERROR";
|
5895
|
-
HMSNotificationTypes2["RECONNECTING"] = "RECONNECTING";
|
5896
|
-
HMSNotificationTypes2["RECONNECTED"] = "RECONNECTED";
|
5897
|
-
HMSNotificationTypes2["TRACK_ADDED"] = "TRACK_ADDED";
|
5898
|
-
HMSNotificationTypes2["TRACK_REMOVED"] = "TRACK_REMOVED";
|
5899
|
-
HMSNotificationTypes2["TRACK_MUTED"] = "TRACK_MUTED";
|
5900
|
-
HMSNotificationTypes2["TRACK_UNMUTED"] = "TRACK_UNMUTED";
|
5901
|
-
HMSNotificationTypes2["TRACK_DEGRADED"] = "TRACK_DEGRADED";
|
5902
|
-
HMSNotificationTypes2["TRACK_RESTORED"] = "TRACK_RESTORED";
|
5903
|
-
HMSNotificationTypes2["TRACK_DESCRIPTION_CHANGED"] = "TRACK_DESCRIPTION_CHANGED";
|
5904
|
-
HMSNotificationTypes2["ROLE_UPDATED"] = "ROLE_UPDATED";
|
5905
|
-
HMSNotificationTypes2["CHANGE_TRACK_STATE_REQUEST"] = "CHANGE_TRACK_STATE_REQUEST";
|
5906
|
-
HMSNotificationTypes2["CHANGE_MULTI_TRACK_STATE_REQUEST"] = "CHANGE_MULTI_TRACK_STATE_REQUEST";
|
5907
|
-
HMSNotificationTypes2["ROOM_ENDED"] = "ROOM_ENDED";
|
5908
|
-
HMSNotificationTypes2["REMOVED_FROM_ROOM"] = "REMOVED_FROM_ROOM";
|
5909
|
-
HMSNotificationTypes2["DEVICE_CHANGE_UPDATE"] = "DEVICE_CHANGE_UPDATE";
|
5910
|
-
HMSNotificationTypes2["PLAYLIST_TRACK_ENDED"] = "PLAYLIST_TRACK_ENDED";
|
5911
|
-
HMSNotificationTypes2["NAME_UPDATED"] = "NAME_UPDATED";
|
5912
|
-
HMSNotificationTypes2["METADATA_UPDATED"] = "METADATA_UPDATED";
|
5913
|
-
HMSNotificationTypes2["POLL_CREATED"] = "POLL_CREATED";
|
5914
|
-
HMSNotificationTypes2["POLL_STARTED"] = "POLL_STARTED";
|
5915
|
-
HMSNotificationTypes2["POLL_STOPPED"] = "POLL_STOPPED";
|
5916
|
-
HMSNotificationTypes2["POLL_VOTES_UPDATED"] = "POLL_VOTES_UPDATED";
|
5917
|
-
})(HMSNotificationTypes || (HMSNotificationTypes = {}));
|
5918
|
-
var HMSPlaylistType;
|
5919
|
-
(function(HMSPlaylistType2) {
|
5920
|
-
HMSPlaylistType2["audio"] = "audio";
|
5921
|
-
HMSPlaylistType2["video"] = "video";
|
5922
|
-
})(HMSPlaylistType || (HMSPlaylistType = {}));
|
5923
|
-
function getScreenSharesByPeer(tracks, peer) {
|
5924
|
-
let videoTrack = void 0;
|
5925
|
-
let audioTrack = void 0;
|
5926
|
-
if (peer) {
|
5927
|
-
for (const trackID of peer.auxiliaryTracks) {
|
5928
|
-
const track = tracks[trackID];
|
5929
|
-
if (isScreenShare(track)) {
|
5930
|
-
audioTrack = isAudio(track) ? track : audioTrack;
|
5931
|
-
videoTrack = isVideo(track) ? track : videoTrack;
|
5932
|
-
}
|
5797
|
+
var Re = ((n2) => (n2.Disconnected = "Disconnected", n2.Preview = "Preview", n2.Connecting = "Connecting", n2.Connected = "Connected", n2.Reconnecting = "Reconnecting", n2.Disconnecting = "Disconnecting", n2.Failed = "Failed", n2))(Re || {});
|
5798
|
+
var Vt = ((e) => (e.CHAT = "chat", e))(Vt || {});
|
5799
|
+
var qe2 = ((t) => (t.INFO = "info", t.ERROR = "error", t))(qe2 || {});
|
5800
|
+
var De = ((M2) => (M2.PEER_JOINED = "PEER_JOINED", M2.PEER_LEFT = "PEER_LEFT", M2.PEER_LIST = "PEER_LIST", M2.NEW_MESSAGE = "NEW_MESSAGE", M2.ERROR = "ERROR", M2.RECONNECTING = "RECONNECTING", M2.RECONNECTED = "RECONNECTED", M2.TRACK_ADDED = "TRACK_ADDED", M2.TRACK_REMOVED = "TRACK_REMOVED", M2.TRACK_MUTED = "TRACK_MUTED", M2.TRACK_UNMUTED = "TRACK_UNMUTED", M2.TRACK_DEGRADED = "TRACK_DEGRADED", M2.TRACK_RESTORED = "TRACK_RESTORED", M2.TRACK_DESCRIPTION_CHANGED = "TRACK_DESCRIPTION_CHANGED", M2.ROLE_UPDATED = "ROLE_UPDATED", M2.CHANGE_TRACK_STATE_REQUEST = "CHANGE_TRACK_STATE_REQUEST", M2.CHANGE_MULTI_TRACK_STATE_REQUEST = "CHANGE_MULTI_TRACK_STATE_REQUEST", M2.ROOM_ENDED = "ROOM_ENDED", M2.REMOVED_FROM_ROOM = "REMOVED_FROM_ROOM", M2.DEVICE_CHANGE_UPDATE = "DEVICE_CHANGE_UPDATE", M2.PLAYLIST_TRACK_ENDED = "PLAYLIST_TRACK_ENDED", M2.NAME_UPDATED = "NAME_UPDATED", M2.METADATA_UPDATED = "METADATA_UPDATED", M2.POLL_CREATED = "POLL_CREATED", M2.POLL_STARTED = "POLL_STARTED", M2.POLL_STOPPED = "POLL_STOPPED", M2.POLL_VOTES_UPDATED = "POLL_VOTES_UPDATED", M2))(De || {});
|
5801
|
+
var je = ((t) => (t.audio = "audio", t.video = "video", t))(je || {});
|
5802
|
+
function j(s, e) {
|
5803
|
+
let t, i;
|
5804
|
+
if (e)
|
5805
|
+
for (let o2 of e.auxiliaryTracks) {
|
5806
|
+
let r = s[o2];
|
5807
|
+
Kt2(r) && (i = $(r) ? r : i, t = W(r) ? r : t);
|
5933
5808
|
}
|
5934
|
-
}
|
5935
|
-
return { video: videoTrack, audio: audioTrack };
|
5809
|
+
return { video: t, audio: i };
|
5936
5810
|
}
|
5937
|
-
function
|
5938
|
-
return
|
5811
|
+
function $(s) {
|
5812
|
+
return s && s.type === "audio";
|
5939
5813
|
}
|
5940
|
-
function
|
5941
|
-
return
|
5814
|
+
function W(s) {
|
5815
|
+
return s && s.type === "video";
|
5942
5816
|
}
|
5943
|
-
function
|
5944
|
-
return
|
5817
|
+
function Kt2(s) {
|
5818
|
+
return s && s.source === "screen";
|
5945
5819
|
}
|
5946
|
-
function
|
5947
|
-
return
|
5820
|
+
function ce2(s) {
|
5821
|
+
return s && s.source === "audioplaylist";
|
5948
5822
|
}
|
5949
|
-
function
|
5950
|
-
return
|
5823
|
+
function J2(s) {
|
5824
|
+
return s && s.source === "videoplaylist";
|
5951
5825
|
}
|
5952
|
-
function
|
5953
|
-
|
5954
|
-
return Boolean(track == null ? void 0 : track.degraded);
|
5955
|
-
}
|
5956
|
-
return false;
|
5826
|
+
function Ge(s) {
|
5827
|
+
return s ? !!(s != null && s.degraded) : false;
|
5957
5828
|
}
|
5958
|
-
function
|
5959
|
-
|
5960
|
-
return store.tracks[trackID].enabled;
|
5961
|
-
}
|
5962
|
-
return false;
|
5829
|
+
function Q(s, e) {
|
5830
|
+
return e && s.tracks[e] ? s.tracks[e].enabled : false;
|
5963
5831
|
}
|
5964
|
-
function
|
5965
|
-
var
|
5966
|
-
let
|
5967
|
-
|
5968
|
-
video = role.publishParams.allowed.includes("video");
|
5969
|
-
audio = role.publishParams.allowed.includes("audio");
|
5970
|
-
screen = role.publishParams.allowed.includes("screen");
|
5971
|
-
}
|
5972
|
-
return {
|
5973
|
-
video,
|
5974
|
-
audio,
|
5975
|
-
screen
|
5976
|
-
};
|
5832
|
+
function Y(s) {
|
5833
|
+
var o2;
|
5834
|
+
let e = false, t = false, i = false;
|
5835
|
+
return (o2 = s == null ? void 0 : s.publishParams) != null && o2.allowed && (e = s.publishParams.allowed.includes("video"), t = s.publishParams.allowed.includes("audio"), i = s.publishParams.allowed.includes("screen")), { video: e, audio: t, screen: i };
|
5977
5836
|
}
|
5978
|
-
var
|
5979
|
-
var
|
5980
|
-
var
|
5981
|
-
var
|
5982
|
-
var
|
5983
|
-
var
|
5984
|
-
var
|
5985
|
-
var
|
5986
|
-
var
|
5987
|
-
var
|
5988
|
-
|
5989
|
-
|
5990
|
-
var
|
5991
|
-
var
|
5992
|
-
|
5993
|
-
|
5994
|
-
|
5995
|
-
|
5996
|
-
|
5997
|
-
|
5998
|
-
var
|
5999
|
-
|
6000
|
-
|
6001
|
-
|
6002
|
-
return Object.values(storeTracks);
|
6003
|
-
});
|
6004
|
-
var selectLocalPeer = createSelector(selectRoom, selectPeersMap, (room, peers) => {
|
6005
|
-
return peers[room.localPeer];
|
6006
|
-
});
|
6007
|
-
var selectLocalPeerID4 = createSelector(selectRoom, (room) => {
|
6008
|
-
return room.localPeer;
|
5837
|
+
var P2 = (s) => s.room;
|
5838
|
+
var Bt = (s) => s.errors;
|
5839
|
+
var li = createSelector(Bt, (s) => s.length === 0 ? null : s.at(-1));
|
5840
|
+
var di = createSelector(P2, (s) => s.id);
|
5841
|
+
var k = (s) => s.peers;
|
5842
|
+
var Qe = (s) => s.messages.byID;
|
5843
|
+
var $e = (s) => s.messages.allIDs;
|
5844
|
+
var T = (s) => s.tracks;
|
5845
|
+
var ve2 = (s) => s.appData;
|
5846
|
+
var qt2 = (s) => s.speakers;
|
5847
|
+
var B = createSelector([P2], (s) => s && s.isConnected);
|
5848
|
+
var Mi = createSelector([B, P2], (s, e) => s ? e.peerCount !== void 0 ? e.peerCount || 1 : e.peers.length : Math.max(e.peerCount !== void 0 ? e.peerCount : e.peers.length - 1, 0));
|
5849
|
+
var w2 = createSelector([P2, k], (s, e) => s.peers.map((t) => e[t]));
|
5850
|
+
var jt2 = createSelector(T, (s) => Object.values(s));
|
5851
|
+
var v2 = createSelector(P2, k, (s, e) => e[s.localPeer]);
|
5852
|
+
var G = createSelector(P2, (s) => s.localPeer);
|
5853
|
+
var Ti2 = createSelector(v2, (s) => s == null ? void 0 : s.name);
|
5854
|
+
var Hi2 = createSelector(v2, (s) => s == null ? void 0 : s.roleName);
|
5855
|
+
var b = createSelector(v2, (s) => s == null ? void 0 : s.audioTrack);
|
5856
|
+
var I = createSelector(v2, (s) => s == null ? void 0 : s.videoTrack);
|
5857
|
+
var Gt = createSelector(v2, (s) => s == null ? void 0 : s.auxiliaryTracks);
|
5858
|
+
var Je = createSelector([b, I, Gt], (s, e, t) => {
|
5859
|
+
let i = t ? [...t] : [];
|
5860
|
+
return s && i.unshift(s), e && i.unshift(e), i;
|
6009
5861
|
});
|
6010
|
-
var
|
6011
|
-
var
|
6012
|
-
|
6013
|
-
var
|
6014
|
-
|
6015
|
-
|
6016
|
-
const trackIDs = auxiliaryTrackIDs ? [...auxiliaryTrackIDs] : [];
|
6017
|
-
audioTrackID && trackIDs.unshift(audioTrackID);
|
6018
|
-
videoTrackID && trackIDs.unshift(videoTrackID);
|
6019
|
-
return trackIDs;
|
6020
|
-
});
|
6021
|
-
var selectRemotePeers = createSelector(selectPeers, (peers) => {
|
6022
|
-
return peers.filter((p) => !p.isLocal);
|
6023
|
-
});
|
6024
|
-
var selectDominantSpeaker = createSelector(selectPeersMap, selectSpeakers, (peersMap, speakers) => {
|
6025
|
-
const speakersInOrder = Object.entries(speakers).sort((s1, s2) => {
|
6026
|
-
var _a, _b;
|
6027
|
-
const s1Level = ((_a = s1[1]) == null ? void 0 : _a.audioLevel) || 0;
|
6028
|
-
const s2Level = ((_b = s2[1]) == null ? void 0 : _b.audioLevel) || 0;
|
6029
|
-
return s2Level > s1Level ? 1 : -1;
|
5862
|
+
var fi2 = createSelector(w2, (s) => s.filter((e) => !e.isLocal));
|
5863
|
+
var mi = createSelector(k, qt2, (s, e) => {
|
5864
|
+
let t = Object.entries(e).sort((i, o2) => {
|
5865
|
+
var n2, l;
|
5866
|
+
let r = ((n2 = i[1]) == null ? void 0 : n2.audioLevel) || 0;
|
5867
|
+
return (((l = o2[1]) == null ? void 0 : l.audioLevel) || 0) > r ? 1 : -1;
|
6030
5868
|
});
|
6031
|
-
if (
|
6032
|
-
|
6033
|
-
if (
|
6034
|
-
return
|
6035
|
-
}
|
5869
|
+
if (t.length > 0 && t[0][1].audioLevel && t[0][1].audioLevel > 0) {
|
5870
|
+
let i = t[0][1].peerID;
|
5871
|
+
if (i in s)
|
5872
|
+
return s[i];
|
6036
5873
|
}
|
6037
5874
|
return null;
|
6038
5875
|
});
|
6039
|
-
var
|
6040
|
-
|
6041
|
-
return !!(
|
5876
|
+
var Ee = createSelector(v2, T, (s, e) => {
|
5877
|
+
let { video: t, audio: i } = j(e, s);
|
5878
|
+
return !!(t || i);
|
6042
5879
|
});
|
6043
|
-
var
|
6044
|
-
let
|
6045
|
-
for (
|
6046
|
-
|
6047
|
-
|
6048
|
-
|
6049
|
-
|
6050
|
-
} else if (audio && !screensharePeer) {
|
6051
|
-
screensharePeer = peer;
|
6052
|
-
}
|
5880
|
+
var Ft = createSelector(k, T, (s, e) => {
|
5881
|
+
let t;
|
5882
|
+
for (let i in s) {
|
5883
|
+
let o2 = s[i], { video: r, audio: a } = j(e, o2);
|
5884
|
+
if (r)
|
5885
|
+
return o2;
|
5886
|
+
a && !t && (t = o2);
|
6053
5887
|
}
|
6054
|
-
return
|
6055
|
-
});
|
6056
|
-
var selectIsSomeoneScreenSharing = createSelector(selectPeerScreenSharing, (peer) => {
|
6057
|
-
return !!peer;
|
5888
|
+
return t;
|
6058
5889
|
});
|
6059
|
-
var
|
6060
|
-
|
6061
|
-
|
6062
|
-
|
6063
|
-
if (!
|
6064
|
-
return
|
6065
|
-
}
|
5890
|
+
var gi = createSelector(Ft, (s) => !!s);
|
5891
|
+
var hi = createSelector(k, T, (s, e) => {
|
5892
|
+
for (let t in s) {
|
5893
|
+
let i = s[t], { audio: o2, video: r } = j(e, i);
|
5894
|
+
if (!r && o2)
|
5895
|
+
return i;
|
6066
5896
|
}
|
6067
|
-
return void 0;
|
6068
5897
|
});
|
6069
|
-
var
|
6070
|
-
|
6071
|
-
|
6072
|
-
|
6073
|
-
|
6074
|
-
const { video, audio } = getScreenSharesByPeer(tracksMap, peer);
|
6075
|
-
if (video) {
|
6076
|
-
videoPeers.push(peer);
|
6077
|
-
} else if (audio) {
|
6078
|
-
audioPeers.push(peer);
|
6079
|
-
}
|
5898
|
+
var Pi2 = createSelector(k, T, (s, e) => {
|
5899
|
+
let t = [], i = [];
|
5900
|
+
for (let o2 in s) {
|
5901
|
+
let r = s[o2], { video: a, audio: n2 } = j(e, r);
|
5902
|
+
a ? t.push(r) : n2 && i.push(r);
|
6080
5903
|
}
|
6081
|
-
return
|
5904
|
+
return t.concat(i);
|
6082
5905
|
});
|
6083
|
-
var
|
6084
|
-
for (
|
6085
|
-
|
6086
|
-
if (
|
6087
|
-
return
|
6088
|
-
}
|
5906
|
+
var ki2 = createSelector(k, T, (s, e) => {
|
5907
|
+
for (let t in e) {
|
5908
|
+
let i = e[t];
|
5909
|
+
if (J2(i) && W(i) && i.peerId)
|
5910
|
+
return s[i.peerId];
|
6089
5911
|
}
|
6090
|
-
return void 0;
|
6091
5912
|
});
|
6092
|
-
var
|
6093
|
-
for (
|
6094
|
-
|
6095
|
-
if (
|
6096
|
-
return
|
6097
|
-
}
|
5913
|
+
var Ri = createSelector(k, T, (s, e) => {
|
5914
|
+
for (let t in e) {
|
5915
|
+
let i = e[t];
|
5916
|
+
if (ce2(i) && i.peerId)
|
5917
|
+
return s[i.peerId];
|
6098
5918
|
}
|
6099
|
-
return void 0;
|
6100
5919
|
});
|
6101
|
-
var
|
6102
|
-
var
|
6103
|
-
var
|
6104
|
-
|
6105
|
-
|
6106
|
-
|
6107
|
-
|
6108
|
-
|
6109
|
-
messages.push(msgMap[msgId]);
|
6110
|
-
});
|
6111
|
-
return messages;
|
5920
|
+
var Di2 = createSelector(jt2, (s) => s.filter(Ge));
|
5921
|
+
var vi = createSelector($e, (s) => s.length);
|
5922
|
+
var Ii2 = createSelector(Qe, (s) => Object.values(s).filter((e) => !e.read).length);
|
5923
|
+
var Se2 = createSelector($e, Qe, (s, e) => {
|
5924
|
+
let t = [];
|
5925
|
+
return s.forEach((i) => {
|
5926
|
+
t.push(e[i]);
|
5927
|
+
}), t;
|
6112
5928
|
});
|
6113
|
-
var
|
6114
|
-
var
|
6115
|
-
var
|
6116
|
-
var
|
6117
|
-
|
5929
|
+
var E2 = createSelector([P2], (s) => s && s.roomState);
|
5930
|
+
var Ei2 = createSelector(E2, (s) => s === "Preview");
|
5931
|
+
var bi2 = createSelector(P2, (s) => s.roomState !== "Disconnected");
|
5932
|
+
var _2 = (s) => s.roles;
|
5933
|
+
var Ai2 = createSelector([_2], (s) => Object.keys(s));
|
5934
|
+
var le2 = createSelector([v2, _2], (s, e) => s != null && s.roleName ? e[s.roleName] : null);
|
5935
|
+
var Qt = (s) => {
|
5936
|
+
var e;
|
5937
|
+
return (e = s.preview) == null ? void 0 : e.asRole;
|
6118
5938
|
};
|
6119
|
-
var
|
6120
|
-
var
|
6121
|
-
var
|
6122
|
-
|
6123
|
-
return (_a = store.preview) == null ? void 0 : _a.asRole;
|
6124
|
-
};
|
6125
|
-
var selectPreviewRole = createSelector([selectPreviewRoleName, selectRolesMap], (roleName, rolesMap) => roleName ? rolesMap[roleName] : null);
|
6126
|
-
var selectIsAllowedToSubscribe = createSelector([selectLocalPeerRole], (role) => {
|
6127
|
-
var _a;
|
6128
|
-
if (!((_a = role == null ? void 0 : role.subscribeParams) == null ? void 0 : _a.subscribeToRoles)) {
|
6129
|
-
return false;
|
6130
|
-
}
|
6131
|
-
return role.subscribeParams.subscribeToRoles.length > 0;
|
5939
|
+
var ze = createSelector([Qt, _2], (s, e) => s ? e[s] : null);
|
5940
|
+
var Ci2 = createSelector([le2], (s) => {
|
5941
|
+
var e;
|
5942
|
+
return (e = s == null ? void 0 : s.subscribeParams) != null && e.subscribeToRoles ? s.subscribeParams.subscribeToRoles.length > 0 : false;
|
6132
5943
|
});
|
6133
|
-
var
|
6134
|
-
var
|
6135
|
-
var
|
6136
|
-
var
|
6137
|
-
var
|
6138
|
-
var
|
6139
|
-
var
|
6140
|
-
var
|
6141
|
-
var
|
6142
|
-
var
|
6143
|
-
var
|
6144
|
-
var
|
6145
|
-
var
|
6146
|
-
var
|
6147
|
-
|
5944
|
+
var Xe = createSelector(le2, (s) => s == null ? void 0 : s.permissions);
|
5945
|
+
var Ni2 = createSelector(P2, (s) => s.recording);
|
5946
|
+
var Li = createSelector(P2, (s) => s.rtmp);
|
5947
|
+
var xi = createSelector(P2, (s) => s.hls);
|
5948
|
+
var Oi2 = createSelector(P2, (s) => s.sessionId);
|
5949
|
+
var _i2 = createSelector(P2, (s) => s.startedAt);
|
5950
|
+
var Ze2 = (s) => s.polls;
|
5951
|
+
var tt = (s = "audio") => (e) => e.playlist[s].list;
|
5952
|
+
var be = (s = "audio") => (e) => e.playlist[s].selection;
|
5953
|
+
var st = (s = "audio") => (e) => e.playlist[s].progress;
|
5954
|
+
var it2 = (s = "audio") => (e) => e.playlist[s].currentTime;
|
5955
|
+
var ot = (s = "audio") => (e) => e.playlist[s].playbackRate;
|
5956
|
+
var rt = (s = "audio") => (e) => e.playlist[s].volume;
|
5957
|
+
var at = (s = "audio") => createSelector(tt(s), (e) => Object.values(e));
|
5958
|
+
var nt2 = (s = "audio") => createSelector(tt(s), be(s), (e, t) => {
|
5959
|
+
if (t.id)
|
5960
|
+
return e[t.id];
|
6148
5961
|
});
|
6149
|
-
var
|
6150
|
-
|
6151
|
-
|
6152
|
-
|
6153
|
-
return storePlaylist[currentSelection.id];
|
6154
|
-
});
|
6155
|
-
var selectAudioPlaylist = {
|
6156
|
-
selection: selectPlaylistSelection(HMSPlaylistType.audio),
|
6157
|
-
progress: selectPlaylistProgress(HMSPlaylistType.audio),
|
6158
|
-
currentTime: selectPlaylistCurrentTime(HMSPlaylistType.audio),
|
6159
|
-
playbackRate: selectPlaylistPlaybackRate(HMSPlaylistType.audio),
|
6160
|
-
volume: selectPlaylistVolume(HMSPlaylistType.audio),
|
6161
|
-
list: selectPlaylist(HMSPlaylistType.audio),
|
6162
|
-
selectedItem: selectPlaylistSelectedItem(HMSPlaylistType.audio)
|
6163
|
-
};
|
6164
|
-
var selectVideoPlaylist = {
|
6165
|
-
selection: selectPlaylistSelection(HMSPlaylistType.video),
|
6166
|
-
progress: selectPlaylistProgress(HMSPlaylistType.video),
|
6167
|
-
currentTime: selectPlaylistCurrentTime(HMSPlaylistType.video),
|
6168
|
-
playbackRate: selectPlaylistPlaybackRate(HMSPlaylistType.video),
|
6169
|
-
volume: selectPlaylistVolume(HMSPlaylistType.video),
|
6170
|
-
list: selectPlaylist(HMSPlaylistType.video),
|
6171
|
-
selectedItem: selectPlaylistSelectedItem(HMSPlaylistType.video)
|
6172
|
-
};
|
6173
|
-
function byIDCurry(selector) {
|
6174
|
-
return (id) => {
|
6175
|
-
return (store) => selector(store, id);
|
6176
|
-
};
|
5962
|
+
var ct2 = { selection: be("audio"), progress: st("audio"), currentTime: it2("audio"), playbackRate: ot("audio"), volume: rt("audio"), list: at("audio"), selectedItem: nt2("audio") };
|
5963
|
+
var St = { selection: be("video"), progress: st("video"), currentTime: it2("video"), playbackRate: ot("video"), volume: rt("video"), list: at("video"), selectedItem: nt2("video") };
|
5964
|
+
function u(s) {
|
5965
|
+
return (e) => (t) => s(t, e);
|
6177
5966
|
}
|
6178
|
-
var
|
6179
|
-
var
|
6180
|
-
static v(
|
6181
|
-
this.log(Pr.VERBOSE,
|
5967
|
+
var X = "HMS-Store:";
|
5968
|
+
var S = class {
|
5969
|
+
static v(e, ...t) {
|
5970
|
+
this.log(Pr.VERBOSE, e, ...t);
|
6182
5971
|
}
|
6183
|
-
static d(...
|
6184
|
-
this.log(Pr.DEBUG, ...
|
5972
|
+
static d(...e) {
|
5973
|
+
this.log(Pr.DEBUG, ...e);
|
6185
5974
|
}
|
6186
|
-
static i(...
|
6187
|
-
this.log(Pr.INFO, ...
|
5975
|
+
static i(...e) {
|
5976
|
+
this.log(Pr.INFO, ...e);
|
6188
5977
|
}
|
6189
|
-
static w(...
|
6190
|
-
this.log(Pr.WARN, ...
|
5978
|
+
static w(...e) {
|
5979
|
+
this.log(Pr.WARN, ...e);
|
6191
5980
|
}
|
6192
|
-
static e(...
|
6193
|
-
this.log(Pr.ERROR, ...
|
5981
|
+
static e(...e) {
|
5982
|
+
this.log(Pr.ERROR, ...e);
|
6194
5983
|
}
|
6195
|
-
static time(
|
6196
|
-
this.log(Pr.TIME, "[HMSPerformanceTiming]",
|
5984
|
+
static time(e) {
|
5985
|
+
this.log(Pr.TIME, "[HMSPerformanceTiming]", e);
|
6197
5986
|
}
|
6198
|
-
static timeEnd(
|
6199
|
-
this.log(Pr.TIMEEND, "[HMSPerformanceTiming]",
|
5987
|
+
static timeEnd(e) {
|
5988
|
+
this.log(Pr.TIMEEND, "[HMSPerformanceTiming]", e, e);
|
6200
5989
|
}
|
6201
5990
|
static cleanup() {
|
6202
|
-
performance.clearMarks();
|
6203
|
-
performance.clearMeasures();
|
5991
|
+
performance.clearMarks(), performance.clearMeasures();
|
6204
5992
|
}
|
6205
|
-
static log(
|
6206
|
-
if (this.level.valueOf() >
|
6207
|
-
|
6208
|
-
|
6209
|
-
|
6210
|
-
|
6211
|
-
|
6212
|
-
|
6213
|
-
|
6214
|
-
|
6215
|
-
|
6216
|
-
|
6217
|
-
|
6218
|
-
|
6219
|
-
|
6220
|
-
|
6221
|
-
|
6222
|
-
|
6223
|
-
|
6224
|
-
|
6225
|
-
|
6226
|
-
|
6227
|
-
|
6228
|
-
|
6229
|
-
|
6230
|
-
|
6231
|
-
|
6232
|
-
|
6233
|
-
|
6234
|
-
|
6235
|
-
|
6236
|
-
|
6237
|
-
|
6238
|
-
|
6239
|
-
|
6240
|
-
|
6241
|
-
performance.clearMeasures(mark);
|
6242
|
-
} catch (error) {
|
6243
|
-
this.log(Pr.DEBUG, tag, mark, error);
|
5993
|
+
static log(e, ...t) {
|
5994
|
+
if (!(this.level.valueOf() > e.valueOf()))
|
5995
|
+
switch (e) {
|
5996
|
+
case Pr.VERBOSE: {
|
5997
|
+
console.log(X, ...t);
|
5998
|
+
break;
|
5999
|
+
}
|
6000
|
+
case Pr.DEBUG: {
|
6001
|
+
console.debug(X, ...t);
|
6002
|
+
break;
|
6003
|
+
}
|
6004
|
+
case Pr.INFO: {
|
6005
|
+
console.info(X, ...t);
|
6006
|
+
break;
|
6007
|
+
}
|
6008
|
+
case Pr.WARN: {
|
6009
|
+
console.warn(X, ...t);
|
6010
|
+
break;
|
6011
|
+
}
|
6012
|
+
case Pr.ERROR: {
|
6013
|
+
console.error(X, ...t);
|
6014
|
+
break;
|
6015
|
+
}
|
6016
|
+
case Pr.TIME: {
|
6017
|
+
performance.mark(t[1]);
|
6018
|
+
break;
|
6019
|
+
}
|
6020
|
+
case Pr.TIMEEND: {
|
6021
|
+
let i = t[0], o2 = t[1];
|
6022
|
+
try {
|
6023
|
+
let r = performance.measure(o2, o2);
|
6024
|
+
this.log(Pr.DEBUG, i, o2, r == null ? void 0 : r.duration), performance.clearMarks(o2), performance.clearMeasures(o2);
|
6025
|
+
} catch (r) {
|
6026
|
+
this.log(Pr.DEBUG, i, o2, r);
|
6027
|
+
}
|
6028
|
+
break;
|
6244
6029
|
}
|
6245
|
-
break;
|
6246
6030
|
}
|
6247
|
-
}
|
6248
6031
|
}
|
6249
6032
|
};
|
6250
|
-
|
6251
|
-
var
|
6252
|
-
var
|
6253
|
-
var
|
6254
|
-
var
|
6255
|
-
var
|
6256
|
-
var
|
6257
|
-
var
|
6258
|
-
var
|
6259
|
-
if (!
|
6033
|
+
S.level = Pr.VERBOSE;
|
6034
|
+
var Ae = (s, e) => e;
|
6035
|
+
var Z = (s, e) => e;
|
6036
|
+
var dt = (s, e) => e;
|
6037
|
+
var Xt2 = (s, e) => e;
|
6038
|
+
var Zt2 = (s, e) => e;
|
6039
|
+
var D = createSelector([k, Ae], (s, e) => e ? s[e] : null);
|
6040
|
+
var Ce = createSelector([T, Z], (s, e) => e ? s[e] : null);
|
6041
|
+
var es = createSelector([T, Z], (s, e) => {
|
6042
|
+
if (!e)
|
6260
6043
|
return null;
|
6261
|
-
|
6262
|
-
|
6263
|
-
if ((track == null ? void 0 : track.type) === "video") {
|
6264
|
-
return track;
|
6265
|
-
}
|
6266
|
-
return null;
|
6044
|
+
let t = s[e];
|
6045
|
+
return (t == null ? void 0 : t.type) === "video" ? t : null;
|
6267
6046
|
});
|
6268
|
-
var
|
6269
|
-
if (!
|
6047
|
+
var ts = createSelector([T, Z], (s, e) => {
|
6048
|
+
if (!e)
|
6270
6049
|
return null;
|
6271
|
-
|
6272
|
-
|
6273
|
-
if ((track == null ? void 0 : track.type) === "audio") {
|
6274
|
-
return track;
|
6275
|
-
}
|
6276
|
-
return null;
|
6050
|
+
let t = s[e];
|
6051
|
+
return (t == null ? void 0 : t.type) === "audio" ? t : null;
|
6277
6052
|
});
|
6278
|
-
var
|
6279
|
-
if (!
|
6053
|
+
var ss = createSelector([T, Z], (s, e) => {
|
6054
|
+
if (!e)
|
6280
6055
|
return null;
|
6281
|
-
|
6282
|
-
|
6283
|
-
if ((track == null ? void 0 : track.type) === "audio" && (track == null ? void 0 : track.source) === "screen") {
|
6284
|
-
return track;
|
6285
|
-
}
|
6286
|
-
return null;
|
6056
|
+
let t = s[e];
|
6057
|
+
return (t == null ? void 0 : t.type) === "audio" && (t == null ? void 0 : t.source) === "screen" ? t : null;
|
6287
6058
|
});
|
6288
|
-
var
|
6289
|
-
if (!
|
6059
|
+
var is2 = createSelector([T, Z], (s, e) => {
|
6060
|
+
if (!e)
|
6290
6061
|
return null;
|
6291
|
-
|
6292
|
-
|
6293
|
-
if ((track == null ? void 0 : track.type) === "video" && (track == null ? void 0 : track.source) === "screen") {
|
6294
|
-
return track;
|
6295
|
-
}
|
6296
|
-
return null;
|
6062
|
+
let t = s[e];
|
6063
|
+
return (t == null ? void 0 : t.type) === "video" && (t == null ? void 0 : t.source) === "screen" ? t : null;
|
6297
6064
|
});
|
6298
|
-
var
|
6299
|
-
var
|
6300
|
-
var
|
6301
|
-
if (
|
6302
|
-
return
|
6303
|
-
}
|
6304
|
-
if (key) {
|
6305
|
-
return appData[key];
|
6306
|
-
}
|
6307
|
-
return appData;
|
6065
|
+
var os = createSelector([Ze2, Zt2], (s, e) => e ? s[e] : null);
|
6066
|
+
var C = u(D);
|
6067
|
+
var Wo = u(createSelector([ve2, Xt2], (s, e) => {
|
6068
|
+
if (s)
|
6069
|
+
return e ? s[e] : s;
|
6308
6070
|
}));
|
6309
|
-
var
|
6310
|
-
var
|
6311
|
-
var
|
6312
|
-
var
|
6313
|
-
var
|
6314
|
-
var
|
6315
|
-
var
|
6316
|
-
|
6317
|
-
if (
|
6318
|
-
return
|
6319
|
-
}
|
6320
|
-
return void 0;
|
6071
|
+
var zo = u(createSelector(D, (s) => s == null ? void 0 : s.name));
|
6072
|
+
var ue = u(Ce);
|
6073
|
+
var ut = u(es);
|
6074
|
+
var Xo = u(ts);
|
6075
|
+
var Zo = u(ss);
|
6076
|
+
var er = u(is2);
|
6077
|
+
var rs2 = u((s, e) => {
|
6078
|
+
let t = D(s, e);
|
6079
|
+
if (t && t.videoTrack && t.videoTrack !== "")
|
6080
|
+
return s.tracks[t.videoTrack];
|
6321
6081
|
});
|
6322
|
-
var
|
6323
|
-
|
6324
|
-
if (
|
6325
|
-
return
|
6326
|
-
}
|
6327
|
-
return void 0;
|
6082
|
+
var as = u((s, e) => {
|
6083
|
+
let t = D(s, e);
|
6084
|
+
if (t && t.audioTrack && t.audioTrack !== "")
|
6085
|
+
return s.tracks[t.audioTrack];
|
6328
6086
|
});
|
6329
|
-
var
|
6330
|
-
|
6331
|
-
return (
|
6087
|
+
var sr = u((s, e) => {
|
6088
|
+
let t = D(s, e);
|
6089
|
+
return (t == null ? void 0 : t.auxiliaryTracks.map((i) => s.tracks[i])) || [];
|
6332
6090
|
});
|
6333
|
-
var
|
6334
|
-
|
6335
|
-
|
6336
|
-
|
6337
|
-
|
6338
|
-
const peerAudioTrack = selectAudioTrackByPeerID2(peerID)(store);
|
6339
|
-
return selectSpeakerByTrackID(store, peerAudioTrack == null ? void 0 : peerAudioTrack.id);
|
6091
|
+
var pt = (s, e) => e ? s.speakers[e] : null;
|
6092
|
+
var ir = u(createSelector(pt, (s) => (s == null ? void 0 : s.audioLevel) || 0));
|
6093
|
+
var ns = (s, e) => {
|
6094
|
+
let t = as(e)(s);
|
6095
|
+
return pt(s, t == null ? void 0 : t.id);
|
6340
6096
|
};
|
6341
|
-
var
|
6342
|
-
var
|
6343
|
-
if (
|
6344
|
-
return
|
6345
|
-
}
|
6346
|
-
return void 0;
|
6097
|
+
var or = u(createSelector(ns, (s) => (s == null ? void 0 : s.audioLevel) || 0));
|
6098
|
+
var rr = u((s, e) => {
|
6099
|
+
if (e)
|
6100
|
+
return s.connectionQualities[e];
|
6347
6101
|
});
|
6348
|
-
var
|
6349
|
-
|
6350
|
-
if (
|
6351
|
-
|
6352
|
-
return
|
6102
|
+
var ar = u((s, e) => {
|
6103
|
+
let t = D(s, e);
|
6104
|
+
if (t) {
|
6105
|
+
let i = t == null ? void 0 : t.auxiliaryTracks.find((o2) => $(s.tracks[o2]));
|
6106
|
+
return i ? s.tracks[i] : void 0;
|
6353
6107
|
}
|
6354
|
-
return void 0;
|
6355
6108
|
});
|
6356
|
-
var
|
6357
|
-
|
6358
|
-
|
6359
|
-
return
|
6109
|
+
var nr = u(createSelector(T, D, (s, e) => {
|
6110
|
+
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
6111
|
+
let o2 = s[i];
|
6112
|
+
return J2(o2) && W(o2);
|
6360
6113
|
});
|
6361
|
-
return
|
6114
|
+
return t ? s[t] : void 0;
|
6362
6115
|
}));
|
6363
|
-
var
|
6364
|
-
|
6365
|
-
|
6366
|
-
return
|
6116
|
+
var cr2 = u(createSelector(T, D, (s, e) => {
|
6117
|
+
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
6118
|
+
let o2 = s[i];
|
6119
|
+
return J2(o2) && $(o2);
|
6367
6120
|
});
|
6368
|
-
return
|
6121
|
+
return t ? s[t] : void 0;
|
6369
6122
|
}));
|
6370
|
-
var
|
6371
|
-
|
6372
|
-
|
6373
|
-
return
|
6123
|
+
var Sr2 = u(createSelector(T, D, (s, e) => {
|
6124
|
+
let t = e == null ? void 0 : e.auxiliaryTracks.find((i) => {
|
6125
|
+
let o2 = s[i];
|
6126
|
+
return ce2(o2) && $(o2);
|
6374
6127
|
});
|
6375
|
-
return
|
6376
|
-
}));
|
6377
|
-
var selectScreenSharesByPeerId = byIDCurry(createSelector(selectTracksMap, selectPeerByIDBare, (tracks, peer) => {
|
6378
|
-
return getScreenSharesByPeer(tracks, peer);
|
6128
|
+
return t ? s[t] : void 0;
|
6379
6129
|
}));
|
6380
|
-
var
|
6381
|
-
|
6130
|
+
var Mt = u(createSelector(T, D, (s, e) => j(s, e)));
|
6131
|
+
var Tt = (s) => createSelector(Mt(s), (e) => e.audio);
|
6132
|
+
var dr2 = u((s, e) => {
|
6133
|
+
let t = D(s, e);
|
6134
|
+
return Q(s, t == null ? void 0 : t.audioTrack);
|
6382
6135
|
});
|
6383
|
-
var
|
6384
|
-
|
6385
|
-
return
|
6136
|
+
var ur2 = u((s, e) => {
|
6137
|
+
let t = D(s, e);
|
6138
|
+
return Q(s, t == null ? void 0 : t.videoTrack);
|
6386
6139
|
});
|
6387
|
-
var
|
6388
|
-
|
6389
|
-
|
6140
|
+
var Ht = u((s, e) => {
|
6141
|
+
if (e && s.tracks[e])
|
6142
|
+
return s.tracks[e].volume === 0;
|
6390
6143
|
});
|
6391
|
-
var
|
6392
|
-
|
6393
|
-
|
6394
|
-
}
|
6395
|
-
return void 0;
|
6144
|
+
var pr = u((s, e) => {
|
6145
|
+
let t = D(s, e);
|
6146
|
+
return Ht(t == null ? void 0 : t.audioTrack)(s);
|
6396
6147
|
});
|
6397
|
-
var
|
6398
|
-
|
6399
|
-
return
|
6148
|
+
var Mr2 = u((s, e) => {
|
6149
|
+
let t = Tt(e)(s);
|
6150
|
+
return Ht(t == null ? void 0 : t.id)(s);
|
6400
6151
|
});
|
6401
|
-
var
|
6402
|
-
|
6403
|
-
|
6404
|
-
|
6405
|
-
|
6406
|
-
|
6407
|
-
if (track) {
|
6408
|
-
if (track.type !== "audio") {
|
6409
|
-
HMSLogger.w("Please pass audio track here");
|
6410
|
-
return void 0;
|
6152
|
+
var ft = u((s, e) => {
|
6153
|
+
let t = Ce(s, e);
|
6154
|
+
if (t) {
|
6155
|
+
if (t.type !== "audio") {
|
6156
|
+
S.w("Please pass audio track here");
|
6157
|
+
return;
|
6411
6158
|
}
|
6412
|
-
return
|
6159
|
+
return t.volume;
|
6413
6160
|
}
|
6414
|
-
return void 0;
|
6415
|
-
});
|
6416
|
-
var selectAudioVolumeByPeerID = byIDCurry((store, peerID) => {
|
6417
|
-
const peer = selectPeerByIDBare(store, peerID);
|
6418
|
-
return selectAudioTrackVolume(peer == null ? void 0 : peer.audioTrack)(store);
|
6419
6161
|
});
|
6420
|
-
var
|
6421
|
-
|
6422
|
-
return
|
6423
|
-
});
|
6424
|
-
var selectSimulcastLayerByTrack = byIDCurry((store, trackID) => {
|
6425
|
-
const track = selectTrackByIDBare(store, trackID);
|
6426
|
-
if (track) {
|
6427
|
-
if (track.type !== "video") {
|
6428
|
-
HMSLogger.w("Please pass video track here");
|
6429
|
-
return void 0;
|
6430
|
-
}
|
6431
|
-
return track.layer;
|
6432
|
-
}
|
6433
|
-
return void 0;
|
6162
|
+
var Tr = u((s, e) => {
|
6163
|
+
let t = D(s, e);
|
6164
|
+
return ft(t == null ? void 0 : t.audioTrack)(s);
|
6434
6165
|
});
|
6435
|
-
var
|
6436
|
-
|
6437
|
-
|
6438
|
-
}
|
6439
|
-
return messages.filter((message) => {
|
6440
|
-
var _a;
|
6441
|
-
if (!message.recipientPeer && !((_a = message.recipientRoles) == null ? void 0 : _a.length)) {
|
6442
|
-
return false;
|
6443
|
-
}
|
6444
|
-
if (message.sender && ![localPeerID, peerID].includes(message.sender)) {
|
6445
|
-
return false;
|
6446
|
-
}
|
6447
|
-
return [localPeerID, peerID].includes(message.recipientPeer);
|
6448
|
-
});
|
6166
|
+
var Hr = u((s, e) => {
|
6167
|
+
let t = Tt(e)(s);
|
6168
|
+
return ft(t == null ? void 0 : t.id)(s);
|
6449
6169
|
});
|
6450
|
-
var
|
6451
|
-
|
6452
|
-
|
6453
|
-
|
6454
|
-
|
6455
|
-
|
6456
|
-
if (!((_a = message.recipientRoles) == null ? void 0 : _a.length)) {
|
6457
|
-
return false;
|
6170
|
+
var fr2 = u((s, e) => {
|
6171
|
+
let t = Ce(s, e);
|
6172
|
+
if (t) {
|
6173
|
+
if (t.type !== "video") {
|
6174
|
+
S.w("Please pass video track here");
|
6175
|
+
return;
|
6458
6176
|
}
|
6459
|
-
return
|
6460
|
-
});
|
6461
|
-
});
|
6462
|
-
var selectBroadcastMessages = createSelector(selectHMSMessages, (messages) => {
|
6463
|
-
return messages.filter((message) => {
|
6464
|
-
var _a;
|
6465
|
-
return !message.recipientPeer && !((_a = message.recipientRoles) == null ? void 0 : _a.length);
|
6466
|
-
});
|
6467
|
-
});
|
6468
|
-
var selectUnreadMessageCountByRole = createSelector([selectMessagesByRoleInternal, selectRoleName], (messages) => {
|
6469
|
-
if (!messages) {
|
6470
|
-
return 0;
|
6471
|
-
}
|
6472
|
-
return messages.filter((m) => !m.read).length;
|
6473
|
-
});
|
6474
|
-
var selectUnreadMessageCountByPeerID = createSelector([selectMessagesByPeerIDInternal, selectPeerID], (messages) => {
|
6475
|
-
if (!messages) {
|
6476
|
-
return 0;
|
6177
|
+
return t.layer;
|
6477
6178
|
}
|
6478
|
-
return messages.filter((m) => !m.read).length;
|
6479
|
-
});
|
6480
|
-
var selectBroadcastMessagesUnreadCount = createSelector(selectBroadcastMessages, (messages) => {
|
6481
|
-
return messages.filter((m) => !m.read).length;
|
6482
6179
|
});
|
6483
|
-
var
|
6484
|
-
|
6485
|
-
|
6486
|
-
var
|
6487
|
-
|
6488
|
-
|
6489
|
-
const participants = Object.values(peersMap).map((peer) => {
|
6490
|
-
var _a;
|
6491
|
-
return {
|
6492
|
-
peer,
|
6493
|
-
isAudioEnabled: peer.audioTrack ? (_a = tracksMap[peer.audioTrack]) == null ? void 0 : _a.enabled : false
|
6494
|
-
};
|
6495
|
-
});
|
6496
|
-
return participants;
|
6180
|
+
var mt = createSelector([Se2, G, Ae], (s, e, t) => {
|
6181
|
+
if (t)
|
6182
|
+
return s.filter((i) => {
|
6183
|
+
var o2;
|
6184
|
+
return !i.recipientPeer && !((o2 = i.recipientRoles) != null && o2.length) || i.sender && ![e, t].includes(i.sender) ? false : [e, t].includes(i.recipientPeer);
|
6185
|
+
});
|
6497
6186
|
});
|
6498
|
-
var
|
6499
|
-
|
6500
|
-
|
6501
|
-
var
|
6502
|
-
|
6503
|
-
|
6504
|
-
}
|
6505
|
-
return {
|
6506
|
-
requestedBy: request.requestedBy ? peersMap[request.requestedBy] : void 0,
|
6507
|
-
role: rolesMap[request.roleName],
|
6508
|
-
token: request.token
|
6509
|
-
};
|
6187
|
+
var yt = createSelector([Se2, dt], (s, e) => {
|
6188
|
+
if (e)
|
6189
|
+
return s.filter((t) => {
|
6190
|
+
var i, o2;
|
6191
|
+
return (i = t.recipientRoles) != null && i.length ? (o2 = t.recipientRoles) == null ? void 0 : o2.includes(e) : false;
|
6192
|
+
});
|
6510
6193
|
});
|
6511
|
-
var
|
6512
|
-
var
|
6513
|
-
|
6514
|
-
|
6515
|
-
|
6516
|
-
|
6517
|
-
|
6518
|
-
|
6194
|
+
var cs = createSelector(Se2, (s) => s.filter((e) => {
|
6195
|
+
var t;
|
6196
|
+
return !e.recipientPeer && !((t = e.recipientRoles) != null && t.length);
|
6197
|
+
}));
|
6198
|
+
var Ss = createSelector([yt, dt], (s) => s ? s.filter((e) => !e.read).length : 0);
|
6199
|
+
var ls = createSelector([mt, Ae], (s) => s ? s.filter((e) => !e.read).length : 0);
|
6200
|
+
var mr2 = createSelector(cs, (s) => s.filter((e) => !e.read).length);
|
6201
|
+
var yr = u(mt);
|
6202
|
+
var gr2 = u(yt);
|
6203
|
+
var hr = u(Ss);
|
6204
|
+
var Pr2 = u(ls);
|
6205
|
+
var gt = u(os);
|
6206
|
+
var Cr = createSelector([k, T], (s, e) => Object.values(s).map((i) => {
|
6207
|
+
var o2;
|
6208
|
+
return { peer: i, isAudioEnabled: i.audioTrack ? (o2 = e[i.audioTrack]) == null ? void 0 : o2.enabled : false };
|
6209
|
+
}));
|
6210
|
+
var ds2 = (s) => s.roleChangeRequests[0] || null;
|
6211
|
+
var Nr = createSelector([ds2, k, _2], (s, e, t) => s ? { requestedBy: s.requestedBy ? e[s.requestedBy] : void 0, role: t[s.roleName], token: s.token } : null);
|
6212
|
+
var Lr = createSelector([le2], (s) => Y(s));
|
6213
|
+
var xr2 = createSelector([ze], (s) => Y(s));
|
6214
|
+
var ps = createSelector([I, T], (s, e) => {
|
6215
|
+
let t = null;
|
6216
|
+
return s && (t = e[s]), (t == null ? void 0 : t.plugins) || [];
|
6519
6217
|
});
|
6520
|
-
var
|
6521
|
-
let
|
6522
|
-
|
6523
|
-
track = tracksMap[trackID];
|
6524
|
-
}
|
6525
|
-
return (track == null ? void 0 : track.plugins) || [];
|
6218
|
+
var Ms = createSelector([b, T], (s, e) => {
|
6219
|
+
let t = null;
|
6220
|
+
return s && (t = e[s]), (t == null ? void 0 : t.plugins) || [];
|
6526
6221
|
});
|
6527
|
-
var
|
6528
|
-
|
6529
|
-
|
6530
|
-
|
6531
|
-
|
6532
|
-
|
6533
|
-
|
6534
|
-
var
|
6535
|
-
|
6536
|
-
|
6537
|
-
|
6538
|
-
|
6539
|
-
|
6540
|
-
|
6541
|
-
|
6542
|
-
};
|
6543
|
-
var POLL_NOTIFICATION_TYPES = {
|
6544
|
-
[zt.POLL_CREATED]: HMSNotificationTypes.POLL_CREATED,
|
6545
|
-
[zt.POLL_STARTED]: HMSNotificationTypes.POLL_STARTED,
|
6546
|
-
[zt.POLL_STOPPED]: HMSNotificationTypes.POLL_STOPPED,
|
6547
|
-
[zt.POLL_STATS_UPDATED]: HMSNotificationTypes.POLL_VOTES_UPDATED
|
6548
|
-
};
|
6549
|
-
var selectLocalPeerID22 = (store) => store.localPeer.id;
|
6550
|
-
var selectLocalAudioTrackID2 = (store) => store.localPeer.audioTrack;
|
6551
|
-
var selectLocalVideoTrackID2 = (store) => store.localPeer.videoTrack;
|
6552
|
-
var selectPeerID2 = (_store, peerID) => peerID;
|
6553
|
-
var selectTrackID2 = (_store, trackID) => trackID;
|
6554
|
-
var selectRemoteTrackStatsMap = (store) => store.remoteTrackStats;
|
6555
|
-
var selectPeerStatsMap = (store) => store.peerStats;
|
6556
|
-
var selectLocalTrackStatsMap = (store) => store.localTrackStats;
|
6557
|
-
var localPeerStats = createSelector([selectPeerStatsMap, selectLocalPeerID22], (storePeerStats, localPeerID) => storePeerStats[localPeerID]);
|
6558
|
-
var packetsLost = createSelector(localPeerStats, (localPeerStats2) => {
|
6559
|
-
var _a;
|
6560
|
-
return (_a = localPeerStats2 == null ? void 0 : localPeerStats2.subscribe) == null ? void 0 : _a.packetsLost;
|
6222
|
+
var He = { [ct.PEER_JOINED]: "PEER_JOINED", [ct.PEER_LEFT]: "PEER_LEFT", [ct.ROLE_UPDATED]: "ROLE_UPDATED", [ct.NAME_UPDATED]: "NAME_UPDATED", [ct.METADATA_UPDATED]: "METADATA_UPDATED" };
|
6223
|
+
var te = { [ie.TRACK_ADDED]: "TRACK_ADDED", [ie.TRACK_REMOVED]: "TRACK_REMOVED", [ie.TRACK_MUTED]: "TRACK_MUTED", [ie.TRACK_UNMUTED]: "TRACK_UNMUTED", [ie.TRACK_DEGRADED]: "TRACK_DEGRADED", [ie.TRACK_RESTORED]: "TRACK_RESTORED", [ie.TRACK_DESCRIPTION_CHANGED]: "TRACK_DESCRIPTION_CHANGED" };
|
6224
|
+
var fe2 = { [zt.POLL_CREATED]: "POLL_CREATED", [zt.POLL_STARTED]: "POLL_STARTED", [zt.POLL_STOPPED]: "POLL_STOPPED", [zt.POLL_STATS_UPDATED]: "POLL_VOTES_UPDATED" };
|
6225
|
+
var Ns = (s) => s.localPeer.id;
|
6226
|
+
var Ls = (s) => s.localPeer.audioTrack;
|
6227
|
+
var xs = (s) => s.localPeer.videoTrack;
|
6228
|
+
var Os = (s, e) => e;
|
6229
|
+
var Ct = (s, e) => e;
|
6230
|
+
var _s = (s) => s.remoteTrackStats;
|
6231
|
+
var Nt = (s) => s.peerStats;
|
6232
|
+
var we = (s) => s.localTrackStats;
|
6233
|
+
var V = createSelector([Nt, Ns], (s, e) => s[e]);
|
6234
|
+
var ws = createSelector(V, (s) => {
|
6235
|
+
var e;
|
6236
|
+
return (e = s == null ? void 0 : s.subscribe) == null ? void 0 : e.packetsLost;
|
6561
6237
|
});
|
6562
|
-
var
|
6563
|
-
var
|
6564
|
-
return (
|
6238
|
+
var Us = createSelector(V, (s) => {
|
6239
|
+
var e;
|
6240
|
+
return (e = s == null ? void 0 : s.subscribe) == null ? void 0 : e.jitter;
|
6565
6241
|
});
|
6566
|
-
var
|
6567
|
-
var
|
6568
|
-
return (
|
6242
|
+
var Vs = createSelector(V, (s) => {
|
6243
|
+
var e;
|
6244
|
+
return (e = s == null ? void 0 : s.publish) == null ? void 0 : e.bitrate;
|
6569
6245
|
});
|
6570
|
-
var
|
6571
|
-
var
|
6572
|
-
return (
|
6246
|
+
var Ks = createSelector(V, (s) => {
|
6247
|
+
var e;
|
6248
|
+
return (e = s == null ? void 0 : s.subscribe) == null ? void 0 : e.bitrate;
|
6573
6249
|
});
|
6574
|
-
var
|
6575
|
-
var
|
6576
|
-
return (
|
6250
|
+
var Bs = createSelector(V, (s) => {
|
6251
|
+
var e;
|
6252
|
+
return (e = s == null ? void 0 : s.publish) == null ? void 0 : e.availableOutgoingBitrate;
|
6577
6253
|
});
|
6578
|
-
var
|
6579
|
-
var
|
6580
|
-
return (
|
6254
|
+
var qs = createSelector(V, (s) => {
|
6255
|
+
var e;
|
6256
|
+
return (e = s == null ? void 0 : s.subscribe) == null ? void 0 : e.availableIncomingBitrate;
|
6581
6257
|
});
|
6582
|
-
var
|
6583
|
-
var
|
6584
|
-
return (
|
6258
|
+
var js = createSelector(V, (s) => {
|
6259
|
+
var e;
|
6260
|
+
return (e = s == null ? void 0 : s.publish) == null ? void 0 : e.bytesSent;
|
6585
6261
|
});
|
6586
|
-
var
|
6587
|
-
var
|
6588
|
-
return (
|
6262
|
+
var Gs = createSelector(V, (s) => {
|
6263
|
+
var e;
|
6264
|
+
return (e = s == null ? void 0 : s.subscribe) == null ? void 0 : e.bytesReceived;
|
6589
6265
|
});
|
6590
|
-
var
|
6591
|
-
var
|
6592
|
-
var
|
6593
|
-
var
|
6594
|
-
var
|
6595
|
-
var
|
6596
|
-
var
|
6597
|
-
return
|
6266
|
+
var Fs = createSelector([Nt, Os], (s, e) => e ? s[e] : void 0);
|
6267
|
+
var Qs = createSelector([_s, Ct], (s, e) => e ? s[e] : void 0);
|
6268
|
+
var Ue = createSelector([we, Ct], (s, e) => e ? s[e] : void 0);
|
6269
|
+
var $s = u(Fs);
|
6270
|
+
var Ws = u(Qs);
|
6271
|
+
var Js = createSelector([we, Ls], (s, e) => {
|
6272
|
+
var t;
|
6273
|
+
return e ? (t = s[e]) == null ? void 0 : t[0] : void 0;
|
6598
6274
|
});
|
6599
|
-
var
|
6600
|
-
var
|
6601
|
-
var
|
6602
|
-
return
|
6275
|
+
var Ys = u(createSelector(Ue, (s) => s == null ? void 0 : s[0]));
|
6276
|
+
var zs = createSelector([we, xs], (s, e) => {
|
6277
|
+
var t;
|
6278
|
+
return e ? (t = s[e]) == null ? void 0 : t[0] : void 0;
|
6603
6279
|
});
|
6604
|
-
var
|
6280
|
+
var Xs = u(createSelector(Ue, (s) => s));
|
6605
6281
|
|
6606
6282
|
// src/Prebuilt/common/PeersSorter.js
|
6607
6283
|
var PeersSorter = class {
|
@@ -6611,7 +6287,7 @@ var PeersSorter = class {
|
|
6611
6287
|
__publicField(this, "setPeersAndTilesPerPage", ({ peers, tilesPerPage }) => {
|
6612
6288
|
this.tilesPerPage = tilesPerPage;
|
6613
6289
|
const peerIds = new Set(peers.map((peer) => peer.id));
|
6614
|
-
this.peers.forEach((
|
6290
|
+
this.peers.forEach((_3, key) => {
|
6615
6291
|
if (!peerIds.has(key)) {
|
6616
6292
|
this.peers.delete(key);
|
6617
6293
|
}
|
@@ -6624,7 +6300,7 @@ var PeersSorter = class {
|
|
6624
6300
|
}
|
6625
6301
|
});
|
6626
6302
|
if (!this.storeUnsubscribe) {
|
6627
|
-
this.storeUnsubscribe = this.store.subscribe(this.onDominantSpeakerChange,
|
6303
|
+
this.storeUnsubscribe = this.store.subscribe(this.onDominantSpeakerChange, mi);
|
6628
6304
|
}
|
6629
6305
|
this.moveSpeakerToFront(this.speaker);
|
6630
6306
|
});
|
@@ -6713,7 +6389,7 @@ var List = ({ maxTileCount, peers, maxColCount, maxRowCount, includeScreenShareF
|
|
6713
6389
|
const tileOffset = useAppConfig("headlessConfig", "tileOffset");
|
6714
6390
|
const isHeadless = useIsHeadless();
|
6715
6391
|
const hideLocalVideo = useUISettings(UI_SETTINGS.hideLocalVideo);
|
6716
|
-
const localPeerId = useHMSStore5(
|
6392
|
+
const localPeerId = useHMSStore5(selectLocalPeerID4);
|
6717
6393
|
let sortedPeers = useSortedPeers_default({ peers, maxTileCount });
|
6718
6394
|
if (hideLocalVideo && sortedPeers.length > 1) {
|
6719
6395
|
sortedPeers = filterPeerId(sortedPeers, localPeerId);
|
@@ -6840,4 +6516,4 @@ export {
|
|
6840
6516
|
GridCenterView,
|
6841
6517
|
GridSidePaneView
|
6842
6518
|
};
|
6843
|
-
//# sourceMappingURL=chunk-
|
6519
|
+
//# sourceMappingURL=chunk-TEHZYXCJ.js.map
|