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

@@ -1,495 +1,494 @@
/* Metro module 8120; source: modules/channel_permissions/ChannelPermissionsConstants.tsx; dependencies: [661, 1244, 8121, 1948, 8122, 2] */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
function _fun65082(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#65082, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8305:6, offset: 0x01bbf6c6, size: 450 bytes, params: 8, frame: 23
var object3;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const constantsModule = require(661) /* metro dependency 661: Constants */;
const env0_3 = constantsModule.ChannelTypes;
const env0_4 = constantsModule.ChannelTypesSets;
const env0_5 = constantsModule.HelpdeskArticles;
const env0_6 = constantsModule.Permissions;
object3 = {EMPTY_STATE: 0};
object3[0] = 'EMPTY_STATE';
object3.ADMINISTRATOR = 1;
object3[1] = 'ADMINISTRATOR';
object3.ROLE = 2;
object3[2] = 'ROLE';
object3.OWNER = 3;
object3[3] = 'OWNER';
object3.MEMBER = 4;
object3[4] = 'MEMBER';
object3.USER = 5;
object3[5] = 'USER';
object3.GUILD = 6;
object3[6] = 'GUILD';
const object4 = {ROLES: 0};
object4[0] = 'ROLES';
object4.MEMBERS = 1;
object4[1] = 'MEMBERS';
object4.USERS = 2;
object4[2] = 'USERS';
object4.GUILDS = 3;
object4[3] = 'GUILDS';
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/ChannelPermissionsConstants.tsx');
exports.RowType = object3;
exports.AudienceSelectorSections = object4;
object = {EMPTY_STATE: 0};
object[0] = 'EMPTY_STATE';
object.ADMINISTRATOR = 1;
object[1] = 'ADMINISTRATOR';
object.ROLE = 2;
object[2] = 'ROLE';
object.OWNER = 3;
object[3] = 'OWNER';
object.MEMBER = 4;
object[4] = 'MEMBER';
object.USER = 5;
object[5] = 'USER';
object.GUILD = 6;
object[6] = 'GUILD';
const object2 = {ROLES: 0};
object2[0] = 'ROLES';
object2.MEMBERS = 1;
object2[1] = 'MEMBERS';
object2.USERS = 2;
object2[2] = 'USERS';
object2.GUILDS = 3;
object2[3] = 'GUILDS';
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/ChannelPermissionsConstants.tsx');
exports.RowType = object;
exports.AudienceSelectorSections = object2;
exports.MEMBER_REQUEST_COUNT = 20;
exports.ADVANCED_MODE_ON_KEY = 'channelPermissionSettingsAdvancedModeOn';
exports.TrackExposureLocations = {SETTINGS_PAGE: 'settings-page', MEMBERS_LIST: 'members-list',
EMPTY_STATE: 'empty-state', CREATE_CHANNEL: 'create-channel'};
exports.SettingMode = {BASIC: 'basic', ADVANCED: 'advanced'};
exports.getChannelPermissionSpecMap = getChannelPermissionSpecMap;
function getChannelPermissionSpecMap(a0, a1, a2) { // fn#65083, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8305:1016, offset: 0x01bbf888, size: 10536 bytes, params: 4, frame: 29
var r1;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var property;
var defaultImport;
var format;
var WFwfSD;
var defaultImport2;
var XRxOo0;
var defaultImport4;
var defaultImport5;
var GEi6Ym;
var defaultImport6;
var defaultImport7;
var defaultImport8;
var Ij0yKX;
var intl2;
const intl3 = (require(1244) /* metro dependency 1244: indexNative */).intl;
var g5MzON;
var intl4;
const type = a0.type;
const object = {};
let VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
const value2 = VIEW_CHANNEL.toString();
const object2 = {};
let GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object2.title = type === GUILD_CATEGORY ? intl.string(t.uV83yi) : intl.string(t['W/A4Qp']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object2.description = a1 ? GUILD_CATEGORY === type ? t['o/vBzj'] : ChannelTypes.GUILD_VOICE === type || ChannelTypes.GUILD_STAGE_VOICE === type ? t.ejL1Wo : t['3jG0Bo'] : type === GUILD_CATEGORY ? t.SzosGs : t.M2iEy3;
VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
object2.flag = VIEW_CHANNEL;
object[value2] = object2;
let MANAGE_CHANNELS = Permissions.MANAGE_CHANNELS;
const value5 = MANAGE_CHANNELS.toString();
const object3 = {};
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object3.title = type === GUILD_CATEGORY ? intl.string(t['9qLtWs']) : intl.string(t.nAw15L);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object3.description = GUILD_CATEGORY === type ? t.KJ2JnG : ChannelTypes.GUILD_VOICE === type ? t['+gl2ne'] : ChannelTypes.GUILD_STAGE_VOICE === type ? t.SDX669 : t.ydL28i;
MANAGE_CHANNELS = Permissions.MANAGE_CHANNELS;
object3.flag = MANAGE_CHANNELS;
object[value5] = object3;
let MANAGE_ROLES = Permissions.MANAGE_ROLES;
const value8 = MANAGE_ROLES.toString();
const value9 = undefined;
let string = intl.string;
const ICb6am = t.ICb6am;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r12 = GUILD_CATEGORY === type ? t.TyyCMD : ChannelTypes.GUILD_STAGE_VOICE === type ? t.hcw4mx : t.hOMXOv;
MANAGE_ROLES = Permissions.MANAGE_ROLES;
object[value8] = {title: Reflect.apply(string, intl, [ICb6am]), description: r12, flag: MANAGE_ROLES};
let MANAGE_WEBHOOKS = Permissions.MANAGE_WEBHOOKS;
const value10 = MANAGE_WEBHOOKS.toString();
const object5 = {};
object5.title = intl.string(t['/ADKmM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object5.description = type === GUILD_CATEGORY ? t['K5+ZZ7'] : t.CYBZry;
MANAGE_WEBHOOKS = Permissions.MANAGE_WEBHOOKS;
object5.flag = MANAGE_WEBHOOKS;
object[value10] = object5;
let CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
const value11 = CREATE_INSTANT_INVITE.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r9 = GUILD_CATEGORY === type ? t['3YFAAX'] : ChannelTypes.GUILD_VOICE === type || ChannelTypes.GUILD_STAGE_VOICE === type ? t.lUCs1n : t.q4g2aI;
CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
object[value11] = {title: intl.string(t.zJrgTG), description: r9, flag: CREATE_INSTANT_INVITE};
let SEND_MESSAGES = Permissions.SEND_MESSAGES;
const value12 = SEND_MESSAGES.toString();
const object7 = {};
let GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
object7.title = GUILD_THREADS_ONLY.has(type) ? intl.string(t.nJwAHX) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t.S1VOwd) : intl.string(t.T32rkC);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r1 = t.IjeLuu;
} else if (ChannelTypes.GUILD_FORUM === type) {
r1 = a2 == null ? t.LG9VAi : a2.createPostsDisabled ? a0.isMediaChannel() ? t.LG9VAi : (importDefault(8121) /* metro dependency 8121: ForumPlatformUtilsNative */).getForumChannelPermissionText() : t.LG9VAi;
} else if (ChannelTypes.GUILD_MEDIA === type) {
r1 = t.LG9VAi;
} else if (ChannelTypes.GUILD_ANNOUNCEMENT === type) {
format = intl.format;
WFwfSD = t.WFwfSD;
defaultImport2 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r1 = Reflect.apply(format, intl, [WFwfSD,
{articleURL: defaultImport2.getArticleURL(HelpdeskArticles.ANNOUNCEMENT_CHANNELS)}]);
} else if (ChannelTypes.GUILD_VOICE === type) {
defaultImport = importDefault(8122) /* metro dependency 8122: GuildTiVPlatformUtilsNative */;
r1 = defaultImport.getTextInVoiceSendMessageChannelPermissionText(a2 == null ? value9 : a2.sendMessagesDisabled);
} else {
r1 = t.WQ6zpT;
}
object7.description = r1;
SEND_MESSAGES = Permissions.SEND_MESSAGES;
object7.flag = SEND_MESSAGES;
object[value12] = object7;
let EMBED_LINKS = Permissions.EMBED_LINKS;
const value19 = EMBED_LINKS.toString();
const object9 = {};
object9.title = intl.string(t['969dEL']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object9.description = type === GUILD_CATEGORY ? t['7zlUay'] : t.XFFhA0;
EMBED_LINKS = Permissions.EMBED_LINKS;
object9.flag = EMBED_LINKS;
object[value19] = object9;
let ATTACH_FILES = Permissions.ATTACH_FILES;
const value20 = ATTACH_FILES.toString();
const object10 = {};
object10.title = intl.string(t['3AS4UM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object10.description = type === GUILD_CATEGORY ? t.XREf9l : t.WK9r7F;
ATTACH_FILES = Permissions.ATTACH_FILES;
object10.flag = ATTACH_FILES;
object[value20] = object10;
let ADD_REACTIONS = Permissions.ADD_REACTIONS;
const value21 = ADD_REACTIONS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
let r11 = GUILD_CATEGORY === type ? t.pZT2Zh : ChannelTypes.GUILD_VOICE === type ? t.xSSbIs : t.PVjR1Y;
ADD_REACTIONS = Permissions.ADD_REACTIONS;
object[value21] = {title: intl.string(t.yEoJAr), description: r11, flag: ADD_REACTIONS};
let USE_EXTERNAL_EMOJIS = Permissions.USE_EXTERNAL_EMOJIS;
const value22 = USE_EXTERNAL_EMOJIS.toString();
const object12 = {};
object12.title = intl.string(t['+bxf3H']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object12.description = type === GUILD_CATEGORY ? t.mWAbK4 : t.Qc5vOr;
USE_EXTERNAL_EMOJIS = Permissions.USE_EXTERNAL_EMOJIS;
object12.flag = USE_EXTERNAL_EMOJIS;
object[value22] = object12;
let USE_EXTERNAL_STICKERS = Permissions.USE_EXTERNAL_STICKERS;
const value23 = USE_EXTERNAL_STICKERS.toString();
string = intl.string;
const ERNhYf = t.ERNhYf;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['39whJ4'] : t.VF4fZZ;
USE_EXTERNAL_STICKERS = Permissions.USE_EXTERNAL_STICKERS;
object[value23] = {title: Reflect.apply(string, intl, [ERNhYf]), description: r1, flag: USE_EXTERNAL_STICKERS};
let MENTION_EVERYONE = Permissions.MENTION_EVERYONE;
const value24 = MENTION_EVERYONE.toString();
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
MENTION_EVERYONE = Permissions.MENTION_EVERYONE;
object[value24] = {title: type === GUILD_STAGE_VOICE ? intl.string(t.VDUAHO) : intl.string(t.Y78KGC),
description: type === GUILD_CATEGORY ? t['HOhg/B'] : type === ChannelTypes.GUILD_STAGE_VOICE ? t.rZn1oO : t['6IUSdt'],
flag: MENTION_EVERYONE};
let MANAGE_MESSAGES = Permissions.MANAGE_MESSAGES;
const value27 = MANAGE_MESSAGES.toString();
const object15 = {};
object15.title = intl.string(t['6lU9xM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r11 = t['5R9nYh'];
} else if (ChannelTypes.GUILD_ANNOUNCEMENT === type) {
format = intl.format;
XRxOo0 = t.XRxOo0;
defaultImport4 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r11 = Reflect.apply(format, intl, [XRxOo0,
{articleURL: defaultImport4.getArticleURL(HelpdeskArticles.ANNOUNCEMENT_CHANNELS)}]);
} else {
r11 = t['SeA+G9'];
}
object15.description = r11;
MANAGE_MESSAGES = Permissions.MANAGE_MESSAGES;
object15.flag = MANAGE_MESSAGES;
object[value27] = object15;
let PIN_MESSAGES = Permissions.PIN_MESSAGES;
const value29 = PIN_MESSAGES.toString();
string = intl.string;
const Y5BI39 = t.Y5BI39;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.gmbD87 : t['0l2EjL'];
PIN_MESSAGES = Permissions.PIN_MESSAGES;
object[value29] = {title: Reflect.apply(string, intl, [Y5BI39]), description: r1, flag: PIN_MESSAGES};
let BYPASS_SLOWMODE = Permissions.BYPASS_SLOWMODE;
const value30 = BYPASS_SLOWMODE.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.C4t1Xu : t.Ha1xbw;
BYPASS_SLOWMODE = Permissions.BYPASS_SLOWMODE;
object[value30] = {title: intl.string(t.kqcjeV), description: r1, flag: BYPASS_SLOWMODE};
let MANAGE_OFFICIAL_MESSAGES = Permissions.MANAGE_OFFICIAL_MESSAGES;
const value31 = MANAGE_OFFICIAL_MESSAGES.toString();
string = intl.string;
const Aj9ruN = t.Aj9ruN;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['Pf0e/Q'] : t.qEbw4W;
MANAGE_OFFICIAL_MESSAGES = Permissions.MANAGE_OFFICIAL_MESSAGES;
object[value31] = {title: Reflect.apply(string, intl, [Aj9ruN]), description: r1, flag: MANAGE_OFFICIAL_MESSAGES};
let READ_MESSAGE_HISTORY = Permissions.READ_MESSAGE_HISTORY;
const value32 = READ_MESSAGE_HISTORY.toString();
const object20 = {};
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
const value33 = GUILD_THREADS_ONLY.has(type);
string = intl.string;
object20.title = value33 ? Reflect.apply(string, intl, [t['0RQwtn']]) : Reflect.apply(string, intl, [t.l9ufaR]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r1 = t['cJRv/g'];
} else if (ChannelTypes.GUILD_VOICE === type) {
defaultImport5 = importDefault(8122) /* metro dependency 8122: GuildTiVPlatformUtilsNative */;
r1 = defaultImport5.getTextInVoiceReadMessageHistoryChannelPermissionText(a2 == null ? value9 : a2.readMessageHistoryDisabled);
} else {
r1 = ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.RqCc7i : t.cuMfH0;
}
object20.description = r1;
READ_MESSAGE_HISTORY = Permissions.READ_MESSAGE_HISTORY;
object20.flag = READ_MESSAGE_HISTORY;
object[value32] = object20;
let SEND_TTS_MESSAGES = Permissions.SEND_TTS_MESSAGES;
const value37 = SEND_TTS_MESSAGES.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.b7pc9U : t.CpakGz;
SEND_TTS_MESSAGES = Permissions.SEND_TTS_MESSAGES;
object[value37] = {title: intl.string(t.mMbwh7), description: r1, flag: SEND_TTS_MESSAGES};
let USE_APPLICATION_COMMANDS = Permissions.USE_APPLICATION_COMMANDS;
const value38 = USE_APPLICATION_COMMANDS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['D+qW0J'] : t.ReG3gG;
USE_APPLICATION_COMMANDS = Permissions.USE_APPLICATION_COMMANDS;
object[value38] = {title: intl.string(t.nkoPOt), description: r1, flag: USE_APPLICATION_COMMANDS};
let SEND_VOICE_MESSAGES = Permissions.SEND_VOICE_MESSAGES;
const value39 = SEND_VOICE_MESSAGES.toString();
string = intl.string;
const WlWSBT = t.WlWSBT;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.gavGfv : t.BhEo9V;
SEND_VOICE_MESSAGES = Permissions.SEND_VOICE_MESSAGES;
object[value39] = {title: Reflect.apply(string, intl, [WlWSBT]), description: r1, flag: SEND_VOICE_MESSAGES};
let SEND_POLLS = Permissions.SEND_POLLS;
const value40 = SEND_POLLS.toString();
string = intl.string;
const UMQ7Ww = t.UMQ7Ww;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r2 = type === GUILD_CATEGORY ? t['18Ya7L'] : t.ckKKIO;
SEND_POLLS = Permissions.SEND_POLLS;
object[value40] = {title: Reflect.apply(string, intl, [UMQ7Ww]), description: r2, flag: SEND_POLLS};
let CONNECT = Permissions.CONNECT;
const value41 = CONNECT.toString();
string = intl.string;
const S0W8Z5 = t.S0W8Z5;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
let r10 = a1 ? GUILD_CATEGORY === type ? t.XcrieN : ChannelTypes.GUILD_STAGE_VOICE === type ? t.SOFNhP : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.LsS8xT : t.j4AyO8 : GUILD_CATEGORY === type ? t.stA0Hl : ChannelTypes.GUILD_STAGE_VOICE === type ? t['G9+Qie'] : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['QU/Rw8'] : t.HvG8uR;
CONNECT = Permissions.CONNECT;
object[value41] = {title: Reflect.apply(string, intl, [S0W8Z5]), description: r10, flag: CONNECT};
let SPEAK = Permissions.SPEAK;
const value42 = SPEAK.toString();
const object26 = {};
object26.title = intl.string(t['8w1tIR']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object26.description = GUILD_CATEGORY === type ? t.iXhS6R : ChannelTypes.GUILD_STAGE_VOICE === type ? t.a8n741 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['+VXsJI'] : t['568E6d'];
SPEAK = Permissions.SPEAK;
object26.flag = SPEAK;
object[value42] = object26;
let STREAM = Permissions.STREAM;
const value43 = STREAM.toString();
string = intl.string;
const FlNoSV = t.FlNoSV;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t['ryG0/J'] : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.AuEQEC : ChannelTypes.GUILD_STAGE_VOICE === type ? t.swJcN6 : t.RY8rIc;
STREAM = Permissions.STREAM;
object[value43] = {title: Reflect.apply(string, intl, [FlNoSV]), description: r10, flag: STREAM};
let USE_EMBEDDED_ACTIVITIES = Permissions.USE_EMBEDDED_ACTIVITIES;
const value44 = USE_EMBEDDED_ACTIVITIES.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t.maNzCO : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.RyEwla : t.qinvMU;
USE_EMBEDDED_ACTIVITIES = Permissions.USE_EMBEDDED_ACTIVITIES;
object[value44] = {title: intl.string(t.rLSGeh), description: r10, flag: USE_EMBEDDED_ACTIVITIES};
let USE_EXTERNAL_APPS = Permissions.USE_EXTERNAL_APPS;
const value45 = USE_EXTERNAL_APPS.toString();
const object29 = {};
object29.title = intl.string(t['3TzAk0']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object29.description = GUILD_CATEGORY === type ? t.bgIY3H : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.qPUPip : t.czqMLp;
USE_EXTERNAL_APPS = Permissions.USE_EXTERNAL_APPS;
object29.flag = USE_EXTERNAL_APPS;
object[value45] = object29;
let USE_SOUNDBOARD = Permissions.USE_SOUNDBOARD;
const value46 = USE_SOUNDBOARD.toString();
const object30 = {};
string = intl.string;
const Bco7NG = t.Bco7NG;
object30.title = Reflect.apply(string, intl, [Bco7NG]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
format = intl.format;
property = t['0kBp/0'];
defaultImport8 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport8.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_TEXT === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_FORUM === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_MEDIA === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else {
format = intl.format;
GEi6Ym = t.GEi6Ym;
defaultImport6 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [GEi6Ym,
{helpCenterArticle: defaultImport6.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
}
object30.description = r10;
USE_SOUNDBOARD = Permissions.USE_SOUNDBOARD;
object30.flag = USE_SOUNDBOARD;
object[value46] = object30;
let USE_EXTERNAL_SOUNDS = Permissions.USE_EXTERNAL_SOUNDS;
const value50 = USE_EXTERNAL_SOUNDS.toString();
USE_EXTERNAL_SOUNDS = Permissions.USE_EXTERNAL_SOUNDS;
object[value50] = {title: intl.string(t.pwaVJ6), description: t.qDpPtX, flag: USE_EXTERNAL_SOUNDS};
let USE_VAD = Permissions.USE_VAD;
const value51 = USE_VAD.toString();
const object34 = {};
object34.title = intl.string(t['08zAV7']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object34.description = GUILD_CATEGORY === type ? t.fUYPly : ChannelTypes.GUILD_STAGE_VOICE === type ? t.BJKqsW : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['3GJwsc'] : t.s2eihY;
USE_VAD = Permissions.USE_VAD;
object34.flag = USE_VAD;
object[value51] = object34;
let PRIORITY_SPEAKER = Permissions.PRIORITY_SPEAKER;
const value52 = PRIORITY_SPEAKER.toString();
const object35 = {};
string = intl.string;
const BVK71i = t.BVK71i;
object35.title = Reflect.apply(string, intl, [BVK71i]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
format = intl.format;
g5MzON = t.g5MzON;
intl4 = (require(1244) /* metro dependency 1244: indexNative */).intl;
r10 = Reflect.apply(format, intl, [g5MzON, {keybind: intl4.string(t.DkSwJ2)}]);
} else if (ChannelTypes.GUILD_TEXT === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else if (ChannelTypes.GUILD_FORUM === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else if (ChannelTypes.GUILD_MEDIA === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else {
format = intl.format;
Ij0yKX = t.Ij0yKX;
intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
r10 = Reflect.apply(format, intl, [Ij0yKX, {keybind: intl2.string(t.DkSwJ2)}]);
}
object35.description = r10;
PRIORITY_SPEAKER = Permissions.PRIORITY_SPEAKER;
object35.flag = PRIORITY_SPEAKER;
object[value52] = object35;
let MUTE_MEMBERS = Permissions.MUTE_MEMBERS;
const value56 = MUTE_MEMBERS.toString();
const object36 = {};
object36.title = intl.string(t['8EI30/']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object36.description = GUILD_CATEGORY === type ? t.bcuobK : ChannelTypes.GUILD_STAGE_VOICE === type ? t.EbvdH9 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.KYDG2K : t.LW5C9P;
MUTE_MEMBERS = Permissions.MUTE_MEMBERS;
object36.flag = MUTE_MEMBERS;
object[value56] = object36;
let DEAFEN_MEMBERS = Permissions.DEAFEN_MEMBERS;
const value57 = DEAFEN_MEMBERS.toString();
const object37 = {};
object37.title = intl.string(t['9L47Fr']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object37.description = GUILD_CATEGORY === type ? t.amZ5vn : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['d+i1nX'] : t.UAdIxo;
DEAFEN_MEMBERS = Permissions.DEAFEN_MEMBERS;
object37.flag = DEAFEN_MEMBERS;
object[value57] = object37;
let MOVE_MEMBERS = Permissions.MOVE_MEMBERS;
const value58 = MOVE_MEMBERS.toString();
string = intl.string;
const YtjJPQ = t.YtjJPQ;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t.XmoyRD : ChannelTypes.GUILD_STAGE_VOICE === type ? t.bizKz6 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.cbdQy2 : t.nSD1ah;
MOVE_MEMBERS = Permissions.MOVE_MEMBERS;
object[value58] = {title: Reflect.apply(string, intl, [YtjJPQ]), description: r10, flag: MOVE_MEMBERS};
let REQUEST_TO_SPEAK = Permissions.REQUEST_TO_SPEAK;
const value59 = REQUEST_TO_SPEAK.toString();
const object38 = {};
object38.title = intl.string(t['5kicT2']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object38.description = type === GUILD_CATEGORY ? t.T1lMSl : t.uzlYFE;
REQUEST_TO_SPEAK = Permissions.REQUEST_TO_SPEAK;
object38.flag = REQUEST_TO_SPEAK;
object[value59] = object38;
let MANAGE_THREADS = Permissions.MANAGE_THREADS;
const value60 = MANAGE_THREADS.toString();
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
MANAGE_THREADS = Permissions.MANAGE_THREADS;
object[value60] = {title: GUILD_THREADS_ONLY.has(type) ? intl.string(t.ossiZD) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t.QKe7Q3) : intl.string(t.kEqgr7),
description: GUILD_CATEGORY === type ? t.S31soU : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['XLi/jG'] : t.yvan0j,
flag: MANAGE_THREADS};
let CREATE_PUBLIC_THREADS = Permissions.CREATE_PUBLIC_THREADS;
const value64 = CREATE_PUBLIC_THREADS.toString();
const object39 = {};
object39.title = intl.string(t['25rKnX']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object39.description = type === GUILD_CATEGORY ? t['+M1yLj'] : t['5SDtGB'];
CREATE_PUBLIC_THREADS = Permissions.CREATE_PUBLIC_THREADS;
object39.flag = CREATE_PUBLIC_THREADS;
object[value64] = object39;
let CREATE_PRIVATE_THREADS = Permissions.CREATE_PRIVATE_THREADS;
const value65 = CREATE_PRIVATE_THREADS.toString();
string = intl.string;
const QwbTSa = t.QwbTSa;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['hBS/zn'] : t.Chg2zd;
CREATE_PRIVATE_THREADS = Permissions.CREATE_PRIVATE_THREADS;
object[value65] = {title: Reflect.apply(string, intl, [QwbTSa]), description: r1, flag: CREATE_PRIVATE_THREADS};
let SEND_MESSAGES_IN_THREADS = Permissions.SEND_MESSAGES_IN_THREADS;
const value66 = SEND_MESSAGES_IN_THREADS.toString();
const object40 = {};
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
object40.title = GUILD_THREADS_ONLY.has(type) ? intl.string(t.fqhqWm) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t['5QlVGy']) : intl.string(t.fTE74g);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object40.description = GUILD_CATEGORY === type ? t.DlIVcN : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.XTnrPH : t.xHO6Me;
SEND_MESSAGES_IN_THREADS = Permissions.SEND_MESSAGES_IN_THREADS;
object40.flag = SEND_MESSAGES_IN_THREADS;
object[value66] = object40;
let MANAGE_EVENTS = Permissions.MANAGE_EVENTS;
const value70 = MANAGE_EVENTS.toString();
string = intl.string;
const HIgA5a = t.HIgA5a;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.CP2sz4 : t['4pO/TY'];
MANAGE_EVENTS = Permissions.MANAGE_EVENTS;
object[value70] = {title: Reflect.apply(string, intl, [HIgA5a]), description: r1, flag: MANAGE_EVENTS};
let CREATE_EVENTS = Permissions.CREATE_EVENTS;
const value71 = CREATE_EVENTS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.XpibmC : t.sPoBLa;
CREATE_EVENTS = Permissions.CREATE_EVENTS;
object[value71] = {title: intl.string(t.qyjZua), description: r1, flag: CREATE_EVENTS};
let SET_VOICE_CHANNEL_STATUS = Permissions.SET_VOICE_CHANNEL_STATUS;
const value72 = SET_VOICE_CHANNEL_STATUS.toString();
string = intl.string;
const VBwkUf = t.VBwkUf;
const r4 = a2 == null ? t.C6BzXx : a2.enableHangoutWindow ? t.CYcJ6H : t.C6BzXx;
SET_VOICE_CHANNEL_STATUS = Permissions.SET_VOICE_CHANNEL_STATUS;
object[value72] = {title: Reflect.apply(string, intl, [VBwkUf]), description: r4, flag: SET_VOICE_CHANNEL_STATUS};
return object;
}
}
function getChannelPermissionSpecMap(a0, a1, a2) { // fn#65083, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8305:1016, offset: 0x01bbf888, size: 10536 bytes, params: 4, frame: 29
var r1;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var property;
var defaultImport;
var format;
var WFwfSD;
var defaultImport2;
var XRxOo0;
var defaultImport4;
var defaultImport5;
var GEi6Ym;
var defaultImport6;
var defaultImport7;
var defaultImport8;
var Ij0yKX;
var intl2;
const intl3 = (require(1244) /* metro dependency 1244: indexNative */).intl;
var g5MzON;
var intl4;
const type = a0.type;
const object4 = {};
let VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
const value2 = VIEW_CHANNEL.toString();
const object6 = {};
let GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object6.title = type === GUILD_CATEGORY ? intl.string(t.uV83yi) : intl.string(t['W/A4Qp']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object6.description = a1 ? GUILD_CATEGORY === type ? t['o/vBzj'] : ChannelTypes.GUILD_VOICE === type || ChannelTypes.GUILD_STAGE_VOICE === type ? t.ejL1Wo : t['3jG0Bo'] : type === GUILD_CATEGORY ? t.SzosGs : t.M2iEy3;
VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
object6.flag = VIEW_CHANNEL;
object4[value2] = object6;
let MANAGE_CHANNELS = Permissions.MANAGE_CHANNELS;
const value5 = MANAGE_CHANNELS.toString();
const object8 = {};
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object8.title = type === GUILD_CATEGORY ? intl.string(t['9qLtWs']) : intl.string(t.nAw15L);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object8.description = GUILD_CATEGORY === type ? t.KJ2JnG : ChannelTypes.GUILD_VOICE === type ? t['+gl2ne'] : ChannelTypes.GUILD_STAGE_VOICE === type ? t.SDX669 : t.ydL28i;
MANAGE_CHANNELS = Permissions.MANAGE_CHANNELS;
object8.flag = MANAGE_CHANNELS;
object4[value5] = object8;
let MANAGE_ROLES = Permissions.MANAGE_ROLES;
const value8 = MANAGE_ROLES.toString();
const value9 = undefined;
let string = intl.string;
const ICb6am = t.ICb6am;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r12 = GUILD_CATEGORY === type ? t.TyyCMD : ChannelTypes.GUILD_STAGE_VOICE === type ? t.hcw4mx : t.hOMXOv;
MANAGE_ROLES = Permissions.MANAGE_ROLES;
object4[value8] = {title: Reflect.apply(string, intl, [ICb6am]), description: r12, flag: MANAGE_ROLES};
let MANAGE_WEBHOOKS = Permissions.MANAGE_WEBHOOKS;
const value10 = MANAGE_WEBHOOKS.toString();
const object11 = {};
object11.title = intl.string(t['/ADKmM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object11.description = type === GUILD_CATEGORY ? t['K5+ZZ7'] : t.CYBZry;
MANAGE_WEBHOOKS = Permissions.MANAGE_WEBHOOKS;
object11.flag = MANAGE_WEBHOOKS;
object4[value10] = object11;
let CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
const value11 = CREATE_INSTANT_INVITE.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r9 = GUILD_CATEGORY === type ? t['3YFAAX'] : ChannelTypes.GUILD_VOICE === type || ChannelTypes.GUILD_STAGE_VOICE === type ? t.lUCs1n : t.q4g2aI;
CREATE_INSTANT_INVITE = Permissions.CREATE_INSTANT_INVITE;
object4[value11] = {title: intl.string(t.zJrgTG), description: r9, flag: CREATE_INSTANT_INVITE};
let SEND_MESSAGES = Permissions.SEND_MESSAGES;
const value12 = SEND_MESSAGES.toString();
const object13 = {};
let GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
object13.title = GUILD_THREADS_ONLY.has(type) ? intl.string(t.nJwAHX) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t.S1VOwd) : intl.string(t.T32rkC);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r1 = t.IjeLuu;
} else if (ChannelTypes.GUILD_FORUM === type) {
r1 = a2 == null ? t.LG9VAi : a2.createPostsDisabled ? a0.isMediaChannel() ? t.LG9VAi : (importDefault(8121) /* metro dependency 8121: ForumPlatformUtilsNative */).getForumChannelPermissionText() : t.LG9VAi;
} else if (ChannelTypes.GUILD_MEDIA === type) {
r1 = t.LG9VAi;
} else if (ChannelTypes.GUILD_ANNOUNCEMENT === type) {
format = intl.format;
WFwfSD = t.WFwfSD;
defaultImport2 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r1 = Reflect.apply(format, intl, [WFwfSD,
{articleURL: defaultImport2.getArticleURL(HelpdeskArticles.ANNOUNCEMENT_CHANNELS)}]);
} else if (ChannelTypes.GUILD_VOICE === type) {
defaultImport = importDefault(8122) /* metro dependency 8122: GuildTiVPlatformUtilsNative */;
r1 = defaultImport.getTextInVoiceSendMessageChannelPermissionText(a2 == null ? value9 : a2.sendMessagesDisabled);
} else {
r1 = t.WQ6zpT;
}
object13.description = r1;
SEND_MESSAGES = Permissions.SEND_MESSAGES;
object13.flag = SEND_MESSAGES;
object4[value12] = object13;
let EMBED_LINKS = Permissions.EMBED_LINKS;
const value19 = EMBED_LINKS.toString();
const object14 = {};
object14.title = intl.string(t['969dEL']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object14.description = type === GUILD_CATEGORY ? t['7zlUay'] : t.XFFhA0;
EMBED_LINKS = Permissions.EMBED_LINKS;
object14.flag = EMBED_LINKS;
object4[value19] = object14;
let ATTACH_FILES = Permissions.ATTACH_FILES;
const value20 = ATTACH_FILES.toString();
const object16 = {};
object16.title = intl.string(t['3AS4UM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object16.description = type === GUILD_CATEGORY ? t.XREf9l : t.WK9r7F;
ATTACH_FILES = Permissions.ATTACH_FILES;
object16.flag = ATTACH_FILES;
object4[value20] = object16;
let ADD_REACTIONS = Permissions.ADD_REACTIONS;
const value21 = ADD_REACTIONS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
let r11 = GUILD_CATEGORY === type ? t.pZT2Zh : ChannelTypes.GUILD_VOICE === type ? t.xSSbIs : t.PVjR1Y;
ADD_REACTIONS = Permissions.ADD_REACTIONS;
object4[value21] = {title: intl.string(t.yEoJAr), description: r11, flag: ADD_REACTIONS};
let USE_EXTERNAL_EMOJIS = Permissions.USE_EXTERNAL_EMOJIS;
const value22 = USE_EXTERNAL_EMOJIS.toString();
const object17 = {};
object17.title = intl.string(t['+bxf3H']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object17.description = type === GUILD_CATEGORY ? t.mWAbK4 : t.Qc5vOr;
USE_EXTERNAL_EMOJIS = Permissions.USE_EXTERNAL_EMOJIS;
object17.flag = USE_EXTERNAL_EMOJIS;
object4[value22] = object17;
let USE_EXTERNAL_STICKERS = Permissions.USE_EXTERNAL_STICKERS;
const value23 = USE_EXTERNAL_STICKERS.toString();
string = intl.string;
const ERNhYf = t.ERNhYf;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['39whJ4'] : t.VF4fZZ;
USE_EXTERNAL_STICKERS = Permissions.USE_EXTERNAL_STICKERS;
object4[value23] = {title: Reflect.apply(string, intl, [ERNhYf]), description: r1, flag: USE_EXTERNAL_STICKERS};
let MENTION_EVERYONE = Permissions.MENTION_EVERYONE;
const value24 = MENTION_EVERYONE.toString();
const GUILD_STAGE_VOICE = ChannelTypes.GUILD_STAGE_VOICE;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
MENTION_EVERYONE = Permissions.MENTION_EVERYONE;
object4[value24] = {title: type === GUILD_STAGE_VOICE ? intl.string(t.VDUAHO) : intl.string(t.Y78KGC),
description: type === GUILD_CATEGORY ? t['HOhg/B'] : type === ChannelTypes.GUILD_STAGE_VOICE ? t.rZn1oO : t['6IUSdt'],
flag: MENTION_EVERYONE};
let MANAGE_MESSAGES = Permissions.MANAGE_MESSAGES;
const value27 = MANAGE_MESSAGES.toString();
const object18 = {};
object18.title = intl.string(t['6lU9xM']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r11 = t['5R9nYh'];
} else if (ChannelTypes.GUILD_ANNOUNCEMENT === type) {
format = intl.format;
XRxOo0 = t.XRxOo0;
defaultImport4 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r11 = Reflect.apply(format, intl, [XRxOo0,
{articleURL: defaultImport4.getArticleURL(HelpdeskArticles.ANNOUNCEMENT_CHANNELS)}]);
} else {
r11 = t['SeA+G9'];
}
object18.description = r11;
MANAGE_MESSAGES = Permissions.MANAGE_MESSAGES;
object18.flag = MANAGE_MESSAGES;
object4[value27] = object18;
let PIN_MESSAGES = Permissions.PIN_MESSAGES;
const value29 = PIN_MESSAGES.toString();
string = intl.string;
const Y5BI39 = t.Y5BI39;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.gmbD87 : t['0l2EjL'];
PIN_MESSAGES = Permissions.PIN_MESSAGES;
object4[value29] = {title: Reflect.apply(string, intl, [Y5BI39]), description: r1, flag: PIN_MESSAGES};
let BYPASS_SLOWMODE = Permissions.BYPASS_SLOWMODE;
const value30 = BYPASS_SLOWMODE.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.C4t1Xu : t.Ha1xbw;
BYPASS_SLOWMODE = Permissions.BYPASS_SLOWMODE;
object4[value30] = {title: intl.string(t.kqcjeV), description: r1, flag: BYPASS_SLOWMODE};
let MANAGE_OFFICIAL_MESSAGES = Permissions.MANAGE_OFFICIAL_MESSAGES;
const value31 = MANAGE_OFFICIAL_MESSAGES.toString();
string = intl.string;
const Aj9ruN = t.Aj9ruN;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['Pf0e/Q'] : t.qEbw4W;
MANAGE_OFFICIAL_MESSAGES = Permissions.MANAGE_OFFICIAL_MESSAGES;
object4[value31] = {title: Reflect.apply(string, intl, [Aj9ruN]), description: r1, flag: MANAGE_OFFICIAL_MESSAGES};
let READ_MESSAGE_HISTORY = Permissions.READ_MESSAGE_HISTORY;
const value32 = READ_MESSAGE_HISTORY.toString();
const object19 = {};
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
const value33 = GUILD_THREADS_ONLY.has(type);
string = intl.string;
object19.title = value33 ? Reflect.apply(string, intl, [t['0RQwtn']]) : Reflect.apply(string, intl, [t.l9ufaR]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
r1 = t['cJRv/g'];
} else if (ChannelTypes.GUILD_VOICE === type) {
defaultImport5 = importDefault(8122) /* metro dependency 8122: GuildTiVPlatformUtilsNative */;
r1 = defaultImport5.getTextInVoiceReadMessageHistoryChannelPermissionText(a2 == null ? value9 : a2.readMessageHistoryDisabled);
} else {
r1 = ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.RqCc7i : t.cuMfH0;
}
object19.description = r1;
READ_MESSAGE_HISTORY = Permissions.READ_MESSAGE_HISTORY;
object19.flag = READ_MESSAGE_HISTORY;
object4[value32] = object19;
let SEND_TTS_MESSAGES = Permissions.SEND_TTS_MESSAGES;
const value37 = SEND_TTS_MESSAGES.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.b7pc9U : t.CpakGz;
SEND_TTS_MESSAGES = Permissions.SEND_TTS_MESSAGES;
object4[value37] = {title: intl.string(t.mMbwh7), description: r1, flag: SEND_TTS_MESSAGES};
let USE_APPLICATION_COMMANDS = Permissions.USE_APPLICATION_COMMANDS;
const value38 = USE_APPLICATION_COMMANDS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['D+qW0J'] : t.ReG3gG;
USE_APPLICATION_COMMANDS = Permissions.USE_APPLICATION_COMMANDS;
object4[value38] = {title: intl.string(t.nkoPOt), description: r1, flag: USE_APPLICATION_COMMANDS};
let SEND_VOICE_MESSAGES = Permissions.SEND_VOICE_MESSAGES;
const value39 = SEND_VOICE_MESSAGES.toString();
string = intl.string;
const WlWSBT = t.WlWSBT;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.gavGfv : t.BhEo9V;
SEND_VOICE_MESSAGES = Permissions.SEND_VOICE_MESSAGES;
object4[value39] = {title: Reflect.apply(string, intl, [WlWSBT]), description: r1, flag: SEND_VOICE_MESSAGES};
let SEND_POLLS = Permissions.SEND_POLLS;
const value40 = SEND_POLLS.toString();
string = intl.string;
const UMQ7Ww = t.UMQ7Ww;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r2 = type === GUILD_CATEGORY ? t['18Ya7L'] : t.ckKKIO;
SEND_POLLS = Permissions.SEND_POLLS;
object4[value40] = {title: Reflect.apply(string, intl, [UMQ7Ww]), description: r2, flag: SEND_POLLS};
let CONNECT = Permissions.CONNECT;
const value41 = CONNECT.toString();
string = intl.string;
const S0W8Z5 = t.S0W8Z5;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
let r10 = a1 ? GUILD_CATEGORY === type ? t.XcrieN : ChannelTypes.GUILD_STAGE_VOICE === type ? t.SOFNhP : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.LsS8xT : t.j4AyO8 : GUILD_CATEGORY === type ? t.stA0Hl : ChannelTypes.GUILD_STAGE_VOICE === type ? t['G9+Qie'] : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['QU/Rw8'] : t.HvG8uR;
CONNECT = Permissions.CONNECT;
object4[value41] = {title: Reflect.apply(string, intl, [S0W8Z5]), description: r10, flag: CONNECT};
let SPEAK = Permissions.SPEAK;
const value42 = SPEAK.toString();
const object21 = {};
object21.title = intl.string(t['8w1tIR']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object21.description = GUILD_CATEGORY === type ? t.iXhS6R : ChannelTypes.GUILD_STAGE_VOICE === type ? t.a8n741 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['+VXsJI'] : t['568E6d'];
SPEAK = Permissions.SPEAK;
object21.flag = SPEAK;
object4[value42] = object21;
let STREAM = Permissions.STREAM;
const value43 = STREAM.toString();
string = intl.string;
const FlNoSV = t.FlNoSV;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t['ryG0/J'] : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.AuEQEC : ChannelTypes.GUILD_STAGE_VOICE === type ? t.swJcN6 : t.RY8rIc;
STREAM = Permissions.STREAM;
object4[value43] = {title: Reflect.apply(string, intl, [FlNoSV]), description: r10, flag: STREAM};
let USE_EMBEDDED_ACTIVITIES = Permissions.USE_EMBEDDED_ACTIVITIES;
const value44 = USE_EMBEDDED_ACTIVITIES.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t.maNzCO : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.RyEwla : t.qinvMU;
USE_EMBEDDED_ACTIVITIES = Permissions.USE_EMBEDDED_ACTIVITIES;
object4[value44] = {title: intl.string(t.rLSGeh), description: r10, flag: USE_EMBEDDED_ACTIVITIES};
let USE_EXTERNAL_APPS = Permissions.USE_EXTERNAL_APPS;
const value45 = USE_EXTERNAL_APPS.toString();
const object22 = {};
object22.title = intl.string(t['3TzAk0']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object22.description = GUILD_CATEGORY === type ? t.bgIY3H : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.qPUPip : t.czqMLp;
USE_EXTERNAL_APPS = Permissions.USE_EXTERNAL_APPS;
object22.flag = USE_EXTERNAL_APPS;
object4[value45] = object22;
let USE_SOUNDBOARD = Permissions.USE_SOUNDBOARD;
const value46 = USE_SOUNDBOARD.toString();
const object23 = {};
string = intl.string;
const Bco7NG = t.Bco7NG;
object23.title = Reflect.apply(string, intl, [Bco7NG]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
format = intl.format;
property = t['0kBp/0'];
defaultImport8 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport8.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_TEXT === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_FORUM === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else if (ChannelTypes.GUILD_MEDIA === type) {
format = intl.format;
property = t['6eYqU1'];
defaultImport7 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [property,
{helpCenterArticle: defaultImport7.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
} else {
format = intl.format;
GEi6Ym = t.GEi6Ym;
defaultImport6 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r10 = Reflect.apply(format, intl, [GEi6Ym,
{helpCenterArticle: defaultImport6.getArticleURL(HelpdeskArticles.SOUNDBOARD)}]);
}
object23.description = r10;
USE_SOUNDBOARD = Permissions.USE_SOUNDBOARD;
object23.flag = USE_SOUNDBOARD;
object4[value46] = object23;
let USE_EXTERNAL_SOUNDS = Permissions.USE_EXTERNAL_SOUNDS;
const value50 = USE_EXTERNAL_SOUNDS.toString();
USE_EXTERNAL_SOUNDS = Permissions.USE_EXTERNAL_SOUNDS;
object4[value50] = {title: intl.string(t.pwaVJ6), description: t.qDpPtX, flag: USE_EXTERNAL_SOUNDS};
let USE_VAD = Permissions.USE_VAD;
const value51 = USE_VAD.toString();
const object24 = {};
object24.title = intl.string(t['08zAV7']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object24.description = GUILD_CATEGORY === type ? t.fUYPly : ChannelTypes.GUILD_STAGE_VOICE === type ? t.BJKqsW : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['3GJwsc'] : t.s2eihY;
USE_VAD = Permissions.USE_VAD;
object24.flag = USE_VAD;
object4[value51] = object24;
let PRIORITY_SPEAKER = Permissions.PRIORITY_SPEAKER;
const value52 = PRIORITY_SPEAKER.toString();
const object25 = {};
string = intl.string;
const BVK71i = t.BVK71i;
object25.title = Reflect.apply(string, intl, [BVK71i]);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
if (GUILD_CATEGORY === type) {
format = intl.format;
g5MzON = t.g5MzON;
intl4 = (require(1244) /* metro dependency 1244: indexNative */).intl;
r10 = Reflect.apply(format, intl, [g5MzON, {keybind: intl4.string(t.DkSwJ2)}]);
} else if (ChannelTypes.GUILD_TEXT === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else if (ChannelTypes.GUILD_FORUM === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else if (ChannelTypes.GUILD_MEDIA === type) {
r10 = intl.format(t['4nbjL0'], {keybind: intl3.string(t.DkSwJ2)});
} else {
format = intl.format;
Ij0yKX = t.Ij0yKX;
intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
r10 = Reflect.apply(format, intl, [Ij0yKX, {keybind: intl2.string(t.DkSwJ2)}]);
}
object25.description = r10;
PRIORITY_SPEAKER = Permissions.PRIORITY_SPEAKER;
object25.flag = PRIORITY_SPEAKER;
object4[value52] = object25;
let MUTE_MEMBERS = Permissions.MUTE_MEMBERS;
const value56 = MUTE_MEMBERS.toString();
const object27 = {};
object27.title = intl.string(t['8EI30/']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object27.description = GUILD_CATEGORY === type ? t.bcuobK : ChannelTypes.GUILD_STAGE_VOICE === type ? t.EbvdH9 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.KYDG2K : t.LW5C9P;
MUTE_MEMBERS = Permissions.MUTE_MEMBERS;
object27.flag = MUTE_MEMBERS;
object4[value56] = object27;
let DEAFEN_MEMBERS = Permissions.DEAFEN_MEMBERS;
const value57 = DEAFEN_MEMBERS.toString();
const object28 = {};
object28.title = intl.string(t['9L47Fr']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object28.description = GUILD_CATEGORY === type ? t.amZ5vn : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['d+i1nX'] : t.UAdIxo;
DEAFEN_MEMBERS = Permissions.DEAFEN_MEMBERS;
object28.flag = DEAFEN_MEMBERS;
object4[value57] = object28;
let MOVE_MEMBERS = Permissions.MOVE_MEMBERS;
const value58 = MOVE_MEMBERS.toString();
string = intl.string;
const YtjJPQ = t.YtjJPQ;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r10 = GUILD_CATEGORY === type ? t.XmoyRD : ChannelTypes.GUILD_STAGE_VOICE === type ? t.bizKz6 : ChannelTypes.GUILD_TEXT === type || ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.cbdQy2 : t.nSD1ah;
MOVE_MEMBERS = Permissions.MOVE_MEMBERS;
object4[value58] = {title: Reflect.apply(string, intl, [YtjJPQ]), description: r10, flag: MOVE_MEMBERS};
let REQUEST_TO_SPEAK = Permissions.REQUEST_TO_SPEAK;
const value59 = REQUEST_TO_SPEAK.toString();
const object31 = {};
object31.title = intl.string(t['5kicT2']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object31.description = type === GUILD_CATEGORY ? t.T1lMSl : t.uzlYFE;
REQUEST_TO_SPEAK = Permissions.REQUEST_TO_SPEAK;
object31.flag = REQUEST_TO_SPEAK;
object4[value59] = object31;
let MANAGE_THREADS = Permissions.MANAGE_THREADS;
const value60 = MANAGE_THREADS.toString();
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
MANAGE_THREADS = Permissions.MANAGE_THREADS;
object4[value60] = {title: GUILD_THREADS_ONLY.has(type) ? intl.string(t.ossiZD) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t.QKe7Q3) : intl.string(t.kEqgr7),
description: GUILD_CATEGORY === type ? t.S31soU : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t['XLi/jG'] : t.yvan0j,
flag: MANAGE_THREADS};
let CREATE_PUBLIC_THREADS = Permissions.CREATE_PUBLIC_THREADS;
const value64 = CREATE_PUBLIC_THREADS.toString();
const object32 = {};
object32.title = intl.string(t['25rKnX']);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object32.description = type === GUILD_CATEGORY ? t['+M1yLj'] : t['5SDtGB'];
CREATE_PUBLIC_THREADS = Permissions.CREATE_PUBLIC_THREADS;
object32.flag = CREATE_PUBLIC_THREADS;
object4[value64] = object32;
let CREATE_PRIVATE_THREADS = Permissions.CREATE_PRIVATE_THREADS;
const value65 = CREATE_PRIVATE_THREADS.toString();
string = intl.string;
const QwbTSa = t.QwbTSa;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t['hBS/zn'] : t.Chg2zd;
CREATE_PRIVATE_THREADS = Permissions.CREATE_PRIVATE_THREADS;
object4[value65] = {title: Reflect.apply(string, intl, [QwbTSa]), description: r1, flag: CREATE_PRIVATE_THREADS};
let SEND_MESSAGES_IN_THREADS = Permissions.SEND_MESSAGES_IN_THREADS;
const value66 = SEND_MESSAGES_IN_THREADS.toString();
const object33 = {};
GUILD_THREADS_ONLY = ChannelTypesSets.GUILD_THREADS_ONLY;
object33.title = GUILD_THREADS_ONLY.has(type) ? intl.string(t.fqhqWm) : type === ChannelTypes.GUILD_CATEGORY ? intl.string(t['5QlVGy']) : intl.string(t.fTE74g);
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
object33.description = GUILD_CATEGORY === type ? t.DlIVcN : ChannelTypes.GUILD_FORUM === type || ChannelTypes.GUILD_MEDIA === type ? t.XTnrPH : t.xHO6Me;
SEND_MESSAGES_IN_THREADS = Permissions.SEND_MESSAGES_IN_THREADS;
object33.flag = SEND_MESSAGES_IN_THREADS;
object4[value66] = object33;
let MANAGE_EVENTS = Permissions.MANAGE_EVENTS;
const value70 = MANAGE_EVENTS.toString();
string = intl.string;
const HIgA5a = t.HIgA5a;
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.CP2sz4 : t['4pO/TY'];
MANAGE_EVENTS = Permissions.MANAGE_EVENTS;
object4[value70] = {title: Reflect.apply(string, intl, [HIgA5a]), description: r1, flag: MANAGE_EVENTS};
let CREATE_EVENTS = Permissions.CREATE_EVENTS;
const value71 = CREATE_EVENTS.toString();
GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
r1 = type === GUILD_CATEGORY ? t.XpibmC : t.sPoBLa;
CREATE_EVENTS = Permissions.CREATE_EVENTS;
object4[value71] = {title: intl.string(t.qyjZua), description: r1, flag: CREATE_EVENTS};
let SET_VOICE_CHANNEL_STATUS = Permissions.SET_VOICE_CHANNEL_STATUS;
const value72 = SET_VOICE_CHANNEL_STATUS.toString();
string = intl.string;
const VBwkUf = t.VBwkUf;
const r4 = a2 == null ? t.C6BzXx : a2.enableHangoutWindow ? t.CYcJ6H : t.C6BzXx;
SET_VOICE_CHANNEL_STATUS = Permissions.SET_VOICE_CHANNEL_STATUS;
object4[value72] = {title: Reflect.apply(string, intl, [VBwkUf]), description: r4, flag: SET_VOICE_CHANNEL_STATUS};
return object4;
}
global.__d(_fun65082, 8120, [661, 1244, 8121, 1948, 8122,
2]) /* metro module 8120, dependencies: [661, 1244, 8121, 1948, 8122, 2] */;
File diff suppressed because it is too large. Load diff
@@ -1,37 +1,41 @@
/* Metro module 11392; source: modules/channel_permissions/native/ChannelPermissionsUtils.tsx; dependencies: [661, 683, 4080, 9095, 1962, 11393, 2] */
import * as FileImportTrackerModule from '../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../../Constants.tsx'; /* Metro dependency 661 */
function _fun87309(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#87309, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11578:6, offset: 0x01fb7d53, size: 137 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/native/ChannelPermissionsUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/native/ChannelPermissionsUtils.tsx');
exports.openAddMembersActionSheet = openAddMembersActionSheet;
exports.openChannelMembersActionSheet = openChannelMembersActionSheet;
function openAddMembersActionSheet(a0) { // fn#87310, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11578:245, offset: 0x01fb7ddc, size: 171 bytes, params: 2, frame: 21
let value = a1;
const r6 = value !== undefined ? value : false;
const defaultImport = importDefault(dependencyMap[1]);
const track = defaultImport.track;
const OPEN_POPOUT = AnalyticEvents.OPEN_POPOUT;
Reflect.apply(track, defaultImport, [OPEN_POPOUT, {type: 'Grant Channel Access'}]);
const defaultImport2 = importDefault(dependencyMap[2]);
const openLazy = defaultImport2.openLazy;
value = require(dependencyMap[4]);
value = value(dependencyMap[3], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'channel-add-members-' + a0.id, {channel: a0, canSkip: r6}]);
}
function openChannelMembersActionSheet(a0, a1) { // fn#87311, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11578:472, offset: 0x01fb7e87, size: 159 bytes, params: 3, frame: 20
const defaultImport = importDefault(dependencyMap[1]);
const track = defaultImport.track;
const OPEN_POPOUT = AnalyticEvents.OPEN_POPOUT;
Reflect.apply(track, defaultImport, [OPEN_POPOUT, {type: 'Manage Channel Access'}]);
const defaultImport2 = importDefault(dependencyMap[2]);
const openLazy = defaultImport2.openLazy;
let value = require(dependencyMap[4]);
value = value(dependencyMap[5], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'channel-members-' + a0, {channelId: a0, guildId: a1}]);
}
}
function openAddMembersActionSheet(a0) { // fn#87310, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11578:245, offset: 0x01fb7ddc, size: 171 bytes, params: 2, frame: 21
let value = a1;
const r6 = value !== undefined ? value : false;
const defaultImport = importDefault(dependencyMap[1]);
const track = defaultImport.track;
const OPEN_POPOUT = AnalyticEvents.OPEN_POPOUT;
Reflect.apply(track, defaultImport, [OPEN_POPOUT, {type: 'Grant Channel Access'}]);
const defaultImport2 = importDefault(dependencyMap[2]);
const openLazy = defaultImport2.openLazy;
value = require(dependencyMap[4]);
value = value(dependencyMap[3], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'channel-add-members-' + a0.id, {channel: a0, canSkip: r6}]);
}
function openChannelMembersActionSheet(a0, a1) { // fn#87311, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11578:472, offset: 0x01fb7e87, size: 159 bytes, params: 3, frame: 20
const defaultImport = importDefault(dependencyMap[1]);
const track = defaultImport.track;
const OPEN_POPOUT = AnalyticEvents.OPEN_POPOUT;
Reflect.apply(track, defaultImport, [OPEN_POPOUT, {type: 'Manage Channel Access'}]);
const defaultImport2 = importDefault(dependencyMap[2]);
const openLazy = defaultImport2.openLazy;
let value = require(dependencyMap[4]);
value = value(dependencyMap[5], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'channel-members-' + a0, {channelId: a0, guildId: a1}]);
}
global.__d(_fun87309, 11392, [661, 683, 4080, 9095, 1962, 11393,
2]) /* metro module 11392, dependencies: [661, 683, 4080, 9095, 1962, 11393, 2] */;
File diff suppressed because it is too large. Load diff
@@ -1,16 +1,34 @@
/* Metro module 11393; source: modules/channel_permissions/native/action_sheets/ChannelMembersActionSheet.tsx; dependencies: [31, 27, 1379, 1945, 1938, 1867, 3784, 661, 33, 4501, 697, 1585, 566, 1484, 4805, 9088, 1244, 6275, 6758, 5278, 4080, 8148, 11394, 7002, 7975, 11392, 10859, 1305, 6277, 9096, 4573, 2] */
import Native from '../../../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import ChannelStore from '../../../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
import UseSafeAreaInsetsNative from '../../../safe_area/useSafeAreaInsets.native.tsx'; /* Metro dependency 1585 */
import GuildStore from '../../../../stores/GuildStore.tsx'; /* Metro dependency 1867 */
import GuildRoleStore from '../../../../stores/GuildRoleStore.tsx'; /* Metro dependency 1938 */
import GuildMemberStore from '../../../../stores/GuildMemberStore.tsx'; /* Metro dependency 1945 */
import PermissionStore from '../../../../stores/PermissionStore.tsx'; /* Metro dependency 3784 */
import ActionSheetActionCreators from '../../../action_sheet/native/ActionSheetActionCreators.tsx'; /* Metro dependency 4080 */
import UseChannelName from '../../../channel/useChannelName.tsx'; /* Metro dependency 4805 */
import ChannelSettingsActionCreators from '../../../../actions/ChannelSettingsActionCreators.tsx'; /* Metro dependency 8148 */
import ChannelOverwritesItem from '../components/ChannelOverwritesItem.tsx'; /* Metro dependency 9096 */
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 ConstantsModule from '../../../../Constants.tsx'; /* Metro dependency 661 */
import * as IndexNativeModule from '../../../../intl/index.native.tsx'; /* Metro dependency 1244 */
import * as UseNavigationNativeModule from '../../../../design/components/Navigator/native/useNavigation.native.tsx'; /* Metro dependency 1484 */
import * as TextModule from '../../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */
import * as BottomSheetNativeModule from '../../../../design/components/Sheet/native/BottomSheet.native.tsx'; /* Metro dependency 6275 */
import * as Module06277Module from '../../../../by-id/module-06277.js'; /* Metro dependency 6277 */
import * as BottomSheetTitleHeaderNativeModule from '../../../../design/components/Sheet/native/BottomSheetTitleHeader.native.tsx'; /* Metro dependency 6758 */
import * as ChannelPermissionsUtilsModule from '../../ChannelPermissionsUtils.tsx'; /* Metro dependency 9088 */
import * as ChannelDetailsUtilsModule from '../../../main_tabs_v2/native/sidebar/details/ChannelDetailsUtils.tsx'; /* Metro dependency 11394 */
function _fun87312(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#87312, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:6, offset: 0x01fb7f26, size: 380 bytes, params: 8, frame: 21
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_3 = (require(27) /* metro dependency 27 */).View;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildRoleStore = importDefault(1938) /* metro dependency 1938: GuildRoleStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const permissionStore = importDefault(3784) /* metro dependency 3784: PermissionStore */;
let value = require(661) /* metro dependency 661: Constants */;
ReactModule;
let value = ConstantsModule;
const env0_9 = value.ChannelSettingsSections;
const env0_10 = value.Permissions;
value = require(33) /* metro dependency 33 */;
@@ -18,151 +36,178 @@ function _fun87312(global, require, importDefault, importAll, module, exports, d
const env0_12 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
const PX_12 = (Native).space.PX_12;
const env0_13 = Reflect.apply(createStyles, value, [{container: {'paddingHorizontal': 16, 'flex': 1},
sectionRowWrapper: {paddingVertical: PX_12}, warning: {'margin': 16, 'marginBottom': 0}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/native/action_sheets/ChannelMembersActionSheet.tsx');
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/native/action_sheets/ChannelMembersActionSheet.tsx');
exports.default = ChannelMembersActionSheet;
}
function ChannelMembersActionSheet({channelId, guildId}) { // fn#87313, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:531, offset: 0x01fb80a2, size: 1293 bytes, params: 2, frame: 34
var r7;
var r9;
var PressableOpacity;
var object5;
const styles = useStyles();
const value2 = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)();
const channel = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelStore], function() {
return ChannelStore.getChannel(channelId);
});
const {guild,
sortedGuildRoles} = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildStore,
GuildRoleStore], _fun87315, [channel]);
const value4 = (require(566) /* metro dependency 566: flux */).useStateFromStoresArray([GuildMemberStore],
_fun87316, [channel]);
const env0_4 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const value5 = (importDefault(4805) /* metro dependency 4805: useChannelName */)(channel);
if (channel == null) {
return null;
}
if (guild == null) {
return null;
}
if (sortedGuildRoles == null) {
return null;
}
const can = PermissionStore.can;
const MANAGE_ROLES = Permissions.MANAGE_ROLES;
const value6 = Reflect.apply(can, PermissionStore, [MANAGE_ROLES, channel]);
const existingRolesRows = (require(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingRolesRows(guild,
sortedGuildRoles, channel, channel.accessPermissions);
const existingMembersRows = (require(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingMembersRows(value4,
channel, guild, channel.accessPermissions);
items2 = [];
let push = items2.push;
const object4 = {};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object4.title = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t['LPJmL/']]);
object4.data = existingRolesRows;
Reflect.apply(push, items2, [object4]);
push = items2.push;
const object6 = {};
object6.title = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['9Oq93m']);
object6.data = existingMembersRows;
Reflect.apply(push, items2, [object6]);
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
const object7 = {'scrollable': true, 'header': null, 'startExpanded': true};
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
string = intl.string;
const ES4CC6 = (require(1244) /* metro dependency 1244: indexNative */).t.ES4CC6;
if (value6) {
PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
r7 = <PressableOpacity onPress={onPress_87317} accessibilityRole="button" accessibilityLabel={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.XPDhcc)}>{((SettingsIcon) => <SettingsIcon />)((require(7002) /* metro dependency 7002: SettingsIcon */).SettingsIcon)}</PressableOpacity>;
} else {
r7 = value6;
}
object7.header = <BottomSheetTitleHeader title={Reflect.apply(string, intl,
[ES4CC6])} subtitle={'#' + value5} trailing={r7} />;
if (value6) {
const RowButton = (require(7975) /* metro dependency 7975: RowButtonNative */).RowButton;
r9 = <RowButton label={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dMJ3Y6)} onPress={onPress_87318} icon={((GroupPlusIcon) => <GroupPlusIcon />)((require(10859) /* metro dependency 10859: GroupPlusIcon */).GroupPlusIcon)} />;
} else {
r9 = <View style={styles.warning}>{((HelpMessage) => <HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.INFO}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.VOuiSj)}</HelpMessage>)((require(1305) /* metro dependency 1305: native */).HelpMessage)}</View>;
}
const BottomSheetSectionList = (require(6277) /* metro dependency 6277 */).BottomSheetSectionList;
const bottom = value2.bottom;
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
return (
<BottomSheet {...object7}>
<View style={styles.container}>
{r9}
<BottomSheetSectionList
contentContainerStyle={{paddingBottom: bottom + PX_16}}
renderItem={renderItem_87319}
renderSectionHeader={renderSectionHeader_87320}
sections={items2}
stickySectionHeadersEnabled={false}
function ChannelMembersActionSheet({channelId, guildId}) { // fn#87313, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:531, offset: 0x01fb80a2, size: 1293 bytes, params: 2, frame: 34
var r7;
var r9;
var PressableOpacity;
var object6;
const styles = useStyles();
const value2 = (UseSafeAreaInsetsNative)();
const channel = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelStore], function() {
return ChannelStore.getChannel(channelId);
});
const {guild,
sortedGuildRoles} = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildStore,
GuildRoleStore], _fun87315, [channel]);
const value4 = (require(566) /* metro dependency 566: flux */).useStateFromStoresArray([GuildMemberStore],
_fun87316, [channel]);
const env0_4 = (UseNavigationNativeModule).useNavigation();
const value5 = (UseChannelName)(channel);
if (channel == null) {
return null;
}
if (guild == null) {
return null;
}
if (sortedGuildRoles == null) {
return null;
}
const permissionStoreBinding = PermissionStore;
const can = permissionStoreBinding.can;
const MANAGE_ROLES = Permissions.MANAGE_ROLES;
const value6 = Reflect.apply(can, permissionStoreBinding, [MANAGE_ROLES, channel]);
const existingRolesRows = (ChannelPermissionsUtilsModule).getExistingRolesRows(guild,
sortedGuildRoles, channel, channel.accessPermissions);
const existingMembersRows = (ChannelPermissionsUtilsModule).getExistingMembersRows(value4,
channel, guild, channel.accessPermissions);
items2 = [];
let push = items2.push;
const object = {};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
object.title = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t['LPJmL/']]);
object.data = existingRolesRows;
Reflect.apply(push, items2, [object]);
push = items2.push;
const object2 = {};
object2.title = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['9Oq93m']);
object2.data = existingMembersRows;
Reflect.apply(push, items2, [object2]);
const BottomSheet = (BottomSheetNativeModule).BottomSheet;
const object3 = {'scrollable': true, 'header': null, 'startExpanded': true};
const BottomSheetTitleHeader = (BottomSheetTitleHeaderNativeModule).BottomSheetTitleHeader;
string = intl.string;
const ES4CC6 = (require(1244) /* metro dependency 1244: indexNative */).t.ES4CC6;
if (value6) {
PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
r7 = (
<PressableOpacity
onPress={onPress_87317}
accessibilityRole="button"
accessibilityLabel={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.XPDhcc)}
>
{((SettingsIcon) => <SettingsIcon />)((require(7002) /* metro dependency 7002: SettingsIcon */).SettingsIcon)}
</PressableOpacity>
);
} else {
r7 = value6;
}
object3.header = (
<BottomSheetTitleHeader
title={Reflect.apply(string, intl, [ES4CC6])}
subtitle={'#' + value5}
trailing={r7}
/>
);
if (value6) {
const RowButton = (require(7975) /* metro dependency 7975: RowButtonNative */).RowButton;
r9 = (
<RowButton
label={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dMJ3Y6)}
onPress={onPress_87318}
icon={((GroupPlusIcon) => <GroupPlusIcon />)((require(10859) /* metro dependency 10859: GroupPlusIcon */).GroupPlusIcon)}
/>
</View>
</BottomSheet>
);
}
);
} else {
r9 = (
<View style={styles.warning}>
{((HelpMessage) => <HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.INFO}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.VOuiSj)}</HelpMessage>)((require(1305) /* metro dependency 1305: native */).HelpMessage)}
</View>
);
}
const BottomSheetSectionList = (Module06277Module).BottomSheetSectionList;
const bottom = value2.bottom;
const PX_16 = (Native).space.PX_16;
return (
<BottomSheet {...object3}>
<View style={styles.container}>
{r9}
<BottomSheetSectionList
contentContainerStyle={{paddingBottom: bottom + PX_16}}
renderItem={renderItem_87319}
renderSectionHeader={renderSectionHeader_87320}
sections={items2}
stickySectionHeadersEnabled={false}
/>
</View>
</BottomSheet>
);
function _fun87315() { // fn#87315, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:714, offset: 0x01fb85af, size: 92 bytes, params: 1, frame: 16
const value = environment.__proto__;
const guildStoreBinding = GuildStore;
const getGuild = guildStoreBinding.getGuild;
const channelBinding = channel;
const value3 = undefined;
const value5 = Reflect.apply(getGuild, guildStoreBinding, [channelBinding == null ? value3 : channel.getGuildId()]);
return {guild: value5, sortedGuildRoles: value5 != null ? GuildRoleStore.getSortedRoles(value5.id) : value3};
}
function _fun87315() { // fn#87315, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:714, offset: 0x01fb85af, size: 92 bytes, params: 1, frame: 16
const value = environment.__proto__;
const getGuild = GuildStore.getGuild;
const channelBinding = channel;
const value3 = undefined;
const value5 = Reflect.apply(getGuild, GuildStore, [channelBinding == null ? value3 : channel.getGuildId()]);
return {guild: value5, sortedGuildRoles: value5 != null ? GuildRoleStore.getSortedRoles(value5.id) : value3};
}
function _fun87316() { // fn#87316, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:916, offset: 0x01fb860b, size: 52 bytes, params: 1, frame: 13
const value = environment.__proto__;
return GuildMemberStore.getMemberIds(channel?.getGuildId());
}
function _fun87316() { // fn#87316, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:916, offset: 0x01fb860b, size: 52 bytes, params: 1, frame: 13
const value = environment.__proto__;
return GuildMemberStore.getMemberIds(channel?.getGuildId());
}
function ChannelMembersActionSheetOnPress() { // fn#87317, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:1540, owner: ChannelMembersActionSheet.onPress, offset: 0x01fb863f, size: 119 bytes, params: 1, frame: 18
(ActionSheetActionCreators).hideActionSheet();
const defaultImport2 = ChannelSettingsActionCreators;
const init = defaultImport2.init;
const channelIdBinding = channelId;
Reflect.apply(init, defaultImport2, [channelIdBinding]);
const navigateToChannelDetailsScreen = ChannelDetailsUtilsModule.navigateToChannelDetailsScreen;
const binding = env0_4;
const PERMISSIONS = ChannelSettingsSections.PERMISSIONS;
Reflect.apply(navigateToChannelDetailsScreen, ChannelDetailsUtilsModule, [binding, PERMISSIONS, channelIdBinding,
'channel-members-action-sheet']);
}
function ChannelMembersActionSheetOnPress() { // fn#87317, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:1540, owner: ChannelMembersActionSheet.onPress, offset: 0x01fb863f, size: 119 bytes, params: 1, frame: 18
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
const defaultImport2 = importDefault(8148) /* metro dependency 8148: ChannelSettingsActionCreators */;
const init = defaultImport2.init;
const channelIdBinding = channelId;
Reflect.apply(init, defaultImport2, [channelIdBinding]);
const channelDetailsUtilsModule = require(11394) /* metro dependency 11394: ChannelDetailsUtils */;
const navigateToChannelDetailsScreen = channelDetailsUtilsModule.navigateToChannelDetailsScreen;
const binding = env0_4;
const PERMISSIONS = ChannelSettingsSections.PERMISSIONS;
Reflect.apply(navigateToChannelDetailsScreen, channelDetailsUtilsModule, [binding, PERMISSIONS, channelIdBinding,
'channel-members-action-sheet']);
}
function ChannelMembersActionSheetOnPress_87318() { // fn#87318, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:1950, owner: ChannelMembersActionSheet.onPress, offset: 0x01fb86b6, size: 45 bytes, params: 1, frame: 11
let value = environment.__proto__;
value = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
return value.openAddMembersActionSheet(channel);
}
function ChannelMembersActionSheetOnPress_87318() { // fn#87318, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:1950, owner: ChannelMembersActionSheet.onPress, offset: 0x01fb86b6, size: 45 bytes, params: 1, frame: 11
let value = environment.__proto__;
value = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
return value.openAddMembersActionSheet(channel);
}
function ChannelMembersActionSheetRenderItem({item, index, section}) { // fn#87319, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:2292, owner: ChannelMembersActionSheet.renderItem, offset: 0x01fb86e3, size: 132 bytes, params: 2, frame: 17
const value = environment.__proto__;
return ((Component) => <Component start={index === 0} end={index === section.data.length - 1} guildId={guildId} item={item} channelId={channelId} showType showRemove={env0_5} />)(ChannelOverwritesItem);
}
function ChannelMembersActionSheetRenderItem({item, index, section}) { // fn#87319, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:2292, owner: ChannelMembersActionSheet.renderItem, offset: 0x01fb86e3, size: 132 bytes, params: 2, frame: 17
const value = environment.__proto__;
return ((Component) => <Component start={index === 0} end={index === section.data.length - 1} guildId={guildId} item={item} channelId={channelId} showType showRemove={env0_5} />)(importDefault(9096) /* metro dependency 9096: ChannelOverwritesItem */);
}
function ChannelMembersActionSheetRenderSectionHeader(a0) { // fn#87320, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:2461, owner: ChannelMembersActionSheet.renderSectionHeader, offset: 0x01fb8767, size: 165 bytes, params: 2, frame: 20
const {title, data} = a0.section;
const Text = (TextModule).Text;
const intl = (IndexNativeModule).intl;
return (
<Text
style={styles.sectionRowWrapper}
maxFontSizeMultiplier={2}
accessibilityRole="header"
variant="text-sm/semibold"
color="interactive-text-default"
>
{intl.format((IndexNativeModule).t.u8CWLl, {numberOfItems: data.length,
sectionTitle: title})}
</Text>
);
}
}
function ChannelMembersActionSheetRenderSectionHeader(a0) { // fn#87320, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11579:2461, owner: ChannelMembersActionSheet.renderSectionHeader, offset: 0x01fb8767, size: 165 bytes, params: 2, frame: 20
const {title, data} = a0.section;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<Text
style={styles.sectionRowWrapper}
maxFontSizeMultiplier={2}
accessibilityRole="header"
variant="text-sm/semibold"
color="interactive-text-default"
>
{intl.format((require(1244) /* metro dependency 1244: indexNative */).t.u8CWLl, {numberOfItems: data.length,
sectionTitle: title})}
</Text>
);
}
global.__d(_fun87312, 11393, [31, 27, 1379, 1945, 1938, 1867, 3784, 661, 33, 4501, 697, 1585, 566, 1484, 4805, 9088,
1244, 6275, 6758, 5278, 4080, 8148, 11394, 7002, 7975, 11392, 10859, 1305, 6277, 9096, 4573,
2]) /* metro module 11393, dependencies: [31, 27, 1379, 1945, 1938, 1867, 3784, 661, 33, 4501, 697, 1585, 566, 1484, 4805, 9088, 1244, 6275, 6758, 5278, 4080, 8148, 11394, 7002, 7975, 11392, 10859, 1305, 6277, 9096, 4573, 2] */;
@@ -1,151 +1,188 @@
/* Metro module 11929; source: modules/channel_permissions/native/components/ChannelAccessInfo.tsx; dependencies: [31, 27, 1422, 1945, 1938, 33, 4501, 697, 1244, 566, 9088, 1360, 4573, 5278, 11392, 1305, 11928, 6699, 9099, 9097, 10787, 2] */
import GuildRoleStore from '../../../../stores/GuildRoleStore.tsx'; /* Metro dependency 1938 */
import GuildMemberStore from '../../../../stores/GuildMemberStore.tsx'; /* Metro dependency 1945 */
import Module10787 from '../../../../by-id/module-10787.js'; /* Metro dependency 10787 */
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 FluxModule from '../../../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as GuildRecordModule from '../../../../records/GuildRecord.tsx'; /* Metro dependency 1422 */
import * as TextModule from '../../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */
import * as PressablesModule from '../../../../design/void/Pressables/native/Pressables.tsx'; /* Metro dependency 5278 */
import * as ChannelPermissionsUtilsModule from '../../ChannelPermissionsUtils.tsx'; /* Metro dependency 9088 */
function _fun91525(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#91525, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:6, offset: 0x02068d4b, size: 459 bytes, params: 8, frame: 25
var object3;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const env0_5 = (require(1422) /* metro dependency 1422: GuildRecord */).isGuildOwner;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildRoleStore = importDefault(1938) /* metro dependency 1938: GuildRoleStore */;
let value = require(33) /* metro dependency 33 */;
let value = JsxRuntimeModule;
const env0_8 = value.jsx;
const env0_9 = value.jsxs;
const env0_10 = value.Fragment;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const object4 = {'alignItems': 'center', 'backgroundColor': null, 'borderRadius': null, 'color': null,
const object2 = {'alignItems': 'center', 'backgroundColor': null, 'borderRadius': null, 'color': null,
'flexDirection': 'row', 'marginBottom': 8, 'marginTop': 8, 'padding': 16};
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object4.backgroundColor = BACKGROUND_SURFACE_HIGH;
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
object2.backgroundColor = BACKGROUND_SURFACE_HIGH;
object2.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
const TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_DEFAULT;
object4.color = TEXT_DEFAULT;
const env0_11 = Reflect.apply(createStyles, value, [{section: object4, sectionContent: {'alignItems': 'center',
object2.color = TEXT_DEFAULT;
const env0_11 = Reflect.apply(createStyles, value, [{section: object2, sectionContent: {'alignItems': 'center',
'flexDirection': 'row', 'flexGrow': 1}, avatar: {marginRight: 8}, labelDetail: {marginRight: 12},
sectionIcon: {marginRight: 6}}]);
object3 = {MEMBERS: 0};
object3[0] = 'MEMBERS';
object3.ROLES = 1;
object3[1] = 'ROLES';
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/native/components/ChannelAccessInfo.tsx');
object = {MEMBERS: 0};
object[0] = 'MEMBERS';
object.ROLES = 1;
object[1] = 'ROLES';
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/native/components/ChannelAccessInfo.tsx');
exports.default = ChannelAccessInfo;
}
function ChannelAccessInfo({guild, channel}) { // fn#91526, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:780, offset: 0x02068f16, size: 984 bytes, params: 2, frame: 37
var object;
var binding;
var MEMBERS;
var items3;
var ROLES;
var items4;
var items5;
const closure = renderCounts;
const styles = useStyles();
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const value3 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.li1wKf);
const value4 = (require(566) /* metro dependency 566: flux */).useStateFromStoresArray([GuildRoleStore], _fun91528,
[guild, channel]);
const existingMembers = (require(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingMembers(GuildMemberStore.getMemberIds(guild?.id),
channel, guild, channel.accessPermissions);
let length = value4.length;
const r22 = length === 0 && existingMembers.length === 1 && isGuildOwner(guild,
existingMembers[0]) ? existingMembers[0] : null;
const jsxRuntimeEnv0_10Binding = jsxRuntimeEnv0_10;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const text = <Text variant="eyebrow">{value3}</Text>;
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
const pressableOpacityProps = {accessibilityLabel: value3, accessibilityRole: 'button', onPress: onPress_91529,
style: styles.section};
if (r22 != null) {
items4 = [((Avatar) => <Avatar style={styles.avatar} user={r22} guildId={guild.id} size={(require(1305) /* metro dependency 1305: native */).AvatarSizes.XSMALL} />)((require(1305) /* metro dependency 1305: native */).Avatar)];
items5 = [<Text variant="text-sm/semibold">{r22.tag}</Text>];
items5[1] = <Text variant="text-xs/medium">{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.rt0ERW)}</Text>;
items4[1] = <View>{items5}</View>;
object = {children: items4};
} else {
binding = env0_12;
MEMBERS = binding.MEMBERS;
length = existingMembers.length;
importDefault(11928) /* metro dependency 11928 */;
items3 = [closure(MEMBERS, length, undefined,
(require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon)];
ROLES = binding.ROLES;
length = value4.length;
importDefault(9099) /* metro dependency 9099 */;
items3[1] = closure(ROLES, length, undefined,
(require(9097) /* metro dependency 9097: ShieldUserIcon */).ShieldUserIcon);
object = {children: items3};
}
const view = <View style={styles.sectionContent}>{((Fragment) => <Fragment {...object} />)(jsxRuntimeEnv0_10Binding)}</View>;
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
const iconProps = {source: importDefault(10787) /* metro dependency 10787 */};
const Icon2 = (require(1305) /* metro dependency 1305: native */).Icon;
const Sizes = Icon2.Sizes;
const SMALL = Sizes.SMALL;
iconProps.size = SMALL;
return (
<>
{text}
<PressableOpacity {...pressableOpacityProps}>
{view}
<Icon {...iconProps} />
</PressableOpacity>
</>
);
}
function renderCounts(a0, a1, a2, a3) { // fn#91527, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:1105, owner: ChannelAccessInfo.renderCounts, offset: 0x020692ee, size: 529 bytes, params: 5, frame: 20
var r8;
var value2;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
if (a1 === 0) {
return null;
}
const MEMBERS = env1_12.MEMBERS;
if (MEMBERS === a0) {
r8 = a1 > 100 ? intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.PR5l07,
{count: 100}) : intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.bu5sya,
{count: a1});
} else if (env1_12.ROLES === a0) {
r8 = a1 > 100 ? intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t['+OYnFQ'],
{count: 100}) : intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.T2BEtm,
{count: a1});
} else {
value2 = undefined;
(require(1360) /* metro dependency 1360: GlobalUtils */).assertNever(a0);
r8 = value2;
}
const Fragment = env1_3.Fragment;
const value8 = ((Component) => <Component size="sm" style={styles.sectionIcon} />)(a3);
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
return (
<Fragment>
{value8}
<Text style={styles.labelDetail} variant="text-sm/medium">
{r8}
function ChannelAccessInfo({guild, channel}) { // fn#91526, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:780, offset: 0x02068f16, size: 984 bytes, params: 2, frame: 37
var object2;
var binding;
var MEMBERS;
var items3;
var ROLES;
var items4;
var items5;
const renderCounts2 = renderCounts;
const styles = useStyles();
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const value3 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.li1wKf);
const value4 = (FluxModule).useStateFromStoresArray([GuildRoleStore], _fun91528,
[guild, channel]);
const existingMembers = (require(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingMembers(GuildMemberStore.getMemberIds(guild?.id),
channel, guild, channel.accessPermissions);
let length = value4.length;
const r22 = length === 0 && existingMembers.length === 1 && isGuildOwner(guild,
existingMembers[0]) ? existingMembers[0] : null;
const jsxRuntimeEnv0_10Binding = jsxRuntimeEnv0_10;
const Text = (TextModule).Text;
const text = (
<Text variant="eyebrow">
{value3}
</Text>
</Fragment>
);
}
);
const PressableOpacity = (PressablesModule).PressableOpacity;
const pressableOpacityProps = {accessibilityLabel: value3, accessibilityRole: 'button', onPress: onPress_91529,
style: styles.section};
if (r22 != null) {
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
items4 = [
<Avatar
style={styles.avatar}
user={r22}
guildId={guild.id}
size={(require(1305) /* metro dependency 1305: native */).AvatarSizes.XSMALL}
/>,
];
items5 = [
<Text variant="text-sm/semibold">
{r22.tag}
</Text>,
];
items5[1] = (
<Text variant="text-xs/medium">
{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.rt0ERW)}
</Text>
);
items4[1] = (
<View>
{items5}
</View>
);
object2 = {children: items4};
} else {
binding = env0_12;
MEMBERS = binding.MEMBERS;
length = existingMembers.length;
importDefault(11928) /* metro dependency 11928 */;
items3 = [renderCounts2(MEMBERS, length, undefined,
(require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon)];
ROLES = binding.ROLES;
length = value4.length;
importDefault(9099) /* metro dependency 9099 */;
items3[1] = renderCounts2(ROLES, length, undefined,
(require(9097) /* metro dependency 9097: ShieldUserIcon */).ShieldUserIcon);
object2 = {children: items3};
}
const view = (
<View style={styles.sectionContent}>
{((Fragment) => <Fragment {...object2} />)(jsxRuntimeEnv0_10Binding)}
</View>
);
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
const iconProps = {source: Module10787};
const Icon2 = (require(1305) /* metro dependency 1305: native */).Icon;
const Sizes = Icon2.Sizes;
const SMALL = Sizes.SMALL;
iconProps.size = SMALL;
return (
<>
{text}
<PressableOpacity {...pressableOpacityProps}>
{view}
<Icon {...iconProps} />
</PressableOpacity>
</>
);
function renderCounts(a0, a1, a2, a3) { // fn#91527, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:1105, owner: ChannelAccessInfo.renderCounts, offset: 0x020692ee, size: 529 bytes, params: 5, frame: 20
var r8;
var value2;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
if (a1 === 0) {
return null;
}
const MEMBERS = env1_12.MEMBERS;
if (MEMBERS === a0) {
r8 = a1 > 100 ? intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.PR5l07,
{count: 100}) : intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.bu5sya,
{count: a1});
} else if (env1_12.ROLES === a0) {
r8 = a1 > 100 ? intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t['+OYnFQ'],
{count: 100}) : intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.T2BEtm,
{count: a1});
} else {
value2 = undefined;
(require(1360) /* metro dependency 1360: GlobalUtils */).assertNever(a0);
r8 = value2;
}
const Fragment = env1_3.Fragment;
const value8 = ((Component) => <Component size="sm" style={styles.sectionIcon} />)(a3);
const Text = (TextModule).Text;
return (
<Fragment>
{value8}
<Text style={styles.labelDetail} variant="text-sm/medium">
{r8}
</Text>
</Fragment>
);
}
function _fun91528() { // fn#91528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:917, offset: 0x020694ff, size: 83 bytes, params: 1, frame: 18
let value = environment.__proto__;
const channelPermissionsUtilsModule = require(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
const getExistingRoles = channelPermissionsUtilsModule.getExistingRoles;
const guildBinding = guild;
value = GuildRoleStore.getSortedRoles(guildBinding.id);
const channelBinding = channel;
return Reflect.apply(getExistingRoles, channelPermissionsUtilsModule, [guildBinding, value, channelBinding,
channelBinding.accessPermissions]);
}
function _fun91528() { // fn#91528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:917, offset: 0x020694ff, size: 83 bytes, params: 1, frame: 18
let value = environment.__proto__;
const getExistingRoles = ChannelPermissionsUtilsModule.getExistingRoles;
const guildBinding = guild;
value = GuildRoleStore.getSortedRoles(guildBinding.id);
const channelBinding = channel;
return Reflect.apply(getExistingRoles, ChannelPermissionsUtilsModule, [guildBinding, value, channelBinding,
channelBinding.accessPermissions]);
}
function ChannelAccessInfoOnPress() { // fn#91529, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:1853, owner: ChannelAccessInfo.onPress, offset: 0x02069552, size: 56 bytes, params: 1, frame: 14
let value = environment.__proto__;
value = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
const openChannelMembersActionSheet = value.openChannelMembersActionSheet;
const channelBinding = channel;
Reflect.apply(openChannelMembersActionSheet, value, [channelBinding.id, channelBinding.guild_id]);
}
}
function ChannelAccessInfoOnPress() { // fn#91529, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12115:1853, owner: ChannelAccessInfo.onPress, offset: 0x02069552, size: 56 bytes, params: 1, frame: 14
let value = environment.__proto__;
value = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
const openChannelMembersActionSheet = value.openChannelMembersActionSheet;
const channelBinding = channel;
Reflect.apply(openChannelMembersActionSheet, value, [channelBinding.id, channelBinding.guild_id]);
}
global.__d(_fun91525, 11929, [31, 27, 1422, 1945, 1938, 33, 4501, 697, 1244, 566, 9088, 1360, 4573, 5278, 11392,
1305, 11928, 6699, 9099, 9097, 10787,
2]) /* metro module 11929, dependencies: [31, 27, 1422, 1945, 1938, 33, 4501, 697, 1244, 566, 9088, 1360, 4573, 5278, 11392, 1305, 11928, 6699, 9099, 9097, 10787, 2] */;
@@ -1,205 +1,255 @@
/* Metro module 9096; source: modules/channel_permissions/native/components/ChannelOverwritesItem.tsx; dependencies: [31, 27, 1878, 8120, 33, 4501, 4500, 1244, 4603, 3856, 5278, 6988, 6238, 9097, 9088, 4573, 1305, 9098, 9099, 3874, 7974, 2] */
import UserStore from '../../../../stores/UserStore.tsx'; /* Metro dependency 1878 */
import Module09099 from '../../../../by-id/module-09099.js'; /* Metro dependency 9099 */
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 IndexNativeModule from '../../../../intl/index.native.tsx'; /* Metro dependency 1244 */
import * as NativeModule from '../../../../design/void/native.tsx'; /* Metro dependency 1305 */
import * as ToastUtilsModule from '../../../toast/native/ToastUtils.tsx'; /* Metro dependency 3856 */
import * as UseA11yRolesNativeModule from '../../../../external/discord_common/js/packages/design/hooks/useA11yRolesNative.tsx'; /* Metro dependency 3874 */
import * as CreateStylesModule from '../../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
import * as TextModule from '../../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */
import * as TableRowNativeModule from '../../../../design/components/TableRow/native/TableRow.native.tsx'; /* Metro dependency 6238 */
import * as FormCheckboxNativeModule from '../../../../design/components/Forms/native/FormCheckbox.native.tsx'; /* Metro dependency 7974 */
import * as ChannelPermissionsConstantsModule from '../../ChannelPermissionsConstants.tsx'; /* Metro dependency 8120 */
import * as ShieldUserIconModule from '../../../../design/components/Icon/native/redesign/generated/ShieldUserIcon.tsx'; /* Metro dependency 9097 */
function _fun71166(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#71166, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:6, offset: 0x01d17473, size: 393 bytes, params: 8, frame: 22
const env0_0 = require;
const closure = ChannelOverwritesItem;
const ChannelOverwritesItem2 = ChannelOverwritesItem;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_6 = (require(8120) /* metro dependency 8120: ChannelPermissionsConstants */).RowType;
const value = require(33) /* metro dependency 33 */;
const env0_7 = value.jsx;
const env0_8 = value.jsxs;
const env0_9 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({nameWrapper: {'flexDirection': 'row',
ReactModule;
const env0_9 = (CreateStylesModule).createStyles({nameWrapper: {'flexDirection': 'row',
'alignItems': 'flex-end', 'marginRight': 16}, name: {paddingRight: 4}, memberName: {flexShrink: 1},
ownerIcon: {alignSelf: 'center'}, roleIcon: {'height': 30, 'width': 30}, rowRemoveIconDisabled: {opacity: 0.3}});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/native/components/ChannelOverwritesItem.tsx');
exports.default = closure;
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/native/components/ChannelOverwritesItem.tsx');
exports.default = ChannelOverwritesItem2;
exports.ChannelOverwritesCheckboxItem = ChannelOverwritesCheckboxItem;
}
function RemoveIcon({item, channelId, onRemove}) { // fn#71167, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:415, offset: 0x01d175fc, size: 231 bytes, params: 2, frame: 23
var r0;
var PressableOpacity;
var object2;
var disabled;
var intl;
var CircleXIcon;
const styles = useStyles();
if (channelId == null) {
r0 = null;
} else {
PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
object2 = {};
disabled = item.disabled;
object2.disabled = disabled;
object2.accessibilityRole = 'button';
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object2.accessibilityLabel = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.N86XcP);
object2.onPress = function() {
var itemBinding;
function RemoveIcon({item, channelId, onRemove}) { // fn#71167, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:415, offset: 0x01d175fc, size: 231 bytes, params: 2, frame: 23
var r0;
var PressableOpacity;
var object;
var disabled;
var intl;
var CircleXIcon;
const styles = useStyles();
if (channelId == null) {
r0 = null;
} else {
PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
object = {};
disabled = item.disabled;
object.disabled = disabled;
object.accessibilityRole = 'button';
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object.accessibilityLabel = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.N86XcP);
object.onPress = function() {
var itemBinding;
if (onRemove != null) {
return onRemove(item);
}
itemBinding = item;
_fun71169(itemBinding.id, itemBinding.name, channelId);
};
CircleXIcon = (require(6988) /* metro dependency 6988: CircleXIcon */).CircleXIcon;
disabled = item.disabled;
r0 = (
<PressableOpacity {...object}>
<CircleXIcon style={disabled ? styles.rowRemoveIconDisabled : undefined} />
</PressableOpacity>
);
}
return r0;
function RemoveIconOnPress() { // fn#71168, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:639, owner: RemoveIcon.onPress, offset: 0x01d176e3, size: 68 bytes, params: 1, frame: 16
if (onRemove != null) {
return onRemove(item);
}
itemBinding = item;
_fun71169(itemBinding.id, itemBinding.name, channelId);
};
CircleXIcon = (require(6988) /* metro dependency 6988: CircleXIcon */).CircleXIcon;
disabled = item.disabled;
r0 = <PressableOpacity {...object2}><CircleXIcon style={disabled ? styles.rowRemoveIconDisabled : undefined} /></PressableOpacity>;
const itemBinding = item;
removeMemberOrRole(itemBinding.id, itemBinding.name, channelId);
function removeMemberOrRole(a0, a1, a2) { // fn#71169, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:668, owner: RemoveIcon.onPress.removeMemberOrRole, offset: 0x01d17727, size: 258 bytes, params: 4, frame: 22
var environment;
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
let value = environment.__proto__.__proto__;
value = require(4500) /* metro dependency 4500: AlertModalNative */;
const showConfirmModal = value.showConfirmModal;
const intl = (IndexNativeModule).intl;
const string = intl.string;
const t = (IndexNativeModule).t;
const GuPYQB = t.GuPYQB;
Reflect.apply(showConfirmModal, value, [{key: 'remove-channel-overwrite-' + a0, title: Reflect.apply(string, intl,
[GuPYQB]), content: intl.format(t.xERCnZ, {name: a1}), confirmText: intl.string(t.fKxYb0),
onConfirm: onConfirm_71170}]);
function removeMemberOrRoleOnConfirm() { // fn#71170, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:924, owner: RemoveIcon.onPress.removeMemberOrRole.onConfirm, offset: 0x01d17829, size: 69 bytes, params: 1, frame: 14
var environment;
let value = environment.__proto__.__proto__.__proto__;
value = importDefault(4603) /* metro dependency 4603: ChannelActionCreators */;
value = value.clearPermissionOverwrite(importDefault, env0_0);
value.then(_fun71171);
function _fun71171() { // fn#71171, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:973, offset: 0x01d1786e, size: 45 bytes, params: 1, frame: 12
const value = environment.__proto__.__proto__.__proto__.__proto__;
(ToastUtilsModule).memberOrRoleRemovedToast(require);
}
}
}
}
}
return r0;
}
function RoleItem_71172({disabled, item, subLabel, channelId, showType, showRemove, start, end, trailing, onPress, accessibilityRole, accessibilityState, accessible}) { // fn#71172, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:1122, offset: 0x01d1789b, size: 285 bytes, params: 2, frame: 31
var r16;
var moduleValue;
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
const object2 = {};
const ShieldUserIcon = (require(9097) /* metro dependency 9097: ShieldUserIcon */).ShieldUserIcon;
object2.icon = <ShieldUserIcon size="lg" color={item.colorString} />;
object2.label = item.name;
if (showType) {
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
r16 = moduleValue.getRowTypeLabel(item.rowType);
} else {
r16 = subLabel;
function RoleItem_71172({disabled, item, subLabel, channelId, showType, showRemove, start, end, trailing, onPress, accessibilityRole, accessibilityState, accessible}) { // fn#71172, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:1122, offset: 0x01d1789b, size: 285 bytes, params: 2, frame: 31
var r16;
var moduleValue;
const TableRow = (TableRowNativeModule).TableRow;
const object = {};
const ShieldUserIcon = (ShieldUserIconModule).ShieldUserIcon;
object.icon = <ShieldUserIcon size="lg" color={item.colorString} />;
object.label = item.name;
if (showType) {
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
r16 = moduleValue.getRowTypeLabel(item.rowType);
} else {
r16 = subLabel;
}
object.subLabel = r16;
object.start = start;
object.end = end;
object.trailing = (
showRemove
? (
<RemoveIcon item={item} channelId={channelId} />
)
: trailing
);
object.onPress = onPress;
object.disabled = disabled;
object.accessibilityRole = accessibilityRole;
object.accessibilityState = accessibilityState;
object.accessible = accessible;
return <TableRow {...object} />;
}
object2.subLabel = r16;
object2.start = start;
object2.end = end;
object2.trailing = showRemove ? <RemoveIcon item={item} channelId={channelId} /> : trailing;
object2.onPress = onPress;
object2.disabled = disabled;
object2.accessibilityRole = accessibilityRole;
object2.accessibilityState = accessibilityState;
object2.accessible = accessible;
return <TableRow {...object2} />;
}
function MemberItem({item, channelId, showRemove, onRemove, guildId, start, end, trailing, onPress, disabled, accessibilityRole, accessibilityState, accessible}) { // fn#71173, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:1590, offset: 0x01d179b8, size: 574 bytes, params: 2, frame: 37
var object2;
const styles = useStyles();
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const text = <Text style={[styles.name,
styles.memberName]} lineClamp={1} variant="text-md/semibold" color="interactive-text-active">{item.name}</Text>;
const rowType = item.rowType;
const OWNER = RowType.OWNER;
const view = <View style={styles.nameWrapper}>{text}{rowType !== OWNER ? null : ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.REFRESH_SMALL_16} source={importDefault(9098) /* metro dependency 9098 */} disableColor style={styles.ownerIcon} />)((require(1305) /* metro dependency 1305: native */).Icon)}</View>;
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
object2 = {};
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const avatarSource = UserStore.getUser(item.id)?.getAvatarSource(guildId);
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const SMALL = AvatarSizes.SMALL;
object2.icon = <Avatar source={avatarSource} size={SMALL} />;
object2.label = view;
const username = item.username;
object2.subLabel = username;
object2.start = start;
object2.end = end;
object2.trailing = showRemove ? <RemoveIcon item={item} channelId={channelId} onRemove={onRemove} /> : trailing;
object2.onPress = onPress;
object2.disabled = disabled;
object2.accessibilityRole = accessibilityRole;
object2.accessibilityState = accessibilityState;
object2.accessible = accessible;
return <TableRow {...object2} />;
}
function EmptyRoleItem({item}) { // fn#71174, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:2413, offset: 0x01d17bf6, size: 168 bytes, params: 2, frame: 23
const styles = useStyles();
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
const iconProps = {source: importDefault(9099) /* metro dependency 9099 */, color: item.colorString};
const IconSizes = (require(1305) /* metro dependency 1305: native */).IconSizes;
const MEDIUM = IconSizes.MEDIUM;
iconProps.size = MEDIUM;
iconProps.style = styles.roleIcon;
return <TableRow icon={<Icon {...iconProps} />} label={item.name} />;
}
function ChannelOverwritesItem(a0) { // fn#71175, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:2607, offset: 0x01d17c9e, size: 217 bytes, params: 2, frame: 17
const item = a0.item;
const value = Object.create(null);
value.item = 0;
const value2 = copyDataProperties({}, a0, value, undefined);
const rowType = item.rowType;
const ADMINISTRATOR = RowType.ADMINISTRATOR;
if (ADMINISTRATOR === rowType) {
return <RoleItem_71172 item={item} {...value2} />;
function MemberItem({item, channelId, showRemove, onRemove, guildId, start, end, trailing, onPress, disabled, accessibilityRole, accessibilityState, accessible}) { // fn#71173, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:1590, offset: 0x01d179b8, size: 574 bytes, params: 2, frame: 37
const styles = useStyles();
const Text = (TextModule).Text;
const text = (
<Text
style={[styles.name, styles.memberName]}
lineClamp={1}
variant="text-md/semibold"
color="interactive-text-active"
>
{item.name}
</Text>
);
const rowType = item.rowType;
const OWNER = RowType.OWNER;
const view = (
<View style={styles.nameWrapper}>
{text}
{
rowType !== OWNER
? null
: ((Icon) => <Icon size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.REFRESH_SMALL_16} source={importDefault(9098) /* metro dependency 9098 */} disableColor style={styles.ownerIcon} />)((require(1305) /* metro dependency 1305: native */).Icon)
}
</View>
);
const TableRow = (TableRowNativeModule).TableRow;
object = {};
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const avatarSource = UserStore.getUser(item.id)?.getAvatarSource(guildId);
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const SMALL = AvatarSizes.SMALL;
object.icon = <Avatar source={avatarSource} size={SMALL} />;
object.label = view;
const username = item.username;
object.subLabel = username;
object.start = start;
object.end = end;
object.trailing = (
showRemove
? (
<RemoveIcon
item={item}
channelId={channelId}
onRemove={onRemove}
/>
)
: trailing
);
object.onPress = onPress;
object.disabled = disabled;
object.accessibilityRole = accessibilityRole;
object.accessibilityState = accessibilityState;
object.accessible = accessible;
return <TableRow {...object} />;
}
const ROLE = RowType.ROLE;
if (ROLE === rowType) {
return <RoleItem_71172 item={item} {...value2} />;
function EmptyRoleItem({item}) { // fn#71174, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:2413, offset: 0x01d17bf6, size: 168 bytes, params: 2, frame: 23
const styles = useStyles();
const TableRow = (TableRowNativeModule).TableRow;
const Icon = (NativeModule).Icon;
const iconProps = {source: Module09099, color: item.colorString};
const IconSizes = (NativeModule).IconSizes;
const MEDIUM = IconSizes.MEDIUM;
iconProps.size = MEDIUM;
iconProps.style = styles.roleIcon;
return <TableRow icon={<Icon {...iconProps} />} label={item.name} />;
}
const OWNER = RowType.OWNER;
if (OWNER === rowType) {
return <MemberItem item={item} {...value2} />;
function ChannelOverwritesItem(a0) { // fn#71175, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:2607, offset: 0x01d17c9e, size: 217 bytes, params: 2, frame: 17
const item = a0.item;
const value = Object.create(null);
value.item = 0;
const value2 = copyDataProperties({}, a0, value, undefined);
const rowType = item.rowType;
const ADMINISTRATOR = RowType.ADMINISTRATOR;
if (ADMINISTRATOR === rowType) {
return <RoleItem_71172 item={item} {...value2} />;
}
const ROLE = RowType.ROLE;
if (ROLE === rowType) {
return <RoleItem_71172 item={item} {...value2} />;
}
const OWNER = RowType.OWNER;
if (OWNER === rowType) {
return <MemberItem item={item} {...value2} />;
}
const MEMBER = RowType.MEMBER;
if (MEMBER === rowType) {
return <MemberItem item={item} {...value2} />;
}
const EMPTY_STATE = RowType.EMPTY_STATE;
if (EMPTY_STATE === rowType) {
return <EmptyRoleItem item={item} {...value2} />;
}
return null;
}
const MEMBER = RowType.MEMBER;
if (MEMBER === rowType) {
return <MemberItem item={item} {...value2} />;
function ChannelOverwritesCheckboxItem(a0) { // fn#71176, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:3055, offset: 0x01d17d77, size: 185 bytes, params: 2, frame: 22
const checked = a0.checked;
const value = Object.create(null);
value.checked = 0;
const value2 = copyDataProperties({}, a0, value, undefined);
const {accessibilityRole,
accessibilityState} = (UseA11yRolesNativeModule).useCheckboxA11yNative({checked: checked});
const channelOverwritesItemBindingProps = {...value2};
channelOverwritesItemBindingProps['accessible'] = true;
channelOverwritesItemBindingProps['accessibilityRole'] = accessibilityRole;
channelOverwritesItemBindingProps['accessibilityState'] = accessibilityState;
const FormCheckbox = (FormCheckboxNativeModule).FormCheckbox;
channelOverwritesItemBindingProps['trailing'] = <FormCheckbox checked={checked} />;
return <ChannelOverwritesItem {...channelOverwritesItemBindingProps} />;
}
const EMPTY_STATE = RowType.EMPTY_STATE;
if (EMPTY_STATE === rowType) {
return <EmptyRoleItem item={item} {...value2} />;
}
return null;
}
function ChannelOverwritesCheckboxItem(a0) { // fn#71176, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:3055, offset: 0x01d17d77, size: 185 bytes, params: 2, frame: 22
const checked = a0.checked;
const value = Object.create(null);
value.checked = 0;
const value2 = copyDataProperties({}, a0, value, undefined);
const {accessibilityRole,
accessibilityState} = (require(3874) /* metro dependency 3874: useA11yRolesNative */).useCheckboxA11yNative({checked: checked});
const channelOverwritesItemBindingProps = {...value2};
channelOverwritesItemBindingProps['accessible'] = true;
channelOverwritesItemBindingProps['accessibilityRole'] = accessibilityRole;
channelOverwritesItemBindingProps['accessibilityState'] = accessibilityState;
const FormCheckbox = (require(7974) /* metro dependency 7974: FormCheckboxNative */).FormCheckbox;
channelOverwritesItemBindingProps['trailing'] = <FormCheckbox checked={checked} />;
return <ChannelOverwritesItem {...channelOverwritesItemBindingProps} />;
}
function RemoveIconOnPress() { // fn#71168, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:639, owner: RemoveIcon.onPress, offset: 0x01d176e3, size: 68 bytes, params: 1, frame: 16
if (onRemove != null) {
return onRemove(item);
}
const itemBinding = item;
removeMemberOrRole(itemBinding.id, itemBinding.name, channelId);
}
function removeMemberOrRole(a0, a1, a2) { // fn#71169, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:668, owner: RemoveIcon.onPress.removeMemberOrRole, offset: 0x01d17727, size: 258 bytes, params: 4, frame: 22
var environment;
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
let value = environment.__proto__.__proto__;
value = require(4500) /* metro dependency 4500: AlertModalNative */;
const showConfirmModal = value.showConfirmModal;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const GuPYQB = t.GuPYQB;
Reflect.apply(showConfirmModal, value, [{key: 'remove-channel-overwrite-' + a0, title: Reflect.apply(string, intl,
[GuPYQB]), content: intl.format(t.xERCnZ, {name: a1}), confirmText: intl.string(t.fKxYb0),
onConfirm: onConfirm_71170}]);
}
function removeMemberOrRoleOnConfirm() { // fn#71170, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:924, owner: RemoveIcon.onPress.removeMemberOrRole.onConfirm, offset: 0x01d17829, size: 69 bytes, params: 1, frame: 14
var environment;
let value = environment.__proto__.__proto__.__proto__;
value = importDefault(4603) /* metro dependency 4603: ChannelActionCreators */;
value = value.clearPermissionOverwrite(importDefault, env0_0);
value.then(_fun71171);
}
function _fun71171() { // fn#71171, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9281:973, offset: 0x01d1786e, size: 45 bytes, params: 1, frame: 12
const value = environment.__proto__.__proto__.__proto__.__proto__;
(require(3856) /* metro dependency 3856: ToastUtils */).memberOrRoleRemovedToast(require);
}
global.__d(_fun71166, 9096, [31, 27, 1878, 8120, 33, 4501, 4500, 1244, 4603, 3856, 5278, 6988, 6238, 9097, 9088,
4573, 1305, 9098, 9099, 3874, 7974,
2]) /* metro module 9096, dependencies: [31, 27, 1878, 8120, 33, 4501, 4500, 1244, 4603, 3856, 5278, 6988, 6238, 9097, 9088, 4573, 1305, 9098, 9099, 3874, 7974, 2] */;
@@ -1,24 +1,40 @@
/* Metro module 15185; source: modules/channel_permissions/native/components/EasyChannelPermissionSettings.tsx; dependencies: [57, 5, 31, 27, 15186, 1379, 1945, 1938, 1867, 3784, 3793, 1878, 8120, 661, 33, 4501, 697, 1484, 566, 9088, 9089, 9090, 1244, 4805, 4647, 9096, 3789, 4572, 6231, 6808, 1305, 6238, 10504, 11392, 5286, 4863, 8853, 9221, 15187, 15189, 2] */
import Module00005 from '../../../../by-id/module-00005.js'; /* Metro dependency 5 */
import Module00057 from '../../../../by-id/module-00057.js'; /* Metro dependency 57 */
import Native from '../../../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import ChannelStore from '../../../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
import GuildStore from '../../../../stores/GuildStore.tsx'; /* Metro dependency 1867 */
import UserStore from '../../../../stores/UserStore.tsx'; /* Metro dependency 1878 */
import GuildRoleStore from '../../../../stores/GuildRoleStore.tsx'; /* Metro dependency 1938 */
import GuildMemberStore from '../../../../stores/GuildMemberStore.tsx'; /* Metro dependency 1945 */
import PermissionStore from '../../../../stores/PermissionStore.tsx'; /* Metro dependency 3784 */
import RelationshipStore from '../../../../stores/RelationshipStore.tsx'; /* Metro dependency 3793 */
import AlertActionCreators from '../../../../actions/AlertActionCreators.tsx'; /* Metro dependency 4647 */
import AppAnalyticsUtils from '../../../app_analytics/AppAnalyticsUtils.tsx'; /* Metro dependency 4863 */
import ChannelSettingsPermissionsStore from '../../../../stores/ChannelSettingsPermissionsStore.tsx'; /* Metro dependency 15186 */
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 FluxModule from '../../../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as UseNavigationNativeModule from '../../../../design/components/Navigator/native/useNavigation.native.tsx'; /* Metro dependency 1484 */
import * as PermissionUtilsModule from '../../../../utils/PermissionUtils.tsx'; /* Metro dependency 3789 */
import * as StackNativeModule from '../../../../design/components/Stack/native/Stack.native.tsx'; /* Metro dependency 4572 */
import * as UseNavigatorBackPressHandlerNativeModule from '../../../../design/components/Navigator/native/useNavigatorBackPressHandler.native.tsx'; /* Metro dependency 5286 */
import * as TableRowGroupNativeModule from '../../../../design/components/TableRow/native/TableRowGroup.native.tsx'; /* Metro dependency 6231 */
import * as TableRowNativeModule from '../../../../design/components/TableRow/native/TableRow.native.tsx'; /* Metro dependency 6238 */
import * as TableSwitchRowNativeModule from '../../../../design/components/TableRow/native/TableSwitchRow.native.tsx'; /* Metro dependency 6808 */
import * as ChannelPermissionsConstantsModule from '../../ChannelPermissionsConstants.tsx'; /* Metro dependency 8120 */
import * as SegmentedControlStateNativeModule from '../../../../design/components/SegmentedControl/native/SegmentedControlState.native.tsx'; /* Metro dependency 8853 */
import * as ChannelPermissionsUtilsModule from '../../ChannelPermissionsUtils.tsx'; /* Metro dependency 9088 */
import * as CirclePlusIconModule from '../../../../design/components/Icon/native/redesign/generated/CirclePlusIcon.tsx'; /* Metro dependency 10504 */
function _fun116013(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116013, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:6, offset: 0x02477fc1, size: 622 bytes, params: 8, frame: 22
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_4 = importDefault(57) /* metro dependency 57 */;
const env0_5 = importDefault(5) /* metro dependency 5 */;
const env0_6 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
let value = ReactNativeModule;
const env0_7 = value.View;
const env0_8 = value.ScrollView;
const channelSettingsPermissionsStore = importDefault(15186) /* metro dependency 15186: ChannelSettingsPermissionsStore */;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildRoleStore = importDefault(1938) /* metro dependency 1938: GuildRoleStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const permissionStore = importDefault(3784) /* metro dependency 3784: PermissionStore */;
const relationshipStore = importDefault(3793) /* metro dependency 3793: RelationshipStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_17 = (require(8120) /* metro dependency 8120: ChannelPermissionsConstants */).SettingMode;
value = require(661) /* metro dependency 661: Constants */;
const env0_18 = value.ChannelTypes;
const env0_19 = value.Permissions;
@@ -28,452 +44,506 @@ function _fun116013(global, require, importDefault, importAll, module, exports,
value = require(33) /* metro dependency 33 */;
const env0_23 = value.jsx;
const env0_24 = value.jsxs;
object2 = {BASIC: 0};
object2[0] = 'BASIC';
object2.ADVANCED = 1;
object2[1] = 'ADVANCED';
object2.MODERATORS = 2;
object2[2] = 'MODERATORS';
object = {BASIC: 0};
object[0] = 'BASIC';
object.ADVANCED = 1;
object[1] = 'ADVANCED';
object.MODERATORS = 2;
object[2] = 'MODERATORS';
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
object2.container = {'flex': 1, 'paddingTop': 16, backgroundColor: BACKGROUND_BASE_LOWER};
object2.content = {'marginTop': 16, 'flex': 1};
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object2.adminWarning = {marginTop: PX_12};
const env0_26 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/channel_permissions/native/components/EasyChannelPermissionSettings.tsx');
object = {};
const BACKGROUND_BASE_LOWER = (Native).colors.BACKGROUND_BASE_LOWER;
object.container = {'flex': 1, 'paddingTop': 16, backgroundColor: BACKGROUND_BASE_LOWER};
object.content = {'marginTop': 16, 'flex': 1};
const PX_12 = (Native).space.PX_12;
object.adminWarning = {marginTop: PX_12};
const env0_26 = Reflect.apply(createStyles, value, [object]);
(FileImportTrackerModule).fileFinishedImporting('modules/channel_permissions/native/components/EasyChannelPermissionSettings.tsx');
exports.default = EasyChannelPermissionSettings;
}
function ChannelPermissionSettingsBasicView({channel, privateToggleState, setPrivateToggleState}) { // fn#116014, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:706, offset: 0x0247822f, size: 1584 bytes, params: 2, frame: 39
const HelpMessage = (require(1305) /* metro dependency 1305: native */).HelpMessage;
let env0_6 = undefined;
const styles = useStyles();
const value3 = (UseNavigationNativeModule).useNavigation();
const {guild,
sortedGuildRoles} = (FluxModule).useStateFromStoresObject([GuildStore,
GuildRoleStore], _fun116016);
env0_6.useLayoutEffect(_fun116017, [value3]);
const value5 = env0_6.useMemo(_fun116018, [guild, sortedGuildRoles, channel]);
if (guild == null) {
return null;
}
if (sortedGuildRoles == null) {
return null;
}
const isCategory2 = channel.isCategory();
const existingMembersRows = (importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingMembersRows(GuildMemberStore.getMemberIds(guild?.id),
channel, guild, channel.accessPermissions);
env0_6 = _fun116019();
const value8 = _fun116023();
const isPrivateGuildChannel2 = (importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */).isPrivateGuildChannel(channel);
let canEveryoneRole = PermissionUtilsModule.canEveryoneRole;
const VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
const canEveryoneRole2 = Reflect.apply(canEveryoneRole, PermissionUtilsModule, [VIEW_CHANNEL, guild]);
canEveryoneRole = PermissionUtilsModule.canEveryoneRole;
const ADMINISTRATOR = Permissions.ADMINISTRATOR;
const canEveryoneRole3 = Reflect.apply(canEveryoneRole, PermissionUtilsModule, [ADMINISTRATOR, guild]);
const type = channel.type;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const value9 = Reflect.apply(string, intl, [t.hfbjIH]);
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r17 = type === GUILD_CATEGORY ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.RQUk61) : type !== ChannelTypes.GUILD_VOICE ? value9 : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.cLjvKg);
const Stack = (StackNativeModule).Stack;
const object2 = {};
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object2.paddingHorizontal = PX_16;
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
const TableRowGroup = (TableRowGroupNativeModule).TableRowGroup;
const TableSwitchRow = (TableSwitchRowNativeModule).TableSwitchRow;
string = intl.string;
const items2 = [
<TableRowGroup title={r17} hasIcons={false}>
<TableSwitchRow
label={isCategory2 ? Reflect.apply(string, intl, [t.lEPAZ5]) : Reflect.apply(string, intl, [t.aUI70g])}
value={privateToggleState}
onValueChange={value8}
/>
</TableRowGroup>,
];
items2[1] = canEveryoneRole3 && <View style={styles.adminWarning}><HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.WARNING}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['5f3HIC'])}</HelpMessage></View>;
items2[2] = !canEveryoneRole3 && !canEveryoneRole2 && !isPrivateGuildChannel2 && <View style={styles.adminWarning}><HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.WARNING}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.ZAk4Q9)}</HelpMessage></View>;
const TableRow = (TableRowNativeModule).TableRow;
const CirclePlusIcon = (CirclePlusIconModule).CirclePlusIcon;
items2[3] = (
<TableRowGroup hasIcons>
<TableRow
arrow
icon={<CirclePlusIcon />}
label={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dMJ3Y6)}
onPress={onPress_116028}
/>
</TableRowGroup>
);
string = intl.string;
const ES4CC6 = (require(1244) /* metro dependency 1244: indexNative */).t.ES4CC6;
items2[4] = (
<TableRowGroup title={Reflect.apply(string, intl, [ES4CC6])} hasIcons>
{value5.map(function(a0) {
return ChannelPermissionSettingsBasicViewRenderRowItem(a0);
})}
</TableRowGroup>
);
items2[5] = (
<TableRowGroup hasIcons>
{existingMembersRows.map(function(a0) {
return ChannelPermissionSettingsBasicViewRenderRowItem(a0);
})}
</TableRowGroup>
);
return (
<Stack style={object2} spacing={PX_16}>
{items2}
</Stack>
);
function ChannelPermissionSettingsBasicViewRenderRowItem(a0) { // fn#116015, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:2394, owner: ChannelPermissionSettingsBasicView.renderRowItem, offset: 0x0247885f, size: 89 bytes, params: 2, frame: 18
let value = environment.__proto__;
value = importDefault(9096) /* metro dependency 9096: ChannelOverwritesItem */;
const channelBinding = channel;
return ((Component) => <Component item={a0} channelId={channelBinding.id} showType showRemove guildId={channelBinding.guild_id} key={a0.id} />)(value);
}
function _fun116016() { // fn#116016, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:888, offset: 0x024788b8, size: 79 bytes, params: 1, frame: 13
const value = environment.__proto__;
const guildStoreBinding = GuildStore;
const getGuild = guildStoreBinding.getGuild;
const channelBinding = channel;
const getGuildId = channelBinding.getGuildId;
const value3 = Reflect.apply(getGuild, guildStoreBinding, [Reflect.apply(getGuildId, channelBinding, [])]);
return {guild: value3, sortedGuildRoles: value3 != null ? GuildRoleStore.getSortedRoles(value3.id) : undefined};
}
function _fun116017() { // fn#116017, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1050, offset: 0x02478907, size: 29 bytes, params: 1, frame: 13
env0_3.setOptions({headerRight: undefined});
}
function _fun116018() { // fn#116018, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1114, offset: 0x02478924, size: 88 bytes, params: 1, frame: 17
var r0;
var sortedGuildRolesBinding;
var value2;
var moduleValue;
var getExistingRolesRows;
var channelBinding;
let guildBinding = guild;
if (guildBinding == null) {
r0 = [];
} else {
sortedGuildRolesBinding = sortedGuildRoles;
if (sortedGuildRolesBinding == null) {
r0 = [];
} else {
value2 = environment.__proto__;
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
getExistingRolesRows = moduleValue.getExistingRolesRows;
guildBinding = guild;
sortedGuildRolesBinding = sortedGuildRoles;
channelBinding = channel;
r0 = Reflect.apply(getExistingRolesRows, moduleValue, [guildBinding, sortedGuildRolesBinding,
channelBinding,
channelBinding.accessPermissions]);
}
}
return r0;
}
function _fun116019() { // fn#116019, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1359, offset: 0x0247897c, size: 36 bytes, params: 1, frame: 12
const env0_0 = env1_5(_fun116021);
return _fun116022;
function* _fun116021() { // fn#116021, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1379, offset: 0x024789ab, size: 260 bytes, params: 1, frame: 22
if (true) {
value = environment.__proto__.__proto__.__proto__;
var binding = env3_2;
var binding2 = env3_3;
var isPrivateGuildChannel2 = binding(binding2[19]).isPrivateGuildChannel(require);
var accessPermissions = require.accessPermissions;
var value6 = binding(binding2[19]).flipEveryonePermission(require, accessPermissions, isPrivateGuildChannel2);
var currentUser = env3_16.getCurrentUser();
binding = env3_14;
var can = binding.can;
var ADMINISTRATOR = env3_19.ADMINISTRATOR;
var value8 = Reflect.apply(can, binding, [ADMINISTRATOR, env2_4]);
var r4 = View || currentUser == null;
r4 = !r4 ? value8 : r4;
if (!r4) {
var value10 = env3_2(env3_3[19]);
yield value10.grantUserChannelAccess(require, accessPermissions);
if (false) {
return undefined;
}
}
value = env3_0(env3_3[20]);
yield value.savePermissionUpdates(require.id, [value6]);
}
}
function _fun116022() { // fn#116022, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1659, offset: 0x00c3945f, size: 30 bytes, params: 1, frame: 13
return env0_0.apply(this, arguments);
}
}
function _fun116023() { // fn#116023, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1707, offset: 0x02478aaf, size: 36 bytes, params: 1, frame: 12
const env0_0 = env1_5(_fun116025);
return _fun116027;
function* _fun116025() { // fn#116025, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1727, offset: 0x02478ade, size: 521 bytes, params: 1, frame: 23
var environment;
var r9;
var r8;
var binding;
var value7;
var binding2;
var intl;
var string;
var t;
var value10;
var computeChannelName;
var channelName;
var binding3;
var format;
var object;
var binding4;
var value13;
var show;
if (true) {
value = environment.__proto__.__proto__;
if (require.guild_id == null) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl, [t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object.onConfirm = env2_6;
object.hideActionSheet = false;
object.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object]);
} else {
if (importDefault) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl,
[t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object.onConfirm = env2_6;
object.hideActionSheet = false;
object.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object]);
return undefined;
}
binding = env3_0;
var value4 = binding(env3_3[21]);
var checkChattableChannelThresholdMetAfterChannelPermissionDeny = value4.checkChattableChannelThresholdMetAfterChannelPermissionDeny;
var VIEW_CHANNEL = env3_19.VIEW_CHANNEL;
yield Reflect.apply(checkChattableChannelThresholdMetAfterChannelPermissionDeny, value4, [require,
VIEW_CHANNEL]);
var value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl,
[t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object.onConfirm = env2_6;
object.hideActionSheet = false;
object.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object]);
return undefined;
}
}
}
function onCancel_116026() { // fn#116026, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:2293, offset: 0x02478ce7, size: 54 bytes, params: 1, frame: 13
const value3 = env4_2(env4_3[19]);
importAll(value3.isPrivateGuildChannel(require));
}
}
function _fun116027() { // fn#116027, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:2348, offset: 0x00c3945f, size: 30 bytes, params: 1, frame: 13
return env0_0.apply(this, arguments);
}
}
function ChannelPermissionSettingsBasicViewOnPress() { // fn#116028, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:3630, owner: ChannelPermissionSettingsBasicView.onPress, offset: 0x02478d1d, size: 57 bytes, params: 1, frame: 12
var value2;
var moduleValue;
if (channel != null) {
value2 = environment.__proto__;
moduleValue = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
moduleValue.openAddMembersActionSheet(channel);
}
}
function ChannelPermissionSettingsBasicView({channel, privateToggleState, setPrivateToggleState}) { // fn#116014, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:706, offset: 0x0247822f, size: 1584 bytes, params: 2, frame: 39
const HelpMessage = (require(1305) /* metro dependency 1305: native */).HelpMessage;
let env0_6 = undefined;
const styles = useStyles();
const value3 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const {guild,
sortedGuildRoles} = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildStore,
GuildRoleStore], _fun116016);
env0_6.useLayoutEffect(_fun116017, [value3]);
const value5 = env0_6.useMemo(_fun116018, [guild, sortedGuildRoles, channel]);
if (guild == null) {
return null;
}
if (sortedGuildRoles == null) {
return null;
function onBack_116031() { // fn#116031, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:3892, offset: 0x02478d56, size: 39 bytes, params: 1, frame: 11
(AlertActionCreators).close();
return false;
}
const isCategory2 = channel.isCategory();
const existingMembersRows = (importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */).getExistingMembersRows(GuildMemberStore.getMemberIds(guild?.id),
channel, guild, channel.accessPermissions);
env0_6 = _fun116019();
const value8 = _fun116023();
const isPrivateGuildChannel2 = (importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */).isPrivateGuildChannel(channel);
const permissionUtilsModule = importAll(3789) /* metro dependency 3789: PermissionUtils */;
let canEveryoneRole = permissionUtilsModule.canEveryoneRole;
const VIEW_CHANNEL = Permissions.VIEW_CHANNEL;
const canEveryoneRole2 = Reflect.apply(canEveryoneRole, permissionUtilsModule, [VIEW_CHANNEL, guild]);
const moduleValue6 = permissionUtilsModule;
canEveryoneRole = moduleValue6.canEveryoneRole;
const ADMINISTRATOR = Permissions.ADMINISTRATOR;
const canEveryoneRole3 = Reflect.apply(canEveryoneRole, moduleValue6, [ADMINISTRATOR, guild]);
const type = channel.type;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const value9 = Reflect.apply(string, intl, [t.hfbjIH]);
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const r17 = type === GUILD_CATEGORY ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.RQUk61) : type !== ChannelTypes.GUILD_VOICE ? value9 : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.cLjvKg);
const Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack;
const object = {};
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object.paddingHorizontal = PX_16;
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
const TableRowGroup = (require(6231) /* metro dependency 6231: TableRowGroupNative */).TableRowGroup;
const TableSwitchRow = (require(6808) /* metro dependency 6808: TableSwitchRowNative */).TableSwitchRow;
string = intl.string;
const items2 = [<TableRowGroup title={r17} hasIcons={false}><TableSwitchRow label={isCategory2 ? Reflect.apply(string,
intl, [t.lEPAZ5]) : Reflect.apply(string, intl,
[t.aUI70g])} value={privateToggleState} onValueChange={value8} /></TableRowGroup>];
items2[1] = canEveryoneRole3 && <View style={styles.adminWarning}><HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.WARNING}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['5f3HIC'])}</HelpMessage></View>;
items2[2] = !canEveryoneRole3 && !canEveryoneRole2 && !isPrivateGuildChannel2 && <View style={styles.adminWarning}><HelpMessage messageType={(require(1305) /* metro dependency 1305: native */).HelpMessageTypes.WARNING}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.ZAk4Q9)}</HelpMessage></View>;
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
const CirclePlusIcon = (require(10504) /* metro dependency 10504: CirclePlusIcon */).CirclePlusIcon;
items2[3] = <TableRowGroup hasIcons><TableRow arrow icon={<CirclePlusIcon />} label={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dMJ3Y6)} onPress={onPress_116028} /></TableRowGroup>;
string = intl.string;
const ES4CC6 = (require(1244) /* metro dependency 1244: indexNative */).t.ES4CC6;
items2[4] = <TableRowGroup title={Reflect.apply(string, intl, [ES4CC6])} hasIcons>{value5.map(function(a0) {
return ChannelPermissionSettingsBasicViewRenderRowItem(a0);
})}</TableRowGroup>;
items2[5] = <TableRowGroup hasIcons>{existingMembersRows.map(function(a0) {
return ChannelPermissionSettingsBasicViewRenderRowItem(a0);
})}</TableRowGroup>;
return (
<Stack style={object} spacing={PX_16}>
{items2}
</Stack>
);
}
function onBack() { // fn#116031, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:3892, offset: 0x02478d56, size: 39 bytes, params: 1, frame: 11
(importDefault(4647) /* metro dependency 4647: AlertActionCreators */).close();
return false;
}
function EasyChannelPermissionSettings({channelId, origin}) { // fn#116032, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:4061, offset: 0x02478d7d, size: 1018 bytes, params: 2, frame: 28
var r0;
var object3;
let env0_4 = undefined;
(require(5286) /* metro dependency 5286: useNavigatorBackPressHandlerNative */).useNavigatorBackPressHandler(onBack);
const styles = useStyles();
const channel = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelStore], function() {
return ChannelStore.getChannel(channelId);
});
const advancedMode = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelSettingsPermissionsStore],
function() {
return ChannelSettingsPermissionsStore.advancedMode;
});
let binding = env0_6;
let useState = binding.useState;
const value4 = Reflect.apply(useState, binding,
[channel == null ? advancedMode ? env0_25.ADVANCED : env0_25.BASIC : channel.isGuildStageVoice() ? env0_25.MODERATORS : advancedMode ? env0_25.ADVANCED : env0_25.BASIC]);
binding = env0_4;
const value5 = binding(value4, 2);
let property = value5[0];
env0_4 = value5[1];
const binding3 = env0_6;
useState = binding3.useState;
const channelPermissionsUtilsModule = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
const value6 = binding(Reflect.apply(useState, binding3,
[channelPermissionsUtilsModule.isPrivateGuildChannel(channel)]), 2);
const property2 = value6[0];
const property3 = value6[1];
env0_6.useEffect(function() {
var originBinding = origin;
var property = ChannelSettingsSections.OVERVIEW;
var defaultImport = importDefault(dependencyMap[35]);
var trackWithMetadata = defaultImport.trackWithMetadata;
var SETTINGS_PANE_VIEWED = AnalyticEvents.SETTINGS_PANE_VIEWED;
Reflect.apply(trackWithMetadata, defaultImport, [SETTINGS_PANE_VIEWED, {settings_type: 'channel',
origin_pane: originBinding !== property ? null : SettingsPaneTypes.CHANNEL_SETTINGS,
destination_pane: ChannelSettingsSections.PERMISSIONS}]);
}, [origin]);
const value7 = env0_6.useCallback(_fun116036, [channel]);
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
items = [intl.string((require(1244) /* metro dependency 1244: indexNative */).t['Mw/UDN'])];
items[1] = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0a6awf']);
if (channel?.isGuildStageVoice() === true) {
items.push(intl.string((require(1244) /* metro dependency 1244: indexNative */).t.YIIUJ3));
}
const segmentedControlStateNativeModule = require(8853) /* metro dependency 8853: SegmentedControlStateNative */;
const useSegmentedControlState = segmentedControlStateNativeModule.useSegmentedControlState;
const object5 = {pageWidth: 0, defaultIndex: property, onSetActiveIndex: value7};
object5.items = items.map(function(a0) {
return {id: a0, label: a0, page: null};
});
const value9 = Reflect.apply(useSegmentedControlState, segmentedControlStateNativeModule, [object5]);
env0_6.useEffect(_fun116038, [channel, property]);
if (channel != null) {
var viewBindingProps = {style: styles.container};
object3 = {};
object3.paddingHorizontal = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
r0 = <View {...viewBindingProps}><View style={object3}>{((SegmentedControl) => <SegmentedControl state={value9} />)((require(9221) /* metro dependency 9221: SegmentedControlNative */).SegmentedControl)}</View><ScrollView style={styles.content}>{property === env0_25.BASIC ? <ChannelPermissionSettingsBasicView channel={channel} privateToggleState={property2} setPrivateToggleState={property3} /> : property === env0_25.MODERATORS ? ((Component) => <Component channel={channel} />)(importDefault(15187) /* metro dependency 15187: ViewModerators */) : ((Component) => <Component channelId={channel.id} />)(importDefault(15189) /* metro dependency 15189: ChannelSettingsPermissionsOverview */)}</ScrollView></View>;
} else {
r0 = null;
}
return r0;
}
function ChannelPermissionSettingsBasicViewRenderRowItem(a0) { // fn#116015, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:2394, owner: ChannelPermissionSettingsBasicView.renderRowItem, offset: 0x0247885f, size: 89 bytes, params: 2, frame: 18
let value = environment.__proto__;
value = importDefault(9096) /* metro dependency 9096: ChannelOverwritesItem */;
const channelBinding = channel;
return ((Component) => <Component item={a0} channelId={channelBinding.id} showType showRemove guildId={channelBinding.guild_id} key={a0.id} />)(value);
}
function _fun116016() { // fn#116016, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:888, offset: 0x024788b8, size: 79 bytes, params: 1, frame: 13
const value = environment.__proto__;
const getGuild = GuildStore.getGuild;
const channelBinding = channel;
const getGuildId = channelBinding.getGuildId;
const value3 = Reflect.apply(getGuild, GuildStore, [Reflect.apply(getGuildId, channelBinding, [])]);
return {guild: value3, sortedGuildRoles: value3 != null ? GuildRoleStore.getSortedRoles(value3.id) : undefined};
}
function _fun116017() { // fn#116017, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1050, offset: 0x02478907, size: 29 bytes, params: 1, frame: 13
env0_3.setOptions({headerRight: undefined});
}
function _fun116018() { // fn#116018, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1114, offset: 0x02478924, size: 88 bytes, params: 1, frame: 17
var r0;
var sortedGuildRolesBinding;
var value2;
var moduleValue;
var getExistingRolesRows;
var channelBinding;
let guildBinding = guild;
if (guildBinding == null) {
r0 = [];
} else {
sortedGuildRolesBinding = sortedGuildRoles;
if (sortedGuildRolesBinding == null) {
r0 = [];
function EasyChannelPermissionSettings({channelId, origin}) { // fn#116032, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:4061, offset: 0x02478d7d, size: 1018 bytes, params: 2, frame: 28
var r0;
var object;
let env0_4 = undefined;
(UseNavigatorBackPressHandlerNativeModule).useNavigatorBackPressHandler(onBack_116031);
const styles = useStyles();
const channel = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelStore], function() {
return ChannelStore.getChannel(channelId);
});
const advancedMode = (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelSettingsPermissionsStore],
function() {
return ChannelSettingsPermissionsStore.advancedMode;
});
let binding = ReactModule;
let useState = binding.useState;
const value4 = Reflect.apply(useState, binding,
[channel == null ? advancedMode ? env0_25.ADVANCED : env0_25.BASIC : channel.isGuildStageVoice() ? env0_25.MODERATORS : advancedMode ? env0_25.ADVANCED : env0_25.BASIC]);
binding = env0_4;
const value5 = binding(value4, 2);
let property = value5[0];
env0_4 = value5[1];
useState = ReactModule.useState;
const value6 = binding(Reflect.apply(useState, ReactModule,
[ChannelPermissionsUtilsModule.isPrivateGuildChannel(channel)]), 2);
const property2 = value6[0];
const property3 = value6[1];
ReactModule.useEffect(function() {
var originBinding = origin;
var property = ChannelSettingsSections.OVERVIEW;
var defaultImport = importDefault(dependencyMap[35]);
var trackWithMetadata = defaultImport.trackWithMetadata;
var SETTINGS_PANE_VIEWED = AnalyticEvents.SETTINGS_PANE_VIEWED;
Reflect.apply(trackWithMetadata, defaultImport, [SETTINGS_PANE_VIEWED, {settings_type: 'channel',
origin_pane: originBinding !== property ? null : SettingsPaneTypes.CHANNEL_SETTINGS,
destination_pane: ChannelSettingsSections.PERMISSIONS}]);
}, [origin]);
const value7 = ReactModule.useCallback(_fun116036, [channel]);
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
items2 = [intl.string((require(1244) /* metro dependency 1244: indexNative */).t['Mw/UDN'])];
items2[1] = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0a6awf']);
if (channel?.isGuildStageVoice() === true) {
items2.push(intl.string((require(1244) /* metro dependency 1244: indexNative */).t.YIIUJ3));
}
const useSegmentedControlState = SegmentedControlStateNativeModule.useSegmentedControlState;
const object2 = {pageWidth: 0, defaultIndex: property, onSetActiveIndex: value7};
object2.items = items2.map(function(a0) {
return {id: a0, label: a0, page: null};
});
const value9 = Reflect.apply(useSegmentedControlState, SegmentedControlStateNativeModule, [object2]);
ReactModule.useEffect(_fun116038, [channel, property]);
if (channel != null) {
var viewBindingProps = {style: styles.container};
object = {};
object.paddingHorizontal = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
r0 = (
<View {...viewBindingProps}>
<View style={object}>
{((SegmentedControl) => <SegmentedControl state={value9} />)((require(9221) /* metro dependency 9221: SegmentedControlNative */).SegmentedControl)}
</View>
<ScrollView style={styles.content}>
{
property === env0_25.BASIC
? (
<ChannelPermissionSettingsBasicView
channel={channel}
privateToggleState={property2}
setPrivateToggleState={property3}
/>
)
: (
property === env0_25.MODERATORS
? ((Component) => <Component channel={channel} />)(importDefault(15187) /* metro dependency 15187: ViewModerators */)
: ((Component) => <Component channelId={channel.id} />)(importDefault(15189) /* metro dependency 15189: ChannelSettingsPermissionsOverview */)
)
}
</ScrollView>
</View>
);
} else {
value2 = environment.__proto__;
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
getExistingRolesRows = moduleValue.getExistingRolesRows;
guildBinding = guild;
sortedGuildRolesBinding = sortedGuildRoles;
channelBinding = channel;
r0 = Reflect.apply(getExistingRolesRows, moduleValue, [guildBinding, sortedGuildRolesBinding,
channelBinding,
channelBinding.accessPermissions]);
r0 = null;
}
}
return r0;
}
function _fun116019() { // fn#116019, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1359, offset: 0x0247897c, size: 36 bytes, params: 1, frame: 12
const env0_0 = env1_5(_fun116021);
return _fun116022;
}
function _fun116023() { // fn#116023, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1707, offset: 0x02478aaf, size: 36 bytes, params: 1, frame: 12
const env0_0 = env1_5(_fun116025);
return _fun116027;
}
function ChannelPermissionSettingsBasicViewOnPress() { // fn#116028, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:3630, owner: ChannelPermissionSettingsBasicView.onPress, offset: 0x02478d1d, size: 57 bytes, params: 1, frame: 12
var value2;
var moduleValue;
if (channel != null) {
value2 = environment.__proto__;
moduleValue = require(11392) /* metro dependency 11392: ChannelPermissionsUtils */;
moduleValue.openAddMembersActionSheet(channel);
}
}
function _fun116036(a0) { // fn#116036, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:4679, offset: 0x024791f7, size: 151 bytes, params: 2, frame: 16
var binding;
var moduleValue;
const value = environment.__proto__;
const ADVANCED = env1_25.ADVANCED;
if (a0 === ADVANCED) {
(require(9089) /* metro dependency 9089: ChannelSettingsPermissionsActionCreators */).setAdvancedMode(true);
} else {
binding = env0_5;
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
binding(moduleValue.isPrivateGuildChannel(channel));
(require(9089) /* metro dependency 9089: ChannelSettingsPermissionsActionCreators */).setAdvancedMode(false);
}
env0_4(a0);
}
function _fun116038() { // fn#116038, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:5144, offset: 0x0247928e, size: 140 bytes, params: 1, frame: 18
let value = environment.__proto__;
const defaultImport = importDefault(4863) /* metro dependency 4863: AppAnalyticsUtils */;
const trackWithMetadata = defaultImport.trackWithMetadata;
const CHANNEL_PERMISSIONS_PAGE_VIEWED = AnalyticEvents.CHANNEL_PERMISSIONS_PAGE_VIEWED;
const object2 = {};
const binding = env0_3;
const BASIC = env1_25.BASIC;
object2.mode = binding === BASIC ? SettingMode.BASIC : SettingMode.ADVANCED;
value = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
object2.channel_is_private = value.isPrivateGuildChannel(channel);
Reflect.apply(trackWithMetadata, defaultImport, [CHANNEL_PERMISSIONS_PAGE_VIEWED, object2]);
}
function* _fun116021() { // fn#116021, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1379, offset: 0x024789ab, size: 260 bytes, params: 1, frame: 22
if (true) {
value = environment.__proto__.__proto__.__proto__;
var binding = env3_2;
var binding2 = env3_3;
var isPrivateGuildChannel2 = binding(binding2[19]).isPrivateGuildChannel(require);
var accessPermissions = require.accessPermissions;
var value6 = binding(binding2[19]).flipEveryonePermission(require, accessPermissions, isPrivateGuildChannel2);
var currentUser = env3_16.getCurrentUser();
binding = env3_14;
var can = binding.can;
var ADMINISTRATOR = env3_19.ADMINISTRATOR;
var value8 = Reflect.apply(can, binding, [ADMINISTRATOR, env2_4]);
var r4 = View || currentUser == null;
r4 = !r4 ? value8 : r4;
if (!r4) {
var value10 = env3_2(env3_3[19]);
yield value10.grantUserChannelAccess(require, accessPermissions);
if (false) {
return undefined;
return r0;
function _fun116036(a0) { // fn#116036, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:4679, offset: 0x024791f7, size: 151 bytes, params: 2, frame: 16
var binding;
var moduleValue;
const value = environment.__proto__;
const ADVANCED = env1_25.ADVANCED;
if (a0 === ADVANCED) {
(require(9089) /* metro dependency 9089: ChannelSettingsPermissionsActionCreators */).setAdvancedMode(true);
} else {
binding = Module00005;
moduleValue = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
binding(moduleValue.isPrivateGuildChannel(channel));
(require(9089) /* metro dependency 9089: ChannelSettingsPermissionsActionCreators */).setAdvancedMode(false);
}
env0_4(a0);
}
value = env3_0(env3_3[20]);
yield value.savePermissionUpdates(require.id, [value6]);
}
}
function* _fun116025() { // fn#116025, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:1727, offset: 0x02478ade, size: 521 bytes, params: 1, frame: 23
var environment;
var r9;
var r8;
var binding;
var value7;
var binding2;
var intl;
var string;
var t;
var value10;
var computeChannelName;
var channelName;
var binding3;
var format;
var object2;
var binding4;
var value13;
var show;
if (true) {
value = environment.__proto__.__proto__;
if (require.guild_id == null) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl, [t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object2 = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object2.onConfirm = env2_6;
object2.hideActionSheet = false;
object2.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object2]);
} else {
if (importDefault) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl,
[t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object2 = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object2.onConfirm = env2_6;
object2.hideActionSheet = false;
object2.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object2]);
return undefined;
}
binding = env3_0;
var value4 = binding(env3_3[21]);
var checkChattableChannelThresholdMetAfterChannelPermissionDeny = value4.checkChattableChannelThresholdMetAfterChannelPermissionDeny;
var VIEW_CHANNEL = env3_19.VIEW_CHANNEL;
yield Reflect.apply(checkChattableChannelThresholdMetAfterChannelPermissionDeny, value4, [require,
VIEW_CHANNEL]);
var value5 = undefined;
if (false) {
return value5;
}
if (value5) {
value7 = environment.__proto__.__proto__.__proto__;
binding = env3_0;
binding2 = env3_3;
intl = binding(binding2[22]).intl;
string = intl.string;
t = binding(binding2[22]).t;
r9 = importDefault ? Reflect.apply(string, intl, [t.vw48TT]) : Reflect.apply(string, intl,
[t['47gQYL']]);
binding = env3_0;
value10 = binding(env3_3[23]);
computeChannelName = value10.computeChannelName;
binding = env3_16;
channelName = Reflect.apply(computeChannelName, value10, [require, binding, env3_15]);
binding = env3_0;
binding3 = env3_3;
intl = binding(binding3[22]).intl;
format = intl.format;
t = binding(binding3[22]).t;
r8 = importDefault ? Reflect.apply(format, intl, [t.hGzPnx,
{channelName: channelName}]) : Reflect.apply(format,
intl, [t.rKzX1E, {channelName: channelName}]);
importAll(!importDefault);
binding = env3_1;
binding4 = env3_3;
value13 = binding(binding4[24]);
show = value13.show;
object2 = {title: r9, body: r8};
binding = env3_0;
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.cancelText = Reflect.apply(string, intl, [t['ETE/oC']]);
intl = binding(binding4[22]).intl;
string = intl.string;
t = binding(binding4[22]).t;
object2.confirmText = Reflect.apply(string, intl, [t.p89ACt]);
object2.onConfirm = env2_6;
object2.hideActionSheet = false;
object2.onCancel = onCancel_116026;
Reflect.apply(show, value13, [object2]);
return undefined;
}
function _fun116038() { // fn#116038, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:5144, offset: 0x0247928e, size: 140 bytes, params: 1, frame: 18
let value = environment.__proto__;
const defaultImport = AppAnalyticsUtils;
const trackWithMetadata = defaultImport.trackWithMetadata;
const CHANNEL_PERMISSIONS_PAGE_VIEWED = AnalyticEvents.CHANNEL_PERMISSIONS_PAGE_VIEWED;
const object = {};
const binding = env0_3;
const BASIC = env1_25.BASIC;
object.mode = binding === BASIC ? SettingMode.BASIC : SettingMode.ADVANCED;
value = importAll(9088) /* metro dependency 9088: ChannelPermissionsUtils */;
object.channel_is_private = value.isPrivateGuildChannel(channel);
Reflect.apply(trackWithMetadata, defaultImport, [CHANNEL_PERMISSIONS_PAGE_VIEWED, object]);
}
}
}
function onCancel_116026() { // fn#116026, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15382:2293, offset: 0x02478ce7, size: 54 bytes, params: 1, frame: 13
const value3 = env4_2(env4_3[19]);
importAll(value3.isPrivateGuildChannel(require));
}
global.__d(_fun116013, 15185, [57, 5, 31, 27, 15186, 1379, 1945, 1938, 1867, 3784, 3793, 1878, 8120, 661, 33, 4501,
697, 1484, 566, 9088, 9089, 9090, 1244, 4805, 4647, 9096, 3789, 4572, 6231, 6808, 1305, 6238, 10504, 11392,
5286, 4863, 8853, 9221, 15187, 15189,
2]) /* metro module 15185, dependencies: [57, 5, 31, 27, 15186, 1379, 1945, 1938, 1867, 3784, 3793, 1878, 8120, 661, 33, 4501, 697, 1484, 566, 9088, 9089, 9090, 1244, 4805, 4647, 9096, 3789, 4572, 6231, 6808, 1305, 6238, 10504, 11392, 5286, 4863, 8853, 9221, 15187, 15189, 2] */;