decord/source/modules/collectibles/native/useHandleUseNow.tsx

71 lines
2.2 KiB
TypeScript
Raw Normal View History

2026-08-05 07:35:12 +00:00
// Module ID: 10017
// Function ID: 10018
2026-07-20 16:05:17 +00:00
// Name: useHandleUseNow
2026-08-05 07:35:12 +00:00
// Dependencies: [19, 9463, 4223, 4460, 4107, 3956, 1236, 10018, 10021, 2]
2026-07-20 16:05:17 +00:00
// Exports: useHandleUseNow
2026-08-05 07:35:12 +00:00
// Module 10017 (useHandleUseNow)
2026-07-29 08:29:29 +00:00
import noop from "noop";
2026-07-23 10:11:24 +00:00
import { RootNavigatorScreen } from "MODE_CHANGE_PHYSICS";
const require = arg1;
2026-07-29 08:29:29 +00:00
const result = require("ACTION_SHEET_HEIGHT_HALF").fileFinishedImporting("modules/collectibles/native/useHandleUseNow.tsx");
2026-07-20 16:05:17 +00:00
export const useHandleUseNow = function useHandleUseNow(onSuccess) {
let analyticsLocations;
let canUseNow;
let handleUseNow;
let isApplying;
let product;
onSuccess = onSuccess.onSuccess;
2026-07-29 08:29:29 +00:00
let importDefault;
2026-07-20 16:05:17 +00:00
const items = [onSuccess];
({ product, analyticsLocations } = onSuccess);
const callback = React.useCallback(() => {
if (null == onSuccess) {
2026-07-29 08:29:29 +00:00
_undefined(outer1_2[2]).hideActionSheet();
const obj = _undefined(outer1_2[2]);
_undefined(outer1_2[3]).popAll();
const obj2 = _undefined(outer1_2[3]);
2026-07-23 10:11:24 +00:00
const rootNavigationRef = onSuccess(outer1_2[4]).getRootNavigationRef();
const obj3 = onSuccess(outer1_2[4]);
2026-07-20 16:05:17 +00:00
if (tmp8) {
2026-07-23 10:11:24 +00:00
rootNavigationRef.navigate(outer1_4.YOU);
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
tmp8 = null != rootNavigationRef && rootNavigationRef.isReady();
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
tmp();
2026-07-20 16:05:17 +00:00
}
}, items);
const callback1 = React.useCallback(() => {
2026-08-05 07:35:12 +00:00
let obj = _undefined(3956);
2026-07-29 08:29:29 +00:00
obj = { key: "collectible shop apply error", content: null };
const intl = onSuccess(1236).intl;
obj[1] = intl.string(onSuccess(1236).t.CKsXk3);
2026-07-20 16:05:17 +00:00
obj.open(obj);
}, []);
2026-08-05 07:35:12 +00:00
let obj = onSuccess(10018);
2026-07-20 16:05:17 +00:00
handleUseNow = obj.useHandleUseNow({ product, onSuccess: callback, onError: callback1 });
({ handleUseNow, isApplying, canUseNow } = handleUseNow);
2026-08-05 07:35:12 +00:00
const tmp4 = importDefault(10021)({ analyticsLocations });
2026-07-23 10:11:24 +00:00
importDefault = tmp4;
2026-07-20 16:05:17 +00:00
obj = {
handleUseNow,
isApplying,
canUseNow,
handleEditProfile: React.useCallback(() => {
2026-07-29 08:29:29 +00:00
_undefined();
2026-07-20 16:05:17 +00:00
if (null == onSuccess) {
2026-07-29 08:29:29 +00:00
_undefined(outer1_2[2]).hideActionSheet();
const obj = _undefined(outer1_2[2]);
_undefined(outer1_2[3]).popAll();
const obj2 = _undefined(outer1_2[3]);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
tmp2();
2026-07-20 16:05:17 +00:00
}
}, items1)
};
2026-07-23 10:11:24 +00:00
items1 = [tmp4, onSuccess];
2026-07-20 16:05:17 +00:00
return obj;
};