decord/source/modules/app_launcher/utils/useLaunchingActivityButtonState.tsx

63 lines
2.2 KiB
TypeScript
Raw Normal View History

2026-07-31 08:44:05 +00:00
// Module ID: 11332
// Function ID: 11333
2026-07-20 16:05:17 +00:00
// Name: useLaunchingActivityButtonState
2026-07-31 08:44:05 +00:00
// Dependencies: [19, 1371, 5690, 5525, 589, 10519, 8129, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-07-31 08:44:05 +00:00
// Module 11332 (useLaunchingActivityButtonState)
2026-07-29 08:29:29 +00:00
import noop from "noop";
import participantFromServer from "participantFromServer";
import map from "map";
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-07-29 08:29:29 +00:00
const result = require("map").fileFinishedImporting("modules/app_launcher/utils/useLaunchingActivityButtonState.tsx");
2026-07-20 16:05:17 +00:00
export default function useLaunchingActivityButtonState(applicationId) {
2026-07-23 10:11:24 +00:00
let importDefault;
2026-07-20 16:05:17 +00:00
let onSubmissionComplete;
applicationId = applicationId.applicationId;
2026-07-23 10:11:24 +00:00
({ context: importDefault, onSubmissionComplete } = applicationId);
let stateFromStores1;
let c4;
let obj = applicationId(onSubmissionComplete[3]);
2026-07-20 16:05:17 +00:00
const getOrFetchApplication = obj.useGetOrFetchApplication(applicationId);
2026-07-23 10:11:24 +00:00
const items = [c4];
const stateFromStores = applicationId(onSubmissionComplete[4]).useStateFromStores(items, () => {
2026-07-20 16:05:17 +00:00
let id;
if ("channel" === closure_1.type) {
id = closure_1.channel.id;
}
2026-07-23 10:11:24 +00:00
return _undefined.getLaunchState(applicationId, id);
2026-07-20 16:05:17 +00:00
});
2026-07-23 10:11:24 +00:00
const obj2 = applicationId(onSubmissionComplete[4]);
2026-07-29 08:29:29 +00:00
let tmp = applicationId;
const items1 = [map];
2026-07-23 10:11:24 +00:00
stateFromStores1 = applicationId(onSubmissionComplete[4]).useStateFromStores(items1, () => outer1_5.isLaunchingFrame(applicationId));
2026-07-20 16:05:17 +00:00
if (null == getOrFetchApplication) {
stateFromStores1 = null != stateFromStores && stateFromStores.isLaunching && stateFromStores.componentId === applicationId.launchingComponentId;
const tmp6 = null != stateFromStores && stateFromStores.isLaunching && stateFromStores.componentId === applicationId.launchingComponentId;
} else {
2026-07-29 08:29:29 +00:00
const tmpResult = tmp(tmp2[5]);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
let tmp7 = importDefault(tmp2[6])(stateFromStores1);
2026-07-23 10:11:24 +00:00
c4 = tmp7;
2026-07-20 16:05:17 +00:00
const items2 = [stateFromStores1, tmp7, onSubmissionComplete];
2026-07-23 10:11:24 +00:00
const effect = stateFromStores1.useEffect(() => {
2026-07-29 08:29:29 +00:00
let tmp = !stateFromStores1;
if (!stateFromStores1) {
tmp = c4;
}
2026-07-20 16:05:17 +00:00
if (tmp) {
2026-07-29 08:29:29 +00:00
if (onSubmissionComplete != null) {
tmp2();
2026-07-20 16:05:17 +00:00
}
}
}, items2);
2026-07-29 08:29:29 +00:00
obj = { submitting: stateFromStores1, wasSubmitting: null };
if (tmp7 == null) {
tmp7 = null;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[1] = tmp7;
2026-07-20 16:05:17 +00:00
return obj;
};