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,144 @@
/* Metro module 15653; source: modules/age_gate/native/AgeGateManager.tsx; dependencies: [5, 6, 7, 15, 17, 18, 1379, 1934, 3969, 1229, 661, 5072, 5080, 15654, 1962, 676, 4860, 2] */
function _fun119985(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#119985, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:6, offset: 0x0251d347, size: 358 bytes, params: 8, frame: 19
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(6) /* metro dependency 6 */;
const env0_5 = importDefault(7) /* metro dependency 7 */;
const env0_6 = importDefault(15) /* metro dependency 15 */;
const env0_7 = importDefault(17) /* metro dependency 17 */;
const env0_8 = importDefault(18) /* metro dependency 18 */;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const selectedChannelStore = importDefault(1934) /* metro dependency 1934: SelectedChannelStore */;
const selectedGuildStore = importDefault(3969) /* metro dependency 3969: SelectedGuildStore */;
let value = require(1229) /* metro dependency 1229: AgeGateConstants */;
const env0_12 = value.EXISTING_USER_AGE_GATE_MODAL_KEY;
const env0_13 = value.AgeGateSource;
value = require(661) /* metro dependency 661: Constants */;
const env0_14 = value.ChannelTypes;
const env0_15 = value.GuildNSFWContentLevel;
value = importDefault(4860) /* metro dependency 4860: AutomaticLifecycleManager */;
value = _fun119989(value);
value = new value();
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/AgeGateManager.tsx');
exports.default = value;
}
function _isNativeReflectConstruct_119986() { // fn#119986, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:307, offset: 0x0251d4ad, size: 98 bytes, params: 1, frame: 18
var Boolean;
var prototype;
var valueOf;
var call;
var Reflect;
var construct;
var closure;
var value;
var error;
try {
Boolean = global.Boolean;
prototype = Boolean.prototype;
valueOf = prototype.valueOf;
call = valueOf.call;
Reflect = global.Reflect;
construct = Reflect.construct;
Boolean = global.Boolean;
closure = function() {
};
value = Reflect.apply(construct, Reflect, [Boolean, [], closure]);
value = Reflect.apply(call, valueOf, [value]);
var result = !value;
} catch (error) {
}
return (_isNativeReflectConstruct_119986_isNativeReflectConstruct = function() {
return !!result;
})();
}
function _fun119989(a0) { // fn#119989, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:510, offset: 0x0251d50f, size: 176 bytes, params: 2, frame: 16
const closure = AgeGateManager;
env0_8(closure, a0);
return env0_5(closure, [{key: 'handlePostConnectionOpen', value: value_119991}, {key: 'handleChannelSelect',
value: value_119992}, {key: 'handleAgeGateModalOpen', value: value_119993}, {key: 'handleAgeGateModalClose',
value: function() {
importDefault(dependencyMap[12]).popWithKey(EXISTING_USER_AGE_GATE_MODAL_KEY);
}}, {key: 'handleGuildUpdate', value: value_119997}]);
}
function AgeGateManager(a0) { // fn#119990, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:522, offset: 0x0251d5bf, size: 197 bytes, params: 2, frame: 19
var r0;
var Reflect;
let value = copyRestArgs(0, undefined);
let binding = env1_4;
binding(this, AgeGateManager);
const items = [];
arraySpread(items, value, 0, items);
value = env1_7(AgeGateManager);
binding = env1_6;
if (_isNativeReflectConstruct_119986()) {
Reflect = global.Reflect;
value = Reflect.construct(value, items, env1_7(this).constructor);
r0 = value;
} else {
value = value.apply(this, items);
r0 = value;
}
value = binding(this, r0);
value.actions = {POST_CONNECTION_OPEN: value.handlePostConnectionOpen, CHANNEL_SELECT: value.handleChannelSelect,
AGE_GATE_MODAL_OPEN: value.handleAgeGateModalOpen, AGE_GATE_MODAL_CLOSE: value.handleAgeGateModalClose,
GUILD_UPDATE: value.handleGuildUpdate};
return value;
}
function value_119991() { // fn#119991, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:1057, offset: 0x0251d684, size: 67 bytes, params: 1, frame: 14
const value = environment.__proto__;
(require(5072) /* metro dependency 5072: AgeGateUtils */).maybeShowAgeGate(SelectedGuildStore.getGuildId(),
SelectedChannelStore.getChannelId());
}
function value_119992({guildId, channelId}) { // fn#119992, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:1174, offset: 0x0251d6c7, size: 108 bytes, params: 2, frame: 16
const value = environment.__proto__;
if (guildId != null && ChannelStore.getChannel(channelId)?.type !== ChannelTypes.GUILD_VOICE) {
(require(5072) /* metro dependency 5072: AgeGateUtils */).maybeShowAgeGate(guildId, channelId);
}
}
function value_119993({source}) { // fn#119993, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:1349, offset: 0x0251d733, size: 80 bytes, params: 2, frame: 17
const defaultImport = importDefault(5080) /* metro dependency 5080: ModalActionCreators */;
defaultImport.pushLazy(env1_3(_fun119995), {source: source}, EXISTING_USER_AGE_GATE_MODAL_KEY);
}
function value_119997({guild}) { // fn#119997, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:1658, offset: 0x0251d847, size: 112 bytes, params: 2, frame: 15
let value = environment.__proto__;
const guildId = SelectedGuildStore.getGuildId();
if (guildId != null && guild.id === guildId && guild.owner_configured_content_level === GuildNSFWContentLevel.AGE_RESTRICTED) {
value = require(5072) /* metro dependency 5072: AgeGateUtils */;
value.maybeShowAgeGate(guild.id, null);
}
}
function* _fun119995() { // fn#119995, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15861:1391, offset: 0x0251d78e, size: 143 bytes, params: 1, frame: 17
var object2;
if (false) {
return undefined;
}
value = environment.__proto__.__proto__.__proto__;
const binding = env3_0;
const binding2 = env3_2;
const value3 = binding(binding2[14]);
let property = binding2[13];
yield value3(property, binding2.paths);
const value4 = undefined;
if (false) {
return value4;
}
property = value4.default;
const AUTH = env3_13.AUTH;
if (AgeGateManager === AUTH) {
object2 = {};
object2.animation = env3_0(env3_2[15]).ModalAnimation.SLIDE_IN_OUT;
property.modalConfig = object2;
}
return property;
}
@@ -0,0 +1,99 @@
/* Metro module 8581; source: modules/age_gate/native/AgeGateUtils.tsx; dependencies: [1867, 3784, 1878, 661, 477, 5080, 8582, 1962, 7867, 2] */
function _fun67879(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#67879, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8766:6, offset: 0x01c36606, size: 271 bytes, params: 8, frame: 20
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const permissionStore = importDefault(3784) /* metro dependency 3784: PermissionStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const constantsModule = require(661) /* metro dependency 661: Constants */;
const GuildNSFWContentLevel = constantsModule.GuildNSFWContentLevel;
const env0_7 = constantsModule.Permissions;
const Set = global.Set;
const EXPLICIT = GuildNSFWContentLevel.EXPLICIT;
const AGE_RESTRICTED = GuildNSFWContentLevel.AGE_RESTRICTED;
const set = new Set([EXPLICIT, AGE_RESTRICTED]);
const closure = isNSFWInvite;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/AgeGateUtils.tsx');
exports.isNSFWInvite = closure;
exports.handleNSFWGuildInvite = handleNSFWGuildInvite;
exports.shouldNSFWGateGuild = shouldNSFWGateGuild;
}
function isNSFWInvite(a0) { // fn#67880, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8766:232, offset: 0x01c36715, size: 67 bytes, params: 2, frame: 16
const binding = env0_8;
return binding.has((a0 == null || a0.guild == null ? undefined : a0.guild.nsfw_level) ?? GuildNSFWContentLevel.DEFAULT);
}
function handleNSFWGuildInvite(a0) { // fn#67881, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8766:454, offset: 0x01c36758, size: 222 bytes, params: 2, frame: 19
var r1;
var r0;
var isNSFWInvite2;
var defaultImport;
var pushLazy;
var value;
const value2 = undefined;
const moduleValue = require(dependencyMap[4]);
if (moduleValue.isIOS()) {
isNSFWInvite2 = isNSFWInvite(a0);
r1 = isNSFWInvite2 ? GuildStore.getGuild(a0 == null || a0.guild == null ? value2 : a0.guild.id) != null : !isNSFWInvite2;
if (r1) {
r0 = !r1;
} else {
defaultImport = importDefault(dependencyMap[5]);
pushLazy = defaultImport.pushLazy;
value = require(dependencyMap[7]);
value = value(dependencyMap[6], dependencyMap.paths);
Reflect.apply(pushLazy, defaultImport, [value,
{guildId: a0 == null || a0.guild == null ? value2 : a0.guild.id}]);
value = true;
r0 = value;
}
return r0;
}
return false;
}
function shouldNSFWGateGuild(a0) { // fn#67882, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8766:709, offset: 0x01c36836, size: 310 bytes, params: 2, frame: 17
var r0;
var r3;
var guild;
var currentUser;
var nsfwLevel;
var value8;
var value9;
var nsfwAllowed;
var value;
const platformUtilsModule = require(477) /* metro dependency 477: PlatformUtils */;
if (platformUtilsModule.isIOS()) {
guild = GuildStore.getGuild(a0);
currentUser = UserStore.getCurrentUser();
if (guild == null) {
return false;
}
if (currentUser == null) {
return false;
}
r0 = PermissionStore.can(Permissions.ADMINISTRATOR, guild) || PermissionStore.can(Permissions.MANAGE_GUILD,
guild);
r0 = !r0 ? PermissionStore.can(Permissions.KICK_MEMBERS, guild) : r0;
r0 = !r0 ? PermissionStore.can(Permissions.BAN_MEMBERS, guild) : r0;
nsfwLevel = guild.nsfwLevel;
value8 = nsfwLevel === GuildNSFWContentLevel.AGE_RESTRICTED;
nsfwLevel = guild.nsfwLevel;
value9 = nsfwLevel === GuildNSFWContentLevel.EXPLICIT;
nsfwAllowed = currentUser.nsfwAllowed;
if (nsfwAllowed) {
value = require(7867) /* metro dependency 7867: AgeRestrictedContentSettingsUtils */;
value = value.getViewNsfwGuildsOrDefault();
r3 = value;
} else {
r3 = nsfwAllowed;
}
value = !r0;
r0 = r0 ? value : value9 ? !!value9 : value8 && !r3;
return r0;
}
return false;
}
@@ -0,0 +1,9 @@
/* Metro module 15655; source: modules/age_gate/native/ExistingUserAgeGateConstants.tsx; dependencies: [2] */
function _fun120020(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120020, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15863:6, offset: 0x0251e187, size: 144 bytes, params: 8, frame: 16
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/ExistingUserAgeGateConstants.tsx');
exports.ExistingUserAgeGateScreens = {AgeGate: 'AgeGate', AgeGateConfirm: 'AgeGateConfirm', Blocked: 'Blocked',
NSFWBlocked: 'NSFWBlocked', NSFWGateGuild: 'NSFWGateGuild', Pawtect: 'Pawtect'};
}
@@ -0,0 +1,116 @@
/* Metro module 14344; source: modules/age_gate/native/components/AgeGateUnderage.tsx; dependencies: [31, 27, 661, 33, 4501, 697, 8973, 1484, 5282, 5286, 1244, 8584, 9004, 5473, 9003, 6766, 1948, 4573, 4578, 2] */
function _fun108552(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#108552, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14541:6, offset: 0x023251d9, size: 237 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const env0_5 = (require(661) /* metro dependency 661: Constants */).HelpdeskArticles;
const value = require(33) /* metro dependency 33 */;
const env0_6 = value.jsx;
const env0_7 = value.Fragment;
const env0_8 = value.jsxs;
const env0_9 = (require(4501) /* metro dependency 4501: createStyles */).createStyles(_fun108553);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/AgeGateUnderage.tsx');
exports.default = AgeGateUnderage;
}
function _fun108553(a0) { // fn#108553, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14541:212, offset: 0x023252c6, size: 128 bytes, params: 2, frame: 14
const BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
return {container: {'alignItems': 'center', 'justifyContent': 'center', 'flex': 1, 'padding': 16, 'paddingTop': 0,
paddingBottom: a0 ? 80 : 0, backgroundColor: BACKGROUND_BASE_LOW}, header: {marginTop: 16},
body: {'marginTop': 8, 'lineHeight': 20, 'textAlign': 'center'}, buttonWrapper: {'width': '100%',
'marginTop': 24}};
}
function AgeGateUnderage({onClose, underageMessage, existingUser, fromRegister, disableSwipe}) { // fn#108554, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14541:595, offset: 0x02325346, size: 1008 bytes, params: 2, frame: 34
var r20;
var r11;
var r5;
var format;
var b0QzXe;
var object;
var intl2;
var defaultImport4;
var jsxRuntimeEnv0_7Binding;
var items2;
var Button;
var object9;
existingUser = !(existingUser === undefined) && existingUser;
fromRegister = !(fromRegister === undefined) && fromRegister;
disableSwipe = !(disableSwipe === undefined) && disableSwipe;
const value2 = (importDefault(8973) /* metro dependency 8973: useWideAuthView */)();
const styles = useStyles(value2);
const value3 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
value3.useLayoutEffect(_fun108555, [onClose, existingUser, value3, disableSwipe]);
(require(5286) /* metro dependency 5286: useNavigatorBackPressHandlerNative */).useNavigatorBackPressHandler(function() {
onClose();
return true;
});
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
const r15 = existingUser ? Reflect.apply(string, intl, [t['NR/zrG']]) : Reflect.apply(string, intl, [t.nCB6Ga]);
const items3 = [value2 ? null : ((Component) => <Component />)(importDefault(8584) /* metro dependency 8584: BackgroundImage */)];
items3[1] = ((Component) => <Component />)(importDefault(9004) /* metro dependency 9004: AuthNavbarPlaceholder */);
const ShieldSpotIllustration = (require(5473) /* metro dependency 5473: native */).ShieldSpotIllustration;
items3[2] = <ShieldSpotIllustration />;
items3[3] = ((Component) => <Component style={styles.header}>{r15}</Component>)(importDefault(9003) /* metro dependency 9003: AuthHeader */);
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
if (fromRegister) {
r11 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.GDQgHL);
} else {
format = intl.format;
b0QzXe = (require(1244) /* metro dependency 1244: indexNative */).t.b0QzXe;
object = {};
if (underageMessage != null) {
r20 = underageMessage;
} else {
intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
r20 = intl2.string((require(1244) /* metro dependency 1244: indexNative */).t.WqEH4D);
}
object.underageMessage = r20;
defaultImport4 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
object.helpURL = defaultImport4.getArticleURL(HelpdeskArticles.AGE_GATE);
r11 = Reflect.apply(format, intl, [b0QzXe, object]);
}
items3[4] = <TextWithIOSLinkWorkaround style={styles.body} variant="text-md/medium" color="interactive-text-default">{r11}</TextWithIOSLinkWorkaround>;
if (existingUser) {
jsxRuntimeEnv0_7Binding = jsxRuntimeEnv0_7;
items2 = [((Text) => <Text style={styles.body} variant="text-md/medium" color="interactive-text-default">{intl.format(t['3axQdB'],
{days: 30})}</Text>)((require(4573) /* metro dependency 4573: Text */).Text)];
var viewBinding2Props = {style: styles.buttonWrapper};
Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
items2[1] = <View {...viewBinding2Props}><Button onPress={onClose} text={intl.string(t.JhDw5o)} grow /></View>;
r5 = <>{items2}</>;
} else {
r5 = null;
}
items3[5] = r5;
return (
<View style={styles.container}>
{items3}
</View>
);
}
function _fun108555() { // fn#108555, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14541:773, offset: 0x02325736, size: 99 bytes, params: 1, frame: 15
var environment;
var r4;
var value2;
var moduleValue;
const binding = env0_3;
const setOptions = binding.setOptions;
if (existingUser) {
r4 = function() {
return null;
};
} else {
value2 = environment.__proto__;
moduleValue = require(5282) /* metro dependency 5282: NavigatorHeaderNative */;
r4 = moduleValue.getHeaderBackButton(onClose);
}
Reflect.apply(setOptions, binding, [{headerLeft: r4, gestureEnabled: !disableSwipe}]);
}
@@ -0,0 +1,47 @@
/* Metro module 15660; source: modules/age_gate/native/components/AgeGateVerify.tsx; dependencies: [31, 27, 33, 4501, 697, 5072, 4813, 6618, 5473, 4573, 4578, 5263, 5074, 2] */
function _fun120052(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120052, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15868:6, offset: 0x0251f57b, size: 306 bytes, params: 8, frame: 22
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
importAll(31) /* metro dependency 31 */;
const env0_3 = (require(27) /* metro dependency 27 */).View;
let value = require(33) /* metro dependency 33 */;
const env0_4 = value.jsx;
const env0_5 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const object = {'padding': null, 'flex': 1, 'alignItems': 'center', 'justifyContent': 'center'};
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object.padding = PX_16;
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object.gap = PX_16;
const env0_6 = Reflect.apply(createStyles, value, [{container: object, header: {textAlign: 'center'},
body: {textAlign: 'center'}, buttonWrapper: {width: '100%'}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/AgeGateVerify.tsx');
exports.default = AgeGateVerify;
}
function AgeGateVerify({source}) { // fn#120053, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15868:467, offset: 0x0251f6ad, size: 389 bytes, params: 2, frame: 27
const styles = useStyles();
const {verifyAgreementButtonText, verifyGateDescription,
verifyTitle} = (require(5072) /* metro dependency 5072: AgeGateUtils */).useAgeGateVerifyContent(source);
(require(4813) /* metro dependency 4813: AgeVerificationUtils */).useMaybePerformReactiveCheckForSource(source);
const SafeAreaPaddingView = (require(6618) /* metro dependency 6618: SafeAreaView */).SafeAreaPaddingView;
const ShieldSpotIllustration = (require(5473) /* metro dependency 5473: native */).ShieldSpotIllustration;
const items2 = [<ShieldSpotIllustration />];
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
items2[1] = <Text style={styles.header} variant="heading-xl/extrabold" color="mobile-text-heading-primary">{verifyTitle}</Text>;
items2[2] = <Text style={styles.body} variant="text-md/medium" color="interactive-text-default">{verifyGateDescription}</Text>;
items2[3] = verifyAgreementButtonText != null && <View style={styles.buttonWrapper}>{((Button) => <Button text={verifyAgreementButtonText} onPress={function() {
var defaultImport = importDefault(dependencyMap[11]);
var object = {};
object.entryPoint = require(dependencyMap[12]).AgeVerificationModalEntryPoint.NSFW_AGE_GATE;
defaultImport.showAgeVerificationGetStartedModal(object);
}} grow />)((require(4578) /* metro dependency 4578: ButtonNative */).Button)}</View>;
return (
<SafeAreaPaddingView top style={styles.container}>
{items2}
</SafeAreaPaddingView>
);
}
@@ -0,0 +1,13 @@
/* Metro module 8583; source: modules/age_gate/native/components/Constants.tsx; dependencies: [2] */
function _fun67886(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#67886, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8768:6, offset: 0x01c36e43, size: 111 bytes, params: 8, frame: 16
var object2;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
object2 = {MODAL: 0};
object2[0] = 'MODAL';
object2.GUILD_SIDEBAR = 1;
object2[1] = 'GUILD_SIDEBAR';
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/Constants.tsx');
exports.NsfwGateSource = object2;
}
@@ -0,0 +1,91 @@
/* Metro module 15658; source: modules/age_gate/native/components/DateInput.tsx; dependencies: [31, 27, 33, 3738, 4080, 9066, 1962, 8967, 1305, 2] */
function _fun120038(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120038, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:6, offset: 0x0251eda7, size: 197 bytes, params: 8, frame: 18
const env0_0 = require;
const initialDate = function() {
return subtractYearsFromToday(10);
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).Keyboard;
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
value = value.forwardRef(_fun120041);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/DateInput.tsx');
exports.default = value;
}
function subtractYearsFromToday(a0) { // fn#120039, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:139, offset: 0x0251ee6c, size: 73 bytes, params: 2, frame: 13
const value = (importDefault(3738) /* metro dependency 3738 */)();
value.set('year', value.year() - a0);
return value.toDate();
}
function _fun120041({date, onChangeDate, label, style, error}, a1) { // fn#120041, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:310, offset: 0x0251eec8, size: 382 bytes, params: 3, frame: 24
const env0_3 = undefined;
const closure = onPress_120043;
const binding = env0_3;
const value3 = binding.useRef(null);
binding.useImperativeHandle(a1, function() {
return {focus: _fun120045};
});
const r7 = date?.format('L') ?? undefined;
const value6 = (importDefault(3738) /* metro dependency 3738 */)(initialDate()).format('L');
const FreeFormInputGroup = importDefault(8967) /* metro dependency 8967: FreeFormInputGroup */;
const value7 = '';
const r12 = r7 ?? value7;
const ClearButtonVisibility = (require(1305) /* metro dependency 1305: native */).ClearButtonVisibility;
const NEVER = ClearButtonVisibility.NEVER;
return (
<FreeFormInputGroup
style={style}
ref={value3}
value={r12}
placeholder={value6}
returnKeyType="next"
textContentType="none"
autoCapitalize="none"
clearButtonVisibility={NEVER}
editable={false}
forceAccessibleContainer
accessibilityLabel={value7 + label + ', ' + (r7 ?? value6)}
onPress={closure}
label={label}
error={error}
/>
);
}
function updateDate(a0) { // fn#120042, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:393, offset: 0x0251f046, size: 44 bytes, params: 2, frame: 12
onChangeDate(a0);
const current = env0_3.current;
if (current != null) {
current.blur();
}
}
function onPress_120043() { // fn#120043, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:457, offset: 0x0251f072, size: 199 bytes, params: 1, frame: 20
Keyboard.dismiss();
const value2 = undefined;
const defaultImport = importDefault(dependencyMap[4]);
const openLazy = defaultImport.openLazy;
const value3 = require(dependencyMap[6])(dependencyMap[5], dependencyMap.paths);
const object2 = {};
object2.onSubmit = updateDate;
object2.title = label;
let r6 = date == null ? value2 : date.toDate();
r6 = r6 ?? initialDate();
object2.startDate = r6;
const subtractYearsFromTodayBinding = subtractYearsFromToday;
object2.maximumDate = subtractYearsFromTodayBinding(3);
object2.minimumDate = subtractYearsFromTodayBinding(100);
object2.requireDateChanged = true;
Reflect.apply(openLazy, defaultImport, [value3, 'DatePicker', object2]);
return value2;
}
function _fun120044() { // fn#120044, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15866:771, offset: 0x0251f139, size: 18 bytes, params: 1, frame: 2
return {focus: function() {
onPress_120043();
}};
}
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,126 @@
/* Metro module 15659; source: modules/age_gate/native/components/ExistingUserAgeGateConfirm.tsx; dependencies: [5, 57, 31, 27, 661, 33, 4501, 1484, 6618, 4573, 1244, 6766, 1948, 4578, 2] */
function _fun120046(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120046, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15867:6, offset: 0x0251f14b, size: 325 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 env0_6 = (require(27) /* metro dependency 27 */).View;
const env0_7 = (require(661) /* metro dependency 661: Constants */).HelpdeskArticles;
const value = require(33) /* metro dependency 33 */;
const env0_8 = value.jsx;
const env0_9 = value.jsxs;
const env0_10 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({container: {'padding': 16,
'flex': 1, 'alignItems': 'center', 'justifyContent': 'center'}, header: {'textAlign': 'center',
'marginBottom': 8}, body: {'textAlign': 'center', 'lineHeight': 20, 'marginBottom': 16},
buttonWrapper: {width: '100%'}});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/ExistingUserAgeGateConfirm.tsx');
exports.default = ExistingUserAgeGateConfirm;
}
function ExistingUserAgeGateConfirm({age, onConfirm}) { // fn#120047, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15867:536, offset: 0x0251f290, size: 581 bytes, params: 2, frame: 32
const styles = useStyles();
const env0_1 = (require(1484) /* metro dependency 1484: useNavigationNative */).useNavigation();
const [property, env0_2] = env0_4(env0_5.useState(false), 2);
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 format = intl.format;
const items2 = [<Text style={styles.header} variant="heading-xl/extrabold" color="mobile-text-heading-primary">{Reflect.apply(format,
intl, [(require(1244) /* metro dependency 1244: indexNative */).t.wumolR, {age: age}])}</Text>];
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
format = intl.format;
const n3QjDE = (require(1244) /* metro dependency 1244: indexNative */).t.n3QjDE;
const defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
const getArticleURL = defaultImport.getArticleURL;
const AGE_GATE = HelpdeskArticles.AGE_GATE;
items2[1] = <TextWithIOSLinkWorkaround style={styles.body} variant="text-md/medium" color="interactive-text-default">{Reflect.apply(format,
intl, [n3QjDE, {helpURL: Reflect.apply(getArticleURL, defaultImport, [AGE_GATE])}])}</TextWithIOSLinkWorkaround>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
items2[2] = <View style={styles.buttonWrapper}><Button loading={property} disabled={property} text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['6tahin'])} onPress={function() {
return ExistingUserAgeGateConfirm_handleConfirm.apply(this, arguments);
}} grow /></View>;
return (
<SafeAreaPaddingView top style={styles.container}>
{items2}
</SafeAreaPaddingView>
);
}
function ExistingUserAgeGateConfirm_handleConfirm() { // fn#120048, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15867:669, owner: ExistingUserAgeGateConfirm._handleConfirm, offset: 0x0251f4d5, size: 53 bytes, params: 1, frame: 13
var environment;
const value = environment.__proto__;
return env1_3(_fun120050).apply(this, arguments);
}
function* _fun120050() { // fn#120050, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15867:720, offset: 0x0251f515, size: 102 bytes, params: 1, frame: 14
var moduleValue;
var value3;
var value4;
var shouldShowError;
var pop;
var error;
if (true) {
value = environment.__proto__.__proto__;
dependencyMap(true);
reducibleJoin3: while (true) {
reduciblePort14: while (true) {
exceptionLanding13: while (true) {
try {
} catch (error) {
break exceptionLanding13;
}
break reducibleJoin3;
}
pop = importDefault.pop;
Reflect.apply(pop, importDefault, []);
break reduciblePort14;
}
dependencyMap(false);
return undefined;
}
try {
moduleValue = require();
} catch (error) {
break exceptionLanding13;
}
yield moduleValue;
try {
value3 = undefined;
value4 = false;
} catch (error) {
break exceptionLanding13;
}
if (value4) {
return value3;
}
try {
shouldShowError = value3.shouldShowError;
} catch (error) {
break exceptionLanding13;
}
reducibleJoin14: while (true) {
if (shouldShowError) {
try {
} catch (error) {
break exceptionLanding13;
}
try {
pop = importDefault.pop;
} catch (error) {
break exceptionLanding13;
}
try {
Reflect.apply(pop, importDefault, []);
} catch (error) {
break exceptionLanding13;
}
break reducibleJoin14;
}
break reducibleJoin14;
}
dependencyMap(false);
}
}
@@ -0,0 +1,232 @@
/* Metro module 15654; source: modules/age_gate/native/components/ExistingUserAgeGateModal.tsx; dependencies: [31, 3969, 1229, 15655, 661, 33, 477, 3857, 15656, 1244, 5075, 6593, 5080, 683, 480, 5282, 15657, 15659, 15660, 14344, 8582, 5072, 4813, 5280, 2] */
function _fun119998(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#119998, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:6, offset: 0x0251d8b7, size: 267 bytes, params: 8, frame: 19
const env0_0 = require;
const renderHeaderTitle = function() {
return null;
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const selectedGuildStore = importDefault(3969) /* metro dependency 3969: SelectedGuildStore */;
const ageGateConstantsModule = require(1229) /* metro dependency 1229: AgeGateConstants */;
const env0_5 = ageGateConstantsModule.AgeGateAnalyticAction;
const env0_6 = ageGateConstantsModule.AgeGateSource;
const env0_7 = (require(15655) /* metro dependency 15655: ExistingUserAgeGateConstants */).ExistingUserAgeGateScreens;
const env0_8 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
const env0_9 = (require(33) /* metro dependency 33 */).jsx;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/ExistingUserAgeGateModal.tsx');
exports.default = ExistingUserAgeGateModal;
}
function onClose_119999() { // fn#119999, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:246, offset: 0x0251d9c2, size: 37 bytes, params: 1, frame: 11
(require(5075) /* metro dependency 5075: AgeGateModalActionCreators */).closeAgeGateModal();
}
function getScreens_120001(a0) { // fn#120001, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:335, offset: 0x0251d9e7, size: 404 bytes, params: 2, frame: 23
const env0_0 = a0;
const r6 = generateOnBack(a0) ?? (function() {
});
const object3 = {};
const AgeGate = ExistingUserAgeGateScreens.AgeGate;
const object4 = {fullscreen: true};
const ImpressionNames = (require(480) /* metro dependency 480: AnalyticsUtils */).ImpressionNames;
const USER_AGE_GATE = ImpressionNames.USER_AGE_GATE;
object4.impressionName = USER_AGE_GATE;
object4.impressionProperties = {existing_user: true};
object4.headerLeft = (require(5282) /* metro dependency 5282: NavigatorHeaderNative */).getHeaderBackButton(r6);
const renderHeaderTitleBinding = renderHeaderTitle;
object4.headerTitle = renderHeaderTitleBinding;
object4.render = render_120009;
object3[AgeGate] = object4;
const AgeGateConfirm = ExistingUserAgeGateScreens.AgeGateConfirm;
object3[AgeGateConfirm] = {fullscreen: true, headerTitle: renderHeaderTitleBinding, render: render_120013};
const Pawtect = ExistingUserAgeGateScreens.Pawtect;
const object6 = {fullscreen: true};
object6.headerLeft = (require(5282) /* metro dependency 5282: NavigatorHeaderNative */).getHeaderBackButton(r6);
const USER_AGE_GATE_VERIFY = ImpressionNames.USER_AGE_GATE_VERIFY;
object6.impressionName = USER_AGE_GATE_VERIFY;
object6.headerTitle = renderHeaderTitleBinding;
object6.render = render_120014;
object3[Pawtect] = object6;
const Blocked = ExistingUserAgeGateScreens.Blocked;
object3[Blocked] = {fullscreen: true, headerTitle: renderHeaderTitleBinding,
impressionProperties: {existing_user: true}, render: render_120015};
const NSFWGateGuild = ExistingUserAgeGateScreens.NSFWGateGuild;
const object7 = {headerTitle: renderHeaderTitleBinding};
object7.headerLeft = (require(5282) /* metro dependency 5282: NavigatorHeaderNative */).getHeaderBackButton(r6);
object7.render = render_120016;
object3[NSFWGateGuild] = object7;
return object3;
}
function ExistingUserAgeGateModal({source}) { // fn#120017, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:2386, offset: 0x0251e043, size: 265 bytes, params: 2, frame: 22
const value2 = (require(5072) /* metro dependency 5072: AgeGateUtils */).useShouldAgeVerifyForAgeGate();
const binding = env0_3;
const env0_1 = binding.useRef(value2);
const ageVerificationUtilsModule = require(4813) /* metro dependency 4813: AgeVerificationUtils */;
const useWatchAgeVerificationStatusChange = ageVerificationUtilsModule.useWatchAgeVerificationStatusChange;
const useCallback = binding.useCallback;
Reflect.apply(useWatchAgeVerificationStatusChange, ageVerificationUtilsModule, [Reflect.apply(useCallback, binding,
[_fun120018, [source]])]);
const Navigator = (require(5280) /* metro dependency 5280: NavigatorNative */).Navigator;
const useMemo = binding.useMemo;
const items2 = [source];
const r5 = value2 ? ExistingUserAgeGateScreens.Pawtect : ExistingUserAgeGateScreens.AgeGate;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
return (
<Navigator
screens={Reflect.apply(useMemo, binding, [function() {
return getScreens_120001(source);
}, items2])}
initialRouteName={r5}
headerBackTitle={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['13/7kX'])}
/>
);
}
function generateOnBack(a0) { // fn#120002, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:375, owner: getScreens_120001.generateOnBack, offset: 0x0251db7b, size: 193 bytes, params: 2, frame: 4
const env0_0 = a0;
const NSFW_SERVER_INVITE = AgeGateSource.NSFW_SERVER_INVITE;
if (NSFW_SERVER_INVITE === a0) {
return _fun120003;
}
const NSFW_SERVER_INVITE_EMBED = AgeGateSource.NSFW_SERVER_INVITE_EMBED;
if (NSFW_SERVER_INVITE_EMBED === a0) {
return _fun120003;
}
const JOIN_LARGE_GUILD_UNDERAGE = AgeGateSource.JOIN_LARGE_GUILD_UNDERAGE;
if (JOIN_LARGE_GUILD_UNDERAGE === a0) {
return _fun120004;
}
const ACCESS_LARGE_GUILD_UNDERAGE = AgeGateSource.ACCESS_LARGE_GUILD_UNDERAGE;
if (ACCESS_LARGE_GUILD_UNDERAGE === a0) {
return _fun120004;
}
const LARGE_GUILD = AgeGateSource.LARGE_GUILD;
if (LARGE_GUILD === a0) {
return _fun120004;
}
const NSFW_SERVER = AgeGateSource.NSFW_SERVER;
if (NSFW_SERVER === a0) {
return _fun120004;
}
const NSFW_CHANNEL = AgeGateSource.NSFW_CHANNEL;
if (NSFW_CHANNEL === a0) {
return _fun120005;
}
const NSFW_VOICE_CHANNEL = AgeGateSource.NSFW_VOICE_CHANNEL;
if (NSFW_VOICE_CHANNEL === a0) {
return _fun120006;
}
const FAMILY_CENTER = AgeGateSource.FAMILY_CENTER;
if (FAMILY_CENTER === a0) {
return _fun120007;
}
}
function getScreens_120001Render(a0, a1) { // fn#120009, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1281, owner: getScreens_120001.render, offset: 0x0251dda8, size: 82 bytes, params: 3, frame: 17
const binding = env0_0;
return ((Component) => <Component onSuccess={generateOnSuccess(binding,
a1)} onClose={onClose_119999} source={binding} />)(importDefault(15657) /* metro dependency 15657: ExistingUserAgeGate */);
}
function getScreens_120001Render_120013(a0) { // fn#120013, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1788, owner: getScreens_120001.render, offset: 0x0251df6f, size: 65 bytes, params: 2, frame: 15
const value = environment.__proto__;
return ((Component) => <Component {...a0} {...{['source']: env0_0}} />)(importDefault(15659) /* metro dependency 15659: ExistingUserAgeGateConfirm */);
}
function getScreens_120001Render_120014() { // fn#120014, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1988, owner: getScreens_120001.render, offset: 0x0251dfb0, size: 50 bytes, params: 1, frame: 14
const value = environment.__proto__;
return ((Component) => <Component source={env0_0} />)(importDefault(15660) /* metro dependency 15660: AgeGateVerify */);
}
function getScreens_120001Render_120015(a0) { // fn#120015, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:2120, owner: getScreens_120001.render, offset: 0x0251dfe2, size: 49 bytes, params: 2, frame: 14
const value = environment.__proto__;
return ((Component) => <Component {...a0} />)(importDefault(14344) /* metro dependency 14344: AgeGateUnderage */);
}
function getScreens_120001Render_120016() { // fn#120016, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:2242, owner: getScreens_120001.render, offset: 0x0251e013, size: 48 bytes, params: 1, frame: 14
return ((Component) => <Component onClose={onClose_119999} />)(importDefault(8582) /* metro dependency 8582: NsfwGateGuild */);
}
function _fun120018() { // fn#120018, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:2559, offset: 0x0251e14c, size: 59 bytes, params: 1, frame: 12
var value2;
var moduleValue;
if (env0_1.current) {
value2 = environment.__proto__;
moduleValue = require(5075) /* metro dependency 5075: AgeGateModalActionCreators */;
moduleValue.closeAgeGateModal(source);
}
}
function _fun120003() { // fn#120003, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:476, offset: 0x0251dc3c, size: 45 bytes, params: 1, frame: 12
const value = environment.__proto__.__proto__;
(require(5075) /* metro dependency 5075: AgeGateModalActionCreators */).closeAgeGateModal(env0_0);
}
function _fun120004() { // fn#120004, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:624, offset: 0x0251dc69, size: 124 bytes, params: 1, frame: 14
const value = environment.__proto__.__proto__;
const guildId = SelectedGuildStore.getGuildId();
if (guildId != null) {
(importDefault(6593) /* metro dependency 6593: GuildActionCreators */).nsfwReturnToSafety(guildId);
}
(require(5075) /* metro dependency 5075: AgeGateModalActionCreators */).closeAgeGateModal(env0_0);
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popAll();
}
function _fun120005() { // fn#120005, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:765, offset: 0x0251dce5, size: 98 bytes, params: 1, frame: 13
const value = environment.__proto__.__proto__;
const guildId = SelectedGuildStore.getGuildId();
if (guildId != null) {
(importDefault(6593) /* metro dependency 6593: GuildActionCreators */).nsfwReturnToSafety(guildId);
}
(require(5075) /* metro dependency 5075: AgeGateModalActionCreators */).closeAgeGateModal(env0_0);
}
function _fun120006() { // fn#120006, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:894, offset: 0x0251dd47, size: 97 bytes, params: 1, frame: 16
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).popAll();
const defaultImport2 = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport2.track;
const AGE_GATE_ACTION = AnalyticEvents.AGE_GATE_ACTION;
const AGE_GATE_CLOSE = AgeGateAnalyticAction.AGE_GATE_CLOSE;
Reflect.apply(track, defaultImport2, [AGE_GATE_ACTION, {source: env0_0, action: AGE_GATE_CLOSE}]);
}
function generateOnSuccess(a0, a1) { // fn#120010, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1299, owner: getScreens_120001.render.generateOnSuccess, offset: 0x0251ddfa, size: 82 bytes, params: 3, frame: 12
var environment;
var r0;
const env0_0 = a1;
let value = environment.__proto__.__proto__;
const NSFW_SERVER_INVITE = AgeGateSource.NSFW_SERVER_INVITE;
if (a0 !== NSFW_SERVER_INVITE) {
r0 = _fun120012;
} else {
value = require(477) /* metro dependency 477: PlatformUtils */;
r0 = value.isIOS() ? _fun120011 : _fun120012;
}
return r0;
}
function _fun120011() { // fn#120011, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1380, offset: 0x0251de4c, size: 148 bytes, params: 1, frame: 17
const push = require.push;
const NSFWGateGuild = ExistingUserAgeGateScreens.NSFWGateGuild;
Reflect.apply(push, require, [NSFWGateGuild]);
const defaultImport = importDefault(3857) /* metro dependency 3857: ToastActionCreators */;
const open = defaultImport.open;
const object2 = {key: 'AGE_GATE_AGE_VERIFIED', icon: importDefault(15656) /* metro dependency 15656 */};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object2.content = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.gUiIGZ);
Reflect.apply(open, defaultImport, [object2]);
}
function _fun120012() { // fn#120012, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15862:1513, offset: 0x0251dee0, size: 143 bytes, params: 1, frame: 17
let value = environment.__proto__.__proto__.__proto__;
(require(5075) /* metro dependency 5075: AgeGateModalActionCreators */).closeAgeGateModal();
value = importDefault(3857) /* metro dependency 3857: ToastActionCreators */;
const open = value.open;
const object2 = {key: 'AGE_GATE_AGE_VERIFIED', icon: importDefault(15656) /* metro dependency 15656 */};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object2.content = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.gUiIGZ);
Reflect.apply(open, value, [object2]);
}
@@ -0,0 +1,58 @@
/* Metro module 11980; source: modules/age_gate/native/components/NsfwGateChat.tsx; dependencies: [31, 27, 33, 4501, 697, 11981, 4573, 1244, 2] */
function _fun91969(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#91969, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12166:6, offset: 0x0207835c, size: 328 bytes, params: 8, frame: 23
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 StyleSheet = value.StyleSheet;
const env0_3 = value.View;
const env0_4 = value.Image;
value = require(33) /* metro dependency 33 */;
const env0_5 = value.jsx;
const env0_6 = value.jsxs;
const env0_7 = value.Fragment;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
const BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
object2.container = {'flex': 1, 'backgroundColor': null, 'alignItems': 'center', 'justifyContent': 'center',
backgroundColor: BACKGROUND_BASE_LOW};
const object4 = {};
object4.height = StyleSheet.hairlineWidth;
const BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
object4.backgroundColor = BACKGROUND_BASE_LOWEST;
object2.border = object4;
object2.description = {'marginTop': 16, 'textAlign': 'center'};
const env0_8 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/NsfwGateChat.tsx');
exports.default = _default_91970;
}
function _default_91970() { // fn#91970, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12166:469, offset: 0x020784a4, size: 247 bytes, params: 1, frame: 25
const styles = useStyles();
const jsxRuntimeEnv0_7Binding = jsxRuntimeEnv0_7;
const view = <View style={styles.border} />;
const image = <Image source={importDefault(11981) /* metro dependency 11981 */} />;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const string = intl.string;
const W4Qyxr = (require(1244) /* metro dependency 1244: indexNative */).t.W4Qyxr;
return (
<>
{view}
<View style={styles.container}>
{image}
<Text
style={styles.description}
variant="text-md/medium"
color="text-muted"
>
{Reflect.apply(string, intl, [W4Qyxr])}
</Text>
</View>
</>
);
}
@@ -0,0 +1,76 @@
/* Metro module 8582; source: modules/age_gate/native/components/NsfwGateGuild.tsx; dependencies: [31, 27, 1945, 1878, 8583, 661, 33, 4501, 697, 1244, 1948, 683, 7867, 8584, 8587, 4573, 4578, 2] */
function _fun67883(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#67883, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8767:6, offset: 0x01c3696c, size: 391 bytes, params: 8, frame: 22
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
let value = require(27) /* metro dependency 27 */;
const env0_4 = value.View;
const env0_5 = value.Image;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_8 = (require(8583) /* metro dependency 8583: Constants */).NsfwGateSource;
value = require(661) /* metro dependency 661: Constants */;
const env0_9 = value.AnalyticEvents;
const env0_10 = value.HelpdeskArticles;
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;
const BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
const env0_13 = Reflect.apply(createStyles, value, [{container: {'flex': 1, 'alignItems': 'center',
'justifyContent': 'center', 'padding': 16, backgroundColor: BACKGROUND_BASE_LOW},
header: {'textAlign': 'center', 'marginBottom': 8}, description: {'textAlign': 'center', 'marginBottom': 16},
image: {marginBottom: 16}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/NsfwGateGuild.tsx');
exports.default = _default_67884;
}
function _default_67884({onClose, guildId}) { // fn#67884, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8767:533, offset: 0x01c36af3, size: 636 bytes, params: 2, frame: 28
const styles = useStyles();
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const value2 = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t.vAymlG]);
string = intl.string;
const Crj6eC = (require(1244) /* metro dependency 1244: indexNative */).t.Crj6eC;
const value3 = Reflect.apply(string, intl, [Crj6eC]);
const format = intl.format;
const Z12LNW = (require(1244) /* metro dependency 1244: indexNative */).t.Z12LNW;
const defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
const getArticleURL = defaultImport.getArticleURL;
const NSFW_GUILD_GUIDELINES = HelpdeskArticles.NSFW_GUILD_GUIDELINES;
const value4 = Reflect.apply(format, intl, [Z12LNW, {helpURL: Reflect.apply(getArticleURL, defaultImport,
[NSFW_GUILD_GUIDELINES])}]);
env0_3.useEffect(_fun67885, [guildId, UserStore.getCurrentUser()]);
const items2 = [((Component) => <Component />)(importDefault(8584) /* metro dependency 8584: BackgroundImage */)];
items2[1] = <Image source={importDefault(8587) /* metro dependency 8587 */} style={styles.image} />;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
items2[2] = <Text style={styles.header} variant="heading-xl/extrabold" color="mobile-text-heading-primary">{value2}</Text>;
items2[3] = <Text style={styles.description} variant="text-md/normal" color="text-default">{value3}</Text>;
items2[4] = <Text style={styles.description} variant="text-md/normal" color="text-default">{value4}</Text>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
items2[5] = <Button onPress={onClose} size="md" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.gRqiWV)} />;
return (
<View style={styles.container}>
{items2}
</View>
);
}
function _fun67885() { // fn#67885, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8767:788, offset: 0x01c36d6f, size: 212 bytes, params: 1, frame: 22
const value2 = undefined;
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
const track = defaultImport.track;
const GUILD_NSFW_GATE_VIEWED = AnalyticEvents.GUILD_NSFW_GATE_VIEWED;
const object2 = {};
object2.guild_id = guildId;
object2.user_id = env0_1 == null ? value2 : env0_1.id;
object2.is_member = GuildMemberStore.isMember(guildId, env0_1 == null ? value2 : env0_1.id);
object2.is_user_opted_in_to_age_restricted_servers = (env0_1 == null ? value2 : env0_1.nsfwAllowed) && (require(7867) /* metro dependency 7867: AgeRestrictedContentSettingsUtils */).getViewNsfwGuildsOrDefault();
const MODAL = NsfwGateSource.MODAL;
object2.source = MODAL;
Reflect.apply(track, defaultImport, [GUILD_NSFW_GATE_VIEWED, object2]);
return value2;
}
@@ -0,0 +1,55 @@
/* Metro module 12682; source: modules/age_gate/native/components/NsfwGateGuildSettingsActionSheet.tsx; dependencies: [31, 33, 12683, 6805, 6758, 6807, 1244, 4080, 6613, 12684, 2] */
function _fun97164(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#97164, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12872:6, offset: 0x021755f5, size: 147 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 value = require(33) /* metro dependency 33 */;
const env0_3 = value.jsx;
const env0_4 = value.jsxs;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/NsfwGateGuildSettingsActionSheet.tsx');
exports.default = NsfwGateGuildSettingsActionSheet;
}
function NsfwGateGuildSettingsActionSheet({guild}) { // fn#97165, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12872:247, offset: 0x02175688, size: 403 bytes, params: 2, frame: 28
var object2;
const value2 = (require(12683) /* metro dependency 12683: useMessageRequestPrivacyOption */).useMessageRequestPrivacyOption({guild: guild});
const ActionSheet = (require(6805) /* metro dependency 6805: ActionSheetNative */).ActionSheet;
object2 = {};
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
object2.header = <BottomSheetTitleHeader title={guild.name} />;
const ActionSheetRow = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow;
const Group = ActionSheetRow.Group;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const items2 = [<ActionSheetRow label={Reflect.apply(string, intl,
[(require(1244) /* metro dependency 1244: indexNative */).t.h850Ss])} onPress={onPress_97166} />];
const RestrictedGuildPrivacyOption = (require(12684) /* metro dependency 12684: GuildActionSheetActions */).RestrictedGuildPrivacyOption;
items2[1] = <RestrictedGuildPrivacyOption guild={guild} />;
items2[2] = value2;
string = intl.string;
const J2TBi3 = (require(1244) /* metro dependency 1244: indexNative */).t.J2TBi3;
items2[3] = <ActionSheetRow variant="danger" label={Reflect.apply(string, intl,
[J2TBi3])} onPress={onPress_97167} />;
return (
<ActionSheet {...object2}>
<Group hasIcons={false}>
{items2}
</Group>
</ActionSheet>
);
}
function NsfwGateGuildSettingsActionSheetOnPress() { // fn#97166, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12872:583, owner: NsfwGateGuildSettingsActionSheet.onPress, offset: 0x0217581b, size: 72 bytes, params: 1, frame: 13
let value = environment.__proto__;
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
value = importDefault(6613) /* metro dependency 6613: NotificationSettingsModalActionCreators */;
value.open(guild.id);
}
function NsfwGateGuildSettingsActionSheetOnPress_97167() { // fn#97167, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12872:783, owner: NsfwGateGuildSettingsActionSheet.onPress, offset: 0x02175863, size: 45 bytes, params: 1, frame: 11
let value = environment.__proto__;
value = require(12684) /* metro dependency 12684: GuildActionSheetActions */;
return value.handleLeaveServer(guild);
}
@@ -0,0 +1,104 @@
/* Metro module 14740; source: modules/age_gate/native/components/NsfwGateGuildSidebar.tsx; dependencies: [31, 27, 1945, 1867, 1878, 8583, 661, 33, 4501, 697, 566, 683, 7867, 14553, 1305, 6597, 14741, 1244, 1948, 2] */
function _fun111185(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#111185, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14937:6, offset: 0x02396d52, size: 374 bytes, params: 8, frame: 22
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importAll(31) /* metro dependency 31 */;
const env0_4 = (require(27) /* metro dependency 27 */).View;
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_8 = (require(8583) /* metro dependency 8583: Constants */).NsfwGateSource;
let value = require(661) /* metro dependency 661: Constants */;
const env0_9 = value.AnalyticEvents;
const env0_10 = value.HelpdeskArticles;
const env0_11 = value.Fonts;
value = require(33) /* metro dependency 33 */;
const env0_12 = value.jsx;
const env0_13 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
const PANEL_BG = (importDefault(697) /* metro dependency 697: native */).colors.PANEL_BG;
const env0_14 = Reflect.apply(createStyles, value, [{container: {flex: 1, backgroundColor: PANEL_BG},
emptyStateContainer: {flex: 1}, emptyStateImageContainer: {marginBottom: 16}}]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/age_gate/native/components/NsfwGateGuildSidebar.tsx');
exports.default = _default_111186;
}
function _default_111186({style, guildId}) { // fn#111186, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14937:429, offset: 0x02396ec8, size: 497 bytes, params: 2, frame: 27
var r0;
var items2;
var RefreshEmptyState;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var format;
var NQuXf0;
var defaultImport3;
const styles = useStyles();
const guild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], function() {
return GuildStore.getGuild(guildId);
});
env0_3.useEffect(_fun111188, [guildId, guild, UserStore.getCurrentUser()]);
if (guild == null) {
r0 = null;
} else {
var viewBindingProps = {style: [styles.container, style]};
items2 = [((Component) => <Component guild={guild} showExtraButtons={false} />)(importDefault(14553) /* metro dependency 14553: ChannelListStickyHeader */)];
RefreshEmptyState = (require(1305) /* metro dependency 1305: native */).RefreshEmptyState;
var refreshEmptyStateProps2 = {imageStyle: styles.emptyStateImageContainer,
titleStyle: (importDefault(6597) /* metro dependency 6597: TextStyles */)(Fonts.DISPLAY_EXTRABOLD,
undefined,
16), containerStyle: styles.emptyStateContainer, source: importDefault(14741) /* metro dependency 14741 */,
title: intl.string(t.bAVpRR)};
format = intl.format;
NQuXf0 = t.NQuXf0;
defaultImport3 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
refreshEmptyStateProps2.body = Reflect.apply(format, intl, [NQuXf0,
{helpURL: defaultImport3.getArticleURL(HelpdeskArticles.NSFW_GUILD_GUIDELINES)}]);
items2[1] = <RefreshEmptyState {...refreshEmptyStateProps2} />;
r0 = <View {...viewBindingProps}>{items2}</View>;
}
return r0;
}
function _fun111188() { // fn#111188, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14937:559, offset: 0x023970b9, size: 188 bytes, params: 1, frame: 20
var r5;
var value4;
var defaultImport;
var track;
var GUILD_NSFW_GATE_VIEWED;
var object2;
var guildIdBinding;
var binding;
var id;
var isMember;
var nsfwAllowed;
var value;
if (env0_2 != null && guild != null) {
value4 = environment.__proto__;
defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
track = defaultImport.track;
GUILD_NSFW_GATE_VIEWED = AnalyticEvents.GUILD_NSFW_GATE_VIEWED;
object2 = {};
guildIdBinding = guildId;
object2.guild_id = guildIdBinding;
binding = env0_2;
id = binding.id;
object2.user_id = id;
isMember = GuildMemberStore.isMember;
id = binding.id;
object2.is_member = Reflect.apply(isMember, GuildMemberStore, [guildIdBinding, id]);
nsfwAllowed = binding.nsfwAllowed;
if (nsfwAllowed) {
value = require(7867) /* metro dependency 7867: AgeRestrictedContentSettingsUtils */;
value = value.getViewNsfwGuildsOrDefault();
r5 = value;
} else {
r5 = nsfwAllowed;
}
object2.is_user_opted_in_to_age_restricted_servers = r5;
object2.source = NsfwGateSource.GUILD_SIDEBAR;
Reflect.apply(track, defaultImport, [GUILD_NSFW_GATE_VIEWED, object2]);
}
}