58 lines
2.9 KiB
TypeScript
58 lines
2.9 KiB
TypeScript
// Module ID: 9727
|
|
// Function ID: 9728
|
|
// Name: UnifiedGiftModal
|
|
// Dependencies: [32, 19, 21, 4611, 5889, 9728, 1236, 5376, 9729, 9769, 5834, 2]
|
|
// Exports: default
|
|
|
|
// Module 9727 (UnifiedGiftModal)
|
|
import closure_3 from "_slicedToArray" /* 32 */;
|
|
import closure_4 from "noop" /* 19 */;
|
|
import { jsx } from "jsxProd" /* 21 */;
|
|
|
|
const require = arg1;
|
|
const result = require("set").fileFinishedImporting("modules/checkout/native/gifting/UnifiedGiftModal.tsx");
|
|
|
|
export default function UnifiedGiftModal(analyticsLocations) {
|
|
({ skuId, applicationId, lockedRecipientUser, onGiftModalDismiss, validateRecipient, renderProductDetails, renderPurchaseSection } = analyticsLocations);
|
|
let first;
|
|
closure_8 = undefined;
|
|
let callback;
|
|
const tmp = onGiftModalDismiss(validateRecipient.useState(lockedRecipientUser), 2);
|
|
first = tmp[0];
|
|
closure_8 = tmp[1];
|
|
const items = [onGiftModalDismiss];
|
|
callback = validateRecipient.useCallback(() => {
|
|
let arr = applicationId(lockedRecipientUser[3]);
|
|
arr = arr.pop();
|
|
if (onGiftModalDismiss != null) {
|
|
onGiftModalDismiss();
|
|
}
|
|
}, items);
|
|
let obj = skuId(lockedRecipientUser[4]);
|
|
const items1 = [lockedRecipientUser, first, skuId, applicationId, callback, validateRecipient, renderProductDetails, renderPurchaseSection];
|
|
const navigatorScreens = obj.useNavigatorScreens(() => {
|
|
let obj = {};
|
|
obj = { title: null, headerLeft: null, render: null };
|
|
const intl = skuId(lockedRecipientUser[6]).intl;
|
|
obj[0] = intl.string(skuId(lockedRecipientUser[6]).t["JCFN/y"]);
|
|
obj[1] = skuId(lockedRecipientUser[7]).getHeaderCloseButton(callback);
|
|
obj[2] = function render() {
|
|
return closure_1_5(closure_1_1(closure_1_2[8]), { skuId: closure_0, applicationId: closure_1, recipientUser: closure_7, setRecipientUser: closure_8, lockedRecipient: null != closure_2, validateRecipient: closure_4, renderProductDetails: closure_5, renderPurchaseSection: closure_6 });
|
|
};
|
|
obj[skuId(lockedRecipientUser[5]).UnifiedGiftModalScreens.GIFT_DETAIL] = obj;
|
|
obj = { title: null, headerLeft: null, render: null };
|
|
const intl2 = skuId(lockedRecipientUser[6]).intl;
|
|
obj[0] = intl2.string(skuId(lockedRecipientUser[6]).t.R0vK0N);
|
|
const obj3 = skuId(lockedRecipientUser[7]);
|
|
obj[1] = skuId(lockedRecipientUser[7]).getHeaderBackButton();
|
|
obj[2] = function render() {
|
|
return closure_1_5(closure_1_1(closure_1_2[9]), { setRecipientUser: closure_8 });
|
|
};
|
|
obj[skuId(lockedRecipientUser[5]).UnifiedGiftModalScreens.RECIPENT_SELECT] = obj;
|
|
return obj;
|
|
}, items1);
|
|
obj = { value: analyticsLocations.analyticsLocations, children: null };
|
|
obj = { initialRouteName: skuId(lockedRecipientUser[5]).UnifiedGiftModalScreens.GIFT_DETAIL, screens: navigatorScreens };
|
|
obj[1] = renderProductDetails(skuId(lockedRecipientUser[4]).Navigator, obj);
|
|
return renderProductDetails(skuId(lockedRecipientUser[10]).AnalyticsLocationProvider, obj);
|
|
};
|