decord/source/modules/mfa/native/screens/MfaOptionScreen.tsx

78 lines
3.1 KiB
TypeScript
Raw Normal View History

// Module ID: 15759
// Function ID: 15760
// Name: MfaOptionScreen
// Dependencies: [19, 17, 21, 7045, 15760, 7226, 5054, 4632, 15761, 7076, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
// Module 15759 (MfaOptionScreen)
import Text_Text from "Text/Text" /* 4632 */;
import Stack_Stack from "Stack/Stack" /* 5054 */;
import useWideAuthViewDefault from "useWideAuthView" /* 7045 */;
import BackgroundImageDefault from "BackgroundImage" /* 7076 */;
import common_SafeAreaView from "common/SafeAreaView" /* 7226 */;
import MfaScreenUtilsDefault from "MfaScreenUtils" /* 15760 */;
import noop from "module_19" /* 19 */;
2026-07-23 10:11:24 +00:00
require = fn;
const ScrollView = fn(17).ScrollView;
const jsxProd = fn(21);
({ jsx: closure_4, jsxs: hasOwnProperty, Fragment: metroRequire } = jsxProd);
const size = fn(2);
const result = size.fileFinishedImporting("modules/mfa/native/screens/MfaOptionScreen.tsx");
2026-07-20 16:05:17 +00:00
export default function MFAOptionScreen(arg0) {
2026-09-02 09:53:35 +00:00
({ headerImage, subtitle, screenProps, error } = arg0);
2026-07-20 16:05:17 +00:00
({ headerText, input, submit, mfaMethod, content } = arg0);
2026-09-02 09:53:35 +00:00
const tmp3 = useWideAuthViewDefault();
const screenStyles = MfaScreenUtilsDefault.useScreenStyles(tmp3);
2026-09-02 09:53:35 +00:00
const first = screenProps.mfaChallenge.methods[0];
2026-07-20 16:05:17 +00:00
let type;
2026-07-29 08:29:29 +00:00
if (first != null) {
2026-07-20 16:05:17 +00:00
type = first.type;
}
const rect = { bottom: !tmp3, top: !tmp3, style: screenStyles.contentContainer, children: null };
const obj2 = { style: screenStyles.mfaContainerHeader, spacing: 4, children: null };
2026-07-29 08:29:29 +00:00
let tmp9 = null != headerImage;
if (tmp9) {
tmp9 = headerImage;
2026-07-20 16:05:17 +00:00
}
const items = [tmp9, React4(Text_Text.Heading, { variant: "heading-xl/extrabold", style: screenStyles.mfaContainerHeaderText, children: headerText }), , ];
2026-07-29 08:29:29 +00:00
let tmp10Result = null != subtitle;
if (tmp10Result) {
const obj4 = { variant: "heading-sm/normal", color: "text-default", children: subtitle };
tmp10Result = tmp10(tmp8(4632).Text, obj4);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
items[2] = tmp10Result;
let tmp10Result4 = null != error;
if (tmp10Result4) {
const obj5 = { variant: "text-sm/normal", color: "text-feedback-critical", children: error };
tmp10Result4 = tmp10(tmp8(4632).Text, obj5);
2026-07-20 16:05:17 +00:00
}
let tmp10Result5 = type === mfaMethod;
const obj6 = { children: null };
items[3] = tmp10Result4;
obj2.children = items;
const items1 = [hasOwnProperty(Stack_Stack.Stack, obj2), input];
obj6.children = items1;
const items2 = [hasOwnProperty(Stack_Stack.Stack, obj6), content, ];
const obj7 = { style: screenStyles.submit, children: null };
2026-07-20 16:05:17 +00:00
const items3 = [submit, ];
if (tmp10Result5) {
const obj8 = { props: screenProps };
tmp10Result5 = tmp10(tmp(15761), obj8);
2026-07-20 16:05:17 +00:00
}
items3[1] = tmp10Result5;
obj7.children = items3;
items2[2] = hasOwnProperty(Stack_Stack.Stack, obj7);
rect.children = items2;
const tmp7Result = hasOwnProperty(common_SafeAreaView.SafeAreaPaddingView, rect);
const children = [React4(BackgroundImageDefault, { backgroundImageCover: false }), ];
let tmp10Result6 = tmp7Result;
2026-09-02 09:53:35 +00:00
if (tmp3) {
const obj9 = { keyboardShouldPersistTaps: "handled", children: tmp7Result };
tmp10Result6 = tmp10(ScrollView, obj9);
2026-07-20 16:05:17 +00:00
}
children[1] = tmp10Result6;
return hasOwnProperty(timestampProducer, { children });
2026-07-20 16:05:17 +00:00
};