Initial commit

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

No files matched your search

@@ -0,0 +1,280 @@
/* Metro module 11425; source: modules/create_guild/native/AcceptGuildTemplate.tsx; dependencies: [31, 27, 1383, 1939, 661, 6934, 33, 4501, 697, 6597, 5461, 44, 1585, 1942, 4573, 1244, 9664, 8967, 4578, 7331, 1305, 22, 9062, 11426, 11427, 11428, 673, 2] */
function _fun87468(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#87468, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:6, offset: 0x01fbf3af, size: 950 bytes, params: 8, frame: 31
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_4 = value.View;
const env0_5 = value.ScrollView;
const env0_6 = (require(1383) /* metro dependency 1383: ChannelRecord */).isGuildVocalChannelType;
const env0_7 = (require(1939) /* metro dependency 1939: GuildRoleRecord */).isEveryoneRole;
value = require(661) /* metro dependency 661: Constants */;
const env0_8 = value.MarketingURLs;
const Fonts = value.Fonts;
const env0_9 = value.ChannelTypes;
const env0_10 = (require(6934) /* metro dependency 6934: GuildTemplatesConstants */).GuildTemplateStates;
value = require(33) /* metro dependency 33 */;
const env0_11 = value.jsx;
const env0_12 = value.jsxs;
const env0_13 = value.Fragment;
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.wrapper = {backgroundColor: BACKGROUND_BASE_LOWER, padding: 16};
const object4 = {textAlign: 'center'};
const textStyles = importDefault(6597) /* metro dependency 6597: TextStyles */;
let DISPLAY_EXTRABOLD = Fonts.DISPLAY_EXTRABOLD;
let MOBILE_TEXT_HEADING_PRIMARY = (importDefault(697) /* metro dependency 697: native */).colors.MOBILE_TEXT_HEADING_PRIMARY;
copyDataProperties(object4, textStyles(DISPLAY_EXTRABOLD, MOBILE_TEXT_HEADING_PRIMARY, 24), undefined);
object2.header = object4;
object2.description = {'textAlign': 'center', 'marginTop': 8, 'marginBottom': 32};
object2.iconUploader = {'alignSelf': 'center', 'marginBottom': 12};
object2.createButtonWrapper = {marginTop: 8};
object2.resolvingContainer = {'alignItems': 'center', 'flex': 1, 'justifyContent': 'center'};
object2.divider = {marginTop: 8};
const object5 = {};
const value3 = textStyles;
DISPLAY_EXTRABOLD = Fonts.DISPLAY_EXTRABOLD;
MOBILE_TEXT_HEADING_PRIMARY = (importDefault(697) /* metro dependency 697: native */).colors.MOBILE_TEXT_HEADING_PRIMARY;
copyDataProperties(object5, value3(DISPLAY_EXTRABOLD, MOBILE_TEXT_HEADING_PRIMARY, 16), undefined);
object5['marginTop'] = 24;
object2.sectionHeader = object5;
const object8 = {};
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object8.backgroundColor = BACKGROUND_SURFACE_HIGH;
object8.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
object8.marginTop = 8;
object8.padding = 8;
object2.rolesChannelsWrapper = object8;
object2.channelsWrapper = {'flexDirection': 'column', 'paddingVertical': 0};
object2.rolesWrapper = {'flexDirection': 'row', 'flexWrap': 'wrap'};
object2.channelRow = {'alignItems': 'center', 'flexDirection': 'row', 'height': 40};
object2.channelIcon = {'marginLeft': 12, 'marginRight': 8, 'height': 20, 'width': 20};
object2.channelCategoryIcon = {'marginLeft': 0, 'marginRight': 2, 'height': 12, 'width': 12};
const CHANNELS_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.CHANNELS_DEFAULT;
object2.channelName = {'color': null, 'fontSize': 16, 'flex': 1, color: CHANNELS_DEFAULT};
const object10 = {};
const value4 = textStyles;
DISPLAY_EXTRABOLD = Fonts.DISPLAY_EXTRABOLD;
copyDataProperties(object10, value4(DISPLAY_EXTRABOLD, undefined, 12, {uppercase: true}), 12);
object2.channelCategoryName = object10;
object2.sectionTip = {marginTop: 8};
const GREEN_360 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GREEN_360;
const PRIMARY_BOLD = Fonts.PRIMARY_BOLD;
object2.protip = {color: GREEN_360, fontFamily: PRIMARY_BOLD, textTransform: 'uppercase'};
const env0_14 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/AcceptGuildTemplate.tsx');
exports.default = AcceptGuildTemplate;
}
function GuildTemplateResolving() { // fn#87469, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:1583, offset: 0x01fbf765, size: 83 bytes, params: 1, frame: 17
const styles = useStyles();
const ActivityIndicator = (require(5461) /* metro dependency 5461: ActivityIndicatorNative */).ActivityIndicator;
return (
<View style={styles.resolvingContainer}>
<ActivityIndicator />
</View>
);
}
function GuildTemplateResolved({guildTemplate, createServer, name, setName, icon, chooseIcon, errors}) { // fn#87470, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:1710, offset: 0x01fbf7b8, size: 1660 bytes, params: 2, frame: 35
var r5;
var jsxRuntimeEnv0_13Binding;
var items5;
const styles = useStyles();
(importDefault(44) /* metro dependency 44 */)(guildTemplate != null, 'guild template cannot be null');
const defaultImport2 = importDefault(44) /* metro dependency 44 */;
let state = guildTemplate.state;
const RESOLVING = GuildTemplateStates.RESOLVING;
defaultImport2(state !== RESOLVING, 'guild must be resolved');
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const value5 = guildTemplate.serializedSourceGuild.roles.map(_fun87471).filter(function(a0) {
return !isEveryoneRole(a0);
});
const items3 = [styles.wrapper];
items3[1] = {marginBottom: bottom};
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const QzUORX = t.QzUORX;
const items2 = [<Text style={styles.header} variant="heading-xl/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
intl, [QzUORX])}</Text>];
items2[1] = <Text style={styles.description} variant="text-lg/medium" color="text-default">{guildTemplate.name}</Text>;
items2[2] = ((Component) => <Component iconBackgroundColor={styles.wrapper.backgroundColor} style={styles.iconUploader} onPress={chooseIcon} icon={icon} />)(importDefault(9664) /* metro dependency 9664: GuildIconUploader */);
const FreeFormInputGroup = importDefault(8967) /* metro dependency 8967: FreeFormInputGroup */;
const freeFormInputGroupProps = {label: intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dBih7e),
error: errors?.name};
const format = intl.format;
const property = (require(1244) /* metro dependency 1244: indexNative */).t['2bprXx'];
const GUIDELINES = MarketingURLs.GUIDELINES;
freeFormInputGroupProps.hint = Reflect.apply(format, intl, [property, {guidelinesURL: GUIDELINES}]);
freeFormInputGroupProps.value = name;
freeFormInputGroupProps.onChangeText = setName;
freeFormInputGroupProps.autoFocus = true;
freeFormInputGroupProps.autoCorrect = false;
freeFormInputGroupProps.returnKeyType = 'done';
items2[3] = <FreeFormInputGroup {...freeFormInputGroupProps} />;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const buttonProps = {size: 'md',
text: intl.string((require(1244) /* metro dependency 1244: indexNative */).t['O0p/lS']), onPress: createServer};
state = guildTemplate.state;
let ACCEPTING = GuildTemplateStates.ACCEPTING;
buttonProps.loading = state === ACCEPTING;
state = guildTemplate.state;
ACCEPTING = GuildTemplateStates.ACCEPTING;
buttonProps.disabled = state === ACCEPTING;
buttonProps.grow = true;
items2[4] = <View style={styles.createButtonWrapper}><Button {...buttonProps} /></View>;
items2[5] = ((Component) => <Component style={styles.divider} outer />)(importDefault(7331) /* metro dependency 7331: FormDivider */);
string = intl.string;
const OGiMXJ = (require(1244) /* metro dependency 1244: indexNative */).t.OGiMXJ;
items2[6] = <Text style={styles.sectionHeader} variant="heading-md/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
intl, [OGiMXJ])}</Text>;
string = intl.string;
const Ztwyoz = (require(1244) /* metro dependency 1244: indexNative */).t.Ztwyoz;
items2[7] = <Text variant="text-xs/medium" color="text-default">{Reflect.apply(string, intl, [Ztwyoz])}</Text>;
items2[8] = <Channels channels={guildTemplate.serializedSourceGuild.channels} />;
const LegacyText = (require(1305) /* metro dependency 1305: native */).LegacyText;
const items4 = [<LegacyText style={styles.protip}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['8tvIiN'])}{': '}</LegacyText>];
items4[1] = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.de7DpI);
items2[9] = <Text style={styles.sectionTip} variant="text-xs/medium" color="interactive-text-default">{items4}</Text>;
if (value5.length > 0) {
jsxRuntimeEnv0_13Binding = jsxRuntimeEnv0_13;
string = intl.string;
items5 = [<Text style={styles.sectionHeader} variant="heading-md/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
intl, [t.mQ0H1p])}</Text>];
string = intl.string;
items5[1] = <Text variant="text-xs/medium" color="text-default">{Reflect.apply(string, intl,
[t.jOPEYC])}</Text>;
items5[2] = <Roles roles={value5} />;
r5 = <>{items5}</>;
} else {
r5 = null;
}
items2[10] = r5;
return (
<ScrollView contentContainerStyle={items3} keyboardShouldPersistTaps="handled">
{items2}
</ScrollView>
);
}
function Channels({channels}) { // fn#87473, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:3909, offset: 0x01fbfe86, size: 147 bytes, params: 2, frame: 17
const styles = useStyles();
return (
<View style={[styles.rolesChannelsWrapper, styles.channelsWrapper]}>
{(importDefault(22) /* metro dependency 22 */)(channels).sortBy(function(a0) {
var r0;
var value;
if (a0.parent_id == null) {
value = global.Number(a0.id);
value = 10000 * value;
r0 = value;
} else {
value = global.Number(a0.parent_id);
value = 10000 * value;
value += a0.id;
r0 = value;
}
return r0;
}).map(_fun87475).value()}
</View>
);
}
function getChannelIcon_87476({type}) { // fn#87476, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:4495, offset: 0x01fc00b7, size: 105 bytes, params: 2, frame: 14
return isGuildVocalChannelType(type) ? importDefault(9062) /* metro dependency 9062 */ : type === ChannelTypes.GUILD_CATEGORY ? importDefault(11426) /* metro dependency 11426 */ : importDefault(11427) /* metro dependency 11427 */;
}
function Roles({roles}) { // fn#87477, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:4589, offset: 0x01fc0120, size: 110 bytes, params: 2, frame: 17
const styles = useStyles();
return (
<View style={[styles.rolesChannelsWrapper, styles.rolesWrapper]}>
{roles.slice().reverse().map(_fun87478)}
</View>
);
}
function AcceptGuildTemplate(a0) { // fn#87479, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:4923, offset: 0x01fc01ff, size: 172 bytes, params: 2, frame: 15
const guildTemplate = a0.guildTemplate;
if (guildTemplate != null) {
var state = guildTemplate.state;
var RESOLVED = GuildTemplateStates.RESOLVED;
if (RESOLVED === state) {
return <GuildTemplateResolved {...a0} />;
}
var ACCEPTING = GuildTemplateStates.ACCEPTING;
if (ACCEPTING === state) {
return <GuildTemplateResolved {...a0} />;
}
var ACCEPTED = GuildTemplateStates.ACCEPTED;
if (ACCEPTED === state) {
return <GuildTemplateResolved {...a0} />;
}
var RESOLVING = GuildTemplateStates.RESOLVING;
if (RESOLVING === state) {
return <GuildTemplateResolving {...a0} />;
}
}
return <GuildTemplateResolving {...a0} />;
}
function _fun87471(a0) { // fn#87471, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:1999, offset: 0x01fbfe34, size: 60 bytes, params: 2, frame: 13
let value = environment.__proto__;
value = importAll(1942) /* metro dependency 1942: GuildRoleRecordUtils */;
return value.fromServer(guildTemplate.serializedSourceGuild.id, a0);
}
function _fun87475(a0) { // fn#87475, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:4047, offset: 0x01fbff72, size: 325 bytes, params: 2, frame: 26
const type = a0.type;
const GUILD_CATEGORY = ChannelTypes.GUILD_CATEGORY;
const value2 = type === GUILD_CATEGORY;
const stylesBinding = styles;
const channelRow = stylesBinding.channelRow;
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
const items2 = [stylesBinding.channelIcon];
const value4 = null;
items2[1] = value2 ? styles.channelCategoryIcon : value4;
const PRIMARY_400 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.PRIMARY_400;
const Icon2 = (require(1305) /* metro dependency 1305: native */).Icon;
const Sizes = Icon2.Sizes;
const CUSTOM = Sizes.CUSTOM;
const icon = <Icon style={items2} color={PRIMARY_400} size={CUSTOM} source={getChannelIcon_87476(a0)} />;
const LegacyText = (require(1305) /* metro dependency 1305: native */).LegacyText;
return (
<View style={channelRow} key={a0.id}>
{icon}
<LegacyText numberOfLines={1} style={[styles.channelName, value2 ? styles.channelCategoryName : value4]}>
{a0.name}
</LegacyText>
</View>
);
}
function _fun87478(a0) { // fn#87478, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11611:4652, offset: 0x01fc018e, size: 113 bytes, params: 2, frame: 19
var r5;
let value = environment.__proto__;
const value2 = undefined;
const RolePill = importDefault(11428) /* metro dependency 11428: RolePill */;
if (a0.color === 0) {
r5 = value2;
} else {
value = require(673) /* metro dependency 673: ColorUtils */;
value = value.int2hex(a0.color);
r5 = value;
}
return (
<RolePill
disableInteraction
role={a0}
color={r5}
key={a0.id}
/>
);
}
@@ -0,0 +1,83 @@
/* Metro module 9663; source: modules/create_guild/native/CreateGuild.tsx; dependencies: [31, 27, 1878, 661, 33, 4501, 697, 4559, 4570, 4572, 4573, 1244, 9664, 7981, 6808, 6766, 4578, 8970, 2] */
function _fun75755(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#75755, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9849:6, offset: 0x01db7e52, size: 362 bytes, params: 8, frame: 21
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 */).ScrollView;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_6 = (require(661) /* metro dependency 661: Constants */).MarketingURLs;
let value = require(33) /* metro dependency 33 */;
const env0_7 = value.jsx;
const env0_8 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
const env0_9 = Reflect.apply(createStyles, value, [{flex: {flex: 1}, contentContainer: {'backgroundColor': null,
'paddingHorizontal': 16, 'paddingBottom': 16, backgroundColor: BACKGROUND_BASE_LOWER},
header: {textAlign: 'center'}, description: {'lineHeight': 18, 'textAlign': 'center', 'marginBottom': 24},
iconUploader: {'alignSelf': 'center', 'marginBottom': 4}, hint: {marginBottom: 8}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/CreateGuild.tsx');
exports.default = CreateGuild;
}
function CreateGuild({guild, onIconPress, onNameChange, onStaffOnlyChange, onCreate, submitting, error, customTitle, customDescription, customButtonLabel, autoFocus}) { // fn#75756, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9849:588, offset: 0x01db7fbc, size: 1331 bytes, params: 2, frame: 42
var r8;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
var TableSwitchRow;
autoFocus = autoFocus === undefined || autoFocus;
const styles = useStyles();
const currentUser = UserStore.getCurrentUser();
const r10 = currentUser == null || !currentUser.isStaff();
const value8 = !r10;
const value9 = (require(4559) /* metro dependency 4559: useIsScreenReaderEnabledNative */).useIsScreenReaderEnabled();
const binding = env0_3;
const value10 = binding.useRef(null);
binding.useEffect(_fun75757, [value9]);
const scrollViewBindingProps = {'style': null, 'contentInset': null, 'automaticallyAdjustContentInsets': false,
'keyboardShouldPersistTaps': 'handled', 'alwaysBounceVertical': false, style: styles.flex,
contentInset: {top: 0}, contentContainerStyle: styles.contentContainer};
const Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const items2 = [<Text ref={value10} style={styles.header} accessibilityRole="header" variant="heading-xl/extrabold" color="mobile-text-heading-primary">{customTitle ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.XioBx6)}</Text>];
items2[1] = <Text style={styles.description} variant="text-sm/medium" color="text-default">{customDescription ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['/k/L/j'])}</Text>;
items2[2] = ((Component) => <Component iconBackgroundColor={styles.contentContainer.backgroundColor} style={styles.iconUploader} onPress={onIconPress} icon={guild.icon} />)(importDefault(9664) /* metro dependency 9664: GuildIconUploader */);
const TextInput = (require(7981) /* metro dependency 7981: TextInputNative */).TextInput;
items2[3] = <TextInput isClearable label={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.dBih7e)} errorMessage={error?.getFirstFieldErrorMessage('name')} value={guild.name} onChange={onNameChange} autoFocus={autoFocus && !value9} autoCorrect={false} returnKeyType="done" />;
if (r10) {
r8 = value8;
} else {
TableSwitchRow = (require(6808) /* metro dependency 6808: TableSwitchRowNative */).TableSwitchRow;
r8 = <TableSwitchRow onValueChange={onStaffOnlyChange} value={guild.staffOnly} start end label="Staff Only" subLabel={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.edQ5va)} />;
}
items2[4] = r8;
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
const format = intl.format;
const property = (require(1244) /* metro dependency 1244: indexNative */).t['2bprXx'];
const GUIDELINES = MarketingURLs.GUIDELINES;
items2[5] = <TextWithIOSLinkWorkaround style={styles.hint} variant="text-xs/medium" color="text-muted">{Reflect.apply(format,
intl, [property, {guidelinesURL: GUIDELINES}])}</TextWithIOSLinkWorkaround>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
items2[6] = <Button disabled={guild.name === ''} size="md" grow text={customButtonLabel ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['O0p/lS'])} onPress={onCreate} loading={submitting} />;
r8 = error?.getFirstFieldErrorMessage('name');
r8 = r8 == null && error?.message != null ? error?.message === '' ? null : ((Component) => <Component>{error?.message}</Component>)(importDefault(8970) /* metro dependency 8970: FreeFormErrorLabel */) : null;
items2[7] = r8;
return (
<ScrollView {...scrollViewBindingProps}>
<Stack>
{items2}
</Stack>
</ScrollView>
);
}
function _fun75757() { // fn#75757, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9849:904, offset: 0x01db84ef, size: 86 bytes, params: 1, frame: 12
var value3;
var moduleValue;
if (env0_0 && env0_1.current != null) {
value3 = environment.__proto__;
moduleValue = require(4570) /* metro dependency 4570: setAccessibilityFocusAndroid */;
moduleValue.setAccessibilityFocus({ref: env0_1, delay: 100});
}
}
@@ -0,0 +1,23 @@
/* Metro module 9006; source: modules/create_guild/native/CreateGuildConstants.tsx; dependencies: [2] */
function _fun70075(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#70075, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9191:6, offset: 0x01ced750, size: 283 bytes, params: 8, frame: 18
var object2;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
object2 = {NUF: 0};
object2[0] = 'NUF';
object2.IN_APP = 1;
object2[1] = 'IN_APP';
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/CreateGuildConstants.tsx');
exports.NUXGuildTemplatesAnalytics = {'FLOW_TYPE': 'Mobile NUX Post Reg', 'STEP_REGISTRATION': 'Registration',
'STEP_GUILD_CREATE': 'Guild Create', 'STEP_GUILD_JOIN': 'Guild Join', 'STEP_GUILD_TEMPLATE': 'Guild Template',
'STEP_FRIEND_LIST': 'Friend List', 'STEP_CREATION_INTENT': 'Server Intent Discovery',
'STEP_INTENT_LANDING': 'Intent Landing', 'STEP_FRIEND_ADD': 'Friend Add'};
exports.CREATE_GUILD_SMALL_SCREEN_MAX_HEIGHT = 375;
exports.IN_APP_GUILD_TEMPLATES_MODAL_KEY = 'in-app-guild-templates';
exports.GuildTemplateTriggers = object2;
exports.GuildTemplateLocation = {FRIENDS_LIST_WELCOME_WIDGET: 'Friends List Welcome Widget'};
exports.CreateGuildModalStates = {CREATE_SERVER: 'create_server', JOIN_SERVER: 'join_server',
ACCEPT_INVITE: 'accept_invite', GUILD_TEMPLATES: 'guild_templates', CHANNEL_PROMPT: 'channel_prompt',
CREATION_INTENT: 'creation_intent', GUILD_INVITE: 'guild_invite', JOIN_STUDENT_HUB: 'join_student_hub'};
}
@@ -0,0 +1,33 @@
/* Metro module 12028; source: modules/create_guild/native/CreateGuildIcons.tsx; dependencies: [9655, 9659, 9657, 9658, 9660, 9661, 9656, 5473, 2] */
function _fun92436(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92436, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12214:6, offset: 0x020893ef, size: 387 bytes, params: 8, frame: 18
var object3;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
object3 = {CREATE: importDefault(9655) /* metro dependency 9655 */,
GAMING: importDefault(9659) /* metro dependency 9659 */,
FRIENDS: importDefault(9657) /* metro dependency 9657 */,
STUDY: importDefault(9658) /* metro dependency 9658 */, CLUBS: importDefault(9660) /* metro dependency 9660 */,
CREATORS: importDefault(9661) /* metro dependency 9661 */,
LOCAL_COMMUNITY: importDefault(9656) /* metro dependency 9656 */,
SCHOOL_CLUB: importDefault(9660) /* metro dependency 9660 */};
const object4 = {};
const PencilIllocon = (require(5473) /* metro dependency 5473: native */).PencilIllocon;
object4.CREATE = PencilIllocon;
const ControllerIllocon = (require(5473) /* metro dependency 5473: native */).ControllerIllocon;
object4.GAMING = ControllerIllocon;
const HeartIllocon = (require(5473) /* metro dependency 5473: native */).HeartIllocon;
object4.FRIENDS = HeartIllocon;
const AppleIllocon = (require(5473) /* metro dependency 5473: native */).AppleIllocon;
object4.STUDY = AppleIllocon;
const BookIllocon = (require(5473) /* metro dependency 5473: native */).BookIllocon;
object4.CLUBS = BookIllocon;
const PaintIllocon = (require(5473) /* metro dependency 5473: native */).PaintIllocon;
object4.CREATORS = PaintIllocon;
const LeafIllocon = (require(5473) /* metro dependency 5473: native */).LeafIllocon;
object4.LOCAL_COMMUNITY = LeafIllocon;
object4.SCHOOL_CLUB = BookIllocon;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/CreateGuildIcons.tsx');
exports.GUILD_TEMPLATE_ICONS = object3;
exports.GUILD_TEMPLATE_ICON_COMPONENTS = object4;
}
@@ -0,0 +1,30 @@
/* Metro module 12025; source: modules/create_guild/native/CreateGuildModalActionCreators.tsx; dependencies: [9006, 5080, 12026, 1962, 12021, 2] */
function _fun92395(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92395, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12211:6, offset: 0x02087c93, size: 189 bytes, params: 8, frame: 18
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const createGuildConstantsModule = require(9006) /* metro dependency 9006: CreateGuildConstants */;
const env0_3 = createGuildConstantsModule.CreateGuildModalStates;
const env0_4 = createGuildConstantsModule.IN_APP_GUILD_TEMPLATES_MODAL_KEY;
object2 = {openCreateGuildModal: function(a0) {
importDefault(dependencyMap[1]).pushLazy(require(dependencyMap[3])(dependencyMap[2], dependencyMap.paths),
{onSuccess: a0}, IN_APP_GUILD_TEMPLATES_MODAL_KEY);
}, closeCreateGuildModal: function() {
importDefault(dependencyMap[1]).popWithKey(IN_APP_GUILD_TEMPLATES_MODAL_KEY);
}, closeCreateGuildOnboardingModal: closeCreateGuildOnboardingModal, openGuildInviteScreen: function(a0) {
importDefault(dependencyMap[1]).pushLazy(require(dependencyMap[3])(dependencyMap[2], dependencyMap.paths),
{channel: a0}, IN_APP_GUILD_TEMPLATES_MODAL_KEY);
}, openGuildJoinServerScreen: function() {
importDefault(dependencyMap[1]).pushLazy(require(dependencyMap[3])(dependencyMap[2], dependencyMap.paths),
{initialState: CreateGuildModalStates.JOIN_SERVER}, IN_APP_GUILD_TEMPLATES_MODAL_KEY);
}};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/CreateGuildModalActionCreators.tsx');
exports.default = object2;
}
function closeCreateGuildOnboardingModal() { // fn#92398, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12211:337, offset: 0x02087dd2, size: 71 bytes, params: 1, frame: 14
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popWithKey(IN_APP_GUILD_TEMPLATES_MODAL_KEY);
(require(12021) /* metro dependency 12021: NUFActionCreators */).nextOnboardingStep({});
}
@@ -0,0 +1,345 @@
/* Metro module 12033; source: modules/create_guild/native/components/AcceptInviteContainer.tsx; dependencies: [5, 31, 1945, 1867, 4097, 3772, 33, 4501, 697, 1484, 566, 5282, 1391, 6598, 1962, 4116, 9052, 6905, 8879, 8581, 12034, 6618, 3868, 2] */
function _fun92478(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92478, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:6, offset: 0x0208b35a, size: 300 bytes, params: 8, frame: 21
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(5) /* metro dependency 5 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const inviteStore = importDefault(4097) /* metro dependency 4097: InviteStore */;
const env0_8 = (require(3772) /* metro dependency 3772: GuildMemberConstants */).GuildMemberFlags;
const env0_9 = (require(33) /* metro dependency 33 */).jsx;
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = createStylesModule.createStyles;
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
const env0_10 = Reflect.apply(createStyles, createStylesModule, [{flex: {flex: 1},
paddingContainer: {backgroundColor: BACKGROUND_SURFACE_HIGH}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/AcceptInviteContainer.tsx');
exports.default = AcceptInviteContainer;
}
function AcceptInviteContainer(a0) { // fn#92479, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:413, offset: 0x0208b486, size: 480 bytes, params: 2, frame: 27
const code = a0.code;
const onPressClose = a0.onPressClose;
const inviteInstanceId = a0.inviteInstanceId;
const object2 = {'code': 0, 'onPressClose': 0, 'inviteInstanceId': 0};
silentSetPrototypeOf(object2, null, undefined);
let value = copyDataProperties({}, a0, object2, undefined);
const styles = useStyles();
const isRegistration = value.isRegistration;
const env0_3 = isRegistration;
const value3 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const env0_4 = value3;
const value4 = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([InviteStore,
GuildMemberStore, GuildStore], _fun92480);
const binding = env0_4;
binding.useLayoutEffect(_fun92482, [value4, value3, onPressClose]);
const useCallback = binding.useCallback;
const binding2 = env0_3;
value = ((Component) => <Component code={code} onPressClose={onPressClose} onPressJoin={binding.useCallback(binding2(_fun92487),
[value4, Reflect.apply(useCallback, binding, [binding2(_fun92485), [isRegistration, value4]]), onPressClose,
inviteInstanceId])} {...value} {...value4} />)(importDefault(12034) /* metro dependency 12034: AcceptInvite */);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
const items5 = [styles.flex];
items5[1] = styles.paddingContainer;
const ThemeContextProvider = (require(3868) /* metro dependency 3868: native */).ThemeContextProvider;
return (
<SafeAreaPaddingView style={items5} bottom>
<ThemeContextProvider theme="darker">
{value}
</ThemeContextProvider>
</SafeAreaPaddingView>
);
}
function _fun92480() { // fn#92480, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:593, offset: 0x0208b666, size: 304 bytes, params: 1, frame: 19
var environment;
var roles;
var r8;
var r3;
var Set;
var set;
let value = environment.__proto__;
const getInvite = InviteStore.getInvite;
const codeBinding = code;
const value3 = Reflect.apply(getInvite, InviteStore, [codeBinding]);
const inviteError = InviteStore.getInviteError(codeBinding);
const value5 = null;
const value6 = undefined;
let r2 = value5 != (value5 == value3 ? value6 : value3.guild) && value5 != GuildStore.getGuild(value3.guild.id);
const r1 = value5 != (value5 == value3 ? value6 : value3.guild) ? GuildMemberStore.getSelfMember(value3.guild.id) : value5;
value = false;
if (r2) {
roles = value5 == value3 ? value6 : value3.roles;
if (value5 != roles) {
roles = value3.roles;
if (roles.length > 0) {
Set = global.Set;
roles = value5 == r1 ? value6 : r1.roles;
r8 = value5 != roles ? roles : [];
set = new Set();
roles = value3.roles;
set = roles.some(_fun92481);
r3 = set;
} else {
r3 = value;
}
} else {
r3 = value;
}
} else {
r3 = value;
}
r2 = r2 && !r3;
return {invite: value3, inviteError: inviteError, isGuildMember: r2, guildMember: r1};
}
function _fun92482() { // fn#92482, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1007, offset: 0x0208b796, size: 96 bytes, params: 1, frame: 15
var environment;
var r3;
var value2;
var moduleValue;
const binding = env0_4;
const setOptions = binding.setOptions;
if (env0_5.invite != null) {
r3 = function() {
return null;
};
} else {
value2 = environment.__proto__;
moduleValue = require(5282) /* metro dependency 5282: NavigatorHeaderNative */;
r3 = moduleValue.getHeaderBackButton(onPressClose);
}
Reflect.apply(setOptions, binding, [{headerLeft: r3}]);
}
function* _fun92485() { // fn#92485, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1129, offset: 0x0208b801, size: 202 bytes, params: 1, frame: 18
var binding;
var value3;
var binding2;
var property;
if (true) {
value = environment.__proto__;
var guildMember = GuildMemberStore.guildMember;
if (env1_3) {
if (guildMember == null) {
return undefined;
}
value = environment.__proto__.__proto__;
binding = env2_0;
value3 = binding(env2_2[12]);
if (value3.hasFlag(guildMember.flags ?? 0, env2_8.COMPLETED_ONBOARDING)) {
return undefined;
}
binding = env2_0;
binding2 = env2_2;
value = binding(binding2[14]);
property = binding2[13];
yield value(property, binding2.paths);
value = undefined;
if (false) {
return value;
}
property = value.default;
yield property({guildId: guildMember.guildId});
value = undefined;
if (false) {
return value;
}
}
}
}
function* _fun92487() { // fn#92487, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1348, offset: 0x0208b8d6, size: 253 bytes, params: 1, frame: 22
var r12;
var environment;
var object3;
if (true) {
value = environment.__proto__;
var isGuildMember = GuildMemberStore.isGuildMember;
var invite = GuildMemberStore.invite;
var value3 = _fun92488();
var value5 = env2_0(env2_2[19]);
if (value5.handleNSFWGuildInvite(invite)) {
return importDefault();
}
if (isGuildMember) {
yield GuildStore();
if (false) {
return undefined;
}
value3(invite);
} else {
if (invite == null) {
yield GuildStore();
if (false) {
return undefined;
}
value3(invite);
return undefined;
}
var value6 = env2_1(env2_2[18]);
var acceptInvite = value6.acceptInvite;
var object4 = {};
object4.inviteKey = invite.code;
var object5 = {location: 'Accept Invite Page'};
if (dependencyMap != null) {
object3 = {invite_instance_id: dependencyMap};
r12 = dependencyMap;
} else {
object3 = {};
}
copyDataProperties(object5, object3, r12);
object4.context = object5;
object4.callback = callback_92493;
Reflect.apply(acceptInvite, value6, [object4]);
}
}
}
function _fun92488() { // fn#92488, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1395, offset: 0x0208b9d3, size: 36 bytes, params: 1, frame: 12
const env0_0 = env3_3(_fun92490);
return _fun92492;
}
function* _fun92490(a0) { // fn#92490, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1415, offset: 0x0208ba02, size: 325 bytes, params: 2, frame: 20
var environment;
var id;
var guild_scheduled_event;
var value3;
var value4;
var binding;
var value5;
var guild;
var value6;
var isRoleSubscriptionInvite;
var binding2;
var property;
var value7;
var performRoleSubscriptionUpsellRedirect;
var value8;
var value9;
var value10;
var error;
var channel;
var value11;
var value12;
var setTimeout;
var value13;
let value = undefined;
if (true) {
var env0_0 = a0;
value = undefined;
if (a0 != null) {
value4 = environment.__proto__.__proto__.__proto__.__proto__.__proto__;
binding = env5_0;
value5 = binding(env5_2[15]);
if (value5.isGuildScheduledEventInviteEmbed(a0)) {
reducibleJoin26: while (true) {
if (a0 == null) {
guild_scheduled_event = value;
break reducibleJoin26;
}
guild_scheduled_event = a0.guild_scheduled_event;
break reducibleJoin26;
}
if (guild_scheduled_event == null) {
return value;
}
value13 = environment.__proto__.__proto__.__proto__.__proto__;
env4_1();
binding = env5_0;
binding(env5_2[16]).transitionToEventDetailsFromInvite(guild_scheduled_event);
return value;
}
guild = a0.guild;
reducibleJoin6: while (true) {
if (guild == null) {
id = value;
break reducibleJoin6;
}
id = guild.id;
break reducibleJoin6;
}
reducibleJoin21: while (true) {
reduciblePort20: while (true) {
exceptionLanding19: while (true) {
binding = env5_0;
value6 = binding(env5_2[15]);
isRoleSubscriptionInvite = value6.isRoleSubscriptionInvite;
if (Reflect.apply(isRoleSubscriptionInvite, value6, [a0])) {
if (id == null) {
break reduciblePort20;
}
try {
binding = env5_1;
} catch (error) {
break exceptionLanding19;
}
try {
binding2 = env5_2;
} catch (error) {
break exceptionLanding19;
}
try {
property = binding2[17];
} catch (error) {
break exceptionLanding19;
}
try {
value7 = binding(property);
} catch (error) {
break exceptionLanding19;
}
try {
performRoleSubscriptionUpsellRedirect = value7.performRoleSubscriptionUpsellRedirect;
} catch (error) {
break exceptionLanding19;
}
try {
value8 = Reflect.apply(performRoleSubscriptionUpsellRedirect, value7, [id]);
} catch (error) {
break exceptionLanding19;
}
yield value8;
try {
value9 = undefined;
value10 = false;
} catch (error) {
break exceptionLanding19;
}
if (value10) {
return value9;
}
break reduciblePort20;
}
break reduciblePort20;
}
break reduciblePort20;
}
channel = a0.channel;
if (channel == null) {
break reducibleJoin21;
}
value12 = environment.__proto__.__proto__.__proto__.__proto__;
env4_1();
setTimeout = global.setTimeout;
setTimeout(_fun92491, 1);
return value;
}
value11 = environment.__proto__.__proto__.__proto__.__proto__;
env4_1();
} else {
value3 = environment.__proto__.__proto__.__proto__.__proto__;
env4_1();
}
}
return value;
}
function _fun92491() { // fn#92491, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12219:1809, offset: 0x0208bb47, size: 45 bytes, params: 1, frame: 12
const value = environment.__proto__.__proto__.__proto__.__proto__.__proto__.__proto__;
env6_1(env6_2[18]).transitionToInvite(env0_0);
}
@@ -0,0 +1,484 @@
/* Metro module 9662; source: modules/create_guild/native/components/CreateGuildContainer.tsx; dependencies: [5, 57, 31, 1935, 1878, 661, 33, 4501, 5314, 6592, 4660, 9649, 6593, 1418, 9164, 6618, 9663, 2] */
function _fun75748(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#75748, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9848:6, offset: 0x01db788d, size: 295 bytes, params: 8, frame: 20
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(5) /* metro dependency 5 */;
const env0_4 = importDefault(57) /* metro dependency 57 */;
const env0_5 = importAll(31) /* metro dependency 31 */;
const guildChannelStore = importDefault(1935) /* metro dependency 1935: GuildChannelStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_8 = (require(661) /* metro dependency 661: Constants */).UPLOAD_MEDIUM_SIZE;
const env0_9 = (require(33) /* metro dependency 33 */).jsx;
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = createStylesModule.createStyles;
const NAV_BAR_HEIGHT = (require(5314) /* metro dependency 5314: NavigatorConstantsNative */).NAV_BAR_HEIGHT;
const env0_10 = Reflect.apply(createStyles, createStylesModule, [{flex: {flex: 1},
contentContainer: {marginTop: NAV_BAR_HEIGHT}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/CreateGuildContainer.tsx');
exports.default = CreateGuildContainer;
}
function CreateGuildContainer(a0) { // fn#75749, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9848:389, offset: 0x01db79b4, size: 618 bytes, params: 2, frame: 35
const onCreate = a0.onCreate;
const guildTemplate = a0.guildTemplate;
let autoFocus = a0.autoFocus;
autoFocus = autoFocus === undefined || autoFocus;
const onHubGuildInfoSet = a0.onHubGuildInfoSet;
const isCommunityIntent = a0.isCommunityIntent;
const env0_3 = isCommunityIntent;
const object2 = {'onCreate': 0, 'guildTemplate': 0, 'autoFocus': 0, 'onHubGuildInfoSet': 0, 'isCommunityIntent': 0};
silentSetPrototypeOf(object2, null, undefined);
const value = copyDataProperties({}, a0, object2, undefined);
const env0_4 = undefined;
const env0_5 = undefined;
const styles = useStyles();
const binding = env0_5;
let useState = binding.useState;
const defaultImport = importDefault(6592) /* metro dependency 6592: GuildUtils */;
const getGuildNameSuggestion = defaultImport.getGuildNameSuggestion;
const value3 = Reflect.apply(useState, binding, [Reflect.apply(getGuildNameSuggestion, defaultImport,
[{truncateUsername: true}])]);
const binding2 = env0_4;
const value4 = binding2(value3, 2);
const property = value4[0];
const property2 = value4[1];
useState = binding.useState;
const value5 = binding2(Reflect.apply(useState, binding, [null]), 2);
const property3 = value5[0];
const env0_6 = value5[1];
useState = binding.useState;
const value6 = binding2(Reflect.apply(useState, binding, [false]), 2);
const property4 = value6[0];
const env0_7 = value6[1];
useState = binding.useState;
const value7 = binding2(Reflect.apply(useState, binding, [null]), 2);
const property5 = value7[0];
const env0_8 = value7[1];
useState = binding.useState;
const value8 = binding2(Reflect.apply(useState, binding, [_fun75750]), 2);
const property6 = value8[0];
const property7 = value8[1];
const useCallback = binding.useCallback;
const binding3 = env0_3;
const value10 = Reflect.apply(useCallback, binding, [binding3(_fun75752), []]);
const value12 = binding.useCallback(binding3(_fun75754), [guildTemplate, property3, property, onCreate,
onHubGuildInfoSet, property6, isCommunityIntent]);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
return (
<SafeAreaPaddingView top style={[styles.flex, styles.contentContainer]}>
{((Component) => <Component {...value} {...{['guild']: {name: property, icon: property3,
staffOnly: property6}}} {...{['error']: property5}} {...{['submitting']: property4}} {...{['onIconPress']: value10}} {...{['onNameChange']: property2}} {...{['onStaffOnlyChange']: property7}} {...{['onCreate']: value12}} {...{['autoFocus']: autoFocus}} />)(importDefault(9663) /* metro dependency 9663: CreateGuild */)}
</SafeAreaPaddingView>
);
}
function _fun75750() { // fn#75750, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9848:748, offset: 0x01db7c1e, size: 49 bytes, params: 1, frame: 11
var r1;
let value = environment.__proto__;
value = UserStore.getCurrentUser();
if (value == null) {
r1 = undefined;
} else {
value = value.isStaff();
r1 = value;
}
return r1 != null && r1;
}
function* _fun75752() { // fn#75752, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9848:874, offset: 0x01db7c5a, size: 96 bytes, params: 1, frame: 14
if (true) {
value = environment.__proto__.__proto__;
var value3 = env2_1(env2_2[10]);
yield value3.openImagePicker({size: env2_8});
value = undefined;
if (false) {
return value;
}
var base64 = value.base64;
if (base64 != null) {
value = environment.__proto__;
GuildChannelStore(base64);
}
}
}
function* _fun75754() { // fn#75754, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9848:982, offset: 0x01db7cc5, size: 397 bytes, params: 1, frame: 27
var r6;
var value4;
var value5;
var binding;
var binding2;
var property;
var value6;
var createGuildFromTemplate;
var binding3;
var binding4;
var jsxRuntimeEnv1_9Binding;
var guildFromTemplate;
var value7;
var value8;
var id;
var binding5;
var value9;
var waitForGuild;
var value10;
var value11;
var value12;
var getDefaultChannel;
var value13;
var binding6;
var value14;
var dangerouslyConstructGuildRecordFromUntypedObject;
var value15;
var value16;
var loadInviteSuggestions;
var object2;
var Set;
var prototype;
var set;
var value18;
var inviteSuggestions;
var value19;
var value20;
var value21;
var moduleValue;
var value22;
var value23;
var binding7;
var error;
let value = undefined;
if (true) {
value = undefined;
UserStore(true);
reducibleJoin3: while (true) {
reduciblePort84: while (true) {
exceptionLanding83: while (true) {
try {
} catch (error) {
break exceptionLanding83;
}
break reducibleJoin3;
}
UPLOAD_MEDIUM_SIZE(error);
break reduciblePort84;
}
UserStore(false);
return value;
}
try {
value4 = dependencyMap != null;
} catch (error) {
break exceptionLanding83;
}
if (value4) {
try {
} catch (error) {
break exceptionLanding83;
}
try {
binding = env1_4;
} catch (error) {
break exceptionLanding83;
}
try {
binding7 = env1_5;
} catch (error) {
break exceptionLanding83;
}
try {
} catch (error) {
break exceptionLanding83;
}
try {
dependencyMap(binding, binding7, importDefault);
} catch (error) {
break exceptionLanding83;
}
} else {
value5 = environment.__proto__.__proto__;
try {
binding = env2_1;
} catch (error) {
break exceptionLanding83;
}
try {
binding2 = env2_2;
} catch (error) {
break exceptionLanding83;
}
try {
property = binding2[11];
} catch (error) {
break exceptionLanding83;
}
try {
value6 = binding(property);
} catch (error) {
break exceptionLanding83;
}
try {
createGuildFromTemplate = value6.createGuildFromTemplate;
} catch (error) {
break exceptionLanding83;
}
try {
binding = env1_4;
} catch (error) {
break exceptionLanding83;
}
try {
binding3 = env1_5;
} catch (error) {
break exceptionLanding83;
}
try {
} catch (error) {
break exceptionLanding83;
}
try {
binding4 = env1_3;
} catch (error) {
break exceptionLanding83;
}
try {
jsxRuntimeEnv1_9Binding = jsxRuntimeEnv1_9;
} catch (error) {
break exceptionLanding83;
}
try {
guildFromTemplate = Reflect.apply(createGuildFromTemplate, value6, [binding, binding3, importDefault,
binding4,
jsxRuntimeEnv1_9Binding]);
} catch (error) {
break exceptionLanding83;
}
yield guildFromTemplate;
try {
value7 = undefined;
value8 = false;
} catch (error) {
break exceptionLanding83;
}
if (value8) {
return value7;
}
try {
id = value7.id;
} catch (error) {
break exceptionLanding83;
}
try {
binding = env2_0;
} catch (error) {
break exceptionLanding83;
}
try {
binding5 = env2_2;
} catch (error) {
break exceptionLanding83;
}
try {
property = binding5[12];
} catch (error) {
break exceptionLanding83;
}
try {
value9 = binding(property);
} catch (error) {
break exceptionLanding83;
}
try {
waitForGuild = value9.waitForGuild;
} catch (error) {
break exceptionLanding83;
}
try {
value10 = Reflect.apply(waitForGuild, value9, [id]);
} catch (error) {
break exceptionLanding83;
}
yield value10;
try {
value11 = undefined;
value12 = false;
} catch (error) {
break exceptionLanding83;
}
if (value12) {
return value11;
}
try {
binding = env2_6;
} catch (error) {
break exceptionLanding83;
}
try {
getDefaultChannel = binding.getDefaultChannel;
} catch (error) {
break exceptionLanding83;
}
try {
value13 = Reflect.apply(getDefaultChannel, binding, [id]);
} catch (error) {
break exceptionLanding83;
}
try {
binding = env2_0;
} catch (error) {
break exceptionLanding83;
}
try {
binding6 = env2_2;
} catch (error) {
break exceptionLanding83;
}
try {
property = binding6[13];
} catch (error) {
break exceptionLanding83;
}
try {
value14 = binding(property);
} catch (error) {
break exceptionLanding83;
}
try {
dangerouslyConstructGuildRecordFromUntypedObject = value14.dangerouslyConstructGuildRecordFromUntypedObject;
} catch (error) {
break exceptionLanding83;
}
try {
value15 = Reflect.apply(dangerouslyConstructGuildRecordFromUntypedObject, value14, [value7]);
} catch (error) {
break exceptionLanding83;
}
try {
property = binding6[14];
} catch (error) {
break exceptionLanding83;
}
try {
value16 = binding(property);
} catch (error) {
break exceptionLanding83;
}
try {
loadInviteSuggestions = value16.loadInviteSuggestions;
} catch (error) {
break exceptionLanding83;
}
try {
object2 = {};
} catch (error) {
break exceptionLanding83;
}
try {
Set = global.Set;
} catch (error) {
break exceptionLanding83;
}
try {
prototype = Set.prototype;
} catch (error) {
break exceptionLanding83;
}
try {
} catch (error) {
break exceptionLanding83;
}
try {
set = new Set();
} catch (error) {
break exceptionLanding83;
}
try {
value18 = set instanceof Object ? set : undefined;
} catch (error) {
break exceptionLanding83;
}
try {
object2.omitUserIds = value18;
} catch (error) {
break exceptionLanding83;
}
try {
object2.guild = value15;
} catch (error) {
break exceptionLanding83;
}
try {
object2.channel = value13;
} catch (error) {
break exceptionLanding83;
}
try {
inviteSuggestions = Reflect.apply(loadInviteSuggestions, value16, [object2]);
} catch (error) {
break exceptionLanding83;
}
yield inviteSuggestions;
try {
value19 = undefined;
value20 = false;
} catch (error) {
break exceptionLanding83;
}
if (value20) {
return value19;
}
try {
} catch (error) {
break exceptionLanding83;
}
try {
value21 = require == null;
} catch (error) {
break exceptionLanding83;
}
reducibleJoin71: while (true) {
if (value21) {
r6 = value;
break reducibleJoin71;
}
try {
} catch (error) {
break exceptionLanding83;
}
try {
object2 = {};
} catch (error) {
break exceptionLanding83;
}
try {
object2.guild = value15;
} catch (error) {
break exceptionLanding83;
}
try {
moduleValue = require(object2);
} catch (error) {
break exceptionLanding83;
}
r6 = moduleValue;
break reducibleJoin71;
}
yield r6;
try {
value22 = undefined;
value23 = false;
} catch (error) {
break exceptionLanding83;
}
reducibleJoin84: while (true) {
if (value23) {
return value22;
}
break reducibleJoin84;
}
}
UserStore(false);
}
return value;
}
@@ -0,0 +1,215 @@
/* Metro module 12026; source: modules/create_guild/native/components/CreateGuildModal.tsx; dependencies: [31, 27, 1935, 9006, 661, 33, 11932, 9158, 683, 6593, 12025, 480, 5282, 12027, 12029, 9662, 1244, 12030, 9603, 12032, 12033, 9444, 9625, 5280, 2] */
function _fun92401(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92401, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:6, offset: 0x02087ecf, size: 290 bytes, params: 8, frame: 19
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).Keyboard;
const guildChannelStore = importDefault(1935) /* metro dependency 1935: GuildChannelStore */;
let value = require(9006) /* metro dependency 9006: CreateGuildConstants */;
const env0_6 = value.CreateGuildModalStates;
const env0_7 = value.GuildTemplateTriggers;
value = require(661) /* metro dependency 661: Constants */;
const env0_8 = value.AnalyticEvents;
const env0_9 = value.AnalyticsSections;
const env0_10 = (require(33) /* metro dependency 33 */).jsx;
object2 = {};
const ImpressionGroups = (require(480) /* metro dependency 480: AnalyticsUtils */).ImpressionGroups;
const GUILD_ADD_FLOW = ImpressionGroups.GUILD_ADD_FLOW;
object2.impression_group = GUILD_ADD_FLOW;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/CreateGuildModal.tsx');
exports.default = CreateGuildModal;
}
function getScreens_92402(a0, a1, a2) { // fn#92402, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:329, offset: 0x02087ff1, size: 686 bytes, params: 4, frame: 22
const env0_0 = a1;
const env0_1 = a2;
const GUILD_TEMPLATES = CreateGuildModalStates.GUILD_TEMPLATES;
const object = {};
const ImpressionNames = (require(480) /* metro dependency 480: AnalyticsUtils */).ImpressionNames;
const GUILD_ADD_LANDING = ImpressionNames.GUILD_ADD_LANDING;
object.impressionName = GUILD_ADD_LANDING;
object.impressionProperties = env0_11;
object.fullscreen = true;
object.headerTitle = function() {
return null;
};
object.headerLeft = (require(5282) /* metro dependency 5282: NavigatorHeaderNative */).getHeaderCloseButton((importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */).closeCreateGuildModal);
object.render = render_92404;
const CREATION_INTENT = CreateGuildModalStates.CREATION_INTENT;
const GUILD_ADD_INTENT_SELECTION = ImpressionNames.GUILD_ADD_INTENT_SELECTION;
const CREATE_SERVER = CreateGuildModalStates.CREATE_SERVER;
const GUILD_ADD_CUSTOMIZE = ImpressionNames.GUILD_ADD_CUSTOMIZE;
const GUILD_INVITE = CreateGuildModalStates.GUILD_INVITE;
const GUILD_ADD_GUILD_INVITE = ImpressionNames.GUILD_ADD_GUILD_INVITE;
const JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
const GUILD_ADD_JOIN = ImpressionNames.GUILD_ADD_JOIN;
const ACCEPT_INVITE = CreateGuildModalStates.ACCEPT_INVITE;
const GUILD_ADD_ACCEPT_INVITE = ImpressionNames.GUILD_ADD_ACCEPT_INVITE;
const JOIN_STUDENT_HUB = CreateGuildModalStates.JOIN_STUDENT_HUB;
return {[GUILD_TEMPLATES]: object, [CREATION_INTENT]: {impressionName: GUILD_ADD_INTENT_SELECTION,
impressionProperties: env0_11, fullscreen: true, headerTitle: function() {
return null;
}, render: render_92406}, [CREATE_SERVER]: {impressionName: GUILD_ADD_CUSTOMIZE, impressionProperties: env0_11,
fullscreen: true, headerTitle: function() {
return null;
}, render: render_92408}, [GUILD_INVITE]: {impressionName: GUILD_ADD_GUILD_INVITE, impressionProperties: env0_11,
fullscreen: true, headerTitle: function() {
return null;
}, render: render_92411}, [JOIN_SERVER]: {impressionName: GUILD_ADD_JOIN, impressionProperties: env0_11,
fullscreen: true, headerTitle: a0 ? _fun92413 : function() {
return null;
}, render: render_92415}, [ACCEPT_INVITE]: {impressionName: GUILD_ADD_ACCEPT_INVITE, impressionProperties: env0_11,
fullscreen: true, headerTitle: function() {
return null;
}, headerLeft: function() {
return null;
}, render: render_92418}, [JOIN_STUDENT_HUB]: {impressionName: undefined, impressionProperties: env0_11,
fullscreen: true, ignoreKeyboard: true, headerTitle: function() {
return null;
}, headerLeft: function() {
return null;
}, render: render_92421}};
}
function CreateGuildModal({channel, initialState, onSuccess}) { // fn#92422, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:2560, offset: 0x0208865d, size: 250 bytes, params: 2, frame: 24
const binding = env0_3;
let useMemo = binding.useMemo;
const value2 = Reflect.apply(useMemo, binding, [_fun92423, [channel, initialState]]);
const value3 = (require(9625) /* metro dependency 9625: useIsWindowSmall */).useIsWindowSmall();
const Navigator = (require(5280) /* metro dependency 5280: NavigatorNative */).Navigator;
useMemo = binding.useMemo;
const items2 = [initialState, value3, onSuccess];
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<Navigator
screens={Reflect.apply(useMemo, binding, [_fun92424, items2])}
initialRouteStack={value2}
headerBackTitle={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['13/7kX'])}
onWillFocus={Keyboard.dismiss}
/>
);
}
function getScreens_92402Render() { // fn#92404, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:580, owner: getScreens_92402.render, offset: 0x0208829f, size: 54 bytes, params: 1, frame: 14
const GuildTemplates = importDefault(12027) /* metro dependency 12027: GuildTemplates */;
const IN_APP = GuildTemplateTriggers.IN_APP;
return <GuildTemplates trigger={IN_APP} />;
}
function getScreens_92402Render_92406({guildTemplate}) { // fn#92406, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:769, owner: getScreens_92402.render, offset: 0x020882d5, size: 68 bytes, params: 2, frame: 15
const CreationIntent = importDefault(12029) /* metro dependency 12029: CreationIntent */;
const IN_APP = GuildTemplateTriggers.IN_APP;
return <CreationIntent guildTemplate={guildTemplate} trigger={IN_APP} />;
}
function getScreens_92402Render_92408(a0, a1) { // fn#92408, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:982, owner: getScreens_92402.render, offset: 0x02088319, size: 136 bytes, params: 3, frame: 18
var environment;
const env0_0 = a1;
const value = environment.__proto__;
const CreateGuildContainer = importDefault(9662) /* metro dependency 9662: CreateGuildContainer */;
const defaultImportProps = {...a0};
defaultImportProps['onCreate'] = renderOnCreate_92409;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
defaultImportProps['customTitle'] = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['5HZu07']);
return <CreateGuildContainer {...defaultImportProps} />;
}
function getScreens_92402Render_92411({guildId}) { // fn#92411, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:1547, owner: getScreens_92402.render, offset: 0x02088490, size: 72 bytes, params: 2, frame: 15
var environment;
const value = environment.__proto__;
return ((Component) => <Component closeOnEditInviteLink={false} onClose={onClose_92412} />)(importDefault(12030) /* metro dependency 12030: GuildInvite */);
}
function _fun92413() { // fn#92413, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:1846, offset: 0x0208852d, size: 96 bytes, params: 1, frame: 18
const GenericHeaderTitle = (require(9603) /* metro dependency 9603: HeaderShared */).GenericHeaderTitle;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return <GenericHeaderTitle title={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.jlfuFW)} />;
}
function getScreens_92402Render_92415(a0) { // fn#92415, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:1945, owner: getScreens_92402.render, offset: 0x0208858d, size: 88 bytes, params: 2, frame: 16
let value = environment.__proto__;
value = importDefault(12032) /* metro dependency 12032: JoinServer */;
const valueProps = {initialRoute: require, ...a0};
valueProps['onClose'] = (importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */).closeCreateGuildModal;
return ((Component) => <Component {...valueProps} />)(value);
}
function getScreens_92402Render_92418({code}) { // fn#92418, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:2190, owner: getScreens_92402.render, offset: 0x020885e5, size: 74 bytes, params: 2, frame: 16
const value = environment.__proto__;
return ((Component) => <Component code={code} onPressClose={(importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */).closeCreateGuildModal} />)(importDefault(12033) /* metro dependency 12033: AcceptInviteContainer */);
}
function getScreens_92402Render_92421() { // fn#92421, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:2415, owner: getScreens_92402.render, offset: 0x0208862f, size: 46 bytes, params: 1, frame: 14
const value = environment.__proto__;
return ((Component) => <Component isNestedNavigator />)(importDefault(9444) /* metro dependency 9444: HubEmailConnectionModal */);
}
function _fun92423() { // fn#92423, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:2643, offset: 0x02088757, size: 188 bytes, params: 1, frame: 14
var items;
var object3;
var object4;
const initialStateBinding = initialState;
let JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
if (initialStateBinding === JOIN_SERVER) {
object3 = {};
JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
object3.name = JOIN_SERVER;
JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
object3.param = {initialRoute: JOIN_SERVER};
items = [object3];
} else if (channel == null) {
items = [{name: CreateGuildModalStates.GUILD_TEMPLATES}];
} else {
object3 = {};
object3.name = CreateGuildModalStates.GUILD_INVITE;
object4 = {};
object4.channel = channel;
object4.onClose = (importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */).closeCreateGuildModal;
object3.param = object4;
items = [object3];
}
return items;
}
function _fun92424() { // fn#92424, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:2925, offset: 0x02088813, size: 33 bytes, params: 1, frame: 15
return getScreens_92402(env0_3, initialState, onSuccess);
}
function renderOnCreate_92409({guild}) { // fn#92409, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:1015, owner: getScreens_92402.render.onCreate, offset: 0x020883a1, size: 239 bytes, params: 2, frame: 21
var defaultImport;
var push;
var GUILD_INVITE;
var defaultImport2;
var track;
var USER_FLOW_TRANSITION;
const id = guild.id;
(require(11932) /* metro dependency 11932: GuildProgressUtils */).createGuildProgress(id);
const defaultChannel = GuildChannelStore.getDefaultChannel(id);
if (defaultChannel != null) {
defaultImport = importDefault(9158) /* metro dependency 9158: CreateInviteModalActionCreators */;
defaultImport.init(id, defaultChannel.id, {location: 'Guild Create Flow'});
push = require.push;
GUILD_INVITE = CreateGuildModalStates.GUILD_INVITE;
Reflect.apply(push, require, [GUILD_INVITE, {guildId: id}]);
defaultImport2 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
track = defaultImport2.track;
USER_FLOW_TRANSITION = AnalyticEvents.USER_FLOW_TRANSITION;
GUILD_INVITE = CreateGuildModalStates.GUILD_INVITE;
Reflect.apply(track, defaultImport2, [USER_FLOW_TRANSITION, {flow_type: AnalyticsSections.GUILD_CREATE_MODAL,
from_step: CreateGuildModalStates.CREATE_SERVER, to_step: GUILD_INVITE}]);
}
}
function renderOnClose_92412() { // fn#92412, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12212:1607, owner: getScreens_92402.render.onClose, offset: 0x020884d8, size: 85 bytes, params: 1, frame: 15
const guildIdBinding = guildId;
let value = environment.__proto__;
value = environment.__proto__.__proto__;
(importDefault(6593) /* metro dependency 6593: GuildActionCreators */).transitionToGuildSync(guildIdBinding);
(importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */).closeCreateGuildModal();
if (importDefault != null) {
importDefault(guildIdBinding);
}
}
@@ -0,0 +1,167 @@
/* Metro module 12029; source: modules/create_guild/native/components/CreationIntent.tsx; dependencies: [31, 27, 9006, 661, 33, 4501, 5314, 697, 1484, 4559, 4570, 12000, 683, 6618, 4573, 1244, 6231, 9653, 5473, 6766, 2] */
function _fun92437(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92437, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12215:6, offset: 0x02089572, size: 503 bytes, params: 8, frame: 23
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_4 = value.View;
const env0_5 = value.ScrollView;
value = require(9006) /* metro dependency 9006: CreateGuildConstants */;
const env0_6 = value.CreateGuildModalStates;
const env0_7 = value.GuildTemplateTriggers;
const env0_8 = value.NUXGuildTemplatesAnalytics;
value = require(661) /* metro dependency 661: Constants */;
const env0_9 = value.AnalyticEvents;
const env0_10 = value.AnalyticsLocations;
value = require(33) /* metro dependency 33 */;
const env0_11 = value.jsx;
const env0_12 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const NAV_BAR_HEIGHT = (require(5314) /* metro dependency 5314: NavigatorConstantsNative */).NAV_BAR_HEIGHT;
object2.contentContainer = {flex: 1, marginTop: NAV_BAR_HEIGHT};
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
object2.scrollContainer = {flex: 1, backgroundColor: BACKGROUND_BASE_LOWER};
object2.headerContainer = {'alignItems': 'center', 'paddingVertical': 20, 'paddingHorizontal': 16};
object2.headerTitle = {'textAlign': 'center', 'marginBottom': 8};
object2.headerDescription = {'lineHeight': 18, 'textAlign': 'center'};
const TABLE_ROW_PADDING = (importDefault(697) /* metro dependency 697: native */).modules.mobile.TABLE_ROW_PADDING;
object2.sections = {paddingHorizontal: TABLE_ROW_PADDING};
object2.skipDescription = {'marginTop': 16, 'paddingHorizontal': 16, 'lineHeight': 18, 'textAlign': 'center'};
const env0_13 = Reflect.apply(createStyles, value, [object2]);
const Math = global.Math;
const result = Math.random() < 0.5;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/CreationIntent.tsx');
exports.default = CreationIntent;
}
function CreationIntent({guildTemplate, trigger}) { // fn#92438, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12215:931, offset: 0x02089769, size: 1140 bytes, params: 2, frame: 40
var items3;
var ListSelectionItem;
var items4;
var ListSelectionItem2;
const styles = useStyles();
const env0_2 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const value2 = (require(4559) /* metro dependency 4559: useIsScreenReaderEnabledNative */).useIsScreenReaderEnabled();
const binding = value2;
const value3 = binding.useRef(null);
binding.useEffect(_fun92440, [value2]);
binding.useEffect(_fun92441, [trigger]);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const items2 = [<View style={styles.headerContainer}><Text ref={value3} style={styles.headerTitle} accessibilityRole="header" variant="heading-xl/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
intl,
[t.f3MvGS])}</Text><Text style={styles.headerDescription} variant="text-sm/medium" color="text-default">{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.nOzc7w)}</Text></View>];
const TableRowGroup = (require(6231) /* metro dependency 6231: TableRowGroupNative */).TableRowGroup;
const resultBinding = result;
const object = {hasIcons: true};
const ListSelectionItem3 = importDefault(9653) /* metro dependency 9653: ListSelectionItem */;
const object2 = {};
const nativeModule = require(5473) /* metro dependency 5473: native */;
if (resultBinding) {
object2.Icon = nativeModule.ChairIllocon;
object2.message = intl.string(t.uE7zcu);
object2.onPress = function() {
CreationIntentOnPress(false);
};
items4 = [<ListSelectionItem3 {...object2} />];
ListSelectionItem2 = ListSelectionItem3;
items4[1] = <ListSelectionItem2 Icon={(require(5473) /* metro dependency 5473: native */).WorldIllocon} message={intl.string(t.h9Q1lG)} onPress={onPress_92443} />;
object.children = items4;
} else {
object2.Icon = nativeModule.WorldIllocon;
object2.message = intl.string(t.h9Q1lG);
object2.onPress = onPress_92444;
items3 = [<ListSelectionItem3 {...object2} />];
ListSelectionItem = importDefault(9653) /* metro dependency 9653: ListSelectionItem */;
items3[1] = <ListSelectionItem Icon={(require(5473) /* metro dependency 5473: native */).ChairIllocon} message={intl.string(t.uE7zcu)} onPress={onPress_92445} />;
object.children = items3;
}
items2[1] = <View style={styles.sections}><TableRowGroup {...object} /></View>;
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
items2[2] = <TextWithIOSLinkWorkaround style={styles.skipDescription} variant="text-sm/medium" color="text-default">{intl.format((require(1244) /* metro dependency 1244: indexNative */).t['SMc+Gz'],
{onSkip: function() {
CreationIntentOnPress(null);
}})}</TextWithIOSLinkWorkaround>;
return (
<SafeAreaPaddingView top style={styles.contentContainer}>
<ScrollView style={styles.scrollContainer}>
{items2}
</ScrollView>
</SafeAreaPaddingView>
);
}
function CreationIntentOnPress(a0) { // fn#92439, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12215:1074, owner: CreationIntent.onPress, offset: 0x02089bdd, size: 417 bytes, params: 2, frame: 24
var OPEN_MODAL;
var CREATE_JOIN_GUILD_MODAL;
var CREATE_GUILD_VIEWED;
let value = a0;
const value3 = undefined;
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
let track = defaultImport.track;
const GUILD_CREATION_INTENT_SELECTED = AnalyticEvents.GUILD_CREATION_INTENT_SELECTED;
Reflect.apply(track, defaultImport, [GUILD_CREATION_INTENT_SELECTED, {skipped: value == null,
is_community: value != null && value}]);
const binding = env0_2;
const push = binding.push;
const CREATE_SERVER = CreateGuildModalStates.CREATE_SERVER;
Reflect.apply(push, binding, [CREATE_SERVER, {guildTemplate: guildTemplate, isCommunityIntent: value}]);
const triggerBinding = trigger;
const NUF = GuildTemplateTriggers.NUF;
if (NUF === triggerBinding) {
value = require(12000) /* metro dependency 12000: NewUserAnalyticsUtils */;
value.trackNUFStep(NUXGuildTemplatesAnalytics.STEP_CREATION_INTENT,
NUXGuildTemplatesAnalytics.STEP_GUILD_CREATE,
{skip: false});
value = defaultImport;
value.track(AnalyticEvents.CREATE_GUILD_VIEWED,
{guild_template_name: guildTemplate == null ? value3 : guildTemplate.id});
} else if (GuildTemplateTriggers.IN_APP === triggerBinding) {
value = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
track = value.track;
OPEN_MODAL = AnalyticEvents.OPEN_MODAL;
CREATE_JOIN_GUILD_MODAL = AnalyticsLocations.CREATE_JOIN_GUILD_MODAL;
Reflect.apply(track, value, [OPEN_MODAL, {type: 'Create Guild Step 2',
location_section: CREATE_JOIN_GUILD_MODAL}]);
value = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
track = value.track;
CREATE_GUILD_VIEWED = AnalyticEvents.CREATE_GUILD_VIEWED;
CREATE_JOIN_GUILD_MODAL = AnalyticsLocations.CREATE_JOIN_GUILD_MODAL;
Reflect.apply(track, value, [CREATE_GUILD_VIEWED, {location_section: CREATE_JOIN_GUILD_MODAL,
guild_template_name: guildTemplate == null ? value3 : guildTemplate.id}]);
}
return value3;
}
function _fun92440() { // fn#92440, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12215:1689, offset: 0x02089d7e, size: 86 bytes, params: 1, frame: 12
var value3;
var moduleValue;
if (env0_3 && env0_4.current != null) {
value3 = environment.__proto__;
moduleValue = require(4570) /* metro dependency 4570: setAccessibilityFocusAndroid */;
moduleValue.setAccessibilityFocus({ref: env0_4, delay: 100});
}
}
function _fun92441() { // fn#92441, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12215:1784, offset: 0x02089dd4, size: 159 bytes, params: 1, frame: 16
var defaultImport;
var moduleValue;
const triggerBinding = trigger;
const NUF = GuildTemplateTriggers.NUF;
if (NUF === triggerBinding) {
moduleValue = require(12000) /* metro dependency 12000: NewUserAnalyticsUtils */;
moduleValue.trackNUFStep(NUXGuildTemplatesAnalytics.STEP_GUILD_TEMPLATE,
NUXGuildTemplatesAnalytics.STEP_CREATION_INTENT, {skip: false});
} else if (GuildTemplateTriggers.IN_APP === triggerBinding) {
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.OPEN_MODAL, {type: 'Server Intent Discovery'});
}
}
@@ -0,0 +1,320 @@
/* Metro module 12030; source: modules/create_guild/native/components/GuildInvite.tsx; dependencies: [57, 31, 27, 9208, 1379, 9152, 1935, 9163, 9006, 661, 33, 4501, 5314, 697, 683, 6238, 6699, 1244, 9207, 1484, 4559, 566, 4570, 4594, 9164, 5282, 4002, 7147, 12025, 9151, 4863, 6618, 4573, 12031, 5278, 1305, 9177, 9205, 4578, 2] */
function _fun92447(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92447, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:6, offset: 0x02089e85, size: 874 bytes, params: 8, frame: 26
var object3;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_5 = value.Image;
const env0_6 = value.View;
const env0_7 = value.FlatList;
const StyleSheet = value.StyleSheet;
const env0_8 = (require(9208) /* metro dependency 9208: InstantInviteSendStateStore */).useInstantInviteSendStates;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const createInviteModalStore = importDefault(9152) /* metro dependency 9152: CreateInviteModalStore */;
const guildChannelStore = importDefault(1935) /* metro dependency 1935: GuildChannelStore */;
const inviteSuggestionsStore = importDefault(9163) /* metro dependency 9163: InviteSuggestionsStore */;
const env0_13 = (require(9006) /* metro dependency 9006: CreateGuildConstants */).CreateGuildModalStates;
value = require(661) /* metro dependency 661: Constants */;
const env0_14 = value.AnalyticEvents;
const env0_15 = value.AnalyticsSections;
const env0_16 = value.InstantInviteSources;
const env0_17 = value.Permissions;
const env0_18 = value.SearchTypes;
value = require(33) /* metro dependency 33 */;
const env0_19 = value.jsx;
const env0_20 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object3 = {};
const object4 = {};
const NAV_BAR_HEIGHT = (require(5314) /* metro dependency 5314: NavigatorConstantsNative */).NAV_BAR_HEIGHT;
object4.marginTop = NAV_BAR_HEIGHT;
object4.flex = 1;
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
object4.backgroundColor = BACKGROUND_BASE_LOWER;
object4.alignItems = 'center';
object3.container = object4;
object3.header = {marginBottom: 8};
object3.description = {'lineHeight': 18, 'marginBottom': 8, 'paddingHorizontal': 16, 'textAlign': 'center'};
object3.headerImage = {marginVertical: 16};
object3.linkContainer = {'paddingHorizontal': 16, 'width': '100%'};
const object6 = {'marginTop': 16, 'flexDirection': 'row', 'alignItems': 'center', 'backgroundColor': null,
'borderRadius': null, 'padding': 12, 'justifyContent': 'space-between'};
let BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
object6.backgroundColor = BACKGROUND_BASE_LOWEST;
object6.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xs;
object3.linkButton = object6;
const INTERACTIVE_TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_TEXT_DEFAULT;
object3.linkButtonIcon = {'flexShrink': 0, 'marginLeft': 8, tintColor: INTERACTIVE_TEXT_DEFAULT};
object3.inviteDetail = {marginTop: 8};
object3.shareButton = {marginVertical: 16};
object3.suggestionsContainer = {'width': '100%', 'flex': 1, 'alignContent': 'flex-start'};
const object7 = {'backgroundColor': null, 'height': 32, 'width': 32, 'padding': 8, 'alignItems': 'center',
'justifyContent': 'center'};
BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
object7.backgroundColor = BACKGROUND_BASE_LOWEST;
object7.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xxl;
object3.friendIcon = object7;
object3.suggestionRowsContainer = {marginHorizontal: 12};
const object8 = {};
object8.height = StyleSheet.hairlineWidth;
const BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
object8.backgroundColor = BORDER_SUBTLE;
const TABLE_ROW_DIVIDER_PADDING = (importDefault(697) /* metro dependency 697: native */).modules.mobile.TABLE_ROW_DIVIDER_PADDING;
object8.marginStart = TABLE_ROW_DIVIDER_PADDING;
object3.separator = object8;
const env0_21 = Reflect.apply(createStyles, value, [object3]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/GuildInvite.tsx');
exports.default = GuildInvite;
}
function SeeMoreFooter({openInviteSheet}) { // fn#92448, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:1540, offset: 0x0208a1ef, size: 197 bytes, params: 2, frame: 23
const styles = useStyles();
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
const object2 = {};
const GroupIcon = (require(6699) /* metro dependency 6699: GroupIcon */).GroupIcon;
object2.icon = <View style={styles.friendIcon}><GroupIcon size="sm" /></View>;
object2.onPress = openInviteSheet;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object2.label = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.zrLIIz);
object2.end = true;
return <TableRow {...object2} />;
}
function GuildInviteSuggestionRows({invite, suggestions, openInviteSheet}) { // fn#92449, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:1761, offset: 0x0208a2b4, size: 236 bytes, params: 2, frame: 24
const styles = useStyles();
const binding = env0_4;
const useMemo = binding.useMemo;
return suggestions.length === 0 ? null : <View style={styles.suggestionsContainer}><FlatList data={Reflect.apply(useMemo,
binding, [function() {
return suggestions.slice(0, 6);
},
[suggestions]])} renderItem={renderItem_92451} contentContainerStyle={styles.suggestionRowsContainer} ListFooterComponent={suggestions.length > 6 ? <SeeMoreFooter openInviteSheet={openInviteSheet} /> : null} ItemSeparatorComponent={ItemSeparatorComponent} keyExtractor={function(a0) {
return a0.item.id;
}} /></View>;
}
function GuildInvite({closeOnEditInviteLink, onClose}) { // fn#92454, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:2362, offset: 0x0208a434, size: 1556 bytes, params: 2, frame: 37
if (closeOnEditInviteLink !== undefined) {
}
let env0_4 = undefined;
const styles = useStyles();
const value4 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const value5 = (require(4559) /* metro dependency 4559: useIsScreenReaderEnabledNative */).useIsScreenReaderEnabled();
const env0_3 = value5;
let binding = env0_4;
const value6 = binding.useRef(null);
env0_4 = value6;
binding = env0_4;
let useState = binding.useState;
const value7 = Reflect.apply(useState, binding, [false]);
binding = env0_3;
const value8 = binding(value7, 2);
const property = value8[0];
const env0_6 = value8[1];
const invite = (require(566) /* metro dependency 566: flux */).useStateFromStores([CreateInviteModalStore],
function() {
return CreateInviteModalStore.getInvite();
});
const channel = (require(566) /* metro dependency 566: flux */).useStateFromStores([CreateInviteModalStore,
ChannelStore, GuildChannelStore], _fun92456);
env0_4.useEffect(_fun92457, [value5, invite]);
const binding3 = env0_4;
useState = binding3.useState;
const property2 = binding(Reflect.apply(useState, binding3, [function() {
return InviteSuggestionsStore.getInviteSuggestionRows();
}]), 1)[0];
const value9 = useInstantInviteSendStates();
(importDefault(4594) /* metro dependency 4594: useMountEffect */)(_fun92459);
env0_4.useEffect(_fun92460, [value9, invite]);
env0_4.useLayoutEffect(_fun92461, [value4, onClose, property]);
const value10 = (importDefault(7147) /* metro dependency 7147: getInviteURL */)(invite?.code);
const r8 = property2 != null && property2.length > 0;
const value13 = env0_4.useCallback(_fun92464, [channel]);
const value14 = env0_4.useCallback(_fun92465, [channel, invite?.code, value10]);
const value15 = env0_4.useCallback(_fun92466, [invite, channel]);
if (invite == null) {
return null;
}
if (channel == null) {
return null;
}
const r6 = r8 && <GuildInviteSuggestionRows invite={invite} suggestions={property2} openInviteSheet={value15} />;
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const OZ1qhO = (require(1244) /* metro dependency 1244: indexNative */).t.OZ1qhO;
const items2 = [<Text ref={value6} style={styles.header} accessibilityRole="header" variant="heading-xl/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
intl, [OZ1qhO])}</Text>];
items2[1] = <Text style={styles.description} variant="text-sm/medium" color="text-default">{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.eU2ZaK)}</Text>;
items2[2] = !r8 && <Image source={importDefault(12031) /* metro dependency 12031 */} resizeMode="contain" style={styles.headerImage} />;
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
const pressableOpacityProps2 = {style: styles.linkButton, accessibilityRole: 'button',
accessibilityLabel: intl.string((require(1244) /* metro dependency 1244: indexNative */).t['3XVNyt']),
onPress: onPress_92467};
const text = <Text variant="text-sm/medium" color="mobile-text-heading-primary" style={{flexShrink: 1}}>{value10}</Text>;
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
const items3 = [<PressableOpacity {...pressableOpacityProps2}>{text}<Icon source={importDefault(9177) /* metro dependency 9177 */} style={styles.linkButtonIcon} /></PressableOpacity>];
const InstantInviteAgeText = importDefault(9205) /* metro dependency 9205: InstantInviteAgeText */;
const GUILD_CREATE = InstantInviteSources.GUILD_CREATE;
items3[1] = <View style={styles.inviteDetail}><InstantInviteAgeText channel={channel} canEditInvite callbackActionSheet={value13} onEdit={function() {
if (closeOnEditInviteLink) {
onClose();
}
}} source={GUILD_CREATE} /></View>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
string = intl.string;
const Ej3B3Y = (require(1244) /* metro dependency 1244: indexNative */).t.Ej3B3Y;
items3[2] = <View style={styles.shareButton}><Button text={Reflect.apply(string, intl,
[Ej3B3Y])} onPress={value14} /></View>;
items2[3] = <View style={styles.linkContainer}>{items3}</View>;
items2[4] = r6;
return (
<SafeAreaPaddingView top style={styles.container}>
{items2}
</SafeAreaPaddingView>
);
}
function GuildInviteSuggestionRowsRenderItem({item, index}) { // fn#92451, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:1977, owner: GuildInviteSuggestionRows.renderItem, offset: 0x0208a3b9, size: 83 bytes, params: 2, frame: 15
const value = environment.__proto__;
return ((Component) => <Component row={item} code={invite.code} start={index === 0} />)(importDefault(9207) /* metro dependency 9207: InstantInviteRow */);
}
function GuildInviteSuggestionRowsItemSeparatorComponent() { // fn#92452, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:2200, owner: GuildInviteSuggestionRows.ItemSeparatorComponent, offset: 0x0208a40c, size: 40 bytes, params: 1, frame: 13
return <View style={styles.separator} />;
}
function _fun92456() { // fn#92456, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:2649, offset: 0x0208aa5b, size: 107 bytes, params: 1, frame: 18
const value = environment.__proto__;
const inviteSettings = CreateInviteModalStore.getInviteSettings();
const value3 = null;
const channelId = value3 == inviteSettings ? undefined : inviteSettings.channelId;
if (value3 != channelId) {
return ChannelStore.getChannel(channelId);
}
const guildId = CreateInviteModalStore.getGuildId();
return value3 != guildId ? GuildChannelStore.getDefaultChannel(guildId, true,
Permissions.CREATE_INSTANT_INVITE) : value3;
}
function _fun92457() { // fn#92457, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:2854, offset: 0x0208aac6, size: 86 bytes, params: 1, frame: 12
var value3;
var moduleValue;
if (env0_3 && env0_4.current != null) {
value3 = environment.__proto__;
moduleValue = require(4570) /* metro dependency 4570: setAccessibilityFocusAndroid */;
moduleValue.setAccessibilityFocus({ref: env0_4, delay: 100});
}
}
function _fun92459() { // fn#92459, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3018, offset: 0x0208ab2f, size: 84 bytes, params: 1, frame: 14
let value = environment.__proto__;
value = require(9164) /* metro dependency 9164: InviteSuggestionsActionCreators */;
const loadInviteSuggestions = value.loadInviteSuggestions;
const Set = global.Set;
const value2 = Object.create(Set.prototype, {constructor: {value: Set}});
const set = new Set();
Reflect.apply(loadInviteSuggestions, value, [{omitUserIds: set instanceof Object ? set : value2, channel: channel}]);
}
function _fun92460() { // fn#92460, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3103, offset: 0x0208ab83, size: 51 bytes, params: 1, frame: 12
if (invite != null) {
if (env0_9[invite.code] != null) {
env0_6(true);
}
}
}
function _fun92461() { // fn#92461, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3170, offset: 0x0208abb6, size: 160 bytes, params: 1, frame: 22
const binding = env0_2;
const setOptions = binding.setOptions;
const navigatorHeaderNativeModule = require(5282) /* metro dependency 5282: NavigatorHeaderNative */;
const getHeaderTextButton = navigatorHeaderNativeModule.getHeaderTextButton;
const binding2 = env0_5;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
Reflect.apply(setOptions, binding, [{headerRight: Reflect.apply(getHeaderTextButton, navigatorHeaderNativeModule,
[binding2 ? Reflect.apply(string, intl, [t.i4jeWR]) : Reflect.apply(string, intl, [t['5Wxrcd']]), _fun92462]),
headerLeft: function() {
return null;
}}]);
}
function _fun92464() { // fn#92464, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3682, offset: 0x0208ad1a, size: 57 bytes, params: 1, frame: 12
var value2;
var defaultImport;
if (channel != null) {
value2 = environment.__proto__;
defaultImport = importDefault(12025) /* metro dependency 12025: CreateGuildModalActionCreators */;
defaultImport.openGuildInviteScreen(channel);
}
}
function _fun92465() { // fn#92465, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3754, offset: 0x0208ad53, size: 124 bytes, params: 1, frame: 19
var code;
var value2;
var value3;
var moduleValue;
var handleOpenShareSheet;
var moduleValue2;
let channelBinding = channel;
if (channelBinding != null) {
value2 = environment.__proto__;
value3 = undefined;
moduleValue = require(9151) /* metro dependency 9151: InstantInviteUtils */;
handleOpenShareSheet = moduleValue.handleOpenShareSheet;
code = invite == null ? value3 : invite.code;
channelBinding = channel;
moduleValue2 = require(9151) /* metro dependency 9151: InstantInviteUtils */;
Reflect.apply(handleOpenShareSheet, moduleValue, [code, channelBinding, moduleValue2.getShareMessage(env0_10)]);
env0_6(true);
}
}
function _fun92466() { // fn#92466, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3907, offset: 0x0208adcf, size: 159 bytes, params: 1, frame: 18
var value4;
var defaultImport;
var moduleValue;
if (invite != null && channel != null) {
value4 = environment.__proto__;
defaultImport = importDefault(4863) /* metro dependency 4863: AppAnalyticsUtils */;
defaultImport.trackWithMetadata(AnalyticEvents.SEARCH_STARTED, {search_type: SearchTypes.INSTANT_INVITE});
moduleValue = require(9151) /* metro dependency 9151: InstantInviteUtils */;
moduleValue.showInstantInviteActionSheet(channel, {source: InstantInviteSources.GUILD_CREATE,
code: invite.code});
}
}
function GuildInviteOnPress() { // fn#92467, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:4848, owner: GuildInvite.onPress, offset: 0x0208ae6e, size: 77 bytes, params: 1, frame: 17
const instantInviteUtilsModule = require(9151) /* metro dependency 9151: InstantInviteUtils */;
const handleCopy = instantInviteUtilsModule.handleCopy;
const code = invite.code;
const channelBinding = channel;
const GUILD_CREATE = InstantInviteSources.GUILD_CREATE;
Reflect.apply(handleCopy, instantInviteUtilsModule, [code, channelBinding, GUILD_CREATE]);
env0_6(true);
}
function _fun92462() { // fn#92462, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12216:3316, offset: 0x0208ac56, size: 196 bytes, params: 1, frame: 18
const AccessibilityAnnouncer = (require(4002) /* metro dependency 4002: shared */).AccessibilityAnnouncer;
const announce = AccessibilityAnnouncer.announce;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
Reflect.apply(announce, AccessibilityAnnouncer,
[intl.string((require(1244) /* metro dependency 1244: indexNative */).t['FY/yLY'])]);
onClose();
const value3 = !env1_5;
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const USER_FLOW_TRANSITION = AnalyticEvents.USER_FLOW_TRANSITION;
const GUILD_CREATE_MODAL = AnalyticsSections.GUILD_CREATE_MODAL;
const GUILD_INVITE = CreateGuildModalStates.GUILD_INVITE;
Reflect.apply(track, defaultImport, [USER_FLOW_TRANSITION, {flow_type: GUILD_CREATE_MODAL, from_step: GUILD_INVITE,
to_step: 'modal_closed', skip: value3}]);
}
@@ -0,0 +1,227 @@
/* Metro module 12027; source: modules/create_guild/native/components/GuildTemplates.tsx; dependencies: [57, 31, 27, 12024, 9006, 661, 33, 4501, 5314, 697, 4573, 1244, 1484, 1585, 4578, 12000, 683, 9653, 12028, 6618, 6231, 2] */
function _fun92425(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92425, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:6, offset: 0x02088834, size: 627 bytes, params: 8, frame: 22
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_5 = value.View;
const env0_6 = value.ScrollView;
value = require(12024) /* metro dependency 12024: CreateGuildConstants */;
const env0_7 = value.getGuildTemplatesMap;
const env0_8 = value.GuildTemplateId;
value = require(9006) /* metro dependency 9006: CreateGuildConstants */;
const env0_9 = value.CreateGuildModalStates;
const env0_10 = value.GuildTemplateTriggers;
const env0_11 = value.NUXGuildTemplatesAnalytics;
value = require(661) /* metro dependency 661: Constants */;
const env0_12 = value.AnalyticEvents;
const env0_13 = value.AnalyticsLocations;
value = require(33) /* metro dependency 33 */;
const env0_14 = value.jsx;
const env0_15 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
object2.flex = {flex: 1};
const NAV_BAR_HEIGHT = (require(5314) /* metro dependency 5314: NavigatorConstantsNative */).NAV_BAR_HEIGHT;
object2.contentContainer = {marginTop: NAV_BAR_HEIGHT};
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
object2.scrollContainer = {flex: 1, backgroundColor: BACKGROUND_BASE_LOWER};
const TABLE_ROW_PADDING = (importDefault(697) /* metro dependency 697: native */).modules.mobile.TABLE_ROW_PADDING;
object2.sections = {paddingHorizontal: TABLE_ROW_PADDING, gap: 24};
object2.headerContainer = {'alignItems': 'center', 'paddingTop': 20, 'paddingBottom': 20, 'paddingHorizontal': 16};
object2.headerTitle = {'textAlign': 'center', 'marginBottom': 8};
object2.headerDescription = {'lineHeight': 18, 'textAlign': 'center'};
const BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.footerSafeAreaContainer = {'backgroundColor': null, 'position': 'absolute', 'bottom': 0, 'width': '100%',
backgroundColor: BACKGROUND_BASE_LOW};
object2.footerContainer = {'padding': 16, 'gap': 16, 'minHeight': 110, 'justifyContent': 'center'};
object2.footerTitle = {'alignSelf': 'center', 'textAlign': 'center'};
const env0_16 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/GuildTemplates.tsx');
exports.default = GuildTemplates;
}
function GuildTemplatesItem_92426({guildTemplate, onGuildTemplatePress}) { // fn#92426, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:2351, offset: 0x02088aa7, size: 119 bytes, params: 2, frame: 18
const ListSelectionItem = importDefault(9653) /* metro dependency 9653: ListSelectionItem */;
const GUILD_TEMPLATE_ICON_COMPONENTS = (require(12028) /* metro dependency 12028: CreateGuildIcons */).GUILD_TEMPLATE_ICON_COMPONENTS;
return (
<ListSelectionItem
Icon={GUILD_TEMPLATE_ICON_COMPONENTS[guildTemplate.id]}
message={guildTemplate.label}
onPress={function() {
return onGuildTemplatePress(guildTemplate);
}}
/>
);
}
function GuildTemplatesHeader() { // fn#92428, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:1082, offset: 0x02088b1e, size: 267 bytes, params: 1, frame: 25
const styles = useStyles();
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<View style={styles.headerContainer}>
<Text
style={styles.headerTitle}
accessibilityRole="header"
variant="heading-xl/extrabold"
color="mobile-text-heading-primary"
>
{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['5HZu07'])}
</Text>
<Text
style={styles.headerDescription}
variant="text-sm/medium"
color="text-default"
>
{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['/k/L/j'])}
</Text>
</View>
);
}
function GuildTemplatesJoinFooter({trigger, onHeightChange}) { // fn#92429, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:1500, offset: 0x02088c29, size: 519 bytes, params: 2, frame: 26
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const styles = useStyles();
const env0_2 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const NUF = GuildTemplateTriggers.NUF;
const r11 = trigger === NUF ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.INo2NK) : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.riOUtB);
const value4 = env0_4.useCallback(function(a0) {
onHeightChange(a0.nativeEvent.layout.height);
}, [onHeightChange]);
const items2 = [styles.footerSafeAreaContainer];
items2[1] = {paddingBottom: bottom};
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const text = <Text style={styles.footerTitle} variant="heading-lg/semibold" color="mobile-text-heading-primary">{intl.string((require(1244) /* metro dependency 1244: indexNative */).t['N+Mi/U'])}</Text>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
return (
<View style={items2} onLayout={value4}>
<View style={styles.footerContainer}>
{text}
<Button
variant="primary"
grow
text={r11}
onPress={onPress_92431}
/>
</View>
</View>
);
}
function GuildTemplates({trigger, location, fromStep}) { // fn#92432, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:2628, offset: 0x02088f3a, size: 873 bytes, params: 2, frame: 37
const styles = useStyles();
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
const env0_3 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const binding = env0_4;
binding.useEffect(_fun92433, [trigger, location, fromStep]);
const closure = onGuildTemplatePress;
const value2 = binding.useState(getGuildTemplatesMap());
const binding2 = env0_3;
const property = binding2(value2, 1)[0];
var [property2, env0_4] = binding2(binding.useState(110), 2);
const value6 = binding.useCallback(_fun92435, []);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
let flex = styles.flex;
const items2 = [flex];
items2[1] = styles.contentContainer;
flex = styles.flex;
const object = {paddingBottom: property2 + bottom + 16};
const guildTemplatesHeader = <GuildTemplatesHeader />;
const TableRowGroup = (require(6231) /* metro dependency 6231: TableRowGroupNative */).TableRowGroup;
const CREATE = GuildTemplateId.CREATE;
const tableRowGroup = <TableRowGroup hasIcons><GuildTemplatesItem_92426 guildTemplate={property[CREATE]} onGuildTemplatePress={closure} /></TableRowGroup>;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const JGDkfg = (require(1244) /* metro dependency 1244: indexNative */).t.JGDkfg;
const GAMING = GuildTemplateId.GAMING;
const SCHOOL_CLUB = GuildTemplateId.SCHOOL_CLUB;
const STUDY = GuildTemplateId.STUDY;
const FRIENDS = GuildTemplateId.FRIENDS;
const CREATORS = GuildTemplateId.CREATORS;
const LOCAL_COMMUNITY = GuildTemplateId.LOCAL_COMMUNITY;
return (
<SafeAreaPaddingView top style={items2}>
<View style={flex}>
<ScrollView style={styles.scrollContainer} contentContainerStyle={object}>
{guildTemplatesHeader}
<View style={styles.sections}>
{tableRowGroup}
<TableRowGroup title={Reflect.apply(string, intl, [JGDkfg])} hasIcons>
<GuildTemplatesItem_92426 guildTemplate={property[GAMING]} onGuildTemplatePress={closure} />
<GuildTemplatesItem_92426 guildTemplate={property[SCHOOL_CLUB]} onGuildTemplatePress={closure} />
<GuildTemplatesItem_92426 guildTemplate={property[STUDY]} onGuildTemplatePress={closure} />
<GuildTemplatesItem_92426 guildTemplate={property[FRIENDS]} onGuildTemplatePress={closure} />
<GuildTemplatesItem_92426 guildTemplate={property[CREATORS]} onGuildTemplatePress={closure} />
<GuildTemplatesItem_92426
guildTemplate={property[LOCAL_COMMUNITY]}
onGuildTemplatePress={closure}
/>
</TableRowGroup>
</View>
</ScrollView>
<GuildTemplatesJoinFooter trigger={trigger} onHeightChange={value6} />
</View>
</SafeAreaPaddingView>
);
}
function GuildTemplatesJoinFooterOnPress() { // fn#92431, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:2081, owner: GuildTemplatesJoinFooter.onPress, offset: 0x02088e54, size: 230 bytes, params: 1, frame: 20
var defaultImport;
var moduleValue;
var defaultImport2;
const triggerBinding = trigger;
const NUF = GuildTemplateTriggers.NUF;
if (NUF === triggerBinding) {
moduleValue = require(12000) /* metro dependency 12000: NewUserAnalyticsUtils */;
moduleValue.trackNUFStep(NUXGuildTemplatesAnalytics.STEP_GUILD_TEMPLATE,
NUXGuildTemplatesAnalytics.STEP_GUILD_JOIN,
{skip: false});
defaultImport2 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport2.track(AnalyticEvents.JOIN_GUILD_VIEWED);
} else if (GuildTemplateTriggers.IN_APP === triggerBinding) {
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.JOIN_GUILD_VIEWED,
{location_section: AnalyticsLocations.CREATE_JOIN_GUILD_MODAL});
}
const binding = env0_2;
const push = binding.push;
const JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
Reflect.apply(push, binding, [JOIN_SERVER, {}]);
}
function _fun92433() { // fn#92433, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:2757, offset: 0x020892a3, size: 209 bytes, params: 1, frame: 18
var defaultImport;
var moduleValue;
const triggerBinding = trigger;
const NUF = GuildTemplateTriggers.NUF;
if (NUF === triggerBinding) {
moduleValue = require(12000) /* metro dependency 12000: NewUserAnalyticsUtils */;
moduleValue.trackNUFStep(fromStep ?? NUXGuildTemplatesAnalytics.STEP_REGISTRATION,
NUXGuildTemplatesAnalytics.STEP_GUILD_TEMPLATE, {skip: false});
} else if (GuildTemplateTriggers.IN_APP === triggerBinding) {
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
defaultImport.track(AnalyticEvents.OPEN_MODAL, {type: 'Create Guild Templates',
source: location ?? 'Guild List'});
}
}
function onGuildTemplatePress(a0) { // fn#92434, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12213:3016, owner: GuildTemplates.onGuildTemplatePress, offset: 0x02089374, size: 123 bytes, params: 2, frame: 17
var value;
const binding = env0_3;
const push = binding.push;
const CREATION_INTENT = CreateGuildModalStates.CREATION_INTENT;
const triggerBinding = trigger;
Reflect.apply(push, binding, [CREATION_INTENT, {guildTemplate: a0, trigger: triggerBinding}]);
const IN_APP = GuildTemplateTriggers.IN_APP;
if (triggerBinding === IN_APP) {
value = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
value.track(AnalyticEvents.GUILD_TEMPLATE_SELECTED, {template_name: a0.id});
}
}
@@ -0,0 +1,111 @@
/* Metro module 12032; source: modules/create_guild/native/components/JoinServer.tsx; dependencies: [57, 31, 9006, 33, 4501, 5314, 1484, 5282, 12000, 6618, 9005, 1244, 8879, 2] */
function _fun92470(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#92470, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12218:6, offset: 0x0208af19, size: 257 bytes, params: 8, frame: 20
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
let value = require(9006) /* metro dependency 9006: CreateGuildConstants */;
const env0_5 = value.CreateGuildModalStates;
const env0_6 = value.NUXGuildTemplatesAnalytics;
const env0_7 = (require(33) /* metro dependency 33 */).jsx;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const NAV_BAR_HEIGHT = (require(5314) /* metro dependency 5314: NavigatorConstantsNative */).NAV_BAR_HEIGHT;
const env0_8 = Reflect.apply(createStyles, value, [{flex: {flex: 1},
contentContainer: {marginTop: NAV_BAR_HEIGHT}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/JoinServer.tsx');
exports.default = JoinServerContainer;
}
function JoinServerContainer({initialRoute, onClose, location}) { // fn#92471, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12218:388, offset: 0x0208b01a, size: 419 bytes, params: 2, frame: 24
var r8;
var intl;
const styles = useStyles();
const binding = env0_4;
let useState = binding.useState;
const value2 = Reflect.apply(useState, binding, ['']);
const binding2 = env0_3;
const value3 = binding2(value2, 2);
const property = value3[0];
var env0_4 = value3[1];
useState = binding.useState;
const value4 = binding2(Reflect.apply(useState, binding, [false]), 2);
const property2 = value4[0];
const env0_5 = value4[1];
useState = binding.useState;
const value5 = binding2(Reflect.apply(useState, binding, [false]), 2);
const property3 = value5[0];
const env0_6 = value5[1];
binding.useLayoutEffect(_fun92472,
[(require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation(), initialRoute, onClose]);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
const items2 = [styles.flex];
items2[1] = styles.contentContainer;
const JoinServer = importDefault(9005) /* metro dependency 9005: JoinServer */;
if (property2) {
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
r8 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.IRq5ah);
} else {
r8 = null;
}
return (
<SafeAreaPaddingView top style={items2}>
<JoinServer
inviteString={property}
error={r8}
submitting={property3}
onInviteChange={onInviteChange}
onDone={onDone}
/>
</SafeAreaPaddingView>
);
}
function _fun92472() { // fn#92472, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12218:638, offset: 0x0208b1bd, size: 134 bytes, params: 1, frame: 16
var environment;
var r3;
const binding = env0_7;
const setOptions = binding.setOptions;
const initialRouteBinding = initialRoute;
let value = environment.__proto__;
const JOIN_SERVER = CreateGuildModalStates.JOIN_SERVER;
if (initialRouteBinding === JOIN_SERVER) {
value = require(5282) /* metro dependency 5282: NavigatorHeaderNative */;
value = value.getHeaderCloseButton(function() {
var moduleValue = require(dependencyMap[8]);
var STEP_GUILD_JOIN = NUXGuildTemplatesAnalytics.STEP_GUILD_JOIN;
var STEP_FRIEND_LIST = NUXGuildTemplatesAnalytics.STEP_FRIEND_LIST;
moduleValue.trackNUFStep(STEP_GUILD_JOIN, STEP_FRIEND_LIST, {skip: true});
onClose();
});
r3 = value;
} else {
value = require(5282) /* metro dependency 5282: NavigatorHeaderNative */;
value = value.getHeaderBackButton(_fun92474);
r3 = value;
}
Reflect.apply(setOptions, binding, [{headerLeft: r3}]);
}
function onDone() { // fn#92476, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12218:1057, owner: JoinServerContainer.onDone, offset: 0x0208b28f, size: 203 bytes, params: 1, frame: 16
var environment;
var value4;
var value5;
var defaultImport;
let binding = env0_3;
const value2 = binding.trim();
if (value2 !== '') {
env0_6(true);
env0_5(false);
value4 = value2.split('/').pop();
value5 = environment.__proto__;
defaultImport = importDefault(8879) /* metro dependency 8879: InstantInviteActionCreators */;
defaultImport.resolveInvite(value4, location ?? 'Join Guild Modal').then(_fun92477);
binding = env0_7;
binding.push(CreateGuildModalStates.ACCEPT_INVITE, {code: value4});
} else {
env0_5(true);
}
}
@@ -0,0 +1,22 @@
/* Metro module 9653; source: modules/create_guild/native/components/ListSelectionItem.tsx; dependencies: [31, 33, 6238, 2] */
function _fun75738(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#75738, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9839:6, offset: 0x01db74fc, size: 131 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_2 = (require(33) /* metro dependency 33 */).jsx;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/create_guild/native/components/ListSelectionItem.tsx');
exports.default = _default_75739;
}
function _default_75739({Icon, message, onPress}) { // fn#75739, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9839:127, offset: 0x01db757f, size: 90 bytes, params: 2, frame: 16
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
return (
<TableRow
onPress={onPress}
label={message}
icon={<Icon size={24} />}
/>
);
}