decord/source/modules/calls/useCallA11yState.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

31 lines
987 B
TypeScript

// Module ID: 16127
// Function ID: 16128
// Name: useCallA11yState
// Dependencies: [502, 5359, 504, 2]
// Exports: default
// Module 16127 (useCallA11yState)
import AuthenticationStore from "AuthenticationStore" /* 502 */;
import CallStore from "CallStore" /* 5359 */;
const require = globalThis.__r;
const require = fn;
const size = fn(2);
const result = size.fileFinishedImporting("modules/calls/useCallA11yState.tsx");
export default function useCallA11yState(arg0) {
_require = arg0;
const items = [CallStore, AuthenticationStore];
return require("initialize").useStateFromStoresObject(items, () => {
const call = CallStore.getCall(closure_0);
const id = AuthenticationStore.getId();
let hasItem = null != call && null != id;
if (hasItem) {
const ringing = call.ringing;
hasItem = ringing.includes(id);
}
const obj2 = { isIncomingCall: hasItem, isOngoingCall: CallStore.isCallActive(closure_0) && !hasItem };
return obj2;
});
};