Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,34 @@
|
||||
/* Metro module 13923; source: modules/app_icons/native/AppIcon.tsx; dependencies: [31, 27, 7902, 33, 4501, 697, 4048, 4002, 2] */
|
||||
function _fun105688(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#105688, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14120:6, offset: 0x022c015b, size: 281 bytes, params: 8, frame: 21
|
||||
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_3 = value.Image;
|
||||
const env0_4 = value.View;
|
||||
const env0_5 = (require(7902) /* metro dependency 7902: AppIconConstants */).getIconById;
|
||||
const env0_6 = (require(33) /* metro dependency 33 */).jsx;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
|
||||
const env0_7 = Reflect.apply(createStyles, value, [{container: {overflow: 'hidden',
|
||||
borderColor: BACKGROUND_BASE_LOWEST}, image: {'resizeMode': 'contain', 'height': '100%', 'width': '100%'}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIcon.tsx');
|
||||
exports.default = AppIcon;
|
||||
}
|
||||
|
||||
function AppIcon({id, size, style}) { // fn#105689, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14120:411, offset: 0x022c0274, size: 200 bytes, params: 2, frame: 22
|
||||
size = size === undefined ? 56 : size;
|
||||
const styles = useStyles();
|
||||
return (
|
||||
<View
|
||||
style={[styles.container, {width: size, height: size,
|
||||
borderWidth: (require(4002) /* metro dependency 4002: shared */).isThemeDark((importDefault(4048) /* metro dependency 4048: useTheme */)()) ? 0 : 1},
|
||||
style]}
|
||||
>
|
||||
<Image style={styles.image} source={getIconById(id).iconSource} />
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,245 @@
|
||||
/* Metro module 7902; source: modules/app_icons/native/AppIconConstants.tsx; dependencies: [7903, 7904, 1244, 7905, 7906, 7907, 7908, 7909, 7910, 7911, 7912, 7913, 7914, 7915, 7916, 7917, 7918, 7919, 7920, 7921, 7922, 7923, 7924, 7925, 7926, 7927, 7928, 2] */
|
||||
function _fun63305(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#63305, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8080:6, offset: 0x01b7a3b8, size: 2667 bytes, params: 8, frame: 29
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const closure = function() {
|
||||
var object = {};
|
||||
object.id = require(dependencyMap[0]).FreemiumAppIconIds.DEFAULT;
|
||||
object.iconSource = importDefault(dependencyMap[1]);
|
||||
object.name = require(dependencyMap[2]).intl.string(require(dependencyMap[2]).t.ANxkLy);
|
||||
object.isPremium = false;
|
||||
return object;
|
||||
};
|
||||
const closure2 = function(a0) {
|
||||
var r0;
|
||||
var value = a0.expiresAt != null;
|
||||
if (value) {
|
||||
value = global.Date.now();
|
||||
value = value > a0.expiresAt;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
};
|
||||
const closure3 = getOfficialAlternateIcons;
|
||||
const closure4 = getLimitedAlternateIcons;
|
||||
const closure5 = function() {
|
||||
var r4;
|
||||
var items = [getDefaultIcon()];
|
||||
arraySpread(items, getLimitedAlternateIcons(), arraySpread(items, getOfficialAlternateIcons(), 1, r4), r4);
|
||||
return items;
|
||||
};
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
object2 = {};
|
||||
const PremiumAppIconIds = (require(7903) /* metro dependency 7903: AppIconTypes */).PremiumAppIconIds;
|
||||
const IN_RAINBOWS = PremiumAppIconIds.IN_RAINBOWS;
|
||||
object2.id = IN_RAINBOWS;
|
||||
object2.iconSource = importDefault(7905) /* metro dependency 7905 */;
|
||||
object2.isPremium = true;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
object2.name = Reflect.apply(string, intl, [t.yxJB9E]);
|
||||
const items2 = [object2];
|
||||
object2 = {};
|
||||
const MIDNIGHT_PRISM = PremiumAppIconIds.MIDNIGHT_PRISM;
|
||||
object2.id = MIDNIGHT_PRISM;
|
||||
object2.iconSource = importDefault(7906) /* metro dependency 7906 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.nshUZZ);
|
||||
items2[1] = object2;
|
||||
object2 = {};
|
||||
const COLOR_WAVE = PremiumAppIconIds.COLOR_WAVE;
|
||||
object2.id = COLOR_WAVE;
|
||||
object2.iconSource = importDefault(7907) /* metro dependency 7907 */;
|
||||
object2.isPremium = true;
|
||||
string = intl.string;
|
||||
const MWRYqh = t.MWRYqh;
|
||||
object2.name = Reflect.apply(string, intl, [MWRYqh]);
|
||||
items2[2] = object2;
|
||||
object2 = {};
|
||||
const BLURPLE_TWILIGHT = PremiumAppIconIds.BLURPLE_TWILIGHT;
|
||||
object2.id = BLURPLE_TWILIGHT;
|
||||
object2.iconSource = importDefault(7908) /* metro dependency 7908 */;
|
||||
object2.isPremium = true;
|
||||
string = intl.string;
|
||||
const Mfoe3p = t.Mfoe3p;
|
||||
object2.name = Reflect.apply(string, intl, [Mfoe3p]);
|
||||
items2[3] = object2;
|
||||
object2 = {};
|
||||
const BRAND_INVERTED = PremiumAppIconIds.BRAND_INVERTED;
|
||||
object2.id = BRAND_INVERTED;
|
||||
object2.iconSource = importDefault(7909) /* metro dependency 7909 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.h6UXSt);
|
||||
items2[4] = object2;
|
||||
object2 = {};
|
||||
const BRAND_DARK = PremiumAppIconIds.BRAND_DARK;
|
||||
object2.id = BRAND_DARK;
|
||||
object2.iconSource = importDefault(7910) /* metro dependency 7910 */;
|
||||
object2.name = intl.string(t.gZEUBl);
|
||||
object2.isPremium = true;
|
||||
items2[5] = object2;
|
||||
object2 = {};
|
||||
const MATTE_DARK = PremiumAppIconIds.MATTE_DARK;
|
||||
object2.id = MATTE_DARK;
|
||||
object2.iconSource = importDefault(7911) /* metro dependency 7911 */;
|
||||
object2.isPremium = true;
|
||||
string = intl.string;
|
||||
const NkshQt = t.NkshQt;
|
||||
object2.name = Reflect.apply(string, intl, [NkshQt]);
|
||||
items2[6] = object2;
|
||||
object2 = {};
|
||||
const MATTE_LIGHT = PremiumAppIconIds.MATTE_LIGHT;
|
||||
object2.id = MATTE_LIGHT;
|
||||
object2.iconSource = importDefault(7912) /* metro dependency 7912 */;
|
||||
string = intl.string;
|
||||
const G2W302 = t.G2W302;
|
||||
object2.name = Reflect.apply(string, intl, [G2W302]);
|
||||
object2.isPremium = true;
|
||||
items2[7] = object2;
|
||||
object2 = {};
|
||||
const PASTEL = PremiumAppIconIds.PASTEL;
|
||||
object2.id = PASTEL;
|
||||
object2.iconSource = importDefault(7913) /* metro dependency 7913 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.mTSkLT);
|
||||
items2[8] = object2;
|
||||
object2 = {};
|
||||
const PIRATE = PremiumAppIconIds.PIRATE;
|
||||
object2.id = PIRATE;
|
||||
object2.iconSource = importDefault(7914) /* metro dependency 7914 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['EgWTY+']);
|
||||
items2[9] = object2;
|
||||
object2 = {};
|
||||
const CAMO = PremiumAppIconIds.CAMO;
|
||||
object2.id = CAMO;
|
||||
object2.iconSource = importDefault(7915) /* metro dependency 7915 */;
|
||||
object2.isPremium = true;
|
||||
string = intl.string;
|
||||
const RSKXOK = t.RSKXOK;
|
||||
object2.name = Reflect.apply(string, intl, [RSKXOK]);
|
||||
items2[10] = object2;
|
||||
object2 = {};
|
||||
const SUNSET = PremiumAppIconIds.SUNSET;
|
||||
object2.id = SUNSET;
|
||||
object2.iconSource = importDefault(7916) /* metro dependency 7916 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.ixdjPB);
|
||||
items2[11] = object2;
|
||||
object2 = {};
|
||||
const GALAXY = PremiumAppIconIds.GALAXY;
|
||||
object2.id = GALAXY;
|
||||
object2.iconSource = importDefault(7917) /* metro dependency 7917 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.cb78Ls);
|
||||
items2[12] = object2;
|
||||
object2 = {};
|
||||
const Y2K = PremiumAppIconIds.Y2K;
|
||||
object2.id = Y2K;
|
||||
object2.iconSource = importDefault(7918) /* metro dependency 7918 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['s+KoXO']);
|
||||
items2[13] = object2;
|
||||
object2 = {};
|
||||
const CHERRY_BLOSSOM = PremiumAppIconIds.CHERRY_BLOSSOM;
|
||||
object2.id = CHERRY_BLOSSOM;
|
||||
object2.iconSource = importDefault(7919) /* metro dependency 7919 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['ta/5RB']);
|
||||
items2[14] = object2;
|
||||
object2 = {};
|
||||
const BEANIE = PremiumAppIconIds.BEANIE;
|
||||
object2.id = BEANIE;
|
||||
object2.iconSource = importDefault(7920) /* metro dependency 7920 */;
|
||||
object2.isPremium = true;
|
||||
string = intl.string;
|
||||
const IoLViw = t.IoLViw;
|
||||
object2.name = Reflect.apply(string, intl, [IoLViw]);
|
||||
items2[15] = object2;
|
||||
object2 = {};
|
||||
const GAMING = PremiumAppIconIds.GAMING;
|
||||
object2.id = GAMING;
|
||||
object2.iconSource = importDefault(7921) /* metro dependency 7921 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['2Tf+c4']);
|
||||
items2[16] = object2;
|
||||
object2 = {};
|
||||
const CIRCUIT = PremiumAppIconIds.CIRCUIT;
|
||||
object2.id = CIRCUIT;
|
||||
object2.iconSource = importDefault(7922) /* metro dependency 7922 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.dUpxKb);
|
||||
items2[17] = object2;
|
||||
object2 = {};
|
||||
const HOLO_WAVES = PremiumAppIconIds.HOLO_WAVES;
|
||||
object2.id = HOLO_WAVES;
|
||||
object2.iconSource = importDefault(7923) /* metro dependency 7923 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['9mg7g1']);
|
||||
items2[18] = object2;
|
||||
object2 = {};
|
||||
const BLUSH = PremiumAppIconIds.BLUSH;
|
||||
object2.id = BLUSH;
|
||||
object2.iconSource = importDefault(7924) /* metro dependency 7924 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.nmd90m);
|
||||
items2[19] = object2;
|
||||
object2 = {};
|
||||
const ANGRY = PremiumAppIconIds.ANGRY;
|
||||
object2.id = ANGRY;
|
||||
object2.iconSource = importDefault(7925) /* metro dependency 7925 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['9PUXpM']);
|
||||
items2[20] = object2;
|
||||
object2 = {};
|
||||
const MANGA = PremiumAppIconIds.MANGA;
|
||||
object2.id = MANGA;
|
||||
object2.iconSource = importDefault(7926) /* metro dependency 7926 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.hGBbF8);
|
||||
items2[21] = object2;
|
||||
object2 = {};
|
||||
const CONTROLLER = PremiumAppIconIds.CONTROLLER;
|
||||
object2.id = CONTROLLER;
|
||||
object2.iconSource = importDefault(7927) /* metro dependency 7927 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t['4QM2U1']);
|
||||
items2[22] = object2;
|
||||
object2 = {};
|
||||
const MUSHROOM = PremiumAppIconIds.MUSHROOM;
|
||||
object2.id = MUSHROOM;
|
||||
object2.iconSource = importDefault(7928) /* metro dependency 7928 */;
|
||||
object2.isPremium = true;
|
||||
object2.name = intl.string(t.gnLLSK);
|
||||
items2[23] = object2;
|
||||
const env0_4 = [];
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIconConstants.tsx');
|
||||
exports.getDefaultIcon = closure;
|
||||
exports.isIconExpired = closure2;
|
||||
exports.getOfficialAlternateIcons = closure3;
|
||||
exports.getLimitedAlternateIcons = closure4;
|
||||
exports.getIcons = closure5;
|
||||
exports.getIconById = getIconById;
|
||||
}
|
||||
|
||||
function getOfficialAlternateIcons() { // fn#63308, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8080:3136, offset: 0x01b7aecf, size: 26 bytes, params: 1, frame: 11
|
||||
return env0_3.filter(function(a0) {
|
||||
return !isIconExpired(a0);
|
||||
});
|
||||
}
|
||||
|
||||
function getLimitedAlternateIcons() { // fn#63310, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8080:3213, offset: 0x01b7aeff, size: 26 bytes, params: 1, frame: 11
|
||||
return env0_4.filter(function(a0) {
|
||||
return !isIconExpired(a0);
|
||||
});
|
||||
}
|
||||
|
||||
function getIconById(a0) { // fn#63313, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8080:3677, offset: 0x01b7af51, size: 54 bytes, params: 2, frame: 13
|
||||
const env0_0 = a0;
|
||||
return getIcons().find(_fun63314) ?? getDefaultIcon();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,153 @@
|
||||
/* Metro module 15663; source: modules/app_icons/native/AppIconPremiumManager.tsx; dependencies: [5, 6, 7, 15, 17, 18, 1878, 7902, 661, 3, 7903, 477, 12187, 3802, 683, 4860, 2] */
|
||||
function _fun120083(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120083, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:6, offset: 0x0252069c, size: 406 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 userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const env0_10 = (require(7902) /* metro dependency 7902: AppIconConstants */).getIconById;
|
||||
const env0_11 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
|
||||
let value = importDefault(3) /* metro dependency 3: Logger */;
|
||||
value = new value('AppIconPremiumManager');
|
||||
const FreemiumAppIconIds = (require(7903) /* metro dependency 7903: AppIconTypes */).FreemiumAppIconIds;
|
||||
const env0_13 = FreemiumAppIconIds.DEFAULT;
|
||||
object = {ORPHANED: 'orphaned', PREMIUM_LOST: 'premium_lost'};
|
||||
value = importDefault(4860) /* metro dependency 4860: AutomaticLifecycleManager */;
|
||||
value = _fun120087(value);
|
||||
value = new value();
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIconPremiumManager.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_120084() { // fn#120084, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:215, offset: 0x02520832, 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_120084_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function _fun120087(a0) { // fn#120087, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:575, offset: 0x02520894, size: 144 bytes, params: 2, frame: 17
|
||||
const closure = AppIconPremiumManager;
|
||||
env0_8(closure, a0);
|
||||
const binding = env0_5;
|
||||
const items2 = [{key: 'handleAppStateUpdate', value: value_120090}];
|
||||
const env0_0 = env0_3(_fun120092);
|
||||
items2[1] = {key: 'validateAndResetIfNeeded', value: value_120093};
|
||||
items2[2] = {key: 'resetIcon', value: value_120094};
|
||||
return binding(closure, items2);
|
||||
}
|
||||
|
||||
function AppIconPremiumManager(a0) { // fn#120088, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:587, offset: 0x02520924, size: 152 bytes, params: 2, frame: 20
|
||||
var r0;
|
||||
var Reflect;
|
||||
let value = copyRestArgs(0, undefined);
|
||||
let binding = env1_4;
|
||||
binding(this, AppIconPremiumManager);
|
||||
const items = [];
|
||||
arraySpread(items, value, 0, items);
|
||||
value = env1_7(AppIconPremiumManager);
|
||||
binding = env1_6;
|
||||
if (_isNativeReflectConstruct_120084()) {
|
||||
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 = {APP_STATE_UPDATE: APP_STATE_UPDATE_120089};
|
||||
return value;
|
||||
}
|
||||
|
||||
function value_120090({state}) { // fn#120090, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:989, offset: 0x025209bc, size: 84 bytes, params: 2, frame: 13
|
||||
let value = environment.__proto__;
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isIOS();
|
||||
if (value ? state === 'active' : state === 'background') {
|
||||
this.validateAndResetIfNeeded();
|
||||
}
|
||||
}
|
||||
|
||||
function* _fun120092() { // fn#120092, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:1141, offset: 0x02520a1b, size: 362 bytes, params: 1, frame: 21
|
||||
if (false) {
|
||||
return undefined;
|
||||
}
|
||||
value = environment.__proto__.__proto__;
|
||||
let binding = env2_9;
|
||||
const currentUser = binding.getCurrentUser();
|
||||
binding = env2_0;
|
||||
const value4 = undefined;
|
||||
const value5 = binding(env2_2[12]);
|
||||
yield value5.fetchCurrentAppIcon();
|
||||
const value6 = undefined;
|
||||
if (false) {
|
||||
return value6;
|
||||
}
|
||||
if (value6 !== env2_13) {
|
||||
var value8 = env2_10(value6);
|
||||
if (value6 !== value8.id) {
|
||||
env2_12.info('Icon ' + value6 + ' is no longer available, resetting to default');
|
||||
this.resetIcon(value6, (currentUser == null ? value4 : currentUser.premiumType) ?? value4,
|
||||
env2_14.ORPHANED);
|
||||
return value4;
|
||||
}
|
||||
if (!env2_1(env2_2[13]).canUsePremiumAppIcons(currentUser) && value8.isPremium) {
|
||||
env2_12.info('User is not premium, resetting icon ' + value6 + ' to default');
|
||||
this.resetIcon(value6, (currentUser == null ? value4 : currentUser.premiumType) ?? value4,
|
||||
env2_14.PREMIUM_LOST);
|
||||
}
|
||||
}
|
||||
return value4;
|
||||
}
|
||||
|
||||
function value_120094(a0, a1, a2) { // fn#120094, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:1699, offset: 0x02520b85, size: 97 bytes, params: 4, frame: 15
|
||||
var environment;
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a2;
|
||||
let value = environment.__proto__;
|
||||
value = (require(12187) /* metro dependency 12187: AppIconUtils */).setAppIcon(DEFAULT, a1);
|
||||
value = value.then(_fun120095);
|
||||
value.catch(_fun120096);
|
||||
}
|
||||
|
||||
function _fun120095() { // fn#120095, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:1746, offset: 0x02520be6, size: 86 bytes, params: 1, frame: 17
|
||||
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
|
||||
const track = defaultImport.track;
|
||||
const APP_ICON_AUTO_RESET = AnalyticEvents.APP_ICON_AUTO_RESET;
|
||||
Reflect.apply(track, defaultImport, [APP_ICON_AUTO_RESET, {previous_icon_id: env0_0, reset_to_icon_id: DEFAULT,
|
||||
reset_reason: importDefault}]);
|
||||
}
|
||||
|
||||
function _fun120096(a0) { // fn#120096, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15871:1854, offset: 0x02520c3c, size: 31 bytes, params: 2, frame: 13
|
||||
env2_12.error('Failed to reset app icon:', a0);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,94 @@
|
||||
/* Metro module 13926; source: modules/app_icons/native/AppIconRow/AppIconRow.tsx; dependencies: [57, 31, 33, 1244, 4501, 697, 7903, 22, 3874, 6238, 13923, 7989, 2] */
|
||||
function _fun105708(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#105708, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14123:6, offset: 0x022c0e8e, size: 282 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_4 = importAll(31) /* metro dependency 31 */;
|
||||
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
|
||||
object = [function() {
|
||||
return require(dependencyMap[3]).intl.string(require(dependencyMap[3]).t['EgWTY+']);
|
||||
}, function() {
|
||||
return require(dependencyMap[3]).intl.string(require(dependencyMap[3]).t.umBn5f);
|
||||
}, function() {
|
||||
return require(dependencyMap[3]).intl.string(require(dependencyMap[3]).t.dG1wD1);
|
||||
}, function() {
|
||||
return require(dependencyMap[3]).intl.string(require(dependencyMap[3]).t.SesI4S);
|
||||
}, function() {
|
||||
return require(dependencyMap[3]).intl.string(require(dependencyMap[3]).t.RnMLvl);
|
||||
}];
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const object3 = {};
|
||||
object3.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
|
||||
const env0_7 = Reflect.apply(createStyles, createStylesModule, [{icon: object3}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIconRow/AppIconRow.tsx');
|
||||
exports.default = AppIconRow;
|
||||
}
|
||||
|
||||
function AppIconRow({icon, hasNitro, currentAppIcon, showEasterEgg, onSelect, onLongPress}) { // fn#105714, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14123:505, offset: 0x022c10e6, size: 492 bytes, params: 2, frame: 29
|
||||
var r3;
|
||||
var binding2;
|
||||
var defaultImport;
|
||||
const styles = useStyles();
|
||||
const id = icon.id;
|
||||
const isPremium = icon.isPremium;
|
||||
const binding = env0_4;
|
||||
const useState = binding.useState;
|
||||
const PremiumAppIconIds = (require(7903) /* metro dependency 7903: AppIconTypes */).PremiumAppIconIds;
|
||||
const PIRATE = PremiumAppIconIds.PIRATE;
|
||||
if (id === PIRATE) {
|
||||
binding2 = env0_6;
|
||||
defaultImport = importDefault(22) /* metro dependency 22 */;
|
||||
r3 = binding2[defaultImport.random(0, binding2.length - 1)]();
|
||||
} else {
|
||||
r3 = icon.name;
|
||||
}
|
||||
const property = env0_3(Reflect.apply(useState, binding, [r3]), 1)[0];
|
||||
const value5 = currentAppIcon === id;
|
||||
const {accessibilityRole,
|
||||
accessibilityState} = (require(3874) /* metro dependency 3874: useA11yRolesNative */).useRadioA11yNative({selected: value5});
|
||||
const BRAND_INVERTED = PremiumAppIconIds.BRAND_INVERTED;
|
||||
if (id !== BRAND_INVERTED) {
|
||||
if (icon.isHidden) {
|
||||
return null;
|
||||
} else {
|
||||
const TableRow = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
|
||||
return (
|
||||
<TableRow
|
||||
icon={((Component) => <Component id={id} style={styles.icon} />)(importDefault(13923) /* metro dependency 13923: AppIcon */)}
|
||||
label={property}
|
||||
onLongPress={function() {
|
||||
return onLongPress(id);
|
||||
}}
|
||||
onPress={onPress_105716}
|
||||
accessibilityRole={accessibilityRole}
|
||||
accessibilityState={accessibilityState}
|
||||
trailing={value5 ? ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio) : isPremium ? hasNitro ? ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio) : null : ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio)}
|
||||
key={id}
|
||||
/>
|
||||
);
|
||||
}
|
||||
} else if (showEasterEgg || value5) {
|
||||
if (icon.isHidden) {
|
||||
return null;
|
||||
} else {
|
||||
const TableRow2 = (require(6238) /* metro dependency 6238: TableRowNative */).TableRow;
|
||||
return (
|
||||
<TableRow2
|
||||
icon={((Component) => <Component id={id} style={styles.icon} />)(importDefault(13923) /* metro dependency 13923: AppIcon */)}
|
||||
label={property}
|
||||
onLongPress={onLongPress_105715}
|
||||
onPress={onPress_105716}
|
||||
accessibilityRole={accessibilityRole}
|
||||
accessibilityState={accessibilityState}
|
||||
trailing={value5 ? ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio) : isPremium ? hasNitro ? ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio) : null : ((FormRadio) => <FormRadio selected={value5} />)((require(7989) /* metro dependency 7989: FormRadioNative */).FormRadio)}
|
||||
key={id}
|
||||
/>
|
||||
);
|
||||
}
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,105 @@
|
||||
/* Metro module 13925; source: modules/app_icons/native/AppIconRows.tsx; dependencies: [57, 31, 27, 1878, 33, 4501, 7903, 6231, 1244, 13926, 12187, 566, 1900, 2] */
|
||||
function _fun105701(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#105701, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14122:6, offset: 0x022c09b9, size: 300 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 */;
|
||||
const env0_5 = (require(27) /* metro dependency 27 */).View;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const env0_7 = (require(31) /* metro dependency 31 */).createElement;
|
||||
const value = require(33) /* metro dependency 33 */;
|
||||
const env0_8 = value.jsx;
|
||||
const env0_9 = value.Fragment;
|
||||
const env0_10 = value.jsxs;
|
||||
const env0_11 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({container: {padding: 16},
|
||||
bottomUpsellPadding: {paddingBottom: 56}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIconRows.tsx');
|
||||
exports.default = AppIconRows;
|
||||
}
|
||||
|
||||
function BackwardsCompatibleAppIconRows(a0) { // fn#105702, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14122:293, offset: 0x022c0ae5, size: 305 bytes, params: 2, frame: 25
|
||||
if (a0 == null) {
|
||||
throwTypeError(a0, "Cannot destructure 'undefined' or 'null'.", undefined);
|
||||
throw undefined;
|
||||
}
|
||||
const value = copyDataProperties({}, a0, undefined, undefined);
|
||||
const env0_3 = undefined;
|
||||
const styles = useStyles();
|
||||
const [env0_1, env0_2] = env0_3(env0_4.useState(false), 2);
|
||||
const icons = value.icons;
|
||||
const title = value.title;
|
||||
const TableRowGroup = (require(6231) /* metro dependency 6231: TableRowGroupNative */).TableRowGroup;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const string = intl.string;
|
||||
const N4YDao = (require(1244) /* metro dependency 1244: indexNative */).t.N4YDao;
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
<TableRowGroup
|
||||
title={title}
|
||||
accessibilityRole="radiogroup"
|
||||
accessibilityLabel={Reflect.apply(string, intl, [N4YDao])}
|
||||
hasIcons
|
||||
>
|
||||
{icons.map(_fun105704)}
|
||||
</TableRowGroup>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function AppIconRows({onSelect}) { // fn#105705, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14122:832, offset: 0x022c0cbf, size: 449 bytes, params: 2, frame: 29
|
||||
var r5;
|
||||
var object2;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const styles = useStyles();
|
||||
const {officialAppIcons, limitedTimeAppIcons,
|
||||
currentAppIcon} = (require(12187) /* metro dependency 12187: AppIconUtils */).useAppIcons();
|
||||
const currentUser = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
|
||||
return UserStore.getCurrentUser();
|
||||
});
|
||||
const isPremium2 = (require(1900) /* metro dependency 1900: PremiumTypeUtils */).isPremium(currentUser);
|
||||
const r14 = limitedTimeAppIcons.length > 0 && limitedTimeAppIcons.filter(function(a0) {
|
||||
return !a0.isHidden;
|
||||
}).length > 0;
|
||||
const jsxRuntimeEnv0_9Binding = jsxRuntimeEnv0_9;
|
||||
if (r14) {
|
||||
r5 = <BackwardsCompatibleAppIconRows hasNitro={isPremium2} icons={limitedTimeAppIcons} currentAppIcon={currentAppIcon} title={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.anqaFd)} onSelect={onSelect} />;
|
||||
} else {
|
||||
r5 = null;
|
||||
}
|
||||
return (
|
||||
<>
|
||||
{r5}
|
||||
<View style={!isPremium2 && styles.bottomUpsellPadding}>
|
||||
<BackwardsCompatibleAppIconRows
|
||||
hasNitro={isPremium2}
|
||||
icons={officialAppIcons}
|
||||
currentAppIcon={currentAppIcon}
|
||||
title={r14 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.Ipxkog) : undefined}
|
||||
onSelect={onSelect}
|
||||
/>
|
||||
</View>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
function BackwardsCompatibleAppIconRowsOnLongPress(a0) { // fn#105703, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14122:423, owner: BackwardsCompatibleAppIconRows.onLongPress, offset: 0x022c0c16, size: 62 bytes, params: 2, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const FreemiumAppIconIds = (require(7903) /* metro dependency 7903: AppIconTypes */).FreemiumAppIconIds;
|
||||
const DEFAULT = FreemiumAppIconIds.DEFAULT;
|
||||
return a0 !== DEFAULT ? null : env0_2(true);
|
||||
}
|
||||
|
||||
function _fun105704(a0) { // fn#105704, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14122:664, offset: 0x022c0c54, size: 107 bytes, params: 2, frame: 17
|
||||
let value = environment.__proto__;
|
||||
const createElementBinding = createElement;
|
||||
value = importDefault(13926) /* metro dependency 13926: AppIconRow */;
|
||||
const object2 = {};
|
||||
copyDataProperties(object2, env0_0, undefined);
|
||||
object2['key'] = a0.id;
|
||||
object2['icon'] = a0;
|
||||
object2['showEasterEgg'] = env0_1;
|
||||
object2['onLongPress'] = BackwardsCompatibleAppIconRowsOnLongPress;
|
||||
return createElementBinding(value, object2);
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,97 @@
|
||||
/* Metro module 15278; source: modules/app_icons/native/AppIconsCoachmark.tsx; dependencies: [31, 27, 1878, 1376, 33, 4501, 697, 566, 3802, 4080, 6275, 15279, 1305, 8619, 4573, 1244, 4578, 12187, 2] */
|
||||
function _fun116873(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#116873, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15475:6, offset: 0x02499143, size: 405 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.Image;
|
||||
const env0_5 = value.View;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const env0_7 = (require(1376) /* metro dependency 1376: DismissibleContentConstants */).ContentDismissActionType;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_8 = value.jsx;
|
||||
const env0_9 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object2 = {};
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.container = {padding: PX_16, paddingBottom: 0};
|
||||
object2.info = {alignItems: 'center'};
|
||||
object2.image = {'alignSelf': 'center', 'marginBottom': 20};
|
||||
object2.nitroWheel = {marginRight: 8};
|
||||
object2.titleContainer = {'display': 'flex', 'flexDirection': 'row', 'alignItems': 'center'};
|
||||
object2.subtitle = {'marginTop': 8, 'textAlign': 'center'};
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object2.footer = {marginTop: 20, gap: PX_8};
|
||||
const env0_10 = Reflect.apply(createStyles, value, [object2]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/AppIconsCoachmark.tsx');
|
||||
exports.default = AppIconsCoachmarkActionSheet;
|
||||
}
|
||||
|
||||
function AppIconsCoachmarkActionSheet({markAsDismissed}) { // fn#116874, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15475:636, offset: 0x024992d8, size: 840 bytes, params: 2, frame: 33
|
||||
const styles = useStyles();
|
||||
const currentUser = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
|
||||
return UserStore.getCurrentUser();
|
||||
});
|
||||
const isPremium2 = (importDefault(3802) /* metro dependency 3802: PremiumUtils */).isPremium(currentUser);
|
||||
const value2 = env0_3.useCallback(function() {
|
||||
importDefault(dependencyMap[9]).hideActionSheet();
|
||||
if (markAsDismissed != null) {
|
||||
markAsDismissed(ContentDismissActionType.DISMISS);
|
||||
}
|
||||
}, [markAsDismissed]);
|
||||
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
const items2 = [<Image source={importDefault(15279) /* metro dependency 15279 */} style={styles.image} />];
|
||||
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
|
||||
const object = {source: importDefault(8619) /* metro dependency 8619 */};
|
||||
const IconSizes = (require(1305) /* metro dependency 1305: native */).IconSizes;
|
||||
const MEDIUM = IconSizes.MEDIUM;
|
||||
object.size = MEDIUM;
|
||||
object.style = styles.nitroWheel;
|
||||
object.disableColor = true;
|
||||
const icon = <Icon {...object} />;
|
||||
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 EfA4Cq = t.EfA4Cq;
|
||||
items2[1] = <View style={styles.titleContainer}>{icon}<Text variant="heading-xl/extrabold" color="mobile-text-heading-primary">{Reflect.apply(string,
|
||||
intl, [EfA4Cq])}</Text></View>;
|
||||
string = intl.string;
|
||||
items2[2] = <Text variant="text-md/normal" color="text-default" style={styles.subtitle}>{isPremium2 ? Reflect.apply(string,
|
||||
intl, [t.IgchKK]) : Reflect.apply(string, intl, [t.D0XzaS])}</Text>;
|
||||
const view = <View style={styles.info}>{items2}</View>;
|
||||
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
string = intl.string;
|
||||
const Pt547C = (require(1244) /* metro dependency 1244: indexNative */).t.Pt547C;
|
||||
return (
|
||||
<BottomSheet
|
||||
onDismiss={function() {
|
||||
return markAsDismissed(ContentDismissActionType.DISMISS);
|
||||
}}
|
||||
contentStyles={styles.container}
|
||||
>
|
||||
{view}
|
||||
<View style={styles.footer}>
|
||||
<Button text={Reflect.apply(string, intl, [Pt547C])} onPress={onPress_116878} />
|
||||
<Button
|
||||
variant="secondary"
|
||||
text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.iSrIIZ)}
|
||||
onPress={value2}
|
||||
/>
|
||||
</View>
|
||||
</BottomSheet>
|
||||
);
|
||||
}
|
||||
|
||||
function AppIconsCoachmarkActionSheetOnPress() { // fn#116878, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15475:1578, owner: AppIconsCoachmarkActionSheet.onPress, offset: 0x02499682, size: 99 bytes, params: 1, frame: 13
|
||||
const value = environment.__proto__;
|
||||
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
|
||||
if (markAsDismissed != null) {
|
||||
markAsDismissed(ContentDismissActionType.PRIMARY);
|
||||
}
|
||||
(require(12187) /* metro dependency 12187: AppIconUtils */).navigateToAppIconSettings();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Metro module 13922; source: modules/app_icons/native/SettingsItemAppIcon.tsx; dependencies: [31, 7902, 33, 4501, 697, 12187, 7903, 8765, 13923, 2] */
|
||||
function _fun105686(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#105686, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14119:6, offset: 0x022bff99, size: 220 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(7902) /* metro dependency 7902: AppIconConstants */).getIconById;
|
||||
const env0_4 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const object = {};
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
const env0_5 = Reflect.apply(createStyles, createStylesModule, [{icon: object}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_icons/native/SettingsItemAppIcon.tsx');
|
||||
exports.default = SettingsItemAppIcon;
|
||||
}
|
||||
|
||||
function SettingsItemAppIcon({color = importDefault(dependencyMap[4]).colors.INTERACTIVE_ICON_DEFAULT}) { // fn#105687, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14119:298, offset: 0x022c0075, size: 230 bytes, params: 2, frame: 18
|
||||
var r0;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
const value2 = (require(12187) /* metro dependency 12187: AppIconUtils */).useCurrentAppIcon();
|
||||
const iconById = getIconById(value2);
|
||||
const FreemiumAppIconIds = (require(7903) /* metro dependency 7903: AppIconTypes */).FreemiumAppIconIds;
|
||||
const DEFAULT = FreemiumAppIconIds.DEFAULT;
|
||||
if (value2 === DEFAULT) {
|
||||
const ClydeIcon = (require(8765) /* metro dependency 8765: ClydeIcon */).ClydeIcon;
|
||||
r0 = <ClydeIcon color={color} />;
|
||||
} else if (iconById == null) {
|
||||
const ClydeIcon2 = (require(8765) /* metro dependency 8765: ClydeIcon */).ClydeIcon;
|
||||
r0 = <ClydeIcon2 color={color} />;
|
||||
} else {
|
||||
value = importDefault(13923) /* metro dependency 13923: AppIcon */;
|
||||
value = ((Component) => <Component style={styles.icon} id={value2} size={32} />)(value);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user