Initial commit

This commit is contained in:
janisslsm committed 2026-07-27 16:20:00 +03:00
commit af3b49f756
16065 files changed
+2938410

No files matched your search

@@ -0,0 +1,17 @@
/* Metro module 15246; source: modules/message_request/native/MessageRequestEmpty.tsx; dependencies: [31, 33, 1305, 15247, 2] */
function _fun116602(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116602, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15443:6, offset: 0x0248fcb1, size: 131 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_2 = (require(33) /* metro dependency 33 */).jsx;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/MessageRequestEmpty.tsx');
exports.default = MessageRequestEmpty;
}
function MessageRequestEmpty({bodyText}) { // fn#116603, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15443:216, offset: 0x0248fd34, size: 81 bytes, params: 2, frame: 17
const EmptyState = (require(1305) /* metro dependency 1305: native */).EmptyState;
const Pending = (require(15247) /* metro dependency 15247: Pending */).Pending;
return <EmptyState Illustration={Pending} body={bodyText} />;
}
@@ -0,0 +1,250 @@
/* Metro module 15235; source: modules/message_request/native/MessageRequestList.tsx; dependencies: [31, 27, 661, 33, 4501, 697, 1244, 3857, 8947, 4601, 5080, 11898, 683, 5278, 15236, 1305, 8096, 13436, 7972, 1585, 15241, 15243, 11896, 15246, 477, 4573, 15251, 2] */
function _fun116540(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116540, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:6, offset: 0x0248d4a3, size: 586 bytes, params: 8, frame: 22
var object2;
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.ActivityIndicator;
const env0_5 = value.View;
const env0_6 = value.FlatList;
const env0_7 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
value = require(33) /* metro dependency 33 */;
const env0_8 = value.jsx;
const env0_9 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
let BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.sectionContainer = {'backgroundColor': null, 'flexDirection': 'row', 'justifyContent': 'space-between',
'marginTop': 6, 'marginBottom': 10, backgroundColor: BACKGROUND_BASE_LOW};
object2.rowContainer = {'flexDirection': 'row', 'alignItems': 'center', 'justifyContent': 'space-between',
'marginTop': 14, 'marginBottom': 12};
object2.actionContainer = {'flexDirection': 'row', 'alignItems': 'flex-start', 'height': '100%'};
const object4 = {'backgroundColor': null, 'tintColor': null, 'borderRadius': null, 'alignItems': 'center',
'justifyContent': 'center', 'height': 32, 'width': 32};
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object4.backgroundColor = BACKGROUND_SURFACE_HIGH;
const INTERACTIVE_TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_TEXT_DEFAULT;
object4.tintColor = INTERACTIVE_TEXT_DEFAULT;
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
object2.actionButton = object4;
object2.acceptButton = {marginRight: 16};
const object6 = {};
object6.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
object2.pressableRow = object6;
object2.activityIndicator = {'height': 16, 'width': 16};
BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.list = {'flex': 1, 'paddingHorizontal': 16, 'alignSelf': 'stretch', backgroundColor: BACKGROUND_BASE_LOW};
const env0_10 = Reflect.apply(createStyles, value, [object2]);
object2 = {ACCEPT_MESSAGE_REQUEST: 'accept-message-request', IGNORE_MESSAGE_REQUEST: 'ignore-message-request',
PREVIEW_MESSAGE_REQUEST: 'preview-message-request'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/MessageRequestList.tsx');
exports.default = MessageRequestList;
}
function PendingMessageRequestRow({messageRequest, goToMessageRequestPreview, isLastRow, hasSingleMessageRequest}) { // fn#116541, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:1194, offset: 0x0248d6ed, size: 1331 bytes, params: 2, frame: 45
var object11;
const styles = useStyles();
const user = messageRequest.user;
let channel = messageRequest.channel;
const env0_3 = channel;
const id = channel.id;
let binding = env0_3;
let useCallback = binding.useCallback;
let closure = function() {
var defaultImport = importDefault(dependencyMap[7]);
var object = {key: 'MESSAGE_REQUEST_REQUEST_ERROR_ALERT_TITLE'};
object.content = require(dependencyMap[6]).intl.string(require(dependencyMap[6]).t['EDYbS+']);
object.icon = importDefault(dependencyMap[8]);
defaultImport.open(object);
};
const value3 = Reflect.apply(useCallback, binding, [closure, []]);
binding = env0_3;
useCallback = binding.useCallback;
const value5 = (require(11898) /* metro dependency 11898: useMessageRequestActions */).useMessageRequestActions({user: user,
onAcceptSuccess: Reflect.apply(useCallback, binding, [_fun116543, [id, hasSingleMessageRequest]]),
onError: value3});
const env0_5 = value5.acceptMessageRequest;
const env0_6 = value5.rejectMessageRequest;
const isAcceptLoading = value5.isAcceptLoading;
const isRejectLoading = value5.isRejectLoading;
const isUserProfileLoading = value5.isUserProfileLoading;
const isOptimisticAccepted = value5.isOptimisticAccepted;
const isOptimisticRejected = value5.isOptimisticRejected;
closure = function() {
rejectMessageRequest(channel.id);
};
const closure2 = function() {
acceptMessageRequest(channel.id);
};
const closure3 = function() {
var defaultImport = importDefault(dependencyMap[12]);
var MESSAGE_REQUEST_PREVIEW_VIEWED = AnalyticEvents.MESSAGE_REQUEST_PREVIEW_VIEWED;
defaultImport.track(MESSAGE_REQUEST_PREVIEW_VIEWED, {is_spam: false, channel_id: channel.id,
other_user_id: user.id});
goToMessageRequestPreview();
};
let r20 = isAcceptLoading || isRejectLoading;
r20 = !r20 ? isUserProfileLoading : r20;
r20 = !r20 ? isOptimisticAccepted : r20;
r20 = !r20 ? isOptimisticRejected : r20;
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
object11 = {onPress: closure3, accessibilityRole: 'button'};
const object5 = {};
const ACCEPT_MESSAGE_REQUEST = env0_11.ACCEPT_MESSAGE_REQUEST;
object5.name = ACCEPT_MESSAGE_REQUEST;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object5.label = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t.hSLLWi]);
const items2 = [object5];
const object6 = {};
const IGNORE_MESSAGE_REQUEST = env0_11.IGNORE_MESSAGE_REQUEST;
object6.name = IGNORE_MESSAGE_REQUEST;
object6.label = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.fIBuSD);
items2[1] = object6;
const object7 = {};
const PREVIEW_MESSAGE_REQUEST = env0_11.PREVIEW_MESSAGE_REQUEST;
object7.name = PREVIEW_MESSAGE_REQUEST;
string = intl.string;
const HjgsKJ = (require(1244) /* metro dependency 1244: indexNative */).t.HjgsKJ;
object7.label = Reflect.apply(string, intl, [HjgsKJ]);
items2[2] = object7;
object11.accessibilityActions = items2;
object11.onAccessibilityAction = onAccessibilityAction_116547;
object11.style = styles.pressableRow;
const MessageRequestRowSenderDetails = importDefault(15236) /* metro dependency 15236: MessageRequestRowSenderDetails */;
channel = messageRequest.channel;
const user2 = messageRequest.user;
const messageRequestRowSenderDetails = <MessageRequestRowSenderDetails channel={channel} otherUser={user2} />;
const PressableOpacity2 = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
let formatToPlainString = intl.formatToPlainString;
let property = (require(1244) /* metro dependency 1244: indexNative */).t['6p0yBo'];
const object8 = {};
object8.name = user?.toString();
const pressableOpacity = <PressableOpacity2 accessibilityRole="button" accessibilityLabel={Reflect.apply(formatToPlainString,
intl, [property, object8])} onPress={closure2} disabled={r20} style={[styles.actionButton,
styles.acceptButton]}>{isAcceptLoading || isUserProfileLoading || isOptimisticAccepted ? <ActivityIndicator style={styles.activityIndicator} /> : ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.SMALL} disableColor source={importDefault(8096) /* metro dependency 8096 */} />)((require(1305) /* metro dependency 1305: native */).Icon)}</PressableOpacity2>;
const PressableOpacity3 = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
formatToPlainString = intl.formatToPlainString;
property = (require(1244) /* metro dependency 1244: indexNative */).t['C9Xe6+'];
const object10 = {};
object10.name = user?.toString();
return (
<PressableOpacity {...object11}>
<View style={styles.rowContainer}>
{messageRequestRowSenderDetails}
<View style={styles.actionContainer}>
{pressableOpacity}
<PressableOpacity3
accessibilityRole="button"
accessibilityLabel={Reflect.apply(formatToPlainString, intl, [property, object10])}
onPress={closure}
disabled={r20}
style={styles.actionButton}
>
{isRejectLoading || isOptimisticRejected ? <ActivityIndicator style={styles.activityIndicator} /> : ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.SMALL} disableColor source={importDefault(13436) /* metro dependency 13436 */} />)((require(1305) /* metro dependency 1305: native */).Icon)}
</PressableOpacity3>
</View>
</View>
{isLastRow ? null : ((FormDivider) => <FormDivider iconPush outer />)((require(7972) /* metro dependency 7972: native */).FormDivider)}
</PressableOpacity>
);
}
function MessageRequestList({goToMessageRequestPreview}) { // fn#116548, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:3696, offset: 0x0248dde7, size: 414 bytes, params: 2, frame: 24
var MessageRequestEmpty;
var intl;
const styles = useStyles();
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const value2 = (importDefault(15241) /* metro dependency 15241: useSortedMessageRequests */)();
const env0_3 = (require(15243) /* metro dependency 15243: useListHasSingleMessageRequest */).useListHasSingleMessageRequest();
const env0_4 = (require(11896) /* metro dependency 11896: useIsMessageRequestRestrictedViewer */).useIsMessageRequestRestrictedViewer('MessageRequestList');
if (value2.length === 0) {
MessageRequestEmpty = importDefault(15246) /* metro dependency 15246: MessageRequestEmpty */;
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return <MessageRequestEmpty bodyText={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.SXrqTf)} />;
}
const items2 = ['header-section'];
arraySpread(items2, value2, 1, undefined);
const items3 = [styles.list];
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
items3[1] = {marginBottom: platformUtilsModule.isAndroid() ? bottom : 0};
return (
<FlatList
style={items3}
scrollIndicatorInsets={{right: 0.01}}
contentContainerStyle={{paddingBottom: bottom, paddingTop: 12}}
renderItem={renderItem_116549}
data={items2}
/>
);
}
function _fun116543() { // fn#116543, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:1523, offset: 0x0248dc99, size: 80 bytes, params: 1, frame: 14
var value2;
var moduleValue;
if (hasSingleMessageRequest) {
value2 = environment.__proto__;
moduleValue = require(4601) /* metro dependency 4601: transitionToChannel */;
moduleValue.transitionToChannel(id);
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).pop();
}
}
function PendingMessageRequestRowOnAccessibilityAction({nativeEvent}) { // fn#116547, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:2409, owner: PendingMessageRequestRow.onAccessibilityAction, offset: 0x0248dd7a, size: 109 bytes, params: 2, frame: 10
const actionName = nativeEvent.actionName;
const ACCEPT_MESSAGE_REQUEST = env1_11.ACCEPT_MESSAGE_REQUEST;
if (ACCEPT_MESSAGE_REQUEST === actionName) {
onPress_116545();
} else {
var IGNORE_MESSAGE_REQUEST = env1_11.IGNORE_MESSAGE_REQUEST;
if (IGNORE_MESSAGE_REQUEST === actionName) {
onPress_116544();
return undefined;
}
var PREVIEW_MESSAGE_REQUEST = env1_11.PREVIEW_MESSAGE_REQUEST;
if (PREVIEW_MESSAGE_REQUEST === actionName) {
onPress_116546();
return undefined;
}
}
}
function MessageRequestListRenderItem({item}) { // fn#116549, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15432:4191, owner: MessageRequestList.renderItem, offset: 0x0248df85, size: 384 bytes, params: 2, frame: 23
var environment;
var r0;
var value;
var Text;
var intl;
if (typeof item === 'string') {
value = environment.__proto__;
var viewBindingProps = {style: styles.sectionContainer};
Text = (require(4573) /* metro dependency 4573: Text */).Text;
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<View {...viewBindingProps}>
<Text variant="eyebrow" color="text-default">
{intl.format((require(1244) /* metro dependency 1244: indexNative */).t.evH4Yb,
{pendingRequestNumber: env0_2.length})}
</Text>
</View>
);
}
const id2 = item.channel.id;
const binding = env0_2;
const property = binding[binding.length - 1];
const value3 = id2 === (property == null ? undefined : property.channel.id);
if (env0_4) {
value = importDefault(15251) /* metro dependency 15251: RestrictedMessageRequestRow */;
value = ((Component) => <Component messageRequest={item} goToMessageRequestPreview={function() {
return goToMessageRequestPreview(item.channel.id);
}} isLastRow={value3} key={item.channel.id} />)(value);
r0 = value;
} else {
r0 = <PendingMessageRequestRow messageRequest={item} goToMessageRequestPreview={goToMessageRequestPreview} isLastRow={value3} hasSingleMessageRequest={env0_3} key={item.channel.id} />;
}
return r0;
}
@@ -0,0 +1,49 @@
/* Metro module 15239; source: modules/message_request/native/MessageRequestMutualServers.tsx; dependencies: [31, 27, 33, 4501, 6819, 15240, 8863, 4573, 1244, 5278, 2] */
function _fun116565(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116565, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15436:6, offset: 0x0248f000, size: 225 bytes, params: 8, frame: 20
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_3 = (require(27) /* metro dependency 27 */).View;
const value = require(33) /* metro dependency 33 */;
const env0_4 = value.jsx;
const env0_5 = value.jsxs;
const env0_6 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({container: {'flexDirection': 'row',
'alignItems': 'center', 'gap': 4}, label: {flexShrink: 1}});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/MessageRequestMutualServers.tsx');
exports.default = MessageRequestMutualServers;
}
function MessageRequestMutualServers({userId, style, onPress, iconSize = require(dependencyMap[4]).GuildIconSizes.XXSMALL_12, textVariant}) { // fn#116566, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15436:358, offset: 0x0248f0e1, size: 557 bytes, params: 2, frame: 27
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
textVariant = textVariant === undefined ? 'text-xs/medium' : textVariant;
const styles = useStyles();
const value2 = (require(15240) /* metro dependency 15240: useMutualGuilds */).useMutualGuildsForMessageRequests(userId);
const length = value2.length;
const value3 = value2.slice(0, 3);
const items2 = [styles.container, style];
const r9 = length > 0 && ((GuildIconPile) => <GuildIconPile size={iconSize} names={value3.map(function(a0) {
return a0.name;
})}>{value3.map(_fun116568)}</GuildIconPile>)((require(8863) /* metro dependency 8863: GuildIconPileNative */).GuildIconPile);
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const view = <View style={items2}>{r9}<Text variant={textVariant} color="text-muted" lineClamp={1} style={styles.label}>{length > 0 ? intl.format((require(1244) /* metro dependency 1244: indexNative */).t.eE3oep,
{count: length}) : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.jpY0X5)}</Text></View>;
if (onPress == null) {
return view;
} else if (length > 0) {
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
return (
<PressableOpacity accessibilityRole="button" onPress={onPress}>
{view}
</PressableOpacity>
);
} else {
return view;
}
}
function _fun116568(a0) { // fn#116568, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15436:701, offset: 0x0248f30e, size: 63 bytes, params: 2, frame: 16
const value = environment.__proto__;
return ((Component) => <Component guild={a0} size={env0_0} key={a0.id} />)(importDefault(6819) /* metro dependency 6819: GuildIcon */);
}
@@ -0,0 +1,336 @@
/* Metro module 15238; source: modules/message_request/native/MessageRequestPreview.tsx; dependencies: [31, 27, 3793, 661, 33, 4501, 6597, 697, 11942, 566, 683, 1244, 8349, 4643, 1305, 2] */
function _fun116561(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116561, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15435:6, offset: 0x0248e950, size: 402 bytes, params: 8, frame: 28
var object4;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const relationshipStore = importDefault(3793) /* metro dependency 3793: RelationshipStore */;
const constantsModule = require(661) /* metro dependency 661: Constants */;
const Fonts = constantsModule.Fonts;
const env0_6 = constantsModule.AnalyticEvents;
const env0_7 = constantsModule.MessageFlags;
const env0_8 = (require(33) /* metro dependency 33 */).jsx;
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = createStylesModule.createStyles;
object4 = {};
const object5 = {fontStyle: 'italic'};
const textStyles = importDefault(6597) /* metro dependency 6597: TextStyles */;
let PRIMARY_MEDIUM = Fonts.PRIMARY_MEDIUM;
let TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_DEFAULT;
copyDataProperties(object5, textStyles(PRIMARY_MEDIUM, TEXT_DEFAULT, 12), undefined);
object5['lineHeight'] = 16;
object4.systemContent = object5;
const object6 = {};
const value5 = textStyles;
PRIMARY_MEDIUM = Fonts.PRIMARY_MEDIUM;
TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_DEFAULT;
copyDataProperties(object6, value5(PRIMARY_MEDIUM, TEXT_DEFAULT, 12), undefined);
object6['lineHeight'] = 16;
object4.messageContent = object6;
const env0_9 = Reflect.apply(createStyles, createStylesModule, [object4]);
value = value.memo(MessageRequestPreview);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/MessageRequestPreview.tsx');
exports.default = value;
}
function MessageRequestPreview({channel, style}) { // fn#116562, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15435:441, offset: 0x0248eae2, size: 1116 bytes, params: 2, frame: 25
var content;
var r8;
var r1;
var r6;
var value5;
var value6;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var value7;
var moduleValue3;
var Array;
var value14;
var value15;
var value16;
var value17;
const styles = useStyles();
const {loaded, error,
message} = (require(11942) /* metro dependency 11942: useMessageRequestPreview */).useMessageRequestPreview(channel);
const {isBlocked,
isIgnored} = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([RelationshipStore],
_fun116563, [message]);
env0_3.useEffect(_fun116564, [channel, message]);
if (error) {
value17 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.BZHld2);
r1 = false;
r6 = value17;
} else {
value5 = null;
value6 = false;
if (loaded) {
if (value5 == message) {
if (value5 == message) {
content = value5 == message ? undefined : message.content;
if (value5 == content) {
if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
} else {
content = message.content;
if (content !== '') {
content = (importDefault(8349) /* metro dependency 8349: renderMessageMarkup */)(message,
{'noStyleAndInteraction': true, 'allowGameMentions': true}).content;
Array = global.Array;
if (Array.isArray(content)) {
if (content.length === 0) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
}
} else if (isIgnored) {
value15 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.uxrh1O);
r1 = value6;
r6 = value15;
} else {
content = value5 == message ? undefined : message.content;
if (value5 == content) {
if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
} else {
content = message.content;
if (content !== '') {
content = (importDefault(8349) /* metro dependency 8349: renderMessageMarkup */)(message,
{'noStyleAndInteraction': true, 'allowGameMentions': true}).content;
Array = global.Array;
if (Array.isArray(content)) {
if (content.length === 0) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
}
}
} else if (isBlocked) {
value16 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['WPe+xL']);
r1 = value6;
r6 = value16;
} else if (value5 == message) {
content = value5 == message ? undefined : message.content;
if (value5 == content) {
if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
} else {
content = message.content;
if (content !== '') {
content = (importDefault(8349) /* metro dependency 8349: renderMessageMarkup */)(message,
{'noStyleAndInteraction': true, 'allowGameMentions': true}).content;
Array = global.Array;
if (Array.isArray(content)) {
if (content.length === 0) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
}
} else if (isIgnored) {
value15 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.uxrh1O);
r1 = value6;
r6 = value15;
} else {
content = value5 == message ? undefined : message.content;
if (value5 == content) {
if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
} else {
content = message.content;
if (content !== '') {
content = (importDefault(8349) /* metro dependency 8349: renderMessageMarkup */)(message,
{'noStyleAndInteraction': true, 'allowGameMentions': true}).content;
Array = global.Array;
if (Array.isArray(content)) {
if (content.length === 0) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 == content) {
value14 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['262oPB']);
r1 = value6;
r6 = value14;
} else {
r1 = true;
r6 = content;
}
} else if (value5 != message) {
moduleValue3 = require(4643) /* metro dependency 4643: StickersUtils */;
r8 = moduleValue3.getMessageStickers(message).length > 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['zuI+by']) : value5 != message.interaction ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['2v7kfl']) : message.hasFlag(MessageFlags.IS_VOICE_MESSAGE) ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6bhHrc']) : message.hasFlag(MessageFlags.IS_COMPONENTS_V2) ? intl.string(t.Xxm5i3) : intl.string(t.LoMGlg);
r1 = value6;
r6 = r8;
} else {
value7 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0KfDxM']);
r1 = value6;
r6 = value7;
}
}
}
} else {
r1 = value6;
r6 = value5;
}
}
const r7 = r1 ? styles.messageContent : styles.systemContent;
const LegacyText = (require(1305) /* metro dependency 1305: native */).LegacyText;
return (
<View style={style}>
<LegacyText
style={r7}
numberOfLines={3}
ellipsizeMode="tail"
>
{r6}
</LegacyText>
</View>
);
}
function _fun116563() { // fn#116563, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15435:614, offset: 0x0248ef3e, size: 85 bytes, params: 1, frame: 15
return {isBlocked: message != null && RelationshipStore.isBlockedForMessage(message),
isIgnored: message != null && RelationshipStore.isIgnoredForMessage(message)};
}
function _fun116564() { // fn#116564, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15435:757, offset: 0x0248ef93, size: 109 bytes, params: 1, frame: 16
var value2;
var defaultImport;
var track;
var MESSAGE_REQUEST_PREVIEW_VIEWED;
var object2;
var channelBinding;
var id;
if (message != null) {
value2 = environment.__proto__;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
track = defaultImport.track;
MESSAGE_REQUEST_PREVIEW_VIEWED = AnalyticEvents.MESSAGE_REQUEST_PREVIEW_VIEWED;
object2 = {};
channelBinding = channel;
object2.is_spam = channelBinding.isSpam;
id = channelBinding.id;
object2.channel_id = id;
id = message.author.id;
object2.other_user_id = id;
Reflect.apply(track, defaultImport, [MESSAGE_REQUEST_PREVIEW_VIEWED, object2]);
}
}
@@ -0,0 +1,96 @@
/* Metro module 15236; source: modules/message_request/native/MessageRequestRowSenderDetails.tsx; dependencies: [31, 27, 3793, 33, 4501, 1305, 697, 566, 3995, 15237, 1426, 4573, 1244, 15238, 15239, 2] */
function _fun116552(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116552, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15433:6, offset: 0x0248e126, size: 435 bytes, params: 8, frame: 24
var object3;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_3 = (require(27) /* metro dependency 27 */).View;
const relationshipStore = importDefault(3793) /* metro dependency 3793: RelationshipStore */;
let value = require(33) /* metro dependency 33 */;
const env0_5 = value.jsx;
const env0_6 = value.jsxs;
const env0_7 = value.Fragment;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object3 = {};
const object4 = {};
const AVATAR_SIZE_MAP = (require(1305) /* metro dependency 1305: native */).AVATAR_SIZE_MAP;
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const NORMAL = AvatarSizes.NORMAL;
object4.borderRadius = AVATAR_SIZE_MAP[NORMAL] / 2;
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object4.backgroundColor = BACKGROUND_SURFACE_HIGH;
object3.avatar = object4;
object3.avatarContainer = {'marginRight': 16, 'alignItems': 'flex-start', 'height': '100%'};
object3.detailsContainer = {'marginRight': 8, 'justifyContent': 'flex-start', 'alignItems': 'flex-start', 'flex': 1};
object3.messageDetails = {'flexDirection': 'row', 'alignItems': 'center'};
const MOBILE_TEXT_HEADING_PRIMARY = (importDefault(697) /* metro dependency 697: native */).colors.MOBILE_TEXT_HEADING_PRIMARY;
object3.username = {flexShrink: 1, color: MOBILE_TEXT_HEADING_PRIMARY};
object3.timestampSeparator = {marginHorizontal: 6};
object3.messagePreview = {marginTop: 2};
object3.usernameTextContainer = {flexShrink: 1};
const env0_8 = Reflect.apply(createStyles, value, [object3]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/MessageRequestRowSenderDetails.tsx');
exports.default = MessageRequestRowSenderDetails;
}
function MessageRequestRowSenderDetails({channel, otherUser, isRestricted}) { // fn#116553, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15433:835, offset: 0x0248e2d9, size: 953 bytes, params: 2, frame: 38
var intl;
isRestricted = !(isRestricted === undefined) && isRestricted;
const styles = useStyles();
const value4 = (require(566) /* metro dependency 566: flux */).useStateFromStores([RelationshipStore], _fun116554);
const value5 = (require(15237) /* metro dependency 15237: useMessageRequestTimestampText */).useMessageRequestRelativeTimestampText(channel);
const Math = global.Math;
const floor = Math.floor;
const Math2 = global.Math;
const value6 = Math2.random();
let DEFAULT_AVATARS = (importDefault(1426) /* metro dependency 1426: AvatarUtils */).DEFAULT_AVATARS;
const value7 = Reflect.apply(floor, Math, [value6 * DEFAULT_AVATARS.length]);
DEFAULT_AVATARS = (importDefault(1426) /* metro dependency 1426: AvatarUtils */).DEFAULT_AVATARS;
const property = DEFAULT_AVATARS[value7];
const jsxRuntimeEnv0_7Binding = jsxRuntimeEnv0_7;
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const view = <View style={styles.avatarContainer}><Avatar {...otherUser != null ? {avatarStyle: styles.avatar,
user: otherUser, guildId: undefined, disablePlaceholder: true,
avatarDecoration: otherUser?.avatarDecoration} : {avatarStyle: styles.avatar, source: property}} /></View>;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const Text2 = (require(4573) /* metro dependency 4573: Text */).Text;
let r23 = value4 ?? otherUser?.username;
if (r23 == null) {
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
r23 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['30mdIx']);
}
const items4 = [<Text lineClamp={1} variant="text-md/semibold" color="mobile-text-heading-primary" style={styles.usernameTextContainer}><Text2 variant="text-md/semibold" color="mobile-text-heading-primary" style={styles.username}>{r23}</Text2>{value4 != null && <Text variant="text-md/medium" color="text-muted">{' '}{(require(3995) /* metro dependency 3995: UserUtils */).getUserTag(otherUser)}</Text>}</Text>];
items4[1] = <Text style={styles.timestampSeparator} variant="text-xs/medium" color="text-muted">{'·'}</Text>;
items4[2] = <Text variant="text-xs/semibold" color="text-muted">{value5}</Text>;
return (
<>
{view}
<View style={styles.detailsContainer}>
<View style={styles.messageDetails}>
{items4}
</View>
{!isRestricted && ((Component) => <Component style={styles.messagePreview} channel={channel} />)(importDefault(15238) /* metro dependency 15238: MessageRequestPreview */)}
{isRestricted && otherUser != null && ((Component) => <Component style={styles.messagePreview} userId={otherUser.id} />)(importDefault(15239) /* metro dependency 15239: MessageRequestMutualServers */)}
</View>
</>
);
}
function _fun116554() { // fn#116554, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15433:964, offset: 0x0248e692, size: 85 bytes, params: 1, frame: 14
var r1;
var defaultImport;
if (otherUser == null) {
return null;
}
const nickname = RelationshipStore.getNickname(otherUser.id);
if (nickname != null) {
r1 = nickname;
} else {
defaultImport = importDefault(3995) /* metro dependency 3995: UserUtils */;
r1 = defaultImport.getGlobalName(otherUser);
}
return r1;
}
@@ -0,0 +1,68 @@
/* Metro module 15258; source: modules/message_request/native/RestrictedMessagePreviewActions.tsx; dependencies: [31, 27, 661, 8781, 33, 4501, 697, 11940, 8783, 4080, 8794, 1962, 8153, 4603, 4578, 1244, 2] */
function _fun116664(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116664, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15455:6, offset: 0x02492167, size: 313 bytes, params: 8, frame: 22
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const env0_5 = (require(661) /* metro dependency 661: Constants */).AnalyticsPages;
const env0_6 = (require(8781) /* metro dependency 8781: RestrictionConfirmationConstants */).BLOCK_CONFIRMATION_ACTION_SHEET_KEY;
let value = require(33) /* metro dependency 33 */;
const env0_7 = value.jsx;
const env0_8 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const object = {'flexDirection': 'row', 'flexWrap': 'wrap'};
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object.gap = PX_8;
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object.marginVertical = PX_12;
const env0_9 = Reflect.apply(createStyles, value, [{container: object}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/RestrictedMessagePreviewActions.tsx');
exports.default = RestrictedMessagePreviewActions;
}
function RestrictedMessagePreviewActions({channel, user}) { // fn#116665, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15455:462, offset: 0x024922a0, size: 575 bytes, params: 2, frame: 31
const styles = useStyles();
const {message, isReportable,
isLoaded} = (require(11940) /* metro dependency 11940: useDMMessageToReport */).useDMMessageToReport(channel,
user.id, user.bot === true);
const binding = env0_3;
const value3 = binding.useCallback(function() {
importDefault(dependencyMap[8]).addRelationship({userId: user.id,
context: {location: AnalyticsPages.DM_CHANNEL}});
}, [user.id]);
const value4 = binding.useCallback(function() {
importDefault(dependencyMap[9]).openLazy(require(dependencyMap[11])(dependencyMap[10], dependencyMap.paths),
BLOCK_CONFIRMATION_ACTION_SHEET_KEY, {userId: user.id, channelId: channel.id});
}, [user.id, channel.id]);
const value5 = binding.useCallback(_fun116668, [message, channel.id]);
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const items2 = [<Button size="sm" variant="active" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['PMsq/b'])} onPress={value3} />];
items2[1] = <Button size="sm" variant="secondary" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.l4Emac)} onPress={value4} />;
items2[2] = isReportable && (message != null || !isLoaded) && <Button size="sm" variant="destructive" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.HHZmDn)} disabled={message == null} onPress={value5} />;
return (
<View style={styles.container}>
{items2}
</View>
);
}
function _fun116668() { // fn#116668, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15455:855, offset: 0x02492598, size: 67 bytes, params: 1, frame: 13
var environment;
var value2;
var moduleValue;
if (message != null) {
value2 = environment.__proto__;
moduleValue = require(8153) /* metro dependency 8153: ReportModals */;
moduleValue.showReportModalForFirstDM(message, _fun116669);
}
}
function _fun116669() { // fn#116669, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15455:907, offset: 0x024925db, size: 53 bytes, params: 1, frame: 14
let value = environment.__proto__.__proto__;
value = importDefault(4603) /* metro dependency 4603: ChannelActionCreators */;
value.closePrivateChannel(channel.id, true);
}
@@ -0,0 +1,101 @@
/* Metro module 15257; source: modules/message_request/native/RestrictedMessagePreviewHeader.tsx; dependencies: [31, 27, 11899, 33, 4501, 697, 6771, 3995, 8743, 6797, 3856, 4080, 8822, 1962, 8515, 6947, 5080, 5278, 1244, 1305, 4573, 15239, 6819, 15258, 2] */
function _fun116658(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116658, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:6, offset: 0x02491af3, size: 320 bytes, params: 8, frame: 22
var object3;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const env0_5 = (require(11899) /* metro dependency 11899: MessageRequestConstants */).MOBILE_MESSAGE_REQUESTS_MODAL_KEY;
let value = require(33) /* metro dependency 33 */;
const env0_6 = value.jsx;
const env0_7 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object3 = {};
const object4 = {alignItems: 'flex-start'};
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object4.gap = PX_8;
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object4.paddingVertical = PX_12;
object3.container = object4;
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
object3.avatar = {marginBottom: PX_4};
const env0_8 = Reflect.apply(createStyles, value, [object3]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/RestrictedMessagePreviewHeader.tsx');
exports.default = RestrictedMessagePreviewHeader;
}
function RestrictedMessagePreviewHeader({channel, user}) { // fn#116659, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:464, offset: 0x02491c33, size: 957 bytes, params: 2, frame: 33
const styles = useStyles();
const analyticsLocations = (importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */)().analyticsLocations;
const name = (importDefault(3995) /* metro dependency 3995: UserUtils */).getName(user);
const userTag = (importDefault(3995) /* metro dependency 3995: UserUtils */).getUserTag(user,
{'decoration': 'never', 'identifiable': 'always'});
const binding = userTag;
const useCallback = binding.useCallback;
let id = user.id;
const value4 = Reflect.apply(useCallback, binding, [_fun116660, [id, channel.id, analyticsLocations]]);
const value5 = binding.useCallback(_fun116661, [userTag]);
const value6 = binding.useCallback(_fun116662, [user]);
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
let iXAna6 = (require(1244) /* metro dependency 1244: indexNative */).t.iXAna6;
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const guild_id = channel.guild_id;
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const XXLARGE = AvatarSizes.XXLARGE;
const items2 = [<PressableOpacity accessibilityRole="button" accessibilityLabel={Reflect.apply(string, intl,
[iXAna6])} onPress={value4}><Avatar style={styles.avatar} user={user} guildId={guild_id} size={XXLARGE} avatarDecoration={user.avatarDecoration} /></PressableOpacity>];
string = intl.string;
iXAna6 = (require(1244) /* metro dependency 1244: indexNative */).t.iXAna6;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
items2[1] = <PressableOpacity accessibilityRole="button" accessibilityLabel={Reflect.apply(string, intl,
[iXAna6])} onPress={value4}><Text variant="heading-xxl/extrabold" color="mobile-text-heading-primary">{name}</Text></PressableOpacity>;
items2[2] = !user.isProvisional && <PressableOpacity accessibilityRole="button" accessibilityHint={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.y5MwJy)} onPress={value5}><Text variant="heading-lg/medium" color="text-default">{userTag}</Text></PressableOpacity>;
items2[3] = <Text variant="text-md/medium" color="text-default">{intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t['Qvg+6+'],
{username: name})}</Text>;
const messageRequestMutualServers = importDefault(15239) /* metro dependency 15239: MessageRequestMutualServers */;
id = user.id;
const GuildIconSizes = (require(6819) /* metro dependency 6819: GuildIcon */).GuildIconSizes;
const XSMALL = GuildIconSizes.XSMALL;
items2[4] = ((Component) => <Component userId={id} onPress={value6} iconSize={XSMALL} textVariant="text-md/medium" />)(messageRequestMutualServers);
items2[5] = ((Component) => <Component channel={channel} user={user} />)(importDefault(15258) /* metro dependency 15258: RestrictedMessagePreviewActions */);
return (
<View style={styles.container}>
{items2}
</View>
);
}
function _fun116660() { // fn#116660, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:670, offset: 0x02491ff0, size: 72 bytes, params: 1, frame: 13
const value = environment.__proto__;
(importDefault(8743) /* metro dependency 8743: showUserProfileActionSheet */)({userId: user.id,
channelId: channel.id, sourceAnalyticsLocations: analyticsLocations});
}
function _fun116661() { // fn#116661, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:774, offset: 0x02492038, size: 67 bytes, params: 1, frame: 14
const value = environment.__proto__;
(require(6797) /* metro dependency 6797: ClipboardUtilsNative */).copy(env0_3);
(require(3856) /* metro dependency 3856: ToastUtils */).presentUsernameCopied();
}
function _fun116662() { // fn#116662, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:852, offset: 0x0249207b, size: 107 bytes, params: 1, frame: 16
var environment;
let value = environment.__proto__;
const defaultImport = importDefault(dependencyMap[11]);
const openLazy = defaultImport.openLazy;
value = require(dependencyMap[13]);
value = value(dependencyMap[12], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport, [value, 'MutualGuildsActionSheet', {user: user,
onPressMutualGuild: onPressMutualGuild}]);
}
function onPressMutualGuild(a0) { // fn#116663, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15454:952, offset: 0x024920e6, size: 129 bytes, params: 2, frame: 16
(require(8515) /* metro dependency 8515: UserProfileAnalyticsUtils */).trackUserProfileAction({action: 'PRESS_MUTUAL_GUILD'});
(require(6947) /* metro dependency 6947: transitionToGuildNative */).transitionToGuild(a0);
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popWithKey(MOBILE_MESSAGE_REQUESTS_MODAL_KEY);
}
@@ -0,0 +1,191 @@
/* Metro module 15259; source: modules/message_request/native/RestrictedMessagePreviewList.tsx; dependencies: [31, 27, 4814, 33, 1305, 4501, 697, 6692, 4573, 1244, 4068, 6771, 566, 8743, 8177, 8199, 4643, 3826, 9773, 5278, 2] */
function _fun116670(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116670, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:6, offset: 0x02492610, size: 720 bytes, params: 8, frame: 23
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const messageStore = importDefault(4814) /* metro dependency 4814: MessageStore */;
let value = require(33) /* metro dependency 33 */;
const env0_6 = value.jsx;
const env0_7 = value.jsxs;
const env0_8 = {'renderEmbeds': false, 'renderReactions': false, 'inlineEmbedMedia': false,
'inlineAttachmentMedia': false, 'animateEmoji': false, 'gifAutoPlay': false, 'timestampHourCycle': 0,
'renderCodedLinks': false, 'renderGiftCode': false, 'renderActivityInstanceEmbed': false,
'renderActivityInviteEmbed': false, 'renderComponents': false, 'renderThreadEmbeds': false,
'renderReplies': false, 'renderCommunicationDisabled': false, 'renderAttachments': false,
'renderExecutedCommands': false, 'renderPolls': false, 'renderSharedClientTheme': false,
'renderForumPostActions': false, 'ignoreMentioned': false, 'ignoreEmbedDescriptionCache': false,
'forceHideSimpleEmbedContent': false, 'enableSwipeActions': false, 'useAlternateEmbedColors': false,
'restrictedPreview': true};
const AVATAR_SIZE_MAP = (require(1305) /* metro dependency 1305: native */).AVATAR_SIZE_MAP;
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
let NORMAL = AvatarSizes.NORMAL;
value = AVATAR_SIZE_MAP[NORMAL] + 18;
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = createStylesModule.createStyles;
object2 = {};
object2.container = {flexDirection: 'column'};
object2.hiddenMedia = {marginLeft: value};
object2.messageRow = {position: 'relative'};
NORMAL = AvatarSizes.NORMAL;
object2.avatarHitbox = {'position': 'absolute', 'top': 0, 'left': 0, width: value, height: AVATAR_SIZE_MAP[NORMAL]};
const object3 = {'flexDirection': 'row', 'alignItems': 'center'};
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object3.gap = PX_8;
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object3.marginVertical = PX_12;
object2.dateDivider = object3;
const BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
object2.dividerLine = {'flex': 1, 'height': 1, backgroundColor: BORDER_SUBTLE};
const object4 = {'alignItems': 'center', 'justifyContent': 'center', 'gap': null, 'height': 160};
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object4.gap = PX_8;
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object4.marginTop = PX_8;
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object4.backgroundColor = BACKGROUND_SURFACE_HIGH;
object2.mediaPlaceholderCard = object4;
const object5 = {'flexDirection': 'row', 'alignItems': 'center'};
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object5.gap = PX_8;
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object5.marginTop = PX_8;
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
object5.marginBottom = PX_4;
object2.mediaHiddenRow = object5;
const env0_9 = Reflect.apply(createStyles, createStylesModule, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/RestrictedMessagePreviewList.tsx');
exports.default = RestrictedMessagePreviewList;
}
function HiddenMedia({count}) { // fn#116671, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:1584, offset: 0x024928e0, size: 279 bytes, params: 2, frame: 26
const styles = useStyles();
const Array = global.Array;
const value2 = Array.from({length: count}, _fun116672);
const CircleInformationIcon = (require(4068) /* metro dependency 4068: CircleInformationIcon */).CircleInformationIcon;
const circleInformationIcon = <CircleInformationIcon size="sm" color="text-muted" />;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<View>
{value2}
<View style={styles.mediaHiddenRow}>
{circleInformationIcon}
<Text variant="text-sm/normal" color="text-muted">
{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['VGf+K3'])}
</Text>
</View>
</View>
);
}
function RestrictedMessagePreviewList({channelId}) { // fn#116673, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:2226, offset: 0x02492ac3, size: 237 bytes, params: 2, frame: 21
const styles = useStyles();
const analyticsLocations = (importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */)().analyticsLocations;
const value2 = (require(566) /* metro dependency 566: flux */).useStateFromStoresArray([MessageStore], _fun116674,
[channelId]);
const binding = value2;
const env0_4 = binding.useCallback(_fun116675, [channelId, analyticsLocations]);
const env0_5 = binding.useMemo(_fun116676, []);
return (
<View style={styles.container}>
{value2.map(_fun116677)}
</View>
);
}
function _fun116672(a0, a1) { // fn#116672, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:1671, offset: 0x024929f7, size: 204 bytes, params: 3, frame: 23
const ImageWarningIcon = (require(6692) /* metro dependency 6692: ImageWarningIcon */).ImageWarningIcon;
const imageWarningIcon = <ImageWarningIcon size="lg" color="text-muted" />;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const B2xSxL = (require(1244) /* metro dependency 1244: indexNative */).t.B2xSxL;
return (
<View style={styles.mediaPlaceholderCard} key={a1}>
{imageWarningIcon}
<Text variant="text-sm/medium" color="text-muted">
{Reflect.apply(string, intl, [B2xSxL])}
</Text>
</View>
);
}
function _fun116674() { // fn#116674, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:2361, offset: 0x02492bb0, size: 37 bytes, params: 1, frame: 11
const value = environment.__proto__;
const getMessages = MessageStore.getMessages;
return Reflect.apply(getMessages, MessageStore, [channelId]).toArray();
}
function _fun116675(a0) { // fn#116675, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:2415, offset: 0x02492bd5, size: 61 bytes, params: 2, frame: 13
const value = environment.__proto__;
(importDefault(8743) /* metro dependency 8743: showUserProfileActionSheet */)({userId: a0, channelId: channelId,
sourceAnalyticsLocations: analyticsLocations});
}
function _fun116676() { // fn#116676, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:2501, offset: 0x02492c12, size: 62 bytes, params: 1, frame: 12
const value3 = new (importDefault(8177) /* metro dependency 8177: RowGenerator */)();
value3.setOptions(env1_8);
return value3;
}
function _fun116677(a0, a1) { // fn#116677, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:2603, offset: 0x02492c50, size: 722 bytes, params: 3, frame: 32
var moduleValue3;
var object;
var stylesBinding;
var dividerLine;
var items3;
var Text;
var moduleValue4;
const value = a0;
const value3 = (require(8199) /* metro dependency 8199: formatMessageForwards */).maybeCreateSingleForwardForMessage(value);
let r6 = value3 == null ? value : value3.messageSnapshot.message;
const value4 = r6.attachments.length + r6.embeds.length;
const stickersUtilsModule = require(4643) /* metro dependency 4643: StickersUtils */;
const getMessageStickers = stickersUtilsModule.getMessageStickers;
const value5 = value4 + Reflect.apply(getMessageStickers, stickersUtilsModule, [r6]).length;
const property = env0_3[a1 - 1];
const value7 = property == null;
if (value7) {
r6 = value7;
} else {
moduleValue3 = require(3826) /* metro dependency 3826: DateUtils */;
r6 = !moduleValue3.isSameDay(property.timestamp, value.timestamp);
}
if (r6) {
object = {};
stylesBinding = styles;
object.style = stylesBinding.dateDivider;
dividerLine = stylesBinding.dividerLine;
items3 = [<View style={dividerLine} />];
Text = (require(4573) /* metro dependency 4573: Text */).Text;
moduleValue4 = require(3826) /* metro dependency 3826: DateUtils */;
items3[1] = <Text variant="text-xs/semibold" color="text-muted">{moduleValue4.dateFormat(value.timestamp,
'LL')}</Text>;
dividerLine = stylesBinding.dividerLine;
items3[2] = <View style={dividerLine} />;
r6 = <View {...object}>{items3}</View>;
}
const items2 = [r6];
stylesBinding = styles;
const messageRow = stylesBinding.messageRow;
const value11 = ((Component) => <Component pointerEvents="none" message={value} rowGenerator={env0_5} />)(importDefault(9773) /* metro dependency 9773: ChatItem */);
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
const avatarHitbox = stylesBinding.avatarHitbox;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
items2[1] = <View style={messageRow}>{value11}<PressableOpacity style={avatarHitbox} accessibilityRole="button" accessibilityLabel={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.iXAna6)} onPress={onPress_116678} /></View>;
items2[2] = value5 > 0 && <View style={styles.hiddenMedia}><HiddenMedia count={value5} /></View>;
return (
<View key={value.id}>
{items2}
</View>
);
}
function onPress_116678() { // fn#116678, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15456:3308, offset: 0x02492f22, size: 34 bytes, params: 1, frame: 11
return env1_4(env0_0.author.id);
}
@@ -0,0 +1,101 @@
/* Metro module 15256; source: modules/message_request/native/RestrictedMessageRequestPreview.tsx; dependencies: [57, 31, 27, 1379, 4814, 1878, 33, 4501, 697, 1585, 566, 15257, 15259, 11895, 2] */
function _fun116647(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116647, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15453:6, offset: 0x0249159f, size: 442 bytes, params: 8, frame: 24
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_5 = value.ScrollView;
const env0_6 = value.View;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const messageStore = importDefault(4814) /* metro dependency 4814: MessageStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
value = require(33) /* metro dependency 33 */;
const env0_10 = value.jsx;
const env0_11 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.container = {flex: 1, backgroundColor: BACKGROUND_BASE_LOW};
object2.scroll = {flex: 1};
object2.hidden = {opacity: 0};
const object3 = {};
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object3.paddingHorizontal = PX_16;
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object3.paddingTop = PX_8;
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object3.paddingBottom = PX_8;
object2.scrollContent = object3;
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object2.footer = {paddingHorizontal: PX_12};
const env0_12 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/RestrictedMessageRequestPreview.tsx');
exports.default = RestrictedMessageRequestPreview;
}
function RestrictedMessageRequestPreview({channelId}) { // fn#116648, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15453:613, offset: 0x02491759, size: 691 bytes, params: 2, frame: 29
var items6;
var items7;
var object;
const styles = useStyles();
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const binding = env0_4;
const value4 = binding.useRef(null);
const env0_2 = binding.useRef(false);
var [property, env0_4] = env0_3(binding.useState(false), 2);
const env0_5 = (require(566) /* metro dependency 566: flux */).useStateFromStores([MessageStore], function() {
return MessageStore.getMessages(channelId).length > 0;
}, [channelId]);
const value7 = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelStore], function() {
return ChannelStore.getChannel(channelId);
}, [channelId]);
let r0 = value7 == null || value7.recipients == null ? undefined : value7.recipients[0];
const value8 = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], _fun116651, [r0]);
env0_4.useEffect(_fun116652, [property]);
if (value7 == null) {
r0 = null;
} else if (value8 == null) {
r0 = null;
} else {
var viewBindingProps = {style: styles.container};
items6 = [<ScrollView ref={value4} style={[styles.scroll,
property ? null : styles.hidden]} contentContainerStyle={styles.scrollContent} onScrollBeginDrag={onScrollBeginDrag_116655} onContentSizeChange={onContentSizeChange}>{((Component) => <Component channel={value7} user={value8} />)(importDefault(15257) /* metro dependency 15257: RestrictedMessagePreviewHeader */)}{((Component) => <Component channelId={channelId} />)(importDefault(15259) /* metro dependency 15259: RestrictedMessagePreviewList */)}</ScrollView>];
items7 = [styles.footer];
object = {};
object.paddingBottom = (importDefault(697) /* metro dependency 697: native */).space.PX_8 + bottom;
items7[1] = object;
items6[1] = <View style={items7}>{((Component) => <Component channel={value7} />)(importDefault(11895) /* metro dependency 11895: ChatInputGuardMessageRequest */)}</View>;
r0 = <View {...viewBindingProps}>{items6}</View>;
}
return r0;
}
function _fun116651() { // fn#116651, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15453:985, offset: 0x02491a32, size: 42 bytes, params: 1, frame: 12
return env0_6 != null ? UserStore.getUser(env0_6) : undefined;
}
function _fun116652() { // fn#116652, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15453:1043, offset: 0x02491a5c, size: 56 bytes, params: 1, frame: 14
if (env0_3) {
return undefined;
}
const env0_0 = global.setTimeout(_fun116653, 1000);
return _fun116654;
}
function RestrictedMessageRequestPreviewOnContentSizeChange() { // fn#116656, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15453:1317, owner: RestrictedMessageRequestPreview.onContentSizeChange, offset: 0x02491a94, size: 95 bytes, params: 1, frame: 13
let current = env0_2.current;
if (!current) {
current = env0_1.current;
if (current != null) {
current.scrollToEnd({animated: false});
}
}
if (!env0_3 && env0_5) {
global.requestAnimationFrame(_fun116657);
}
}
@@ -0,0 +1,79 @@
/* Metro module 15251; source: modules/message_request/native/RestrictedMessageRequestRow.tsx; dependencies: [31, 27, 661, 33, 4501, 3857, 1244, 8947, 11898, 15236, 8341, 5312, 4578, 683, 7972, 2] */
function _fun116614(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116614, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15448:6, offset: 0x0248ff68, size: 260 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const env0_5 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
const value = require(33) /* metro dependency 33 */;
const env0_6 = value.jsx;
const env0_7 = value.jsxs;
const env0_8 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({rowContainer: {'flexDirection': 'row',
'alignItems': 'center', 'justifyContent': 'space-between', 'marginTop': 14, 'marginBottom': 12},
actionContainer: {'flexDirection': 'row', 'alignItems': 'center', 'gap': 8}});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/RestrictedMessageRequestRow.tsx');
exports.default = RestrictedMessageRequestRow;
}
function RestrictedMessageRequestRow({messageRequest, goToMessageRequestPreview, isLastRow}) { // fn#116615, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15448:485, offset: 0x0249006c, size: 644 bytes, params: 2, frame: 33
const styles = useStyles();
const user = messageRequest.user;
const channel = messageRequest.channel;
const value4 = (require(11898) /* metro dependency 11898: useMessageRequestActions */).useMessageRequestActions({user: user,
onError: env0_3.useCallback(function() {
var defaultImport = importDefault(dependencyMap[5]);
var object = {key: 'MESSAGE_REQUEST_REQUEST_ERROR_ALERT_TITLE'};
object.content = require(dependencyMap[6]).intl.string(require(dependencyMap[6]).t['EDYbS+']);
object.icon = importDefault(dependencyMap[7]);
defaultImport.open(object);
}, [])});
var env0_3 = value4.rejectMessageRequest;
const isRejectLoading = value4.isRejectLoading;
const isOptimisticRejected = value4.isOptimisticRejected;
const value5 = ((Component) => <Component channel={channel} otherUser={user} isRestricted />)(importDefault(15236) /* metro dependency 15236: MessageRequestRowSenderDetails */);
const IconButton = (require(8341) /* metro dependency 8341: IconButtonNative */).IconButton;
let object = {'variant': 'critical-secondary', 'size': 'sm'};
const XSmallIcon = (require(5312) /* metro dependency 5312: XSmallIcon */).XSmallIcon;
object.icon = <XSmallIcon />;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const formatToPlainString = intl.formatToPlainString;
const property = (require(1244) /* metro dependency 1244: indexNative */).t['C9Xe6+'];
const object2 = {};
object2.name = user?.toString();
object.accessibilityLabel = Reflect.apply(formatToPlainString, intl, [property, object2]);
object.onPress = function() {
rejectMessageRequest(channel.id);
};
object.disabled = isRejectLoading || isOptimisticRejected;
object.loading = isRejectLoading || isOptimisticRejected;
const iconButton = <IconButton {...object} />;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const string = intl.string;
const NB4jq8 = (require(1244) /* metro dependency 1244: indexNative */).t.NB4jq8;
return (
<View>
<View style={styles.rowContainer}>
{value5}
<View style={styles.actionContainer}>
{iconButton}
<Button
variant="primary"
size="sm"
text={Reflect.apply(string, intl, [NB4jq8])}
onPress={function() {
var defaultImport = importDefault(dependencyMap[13]);
var MESSAGE_REQUEST_PREVIEW_VIEWED = AnalyticEvents.MESSAGE_REQUEST_PREVIEW_VIEWED;
defaultImport.track(MESSAGE_REQUEST_PREVIEW_VIEWED, {is_spam: false, channel_id: channel.id,
other_user_id: user.id});
goToMessageRequestPreview();
}}
disabled={isOptimisticRejected}
/>
</View>
</View>
{isLastRow ? null : ((FormDivider) => <FormDivider iconPush outer />)((require(7972) /* metro dependency 7972: native */).FormDivider)}
</View>
);
}
@@ -0,0 +1,53 @@
/* Metro module 12683; source: modules/message_request/native/hooks/useMessageRequestPrivacyOption.tsx; dependencies: [31, 33, 3829, 7004, 6807, 1244, 11901, 2] */
function _fun97168(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#97168, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12873:6, offset: 0x02175890, size: 153 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 */;
const env0_4 = (require(33) /* metro dependency 33 */).jsx;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/hooks/useMessageRequestPrivacyOption.tsx');
exports.useMessageRequestPrivacyOption = useMessageRequestPrivacyOption;
}
function MessageRequestRestrictedGuildPrivacyOption({guild}) { // fn#97169, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12873:163, offset: 0x02175929, size: 298 bytes, params: 2, frame: 22
var object2;
const id = guild.id;
const MessageRequestRestrictedGuildIds = (require(3829) /* metro dependency 3829: UserSettings */).MessageRequestRestrictedGuildIds;
const value2 = MessageRequestRestrictedGuildIds.useSetting();
const value3 = value2.includes(id);
const RestrictedGuildIds = (require(3829) /* metro dependency 3829: UserSettings */).RestrictedGuildIds;
const value4 = RestrictedGuildIds.useSetting();
const value5 = value4.includes(guild.id);
const value6 = env0_3.useCallback(_fun97170, [id]);
const ActionSheetSwitchRow = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetSwitchRow;
object2 = {};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object2.label = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t['7UgSGP']]);
string = intl.string;
const INRaYb = (require(1244) /* metro dependency 1244: indexNative */).t.INRaYb;
object2.subLabel = Reflect.apply(string, intl, [INRaYb]);
object2.value = !value5 && !value3;
object2.onValueChange = value6;
object2.disabled = value5;
return <ActionSheetSwitchRow {...object2} />;
}
function useMessageRequestPrivacyOption({guild}) { // fn#97171, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12873:807, offset: 0x02175ad9, size: 64 bytes, params: 2, frame: 15
return (importDefault(11901) /* metro dependency 11901: useIsStricterMessageRequests */)() ? null : <MessageRequestRestrictedGuildPrivacyOption guild={guild} />;
}
function _fun97170(a0) { // fn#97170, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12873:330, offset: 0x02175a53, size: 134 bytes, params: 2, frame: 14
const sanitizedMessageRequestRestrictedGuilds = (require(7004) /* metro dependency 7004: UserSettingsUtils */).getSanitizedMessageRequestRestrictedGuilds();
if (a0) {
sanitizedMessageRequestRestrictedGuilds.delete(id);
} else {
sanitizedMessageRequestRestrictedGuilds.add(id);
}
const MessageRequestRestrictedGuildIds = (require(3829) /* metro dependency 3829: UserSettings */).MessageRequestRestrictedGuildIds;
const updateSetting = MessageRequestRestrictedGuildIds.updateSetting;
const Array = global.Array;
Reflect.apply(updateSetting, MessageRequestRestrictedGuildIds,
[Array.from(sanitizedMessageRequestRestrictedGuilds)]);
}
@@ -0,0 +1,102 @@
/* Metro module 11903; source: modules/message_request/native/spam/SpamMessageHamActionSheet.tsx; dependencies: [57, 31, 27, 1878, 33, 4501, 697, 566, 11898, 3857, 1244, 8947, 4080, 6275, 6758, 6806, 7972, 4578, 2] */
function _fun91357(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#91357, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12089:6, offset: 0x0205c4d3, size: 360 bytes, params: 8, frame: 23
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
const env0_5 = (require(27) /* metro dependency 27 */).View;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
let value = require(33) /* metro dependency 33 */;
const env0_7 = value.jsx;
const env0_8 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object2.header = {backgroundColor: BACKGROUND_SURFACE_HIGH};
const object4 = {};
let PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
object4.marginTop = PX_24;
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object4.paddingHorizontal = PX_16;
object2.container = object4;
PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
object2.buttonContainer = {marginTop: PX_24};
object2.switch = {paddingHorizontal: 0};
const env0_9 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/spam/SpamMessageHamActionSheet.tsx');
exports.default = SpamMessageRequestHamActionSheet;
}
function SpamMessageRequestHamActionSheet({channel, onConfirm, onCancel}) { // fn#91358, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12089:525, offset: 0x0205c63b, size: 712 bytes, params: 2, frame: 31
const closure = function() {
onCancel();
};
const styles = useStyles();
const [property, env0_4] = env0_3(env0_4Binding.useState(false), 2);
const user = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
return UserStore.getUser(channel.getRecipientId());
});
const value4 = (require(11898) /* metro dependency 11898: useMessageRequestActions */).useMessageRequestActions({user: user,
onError: function() {
var defaultImport = importDefault(dependencyMap[9]);
var object = {key: 'MESSAGE_REQUEST_REQUEST_ERROR_ALERT_TITLE'};
object.content = require(dependencyMap[10]).intl.string(require(dependencyMap[10]).t['EDYbS+']);
object.icon = importDefault(dependencyMap[11]);
defaultImport.open(object);
}, onAcceptSuccess: onAcceptSuccess});
const env0_5 = value4.acceptMessageRequest;
const isAcceptLoading = value4.isAcceptLoading;
const isUserProfileLoading = value4.isUserProfileLoading;
const isOptimisticAccepted = value4.isOptimisticAccepted;
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
let object = {};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object.title = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t['9ty6yc']]);
const ActionSheetCloseButton = (require(6806) /* metro dependency 6806: ActionSheetCloseButtonNative */).ActionSheetCloseButton;
object.trailing = <ActionSheetCloseButton onPress={closure} />;
object.backgroundColor = styles.header;
const bottomSheetTitleHeader = <BottomSheetTitleHeader {...object} />;
const FormSwitchRow = (require(7972) /* metro dependency 7972: native */).FormSwitchRow;
const object3 = {style: styles.switch};
string = intl.string;
const ZhGpNQ = (require(1244) /* metro dependency 1244: indexNative */).t.ZhGpNQ;
object3.label = Reflect.apply(string, intl, [ZhGpNQ]);
object3.value = property;
object3.switchProps = {renderIosBackground: true};
object3.onValueChange = onValueChange_91363;
const formSwitchRow = <FormSwitchRow {...object3} />;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const buttonProps = {size: 'md', onPress: onPress_91364,
text: intl.string((require(1244) /* metro dependency 1244: indexNative */).t.olZgw5)};
let r14 = isAcceptLoading || isUserProfileLoading;
r14 = !r14 ? isOptimisticAccepted : r14;
buttonProps.disabled = r14;
buttonProps.loading = isAcceptLoading || isOptimisticAccepted;
return (
<BottomSheet onDismiss={closure}>
{bottomSheetTitleHeader}
<View style={styles.container}>
{formSwitchRow}
<View style={styles.buttonContainer}>
<Button {...buttonProps} />
</View>
</View>
</BottomSheet>
);
}
function onAcceptSuccess() { // fn#91362, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12089:925, owner: SpamMessageRequestHamActionSheet.onAcceptSuccess, offset: 0x0205c9a1, size: 37 bytes, params: 1, frame: 11
const value = environment.__proto__;
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
}
function SpamMessageRequestHamActionSheetOnPress() { // fn#91364, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12089:1586, owner: SpamMessageRequestHamActionSheet.onPress, offset: 0x0205c9c6, size: 38 bytes, params: 1, frame: 12
onConfirm(env0_3);
acceptMessageRequest(channel.id);
}
@@ -0,0 +1,277 @@
/* Metro module 15252; source: modules/message_request/native/spam/SpamMessageList.tsx; dependencies: [31, 27, 661, 33, 4501, 697, 1244, 11908, 3857, 8947, 4601, 5080, 11898, 683, 5278, 15236, 1305, 8096, 13436, 7972, 1585, 15245, 15253, 15243, 4594, 4826, 4831, 15246, 477, 4573, 2] */
function _fun116619(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116619, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:6, offset: 0x024903e1, size: 586 bytes, params: 8, frame: 22
var object2;
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.ActivityIndicator;
const env0_5 = value.View;
const env0_6 = value.FlatList;
const env0_7 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
value = require(33) /* metro dependency 33 */;
const env0_8 = value.jsx;
const env0_9 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
let BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.sectionContainer = {'backgroundColor': null, 'flexDirection': 'row', 'justifyContent': 'space-between',
'marginTop': 6, 'marginBottom': 10, backgroundColor: BACKGROUND_BASE_LOW};
object2.rowContainer = {'flexDirection': 'row', 'alignItems': 'center', 'justifyContent': 'space-between',
'marginTop': 14, 'marginBottom': 12};
object2.actionContainer = {'flexDirection': 'row', 'alignItems': 'flex-start', 'height': '100%'};
const object4 = {'backgroundColor': null, 'tintColor': null, 'borderRadius': null, 'alignItems': 'center',
'justifyContent': 'center', 'height': 32, 'width': 32};
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object4.backgroundColor = BACKGROUND_SURFACE_HIGH;
const INTERACTIVE_TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_TEXT_DEFAULT;
object4.tintColor = INTERACTIVE_TEXT_DEFAULT;
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
object2.actionButton = object4;
object2.acceptButton = {marginRight: 16};
const object6 = {};
object6.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
object2.pressableRow = object6;
object2.activityIndicator = {'height': 16, 'width': 16};
BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.list = {'flex': 1, 'paddingHorizontal': 16, 'alignSelf': 'stretch', backgroundColor: BACKGROUND_BASE_LOW};
const env0_10 = Reflect.apply(createStyles, value, [object2]);
object2 = {ACCEPT_SPAM_MESSAGE: 'accept-spam-message-request', IGNORE_SPAM_MESSAGE: 'ignore-spam-message-request',
PREVIEW_SPAM_MESSAGE: 'preview-spam-message-request'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/message_request/native/spam/SpamMessageList.tsx');
exports.default = SpamMessageList;
}
function PendingSpamMessageRequestRow({messageRequest, goToMessageRequestPreview, isLastRow, hasSingleMessageRequest}) { // fn#116620, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:1200, offset: 0x0249062b, size: 1369 bytes, params: 2, frame: 45
var object11;
const styles = useStyles();
const user = messageRequest.user;
let channel = messageRequest.channel;
const env0_3 = channel;
const id = channel.id;
const useLongestChannelMessageBeforeReplyModule = require(11908) /* metro dependency 11908: useLongestChannelMessageBeforeReply */;
const useLongestChannelMessageBeforeReply = useLongestChannelMessageBeforeReplyModule.useLongestChannelMessageBeforeReply;
const getRecipientId = channel.getRecipientId;
const env0_5 = Reflect.apply(useLongestChannelMessageBeforeReply, useLongestChannelMessageBeforeReplyModule, [id,
Reflect.apply(getRecipientId, channel, [])]);
let binding = env0_3;
let useCallback = binding.useCallback;
let closure = function() {
var defaultImport = importDefault(dependencyMap[8]);
var object = {key: 'MESSAGE_REQUESTS_SPAM_ERROR_ALERT_TITLE'};
object.content = require(dependencyMap[6]).intl.string(require(dependencyMap[6]).t.pIQ3h4);
object.icon = importDefault(dependencyMap[9]);
defaultImport.open(object);
};
const value3 = Reflect.apply(useCallback, binding, [closure, []]);
binding = env0_3;
useCallback = binding.useCallback;
const value5 = (require(11898) /* metro dependency 11898: useMessageRequestActions */).useMessageRequestActions({user: user,
onAcceptSuccess: Reflect.apply(useCallback, binding, [_fun116622, [id, hasSingleMessageRequest]]),
onError: value3});
const env0_6 = value5.rejectMessageRequest;
const isAcceptLoading = value5.isAcceptLoading;
const isRejectLoading = value5.isRejectLoading;
const isUserProfileLoading = value5.isUserProfileLoading;
const isOptimisticAccepted = value5.isOptimisticAccepted;
const isOptimisticRejected = value5.isOptimisticRejected;
const env0_7 = value5.markAsNotSpam;
closure = function() {
rejectMessageRequest(channel.id);
};
const closure2 = onPress_116624;
const closure3 = function() {
var defaultImport = importDefault(dependencyMap[13]);
var MESSAGE_REQUEST_PREVIEW_VIEWED = AnalyticEvents.MESSAGE_REQUEST_PREVIEW_VIEWED;
defaultImport.track(MESSAGE_REQUEST_PREVIEW_VIEWED, {is_spam: true, channel_id: channel.id,
other_user_id: user.id});
goToMessageRequestPreview();
};
let r20 = isAcceptLoading || isRejectLoading;
r20 = !r20 ? isUserProfileLoading : r20;
r20 = !r20 ? isOptimisticAccepted : r20;
r20 = !r20 ? isOptimisticRejected : r20;
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
object11 = {onPress: closure3, accessibilityRole: 'button'};
const object5 = {};
const ACCEPT_SPAM_MESSAGE = env0_11.ACCEPT_SPAM_MESSAGE;
object5.name = ACCEPT_SPAM_MESSAGE;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object5.label = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t.apePSa]);
const items2 = [object5];
const object6 = {};
const IGNORE_SPAM_MESSAGE = env0_11.IGNORE_SPAM_MESSAGE;
object6.name = IGNORE_SPAM_MESSAGE;
string = intl.string;
const MWOV9D = (require(1244) /* metro dependency 1244: indexNative */).t.MWOV9D;
object6.label = Reflect.apply(string, intl, [MWOV9D]);
items2[1] = object6;
const object7 = {};
const PREVIEW_SPAM_MESSAGE = env0_11.PREVIEW_SPAM_MESSAGE;
object7.name = PREVIEW_SPAM_MESSAGE;
string = intl.string;
const I6PFLB = (require(1244) /* metro dependency 1244: indexNative */).t.I6PFLB;
object7.label = Reflect.apply(string, intl, [I6PFLB]);
items2[2] = object7;
object11.accessibilityActions = items2;
object11.onAccessibilityAction = onAccessibilityAction_116626;
object11.style = styles.pressableRow;
const MessageRequestRowSenderDetails = importDefault(15236) /* metro dependency 15236: MessageRequestRowSenderDetails */;
channel = messageRequest.channel;
const user2 = messageRequest.user;
const messageRequestRowSenderDetails = <MessageRequestRowSenderDetails channel={channel} otherUser={user2} />;
const PressableOpacity2 = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
let formatToPlainString = intl.formatToPlainString;
let property = (require(1244) /* metro dependency 1244: indexNative */).t['6p0yBo'];
const object8 = {};
object8.name = user?.toString();
const pressableOpacity = <PressableOpacity2 accessibilityRole="button" accessibilityLabel={Reflect.apply(formatToPlainString,
intl, [property, object8])} onPress={closure2} disabled={r20} style={[styles.actionButton,
styles.acceptButton]}>{isAcceptLoading || isUserProfileLoading || isOptimisticAccepted ? <ActivityIndicator style={styles.activityIndicator} /> : ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.SMALL} disableColor source={importDefault(8096) /* metro dependency 8096 */} />)((require(1305) /* metro dependency 1305: native */).Icon)}</PressableOpacity2>;
const PressableOpacity3 = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
formatToPlainString = intl.formatToPlainString;
property = (require(1244) /* metro dependency 1244: indexNative */).t['C9Xe6+'];
const object10 = {};
object10.name = user?.toString();
return (
<PressableOpacity {...object11}>
<View style={styles.rowContainer}>
{messageRequestRowSenderDetails}
<View style={styles.actionContainer}>
{pressableOpacity}
<PressableOpacity3
accessibilityRole="button"
accessibilityLabel={Reflect.apply(formatToPlainString, intl, [property, object10])}
onPress={closure}
disabled={r20}
style={styles.actionButton}
>
{isRejectLoading || isOptimisticRejected ? <ActivityIndicator style={styles.activityIndicator} /> : ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.SMALL} disableColor source={importDefault(13436) /* metro dependency 13436 */} />)((require(1305) /* metro dependency 1305: native */).Icon)}
</PressableOpacity3>
</View>
</View>
{isLastRow ? null : ((FormDivider) => <FormDivider iconPush outer />)((require(7972) /* metro dependency 7972: native */).FormDivider)}
</PressableOpacity>
);
}
function SpamMessageList({goToMessageRequestPreview}) { // fn#116627, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:3746, offset: 0x02490d34, size: 431 bytes, params: 2, frame: 24
var MessageRequestEmpty;
var intl;
const styles = useStyles();
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const env0_2 = (require(15245) /* metro dependency 15245: useSpamMessageRequestsCount */).useSpamMessageRequestCount();
const value2 = (importDefault(15253) /* metro dependency 15253: useSortedSpamMessageRequests */)();
const env0_4 = (require(15243) /* metro dependency 15243: useListHasSingleMessageRequest */).useListHasSingleSpamMessageRequest();
(importDefault(4594) /* metro dependency 4594: useMountEffect */)(_fun116628);
if (value2.length === 0) {
MessageRequestEmpty = importDefault(15246) /* metro dependency 15246: MessageRequestEmpty */;
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return <MessageRequestEmpty bodyText={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.hasFPQ)} />;
}
const items2 = ['header-section'];
arraySpread(items2, value2, 1, undefined);
const items3 = [styles.list];
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
items3[1] = {marginBottom: platformUtilsModule.isAndroid() ? bottom : 0};
return (
<FlatList
style={items3}
scrollIndicatorInsets={{right: 0.01}}
contentContainerStyle={{paddingBottom: bottom, paddingTop: 12}}
renderItem={renderItem_116629}
data={items2}
/>
);
}
function _fun116622() { // fn#116622, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:1596, offset: 0x02490bff, size: 80 bytes, params: 1, frame: 14
var value2;
var moduleValue;
if (hasSingleMessageRequest) {
value2 = environment.__proto__;
moduleValue = require(4601) /* metro dependency 4601: transitionToChannel */;
moduleValue.transitionToChannel(id);
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).pop();
}
}
function PendingSpamMessageRequestRowOnPress_116624() { // fn#116624, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:1962, owner: PendingSpamMessageRequestRow.onPress, offset: 0x02490c4f, size: 25 bytes, params: 1, frame: 13
markAsNotSpam(channel, env0_5);
}
function PendingSpamMessageRequestRowOnAccessibilityAction({nativeEvent}) { // fn#116626, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:2466, owner: PendingSpamMessageRequestRow.onAccessibilityAction, offset: 0x02490cc7, size: 109 bytes, params: 2, frame: 10
const actionName = nativeEvent.actionName;
const ACCEPT_SPAM_MESSAGE = env1_11.ACCEPT_SPAM_MESSAGE;
if (ACCEPT_SPAM_MESSAGE === actionName) {
onPress_116624();
} else {
var IGNORE_SPAM_MESSAGE = env1_11.IGNORE_SPAM_MESSAGE;
if (IGNORE_SPAM_MESSAGE === actionName) {
onPress_116623();
return undefined;
}
var PREVIEW_SPAM_MESSAGE = env1_11.PREVIEW_SPAM_MESSAGE;
if (PREVIEW_SPAM_MESSAGE === actionName) {
onPress_116625();
return undefined;
}
}
}
function _fun116628() { // fn#116628, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:3946, offset: 0x02490ee3, size: 121 bytes, params: 1, frame: 18
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const SPAM_MESSAGE_REQUESTS_VIEWED = AnalyticEvents.SPAM_MESSAGE_REQUESTS_VIEWED;
Reflect.apply(track, defaultImport, [SPAM_MESSAGE_REQUESTS_VIEWED, {num_spam_message_requests: env0_2}]);
const defaultImport2 = importDefault(4826) /* metro dependency 4826: MonitoringAgent */;
const increment = defaultImport2.increment;
const MetricEvents = (require(4831) /* metro dependency 4831: MetricEvents */).MetricEvents;
const SPAM_MESSAGE_REQUEST_VIEW = MetricEvents.SPAM_MESSAGE_REQUEST_VIEW;
Reflect.apply(increment, defaultImport2, [{name: SPAM_MESSAGE_REQUEST_VIEW}]);
}
function SpamMessageListRenderItem({item}) { // fn#116629, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15449:4383, owner: SpamMessageList.renderItem, offset: 0x02490f5c, size: 316 bytes, params: 2, frame: 24
var environment;
var id;
var r0;
var value;
var object2;
var channel;
var id2;
var binding;
var property;
var Text;
var intl;
if (typeof item === 'string') {
value = environment.__proto__;
var viewBindingProps = {style: styles.sectionContainer};
Text = (require(4573) /* metro dependency 4573: Text */).Text;
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
value = <View {...viewBindingProps}><Text variant="eyebrow" color="text-default">{intl.format((require(1244) /* metro dependency 1244: indexNative */).t.aNh5Kf,
{count: env0_3.length})}</Text></View>;
r0 = value;
} else {
value = environment.__proto__;
object2 = {messageRequest: item, goToMessageRequestPreview: function() {
return goToMessageRequestPreview(item.channel.id);
}};
channel = item.channel;
id2 = channel.id;
binding = env0_3;
property = binding[binding.length - 1];
id = property == null ? undefined : property.channel.id;
object2.isLastRow = id2 === id;
object2.hasSingleMessageRequest = env0_4;
channel = item.channel;
id = channel.id;
value = <PendingSpamMessageRequestRow {...object2} key={id} />;
r0 = value;
}
return r0;
}