Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,106 @@
|
||||
/* Metro module 15636; source: modules/captcha/native/CaptchaModal.tsx; dependencies: [31, 27, 14304, 14305, 33, 4501, 8973, 1536, 15637, 6275, 4572, 5473, 4573, 1244, 4578, 9486, 15638, 14312, 2] */
|
||||
function _fun119735(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#119735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15844:6, offset: 0x02517660, size: 269 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
let value = require(27) /* metro dependency 27 */;
|
||||
const env0_4 = value.Keyboard;
|
||||
const env0_5 = value.View;
|
||||
const env0_6 = (require(14304) /* metro dependency 14304: RegistrationUIStore */).doesRegistrationHaveIdentityType;
|
||||
value = require(14305) /* metro dependency 14305: RegistrationConstants */;
|
||||
const env0_7 = value.RegisterTransitionSteps;
|
||||
const env0_8 = value.RegistrationTransitionActionTypes;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_9 = value.jsx;
|
||||
const env0_10 = value.jsxs;
|
||||
const env0_11 = (require(4501) /* metro dependency 4501: createStyles */).createStyles(function(a0) {
|
||||
return {contentContainer: {'alignItems': 'center', 'paddingVertical': 8, paddingHorizontal: a0 ? 32 : 8},
|
||||
description: {'paddingBottom': 12, 'paddingTop': 4}};
|
||||
});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/captcha/native/CaptchaModal.tsx');
|
||||
exports.default = CaptchaModal;
|
||||
}
|
||||
|
||||
function CaptchaModal({onCaptchaVerify, onReject, close, sitekey, captchaService, headerText, bodyText, rqdata, rqtoken, userflow}) { // fn#119737, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15844:527, offset: 0x025177a6, size: 756 bytes, params: 2, frame: 34
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const styles = useStyles((importDefault(8973) /* metro dependency 8973: useWideAuthView */)());
|
||||
const value3 = (importDefault(1536) /* metro dependency 1536 */)();
|
||||
const binding = sitekey;
|
||||
const useMemo = binding.useMemo;
|
||||
const env0_9 = (importDefault(15637) /* metro dependency 15637: useCaptchaModalEffects */)({onReject: onReject,
|
||||
analyticsType: Reflect.apply(useMemo, binding, [_fun119738, [value3]])});
|
||||
binding.useEffect(function() {
|
||||
Keyboard.dismiss();
|
||||
}, []);
|
||||
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
const Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack;
|
||||
const DisguiseSpotIllustration = (require(5473) /* metro dependency 5473: native */).DisguiseSpotIllustration;
|
||||
const items2 = [<DisguiseSpotIllustration scale={0.5} />];
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
items2[1] = <View><Text variant="heading-xl/bold" accessibilityRole="header">{headerText ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.FpoiHe)}</Text><Text variant="text-md/medium" color="text-subtle" style={styles.description}>{bodyText ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['/CidxO'])}</Text></View>;
|
||||
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
items2[2] = <Button grow onPress={onPress_119740} text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['cY+Oob'])} />;
|
||||
return (
|
||||
<BottomSheet startHeight={900} startExpanded>
|
||||
<Stack style={styles.contentContainer} spacing={12}>
|
||||
{items2}
|
||||
</Stack>
|
||||
</BottomSheet>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun119738() { // fn#119738, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15844:718, offset: 0x02517a9a, size: 89 bytes, params: 1, frame: 12
|
||||
const binding = env0_8;
|
||||
const getState = binding.getState;
|
||||
const name = Reflect.apply(getState, binding, []).routes[0]?.name;
|
||||
const value2 = 'Guild Join Captcha';
|
||||
return name !== 'auth' ? value2 : doesRegistrationHaveIdentityType() ? 'User Registration Captcha' : value2;
|
||||
}
|
||||
|
||||
function CaptchaModalOnPress() { // fn#119740, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15844:1444, owner: CaptchaModal.onPress, offset: 0x02517b08, size: 139 bytes, params: 1, frame: 18
|
||||
env0_9();
|
||||
close();
|
||||
const sharedCaptchaUtilsModule = require(9486) /* metro dependency 9486: SharedCaptchaUtils */;
|
||||
sharedCaptchaUtilsModule.emitCaptchaDistributionMetric(userflow);
|
||||
const defaultImport = importDefault(15638) /* metro dependency 15638: CaptchaUtils */;
|
||||
let value = defaultImport.showCaptcha(captchaService, sitekey, rqdata);
|
||||
value = value.then(_fun119741);
|
||||
value.catch(function(a0) {
|
||||
if (onReject != null) {
|
||||
onReject(a0);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function _fun119741(a0) { // fn#119741, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15844:1533, offset: 0x02517b93, size: 266 bytes, params: 2, frame: 17
|
||||
var r1;
|
||||
var value5;
|
||||
let value = environment.__proto__;
|
||||
let binding = env1_8;
|
||||
let getState = binding.getState;
|
||||
if (Reflect.apply(getState, binding, []).routes[0].name === 'auth' && doesRegistrationHaveIdentityType()) {
|
||||
value5 = environment.__proto__.__proto__;
|
||||
(require(14312) /* metro dependency 14312: RegistrationUtils */).trackRegTransition({step: RegisterTransitionSteps.CAPTCHA,
|
||||
|
||||
actionType: RegistrationTransitionActionTypes.SUBMITTED});
|
||||
}
|
||||
onCaptchaVerify(a0, rqtoken);
|
||||
binding = env1_8;
|
||||
getState = binding.getState;
|
||||
value = Reflect.apply(getState, binding, []).routes[0].name === 'auth';
|
||||
if (value) {
|
||||
value = environment.__proto__.__proto__;
|
||||
value = doesRegistrationHaveIdentityType();
|
||||
r1 = value;
|
||||
} else {
|
||||
r1 = value;
|
||||
}
|
||||
if (r1) {
|
||||
value = environment.__proto__.__proto__;
|
||||
(require(14312) /* metro dependency 14312: RegistrationUtils */).trackRegTransition({step: RegisterTransitionSteps.CAPTCHA,
|
||||
|
||||
actionType: RegistrationTransitionActionTypes.SUCCESS});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
/* Metro module 15640; source: modules/captcha/native/HcaptchaModal.tsx; dependencies: [29, 31, 27, 1949, 1878, 661, 33, 4501, 566, 1484, 1909, 1585, 1244, 9486, 4571, 4572, 697, 4573, 477, 15639, 5278, 4066, 2] */
|
||||
function _fun119773(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#119773, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15848:6, offset: 0x02518d3f, size: 389 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const env0_3 = ['onMessage', 'onClose'];
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_4 = importDefault(29) /* metro dependency 29 */;
|
||||
const env0_5 = importAll(31) /* metro dependency 31 */;
|
||||
let value = require(27) /* metro dependency 27 */;
|
||||
const env0_6 = value.ActivityIndicator;
|
||||
const env0_7 = value.View;
|
||||
const env0_8 = value.StyleSheet;
|
||||
const localeStore = importDefault(1949) /* metro dependency 1949: LocaleStore */;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const ModalAnimation = (require(661) /* metro dependency 661: Constants */).ModalAnimation;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_11 = value.jsx;
|
||||
const env0_12 = value.jsxs;
|
||||
const env0_13 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({container: {'flex': 1,
|
||||
'justifyContent': 'center', 'alignItems': 'center'}, title: {textAlign: 'center'},
|
||||
closeButtonContainer: {'position': 'absolute', 'top': 0, 'left': 0, 'zIndex': 2},
|
||||
closeButtonHitArea: {'minWidth': 44, 'minHeight': 44, 'justifyContent': 'center', 'alignItems': 'center'}});
|
||||
const closure = HcaptchaModal;
|
||||
const FADE = ModalAnimation.FADE;
|
||||
closure.modalConfig = {animation: FADE};
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/captcha/native/HcaptchaModal.tsx');
|
||||
exports.default = closure;
|
||||
}
|
||||
|
||||
function HcaptchaModal(a0) { // fn#119774, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15848:559, offset: 0x02518ec4, size: 1011 bytes, params: 2, frame: 32
|
||||
var r5;
|
||||
var Stack;
|
||||
var object;
|
||||
var value12;
|
||||
var items4;
|
||||
var moduleValue3;
|
||||
const onMessage = a0.onMessage;
|
||||
a0.onClose;
|
||||
const binding = env0_4;
|
||||
const value2 = undefined;
|
||||
const value3 = binding(a0, env0_3);
|
||||
const styles = useStyles();
|
||||
const currentUser = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
|
||||
return UserStore.getCurrentUser();
|
||||
});
|
||||
const value4 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
|
||||
const getState = value4.getState;
|
||||
const routes = Reflect.apply(getState, value4, []).routes;
|
||||
let r4 = routes.length > 0 && routes[0].name === 'auth';
|
||||
r4 = !r4 ? (currentUser == null ? value2 : currentUser.ageVerificationStatus) === (require(1909) /* metro dependency 1909: Server */).AgeVerificationStatusUkAndAusOnly.CLIENT_ONLY_PENDING : r4;
|
||||
const value8 = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)();
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
const value9 = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t.wsoPhr]);
|
||||
const value10 = env0_5.useCallback(_fun119776, [onMessage]);
|
||||
(importDefault(4571) /* metro dependency 4571: useBackPressHandler */)(_fun119777);
|
||||
if (r4) {
|
||||
r5 = !r4;
|
||||
} else {
|
||||
Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack;
|
||||
object = {};
|
||||
value12 = 16;
|
||||
object.spacing = importDefault(dependencyMap[value12]).space.PX_16;
|
||||
object.align = 'center';
|
||||
items4 = [((Text) => <Text accessibilityRole="header" variant="heading-lg/bold" color="mobile-text-heading-primary" style={styles.title}>{value9}</Text>)((require(4573) /* metro dependency 4573: Text */).Text)];
|
||||
moduleValue3 = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
items4[1] = <ActivityIndicator size="small" color={moduleValue3.isAndroid() ? importDefault(dependencyMap[value12]).unsafe_rawColors.WHITE : value2} />;
|
||||
r5 = <Stack {...object}>{items4}</Stack>;
|
||||
}
|
||||
const items2 = [r5];
|
||||
items2[1] = <View style={StyleSheet.absoluteFillObject}>{((Component) => <Component {...value3} {...{['languageCode']: LocaleStore.locale}} {...{['onMessage']: onMessage}} />)(importDefault(15639) /* metro dependency 15639 */)}</View>;
|
||||
const items3 = [styles.closeButtonContainer];
|
||||
const object3 = {};
|
||||
const top = value8.top;
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.paddingTop = top + PX_8;
|
||||
const left = value8.left;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object3.paddingLeft = left + PX_16;
|
||||
items3[1] = object3;
|
||||
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
|
||||
string = intl.string;
|
||||
const cpT0Cq = (require(1244) /* metro dependency 1244: indexNative */).t.cpT0Cq;
|
||||
const XLargeIcon = (require(4066) /* metro dependency 4066: XLargeIcon */).XLargeIcon;
|
||||
const INTERACTIVE_ICON_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_ICON_DEFAULT;
|
||||
items2[2] = <View style={items3} pointerEvents="box-none"><PressableOpacity accessibilityRole="button" accessibilityLabel={Reflect.apply(string,
|
||||
intl,
|
||||
[cpT0Cq])} onPress={value10} style={styles.closeButtonHitArea}><XLargeIcon color={INTERACTIVE_ICON_DEFAULT} /></PressableOpacity></View>;
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
{items2}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun119776() { // fn#119776, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15848:923, offset: 0x025192b7, size: 76 bytes, params: 1, frame: 14
|
||||
var object;
|
||||
let onMessageBinding = onMessage;
|
||||
if (onMessageBinding != null) {
|
||||
onMessageBinding = onMessage;
|
||||
object = {};
|
||||
value = environment.__proto__;
|
||||
object.data = (require(9486) /* metro dependency 9486: SharedCaptchaUtils */).CaptchaError.CANCEL;
|
||||
onMessageBinding({nativeEvent: object});
|
||||
}
|
||||
}
|
||||
|
||||
function _fun119777() { // fn#119777, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15848:1014, offset: 0x02519303, size: 17 bytes, params: 1, frame: 9
|
||||
env0_1();
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user