This commit is contained in:
janisslsm committed 2026-07-28 01:06:53 +03:00
1 parent af3b49f756
commit 1781d25a15
22448 files changed
+2731829 -2650550

No files matched your search

+22 -18
View File
@@ -1,25 +1,29 @@
/* Metro module 15676; source: utils/native/AppInfoUtils.tsx; dependencies: [1582, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ClientInfoUtilsModule from './ClientInfoUtils.tsx'; /* Metro dependency 1582 */
function _fun120244(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120244, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15884:6, offset: 0x0252583f, size: 113 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_0 = (require(1582) /* metro dependency 1582: ClientInfoUtils */).getConstants();
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/AppInfoUtils.tsx');
const env0_0 = (ClientInfoUtilsModule).getConstants();
(FileImportTrackerModule).fileFinishedImporting('utils/native/AppInfoUtils.tsx');
exports.getAppMajorVersion = getAppMajorVersion;
function getAppMajorVersion() { // fn#120245, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15884:205, offset: 0x025258b0, size: 84 bytes, params: 1, frame: 13
var r0;
var value;
if (env0_0 === undefined) {
return -1;
}
const Version = env0_0.Version;
if (Version.split('.').length !== 2) {
r0 = -1;
} else {
value = global.Number(value[0]);
r0 = value;
}
return r0;
}
}
function getAppMajorVersion() { // fn#120245, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15884:205, offset: 0x025258b0, size: 84 bytes, params: 1, frame: 13
var r0;
var value;
if (env0_0 === undefined) {
return -1;
}
const Version = env0_0.Version;
if (Version.split('.').length !== 2) {
r0 = -1;
} else {
value = global.Number(value[0]);
r0 = value;
}
return r0;
}
global.__d(_fun120244, 15676, [1582, 2]) /* metro module 15676, dependencies: [1582, 2] */;
+136 -130
View File
@@ -1,147 +1,153 @@
/* Metro module 8870; source: utils/native/ApplicationUtils.tsx; dependencies: [661, 8871, 683, 8872, 3853, 10203, 483, 5080, 10206, 1962, 4122, 2] */
import ModalActionCreators from '../../actions/ModalActionCreators.tsx'; /* Metro dependency 5080 */
import AuthorizeCallback from '../../modules/oauth2/native/authorizeCallback.tsx'; /* Metro dependency 10203 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as ConstantsModule2 from '../../modules/oauth2/native/Constants.tsx'; /* Metro dependency 8871 */
function _fun69146(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#69146, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:6, offset: 0x01c6ace9, size: 185 bytes, params: 8, frame: 19
const env0_0 = require;
const closure = openOAuth2Modal;
const openOAuth2Modal2 = openOAuth2Modal;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_4 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
const env0_5 = (require(8871) /* metro dependency 8871: Constants */).OAUTH2_AUTHORIZE_MODAL_KEY;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ApplicationUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/ApplicationUtils.tsx');
exports.installApplication = installApplication;
exports.openOAuth2Modal = closure;
exports.openOAuth2Modal = openOAuth2Modal2;
exports.installPrivateChannelIntegration = installPrivateChannelIntegration;
}
function openOAuth2Modal(a0) { // fn#69147, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:158, offset: 0x01c6ada2, size: 139 bytes, params: 2, frame: 20
const env0_0 = a0;
importDefault(dependencyMap[7]).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
const defaultImport2 = importDefault(dependencyMap[7]);
const pushLazy = defaultImport2.pushLazy;
const value2 = require(dependencyMap[9])(dependencyMap[8], dependencyMap.paths);
const object2 = {};
copyDataProperties(object2, a0, undefined);
object2['dismissOAuthModal'] = openOAuth2ModalDismissOAuthModal;
Reflect.apply(pushLazy, defaultImport2, [value2, object2, OAUTH2_AUTHORIZE_MODAL_KEY]);
}
function installApplication({applicationId, customInstallUrl, installParams, integrationTypesConfig, guildId, channelId, disableGuildSelect, source, oauth2Callback}) { // fn#69149, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:441, offset: 0x01c6ae78, size: 591 bytes, params: 2, frame: 25
var r8;
var value;
var value2;
var defaultImport;
var object2;
var openOAuth2ModalBinding;
var defaultImport2;
var defaultImport3;
if (customInstallUrl != null) {
defaultImport3 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport3.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'custom_url', source: source, device_platform: 'mobile_native'});
return (require(8872) /* metro dependency 8872: MaskedLinkUtils */).handleClick({href: customInstallUrl,
onConfirm: onConfirm});
}
if (integrationTypesConfig == null) {
if (installParams != null) {
value2 = undefined;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2ModalBinding = openOAuth2Modal;
object2 = {clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect};
object2.scopes = installParams == null ? value2 : installParams.scopes;
if ((installParams == null ? value2 : installParams.permissions) != null) {
value = importAll(483) /* metro dependency 483: BigFlagUtils */;
value = value.deserialize(installParams == null ? value2 : installParams.permissions);
r8 = value;
} else {
r8 = value2;
function openOAuth2Modal(a0) { // fn#69147, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:158, offset: 0x01c6ada2, size: 139 bytes, params: 2, frame: 20
const env0_0 = a0;
importDefault(dependencyMap[7]).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
const defaultImport2 = importDefault(dependencyMap[7]);
const pushLazy = defaultImport2.pushLazy;
const value2 = require(dependencyMap[9])(dependencyMap[8], dependencyMap.paths);
const object = {};
copyDataProperties(object, a0, undefined);
object['dismissOAuthModal'] = openOAuth2ModalDismissOAuthModal;
Reflect.apply(pushLazy, defaultImport2, [value2, object, OAUTH2_AUTHORIZE_MODAL_KEY]);
function openOAuth2ModalDismissOAuthModal() { // fn#69148, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:271, owner: openOAuth2Modal.dismissOAuthModal, offset: 0x01c6ae2d, size: 75 bytes, params: 1, frame: 12
if (env0_0.dismissOAuthModal != null) {
env0_0.dismissOAuthModal();
}
object2.permissions = r8;
object2.callback = function(a0) {
importDefault(dependencyMap[5])(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
(ModalActionCreators).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
}
}
function installApplication({applicationId, customInstallUrl, installParams, integrationTypesConfig, guildId, channelId, disableGuildSelect, source, oauth2Callback}) { // fn#69149, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:441, offset: 0x01c6ae78, size: 591 bytes, params: 2, frame: 25
var r8;
var value;
var value2;
var defaultImport;
var object;
var openOAuth2ModalBinding;
var defaultImport2;
var defaultImport3;
if (customInstallUrl != null) {
defaultImport3 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport3.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'custom_url', source: source, device_platform: 'mobile_native'});
return (require(8872) /* metro dependency 8872: MaskedLinkUtils */).handleClick({href: customInstallUrl,
onConfirm: onConfirm_69150});
}
if (integrationTypesConfig == null) {
if (installParams != null) {
value2 = undefined;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2ModalBinding = openOAuth2Modal;
object = {clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect};
object.scopes = installParams == null ? value2 : installParams.scopes;
if ((installParams == null ? value2 : installParams.permissions) != null) {
value = importAll(483) /* metro dependency 483: BigFlagUtils */;
value = value.deserialize(installParams == null ? value2 : installParams.permissions);
r8 = value;
} else {
r8 = value2;
}
};
openOAuth2ModalBinding(object2);
}
} else {
var Object = global.Object;
value = Object.values(integrationTypesConfig);
if (value.some(function(a0) {
var value = undefined;
return (a0 == null ? value : a0.oauth2_install_params) != null || (a0 == null ? value : a0.oauth2InstallParams) != null;
})) {
defaultImport2 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport2.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2Modal({clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect, callback: callback_69152});
return undefined;
}
if (installParams != null) {
value2 = undefined;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2ModalBinding = openOAuth2Modal;
object2 = {clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect};
object2.scopes = installParams == null ? value2 : installParams.scopes;
if ((installParams == null ? value2 : installParams.permissions) != null) {
value = importAll(483) /* metro dependency 483: BigFlagUtils */;
value = value.deserialize(installParams == null ? value2 : installParams.permissions);
r8 = value;
} else {
r8 = value2;
object.permissions = r8;
object.callback = function(a0) {
importDefault(dependencyMap[5])(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
}
};
openOAuth2ModalBinding(object);
}
object2.permissions = r8;
object2.callback = function(a0) {
importDefault(dependencyMap[5])(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
} else {
var Object = global.Object;
value = Object.values(integrationTypesConfig);
if (value.some(function(a0) {
var value = undefined;
return (a0 == null ? value : a0.oauth2_install_params) != null || (a0 == null ? value : a0.oauth2InstallParams) != null;
})) {
defaultImport2 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport2.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2Modal({clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect, callback: callback_69152});
return undefined;
}
if (installParams != null) {
value2 = undefined;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.APPLICATION_ADD_TO_SERVER_CLICKED, {application_id: applicationId,
auth_type: 'in_app', source: source, device_platform: 'mobile_native'});
openOAuth2ModalBinding = openOAuth2Modal;
object = {clientId: applicationId, guildId: guildId, channelId: channelId,
disableGuildSelect: disableGuildSelect};
object.scopes = installParams == null ? value2 : installParams.scopes;
if ((installParams == null ? value2 : installParams.permissions) != null) {
value = importAll(483) /* metro dependency 483: BigFlagUtils */;
value = value.deserialize(installParams == null ? value2 : installParams.permissions);
r8 = value;
} else {
r8 = value2;
}
};
openOAuth2ModalBinding(object2);
object.permissions = r8;
object.callback = function(a0) {
importDefault(dependencyMap[5])(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
}
};
openOAuth2ModalBinding(object);
}
}
function installApplicationOnConfirm() { // fn#69150, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:807, owner: installApplication.onConfirm, offset: 0x01c6b0c7, size: 45 bytes, params: 1, frame: 12
let value = environment.__proto__;
value = importDefault(3853) /* metro dependency 3853: Linking */;
value.openURL(customInstallUrl);
}
function installApplicationCallback(a0) { // fn#69152, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:1189, owner: installApplication.callback, offset: 0x01c6b0f4, size: 57 bytes, params: 2, frame: 13
(AuthorizeCallback)(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
}
}
}
}
function installPrivateChannelIntegration({applicationId, channelId, callback}) { // fn#69154, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:1681, offset: 0x01c6b12d, size: 171 bytes, params: 2, frame: 22
const defaultImport = importDefault(dependencyMap[7]);
const pushLazy = defaultImport.pushLazy;
const value2 = require(dependencyMap[9])(dependencyMap[8], dependencyMap.paths);
const object2 = {clientId: applicationId};
const OAuth2Scopes = require(dependencyMap[10]).OAuth2Scopes;
const APPLICATIONS_COMMANDS = OAuth2Scopes.APPLICATIONS_COMMANDS;
object2.scopes = [APPLICATIONS_COMMANDS];
object2.channelId = channelId;
object2.dismissOAuthModal = function() {
return importDefault(dependencyMap[7]).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
};
object2.disableGuildSelect = true;
object2.callback = callback;
Reflect.apply(pushLazy, defaultImport, [value2, object2, OAUTH2_AUTHORIZE_MODAL_KEY]);
}
function openOAuth2ModalDismissOAuthModal() { // fn#69148, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:271, owner: openOAuth2Modal.dismissOAuthModal, offset: 0x01c6ae2d, size: 75 bytes, params: 1, frame: 12
if (env0_0.dismissOAuthModal != null) {
env0_0.dismissOAuthModal();
}
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
}
function installApplicationOnConfirm() { // fn#69150, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:807, owner: installApplication.onConfirm, offset: 0x01c6b0c7, size: 45 bytes, params: 1, frame: 12
let value = environment.__proto__;
value = importDefault(3853) /* metro dependency 3853: Linking */;
value.openURL(customInstallUrl);
}
function installApplicationCallback(a0) { // fn#69152, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:1189, owner: installApplication.callback, offset: 0x01c6b0f4, size: 57 bytes, params: 2, frame: 13
(importDefault(10203) /* metro dependency 10203: authorizeCallback */)(a0);
if (oauth2Callback != null) {
oauth2Callback(a0);
function installPrivateChannelIntegration({applicationId, channelId, callback}) { // fn#69154, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9055:1681, offset: 0x01c6b12d, size: 171 bytes, params: 2, frame: 22
const defaultImport = importDefault(dependencyMap[7]);
const pushLazy = defaultImport.pushLazy;
const value2 = require(dependencyMap[9])(dependencyMap[8], dependencyMap.paths);
const object = {clientId: applicationId};
const OAuth2Scopes = require(dependencyMap[10]).OAuth2Scopes;
const APPLICATIONS_COMMANDS = OAuth2Scopes.APPLICATIONS_COMMANDS;
object.scopes = [APPLICATIONS_COMMANDS];
object.channelId = channelId;
object.dismissOAuthModal = function() {
return importDefault(dependencyMap[7]).popWithKey(OAUTH2_AUTHORIZE_MODAL_KEY);
};
object.disableGuildSelect = true;
object.callback = callback;
Reflect.apply(pushLazy, defaultImport, [value2, object, OAUTH2_AUTHORIZE_MODAL_KEY]);
}
}
global.__d(_fun69146, 8870, [661, 8871, 683, 8872, 3853, 10203, 483, 5080, 10206, 1962, 4122,
2]) /* metro module 8870, dependencies: [661, 8871, 683, 8872, 3853, 10203, 483, 5080, 10206, 1962, 4122, 2] */;
+5 -2
View File
@@ -1,10 +1,12 @@
/* Metro module 6589; source: utils/native/AutocompleteUtils.tsx; dependencies: [661, 1244, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
function _fun51858(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#51858, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6767:6, offset: 0x012e643a, size: 142 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_2 = (require(661) /* metro dependency 661: Constants */).AutoCompleteResultTypes;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/AutocompleteUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/AutocompleteUtils.tsx');
exports.default = {MENTION_EVERYONE: function() {
var object = {'type': null, 'test': 'everyone', 'text': '@everyone'};
object.type = AutoCompleteResultTypes.GLOBAL;
@@ -20,3 +22,4 @@ function _fun51858(global, require, importDefault, importAll, module, exports, d
}};
}
global.__d(_fun51858, 6589, [661, 1244, 2]) /* metro module 6589, dependencies: [661, 1244, 2] */;
+63 -39
View File
@@ -1,67 +1,91 @@
/* Metro module 1426; source: utils/native/AvatarUtils.tsx; dependencies: [27, 1427, 1428, 1429, 1430, 1431, 1432, 1433, 1434, 1435, 1436, 1437, 1438, 1439, 1440, 1441, 1442, 1443, 1444, 1445, 1446, 1447, 1448, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 1456, 2] */
import Module01433 from '../../by-id/module-01433.js'; /* Metro dependency 1433 */
import Module01434 from '../../by-id/module-01434.js'; /* Metro dependency 1434 */
import Module01435 from '../../by-id/module-01435.js'; /* Metro dependency 1435 */
import Module01436 from '../../by-id/module-01436.js'; /* Metro dependency 1436 */
import Module01437 from '../../by-id/module-01437.js'; /* Metro dependency 1437 */
import Module01438 from '../../by-id/module-01438.js'; /* Metro dependency 1438 */
import Module01439 from '../../by-id/module-01439.js'; /* Metro dependency 1439 */
import Module01440 from '../../by-id/module-01440.js'; /* Metro dependency 1440 */
import Module01441 from '../../by-id/module-01441.js'; /* Metro dependency 1441 */
import Module01442 from '../../by-id/module-01442.js'; /* Metro dependency 1442 */
import Module01443 from '../../by-id/module-01443.js'; /* Metro dependency 1443 */
import Module01444 from '../../by-id/module-01444.js'; /* Metro dependency 1444 */
import Module01445 from '../../by-id/module-01445.js'; /* Metro dependency 1445 */
import Module01446 from '../../by-id/module-01446.js'; /* Metro dependency 1446 */
import Module01447 from '../../by-id/module-01447.js'; /* Metro dependency 1447 */
import Module01448 from '../../by-id/module-01448.js'; /* Metro dependency 1448 */
import Module01449 from '../../by-id/module-01449.js'; /* Metro dependency 1449 */
import Module01450 from '../../by-id/module-01450.js'; /* Metro dependency 1450 */
import Module01451 from '../../by-id/module-01451.js'; /* Metro dependency 1451 */
import Module01452 from '../../by-id/module-01452.js'; /* Metro dependency 1452 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
function _fun16653(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#16653, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1553:6, offset: 0x00e56fcc, size: 753 bytes, params: 8, frame: 25
const closure = ensureAvatarSource;
const ensureAvatarSource2 = ensureAvatarSource;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const value = require(27) /* metro dependency 27 */;
const env0_2 = value.Image;
const NativeModules = value.NativeModules;
const NativeModules = ReactNativeModule.NativeModules;
items4 = [importDefault(1427) /* metro dependency 1427 */, importDefault(1428) /* metro dependency 1428 */,
importDefault(1429) /* metro dependency 1429 */, importDefault(1430) /* metro dependency 1430 */,
importDefault(1431) /* metro dependency 1431 */, importDefault(1432) /* metro dependency 1432 */];
const items5 = [importDefault(1433) /* metro dependency 1433 */, importDefault(1434) /* metro dependency 1434 */,
importDefault(1435) /* metro dependency 1435 */, importDefault(1436) /* metro dependency 1436 */,
importDefault(1437) /* metro dependency 1437 */, importDefault(1438) /* metro dependency 1438 */];
const items2 = [importDefault(1439) /* metro dependency 1439 */, importDefault(1440) /* metro dependency 1440 */,
importDefault(1441) /* metro dependency 1441 */, importDefault(1442) /* metro dependency 1442 */,
importDefault(1443) /* metro dependency 1443 */, importDefault(1444) /* metro dependency 1444 */];
const items3 = [importDefault(1445) /* metro dependency 1445 */, importDefault(1446) /* metro dependency 1446 */,
importDefault(1447) /* metro dependency 1447 */, importDefault(1448) /* metro dependency 1448 */,
importDefault(1449) /* metro dependency 1449 */, importDefault(1450) /* metro dependency 1450 */,
importDefault(1451) /* metro dependency 1451 */, importDefault(1452) /* metro dependency 1452 */];
const items5 = [Module01433, Module01434,
Module01435, Module01436,
Module01437, Module01438];
const items2 = [Module01439, Module01440,
Module01441, Module01442,
Module01443, Module01444];
const items3 = [Module01445, Module01446,
Module01447, Module01448,
Module01449, Module01450,
Module01451, Module01452];
const Set = global.Set;
const MediaManager = NativeModules.MediaManager;
const getConstants = MediaManager.getConstants;
const set = new Set(Reflect.apply(getConstants, MediaManager, []).supportedExtensions);
const object3 = {DEFAULT_AVATARS: items4, DEFAULT_AVATARS_SMALL: items5, DEFAULT_AVATARS_SMALL_MAX_SIZE: 24,
const object = {DEFAULT_AVATARS: items4, DEFAULT_AVATARS_SMALL: items5, DEFAULT_AVATARS_SMALL_MAX_SIZE: 24,
DEFAULT_PROVISIONAL_AVATARS: items2, DEFAULT_GROUP_DM_AVATARS: items3};
object3.BOT_AVATARS = {clyde: importDefault(1453) /* metro dependency 1453 */,
object.BOT_AVATARS = {clyde: importDefault(1453) /* metro dependency 1453 */,
nitro_wumpus: importDefault(1454) /* metro dependency 1454 */};
object3.DEFAULT_CHANNEL_ICON = importDefault(1456) /* metro dependency 1456 */;
object3.ensureAvatarSource = closure;
object3.canUseWebp = canUseWebp;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/AvatarUtils.tsx');
exports.default = object3;
object.DEFAULT_CHANNEL_ICON = importDefault(1456) /* metro dependency 1456 */;
object.ensureAvatarSource = ensureAvatarSource2;
object.canUseWebp = canUseWebp;
(FileImportTrackerModule).fileFinishedImporting('utils/native/AvatarUtils.tsx');
exports.default = object;
exports.DEFAULT_AVATARS = items4;
exports.DEFAULT_AVATARS_SMALL = items5;
exports.DEFAULT_AVATARS_SMALL_MAX_SIZE = 24;
exports.DEFAULT_PROVISIONAL_AVATARS = items2;
exports.ensureAvatarSource = closure;
exports.ensureAvatarSource = ensureAvatarSource2;
exports.getAutomodAvatarURL = function() {
return importDefault(dependencyMap[29]);
};
}
function ensureAvatarSource(a0) { // fn#16654, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1553:436, offset: 0x00e572bd, size: 58 bytes, params: 2, frame: 12
var r0;
var Array;
let value = a0;
if (typeof value === 'number') {
value = Image.resolveAssetSource(value);
r0 = value;
} else {
Array = global.Array;
if (Array.isArray(value)) {
function ensureAvatarSource(a0) { // fn#16654, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1553:436, offset: 0x00e572bd, size: 58 bytes, params: 2, frame: 12
var r0;
var Array;
let value = a0;
if (typeof value === 'number') {
value = Image.resolveAssetSource(value);
r0 = value;
} else {
r0 = value;
Array = global.Array;
if (Array.isArray(value)) {
value = Image.resolveAssetSource(value);
r0 = value;
} else {
r0 = value;
}
}
return r0;
}
function canUseWebp() { // fn#16655, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1553:806, offset: 0x00e572f7, size: 25 bytes, params: 1, frame: 11
return env0_3.has('webp');
}
return r0;
}
function canUseWebp() { // fn#16655, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1553:806, offset: 0x00e572f7, size: 25 bytes, params: 1, frame: 11
return env0_3.has('webp');
}
global.__d(_fun16653, 1426, [27, 1427, 1428, 1429, 1430, 1431, 1432, 1433, 1434, 1435, 1436, 1437, 1438, 1439, 1440,
1441, 1442, 1443, 1444, 1445, 1446, 1447, 1448, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 1456,
2]) /* metro module 1426, dependencies: [27, 1427, 1428, 1429, 1430, 1431, 1432, 1433, 1434, 1435, 1436, 1437, 1438, 1439, 1440, 1441, 1442, 1443, 1444, 1445, 1446, 1447, 1448, 1449, 1450, 1451, 1452, 1453, 1454, 1455, 1456, 2] */;
+235 -223
View File
@@ -1,24 +1,34 @@
/* Metro module 15638; source: utils/native/CaptchaUtils.tsx; dependencies: [31, 27, 1949, 1310, 661, 33, 683, 4826, 4831, 566, 491, 562, 15639, 9486, 5080, 15640, 1962, 2] */
import AnalyticsUtils from '../AnalyticsUtils.tsx'; /* Metro dependency 683 */
import ThemeStore from '../../modules/user_settings/ThemeStore.tsx'; /* Metro dependency 1310 */
import LocaleStore from '../../modules/user_settings/LocaleStore.tsx'; /* Metro dependency 1949 */
import MonitoringAgent from '../../modules/monitoring/MonitoringAgent.tsx'; /* Metro dependency 4826 */
import ModalActionCreators from '../../actions/ModalActionCreators.tsx'; /* Metro dependency 5080 */
import Module15639 from '../../by-id/module-15639.jsx'; /* Metro dependency 15639 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as Module00491Module from '../../by-id/module-00491.js'; /* Metro dependency 491 */
import * as V8APIErrorModule from '../../external/discord_common/js/packages/http-utils/V8APIError.tsx'; /* Metro dependency 562 */
import * as MetricEventsModule from '../../external/discord_common/js/shared/shared-constants/MetricEvents.tsx'; /* Metro dependency 4831 */
import * as SharedCaptchaUtilsModule from '../../modules/captcha/SharedCaptchaUtils.tsx'; /* Metro dependency 9486 */
function _fun119750(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#119750, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:6, offset: 0x02517eb5, size: 358 bytes, params: 8, frame: 19
var object2;
let 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 */;
let value = ReactNativeModule;
const NativeModules = value.NativeModules;
const NativeEventEmitter = value.NativeEventEmitter;
const env0_4 = value.Keyboard;
const localeStore = importDefault(1949) /* metro dependency 1949: LocaleStore */;
const themeStore = importDefault(1310) /* metro dependency 1310: ThemeStore */;
value = require(661) /* metro dependency 661: Constants */;
const env0_7 = value.CaptchaEvent;
const env0_8 = value.RECAPTCHA_SITE_KEY;
const env0_9 = value.AnalyticEvents;
const env0_10 = (require(33) /* metro dependency 33 */).jsx;
const CaptchaManager = NativeModules.CaptchaManager;
const nativeEventEmitter = new NativeEventEmitter(CaptchaManager);
object2 = {showCaptcha: showCaptcha_119752, closeCaptcha: function() {
object = {showCaptcha: showCaptcha_119752, closeCaptcha: function() {
CaptchaManager.closeCaptcha();
}, showHcaptcha: function(a0, a1) {
var env0_0 = a0;
@@ -34,225 +44,227 @@ function _fun119750(global, require, importDefault, importAll, module, exports,
var value2 = new Promise(_fun119758);
return value2 instanceof Object ? value2 : value;
}};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/CaptchaUtils.tsx');
exports.default = object2;
(FileImportTrackerModule).fileFinishedImporting('utils/native/CaptchaUtils.tsx');
exports.default = object;
exports.InlineHcaptcha = InlineHcaptcha;
}
function trackCaptchaEvent(a0, a1, a2, a3) { // fn#119751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:305, offset: 0x0251801b, size: 206 bytes, params: 5, frame: 20
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
let CAPTCHA_EVENT = AnalyticEvents.CAPTCHA_EVENT;
Reflect.apply(track, defaultImport, [CAPTCHA_EVENT, {captcha_event_name: a0, captcha_service: a3, sitekey: a2,
captcha_flow_key: a1}]);
const defaultImport2 = importDefault(4826) /* metro dependency 4826: MonitoringAgent */;
const increment = defaultImport2.increment;
const MetricEvents = (require(4831) /* metro dependency 4831: MetricEvents */).MetricEvents;
CAPTCHA_EVENT = MetricEvents.CAPTCHA_EVENT;
Reflect.apply(increment, defaultImport2, [{name: CAPTCHA_EVENT, tags: ['event_name:' + a0,
'captcha_service:' + a3]}]);
}
function showCaptcha_119752() { // fn#119752, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:558, offset: 0x025180e9, size: 185 bytes, params: 1, frame: 20
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
const value = a0;
const r1 = value !== undefined ? value : CaptchaTypes.RECAPTCHA;
Keyboard.dismiss();
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const OPEN_MODAL = AnalyticEvents.OPEN_MODAL;
Reflect.apply(track, defaultImport, [OPEN_MODAL, {type: 'CAPTCHA'}]);
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
return r1 !== HCAPTCHA ? this.showRecaptcha() : a1 != null ? this.showHcaptcha(a1, a2) : this.showRecaptcha();
}
function showHcaptcha(a0, a1) { // fn#119754, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:808, offset: 0x025181b7, size: 53 bytes, params: 3, frame: 11
const env0_0 = a0;
const env0_1 = a1;
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun119755);
return promise instanceof Object ? promise : value;
}
function showRecaptcha() { // fn#119757, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1389, offset: 0x0251842a, size: 46 bytes, params: 1, frame: 11
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun119758);
return promise instanceof Object ? promise : value;
}
function InlineHcaptcha(a0) { // fn#119761, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2037, offset: 0x02518633, size: 247 bytes, params: 2, frame: 21
const siteKey = a0.siteKey;
const env0_1 = a0.onVerify;
const env0_2 = a0.onError;
const object2 = {'siteKey': 0, 'onVerify': 0, 'onError': 0};
silentSetPrototypeOf(object2, null, undefined);
const value = copyDataProperties({}, a0, object2, undefined);
const locale = (require(566) /* metro dependency 566: flux */).useStateFromStores([LocaleStore], function() {
return LocaleStore.locale;
});
const value3 = (require(491) /* metro dependency 491 */).v4();
value3.useEffect(_fun119763, [value3, siteKey]);
return ((Component) => <Component siteKey={siteKey} onMessage={onMessage} languageCode={locale} {...value} />)(importDefault(15639) /* metro dependency 15639 */);
}
function _fun119755(a0, a1) { // fn#119755, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:828, offset: 0x025181ec, size: 203 bytes, params: 3, frame: 22
var environment;
const env0_0 = a0;
const env0_1 = a1;
let value = environment.__proto__;
const value2 = require(dependencyMap[10]).v4();
const trackCaptchaEventBinding = trackCaptchaEvent;
const binding = env0_0;
const CaptchaTypes = require(dependencyMap[11]).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', value2, binding, HCAPTCHA);
value = importDefault(dependencyMap[14]);
value.pushLazy(require(dependencyMap[16])(dependencyMap[15], dependencyMap.paths), {siteKey: binding,
onMessage: onMessage_119756, rqdata: require}, 'hcaptcha');
}
function _fun119758(a0, a1) { // fn#119758, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1425, offset: 0x02518458, size: 198 bytes, params: 3, frame: 20
const env0_0 = a0;
const env0_1 = a1;
const value2 = (require(491) /* metro dependency 491 */).v4();
const trackCaptchaEventBinding = trackCaptchaEvent;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', value2, RECAPTCHA_SITE_KEY, HCAPTCHA);
CaptchaManager.showCaptcha(RECAPTCHA_SITE_KEY, ThemeStore.theme, 'https://cdn.discordapp.com/recaptcha/ios.html');
const binding = env1_12;
let addListener = binding.addListener;
const SOLVED = CaptchaEvent.SOLVED;
Reflect.apply(addListener, binding, [SOLVED, _fun119759]);
addListener = binding.addListener;
const EXPIRED = CaptchaEvent.EXPIRED;
Reflect.apply(addListener, binding, [EXPIRED, _fun119760]);
}
function _fun119763() { // fn#119763, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2189, offset: 0x0251872a, size: 66 bytes, params: 1, frame: 17
const trackCaptchaEventBinding = trackCaptchaEvent;
const binding = env0_3;
const siteKeyBinding = siteKey;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', binding, siteKeyBinding, HCAPTCHA);
}
function onMessage(a0) { // fn#119764, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2304, owner: InlineHcaptcha.onMessage, offset: 0x0251876c, size: 333 bytes, params: 2, frame: 22
var value;
const CaptchaError = (require(9486) /* metro dependency 9486: SharedCaptchaUtils */).CaptchaError;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
var defaultImport;
let data = a0.nativeEvent.data;
if (data != null) {
data = a0.nativeEvent.data;
value = environment.__proto__;
if (data === CaptchaError.CANCEL) {
trackCaptchaEvent(data, env0_3, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else if (data === CaptchaError.ERROR) {
trackCaptchaEvent(data, env0_3, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else if (data === CaptchaError.EXPIRED) {
trackCaptchaEvent(data, env0_3, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else {
trackCaptchaEvent('verify', env0_3, siteKey, CaptchaTypes.HCAPTCHA);
onVerify(data);
}
function trackCaptchaEvent(a0, a1, a2, a3) { // fn#119751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:305, offset: 0x0251801b, size: 206 bytes, params: 5, frame: 20
const defaultImport = AnalyticsUtils;
const track = defaultImport.track;
let CAPTCHA_EVENT = AnalyticEvents.CAPTCHA_EVENT;
Reflect.apply(track, defaultImport, [CAPTCHA_EVENT, {captcha_event_name: a0, captcha_service: a3, sitekey: a2,
captcha_flow_key: a1}]);
const defaultImport2 = MonitoringAgent;
const increment = defaultImport2.increment;
const MetricEvents = (MetricEventsModule).MetricEvents;
CAPTCHA_EVENT = MetricEvents.CAPTCHA_EVENT;
Reflect.apply(increment, defaultImport2, [{name: CAPTCHA_EVENT, tags: ['event_name:' + a0,
'captcha_service:' + a3]}]);
}
}
function onMessage_119756(a0) { // fn#119756, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:988, offset: 0x025182b7, size: 371 bytes, params: 2, frame: 21
var value2;
const CaptchaError = (require(9486) /* metro dependency 9486: SharedCaptchaUtils */).CaptchaError;
var trackCaptchaEventBinding;
var binding;
var value4;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
var value6;
var defaultImport;
const value = undefined;
let data = a0 == null ? value : a0.nativeEvent.data;
if (data != null) {
data = a0.nativeEvent.data;
value2 = environment.__proto__.__proto__;
if (data === CaptchaError.CANCEL) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else if (data === CaptchaError.ERROR) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else if (data === CaptchaError.EXPIRED) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value4 = environment.__proto__;
trackCaptchaEventBinding('verify', binding, env1_0, CaptchaTypes.HCAPTCHA);
env0_0(data);
}
function showCaptcha_119752() { // fn#119752, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:558, offset: 0x025180e9, size: 185 bytes, params: 1, frame: 20
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
const value = a0;
const r1 = value !== undefined ? value : CaptchaTypes.RECAPTCHA;
Keyboard.dismiss();
const defaultImport = AnalyticsUtils;
const track = defaultImport.track;
const OPEN_MODAL = AnalyticEvents.OPEN_MODAL;
Reflect.apply(track, defaultImport, [OPEN_MODAL, {type: 'CAPTCHA'}]);
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
return r1 !== HCAPTCHA ? this.showRecaptcha() : a1 != null ? this.showHcaptcha(a1, a2) : this.showRecaptcha();
}
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).pop();
return value;
}
function _fun119759(a0) { // fn#119759, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1619, offset: 0x0251851e, size: 93 bytes, params: 2, frame: 18
let binding = env1_0;
binding.closeCaptcha();
const trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
const RECAPTCHA = CaptchaTypes.RECAPTCHA;
trackCaptchaEventBinding('verify', binding, RECAPTCHA_SITE_KEY, RECAPTCHA);
env0_0(a0);
}
function _fun119760() { // fn#119760, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1740, offset: 0x0251857b, size: 184 bytes, params: 1, frame: 22
let binding = env1_0;
binding.closeCaptcha();
const trackCaptchaEventBinding = trackCaptchaEvent;
const CaptchaError = (require(9486) /* metro dependency 9486: SharedCaptchaUtils */).CaptchaError;
let EXPIRED = CaptchaError.EXPIRED;
binding = env0_2;
const CaptchaTypes = (require(562) /* metro dependency 562: V8APIError */).CaptchaTypes;
const RECAPTCHA = CaptchaTypes.RECAPTCHA;
trackCaptchaEventBinding(EXPIRED, binding, RECAPTCHA_SITE_KEY, RECAPTCHA);
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const CAPTCHA_FAILED = AnalyticEvents.CAPTCHA_FAILED;
Reflect.apply(track, defaultImport, [CAPTCHA_FAILED, {reason: 'expired'}]);
EXPIRED = CaptchaError.EXPIRED;
require(EXPIRED);
function showHcaptcha(a0, a1) { // fn#119754, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:808, offset: 0x025181b7, size: 53 bytes, params: 3, frame: 11
const env0_0 = a0;
const env0_1 = a1;
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun119755);
return promise instanceof Object ? promise : value;
function _fun119755(a0, a1) { // fn#119755, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:828, offset: 0x025181ec, size: 203 bytes, params: 3, frame: 22
var environment;
const env0_0 = a0;
const env0_1 = a1;
let value = environment.__proto__;
const value2 = require(dependencyMap[10]).v4();
const trackCaptchaEventBinding = trackCaptchaEvent;
const binding = env0_0;
const CaptchaTypes = require(dependencyMap[11]).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', value2, binding, HCAPTCHA);
value = importDefault(dependencyMap[14]);
value.pushLazy(require(dependencyMap[16])(dependencyMap[15], dependencyMap.paths), {siteKey: binding,
onMessage: onMessage_119756, rqdata: require}, 'hcaptcha');
function onMessage_119756(a0) { // fn#119756, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:988, offset: 0x025182b7, size: 371 bytes, params: 2, frame: 21
var value2;
const CaptchaError = (SharedCaptchaUtilsModule).CaptchaError;
var trackCaptchaEventBinding;
var binding;
var value4;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
var value6;
var defaultImport;
const value = undefined;
let data = a0 == null ? value : a0.nativeEvent.data;
if (data != null) {
data = a0.nativeEvent.data;
value2 = environment.__proto__.__proto__;
if (data === CaptchaError.CANCEL) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else if (data === CaptchaError.ERROR) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else if (data === CaptchaError.EXPIRED) {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value6 = environment.__proto__;
trackCaptchaEventBinding(data, binding, env1_0, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
require(data);
} else {
trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
value4 = environment.__proto__;
trackCaptchaEventBinding('verify', binding, env1_0, CaptchaTypes.HCAPTCHA);
env0_0(data);
}
}
(ModalActionCreators).pop();
return value;
}
}
}
function showRecaptcha() { // fn#119757, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1389, offset: 0x0251842a, size: 46 bytes, params: 1, frame: 11
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun119758);
return promise instanceof Object ? promise : value;
function _fun119758(a0, a1) { // fn#119758, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1425, offset: 0x02518458, size: 198 bytes, params: 3, frame: 20
const env0_0 = a0;
const env0_1 = a1;
const value2 = (Module00491Module).v4();
const trackCaptchaEventBinding = trackCaptchaEvent;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', value2, RECAPTCHA_SITE_KEY, HCAPTCHA);
CaptchaManager.showCaptcha(RECAPTCHA_SITE_KEY, ThemeStore.theme, 'https://cdn.discordapp.com/recaptcha/ios.html');
const binding = env1_12;
let addListener = binding.addListener;
const SOLVED = CaptchaEvent.SOLVED;
Reflect.apply(addListener, binding, [SOLVED, _fun119759]);
addListener = binding.addListener;
const EXPIRED = CaptchaEvent.EXPIRED;
Reflect.apply(addListener, binding, [EXPIRED, _fun119760]);
function _fun119759(a0) { // fn#119759, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1619, offset: 0x0251851e, size: 93 bytes, params: 2, frame: 18
let binding = env1_0;
binding.closeCaptcha();
const trackCaptchaEventBinding = trackCaptchaEvent;
binding = env0_2;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
const RECAPTCHA = CaptchaTypes.RECAPTCHA;
trackCaptchaEventBinding('verify', binding, RECAPTCHA_SITE_KEY, RECAPTCHA);
env0_0(a0);
}
function _fun119760() { // fn#119760, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:1740, offset: 0x0251857b, size: 184 bytes, params: 1, frame: 22
let binding = env1_0;
binding.closeCaptcha();
const trackCaptchaEventBinding = trackCaptchaEvent;
const CaptchaError = (SharedCaptchaUtilsModule).CaptchaError;
let EXPIRED = CaptchaError.EXPIRED;
binding = env0_2;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
const RECAPTCHA = CaptchaTypes.RECAPTCHA;
trackCaptchaEventBinding(EXPIRED, binding, RECAPTCHA_SITE_KEY, RECAPTCHA);
const defaultImport = AnalyticsUtils;
const track = defaultImport.track;
const CAPTCHA_FAILED = AnalyticEvents.CAPTCHA_FAILED;
Reflect.apply(track, defaultImport, [CAPTCHA_FAILED, {reason: 'expired'}]);
EXPIRED = CaptchaError.EXPIRED;
require(EXPIRED);
}
}
}
function InlineHcaptcha(a0) { // fn#119761, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2037, offset: 0x02518633, size: 247 bytes, params: 2, frame: 21
const siteKey = a0.siteKey;
const env0_1 = a0.onVerify;
const env0_2 = a0.onError;
const object = {'siteKey': 0, 'onVerify': 0, 'onError': 0};
silentSetPrototypeOf(object, null, undefined);
const value = copyDataProperties({}, a0, object, undefined);
const locale = (require(566) /* metro dependency 566: flux */).useStateFromStores([LocaleStore], function() {
return LocaleStore.locale;
});
const value3 = (Module00491Module).v4();
value3.useEffect(_fun119763, [value3, siteKey]);
return ((Component) => <Component siteKey={siteKey} onMessage={onMessage_119764} languageCode={locale} {...value} />)(Module15639);
function _fun119763() { // fn#119763, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2189, offset: 0x0251872a, size: 66 bytes, params: 1, frame: 17
const trackCaptchaEventBinding = trackCaptchaEvent;
const siteKeyBinding = siteKey;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
const HCAPTCHA = CaptchaTypes.HCAPTCHA;
trackCaptchaEventBinding('initial-load', ReactModule, siteKeyBinding, HCAPTCHA);
}
function InlineHcaptchaOnMessage(a0) { // fn#119764, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15846:2304, owner: InlineHcaptcha.onMessage, offset: 0x0251876c, size: 333 bytes, params: 2, frame: 22
var value;
const CaptchaError = (SharedCaptchaUtilsModule).CaptchaError;
const CaptchaTypes = (V8APIErrorModule).CaptchaTypes;
var defaultImport;
let data = a0.nativeEvent.data;
if (data != null) {
data = a0.nativeEvent.data;
value = environment.__proto__;
if (data === CaptchaError.CANCEL) {
trackCaptchaEvent(data, ReactModule, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else if (data === CaptchaError.ERROR) {
trackCaptchaEvent(data, ReactModule, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else if (data === CaptchaError.EXPIRED) {
trackCaptchaEvent(data, ReactModule, siteKey, CaptchaTypes.HCAPTCHA);
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.CAPTCHA_FAILED, {reason: data});
if (onError != null) {
onError(data);
}
} else {
trackCaptchaEvent('verify', ReactModule, siteKey, CaptchaTypes.HCAPTCHA);
onVerify(data);
}
}
}
}
}
global.__d(_fun119750, 15638, [31, 27, 1949, 1310, 661, 33, 683, 4826, 4831, 566, 491, 562, 15639, 9486, 5080,
15640, 1962,
2]) /* metro module 15638, dependencies: [31, 27, 1949, 1310, 661, 33, 683, 4826, 4831, 566, 491, 562, 15639, 9486, 5080, 15640, 1962, 2] */;
+241 -233
View File
@@ -1,30 +1,37 @@
/* Metro module 8340; source: utils/native/ChangeLogUtils.tsx; dependencies: [31, 27, 33, 4501, 697, 6235, 4597, 6766, 3855, 2] */
import Native from '../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import Module03855 from '../../by-id/module-03855.js'; /* Metro dependency 3855 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as LegacyTokensModule from '../../design/migrations/native/LegacyTokens.tsx'; /* Metro dependency 6235 */
import * as TextWithIOSLinkWorkaroundModule from '../../modules/a11y/native/TextWithIOSLinkWorkaround.tsx'; /* Metro dependency 6766 */
function _fun66412(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66412, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:6, offset: 0x01bfa8fa, size: 526 bytes, params: 8, frame: 23
var object2;
let env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
ReactModule;
let value = ReactNativeModule;
const env0_3 = value.View;
const env0_4 = value.Image;
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const TEXT_LINK = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_LINK;
object2.link = {color: TEXT_LINK};
object2.list = {marginBottom: 10};
object2.image = {'alignSelf': 'center', 'flex': 1};
const DARK_PRIMARY_500_LIGHT_PRIMARY_300 = (require(6235) /* metro dependency 6235: LegacyTokens */).DARK_PRIMARY_500_LIGHT_PRIMARY_300;
object2.container = {'borderLeftWidth': 2, 'paddingLeft': 8, 'marginBottom': 10,
object = {};
const TEXT_LINK = (Native).colors.TEXT_LINK;
object.link = {color: TEXT_LINK};
object.list = {marginBottom: 10};
object.image = {'alignSelf': 'center', 'flex': 1};
const DARK_PRIMARY_500_LIGHT_PRIMARY_300 = (LegacyTokensModule).DARK_PRIMARY_500_LIGHT_PRIMARY_300;
object.container = {'borderLeftWidth': 2, 'paddingLeft': 8, 'marginBottom': 10,
borderLeftColor: DARK_PRIMARY_500_LIGHT_PRIMARY_300};
const TEXT_MUTED = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_MUTED;
object2.text = {'fontSize': 14, 'lineHeight': 18, 'marginBottom': 8, color: TEXT_MUTED};
const env0_6 = Reflect.apply(createStyles, value, [object2]);
const TEXT_MUTED = (Native).colors.TEXT_MUTED;
object.text = {'fontSize': 14, 'lineHeight': 18, 'marginBottom': 8, color: TEXT_MUTED};
const env0_6 = Reflect.apply(createStyles, value, [object]);
value = importAll(4597) /* metro dependency 4597: CustomMarkupNative */;
value = value.createRules({});
object2 = {link: function(a0) {
object = {link: function(a0) {
var env0_0 = a0;
return {react: _fun66424};
}, lheading: function(a0) {
@@ -37,230 +44,231 @@ function _fun66412(global, require, importDefault, importAll, module, exports, d
var env0_0 = a0;
return {react: _fun66430};
}};
object2.image = {react: react};
object2.blockQuote = {react: react_66432};
object2.paragraph = function(a0) {
object.image = {react: react};
object.blockQuote = {react: react_66432};
object.paragraph = function(a0) {
var env0_0 = a0;
return {react: _fun66434};
};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ChangeLogUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/ChangeLogUtils.tsx');
exports.baseRules = value;
exports.customRules = object2;
}
function ChangeLogLink({node, output, state, styling}) { // fn#66413, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:493, offset: 0x01bfab08, size: 131 bytes, params: 2, frame: 20
const styles = useStyles();
const Link = styling.components.Link;
const linkProps = {className: styles.link, target: node.target};
const content = node.content;
const object = {};
copyDataProperties(object, state, undefined);
object['inLink'] = true;
return (
<Link {...linkProps} key={state.key}>
{output(content, object)}
</Link>
);
}
function ChangeLogList({node, output, state, styling}) { // fn#66414, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:671, offset: 0x01bfab8b, size: 131 bytes, params: 2, frame: 18
const styles = useStyles();
const List = styling.components.List;
return ((Component) => <Component style={styles.list} key={state.key}>{node.items.map(_fun66415)}</Component>)(List || View);
}
function ChangeLogParagraph({node, output, state, styling}) { // fn#66420, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1182, offset: 0x01bfadb9, size: 146 bytes, params: 2, frame: 20
const styles = useStyles();
const Paragraph = styling.components?.Paragraph;
return ((Component) => <Component variant="text-sm/normal" style={styles.text} key={state.key}>{output(node.content,
state)}</Component>)(Paragraph ?? (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround);
}
function ChangeLogImage({node, state}) { // fn#66421, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1433, offset: 0x01bfae4b, size: 108 bytes, params: 2, frame: 20
const styles = useStyles();
const value = importDefault(3855) /* metro dependency 3855 */;
return (
<Image
style={styles.image}
source={{uri: value.sanitizeUrl(node.target)}}
key={state.key}
/>
);
}
function ChangeLogBlockQuote({node, output, state}) { // fn#66422, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1562, offset: 0x01bfaeb7, size: 142 bytes, params: 2, frame: 22
const styles = useStyles();
const viewBindingProps = {style: styles.container};
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
return (
<View {...viewBindingProps} key={state.key}>
<TextWithIOSLinkWorkaround variant="text-sm/normal" style={styles.text}>
{output(node.content, state)}
</TextWithIOSLinkWorkaround>
</View>
);
}
function link_66423(a0) { // fn#66423, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1788, offset: 0x01bfaf45, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66424};
}
function lheading(a0) { // fn#66425, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1897, offset: 0x01bfafa0, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66426};
}
function heading(a0) { // fn#66427, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2006, offset: 0x01bfb008, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66428};
}
function list(a0) { // fn#66429, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2125, offset: 0x01bfb07b, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66430};
}
function react(a0, a1, a2) { // fn#66431, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2213, offset: 0x01bfb0ce, size: 46 bytes, params: 4, frame: 13
return (
<ChangeLogImage
node={a0}
output={a1}
state={a2}
/>
);
}
function react_66432(a0, a1, a2) { // fn#66432, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2285, offset: 0x01bfb0fc, size: 46 bytes, params: 4, frame: 13
return (
<ChangeLogBlockQuote
node={a0}
output={a1}
state={a2}
/>
);
}
function paragraph(a0) { // fn#66433, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2354, offset: 0x01bfb12a, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66434};
}
function _fun66415(a0, a1) { // fn#66415, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:811, offset: 0x01bfac0e, size: 62 bytes, params: 3, frame: 15
const env0_0 = a0;
const ListItem = styling.components.ListItem;
return <ListItem {...{children: children_66416}} key={a1} />;
}
function link_66423React(a0, a1, a2) { // fn#66424, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1799, owner: link_66423.react, offset: 0x01bfaf5e, size: 66 bytes, params: 4, frame: 13
return (
<ChangeLogLink
accessibilityRole="link"
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
function lheadingReact(a0, a1, a2) { // fn#66426, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1908, owner: lheading.react, offset: 0x01bfafb9, size: 79 bytes, params: 4, frame: 17
const LHeading = env0_0.components.LHeading;
return (
<LHeading className={a0.className} key={a2.key}>
{a1(a0.content, a2)}
</LHeading>
);
}
function headingReact(a0, a1, a2) { // fn#66428, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2017, owner: heading.react, offset: 0x01bfb021, size: 90 bytes, params: 4, frame: 17
const Heading = env0_0.components.Heading;
return (
<Heading
className={a0.className}
level={a0.level}
key={a2.key}
>
{a1(a0.content, a2)}
</Heading>
);
}
function listReact(a0, a1, a2) { // fn#66430, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2136, owner: list.react, offset: 0x01bfb094, size: 58 bytes, params: 4, frame: 13
return (
<ChangeLogList
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
function paragraphReact(a0, a1, a2) { // fn#66434, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2365, owner: paragraph.react, offset: 0x01bfb143, size: 58 bytes, params: 4, frame: 13
return (
<ChangeLogParagraph
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
function children_66416(a0) { // fn#66416, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:852, offset: 0x01bfac4c, size: 38 bytes, params: 2, frame: 17
return ((a0, a1, a2, a3) => {
var env0_0 = a1;
var env0_1 = a2;
var env0_2 = a3;
var closure = _fun66418;
var env0_5 = closure;
var env0_4 = [];
a0.forEach(_fun66419);
closure();
return [];
})(env0_0, output, state, a0);
}
function processListItem(a0, a1, a2, a3) { // fn#66417, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:855, owner: children_66416.processListItem, offset: 0x01bfac72, size: 78 bytes, params: 5, frame: 13
const env0_0 = a1;
const env0_1 = a2;
const env0_2 = a3;
const closure = renderText;
const env0_4 = [];
a0.forEach(_fun66419);
closure();
return [];
}
function renderText() { // fn#66418, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:903, owner: children_66416.processListItem.renderText, offset: 0x01bfacc0, size: 142 bytes, params: 1, frame: 20
var binding;
var push;
var value2;
if (env0_4.length > 0) {
binding = env0_3;
push = binding.push;
value2 = environment.__proto__.__proto__.__proto__.__proto__;
Reflect.apply(push, binding,
[((TextWithIOSLinkWorkaround) => <TextWithIOSLinkWorkaround variant="text-sm/normal" {...importAll} key={-1}>{require(env0_4,
importDefault)}</TextWithIOSLinkWorkaround>)((require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround)]);
env0_4 = [];
exports.customRules = object;
function ChangeLogLink({node, output, state, styling}) { // fn#66413, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:493, offset: 0x01bfab08, size: 131 bytes, params: 2, frame: 20
const styles = useStyles();
const Link = styling.components.Link;
const linkProps = {className: styles.link, target: node.target};
const content = node.content;
const object2 = {};
copyDataProperties(object2, state, undefined);
object2['inLink'] = true;
return (
<Link {...linkProps} key={state.key}>
{output(content, object2)}
</Link>
);
}
}
function _fun66419(a0, a1) { // fn#66419, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1058, offset: 0x01bfad4e, size: 107 bytes, params: 3, frame: 19
var binding;
var push;
var value2;
if (a0.type === 'list') {
renderText();
binding = env0_3;
push = binding.push;
value2 = environment.__proto__.__proto__.__proto__.__proto__;
Reflect.apply(push, binding, [<View key={a1}>{require(a0, importDefault)}</View>]);
} else {
env0_4.push(a0);
function ChangeLogList({node, output, state, styling}) { // fn#66414, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:671, offset: 0x01bfab8b, size: 131 bytes, params: 2, frame: 18
const styles = useStyles();
const List = styling.components.List;
return ((Component) => <Component style={styles.list} key={state.key}>{node.items.map(_fun66415)}</Component>)(List || View);
function _fun66415(a0, a1) { // fn#66415, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:811, offset: 0x01bfac0e, size: 62 bytes, params: 3, frame: 15
const env0_0 = a0;
const ListItem = styling.components.ListItem;
return <ListItem {...{children: children_66416}} key={a1} />;
function children_66416(a0) { // fn#66416, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:852, offset: 0x01bfac4c, size: 38 bytes, params: 2, frame: 17
return ((a0, a1, a2, a3) => {
var env0_0 = a1;
var env0_1 = a2;
var env0_2 = a3;
var closure = _fun66418;
var env0_5 = closure;
var env0_4 = [];
a0.forEach(_fun66419);
closure();
return [];
})(env0_0, output, state, a0);
function processListItem(a0, a1, a2, a3) { // fn#66417, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:855, owner: children_66416.processListItem, offset: 0x01bfac72, size: 78 bytes, params: 5, frame: 13
const env0_0 = a1;
const env0_1 = a2;
const env0_2 = a3;
const renderText2 = renderText;
const env0_4 = [];
a0.forEach(_fun66419);
renderText2();
return [];
function renderText() { // fn#66418, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:903, owner: children_66416.processListItem.renderText, offset: 0x01bfacc0, size: 142 bytes, params: 1, frame: 20
var binding;
var push;
var value2;
if (items2.length > 0) {
binding = env0_3;
push = binding.push;
value2 = environment.__proto__.__proto__.__proto__.__proto__;
Reflect.apply(push, binding,
[((TextWithIOSLinkWorkaround) => <TextWithIOSLinkWorkaround variant="text-sm/normal" {...importAll} key={-1}>{require(items2,
importDefault)}</TextWithIOSLinkWorkaround>)((require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround)]);
items2 = [];
}
}
function _fun66419(a0, a1) { // fn#66419, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1058, offset: 0x01bfad4e, size: 107 bytes, params: 3, frame: 19
var binding;
var push;
var value2;
if (a0.type === 'list') {
renderText();
binding = env0_3;
push = binding.push;
value2 = environment.__proto__.__proto__.__proto__.__proto__;
Reflect.apply(push, binding, [<View key={a1}>{require(a0, importDefault)}</View>]);
} else {
env0_4.push(a0);
}
}
}
}
}
}
function ChangeLogParagraph({node, output, state, styling}) { // fn#66420, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1182, offset: 0x01bfadb9, size: 146 bytes, params: 2, frame: 20
const styles = useStyles();
const Paragraph = styling.components?.Paragraph;
return ((Component) => <Component variant="text-sm/normal" style={styles.text} key={state.key}>{output(node.content,
state)}</Component>)(Paragraph ?? (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround);
}
function ChangeLogImage({node, state}) { // fn#66421, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1433, offset: 0x01bfae4b, size: 108 bytes, params: 2, frame: 20
const styles = useStyles();
return (
<Image
style={styles.image}
source={{uri: Module03855.sanitizeUrl(node.target)}}
key={state.key}
/>
);
}
function ChangeLogBlockQuote({node, output, state}) { // fn#66422, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1562, offset: 0x01bfaeb7, size: 142 bytes, params: 2, frame: 22
const styles = useStyles();
const viewBindingProps = {style: styles.container};
const TextWithIOSLinkWorkaround = (TextWithIOSLinkWorkaroundModule).TextWithIOSLinkWorkaround;
return (
<View {...viewBindingProps} key={state.key}>
<TextWithIOSLinkWorkaround variant="text-sm/normal" style={styles.text}>
{output(node.content, state)}
</TextWithIOSLinkWorkaround>
</View>
);
}
function link_66423(a0) { // fn#66423, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1788, offset: 0x01bfaf45, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66424};
function link_66423React(a0, a1, a2) { // fn#66424, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1799, owner: link_66423.react, offset: 0x01bfaf5e, size: 66 bytes, params: 4, frame: 13
return (
<ChangeLogLink
accessibilityRole="link"
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
}
function lheading(a0) { // fn#66425, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1897, offset: 0x01bfafa0, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66426};
function lheadingReact(a0, a1, a2) { // fn#66426, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:1908, owner: lheading.react, offset: 0x01bfafb9, size: 79 bytes, params: 4, frame: 17
const LHeading = env0_0.components.LHeading;
return (
<LHeading className={a0.className} key={a2.key}>
{a1(a0.content, a2)}
</LHeading>
);
}
}
function heading(a0) { // fn#66427, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2006, offset: 0x01bfb008, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66428};
function headingReact(a0, a1, a2) { // fn#66428, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2017, owner: heading.react, offset: 0x01bfb021, size: 90 bytes, params: 4, frame: 17
const Heading = env0_0.components.Heading;
return (
<Heading
className={a0.className}
level={a0.level}
key={a2.key}
>
{a1(a0.content, a2)}
</Heading>
);
}
}
function list_66429(a0) { // fn#66429, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2125, offset: 0x01bfb07b, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66430};
function list_66429React(a0, a1, a2) { // fn#66430, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2136, owner: list_66429.react, offset: 0x01bfb094, size: 58 bytes, params: 4, frame: 13
return (
<ChangeLogList
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
}
function react(a0, a1, a2) { // fn#66431, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2213, offset: 0x01bfb0ce, size: 46 bytes, params: 4, frame: 13
return (
<ChangeLogImage
node={a0}
output={a1}
state={a2}
/>
);
}
function react_66432(a0, a1, a2) { // fn#66432, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2285, offset: 0x01bfb0fc, size: 46 bytes, params: 4, frame: 13
return (
<ChangeLogBlockQuote
node={a0}
output={a1}
state={a2}
/>
);
}
function paragraph(a0) { // fn#66433, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2354, offset: 0x01bfb12a, size: 25 bytes, params: 2, frame: 2
const env0_0 = a0;
return {react: react_66434};
function paragraphReact(a0, a1, a2) { // fn#66434, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8525:2365, owner: paragraph.react, offset: 0x01bfb143, size: 58 bytes, params: 4, frame: 13
return (
<ChangeLogParagraph
node={a0}
output={a1}
state={a2}
styling={env0_0}
/>
);
}
}
}
global.__d(_fun66412, 8340, [31, 27, 33, 4501, 697, 6235, 4597, 6766, 3855,
2]) /* metro module 8340, dependencies: [31, 27, 33, 4501, 697, 6235, 4597, 6766, 3855, 2] */;
+416 -383
View File
@@ -1,4 +1,37 @@
/* Metro module 6647; source: utils/native/ChannelUtils.tsx; dependencies: [1945, 1867, 1878, 661, 6648, 6649, 6650, 6651, 6652, 6653, 6654, 6655, 6656, 6657, 6658, 6659, 6660, 6661, 6662, 6663, 6664, 6667, 6668, 6669, 5107, 6670, 6671, 6672, 6673, 6674, 6675, 6676, 6677, 6678, 6679, 6680, 6681, 6682, 6683, 6684, 6685, 6686, 6687, 6688, 6689, 6690, 6691, 6692, 6693, 6694, 6695, 6696, 6697, 6698, 6699, 6700, 6701, 6702, 6703, 6704, 6705, 6706, 6707, 6708, 6709, 6710, 6711, 6712, 2] */
import GuildStore from '../../stores/GuildStore.tsx'; /* Metro dependency 1867 */
import UserStore from '../../stores/UserStore.tsx'; /* Metro dependency 1878 */
import GuildMemberStore from '../../stores/GuildMemberStore.tsx'; /* Metro dependency 1945 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as UseShowMemberVerificationGateModule from '../../modules/guild_member_verification/hooks/useShowMemberVerificationGate.tsx'; /* Metro dependency 6664 */
import * as ChatIconModule from '../../design/components/Icon/native/redesign/generated/ChatIcon.tsx'; /* Metro dependency 6682 */
import * as ThreadIconModule from '../../design/components/Icon/native/redesign/generated/ThreadIcon.tsx'; /* Metro dependency 6684 */
import * as BookCheckIconModule from '../../design/components/Icon/native/redesign/generated/BookCheckIcon.tsx'; /* Metro dependency 6686 */
import * as TextWarningIconModule from '../../design/components/Icon/native/redesign/generated/TextWarningIcon.tsx'; /* Metro dependency 6687 */
import * as TextSpoilerIconModule from '../../design/components/Icon/native/redesign/generated/TextSpoilerIcon.tsx'; /* Metro dependency 6688 */
import * as TextLockIconModule from '../../design/components/Icon/native/redesign/generated/TextLockIcon.tsx'; /* Metro dependency 6689 */
import * as TextControllerIconModule from '../../design/components/Icon/native/redesign/generated/TextControllerIcon.tsx'; /* Metro dependency 6690 */
import * as TextIconModule from '../../design/components/Icon/native/redesign/generated/TextIcon.tsx'; /* Metro dependency 6691 */
import * as ImageWarningIconModule from '../../design/components/Icon/native/redesign/generated/ImageWarningIcon.tsx'; /* Metro dependency 6692 */
import * as ForumWarningIconModule from '../../design/components/Icon/native/redesign/generated/ForumWarningIcon.tsx'; /* Metro dependency 6693 */
import * as ForumSpoilerIconModule from '../../design/components/Icon/native/redesign/generated/ForumSpoilerIcon.tsx'; /* Metro dependency 6694 */
import * as ImageLockIconModule from '../../design/components/Icon/native/redesign/generated/ImageLockIcon.tsx'; /* Metro dependency 6695 */
import * as ForumLockIconModule from '../../design/components/Icon/native/redesign/generated/ForumLockIcon.tsx'; /* Metro dependency 6696 */
import * as ImageIconModule from '../../design/components/Icon/native/redesign/generated/ImageIcon.tsx'; /* Metro dependency 6697 */
import * as ForumIconModule from '../../design/components/Icon/native/redesign/generated/ForumIcon.tsx'; /* Metro dependency 6698 */
import * as AnnouncementsWarningIconModule from '../../design/components/Icon/native/redesign/generated/AnnouncementsWarningIcon.tsx'; /* Metro dependency 6701 */
import * as AnnouncementsSpoilerIconModule from '../../design/components/Icon/native/redesign/generated/AnnouncementsSpoilerIcon.tsx'; /* Metro dependency 6702 */
import * as AnnouncementsLockIconModule from '../../design/components/Icon/native/redesign/generated/AnnouncementsLockIcon.tsx'; /* Metro dependency 6703 */
import * as AnnouncementsIconModule from '../../design/components/Icon/native/redesign/generated/AnnouncementsIcon.tsx'; /* Metro dependency 6704 */
import * as LockIconModule from '../../design/components/Icon/native/redesign/generated/LockIcon.tsx'; /* Metro dependency 6705 */
import * as StageLockIconModule from '../../design/components/Icon/native/redesign/generated/StageLockIcon.tsx'; /* Metro dependency 6706 */
import * as StageIconModule from '../../design/components/Icon/native/redesign/generated/StageIcon.tsx'; /* Metro dependency 6707 */
import * as VoiceLockIconModule from '../../design/components/Icon/native/redesign/generated/VoiceLockIcon.tsx'; /* Metro dependency 6708 */
import * as VoiceWarningIconModule from '../../design/components/Icon/native/redesign/generated/VoiceWarningIcon.tsx'; /* Metro dependency 6709 */
import * as VoiceNormalSpoilerIconModule from '../../design/components/Icon/native/redesign/generated/VoiceNormalSpoilerIcon.tsx'; /* Metro dependency 6710 */
import * as VoiceNormalIconModule from '../../design/components/Icon/native/redesign/generated/VoiceNormalIcon.tsx'; /* Metro dependency 6711 */
function _fun52587(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#52587, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:6, offset: 0x0133153b, size: 259 bytes, params: 8, frame: 22
const env0_0 = require;
const closure = function(a0) {
@@ -13,75 +46,112 @@ function _fun52587(global, require, importDefault, importAll, module, exports, d
}
return null;
};
const closure2 = getChannelIcon;
const closure3 = getChannelIconComponent;
const getChannelIcon2 = getChannelIcon;
const getChannelIconComponent2 = getChannelIconComponent;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_6 = (require(661) /* metro dependency 661: Constants */).ChannelTypes;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ChannelUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/ChannelUtils.tsx');
exports.getThreadChannelIcon = closure;
exports.getSimpleChannelIcon = getSimpleChannelIcon;
exports.getChannelIconWithGuild = getChannelIconWithGuild;
exports.getChannelMentionIcon = getChannelMentionIcon;
exports.getChannelIcon = closure2;
exports.getChannelIcon = getChannelIcon2;
exports.getChannelIconComponentWithGuild = getChannelIconComponentWithGuild;
exports.getChannelIconComponent = closure3;
exports.getChannelIconComponent = getChannelIconComponent2;
exports.getSimpleChannelIconComponent = getSimpleChannelIconComponent;
}
function getChannelIcon(a0, a1) { // fn#52589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:313, offset: 0x013316a2, size: 1908 bytes, params: 3, frame: 28
var r10;
var r7;
var r9;
const value = a1;
const {isRulesChannel, textFocused, locked} = value ?? ({});
const moduleValue = require(dependencyMap[20]);
const shouldShowMembershipVerificationGate2 = moduleValue.shouldShowMembershipVerificationGate(a0.guild_id,
[GuildStore, UserStore, GuildMemberStore]);
if (a0.isForumPost()) {
return importDefault(dependencyMap[16]);
}
const getThreadChannelIconBinding = getThreadChannelIcon;
let type = a0.type;
const threadChannelIconBinding = getThreadChannelIconBinding(type);
if (threadChannelIconBinding != null) {
return threadChannelIconBinding;
}
const isMediaChannel2 = a0.isMediaChannel();
const isNSFW2 = a0.isNSFW();
type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return importDefault(dependencyMap[6]);
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[22]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[23]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[23]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[22]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[23]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[23]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]);
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
if (isRulesChannel) {
r7 = importDefault(dependencyMap[21]);
} else if (isNSFW2) {
if (value == null) {
r7 = isMediaChannel2 ? dependencyMap[26] : dependencyMap[27];
r7 = importDefault(r7);
} else if (value.ignoreTraits) {
function getChannelIcon(a0, a1) { // fn#52589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:313, offset: 0x013316a2, size: 1908 bytes, params: 3, frame: 28
var r10;
var r7;
var r9;
const value = a1;
const {isRulesChannel, textFocused, locked} = value ?? ({});
const moduleValue = require(dependencyMap[20]);
const shouldShowMembershipVerificationGate2 = moduleValue.shouldShowMembershipVerificationGate(a0.guild_id,
[GuildStore, UserStore, GuildMemberStore]);
if (a0.isForumPost()) {
return importDefault(dependencyMap[16]);
}
const getThreadChannelIconBinding = getThreadChannelIcon;
let type = a0.type;
const threadChannelIconBinding = getThreadChannelIconBinding(type);
if (threadChannelIconBinding != null) {
return threadChannelIconBinding;
}
const isMediaChannel2 = a0.isMediaChannel();
const isNSFW2 = a0.isNSFW();
type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return importDefault(dependencyMap[6]);
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[22]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[23]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[23]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[22]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[23]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[23]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[19]) : value.ignoreTraits ? a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]) : importDefault(dependencyMap[19]) : a0.linkedLobby != null ? importDefault(dependencyMap[25]) : importDefault(dependencyMap[7]);
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
if (isRulesChannel) {
r7 = importDefault(dependencyMap[21]);
} else if (isNSFW2) {
if (value == null) {
r7 = isMediaChannel2 ? dependencyMap[26] : dependencyMap[27];
r7 = importDefault(r7);
} else if (value.ignoreTraits) {
if (a0.isSpoilerChannel()) {
if (value == null) {
r9 = importDefault(dependencyMap[28]);
} else if (value.ignoreTraits) {
if (importDefault(dependencyMap[24])(a0)) {
if (value == null) {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
} else if (value.ignoreTraits) {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
} else {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
}
} else {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
}
r9 = r10;
} else {
r9 = importDefault(dependencyMap[28]);
}
} else {
if (importDefault(dependencyMap[24])(a0)) {
if (value == null) {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
} else if (value.ignoreTraits) {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
} else {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
}
} else {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
}
r9 = r10;
}
r7 = r9;
} else {
r7 = isMediaChannel2 ? dependencyMap[26] : dependencyMap[27];
r7 = importDefault(r7);
}
} else {
if (a0.isSpoilerChannel()) {
if (value == null) {
r9 = importDefault(dependencyMap[28]);
@@ -120,337 +190,300 @@ function getChannelIcon(a0, a1) { // fn#52589, source: /ci/build/discord/discord
r9 = r10;
}
r7 = r9;
} else {
r7 = isMediaChannel2 ? dependencyMap[26] : dependencyMap[27];
r7 = importDefault(r7);
}
} else {
if (a0.isSpoilerChannel()) {
if (value == null) {
r9 = importDefault(dependencyMap[28]);
} else if (value.ignoreTraits) {
if (importDefault(dependencyMap[24])(a0)) {
if (value == null) {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
} else if (value.ignoreTraits) {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
} else {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
}
} else {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
}
r9 = r10;
} else {
r9 = importDefault(dependencyMap[28]);
}
} else {
if (importDefault(dependencyMap[24])(a0)) {
if (value == null) {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
} else if (value.ignoreTraits) {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
} else {
r10 = isMediaChannel2 ? dependencyMap[29] : dependencyMap[30];
r10 = importDefault(r10);
}
} else {
r10 = importDefault(isMediaChannel2 ? dependencyMap[18] : dependencyMap[17]);
}
r9 = r10;
}
r7 = r9;
return r7;
}
return r7;
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[26]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[29]) : value.ignoreTraits ? importDefault(dependencyMap[18]) : importDefault(dependencyMap[29]) : importDefault(dependencyMap[18]) : importDefault(dependencyMap[26]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[29]) : value.ignoreTraits ? importDefault(dependencyMap[18]) : importDefault(dependencyMap[29]) : importDefault(dependencyMap[18]);
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return importDefault(dependencyMap[8]);
}
const DM = ChannelTypes.DM;
if (DM === type) {
return importDefault(dependencyMap[9]);
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[31]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[32]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[32]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[31]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[32]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[32]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]);
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return shouldShowMembershipVerificationGate2 ? value == null ? importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[15]) : value.ignoreTraits ? locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[15]) : locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]);
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return textFocused ? importDefault(dependencyMap[16]) : shouldShowMembershipVerificationGate2 ? value == null ? importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[14]) : value.ignoreTraits ? locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[14]) : locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefLine truncated
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return importDefault(dependencyMap[13]);
}
return null;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[26]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[29]) : value.ignoreTraits ? importDefault(dependencyMap[18]) : importDefault(dependencyMap[29]) : importDefault(dependencyMap[18]) : importDefault(dependencyMap[26]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[29]) : value.ignoreTraits ? importDefault(dependencyMap[18]) : importDefault(dependencyMap[29]) : importDefault(dependencyMap[18]);
function getChannelIconComponent(a0, a1) { // fn#52590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:2086, offset: 0x01331e16, size: 2198 bytes, params: 3, frame: 27
const VoiceLockIcon = (VoiceLockIconModule).VoiceLockIcon;
const LockIcon = (LockIconModule).LockIcon;
const VoiceWarningIcon = (VoiceWarningIconModule).VoiceWarningIcon;
const VoiceNormalSpoilerIcon = (VoiceNormalSpoilerIconModule).VoiceNormalSpoilerIcon;
const VoiceNormalIcon = (VoiceNormalIconModule).VoiceNormalIcon;
const StageLockIcon = (StageLockIconModule).StageLockIcon;
const StageIcon = (StageIconModule).StageIcon;
const AnnouncementsWarningIcon = (AnnouncementsWarningIconModule).AnnouncementsWarningIcon;
const AnnouncementsSpoilerIcon = (AnnouncementsSpoilerIconModule).AnnouncementsSpoilerIcon;
const AnnouncementsLockIcon = (AnnouncementsLockIconModule).AnnouncementsLockIcon;
const AnnouncementsIcon = (AnnouncementsIconModule).AnnouncementsIcon;
const BookCheckIcon = (BookCheckIconModule).BookCheckIcon;
const ImageWarningIcon = (ImageWarningIconModule).ImageWarningIcon;
const ImageLockIcon = (ImageLockIconModule).ImageLockIcon;
const ImageIcon = (ImageIconModule).ImageIcon;
const ForumWarningIcon = (ForumWarningIconModule).ForumWarningIcon;
const ForumSpoilerIcon = (ForumSpoilerIconModule).ForumSpoilerIcon;
const ForumLockIcon = (ForumLockIconModule).ForumLockIcon;
const ForumIcon = (ForumIconModule).ForumIcon;
const TextWarningIcon = (TextWarningIconModule).TextWarningIcon;
const TextSpoilerIcon = (TextSpoilerIconModule).TextSpoilerIcon;
const TextLockIcon = (TextLockIconModule).TextLockIcon;
const TextIcon = (TextIconModule).TextIcon;
const TextControllerIcon = (TextControllerIconModule).TextControllerIcon;
const value = a1;
const {isRulesChannel, textFocused, locked} = value ?? ({});
const shouldShowMembershipVerificationGate2 = UseShowMemberVerificationGateModule.shouldShowMembershipVerificationGate(a0.guild_id,
[GuildStore, UserStore, GuildMemberStore]);
if (a0.isForumPost()) {
return (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon;
}
const isMediaChannel2 = a0.isMediaChannel();
const isNSFW2 = a0.isNSFW();
const type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return (require(6683) /* metro dependency 6683: ThreadLockIcon */).ThreadLockIcon;
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return (require(6684) /* metro dependency 6684: ThreadIcon */).ThreadIcon;
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return (require(6684) /* metro dependency 6684: ThreadIcon */).ThreadIcon;
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return (require(6685) /* metro dependency 6685: FolderIcon */).FolderIcon;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? TextWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? TextSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextWarningIcon : a0.isSpoilerChannel() ? value == null ? TextSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? isMediaChannel2 ? ImageWarningIcon : ForumWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? ForumSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : ForumSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageWarningIcon : ForumWarningIcon : a0.isSpoilerChannel() ? value == null ? ForumSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : ForumSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? ImageWarningIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? ImageLockIcon : value.ignoreTraits ? ImageIcon : ImageLockIcon : ImageIcon : ImageWarningIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? ImageLockIcon : value.ignoreTraits ? ImageIcon : ImageLockIcon : ImageIcon;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return (require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return (require(6700) /* metro dependency 6700: AtIcon */).AtIcon;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? AnnouncementsWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? AnnouncementsSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsWarningIcon : a0.isSpoilerChannel() ? value == null ? AnnouncementsSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return shouldShowMembershipVerificationGate2 ? value == null ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : StageLockIcon : value.ignoreTraits ? locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : StageLockIcon : locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return textFocused ? (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon : shouldShowMembershipVerificationGate2 ? value == null ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : VoiceLockIcon : value.ignoreTraits ? locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : VoiceLockIcon : locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return (require(6712) /* metro dependency 6712: HubIcon */).HubIcon;
}
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return importDefault(dependencyMap[8]);
function getSimpleChannelIcon(a0) { // fn#52591, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:4530, offset: 0x013326ac, size: 441 bytes, params: 2, frame: 15
const getThreadChannelIconBinding = getThreadChannelIcon;
let type = a0.type;
const threadChannelIconBinding = getThreadChannelIconBinding(type);
if (threadChannelIconBinding != null) {
return threadChannelIconBinding;
}
type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return importDefault(6650) /* metro dependency 6650 */;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return importDefault(6652) /* metro dependency 6652 */;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return importDefault(6653) /* metro dependency 6653 */;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return importDefault(6654) /* metro dependency 6654 */;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return importDefault(6655) /* metro dependency 6655 */;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return importDefault(6656) /* metro dependency 6656 */;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return importDefault(6657) /* metro dependency 6657 */;
}
return null;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return importDefault(dependencyMap[9]);
function getChannelIconWithGuild(a0, a1) { // fn#52592, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5108, offset: 0x01332865, size: 56 bytes, params: 3, frame: 16
return getChannelIcon(a0, {isRulesChannel: a1?.rulesChannelId === a0.id});
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return isRulesChannel ? importDefault(dependencyMap[21]) : isNSFW2 ? value == null ? importDefault(dependencyMap[31]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[32]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[32]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[31]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[32]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]) : importDefault(dependencyMap[32]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[33]) : value.ignoreTraits ? importDefault(dependencyMap[10]) : importDefault(dependencyMap[33]) : importDefault(dependencyMap[10]);
function getChannelMentionIcon(a0) { // fn#52593, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5254, offset: 0x0133289d, size: 389 bytes, params: 2, frame: 11
if (a0 === 'voice') {
return importDefault(6656) /* metro dependency 6656 */;
}
if (a0 === 'voice-locked') {
return importDefault(6658) /* metro dependency 6658 */;
}
if (a0 === 'stage') {
return importDefault(6655) /* metro dependency 6655 */;
}
if (a0 === 'stage-locked') {
return importDefault(6659) /* metro dependency 6659 */;
}
if (a0 === 'text') {
return importDefault(6651) /* metro dependency 6651 */;
}
if (a0 === 'thread') {
return importDefault(6649) /* metro dependency 6649 */;
}
if (a0 === 'post') {
return importDefault(6660) /* metro dependency 6660 */;
}
if (a0 === 'message') {
return importDefault(6660) /* metro dependency 6660 */;
}
if (a0 === 'forum') {
return importDefault(6661) /* metro dependency 6661 */;
}
if (a0 === 'media') {
return importDefault(6662) /* metro dependency 6662 */;
}
if (a0 === 'locked') {
return importDefault(6663) /* metro dependency 6663 */;
}
return null;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return shouldShowMembershipVerificationGate2 ? value == null ? importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[15]) : value.ignoreTraits ? locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[15]) : locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[15]) : value.ignoreTraits ? importDefault(dependencyMap[11]) : importDefault(dependencyMap[15]) : importDefault(dependencyMap[11]);
function getChannelIconComponentWithGuild(a0, a1) { // fn#52594, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5693, offset: 0x01332a22, size: 56 bytes, params: 3, frame: 16
return getChannelIconComponent(a0, {isRulesChannel: a1?.rulesChannelId === a0.id});
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return textFocused ? importDefault(dependencyMap[16]) : shouldShowMembershipVerificationGate2 ? value == null ? importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[14]) : value.ignoreTraits ? locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[24])(a0) ? importDefault(dependencyMap[34]) : importDefault(dependencyMap[14]) : locked ? value == null ? importDefault(dependencyMap[34]) : value.ignoreTraits ? importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[34]) : importDefault(dependencyMap[24])(a0) ? value == null ? importDefault(dependencyMap[14]) : value.ignoreTraits ? isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[35]) : a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefault(dependencyMap[12]) : importDefault(dependencyMap[36]) : importDefault(dependencyMap[12]) : importDefault(dependencyMap[14]) : isNSFW2 ? value == null ? importDefault(dependencyMap[35]) : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? importDefault(dependencyMap[36]) : value.ignoreTraits ? importDefaultLine truncated
function getSimpleChannelIconComponent(a0) { // fn#52595, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5915, offset: 0x01332a5a, size: 592 bytes, params: 2, frame: 13
const ThreadIcon = (ThreadIconModule).ThreadIcon;
const ChatIcon = (ChatIconModule).ChatIcon;
const type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return (require(6685) /* metro dependency 6685: FolderIcon */).FolderIcon;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return (require(6691) /* metro dependency 6691: TextIcon */).TextIcon;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return (require(6698) /* metro dependency 6698: ForumIcon */).ForumIcon;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return (require(6697) /* metro dependency 6697: ImageIcon */).ImageIcon;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return (require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return (require(6700) /* metro dependency 6700: AtIcon */).AtIcon;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return (require(6704) /* metro dependency 6704: AnnouncementsIcon */).AnnouncementsIcon;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return (require(6707) /* metro dependency 6707: StageIcon */).StageIcon;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return (require(6711) /* metro dependency 6711: VoiceNormalIcon */).VoiceNormalIcon;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return (require(6712) /* metro dependency 6712: HubIcon */).HubIcon;
}
return null;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return importDefault(dependencyMap[13]);
}
return null;
}
function getChannelIconComponent(a0, a1) { // fn#52590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:2086, offset: 0x01331e16, size: 2198 bytes, params: 3, frame: 27
const VoiceLockIcon = (require(6708) /* metro dependency 6708: VoiceLockIcon */).VoiceLockIcon;
const LockIcon = (require(6705) /* metro dependency 6705: LockIcon */).LockIcon;
const VoiceWarningIcon = (require(6709) /* metro dependency 6709: VoiceWarningIcon */).VoiceWarningIcon;
const VoiceNormalSpoilerIcon = (require(6710) /* metro dependency 6710: VoiceNormalSpoilerIcon */).VoiceNormalSpoilerIcon;
const VoiceNormalIcon = (require(6711) /* metro dependency 6711: VoiceNormalIcon */).VoiceNormalIcon;
const StageLockIcon = (require(6706) /* metro dependency 6706: StageLockIcon */).StageLockIcon;
const StageIcon = (require(6707) /* metro dependency 6707: StageIcon */).StageIcon;
const AnnouncementsWarningIcon = (require(6701) /* metro dependency 6701: AnnouncementsWarningIcon */).AnnouncementsWarningIcon;
const AnnouncementsSpoilerIcon = (require(6702) /* metro dependency 6702: AnnouncementsSpoilerIcon */).AnnouncementsSpoilerIcon;
const AnnouncementsLockIcon = (require(6703) /* metro dependency 6703: AnnouncementsLockIcon */).AnnouncementsLockIcon;
const AnnouncementsIcon = (require(6704) /* metro dependency 6704: AnnouncementsIcon */).AnnouncementsIcon;
const BookCheckIcon = (require(6686) /* metro dependency 6686: BookCheckIcon */).BookCheckIcon;
const ImageWarningIcon = (require(6692) /* metro dependency 6692: ImageWarningIcon */).ImageWarningIcon;
const ImageLockIcon = (require(6695) /* metro dependency 6695: ImageLockIcon */).ImageLockIcon;
const ImageIcon = (require(6697) /* metro dependency 6697: ImageIcon */).ImageIcon;
const ForumWarningIcon = (require(6693) /* metro dependency 6693: ForumWarningIcon */).ForumWarningIcon;
const ForumSpoilerIcon = (require(6694) /* metro dependency 6694: ForumSpoilerIcon */).ForumSpoilerIcon;
const ForumLockIcon = (require(6696) /* metro dependency 6696: ForumLockIcon */).ForumLockIcon;
const ForumIcon = (require(6698) /* metro dependency 6698: ForumIcon */).ForumIcon;
const TextWarningIcon = (require(6687) /* metro dependency 6687: TextWarningIcon */).TextWarningIcon;
const TextSpoilerIcon = (require(6688) /* metro dependency 6688: TextSpoilerIcon */).TextSpoilerIcon;
const TextLockIcon = (require(6689) /* metro dependency 6689: TextLockIcon */).TextLockIcon;
const TextIcon = (require(6691) /* metro dependency 6691: TextIcon */).TextIcon;
const TextControllerIcon = (require(6690) /* metro dependency 6690: TextControllerIcon */).TextControllerIcon;
const value = a1;
const {isRulesChannel, textFocused, locked} = value ?? ({});
const useShowMemberVerificationGateModule = require(6664) /* metro dependency 6664: useShowMemberVerificationGate */;
const shouldShowMembershipVerificationGate2 = useShowMemberVerificationGateModule.shouldShowMembershipVerificationGate(a0.guild_id,
[GuildStore, UserStore, GuildMemberStore]);
if (a0.isForumPost()) {
return (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon;
}
const isMediaChannel2 = a0.isMediaChannel();
const isNSFW2 = a0.isNSFW();
const type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return (require(6683) /* metro dependency 6683: ThreadLockIcon */).ThreadLockIcon;
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return (require(6684) /* metro dependency 6684: ThreadIcon */).ThreadIcon;
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return (require(6684) /* metro dependency 6684: ThreadIcon */).ThreadIcon;
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return (require(6685) /* metro dependency 6685: FolderIcon */).FolderIcon;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? TextWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? TextSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextWarningIcon : a0.isSpoilerChannel() ? value == null ? TextSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? TextLockIcon : value.ignoreTraits ? a0.linkedLobby != null ? TextControllerIcon : TextIcon : TextLockIcon : a0.linkedLobby != null ? TextControllerIcon : TextIcon;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? isMediaChannel2 ? ImageWarningIcon : ForumWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? ForumSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : ForumSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageWarningIcon : ForumWarningIcon : a0.isSpoilerChannel() ? value == null ? ForumSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon : ForumSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? isMediaChannel2 ? ImageLockIcon : ForumLockIcon : value.ignoreTraits ? isMediaChannel2 ? ImageIcon : ForumIcon : isMediaChannel2 ? ImageLockIcon : ForumLockIcon : isMediaChannel2 ? ImageIcon : ForumIcon;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? ImageWarningIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? ImageLockIcon : value.ignoreTraits ? ImageIcon : ImageLockIcon : ImageIcon : ImageWarningIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? ImageLockIcon : value.ignoreTraits ? ImageIcon : ImageLockIcon : ImageIcon;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return (require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return (require(6700) /* metro dependency 6700: AtIcon */).AtIcon;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return isRulesChannel ? BookCheckIcon : isNSFW2 ? value == null ? AnnouncementsWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? AnnouncementsSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsWarningIcon : a0.isSpoilerChannel() ? value == null ? AnnouncementsSpoilerIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon : AnnouncementsSpoilerIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? AnnouncementsLockIcon : value.ignoreTraits ? AnnouncementsIcon : AnnouncementsLockIcon : AnnouncementsIcon;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return shouldShowMembershipVerificationGate2 ? value == null ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : StageLockIcon : value.ignoreTraits ? locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : StageLockIcon : locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? StageLockIcon : value.ignoreTraits ? StageIcon : StageLockIcon : StageIcon;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return textFocused ? (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon : shouldShowMembershipVerificationGate2 ? value == null ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : VoiceLockIcon : value.ignoreTraits ? locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? LockIcon : VoiceLockIcon : locked ? value == null ? LockIcon : value.ignoreTraits ? (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : LockIcon : (importDefault(5107) /* metro dependency 5107: isRoleRequired */)(a0) ? value == null ? VoiceLockIcon : value.ignoreTraits ? isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceLockIcon : isNSFW2 ? value == null ? VoiceWarningIcon : value.ignoreTraits ? a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon : VoiceWarningIcon : a0.isSpoilerChannel() ? value == null ? VoiceNormalSpoilerIcon : value.ignoreTraits ? VoiceNormalIcon : VoiceNormalSpoilerIcon : VoiceNormalIcon;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return (require(6712) /* metro dependency 6712: HubIcon */).HubIcon;
}
}
function getSimpleChannelIcon(a0) { // fn#52591, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:4530, offset: 0x013326ac, size: 441 bytes, params: 2, frame: 15
const getThreadChannelIconBinding = getThreadChannelIcon;
let type = a0.type;
const threadChannelIconBinding = getThreadChannelIconBinding(type);
if (threadChannelIconBinding != null) {
return threadChannelIconBinding;
}
type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return getThreadChannelIcon(a0.type);
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return importDefault(6650) /* metro dependency 6650 */;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return importDefault(6651) /* metro dependency 6651 */;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return importDefault(6652) /* metro dependency 6652 */;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return importDefault(6653) /* metro dependency 6653 */;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return importDefault(6654) /* metro dependency 6654 */;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return importDefault(6655) /* metro dependency 6655 */;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return importDefault(6656) /* metro dependency 6656 */;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return importDefault(6657) /* metro dependency 6657 */;
}
return null;
}
function getChannelIconWithGuild(a0, a1) { // fn#52592, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5108, offset: 0x01332865, size: 56 bytes, params: 3, frame: 16
return getChannelIcon(a0, {isRulesChannel: a1?.rulesChannelId === a0.id});
}
function getChannelMentionIcon(a0) { // fn#52593, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5254, offset: 0x0133289d, size: 389 bytes, params: 2, frame: 11
if (a0 === 'voice') {
return importDefault(6656) /* metro dependency 6656 */;
}
if (a0 === 'voice-locked') {
return importDefault(6658) /* metro dependency 6658 */;
}
if (a0 === 'stage') {
return importDefault(6655) /* metro dependency 6655 */;
}
if (a0 === 'stage-locked') {
return importDefault(6659) /* metro dependency 6659 */;
}
if (a0 === 'text') {
return importDefault(6651) /* metro dependency 6651 */;
}
if (a0 === 'thread') {
return importDefault(6649) /* metro dependency 6649 */;
}
if (a0 === 'post') {
return importDefault(6660) /* metro dependency 6660 */;
}
if (a0 === 'message') {
return importDefault(6660) /* metro dependency 6660 */;
}
if (a0 === 'forum') {
return importDefault(6661) /* metro dependency 6661 */;
}
if (a0 === 'media') {
return importDefault(6662) /* metro dependency 6662 */;
}
if (a0 === 'locked') {
return importDefault(6663) /* metro dependency 6663 */;
}
return null;
}
function getChannelIconComponentWithGuild(a0, a1) { // fn#52594, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5693, offset: 0x01332a22, size: 56 bytes, params: 3, frame: 16
return getChannelIconComponent(a0, {isRulesChannel: a1?.rulesChannelId === a0.id});
}
function getSimpleChannelIconComponent(a0) { // fn#52595, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6825:5915, offset: 0x01332a5a, size: 592 bytes, params: 2, frame: 13
const ThreadIcon = (require(6684) /* metro dependency 6684: ThreadIcon */).ThreadIcon;
const ChatIcon = (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon;
const type = a0.type;
const PRIVATE_THREAD = ChannelTypes.PRIVATE_THREAD;
if (PRIVATE_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const ANNOUNCEMENT_THREAD = ChannelTypes.ANNOUNCEMENT_THREAD;
if (ANNOUNCEMENT_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const PUBLIC_THREAD = ChannelTypes.PUBLIC_THREAD;
if (PUBLIC_THREAD === type) {
return a0.isForumPost() ? ChatIcon : ThreadIcon;
}
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
return (require(6685) /* metro dependency 6685: FolderIcon */).FolderIcon;
}
const GUILD_TEXT = ChannelTypes.GUILD_TEXT;
if (GUILD_TEXT === type) {
return (require(6691) /* metro dependency 6691: TextIcon */).TextIcon;
}
const GUILD_FORUM = ChannelTypes.GUILD_FORUM;
if (GUILD_FORUM === type) {
return (require(6698) /* metro dependency 6698: ForumIcon */).ForumIcon;
}
const GUILD_MEDIA = ChannelTypes.GUILD_MEDIA;
if (GUILD_MEDIA === type) {
return (require(6697) /* metro dependency 6697: ImageIcon */).ImageIcon;
}
const GROUP_DM = ChannelTypes.GROUP_DM;
if (GROUP_DM === type) {
return (require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon;
}
const DM = ChannelTypes.DM;
if (DM === type) {
return (require(6700) /* metro dependency 6700: AtIcon */).AtIcon;
}
const GUILD_ANNOUNCEMENT = ChannelTypes.GUILD_ANNOUNCEMENT;
if (GUILD_ANNOUNCEMENT === type) {
return (require(6704) /* metro dependency 6704: AnnouncementsIcon */).AnnouncementsIcon;
}
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
if (GUILD_STAGE_VOICE === type) {
return (require(6707) /* metro dependency 6707: StageIcon */).StageIcon;
}
const GUILD_VOICE = ChannelTypes.GUILD_VOICE;
if (GUILD_VOICE === type) {
return (require(6711) /* metro dependency 6711: VoiceNormalIcon */).VoiceNormalIcon;
}
const GUILD_DIRECTORY = ChannelTypes.GUILD_DIRECTORY;
if (GUILD_DIRECTORY === type) {
return (require(6712) /* metro dependency 6712: HubIcon */).HubIcon;
}
return null;
}
global.__d(_fun52587, 6647, [1945, 1867, 1878, 661, 6648, 6649, 6650, 6651, 6652, 6653, 6654, 6655, 6656, 6657,
6658, 6659, 6660, 6661, 6662, 6663, 6664, 6667, 6668, 6669, 5107, 6670, 6671, 6672, 6673, 6674, 6675, 6676,
6677, 6678, 6679, 6680, 6681, 6682, 6683, 6684, 6685, 6686, 6687, 6688, 6689, 6690, 6691, 6692, 6693, 6694,
6695, 6696, 6697, 6698, 6699, 6700, 6701, 6702, 6703, 6704, 6705, 6706, 6707, 6708, 6709, 6710, 6711, 6712,
2]) /* metro module 6647, dependencies: [1945, 1867, 1878, 661, 6648, 6649, 6650, 6651, 6652, 6653, 6654, 6655, 6656, 6657, 6658, 6659, 6660, 6661, 6662, 6663, 6664, 6667, 6668, 6669, 5107, 6670, 6671, 6672, 6673, 6674, 6675, 6676, 6677, 6678, 6679, 6680, 6681, 6682, 6683, 6684, 6685, 6686, 6687, 6688, 6689, 6690, 6691, 6692, 6693, 6694, 6695, 6696, 6697, 6698, 6699, 6700, 6701, 6702, 6703, 6704, 6705, 6706, 6707, 6708, 6709, 6710, 6711, 6712, 2] */;
+176 -168
View File
@@ -1,15 +1,21 @@
/* Metro module 4015; source: utils/native/ChatInputUtils.tsx; dependencies: [4016, 1848, 4022, 1583, 1482, 4023, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as KeyboardTypesModule from '../../modules/keyboard/native/KeyboardTypes.tsx'; /* Metro dependency 1583 */
import * as KeyboardManagerUtilsModule from './KeyboardManagerUtils.tsx'; /* Metro dependency 1848 */
import * as UseKeyboardTypeModule from '../../modules/keyboard/native/useKeyboardType.tsx'; /* Metro dependency 4022 */
import * as PortalKeyboardUIStoreNativeModule from '../../modules/keyboard/native/PortalKeyboardUIStore.native.tsx'; /* Metro dependency 4023 */
function _fun33058(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#33058, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:6, offset: 0x01026bbc, size: 226 bytes, params: 8, frame: 21
let env0_0 = require;
const closure = getHighestActiveScreenIndex;
const closure2 = getBestActiveInput;
const getHighestActiveScreenIndex2 = getHighestActiveScreenIndex;
const getBestActiveInput2 = getBestActiveInput;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let Map = global.Map;
let map = new Map();
Map = global.Map;
map = new Map();
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ChatInputUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/ChatInputUtils.tsx');
exports.createInputRefTracker = function(a0, a1) {
var env0_0 = a1;
var env0_3 = _fun33064;
@@ -18,190 +24,192 @@ function _fun33058(global, require, importDefault, importAll, module, exports, d
var env0_2 = {current: a0};
return {handleRef: _fun33066, register: _fun33067, unregister: _fun33068};
};
exports.getHighestActiveScreenIndex = closure;
exports.getHighestActiveScreenIndex = getHighestActiveScreenIndex2;
exports.getChatInputRef = getChatInputRef;
exports.getBestActiveInputForChannelId = getBestActiveInputForChannelId;
exports.getBestActiveInput = closure2;
exports.getBestActiveInput = getBestActiveInput2;
exports.dismissKeyboard = dismissKeyboard_33071;
}
function getHighestActiveScreenIndex() { // fn#33059, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:116, offset: 0x01026c9e, size: 190 bytes, params: 1, frame: 20
var Math;
var max;
var items2;
let value = a0;
const r9 = value !== undefined ? value : env0_3;
if (r9.size !== 0) {
var has = r9.has;
if (Reflect.apply(has, r9, ['voice-panel'])) {
return 'voice-panel';
}
has = r9.has;
if (Reflect.apply(has, r9, ['message-request'])) {
return 'message-request';
}
has = r9.has;
if (Reflect.apply(has, r9, ['new-message'])) {
return 'new-message';
}
var Array = global.Array;
value = Array.from(r9.keys());
value = value.filter(_fun33060);
if (value.length !== 0) {
Math = global.Math;
max = Math.max;
items2 = [];
arraySpread(items2, value, 0, r9);
return apply(max, items2, Math, r9);
}
}
function _fun33060(a0) { // fn#33060, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:348, offset: 0x01026d5c, size: 57 bytes, params: 2, frame: 13
var r0;
let value = typeof a0 === 'number';
if (value) {
value = environment.__proto__;
value = require(4016) /* metro dependency 4016: ScreenIndexFrozen */;
value = !value.isScreenIndexFrozen(a0);
r0 = value;
} else {
r0 = value;
}
return r0;
}
function getHighestActiveScreenIndex() { // fn#33059, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:116, offset: 0x01026c9e, size: 190 bytes, params: 1, frame: 20
var Math;
var max;
var items2;
let value = a0;
const r9 = value !== undefined ? value : env0_3;
if (r9.size !== 0) {
var has = r9.has;
if (Reflect.apply(has, r9, ['voice-panel'])) {
return 'voice-panel';
}
has = r9.has;
if (Reflect.apply(has, r9, ['message-request'])) {
return 'message-request';
}
has = r9.has;
if (Reflect.apply(has, r9, ['new-message'])) {
return 'new-message';
}
var Array = global.Array;
value = Array.from(r9.keys());
value = value.filter(_fun33060);
if (value.length !== 0) {
Math = global.Math;
max = Math.max;
items2 = [];
arraySpread(items2, value, 0, r9);
return apply(max, items2, Math, r9);
}
function getHighestIndexForScreenIndexMap(a0) { // fn#33061, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:444, offset: 0x01026d95, size: 37 bytes, params: 2, frame: 12
const highestActiveScreenIndex = getHighestActiveScreenIndex(a0);
if (highestActiveScreenIndex != null) {
return a0.get(highestActiveScreenIndex);
}
}
}
function getHighestIndexForScreenIndexMap(a0) { // fn#33061, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:444, offset: 0x01026d95, size: 37 bytes, params: 2, frame: 12
const highestActiveScreenIndex = getHighestActiveScreenIndex(a0);
if (highestActiveScreenIndex != null) {
return a0.get(highestActiveScreenIndex);
function getBestActiveInput() { // fn#33062, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:553, offset: 0x01026dba, size: 48 bytes, params: 1, frame: 13
const getHighestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMap;
const value = undefined;
const highestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMapBinding(env0_3);
return (highestIndexForScreenIndexMapBinding == null ? value : highestIndexForScreenIndexMapBinding.current) ?? value;
}
}
function getBestActiveInput() { // fn#33062, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:553, offset: 0x01026dba, size: 48 bytes, params: 1, frame: 13
const getHighestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMap;
const value = undefined;
const highestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMapBinding(env0_3);
return (highestIndexForScreenIndexMapBinding == null ? value : highestIndexForScreenIndexMapBinding.current) ?? value;
}
function createInputRefTracker(a0, a1) { // fn#33063, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:769, offset: 0x01026dea, size: 80 bytes, params: 3, frame: 3
const env0_0 = a1;
const object = {current: a0};
return {handleRef: handleRef, register: register_33067, unregister: unregister_33068};
}
function getChatInputRef(a0, a1) { // fn#33069, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1426, offset: 0x01026ffa, size: 80 bytes, params: 3, frame: 14
var current;
var value;
var value2;
if (a0 != null) {
value = env0_2.get(a0);
value2 = undefined;
if (value == null) {
current = value2;
} else {
value = value.get(a1);
current = value == null ? value2 : value.current;
function createInputRefTracker(a0, a1) { // fn#33063, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:769, offset: 0x01026dea, size: 80 bytes, params: 3, frame: 3
const env0_0 = a1;
const object = {current: a0};
return {handleRef: handleRef, register: register_33067, unregister: unregister_33068};
function addRef(a0, a1, a2) { // fn#33064, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:830, owner: createInputRefTracker.addRef, offset: 0x01026e3a, size: 149 bytes, params: 4, frame: 16
var r5;
var map;
const value2 = env1_2.get(a1);
if (value2 != null) {
r5 = value2;
} else {
map = new global.Map();
}
r5.set(a2, a0);
env1_2.set(a1, r5);
env1_3.set(a2, a0);
const DEVELOPMENT = global.process.env.DEVELOPMENT;
if (DEVELOPMENT === 'development') {
env1_3.has(a2);
}
}
return current ?? value2;
}
}
function getBestActiveInputForChannelId(a0) { // fn#33070, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1591, offset: 0x0102704a, size: 73 bytes, params: 2, frame: 13
var getHighestIndexForScreenIndexMapBinding;
var highestIndexForScreenIndexMapBinding;
if (a0 != null) {
function removeRef(a0, a1, a2) { // fn#33065, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:973, owner: createInputRefTracker.removeRef, offset: 0x01026ecf, size: 82 bytes, params: 4, frame: 13
const value2 = env1_2.get(a1);
if (value2 != null) {
value2.delete(a2);
if (value2.size === 0) {
env1_2.delete(a1);
}
env1_3.delete(a2);
}
}
function handleRef(a0, a1) { // fn#33066, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1090, owner: createInputRefTracker.handleRef, offset: 0x01026f21, size: 111 bytes, params: 3, frame: 17
env0_2.current = a1;
if (a0 == null) {
if (env0_1 == null) {
return undefined;
}
removeRef(undefined, a1, require);
} else if (env0_1 == null) {
addRef({current: a0}, a1, require);
} else {
env0_1.current = a0;
}
}
function createInputRefTrackerRegister() { // fn#33067, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1233, owner: createInputRefTracker.register, offset: 0x01026f90, size: 63 bytes, params: 1, frame: 16
var removeRefBinding;
var binding;
var current;
var addRefBinding;
var binding2;
if (env0_1 != null) {
removeRefBinding = removeRef;
binding = env0_2;
current = binding.current;
removeRefBinding(undefined, current, require);
addRefBinding = addRef;
binding2 = env0_1;
current = binding.current;
addRefBinding(binding2, current, require);
}
}
function createInputRefTrackerUnregister() { // fn#33068, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1308, owner: createInputRefTracker.unregister, offset: 0x01026fcf, size: 43 bytes, params: 1, frame: 14
if (env0_1 != null) {
removeRef(undefined, env0_2.current, require);
}
}
}
function getChatInputRef(a0, a1) { // fn#33069, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1426, offset: 0x01026ffa, size: 80 bytes, params: 3, frame: 14
var current;
var value;
var value2 = env0_2.get(a0);
if (value2 != null) {
getHighestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMap;
value = undefined;
highestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMapBinding(value2);
return (highestIndexForScreenIndexMapBinding == null ? value : highestIndexForScreenIndexMapBinding.current) ?? value;
var value2;
if (a0 != null) {
value = env0_2.get(a0);
value2 = undefined;
if (value == null) {
current = value2;
} else {
value = value.get(a1);
current = value == null ? value2 : value.current;
}
return current ?? value2;
}
}
}
function dismissKeyboard_33071() { // fn#33071, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1829, offset: 0x01027093, size: 207 bytes, params: 1, frame: 16
(require(1848) /* metro dependency 1848: KeyboardManagerUtils */).dismissGlobalKeyboard();
const bestActiveInput = getBestActiveInput();
if (bestActiveInput != null) {
bestActiveInput.closeCustomKeyboard();
}
const keyboardType = (require(4022) /* metro dependency 4022: useKeyboardType */).getKeyboardType();
const KeyboardTypes = (require(1583) /* metro dependency 1583: KeyboardTypes */).KeyboardTypes;
const SYSTEM = KeyboardTypes.SYSTEM;
if (keyboardType !== SYSTEM) {
(require(1482) /* metro dependency 1482: KeyboardUIStoreNative */).setKeyboardType({type: KeyboardTypes.SYSTEM});
}
(require(4023) /* metro dependency 4023: PortalKeyboardUIStoreNative */).closePortalKeyboardRequest();
}
function _fun33060(a0) { // fn#33060, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:348, offset: 0x01026d5c, size: 57 bytes, params: 2, frame: 13
var r0;
let value = typeof a0 === 'number';
if (value) {
value = environment.__proto__;
value = require(4016) /* metro dependency 4016: ScreenIndexFrozen */;
value = !value.isScreenIndexFrozen(a0);
r0 = value;
} else {
r0 = value;
}
return r0;
}
function addRef(a0, a1, a2) { // fn#33064, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:830, owner: createInputRefTracker.addRef, offset: 0x01026e3a, size: 149 bytes, params: 4, frame: 16
var r5;
var map;
const value2 = env1_2.get(a1);
if (value2 != null) {
r5 = value2;
} else {
map = new global.Map();
}
r5.set(a2, a0);
env1_2.set(a1, r5);
env1_3.set(a2, a0);
const DEVELOPMENT = global.process.env.DEVELOPMENT;
if (DEVELOPMENT === 'development') {
env1_3.has(a2);
}
}
function removeRef(a0, a1, a2) { // fn#33065, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:973, owner: createInputRefTracker.removeRef, offset: 0x01026ecf, size: 82 bytes, params: 4, frame: 13
const value2 = env1_2.get(a1);
if (value2 != null) {
value2.delete(a2);
if (value2.size === 0) {
env1_2.delete(a1);
function getBestActiveInputForChannelId(a0) { // fn#33070, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1591, offset: 0x0102704a, size: 73 bytes, params: 2, frame: 13
var getHighestIndexForScreenIndexMapBinding;
var highestIndexForScreenIndexMapBinding;
if (a0 != null) {
var value;
var value2 = env0_2.get(a0);
if (value2 != null) {
getHighestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMap;
value = undefined;
highestIndexForScreenIndexMapBinding = getHighestIndexForScreenIndexMapBinding(value2);
return (highestIndexForScreenIndexMapBinding == null ? value : highestIndexForScreenIndexMapBinding.current) ?? value;
}
}
env1_3.delete(a2);
}
}
function handleRef(a0, a1) { // fn#33066, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1090, owner: createInputRefTracker.handleRef, offset: 0x01026f21, size: 111 bytes, params: 3, frame: 17
env0_2.current = a1;
if (a0 == null) {
if (env0_1 == null) {
return undefined;
function dismissKeyboard_33071() { // fn#33071, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1829, offset: 0x01027093, size: 207 bytes, params: 1, frame: 16
(KeyboardManagerUtilsModule).dismissGlobalKeyboard();
const bestActiveInput = getBestActiveInput();
if (bestActiveInput != null) {
bestActiveInput.closeCustomKeyboard();
}
removeRef(undefined, a1, require);
} else if (env0_1 == null) {
addRef({current: a0}, a1, require);
} else {
env0_1.current = a0;
}
}
function createInputRefTrackerRegister() { // fn#33067, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1233, owner: createInputRefTracker.register, offset: 0x01026f90, size: 63 bytes, params: 1, frame: 16
var removeRefBinding;
var binding;
var current;
var addRefBinding;
var binding2;
if (env0_1 != null) {
removeRefBinding = removeRef;
binding = env0_2;
current = binding.current;
removeRefBinding(undefined, current, require);
addRefBinding = addRef;
binding2 = env0_1;
current = binding.current;
addRefBinding(binding2, current, require);
}
}
function createInputRefTrackerUnregister() { // fn#33068, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4173:1308, owner: createInputRefTracker.unregister, offset: 0x01026fcf, size: 43 bytes, params: 1, frame: 14
if (env0_1 != null) {
removeRef(undefined, env0_2.current, require);
const keyboardType = (UseKeyboardTypeModule).getKeyboardType();
const KeyboardTypes = (KeyboardTypesModule).KeyboardTypes;
const SYSTEM = KeyboardTypes.SYSTEM;
if (keyboardType !== SYSTEM) {
(require(1482) /* metro dependency 1482: KeyboardUIStoreNative */).setKeyboardType({type: KeyboardTypes.SYSTEM});
}
(PortalKeyboardUIStoreNativeModule).closePortalKeyboardRequest();
}
}
global.__d(_fun33058, 4015, [4016, 1848, 4022, 1583, 1482, 4023,
2]) /* metro module 4015, dependencies: [4016, 1848, 4022, 1583, 1482, 4023, 2] */;
+15 -12
View File
@@ -1,26 +1,29 @@
/* Metro module 1582; source: utils/native/ClientInfoUtils.tsx; dependencies: [27, 477, 657, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as PlatformUtilsModule from '../PlatformUtils.tsx'; /* Metro dependency 477 */
function _fun17598(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#17598, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1709:6, offset: 0x00e70e30, size: 133 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = (require(27) /* metro dependency 27 */).NativeModules;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ClientInfoUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/ClientInfoUtils.tsx');
exports.getConstants = getConstants_17599;
exports.getBuildNumberLabel = function() {
var value = '5867';
return ['0', '123456', '1234567890'].includes(value) ? 'dev (' + value + ')' : value;
};
}
function getConstants_17599() { // fn#17599, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1709:201, offset: 0x00e70eb5, size: 151 bytes, params: 1, frame: 13
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isAndroid()) {
if ((importDefault(657) /* metro dependency 657: NativeClientInfoModule */) === null) {
throw new global.Error('Turbo module RTNClientInfoManager is undefined for Android');
function getConstants_17599() { // fn#17599, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1709:201, offset: 0x00e70eb5, size: 151 bytes, params: 1, frame: 13
if (PlatformUtilsModule.isAndroid()) {
if ((importDefault(657) /* metro dependency 657: NativeClientInfoModule */) === null) {
throw new global.Error('Turbo module RTNClientInfoManager is undefined for Android');
}
return (importDefault(657) /* metro dependency 657: NativeClientInfoModule */).getConstants();
}
return (importDefault(657) /* metro dependency 657: NativeClientInfoModule */).getConstants();
const InfoDictionaryManager = NativeModules.InfoDictionaryManager;
return InfoDictionaryManager.getConstants();
}
const InfoDictionaryManager = NativeModules.InfoDictionaryManager;
return InfoDictionaryManager.getConstants();
}
global.__d(_fun17598, 1582, [27, 477, 657, 2]) /* metro module 1582, dependencies: [27, 477, 657, 2] */;
+114 -109
View File
@@ -1,29 +1,33 @@
/* Metro module 4092; source: utils/native/DeviceUtils.tsx; dependencies: [27, 477, 656, 587, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as PlatformUtilsModule from '../PlatformUtils.tsx'; /* Metro dependency 477 */
import * as StorageModule from '../../external/discord_common/js/packages/storage/Storage.tsx'; /* Metro dependency 587 */
function _fun33520(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#33520, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:6, offset: 0x01031798, size: 411 bytes, params: 8, frame: 22
var DCDDeviceManager;
var value5;
const env0_0 = require;
const closure = getSystemVersion;
const closure2 = getDevice_33522;
const getSystemVersion2 = getSystemVersion;
const getDevice_335222 = getDevice_33522;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const value = undefined;
const NativeModules = (require(27) /* metro dependency 27 */).NativeModules;
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isAndroid()) {
const NativeModules = (ReactNativeModule).NativeModules;
if (PlatformUtilsModule.isAndroid()) {
if ((importDefault(656) /* metro dependency 656: NativeDeviceModule */) != null) {
value5 = (importDefault(656) /* metro dependency 656: NativeDeviceModule */).getConstants();
}
} else {
DCDDeviceManager = NativeModules.DCDDeviceManager;
}
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/DeviceUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/DeviceUtils.tsx');
exports.isIpadOS = isIpadOS;
exports.isGestureNavigationEnabled = isGestureNavigationEnabled;
exports.getSystemVersion = closure;
exports.getSystemVersion = getSystemVersion2;
exports.getSystemVersionMajor = getSystemVersionMajor;
exports.getSystemVersionMinor = getSystemVersionMinor;
exports.getDevice = closure2;
exports.getDevice = getDevice_335222;
exports.getDeviceInfo = getDeviceInfo;
exports.getDeviceMediaPerformanceClass = getDeviceMediaPerformanceClass;
exports.getDeviceModel = getDeviceModel;
@@ -37,125 +41,126 @@ function _fun33520(global, require, importDefault, importAll, module, exports, d
exports.getTimeZone = getTimeZone;
exports.getIsRunningOnSimulator = getIsRunningOnSimulator;
return value;
}
function getSystemVersion() { // fn#33521, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:205, offset: 0x01031933, size: 15 bytes, params: 1, frame: 1
return env0_3.systemVersion;
}
function getDevice_33522() { // fn#33522, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:256, offset: 0x01031942, size: 15 bytes, params: 1, frame: 1
return env0_3.device;
}
function isIpadOS() { // fn#33523, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:403, offset: 0x01031951, size: 23 bytes, params: 1, frame: 2
return env0_3.deviceModel === 'iPad';
}
function isGestureNavigationEnabled() { // fn#33524, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:482, offset: 0x01031968, size: 15 bytes, params: 1, frame: 1
return env0_3.isGestureNavigationEnabled;
}
function getSystemVersionMajor() { // fn#33525, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:617, offset: 0x01031977, size: 102 bytes, params: 1, frame: 15
let value = getSystemVersion();
value = value.match(RegExp('\\d+', ''));
if (value == null) {
return 0;
function getSystemVersion() { // fn#33521, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:205, offset: 0x01031933, size: 15 bytes, params: 1, frame: 1
return env0_3.systemVersion;
}
let Number = global.Number;
const value2 = 0;
value = Number.parseInt(value[value2], 10);
Number = global.Number;
return Number.isNaN(value) ? value2 : value;
}
function getSystemVersionMinor() { // fn#33526, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:791, offset: 0x010319dd, size: 117 bytes, params: 1, frame: 14
let value = getSystemVersion();
value = value.match(RegExp('\\d+', 'g'));
if (value == null) {
return 0;
function getDevice_33522() { // fn#33522, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:256, offset: 0x01031942, size: 15 bytes, params: 1, frame: 1
return env0_3.device;
}
if (value.length < 2) {
return 0;
function isIpadOS() { // fn#33523, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:403, offset: 0x01031951, size: 23 bytes, params: 1, frame: 2
return env0_3.deviceModel === 'iPad';
}
let Number = global.Number;
value = Number.parseInt(value[1], 10);
Number = global.Number;
return Number.isNaN(value) ? 0 : value;
}
function getDeviceInfo() { // fn#33527, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:992, offset: 0x01031a52, size: 87 bytes, params: 1, frame: 12
const isAndroid2 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid();
const device_33522 = getDevice_33522();
return isAndroid2 ? device_33522 + ' (' + env0_3.deviceModel + ')' : device_33522;
}
function isGestureNavigationEnabled() { // fn#33524, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:482, offset: 0x01031968, size: 15 bytes, params: 1, frame: 1
return env0_3.isGestureNavigationEnabled;
}
function getDeviceMediaPerformanceClass() { // fn#33528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1125, offset: 0x01031aa9, size: 190 bytes, params: 1, frame: 17
var r2;
var r0;
var value3;
const Storage = (require(587) /* metro dependency 587: Storage */).Storage;
var value4;
const isAndroid2 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid();
const value2 = null;
if (isAndroid2) {
value3 = value2 == env0_4;
if (value3) {
value4 = Storage.get(env0_5);
env0_4 = value4;
r2 = value2 == value4;
function getSystemVersionMajor() { // fn#33525, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:617, offset: 0x01031977, size: 102 bytes, params: 1, frame: 15
let value = getSystemVersion();
value = value.match(RegExp('\\d+', ''));
if (value == null) {
return 0;
}
let Number = global.Number;
const value2 = 0;
value = Number.parseInt(value[value2], 10);
Number = global.Number;
return Number.isNaN(value) ? value2 : value;
}
function getSystemVersionMinor() { // fn#33526, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:791, offset: 0x010319dd, size: 117 bytes, params: 1, frame: 14
let value = getSystemVersion();
value = value.match(RegExp('\\d+', 'g'));
if (value == null) {
return 0;
}
if (value.length < 2) {
return 0;
}
let Number = global.Number;
value = Number.parseInt(value[1], 10);
Number = global.Number;
return Number.isNaN(value) ? 0 : value;
}
function getDeviceInfo() { // fn#33527, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:992, offset: 0x01031a52, size: 87 bytes, params: 1, frame: 12
const isAndroid2 = (PlatformUtilsModule).isAndroid();
const device_33522 = getDevice_33522();
return isAndroid2 ? device_33522 + ' (' + env0_3.deviceModel + ')' : device_33522;
}
function getDeviceMediaPerformanceClass() { // fn#33528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1125, offset: 0x01031aa9, size: 190 bytes, params: 1, frame: 17
var r2;
var r0;
var value3;
const Storage = (StorageModule).Storage;
var value4;
const isAndroid2 = (PlatformUtilsModule).isAndroid();
const value2 = null;
if (isAndroid2) {
value3 = value2 == env0_4;
if (value3) {
value4 = Storage.get(env0_5);
env0_4 = value4;
r2 = value2 == value4;
} else {
r2 = value3;
}
if (r2) {
env0_4 = (importDefault(656) /* metro dependency 656: NativeDeviceModule */).getMediaPerformanceClass();
Storage.set(env0_5, env0_4);
}
r0 = env0_4;
} else {
r2 = value3;
r0 = value2;
}
if (r2) {
env0_4 = (importDefault(656) /* metro dependency 656: NativeDeviceModule */).getMediaPerformanceClass();
Storage.set(env0_5, env0_4);
}
r0 = env0_4;
} else {
r0 = value2;
return r0;
}
return r0;
}
function getDeviceModel() { // fn#33529, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1328, offset: 0x01031b67, size: 15 bytes, params: 1, frame: 1
return env0_3.deviceModel;
}
function getDeviceModel() { // fn#33529, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1328, offset: 0x01031b67, size: 15 bytes, params: 1, frame: 1
return env0_3.deviceModel;
}
function getDeviceBrand() { // fn#33530, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1393, offset: 0x01031b76, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceBrand;
}
function getDeviceBrand() { // fn#33530, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1393, offset: 0x01031b76, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceBrand;
}
function getDeviceProduct() { // fn#33531, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1460, offset: 0x01031b87, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceProduct;
}
function getDeviceProduct() { // fn#33531, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1460, offset: 0x01031b87, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceProduct;
}
function getDeviceManufacturer() { // fn#33532, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1536, offset: 0x01031b98, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceManufacturer;
}
function getDeviceManufacturer() { // fn#33532, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1536, offset: 0x01031b98, size: 17 bytes, params: 1, frame: 1
return env0_3.deviceManufacturer;
}
function getSmallestScreenWidth() { // fn#33533, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1623, offset: 0x01031ba9, size: 17 bytes, params: 1, frame: 1
return env0_3.smallestScreenWidth;
}
function getSmallestScreenWidth() { // fn#33533, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1623, offset: 0x01031ba9, size: 17 bytes, params: 1, frame: 1
return env0_3.smallestScreenWidth;
}
function getSocName() { // fn#33534, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1700, offset: 0x01031bba, size: 17 bytes, params: 1, frame: 1
return env0_3.socName;
}
function getSocName() { // fn#33534, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1700, offset: 0x01031bba, size: 17 bytes, params: 1, frame: 1
return env0_3.socName;
}
function getRamSize() { // fn#33535, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1753, offset: 0x01031bcb, size: 42 bytes, params: 1, frame: 12
const ramSize = env0_3.ramSize;
return ramSize === '' ? undefined : global.parseFloat(ramSize);
}
function getRamSize() { // fn#33535, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1753, offset: 0x01031bcb, size: 42 bytes, params: 1, frame: 12
const ramSize = env0_3.ramSize;
return ramSize === '' ? undefined : global.parseFloat(ramSize);
}
function getMaxCpuFreq() { // fn#33536, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1842, offset: 0x01031bf5, size: 42 bytes, params: 1, frame: 12
const maxCpuFreq = env0_3.maxCpuFreq;
return maxCpuFreq === '' ? undefined : global.parseFloat(maxCpuFreq);
}
function getMaxCpuFreq() { // fn#33536, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1842, offset: 0x01031bf5, size: 42 bytes, params: 1, frame: 12
const maxCpuFreq = env0_3.maxCpuFreq;
return maxCpuFreq === '' ? undefined : global.parseFloat(maxCpuFreq);
}
function getTimeZone() { // fn#33537, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1935, offset: 0x01031c1f, size: 15 bytes, params: 1, frame: 1
return env0_3.timeZone;
}
function getTimeZone() { // fn#33537, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:1935, offset: 0x01031c1f, size: 15 bytes, params: 1, frame: 1
return env0_3.timeZone;
}
function getIsRunningOnSimulator() { // fn#33538, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:2003, offset: 0x01031c2e, size: 17 bytes, params: 1, frame: 1
return env0_3.isRunningOnSimulator;
}
function getIsRunningOnSimulator() { // fn#33538, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4250:2003, offset: 0x01031c2e, size: 17 bytes, params: 1, frame: 1
return env0_3.isRunningOnSimulator;
}
global.__d(_fun33520, 4092, [27, 477, 656, 587, 2]) /* metro module 4092, dependencies: [27, 477, 656, 587, 2] */;
+20 -17
View File
@@ -1,30 +1,33 @@
/* Metro module 4020; source: utils/native/FabricUtils.tsx; dependencies: [4021, 477, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun33087(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#33087, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4178:6, offset: 0x010275fa, size: 135 bytes, params: 8, frame: 20
const env0_0 = require;
const closure = isFabric_33088;
const isFabric_330882 = isFabric_33088;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const RN$Bridgeless = global.RN$Bridgeless;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/FabricUtils.tsx');
exports.isFabric = closure;
(FileImportTrackerModule).fileFinishedImporting('utils/native/FabricUtils.tsx');
exports.isFabric = isFabric_330882;
exports.isIosFabric = isIosFabric;
exports.isBridgeless = RN$Bridgeless === true;
}
function isFabric_33088() { // fn#33088, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4178:43, offset: 0x01027681, size: 74 bytes, params: 1, frame: 14
var r1;
var value;
if ((importDefault(4021) /* metro dependency 4021: NativeArchitectureProvider */) == null) {
r1 = undefined;
} else {
value = importDefault(4021) /* metro dependency 4021: NativeArchitectureProvider */;
value = value.isFabric();
r1 = value;
}
return r1 != null && r1;
}
function isFabric_33088() { // fn#33088, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4178:43, offset: 0x01027681, size: 74 bytes, params: 1, frame: 14
var r1;
var value;
if ((importDefault(4021) /* metro dependency 4021: NativeArchitectureProvider */) == null) {
r1 = undefined;
} else {
value = importDefault(4021) /* metro dependency 4021: NativeArchitectureProvider */;
value = value.isFabric();
r1 = value;
function isIosFabric() { // fn#33089, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4178:301, offset: 0x010276cb, size: 48 bytes, params: 1, frame: 12
return (require(477) /* metro dependency 477: PlatformUtils */).isIOS() && isFabric_33088();
}
return r1 != null && r1;
}
function isIosFabric() { // fn#33089, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4178:301, offset: 0x010276cb, size: 48 bytes, params: 1, frame: 12
return (require(477) /* metro dependency 477: PlatformUtils */).isIOS() && isFabric_33088();
}
global.__d(_fun33087, 4020, [4021, 477, 2]) /* metro module 4020, dependencies: [4021, 477, 2] */;
File diff suppressed because it is too large. Load diff
+4 -1
View File
@@ -1,9 +1,11 @@
/* Metro module 7358; source: utils/native/IAPUtils.mock.tsx; dependencies: [7359, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun59307(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#59307, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7536:6, offset: 0x016e5213, size: 141 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/IAPUtils.mock.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/IAPUtils.mock.tsx');
exports.default = {loadProducts: function() {
var Promise = global.Promise;
return Promise.resolve(require(dependencyMap[0]).copiedIAPProducts);
@@ -23,3 +25,4 @@ function _fun59307(global, require, importDefault, importAll, module, exports, d
}};
}
global.__d(_fun59307, 7358, [7359, 2]) /* metro module 7358, dependencies: [7359, 2] */;
File diff suppressed because it is too large. Load diff
+83 -78
View File
@@ -1,13 +1,18 @@
/* Metro module 1477; source: utils/native/ImageUtils.tsx; dependencies: [57, 27, 661, 1478, 1468, 22, 1426, 1423, 2] */
import Module00057 from '../../by-id/module-00057.js'; /* Metro dependency 57 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as UseWindowDimensionsNativeModule from '../../modules/screen/useWindowDimensions.native.tsx'; /* Metro dependency 1478 */
function _fun16931(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#16931, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1604:6, offset: 0x00e5f2fc, size: 275 bytes, params: 8, frame: 22
var object2;
const env0_0 = require;
const clampDimension = function(a0) {
var value = a0;
return value > MEDIA_PROXY_MAX_TARGET_RESOLUTION ? MEDIA_PROXY_MAX_TARGET_RESOLUTION : value;
};
const closure = getSrcWithWidthAndHeight_16933;
const closure2 = getMobileOptimizedSrc;
const getSrcWithWidthAndHeight_169332 = getSrcWithWidthAndHeight_16933;
const getMobileOptimizedSrc2 = getMobileOptimizedSrc;
const closure3 = function(a0) {
var value2 = require(dependencyMap[6]).ensureAvatarSource(require(dependencyMap[7]).makeSource(a0));
var ImageManager = NativeModules.ImageManager;
@@ -15,91 +20,91 @@ function _fun16931(global, require, importDefault, importAll, module, exports, d
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
let value = require(27) /* metro dependency 27 */;
let value = ReactNativeModule;
const env0_4 = value.NativeModules;
const env0_5 = value.PixelRatio;
const env0_6 = (require(661) /* metro dependency 661: Constants */).MEDIA_PROXY_MAX_TARGET_RESOLUTION;
const regexp = RegExp('\\.(gif)$', 'i');
const regexp2 = RegExp('\\.(avif)$', 'i');
object2 = {getMobileOptimizedSrc: closure2, getPaletteForAvatarMobile: closure3};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/ImageUtils.tsx');
exports.default = object2;
object = {getMobileOptimizedSrc: getMobileOptimizedSrc2, getPaletteForAvatarMobile: closure3};
(FileImportTrackerModule).fileFinishedImporting('utils/native/ImageUtils.tsx');
exports.default = object;
exports.GIF_RE = regexp;
exports.AVIF_RE = regexp2;
exports.getSrcWithWidthAndHeight = closure;
exports.getMobileOptimizedSrc = closure2;
exports.getSrcWithWidthAndHeight = getSrcWithWidthAndHeight_169332;
exports.getMobileOptimizedSrc = getMobileOptimizedSrc2;
exports.getPaletteForAvatarMobile = closure3;
}
function getSrcWithWidthAndHeight_16933({src, sourceWidth, sourceHeight, targetWidth, targetHeight, format, animated}) { // fn#16933, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1604:264, offset: 0x00e5f423, size: 339 bytes, params: 2, frame: 26
var r0;
format = format === undefined ? null : format;
animated = !(animated === undefined) && animated;
let value = src.split('?');
value = env0_3(value, 2);
let property = value[0];
const property2 = value[1];
const items2 = [property];
value = importDefault(1468) /* metro dependency 1468 */;
items2[1] = value.parse(property2);
value = env0_3(items2, 2);
property = value[0];
const property3 = value[1];
const binding = env0_8;
if (binding.test(property)) {
property3.format = 'webp';
} else if (format != null) {
property3.format = format;
}
const clampDimensionBinding = clampDimension;
value = clampDimensionBinding(targetWidth);
const value3 = clampDimensionBinding(targetHeight);
if (!(value === sourceWidth && value3 === sourceHeight)) {
property3.width = value | 0;
property3.height = value3 | 0;
}
if (animated) {
property3.animated = true;
}
if (Reflect.apply((importDefault(22) /* metro dependency 22 */).isEmpty, value, [property3])) {
r0 = property;
} else {
function getSrcWithWidthAndHeight_16933({src, sourceWidth, sourceHeight, targetWidth, targetHeight, format, animated}) { // fn#16933, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1604:264, offset: 0x00e5f423, size: 339 bytes, params: 2, frame: 26
var r0;
format = format === undefined ? null : format;
animated = !(animated === undefined) && animated;
let value = src.split('?');
value = Module00057(value, 2);
let property = value[0];
const property2 = value[1];
const items2 = [property];
value = importDefault(1468) /* metro dependency 1468 */;
value = property + ('?' + value.stringify(property3));
r0 = value;
items2[1] = value.parse(property2);
value = Module00057(items2, 2);
property = value[0];
const property3 = value[1];
const binding = env0_8;
if (binding.test(property)) {
property3.format = 'webp';
} else if (format != null) {
property3.format = format;
}
const clampDimensionBinding = clampDimension;
value = clampDimensionBinding(targetWidth);
const value3 = clampDimensionBinding(targetHeight);
if (!(value === sourceWidth && value3 === sourceHeight)) {
property3.width = value | 0;
property3.height = value3 | 0;
}
if (animated) {
property3.animated = true;
}
if (Reflect.apply((importDefault(22) /* metro dependency 22 */).isEmpty, value, [property3])) {
r0 = property;
} else {
value = importDefault(1468) /* metro dependency 1468 */;
value = property + ('?' + value.stringify(property3));
r0 = value;
}
return r0;
}
return r0;
}
function getMobileOptimizedSrc(a0, a1, a2) { // fn#16934, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1604:727, offset: 0x00e5f576, size: 268 bytes, params: 4, frame: 22
var r4;
var value15;
const value = a1;
const value2 = a2;
const value3 = a3;
const r3 = value3 !== undefined ? value3 : null;
const value6 = env0_7.test(a0);
const value7 = 1;
let r5 = value6 ? 0.3 : value7;
const windowDimensions = (require(1478) /* metro dependency 1478: useWindowDimensionsNative */).getWindowDimensions();
let getPixelSizeForLayoutSize = PixelRatio.getPixelSizeForLayoutSize;
const value10 = Reflect.apply(getPixelSizeForLayoutSize, PixelRatio, [windowDimensions.width]) * r5;
getPixelSizeForLayoutSize = PixelRatio.getPixelSizeForLayoutSize;
r5 = value > value2 ? value10 / value : Reflect.apply(getPixelSizeForLayoutSize, PixelRatio, [windowDimensions.height / 2]) * r5 / value2;
let Math = global.Math;
const value14 = Math.min(r5, value7);
if (value14 < value7) {
Math = global.Math;
value15 = Math.ceil(value * value14);
Math = global.Math;
r4 = Math.ceil(value2 * value14);
r5 = value15;
} else {
r4 = value2;
r5 = value;
function getMobileOptimizedSrc(a0, a1, a2) { // fn#16934, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1604:727, offset: 0x00e5f576, size: 268 bytes, params: 4, frame: 22
var r4;
var value15;
const value = a1;
const value2 = a2;
const value3 = a3;
const r3 = value3 !== undefined ? value3 : null;
const value6 = env0_7.test(a0);
const value7 = 1;
let r5 = value6 ? 0.3 : value7;
const windowDimensions = (UseWindowDimensionsNativeModule).getWindowDimensions();
let getPixelSizeForLayoutSize = PixelRatio.getPixelSizeForLayoutSize;
const value10 = Reflect.apply(getPixelSizeForLayoutSize, PixelRatio, [windowDimensions.width]) * r5;
getPixelSizeForLayoutSize = PixelRatio.getPixelSizeForLayoutSize;
r5 = value > value2 ? value10 / value : Reflect.apply(getPixelSizeForLayoutSize, PixelRatio, [windowDimensions.height / 2]) * r5 / value2;
let Math = global.Math;
const value14 = Math.min(r5, value7);
if (value14 < value7) {
Math = global.Math;
value15 = Math.ceil(value * value14);
Math = global.Math;
r4 = Math.ceil(value2 * value14);
r5 = value15;
} else {
r4 = value2;
r5 = value;
}
return getSrcWithWidthAndHeight_16933({src: a0, sourceWidth: value, sourceHeight: value2, targetWidth: r5,
targetHeight: r4, format: r3});
}
return getSrcWithWidthAndHeight_16933({src: a0, sourceWidth: value, sourceHeight: value2, targetWidth: r5,
targetHeight: r4, format: r3});
}
global.__d(_fun16931, 1477, [57, 27, 661, 1478, 1468, 22, 1426, 1423,
2]) /* metro module 1477, dependencies: [57, 27, 661, 1478, 1468, 22, 1426, 1423, 2] */;
+110 -76
View File
@@ -1,4 +1,12 @@
/* Metro module 9154; source: utils/native/InstantInviteUtils.tsx; dependencies: [1379, 1935, 3784, 661, 1244, 9050, 566, 2] */
import ChannelStore from '../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
import GuildChannelStore from '../../stores/GuildChannelStore.tsx'; /* Metro dependency 1935 */
import PermissionStore from '../../stores/PermissionStore.tsx'; /* Metro dependency 3784 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as FluxModule from '../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as GuildChannelStoreModule from '../../stores/GuildChannelStore.tsx'; /* Metro dependency 1935 */
function _fun71749(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#71749, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:6, offset: 0x01d2c5c1, size: 809 bytes, params: 8, frame: 37
let env0_0 = require;
const closure = function(a0, a1) {
@@ -14,13 +22,9 @@ function _fun71749(global, require, importDefault, importAll, module, exports, d
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
let value = require(1935) /* metro dependency 1935: GuildChannelStore */;
let value = GuildChannelStoreModule;
const env0_3 = value.GUILD_SELECTABLE_CHANNELS_KEY;
const env0_4 = value.GUILD_VOCAL_CHANNELS_KEY;
const guildChannelStore = importDefault(1935) /* metro dependency 1935: GuildChannelStore */;
const permissionStore = importDefault(3784) /* metro dependency 3784: PermissionStore */;
const env0_7 = (require(661) /* metro dependency 661: Constants */).Permissions;
value = closure(0, function() {
return require(dependencyMap[4]).intl.string(require(dependencyMap[4]).t.PqEzn8);
}, function() {
@@ -95,7 +99,7 @@ function _fun71749(global, require, importDefault, importAll, module, exports, d
return require(dependencyMap[4]).intl.formatToPlainString(require(dependencyMap[4]).t.gPl14C, {maxUses: 100});
});
const items3 = [value12, value13, value14, value15, value16, value17, value18];
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/InstantInviteUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/InstantInviteUtils.tsx');
exports.INVITE_OPTIONS_FOREVER = value;
exports.INVITE_OPTIONS_7_DAYS = value2;
exports.INVITE_OPTIONS_14_DAYS = value3;
@@ -119,81 +123,111 @@ function _fun71749(global, require, importDefault, importAll, module, exports, d
exports.getInviteChannelId = getInviteChannelId;
exports.shouldRenderInvite = shouldRenderInvite;
exports.useShouldShowInviteInActionBar = useShouldShowInviteInActionBar;
}
function makeOption(a0, a1) { // fn#71750, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:221, offset: 0x01d2c8ea, size: 70 bytes, params: 3, frame: 5
const value = a1;
const value2 = a2;
const env0_1 = value2 !== undefined ? value2 : value;
const object2 = {value: a0};
Object.defineProperty(object2, 'label', {get: function() {
return require();
}, set: undefined, enumerable: true, configurable: true});
Object.defineProperty(object2, 'descriptiveLabel', {get: _fun71752, set: undefined, enumerable: true,
configurable: true});
return object2;
}
function getInviteChannelId(a0, a1) { // fn#71780, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:2738, offset: 0x01d2cf07, size: 195 bytes, params: 3, frame: 19
var r1;
var canWithPartialContext2;
var value5;
var channel;
const value = a0;
const value2 = null;
if (value2 == a1) {
return value2;
}
if (value2 != value) {
canWithPartialContext2 = PermissionStore.canWithPartialContext(Permissions.CREATE_INSTANT_INVITE,
{channelId: value});
value5 = a1[GUILD_SELECTABLE_CHANNELS_KEY].concat(a1[GUILD_VOCAL_CHANNELS_KEY]).find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
});
if (canWithPartialContext2) {
channel = ChannelStore.getChannel(value);
r1 = value2 == channel ? value : channel.isThread() ? value2 == channel.parent_id ? value : channel.parent_id : value;
} else {
r1 = value2 != value5 ? value5.channel.id : value2;
function makeOption(a0, a1) { // fn#71750, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:221, offset: 0x01d2c8ea, size: 70 bytes, params: 3, frame: 5
const value = a1;
const value2 = a2;
const env0_1 = value2 !== undefined ? value2 : value;
const object = {value: a0};
Object.defineProperty(object, 'label', {get: function() {
return require();
}, set: undefined, enumerable: true, configurable: true});
Object.defineProperty(object, 'descriptiveLabel', {get: _fun71752, set: undefined, enumerable: true,
configurable: true});
return object;
function _fun71751() { // fn#71751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:265, offset: 0x00cefeb4, size: 15 bytes, params: 1, frame: 9
return require();
}
} else {
r1 = value2;
function _fun71752() { // fn#71752, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:289, offset: 0x01025531, size: 15 bytes, params: 1, frame: 9
return env0_1();
}
}
return r1;
}
function shouldRenderInvite(a0, a1) { // fn#71782, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3109, offset: 0x01d2cff1, size: 163 bytes, params: 3, frame: 19
var r1;
let value = undefined;
const value2 = (a1 == null ? value : a1.vanityURLCode) == null;
if (value2) {
r1 = value2;
} else {
value = require(9050) /* metro dependency 9050: canViewInviteModal */;
value = !value.canViewInviteModal(PermissionStore, a1);
r1 = value;
function getInviteChannelId(a0, a1) { // fn#71780, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:2738, offset: 0x01d2cf07, size: 195 bytes, params: 3, frame: 19
var r1;
var permissionStoreBinding;
var canWithPartialContext2;
var value5;
var channel;
const value = a0;
const value2 = null;
if (value2 == a1) {
return value2;
}
if (value2 != value) {
permissionStoreBinding = PermissionStore;
canWithPartialContext2 = permissionStoreBinding.canWithPartialContext(Permissions.CREATE_INSTANT_INVITE,
{channelId: value});
value5 = a1[GUILD_SELECTABLE_CHANNELS_KEY].concat(a1[GUILD_VOCAL_CHANNELS_KEY]).find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
});
if (canWithPartialContext2) {
channel = ChannelStore.getChannel(value);
r1 = value2 == channel ? value : channel.isThread() ? value2 == channel.parent_id ? value : channel.parent_id : value;
} else {
r1 = value2 != value5 ? value5.channel.id : value2;
}
} else {
r1 = value2;
}
return r1;
}
return r1 ? a0 != null && (a0[GUILD_SELECTABLE_CHANNELS_KEY].find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
}) != null || a0[GUILD_VOCAL_CHANNELS_KEY].find(_fun71784) != null) : !r1;
}
function useShouldShowInviteInActionBar(a0) { // fn#71785, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3405, offset: 0x01d2d094, size: 226 bytes, params: 2, frame: 20
var r1;
var moduleValue2;
const env0_0 = a0;
const value2 = undefined;
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildChannelStore],
_fun71786, [a0.id]);
const value4 = (a0 == null ? value2 : a0.vanityURLCode) == null;
if (value4) {
r1 = value4;
} else {
moduleValue2 = require(9050) /* metro dependency 9050: canViewInviteModal */;
r1 = !moduleValue2.canViewInviteModal(PermissionStore, a0);
function shouldRenderInvite(a0, a1) { // fn#71782, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3109, offset: 0x01d2cff1, size: 163 bytes, params: 3, frame: 19
var r1;
let value = undefined;
const value2 = (a1 == null ? value : a1.vanityURLCode) == null;
if (value2) {
r1 = value2;
} else {
value = require(9050) /* metro dependency 9050: canViewInviteModal */;
value = !value.canViewInviteModal(PermissionStore, a1);
r1 = value;
}
return r1 ? a0 != null && (a0[GUILD_SELECTABLE_CHANNELS_KEY].find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
}) != null || a0[GUILD_VOCAL_CHANNELS_KEY].find(_fun71784) != null) : !r1;
function _fun71784({channel}) { // fn#71784, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3320, offset: 0x01d2cfca, size: 39 bytes, params: 2, frame: 13
const permissionStoreBinding = PermissionStore;
const can = permissionStoreBinding.can;
const CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
return Reflect.apply(can, permissionStoreBinding, [CREATE_INSTANT_INVITE, channel]);
}
}
function useShouldShowInviteInActionBar(a0) { // fn#71785, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3405, offset: 0x01d2d094, size: 226 bytes, params: 2, frame: 20
var r1;
var moduleValue2;
const env0_0 = a0;
const value2 = undefined;
const value3 = (FluxModule).useStateFromStoresObject([GuildChannelStore],
_fun71786, [a0.id]);
const value4 = (a0 == null ? value2 : a0.vanityURLCode) == null;
if (value4) {
r1 = value4;
} else {
moduleValue2 = require(9050) /* metro dependency 9050: canViewInviteModal */;
r1 = !moduleValue2.canViewInviteModal(PermissionStore, a0);
}
return r1 ? value3 == null || (value3[GUILD_SELECTABLE_CHANNELS_KEY].find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
}) != null || value3[GUILD_VOCAL_CHANNELS_KEY].find(_fun71788) != null) : !r1;
function _fun71786() { // fn#71786, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3492, offset: 0x01d2d176, size: 32 bytes, params: 1, frame: 11
return GuildChannelStore.getChannels(env0_0.id);
}
function _fun71788({channel}) { // fn#71788, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9339:3704, offset: 0x01d2cfca, size: 39 bytes, params: 2, frame: 13
const permissionStoreBinding = PermissionStore;
const can = permissionStoreBinding.can;
const CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
return Reflect.apply(can, permissionStoreBinding, [CREATE_INSTANT_INVITE, channel]);
}
}
return r1 ? value3 == null || (value3[GUILD_SELECTABLE_CHANNELS_KEY].find(function({channel}) {
return PermissionStore.can(Permissions.CREATE_INSTANT_INVITE, channel);
}) != null || value3[GUILD_VOCAL_CHANNELS_KEY].find(_fun71788) != null) : !r1;
}
global.__d(_fun71749, 9154, [1379, 1935, 3784, 661, 1244, 9050, 566,
2]) /* metro module 9154, dependencies: [1379, 1935, 3784, 661, 1244, 9050, 566, 2] */;
+32 -31
View File
@@ -1,48 +1,49 @@
/* Metro module 1848; source: utils/native/KeyboardManagerUtils.tsx; dependencies: [27, 477, 1849, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as PlatformUtilsModule from '../PlatformUtils.tsx'; /* Metro dependency 477 */
function _fun20000(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#20000, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:6, offset: 0x00ebc0a1, size: 144 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = (require(27) /* metro dependency 27 */).NativeModules;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/KeyboardManagerUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/KeyboardManagerUtils.tsx');
exports.dismissGlobalKeyboard = dismissGlobalKeyboard;
exports.clearCurrentFocusAndDismissKeyboard = clearCurrentFocusAndDismissKeyboard;
exports.onKeyboardChanged = onKeyboardChanged;
}
function dismissGlobalKeyboard() { // fn#20001, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:215, offset: 0x00ebc131, size: 115 bytes, params: 1, frame: 13
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).dismissGlobalKeyboard();
}
} else {
NativeModules.KeyboardManager.dismissGlobalKeyboard();
}
}
function clearCurrentFocusAndDismissKeyboard() { // fn#20002, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:396, offset: 0x00ebc1a4, size: 93 bytes, params: 1, frame: 13
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).clearCurrentFocusAndDismissKeyboard();
function dismissGlobalKeyboard() { // fn#20001, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:215, offset: 0x00ebc131, size: 115 bytes, params: 1, frame: 13
if (PlatformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).dismissGlobalKeyboard();
}
} else {
NativeModules.KeyboardManager.dismissGlobalKeyboard();
}
}
}
function onKeyboardChanged(a0) { // fn#20003, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:548, offset: 0x00ebc201, size: 150 bytes, params: 2, frame: 13
var KeyboardManager;
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).onKeyboardChanged(a0);
function clearCurrentFocusAndDismissKeyboard() { // fn#20002, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:396, offset: 0x00ebc1a4, size: 93 bytes, params: 1, frame: 13
if (PlatformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).clearCurrentFocusAndDismissKeyboard();
}
}
} else {
KeyboardManager = NativeModules.KeyboardManager;
if (KeyboardManager.onKeyboardChanged != null) {
}
function onKeyboardChanged(a0) { // fn#20003, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1975:548, offset: 0x00ebc201, size: 150 bytes, params: 2, frame: 13
var KeyboardManager;
if (PlatformUtilsModule.isAndroid()) {
if ((importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */) != null) {
(importDefault(1849) /* metro dependency 1849: NativeKeyboardModule */).onKeyboardChanged(a0);
}
} else {
KeyboardManager = NativeModules.KeyboardManager;
KeyboardManager.onKeyboardChanged(global.open);
if (KeyboardManager.onKeyboardChanged != null) {
KeyboardManager = NativeModules.KeyboardManager;
KeyboardManager.onKeyboardChanged(global.open);
}
}
}
}
global.__d(_fun20000, 1848, [27, 477, 1849, 2]) /* metro module 1848, dependencies: [27, 477, 1849, 2] */;
+11 -8
View File
@@ -1,16 +1,19 @@
/* Metro module 11029; source: utils/native/KeyboardUtils.tsx; dependencies: [27, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
function _fun84449(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#84449, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11215:6, offset: 0x01f4ab07, size: 109 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_0 = (require(27) /* metro dependency 27 */).Keyboard;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/KeyboardUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/KeyboardUtils.tsx');
exports.dismissKeyboard = dismissKeyboard_84450;
}
function dismissKeyboard_84450() { // fn#84450, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11215:197, offset: 0x01f4ab74, size: 33 bytes, params: 1, frame: 10
const value = a0;
if (!(!(value !== undefined) || value)) {
Keyboard.dismiss();
function dismissKeyboard_84450() { // fn#84450, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11215:197, offset: 0x01f4ab74, size: 33 bytes, params: 1, frame: 10
const value = a0;
if (!(!(value !== undefined) || value)) {
Keyboard.dismiss();
}
}
}
global.__d(_fun84449, 11029, [27, 2]) /* metro module 11029, dependencies: [27, 2] */;
+288 -281
View File
@@ -1,14 +1,14 @@
/* Metro module 11523; source: utils/native/MessagesUtils.tsx; dependencies: [661, 6934, 4101, 4105, 4803, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as CodedLinkModule from '../../modules/coded_links/CodedLink.tsx'; /* Metro dependency 4101 */
import * as GuildTemplatesConstantsModule from '../../modules/guild_templates/GuildTemplatesConstants.tsx'; /* Metro dependency 6934 */
function _fun88206(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#88206, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:6, offset: 0x01fd9d9c, size: 192 bytes, params: 8, frame: 18
var object2;
let env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const constantsModule = require(661) /* metro dependency 661: Constants */;
const env0_2 = constantsModule.InviteStates;
const env0_3 = constantsModule.MessageEmbedTypes;
const env0_4 = (require(6934) /* metro dependency 6934: GuildTemplatesConstants */).GuildTemplateStates;
object2 = {messageAuthorActivitiesChanged: function(a0, a1, a2) {
object = {messageAuthorActivitiesChanged: function(a0, a1, a2) {
var r0;
var property = a1.messageAuthorActivities;
r0 = property !== a2.messageAuthorActivities && a0.activity != null;
@@ -36,286 +36,293 @@ function _fun88206(global, require, importDefault, importAll, module, exports, d
}
return r0;
}};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/MessagesUtils.tsx');
exports.default = object2;
}
function codedLinksChanged(a0, a1, a2) { // fn#88208, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:439, offset: 0x01fd9eb7, size: 299 bytes, params: 4, frame: 16
var r1;
var r0;
const env0_0 = a1;
const env0_1 = a2;
const value = a0.codedLinks.length !== 0;
if (value) {
r1 = a1.invites !== a2.invites || a1.appDirectoryEmbedApplications !== a2.appDirectoryEmbedApplications;
r1 = !r1 ? a1.invalidAppDirectoryEmbedApplicationIds !== a2.invalidAppDirectoryEmbedApplicationIds : r1;
r1 = !r1 ? a1.invalidApplicationIds !== a2.invalidApplicationIds : r1;
r1 = !r1 ? a1.appDirectoryEmbedApplicationFetchStates !== a2.appDirectoryEmbedApplicationFetchStates : r1;
r1 = !r1 ? a1.guildTemplates !== a2.guildTemplates : r1;
r1 = !r1 ? a1.buildOverrides !== a2.buildOverrides : r1;
r1 = !r1 ? a1.activityParticipants !== a2.activityParticipants : r1;
r1 = !r1 ? a1.quests !== a2.quests : r1;
r1 = !r1 ? a1.isFetchingCurrentQuests !== a2.isFetchingCurrentQuests : r1;
r1 = !r1 ? a1.applicationAssetFetchingIds !== a2.applicationAssetFetchingIds : r1;
r1 = !r1 ? a1.experimentEmbeds !== a2.experimentEmbeds : r1;
r1 = r1 && a0.codedLinks.some(_fun88209);
r0 = r1;
} else {
r0 = value;
}
return r0;
}
function giftCodesChanged(a0, a1, a2) { // fn#88210, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4142, offset: 0x01fda71f, size: 65 bytes, params: 4, frame: 12
const env0_0 = a1;
const env0_1 = a2;
return a0.giftCodes.length !== 0 && a0.giftCodes.some(_fun88211);
}
function mediaPostPreviewEmbedsChanged({embeds}, a1, a2) { // fn#88212, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4506, offset: 0x01fda7e2, size: 76 bytes, params: 4, frame: 12
var r0;
const env0_0 = a1;
const env0_1 = a2;
let value = embeds.filter(function({type}) {
return type === MessageEmbedTypes.POST_PREVIEW;
});
const value2 = value.length !== 0;
if (value2) {
value = value.some(_fun88214);
r0 = value;
} else {
r0 = value2;
}
return r0;
}
function _fun88209({type, code}) { // fn#88209, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:1143, offset: 0x01fd9fe2, size: 1853 bytes, params: 2, frame: 19
var r3;
var r5;
var r8;
var r1;
var invites;
var value6;
var value7;
var appDirectoryEmbedApplications;
var property;
var property2;
var invalidAppDirectoryEmbedApplicationIds;
var value14;
var appDirectoryEmbedApplicationFetchStates;
var property3;
var guildTemplates;
var value17;
var value18;
var value21;
var value22;
var value23;
var value25;
var experimentEmbeds;
var legacyExperiments;
var value27;
var legacyOverridesInfo;
var apexExperiments;
var apexOverridesInfo;
var buildOverrides;
let value = environment.__proto__;
const CodedLinkType = (require(4101) /* metro dependency 4101: CodedLink */).CodedLinkType;
const BUILD_OVERRIDE = CodedLinkType.BUILD_OVERRIDE;
if (BUILD_OVERRIDE === type) {
buildOverrides = require.buildOverrides;
property = buildOverrides[code];
buildOverrides = importDefault.buildOverrides;
return property?.state !== buildOverrides[code]?.state;
}
const MANUAL_BUILD_OVERRIDE = CodedLinkType.MANUAL_BUILD_OVERRIDE;
if (MANUAL_BUILD_OVERRIDE === type) {
buildOverrides = require.buildOverrides;
property = buildOverrides[code];
buildOverrides = importDefault.buildOverrides;
return property?.state !== buildOverrides[code]?.state;
}
const EXPERIMENT = CodedLinkType.EXPERIMENT;
if (EXPERIMENT === type) {
value = require(4105) /* metro dependency 4105: ExperimentEmbedUtils */;
value = value.getExperimentFromEmbedURL(code);
value25 = value != null;
if (value25) {
experimentEmbeds = require.experimentEmbeds;
legacyExperiments = experimentEmbeds.legacyExperiments;
r5 = legacyExperiments?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
legacyExperiments = experimentEmbeds.legacyExperiments;
r3 = legacyExperiments?.[value];
value27 = r5 !== r3;
if (value27) {
r3 = value27;
} else {
experimentEmbeds = require.experimentEmbeds;
legacyOverridesInfo = experimentEmbeds.legacyOverridesInfo;
r8 = legacyOverridesInfo?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
legacyOverridesInfo = experimentEmbeds.legacyOverridesInfo;
r3 = r8 !== legacyOverridesInfo?.[value];
}
if (!r3) {
experimentEmbeds = require.experimentEmbeds;
apexExperiments = experimentEmbeds.apexExperiments;
r8 = apexExperiments?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
apexExperiments = experimentEmbeds.apexExperiments;
r3 = r8 !== apexExperiments?.[value];
}
if (!r3) {
experimentEmbeds = require.experimentEmbeds;
apexOverridesInfo = experimentEmbeds.apexOverridesInfo;
r5 = apexOverridesInfo?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
apexOverridesInfo = experimentEmbeds.apexOverridesInfo;
value = r5 !== apexOverridesInfo?.[value];
r3 = value;
}
r1 = r3;
(FileImportTrackerModule).fileFinishedImporting('utils/native/MessagesUtils.tsx');
exports.default = object;
function codedLinksChanged(a0, a1, a2) { // fn#88208, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:439, offset: 0x01fd9eb7, size: 299 bytes, params: 4, frame: 16
var r1;
var r0;
const env0_0 = a1;
const env0_1 = a2;
const value = a0.codedLinks.length !== 0;
if (value) {
r1 = a1.invites !== a2.invites || a1.appDirectoryEmbedApplications !== a2.appDirectoryEmbedApplications;
r1 = !r1 ? a1.invalidAppDirectoryEmbedApplicationIds !== a2.invalidAppDirectoryEmbedApplicationIds : r1;
r1 = !r1 ? a1.invalidApplicationIds !== a2.invalidApplicationIds : r1;
r1 = !r1 ? a1.appDirectoryEmbedApplicationFetchStates !== a2.appDirectoryEmbedApplicationFetchStates : r1;
r1 = !r1 ? a1.guildTemplates !== a2.guildTemplates : r1;
r1 = !r1 ? a1.buildOverrides !== a2.buildOverrides : r1;
r1 = !r1 ? a1.activityParticipants !== a2.activityParticipants : r1;
r1 = !r1 ? a1.quests !== a2.quests : r1;
r1 = !r1 ? a1.isFetchingCurrentQuests !== a2.isFetchingCurrentQuests : r1;
r1 = !r1 ? a1.applicationAssetFetchingIds !== a2.applicationAssetFetchingIds : r1;
r1 = !r1 ? a1.experimentEmbeds !== a2.experimentEmbeds : r1;
r1 = r1 && a0.codedLinks.some(_fun88209);
r0 = r1;
} else {
r1 = value25;
r0 = value;
}
return r1;
return r0;
function _fun88209({type, code}) { // fn#88209, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:1143, offset: 0x01fd9fe2, size: 1853 bytes, params: 2, frame: 19
var r3;
var r5;
var r8;
var r1;
var invites;
var value6;
var value7;
var appDirectoryEmbedApplications;
var property;
var property2;
var invalidAppDirectoryEmbedApplicationIds;
var value14;
var appDirectoryEmbedApplicationFetchStates;
var property3;
var guildTemplates;
var value17;
var value18;
var value21;
var value22;
var value23;
var value25;
var experimentEmbeds;
var legacyExperiments;
var value27;
var legacyOverridesInfo;
var apexExperiments;
var apexOverridesInfo;
var buildOverrides;
let value = environment.__proto__;
const CodedLinkType = (CodedLinkModule).CodedLinkType;
const BUILD_OVERRIDE = CodedLinkType.BUILD_OVERRIDE;
if (BUILD_OVERRIDE === type) {
buildOverrides = require.buildOverrides;
property = buildOverrides[code];
buildOverrides = importDefault.buildOverrides;
return property?.state !== buildOverrides[code]?.state;
}
const MANUAL_BUILD_OVERRIDE = CodedLinkType.MANUAL_BUILD_OVERRIDE;
if (MANUAL_BUILD_OVERRIDE === type) {
buildOverrides = require.buildOverrides;
property = buildOverrides[code];
buildOverrides = importDefault.buildOverrides;
return property?.state !== buildOverrides[code]?.state;
}
const EXPERIMENT = CodedLinkType.EXPERIMENT;
if (EXPERIMENT === type) {
value = require(4105) /* metro dependency 4105: ExperimentEmbedUtils */;
value = value.getExperimentFromEmbedURL(code);
value25 = value != null;
if (value25) {
experimentEmbeds = require.experimentEmbeds;
legacyExperiments = experimentEmbeds.legacyExperiments;
r5 = legacyExperiments?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
legacyExperiments = experimentEmbeds.legacyExperiments;
r3 = legacyExperiments?.[value];
value27 = r5 !== r3;
if (value27) {
r3 = value27;
} else {
experimentEmbeds = require.experimentEmbeds;
legacyOverridesInfo = experimentEmbeds.legacyOverridesInfo;
r8 = legacyOverridesInfo?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
legacyOverridesInfo = experimentEmbeds.legacyOverridesInfo;
r3 = r8 !== legacyOverridesInfo?.[value];
}
if (!r3) {
experimentEmbeds = require.experimentEmbeds;
apexExperiments = experimentEmbeds.apexExperiments;
r8 = apexExperiments?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
apexExperiments = experimentEmbeds.apexExperiments;
r3 = r8 !== apexExperiments?.[value];
}
if (!r3) {
experimentEmbeds = require.experimentEmbeds;
apexOverridesInfo = experimentEmbeds.apexOverridesInfo;
r5 = apexOverridesInfo?.[value];
experimentEmbeds = importDefault.experimentEmbeds;
apexOverridesInfo = experimentEmbeds.apexOverridesInfo;
value = r5 !== apexOverridesInfo?.[value];
r3 = value;
}
r1 = r3;
} else {
r1 = value25;
}
return r1;
}
const INVITE = CodedLinkType.INVITE;
if (INVITE === type) {
invites = require.invites;
value21 = invites.get(code);
invites = importDefault.invites;
value22 = invites.get(code);
value23 = require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds;
r3 = value21?.state !== value22?.state && value22?.state !== InviteStates.RESOLVING;
r3 = !r3 ? value23 : r3;
return r3;
}
const TEMPLATE = CodedLinkType.TEMPLATE;
if (TEMPLATE === type) {
guildTemplates = require.guildTemplates;
value17 = guildTemplates.get(code);
guildTemplates = importDefault.guildTemplates;
value18 = guildTemplates.get(code);
return value17?.state !== value18?.state && value18?.state !== GuildTemplateStates.RESOLVING;
}
const EVENT = CodedLinkType.EVENT;
if (EVENT === type) {
return false;
}
const CHANNEL_LINK = CodedLinkType.CHANNEL_LINK;
if (CHANNEL_LINK === type) {
return false;
}
const APP_DIRECTORY_PROFILE = CodedLinkType.APP_DIRECTORY_PROFILE;
if (APP_DIRECTORY_PROFILE === type) {
appDirectoryEmbedApplications = require.appDirectoryEmbedApplications;
property = appDirectoryEmbedApplications[code];
appDirectoryEmbedApplications = importDefault.appDirectoryEmbedApplications;
property2 = appDirectoryEmbedApplications[code];
invalidAppDirectoryEmbedApplicationIds = require.invalidAppDirectoryEmbedApplicationIds;
value = invalidAppDirectoryEmbedApplicationIds.has(code);
invalidAppDirectoryEmbedApplicationIds = importDefault.invalidAppDirectoryEmbedApplicationIds;
value14 = invalidAppDirectoryEmbedApplicationIds.has(code);
appDirectoryEmbedApplicationFetchStates = require.appDirectoryEmbedApplicationFetchStates;
property3 = appDirectoryEmbedApplicationFetchStates[code];
appDirectoryEmbedApplicationFetchStates = importDefault.appDirectoryEmbedApplicationFetchStates;
r3 = property !== property2 || value !== value14;
r3 = !r3 ? property3 !== appDirectoryEmbedApplicationFetchStates[code] : r3;
return r3;
}
const ACTIVITY_BOOKMARK = CodedLinkType.ACTIVITY_BOOKMARK;
if (ACTIVITY_BOOKMARK === type) {
r3 = require.activityParticipants !== importDefault.activityParticipants || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
r3 = !r3 ? require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds : r3;
return r3;
}
const EMBEDDED_ACTIVITY_INVITE = CodedLinkType.EMBEDDED_ACTIVITY_INVITE;
if (EMBEDDED_ACTIVITY_INVITE === type) {
invites = require.invites;
value6 = invites.get(code);
invites = importDefault.invites;
value7 = invites.get(code);
r3 = require.activityParticipants !== importDefault.activityParticipants || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
r3 = !r3 ? require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds : r3;
r3 = !r3 ? value6?.state !== value7?.state && value7?.state !== InviteStates.RESOLVING : r3;
return r3;
}
const GUILD_PRODUCT = CodedLinkType.GUILD_PRODUCT;
if (GUILD_PRODUCT === type) {
return false;
}
const SERVER_SHOP = CodedLinkType.SERVER_SHOP;
if (SERVER_SHOP === type) {
return false;
}
const SOCIAL_LAYER_STOREFRONT = CodedLinkType.SOCIAL_LAYER_STOREFRONT;
if (SOCIAL_LAYER_STOREFRONT === type) {
return false;
}
const SOCIAL_LAYER_STOREFRONT_APP = CodedLinkType.SOCIAL_LAYER_STOREFRONT_APP;
if (SOCIAL_LAYER_STOREFRONT_APP === type) {
return false;
}
const QUESTS_EMBED = CodedLinkType.QUESTS_EMBED;
if (QUESTS_EMBED === type) {
return require.quests !== importDefault.quests || require.isFetchingCurrentQuests !== importDefault.isFetchingCurrentQuests;
}
const APP_DIRECTORY_STOREFRONT = CodedLinkType.APP_DIRECTORY_STOREFRONT;
if (APP_DIRECTORY_STOREFRONT === type) {
return false;
}
const APP_DIRECTORY_STOREFRONT_SKU = CodedLinkType.APP_DIRECTORY_STOREFRONT_SKU;
if (APP_DIRECTORY_STOREFRONT_SKU === type) {
return false;
}
const APP_OAUTH2_LINK = CodedLinkType.APP_OAUTH2_LINK;
if (APP_OAUTH2_LINK === type) {
return require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
}
const COLLECTIBLES_SHOP = CodedLinkType.COLLECTIBLES_SHOP;
if (COLLECTIBLES_SHOP === type) {
return false;
}
const Error = global.Error;
throw Error('Unknown coded link type: ' + type);
}
}
const INVITE = CodedLinkType.INVITE;
if (INVITE === type) {
invites = require.invites;
value21 = invites.get(code);
invites = importDefault.invites;
value22 = invites.get(code);
value23 = require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds;
r3 = value21?.state !== value22?.state && value22?.state !== InviteStates.RESOLVING;
r3 = !r3 ? value23 : r3;
return r3;
function giftCodesChanged(a0, a1, a2) { // fn#88210, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4142, offset: 0x01fda71f, size: 65 bytes, params: 4, frame: 12
const env0_0 = a1;
const env0_1 = a2;
return a0.giftCodes.length !== 0 && a0.giftCodes.some(_fun88211);
function _fun88211(a0) { // fn#88211, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4224, offset: 0x01fda760, size: 130 bytes, params: 2, frame: 16
const value2 = require.resolvedGiftCodes.includes(a0);
const value = importDefault.resolvedGiftCodes.includes(a0);
const value3 = require.resolvingGiftCodes.includes(a0);
const value4 = importDefault.resolvingGiftCodes.includes(a0);
const value5 = require.acceptingGiftCodes.includes(a0);
const value6 = importDefault.acceptingGiftCodes.includes(a0);
if (value2 !== value) {
return true;
}
if (value3 !== value4) {
return true;
}
if (value5 !== value6) {
return true;
}
}
}
const TEMPLATE = CodedLinkType.TEMPLATE;
if (TEMPLATE === type) {
guildTemplates = require.guildTemplates;
value17 = guildTemplates.get(code);
guildTemplates = importDefault.guildTemplates;
value18 = guildTemplates.get(code);
return value17?.state !== value18?.state && value18?.state !== GuildTemplateStates.RESOLVING;
function mediaPostPreviewEmbedsChanged({embeds}, a1, a2) { // fn#88212, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4506, offset: 0x01fda7e2, size: 76 bytes, params: 4, frame: 12
var r0;
const env0_0 = a1;
const env0_1 = a2;
let value = embeds.filter(function({type}) {
return type === MessageEmbedTypes.POST_PREVIEW;
});
const value2 = value.length !== 0;
if (value2) {
value = value.some(_fun88214);
r0 = value;
} else {
r0 = value2;
}
return r0;
function _fun88213({type}) { // fn#88213, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4575, offset: 0x01fda82e, size: 27 bytes, params: 2, frame: 2
const POST_PREVIEW = MessageEmbedTypes.POST_PREVIEW;
return type === POST_PREVIEW;
}
function _fun88214({url}) { // fn#88214, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4633, offset: 0x01fda849, size: 90 bytes, params: 2, frame: 12
var r0;
var mediaPostPreviewEmbeds;
var property;
let value = environment.__proto__;
value = require(4803) /* metro dependency 4803: MediaPostEmbedUtils */;
value = value.getMediaPostEmbedChannelId(url);
const value2 = value != null;
if (value2) {
mediaPostPreviewEmbeds = require.mediaPostPreviewEmbeds;
property = mediaPostPreviewEmbeds[value];
mediaPostPreviewEmbeds = importDefault.mediaPostPreviewEmbeds;
value = property !== mediaPostPreviewEmbeds[value];
r0 = value;
} else {
r0 = value2;
}
return r0;
}
}
const EVENT = CodedLinkType.EVENT;
if (EVENT === type) {
return false;
}
const CHANNEL_LINK = CodedLinkType.CHANNEL_LINK;
if (CHANNEL_LINK === type) {
return false;
}
const APP_DIRECTORY_PROFILE = CodedLinkType.APP_DIRECTORY_PROFILE;
if (APP_DIRECTORY_PROFILE === type) {
appDirectoryEmbedApplications = require.appDirectoryEmbedApplications;
property = appDirectoryEmbedApplications[code];
appDirectoryEmbedApplications = importDefault.appDirectoryEmbedApplications;
property2 = appDirectoryEmbedApplications[code];
invalidAppDirectoryEmbedApplicationIds = require.invalidAppDirectoryEmbedApplicationIds;
value = invalidAppDirectoryEmbedApplicationIds.has(code);
invalidAppDirectoryEmbedApplicationIds = importDefault.invalidAppDirectoryEmbedApplicationIds;
value14 = invalidAppDirectoryEmbedApplicationIds.has(code);
appDirectoryEmbedApplicationFetchStates = require.appDirectoryEmbedApplicationFetchStates;
property3 = appDirectoryEmbedApplicationFetchStates[code];
appDirectoryEmbedApplicationFetchStates = importDefault.appDirectoryEmbedApplicationFetchStates;
r3 = property !== property2 || value !== value14;
r3 = !r3 ? property3 !== appDirectoryEmbedApplicationFetchStates[code] : r3;
return r3;
}
const ACTIVITY_BOOKMARK = CodedLinkType.ACTIVITY_BOOKMARK;
if (ACTIVITY_BOOKMARK === type) {
r3 = require.activityParticipants !== importDefault.activityParticipants || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
r3 = !r3 ? require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds : r3;
return r3;
}
const EMBEDDED_ACTIVITY_INVITE = CodedLinkType.EMBEDDED_ACTIVITY_INVITE;
if (EMBEDDED_ACTIVITY_INVITE === type) {
invites = require.invites;
value6 = invites.get(code);
invites = importDefault.invites;
value7 = invites.get(code);
r3 = require.activityParticipants !== importDefault.activityParticipants || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
r3 = !r3 ? require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds : r3;
r3 = !r3 ? value6?.state !== value7?.state && value7?.state !== InviteStates.RESOLVING : r3;
return r3;
}
const GUILD_PRODUCT = CodedLinkType.GUILD_PRODUCT;
if (GUILD_PRODUCT === type) {
return false;
}
const SERVER_SHOP = CodedLinkType.SERVER_SHOP;
if (SERVER_SHOP === type) {
return false;
}
const SOCIAL_LAYER_STOREFRONT = CodedLinkType.SOCIAL_LAYER_STOREFRONT;
if (SOCIAL_LAYER_STOREFRONT === type) {
return false;
}
const SOCIAL_LAYER_STOREFRONT_APP = CodedLinkType.SOCIAL_LAYER_STOREFRONT_APP;
if (SOCIAL_LAYER_STOREFRONT_APP === type) {
return false;
}
const QUESTS_EMBED = CodedLinkType.QUESTS_EMBED;
if (QUESTS_EMBED === type) {
return require.quests !== importDefault.quests || require.isFetchingCurrentQuests !== importDefault.isFetchingCurrentQuests;
}
const APP_DIRECTORY_STOREFRONT = CodedLinkType.APP_DIRECTORY_STOREFRONT;
if (APP_DIRECTORY_STOREFRONT === type) {
return false;
}
const APP_DIRECTORY_STOREFRONT_SKU = CodedLinkType.APP_DIRECTORY_STOREFRONT_SKU;
if (APP_DIRECTORY_STOREFRONT_SKU === type) {
return false;
}
const APP_OAUTH2_LINK = CodedLinkType.APP_OAUTH2_LINK;
if (APP_OAUTH2_LINK === type) {
return require.applicationAssetFetchingIds !== importDefault.applicationAssetFetchingIds || require.invalidApplicationIds !== importDefault.invalidApplicationIds;
}
const COLLECTIBLES_SHOP = CodedLinkType.COLLECTIBLES_SHOP;
if (COLLECTIBLES_SHOP === type) {
return false;
}
const Error = global.Error;
throw Error('Unknown coded link type: ' + type);
}
function _fun88211(a0) { // fn#88211, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4224, offset: 0x01fda760, size: 130 bytes, params: 2, frame: 16
const value2 = require.resolvedGiftCodes.includes(a0);
const value = importDefault.resolvedGiftCodes.includes(a0);
const value3 = require.resolvingGiftCodes.includes(a0);
const value4 = importDefault.resolvingGiftCodes.includes(a0);
const value5 = require.acceptingGiftCodes.includes(a0);
const value6 = importDefault.acceptingGiftCodes.includes(a0);
if (value2 !== value) {
return true;
}
if (value3 !== value4) {
return true;
}
if (value5 !== value6) {
return true;
}
}
function _fun88214({url}) { // fn#88214, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11709:4633, offset: 0x01fda849, size: 90 bytes, params: 2, frame: 12
var r0;
var mediaPostPreviewEmbeds;
var property;
let value = environment.__proto__;
value = require(4803) /* metro dependency 4803: MediaPostEmbedUtils */;
value = value.getMediaPostEmbedChannelId(url);
const value2 = value != null;
if (value2) {
mediaPostPreviewEmbeds = require.mediaPostPreviewEmbeds;
property = mediaPostPreviewEmbeds[value];
mediaPostPreviewEmbeds = importDefault.mediaPostPreviewEmbeds;
value = property !== mediaPostPreviewEmbeds[value];
r0 = value;
} else {
r0 = value2;
}
return r0;
}
global.__d(_fun88206, 11523, [661, 6934, 4101, 4105, 4803,
2]) /* metro module 11523, dependencies: [661, 6934, 4101, 4105, 4803, 2] */;
+77 -69
View File
@@ -1,6 +1,10 @@
/* Metro module 1459; source: utils/native/NetworkUtils.tsx; dependencies: [661, 3, 1460, 2] */
import Logger from '../../modules/debug/Logger.tsx'; /* Metro dependency 3 */
import Module01460 from '../../by-id/module-01460.js'; /* Metro dependency 1460 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
function _fun16713(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#16713, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:6, offset: 0x00e58762, size: 377 bytes, params: 8, frame: 20
var object2;
const convertNetInfo = function({type, details}) {
var value2 = null;
return {type: type,
@@ -9,8 +13,7 @@ function _fun16713(global, require, importDefault, importAll, module, exports, d
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_2 = (require(661) /* metro dependency 661: Constants */).NetworkConnectionTypes;
let value = importDefault(3) /* metro dependency 3: Logger */;
let value = Logger;
value = new value('NetworkUtils');
value.enableNativeLogger(true);
const env0_4 = [];
@@ -19,7 +22,7 @@ function _fun16713(global, require, importDefault, importAll, module, exports, d
value = importDefault(1460) /* metro dependency 1460 */;
value = value.fetch();
value.then(_fun16722);
object2 = {addOnlineCallback: function(a0) {
object = {addOnlineCallback: function(a0) {
addCallback(true, a0);
}, removeOnlineCallback: function(a0) {
removeCallback(true, a0);
@@ -29,79 +32,84 @@ function _fun16713(global, require, importDefault, importAll, module, exports, d
removeCallback(false, a0);
}, addChangeCallback: addChangeCallback, removeChangeCallback: removeChangeCallback,
getNetworkInformation: getNetworkInformation, isOnline: isOnline};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/NetworkUtils.tsx');
exports.default = object2;
}
function ensureChangeListenerCreated() { // fn#16714, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:216, offset: 0x00e588db, size: 58 bytes, params: 1, frame: 12
var defaultImport;
if (env0_7 == null) {
defaultImport = importDefault(1460) /* metro dependency 1460 */;
env0_7 = defaultImport.addEventListener(notifyListeners);
(FileImportTrackerModule).fileFinishedImporting('utils/native/NetworkUtils.tsx');
exports.default = object;
function ensureChangeListenerCreated() { // fn#16714, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:216, offset: 0x00e588db, size: 58 bytes, params: 1, frame: 12
var defaultImport;
if (env0_7 == null) {
defaultImport = importDefault(1460) /* metro dependency 1460 */;
env0_7 = defaultImport.addEventListener(notifyListeners_16717);
}
}
}
function cleanupChangeListener() { // fn#16715, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:310, offset: 0x00e58915, size: 88 bytes, params: 1, frame: 12
if (env0_7 != null && env0_4.length === 0 && env0_5.length === 0 && env0_6.length === 0) {
env0_7();
function cleanupChangeListener() { // fn#16715, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:310, offset: 0x00e58915, size: 88 bytes, params: 1, frame: 12
if (env0_7 != null && env0_4.length === 0 && env0_5.length === 0 && env0_6.length === 0) {
env0_7();
}
}
}
function notifyListeners(a0) { // fn#16717, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:576, offset: 0x00e589be, size: 162 bytes, params: 2, frame: 25
const isConnected = a0.isConnected;
const value2 = convertNetInfo(a0);
const r5 = isConnected ? env0_4 : env0_5;
env0_8 = isConnected != null && isConnected;
const binding = env0_3;
binding.log('Network status changed: isConnected:' + isConnected + ' type:' + a0.type + ' speed:' + value2.cellularGeneration);
r5.forEach(_fun16718);
env0_6.forEach(_fun16719);
}
function notifyListeners_16717(a0) { // fn#16717, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:576, offset: 0x00e589be, size: 162 bytes, params: 2, frame: 25
const isConnected = a0.isConnected;
const value2 = convertNetInfo(a0);
const r5 = isConnected ? env0_4 : env0_5;
env0_8 = isConnected != null && isConnected;
const binding = env0_3;
binding.log('Network status changed: isConnected:' + isConnected + ' type:' + a0.type + ' speed:' + value2.cellularGeneration);
r5.forEach(_fun16718);
env0_6.forEach(_fun16719);
function _fun16718(a0) { // fn#16718, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:771, offset: 0x00e58a60, size: 37 bytes, params: 2, frame: 13
return a0(isConnected != null && isConnected, env0_1);
}
function addCallback(a0, a1) { // fn#16720, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:813, offset: 0x00e58a98, size: 44 bytes, params: 3, frame: 12
(a0 ? env0_4 : env0_5).push(a1);
ensureChangeListenerCreated();
}
function _fun16719(a0) { // fn#16719, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:803, offset: 0x00e58a85, size: 19 bytes, params: 2, frame: 11
return a0(env0_1);
}
function removeCallback(a0, a1) { // fn#16721, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:885, offset: 0x00e58ac4, size: 75 bytes, params: 3, frame: 14
const r2 = a0 ? env0_4 : env0_5;
const value2 = r2.indexOf(a1);
if (value2 !== -1) {
r2.splice(value2, 1);
cleanupChangeListener();
}
}
function _fun16722({isConnected}) { // fn#16722, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1011, offset: 0x00e58b0f, size: 32 bytes, params: 2, frame: 3
const r1 = isConnected != null && isConnected;
}
function addChangeCallback(a0) { // fn#16727, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1228, offset: 0x00e58b87, size: 32 bytes, params: 2, frame: 12
env0_6.push(a0);
ensureChangeListenerCreated();
}
function removeChangeCallback(a0) { // fn#16728, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1325, offset: 0x00e58ba7, size: 64 bytes, params: 2, frame: 14
const value2 = env0_6.indexOf(a0);
if (value2 !== -1) {
env0_6.splice(value2, 1);
cleanupChangeListener();
function addCallback(a0, a1) { // fn#16720, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:813, offset: 0x00e58a98, size: 44 bytes, params: 3, frame: 12
(a0 ? env0_4 : env0_5).push(a1);
ensureChangeListenerCreated();
}
function removeCallback(a0, a1) { // fn#16721, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:885, offset: 0x00e58ac4, size: 75 bytes, params: 3, frame: 14
const r2 = a0 ? env0_4 : env0_5;
const value2 = r2.indexOf(a1);
if (value2 !== -1) {
r2.splice(value2, 1);
cleanupChangeListener();
}
}
function _fun16722({isConnected}) { // fn#16722, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1011, offset: 0x00e58b0f, size: 32 bytes, params: 2, frame: 3
const r1 = isConnected != null && isConnected;
}
function addChangeCallback(a0) { // fn#16727, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1228, offset: 0x00e58b87, size: 32 bytes, params: 2, frame: 12
env0_6.push(a0);
ensureChangeListenerCreated();
}
function removeChangeCallback(a0) { // fn#16728, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1325, offset: 0x00e58ba7, size: 64 bytes, params: 2, frame: 14
const value2 = env0_6.indexOf(a0);
if (value2 !== -1) {
env0_6.splice(value2, 1);
cleanupChangeListener();
}
}
function getNetworkInformation() { // fn#16729, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1477, offset: 0x00e58be7, size: 54 bytes, params: 1, frame: 11
let value = Module01460;
value = value.fetch();
return value.then(function(a0) {
return convertNetInfo(a0);
});
}
function isOnline() { // fn#16731, offset: 0x00c539ad, size: 9 bytes, params: 1, frame: 1
return env0_8;
}
}
function getNetworkInformation() { // fn#16729, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:1477, offset: 0x00e58be7, size: 54 bytes, params: 1, frame: 11
let value = importDefault(1460) /* metro dependency 1460 */;
value = value.fetch();
return value.then(function(a0) {
return convertNetInfo(a0);
});
}
function _fun16718(a0) { // fn#16718, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:771, offset: 0x00e58a60, size: 37 bytes, params: 2, frame: 13
return a0(isConnected != null && isConnected, env0_1);
}
function _fun16719(a0) { // fn#16719, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:1586:803, offset: 0x00e58a85, size: 19 bytes, params: 2, frame: 11
return a0(env0_1);
}
global.__d(_fun16713, 1459, [661, 3, 1460, 2]) /* metro module 1459, dependencies: [661, 3, 1460, 2] */;
+75 -65
View File
@@ -1,78 +1,88 @@
/* Metro module 11881; source: utils/native/NotificationUtils.tsx; dependencies: [5, 27, 11872, 661, 11875, 683, 10741, 10756, 2] */
import Module00005 from '../../by-id/module-00005.js'; /* Metro dependency 5 */
import AnalyticsUtils from '../AnalyticsUtils.tsx'; /* Metro dependency 683 */
import PushNotification from '../../lib/pushnotification/PushNotification.tsx'; /* Metro dependency 10741 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as PushNotificationPermissionStoreModule from '../../stores/native/PushNotificationPermissionStore.tsx'; /* Metro dependency 11872 */
import * as PushNotificationActionCreatorsModule from '../../actions/native/PushNotificationActionCreators.tsx'; /* Metro dependency 11875 */
function _fun91150(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#91150, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:6, offset: 0x02054069, size: 234 bytes, params: 8, frame: 20
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(5) /* metro dependency 5 */;
const env0_4 = (require(27) /* metro dependency 27 */).NativeModules;
const env0_5 = (require(11872) /* metro dependency 11872: PushNotificationPermissionStore */).PermissionStateType;
const env0_6 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
object2 = {hasPermission: hasPermission_91151, requestPermission: requestPermission,
object = {hasPermission: hasPermission_91151, requestPermission: requestPermission,
showNotification: showNotification_91156, shouldRequestNotification: true,
playNotificationSound: playNotificationSound};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/NotificationUtils.tsx');
exports.default = object2;
}
(FileImportTrackerModule).fileFinishedImporting('utils/native/NotificationUtils.tsx');
exports.default = object;
function hasPermission_91151() { // fn#91151, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:206, offset: 0x02054153, size: 47 bytes, params: 1, frame: 11
return (importDefault(10741) /* metro dependency 10741: PushNotification */).requestPermissions(function({alert,
badge, sound}) {
var r0 = alert || badge;
r0 = !r0 ? sound : r0;
return r0;
});
}
function hasPermission_91151() { // fn#91151, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:206, offset: 0x02054153, size: 47 bytes, params: 1, frame: 11
return (importDefault(10741) /* metro dependency 10741: PushNotification */).requestPermissions(function({alert,
badge, sound}) {
var r0 = alert || badge;
r0 = !r0 ? sound : r0;
return r0;
});
}
function requestPermission(a0) { // fn#91153, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:324, offset: 0x020541a5, size: 143 bytes, params: 2, frame: 18
const env0_0 = a0;
const setPushPermissionState = PushNotificationActionCreatorsModule.setPushPermissionState;
const REQUESTED = PermissionStateType.REQUESTED;
Reflect.apply(setPushPermissionState, PushNotificationActionCreatorsModule, [REQUESTED]);
const defaultImport = AnalyticsUtils;
const track = defaultImport.track;
const PERMISSIONS_REQUESTED = AnalyticEvents.PERMISSIONS_REQUESTED;
Reflect.apply(track, defaultImport, [PERMISSIONS_REQUESTED, {type: 'notification'}]);
let value = PushNotification;
value = value.requestPermissions();
value.then(_fun91154);
function _fun91154({alert, sound, badge}) { // fn#91154, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:494, offset: 0x02054234, size: 173 bytes, params: 2, frame: 18
var environment;
let r2 = alert || sound;
r2 = !r2 ? badge : r2;
const value = environment.__proto__;
const defaultImport = AnalyticsUtils;
const track = defaultImport.track;
const PERMISSIONS_ACKED = AnalyticEvents.PERMISSIONS_ACKED;
Reflect.apply(track, defaultImport, [PERMISSIONS_ACKED, {type: 'notification', action: r2 ? 'accepted' : 'denied'}]);
const NativePermissionManager = NativeModules.NativePermissionManager;
NativePermissionManager.getNotificationAuthorizationStatus().then(_fun91155);
if (r2 != null) {
if (env0_0 != null) {
env0_0(r2);
}
}
function _fun91155(a0) { // fn#91155, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:693, offset: 0x020542e1, size: 49 bytes, params: 2, frame: 12
var value;
if (a0 != null) {
value = environment.__proto__.__proto__;
value = require(11875) /* metro dependency 11875: PushNotificationActionCreators */;
value.updateNotificationAuthorizationStatus(a0);
}
}
function requestPermission(a0) { // fn#91153, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:324, offset: 0x020541a5, size: 143 bytes, params: 2, frame: 18
const env0_0 = a0;
const pushNotificationActionCreatorsModule = require(11875) /* metro dependency 11875: PushNotificationActionCreators */;
const setPushPermissionState = pushNotificationActionCreatorsModule.setPushPermissionState;
const REQUESTED = PermissionStateType.REQUESTED;
Reflect.apply(setPushPermissionState, pushNotificationActionCreatorsModule, [REQUESTED]);
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const PERMISSIONS_REQUESTED = AnalyticEvents.PERMISSIONS_REQUESTED;
Reflect.apply(track, defaultImport, [PERMISSIONS_REQUESTED, {type: 'notification'}]);
let value = importDefault(10741) /* metro dependency 10741: PushNotification */;
value = value.requestPermissions();
value.then(_fun91154);
}
function showNotification_91156() { // fn#91156, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:804, offset: 0x02054312, size: 29 bytes, params: 1, frame: 11
return env0_3(_fun91158)();
}
function playNotificationSound(a0) { // fn#91159, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:880, offset: 0x0205433a, size: 61 bytes, params: 2, frame: 17
const value = a1;
(require(10756) /* metro dependency 10756: SoundUtils */).playSound(a0, value !== undefined ? value : 1, undefined,
a2);
}
function _fun91154({alert, sound, badge}) { // fn#91154, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:494, offset: 0x02054234, size: 173 bytes, params: 2, frame: 18
var environment;
let r2 = alert || sound;
r2 = !r2 ? badge : r2;
const value = environment.__proto__;
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const PERMISSIONS_ACKED = AnalyticEvents.PERMISSIONS_ACKED;
Reflect.apply(track, defaultImport, [PERMISSIONS_ACKED, {type: 'notification', action: r2 ? 'accepted' : 'denied'}]);
const NativePermissionManager = NativeModules.NativePermissionManager;
NativePermissionManager.getNotificationAuthorizationStatus().then(_fun91155);
if (r2 != null) {
if (env0_0 != null) {
env0_0(r2);
}
}
function showNotification_91156() { // fn#91156, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:804, offset: 0x02054312, size: 29 bytes, params: 1, frame: 11
return Module00005(_fun91158)();
}
function playNotificationSound(a0) { // fn#91159, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:880, offset: 0x0205433a, size: 61 bytes, params: 2, frame: 17
const value = a1;
(require(10756) /* metro dependency 10756: SoundUtils */).playSound(a0, value !== undefined ? value : 1, undefined,
a2);
}
}
function* _fun91158() { // fn#91158, original name: ?anon_0_, offset: 0x00c861c8, size: 15 bytes, params: 1, frame: 2
if (false) {
}
}
function _fun91155(a0) { // fn#91155, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12067:693, offset: 0x020542e1, size: 49 bytes, params: 2, frame: 12
var value;
if (a0 != null) {
value = environment.__proto__.__proto__;
value = require(11875) /* metro dependency 11875: PushNotificationActionCreators */;
value.updateNotificationAuthorizationStatus(a0);
}
}
global.__d(_fun91150, 11881, [5, 27, 11872, 661, 11875, 683, 10741, 10756,
2]) /* metro module 11881, dependencies: [5, 27, 11872, 661, 11875, 683, 10741, 10756, 2] */;
+301 -293
View File
@@ -1,316 +1,324 @@
/* Metro module 7882; source: utils/native/PremiumUpsellUtils.tsx; dependencies: [31, 1878, 661, 1880, 33, 7883, 1244, 7884, 7885, 7886, 7887, 7888, 7889, 4496, 7901, 1962, 3802, 7062, 7940, 4015, 683, 4080, 5080, 7028, 2] */
import UserStore from '../../stores/UserStore.tsx'; /* Metro dependency 1878 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as IndexNativeModule from '../../intl/index.native.tsx'; /* Metro dependency 1244 */
import * as UsePremiumTrialOfferNativeModule from '../../modules/premium/hooks/usePremiumTrialOffer.native.tsx'; /* Metro dependency 7062 */
import * as PremiumFeaturesCardsModule from '../../modules/user_settings/premium/native/PremiumFeaturesCards.tsx'; /* Metro dependency 7940 */
function _fun63186(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#63186, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:6, offset: 0x01b7424b, size: 264 bytes, params: 8, frame: 20
var object2;
const env0_0 = require;
const closure = usePremiumUpsellConfig;
const usePremiumUpsellConfig2 = usePremiumUpsellConfig;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
let value = require(661) /* metro dependency 661: Constants */;
let value = ConstantsModule;
const env0_5 = value.AnalyticEvents;
const env0_6 = value.AnalyticsObjects;
const env0_7 = value.UpsellTypes;
value = require(1880) /* metro dependency 1880: PremiumConstants */;
const env0_8 = value.PremiumSubscriptionSKUs;
const env0_9 = value.PremiumTypes;
const env0_10 = (require(33) /* metro dependency 33 */).jsx;
object2 = {handleShowUpsellAlert: handleShowUpsellAlert, usePremiumUpsellConfig: closure};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/PremiumUpsellUtils.tsx');
exports.default = object2;
object = {handleShowUpsellAlert: handleShowUpsellAlert, usePremiumUpsellConfig: usePremiumUpsellConfig2};
(FileImportTrackerModule).fileFinishedImporting('utils/native/PremiumUpsellUtils.tsx');
exports.default = object;
exports.getUpsellItems = getUpsellItems;
exports.usePremiumUpsellConfig = closure;
}
function usePremiumUpsellConfig(a0, a1, a2) { // fn#63187, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:251, offset: 0x01b74353, size: 329 bytes, params: 4, frame: 21
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
const value2 = undefined;
const value3 = (require(7062) /* metro dependency 7062: usePremiumTrialOfferNative */).usePremiumTrialOffer();
const env0_3 = value3;
const Set = global.Set;
const GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
const UPLOAD = UpsellTypes.UPLOAD;
const r6 = value3 != null && new Set([GLOBAL_EMOJI, UPLOAD]).has(a0);
const r3 = r6 && (value3 == null || value3.subscription_trial == null ? value2 : value3.subscription_trial.sku_id) === PremiumSubscriptionSKUs.TIER_0;
let binding = env0_3;
let useMemo = binding.useMemo;
const value10 = env0_3.useCallback(_fun63189, [Reflect.apply(useMemo, binding, [_fun63188, [a0, r3]]), a1, a2]);
binding = env0_3;
useMemo = binding.useMemo;
return {useTier0UpsellContent: r3, onViewAllPerks: value10, getNitroText: Reflect.apply(useMemo, binding,
[_fun63190, [r3, value3, r6]])};
}
function handleShowUpsellAlert(a0) { // fn#63191, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:1669, offset: 0x01b74811, size: 921 bytes, params: 2, frame: 19
var r5;
var r2;
var object;
var defaultImport;
var defaultImport2;
var defaultImport3;
var defaultImport4;
var defaultImport5;
var defaultImport6;
var canUseAnimatedEmojis2;
var defaultImport8;
var defaultImport9;
var defaultImport10;
var defaultImport11;
var defaultImport12;
var defaultImport13;
const initialUpsellKey = a0.initialUpsellKey;
if (a0.analyticsLocation === undefined) {
object = {};
}
if (a0.analyticsLocations === undefined) {
object = [];
}
if (a0.analyticsProperties === undefined) {
object = {};
}
const env0_4 = a0.largestFileSize;
const env0_5 = a0.imageSource;
var value;
const currentUser = UserStore.getCurrentUser();
const value3 = false;
if (currentUser == null) {
r2 = value3;
} else if (UpsellTypes.UPLOAD === initialUpsellKey) {
defaultImport13 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport13.isPremiumExactly(currentUser, PremiumTypes.TIER_2);
} else if (UpsellTypes.GLOBAL_EMOJI === initialUpsellKey) {
defaultImport12 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport12.canUseEmojisEverywhere(currentUser);
} else if (UpsellTypes.ANIMATED_AVATAR === initialUpsellKey) {
defaultImport11 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport11.canUseAnimatedAvatar(currentUser);
} else if (UpsellTypes.BADGE === initialUpsellKey) {
defaultImport10 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport10.canUseBadges(currentUser);
} else if (UpsellTypes.ANIMATED_EMOJI === initialUpsellKey) {
defaultImport9 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport9.canUseAnimatedEmojis(currentUser);
} else if (UpsellTypes.EMOJI_AUTOCOMPLETE === initialUpsellKey) {
canUseAnimatedEmojis2 = (importDefault(3802) /* metro dependency 3802: PremiumUtils */).canUseAnimatedEmojis(currentUser);
if (canUseAnimatedEmojis2) {
defaultImport8 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r5 = !defaultImport8.canUseEmojisEverywhere(currentUser);
} else {
r5 = !canUseAnimatedEmojis2;
}
r2 = r5;
} else if (UpsellTypes.CUSTOM_PROFILES === initialUpsellKey) {
defaultImport6 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport6.canUsePremiumProfileCustomization(currentUser);
} else if (UpsellTypes.APP_ICONS === initialUpsellKey) {
defaultImport5 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport5.canUsePremiumAppIcons(currentUser);
} else if (UpsellTypes.GLOBAL_STICKER === initialUpsellKey) {
defaultImport4 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport4.canUseCustomStickersEverywhere(currentUser);
} else if (UpsellTypes.PREMIUM_GUILD_PROFILE === initialUpsellKey) {
defaultImport3 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport3.canUsePremiumGuildMemberProfile(currentUser);
} else if (UpsellTypes.LONGER_MESSAGE === initialUpsellKey) {
defaultImport2 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport2.canUseIncreasedMessageLength(currentUser);
} else if (UpsellTypes.GUILD_CAP === initialUpsellKey) {
defaultImport = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport.canUseIncreasedGuildCap(currentUser);
} else {
r2 = !(UpsellTypes.STREAM_HIGH_QUALITY !== initialUpsellKey) || value3;
}
if (r2) {
if ((importDefault(7889) /* metro dependency 7889: shouldOpenPremiumUpsellActionSheet */)(a0)) {
return undefined;
}
value = importDefault(4496) /* metro dependency 4496: AlertActionCreators */;
value.openLazy({importer: importer_63192});
}
}
function getUpsellItems() { // fn#63195, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:3217, offset: 0x01b74c72, size: 1261 bytes, params: 1, frame: 24
let object3 = {};
const GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
object3.key = GLOBAL_EMOJI;
object3.image = importDefault(7883) /* metro dependency 7883 */;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
object3.activeTitle = Reflect.apply(string, intl, [t.gKtr8N]);
string = intl.string;
const N8ZRNb = t.N8ZRNb;
object3.passiveTitle = Reflect.apply(string, intl, [N8ZRNb]);
let format = intl.format;
object3.description = Reflect.apply(format, intl, [t.rf7Ixp, {}]);
const items2 = [object3];
object3 = {};
const ANIMATED_EMOJI = UpsellTypes.ANIMATED_EMOJI;
object3.key = ANIMATED_EMOJI;
object3.image = importDefault(7884) /* metro dependency 7884 */;
string = intl.string;
const F6rmyq = t.F6rmyq;
object3.activeTitle = Reflect.apply(string, intl, [F6rmyq]);
object3.passiveTitle = intl.string(t.e4cKNt);
format = intl.format;
const JxTzzb = t.JxTzzb;
object3.description = Reflect.apply(format, intl, [JxTzzb, {}]);
items2[1] = object3;
object3 = {};
const ANIMATED_AVATAR = UpsellTypes.ANIMATED_AVATAR;
object3.key = ANIMATED_AVATAR;
object3.image = importDefault(7885) /* metro dependency 7885 */;
object3.activeTitle = intl.string(t['tQh+gF']);
string = intl.string;
const HGSXTM = t.HGSXTM;
object3.passiveTitle = Reflect.apply(string, intl, [HGSXTM]);
object3.description = intl.format(t['Tso/Fn'], {});
items2[2] = object3;
object3 = {};
const UPLOAD = UpsellTypes.UPLOAD;
object3.key = UPLOAD;
object3.image = importDefault(7886) /* metro dependency 7886 */;
object3.activeTitle = intl.string(t['1EOZqw']);
object3.passiveTitle = intl.string(t.tB51W4);
format = intl.format;
const DUT5IC = t.DUT5IC;
const object4 = {};
const intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
string = intl2.string;
const Ll40SK = t.Ll40SK;
object4.maxUploadStandard = Reflect.apply(string, intl2, [Ll40SK]);
const intl3 = (require(1244) /* metro dependency 1244: indexNative */).intl;
string = intl3.string;
const EaBfeq = t.EaBfeq;
object4.maxUploadPremium = Reflect.apply(string, intl3, [EaBfeq]);
object3.description = Reflect.apply(format, intl, [DUT5IC, object4]);
items2[3] = object3;
object3 = {};
const BADGE = UpsellTypes.BADGE;
object3.key = BADGE;
object3.image = importDefault(7887) /* metro dependency 7887 */;
object3.activeTitle = intl.string(t['602BK4']);
object3.passiveTitle = intl.string(t.j0TXTX);
object3.description = intl.format(t['p7i+li'], {});
items2[4] = object3;
object3 = {};
const APP_ICONS = UpsellTypes.APP_ICONS;
object3.key = APP_ICONS;
object3.image = importDefault(7888) /* metro dependency 7888 */;
object3.activeTitle = intl.string(t['1B1Cyn']);
object3.passiveTitle = intl.string(t['1B1Cyn']);
string = intl.string;
const VL5TYT = t.VL5TYT;
object3.description = Reflect.apply(string, intl, [VL5TYT]);
items2[5] = object3;
return items2;
}
function _fun63188() { // fn#63188, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:474, offset: 0x01b7449c, size: 290 bytes, params: 1, frame: 12
const PremiumFeatureCardOrder = (require(7940) /* metro dependency 7940: PremiumFeaturesCards */).PremiumFeatureCardOrder;
if (!env0_5) {
var binding = env0_0;
var UPLOAD = UpsellTypes.UPLOAD;
if (UPLOAD === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var ANIMATED_EMOJI = UpsellTypes.ANIMATED_EMOJI;
if (ANIMATED_EMOJI === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
if (GLOBAL_EMOJI === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var GLOBAL_STICKER = UpsellTypes.GLOBAL_STICKER;
if (GLOBAL_STICKER === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var CUSTOM_PROFILES = UpsellTypes.CUSTOM_PROFILES;
if (CUSTOM_PROFILES === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var PREMIUM_GUILD_PROFILE = UpsellTypes.PREMIUM_GUILD_PROFILE;
if (PREMIUM_GUILD_PROFILE === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var APP_ICONS = UpsellTypes.APP_ICONS;
if (APP_ICONS === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var STREAM_HIGH_QUALITY = UpsellTypes.STREAM_HIGH_QUALITY;
if (STREAM_HIGH_QUALITY === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var LONGER_MESSAGE = UpsellTypes.LONGER_MESSAGE;
if (LONGER_MESSAGE !== binding) {
if (UpsellTypes.GUILD_CAP !== binding) {
UpsellTypes.ANIMATED_AVATAR;
exports.usePremiumUpsellConfig = usePremiumUpsellConfig2;
function usePremiumUpsellConfig(a0, a1, a2) { // fn#63187, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:251, offset: 0x01b74353, size: 329 bytes, params: 4, frame: 21
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
const value2 = undefined;
const value3 = (UsePremiumTrialOfferNativeModule).usePremiumTrialOffer();
const env0_3 = value3;
const Set = global.Set;
const GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
const UPLOAD = UpsellTypes.UPLOAD;
const r6 = value3 != null && new Set([GLOBAL_EMOJI, UPLOAD]).has(a0);
const r3 = r6 && (value3 == null || value3.subscription_trial == null ? value2 : value3.subscription_trial.sku_id) === PremiumSubscriptionSKUs.TIER_0;
let binding = env0_3;
let useMemo = binding.useMemo;
const value10 = env0_3.useCallback(_fun63189, [Reflect.apply(useMemo, binding, [_fun63188, [a0, r3]]), a1, a2]);
binding = env0_3;
useMemo = binding.useMemo;
return {useTier0UpsellContent: r3, onViewAllPerks: value10, getNitroText: Reflect.apply(useMemo, binding,
[_fun63190, [r3, value3, r6]])};
function _fun63188() { // fn#63188, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:474, offset: 0x01b7449c, size: 290 bytes, params: 1, frame: 12
const PremiumFeatureCardOrder = (PremiumFeaturesCardsModule).PremiumFeatureCardOrder;
if (!env0_5) {
var binding = env0_0;
var UPLOAD = UpsellTypes.UPLOAD;
if (UPLOAD === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var ANIMATED_EMOJI = UpsellTypes.ANIMATED_EMOJI;
if (ANIMATED_EMOJI === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
if (GLOBAL_EMOJI === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var GLOBAL_STICKER = UpsellTypes.GLOBAL_STICKER;
if (GLOBAL_STICKER === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var CUSTOM_PROFILES = UpsellTypes.CUSTOM_PROFILES;
if (CUSTOM_PROFILES === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var PREMIUM_GUILD_PROFILE = UpsellTypes.PREMIUM_GUILD_PROFILE;
if (PREMIUM_GUILD_PROFILE === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var APP_ICONS = UpsellTypes.APP_ICONS;
if (APP_ICONS === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var STREAM_HIGH_QUALITY = UpsellTypes.STREAM_HIGH_QUALITY;
if (STREAM_HIGH_QUALITY === binding) {
return PremiumFeatureCardOrder.TIER_2_LEADING;
}
var LONGER_MESSAGE = UpsellTypes.LONGER_MESSAGE;
if (LONGER_MESSAGE !== binding) {
if (UpsellTypes.GUILD_CAP !== binding) {
UpsellTypes.ANIMATED_AVATAR;
}
}
}
return PremiumFeatureCardOrder.TIER_0_LEADING;
}
}
return PremiumFeatureCardOrder.TIER_0_LEADING;
}
function _fun63189() { // fn#63189, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:930, offset: 0x01b745be, size: 257 bytes, params: 1, frame: 21
const bestActiveInput = require(dependencyMap[19]).getBestActiveInput();
if (bestActiveInput != null) {
bestActiveInput.closeCustomKeyboard();
}
const defaultImport = importDefault(dependencyMap[20]);
const track = defaultImport.track;
const PREMIUM_PROMOTION_OPENED = AnalyticEvents.PREMIUM_PROMOTION_OPENED;
Reflect.apply(track, defaultImport, [PREMIUM_PROMOTION_OPENED, {location: importDefault}]);
importDefault(dependencyMap[21]).hideActionSheet();
const defaultImport3 = importDefault(dependencyMap[22]);
const pushLazy = defaultImport3.pushLazy;
const value4 = require(dependencyMap[15])(dependencyMap[23], dependencyMap.paths);
const object = {};
copyDataProperties(object, importDefault, undefined);
const BUTTON_CTA = AnalyticsObjects.BUTTON_CTA;
object['object'] = BUTTON_CTA;
Reflect.apply(pushLazy, defaultImport3, [value4, {analyticsLocation: object, analyticsLocations: require ?? [],
premiumFeatureCardOrder: env0_6}]);
}
function _fun63190() { // fn#63190, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:1261, offset: 0x01b746bf, size: 338 bytes, params: 1, frame: 16
var sku_id;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
if (env0_4) {
sku_id = env0_3 == null || env0_3.subscription_trial == null ? undefined : env0_3.subscription_trial.sku_id;
value = environment.__proto__;
if (PremiumSubscriptionSKUs.TIER_0 === sku_id) {
return intl.string(t.hz78hE);
function _fun63189() { // fn#63189, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:930, offset: 0x01b745be, size: 257 bytes, params: 1, frame: 21
const bestActiveInput = require(dependencyMap[19]).getBestActiveInput();
if (bestActiveInput != null) {
bestActiveInput.closeCustomKeyboard();
}
const defaultImport = importDefault(dependencyMap[20]);
const track = defaultImport.track;
const PREMIUM_PROMOTION_OPENED = AnalyticEvents.PREMIUM_PROMOTION_OPENED;
Reflect.apply(track, defaultImport, [PREMIUM_PROMOTION_OPENED, {location: importDefault}]);
importDefault(dependencyMap[21]).hideActionSheet();
const defaultImport3 = importDefault(dependencyMap[22]);
const pushLazy = defaultImport3.pushLazy;
const value4 = require(dependencyMap[15])(dependencyMap[23], dependencyMap.paths);
const object2 = {};
copyDataProperties(object2, importDefault, undefined);
const BUTTON_CTA = AnalyticsObjects.BUTTON_CTA;
object2['object'] = BUTTON_CTA;
Reflect.apply(pushLazy, defaultImport3, [value4, {analyticsLocation: object2, analyticsLocations: require ?? [],
premiumFeatureCardOrder: env0_6}]);
}
if (PremiumSubscriptionSKUs.TIER_2 === sku_id) {
return intl.string(t['Gd/XHF']);
function _fun63190() { // fn#63190, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:1261, offset: 0x01b746bf, size: 338 bytes, params: 1, frame: 16
var sku_id;
const intl = (IndexNativeModule).intl;
const t = (IndexNativeModule).t;
if (env0_4) {
sku_id = env0_3 == null || env0_3.subscription_trial == null ? undefined : env0_3.subscription_trial.sku_id;
value = environment.__proto__;
if (PremiumSubscriptionSKUs.TIER_0 === sku_id) {
return intl.string(t.hz78hE);
}
if (PremiumSubscriptionSKUs.TIER_2 === sku_id) {
return intl.string(t['Gd/XHF']);
}
value = environment.__proto__;
} else if (env0_5) {
value = environment.__proto__;
return intl.string(t['9CM5v9']);
}
return intl.string(t.pj0XBN);
}
value = environment.__proto__;
} else if (env0_5) {
value = environment.__proto__;
return intl.string(t['9CM5v9']);
}
return intl.string(t.pj0XBN);
}
function handleShowUpsellAlertImporter() { // fn#63192, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2887, owner: handleShowUpsellAlert.importer, offset: 0x01b74baa, size: 62 bytes, params: 1, frame: 13
var environment;
let value = environment.__proto__;
value = require(dependencyMap[15]);
value = value(dependencyMap[14], dependencyMap.paths);
return value.then(function({default: env0_0}) {
return _fun63194;
});
}
function handleShowUpsellAlert(a0) { // fn#63191, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:1669, offset: 0x01b74811, size: 921 bytes, params: 2, frame: 19
var r5;
var r2;
var object;
var defaultImport;
var defaultImport2;
var defaultImport3;
var defaultImport4;
var defaultImport5;
var defaultImport6;
var canUseAnimatedEmojis2;
var defaultImport8;
var defaultImport9;
var defaultImport10;
var defaultImport11;
var defaultImport12;
var defaultImport13;
const initialUpsellKey = a0.initialUpsellKey;
if (a0.analyticsLocation === undefined) {
object = {};
}
if (a0.analyticsLocations === undefined) {
object = [];
}
if (a0.analyticsProperties === undefined) {
object = {};
}
const env0_4 = a0.largestFileSize;
const env0_5 = a0.imageSource;
var value;
const currentUser = UserStore.getCurrentUser();
const value3 = false;
if (currentUser == null) {
r2 = value3;
} else if (UpsellTypes.UPLOAD === initialUpsellKey) {
defaultImport13 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport13.isPremiumExactly(currentUser, PremiumTypes.TIER_2);
} else if (UpsellTypes.GLOBAL_EMOJI === initialUpsellKey) {
defaultImport12 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport12.canUseEmojisEverywhere(currentUser);
} else if (UpsellTypes.ANIMATED_AVATAR === initialUpsellKey) {
defaultImport11 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport11.canUseAnimatedAvatar(currentUser);
} else if (UpsellTypes.BADGE === initialUpsellKey) {
defaultImport10 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport10.canUseBadges(currentUser);
} else if (UpsellTypes.ANIMATED_EMOJI === initialUpsellKey) {
defaultImport9 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport9.canUseAnimatedEmojis(currentUser);
} else if (UpsellTypes.EMOJI_AUTOCOMPLETE === initialUpsellKey) {
canUseAnimatedEmojis2 = (importDefault(3802) /* metro dependency 3802: PremiumUtils */).canUseAnimatedEmojis(currentUser);
if (canUseAnimatedEmojis2) {
defaultImport8 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r5 = !defaultImport8.canUseEmojisEverywhere(currentUser);
} else {
r5 = !canUseAnimatedEmojis2;
}
r2 = r5;
} else if (UpsellTypes.CUSTOM_PROFILES === initialUpsellKey) {
defaultImport6 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport6.canUsePremiumProfileCustomization(currentUser);
} else if (UpsellTypes.APP_ICONS === initialUpsellKey) {
defaultImport5 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport5.canUsePremiumAppIcons(currentUser);
} else if (UpsellTypes.GLOBAL_STICKER === initialUpsellKey) {
defaultImport4 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport4.canUseCustomStickersEverywhere(currentUser);
} else if (UpsellTypes.PREMIUM_GUILD_PROFILE === initialUpsellKey) {
defaultImport3 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport3.canUsePremiumGuildMemberProfile(currentUser);
} else if (UpsellTypes.LONGER_MESSAGE === initialUpsellKey) {
defaultImport2 = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport2.canUseIncreasedMessageLength(currentUser);
} else if (UpsellTypes.GUILD_CAP === initialUpsellKey) {
defaultImport = importDefault(3802) /* metro dependency 3802: PremiumUtils */;
r2 = !defaultImport.canUseIncreasedGuildCap(currentUser);
} else {
r2 = !(UpsellTypes.STREAM_HIGH_QUALITY !== initialUpsellKey) || value3;
}
if (r2) {
if ((importDefault(7889) /* metro dependency 7889: shouldOpenPremiumUpsellActionSheet */)(a0)) {
return undefined;
}
value = importDefault(4496) /* metro dependency 4496: AlertActionCreators */;
value.openLazy({importer: importer_63192});
}
function handleShowUpsellAlertImporter() { // fn#63192, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2887, owner: handleShowUpsellAlert.importer, offset: 0x01b74baa, size: 62 bytes, params: 1, frame: 13
var environment;
let value = environment.__proto__;
value = require(dependencyMap[15]);
value = value(dependencyMap[14], dependencyMap.paths);
return value.then(function({default: env0_0}) {
return _fun63194;
});
function _fun63193({default: env0_0}) { // fn#63193, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2921, offset: 0x01b74be8, size: 21 bytes, params: 2, frame: 2
return _fun63194;
function _fun63194(a0) { // fn#63194, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2936, offset: 0x01b74bfd, size: 117 bytes, params: 2, frame: 15
return ((Component) => <Component {...a0} {...{['initialUpsellKey']: initialUpsellKey}} {...{['analyticsLocation']: env2_1}} {...{['analyticsProperties']: env2_3}} {...{['analyticsLocations']: env2_2}} {...{['largestFileSize']: largestFileSize}} {...{['imageSource']: imageSource}} />)(env0_0);
}
function _fun63193({default: env0_0}) { // fn#63193, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2921, offset: 0x01b74be8, size: 21 bytes, params: 2, frame: 2
return _fun63194;
}
}
}
}
function getUpsellItems() { // fn#63195, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:3217, offset: 0x01b74c72, size: 1261 bytes, params: 1, frame: 24
let object = {};
const GLOBAL_EMOJI = UpsellTypes.GLOBAL_EMOJI;
object.key = GLOBAL_EMOJI;
object.image = importDefault(7883) /* metro dependency 7883 */;
const intl = (IndexNativeModule).intl;
let string = intl.string;
const t = (IndexNativeModule).t;
object.activeTitle = Reflect.apply(string, intl, [t.gKtr8N]);
string = intl.string;
const N8ZRNb = t.N8ZRNb;
object.passiveTitle = Reflect.apply(string, intl, [N8ZRNb]);
let format = intl.format;
object.description = Reflect.apply(format, intl, [t.rf7Ixp, {}]);
const items2 = [object];
object = {};
const ANIMATED_EMOJI = UpsellTypes.ANIMATED_EMOJI;
object.key = ANIMATED_EMOJI;
object.image = importDefault(7884) /* metro dependency 7884 */;
string = intl.string;
const F6rmyq = t.F6rmyq;
object.activeTitle = Reflect.apply(string, intl, [F6rmyq]);
object.passiveTitle = intl.string(t.e4cKNt);
format = intl.format;
const JxTzzb = t.JxTzzb;
object.description = Reflect.apply(format, intl, [JxTzzb, {}]);
items2[1] = object;
object = {};
const ANIMATED_AVATAR = UpsellTypes.ANIMATED_AVATAR;
object.key = ANIMATED_AVATAR;
object.image = importDefault(7885) /* metro dependency 7885 */;
object.activeTitle = intl.string(t['tQh+gF']);
string = intl.string;
const HGSXTM = t.HGSXTM;
object.passiveTitle = Reflect.apply(string, intl, [HGSXTM]);
object.description = intl.format(t['Tso/Fn'], {});
items2[2] = object;
object = {};
const UPLOAD = UpsellTypes.UPLOAD;
object.key = UPLOAD;
object.image = importDefault(7886) /* metro dependency 7886 */;
object.activeTitle = intl.string(t['1EOZqw']);
object.passiveTitle = intl.string(t.tB51W4);
format = intl.format;
const DUT5IC = t.DUT5IC;
const object2 = {};
const intl2 = (IndexNativeModule).intl;
string = intl2.string;
const Ll40SK = t.Ll40SK;
object2.maxUploadStandard = Reflect.apply(string, intl2, [Ll40SK]);
const intl3 = (IndexNativeModule).intl;
string = intl3.string;
const EaBfeq = t.EaBfeq;
object2.maxUploadPremium = Reflect.apply(string, intl3, [EaBfeq]);
object.description = Reflect.apply(format, intl, [DUT5IC, object2]);
items2[3] = object;
object = {};
const BADGE = UpsellTypes.BADGE;
object.key = BADGE;
object.image = importDefault(7887) /* metro dependency 7887 */;
object.activeTitle = intl.string(t['602BK4']);
object.passiveTitle = intl.string(t.j0TXTX);
object.description = intl.format(t['p7i+li'], {});
items2[4] = object;
object = {};
const APP_ICONS = UpsellTypes.APP_ICONS;
object.key = APP_ICONS;
object.image = importDefault(7888) /* metro dependency 7888 */;
object.activeTitle = intl.string(t['1B1Cyn']);
object.passiveTitle = intl.string(t['1B1Cyn']);
string = intl.string;
const VL5TYT = t.VL5TYT;
object.description = Reflect.apply(string, intl, [VL5TYT]);
items2[5] = object;
return items2;
}
function _fun63194(a0) { // fn#63194, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8060:2936, offset: 0x01b74bfd, size: 117 bytes, params: 2, frame: 15
return ((Component) => <Component {...a0} {...{['initialUpsellKey']: initialUpsellKey}} {...{['analyticsLocation']: env2_1}} {...{['analyticsProperties']: env2_3}} {...{['analyticsLocations']: env2_2}} {...{['largestFileSize']: largestFileSize}} {...{['imageSource']: imageSource}} />)(env0_0);
}
global.__d(_fun63186, 7882, [31, 1878, 661, 1880, 33, 7883, 1244, 7884, 7885, 7886, 7887, 7888, 7889, 4496, 7901,
1962, 3802, 7062, 7940, 4015, 683, 4080, 5080, 7028,
2]) /* metro module 7882, dependencies: [31, 1878, 661, 1880, 33, 7883, 1244, 7884, 7885, 7886, 7887, 7888, 7889, 4496, 7901, 1962, 3802, 7062, 7940, 4015, 683, 4080, 5080, 7028, 2] */;
+381 -328
View File
@@ -1,19 +1,38 @@
/* Metro module 7709; source: utils/native/PrivateChannelCallUtils.tsx; dependencies: [5, 31, 3849, 7710, 1379, 3793, 1934, 1878, 661, 1229, 4661, 33, 5072, 7712, 7713, 1239, 5080, 7714, 1962, 5459, 5075, 4080, 12084, 4796, 4496, 1244, 4662, 4015, 12120, 4497, 8916, 4007, 8114, 2] */
import Module00005 from '../../by-id/module-00005.js'; /* Metro dependency 5 */
import ChannelStore from '../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
import UserStore from '../../stores/UserStore.tsx'; /* Metro dependency 1878 */
import SelectedChannelStore from '../../stores/SelectedChannelStore.tsx'; /* Metro dependency 1934 */
import RelationshipStore from '../../stores/RelationshipStore.tsx'; /* Metro dependency 3793 */
import ActionSheetStore from '../../modules/action_sheet/native/ActionSheetStore.tsx'; /* Metro dependency 3849 */
import AlertActionCreators from '../../actions/native/AlertActionCreators.tsx'; /* Metro dependency 4496 */
import SelectedChannelActionCreators from '../../actions/SelectedChannelActionCreators.tsx'; /* Metro dependency 4796 */
import ModalActionCreators from '../../actions/ModalActionCreators.tsx'; /* Metro dependency 5080 */
import VoicePanelStore from '../../modules/voice_panel/VoicePanelStore.tsx'; /* Metro dependency 7710 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
import * as AgeGateConstantsModule from '../../modules/age_gate/AgeGateConstants.tsx'; /* Metro dependency 1229 */
import * as IndexNativeModule from '../../intl/index.native.tsx'; /* Metro dependency 1244 */
import * as NativePermissionConstantsModule from '../../modules/native_permissions/NativePermissionConstants.tsx'; /* Metro dependency 4661 */
import * as AgeGateUtilsModule from '../../modules/age_gate/AgeGateUtils.tsx'; /* Metro dependency 5072 */
function _fun61571(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#61571, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:6, offset: 0x01b4599f, size: 554 bytes, params: 8, frame: 26
const env0_0 = require;
const closure = function(a0) {
return getVoiceChannelKeyByChannelId(a0);
};
const closure2 = openChannelCallModal;
const closure3 = dismissVoiceChannelScreens;
const openChannelCallModal2 = openChannelCallModal;
const dismissVoiceChannelScreens2 = dismissVoiceChannelScreens;
const closure4 = function() {
var Promise = global.Promise;
var value = Object.create(Promise.prototype, {constructor: {value: Promise}});
var value2 = new Promise(_fun61576);
return value2 instanceof Object ? value2 : value;
};
const closure5 = showGuardCallAlert;
const closure6 = guardPrivateCallForChannel;
const showGuardCallAlert2 = showGuardCallAlert;
const guardPrivateCallForChannel2 = guardPrivateCallForChannel;
const closure7 = function(a0, a1) {
if (!require(dependencyMap[31]).isModalOpen(getVoiceChannelKey(a0.id))) {
openChannelCallModal(a0);
@@ -21,40 +40,25 @@ function _fun61571(global, require, importDefault, importAll, module, exports, d
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(5) /* metro dependency 5 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
const actionSheetStore = importDefault(3849) /* metro dependency 3849: ActionSheetStore */;
const voicePanelStore = importDefault(7710) /* metro dependency 7710: VoicePanelStore */;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const relationshipStore = importDefault(3793) /* metro dependency 3793: RelationshipStore */;
const selectedChannelStore = importDefault(1934) /* metro dependency 1934: SelectedChannelStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const constantsModule = require(661) /* metro dependency 661: Constants */;
const env0_11 = constantsModule.ChannelTypes;
const env0_12 = constantsModule.ComponentActions;
const env0_13 = constantsModule.NOOP;
const env0_14 = (require(1229) /* metro dependency 1229: AgeGateConstants */).AgeGateSource;
const env0_15 = (require(4661) /* metro dependency 4661: NativePermissionConstants */).NativePermissionTypes;
const env0_16 = (require(33) /* metro dependency 33 */).jsx;
const closure8 = function(a0) {
return '' + 'voice-channel' + '-' + a0;
};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/PrivateChannelCallUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/PrivateChannelCallUtils.tsx');
exports.getVoiceChannelKeyByChannelId = closure8;
exports.getVoiceChannelKey = closure;
exports.isVoiceChannelModalKey = function(a0) {
return a0.startsWith('voice-channel');
};
exports.openChannelCallModal = closure2;
exports.openChannelCallModal = openChannelCallModal2;
exports.maybeShowAgeGateModal = maybeShowAgeGateModal;
exports.openVoiceChannelActionSheet = openVoiceChannelActionSheet;
exports.hideVoiceChannelActionSheet = function(a0) {
importDefault(dependencyMap[21]).hideActionSheet(getVoiceChannelKey(a0.id));
};
exports.dismissVoiceChannelScreens = closure3;
exports.dismissVoiceChannelScreens = dismissVoiceChannelScreens2;
exports.monkeyPatchCall = closure4;
exports.showGuardCallAlert = closure5;
exports.guardPrivateCallForChannel = closure6;
exports.showGuardCallAlert = showGuardCallAlert2;
exports.guardPrivateCallForChannel = guardPrivateCallForChannel2;
exports.handleJoinCall = handleJoinCall;
exports.handleStartCall = handleStartCall;
exports.handleRedesignGroupDMCall = handleRedesignGroupDMCall;
@@ -69,340 +73,389 @@ function _fun61571(global, require, importDefault, importAll, module, exports, d
openGuildVoiceModal(a0);
}
};
}
function openChannelCallModal(a0) { // fn#61573, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:439, offset: 0x01b45bdc, size: 289 bytes, params: 2, frame: 19
var moduleValue2;
var defaultImport2;
var state;
var openChannel;
var ComponentDispatch;
var dispatch;
var VOICE_PANEL_OPEN;
const moduleValue = require(dependencyMap[12]);
const maybeOpenAgeGateForVoiceChannel = moduleValue.maybeOpenAgeGateForVoiceChannel;
let id = a0.id;
if (!Reflect.apply(maybeOpenAgeGateForVoiceChannel, moduleValue, [id])) {
importDefault(dependencyMap[13]).rebuildRTCActiveChannels();
moduleValue2 = require(dependencyMap[14]);
if (moduleValue2.isVoicePanelEnabled(a0)) {
state = VoicePanelStore.getState();
openChannel = state.openChannel;
id = a0.id;
Reflect.apply(openChannel, state, [id]);
ComponentDispatch = require(dependencyMap[15]).ComponentDispatch;
dispatch = ComponentDispatch.dispatch;
VOICE_PANEL_OPEN = ComponentActions.VOICE_PANEL_OPEN;
id = a0.id;
Reflect.apply(dispatch, ComponentDispatch, [VOICE_PANEL_OPEN, {channelId: id}]);
} else {
defaultImport2 = importDefault(dependencyMap[16]);
defaultImport2.pushLazy(require(dependencyMap[18])(dependencyMap[17], dependencyMap.paths), {channel: a0},
getVoiceChannelKey(a0.id));
function openChannelCallModal(a0) { // fn#61573, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:439, offset: 0x01b45bdc, size: 289 bytes, params: 2, frame: 19
var moduleValue2;
var defaultImport2;
var state;
var openChannel;
var ComponentDispatch;
var dispatch;
var VOICE_PANEL_OPEN;
const moduleValue = require(dependencyMap[12]);
const maybeOpenAgeGateForVoiceChannel = moduleValue.maybeOpenAgeGateForVoiceChannel;
let id = a0.id;
if (!Reflect.apply(maybeOpenAgeGateForVoiceChannel, moduleValue, [id])) {
importDefault(dependencyMap[13]).rebuildRTCActiveChannels();
moduleValue2 = require(dependencyMap[14]);
if (moduleValue2.isVoicePanelEnabled(a0)) {
state = VoicePanelStore.getState();
openChannel = state.openChannel;
id = a0.id;
Reflect.apply(openChannel, state, [id]);
ComponentDispatch = require(dependencyMap[15]).ComponentDispatch;
dispatch = ComponentDispatch.dispatch;
VOICE_PANEL_OPEN = ComponentActions.VOICE_PANEL_OPEN;
id = a0.id;
Reflect.apply(dispatch, ComponentDispatch, [VOICE_PANEL_OPEN, {channelId: id}]);
} else {
defaultImport2 = importDefault(dependencyMap[16]);
defaultImport2.pushLazy(require(dependencyMap[18])(dependencyMap[17], dependencyMap.paths), {channel: a0},
getVoiceChannelKey(a0.id));
}
}
}
}
function dismissVoiceChannelScreens({id}, a1) { // fn#61574, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:776, offset: 0x01b45cfd, size: 107 bytes, params: 3, frame: 15
const voiceChannelKey = getVoiceChannelKey(id);
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popWithKey(voiceChannelKey, a1);
const getKey = ActionSheetStore.getKey;
if (Reflect.apply(getKey, ActionSheetStore, []) === voiceChannelKey) {
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
function dismissVoiceChannelScreens({id}, a1) { // fn#61574, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:776, offset: 0x01b45cfd, size: 107 bytes, params: 3, frame: 15
const voiceChannelKey = getVoiceChannelKey(id);
(ModalActionCreators).popWithKey(voiceChannelKey, a1);
const actionSheetStoreBinding = ActionSheetStore;
const getKey = actionSheetStoreBinding.getKey;
if (Reflect.apply(getKey, actionSheetStoreBinding, []) === voiceChannelKey) {
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
}
}
}
function monkeyPatchCall() { // fn#61575, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:916, offset: 0x01b45d68, size: 37 bytes, params: 1, frame: 11
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun61576);
return promise instanceof Object ? promise : value;
}
function monkeyPatchCall() { // fn#61575, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:916, offset: 0x01b45d68, size: 37 bytes, params: 1, frame: 11
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun61576);
return promise instanceof Object ? promise : value;
function _fun61576(a0) { // fn#61576, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:963, offset: 0x01b45d8d, size: 106 bytes, params: 2, frame: 14
const value = environment.__proto__;
const channel = ChannelStore.getChannel(SelectedChannelStore.getVoiceChannelId());
if (channel != null) {
dismissVoiceChannelScreens(channel);
}
(SelectedChannelActionCreators).selectVoiceChannel(null);
global.setTimeout(a0, 500);
}
function showGuardCallAlert(a0) { // fn#61577, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1107, offset: 0x01b45df7, size: 224 bytes, params: 2, frame: 20
const env0_0 = a0;
const defaultImport = importDefault(4496) /* metro dependency 4496: AlertActionCreators */;
const show = defaultImport.show;
const object2 = {};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
object2.title = Reflect.apply(string, intl, [t['91WuJ9']]);
object2.body = intl.string(t['Rs+Vk1']);
object2.cancelText = intl.string(t['ETE/oC']);
object2.onConfirm = onConfirm;
object2.onCancel = NOOP;
Reflect.apply(show, defaultImport, [object2]);
}
function guardPrivateCallForChannel(a0, a1) { // fn#61579, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1335, offset: 0x01b45ed7, size: 123 bytes, params: 3, frame: 16
const env0_0 = a1;
const channel = ChannelStore.getChannel(SelectedChannelStore.getVoiceChannelId());
if (channel == null) {
a1();
} else if (channel.type === ChannelTypes.GUILD_VOICE) {
a1();
} else if (a0 == null) {
a1();
} else if (a0.id !== channel.id) {
showGuardCallAlert(env0_3(_fun61581));
} else {
a1();
}
}
function maybeShowAgeGateModal(a0) { // fn#61585, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1989, offset: 0x01b4600d, size: 86 bytes, params: 2, frame: 14
const ageGateUtilsModule = require(5072) /* metro dependency 5072: AgeGateUtils */;
if (ageGateUtilsModule.shouldShowAgeGateForChannelId(a0)) {
(require(5459) /* metro dependency 5459: RunAfterInteractionsUtils */).runAfterInteractions(function() {
require(dependencyMap[20]).openAgeGateModal(AgeGateSource.NSFW_VOICE_CHANNEL);
}, 150);
function showGuardCallAlert(a0) { // fn#61577, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1107, offset: 0x01b45df7, size: 224 bytes, params: 2, frame: 20
const env0_0 = a0;
const defaultImport = AlertActionCreators;
const show = defaultImport.show;
const object = {};
const intl = (IndexNativeModule).intl;
const string = intl.string;
const t = (IndexNativeModule).t;
object.title = Reflect.apply(string, intl, [t['91WuJ9']]);
object.body = intl.string(t['Rs+Vk1']);
object.cancelText = intl.string(t['ETE/oC']);
object.onConfirm = onConfirm_61578;
object.onCancel = NOOP;
Reflect.apply(show, defaultImport, [object]);
function showGuardCallAlertOnConfirm() { // fn#61578, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1314, owner: showGuardCallAlert.onConfirm, offset: 0x00cefeb4, size: 15 bytes, params: 1, frame: 9
return env0_0();
}
}
}
function openVoiceChannelActionSheet(a0) { // fn#61587, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2188, offset: 0x01b46093, size: 97 bytes, params: 2, frame: 18
const defaultImport = importDefault(dependencyMap[21]);
defaultImport.openLazy(require(dependencyMap[18])(dependencyMap[22], dependencyMap.paths),
getVoiceChannelKey(a0.id), {channel: a0});
}
function guardPrivateCallForChannel(a0, a1) { // fn#61579, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1335, offset: 0x01b45ed7, size: 123 bytes, params: 3, frame: 16
const env0_0 = a1;
const channel = ChannelStore.getChannel(SelectedChannelStore.getVoiceChannelId());
if (channel == null) {
a1();
} else if (channel.type === ChannelTypes.GUILD_VOICE) {
a1();
} else if (a0 == null) {
a1();
} else if (a0.id !== channel.id) {
showGuardCallAlert(Module00005(_fun61581));
} else {
a1();
}
function* _fun61581() { // fn#61581, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1498, offset: 0x01b45f5b, size: 50 bytes, params: 1, frame: 11
if (true) {
value = environment.__proto__.__proto__;
yield env2_21();
if (false) {
return undefined;
}
value = environment.__proto__;
require();
}
}
function handleJoinCall(a0) { // fn#61589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2634, offset: 0x01b4612b, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm.apply(this, arguments);
});
}
}
function handleStartCall(a0) { // fn#61594, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2982, offset: 0x01b46243, size: 66 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
if (!guardAgainstCallingProvisionalAccount(a0)) {
function maybeShowAgeGateModal(a0) { // fn#61585, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1989, offset: 0x01b4600d, size: 86 bytes, params: 2, frame: 14
if (AgeGateUtilsModule.shouldShowAgeGateForChannelId(a0)) {
(require(5459) /* metro dependency 5459: RunAfterInteractionsUtils */).runAfterInteractions(function() {
require(dependencyMap[20]).openAgeGateModal(AgeGateSource.NSFW_VOICE_CHANNEL);
}, 150);
}
}
function openVoiceChannelActionSheet(a0) { // fn#61587, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2188, offset: 0x01b46093, size: 97 bytes, params: 2, frame: 18
const defaultImport = importDefault(dependencyMap[21]);
defaultImport.openLazy(require(dependencyMap[18])(dependencyMap[22], dependencyMap.paths),
getVoiceChannelKey(a0.id), {channel: a0});
}
function handleJoinCall(a0) { // fn#61589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2634, offset: 0x01b4612b, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm2.apply(this, arguments);
return _onConfirm.apply(this, arguments);
});
}
}
function _onConfirm() { // fn#61590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2666, owner: handleJoinCall._onConfirm, offset: 0x01b46160, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61592).apply(this, arguments);
function* _fun61592() { // fn#61592, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2709, offset: 0x01b4619c, size: 167 bytes, params: 1, frame: 17
var value3;
var binding;
var value4;
var value5;
var value7;
var binding2;
var value9;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
return undefined;
}
} else {
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
}
}
}
function handleRedesignGroupDMCall(a0) { // fn#61601, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3689, offset: 0x01b46493, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm3.apply(this, arguments);
});
}
function handleRedesignJoinCall(a0) { // fn#61606, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:4047, offset: 0x01b465ad, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm4.apply(this, arguments);
});
}
function _fun61576(a0) { // fn#61576, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:963, offset: 0x01b45d8d, size: 106 bytes, params: 2, frame: 14
const value = environment.__proto__;
const channel = ChannelStore.getChannel(SelectedChannelStore.getVoiceChannelId());
if (channel != null) {
dismissVoiceChannelScreens(channel);
}
(importDefault(4796) /* metro dependency 4796: SelectedChannelActionCreators */).selectVoiceChannel(null);
global.setTimeout(a0, 500);
}
function* _fun61581() { // fn#61581, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:1498, offset: 0x01b45f5b, size: 50 bytes, params: 1, frame: 11
if (true) {
value = environment.__proto__.__proto__;
yield env2_21();
if (false) {
return undefined;
}
value = environment.__proto__;
require();
}
}
function _onConfirm() { // fn#61590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2666, owner: handleJoinCall._onConfirm, offset: 0x01b46160, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61592).apply(this, arguments);
}
function handleStartCall(a0) { // fn#61594, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2982, offset: 0x01b46243, size: 66 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
if (!guardAgainstCallingProvisionalAccount(a0)) {
guardPrivateCallForChannel(a0, function() {
return _onConfirm2.apply(this, arguments);
});
}
function _onConfirm2() { // fn#61595, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3015, owner: handleStartCall._onConfirm2, offset: 0x01b46285, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61597).apply(this, arguments);
function* _fun61597() { // fn#61597, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3060, offset: 0x01b462c1, size: 280 bytes, params: 1, frame: 22
var r8;
var r7;
var value3;
var binding;
var value4;
var value5;
var value7;
var value12;
var call;
var id;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding(env3_2[27]).dismissKeyboard();
r8 = require.type !== env3_11.DM || env3_8.isFriend(require.getRecipientId());
r7 = r8 ? null : require.getRecipientId();
binding = env3_1;
value12 = binding(env3_2[30]);
call = value12.call;
id = require.id;
r8 = r8 && !require.isManaged();
Reflect.apply(call, value12, [id, importDefault, r8, r7]);
return undefined;
}
} else {
binding = env3_0;
binding(env3_2[27]).dismissKeyboard();
r8 = require.type !== env3_11.DM || env3_8.isFriend(require.getRecipientId());
r7 = r8 ? null : require.getRecipientId();
binding = env3_1;
value12 = binding(env3_2[30]);
call = value12.call;
id = require.id;
r8 = r8 && !require.isManaged();
Reflect.apply(call, value12, [id, importDefault, r8, r7]);
}
}
}
function _onConfirm2() { // fn#61595, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3015, owner: handleStartCall._onConfirm2, offset: 0x01b46285, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61597).apply(this, arguments);
}
}
function guardAgainstCallingProvisionalAccount(a0) { // fn#61598, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3307, owner: handleStartCall.guardAgainstCallingProvisionalAccount, offset: 0x01b463d9, size: 141 bytes, params: 2, frame: 15
var environment;
var value;
var value2;
if (a0.isDM()) {
value = environment.__proto__;
value2 = UserStore.getUser(a0.getRecipientId());
if (value2 == null) {
function guardAgainstCallingProvisionalAccount(a0) { // fn#61598, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3307, owner: handleStartCall.guardAgainstCallingProvisionalAccount, offset: 0x01b463d9, size: 141 bytes, params: 2, frame: 15
var environment;
var value;
var userStoreBinding;
var value2;
if (a0.isDM()) {
value = environment.__proto__;
userStoreBinding = UserStore;
value2 = userStoreBinding.getUser(a0.getRecipientId());
if (value2 == null) {
return false;
}
if (value2.isProvisional) {
(require(4497) /* metro dependency 4497: useAlertStoreNative */).openAlert('ProvisionalAccountNocallAllowed',
((Component) => <Component />)(env1_4.lazy(_fun61599)));
return true;
}
}
return false;
function _fun61599() { // fn#61599, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3448, offset: 0x01b46466, size: 45 bytes, params: 1, frame: 13
const value = environment.__proto__.__proto__;
return require(dependencyMap[18])(dependencyMap[28], dependencyMap.paths);
}
}
if (value2.isProvisional) {
(require(4497) /* metro dependency 4497: useAlertStoreNative */).openAlert('ProvisionalAccountNocallAllowed',
((Component) => <Component />)(env1_4.lazy(_fun61599)));
return true;
}
}
return false;
}
function _onConfirm3() { // fn#61602, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3732, owner: handleRedesignGroupDMCall._onConfirm3, offset: 0x01b464c8, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61604).apply(this, arguments);
}
function _onConfirm4() { // fn#61607, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:4087, owner: handleRedesignJoinCall._onConfirm4, offset: 0x01b465e2, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61609).apply(this, arguments);
}
function* _fun61592() { // fn#61592, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:2709, offset: 0x01b4619c, size: 167 bytes, params: 1, frame: 17
var value3;
var binding;
var value4;
var value5;
var value7;
var binding2;
var value9;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
function handleRedesignGroupDMCall(a0) { // fn#61601, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3689, offset: 0x01b46493, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm3.apply(this, arguments);
});
function _onConfirm3() { // fn#61602, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3732, owner: handleRedesignGroupDMCall._onConfirm3, offset: 0x01b464c8, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61604).apply(this, arguments);
function* _fun61604() { // fn#61604, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3777, offset: 0x01b46504, size: 169 bytes, params: 1, frame: 18
var value3;
var binding;
var value4;
var value5;
var value7;
var binding2;
var value9;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[30]);
value9.call(require.id, importDefault, true);
return undefined;
}
} else {
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[30]);
value9.call(require.id, importDefault, true);
}
}
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
return undefined;
}
} else {
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
}
}
}
function* _fun61597() { // fn#61597, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3060, offset: 0x01b462c1, size: 280 bytes, params: 1, frame: 22
var r8;
var r7;
var value3;
var binding;
var value4;
var value5;
var value7;
var value12;
var call;
var id;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
function handleRedesignJoinCall(a0) { // fn#61606, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:4047, offset: 0x01b465ad, size: 53 bytes, params: 2, frame: 14
const value = a1;
const env0_0 = a0;
const env0_1 = value !== undefined ? value : false;
guardPrivateCallForChannel(a0, function() {
return _onConfirm4.apply(this, arguments);
});
function _onConfirm4() { // fn#61607, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:4087, owner: handleRedesignJoinCall._onConfirm4, offset: 0x01b465e2, size: 51 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun61609).apply(this, arguments);
function* _fun61609() { // fn#61609, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:4132, offset: 0x01b4619c, size: 167 bytes, params: 1, frame: 17
var value3;
var binding;
var value4;
var value5;
var value7;
var binding2;
var value9;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
return undefined;
}
} else {
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[23]);
value9.selectVoiceChannel(require.id, importDefault);
}
}
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding(env3_2[27]).dismissKeyboard();
r8 = require.type !== env3_11.DM || env3_8.isFriend(require.getRecipientId());
r7 = r8 ? null : require.getRecipientId();
binding = env3_1;
value12 = binding(env3_2[30]);
call = value12.call;
id = require.id;
r8 = r8 && !require.isManaged();
Reflect.apply(call, value12, [id, importDefault, r8, r7]);
return undefined;
}
} else {
binding = env3_0;
binding(env3_2[27]).dismissKeyboard();
r8 = require.type !== env3_11.DM || env3_8.isFriend(require.getRecipientId());
r7 = r8 ? null : require.getRecipientId();
binding = env3_1;
value12 = binding(env3_2[30]);
call = value12.call;
id = require.id;
r8 = r8 && !require.isManaged();
Reflect.apply(call, value12, [id, importDefault, r8, r7]);
}
}
}
function _fun61599() { // fn#61599, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3448, offset: 0x01b46466, size: 45 bytes, params: 1, frame: 13
const value = environment.__proto__.__proto__;
return require(dependencyMap[18])(dependencyMap[28], dependencyMap.paths);
}
function* _fun61604() { // fn#61604, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7887:3777, offset: 0x01b46504, size: 169 bytes, params: 1, frame: 18
var value3;
var binding;
var value4;
var value5;
var value7;
var binding2;
var value9;
if (true) {
value = environment.__proto__.__proto__;
if (importDefault) {
value3 = environment.__proto__.__proto__.__proto__;
binding = env3_1;
value4 = binding(env3_2[26]);
yield value4.requestPermission(env3_15.CAMERA);
value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[30]);
value9.call(require.id, importDefault, true);
return undefined;
}
} else {
binding = env3_0;
binding2 = env3_2;
binding(binding2[27]).dismissKeyboard();
binding = env3_1;
value9 = binding(binding2[30]);
value9.call(require.id, importDefault, true);
}
}
}
global.__d(_fun61571, 7709, [5, 31, 3849, 7710, 1379, 3793, 1934, 1878, 661, 1229, 4661, 33, 5072, 7712, 7713, 1239,
5080, 7714, 1962, 5459, 5075, 4080, 12084, 4796, 4496, 1244, 4662, 4015, 12120, 4497, 8916, 4007, 8114,
2]) /* metro module 7709, dependencies: [5, 31, 3849, 7710, 1379, 3793, 1934, 1878, 661, 1229, 4661, 33, 5072, 7712, 7713, 1239, 5080, 7714, 1962, 5459, 5075, 4080, 12084, 4796, 4496, 1244, 4662, 4015, 12120, 4497, 8916, 4007, 8114, 2] */;
@@ -1,39 +1,42 @@
/* Metro module 5459; source: utils/native/RunAfterInteractionsUtils.tsx; dependencies: [27, 4041, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as TimersModule from '../../external/discord_common/js/packages/timers/Timers.tsx'; /* Metro dependency 4041 */
function _fun48022(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#48022, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:6, offset: 0x011d76e6, size: 128 bytes, params: 8, frame: 19
var object2;
const env0_0 = require;
const closure = runAfterInteractions_48023;
const runAfterInteractions_480232 = runAfterInteractions_48023;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_2 = (require(27) /* metro dependency 27 */).InteractionManager;
object2 = {runAfterInteractions: closure};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/RunAfterInteractionsUtils.tsx');
exports.default = object2;
exports.runAfterInteractions = closure;
}
object = {runAfterInteractions: runAfterInteractions_480232};
(FileImportTrackerModule).fileFinishedImporting('utils/native/RunAfterInteractionsUtils.tsx');
exports.default = object;
exports.runAfterInteractions = runAfterInteractions_480232;
function runAfterInteractions_48023(a0) { // fn#48023, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:125, offset: 0x011d7766, size: 141 bytes, params: 2, frame: 16
const value = a1;
const env0_0 = a0;
const r4 = value !== undefined ? value : 2000;
const env0_1 = InteractionManager.runAfterInteractions(_fun48024);
const DelayedCall = (TimersModule).DelayedCall;
new DelayedCall(r4, _fun48025).delay();
return {cancel: cancel_48026};
function _fun48024() { // fn#48024, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:194, offset: 0x011d77f3, size: 29 bytes, params: 1, frame: 10
ReactNativeModule.InteractionManager.cancel();
env0_0();
}
function runAfterInteractions_48023(a0) { // fn#48023, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:125, offset: 0x011d7766, size: 141 bytes, params: 2, frame: 16
const value = a1;
const env0_0 = a0;
const r4 = value !== undefined ? value : 2000;
const env0_1 = InteractionManager.runAfterInteractions(_fun48024);
const DelayedCall = (require(4041) /* metro dependency 4041: Timers */).DelayedCall;
new DelayedCall(r4, _fun48025).delay();
return {cancel: cancel_48026};
}
function _fun48025() { // fn#48025, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:247, offset: 0x011d7810, size: 29 bytes, params: 1, frame: 10
env0_1.cancel();
env0_0();
}
function _fun48024() { // fn#48024, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:194, offset: 0x011d77f3, size: 29 bytes, params: 1, frame: 10
env0_2.cancel();
env0_0();
}
function runAfterInteractions_48023Cancel() { // fn#48026, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:295, owner: runAfterInteractions_48023.cancel, offset: 0x011d782d, size: 35 bytes, params: 1, frame: 10
ReactNativeModule.InteractionManager.cancel();
env0_1.cancel();
}
function _fun48025() { // fn#48025, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:247, offset: 0x011d7810, size: 29 bytes, params: 1, frame: 10
env0_1.cancel();
env0_0();
}
}
function runAfterInteractions_48023Cancel() { // fn#48026, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5637:295, owner: runAfterInteractions_48023.cancel, offset: 0x011d782d, size: 35 bytes, params: 1, frame: 10
env0_2.cancel();
env0_1.cancel();
}
global.__d(_fun48022, 5459, [27, 4041, 2]) /* metro module 5459, dependencies: [27, 4041, 2] */;
+60 -57
View File
@@ -1,68 +1,71 @@
/* Metro module 8705; source: utils/native/StringUtils.tsx; dependencies: [8704, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun68371(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#68371, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8890:6, offset: 0x01c4c2cd, size: 99 bytes, params: 8, frame: 17
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/StringUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/StringUtils.tsx');
exports.splitGraphemes = splitGraphemes;
}
function splitGraphemes(a0) { // fn#68372, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8890:171, offset: 0x01c4c330, size: 236 bytes, params: 2, frame: 24
var r13;
var r2;
var lastIndex;
var r6;
var index;
var push;
var Array;
var from;
var slice;
var value4;
var items2;
var value5;
var value6;
var items3;
const value = 0;
const value2 = importDefault(dependencyMap[value])();
const items4 = [];
const value3 = value2.exec(a0);
if (value3 === null) {
r6 = value;
} else {
r2 = value3;
lastIndex = value;
while (true) {
index = r2.index;
if (index > lastIndex) {
push = items4.push;
Array = global.Array;
from = Array.from;
slice = a0.slice;
function splitGraphemes(a0) { // fn#68372, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8890:171, offset: 0x01c4c330, size: 236 bytes, params: 2, frame: 24
var r13;
var r2;
var lastIndex;
var r6;
var index;
var push;
var Array;
var from;
var slice;
var value4;
var items2;
var value5;
var value6;
var items3;
const value = 0;
const value2 = importDefault(dependencyMap[value])();
const items4 = [];
const value3 = value2.exec(a0);
if (value3 === null) {
r6 = value;
} else {
r2 = value3;
lastIndex = value;
while (true) {
index = r2.index;
value4 = Reflect.apply(from, Array, [Reflect.apply(slice, a0, [lastIndex, index])]);
items2 = [];
arraySpread(items2, value4, value, slice);
apply(push, items2, items4, slice);
r13 = slice;
if (index > lastIndex) {
push = items4.push;
Array = global.Array;
from = Array.from;
slice = a0.slice;
index = r2.index;
value4 = Reflect.apply(from, Array, [Reflect.apply(slice, a0, [lastIndex, index])]);
items2 = [];
arraySpread(items2, value4, value, slice);
apply(push, items2, items4, slice);
r13 = slice;
}
items4.push(r2[value]);
lastIndex = value2.lastIndex;
value5 = value2.exec(a0);
if (value5 !== null) {
r2 = value5;
continue;
}
r6 = lastIndex;
break;
}
items4.push(r2[value]);
lastIndex = value2.lastIndex;
value5 = value2.exec(a0);
if (value5 !== null) {
r2 = value5;
continue;
}
r6 = lastIndex;
break;
}
if (r6 < a0.length) {
push = items4.push;
Array = global.Array;
value6 = Array.from(a0.slice(r6));
items3 = [];
arraySpread(items3, value6, value, r13);
apply(push, items3, items4, r13);
}
return items4;
}
if (r6 < a0.length) {
push = items4.push;
Array = global.Array;
value6 = Array.from(a0.slice(r6));
items3 = [];
arraySpread(items3, value6, value, r13);
apply(push, items3, items4, r13);
}
return items4;
}
global.__d(_fun68371, 8705, [8704, 2]) /* metro module 8705, dependencies: [8704, 2] */;
+41 -39
View File
@@ -1,50 +1,52 @@
/* Metro module 5279; source: utils/native/StyleSheetUtils.tsx; dependencies: [2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun46918(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#46918, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5457:6, offset: 0x011b2e2f, size: 96 bytes, params: 8, frame: 16
var object2;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
object2 = {};
object2.getStyleProp = getStyleProp;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/StyleSheetUtils.tsx');
exports.default = object2;
}
function getStyleProp(a0, a1) { // fn#46919, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5457:113, offset: 0x011b2e8f, size: 116 bytes, params: 3, frame: 18
var r4;
var value;
if (a1 == null) {
return undefined;
}
if (a1 === '') {
return undefined;
}
const Array = global.Array;
if (Array.isArray(a0)) {
value = a0.length - 1;
if (value >= 0) {
r4 = value;
loopExit7: while (true) {
value = getStyleProp(a0[r4], a1);
if (value != null) {
return value;
object = {};
object.getStyleProp = getStyleProp;
(FileImportTrackerModule).fileFinishedImporting('utils/native/StyleSheetUtils.tsx');
exports.default = object;
function getStyleProp(a0, a1) { // fn#46919, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:5457:113, offset: 0x011b2e8f, size: 116 bytes, params: 3, frame: 18
var r4;
var value;
if (a1 == null) {
return undefined;
}
if (a1 === '') {
return undefined;
}
const Array = global.Array;
if (Array.isArray(a0)) {
value = a0.length - 1;
if (value >= 0) {
r4 = value;
loopExit7: while (true) {
value = getStyleProp(a0[r4], a1);
if (value != null) {
return value;
}
value = typeof r4 === 'bigint' ? r4 - 1n : +r4 - 1;
if (value >= 0) {
r4 = value;
continue;
}
break loopExit7;
}
value = typeof r4 === 'bigint' ? r4 - 1n : +r4 - 1;
if (value >= 0) {
r4 = value;
continue;
}
break loopExit7;
return undefined;
}
return undefined;
}
return undefined;
if (a0 == null) {
return undefined;
}
if (typeof a0 !== 'object') {
return undefined;
}
return a0[a1];
}
if (a0 == null) {
return undefined;
}
if (typeof a0 !== 'object') {
return undefined;
}
return a0[a1];
}
global.__d(_fun46918, 5279, [2]) /* metro module 5279, dependencies: [2] */;
+34 -30
View File
@@ -1,42 +1,46 @@
/* Metro module 13935; source: utils/native/SupportUtils.tsx; dependencies: [5, 1949, 1582, 4092, 3853, 1948, 2] */
import Module00005 from '../../by-id/module-00005.js'; /* Metro dependency 5 */
import LocaleStore from '../../modules/user_settings/LocaleStore.tsx'; /* Metro dependency 1949 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun105743(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#105743, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14132:6, offset: 0x022c21c1, size: 152 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_4 = importDefault(5) /* metro dependency 5 */;
const localeStore = importDefault(1949) /* metro dependency 1949: LocaleStore */;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/SupportUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/SupportUtils.tsx');
exports.emailSupport = function() {
return _emailSupport.apply(this, arguments);
};
}
function _emailSupport() { // fn#105744, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14132:116, offset: 0x022c2259, size: 50 bytes, params: 1, frame: 14
return env0_4(_fun105746).apply(this, arguments);
}
function* _fun105746() { // fn#105746, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14132:165, offset: 0x022c2296, size: 274 bytes, params: 1, frame: 33
if (true) {
value = environment.__proto__.__proto__;
var binding = env2_1;
var binding2 = env2_3;
var value3 = binding(binding2[4]);
var openURL = value3.openURL;
var value4 = binding(binding2[5]);
var getSubmitRequestURL = value4.getSubmitRequestURL;
var constants = env2_2(binding2[2]).getConstants();
var Manifest = constants.Manifest;
Manifest = Manifest.trim().length > 0 ? constants.Manifest : 'N/A';
var Version = constants.Version;
binding = env2_0;
var binding3 = env2_3;
yield Reflect.apply(getSubmitRequestURL, value4,
['App version: ' + Version + '\n Manifest: ' + Manifest + '\n iOS version: ' + binding(binding3[3]).getSystemVersion() + '\n Device: ' + binding(binding3[3]).getDeviceInfo() + '\n Language: ' + env2_5.locale]);
value = undefined;
if (false) {
return value;
function _emailSupport() { // fn#105744, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14132:116, offset: 0x022c2259, size: 50 bytes, params: 1, frame: 14
return Module00005(_fun105746).apply(this, arguments);
function* _fun105746() { // fn#105746, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14132:165, offset: 0x022c2296, size: 274 bytes, params: 1, frame: 33
if (true) {
value = environment.__proto__.__proto__;
var binding = env2_1;
var binding2 = env2_3;
var value3 = binding(binding2[4]);
var openURL = value3.openURL;
var value4 = binding(binding2[5]);
var getSubmitRequestURL = value4.getSubmitRequestURL;
var constants = env2_2(binding2[2]).getConstants();
var Manifest = constants.Manifest;
Manifest = Manifest.trim().length > 0 ? constants.Manifest : 'N/A';
var Version = constants.Version;
binding = env2_0;
var binding3 = env2_3;
yield Reflect.apply(getSubmitRequestURL, value4,
['App version: ' + Version + '\n Manifest: ' + Manifest + '\n iOS version: ' + binding(binding3[3]).getSystemVersion() + '\n Device: ' + binding(binding3[3]).getDeviceInfo() + '\n Language: ' + env2_5.locale]);
value = undefined;
if (false) {
return value;
}
Reflect.apply(openURL, value3, [value]);
}
}
Reflect.apply(openURL, value3, [value]);
}
}
global.__d(_fun105743, 13935, [5, 1949, 1582, 4092, 3853, 1948,
2]) /* metro module 13935, dependencies: [5, 1949, 1582, 4092, 3853, 1948, 2] */;
+4 -1
View File
@@ -1,8 +1,10 @@
/* Metro module 4690; source: utils/native/TimeUtils.tsx; dependencies: [2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun40563(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#40563, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4868:6, offset: 0x01104fb2, size: 85 bytes, params: 8, frame: 15
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/TimeUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/TimeUtils.tsx');
exports.getTimeFormat = getTimeFormat;
}
@@ -36,3 +38,4 @@ function getTimeFormat(a0, a1) { // fn#40564, source: /ci/build/discord/discord/
return r0;
}
global.__d(_fun40563, 4690, [2]) /* metro module 4690, dependencies: [2] */;
File diff suppressed because it is too large. Load diff
+76 -66
View File
@@ -1,81 +1,91 @@
/* Metro module 11970; source: utils/native/WelcomeScreenUtils.tsx; dependencies: [31, 11971, 1935, 1867, 3980, 11972, 566, 11973, 4080, 11974, 1962, 2] */
import GuildStore from '../../stores/GuildStore.tsx'; /* Metro dependency 1867 */
import GuildChannelStore from '../../stores/GuildChannelStore.tsx'; /* Metro dependency 1935 */
import WelcomeScreenStore from '../../modules/welcome_screen/WelcomeScreenStore.tsx'; /* Metro dependency 11971 */
import UseWelcomeScreenEnabled from '../../modules/welcome_screen/useWelcomeScreenEnabled.tsx'; /* Metro dependency 11972 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as FluxModule from '../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as Module03980Module from '../../by-id/module-03980.js'; /* Metro dependency 3980 */
import * as WelcomeScreenStoreModule from '../../modules/welcome_screen/WelcomeScreenStore.tsx'; /* Metro dependency 11971 */
function _fun91875(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#91875, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:6, offset: 0x020757bd, size: 219 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 welcomeScreenStore = importDefault(11971) /* metro dependency 11971: WelcomeScreenStore */;
const env0_5 = (require(11971) /* metro dependency 11971: WelcomeScreenStore */).NO_WELCOME_SCREEN;
const guildChannelStore = importDefault(1935) /* metro dependency 1935: GuildChannelStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
object = {welcomeScreenModalVisible: false, shouldFetchGuildId: undefined};
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/WelcomeScreenUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/WelcomeScreenUtils.tsx');
exports.useShowWelcomeModal = useShowWelcomeModal;
exports.openWelcomeActionSheet = openWelcomeActionSheet;
}
function useShowWelcomeModal(a0, a1) { // fn#91876, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:315, offset: 0x02075898, size: 194 bytes, params: 3, frame: 18
const env0_0 = a0;
const env0_1 = a1;
const useLocation = Module03980Module.useLocation;
const env0_2 = Reflect.apply(useLocation, Module03980Module, []).welcomeModalChannelId;
const env0_3 = (UseWelcomeScreenEnabled)(a1, a0);
const {welcomeScreenModalVisible,
shouldFetchGuildId} = (FluxModule).useStateFromStoresObject([GuildStore,
WelcomeScreenStore, GuildChannelStore], _fun91877);
env0_3.useEffect(_fun91878, [shouldFetchGuildId]);
return welcomeScreenModalVisible;
function _fun91877() { // fn#91877, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:458, offset: 0x0207595a, size: 209 bytes, params: 1, frame: 18
var r3;
var r1;
var guildStoreBinding;
var getGuild;
var binding;
var value3;
var selectableChannelIds;
var welcomeScreenStoreBinding;
var value5;
var hasSeen2;
var hasError2;
var isFetching2;
if (env0_3) {
guildStoreBinding = GuildStore;
getGuild = guildStoreBinding.getGuild;
binding = env0_0;
value3 = Reflect.apply(getGuild, guildStoreBinding, [binding]);
selectableChannelIds = GuildChannelStore.getSelectableChannelIds(binding);
welcomeScreenStoreBinding = WelcomeScreenStore;
value5 = welcomeScreenStoreBinding.get(binding);
hasSeen2 = welcomeScreenStoreBinding.hasSeen(binding);
hasError2 = welcomeScreenStoreBinding.hasError();
isFetching2 = welcomeScreenStoreBinding.isFetching();
r3 = !hasSeen2 && welcomeModalChannelId === require;
r1 = r3 && value5 != null;
r1 = r1 && value5 !== NO_WELCOME_SCREEN;
r1 = r1 && !isFetching2;
r1 = r1 && !hasError2;
r1 = r1 && selectableChannelIds.length > 0;
return {welcomeScreenModalVisible: r1,
shouldFetchGuildId: r3 && value5 == null && value3 != null ? value3.id : undefined};
}
return env1_8;
}
function useShowWelcomeModal(a0, a1) { // fn#91876, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:315, offset: 0x02075898, size: 194 bytes, params: 3, frame: 18
const env0_0 = a0;
const env0_1 = a1;
const moduleValue = require(3980) /* metro dependency 3980 */;
const useLocation = moduleValue.useLocation;
const env0_2 = Reflect.apply(useLocation, moduleValue, []).welcomeModalChannelId;
const env0_3 = (importDefault(11972) /* metro dependency 11972: useWelcomeScreenEnabled */)(a1, a0);
const {welcomeScreenModalVisible,
shouldFetchGuildId} = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildStore,
WelcomeScreenStore, GuildChannelStore], _fun91877);
env0_3.useEffect(_fun91878, [shouldFetchGuildId]);
return welcomeScreenModalVisible;
}
function _fun91878() { // fn#91878, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:798, offset: 0x02075a2b, size: 57 bytes, params: 1, frame: 12
var value2;
var moduleValue;
if (shouldFetchGuildId != null) {
value2 = environment.__proto__;
moduleValue = require(11973) /* metro dependency 11973: WelcomeScreenActionCreators */;
moduleValue.fetchWelcomeScreen(shouldFetchGuildId);
}
}
function openWelcomeActionSheet({guildId, onHide}) { // fn#91879, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:877, offset: 0x02075a64, size: 123 bytes, params: 2, frame: 18
const defaultImport = importDefault(dependencyMap[8]);
const openLazy = defaultImport.openLazy;
let value = require(dependencyMap[10]);
value = value(dependencyMap[9], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport, [value, 'GuildWelcomeActionSheet' + guildId, {guildId: guildId,
onHide: onHide}]);
}
function _fun91877() { // fn#91877, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:458, offset: 0x0207595a, size: 209 bytes, params: 1, frame: 18
var r3;
var r1;
var getGuild;
var binding;
var value3;
var selectableChannelIds;
var value5;
var hasSeen2;
var hasError2;
var isFetching2;
if (env0_3) {
getGuild = GuildStore.getGuild;
binding = env0_0;
value3 = Reflect.apply(getGuild, GuildStore, [binding]);
selectableChannelIds = GuildChannelStore.getSelectableChannelIds(binding);
value5 = WelcomeScreenStore.get(binding);
hasSeen2 = WelcomeScreenStore.hasSeen(binding);
hasError2 = WelcomeScreenStore.hasError();
isFetching2 = WelcomeScreenStore.isFetching();
r3 = !hasSeen2 && welcomeModalChannelId === require;
r1 = r3 && value5 != null;
r1 = r1 && value5 !== NO_WELCOME_SCREEN;
r1 = r1 && !isFetching2;
r1 = r1 && !hasError2;
r1 = r1 && selectableChannelIds.length > 0;
return {welcomeScreenModalVisible: r1,
shouldFetchGuildId: r3 && value5 == null && value3 != null ? value3.id : undefined};
}
return env1_8;
}
function _fun91878() { // fn#91878, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:798, offset: 0x02075a2b, size: 57 bytes, params: 1, frame: 12
var value2;
var moduleValue;
if (shouldFetchGuildId != null) {
value2 = environment.__proto__;
moduleValue = require(11973) /* metro dependency 11973: WelcomeScreenActionCreators */;
moduleValue.fetchWelcomeScreen(shouldFetchGuildId);
function openWelcomeActionSheet({guildId, onHide}) { // fn#91879, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12156:877, offset: 0x02075a64, size: 123 bytes, params: 2, frame: 18
const defaultImport = importDefault(dependencyMap[8]);
const openLazy = defaultImport.openLazy;
let value = require(dependencyMap[10]);
value = value(dependencyMap[9], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport, [value, 'GuildWelcomeActionSheet' + guildId, {guildId: guildId,
onHide: onHide}]);
}
}
global.__d(_fun91875, 11970, [31, 11971, 1935, 1867, 3980, 11972, 566, 11973, 4080, 11974, 1962,
2]) /* metro module 11970, dependencies: [31, 11971, 1935, 1867, 3980, 11972, 566, 11973, 4080, 11974, 1962, 2] */;
@@ -1,10 +1,12 @@
/* Metro module 8112; source: utils/native/openChannelCallModalForChannelId.tsx; dependencies: [1379, 8113, 7709, 2] */
import ChannelStore from '../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun65001(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#65001, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8297:6, offset: 0x01bbcb5e, size: 112 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/openChannelCallModalForChannelId.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/openChannelCallModalForChannelId.tsx');
exports.default = function(a0, a1) {
var r1;
var value = a1;
@@ -24,3 +26,4 @@ function _fun65001(global, require, importDefault, importAll, module, exports, d
};
}
global.__d(_fun65001, 8112, [1379, 8113, 7709, 2]) /* metro module 8112, dependencies: [1379, 8113, 7709, 2] */;
File diff suppressed because it is too large. Load diff
@@ -1,8 +1,11 @@
/* Metro module 4567; source: utils/native/requireNativeComponentOrDefault.native.tsx; dependencies: [27, 3, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
function _fun38804(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#38804, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4745:6, offset: 0x010cae70, size: 201 bytes, params: 8, frame: 19
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = require(27) /* metro dependency 27 */;
let value = ReactNativeModule;
const env0_0 = value.requireNativeComponent;
const env0_1 = value.UIManager;
const env0_2 = value.View;
@@ -10,29 +13,30 @@ function _fun38804(global, require, importDefault, importAll, module, exports, d
value = new value('RequireNativeComponentOrDefault');
const Map = global.Map;
const map = new Map();
(require(2) /* metro dependency 2 */).fileFinishedImporting('utils/native/requireNativeComponentOrDefault.native.tsx');
(FileImportTrackerModule).fileFinishedImporting('utils/native/requireNativeComponentOrDefault.native.tsx');
exports.default = requireNativeComponentOrDefault;
}
function requireNativeComponentOrDefault({componentName, componentFoundInstance, componentMissingFallbackInstance, warnWhenMissing}) { // fn#38805, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4745:315, offset: 0x010caf39, size: 184 bytes, params: 2, frame: 20
var r0;
var binding;
const r2 = componentMissingFallbackInstance !== undefined ? componentMissingFallbackInstance : View;
warnWhenMissing = warnWhenMissing === undefined || warnWhenMissing;
if (UIManager.hasViewManagerConfig(componentName)) {
binding = env0_4;
if (!binding.has(componentName)) {
function requireNativeComponentOrDefault({componentName, componentFoundInstance, componentMissingFallbackInstance, warnWhenMissing}) { // fn#38805, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4745:315, offset: 0x010caf39, size: 184 bytes, params: 2, frame: 20
var r0;
var binding;
const r2 = componentMissingFallbackInstance !== undefined ? componentMissingFallbackInstance : View;
warnWhenMissing = warnWhenMissing === undefined || warnWhenMissing;
if (UIManager.hasViewManagerConfig(componentName)) {
binding = env0_4;
binding.set(componentName, componentFoundInstance ?? requireNativeComponent(componentName));
if (!binding.has(componentName)) {
binding = env0_4;
binding.set(componentName, componentFoundInstance ?? requireNativeComponent(componentName));
}
binding = env0_4;
r0 = binding.get(componentName);
} else if (warnWhenMissing) {
env0_3.warn('' + componentName + ' not found, you are likely on a branch override without the native code.');
r0 = r2;
} else {
r0 = r2;
}
binding = env0_4;
r0 = binding.get(componentName);
} else if (warnWhenMissing) {
env0_3.warn('' + componentName + ' not found, you are likely on a branch override without the native code.');
r0 = r2;
} else {
r0 = r2;
return r0;
}
return r0;
}
global.__d(_fun38804, 4567, [27, 3, 2]) /* metro module 4567, dependencies: [27, 3, 2] */;