2026-07-25 08:10:48 +00:00
|
|
|
// Module ID: 8842
|
2026-07-27 11:26:19 +00:00
|
|
|
// Function ID: 70036
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: SecureFramesUserVerificationBottomSheet
|
2026-07-25 08:10:48 +00:00
|
|
|
// Dependencies: [57, 31, 27, 4203, 1850, 8826, 653, 33, 4131, 689, 8830, 8843, 8805, 8832, 566, 8835, 5656, 4320, 8824, 8834, 8623, 8844, 4099, 3832, 4092, 1212, 5187, 5186, 5499, 4127, 8836, 4542, 4544, 2]
|
2026-07-20 16:05:17 +00:00
|
|
|
// Exports: default
|
|
|
|
|
|
2026-07-25 08:10:48 +00:00
|
|
|
// Module 8842 (SecureFramesUserVerificationBottomSheet)
|
2026-07-23 10:11:24 +00:00
|
|
|
import _slicedToArray from "_slicedToArray";
|
|
|
|
|
import Stack from "Stack";
|
|
|
|
|
import get_ActivityIndicator from "RedesignBottomSheetTitleHeaderBase";
|
|
|
|
|
import _isNativeReflectConstruct from "_isNativeReflectConstruct";
|
|
|
|
|
import closure_8 from "_isNativeReflectConstruct";
|
|
|
|
|
import SECURE_FRAMES_LINKING_BOTTOM_SHEET_KEY from "SECURE_FRAMES_LINKING_BOTTOM_SHEET_KEY";
|
|
|
|
|
import { AnalyticsLocations } from "ME";
|
|
|
|
|
import jsxProd from "set";
|
|
|
|
|
import _createForOfIteratorHelperLoose from "_createForOfIteratorHelperLoose";
|
|
|
|
|
|
|
|
|
|
let closure_10;
|
|
|
|
|
let closure_11;
|
|
|
|
|
let closure_13;
|
|
|
|
|
let closure_14;
|
|
|
|
|
let closure_5;
|
|
|
|
|
let closure_6;
|
|
|
|
|
let closure_9;
|
|
|
|
|
const require = arg1;
|
|
|
|
|
({ ActivityIndicator: closure_5, View: closure_6 } = get_ActivityIndicator);
|
|
|
|
|
({ AnalyticsSecureFramesUserVerification: closure_9, SECURE_FRAMES_PUBLIC_KEY_VERSION: closure_10, USER_VERIFIED_TOAST_KEY: closure_11 } = SECURE_FRAMES_LINKING_BOTTOM_SHEET_KEY);
|
|
|
|
|
({ jsx: closure_13, jsxs: closure_14 } = jsxProd);
|
|
|
|
|
_createForOfIteratorHelperLoose = {};
|
|
|
|
|
_createForOfIteratorHelperLoose = { height: 80, width: 80, borderRadius: 40, alignItems: "center", justifyContent: "center", backgroundColor: require("_createForOfIteratorHelperLoose").colors.BACKGROUND_MOD_STRONG, marginBottom: 16 };
|
|
|
|
|
_createForOfIteratorHelperLoose.iconContainer = _createForOfIteratorHelperLoose;
|
|
|
|
|
_createForOfIteratorHelperLoose.icon = { height: 48, width: 48 };
|
|
|
|
|
_createForOfIteratorHelperLoose.content = { padding: 16, justifyContent: "center", alignItems: "center" };
|
|
|
|
|
_createForOfIteratorHelperLoose.subtitle = { textAlign: "center", marginTop: 8, marginBottom: 40 };
|
|
|
|
|
_createForOfIteratorHelperLoose.buttons = { marginTop: 40 };
|
|
|
|
|
_createForOfIteratorHelperLoose.helpMessage = { marginTop: 16 };
|
|
|
|
|
_createForOfIteratorHelperLoose = _createForOfIteratorHelperLoose.createStyles(_createForOfIteratorHelperLoose);
|
|
|
|
|
let result = require("get ActivityIndicator").fileFinishedImporting("modules/rtc/native/SecureFramesUserVerificationBottomSheet.tsx");
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
export default function SecureFramesUserVerificationBottomSheet(userId) {
|
|
|
|
|
let tmp14;
|
|
|
|
|
let tmp15;
|
|
|
|
|
userId = userId.userId;
|
|
|
|
|
const channelId = userId.channelId;
|
|
|
|
|
const fingerprint = userId.fingerprint;
|
2026-07-23 10:11:24 +00:00
|
|
|
let tmp = _createForOfIteratorHelperLoose();
|
2026-07-20 16:05:17 +00:00
|
|
|
let callback = tmp;
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj = userId(fingerprint[10]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const secureFramesPairwiseFingerprint = obj.useSecureFramesPairwiseFingerprint({ userId });
|
|
|
|
|
const userKey = secureFramesPairwiseFingerprint.userKey;
|
|
|
|
|
const fingerprint2 = secureFramesPairwiseFingerprint.fingerprint;
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj1 = userId(fingerprint[11]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const isSecureFramesUIEnabled = obj1.useIsSecureFramesUIEnabled({ channelId });
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj2 = userId(fingerprint[12]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const isUserSecureFramesVerified = obj2.useIsUserSecureFramesVerified({ userId, channelId });
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj3 = userId(fingerprint[13]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const isPersistentSecureFramesFingerprint = obj3.useIsPersistentSecureFramesFingerprint({ userId });
|
|
|
|
|
const isOtherUserKeyPersistent = isPersistentSecureFramesFingerprint.isOtherUserKeyPersistent;
|
|
|
|
|
let loading = isPersistentSecureFramesFingerprint.loading;
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj4 = userId(fingerprint[14]);
|
|
|
|
|
const items = [isUserSecureFramesVerified];
|
2026-07-20 16:05:17 +00:00
|
|
|
const stateFromStores = obj4.useStateFromStores(items, () => isUserSecureFramesVerified.isConnected());
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj5 = userId(fingerprint[14]);
|
|
|
|
|
const items1 = [isUserSecureFramesVerified];
|
2026-07-20 16:05:17 +00:00
|
|
|
const stateFromStores1 = obj5.useStateFromStores(items1, () => isUserSecureFramesVerified.isUserConnected(userId));
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj6 = userId(fingerprint[15]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const isSecureFramesKeyInconsistent = obj6.useIsSecureFramesKeyInconsistent({ userId });
|
|
|
|
|
const items2 = [fingerprint, channelId, fingerprint2, stateFromStores, isSecureFramesKeyInconsistent, stateFromStores1, isSecureFramesUIEnabled, isUserSecureFramesVerified];
|
2026-07-23 10:11:24 +00:00
|
|
|
const memo = userKey.useMemo(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
if (null != channelId) {
|
|
|
|
|
if (stateFromStores) {
|
|
|
|
|
if (!stateFromStores1) {
|
|
|
|
|
const OTHER_USER_DISCONNECTED = stateFromStores.OTHER_USER_DISCONNECTED;
|
|
|
|
|
}
|
|
|
|
|
if (!isSecureFramesUIEnabled) {
|
|
|
|
|
const UNABLE_TO_VERIFY = stateFromStores.UNABLE_TO_VERIFY;
|
|
|
|
|
}
|
|
|
|
|
if (isUserSecureFramesVerified) {
|
|
|
|
|
let MATCH = stateFromStores.OTHER_USER_ALREADY_VERIFIED;
|
|
|
|
|
} else if (isSecureFramesKeyInconsistent) {
|
|
|
|
|
MATCH = stateFromStores.OTHER_USER_INCONSISTENT_KEYS;
|
|
|
|
|
} else if (fingerprint !== fingerprint2) {
|
|
|
|
|
MATCH = stateFromStores.FINGERPRINT_MISMATCH;
|
|
|
|
|
} else {
|
|
|
|
|
MATCH = stateFromStores.MATCH;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return stateFromStores.CURRENT_USER_DISCONNECTED;
|
|
|
|
|
}, items2);
|
|
|
|
|
const items3 = [userId];
|
2026-07-23 10:11:24 +00:00
|
|
|
const effect = userKey.useEffect(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
const user = userId(fingerprint[16]).getUser(userId);
|
|
|
|
|
}, items3);
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj7 = userId(fingerprint[14]);
|
|
|
|
|
const items4 = [isOtherUserKeyPersistent];
|
2026-07-20 16:05:17 +00:00
|
|
|
const stateFromStores2 = obj7.useStateFromStores(items4, () => isOtherUserKeyPersistent.getUser(userId));
|
2026-07-23 10:11:24 +00:00
|
|
|
let obj8 = channelId(fingerprint[17]);
|
2026-07-20 16:05:17 +00:00
|
|
|
const name = obj8.useName(userId.guildId, channelId, stateFromStores2);
|
|
|
|
|
const items5 = [memo, name];
|
|
|
|
|
const items6 = [channelId, memo, userId];
|
2026-07-23 10:11:24 +00:00
|
|
|
[tmp14, tmp15] = callback(userKey.useMemo(() => userId(fingerprint[18]).getUserVerifyStateText(memo, name), items5), 2);
|
|
|
|
|
const effect1 = userKey.useEffect(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
if (stateFromStores.OTHER_USER_ALREADY_VERIFIED !== memo) {
|
|
|
|
|
if (stateFromStores.MATCH !== tmp) {
|
|
|
|
|
let obj = userId(fingerprint[19]);
|
|
|
|
|
obj = { channelId, userId, reason: memo, keyVersion: stateFromStores1 };
|
|
|
|
|
const result = obj.trackE2EEUserVerificationFailed(obj);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}, items6);
|
|
|
|
|
const items7 = [memo, tmp.icon];
|
2026-07-23 10:11:24 +00:00
|
|
|
let memo1 = userKey.useMemo(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
if (stateFromStores.OTHER_USER_ALREADY_VERIFIED !== memo) {
|
|
|
|
|
if (stateFromStores.MATCH !== tmp) {
|
|
|
|
|
let obj = { style: tmp.icon, color: channelId(fingerprint[9]).colors.TEXT_FEEDBACK_CRITICAL };
|
|
|
|
|
return name(userId(fingerprint[21]).XLargeBoldIcon, obj);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
obj = { style: tmp.icon, color: channelId(fingerprint[9]).colors.TEXT_FEEDBACK_POSITIVE };
|
|
|
|
|
return name(userId(fingerprint[20]).CheckmarkLargeBoldIcon, obj);
|
|
|
|
|
}, items7);
|
2026-07-23 10:11:24 +00:00
|
|
|
callback = userKey.useCallback(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
channelId(fingerprint[22]).hideActionSheet();
|
|
|
|
|
}, []);
|
|
|
|
|
const items8 = [channelId, userKey, isOtherUserKeyPersistent, name, userId];
|
2026-07-23 10:11:24 +00:00
|
|
|
const callback1 = userKey.useCallback(() => {
|
2026-07-20 16:05:17 +00:00
|
|
|
let tmp = null != channelId;
|
|
|
|
|
if (tmp) {
|
|
|
|
|
tmp = null != userKey;
|
|
|
|
|
}
|
|
|
|
|
if (tmp) {
|
|
|
|
|
let obj = userId(fingerprint[18]);
|
|
|
|
|
obj.addVerification(userId, userKey, isOtherUserKeyPersistent, channelId, memo.DEEP_LINK);
|
|
|
|
|
channelId(fingerprint[22]).hideActionSheet();
|
|
|
|
|
const obj2 = channelId(fingerprint[22]);
|
|
|
|
|
obj = { key: isSecureFramesKeyInconsistent, iconColor: "text-feedback-positive", IconComponent: userId(fingerprint[24]).CircleCheckIcon };
|
|
|
|
|
const intl = userId(fingerprint[25]).intl;
|
|
|
|
|
obj = { username: name };
|
|
|
|
|
obj.content = intl.formatToPlainString(userId(fingerprint[25]).t.Gwu134, obj);
|
|
|
|
|
channelId(fingerprint[23]).open(obj);
|
|
|
|
|
const obj3 = channelId(fingerprint[23]);
|
|
|
|
|
}
|
|
|
|
|
}, items8);
|
|
|
|
|
obj = { startExpanded: true };
|
2026-07-23 10:11:24 +00:00
|
|
|
obj = { title: null, leading: name(userId(fingerprint[28]).ActionSheetCloseButton, { onPress: callback }) };
|
|
|
|
|
obj.header = name(userId(fingerprint[27]).BottomSheetTitleHeader, obj);
|
2026-07-20 16:05:17 +00:00
|
|
|
obj1 = { style: tmp.content };
|
|
|
|
|
obj2 = { style: tmp.iconContainer };
|
|
|
|
|
if (!loading) {
|
|
|
|
|
obj2.children = memo1;
|
|
|
|
|
const items9 = [tmp20(tmp22, obj2), , , , ];
|
2026-07-23 10:11:24 +00:00
|
|
|
obj3 = { variant: "heading-xl/bold", color: "mobile-text-heading-primary", children: tmp14 };
|
|
|
|
|
items9[1] = name(userId(fingerprint[29]).Text, obj3);
|
|
|
|
|
obj4 = { style: tmp.subtitle, variant: "text-md/medium", color: "text-default", children: tmp15 };
|
|
|
|
|
items9[2] = name(userId(fingerprint[29]).Text, obj4);
|
2026-07-20 16:05:17 +00:00
|
|
|
obj5 = { style: tmp.helpMessage, userId, userKey };
|
2026-07-23 10:11:24 +00:00
|
|
|
items9[3] = name(channelId(fingerprint[30]), obj5);
|
2026-07-20 16:05:17 +00:00
|
|
|
obj6 = { spacing: 12, style: tmp.buttons };
|
|
|
|
|
obj7 = { variant: "primary", onPress: callback1 };
|
2026-07-23 10:11:24 +00:00
|
|
|
let intl = userId(fingerprint[25]).intl;
|
|
|
|
|
obj7.text = intl.string(userId(fingerprint[25]).t["0tvNAn"]);
|
2026-07-20 16:05:17 +00:00
|
|
|
if (!loading) {
|
|
|
|
|
loading = memo !== stateFromStores.MATCH;
|
|
|
|
|
}
|
|
|
|
|
obj7.disabled = loading;
|
2026-07-23 10:11:24 +00:00
|
|
|
const items10 = [name(userId(fingerprint[32]).Button, obj7), ];
|
2026-07-20 16:05:17 +00:00
|
|
|
obj8 = { variant: "secondary", onPress: callback };
|
2026-07-23 10:11:24 +00:00
|
|
|
const intl2 = userId(fingerprint[25]).intl;
|
|
|
|
|
obj8.text = intl2.string(userId(fingerprint[25]).t["ETE/oC"]);
|
|
|
|
|
items10[1] = name(userId(fingerprint[32]).Button, obj8);
|
2026-07-20 16:05:17 +00:00
|
|
|
obj6.children = items10;
|
2026-07-23 10:11:24 +00:00
|
|
|
items9[4] = closure_14(userId(fingerprint[31]).Stack, obj6);
|
2026-07-20 16:05:17 +00:00
|
|
|
obj1.children = items9;
|
|
|
|
|
obj.children = tmp21(tmp22, obj1);
|
2026-07-23 10:11:24 +00:00
|
|
|
return tmp20(userId(fingerprint[26]).BottomSheet, obj);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
memo1 = name(fingerprint2, {});
|
|
|
|
|
};
|