decord/source/modules/age_assurance/native/AgeVerificationIncodeMethodSelectScreen.tsx

215 lines
7.8 KiB
TypeScript
Raw Normal View History

2026-08-26 06:04:24 +00:00
// Module ID: 8014
// Function ID: 8015
2026-07-20 16:05:17 +00:00
// Name: AgeVerificationIncodeMethodSelectScreen
2026-08-26 06:04:24 +00:00
// Dependencies: [5, 32, 19, 1302, 8010, 8012, 21, 4444, 8015, 8019, 8020, 4877, 5995, 6202, 4440, 1236, 2887, 5939, 5546, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-08-26 06:04:24 +00:00
// Module 8014 (AgeVerificationIncodeMethodSelectScreen)
2026-08-24 06:08:38 +00:00
import closure_3 from "asyncGeneratorStep" /* 5 */;
import closure_4 from "_slicedToArray" /* 32 */;
import closure_5 from "noop" /* 19 */;
import closure_6 from "handleThemeChange" /* 1302 */;
2026-08-26 06:04:24 +00:00
import { VerificationMethod } from "set" /* 8010 */;
import { buildIncodeParamsInjection as closure_8 } from "AGE_VERIFICATION_INCODE_PATH" /* 8012 */;
2026-08-24 06:08:38 +00:00
import jsxProd from "jsxProd" /* 21 */;
2026-08-26 06:04:24 +00:00
import createCacheKey from "createCacheKey" /* 4444 */;
2026-07-21 22:01:30 +00:00
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-08-06 08:05:19 +00:00
({ jsx: c9, jsxs: c10 } = jsxProd);
let closure_11 = createCacheKey.createStyles({ container: { alignSelf: "stretch" }, header: { textAlign: "center" }, loadingContainer: { flex: 1, alignSelf: "stretch" } });
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/age_assurance/native/AgeVerificationIncodeMethodSelectScreen.tsx");
2026-07-20 16:05:17 +00:00
export default function AgeVerificationIncodeMethodSelectScreen(onMethodSelected) {
onMethodSelected = onMethodSelected.onMethodSelected;
2026-07-29 08:29:29 +00:00
let _require = onMethodSelected;
2026-07-20 16:05:17 +00:00
const trustedOrigin = onMethodSelected.trustedOrigin;
2026-08-24 06:08:38 +00:00
dependencyMap = undefined;
2026-07-29 08:29:29 +00:00
let callback;
let callback2;
[tmp2, c2] = callback2(React.useState(false), 2);
const tmp = callback2(React.useState(false), 2);
[tmp4, c3] = callback2(React.useState(false), 2);
2026-08-06 08:05:19 +00:00
const tmp5 = callback4();
2026-07-29 08:29:29 +00:00
_require = undefined;
_require = callback((arg0) => {
2026-08-24 06:08:38 +00:00
closure_0 = arg0;
c5 = 0;
c6 = 0;
c4 = 0;
2026-07-29 08:29:29 +00:00
return (function*(arg0) {
if (c6 === 2) {
c6 = 3;
HermesBuiltin.throwTypeError();
} else if (tmp7 === 3) {
if (arg0 === 1) {
throw arg1;
} else if (arg0 === 2) {
let obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
2026-08-26 06:04:24 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
try {
c6 = 2;
if (0 === c5) {
if (arg0 === 1) {
c6 = 3;
throw arg1;
} else if (arg0 === 2) {
c6 = 3;
obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
2026-08-24 06:08:38 +00:00
closure_2 = tmp4;
closure_1 = tmp8;
2026-07-29 08:29:29 +00:00
closure_1 = undefined;
closure_2 = undefined;
2026-08-24 06:08:38 +00:00
closure_1_2(true);
closure_1_3(false);
c4 = 2;
2026-08-06 08:05:19 +00:00
let obj2 = callback(table[8]);
2026-07-29 08:29:29 +00:00
c5 = 3;
c6 = 1;
2026-08-24 06:08:38 +00:00
obj1 = { value: null, done: false };
2026-07-29 08:29:29 +00:00
obj1[0] = obj2.requestIncodeMethodSession(callback);
return obj1;
}
} else if (1 === tmp8) {
c4 = 0;
2026-08-24 06:08:38 +00:00
closure_1_2(false);
throw closure_3;
2026-07-29 08:29:29 +00:00
} else {
if (2 === tmp8) {
c4 = 1;
2026-08-24 06:08:38 +00:00
closure_1_3(true);
2026-07-29 08:29:29 +00:00
c4 = 0;
2026-08-24 06:08:38 +00:00
closure_1_2(false);
2026-07-29 08:29:29 +00:00
c6 = 3;
} else if (arg0 === 1) {
c6 = 3;
throw arg1;
} else if (arg0 === 2) {
c4 = 0;
2026-08-24 06:08:38 +00:00
closure_1_2(false);
2026-07-29 08:29:29 +00:00
c6 = 3;
obj2 = { value: null, done: true };
obj2[0] = arg1;
return obj2;
} else {
closure_1 = arg1;
if (null != closure_1) {
const obj3 = { apiUrl: null, sessionToken: null, consentId: null, interviewId: null, theme: null, method: null };
obj3[0] = closure_1.apiUrl;
obj3[1] = closure_1.sessionToken;
obj3[2] = closure_1.consentId;
obj3[3] = closure_1.interviewId;
2026-08-24 06:08:38 +00:00
obj3[4] = closure_2_6.theme;
2026-07-29 08:29:29 +00:00
obj3[5] = callback;
2026-08-24 06:08:38 +00:00
closure_2 = closure_2_8(obj3, closure_1_1);
2026-07-29 08:29:29 +00:00
callback(closure_2);
c4 = 1;
}
}
2026-08-24 06:08:38 +00:00
closure_1_3(true);
2026-07-29 08:29:29 +00:00
c4 = 0;
2026-08-24 06:08:38 +00:00
closure_1_2(false);
2026-07-29 08:29:29 +00:00
c6 = 3;
obj = { value: null, done: true };
obj[0] = undefined;
return obj;
}
} catch (tmp36) {
2026-08-24 06:08:38 +00:00
closure_3 = tmp36;
2026-07-29 08:29:29 +00:00
if (tmp5 === c4) {
c6 = tmp3;
throw tmp36;
} else if (tmp2 === tmp38) {
c5 = tmp2;
} else {
c5 = tmp;
}
}
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
})();
});
const items = [onMethodSelected, trustedOrigin];
callback2 = React.useCallback(function() {
const self = this;
const apply = closure_0.apply;
if (typeof apply === "unknown") {
let applyArgumentsResult = HermesBuiltin.applyArguments(self);
} else {
applyArgumentsResult = apply(self, arguments);
}
return applyArgumentsResult;
}, items);
2026-08-06 08:05:19 +00:00
let obj = { children: null };
2026-08-26 06:04:24 +00:00
const ModalContent = _require(8020).ModalContent;
2026-08-06 08:05:19 +00:00
obj = { children: null };
2026-07-20 16:05:17 +00:00
if (tmp2) {
2026-08-06 08:05:19 +00:00
obj = { align: "center", justify: "center", spacing: 16, style: null, children: null };
obj[3] = tmp5.loadingContainer;
2026-08-26 06:04:24 +00:00
obj[4] = tmp6(tmp7(5995).ActivityIndicator, { size: "large" });
obj[0] = tmp6(tmp7(4877).Stack, obj);
2026-08-06 08:05:19 +00:00
obj[0] = tmp6(ModalContent, obj);
let tmp11 = obj;
2026-07-20 16:05:17 +00:00
} else {
2026-08-24 06:08:38 +00:00
obj1 = { align: "stretch", spacing: 24, style: null, children: null };
2026-08-06 08:05:19 +00:00
obj1[2] = tmp5.container;
let obj2 = { align: "center", justify: "center", spacing: 16, children: null };
2026-08-26 06:04:24 +00:00
const items1 = [tmp6(tmp7(6202).ShieldSpotIllustration, { height: 100, width: 177 }), ];
2026-08-06 08:05:19 +00:00
let obj3 = { align: "center", justify: "center", spacing: 8, children: null };
const obj4 = { accessibilityRole: "header", variant: "heading-xl/bold", color: "mobile-text-heading-primary", style: null, children: null };
obj4[3] = tmp5.header;
const intl = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj4[4] = intl.string(trustedOrigin(2887).eZvwAe);
const items2 = [tmp6(tmp7(4440).Text, obj4), ];
2026-08-06 08:05:19 +00:00
const obj5 = { variant: "text-md/medium", color: "text-strong", style: null, children: null };
obj5[2] = tmp5.header;
const intl2 = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj5[3] = intl2.string(trustedOrigin(2887)["5yWXmT"]);
items2[1] = tmp6(tmp7(4440).Text, obj5);
2026-08-06 08:05:19 +00:00
obj3[3] = items2;
2026-08-26 06:04:24 +00:00
items1[1] = callback3(tmp7(4877).Stack, obj3);
2026-08-06 08:05:19 +00:00
obj2[3] = items1;
2026-08-26 06:04:24 +00:00
const items3 = [callback3(tmp7(4877).Stack, obj2), , ];
2026-07-29 08:29:29 +00:00
if (tmp6Result) {
2026-08-06 08:05:19 +00:00
const obj6 = { variant: "text-sm/medium", color: "text-feedback-critical", style: null, children: null };
obj6[2] = tmp5.header;
const intl3 = tmp7(1236).intl;
obj6[3] = intl3.string(tmp7(1236).t.c6kn6F);
2026-08-26 06:04:24 +00:00
tmp6Result = tmp6(tmp7(4440).Text, obj6);
2026-07-20 16:05:17 +00:00
}
2026-08-06 08:05:19 +00:00
items3[1] = tmp6Result;
const obj7 = { hasIcons: false, children: null };
const obj8 = { arrow: true, label: null, subLabel: null, onPress: null };
const intl4 = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj8[1] = intl4.string(trustedOrigin(2887).rgXXcW);
2026-08-06 08:05:19 +00:00
const intl5 = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj8[2] = intl5.string(trustedOrigin(2887).fm7qBC);
2026-08-06 08:05:19 +00:00
obj8[3] = function onPress() {
2026-08-24 06:08:38 +00:00
callback(closure_1_7.FACIAL_AGE_ESTIMATION);
2026-07-20 16:05:17 +00:00
};
2026-08-26 06:04:24 +00:00
const items4 = [tmp6(tmp7(5546).TableRow, obj8), ];
2026-08-06 08:05:19 +00:00
const obj9 = { arrow: true, label: null, subLabel: null, onPress: null };
const intl6 = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj9[1] = intl6.string(trustedOrigin(2887)["NeVlw/"]);
2026-08-06 08:05:19 +00:00
const intl7 = tmp7(1236).intl;
2026-08-26 06:04:24 +00:00
obj9[2] = intl7.string(trustedOrigin(2887).ARmJ0M);
2026-08-06 08:05:19 +00:00
obj9[3] = function onPress() {
2026-08-24 06:08:38 +00:00
callback(closure_1_7.ID_VERIFICATION);
2026-07-20 16:05:17 +00:00
};
2026-08-26 06:04:24 +00:00
items4[1] = tmp6(tmp7(5546).TableRow, obj9);
2026-08-06 08:05:19 +00:00
obj7[1] = items4;
2026-08-26 06:04:24 +00:00
items3[2] = callback3(tmp7(5939).TableRowGroup, obj7);
2026-08-06 08:05:19 +00:00
obj1[3] = items3;
2026-08-26 06:04:24 +00:00
obj[0] = callback3(tmp7(4877).Stack, obj1);
2026-08-06 08:05:19 +00:00
obj[0] = tmp6(ModalContent, obj);
tmp11 = obj;
2026-07-20 16:05:17 +00:00
}
2026-08-26 06:04:24 +00:00
return closure_9(_require(8019).ModalScreen, tmp11);
2026-07-20 16:05:17 +00:00
};