decord/source/modules/rtc/hooks/useIsEmptyRTCConnection.tsx
github-actions da5b5e5efe chore: update source for alpha 346.6
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4821.js (118.4 MB)
2026-09-12 13:45:10 +00:00

55 lines
1.8 KiB
TypeScript

// Module ID: 9302
// Function ID: 9303
// Name: useIsEmptyRTCConnection
// Dependencies: [502, 4659, 4675, 504, 2]
// Exports: useIsCallRTCConnectionEmpty, useIsStreamRTCConnectionEmpty
// Module 9302 (useIsEmptyRTCConnection)
import initialize from "initialize" /* 504 */;
import AuthenticationStore from "AuthenticationStore" /* 502 */;
import RTCConnectionStore from "RTCConnectionStore" /* 4659 */;
import StreamRTCConnectionStore from "StreamRTCConnectionStore" /* 4675 */;
const require = globalThis.__r;
require = fn;
const size = fn(2);
const result = size.fileFinishedImporting("modules/rtc/hooks/useIsEmptyRTCConnection.tsx");
export const useIsStreamRTCConnectionEmpty = function useIsStreamRTCConnectionEmpty(stateFromStores4) {
_require = stateFromStores4;
const items = [StreamRTCConnectionStore, AuthenticationStore];
return require("initialize").useStateFromStores(items, () => {
if (null == closure_0) {
return true;
} else {
const userIds = StreamRTCConnectionStore.getUserIds(tmp);
let tmp3 = null == userIds;
if (!tmp3) {
let tmp6 = 0 === userIds.size;
if (!tmp6) {
tmp6 = 1 === userIds.size && userIds.has(tmp5);
const tmp7 = 1 === userIds.size && userIds.has(tmp5);
}
tmp3 = tmp6;
}
return tmp3;
}
});
};
export const useIsCallRTCConnectionEmpty = function useIsCallRTCConnectionEmpty() {
const items = [RTCConnectionStore, AuthenticationStore];
return initialize.useStateFromStores(items, () => {
userIds = userIds.getUserIds();
let tmp = null == userIds;
if (!tmp) {
let tmp4 = 0 === userIds.size;
if (!tmp4) {
tmp4 = 1 === userIds.size && userIds.has(tmp3);
const tmp5 = 1 === userIds.size && userIds.has(tmp3);
}
tmp = tmp4;
}
return tmp;
});
};