Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,289 @@
|
||||
/* Metro module 2256; source: modules/premium/powerups/GuildPowerups.messages.js; dependencies: [1247, 2257, 2258, 2259, 2260, 2261, 2262, 2263, 2264, 2265, 2266, 2267, 2268, 2269, 2270, 2271, 2272, 2273, 2274, 2275, 2276, 2277, 2278, 2279, 2280, 2281, 2282, 2283, 2284, 2285, 2286, 2287, 1282, 2] */
|
||||
function _fun22728(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#22728, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:6, offset: 0x00f0561a, size: 453 bytes, params: 8, frame: 19
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
object2 = {bg: bg_22729, cs: cs_22731, da: da_22733, de: de_22735, el: el_22737};
|
||||
object2['en-GB'] = _fun22739;
|
||||
object2['es-419'] = _fun22741;
|
||||
object2['es-ES'] = _fun22743;
|
||||
object2.fi = fi_22745;
|
||||
object2.fr = fr_22747;
|
||||
object2.hi = hi_22749;
|
||||
object2.hr = hr_22751;
|
||||
object2.hu = hu_22753;
|
||||
object2.it = it_22755;
|
||||
object2.ja = ja_22757;
|
||||
object2.ko = ko_22759;
|
||||
object2.lt = lt_22761;
|
||||
object2.nl = nl_22763;
|
||||
object2.no = no_22765;
|
||||
object2.pl = pl_22767;
|
||||
object2['pt-BR'] = _fun22769;
|
||||
object2.ro = ro_22771;
|
||||
object2.ru = ru_22773;
|
||||
object2['sv-SE'] = _fun22775;
|
||||
object2.th = th_22777;
|
||||
object2.tr = tr_22779;
|
||||
object2.uk = uk_22781;
|
||||
object2.vi = vi_22783;
|
||||
object2['zh-CN'] = _fun22785;
|
||||
object2['zh-TW'] = _fun22787;
|
||||
object2['en-US'] = _fun22789;
|
||||
let value = require(1282) /* metro dependency 1282 */;
|
||||
value = value.createLoader(object2, 'en-US');
|
||||
const messagesProxy = (require(1282) /* metro dependency 1282 */).makeMessagesProxy(value);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/GuildPowerups.messages.js');
|
||||
exports.default = messagesProxy;
|
||||
exports.messagesLoader = value;
|
||||
}
|
||||
|
||||
function bg_22729() { // fn#22729, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:102, offset: 0x00f057df, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2257) /* metro dependency 2257 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function cs_22731() { // fn#22731, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:165, offset: 0x00f05820, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2258) /* metro dependency 2258 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function da_22733() { // fn#22733, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:228, offset: 0x00f05861, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2259) /* metro dependency 2259 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function de_22735() { // fn#22735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:291, offset: 0x00f058a2, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2260) /* metro dependency 2260 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function el_22737() { // fn#22737, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:354, offset: 0x00f058e3, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2261) /* metro dependency 2261 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22739() { // fn#22739, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:422, offset: 0x00f05924, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2262) /* metro dependency 2262 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22741() { // fn#22741, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:491, offset: 0x00f05965, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2263) /* metro dependency 2263 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22743() { // fn#22743, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:559, offset: 0x00f059a6, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2264) /* metro dependency 2264 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function fi_22745() { // fn#22745, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:622, offset: 0x00f059e7, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2265) /* metro dependency 2265 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function fr_22747() { // fn#22747, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:685, offset: 0x00f05a28, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2266) /* metro dependency 2266 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function hi_22749() { // fn#22749, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:749, offset: 0x00f05a69, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2267) /* metro dependency 2267 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function hr_22751() { // fn#22751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:813, offset: 0x00f05aaa, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2268) /* metro dependency 2268 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function hu_22753() { // fn#22753, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:877, offset: 0x00f05aeb, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2269) /* metro dependency 2269 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function it_22755() { // fn#22755, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:941, offset: 0x00f05b2c, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2270) /* metro dependency 2270 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function ja_22757() { // fn#22757, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1005, offset: 0x00f05b6d, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2271) /* metro dependency 2271 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function ko_22759() { // fn#22759, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1069, offset: 0x00f05bae, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2272) /* metro dependency 2272 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function lt_22761() { // fn#22761, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1133, offset: 0x00f05bef, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2273) /* metro dependency 2273 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function nl_22763() { // fn#22763, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1197, offset: 0x00f05c30, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2274) /* metro dependency 2274 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function no_22765() { // fn#22765, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1261, offset: 0x00f05c71, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2275) /* metro dependency 2275 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function pl_22767() { // fn#22767, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1325, offset: 0x00f05cb2, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2276) /* metro dependency 2276 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22769() { // fn#22769, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1394, offset: 0x00f05cf3, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2277) /* metro dependency 2277 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function ro_22771() { // fn#22771, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1458, offset: 0x00f05d34, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2278) /* metro dependency 2278 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function ru_22773() { // fn#22773, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1522, offset: 0x00f05d75, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2279) /* metro dependency 2279 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22775() { // fn#22775, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1591, offset: 0x00f05db6, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2280) /* metro dependency 2280 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function th_22777() { // fn#22777, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1655, offset: 0x00f05df7, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2281) /* metro dependency 2281 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function tr_22779() { // fn#22779, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1719, offset: 0x00f05e38, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2282) /* metro dependency 2282 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function uk_22781() { // fn#22781, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1783, offset: 0x00f05e79, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2283) /* metro dependency 2283 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function vi_22783() { // fn#22783, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1847, offset: 0x00f05eba, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2284) /* metro dependency 2284 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22785() { // fn#22785, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1916, offset: 0x00f05efb, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2285) /* metro dependency 2285 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22787() { // fn#22787, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:1985, offset: 0x00f05f3c, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2286) /* metro dependency 2286 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
function _fun22789() { // fn#22789, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:2383:2054, offset: 0x00f05f7d, size: 65 bytes, params: 1, frame: 14
|
||||
let value = require(1247) /* metro dependency 1247: AssetJsonUtils */;
|
||||
value = value.loadJsonAsset(require(2287) /* metro dependency 2287 */);
|
||||
return value.then(function(a0) {
|
||||
return {default: a0};
|
||||
});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,155 @@
|
||||
/* Metro module 12307; source: modules/premium/powerups/GuildPowerupsActionCreators.tsx; dependencies: [8259, 661, 694, 12308, 4141, 12309, 1360, 507, 2] */
|
||||
function _fun93980(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93980, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:6, offset: 0x020cd830, size: 221 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_3 = guildPowerupsConstantsModule.GUILD_POWERUP_APPLICATION_ID;
|
||||
const env0_4 = guildPowerupsConstantsModule.GuildPowerupType;
|
||||
const env0_5 = (require(661) /* metro dependency 661: Constants */).Endpoints;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/GuildPowerupsActionCreators.tsx');
|
||||
exports.guildPowerupsAckNotification = guildPowerupsAckNotification;
|
||||
exports.guildPowerupsResetNotifications = guildPowerupsResetNotifications;
|
||||
exports.fetchPowerupCatalogForGuild = fetchPowerupCatalogForGuild;
|
||||
exports.fetchGuildBoostEntitlements = fetchGuildBoostEntitlements;
|
||||
exports.enablePowerupForGuild = function(a0, a1) {
|
||||
var HTTP = require(dependencyMap[7]).HTTP;
|
||||
var object = {};
|
||||
object.url = Endpoints.GUILD_POWERUP_TOGGLE(a0, a1);
|
||||
object.rejectWithError = true;
|
||||
return HTTP.post(object);
|
||||
};
|
||||
exports.disablePowerupForGuild = function(a0, a1) {
|
||||
var HTTP = require(dependencyMap[7]).HTTP;
|
||||
var object = {};
|
||||
object.url = Endpoints.GUILD_POWERUP_TOGGLE(a0, a1);
|
||||
object.rejectWithError = true;
|
||||
return HTTP.del(object);
|
||||
};
|
||||
}
|
||||
|
||||
function guildPowerupsAckNotification(a0) { // fn#93981, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:302, offset: 0x020cd90d, size: 56 bytes, params: 2, frame: 13
|
||||
(importDefault(694) /* metro dependency 694: Dispatcher */).dispatch({type: 'GUILD_POWERUPS_ACK_NOTIFICATION',
|
||||
guildId: a0});
|
||||
}
|
||||
|
||||
function guildPowerupsResetNotifications() { // fn#93982, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:447, offset: 0x020cd945, size: 49 bytes, params: 1, frame: 13
|
||||
(importDefault(694) /* metro dependency 694: Dispatcher */).dispatch({type: 'GUILD_POWERUPS_RESET_NOTIFICATIONS'});
|
||||
}
|
||||
|
||||
function fetchPowerupCatalogForGuild(a0, a1) { // fn#93983, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:583, offset: 0x020cd976, size: 327 bytes, params: 3, frame: 21
|
||||
var value;
|
||||
var object2;
|
||||
const MOCK_LEVELS = (require(12308) /* metro dependency 12308: GuildPowerupMocks */).MOCK_LEVELS;
|
||||
const MOCK_PERKS = (require(12308) /* metro dependency 12308: GuildPowerupMocks */).MOCK_PERKS;
|
||||
var value2;
|
||||
var dispatch;
|
||||
var object4;
|
||||
const env0_0 = a0;
|
||||
if (a1 === true) {
|
||||
value2 = MOCK_LEVELS.concat(MOCK_PERKS);
|
||||
object2 = {};
|
||||
object2[GuildPowerupType.LEVEL] = MOCK_LEVELS;
|
||||
object2[GuildPowerupType.PERK] = MOCK_PERKS;
|
||||
value = importDefault(694) /* metro dependency 694: Dispatcher */;
|
||||
dispatch = value.dispatch;
|
||||
object4 = {type: 'GUILD_POWERUP_CATALOG_FETCH_SUCCESS', guildId: a0};
|
||||
object4.allPowerups = value2.sort(function({skuId}, a1) {
|
||||
return skuId >= a1.skuId ? 1 : -1;
|
||||
}).reduce(_fun93985, {});
|
||||
object4.powerupCatalog = object2;
|
||||
Reflect.apply(dispatch, value, [object4]);
|
||||
return undefined;
|
||||
}
|
||||
const storeUtilsModule = require(4141) /* metro dependency 4141: StoreUtils */;
|
||||
const httpGetWithCountryCodeQuery = storeUtilsModule.httpGetWithCountryCodeQuery;
|
||||
const STORE_PUBLISHED_LISTINGS_SKUS = Endpoints.STORE_PUBLISHED_LISTINGS_SKUS;
|
||||
return Reflect.apply(httpGetWithCountryCodeQuery, storeUtilsModule, [{url: STORE_PUBLISHED_LISTINGS_SKUS,
|
||||
query: {application_id: GUILD_POWERUP_APPLICATION_ID, guild_id: a0}, oldFormErrors: true,
|
||||
rejectWithError: false}]).then(_fun93986);
|
||||
}
|
||||
|
||||
function fetchGuildBoostEntitlements(a0) { // fn#93990, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:1596, offset: 0x020cdc4a, size: 121 bytes, params: 2, frame: 16
|
||||
const value = a1;
|
||||
const env0_0 = a0;
|
||||
const r5 = !(value !== undefined) || value;
|
||||
const storeUtilsModule = require(4141) /* metro dependency 4141: StoreUtils */;
|
||||
const httpGetWithCountryCodeQuery = storeUtilsModule.httpGetWithCountryCodeQuery;
|
||||
const object2 = {};
|
||||
object2.url = Endpoints.GUILD_POWERUPS(a0);
|
||||
object2.query = {include_ends_at: r5};
|
||||
object2.oldFormErrors = true;
|
||||
object2.rejectWithError = false;
|
||||
return Reflect.apply(httpGetWithCountryCodeQuery, storeUtilsModule, [object2]).then(_fun93991);
|
||||
}
|
||||
|
||||
function _fun93985(a0, a1) { // fn#93985, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:896, offset: 0x020cdadf, size: 17 bytes, params: 3, frame: 3
|
||||
a0[a1.skuId] = a1;
|
||||
return a0;
|
||||
}
|
||||
|
||||
function _fun93986(a0) { // fn#93986, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:1104, offset: 0x020cdaf0, size: 203 bytes, params: 2, frame: 18
|
||||
const env0_0 = a0;
|
||||
let value = a0.body.map(_fun93987);
|
||||
value = value.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish);
|
||||
value = value.sort(function({skuId}, a1) {
|
||||
return skuId >= a1.skuId ? 1 : -1;
|
||||
});
|
||||
value = value.reduce(function(a0, a1) {
|
||||
var property = a0.allPowerups;
|
||||
var powerupCatalog = a0.powerupCatalog;
|
||||
property[a1.skuId] = a1;
|
||||
if (powerupCatalog[a1.type] == null) {
|
||||
powerupCatalog[a1.type] = [];
|
||||
}
|
||||
property = powerupCatalog[a1.type];
|
||||
if (!(property == null || property.push == null)) {
|
||||
property.push(a1);
|
||||
}
|
||||
return a0;
|
||||
}, {allPowerups: {}, powerupCatalog: {}});
|
||||
(importDefault(694) /* metro dependency 694: Dispatcher */).dispatch({type: 'GUILD_POWERUP_CATALOG_FETCH_SUCCESS',
|
||||
guildId: env0_0, allPowerups: value.allPowerups, powerupCatalog: value.powerupCatalog});
|
||||
return a0.body;
|
||||
}
|
||||
|
||||
function _fun93991({body}) { // fn#93991, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:1779, offset: 0x020cdcc3, size: 107 bytes, params: 2, frame: 15
|
||||
var environment;
|
||||
const object2 = {};
|
||||
const env0_0 = object2;
|
||||
body.forEach(_fun93992);
|
||||
const value = environment.__proto__;
|
||||
(importDefault(694) /* metro dependency 694: Dispatcher */).dispatch({type: 'GUILD_BOOST_ENTITLEMENTS_FETCH_SUCCESS',
|
||||
guildId: env0_0, unlockedPowerups: object2, unlockedGameServers: {}});
|
||||
}
|
||||
|
||||
function _fun93987(a0) { // fn#93987, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:1126, offset: 0x020cdbbb, size: 48 bytes, params: 2, frame: 13
|
||||
const value = environment.__proto__.__proto__;
|
||||
return (importDefault(12309) /* metro dependency 12309: storeListingToGuildPowerup */)(env0_0.body, a0);
|
||||
}
|
||||
|
||||
function _fun93992(a0) { // fn#93992, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12493:1813, offset: 0x020cdd2e, size: 188 bytes, params: 2, frame: 6
|
||||
var powerup_metadata;
|
||||
let sku = a0.sku;
|
||||
const value = undefined;
|
||||
if ((sku == null || sku.tenant_metadata == null || sku.tenant_metadata.guild_monetization == null ? value : sku.tenant_metadata.guild_monetization.powerup) != null) {
|
||||
env0_0[a0.sku_id] = a0;
|
||||
} else {
|
||||
if (a0 == null) {
|
||||
powerup_metadata = value;
|
||||
} else {
|
||||
sku = a0.sku;
|
||||
powerup_metadata = sku == null ? value : sku.powerup_metadata;
|
||||
}
|
||||
if (powerup_metadata != null) {
|
||||
env0_0[a0.sku_id] = a0;
|
||||
} else {
|
||||
sku = a0.sku;
|
||||
if ((sku == null || sku.tenant_metadata == null || sku.tenant_metadata.guild_monetization == null ? value : sku.tenant_metadata.guild_monetization.game_server) != null) {
|
||||
env0_1[a0.id] = a0;
|
||||
}
|
||||
}
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,180 @@
|
||||
/* Metro module 15721; source: modules/premium/powerups/GuildPowerupsManager.tsx; dependencies: [6, 7, 15, 17, 18, 1867, 3784, 3969, 8258, 6892, 6857, 8262, 8263, 8264, 14618, 14614, 14616, 12310, 15722, 4140, 12307, 14675, 8251, 4860, 2] */
|
||||
function _fun120722(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120722, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:6, offset: 0x02533f09, size: 294 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(6) /* metro dependency 6 */;
|
||||
const env0_4 = importDefault(7) /* metro dependency 7 */;
|
||||
const env0_5 = importDefault(15) /* metro dependency 15 */;
|
||||
const env0_6 = importDefault(17) /* metro dependency 17 */;
|
||||
const env0_7 = importDefault(18) /* metro dependency 18 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const permissionStore = importDefault(3784) /* metro dependency 3784: PermissionStore */;
|
||||
const selectedGuildStore = importDefault(3969) /* metro dependency 3969: SelectedGuildStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
let value = importDefault(4860) /* metro dependency 4860: AutomaticLifecycleManager */;
|
||||
value = _fun120726(value);
|
||||
value = new value();
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/GuildPowerupsManager.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_120723() { // fn#120723, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:188, offset: 0x0253402f, 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_120723_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function _fun120726(a0) { // fn#120726, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:391, offset: 0x02534091, size: 151 bytes, params: 2, frame: 16
|
||||
const closure = GuildPowerupsManager;
|
||||
env0_7(closure, a0);
|
||||
return env0_4(closure, [{key: 'handleSelectedGuildChange', value: value_120728}, {key: 'handleEntitlementUpdate',
|
||||
value: function({guildId}) {
|
||||
this.refreshGuildPowerups(guildId);
|
||||
}}, {key: 'handleAppliedBoostUpdate', value: function({guildId}) {
|
||||
this.refreshGuildPowerups(guildId);
|
||||
}}, {key: 'refreshGuildPowerups', value: value_120731}]);
|
||||
}
|
||||
|
||||
function GuildPowerupsManager(a0) { // fn#120727, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:403, offset: 0x02534128, size: 258 bytes, params: 2, frame: 20
|
||||
var r0;
|
||||
var Reflect;
|
||||
let value = copyRestArgs(0, undefined);
|
||||
let binding = env1_3;
|
||||
binding(this, GuildPowerupsManager);
|
||||
let object = [];
|
||||
arraySpread(object, value, 0, object);
|
||||
value = env1_6(GuildPowerupsManager);
|
||||
binding = env1_5;
|
||||
if (_isNativeReflectConstruct_120723()) {
|
||||
Reflect = global.Reflect;
|
||||
value = Reflect.construct(value, object, env1_6(this).constructor);
|
||||
r0 = value;
|
||||
} else {
|
||||
value = value.apply(this, object);
|
||||
r0 = value;
|
||||
}
|
||||
value = binding(this, r0);
|
||||
const Map = global.Map;
|
||||
const map = new Map();
|
||||
value.stores = map.set(SelectedGuildStore, value.handleSelectedGuildChange);
|
||||
object = {};
|
||||
object.GUILD_POWERUP_ENTITLEMENTS_CREATE = value.handleEntitlementUpdate.bind(value);
|
||||
object.GUILD_POWERUP_ENTITLEMENTS_DELETE = value.handleEntitlementUpdate.bind(value);
|
||||
object.GUILD_APPLIED_BOOSTS_UPDATE = value.handleAppliedBoostUpdate.bind(value);
|
||||
value.actions = object;
|
||||
return value;
|
||||
}
|
||||
|
||||
function value_120728() { // fn#120728, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:1012, offset: 0x0253422a, size: 646 bytes, params: 1, frame: 21
|
||||
const value = environment.__proto__;
|
||||
const guildId = SelectedGuildStore.getGuildId();
|
||||
if (guildId != null) {
|
||||
var moduleValue = require(6892) /* metro dependency 6892: FavoritesUtils */;
|
||||
if (moduleValue.isFavoritesGuildId(guildId)) {
|
||||
return undefined;
|
||||
}
|
||||
var guild = GuildStore.getGuild(guildId);
|
||||
if (guild == null) {
|
||||
return undefined;
|
||||
}
|
||||
var GameServerExperiment = (require(6857) /* metro dependency 6857: GameServerExperiment */).GameServerExperiment;
|
||||
var trackExposure = GameServerExperiment.trackExposure;
|
||||
var id = guild.id;
|
||||
Reflect.apply(trackExposure, GameServerExperiment, [{guildId: id, location: 'GuildPowerupsManager'}]);
|
||||
var FileUpload250MbPowerupExperiment = (require(8262) /* metro dependency 8262: FileUpload250MbPowerupExperiment */).FileUpload250MbPowerupExperiment;
|
||||
trackExposure = FileUpload250MbPowerupExperiment.trackExposure;
|
||||
id = guild.id;
|
||||
Reflect.apply(trackExposure, FileUpload250MbPowerupExperiment, [{guildId: id,
|
||||
location: 'GuildPowerupsManager'}]);
|
||||
var ServerThemeExperiment = (require(8263) /* metro dependency 8263: ServerThemeExperiment */).ServerThemeExperiment;
|
||||
trackExposure = ServerThemeExperiment.trackExposure;
|
||||
id = guild.id;
|
||||
Reflect.apply(trackExposure, ServerThemeExperiment, [{guildId: id, location: 'GuildPowerupsManager'}]);
|
||||
var ServerThemeApexShadowExperiment = (require(8264) /* metro dependency 8264: ServerThemeApexShadowExperiment */).ServerThemeApexShadowExperiment;
|
||||
var getConfig = ServerThemeApexShadowExperiment.getConfig;
|
||||
id = guild.id;
|
||||
Reflect.apply(getConfig, ServerThemeApexShadowExperiment, [{guildId: id, location: 'GuildPowerupsManager'}]);
|
||||
var moduleValue2 = require(6857) /* metro dependency 6857: GameServerExperiment */;
|
||||
var getGameServerEnabled = moduleValue2.getGameServerEnabled;
|
||||
id = guild.id;
|
||||
if (Reflect.apply(getGameServerEnabled, moduleValue2, [id, 'GuildPowerupsManager'])) {
|
||||
(require(14618) /* metro dependency 14618: GameServerPricingExperiment */).GameServerPricingExperiment.trackExposure({guildId: guild.id,
|
||||
|
||||
|
||||
location: 'GuildPowerupsManager'});
|
||||
}
|
||||
var defaultImport = importDefault(14614) /* metro dependency 14614: BoostToUnlockCoachmarkExperiment */;
|
||||
getConfig = defaultImport.getConfig;
|
||||
var enabled = Reflect.apply(getConfig, defaultImport, [{location: 'GuildPowerupsManager'}]).enabled;
|
||||
var defaultImport2 = importDefault(14616) /* metro dependency 14616: ExpiringPowerupCoachmarkExperiment */;
|
||||
getConfig = defaultImport2.getConfig;
|
||||
var enabled2 = Reflect.apply(getConfig, defaultImport2, [{location: 'GuildPowerupsManager'}]).enabled;
|
||||
var moduleValue3 = require(12310) /* metro dependency 12310: useHasAllocateBoostPermission */;
|
||||
var getHasAllocateBoostPermission = moduleValue3.getHasAllocateBoostPermission;
|
||||
if (Reflect.apply(getHasAllocateBoostPermission, moduleValue3, [PermissionStore, guild])) {
|
||||
if (GuildPowerupsStore.shouldFetchCatalogForGuild(guildId)) {
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchPowerupCatalogForGuild(guildId);
|
||||
}
|
||||
if (GuildPowerupsStore.shouldFetchPowerupsForGuild(guildId)) {
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchGuildBoostEntitlements(guildId);
|
||||
}
|
||||
return undefined;
|
||||
}
|
||||
var r1 = enabled || enabled2;
|
||||
r1 = r1 && (require(15722) /* metro dependency 15722: useIsCurrentUserEligibleForPowerupUpsells */).getIsCurrentUserEligibleForPowerupUpsells();
|
||||
if ((require(4140) /* metro dependency 4140: PlatformUtils */).isMobile) {
|
||||
return undefined;
|
||||
}
|
||||
if (r1) {
|
||||
if (GuildPowerupsStore.shouldFetchCatalogForGuild(guildId)) {
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchPowerupCatalogForGuild(guildId);
|
||||
}
|
||||
if (GuildPowerupsStore.shouldFetchPowerupsForGuild(guildId)) {
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchGuildBoostEntitlements(guildId);
|
||||
}
|
||||
return undefined;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function value_120731(a0) { // fn#120731, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15929:2313, offset: 0x025344ca, size: 173 bytes, params: 2, frame: 17
|
||||
var enabled;
|
||||
let value = environment.__proto__;
|
||||
const useHasAllocateBoostPermissionModule = require(12310) /* metro dependency 12310: useHasAllocateBoostPermission */;
|
||||
const getHasAllocateBoostPermission = useHasAllocateBoostPermissionModule.getHasAllocateBoostPermission;
|
||||
const getGuild = GuildStore.getGuild;
|
||||
if (Reflect.apply(getHasAllocateBoostPermission, useHasAllocateBoostPermissionModule, [PermissionStore,
|
||||
Reflect.apply(getGuild, GuildStore, [a0])]) === true) {
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchGuildBoostEntitlements(a0);
|
||||
value = importDefault(14675) /* metro dependency 14675: ExpiringBoostsExperiment */;
|
||||
enabled = value.getConfig({location: 'GuildPowerupsManager'}).enabled;
|
||||
value = require(8251) /* metro dependency 8251: BoostingActionCreators */;
|
||||
value.fetchAppliedGuildBoostsForGuild(a0, {includeEnded: enabled});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,151 @@
|
||||
/* Metro module 14608; source: modules/premium/powerups/GuildPowerupsNotificationStore.tsx; dependencies: [6, 7, 15, 17, 18, 1867, 8255, 8258, 14609, 566, 694, 2] */
|
||||
function _fun110465(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110465, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:6, offset: 0x0237abaa, size: 370 bytes, params: 8, frame: 19
|
||||
let env0_0 = require;
|
||||
let Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importDefault(6) /* metro dependency 6 */;
|
||||
const env0_3 = importDefault(7) /* metro dependency 7 */;
|
||||
const env0_4 = importDefault(15) /* metro dependency 15 */;
|
||||
const env0_5 = importDefault(17) /* metro dependency 17 */;
|
||||
const env0_6 = importDefault(18) /* metro dependency 18 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const gameServerStore = importDefault(8255) /* metro dependency 8255: GameServerStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
let env0_10 = {};
|
||||
const PersistedStore = (importDefault(566) /* metro dependency 566: flux */).PersistedStore;
|
||||
let value = _fun110469(PersistedStore);
|
||||
value.displayName = 'GuildPowerupsNotificationStore';
|
||||
value.persistKey = 'GuildPowerupsNotificationStore';
|
||||
value.migrations = [function(a0) {
|
||||
var env0_0 = a0;
|
||||
var Object = global.Object;
|
||||
Object.entries(a0).forEach(_fun110475);
|
||||
return a0;
|
||||
}];
|
||||
value = new value(importDefault(694) /* metro dependency 694: Dispatcher */,
|
||||
{GUILD_POWERUPS_ACK_NOTIFICATION: GUILD_POWERUPS_ACK_NOTIFICATION,
|
||||
GUILD_POWERUPS_RESET_NOTIFICATIONS: function() {
|
||||
env0_10 = {};
|
||||
}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/GuildPowerupsNotificationStore.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_110466() { // fn#110466, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:178, offset: 0x0237ad1c, 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_110466_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function _fun110469(a0) { // fn#110469, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:386, offset: 0x0237ad7e, size: 124 bytes, params: 2, frame: 16
|
||||
const closure = GuildPowerupsNotificationStore;
|
||||
env0_6(closure, a0);
|
||||
return env0_3(closure, [{key: 'getState', value: value_110471}, {key: 'initialize', value: function(a0) {
|
||||
this.waitFor(GameServerStore, GuildPowerupsStore, GuildStore);
|
||||
if (a0 != null) {
|
||||
env1_10 = a0;
|
||||
}
|
||||
}}, {key: 'getNotificationStateForGuild', value: value_110473}]);
|
||||
}
|
||||
|
||||
function _fun110474(a0) { // fn#110474, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:1061, offset: 0x0237ae2a, size: 47 bytes, params: 2, frame: 12
|
||||
const env0_0 = a0;
|
||||
const Object = global.Object;
|
||||
Object.entries(a0).forEach(_fun110475);
|
||||
return a0;
|
||||
}
|
||||
|
||||
function GUILD_POWERUPS_ACK_NOTIFICATION({guildId}) { // fn#110476, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:1170, offset: 0x0237aea5, size: 342 bytes, params: 2, frame: 25
|
||||
const r5 = GuildStore.getGuild(guildId)?.premiumSubscriberCount ?? 0;
|
||||
const stateForGuild = GuildPowerupsStore.getStateForGuild(guildId);
|
||||
const stateForGuild2 = GameServerStore.getStateForGuild(guildId);
|
||||
const getExpiringGuildEntitlementsModule = require(14609) /* metro dependency 14609: getExpiringGuildEntitlements */;
|
||||
const getExpiringGuildEntitlements = getExpiringGuildEntitlementsModule.getExpiringGuildEntitlements;
|
||||
let Object = global.Object;
|
||||
let values = Object.values;
|
||||
const value7 = stateForGuild == null;
|
||||
const value8 = Reflect.apply(values, Object, [(value7 ? undefined : stateForGuild.unlockedPowerups) ?? ({})]);
|
||||
let object = [];
|
||||
const value9 = arraySpread(object, value8, 0, value7);
|
||||
Object = global.Object;
|
||||
values = Object.values;
|
||||
const value10 = stateForGuild2 == null;
|
||||
arraySpread(object, Reflect.apply(values, Object, [(value10 ? undefined : stateForGuild2.entitlements) ?? ({})]),
|
||||
value9, value10);
|
||||
const value11 = Reflect.apply(getExpiringGuildEntitlements, getExpiringGuildEntitlementsModule, [object]);
|
||||
object = {};
|
||||
copyDataProperties(object, env0_10, value9);
|
||||
const object2 = {};
|
||||
const Date = global.Date;
|
||||
const r6 = value11[value11.length - 1]?.ends_at ?? global.Date.now();
|
||||
const value13 = Object.create(Date.prototype, {constructor: {value: Date}});
|
||||
const date = new Date();
|
||||
object2.lastSeenWarningNotification = (date instanceof Object ? date : value13).getTime();
|
||||
object2.lastBoostCount = r5;
|
||||
object[guildId] = object2;
|
||||
}
|
||||
|
||||
function _fun110475(a0) { // fn#110475, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14805:1092, offset: 0x0237ae59, size: 76 bytes, params: 2, frame: 8
|
||||
var r1;
|
||||
var r2;
|
||||
var r4;
|
||||
var item3;
|
||||
var value3;
|
||||
const iterator = a0[Symbol.iterator]();
|
||||
const iterator2 = iterator.next;
|
||||
let item2 = Reflect.apply(iterator2, iterator, []);
|
||||
let item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
const value = undefined;
|
||||
const value2 = item2 === value;
|
||||
const r3 = value2 ? value : item;
|
||||
if (value2) {
|
||||
r1 = item2;
|
||||
r2 = value;
|
||||
r4 = value2;
|
||||
} else {
|
||||
item3 = Reflect.apply(iterator2, item2, []);
|
||||
item = item3.value;
|
||||
item3 = item3.done ? undefined : item2;
|
||||
value3 = item3 === value;
|
||||
if (value3) {
|
||||
r1 = item3;
|
||||
r2 = value;
|
||||
r4 = value3;
|
||||
} else {
|
||||
r1 = item3;
|
||||
r2 = item;
|
||||
r4 = value3;
|
||||
}
|
||||
}
|
||||
if (!r4) {
|
||||
r1.return();
|
||||
}
|
||||
env0_0[r3] = r2;
|
||||
return value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,465 @@
|
||||
/* Metro module 8258; source: modules/premium/powerups/GuildPowerupsStore.tsx; dependencies: [6, 7, 15, 17, 18, 57, 1867, 8259, 661, 566, 694, 2] */
|
||||
function _fun66058(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66058, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:6, offset: 0x01bea02c, size: 501 bytes, params: 8, frame: 19
|
||||
let Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_0 = importDefault(6) /* metro dependency 6 */;
|
||||
const env0_1 = importDefault(7) /* metro dependency 7 */;
|
||||
const env0_2 = importDefault(15) /* metro dependency 15 */;
|
||||
const env0_3 = importDefault(17) /* metro dependency 17 */;
|
||||
const env0_4 = importDefault(18) /* metro dependency 18 */;
|
||||
const env0_5 = importDefault(57) /* metro dependency 57 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const env0_7 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).PURCHASABLE_PREMIUM_FEATURES_BOOST_INFO;
|
||||
let value = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_8 = value.AppliedGuildBoostsRequiredForBoostedGuildTier;
|
||||
const env0_9 = value.BoostedGuildTiers;
|
||||
const env0_10 = value.GuildFeatures;
|
||||
let env0_11 = {};
|
||||
const PersistedStore = (importDefault(566) /* metro dependency 566: flux */).PersistedStore;
|
||||
value = _fun66066(PersistedStore);
|
||||
value.displayName = 'GuildPowerupsStore';
|
||||
value.persistKey = 'GuildPowerupsStore';
|
||||
value.migrations = [function(a0) {
|
||||
var r0;
|
||||
var Object;
|
||||
var value = a0;
|
||||
if (value == null) {
|
||||
r0 = value;
|
||||
} else {
|
||||
Object = global.Object;
|
||||
value = global.Object.entries(value);
|
||||
value = value.filter(_fun66076);
|
||||
value = Object.fromEntries(value.map(_fun66077));
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}];
|
||||
value = new value(importDefault(694) /* metro dependency 694: Dispatcher */, {LOGOUT: function() {
|
||||
env0_11 = {};
|
||||
}, GUILD_POWERUP_CATALOG_FETCH_SUCCESS: GUILD_POWERUP_CATALOG_FETCH_SUCCESS,
|
||||
GUILD_BOOST_ENTITLEMENTS_FETCH_SUCCESS: GUILD_BOOST_ENTITLEMENTS_FETCH_SUCCESS_66080,
|
||||
GUILD_POWERUP_ENTITLEMENTS_CREATE: function(a0) {
|
||||
recalculateState(a0, true);
|
||||
}, GUILD_POWERUP_ENTITLEMENTS_DELETE: function(a0) {
|
||||
recalculateState(a0, false);
|
||||
}, GUILD_UPDATE: GUILD_UPDATE_66083,
|
||||
GAME_SERVER_FETCH_INSTANCES_SUCCESS: GAME_SERVER_FETCH_INSTANCES_SUCCESS_66084});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/GuildPowerupsStore.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_66059() { // fn#66059, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:318, offset: 0x01bea221, 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_66059_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function calculateAppliedBoosts(a0) { // fn#66062, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:520, offset: 0x01bea283, size: 343 bytes, params: 2, frame: 28
|
||||
var r2;
|
||||
var premiumTier;
|
||||
var r0;
|
||||
var r3;
|
||||
var r4;
|
||||
var r5;
|
||||
var r16;
|
||||
var r15;
|
||||
var r17;
|
||||
var features;
|
||||
var property;
|
||||
var value7;
|
||||
var property2;
|
||||
var value8;
|
||||
var premiumFeatures;
|
||||
var value9;
|
||||
var value10;
|
||||
var isEnabled;
|
||||
var isEnabled2;
|
||||
var value11;
|
||||
var includedInLevel;
|
||||
var value12;
|
||||
var value13;
|
||||
var boostPrice;
|
||||
var value14;
|
||||
var value15;
|
||||
const guild = GuildStore.getGuild(a0);
|
||||
const value3 = undefined;
|
||||
if (guild == null) {
|
||||
r2 = value3;
|
||||
} else {
|
||||
features = guild.features;
|
||||
r2 = features.has(GuildFeatures.PREMIUM_TIER_3_OVERRIDE);
|
||||
}
|
||||
const value5 = 0;
|
||||
if (r2 === true) {
|
||||
r0 = value5;
|
||||
} else {
|
||||
premiumTier = guild == null ? value3 : guild.premiumTier;
|
||||
property = AppliedGuildBoostsRequiredForBoostedGuildTier[premiumTier ?? BoostedGuildTiers.NONE];
|
||||
r0 = property;
|
||||
}
|
||||
const Object = global.Object;
|
||||
const value6 = Object.entries(PURCHASABLE_PREMIUM_FEATURES_BOOST_INFO);
|
||||
let length = value6.length;
|
||||
if (value5 < length) {
|
||||
r3 = value3;
|
||||
r4 = value5;
|
||||
r5 = r0;
|
||||
while (true) {
|
||||
property = value6[r4];
|
||||
value7 = env0_5(property, 2);
|
||||
property = value7[value5];
|
||||
property2 = value7[1];
|
||||
value8 = guild != null;
|
||||
if (value8) {
|
||||
premiumFeatures = guild.premiumFeatures;
|
||||
value9 = premiumFeatures != null;
|
||||
r3 = premiumFeatures;
|
||||
r16 = value9;
|
||||
} else {
|
||||
r16 = value8;
|
||||
}
|
||||
if (!r16) {
|
||||
continue;
|
||||
}
|
||||
features = r3.features;
|
||||
value10 = features.includes(property);
|
||||
r16 = value10;
|
||||
if (!r16) {
|
||||
continue;
|
||||
}
|
||||
isEnabled = property2.isEnabled;
|
||||
if (isEnabled == null) {
|
||||
r15 = value3;
|
||||
continue;
|
||||
}
|
||||
isEnabled2 = property2.isEnabled(a0);
|
||||
r15 = isEnabled2;
|
||||
value11 = r15 == null;
|
||||
if (value11) {
|
||||
r17 = value11;
|
||||
continue;
|
||||
}
|
||||
r17 = r15;
|
||||
continue;
|
||||
r16 = r17;
|
||||
if (!r16) {
|
||||
continue;
|
||||
}
|
||||
includedInLevel = property2.includedInLevel;
|
||||
value12 = includedInLevel == null;
|
||||
if (value12) {
|
||||
r15 = value12;
|
||||
continue;
|
||||
}
|
||||
premiumTier = guild.premiumTier;
|
||||
includedInLevel = property2.includedInLevel;
|
||||
value13 = premiumTier < includedInLevel;
|
||||
r15 = value13;
|
||||
r16 = r15;
|
||||
if (!r16) {
|
||||
r15 = r5;
|
||||
continue;
|
||||
}
|
||||
boostPrice = property2.boostPrice;
|
||||
value14 = r5 + boostPrice;
|
||||
r15 = value14;
|
||||
value15 = typeof r4 === 'bigint' ? r4 + 1n : +r4 + 1;
|
||||
length = value6.length;
|
||||
if (value15 < length) {
|
||||
r4 = value15;
|
||||
r5 = r15;
|
||||
continue;
|
||||
}
|
||||
r0 = r15;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function getStateForGuild_66063(a0) { // fn#66063, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:987, offset: 0x01bea3da, size: 77 bytes, params: 2, frame: 14
|
||||
if (env0_11[a0] == null) {
|
||||
env0_11[a0] = {allPowerups: {}, powerupCatalog: {}, unlockedPowerups: {},
|
||||
appliedBoosts: calculateAppliedBoosts(a0)};
|
||||
}
|
||||
return env0_11[a0];
|
||||
}
|
||||
|
||||
function recalculateState({guildId, entitlements}, a1) { // fn#66064, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:1151, offset: 0x01bea427, size: 112 bytes, params: 3, frame: 16
|
||||
const env0_0 = a1;
|
||||
const stateForGuild_66063 = getStateForGuild_66063(guildId);
|
||||
entitlements.forEach(_fun66065);
|
||||
const object3 = {};
|
||||
copyDataProperties(object3, env0_11, entitlements);
|
||||
const object4 = {};
|
||||
copyDataProperties(object4, stateForGuild_66063, entitlements);
|
||||
object4['appliedBoosts'] = calculateAppliedBoosts(guildId);
|
||||
object3[guildId] = object4;
|
||||
}
|
||||
|
||||
function _fun66066(a0) { // fn#66066, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:1386, offset: 0x01bea4c2, size: 228 bytes, params: 2, frame: 16
|
||||
const closure = GuildPowerupsStore;
|
||||
env0_4(closure, a0);
|
||||
return env0_1(closure, [{key: 'initialize', value: function(a0) {
|
||||
this.waitFor(GuildStore);
|
||||
if (a0 != null) {
|
||||
env1_11 = a0;
|
||||
}
|
||||
}}, {key: 'getState', value: value_66069}, {key: 'getStateForGuild', value: value_66070},
|
||||
{key: 'shouldFetchCatalogForGuild', value: value_66071}, {key: 'shouldFetchPowerupsForGuild',
|
||||
value: value_66072}, {key: 'hasFetchedPowerupCatalog', value: value_66073}, {key: 'hasFetchedUnlockedPowerups',
|
||||
value: value_66074}]);
|
||||
}
|
||||
|
||||
function _fun66075(a0) { // fn#66075, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2533, offset: 0x01bea6d9, size: 86 bytes, params: 2, frame: 15
|
||||
var r0;
|
||||
var Object;
|
||||
var fromEntries;
|
||||
let value = a0;
|
||||
if (value == null) {
|
||||
r0 = value;
|
||||
} else {
|
||||
Object = global.Object;
|
||||
fromEntries = Object.fromEntries;
|
||||
value = global.Object.entries(value);
|
||||
value = value.filter(function(a0) {
|
||||
var r0;
|
||||
var r1;
|
||||
var r2;
|
||||
var item3;
|
||||
var value3;
|
||||
var iterator = a0[Symbol.iterator]();
|
||||
var iterator2 = iterator.next;
|
||||
var item2 = Reflect.apply(iterator2, iterator, []);
|
||||
var item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
var value = undefined;
|
||||
var value2 = item2 === value;
|
||||
if (value2) {
|
||||
r0 = item2;
|
||||
r1 = value;
|
||||
r2 = value2;
|
||||
} else {
|
||||
item3 = Reflect.apply(iterator2, item2, []);
|
||||
item = item3.value;
|
||||
item3 = item3.done ? undefined : item2;
|
||||
value3 = item3 === value;
|
||||
if (value3) {
|
||||
r0 = item3;
|
||||
r1 = value;
|
||||
r2 = value3;
|
||||
} else {
|
||||
r0 = item3;
|
||||
r1 = item;
|
||||
r2 = value3;
|
||||
}
|
||||
}
|
||||
if (!r2) {
|
||||
r0.return();
|
||||
}
|
||||
return r1 != null && typeof r1 === 'object';
|
||||
});
|
||||
value = Reflect.apply(fromEntries, Object, [value.map(_fun66077)]);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function GUILD_POWERUP_CATALOG_FETCH_SUCCESS({guildId, allPowerups, powerupCatalog}) { // fn#66079, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2914, offset: 0x01bea816, size: 129 bytes, params: 2, frame: 17
|
||||
const stateForGuild_66063 = getStateForGuild_66063(guildId);
|
||||
const object3 = {};
|
||||
copyDataProperties(object3, env0_11, allPowerups);
|
||||
const object4 = {};
|
||||
copyDataProperties(object4, stateForGuild_66063, allPowerups);
|
||||
object4['allPowerups'] = allPowerups;
|
||||
object4['powerupCatalog'] = powerupCatalog;
|
||||
const Date = global.Date;
|
||||
object4['catalogFetchCooldown'] = Date.now();
|
||||
object4['hasFetchedPowerupCatalog'] = true;
|
||||
object3[guildId] = object4;
|
||||
}
|
||||
|
||||
function GUILD_BOOST_ENTITLEMENTS_FETCH_SUCCESS_66080({guildId, unlockedPowerups}) { // fn#66080, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:3182, offset: 0x01bea897, size: 132 bytes, params: 2, frame: 17
|
||||
const stateForGuild_66063 = getStateForGuild_66063(guildId);
|
||||
const value3 = calculateAppliedBoosts(guildId);
|
||||
const object3 = {};
|
||||
copyDataProperties(object3, env0_11, unlockedPowerups);
|
||||
const object4 = {};
|
||||
copyDataProperties(object4, stateForGuild_66063, unlockedPowerups);
|
||||
object4['unlockedPowerups'] = unlockedPowerups;
|
||||
object4['appliedBoosts'] = value3;
|
||||
const Date = global.Date;
|
||||
object4['unlockedPowerupsFetchCooldown'] = Date.now();
|
||||
object4['hasFetchedUnlockedPowerups'] = true;
|
||||
object3[guildId] = object4;
|
||||
}
|
||||
|
||||
function GUILD_UPDATE_66083({guild}) { // fn#66083, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:3650, offset: 0x01bea947, size: 64 bytes, params: 2, frame: 15
|
||||
const id = guild.id;
|
||||
const binding = env0_11;
|
||||
const object2 = {};
|
||||
const getStateForGuild_66063Binding = getStateForGuild_66063;
|
||||
copyDataProperties(object2, getStateForGuild_66063Binding(id), getStateForGuild_66063Binding);
|
||||
object2['appliedBoosts'] = calculateAppliedBoosts(id);
|
||||
binding[id] = object2;
|
||||
}
|
||||
|
||||
function GAME_SERVER_FETCH_INSTANCES_SUCCESS_66084({guildId}) { // fn#66084, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:3801, offset: 0x01bea987, size: 59 bytes, params: 2, frame: 15
|
||||
const binding = env0_11;
|
||||
const object2 = {};
|
||||
const getStateForGuild_66063Binding = getStateForGuild_66063;
|
||||
copyDataProperties(object2, getStateForGuild_66063Binding(guildId), getStateForGuild_66063Binding);
|
||||
object2['appliedBoosts'] = calculateAppliedBoosts(guildId);
|
||||
binding[guildId] = object2;
|
||||
}
|
||||
|
||||
function _fun66065(a0) { // fn#66065, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:1244, offset: 0x01bea497, size: 43 bytes, params: 2, frame: 4
|
||||
const unlockedPowerups = env0_1.unlockedPowerups;
|
||||
const sku_id = a0.sku_id;
|
||||
if (require) {
|
||||
unlockedPowerups[sku_id] = a0;
|
||||
} else {
|
||||
delete unlockedPowerups[sku_id];
|
||||
}
|
||||
}
|
||||
|
||||
function value_66070(a0) { // fn#66070, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:1825, offset: 0x01bea5cc, size: 27 bytes, params: 2, frame: 3
|
||||
return a0 != null ? env1_11[a0] : undefined;
|
||||
}
|
||||
|
||||
function value_66071(a0) { // fn#66071, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:1906, offset: 0x01bea5e7, size: 73 bytes, params: 2, frame: 11
|
||||
var r0;
|
||||
var Date;
|
||||
let value = environment.__proto__;
|
||||
const catalogFetchCooldown = env1_11[a0]?.catalogFetchCooldown;
|
||||
value = catalogFetchCooldown == null;
|
||||
if (value) {
|
||||
r0 = value;
|
||||
} else {
|
||||
value = catalogFetchCooldown + 86400000;
|
||||
Date = global.Date;
|
||||
value = value < Date.now();
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function value_66072(a0) { // fn#66072, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2049, offset: 0x01bea630, size: 73 bytes, params: 2, frame: 11
|
||||
var r0;
|
||||
var Date;
|
||||
let value = environment.__proto__;
|
||||
const unlockedPowerupsFetchCooldown = env1_11[a0]?.unlockedPowerupsFetchCooldown;
|
||||
value = unlockedPowerupsFetchCooldown == null;
|
||||
if (value) {
|
||||
r0 = value;
|
||||
} else {
|
||||
value = unlockedPowerupsFetchCooldown + 3600000;
|
||||
Date = global.Date;
|
||||
value = value < Date.now();
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function value_66073(a0) { // fn#66073, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2197, offset: 0x01bea679, size: 48 bytes, params: 2, frame: 4
|
||||
var r0;
|
||||
var property;
|
||||
let value = a0 != null;
|
||||
if (value) {
|
||||
value = environment.__proto__;
|
||||
property = env1_11[a0];
|
||||
value = undefined;
|
||||
value = (property == null ? value : property.hasFetchedPowerupCatalog) === true;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function value_66074(a0) { // fn#66074, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2329, offset: 0x01bea6a9, size: 48 bytes, params: 2, frame: 4
|
||||
var r0;
|
||||
var property;
|
||||
let value = a0 != null;
|
||||
if (value) {
|
||||
value = environment.__proto__;
|
||||
property = env1_11[a0];
|
||||
value = undefined;
|
||||
value = (property == null ? value : property.hasFetchedUnlockedPowerups) === true;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun66077(a0) { // fn#66077, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8443:2635, offset: 0x01bea77c, size: 154 bytes, params: 2, frame: 16
|
||||
var r0;
|
||||
var r2;
|
||||
var r3;
|
||||
var item3;
|
||||
var value3;
|
||||
const iterator = a0[Symbol.iterator]();
|
||||
const iterator2 = iterator.next;
|
||||
let item2 = Reflect.apply(iterator2, iterator, []);
|
||||
let item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
const value = undefined;
|
||||
const value2 = item2 === value;
|
||||
const r1 = value2 ? value : item;
|
||||
if (value2) {
|
||||
r0 = item2;
|
||||
r2 = value2;
|
||||
r3 = value;
|
||||
} else {
|
||||
item3 = Reflect.apply(iterator2, item2, []);
|
||||
item = item3.value;
|
||||
item3 = item3.done ? undefined : item2;
|
||||
value3 = item3 === value;
|
||||
if (value3) {
|
||||
r0 = item3;
|
||||
r2 = value3;
|
||||
r3 = value;
|
||||
} else {
|
||||
r0 = item3;
|
||||
r2 = value3;
|
||||
r3 = item;
|
||||
}
|
||||
}
|
||||
if (!r2) {
|
||||
r0.return();
|
||||
}
|
||||
const items2 = [r1];
|
||||
const object2 = {};
|
||||
copyDataProperties(object2, r3, value);
|
||||
object2['allPowerups'] = r3.allPowerups ?? ({});
|
||||
object2['powerupCatalog'] = r3.powerupCatalog ?? ({});
|
||||
object2['unlockedPowerups'] = r3.unlockedPowerups ?? ({});
|
||||
items2[1] = object2;
|
||||
return items2;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/* Metro module 14657; source: modules/premium/powerups/analytics/GuildPowerupAnalytics.tsx; dependencies: [31, 661, 683, 2] */
|
||||
function _fun110711(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110711, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14854:6, offset: 0x02383913, size: 173 bytes, params: 8, frame: 18
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(661) /* metro dependency 661: Constants */).AnalyticEvents;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/analytics/GuildPowerupAnalytics.tsx');
|
||||
exports.ModalType = {DETAIL: 'Boost Perk Shop Details', DEACTIVATE: 'Boost Perk Shop Disable'};
|
||||
exports.useLogPowerupModalOpened = function(a0, a1, a2) {
|
||||
var env0_0 = a0;
|
||||
var env0_1 = a1;
|
||||
a2.useEffect(_fun110713, [a2, a0, a1.skuId]);
|
||||
};
|
||||
}
|
||||
|
||||
function useLogPowerupModalOpened(a0, a1, a2) { // fn#110712, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14854:368, offset: 0x023839c0, size: 73 bytes, params: 4, frame: 16
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
a2.useEffect(_fun110713, [a2, a0, a1.skuId]);
|
||||
}
|
||||
|
||||
function _fun110713() { // fn#110713, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14854:422, offset: 0x02383a09, size: 83 bytes, params: 1, frame: 16
|
||||
const defaultImport = importDefault(683) /* metro dependency 683: AnalyticsUtils */;
|
||||
const track = defaultImport.track;
|
||||
const OPEN_MODAL = AnalyticEvents.OPEN_MODAL;
|
||||
Reflect.apply(track, defaultImport, [OPEN_MODAL, {type: importDefault, sku_id: require.skuId, guild_id: env0_0}]);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/* Metro module 15949; source: modules/premium/powerups/constants/EnhancedRoleColorConstants.tsx; dependencies: [2] */
|
||||
function _fun123257(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#123257, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16157:6, offset: 0x02585a67, size: 338 bytes, params: 8, frame: 15
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/constants/EnhancedRoleColorConstants.tsx');
|
||||
exports.HOLOGRAPHIC_ROLE_COLORS = {'primary_color': 11127295, 'secondary_color': 16759788,
|
||||
'tertiary_color': 16761760};
|
||||
exports.DEFAULT_GRADIENT_ROLE_COLORS = {'primary_color': 10382335, 'secondary_color': 10469887,
|
||||
'tertiary_color': null};
|
||||
exports.GRADIENT_PRESETS = [{'start': 11156283, 'end': 16730184, 'name': 'fire'}, {'start': 13927485,
|
||||
'end': 16768656, 'name': 'golddust'}, {'start': 3577974, 'end': 7471006, 'name': 'emerald'}, {'start': 5025232,
|
||||
'end': 11729407, 'name': 'diamond'}, {'start': 10382335, 'end': 10469887, 'name': 'blurple'},
|
||||
{'start': 16735702, 'end': 16751807, 'name': 'cupid'}, {'start': 9467253, 'end': 16764614, 'name': 'rosegold'},
|
||||
{'start': 10192486, 'end': 16769460, 'name': 'desert'}, {'start': 7640178, 'end': 11788729, 'name': 'moss'},
|
||||
{'start': 8886702, 'end': 15857663, 'name': 'platinum'}, {'start': 8547266, 'end': 12036081, 'name': 'plum'},
|
||||
{'start': 9854847, 'end': 16755420, 'name': 'rose'}];
|
||||
}
|
||||
|
||||
@@ -0,0 +1,313 @@
|
||||
/* Metro module 8259; source: modules/premium/powerups/constants/GuildPowerupsConstants.tsx; dependencies: [1880, 8260, 661, 8188, 1365, 8249, 1244, 4657, 8262, 4043, 8263, 6857, 2] */
|
||||
function _fun66085(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66085, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8444:6, offset: 0x01bea9c2, size: 2193 bytes, params: 8, frame: 41
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = (require(1880) /* metro dependency 1880: PremiumConstants */).BoostedGuildFeatures;
|
||||
const GAME_SERVER_POWERUP_SKU_ID = (require(8260) /* metro dependency 8260: GameServerConstants */).GAME_SERVER_POWERUP_SKU_ID;
|
||||
const {BoostedGuildTiers, GuildFeatures} = require(661) /* metro dependency 661: Constants */;
|
||||
let Set = global.Set;
|
||||
const GUILD_POWERUP_LEVEL_1_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_1_SKU_ID;
|
||||
const items2 = [GUILD_POWERUP_LEVEL_1_SKU_ID];
|
||||
const GUILD_POWERUP_LEVEL_2_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_2_SKU_ID;
|
||||
items2[1] = GUILD_POWERUP_LEVEL_2_SKU_ID;
|
||||
const GUILD_POWERUP_LEVEL_3_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_3_SKU_ID;
|
||||
items2[2] = GUILD_POWERUP_LEVEL_3_SKU_ID;
|
||||
let set = new Set(items2);
|
||||
const object = {};
|
||||
let TIER_1 = BoostedGuildTiers.TIER_1;
|
||||
object[TIER_1] = GUILD_POWERUP_LEVEL_1_SKU_ID;
|
||||
let TIER_2 = BoostedGuildTiers.TIER_2;
|
||||
object[TIER_2] = GUILD_POWERUP_LEVEL_2_SKU_ID;
|
||||
let TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
object[TIER_3] = GUILD_POWERUP_LEVEL_3_SKU_ID;
|
||||
let NONE = BoostedGuildTiers.NONE;
|
||||
object[NONE] = undefined;
|
||||
const object7 = {};
|
||||
TIER_1 = BoostedGuildTiers.TIER_1;
|
||||
object7[GUILD_POWERUP_LEVEL_1_SKU_ID] = TIER_1;
|
||||
TIER_2 = BoostedGuildTiers.TIER_2;
|
||||
object7[GUILD_POWERUP_LEVEL_2_SKU_ID] = TIER_2;
|
||||
TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
object7[GUILD_POWERUP_LEVEL_3_SKU_ID] = TIER_3;
|
||||
const object8 = {};
|
||||
TIER_1 = BoostedGuildTiers.TIER_1;
|
||||
const DismissibleGuildContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent;
|
||||
const GUILD_POWERUP_LEVEL_1_COACHMARK = DismissibleGuildContent.GUILD_POWERUP_LEVEL_1_COACHMARK;
|
||||
object8[TIER_1] = GUILD_POWERUP_LEVEL_1_COACHMARK;
|
||||
TIER_2 = BoostedGuildTiers.TIER_2;
|
||||
const GUILD_POWERUP_LEVEL_2_COACHMARK = DismissibleGuildContent.GUILD_POWERUP_LEVEL_2_COACHMARK;
|
||||
object8[TIER_2] = GUILD_POWERUP_LEVEL_2_COACHMARK;
|
||||
TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
const GUILD_POWERUP_LEVEL_3_COACHMARK = DismissibleGuildContent.GUILD_POWERUP_LEVEL_3_COACHMARK;
|
||||
object8[TIER_3] = GUILD_POWERUP_LEVEL_3_COACHMARK;
|
||||
NONE = BoostedGuildTiers.NONE;
|
||||
object8[NONE] = undefined;
|
||||
const GUILD_POWERUP_TAG_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_TAG_SKU_ID;
|
||||
const items3 = [[GUILD_POWERUP_TAG_SKU_ID]];
|
||||
const GUILD_POWERUP_ROLE_COLOR_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_ROLE_COLOR_SKU_ID;
|
||||
items3[1] = [GUILD_POWERUP_ROLE_COLOR_SKU_ID];
|
||||
const VANITY_URL_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).VANITY_URL_POWERUP_SKU_ID;
|
||||
items3[2] = [VANITY_URL_POWERUP_SKU_ID];
|
||||
const GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID;
|
||||
const items6 = [GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID];
|
||||
const GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID;
|
||||
items6[1] = GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID;
|
||||
items3[3] = items6;
|
||||
const GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID;
|
||||
const items7 = [GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID];
|
||||
const GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID;
|
||||
items7[1] = GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID;
|
||||
items3[4] = items7;
|
||||
const GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID;
|
||||
items3[5] = [GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
const GUILD_POWERUP_GUILD_THEME_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
items3[6] = [GUILD_POWERUP_GUILD_THEME_SKU_ID];
|
||||
const object9 = {};
|
||||
object9[GAME_SERVER_POWERUP_SKU_ID] = 'beta';
|
||||
object9[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID] = 'beta';
|
||||
object9[GUILD_POWERUP_GUILD_THEME_SKU_ID] = 'beta';
|
||||
Set = global.Set;
|
||||
set = new Set([GUILD_POWERUP_TAG_SKU_ID, GUILD_POWERUP_ROLE_COLOR_SKU_ID, VANITY_URL_POWERUP_SKU_ID,
|
||||
GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID, GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID,
|
||||
GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID, GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID,
|
||||
GUILD_POWERUP_GUILD_THEME_SKU_ID]);
|
||||
Set = global.Set;
|
||||
set = new Set([GUILD_POWERUP_ROLE_COLOR_SKU_ID]);
|
||||
const object10 = {};
|
||||
let VANITY_URL = GuildFeatures.VANITY_URL;
|
||||
TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
object10[VANITY_URL] = {boostPrice: 5, includedInLevel: TIER_3};
|
||||
const GUILD_TAGS = GuildFeatures.GUILD_TAGS;
|
||||
object10[GUILD_TAGS] = {boostPrice: 3};
|
||||
const ENHANCED_ROLE_COLORS = GuildFeatures.ENHANCED_ROLE_COLORS;
|
||||
object10[ENHANCED_ROLE_COLORS] = {boostPrice: 3};
|
||||
const GUILD_TAGS_BADGE_PACK_PETS = GuildFeatures.GUILD_TAGS_BADGE_PACK_PETS;
|
||||
object10[GUILD_TAGS_BADGE_PACK_PETS] = {boostPrice: 3};
|
||||
const GUILD_TAGS_BADGE_PACK_FLEX = GuildFeatures.GUILD_TAGS_BADGE_PACK_FLEX;
|
||||
object10[GUILD_TAGS_BADGE_PACK_FLEX] = {boostPrice: 5};
|
||||
const GUILD_TAGS_BADGE_PACK_PLANT = GuildFeatures.GUILD_TAGS_BADGE_PACK_PLANT;
|
||||
object10[GUILD_TAGS_BADGE_PACK_PLANT] = {boostPrice: 3};
|
||||
const GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES = GuildFeatures.GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES;
|
||||
object10[GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES] = {boostPrice: 2};
|
||||
const MAX_FILE_SIZE_250_MB = GuildFeatures.MAX_FILE_SIZE_250_MB;
|
||||
object10[MAX_FILE_SIZE_250_MB] = {boostPrice: 4, isEnabled: isEnabled_66086};
|
||||
let GUILD_THEME = GuildFeatures.GUILD_THEME;
|
||||
object10[GUILD_THEME] = {boostPrice: 3, isEnabled: isEnabled_66087};
|
||||
const object11 = {};
|
||||
const GAME_SERVERS = GuildFeatures.GAME_SERVERS;
|
||||
object11[GAME_SERVERS] = {boostPrice: 3, isEnabled: isEnabled_66088};
|
||||
const object12 = {};
|
||||
TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
object12[VANITY_URL_POWERUP_SKU_ID] = TIER_3;
|
||||
const object13 = {VANITY_URL: 1};
|
||||
object13[1] = 'VANITY_URL';
|
||||
object13.GUILD_TAG_BADGE_PACKS_WAVE_ONE = 2;
|
||||
object13[2] = 'GUILD_TAG_BADGE_PACKS_WAVE_ONE';
|
||||
object13.GAME_SERVER_HOSTING = 3;
|
||||
object13[3] = 'GAME_SERVER_HOSTING';
|
||||
object13.GUILD_TAG_BADGE_PACKS_WAVE_TWO = 4;
|
||||
object13[4] = 'GUILD_TAG_BADGE_PACKS_WAVE_TWO';
|
||||
object13.FILE_UPLOAD_250_MB = 5;
|
||||
object13[5] = 'FILE_UPLOAD_250_MB';
|
||||
object13.GUILD_THEME = 6;
|
||||
object13[6] = 'GUILD_THEME';
|
||||
Set = global.Set;
|
||||
set = new Set([GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID, GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID]);
|
||||
Set = global.Set;
|
||||
set = new Set([GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID, GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID]);
|
||||
const object14 = {};
|
||||
VANITY_URL = object13.VANITY_URL;
|
||||
Set = global.Set;
|
||||
const items14 = [VANITY_URL_POWERUP_SKU_ID];
|
||||
const value10 = Object.create(Set.prototype, {constructor: {value: Set}});
|
||||
set = new Set(items14);
|
||||
object14[VANITY_URL] = set instanceof Object ? set : value10;
|
||||
const GUILD_TAG_BADGE_PACKS_WAVE_ONE = object13.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
object14[GUILD_TAG_BADGE_PACKS_WAVE_ONE] = set;
|
||||
const GAME_SERVER_HOSTING = object13.GAME_SERVER_HOSTING;
|
||||
Set = global.Set;
|
||||
const value12 = Object.create(Set.prototype, {constructor: {value: Set}});
|
||||
set = new Set();
|
||||
object14[GAME_SERVER_HOSTING] = set instanceof Object ? set : value12;
|
||||
const GUILD_TAG_BADGE_PACKS_WAVE_TWO = object13.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
object14[GUILD_TAG_BADGE_PACKS_WAVE_TWO] = set;
|
||||
const FILE_UPLOAD_250_MB = object13.FILE_UPLOAD_250_MB;
|
||||
Set = global.Set;
|
||||
const items15 = [GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
const value14 = Object.create(Set.prototype, {constructor: {value: Set}});
|
||||
set = new Set(items15);
|
||||
object14[FILE_UPLOAD_250_MB] = set instanceof Object ? set : value14;
|
||||
GUILD_THEME = object13.GUILD_THEME;
|
||||
Set = global.Set;
|
||||
const items16 = [GUILD_POWERUP_GUILD_THEME_SKU_ID];
|
||||
const value16 = Object.create(Set.prototype, {constructor: {value: Set}});
|
||||
set = new Set(items16);
|
||||
object14[GUILD_THEME] = set instanceof Object ? set : value16;
|
||||
const object15 = {AVAILABLE: 0};
|
||||
object15[0] = 'AVAILABLE';
|
||||
object15.SPENT = 1;
|
||||
object15[1] = 'SPENT';
|
||||
object15.TOTAL = 2;
|
||||
object15[2] = 'TOTAL';
|
||||
const object17 = {LEVEL: 0};
|
||||
object17[0] = 'LEVEL';
|
||||
object17.PERK = 1;
|
||||
object17[1] = 'PERK';
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/constants/GuildPowerupsConstants.tsx');
|
||||
exports.GuildPowerupType = {PERK: 'perk', LEVEL: 'level'};
|
||||
exports.GUILD_POWERUP_APPLICATION_ID = '1340102344645283891';
|
||||
exports.GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS = set;
|
||||
exports.GUILD_POWERUP_MIGRATION_USER_ID = '525479941211684874';
|
||||
exports.BOOSTING_TIER_TO_LEVEL_SKU_ID = object;
|
||||
exports.LEVEL_SKU_ID_TO_BOOSTING_TIER = object7;
|
||||
exports.BOOSTING_TIER_TO_LEVEL_UNLOCKED_DC = object8;
|
||||
exports.GUILD_POWERUP_MODAL_KEY = 'guild_powerup_modal';
|
||||
exports.GUILD_POWERUP_NEW_PERK_GROUPS = items3;
|
||||
exports.PERK_SKU_BADGES = object9;
|
||||
exports.GUILD_POWERUP_CONFIGURABLE_SKUS_DESKTOP = set;
|
||||
exports.GUILD_POWERUP_CONFIGURABLE_SKUS_MOBILE = set;
|
||||
exports.GUILD_FEATURE_TO_PERK = GUILD_FEATURE_TO_PERK;
|
||||
exports.PURCHASABLE_PREMIUM_FEATURES_BOOST_INFO = object10;
|
||||
exports.MULTIPLE_PURCHASEABLE_PREMIUM_FEATURES_BOOST_INFO = object11;
|
||||
exports.POWERUPS_INCLUDED_IN_LEVEL = object12;
|
||||
exports.PowerupActiveStatusType = {INACTIVE: 'inactive', POWERUP_ACTIVATED: 'powerup_activated',
|
||||
LEVEL_ACTIVATED: 'level_activated', TIER_OVERRIDE_ACTIVATED: 'tier_override_activated'};
|
||||
exports.GuildPowerupNewPerkAvailableCoachmarkVersion = object13;
|
||||
exports.GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET = set;
|
||||
exports.GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET = set;
|
||||
exports.NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET = object14;
|
||||
exports.POWERUP_ID_QUERY_PARAM = 'powerupId';
|
||||
exports.BoostInfoType = object15;
|
||||
exports.BoostPurchaseIntent = object17;
|
||||
exports.LevelCardPosition = {START: 'start', MIDDLE: 'middle', END: 'end'};
|
||||
exports.LevelCardGradient = {FULL: 'full', HALF: 'half', NONE: 'none'};
|
||||
}
|
||||
|
||||
function isEnabled_66086(a0) { // fn#66086, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8444:2304, offset: 0x01beb253, size: 102 bytes, params: 2, frame: 16
|
||||
var r0;
|
||||
var value;
|
||||
const FileUploadPowerupHoldoutExperiment = (require(4657) /* metro dependency 4657: FileUploadPowerupHoldoutExperiment */).FileUploadPowerupHoldoutExperiment;
|
||||
const getConfig = FileUploadPowerupHoldoutExperiment.getConfig;
|
||||
const enabled = Reflect.apply(getConfig, FileUploadPowerupHoldoutExperiment,
|
||||
[{location: 'GuildPowerupsConstants'}]).enabled;
|
||||
if (enabled) {
|
||||
r0 = !enabled;
|
||||
} else {
|
||||
value = require(8262) /* metro dependency 8262: FileUpload250MbPowerupExperiment */;
|
||||
value = value.getFileUpload250MbPowerupEnabled(a0, 'GuildPowerupsConstants');
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function isEnabled_66087(a0) { // fn#66087, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8444:2517, offset: 0x01beb2b9, size: 82 bytes, params: 2, frame: 15
|
||||
var r0;
|
||||
var value;
|
||||
const serverThemeUserEnabled = (require(4043) /* metro dependency 4043: ServerThemeUserExperiment */).getServerThemeUserEnabled('GuildPowerupsConstants');
|
||||
if (serverThemeUserEnabled) {
|
||||
value = require(8263) /* metro dependency 8263: ServerThemeExperiment */;
|
||||
value = value.getServerThemeEnabled(a0, 'GuildPowerupsConstants');
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = serverThemeUserEnabled;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function isEnabled_66088(a0) { // fn#66088, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8444:2686, offset: 0x01beb30b, size: 48 bytes, params: 2, frame: 13
|
||||
return (require(6857) /* metro dependency 6857: GameServerExperiment */).getGameServerEnabled(a0,
|
||||
'GuildPowerupsConstants');
|
||||
}
|
||||
|
||||
function GUILD_FEATURE_TO_PERK() { // fn#66089, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8444:4763, offset: 0x01beb33b, size: 1295 bytes, params: 1, frame: 28
|
||||
const object3 = {};
|
||||
const VIDEO_QUALITY_1080_60FPS = GuildFeatures.VIDEO_QUALITY_1080_60FPS;
|
||||
const object4 = {};
|
||||
const PerkIcons = (require(8249) /* metro dependency 8249: GuildBoostingUtils */).PerkIcons;
|
||||
const STREAM = PerkIcons.STREAM;
|
||||
object4.perkIcon = STREAM;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
object4.description = Reflect.apply(string, intl, [t.y4ft4D]);
|
||||
object3[VIDEO_QUALITY_1080_60FPS] = object4;
|
||||
const AUDIO_BITRATE_128_KBPS = GuildFeatures.AUDIO_BITRATE_128_KBPS;
|
||||
let AUDIO = PerkIcons.AUDIO;
|
||||
let formatToPlainString = intl.formatToPlainString;
|
||||
let zoT1ZE = t.zoT1ZE;
|
||||
const TIER_1 = BoostedGuildTiers.TIER_1;
|
||||
object3[AUDIO_BITRATE_128_KBPS] = {perkIcon: AUDIO, description: Reflect.apply(formatToPlainString, intl, [zoT1ZE,
|
||||
{bitrate: BoostedGuildFeatures[TIER_1].limits.bitrate / 1000}])};
|
||||
const INVITE_SPLASH = GuildFeatures.INVITE_SPLASH;
|
||||
let CUSTOMIZATION = PerkIcons.CUSTOMIZATION;
|
||||
string = intl.string;
|
||||
const Qwlpov = t.Qwlpov;
|
||||
object3[INVITE_SPLASH] = {perkIcon: CUSTOMIZATION, description: Reflect.apply(string, intl, [Qwlpov])};
|
||||
const ANIMATED_ICON = GuildFeatures.ANIMATED_ICON;
|
||||
let ANIMATED = PerkIcons.ANIMATED;
|
||||
string = intl.string;
|
||||
const PbAyub = t.PbAyub;
|
||||
object3[ANIMATED_ICON] = {perkIcon: ANIMATED, description: Reflect.apply(string, intl, [PbAyub])};
|
||||
const AUDIO_BITRATE_256_KBPS = GuildFeatures.AUDIO_BITRATE_256_KBPS;
|
||||
AUDIO = PerkIcons.AUDIO;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
zoT1ZE = t.zoT1ZE;
|
||||
const TIER_2 = BoostedGuildTiers.TIER_2;
|
||||
object3[AUDIO_BITRATE_256_KBPS] = {perkIcon: AUDIO, description: Reflect.apply(formatToPlainString, intl, [zoT1ZE,
|
||||
{bitrate: BoostedGuildFeatures[TIER_2].limits.bitrate / 1000}])};
|
||||
const ROLE_ICONS = GuildFeatures.ROLE_ICONS;
|
||||
const object5 = {};
|
||||
const CUSTOM_ROLE_ICON = PerkIcons.CUSTOM_ROLE_ICON;
|
||||
object5.perkIcon = CUSTOM_ROLE_ICON;
|
||||
object5.description = intl.string(t['6PV6Qc']);
|
||||
object3[ROLE_ICONS] = object5;
|
||||
const MAX_FILE_SIZE_50_MB = GuildFeatures.MAX_FILE_SIZE_50_MB;
|
||||
const object6 = {};
|
||||
let UPLOAD = PerkIcons.UPLOAD;
|
||||
object6.perkIcon = UPLOAD;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
let aFRl53 = t.aFRl53;
|
||||
const intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
string = intl2.string;
|
||||
const M6qV8j = t.M6qV8j;
|
||||
object6.description = Reflect.apply(formatToPlainString, intl, [aFRl53, {uploadSizeLimit: Reflect.apply(string,
|
||||
intl2, [M6qV8j])}]);
|
||||
object3[MAX_FILE_SIZE_50_MB] = object6;
|
||||
const BANNER = GuildFeatures.BANNER;
|
||||
const object7 = {};
|
||||
CUSTOMIZATION = PerkIcons.CUSTOMIZATION;
|
||||
object7.perkIcon = CUSTOMIZATION;
|
||||
object7.description = intl.string(t['1a5rjl']);
|
||||
object3[BANNER] = object7;
|
||||
const ANIMATED_BANNER = GuildFeatures.ANIMATED_BANNER;
|
||||
const object8 = {};
|
||||
ANIMATED = PerkIcons.ANIMATED;
|
||||
object8.perkIcon = ANIMATED;
|
||||
object8.description = intl.string(t['1+Vmh9']);
|
||||
object3[ANIMATED_BANNER] = object8;
|
||||
const AUDIO_BITRATE_384_KBPS = GuildFeatures.AUDIO_BITRATE_384_KBPS;
|
||||
AUDIO = PerkIcons.AUDIO;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
zoT1ZE = t.zoT1ZE;
|
||||
const TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
object3[AUDIO_BITRATE_384_KBPS] = {perkIcon: AUDIO, description: Reflect.apply(formatToPlainString, intl, [zoT1ZE,
|
||||
{bitrate: BoostedGuildFeatures[TIER_3].limits.bitrate / 1000}])};
|
||||
const VANITY_URL = GuildFeatures.VANITY_URL;
|
||||
const object11 = {};
|
||||
const VANITY = PerkIcons.VANITY;
|
||||
object11.perkIcon = VANITY;
|
||||
object11.description = intl.string(t['5XZKy/']);
|
||||
object3[VANITY_URL] = object11;
|
||||
const MAX_FILE_SIZE_100_MB = GuildFeatures.MAX_FILE_SIZE_100_MB;
|
||||
const object14 = {};
|
||||
UPLOAD = PerkIcons.UPLOAD;
|
||||
object14.perkIcon = UPLOAD;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
aFRl53 = t.aFRl53;
|
||||
const intl3 = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object14.description = Reflect.apply(formatToPlainString, intl, [aFRl53, {uploadSizeLimit: intl3.string(t.yMOW8D)}]);
|
||||
object3[MAX_FILE_SIZE_100_MB] = object14;
|
||||
return object3;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
/* Metro module 14598; source: modules/premium/powerups/constants/GuildPowerupsNotification.tsx; dependencies: [2] */
|
||||
function _fun110377(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110377, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14795:6, offset: 0x02377375, size: 344 bytes, params: 8, frame: 18
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const object = {LEVEL_REACHED: 0};
|
||||
object[0] = 'LEVEL_REACHED';
|
||||
object.PERKS_PURCHASABLE = 1;
|
||||
object[1] = 'PERKS_PURCHASABLE';
|
||||
object.PERKS_AVAILABLE = 2;
|
||||
object[2] = 'PERKS_AVAILABLE';
|
||||
object.NEW_PERK_AVAILABLE = 3;
|
||||
object[3] = 'NEW_PERK_AVAILABLE';
|
||||
object.BOOST_TO_UNLOCK = 4;
|
||||
object[4] = 'BOOST_TO_UNLOCK';
|
||||
object.EXPIRING_PERK = 5;
|
||||
object[5] = 'EXPIRING_PERK';
|
||||
object.GAME_SERVER_HOSTING_AVAILABLE = 6;
|
||||
object[6] = 'GAME_SERVER_HOSTING_AVAILABLE';
|
||||
object.GAME_SERVER_HOSTING_GUILD_ELIGIBLE = 7;
|
||||
object[7] = 'GAME_SERVER_HOSTING_GUILD_ELIGIBLE';
|
||||
object.GAME_SERVER_HOSTING_ENABLED = 8;
|
||||
object[8] = 'GAME_SERVER_HOSTING_ENABLED';
|
||||
object.GAME_SERVER_NEW_GAMES = 9;
|
||||
object[9] = 'GAME_SERVER_NEW_GAMES';
|
||||
object.GAME_SERVER_PRICING_CHANGE = 10;
|
||||
object[10] = 'GAME_SERVER_PRICING_CHANGE';
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/constants/GuildPowerupsNotification.tsx');
|
||||
exports.GUILD_POWERUP_NOTIFICATION_COOLDOWN = 21600000;
|
||||
exports.BOOST_TO_UNLOCK_COACHMARK_COOLDOWN = 2592000000;
|
||||
exports.BOOST_TO_UNLOCK_COACHMARK_MAX_TIMES_TO_RECUR = 5;
|
||||
exports.EXPIRING_POWERUP_COACHMARK_COOLDOWN = 259200000;
|
||||
exports.GuildPowerupNotificationIndicatorType = {WARNING: 'warning', UNREAD: 'unread'};
|
||||
exports.GuildPowerupNotificationPopoutType = object;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
/* Metro module 14614; source: modules/premium/powerups/experiments/BoostToUnlockCoachmarkExperiment.tsx; dependencies: [1358, 2] */
|
||||
function _fun110509(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110509, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14811:6, offset: 0x0237b963, size: 171 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importDefault(1358) /* metro dependency 1358: ApexExperiment */;
|
||||
value = value({'name': '2026-02-boost-to-unlock-coachmark', 'kind': 'user', defaultConfig: {enabled: false},
|
||||
variations: {[0]: {enabled: false}, [1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/BoostToUnlockCoachmarkExperiment.tsx');
|
||||
exports.default = value;
|
||||
exports.useBoostToUnlockCoachmarkEnabled = useBoostToUnlockCoachmarkEnabled;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
/* Metro module 14675; source: modules/premium/powerups/experiments/ExpiringBoostsExperiment.tsx; dependencies: [1358, 2] */
|
||||
function _fun110784(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110784, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14872:6, offset: 0x02386ff6, size: 171 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importDefault(1358) /* metro dependency 1358: ApexExperiment */;
|
||||
value = value({'name': '2026-05-expiring-boosts', 'kind': 'user', defaultConfig: {enabled: false},
|
||||
variations: {[0]: {enabled: false}, [1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ExpiringBoostsExperiment.tsx');
|
||||
exports.default = value;
|
||||
exports.useExpiringBoostsEnabled = useExpiringBoostsEnabled;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
/* Metro module 14616; source: modules/premium/powerups/experiments/ExpiringPowerupCoachmarkExperiment.tsx; dependencies: [1358, 2] */
|
||||
function _fun110518(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110518, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14813:6, offset: 0x0237bdb6, size: 171 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importDefault(1358) /* metro dependency 1358: ApexExperiment */;
|
||||
value = value({'name': '2026-02-expiring-powerup-coachmark', 'kind': 'user', defaultConfig: {enabled: false},
|
||||
variations: {[0]: {enabled: false}, [1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ExpiringPowerupCoachmarkExperiment.tsx');
|
||||
exports.default = value;
|
||||
exports.useExpiringPowerupCoachmarkEnabled = useExpiringPowerupCoachmarkEnabled;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
/* Metro module 8262; source: modules/premium/powerups/experiments/FileUpload250MbPowerupExperiment.tsx; dependencies: [4620, 2] */
|
||||
function _fun66094(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66094, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8447:6, offset: 0x01bebc88, size: 200 bytes, params: 8, frame: 22
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(4620) /* metro dependency 4620: experiments */;
|
||||
value = value.createExperiment({'kind': 'guild', 'id': '2026-03_file_upload_250_mb_powerup',
|
||||
'label': 'File Upload 250MB Powerup', defaultConfig: {enabled: false}, treatments: [{'id': 1,
|
||||
'label': 'Enable File Upload 250MB Powerup', config: {enabled: true}}]});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/FileUpload250MbPowerupExperiment.tsx');
|
||||
exports.FileUpload250MbPowerupExperiment = value;
|
||||
exports.getFileUpload250MbPowerupEnabled = getFileUpload250MbPowerupEnabled;
|
||||
exports.useFileUpload250MbPowerupEnabled = useFileUpload250MbPowerupEnabled;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/* Metro module 4657; source: modules/premium/powerups/experiments/FileUploadPowerupHoldoutExperiment.tsx; dependencies: [1854, 2] */
|
||||
function _fun40245(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#40245, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4835:6, offset: 0x010fa498, size: 145 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(1854) /* metro dependency 1854: apex */;
|
||||
value = value.createApexExperiment({'kind': 'user', 'name': '2026-03-file-upload-powerup-holdout',
|
||||
defaultConfig: {enabled: false}, variations: {[1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/FileUploadPowerupHoldoutExperiment.tsx');
|
||||
exports.FileUploadPowerupHoldoutExperiment = value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
/* Metro module 14555; source: modules/premium/powerups/experiments/MobileBoostProgressBarExperiment.tsx; dependencies: [1854, 2] */
|
||||
function _fun110081(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110081, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14752:6, offset: 0x023698b3, size: 179 bytes, params: 8, frame: 21
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(1854) /* metro dependency 1854: apex */;
|
||||
value = value.createApexExperiment({'name': '2026-04-mobile-boost-progress-bar', 'kind': 'user',
|
||||
defaultConfig: {enabled: false}, variations: {[1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/MobileBoostProgressBarExperiment.tsx');
|
||||
exports.MobileBoostProgressBarExperiment = value;
|
||||
exports.useMobileBoostProgressBarEnabled = useMobileBoostProgressBarEnabled;
|
||||
exports.getMobileBoostProgressBarEnabled = getMobileBoostProgressBarEnabled;
|
||||
}
|
||||
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
/* Metro module 12326; source: modules/premium/powerups/experiments/ServerBoostStreamQualityMarketingExperiment.tsx; dependencies: [1358, 2] */
|
||||
function _fun94091(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#94091, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12512:6, offset: 0x020d217b, size: 181 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importDefault(1358) /* metro dependency 1358: ApexExperiment */;
|
||||
value = value({'name': '2026-04-server-boost-copy-1440p', 'kind': 'user',
|
||||
defaultConfig: {streamQualityMarketingResolution: '1080p'},
|
||||
variations: {[1]: {streamQualityMarketingResolution: '1440p'}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ServerBoostStreamQualityMarketingExperiment.tsx');
|
||||
exports.default = value;
|
||||
exports.CONTROL_RESOLUTION = '1080p';
|
||||
exports.getServerBoostStreamQualityMarketingResolution = getServerBoostStreamQualityMarketingResolution;
|
||||
}
|
||||
|
||||
function getServerBoostStreamQualityMarketingResolution(a0) { // fn#94092, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12512:489, offset: 0x020d2230, size: 35 bytes, params: 2, frame: 12
|
||||
const binding = env0_0;
|
||||
const getConfig = binding.getConfig;
|
||||
return Reflect.apply(getConfig, binding, [{location: a0}]).streamQualityMarketingResolution;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
/* Metro module 8264; source: modules/premium/powerups/experiments/ServerThemeApexShadowExperiment.tsx; dependencies: [1854, 2] */
|
||||
function _fun66100(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66100, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8449:6, offset: 0x01bebfa2, size: 213 bytes, params: 8, frame: 19
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(1854) /* metro dependency 1854: apex */;
|
||||
value = value.createApexExperiment({'kind': 'guild', 'name': '2026-06-server-theme-apex-shadow',
|
||||
defaultConfig: {'enabled': false, 'inExperiment': false, 'gatesApex': false},
|
||||
variations: {[0]: {'enabled': false, 'inExperiment': true, 'gatesApex': false}, [1]: {'enabled': true,
|
||||
'inExperiment': true, 'gatesApex': false}, [2]: {'enabled': false, 'inExperiment': true, 'gatesApex': true},
|
||||
[3]: {'enabled': true, 'inExperiment': true, 'gatesApex': true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ServerThemeApexShadowExperiment.tsx');
|
||||
exports.ServerThemeApexShadowExperiment = value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
/* Metro module 8263; source: modules/premium/powerups/experiments/ServerThemeExperiment.tsx; dependencies: [661, 4620, 8264, 2] */
|
||||
function _fun66097(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66097, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8448:6, offset: 0x01bebd50, size: 279 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = (require(661) /* metro dependency 661: Constants */).EMPTY_STRING_SNOWFLAKE_ID;
|
||||
let value = require(4620) /* metro dependency 4620: experiments */;
|
||||
value = value.createExperiment({'kind': 'guild', 'id': '2026-04_server_theme', 'label': 'Server Theme',
|
||||
defaultConfig: {'enabled': false, 'inExperiment': false, 'gatesApex': false}, treatments: [{'id': 0,
|
||||
'label': 'Control', config: {'enabled': false, 'inExperiment': true, 'gatesApex': false}}, {'id': 1,
|
||||
'label': 'Enable Server Theme', config: {'enabled': true, 'inExperiment': true, 'gatesApex': false}}]});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ServerThemeExperiment.tsx');
|
||||
exports.ServerThemeExperiment = value;
|
||||
exports.getServerThemeEnabled = getServerThemeEnabled;
|
||||
exports.useServerThemeEnabled = useServerThemeEnabled;
|
||||
}
|
||||
|
||||
function getServerThemeEnabled(a0, a1) { // fn#66098, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8448:593, offset: 0x01bebe67, size: 157 bytes, params: 3, frame: 17
|
||||
const {enabled, inExperiment} = env0_3.getCurrentConfig({guildId: a0, location: a1}, {autoTrackExposure: false});
|
||||
const r1 = a0 != null ? (require(8264) /* metro dependency 8264: ServerThemeApexShadowExperiment */).ServerThemeApexShadowExperiment.getConfig({guildId: a0,
|
||||
location: a1}) : {'enabled': false, 'gatesApex': false};
|
||||
const enabled2 = r1.enabled;
|
||||
const gatesApex = r1.gatesApex;
|
||||
return inExperiment ? enabled : gatesApex ? enabled2 : !!gatesApex;
|
||||
}
|
||||
|
||||
function useServerThemeEnabled(a0, a1) { // fn#66099, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8448:909, offset: 0x01bebf04, size: 158 bytes, params: 3, frame: 20
|
||||
const value = a0;
|
||||
const {enabled, inExperiment} = env0_3.useExperiment({guildId: value, location: a1}, {autoTrackExposure: false});
|
||||
const ServerThemeApexShadowExperiment = (require(8264) /* metro dependency 8264: ServerThemeApexShadowExperiment */).ServerThemeApexShadowExperiment;
|
||||
const value4 = ServerThemeApexShadowExperiment.useConfig({guildId: value ?? EMPTY_STRING_SNOWFLAKE_ID,
|
||||
location: a1});
|
||||
const enabled2 = value4.enabled;
|
||||
const gatesApex = value4.gatesApex;
|
||||
return inExperiment ? enabled : value != null && (gatesApex ? enabled2 : !!gatesApex);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
/* Metro module 4043; source: modules/premium/powerups/experiments/ServerThemeUserExperiment.tsx; dependencies: [1854, 2] */
|
||||
function _fun33359(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#33359, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4201:6, offset: 0x0102ce92, size: 175 bytes, params: 8, frame: 21
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(1854) /* metro dependency 1854: apex */;
|
||||
value = value.createApexExperiment({'kind': 'user', 'name': '2026-05-server-theme-user',
|
||||
defaultConfig: {enabled: false}, variations: {[1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/experiments/ServerThemeUserExperiment.tsx');
|
||||
exports.ServerThemeUserExperiment = value;
|
||||
exports.getServerThemeUserEnabled = getServerThemeUserEnabled;
|
||||
exports.useServerThemeUserEnabled = useServerThemeUserEnabled;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
/* Metro module 14612; source: modules/premium/powerups/hooks/GuildPowerupsNotificationsDCF.native.tsx; dependencies: [7013, 1365, 14598, 2] */
|
||||
function _fun110487(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110487, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14809:6, offset: 0x0237b17c, size: 174 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/GuildPowerupsNotificationsDCF.native.tsx');
|
||||
exports.usePerksCoachmarkDCF = function(a0) {
|
||||
return require(dependencyMap[0]).useSelectedDismissibleContent(a0 ? [require(dependencyMap[1]).DismissibleContent.GUILD_POWERUP_PERKS_COACHMARK] : []);
|
||||
};
|
||||
exports.useNewPerkAvailableCoachmarkDCF = function(a0, a1) {
|
||||
return require(dependencyMap[0]).useSelectedVersionedDismissibleContent(a0 && a1 > 0 ? require(dependencyMap[1]).DismissibleContent.GUILD_POWERUP_NEW_PERK_AVAILABLE_COACHMARK : null,
|
||||
|
||||
a1);
|
||||
};
|
||||
exports.useGuildPowerupNotificationDCF = function(a0) {
|
||||
var r1;
|
||||
var moduleValue = require(dependencyMap[0]);
|
||||
var useSelectedTimeRecurringDismissibleContent = moduleValue.useSelectedTimeRecurringDismissibleContent;
|
||||
r1 = a0 ? require(dependencyMap[1]).DismissibleContent.GUILD_POWERUP_NOTIFICATION : null;
|
||||
var object = {};
|
||||
object.cooldownDurationMs = require(dependencyMap[2]).GUILD_POWERUP_NOTIFICATION_COOLDOWN;
|
||||
return Reflect.apply(useSelectedTimeRecurringDismissibleContent, moduleValue, [r1, object]);
|
||||
};
|
||||
exports.useNewGamesCoachmarkDC = function() {
|
||||
return [null, _fun110492];
|
||||
};
|
||||
exports.useGameServerPricingCoachmarkDCF = function() {
|
||||
return [null, _fun110494];
|
||||
};
|
||||
exports.useBoostToUnlockCoachmarkDCF = function() {
|
||||
return [null, _fun110496];
|
||||
};
|
||||
exports.useExpiringPowerupCoachmarkDCF = function() {
|
||||
return [null, _fun110498];
|
||||
};
|
||||
}
|
||||
|
||||
function useNewGamesCoachmarkDC() { // fn#110491, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14809:871, offset: 0x0237b34f, size: 23 bytes, params: 1, frame: 2
|
||||
return [null, function() {
|
||||
}];
|
||||
}
|
||||
|
||||
function useGameServerPricingCoachmarkDCF() { // fn#110493, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14809:961, offset: 0x0237b366, size: 23 bytes, params: 1, frame: 2
|
||||
return [null, function() {
|
||||
}];
|
||||
}
|
||||
|
||||
function useBoostToUnlockCoachmarkDCF() { // fn#110495, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14809:1057, offset: 0x0237b37d, size: 23 bytes, params: 1, frame: 2
|
||||
return [null, function() {
|
||||
}];
|
||||
}
|
||||
|
||||
function useExpiringPowerupCoachmarkDCF() { // fn#110497, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14809:1151, offset: 0x0237b394, size: 23 bytes, params: 1, frame: 2
|
||||
return [null, function() {
|
||||
}];
|
||||
}
|
||||
|
||||
@@ -0,0 +1,129 @@
|
||||
/* Metro module 14652; source: modules/premium/powerups/hooks/useAvailableBoostCountForPowerup.tsx; dependencies: [31, 1867, 8258, 8259, 566, 8254, 1360, 2] */
|
||||
function _fun110685(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110685, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14849:6, offset: 0x02382957, size: 195 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_6 = guildPowerupsConstantsModule.GuildPowerupType;
|
||||
const env0_7 = guildPowerupsConstantsModule.POWERUPS_INCLUDED_IN_LEVEL;
|
||||
const env0_8 = guildPowerupsConstantsModule.LEVEL_SKU_ID_TO_BOOSTING_TIER;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useAvailableBoostCountForPowerup.tsx');
|
||||
exports.default = useAvailableBoostCountForPowerup;
|
||||
}
|
||||
|
||||
function useAvailableBoostCountForPowerup(a0, a1) { // fn#110686, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14849:333, offset: 0x02382a1a, size: 277 bytes, params: 3, frame: 21
|
||||
var r5;
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = undefined;
|
||||
const guild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110687);
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110688);
|
||||
const spent = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0).spent;
|
||||
let value = env0_3.useMemo(_fun110689, [a1, stateForGuild]);
|
||||
if (value == null) {
|
||||
r5 = value2;
|
||||
} else {
|
||||
value = value.reduce(function(a0, a1) {
|
||||
return a0 + a1.cost;
|
||||
}, 0);
|
||||
r5 = value;
|
||||
}
|
||||
const Math = global.Math;
|
||||
const max = Math.max;
|
||||
const premiumSubscriberCount = guild == null ? value2 : guild.premiumSubscriberCount;
|
||||
value = 0;
|
||||
return Reflect.apply(max, Math, [(premiumSubscriberCount ?? value) - spent + (r5 ?? value), value]);
|
||||
}
|
||||
|
||||
function _fun110689() { // fn#110689, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14849:534, offset: 0x02382b4a, size: 192 bytes, params: 1, frame: 14
|
||||
var r0;
|
||||
var value;
|
||||
if (require == null) {
|
||||
return [];
|
||||
}
|
||||
const type = require.type;
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
if (type !== LEVEL) {
|
||||
return [];
|
||||
}
|
||||
if (stateForGuild == null) {
|
||||
return [];
|
||||
}
|
||||
if (LEVEL_SKU_ID_TO_BOOSTING_TIER[require.skuId] == null) {
|
||||
r0 = [];
|
||||
} else {
|
||||
value = global.Object.entries(POWERUPS_INCLUDED_IN_LEVEL);
|
||||
value = value.filter(_fun110690);
|
||||
value = value.map(_fun110691);
|
||||
value = value.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110690(a0) { // fn#110690, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14849:647, offset: 0x02382c0a, size: 102 bytes, params: 2, frame: 7
|
||||
var r0;
|
||||
var r1;
|
||||
var r3;
|
||||
var item3;
|
||||
var value3;
|
||||
const iterator = a0[Symbol.iterator]();
|
||||
const iterator2 = iterator.next;
|
||||
let item2 = Reflect.apply(iterator2, iterator, []);
|
||||
let item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
let value = undefined;
|
||||
const value2 = item2 === value;
|
||||
const r2 = value2 ? value : item;
|
||||
if (value2) {
|
||||
r0 = item2;
|
||||
r1 = value;
|
||||
r3 = value2;
|
||||
} else {
|
||||
item3 = Reflect.apply(iterator2, item2, []);
|
||||
item = item3.value;
|
||||
item3 = item3.done ? undefined : item2;
|
||||
value3 = item3 === value;
|
||||
if (value3) {
|
||||
r0 = item3;
|
||||
r1 = value;
|
||||
r3 = value3;
|
||||
} else {
|
||||
r0 = item3;
|
||||
r1 = item;
|
||||
r3 = value3;
|
||||
}
|
||||
}
|
||||
if (!r3) {
|
||||
r0.return();
|
||||
}
|
||||
value = r1 === env0_0;
|
||||
if (value) {
|
||||
value = environment.__proto__;
|
||||
value = stateForGuild.unlockedPowerups[r2] != null;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110691(a0) { // fn#110691, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14849:698, offset: 0x02382c70, size: 50 bytes, params: 2, frame: 5
|
||||
const iterator = a0[Symbol.iterator]();
|
||||
let item2 = iterator.next();
|
||||
const item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
let value = undefined;
|
||||
const value2 = item2 === value;
|
||||
const r1 = value2 ? value : item;
|
||||
if (!value2) {
|
||||
item2.return();
|
||||
}
|
||||
value = environment.__proto__;
|
||||
return stateForGuild.allPowerups[r1];
|
||||
}
|
||||
|
||||
@@ -0,0 +1,259 @@
|
||||
/* Metro module 14613; source: modules/premium/powerups/hooks/useBoostToUnlockFeaturedPowerup.tsx; dependencies: [57, 31, 1867, 8258, 8259, 661, 8188, 566, 8254, 14614, 2] */
|
||||
function _fun110499(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110499, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14810:6, offset: 0x0237b3ab, size: 456 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const _arrayLikeToArray_110502 = function(a0, a1) {
|
||||
var r0;
|
||||
var r1;
|
||||
var r2;
|
||||
var value3;
|
||||
var length;
|
||||
var value5;
|
||||
var value = undefined;
|
||||
var value2 = value == null;
|
||||
reducibleJoin2: while (true) {
|
||||
if (value2) {
|
||||
r0 = value2;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
value3 = value > a0.length;
|
||||
r0 = value3;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
reducibleJoin4: while (true) {
|
||||
if (r0) {
|
||||
length = a0.length;
|
||||
r1 = length;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
r1 = value;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
value = (0, global.Array)(r1);
|
||||
var value4 = 0;
|
||||
if (value4 < r1) {
|
||||
r2 = value4;
|
||||
reducibleLoop5: while (true) {
|
||||
value[r2] = a0[r2];
|
||||
value5 = typeof r2 === 'bigint' ? r2 + 1n : +r2 + 1;
|
||||
if (value5 < r1) {
|
||||
r2 = value5;
|
||||
continue reducibleLoop5;
|
||||
}
|
||||
break reducibleLoop5;
|
||||
}
|
||||
}
|
||||
return value;
|
||||
};
|
||||
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 guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const env0_7 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS;
|
||||
const env0_8 = (require(661) /* metro dependency 661: Constants */).GuildFeatures;
|
||||
const GUILD_POWERUP_LEVEL_1_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_1_SKU_ID;
|
||||
const items2 = [{skuId: GUILD_POWERUP_LEVEL_1_SKU_ID, threshold: 1}];
|
||||
const GUILD_POWERUP_LEVEL_2_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_2_SKU_ID;
|
||||
items2[1] = {skuId: GUILD_POWERUP_LEVEL_2_SKU_ID, threshold: 2};
|
||||
const GUILD_POWERUP_LEVEL_3_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_3_SKU_ID;
|
||||
items2[2] = {skuId: GUILD_POWERUP_LEVEL_3_SKU_ID, threshold: 2};
|
||||
const GUILD_POWERUP_TAG_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_TAG_SKU_ID;
|
||||
items2[3] = {skuId: GUILD_POWERUP_TAG_SKU_ID, threshold: 1};
|
||||
const GUILD_POWERUP_ROLE_COLOR_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_ROLE_COLOR_SKU_ID;
|
||||
items2[4] = {skuId: GUILD_POWERUP_ROLE_COLOR_SKU_ID, threshold: 1};
|
||||
const GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID;
|
||||
items2[5] = {skuId: GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID, threshold: 1};
|
||||
const GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID;
|
||||
items2[6] = {skuId: GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID, threshold: 1};
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useBoostToUnlockFeaturedPowerup.tsx');
|
||||
exports.default = useBoostToUnlockFeaturedPowerup;
|
||||
}
|
||||
|
||||
function _createForOfIteratorHelperLoose_110500(a0, a1) { // fn#110500, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14810:214, offset: 0x0237b573, size: 372 bytes, params: 3, frame: 20
|
||||
var r6;
|
||||
var r9;
|
||||
var r5;
|
||||
var value3;
|
||||
var regexp;
|
||||
const env0_0 = a0;
|
||||
const Symbol = global.Symbol;
|
||||
let value = typeof Symbol !== 'undefined';
|
||||
let r1 = value && a0[global.Symbol.iterator];
|
||||
r1 = !r1 ? a0['@@iterator'] : r1;
|
||||
if (r1) {
|
||||
value = r1.call(a0);
|
||||
return value.next.bind(value);
|
||||
}
|
||||
const Array = global.Array;
|
||||
if (Array.isArray(a0)) {
|
||||
if (r1) {
|
||||
}
|
||||
return _fun110501;
|
||||
}
|
||||
value = undefined;
|
||||
if (a0) {
|
||||
if (typeof a0 === 'string') {
|
||||
value = _arrayLikeToArray_110502(a0, value);
|
||||
r5 = value;
|
||||
} else {
|
||||
value3 = ({}).toString.call(a0).slice(8, -1);
|
||||
r6 = value3 === 'Object' && a0.constructor;
|
||||
r9 = r6 ? a0.constructor.name : value3;
|
||||
if (r9 === 'Map') {
|
||||
r6 = global.Array.from(a0);
|
||||
} else if (r9 === 'Set') {
|
||||
r6 = global.Array.from(a0);
|
||||
} else if (r9 === 'Arguments') {
|
||||
value = _arrayLikeToArray_110502(a0, value);
|
||||
r6 = value;
|
||||
} else {
|
||||
regexp = RegExp('^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$', '');
|
||||
if (regexp.test(r9)) {
|
||||
value = _arrayLikeToArray_110502(a0, value);
|
||||
r6 = value;
|
||||
} else {
|
||||
r6 = value;
|
||||
}
|
||||
}
|
||||
r5 = r6;
|
||||
}
|
||||
} else {
|
||||
r5 = value;
|
||||
}
|
||||
if (r5) {
|
||||
if (r5) {
|
||||
}
|
||||
return _fun110501;
|
||||
}
|
||||
const TypeError = global.TypeError;
|
||||
throw new TypeError('Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.');
|
||||
}
|
||||
|
||||
function useBoostToUnlockFeaturedPowerup(a0) { // fn#110503, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14810:1676, offset: 0x0237b6e7, size: 263 bytes, params: 2, frame: 20
|
||||
const env0_0 = a0;
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110504);
|
||||
const available = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0).available;
|
||||
const value2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110505);
|
||||
const env0_3 = value2;
|
||||
const value3 = (require(14614) /* metro dependency 14614: BoostToUnlockCoachmarkExperiment */).useBoostToUnlockCoachmarkEnabled('useBoostToUnlockFeaturedPowerup');
|
||||
const binding = value3;
|
||||
return binding.useMemo(_fun110507, [stateForGuild, available, value2, value3, env0_3(binding.useState(function() {
|
||||
var Math = global.Math;
|
||||
return Math.random();
|
||||
}), 1)[0]]);
|
||||
}
|
||||
|
||||
function _fun110505() { // fn#110505, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14810:1845, offset: 0x0237b7ee, size: 70 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return (guild == null ? undefined : guild.features.has(GuildFeatures.PREMIUM_TIER_3_OVERRIDE)) === true;
|
||||
}
|
||||
|
||||
function _fun110507() { // fn#110507, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14810:2088, offset: 0x0237b834, size: 303 bytes, params: 1, frame: 26
|
||||
var environment;
|
||||
var r5;
|
||||
var r14;
|
||||
var allPowerups;
|
||||
var unlockedPowerups;
|
||||
var items2;
|
||||
var value2;
|
||||
var value3;
|
||||
var value4;
|
||||
var done;
|
||||
var value5;
|
||||
var skuId;
|
||||
var threshold;
|
||||
var property;
|
||||
var has;
|
||||
var dependencies;
|
||||
var every;
|
||||
var cost;
|
||||
var value6;
|
||||
var value7;
|
||||
var value8;
|
||||
var push;
|
||||
var value9;
|
||||
var length;
|
||||
var Math;
|
||||
let stateForGuildBinding = stateForGuild;
|
||||
if (stateForGuildBinding != null) {
|
||||
reducibleJoin14: while (true) {
|
||||
if (env0_4) {
|
||||
stateForGuildBinding = stateForGuild;
|
||||
allPowerups = stateForGuildBinding.allPowerups;
|
||||
unlockedPowerups = stateForGuildBinding.unlockedPowerups;
|
||||
var env0_0 = unlockedPowerups;
|
||||
items2 = [];
|
||||
value2 = environment.__proto__;
|
||||
value3 = _createForOfIteratorHelperLoose_110500(env1_9);
|
||||
value4 = value3();
|
||||
done = value4.done;
|
||||
if (!done) {
|
||||
r5 = value4;
|
||||
reducibleLoop3: while (true) {
|
||||
value5 = r5.value;
|
||||
skuId = value5.skuId;
|
||||
threshold = value5.threshold;
|
||||
property = allPowerups[skuId];
|
||||
reducibleJoin12: while (true) {
|
||||
if (property == null) {
|
||||
break reducibleJoin12;
|
||||
}
|
||||
if (env0_3) {
|
||||
has = GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS.has;
|
||||
if (Reflect.apply(has, GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS, [skuId])) {
|
||||
break reducibleJoin12;
|
||||
}
|
||||
}
|
||||
if (unlockedPowerups[skuId] != null) {
|
||||
break reducibleJoin12;
|
||||
}
|
||||
dependencies = property.dependencies;
|
||||
every = dependencies.every;
|
||||
if (Reflect.apply(every, dependencies, [function(a0) {
|
||||
return unlockedPowerups[a0] != null;
|
||||
}])) {
|
||||
cost = property.cost;
|
||||
value6 = cost - available;
|
||||
value7 = value6 > 0;
|
||||
reducibleJoin10: while (true) {
|
||||
if (value7) {
|
||||
value8 = value6 <= threshold;
|
||||
r14 = value8;
|
||||
break reducibleJoin10;
|
||||
}
|
||||
r14 = value7;
|
||||
break reducibleJoin10;
|
||||
}
|
||||
if (r14) {
|
||||
push = items2.push;
|
||||
Reflect.apply(push, items2, [property]);
|
||||
break reducibleJoin12;
|
||||
}
|
||||
break reducibleJoin12;
|
||||
}
|
||||
break reducibleJoin12;
|
||||
}
|
||||
value9 = value3();
|
||||
done = value9.done;
|
||||
if (done) {
|
||||
break reducibleLoop3;
|
||||
}
|
||||
r5 = value9;
|
||||
continue reducibleLoop3;
|
||||
}
|
||||
}
|
||||
length = items2.length;
|
||||
if (length > 0) {
|
||||
Math = global.Math;
|
||||
return items2[Math.floor(env0_5 * items2.length)];
|
||||
}
|
||||
break reducibleJoin14;
|
||||
}
|
||||
break reducibleJoin14;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,69 @@
|
||||
/* Metro module 14649; source: modules/premium/powerups/hooks/useCanGuildPowerupBeToggled.tsx; dependencies: [31, 8258, 8259, 566, 14635, 1244, 2256, 2] */
|
||||
function _fun110664(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110664, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14846:6, offset: 0x0238202a, size: 159 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const env0_5 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).PowerupActiveStatusType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useCanGuildPowerupBeToggled.tsx');
|
||||
exports.default = useCanGuildPowerupBeToggled;
|
||||
}
|
||||
|
||||
function useCanGuildPowerupBeToggled(a0, a1, a2) { // fn#110665, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14846:256, offset: 0x023820c9, size: 172 bytes, params: 4, frame: 20
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const env0_2 = a2;
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110666);
|
||||
return stateForGuild.useMemo(_fun110667, [stateForGuild, a1.skuId, a1.dependencies, a2,
|
||||
(importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(a0, a1).type]);
|
||||
}
|
||||
|
||||
function _fun110667() { // fn#110667, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14846:399, offset: 0x02382175, size: 339 bytes, params: 1, frame: 21
|
||||
var r3;
|
||||
var r1;
|
||||
var intl;
|
||||
var formatToPlainString;
|
||||
var property;
|
||||
var value;
|
||||
if (stateForGuild == null) {
|
||||
return {disabled: true, reason: undefined};
|
||||
}
|
||||
const type = env0_4.type;
|
||||
const LEVEL_ACTIVATED = PowerupActiveStatusType.LEVEL_ACTIVATED;
|
||||
if (type === LEVEL_ACTIVATED) {
|
||||
return {disabled: true, reason: undefined};
|
||||
}
|
||||
stateForGuildBinding = stateForGuild;
|
||||
const allPowerups = stateForGuildBinding.allPowerups;
|
||||
const r7 = importDefault ? global.Object.values(stateForGuildBinding.unlockedPowerups).find(_fun110668)?.sku_id : require.dependencies.find(function(a0) {
|
||||
return unlockedPowerups[a0] == null;
|
||||
});
|
||||
const object2 = {disabled: r7 != null};
|
||||
const value7 = undefined;
|
||||
if (r7 != null) {
|
||||
if (allPowerups[r7] != null) {
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
value = importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */;
|
||||
r3 = importDefault ? value.vCEBiS : value['1B8AZr'];
|
||||
property = allPowerups[r7];
|
||||
value = Reflect.apply(formatToPlainString, intl, [r3, {perk: property == null ? value7 : property.title}]);
|
||||
r1 = value;
|
||||
} else {
|
||||
r1 = value7;
|
||||
}
|
||||
} else {
|
||||
r1 = value7;
|
||||
}
|
||||
object2.reason = r1;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun110668({sku}) { // fn#110668, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14846:598, offset: 0x023822c8, size: 44 bytes, params: 2, frame: 3
|
||||
const dependent_sku_id = sku?.dependent_sku_id;
|
||||
value = environment.__proto__;
|
||||
return dependent_sku_id === require.skuId;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,96 @@
|
||||
/* Metro module 14656; source: modules/premium/powerups/hooks/useDeactivateWarningText.tsx; dependencies: [31, 4111, 1938, 1867, 566, 6736, 8188, 1244, 2256, 2] */
|
||||
function _fun110704(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110704, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:6, offset: 0x023833c1, size: 169 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildMemberCountStore = importDefault(4111) /* metro dependency 4111: GuildMemberCountStore */;
|
||||
const guildRoleStore = importDefault(1938) /* metro dependency 1938: GuildRoleStore */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useDeactivateWarningText.tsx');
|
||||
exports.default = useDeactivateWarningText;
|
||||
}
|
||||
|
||||
function useDeactivateWarningText(a0, a1) { // fn#110705, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:239, offset: 0x0238346a, size: 252 bytes, params: 3, frame: 24
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const memberCount = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildMemberCountStore],
|
||||
_fun110706);
|
||||
const value2 = (importDefault(6736) /* metro dependency 6736: useGuildRoleMemberCounts */)(a0);
|
||||
return value2.useMemo(_fun110710, [a1,
|
||||
(require(566) /* metro dependency 566: flux */).useStateFromStores([GuildRoleStore], _fun110708, [a0, a1.skuId,
|
||||
value2]), memberCount, (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore],
|
||||
_fun110707)]);
|
||||
}
|
||||
|
||||
function _fun110706() { // fn#110706, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:316, offset: 0x02383566, size: 27 bytes, params: 1, frame: 11
|
||||
return GuildMemberCountStore.getMemberCount(env0_0);
|
||||
}
|
||||
|
||||
function _fun110707() { // fn#110707, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:389, offset: 0x02383581, size: 48 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
return GuildStore.getGuild(env0_0)?.vanityURLCode != null;
|
||||
}
|
||||
|
||||
function _fun110708() { // fn#110708, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:499, offset: 0x023835b1, size: 108 bytes, params: 1, frame: 15
|
||||
var r0;
|
||||
var value;
|
||||
const skuId = require.skuId;
|
||||
const GUILD_POWERUP_ROLE_COLOR_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_ROLE_COLOR_SKU_ID;
|
||||
const value3 = 0;
|
||||
if (skuId !== GUILD_POWERUP_ROLE_COLOR_SKU_ID) {
|
||||
r0 = value3;
|
||||
} else if (env0_3 == null) {
|
||||
r0 = value3;
|
||||
} else {
|
||||
value = GuildRoleStore.getSortedRoles(env0_0);
|
||||
value = value.reduce(_fun110709, value3);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110710() { // fn#110710, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:739, offset: 0x02383663, size: 688 bytes, params: 1, frame: 20
|
||||
var r2;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var string;
|
||||
var binding;
|
||||
var defaultImport;
|
||||
const skuId = require.skuId;
|
||||
const GUILD_POWERUP_ROLE_COLOR_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_ROLE_COLOR_SKU_ID;
|
||||
if (GUILD_POWERUP_ROLE_COLOR_SKU_ID === skuId) {
|
||||
r2 = env0_5 > 0 ? intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['4jSvr1'],
|
||||
|
||||
{perk: require.title,
|
||||
memberCount: env0_5}) : intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).cavtEo,
|
||||
|
||||
{perk: require.title});
|
||||
} else if ((require(8188) /* metro dependency 8188: Powerups */).VANITY_URL_POWERUP_SKU_ID === skuId) {
|
||||
binding = env0_4;
|
||||
string = intl.string;
|
||||
defaultImport = importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */;
|
||||
r2 = binding ? Reflect.apply(string, intl, [defaultImport.hN75yb]) : Reflect.apply(string, intl,
|
||||
[defaultImport.Du91Rb]);
|
||||
} else {
|
||||
r2 = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID === skuId || (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID === skuId ? intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).Vf2ZcR) : intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['4jSvr1'],
|
||||
|
||||
{perk: require.title, memberCount: memberCount ?? 0});
|
||||
}
|
||||
return {warningText: r2,
|
||||
vanityUrlWarning: env0_4 && require.skuId === (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_LEVEL_3_SKU_ID ? intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).M4XL5n) : null};
|
||||
}
|
||||
|
||||
function _fun110709(a0, a1) { // fn#110709, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14853:592, offset: 0x0238361d, size: 70 bytes, params: 3, frame: 6
|
||||
var r0;
|
||||
var value3;
|
||||
let value = a0;
|
||||
if (a1.colorStrings?.secondaryColor == null) {
|
||||
r0 = value;
|
||||
} else {
|
||||
value3 = environment.__proto__;
|
||||
value += env1_3[a1.id] ?? 0;
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,144 @@
|
||||
/* Metro module 14615; source: modules/premium/powerups/hooks/useFeaturedExpiringPowerup.tsx; dependencies: [31, 8255, 8258, 566, 14616, 5134, 2] */
|
||||
function _fun110511(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110511, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14812:6, offset: 0x0237ba0e, size: 149 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
const gameServerStore = importDefault(8255) /* metro dependency 8255: GameServerStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useFeaturedExpiringPowerup.tsx');
|
||||
exports.default = useFeaturedExpiringPowerup;
|
||||
}
|
||||
|
||||
function useFeaturedExpiringPowerup(a0) { // fn#110512, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14812:231, offset: 0x0237baa3, size: 184 bytes, params: 2, frame: 19
|
||||
const env0_0 = a0;
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110513);
|
||||
const stateForGuild2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GameServerStore],
|
||||
_fun110514);
|
||||
return stateForGuild2.useMemo(_fun110515, [stateForGuild, stateForGuild2,
|
||||
(require(14616) /* metro dependency 14616: ExpiringPowerupCoachmarkExperiment */).useExpiringPowerupCoachmarkEnabled('useFeaturedExpiringPowerup')]);
|
||||
}
|
||||
|
||||
function _fun110515() { // fn#110515, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14812:491, offset: 0x0237bb91, size: 463 bytes, params: 1, frame: 23
|
||||
var environment;
|
||||
var unlockedPowerups;
|
||||
var r1;
|
||||
var entitlements;
|
||||
var title;
|
||||
var r7;
|
||||
var num_expiring_boosts;
|
||||
var Object;
|
||||
var values;
|
||||
var stateForGuildBinding;
|
||||
var value2;
|
||||
var value3;
|
||||
var object;
|
||||
var value4;
|
||||
var value5;
|
||||
var value6;
|
||||
var value7;
|
||||
var value8;
|
||||
var sku;
|
||||
var Math;
|
||||
var max;
|
||||
var value9;
|
||||
var moduleValue;
|
||||
var getDaysRemaining;
|
||||
var Date;
|
||||
var ends_at;
|
||||
var value10;
|
||||
var date;
|
||||
var metadata;
|
||||
var value;
|
||||
if (env0_3) {
|
||||
Object = global.Object;
|
||||
values = Object.values;
|
||||
stateForGuildBinding = stateForGuild;
|
||||
value2 = null;
|
||||
value3 = undefined;
|
||||
unlockedPowerups = value2 == stateForGuildBinding ? value3 : stateForGuild.unlockedPowerups;
|
||||
r1 = value2 != unlockedPowerups ? unlockedPowerups : {};
|
||||
value4 = Reflect.apply(values, Object, [r1]);
|
||||
object = [];
|
||||
value5 = 0;
|
||||
value6 = arraySpread(object, value4, value5, undefined);
|
||||
Object = global.Object;
|
||||
values = Object.values;
|
||||
entitlements = value2 == stateForGuild ? value3 : stateForGuild.entitlements;
|
||||
r1 = value2 != entitlements ? entitlements : {};
|
||||
arraySpread(object, Reflect.apply(values, Object, [r1]), value6, undefined);
|
||||
value7 = object.filter(function(a0) {
|
||||
var r3;
|
||||
var r0;
|
||||
var property;
|
||||
var value = a0.ends_at != null;
|
||||
if (value) {
|
||||
property = a0.metadata;
|
||||
value = undefined;
|
||||
r3 = property == null ? value : property.num_expiring_boosts;
|
||||
value = 0;
|
||||
value = (r3 ?? value) > value;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
});
|
||||
if (value5 === value7.length) {
|
||||
return undefined;
|
||||
}
|
||||
value8 = value7.reduce(_fun110517);
|
||||
title = value2 == stateForGuild || value2 == stateForGuild.allPowerups[value8.sku_id] ? value3 : stateForGuild.allPowerups[value8.sku_id].title;
|
||||
r7 = value2 != title ? title : value2;
|
||||
sku = value8.sku;
|
||||
value = value2 != (value2 == sku || value2 == sku.tenant_metadata || value2 == sku.tenant_metadata.guild_monetization ? value3 : sku.tenant_metadata.guild_monetization.game_server);
|
||||
if (value2 !== r7) {
|
||||
object = {name: r7};
|
||||
Math = global.Math;
|
||||
max = Math.max;
|
||||
value9 = environment.__proto__;
|
||||
moduleValue = require(5134) /* metro dependency 5134: CollectiblesUtils */;
|
||||
getDaysRemaining = moduleValue.getDaysRemaining;
|
||||
Date = global.Date;
|
||||
ends_at = value8.ends_at;
|
||||
value10 = Object.create(Date.prototype, {constructor: {value: Date}});
|
||||
date = new Date();
|
||||
object.daysUntilExpiry = Reflect.apply(max, Math, [value5, Reflect.apply(getDaysRemaining, moduleValue,
|
||||
[date instanceof Object ? date : value10])]);
|
||||
metadata = value8.metadata;
|
||||
num_expiring_boosts = value2 == metadata ? value3 : metadata.num_expiring_boosts;
|
||||
object.numExpiringBoosts = value2 != num_expiring_boosts ? num_expiring_boosts : value5;
|
||||
object.isGameServer = value;
|
||||
object.skuId = value8.sku_id;
|
||||
return object;
|
||||
}
|
||||
if (value) {
|
||||
object = {name: r7};
|
||||
Math = global.Math;
|
||||
max = Math.max;
|
||||
value9 = environment.__proto__;
|
||||
moduleValue = require(5134) /* metro dependency 5134: CollectiblesUtils */;
|
||||
getDaysRemaining = moduleValue.getDaysRemaining;
|
||||
Date = global.Date;
|
||||
ends_at = value8.ends_at;
|
||||
value10 = Object.create(Date.prototype, {constructor: {value: Date}});
|
||||
date = new Date();
|
||||
object.daysUntilExpiry = Reflect.apply(max, Math, [value5, Reflect.apply(getDaysRemaining, moduleValue,
|
||||
[date instanceof Object ? date : value10])]);
|
||||
metadata = value8.metadata;
|
||||
num_expiring_boosts = value2 == metadata ? value3 : metadata.num_expiring_boosts;
|
||||
object.numExpiringBoosts = value2 != num_expiring_boosts ? num_expiring_boosts : value5;
|
||||
object.isGameServer = value;
|
||||
object.skuId = value8.sku_id;
|
||||
return object;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110517(a0, a1) { // fn#110517, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14812:806, offset: 0x0237bd9b, size: 27 bytes, params: 3, frame: 4
|
||||
const value = a0;
|
||||
const value2 = a1;
|
||||
return value2.ends_at > value.ends_at ? value2 : value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
/* Metro module 14625; source: modules/premium/powerups/hooks/useGetExpiringGuildPowerups.tsx; dependencies: [31, 8258, 566, 14609, 1360, 2] */
|
||||
function _fun110558(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110558, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14822:6, offset: 0x0237d3b2, size: 133 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGetExpiringGuildPowerups.tsx');
|
||||
exports.default = useGetExpiringGuildPowerups;
|
||||
}
|
||||
|
||||
function useGetExpiringGuildPowerups(a0) { // fn#110559, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14822:222, offset: 0x0237d437, size: 100 bytes, params: 2, frame: 15
|
||||
const env0_0 = a0;
|
||||
return env0_2.useMemo(_fun110561,
|
||||
[(require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore], _fun110560)]);
|
||||
}
|
||||
|
||||
function _fun110561() { // fn#110561, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14822:346, offset: 0x0237d49b, size: 145 bytes, params: 1, frame: 17
|
||||
var environment;
|
||||
if (stateForGuild == null) {
|
||||
return [];
|
||||
}
|
||||
stateForGuildBinding = stateForGuild;
|
||||
const env0_0 = stateForGuildBinding.allPowerups;
|
||||
const unlockedPowerups = stateForGuildBinding.unlockedPowerups;
|
||||
let value = environment.__proto__;
|
||||
const getExpiringGuildEntitlements = (require(14609) /* metro dependency 14609: getExpiringGuildEntitlements */).getExpiringGuildEntitlements;
|
||||
const Object = global.Object;
|
||||
value = Reflect.apply(getExpiringGuildEntitlements, value, [Object.values(unlockedPowerups)]);
|
||||
value = value.map(function(a0) {
|
||||
return allPowerups[a0.sku_id];
|
||||
});
|
||||
return value.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
/* Metro module 14640; source: modules/premium/powerups/hooks/useGetGuildPowerupBannerImage.tsx; dependencies: [4502, 566, 2] */
|
||||
function _fun110635(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110635, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14837:6, offset: 0x02380d1e, size: 131 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const closure = function(a0, a1, a2, a3) {
|
||||
if (a0 != null) {
|
||||
return a1 || a2 === false || a3 ? a0.staticImageUrl : a0.animatedImageUrl ?? a0.staticImageUrl;
|
||||
}
|
||||
};
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGetGuildPowerupBannerImage.tsx');
|
||||
exports.default = useGetGuildPowerupBannerImage;
|
||||
exports.getGuildPowerupBannerImage = closure;
|
||||
}
|
||||
|
||||
function useGetGuildPowerupBannerImage(a0, a1, a2) { // fn#110637, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14837:361, offset: 0x02380ddd, size: 78 bytes, params: 4, frame: 17
|
||||
const getGuildPowerupBannerImageBinding = getGuildPowerupBannerImage;
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
return getGuildPowerupBannerImageBinding(a0, useReducedMotion, a1, a2);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
/* Metro module 14648; source: modules/premium/powerups/hooks/useGuildPowerupCardFooterConfig.tsx; dependencies: [1867, 8259, 661, 14635, 566, 8188, 14610, 2] */
|
||||
function _fun110661(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110661, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14845:6, offset: 0x02381e27, size: 178 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
guildPowerupsConstantsModule.GUILD_POWERUP_CONFIGURABLE_SKUS_DESKTOP;
|
||||
const env0_4 = guildPowerupsConstantsModule.GUILD_POWERUP_CONFIGURABLE_SKUS_MOBILE;
|
||||
const env0_5 = guildPowerupsConstantsModule.PowerupActiveStatusType;
|
||||
const env0_6 = (require(661) /* metro dependency 661: Constants */).GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupCardFooterConfig.tsx');
|
||||
exports.default = useGuildPowerupCardFooterConfig;
|
||||
}
|
||||
|
||||
function useGuildPowerupCardFooterConfig(a0, a1) { // fn#110662, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14845:365, offset: 0x02381ed9, size: 267 bytes, params: 3, frame: 23
|
||||
const env0_0 = a0;
|
||||
const value2 = (importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(a0, a1);
|
||||
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110663, [a0]);
|
||||
const skuId = a1.skuId;
|
||||
const GUILD_POWERUP_GUILD_THEME_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
const value4 = skuId === GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
let type = value2.type;
|
||||
const INACTIVE = PowerupActiveStatusType.INACTIVE;
|
||||
const r1 = type !== INACTIVE || value4 && value3;
|
||||
type = value2.type;
|
||||
const TIER_OVERRIDE_ACTIVATED = PowerupActiveStatusType.TIER_OVERRIDE_ACTIVATED;
|
||||
return {showToggleButton: (r1 || !(importDefault(14610) /* metro dependency 14610: useGuildPowerupRollbackEnabled */)(a0,
|
||||
a1, 'GuildPowerupCardFooterAdmin')) && !(type === TIER_OVERRIDE_ACTIVATED),
|
||||
showConfigureButton: r1 && GUILD_POWERUP_CONFIGURABLE_SKUS_MOBILE.has(a1.skuId), isPowerupActive: r1};
|
||||
}
|
||||
|
||||
function _fun110663() { // fn#110663, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14845:464, offset: 0x02381fe4, size: 70 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return (guild == null ? undefined : guild.features.has(GuildFeatures.GUILD_THEME)) === true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
/* Metro module 14624; source: modules/premium/powerups/hooks/useGuildPowerupExpiringNotificationsConfig.tsx; dependencies: [14625, 14626, 1244, 2646, 8188, 2256, 2] */
|
||||
function _fun110554(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110554, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14821:6, offset: 0x0237d160, size: 103 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupExpiringNotificationsConfig.tsx');
|
||||
exports.default = useGuildPowerupExpiringNotificationsConfig;
|
||||
}
|
||||
|
||||
function useGuildPowerupExpiringNotificationsConfig(a0) { // fn#110555, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14821:213, offset: 0x0237d1c7, size: 446 bytes, params: 2, frame: 24
|
||||
var r11;
|
||||
var items;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var value8;
|
||||
var items3;
|
||||
const value2 = undefined;
|
||||
const value3 = (importDefault(14625) /* metro dependency 14625: useGetExpiringGuildPowerups */)(a0);
|
||||
const value4 = (importDefault(14626) /* metro dependency 14626: useGameServerGetExpiringEntitlements */)(a0);
|
||||
let length = value3.length;
|
||||
const r4 = length > 0 || value4.length > 0;
|
||||
if (r4) {
|
||||
length = value4.length;
|
||||
r11 = length > 0 ? intl.string((importDefault(2646) /* metro dependency 2646: GameServerMessages */)['B3OfL/']) : value2;
|
||||
value8 = value3.map(function(a0) {
|
||||
return a0.title;
|
||||
});
|
||||
items = [];
|
||||
arraySpread(items, r11 != null ? [r11] : [], arraySpread(items, value8, 0, undefined), undefined);
|
||||
items3 = [];
|
||||
if (value3.some(_fun110557)) {
|
||||
items3.push(intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).Sfr0Jw));
|
||||
}
|
||||
length = value4.length;
|
||||
if (length > 0) {
|
||||
items3.push(intl.string((importDefault(2646) /* metro dependency 2646: GameServerMessages */).wiungr));
|
||||
}
|
||||
return {shouldShow: r4, expiringPowerups: value3, expiringPowerupNames: items, warnings: items3};
|
||||
}
|
||||
return {shouldShow: false, expiringPowerups: [], expiringPowerupNames: [], warnings: []};
|
||||
}
|
||||
|
||||
function _fun110557({skuId}) { // fn#110557, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14821:535, offset: 0x0237d385, size: 45 bytes, params: 2, frame: 12
|
||||
const VANITY_URL_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).VANITY_URL_POWERUP_SKU_ID;
|
||||
return skuId === VANITY_URL_POWERUP_SKU_ID;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,89 @@
|
||||
/* Metro module 14647; source: modules/premium/powerups/hooks/useGuildPowerupLevelPerks.tsx; dependencies: [31, 8259, 8249, 1244, 2256, 1360, 2] */
|
||||
function _fun110657(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110657, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14844:6, offset: 0x02381ae3, size: 143 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(8259) /* metro dependency 8259: GuildPowerupsConstants */).GUILD_FEATURE_TO_PERK;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupLevelPerks.tsx');
|
||||
exports.default = useGuildPowerupLevelPerks;
|
||||
}
|
||||
|
||||
function useGuildPowerupLevelPerks(a0) { // fn#110658, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14844:242, offset: 0x02381b72, size: 109 bytes, params: 2, frame: 17
|
||||
const value = a1;
|
||||
const env0_0 = a0;
|
||||
const {includeEmojis, includeStickers, includeSoundboards} = value !== undefined ? value : {'includeEmojis': true,
|
||||
'includeStickers': true, 'includeSoundboards': true};
|
||||
return includeSoundboards.useMemo(_fun110659, [a0, includeEmojis, includeStickers, includeSoundboards]);
|
||||
}
|
||||
|
||||
function _fun110659() { // fn#110659, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14844:415, offset: 0x02381bdf, size: 584 bytes, params: 1, frame: 22
|
||||
var push;
|
||||
var object7;
|
||||
const PerkIcons = (require(8249) /* metro dependency 8249: GuildBoostingUtils */).PerkIcons;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var formatToPlainString;
|
||||
var property;
|
||||
var object8;
|
||||
var binding;
|
||||
var features;
|
||||
var object9;
|
||||
var ZEvvPz;
|
||||
var object10;
|
||||
var object11;
|
||||
var object12;
|
||||
const items2 = [];
|
||||
const env0_0 = GUILD_FEATURE_TO_PERK();
|
||||
if (includeEmojis) {
|
||||
push = items2.push;
|
||||
object7 = {};
|
||||
object7.perkIcon = PerkIcons.EMOJI;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['NXvV0+'];
|
||||
object8 = {};
|
||||
binding = env0_0;
|
||||
features = binding.features;
|
||||
object8.totalEmojis = features.total_emoji_slots;
|
||||
features = binding.features;
|
||||
object8.additionalEmojis = features.additional_emoji_slots;
|
||||
object7.description = Reflect.apply(formatToPlainString, intl, [property, object8]);
|
||||
Reflect.apply(push, items2, [object7]);
|
||||
}
|
||||
if (includeStickers) {
|
||||
push = items2.push;
|
||||
object9 = {};
|
||||
object9.perkIcon = PerkIcons.STICKER;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
ZEvvPz = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).ZEvvPz;
|
||||
object10 = {};
|
||||
binding = env0_0;
|
||||
features = binding.features;
|
||||
object10.totalStickers = features.total_sticker_slots;
|
||||
features = binding.features;
|
||||
object10.additionalStickers = features.additional_sticker_slots;
|
||||
object9.description = Reflect.apply(formatToPlainString, intl, [ZEvvPz, object10]);
|
||||
Reflect.apply(push, items2, [object9]);
|
||||
}
|
||||
if (includeSoundboards) {
|
||||
push = items2.push;
|
||||
object11 = {};
|
||||
object11.perkIcon = PerkIcons.SOUNDBOARD;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['s9u/E7'];
|
||||
object12 = {};
|
||||
binding = env0_0;
|
||||
features = binding.features;
|
||||
object12.totalSoundboards = features.total_sound_slots;
|
||||
features = binding.features;
|
||||
object12.additionalSoundboards = features.additional_sound_slots;
|
||||
object11.description = Reflect.apply(formatToPlainString, intl, [property, object12]);
|
||||
Reflect.apply(push, items2, [object11]);
|
||||
}
|
||||
const concat = items2.concat;
|
||||
features = env0_0.features;
|
||||
features = features.features;
|
||||
const value3 = features.map(_fun110660);
|
||||
return Reflect.apply(concat, items2,
|
||||
[value3.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish)]);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
/* Metro module 14655; source: modules/premium/powerups/hooks/useGuildPowerupOnDeactivate.tsx; dependencies: [31, 14651, 2] */
|
||||
function _fun110701(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110701, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14852:6, offset: 0x023832e0, size: 117 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupOnDeactivate.tsx');
|
||||
exports.default = useGuildPowerupOnDeactivate;
|
||||
}
|
||||
|
||||
function useGuildPowerupOnDeactivate(a0, a1) { // fn#110702, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14852:212, offset: 0x02383355, size: 108 bytes, params: 3, frame: 15
|
||||
const {isLoading, error,
|
||||
onToggle} = (importDefault(14651) /* metro dependency 14651: useGuildPowerupOnToggle */)(a0, a1);
|
||||
const binding = env0_2;
|
||||
const useCallback = binding.useCallback;
|
||||
return {isLoading: isLoading, error: error, onDeactivate: Reflect.apply(useCallback, binding, [function() {
|
||||
return onToggle(false);
|
||||
}, [onToggle]])};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
/* Metro module 14651; source: modules/premium/powerups/hooks/useGuildPowerupOnToggle.tsx; dependencies: [57, 31, 12307, 2] */
|
||||
function _fun110680(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110680, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14848:6, offset: 0x02382770, size: 133 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupOnToggle.tsx');
|
||||
exports.default = useGuildPowerupOnToggle;
|
||||
}
|
||||
|
||||
function useGuildPowerupOnToggle(a0, a1) { // fn#110681, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14848:221, offset: 0x023827f5, size: 143 bytes, params: 3, frame: 20
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const binding = env0_3;
|
||||
let useState = binding.useState;
|
||||
const value2 = Reflect.apply(useState, binding, [false]);
|
||||
const binding2 = env0_2;
|
||||
let value = binding2(value2, 2);
|
||||
const property = value[0];
|
||||
var env0_2 = value[1];
|
||||
useState = binding.useState;
|
||||
value = binding2(Reflect.apply(useState, binding, [undefined]), 2);
|
||||
const property2 = value[0];
|
||||
var env0_3 = value[1];
|
||||
const object2 = {isLoading: property, error: property2};
|
||||
object2.onToggle = binding.useCallback(_fun110682, [a0, a1]);
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun110682(a0) { // fn#110682, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14848:398, offset: 0x02382884, size: 159 bytes, params: 2, frame: 15
|
||||
if (require == null) {
|
||||
return global.Promise.resolve();
|
||||
}
|
||||
const guildPowerupsActionCreatorsModule = require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */;
|
||||
const r3 = a0 ? guildPowerupsActionCreatorsModule.enablePowerupForGuild : guildPowerupsActionCreatorsModule.disablePowerupForGuild;
|
||||
env0_2(true);
|
||||
env0_3(undefined);
|
||||
let value = r3(env0_0, require.skuId);
|
||||
value = value.catch(_fun110683);
|
||||
return value.finally(_fun110684);
|
||||
}
|
||||
|
||||
function _fun110683(a0) { // fn#110683, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14848:550, offset: 0x02382923, size: 52 bytes, params: 2, frame: 15
|
||||
let value = environment.__proto__;
|
||||
const binding = env1_3;
|
||||
const body = a0.body;
|
||||
value = undefined;
|
||||
binding((body == null ? value : body.message) ?? value);
|
||||
throw a0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
/* Metro module 14610; source: modules/premium/powerups/hooks/useGuildPowerupRollbackEnabled.tsx; dependencies: [2] */
|
||||
function _fun110482(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110482, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14807:6, offset: 0x0237b0b1, size: 100 bytes, params: 8, frame: 16
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupRollbackEnabled.tsx');
|
||||
exports.default = function() {
|
||||
return false;
|
||||
};
|
||||
exports.isGuildPowerupRollbackEnabled = function() {
|
||||
return false;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
/* Metro module 14611; source: modules/premium/powerups/hooks/useGuildPowerupRollbackNotificationConfig.tsx; dependencies: [2] */
|
||||
function _fun110485(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110485, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14808:6, offset: 0x0237b115, size: 87 bytes, params: 8, frame: 15
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupRollbackNotificationConfig.tsx');
|
||||
exports.default = function() {
|
||||
return {'shouldShow': false, 'notificationConfig': null};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
/* Metro module 14623; source: modules/premium/powerups/hooks/useGuildPowerupTier3OverrideConfig.tsx; dependencies: [1867, 661, 566, 1244, 2256, 2] */
|
||||
function _fun110551(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110551, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14820:6, offset: 0x0237cfee, size: 140 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const env0_4 = (require(661) /* metro dependency 661: Constants */).GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupTier3OverrideConfig.tsx');
|
||||
exports.default = useGuildPowerupTier3OverrideConfig;
|
||||
}
|
||||
|
||||
function useGuildPowerupTier3OverrideConfig(a0) { // fn#110552, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14820:243, offset: 0x0237d07a, size: 160 bytes, params: 2, frame: 17
|
||||
var r0;
|
||||
var intl;
|
||||
const env0_0 = a0;
|
||||
const fluxModule = require(566) /* metro dependency 566: flux */;
|
||||
const useStateFromStores = fluxModule.useStateFromStores;
|
||||
let object = [GuildStore];
|
||||
if (Reflect.apply(useStateFromStores, fluxModule, [object, _fun110553])) {
|
||||
object = {shouldShow: true};
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object.text = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).l9n4QZ);
|
||||
r0 = object;
|
||||
} else {
|
||||
r0 = {'shouldShow': false, 'text': ''};
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110553() { // fn#110553, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14820:329, offset: 0x0237d11a, size: 70 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return (guild == null ? undefined : guild.features.has(GuildFeatures.PREMIUM_TIER_3_OVERRIDE)) === true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
/* Metro module 8254; source: modules/premium/powerups/hooks/useGuildPowerupsBoostCount.tsx; dependencies: [31, 1867, 8255, 8258, 6857, 566, 2] */
|
||||
function _fun66010(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66010, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:6, offset: 0x01be8f48, size: 178 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const gameServerStore = importDefault(8255) /* metro dependency 8255: GameServerStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupsBoostCount.tsx');
|
||||
exports.default = useGuildAppliedBoostCount;
|
||||
exports.getGuildPowerupsBoostCount = getGuildPowerupsBoostCount;
|
||||
}
|
||||
|
||||
function useGuildAppliedBoostCount(a0) { // fn#66011, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:241, offset: 0x01be8ffa, size: 254 bytes, params: 2, frame: 21
|
||||
const env0_0 = a0;
|
||||
const r7 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun66012) ?? 0;
|
||||
const value4 = (require(6857) /* metro dependency 6857: GameServerExperiment */).useGameServerEnabled(a0,
|
||||
'GuildPowerupsBoostCount');
|
||||
return value4.useMemo(_fun66015, [r7,
|
||||
(require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore], _fun66013),
|
||||
(require(566) /* metro dependency 566: flux */).useStateFromStores([GameServerStore], _fun66014), value4]);
|
||||
}
|
||||
|
||||
function getGuildPowerupsBoostCount(a0) { // fn#66016, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:887, offset: 0x01be91fe, size: 242 bytes, params: 2, frame: 19
|
||||
var object2;
|
||||
const guild = GuildStore.getGuild(a0);
|
||||
const value3 = undefined;
|
||||
const premiumSubscriberCount = guild == null ? value3 : guild.premiumSubscriberCount;
|
||||
const value4 = 0;
|
||||
const r1 = premiumSubscriberCount ?? value4;
|
||||
const gameServerEnabled = (require(6857) /* metro dependency 6857: GameServerExperiment */).getGameServerEnabled(a0,
|
||||
'GuildPowerupsBoostCount');
|
||||
const stateForGuild = GuildPowerupsStore.getStateForGuild(a0);
|
||||
const appliedBoosts = stateForGuild == null ? value3 : stateForGuild.appliedBoosts;
|
||||
let value = GameServerStore.getStateForGuild(a0);
|
||||
const appliedBoosts2 = value == null ? value3 : value.appliedBoosts;
|
||||
if (appliedBoosts == null) {
|
||||
return {'available': 0, 'spent': 0, total: r1};
|
||||
}
|
||||
if (gameServerEnabled) {
|
||||
if (appliedBoosts2 == null) {
|
||||
return {'available': 0, 'spent': 0, total: r1};
|
||||
}
|
||||
value = appliedBoosts + (appliedBoosts2 ?? value4);
|
||||
object2 = {};
|
||||
object2.available = global.Math.max(value4, r1 - value);
|
||||
} else {
|
||||
value = appliedBoosts + (appliedBoosts2 ?? value4);
|
||||
object2 = {};
|
||||
object2.available = global.Math.max(value4, r1 - value);
|
||||
}
|
||||
object2.spent = value;
|
||||
object2.total = r1;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun66012() { // fn#66012, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:328, offset: 0x01be90f8, size: 44 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildStore.getGuild(env0_0)?.premiumSubscriberCount;
|
||||
}
|
||||
|
||||
function _fun66013() { // fn#66013, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:504, offset: 0x01be9124, size: 44 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildPowerupsStore.getStateForGuild(env0_0)?.appliedBoosts;
|
||||
}
|
||||
|
||||
function _fun66014() { // fn#66014, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:614, offset: 0x01be9150, size: 44 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GameServerStore.getStateForGuild(env0_0)?.appliedBoosts;
|
||||
}
|
||||
|
||||
function _fun66015() { // fn#66015, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8439:708, offset: 0x01be917c, size: 130 bytes, params: 1, frame: 16
|
||||
var binding;
|
||||
var value2;
|
||||
var value3;
|
||||
var object2;
|
||||
if (env0_3 == null) {
|
||||
return {'available': 0, 'spent': 0, total: env0_1};
|
||||
}
|
||||
if (env0_2) {
|
||||
if (env0_4 == null) {
|
||||
return {'available': 0, 'spent': 0, total: env0_1};
|
||||
}
|
||||
binding = env0_3;
|
||||
value2 = 0;
|
||||
value3 = binding + (env0_4 ?? value2);
|
||||
object2 = {};
|
||||
object2.available = global.Math.max(value2, env0_1 - value3);
|
||||
} else {
|
||||
binding = env0_3;
|
||||
value2 = 0;
|
||||
value3 = binding + (env0_4 ?? value2);
|
||||
object2 = {};
|
||||
object2.available = global.Math.max(value2, env0_1 - value3);
|
||||
}
|
||||
object2.spent = value3;
|
||||
object2.total = env0_1;
|
||||
return object2;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
/* Metro module 8265; source: modules/premium/powerups/hooks/useGuildPowerupsBoostLevelProgress.tsx; dependencies: [1867, 661, 8254, 566, 2] */
|
||||
function _fun66101(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66101, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8450:6, offset: 0x01bec077, size: 173 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const constantsModule = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_4 = constantsModule.AppliedGuildBoostsRequiredForBoostedGuildTier;
|
||||
const env0_5 = constantsModule.BoostedGuildTiers;
|
||||
const env0_6 = constantsModule.GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupsBoostLevelProgress.tsx');
|
||||
exports.default = useGuildPowerupBoostLevelProgress;
|
||||
exports.getGuildPowerupBoostLevelProgress = function(a0) {
|
||||
var r2;
|
||||
var value2 = undefined;
|
||||
var value3 = require(dependencyMap[2]).getGuildPowerupsBoostCount(a0);
|
||||
var value4 = GuildStore.getGuild(a0);
|
||||
r2 = value4 == null ? value2 : value4.premiumTier;
|
||||
r2 = r2 ?? BoostedGuildTiers.NONE;
|
||||
return AppliedGuildBoostsRequiredForBoostedGuildTier[r2] + value3.available;
|
||||
};
|
||||
}
|
||||
|
||||
function useGuildPowerupBoostLevelProgress(a0) { // fn#66102, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8450:319, offset: 0x01bec124, size: 145 bytes, params: 2, frame: 21
|
||||
const env0_0 = a0;
|
||||
const value2 = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0);
|
||||
const fluxModule = require(566) /* metro dependency 566: flux */;
|
||||
let useStateFromStores = fluxModule.useStateFromStores;
|
||||
const value3 = Reflect.apply(useStateFromStores, fluxModule, [[GuildStore], _fun66103]);
|
||||
const moduleValue2 = fluxModule;
|
||||
useStateFromStores = moduleValue2.useStateFromStores;
|
||||
return (Reflect.apply(useStateFromStores, moduleValue2, [[GuildStore],
|
||||
_fun66104]) ? 0 : AppliedGuildBoostsRequiredForBoostedGuildTier[value3]) + value2.available;
|
||||
}
|
||||
|
||||
function _fun66103() { // fn#66103, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8450:416, offset: 0x01bec1b5, size: 58 bytes, params: 1, frame: 13
|
||||
return GuildStore.getGuild(env0_0)?.premiumTier ?? BoostedGuildTiers.NONE;
|
||||
}
|
||||
|
||||
function _fun66104() { // fn#66104, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8450:542, offset: 0x01bec1ef, size: 70 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return (guild == null ? undefined : guild.features.has(GuildFeatures.PREMIUM_TIER_3_OVERRIDE)) === true;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,998 @@
|
||||
/* Metro module 14607; source: modules/premium/powerups/hooks/useGuildPowerupsNotifications.tsx; dependencies: [57, 31, 1867, 8255, 14608, 8258, 8259, 661, 1376, 8249, 14247, 14598, 8188, 14610, 1360, 1365, 6857, 632, 8263, 4043, 8254, 14611, 1367, 14609, 14612, 14613, 14615, 14617, 14618, 12307, 2] */
|
||||
function _fun110428(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110428, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:6, offset: 0x0237911c, size: 468 bytes, params: 8, frame: 26
|
||||
const env0_0 = require;
|
||||
const closure = maybeGetLevelUnlockedPopoutDCF;
|
||||
const closure2 = maybeGetPerkPurchaseablePopoutDCF;
|
||||
const closure3 = maybeGetGameServerHostingGuildEligiblePopoutDCF;
|
||||
const closure4 = useGuildPowerupNewPerkAvailableCoachmarkVersion;
|
||||
const closure5 = useGuildPowerupsNotificationIndicator;
|
||||
const closure6 = useGuildPowerupsChannelListPopout;
|
||||
const closure7 = useGuildPowerupsNotifications;
|
||||
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 guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const gameServerStore = importDefault(8255) /* metro dependency 8255: GameServerStore */;
|
||||
const guildPowerupsNotificationStore = importDefault(14608) /* metro dependency 14608: GuildPowerupsNotificationStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
let value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_9 = value.BOOSTING_TIER_TO_LEVEL_SKU_ID;
|
||||
const env0_10 = value.BOOSTING_TIER_TO_LEVEL_UNLOCKED_DC;
|
||||
const env0_11 = value.GUILD_POWERUP_MIGRATION_USER_ID;
|
||||
const env0_12 = value.GUILD_POWERUP_NEW_PERK_GROUPS;
|
||||
const env0_13 = value.GuildPowerupNewPerkAvailableCoachmarkVersion;
|
||||
const env0_14 = value.NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET;
|
||||
const env0_15 = value.POWERUPS_INCLUDED_IN_LEVEL;
|
||||
value = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_16 = value.BoostedGuildTiers;
|
||||
const env0_17 = value.GuildFeatures;
|
||||
const env0_18 = (require(1376) /* metro dependency 1376: DismissibleContentConstants */).ContentDismissActionType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupsNotifications.tsx');
|
||||
exports.default = closure7;
|
||||
exports.maybeGetLevelUnlockedPopoutDCF = closure;
|
||||
exports.maybeGetPerkPurchaseablePopoutDCF = closure2;
|
||||
exports.maybeGetGameServerHostingGuildEligiblePopoutDCF = closure3;
|
||||
exports.useGuildPowerupNewPerkAvailableCoachmarkVersion = closure4;
|
||||
exports.useGuildPowerupsNotificationIndicator = closure5;
|
||||
exports.useGuildPowerupsChannelListPopout = closure6;
|
||||
exports.useAutoDismissGuildPowerupsNotifications = useAutoDismissGuildPowerupsNotifications;
|
||||
}
|
||||
|
||||
function maybeGetLevelUnlockedPopoutDCF(a0, a1) { // fn#110429, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:537, offset: 0x023792f0, size: 218 bytes, params: 3, frame: 20
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = undefined;
|
||||
const ReverseOrderedTiers = (require(8249) /* metro dependency 8249: GuildBoostingUtils */).ReverseOrderedTiers;
|
||||
const value3 = ReverseOrderedTiers.find(_fun110430);
|
||||
if (value3 == null) {
|
||||
return value2;
|
||||
}
|
||||
let property = BOOSTING_TIER_TO_LEVEL_UNLOCKED_DC[value3];
|
||||
if (property == null) {
|
||||
return value2;
|
||||
}
|
||||
const guildDismissibleContentUtilsModule = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
if (guildDismissibleContentUtilsModule.isContentDismissed(property, a0)) {
|
||||
return value2;
|
||||
}
|
||||
property = BOOSTING_TIER_TO_LEVEL_SKU_ID[value3];
|
||||
const r3 = property != null ? a1.allPowerups[property] : value2;
|
||||
if (r3 == null) {
|
||||
return value2;
|
||||
}
|
||||
const GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
const LEVEL_REACHED = GuildPowerupNotificationPopoutType.LEVEL_REACHED;
|
||||
return {type: LEVEL_REACHED, powerup: r3, markAsDismissed: markAsDismissed};
|
||||
}
|
||||
|
||||
function maybeGetPerkPurchaseablePopoutDCF(a0, a1, a2, a3) { // fn#110432, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:981, offset: 0x02379443, size: 452 bytes, params: 5, frame: 21
|
||||
var r1;
|
||||
var moduleValue;
|
||||
const DismissibleGuildContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent;
|
||||
const GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var moduleValue2;
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const env0_2 = a2;
|
||||
const env0_3 = a3;
|
||||
const guild = GuildStore.getGuild(a0);
|
||||
const value3 = undefined;
|
||||
let r0 = (guild == null ? value3 : guild.premiumTier) ?? BoostedGuildTiers.NONE;
|
||||
const Array = global.Array;
|
||||
const value5 = Array.from(GUILD_POWERUP_NEW_PERK_GROUPS.values()).flatMap(function(a0) {
|
||||
return a0.length <= 0 || a0.some(_fun110434) ? [] : a0.map(_fun110435);
|
||||
});
|
||||
const value6 = value5.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish);
|
||||
if (value6.length !== 0) {
|
||||
if (value6.length !== 1) {
|
||||
if (value6.length > 1) {
|
||||
moduleValue2 = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
r1 = moduleValue2.isContentDismissed(DismissibleGuildContent.GUILD_POWERUP_CHOICE_SKU_PURCHASE_COACHMARK,
|
||||
|
||||
a0) ? value3 : {type: GuildPowerupNotificationPopoutType.PERKS_PURCHASABLE, powerups: value6,
|
||||
markAsDismissed: markAsDismissed_110437};
|
||||
} else {
|
||||
r1 = value3;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
moduleValue = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
if (moduleValue.isContentDismissed(DismissibleGuildContent.GUILD_POWERUP_SINGLE_SKU_PURCHASE_COACHMARK,
|
||||
a0)) {
|
||||
if (value6.length > 1) {
|
||||
moduleValue2 = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
r1 = moduleValue2.isContentDismissed(DismissibleGuildContent.GUILD_POWERUP_CHOICE_SKU_PURCHASE_COACHMARK,
|
||||
|
||||
|
||||
a0) ? value3 : {type: GuildPowerupNotificationPopoutType.PERKS_PURCHASABLE, powerups: value6,
|
||||
markAsDismissed: markAsDismissed_110437};
|
||||
} else {
|
||||
r1 = value3;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
r0 = {type: GuildPowerupNotificationPopoutType.PERKS_PURCHASABLE, powerups: value6,
|
||||
markAsDismissed: markAsDismissed};
|
||||
}
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
return value3;
|
||||
}
|
||||
|
||||
function maybeGetGameServerHostingGuildEligiblePopoutDCF(a0, a1, a2, a3) { // fn#110439, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:2267, offset: 0x023797f0, size: 196 bytes, params: 5, frame: 18
|
||||
var moduleValue2;
|
||||
var object2;
|
||||
const env0_0 = a0;
|
||||
const gameServerExperimentModule = require(6857) /* metro dependency 6857: GameServerExperiment */;
|
||||
const getGameServerEnabled = gameServerExperimentModule.getGameServerEnabled;
|
||||
if (Reflect.apply(getGameServerEnabled, gameServerExperimentModule, [a0,
|
||||
'maybeGetGameServerHostingGuildEligiblePopoutDCF'])) {
|
||||
if (a1) {
|
||||
return undefined;
|
||||
}
|
||||
if (a3 == null) {
|
||||
return undefined;
|
||||
}
|
||||
if (a2 >= a3) {
|
||||
moduleValue2 = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
if (moduleValue2.isContentDismissed((require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent.GAME_SERVER_HOSTING_GUILD_ELIGIBLE_COACHMARK,
|
||||
|
||||
|
||||
a0)) {
|
||||
return undefined;
|
||||
}
|
||||
object2 = {};
|
||||
object2.type = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType.GAME_SERVER_HOSTING_GUILD_ELIGIBLE;
|
||||
object2.markAsDismissed = markAsDismissed;
|
||||
return object2;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function useGuildPowerupNewPerkAvailableCoachmarkVersion(a0, a1) { // fn#110441, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:2780, offset: 0x02379900, size: 219 bytes, params: 3, frame: 21
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = (require(6857) /* metro dependency 6857: GameServerExperiment */).useGameServerEnabled(a0,
|
||||
'GuildPowerupsChannelRow');
|
||||
const value3 = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildStore],
|
||||
_fun110442);
|
||||
const r4 = (require(8263) /* metro dependency 8263: ServerThemeExperiment */).useServerThemeEnabled(a0,
|
||||
'useGuildPowerupNewPerkAvailableCoachmarkVersion') && (require(4043) /* metro dependency 4043: ServerThemeUserExperiment */).useServerThemeUserEnabled('useGuildPowerupNewPerkAvailableCoachmarkVersion');
|
||||
return r4.useMemo(_fun110443, [a1, value2, value3, r4]);
|
||||
}
|
||||
|
||||
function useGuildPowerupsNotificationIndicator(a0, a1, a2) { // fn#110446, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:4093, offset: 0x02379c4e, size: 308 bytes, params: 4, frame: 22
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const env0_2 = a2;
|
||||
const value2 = undefined;
|
||||
const available = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0).available;
|
||||
const shouldShow = (importDefault(14611) /* metro dependency 14611: useGuildPowerupRollbackNotificationConfig */)(a0,
|
||||
'useGuildPowerupsNotificationIndicator').shouldShow;
|
||||
const dismissibleContentUtilsModule = require(1367) /* metro dependency 1367: DismissibleContentUtils */;
|
||||
const useIsSingleUseGuildDismissibleContentDismissed = dismissibleContentUtilsModule.useIsSingleUseGuildDismissibleContentDismissed;
|
||||
const DismissibleContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleContent;
|
||||
const VANITY_URL_POWERUP_ROLLBACK_NOTIFICATION = DismissibleContent.VANITY_URL_POWERUP_ROLLBACK_NOTIFICATION;
|
||||
const r7 = shouldShow && !Reflect.apply(useIsSingleUseGuildDismissibleContentDismissed,
|
||||
dismissibleContentUtilsModule, [VANITY_URL_POWERUP_ROLLBACK_NOTIFICATION, a0]);
|
||||
const env0_4 = r7;
|
||||
const stateForGuild = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GameServerStore],
|
||||
_fun110447);
|
||||
return env0_4.useMemo(_fun110448, [available, a2 == null ? value2 : a2.lastBoostCount,
|
||||
a2 == null ? value2 : a2.lastSeenWarningNotification, a1, r7,
|
||||
stateForGuild == null ? value2 : stateForGuild.entitlements]);
|
||||
}
|
||||
|
||||
function useGuildPowerupsChannelListPopout(a0, a1) { // fn#110449, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:5239, offset: 0x02379f8c, size: 1176 bytes, params: 3, frame: 43
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value3 = env0_3((require(14612) /* metro dependency 14612: GuildPowerupsNotificationsDCFNative */).usePerksCoachmarkDCF(a1 != null),
|
||||
2);
|
||||
let property = value3[0];
|
||||
const property2 = value3[1];
|
||||
const DismissibleContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleContent;
|
||||
const GUILD_POWERUP_PERKS_COACHMARK = DismissibleContent.GUILD_POWERUP_PERKS_COACHMARK;
|
||||
const value4 = property === GUILD_POWERUP_PERKS_COACHMARK;
|
||||
const available = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0).available;
|
||||
const env0_4 = available;
|
||||
const value5 = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildStore],
|
||||
_fun110450);
|
||||
const lowestGameCostForGuild = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GameServerStore],
|
||||
_fun110451);
|
||||
const r19 = (require(8263) /* metro dependency 8263: ServerThemeExperiment */).useServerThemeEnabled(a0,
|
||||
'useGuildPowerupsChannelListPopout') && (require(4043) /* metro dependency 4043: ServerThemeUserExperiment */).useServerThemeUserEnabled('useGuildPowerupsChannelListPopout');
|
||||
const value8 = useGuildPowerupNewPerkAvailableCoachmarkVersion(a0, a1);
|
||||
const guildPowerupsNotificationsDCFNativeModule = require(14612) /* metro dependency 14612: GuildPowerupsNotificationsDCFNative */;
|
||||
const useNewPerkAvailableCoachmarkDCF = guildPowerupsNotificationsDCFNativeModule.useNewPerkAvailableCoachmarkDCF;
|
||||
let r4 = a1 != null && !value4;
|
||||
const value12 = env0_3(Reflect.apply(useNewPerkAvailableCoachmarkDCF, guildPowerupsNotificationsDCFNativeModule,
|
||||
[r4, value8]), 2);
|
||||
property = value12[0];
|
||||
const property3 = value12[1];
|
||||
const GUILD_POWERUP_NEW_PERK_AVAILABLE_COACHMARK = DismissibleContent.GUILD_POWERUP_NEW_PERK_AVAILABLE_COACHMARK;
|
||||
const value13 = property === GUILD_POWERUP_NEW_PERK_AVAILABLE_COACHMARK;
|
||||
const value14 = (importDefault(14613) /* metro dependency 14613: useBoostToUnlockFeaturedPowerup */)(a0);
|
||||
const moduleValue7 = guildPowerupsNotificationsDCFNativeModule;
|
||||
const useBoostToUnlockCoachmarkDCF = moduleValue7.useBoostToUnlockCoachmarkDCF;
|
||||
const value20 = env0_3(Reflect.apply(useBoostToUnlockCoachmarkDCF, moduleValue7,
|
||||
[a1 != null && !value4 && !value13 && value14 != null, a0]), 2);
|
||||
property = value20[0];
|
||||
const property4 = value20[1];
|
||||
const BOOST_TO_UNLOCK_COACHMARK = DismissibleContent.BOOST_TO_UNLOCK_COACHMARK;
|
||||
const value21 = property === BOOST_TO_UNLOCK_COACHMARK;
|
||||
const value22 = (importDefault(14615) /* metro dependency 14615: useFeaturedExpiringPowerup */)(a0);
|
||||
const moduleValue8 = guildPowerupsNotificationsDCFNativeModule;
|
||||
const useExpiringPowerupCoachmarkDCF = moduleValue8.useExpiringPowerupCoachmarkDCF;
|
||||
r4 = a1 != null && !value4 && !value13;
|
||||
r4 = r4 && !value21 && value22 != null;
|
||||
const value29 = env0_3(Reflect.apply(useExpiringPowerupCoachmarkDCF, moduleValue8, [r4, a0]), 2);
|
||||
property = value29[0];
|
||||
const property5 = value29[1];
|
||||
const EXPIRING_POWERUP_COACHMARK = DismissibleContent.EXPIRING_POWERUP_COACHMARK;
|
||||
const value30 = property === EXPIRING_POWERUP_COACHMARK;
|
||||
const gameServerEnabled = (require(6857) /* metro dependency 6857: GameServerExperiment */).getGameServerEnabled(a0,
|
||||
'useGuildPowerupsChannelListPopout');
|
||||
const value32 = (require(14617) /* metro dependency 14617: NewGamesCoachmarkExperiment */).useIsNewGamesCoachmarkEnabled('useGuildPowerupsChannelListPopout');
|
||||
const moduleValue11 = guildPowerupsNotificationsDCFNativeModule;
|
||||
const useNewGamesCoachmarkDC = moduleValue11.useNewGamesCoachmarkDC;
|
||||
const value35 = env0_3(Reflect.apply(useNewGamesCoachmarkDC, moduleValue11,
|
||||
[a1 != null && gameServerEnabled && value32]), 2);
|
||||
property = value35[0];
|
||||
const property6 = value35[1];
|
||||
const GAME_SERVER_NEW_GAMES_COACHMARK = DismissibleContent.GAME_SERVER_NEW_GAMES_COACHMARK;
|
||||
const value36 = property === GAME_SERVER_NEW_GAMES_COACHMARK;
|
||||
const value37 = (require(14618) /* metro dependency 14618: GameServerPricingExperiment */).useIsGameServerPricingEnabled(a0,
|
||||
'useGuildPowerupsChannelListPopout');
|
||||
const moduleValue13 = guildPowerupsNotificationsDCFNativeModule;
|
||||
const useGameServerPricingCoachmarkDCF = moduleValue13.useGameServerPricingCoachmarkDCF;
|
||||
const value41 = env0_3(Reflect.apply(useGameServerPricingCoachmarkDCF, moduleValue13,
|
||||
[a1 != null && !value5 && gameServerEnabled && value37]), 2);
|
||||
property = value41[0];
|
||||
const property7 = value41[1];
|
||||
const GAME_SERVER_PRICING_CHANGE_COACHMARK = DismissibleContent.GAME_SERVER_PRICING_CHANGE_COACHMARK;
|
||||
const value42 = property === GAME_SERVER_PRICING_CHANGE_COACHMARK;
|
||||
const value43 = env0_4.useMemo(_fun110452, [a0, a1, value4, value13, value36, value42, value21, value30, available,
|
||||
value5, lowestGameCostForGuild, r19]);
|
||||
const value45 = env0_3(guildPowerupsNotificationsDCFNativeModule.useGuildPowerupNotificationDCF(value43 != null), 2);
|
||||
return env0_4.useMemo(_fun110453, [a1, value4, property2, value43, value45[0], value45[1], value13, property3,
|
||||
value8, value21, value14, property4, value30, value22, property5, value36, property6, value42, property7]);
|
||||
}
|
||||
|
||||
function useGuildPowerupsNotifications(a0) { // fn#110456, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:8344, offset: 0x0237a829, size: 207 bytes, params: 2, frame: 22
|
||||
const env0_0 = a0;
|
||||
const value2 = undefined;
|
||||
const value3 = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildPowerupsNotificationStore],
|
||||
_fun110457, [a0]);
|
||||
const stateForGuild = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110458);
|
||||
const {indicator, showUnread} = useGuildPowerupsNotificationIndicator(a0, stateForGuild ?? value2, value3);
|
||||
const value = useGuildPowerupsChannelListPopout(a0, stateForGuild ?? value2);
|
||||
if (stateForGuild !== null) {
|
||||
if (indicator != null) {
|
||||
return {indicator: indicator, showUnread: showUnread, popout: value};
|
||||
}
|
||||
if (showUnread) {
|
||||
return {indicator: indicator, showUnread: showUnread, popout: value};
|
||||
}
|
||||
if (value != null) {
|
||||
return {indicator: indicator, showUnread: showUnread, popout: value};
|
||||
}
|
||||
}
|
||||
return value2;
|
||||
}
|
||||
|
||||
function useAutoDismissGuildPowerupsNotifications(a0) { // fn#110459, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:9416, offset: 0x0237a930, size: 177 bytes, params: 2, frame: 19
|
||||
const env0_0 = a0;
|
||||
const stateForGuild = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110460);
|
||||
const value2 = useGuildPowerupsNotifications(a0);
|
||||
env0_4.useEffect(_fun110461, [a0]);
|
||||
env0_4.useEffect(_fun110462, [value2]);
|
||||
env0_4.useEffect(_fun110463, [a0, stateForGuild]);
|
||||
}
|
||||
|
||||
function _fun110430(a0) { // fn#110430, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:622, offset: 0x023793ca, size: 65 bytes, params: 2, frame: 5
|
||||
const value = environment.__proto__;
|
||||
const property = BOOSTING_TIER_TO_LEVEL_SKU_ID[a0];
|
||||
const r2 = property != null ? require.unlockedPowerups[property] : undefined;
|
||||
return r2 != null && r2.user_id !== GUILD_POWERUP_MIGRATION_USER_ID;
|
||||
}
|
||||
|
||||
function maybeGetLevelUnlockedPopoutDCFMarkAsDismissed(a0) { // fn#110431, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:931, owner: maybeGetLevelUnlockedPopoutDCF.markAsDismissed, offset: 0x0237940b, size: 56 bytes, params: 2, frame: 18
|
||||
let value = environment.__proto__;
|
||||
value = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
value.markContentAsDismissed(env0_2, env0_0, true, a0);
|
||||
}
|
||||
|
||||
function _fun110433(a0) { // fn#110433, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:1141, offset: 0x02379607, size: 62 bytes, params: 2, frame: 12
|
||||
return a0.length <= 0 || a0.some(_fun110434) ? [] : a0.map(_fun110435);
|
||||
}
|
||||
|
||||
function maybeGetPerkPurchaseablePopoutDCFMarkAsDismissed(a0) { // fn#110437, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:1919, owner: maybeGetPerkPurchaseablePopoutDCF.markAsDismissed, offset: 0x02379758, size: 76 bytes, params: 2, frame: 18
|
||||
let value = environment.__proto__;
|
||||
value = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
const markContentAsDismissed = value.markContentAsDismissed;
|
||||
const DismissibleGuildContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent;
|
||||
const GUILD_POWERUP_CHOICE_SKU_PURCHASE_COACHMARK = DismissibleGuildContent.GUILD_POWERUP_CHOICE_SKU_PURCHASE_COACHMARK;
|
||||
Reflect.apply(markContentAsDismissed, value, [GUILD_POWERUP_CHOICE_SKU_PURCHASE_COACHMARK, env0_0, true, a0]);
|
||||
}
|
||||
|
||||
function maybeGetPerkPurchaseablePopoutDCFMarkAsDismissed_110438(a0) { // fn#110438, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:2144, owner: maybeGetPerkPurchaseablePopoutDCF.markAsDismissed, offset: 0x023797a4, size: 76 bytes, params: 2, frame: 18
|
||||
let value = environment.__proto__;
|
||||
value = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
const markContentAsDismissed = value.markContentAsDismissed;
|
||||
const DismissibleGuildContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent;
|
||||
const GUILD_POWERUP_SINGLE_SKU_PURCHASE_COACHMARK = DismissibleGuildContent.GUILD_POWERUP_SINGLE_SKU_PURCHASE_COACHMARK;
|
||||
Reflect.apply(markContentAsDismissed, value, [GUILD_POWERUP_SINGLE_SKU_PURCHASE_COACHMARK, env0_0, true, a0]);
|
||||
}
|
||||
|
||||
function maybeGetGameServerHostingGuildEligiblePopoutDCFMarkAsDismissed(a0) { // fn#110440, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:2656, owner: maybeGetGameServerHostingGuildEligiblePopoutDCF.markAsDismissed, offset: 0x023798b4, size: 76 bytes, params: 2, frame: 18
|
||||
let value = environment.__proto__;
|
||||
value = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
const markContentAsDismissed = value.markContentAsDismissed;
|
||||
const DismissibleGuildContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleGuildContent;
|
||||
const GAME_SERVER_HOSTING_GUILD_ELIGIBLE_COACHMARK = DismissibleGuildContent.GAME_SERVER_HOSTING_GUILD_ELIGIBLE_COACHMARK;
|
||||
Reflect.apply(markContentAsDismissed, value, [GAME_SERVER_HOSTING_GUILD_ELIGIBLE_COACHMARK, env0_0, true, a0]);
|
||||
}
|
||||
|
||||
function _fun110442() { // fn#110442, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:2942, offset: 0x023799db, size: 64 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return guild == null ? undefined : guild.features.has(GuildFeatures.GAME_SERVERS);
|
||||
}
|
||||
|
||||
function _fun110443() { // fn#110443, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:3224, offset: 0x02379a1b, size: 513 bytes, params: 1, frame: 18
|
||||
var environment;
|
||||
var GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
var r2;
|
||||
var r1;
|
||||
const GUILD_POWERUP_GUILD_THEME_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
const GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID;
|
||||
var value8;
|
||||
var Array;
|
||||
var from;
|
||||
var value11;
|
||||
var value12;
|
||||
var value;
|
||||
const value2 = undefined;
|
||||
const value4 = (require == null || require.allPowerups == null ? value2 : require.allPowerups[GUILD_POWERUP_GUILD_THEME_SKU_ID]) != null;
|
||||
let r0 = require == null || require.unlockedPowerups == null ? value2 : require.unlockedPowerups[GUILD_POWERUP_GUILD_THEME_SKU_ID];
|
||||
if (env0_4) {
|
||||
if (value4) {
|
||||
if (r0 != null) {
|
||||
r0 = require == null || require.allPowerups == null ? value2 : require.allPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
value8 = r0 != null;
|
||||
r0 = require == null || require.unlockedPowerups == null ? value2 : require.unlockedPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
if (value8) {
|
||||
if (r0 != null) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(function(a0) {
|
||||
return (require == null || require.unlockedPowerups == null ? undefined : require.unlockedPowerups[a0]) != null;
|
||||
})) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
value = environment.__proto__;
|
||||
r0 = GuildPowerupNewPerkAvailableCoachmarkVersion.FILE_UPLOAD_250_MB;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(_fun110444)) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
value = environment.__proto__;
|
||||
return GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_THEME;
|
||||
}
|
||||
r0 = require == null || require.allPowerups == null ? value2 : require.allPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
value8 = r0 != null;
|
||||
r0 = require == null || require.unlockedPowerups == null ? value2 : require.unlockedPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
if (value8) {
|
||||
if (r0 != null) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(_fun110444)) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
value = environment.__proto__;
|
||||
r0 = GuildPowerupNewPerkAvailableCoachmarkVersion.FILE_UPLOAD_250_MB;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(_fun110444)) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
}
|
||||
} else {
|
||||
r0 = require == null || require.allPowerups == null ? value2 : require.allPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
value8 = r0 != null;
|
||||
r0 = require == null || require.unlockedPowerups == null ? value2 : require.unlockedPowerups[GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID];
|
||||
if (value8) {
|
||||
if (r0 != null) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(function(a0) {
|
||||
return (require == null || require.unlockedPowerups == null ? undefined : require.unlockedPowerups[a0]) != null;
|
||||
})) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
value = environment.__proto__;
|
||||
r0 = GuildPowerupNewPerkAvailableCoachmarkVersion.FILE_UPLOAD_250_MB;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
value11 = environment.__proto__;
|
||||
value12 = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO]]);
|
||||
if (value12.some(_fun110444)) {
|
||||
if (env0_2) {
|
||||
if (env0_3) {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
} else {
|
||||
r2 = GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING;
|
||||
}
|
||||
} else {
|
||||
Array = global.Array;
|
||||
from = Array.from;
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
value = Reflect.apply(from, Array,
|
||||
[NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[GUILD_TAG_BADGE_PACKS_WAVE_ONE]]);
|
||||
value = value.some(_fun110445);
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE = value ? 0 : GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
r2 = GUILD_TAG_BADGE_PACKS_WAVE_ONE;
|
||||
}
|
||||
r1 = r2;
|
||||
} else {
|
||||
r1 = GuildPowerupNewPerkAvailableCoachmarkVersion.GUILD_TAG_BADGE_PACKS_WAVE_TWO;
|
||||
}
|
||||
r0 = r1;
|
||||
}
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110448() { // fn#110448, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:4459, offset: 0x02379d9d, size: 495 bytes, params: 1, frame: 24
|
||||
var r13;
|
||||
var entitlements;
|
||||
const GuildPowerupNotificationIndicatorType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationIndicatorType;
|
||||
if (require == null) {
|
||||
return {indicator: undefined, showUnread: false};
|
||||
}
|
||||
const unlockedPowerups = require.unlockedPowerups;
|
||||
const value3 = undefined;
|
||||
const getExpiringGuildEntitlementsModule = require(14609) /* metro dependency 14609: getExpiringGuildEntitlements */;
|
||||
const getExpiringGuildEntitlements = getExpiringGuildEntitlementsModule.getExpiringGuildEntitlements;
|
||||
let Object = global.Object;
|
||||
let values = Object.values;
|
||||
const value4 = Reflect.apply(values, Object, [unlockedPowerups]);
|
||||
const items = [];
|
||||
const value5 = 0;
|
||||
const value6 = arraySpread(items, value4, value5, r13);
|
||||
Object = global.Object;
|
||||
values = Object.values;
|
||||
const value7 = stateForGuild == null;
|
||||
if (value7) {
|
||||
entitlements = value3;
|
||||
r13 = value7;
|
||||
} else {
|
||||
stateForGuildBinding = stateForGuild;
|
||||
entitlements = stateForGuildBinding.entitlements;
|
||||
r13 = stateForGuildBinding;
|
||||
}
|
||||
arraySpread(items, Reflect.apply(values, Object, [entitlements ?? ({})]), value6, r13);
|
||||
const value8 = Reflect.apply(getExpiringGuildEntitlements, getExpiringGuildEntitlementsModule, [items]);
|
||||
const r7 = (importDefault == null ? value3 : importDefault.lastSeenWarningNotification) ?? global.Date.now();
|
||||
const Date = global.Date;
|
||||
const property = value8[value8.length - 1];
|
||||
const ends_at = property == null ? value3 : property.ends_at;
|
||||
const value10 = Object.create(Date.prototype, {constructor: {value: Date}});
|
||||
const date = new Date(ends_at);
|
||||
const time = (date instanceof Object ? date : value10).getTime();
|
||||
const r2 = (importDefault == null ? value3 : importDefault.lastBoostCount) ?? value5;
|
||||
const r6 = value8.length > value5 && r7 < time;
|
||||
const value15 = available - r2;
|
||||
return r6 || env0_4 ? {indicator: {type: GuildPowerupNotificationIndicatorType.WARNING},
|
||||
showUnread: true} : available === r2 ? {indicator: value3,
|
||||
showUnread: false} : value15 > value5 ? {indicator: {type: GuildPowerupNotificationIndicatorType.UNREAD,
|
||||
count: value15}, showUnread: true} : {indicator: value3, showUnread: false};
|
||||
}
|
||||
|
||||
function _fun110450() { // fn#110450, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:5478, offset: 0x0237a424, size: 74 bytes, params: 1, frame: 13
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
const r1 = guild == null ? undefined : guild.features.has(GuildFeatures.GAME_SERVERS);
|
||||
return r1 != null && r1;
|
||||
}
|
||||
|
||||
function _fun110451() { // fn#110451, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:5611, offset: 0x0237a46e, size: 27 bytes, params: 1, frame: 11
|
||||
return GameServerStore.getLowestGameCostForGuild(env0_0);
|
||||
}
|
||||
|
||||
function _fun110452() { // fn#110452, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:6896, offset: 0x0237a489, size: 172 bytes, params: 1, frame: 21
|
||||
if (require == null) {
|
||||
return undefined;
|
||||
}
|
||||
if (result) {
|
||||
return undefined;
|
||||
}
|
||||
if (result_2) {
|
||||
return undefined;
|
||||
}
|
||||
if (result_5) {
|
||||
return undefined;
|
||||
}
|
||||
if (result_6) {
|
||||
return undefined;
|
||||
}
|
||||
if (result_3) {
|
||||
return undefined;
|
||||
}
|
||||
if (result_4) {
|
||||
return undefined;
|
||||
}
|
||||
const maybeGetLevelUnlockedPopoutDCFBinding = maybeGetLevelUnlockedPopoutDCF;
|
||||
const binding = env0_0;
|
||||
const value3 = undefined;
|
||||
const value4 = maybeGetLevelUnlockedPopoutDCFBinding(binding, require);
|
||||
if (value4 != null) {
|
||||
return value4;
|
||||
}
|
||||
const value5 = maybeGetPerkPurchaseablePopoutDCF(env0_0, require, available, env0_7);
|
||||
if (value5 != null) {
|
||||
return value5;
|
||||
}
|
||||
return maybeGetGameServerHostingGuildEligiblePopoutDCF(env0_0, env0_5, available, lowestGameCostForGuild) ?? value3;
|
||||
}
|
||||
|
||||
function _fun110453() { // fn#110453, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:7284, offset: 0x0237a535, size: 695 bytes, params: 1, frame: 16
|
||||
var environment;
|
||||
var r2;
|
||||
var binding;
|
||||
var value2;
|
||||
var value3;
|
||||
const DismissibleContent = (require(1365) /* metro dependency 1365: dismissible_content */).DismissibleContent;
|
||||
var object2;
|
||||
var value4;
|
||||
const GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var value5;
|
||||
var value6;
|
||||
var value7;
|
||||
var value8;
|
||||
var Object;
|
||||
var value10;
|
||||
var value11;
|
||||
if (require != null) {
|
||||
if (result) {
|
||||
value11 = environment.__proto__;
|
||||
return {type: GuildPowerupNotificationPopoutType.PERKS_AVAILABLE, markAsDismissed: env0_2};
|
||||
}
|
||||
if (result_2) {
|
||||
binding = env0_8;
|
||||
value8 = environment.__proto__;
|
||||
if (binding === GuildPowerupNewPerkAvailableCoachmarkVersion.GAME_SERVER_HOSTING) {
|
||||
return {type: GuildPowerupNotificationPopoutType.GAME_SERVER_HOSTING_AVAILABLE,
|
||||
markAsDismissed: env0_9};
|
||||
}
|
||||
var env0_0 = NEW_PERK_AVAILABLE_COACHMARK_VERSION_TO_POWERUP_SKU_ID_SET[env0_8];
|
||||
Object = global.Object;
|
||||
value10 = Object.values(require.allPowerups).filter(_fun110454);
|
||||
if (value10.length === 0) {
|
||||
return undefined;
|
||||
}
|
||||
return {powerups: value10, type: GuildPowerupNotificationPopoutType.NEW_PERK_AVAILABLE,
|
||||
markAsDismissed: env0_9};
|
||||
}
|
||||
if (result_3) {
|
||||
if (env0_11 != null) {
|
||||
value7 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.BOOST_TO_UNLOCK, powerup: env0_11,
|
||||
markAsDismissed: env0_12};
|
||||
} else if (result_4) {
|
||||
if (env0_14 != null) {
|
||||
value6 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.EXPIRING_PERK, featuredExpiringPowerup: env0_14,
|
||||
markAsDismissed: env0_15};
|
||||
} else if (result_5) {
|
||||
value5 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_NEW_GAMES, markAsDismissed: env0_17};
|
||||
} else if (result_6) {
|
||||
value4 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_PRICING_CHANGE,
|
||||
markAsDismissed: env0_19};
|
||||
} else {
|
||||
binding = env0_22;
|
||||
value2 = environment.__proto__;
|
||||
value3 = undefined;
|
||||
if (binding !== DismissibleContent.GUILD_POWERUP_NOTIFICATION) {
|
||||
r2 = value3;
|
||||
} else if (env0_21 != null) {
|
||||
object2 = {};
|
||||
copyDataProperties(object2, env0_21, binding);
|
||||
object2['markAsDismissed'] = markAsDismissed_110455;
|
||||
r2 = object2;
|
||||
} else {
|
||||
r2 = value3;
|
||||
}
|
||||
}
|
||||
} else if (result_5) {
|
||||
value5 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_NEW_GAMES, markAsDismissed: env0_17};
|
||||
} else if (result_6) {
|
||||
value4 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_PRICING_CHANGE, markAsDismissed: env0_19};
|
||||
} else {
|
||||
binding = env0_22;
|
||||
value2 = environment.__proto__;
|
||||
value3 = undefined;
|
||||
if (binding !== DismissibleContent.GUILD_POWERUP_NOTIFICATION) {
|
||||
r2 = value3;
|
||||
} else if (env0_21 != null) {
|
||||
object2 = {};
|
||||
copyDataProperties(object2, env0_21, binding);
|
||||
object2['markAsDismissed'] = markAsDismissed_110455;
|
||||
r2 = object2;
|
||||
} else {
|
||||
r2 = value3;
|
||||
}
|
||||
}
|
||||
} else if (result_4) {
|
||||
if (env0_14 != null) {
|
||||
value6 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.EXPIRING_PERK, featuredExpiringPowerup: env0_14,
|
||||
markAsDismissed: env0_15};
|
||||
} else if (result_5) {
|
||||
value5 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_NEW_GAMES, markAsDismissed: env0_17};
|
||||
} else if (result_6) {
|
||||
value4 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_PRICING_CHANGE, markAsDismissed: env0_19};
|
||||
} else {
|
||||
binding = env0_22;
|
||||
value2 = environment.__proto__;
|
||||
value3 = undefined;
|
||||
if (binding !== DismissibleContent.GUILD_POWERUP_NOTIFICATION) {
|
||||
r2 = value3;
|
||||
} else if (env0_21 != null) {
|
||||
object2 = {};
|
||||
copyDataProperties(object2, env0_21, binding);
|
||||
object2['markAsDismissed'] = markAsDismissed_110455;
|
||||
r2 = object2;
|
||||
} else {
|
||||
r2 = value3;
|
||||
}
|
||||
}
|
||||
} else if (result_5) {
|
||||
value5 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_NEW_GAMES, markAsDismissed: env0_17};
|
||||
} else if (result_6) {
|
||||
value4 = environment.__proto__;
|
||||
r2 = {type: GuildPowerupNotificationPopoutType.GAME_SERVER_PRICING_CHANGE, markAsDismissed: env0_19};
|
||||
} else {
|
||||
binding = env0_22;
|
||||
value2 = environment.__proto__;
|
||||
value3 = undefined;
|
||||
if (binding !== DismissibleContent.GUILD_POWERUP_NOTIFICATION) {
|
||||
r2 = value3;
|
||||
} else if (env0_21 != null) {
|
||||
object2 = {};
|
||||
copyDataProperties(object2, env0_21, binding);
|
||||
object2['markAsDismissed'] = markAsDismissed_110455;
|
||||
r2 = object2;
|
||||
} else {
|
||||
r2 = value3;
|
||||
}
|
||||
}
|
||||
return r2;
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110457() { // fn#110457, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:8425, offset: 0x0237a8f8, size: 29 bytes, params: 1, frame: 11
|
||||
return GuildPowerupsNotificationStore.getNotificationStateForGuild(env0_0);
|
||||
}
|
||||
|
||||
function _fun110458() { // fn#110458, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:8504, offset: 0x0237a915, size: 27 bytes, params: 1, frame: 11
|
||||
return GuildPowerupsStore.getStateForGuild(env0_0);
|
||||
}
|
||||
|
||||
function _fun110461() { // fn#110461, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:9584, offset: 0x0237a9e1, size: 45 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).guildPowerupsAckNotification(env0_0);
|
||||
}
|
||||
|
||||
function _fun110462() { // fn#110462, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:9650, offset: 0x0237aa0e, size: 234 bytes, params: 1, frame: 16
|
||||
var type;
|
||||
var r3;
|
||||
var popout;
|
||||
const Set = global.Set;
|
||||
const value2 = undefined;
|
||||
const {BOOST_TO_UNLOCK,
|
||||
EXPIRING_PERK} = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
const set = new Set([BOOST_TO_UNLOCK, EXPIRING_PERK]);
|
||||
if (env0_2 == null) {
|
||||
type = value2;
|
||||
} else {
|
||||
popout = env0_2.popout;
|
||||
type = popout == null ? value2 : popout.type;
|
||||
}
|
||||
let r2 = type != null && set.has(env0_2.popout.type);
|
||||
r2 = !r2 ? env0_2 == null : r2;
|
||||
if (r2) {
|
||||
r3 = value2;
|
||||
} else {
|
||||
popout = env0_2.popout;
|
||||
r2 = popout == null;
|
||||
r3 = popout;
|
||||
}
|
||||
if (!r2) {
|
||||
r3.markAsDismissed(ContentDismissActionType.AUTO_DISMISS);
|
||||
}
|
||||
return value2;
|
||||
}
|
||||
|
||||
function _fun110463() { // fn#110463, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:9950, offset: 0x0237aaf8, size: 67 bytes, params: 1, frame: 11
|
||||
var environment;
|
||||
if (stateForGuild != null) {
|
||||
value = environment.__proto__;
|
||||
(require(8249) /* metro dependency 8249: GuildBoostingUtils */).ReverseOrderedTiers.forEach(_fun110464);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110434(a0) { // fn#110434, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:1165, offset: 0x02379645, size: 58 bytes, params: 2, frame: 4
|
||||
const value = environment.__proto__;
|
||||
if (require.unlockedPowerups[a0] != null) {
|
||||
return true;
|
||||
}
|
||||
const property = POWERUPS_INCLUDED_IN_LEVEL[a0];
|
||||
return property != null && env1_4 >= property;
|
||||
}
|
||||
|
||||
function _fun110435(a0) { // fn#110435, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:1254, offset: 0x0237967f, size: 189 bytes, params: 2, frame: 19
|
||||
var environment;
|
||||
var r1;
|
||||
var r0;
|
||||
var value3;
|
||||
var property;
|
||||
var value4;
|
||||
var dependencies;
|
||||
let value = environment.__proto__.__proto__;
|
||||
const GUILD_POWERUP_GUILD_THEME_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
if (a0 !== GUILD_POWERUP_GUILD_THEME_SKU_ID) {
|
||||
value3 = environment.__proto__;
|
||||
property = require.allPowerups[a0];
|
||||
value4 = null;
|
||||
if (value4 == property) {
|
||||
r0 = value4;
|
||||
} else if (importDefault < property.cost) {
|
||||
r0 = value4;
|
||||
} else {
|
||||
dependencies = property.dependencies;
|
||||
if (dependencies.every(function(a0) {
|
||||
return require.unlockedPowerups[a0] != null;
|
||||
})) {
|
||||
value = require(14610) /* metro dependency 14610: useGuildPowerupRollbackEnabled */;
|
||||
r1 = value.isGuildPowerupRollbackEnabled(env1_0, property,
|
||||
'maybeGetPerkPurchaseablePopoutDCF') ? value4 : property;
|
||||
} else {
|
||||
r1 = value4;
|
||||
}
|
||||
r0 = r1;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
if (importAll) {
|
||||
value3 = environment.__proto__;
|
||||
property = require.allPowerups[a0];
|
||||
value4 = null;
|
||||
if (value4 == property) {
|
||||
r0 = value4;
|
||||
} else if (importDefault < property.cost) {
|
||||
r0 = value4;
|
||||
} else {
|
||||
dependencies = property.dependencies;
|
||||
if (dependencies.every(function(a0) {
|
||||
return require.unlockedPowerups[a0] != null;
|
||||
})) {
|
||||
value = require(14610) /* metro dependency 14610: useGuildPowerupRollbackEnabled */;
|
||||
r1 = value.isGuildPowerupRollbackEnabled(env1_0, property,
|
||||
'maybeGetPerkPurchaseablePopoutDCF') ? value4 : property;
|
||||
} else {
|
||||
r1 = value4;
|
||||
}
|
||||
r0 = r1;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function _fun110444(a0) { // fn#110444, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:3774, offset: 0x02379c1c, size: 50 bytes, params: 2, frame: 5
|
||||
return (require == null || require.unlockedPowerups == null ? undefined : require.unlockedPowerups[a0]) != null;
|
||||
}
|
||||
|
||||
function _fun110454({skuId}) { // fn#110454, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:7587, offset: 0x0237a7ec, size: 27 bytes, params: 2, frame: 11
|
||||
return env0_0.has(skuId);
|
||||
}
|
||||
|
||||
function markAsDismissed_110455(a0) { // fn#110455, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:8254, offset: 0x0237a807, size: 34 bytes, params: 2, frame: 12
|
||||
env1_23(a0);
|
||||
env1_21.markAsDismissed(a0);
|
||||
}
|
||||
|
||||
function _fun110464(a0) { // fn#110464, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14804:10001, offset: 0x0237ab3b, size: 111 bytes, params: 2, frame: 17
|
||||
var value2;
|
||||
var moduleValue;
|
||||
let property = BOOSTING_TIER_TO_LEVEL_SKU_ID[a0];
|
||||
if (property != null) {
|
||||
value2 = environment.__proto__;
|
||||
if (stateForGuild.unlockedPowerups[property] != null) {
|
||||
property = BOOSTING_TIER_TO_LEVEL_UNLOCKED_DC[a0];
|
||||
if (property != null) {
|
||||
moduleValue = require(14247) /* metro dependency 14247: GuildDismissibleContentUtils */;
|
||||
moduleValue.markContentAsDismissed(property, env1_0, false, ContentDismissActionType.AUTO_DISMISS);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,71 @@
|
||||
/* Metro module 14628; source: modules/premium/powerups/hooks/useGuildPowerupsWarningConfig.tsx; dependencies: [31, 12346, 8254, 566, 1244, 2256, 2] */
|
||||
function _fun110570(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110570, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14825:6, offset: 0x0237da44, size: 137 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const appliedGuildBoostStore = importDefault(12346) /* metro dependency 12346: AppliedGuildBoostStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useGuildPowerupsWarningConfig.tsx');
|
||||
exports.default = useGuildPowerupsWarningConfig;
|
||||
}
|
||||
|
||||
function useGuildPowerupsWarningConfig(a0, a1) { // fn#110571, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14825:224, offset: 0x0237dacd, size: 181 bytes, params: 3, frame: 19
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const spent = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(a0).spent;
|
||||
const value2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([AppliedGuildBoostStore],
|
||||
_fun110572, [a0]);
|
||||
const binding = env0_3;
|
||||
const useMemo = binding.useMemo;
|
||||
return binding.useMemo(_fun110575, [spent - Reflect.apply(useMemo, binding, [_fun110573, [value2]]), a1]);
|
||||
}
|
||||
|
||||
function _fun110572() { // fn#110572, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14825:325, offset: 0x0237db82, size: 27 bytes, params: 1, frame: 11
|
||||
return AppliedGuildBoostStore.getAppliedGuildBoostsForGuild(env0_0);
|
||||
}
|
||||
|
||||
function _fun110573() { // fn#110573, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14825:385, offset: 0x0237db9d, size: 87 bytes, params: 1, frame: 14
|
||||
var length;
|
||||
var value;
|
||||
const value2 = undefined;
|
||||
if (env0_2 == null) {
|
||||
length = value2;
|
||||
} else if (env0_2.filter == null) {
|
||||
length = value2;
|
||||
} else {
|
||||
value = env0_2.filter(function(a0) {
|
||||
return !a0.ended && a0.endsAt == null;
|
||||
});
|
||||
length = value == null ? value2 : value.length;
|
||||
}
|
||||
return length ?? 0;
|
||||
}
|
||||
|
||||
function _fun110575() { // fn#110575, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14825:535, offset: 0x0237dc11, size: 200 bytes, params: 1, frame: 20
|
||||
var r0;
|
||||
var object3;
|
||||
var value2;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var formatToPlainString;
|
||||
var iAaAiG;
|
||||
var object4;
|
||||
var binding;
|
||||
if (env0_3 <= 0) {
|
||||
r0 = {'shouldShow': false, 'title': '', 'description': '', 'requiredBoostCount': 0};
|
||||
} else {
|
||||
object3 = {shouldShow: true};
|
||||
value2 = environment.__proto__;
|
||||
object3.title = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).n5hQhc);
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
iAaAiG = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).iAaAiG;
|
||||
object4 = {};
|
||||
binding = env0_3;
|
||||
object4.boostCount = binding;
|
||||
object4.perksString = require.join(', ');
|
||||
object3.description = Reflect.apply(formatToPlainString, intl, [iAaAiG, object4]);
|
||||
object3.requiredBoostCount = binding;
|
||||
r0 = object3;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
/* Metro module 12310; source: modules/premium/powerups/hooks/useHasAllocateBoostPermission.tsx; dependencies: [1867, 3784, 482, 566, 2] */
|
||||
function _fun93999(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93999, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12496:6, offset: 0x020ce49e, size: 169 bytes, params: 8, frame: 20
|
||||
let env0_0 = require;
|
||||
const closure = getHasAllocateBoostPermission;
|
||||
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 env0_4 = (require(482) /* metro dependency 482: Constants */).Permissions;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useHasAllocateBoostPermission.tsx');
|
||||
exports.default = function(a0) {
|
||||
var env0_0 = a0;
|
||||
return require(dependencyMap[3]).useStateFromStores([PermissionStore, GuildStore], _fun94002);
|
||||
};
|
||||
exports.getHasAllocateBoostPermission = closure;
|
||||
}
|
||||
|
||||
function getHasAllocateBoostPermission(a0, a1) { // fn#94000, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12496:138, offset: 0x020ce547, size: 64 bytes, params: 3, frame: 14
|
||||
const value = null;
|
||||
return value == a1 || value == a0.getGuildPermissions(a1) ? value : a0.can(Permissions.ADMINISTRATOR, a1);
|
||||
}
|
||||
|
||||
function useHasAllocateBoostPermission(a0) { // fn#94001, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12496:367, offset: 0x020ce587, size: 74 bytes, params: 2, frame: 15
|
||||
const env0_0 = a0;
|
||||
return (require(566) /* metro dependency 566: flux */).useStateFromStores([PermissionStore, GuildStore], _fun94002);
|
||||
}
|
||||
|
||||
function _fun94002() { // fn#94002, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12496:450, offset: 0x020ce5d1, size: 43 bytes, params: 1, frame: 14
|
||||
const value = environment.__proto__;
|
||||
return getHasAllocateBoostPermission(PermissionStore, GuildStore.getGuild(env0_0));
|
||||
}
|
||||
|
||||
@@ -0,0 +1,49 @@
|
||||
/* Metro module 6630; source: modules/premium/powerups/hooks/useHasEnhancedRoleColors.tsx; dependencies: [1867, 661, 566, 2] */
|
||||
function _fun52491(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#52491, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:6, offset: 0x0132e055, size: 167 bytes, params: 8, frame: 18
|
||||
let env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const env0_3 = (require(661) /* metro dependency 661: Constants */).GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useHasEnhancedRoleColors.tsx');
|
||||
exports.default = function(a0) {
|
||||
var env0_0 = a0;
|
||||
return require(dependencyMap[2]).useStateFromStores([GuildStore], _fun52493);
|
||||
};
|
||||
exports.getHasEnhancedRoleColors = getHasEnhancedRoleColors;
|
||||
exports.useHasEnhancedRoleColorsForRole = function(a0) {
|
||||
var env0_0 = a0;
|
||||
return require(dependencyMap[2]).useStateFromStores([GuildStore], _fun52496);
|
||||
};
|
||||
exports.getHasEnhancedRoleColorsForRole = getHasEnhancedRoleColorsForRole;
|
||||
}
|
||||
|
||||
function useHasEnhancedRoleColors(a0) { // fn#52492, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:233, offset: 0x0132e0fc, size: 64 bytes, params: 2, frame: 14
|
||||
const env0_0 = a0;
|
||||
return (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun52493);
|
||||
}
|
||||
|
||||
function getHasEnhancedRoleColors(a0) { // fn#52494, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:420, offset: 0x0132e17a, size: 66 bytes, params: 2, frame: 13
|
||||
if (a0 == null) {
|
||||
return false;
|
||||
}
|
||||
const guild = GuildStore.getGuild(a0);
|
||||
return guild != null && guild.features.has(GuildFeatures.ENHANCED_ROLE_COLORS);
|
||||
}
|
||||
|
||||
function useHasEnhancedRoleColorsForRole(a0) { // fn#52495, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:587, offset: 0x0132e1bc, size: 64 bytes, params: 2, frame: 14
|
||||
const env0_0 = a0;
|
||||
return (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun52496);
|
||||
}
|
||||
|
||||
function getHasEnhancedRoleColorsForRole(a0) { // fn#52497, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:788, offset: 0x0132e1fc, size: 58 bytes, params: 2, frame: 12
|
||||
const guild = GuildStore.getGuild(a0);
|
||||
return guild != null && guild.features.has(GuildFeatures.ENHANCED_ROLE_COLORS);
|
||||
}
|
||||
|
||||
function _fun52493() { // fn#52493, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6808:309, offset: 0x0132e13c, size: 62 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
const guild = GuildStore.getGuild(env0_0);
|
||||
return guild != null && guild.features.has(GuildFeatures.ENHANCED_ROLE_COLORS);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
/* Metro module 15722; source: modules/premium/powerups/hooks/useIsCurrentUserEligibleForPowerupUpsells.tsx; dependencies: [1945, 4896, 1878, 7020, 1880, 1900, 566, 2] */
|
||||
function _fun120732(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120732, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:6, offset: 0x02534577, size: 208 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
|
||||
const sortedGuildStore = importDefault(4896) /* metro dependency 4896: SortedGuildStore */;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const guildBoostSlotStore = importDefault(7020) /* metro dependency 7020: GuildBoostSlotStore */;
|
||||
const env0_6 = (require(1880) /* metro dependency 1880: PremiumConstants */).PremiumTypes;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useIsCurrentUserEligibleForPowerupUpsells.tsx');
|
||||
exports.default = useIsCurrentUserEligibleForPowerupUpsells;
|
||||
exports.getIsCurrentUserEligibleForPowerupUpsells = getIsCurrentUserEligibleForPowerupUpsells;
|
||||
}
|
||||
|
||||
function checkPowerupUpsellEligibility(a0, a1, a2) { // fn#120733, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:159, offset: 0x02534647, size: 155 bytes, params: 4, frame: 19
|
||||
var r2;
|
||||
var r1;
|
||||
var r0;
|
||||
var moduleValue;
|
||||
const env0_0 = a0;
|
||||
let value = a0 != null;
|
||||
if (value) {
|
||||
value = a0.isPremiumGroupMember();
|
||||
if (value) {
|
||||
r1 = !value;
|
||||
} else {
|
||||
moduleValue = require(1900) /* metro dependency 1900: PremiumTypeUtils */;
|
||||
value = moduleValue.isPremium(a0, PremiumTypes.TIER_2);
|
||||
if (value) {
|
||||
r2 = !!value;
|
||||
} else {
|
||||
value = a1.some(function(a0) {
|
||||
return a0.premiumGuildSubscription != null;
|
||||
});
|
||||
r2 = value ? !!value : a2.some(_fun120735);
|
||||
}
|
||||
r1 = r2;
|
||||
}
|
||||
r0 = r1;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function useIsCurrentUserEligibleForPowerupUpsells() { // fn#120736, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:542, offset: 0x0253471b, size: 149 bytes, params: 1, frame: 22
|
||||
const checkPowerupUpsellEligibilityBinding = checkPowerupUpsellEligibility;
|
||||
const fluxModule = require(566) /* metro dependency 566: flux */;
|
||||
let useStateFromStores = fluxModule.useStateFromStores;
|
||||
const currentUser = Reflect.apply(useStateFromStores, fluxModule, [[UserStore], function() {
|
||||
return UserStore.getCurrentUser();
|
||||
}]);
|
||||
const value2 = fluxModule.useStateFromStoresArray([GuildBoostSlotStore], _fun120738);
|
||||
const moduleValue3 = fluxModule;
|
||||
useStateFromStores = moduleValue3.useStateFromStores;
|
||||
return checkPowerupUpsellEligibilityBinding(currentUser, value2, Reflect.apply(useStateFromStores, moduleValue3,
|
||||
[[SortedGuildStore], function() {
|
||||
return SortedGuildStore.getFlattenedGuildIds();
|
||||
}]));
|
||||
}
|
||||
|
||||
function getIsCurrentUserEligibleForPowerupUpsells() { // fn#120740, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:885, offset: 0x025347f7, size: 92 bytes, params: 1, frame: 17
|
||||
return checkPowerupUpsellEligibility(UserStore.getCurrentUser(),
|
||||
GuildBoostSlotStore.hasFetched ? global.Object.values(GuildBoostSlotStore.boostSlots) : [],
|
||||
SortedGuildStore.getFlattenedGuildIds());
|
||||
}
|
||||
|
||||
function _fun120735(a0) { // fn#120735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:341, offset: 0x025346e2, size: 57 bytes, params: 2, frame: 13
|
||||
const value = environment.__proto__;
|
||||
return GuildMemberStore.getMember(a0, env0_0.id)?.premiumSince != null;
|
||||
}
|
||||
|
||||
function _fun120738() { // fn#120738, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15930:726, offset: 0x025347b0, size: 52 bytes, params: 1, frame: 12
|
||||
const value = environment.__proto__;
|
||||
return GuildBoostSlotStore.hasFetched ? global.Object.values(GuildBoostSlotStore.boostSlots) : [];
|
||||
}
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
/* Metro module 12685; source: modules/premium/powerups/hooks/useIsServerThemeAvailableForGuild.tsx; dependencies: [8263, 4038, 2] */
|
||||
function _fun97220(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#97220, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12875:6, offset: 0x02177b0b, size: 96 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useIsServerThemeAvailableForGuild.tsx');
|
||||
exports.default = function(a0, a1) {
|
||||
var value = a0;
|
||||
require(dependencyMap[0]).useServerThemeEnabled(value ?? undefined, a1);
|
||||
return require(dependencyMap[1]).useEnabledGuildThemeForGuildId(value, a1) != null;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
/* Metro module 14601; source: modules/premium/powerups/hooks/useLoadGuildPowerups.tsx; dependencies: [31, 6857, 14602, 12307, 2] */
|
||||
function _fun110385(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110385, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14798:6, offset: 0x02377c5d, size: 114 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useLoadGuildPowerups.tsx');
|
||||
exports.default = useLoadGuildPowerups;
|
||||
}
|
||||
|
||||
function useLoadGuildPowerups(a0) { // fn#110386, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14798:205, offset: 0x02377ccf, size: 118 bytes, params: 2, frame: 17
|
||||
const env0_0 = a0;
|
||||
const value2 = (require(6857) /* metro dependency 6857: GameServerExperiment */).useGameServerEnabled(a0,
|
||||
'useLoadGuildPowerups');
|
||||
const binding = env0_2;
|
||||
binding.useEffect(_fun110387, [a0, value2]);
|
||||
binding.useEffect(_fun110388, [a0]);
|
||||
}
|
||||
|
||||
function _fun110387() { // fn#110387, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14798:312, offset: 0x02377d45, size: 54 bytes, params: 1, frame: 12
|
||||
var value2;
|
||||
if (env0_1) {
|
||||
value2 = environment.__proto__;
|
||||
(require(14602) /* metro dependency 14602: GameServerActionCreators */).fetchGameServerCatalog(env0_0);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110388() { // fn#110388, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14798:376, offset: 0x02377d7b, size: 65 bytes, params: 1, frame: 15
|
||||
let value = environment.__proto__;
|
||||
value = require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */;
|
||||
const fetchPowerupCatalogForGuild = value.fetchPowerupCatalogForGuild;
|
||||
const binding = env0_0;
|
||||
Reflect.apply(fetchPowerupCatalogForGuild, value, [binding]);
|
||||
(require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */).fetchGuildBoostEntitlements(binding);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
/* Metro module 12303; source: modules/premium/powerups/hooks/useMarketablePowerupPerks.tsx; dependencies: [31, 8258, 8259, 8188, 566, 12304, 2] */
|
||||
function _fun93968(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93968, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12489:6, offset: 0x020cd1e8, size: 283 bytes, params: 8, frame: 23
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
let value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET = value.GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET;
|
||||
const GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET = value.GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET;
|
||||
const env0_5 = value.GuildPowerupType;
|
||||
const Set = global.Set;
|
||||
let Array = global.Array;
|
||||
value = Array.from(GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET);
|
||||
items = [];
|
||||
value = arraySpread(items, value, 0, GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET);
|
||||
Array = global.Array;
|
||||
value = arraySpread(items, Array.from(GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET), value,
|
||||
GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET);
|
||||
const VANITY_URL_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).VANITY_URL_POWERUP_SKU_ID;
|
||||
items[value] = VANITY_URL_POWERUP_SKU_ID;
|
||||
value + 1;
|
||||
const set = new Set(items);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useMarketablePowerupPerks.tsx');
|
||||
exports.default = useMarketablePowerupPerks;
|
||||
}
|
||||
|
||||
function useMarketablePowerupPerks(a0) { // fn#93969, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12489:424, offset: 0x020cd303, size: 129 bytes, params: 2, frame: 18
|
||||
const env0_0 = a0;
|
||||
return env0_3.useMemo(_fun93971,
|
||||
[(require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore], _fun93970),
|
||||
(importDefault(12304) /* metro dependency 12304: useGameServerPerk */)(a0)]);
|
||||
}
|
||||
|
||||
function _fun93970() { // fn#93970, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12489:500, offset: 0x020cd384, size: 67 bytes, params: 1, frame: 14
|
||||
const stateForGuild = GuildPowerupsStore.getStateForGuild(env0_0);
|
||||
return stateForGuild == null || stateForGuild.powerupCatalog == null ? undefined : stateForGuild.powerupCatalog[GuildPowerupType.PERK];
|
||||
}
|
||||
|
||||
function _fun93971() { // fn#93971, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12489:629, offset: 0x020cd3c7, size: 82 bytes, params: 1, frame: 15
|
||||
const r4 = env0_1 ?? [];
|
||||
const items2 = [];
|
||||
arraySpread(items2, r4, 0, r4);
|
||||
if (env0_2 != null) {
|
||||
items2.push(env0_2);
|
||||
}
|
||||
return items2.filter(_fun93972);
|
||||
}
|
||||
|
||||
function _fun93972({skuId}) { // fn#93972, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12489:694, offset: 0x020cd419, size: 30 bytes, params: 2, frame: 11
|
||||
const binding = env2_6;
|
||||
return !binding.has(skuId);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,152 @@
|
||||
/* Metro module 14674; source: modules/premium/powerups/hooks/useMaybeGetSortedBoosts.tsx; dependencies: [57, 31, 12346, 6269, 1945, 1867, 14675, 566, 14676, 8251, 21, 1244, 2] */
|
||||
function _fun110766(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110766, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:6, offset: 0x023868d8, size: 214 bytes, params: 8, frame: 19
|
||||
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 appliedGuildBoostStore = importDefault(12346) /* metro dependency 12346: AppliedGuildBoostStore */;
|
||||
const guildMemberRequesterStore = importDefault(6269) /* metro dependency 6269: GuildMemberRequesterStore */;
|
||||
const guildMemberStore = importDefault(1945) /* metro dependency 1945: GuildMemberStore */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useMaybeGetSortedBoosts.tsx');
|
||||
exports.default = useMaybeGetSortedBoosts;
|
||||
exports.useGetBoostUserConfig = useGetBoostUserConfig;
|
||||
}
|
||||
|
||||
function useMaybeGetSortedBoosts(a0, a1) { // fn#110767, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:261, offset: 0x023869ae, size: 456 bytes, params: 3, frame: 27
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = (require(14675) /* metro dependency 14675: ExpiringBoostsExperiment */).useExpiringBoostsEnabled('GuildPowerupsRecentActivity');
|
||||
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStoresArray([AppliedGuildBoostStore],
|
||||
_fun110768, [a0]);
|
||||
const env0_3 = value3;
|
||||
const binding = env0_4;
|
||||
const value6 = binding.useMemo(_fun110770, [value3, a1, env0_3(binding.useState(function() {
|
||||
var Date = global.Date;
|
||||
return Date.now();
|
||||
}), 1)[0], value2]);
|
||||
binding.useEffect(_fun110775, [a0,
|
||||
(require(566) /* metro dependency 566: flux */).useStateFromStoresArray([GuildMemberStore], _fun110773, [a0,
|
||||
value6])]);
|
||||
binding.useEffect(_fun110781, [a0, (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore],
|
||||
_fun110777), binding.useMemo(_fun110778, [value3]), value2,
|
||||
(require(566) /* metro dependency 566: flux */).useStateFromStores([AppliedGuildBoostStore], _fun110780, [a0])]);
|
||||
return value6;
|
||||
}
|
||||
|
||||
function useGetBoostUserConfig(a0) { // fn#110782, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1460, offset: 0x02386e65, size: 176 bytes, params: 2, frame: 19
|
||||
const env0_0 = a0;
|
||||
const Date = global.Date;
|
||||
const defaultImport = importDefault(21) /* metro dependency 21: SnowflakeUtils */;
|
||||
const date = new Date(defaultImport.extractTimestamp(a0.id));
|
||||
const value = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([GuildMemberStore],
|
||||
_fun110783, [a0]);
|
||||
const username = value.username;
|
||||
return {timestamp: date, username: username, roleColor: value.roleColor, roleColorStrings: value.roleColorStrings};
|
||||
}
|
||||
|
||||
function _fun110768() { // fn#110768, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:408, offset: 0x02386b76, size: 37 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return AppliedGuildBoostStore.getAppliedGuildBoostsForGuild(env0_0) ?? [];
|
||||
}
|
||||
|
||||
function _fun110770() { // fn#110770, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:539, offset: 0x02386b9b, size: 63 bytes, params: 1, frame: 14
|
||||
return env0_3.map(_fun110771).sort(function(a0, {sortKey}) {
|
||||
return sortKey - a0.sortKey;
|
||||
}).slice(0, require);
|
||||
}
|
||||
|
||||
function _fun110773() { // fn#110773, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:868, offset: 0x02386ca9, size: 76 bytes, params: 1, frame: 13
|
||||
const Set = global.Set;
|
||||
const set = new Set();
|
||||
env0_5.forEach(_fun110774);
|
||||
const Array = global.Array;
|
||||
return Array.from(set);
|
||||
}
|
||||
|
||||
function _fun110775() { // fn#110775, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1005, offset: 0x02386d3d, size: 45 bytes, params: 1, frame: 11
|
||||
if (env0_6.length > 0) {
|
||||
env0_6.forEach(_fun110776);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110777() { // fn#110777, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1106, offset: 0x02386d89, size: 44 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildStore.getGuild(env0_0)?.premiumSubscriberCount;
|
||||
}
|
||||
|
||||
function _fun110778() { // fn#110778, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1196, offset: 0x02386db5, size: 33 bytes, params: 1, frame: 11
|
||||
const binding = env0_3;
|
||||
return binding.filter(function(a0) {
|
||||
return !a0.ended;
|
||||
}).length;
|
||||
}
|
||||
|
||||
function _fun110780() { // fn#110780, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1271, offset: 0x02386de4, size: 35 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return AppliedGuildBoostStore.getLastFetchedAtForGuild(env0_0) != null;
|
||||
}
|
||||
|
||||
function _fun110781() { // fn#110781, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1337, offset: 0x02386e07, size: 94 bytes, params: 1, frame: 14
|
||||
var value4;
|
||||
var moduleValue;
|
||||
if (env0_7 !== env0_8 || env0_2 && !env0_9) {
|
||||
value4 = environment.__proto__;
|
||||
moduleValue = require(8251) /* metro dependency 8251: BoostingActionCreators */;
|
||||
moduleValue.fetchAppliedGuildBoostsForGuild(env0_0, {includeEnded: env0_2});
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110783() { // fn#110783, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1582, offset: 0x02386f15, size: 225 bytes, params: 1, frame: 19
|
||||
var intl;
|
||||
let value = environment.__proto__;
|
||||
const getMember = GuildMemberStore.getMember;
|
||||
const binding = env0_0;
|
||||
let guildId = binding.guildId;
|
||||
let userId = binding.userId;
|
||||
const value3 = Reflect.apply(getMember, GuildMemberStore, [guildId, userId]);
|
||||
const getNick = GuildMemberStore.getNick;
|
||||
guildId = binding.guildId;
|
||||
userId = binding.userId;
|
||||
const value4 = Reflect.apply(getNick, GuildMemberStore, [guildId, userId]);
|
||||
const value5 = null;
|
||||
let r2 = value5 != value4 ? value4 : value5 == env0_0.user ? undefined : env0_0.user.username;
|
||||
if (value5 == r2) {
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
r2 = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['30mdIx']);
|
||||
}
|
||||
value = undefined;
|
||||
const colorString = value5 == value3 ? value : value3.colorString;
|
||||
const colorStrings = value5 == value3 ? value : value3.colorStrings;
|
||||
return {username: r2, roleColor: value5 != colorString ? colorString : value5,
|
||||
roleColorStrings: value5 != colorStrings ? colorStrings : value5};
|
||||
}
|
||||
|
||||
function _fun110771(a0) { // fn#110771, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:550, offset: 0x02386bda, size: 183 bytes, params: 2, frame: 15
|
||||
let value = environment.__proto__;
|
||||
const r1 = env1_2 ? (require(14676) /* metro dependency 14676: getBoostLifecyclePhase */).getBoostLifecycleInfo(a0,
|
||||
env1_4) : {phase: 'gave'};
|
||||
value = environment.__proto__.__proto__;
|
||||
value = require(14676) /* metro dependency 14676: getBoostLifecyclePhase */;
|
||||
value = value.getBoostLifecycleTimestamp(a0, r1);
|
||||
return r1.phase === 'expiring' ? {boost: a0, phase: 'expiring', sortKey: value, endsAt: r1.endsAt} : {boost: a0,
|
||||
phase: r1.phase, sortKey: value};
|
||||
}
|
||||
|
||||
function _fun110774({boost}) { // fn#110774, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:905, offset: 0x02386cf5, size: 72 bytes, params: 2, frame: 14
|
||||
let value = environment.__proto__.__proto__;
|
||||
const getMember = GuildMemberStore.getMember;
|
||||
value = environment.__proto__;
|
||||
let binding = env1_0;
|
||||
const userId = boost.userId;
|
||||
if (Reflect.apply(getMember, GuildMemberStore, [binding, userId]) == null) {
|
||||
binding = env0_0;
|
||||
binding.add(boost.userId);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110776(a0) { // fn#110776, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14871:1033, offset: 0x02386d6a, size: 31 bytes, params: 2, frame: 13
|
||||
return GuildMemberRequesterStore.requestMember(env1_0, a0);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,69 @@
|
||||
/* Metro module 14668; source: modules/premium/powerups/hooks/useMultiPerkStatusValues.tsx; dependencies: [8259, 14635, 1244, 2256, 2] */
|
||||
function _fun110738(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110738, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14865:6, offset: 0x02385002, size: 124 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).PowerupActiveStatusType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useMultiPerkStatusValues.tsx');
|
||||
exports.default = useMultiPerkStatusValues;
|
||||
}
|
||||
|
||||
function useMultiPerkStatusValues({guildId, powerups}) { // fn#110739, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14865:233, offset: 0x0238507e, size: 397 bytes, params: 2, frame: 23
|
||||
var r5;
|
||||
var object2;
|
||||
var intl;
|
||||
let value3 = (require(14635) /* metro dependency 14635: usePowerupActiveStatus */).usePowerupsActiveStatuses(guildId,
|
||||
powerups);
|
||||
const value4 = value3.some(function({type}) {
|
||||
return type !== PowerupActiveStatusType.INACTIVE;
|
||||
});
|
||||
if (powerups.length <= 0) {
|
||||
return null;
|
||||
}
|
||||
let reduce = value3.reduce;
|
||||
const value6 = Reflect.apply(reduce, value3, [function(a0, a1) {
|
||||
var r2;
|
||||
var value = a0;
|
||||
r2 = a1.sourceEntitlement?.ends_at;
|
||||
return r2 == null ? value : value == null || r2 < value ? r2 : value;
|
||||
}, undefined]);
|
||||
if (value6 != null) {
|
||||
r5 = {type: 'expiring', expiringAt: value6};
|
||||
} else if (value4) {
|
||||
object2 = {type: 'active'};
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object2.statusText = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).FFLkmx);
|
||||
r5 = object2;
|
||||
} else {
|
||||
r5 = undefined;
|
||||
}
|
||||
let value = value3.reduce(function(a0, a1) {
|
||||
var r0;
|
||||
var value = a0;
|
||||
if (a1.type !== PowerupActiveStatusType.POWERUP_ACTIVATED) {
|
||||
r0 = value;
|
||||
} else {
|
||||
value += a1.powerup.cost;
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}, 0);
|
||||
reduce = value3.reduce;
|
||||
let property = value3[0];
|
||||
const value7 = Reflect.apply(reduce, value3, [function(a0, a1) {
|
||||
var r6;
|
||||
var value = a0;
|
||||
var property = a1.powerup;
|
||||
var value2 = undefined;
|
||||
r6 = property == null ? value2 : property.cost;
|
||||
var value3 = 0;
|
||||
return value < (r6 ?? value3) ? value : (property == null ? value2 : property.cost) ?? value3;
|
||||
}, (property == null || property.powerup == null ? undefined : property.powerup.cost) ?? 0]);
|
||||
const value8 = value3.reduce(function(a0, {powerup}) {
|
||||
return a0 + (powerup?.cost ?? 0);
|
||||
}, 0);
|
||||
let r6 = value4 ? value : value7;
|
||||
return {isActive: value4, status: r5, cost: r6, costDecorator: value4 ? undefined : value8 > r6 ? '+' : undefined,
|
||||
expiringAt: value6, activeCost: value, minCost: value7, totalCost: value8};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
/* Metro module 14635; source: modules/premium/powerups/hooks/usePowerupActiveStatus.tsx; dependencies: [1867, 8258, 8260, 8259, 661, 566, 2] */
|
||||
function _fun110610(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110610, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14832:6, offset: 0x0237f806, size: 256 bytes, params: 8, frame: 20
|
||||
const env0_0 = require;
|
||||
const closure = usePowerupsActiveStatuses;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const env0_4 = (require(8260) /* metro dependency 8260: GameServerConstants */).GAME_SERVER_POWERUP_SKU_ID;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_5 = guildPowerupsConstantsModule.GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS;
|
||||
const env0_6 = guildPowerupsConstantsModule.PowerupActiveStatusType;
|
||||
const env0_7 = guildPowerupsConstantsModule.POWERUPS_INCLUDED_IN_LEVEL;
|
||||
const env0_8 = guildPowerupsConstantsModule.BOOSTING_TIER_TO_LEVEL_SKU_ID;
|
||||
const env0_9 = (require(661) /* metro dependency 661: Constants */).GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/usePowerupActiveStatus.tsx');
|
||||
exports.default = function(a0, a1) {
|
||||
var value2 = usePowerupsActiveStatuses(a0, a1 == null ? [] : [a1]);
|
||||
return value2.length <= 0 ? {type: PowerupActiveStatusType.INACTIVE, sourceEntitlement: undefined,
|
||||
sourcePowerup: undefined} : value2[0];
|
||||
};
|
||||
exports.isPowerupActiveStatusActive = function({type}) {
|
||||
return type !== PowerupActiveStatusType.INACTIVE;
|
||||
};
|
||||
exports.usePowerupsActiveStatuses = closure;
|
||||
}
|
||||
|
||||
function usePowerupsActiveStatuses(a0, a1) { // fn#110611, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14832:321, offset: 0x0237f906, size: 204 bytes, params: 3, frame: 20
|
||||
const env0_0 = a0;
|
||||
const value2 = undefined;
|
||||
const guild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110613);
|
||||
const env0_2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore], _fun110614);
|
||||
const r3 = guild == null || guild.features == null ? value2 : guild.features.has(GuildFeatures.PREMIUM_TIER_3_OVERRIDE);
|
||||
const env0_3 = r3 != null && r3;
|
||||
return a1.map(function(a0) {
|
||||
return getPowerupActiveStatus(a0);
|
||||
});
|
||||
}
|
||||
|
||||
function getPowerupActiveStatus(a0) { // fn#110612, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14832:570, owner: usePowerupsActiveStatuses.getPowerupActiveStatus, offset: 0x0237f9d2, size: 596 bytes, params: 2, frame: 19
|
||||
var r3;
|
||||
var guildBinding;
|
||||
var value10;
|
||||
if (a0.skuId === GAME_SERVER_POWERUP_SKU_ID) {
|
||||
guildBinding = guild;
|
||||
value10 = undefined;
|
||||
r3 = guildBinding == null || guild.features == null ? value10 : guild.features.has(GuildFeatures.GAME_SERVERS);
|
||||
r3 = r3 == null ? PowerupActiveStatusType.INACTIVE : r3 ? PowerupActiveStatusType.POWERUP_ACTIVATED : PowerupActiveStatusType.INACTIVE;
|
||||
return {type: r3, powerup: a0, sourceEntitlement: value10, sourcePowerup: value10};
|
||||
}
|
||||
const value2 = null;
|
||||
let r0 = value2 == a0 || value2 == guild || (value2 == stateForGuild || value2 == POWERUPS_INCLUDED_IN_LEVEL[a0.skuId]) ? {isActiveFromLevel: false,
|
||||
levelEntitlement: undefined,
|
||||
levelPowerup: undefined} : {isActiveFromLevel: guild.premiumTier >= POWERUPS_INCLUDED_IN_LEVEL[a0.skuId],
|
||||
levelEntitlement: value2 != BOOSTING_TIER_TO_LEVEL_SKU_ID[POWERUPS_INCLUDED_IN_LEVEL[a0.skuId]] ? value2 == stateForGuild.unlockedPowerups ? undefined : stateForGuild.unlockedPowerups[BOOSTING_TIER_TO_LEVEL_SKU_ID[POWERUPS_INCLUDED_IN_LEVEL[a0.skuId]]] : undefined,
|
||||
levelPowerup: value2 != BOOSTING_TIER_TO_LEVEL_SKU_ID[POWERUPS_INCLUDED_IN_LEVEL[a0.skuId]] ? value2 == stateForGuild.allPowerups ? undefined : stateForGuild.allPowerups[BOOSTING_TIER_TO_LEVEL_SKU_ID[POWERUPS_INCLUDED_IN_LEVEL[a0.skuId]]] : undefined};
|
||||
const isActiveFromLevel = r0.isActiveFromLevel;
|
||||
const levelEntitlement = r0.levelEntitlement;
|
||||
const levelPowerup = r0.levelPowerup;
|
||||
const r8 = env0_3 && GUILD_POWERUP_TIER_3_OVERRIDDEN_SKUS.has(a0.skuId);
|
||||
const stateForGuildBinding = stateForGuild;
|
||||
const value8 = undefined;
|
||||
r0 = value2 == stateForGuildBinding || value2 == stateForGuild.unlockedPowerups ? value8 : stateForGuild.unlockedPowerups[a0.skuId];
|
||||
const r7 = value2 != r0 ? r0 : value2;
|
||||
const INACTIVE = PowerupActiveStatusType.INACTIVE;
|
||||
return isActiveFromLevel ? {type: PowerupActiveStatusType.LEVEL_ACTIVATED, powerup: a0,
|
||||
sourceEntitlement: levelEntitlement,
|
||||
sourcePowerup: levelPowerup} : r8 ? {type: PowerupActiveStatusType.TIER_OVERRIDE_ACTIVATED, powerup: a0,
|
||||
sourceEntitlement: value8, sourcePowerup: a0} : value2 == r7 ? {type: INACTIVE, powerup: a0,
|
||||
sourceEntitlement: value8, sourcePowerup: value8} : {type: PowerupActiveStatusType.POWERUP_ACTIVATED,
|
||||
powerup: a0, sourceEntitlement: r7, sourcePowerup: a0};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
/* Metro module 14691; source: modules/premium/powerups/hooks/useTotalPossibleBoostCount.tsx; dependencies: [31, 8259, 661, 2] */
|
||||
function _fun110852(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110852, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14888:6, offset: 0x023897ba, size: 182 bytes, params: 8, frame: 18
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let env0_0 = (require(31) /* metro dependency 31 */).useMemo;
|
||||
let value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_1 = value.MULTIPLE_PURCHASEABLE_PREMIUM_FEATURES_BOOST_INFO;
|
||||
const env0_2 = value.PURCHASABLE_PREMIUM_FEATURES_BOOST_INFO;
|
||||
value = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_3 = value.AppliedGuildBoostsRequiredForBoostedGuildTier;
|
||||
const env0_4 = value.BoostedGuildTiers;
|
||||
const env0_5 = value.GuildFeatures;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/hooks/useTotalPossibleBoostCount.tsx');
|
||||
exports.default = function(a0) {
|
||||
var env0_0 = a0;
|
||||
return useMemo(_fun110854, [a0]);
|
||||
};
|
||||
}
|
||||
|
||||
function useTotalPossibleBoostCount(a0) { // fn#110853, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14888:427, offset: 0x02389870, size: 41 bytes, params: 2, frame: 13
|
||||
const env0_0 = a0;
|
||||
return useMemo(_fun110854, [a0]);
|
||||
}
|
||||
|
||||
function _fun110854() { // fn#110854, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14888:476, offset: 0x02389899, size: 179 bytes, params: 1, frame: 14
|
||||
var environment;
|
||||
var r3;
|
||||
var features;
|
||||
var has;
|
||||
var value;
|
||||
if (env0_0 == null) {
|
||||
return 0;
|
||||
}
|
||||
if (env0_0 == null) {
|
||||
r3 = undefined;
|
||||
} else {
|
||||
features = env0_0.features;
|
||||
has = features.has;
|
||||
value = environment.__proto__;
|
||||
value = Reflect.apply(has, features, [GuildFeatures.PREMIUM_TIER_3_OVERRIDE]);
|
||||
r3 = value;
|
||||
}
|
||||
var env0_0 = r3 === true ? 0 : AppliedGuildBoostsRequiredForBoostedGuildTier[BoostedGuildTiers.TIER_3];
|
||||
let Object = global.Object;
|
||||
const values = Object.values;
|
||||
value = environment.__proto__;
|
||||
const value3 = Reflect.apply(values, Object, [PURCHASABLE_PREMIUM_FEATURES_BOOST_INFO]);
|
||||
Object = global.Object;
|
||||
value = Object.values(MULTIPLE_PURCHASEABLE_PREMIUM_FEATURES_BOOST_INFO);
|
||||
value = value3.concat(value);
|
||||
value.forEach(_fun110855);
|
||||
return env0_0;
|
||||
}
|
||||
|
||||
function _fun110855(a0) { // fn#110855, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14888:651, offset: 0x0238994c, size: 97 bytes, params: 2, frame: 14
|
||||
var r3;
|
||||
var r1;
|
||||
var isEnabled;
|
||||
let value = a0.includedInLevel != null;
|
||||
if (value) {
|
||||
r1 = value;
|
||||
} else {
|
||||
isEnabled = a0.isEnabled;
|
||||
value = undefined;
|
||||
if (isEnabled == null) {
|
||||
r3 = value;
|
||||
} else {
|
||||
isEnabled = a0.isEnabled;
|
||||
value = environment.__proto__;
|
||||
value = Reflect.apply(isEnabled, a0, [env1_0.id]);
|
||||
r3 = value;
|
||||
}
|
||||
value = r3 != null;
|
||||
r1 = value && !r3;
|
||||
}
|
||||
if (!r1) {
|
||||
env0_0 = env0_0 + a0.boostPrice;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
/* Metro module 12308; source: modules/premium/powerups/mocks/GuildPowerupMocks.tsx; dependencies: [8259, 2] */
|
||||
function _fun93995(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93995, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12494:6, offset: 0x020cde84, size: 479 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const GuildPowerupType = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).GuildPowerupType;
|
||||
let LEVEL = GuildPowerupType.LEVEL;
|
||||
const items3 = [{'type': null, 'skuId': '1', 'title': 'Lorem ipsum', 'cost': 1, type: LEVEL, dependencies: [],
|
||||
features: {'additional_emoji_slots': 50, 'additional_sound_slots': 50, 'additional_sticker_slots': 50,
|
||||
'total_emoji_slots': 50, 'total_sound_slots': 50, 'total_sticker_slots': 50, features: []}}];
|
||||
LEVEL = GuildPowerupType.LEVEL;
|
||||
items3[1] = {'type': null, 'skuId': '2', 'title': 'Lorem ipsum', 'cost': 1, type: LEVEL, dependencies: ['1'],
|
||||
features: {'additional_emoji_slots': 50, 'additional_sound_slots': 50, 'additional_sticker_slots': 50,
|
||||
'total_emoji_slots': 50, 'total_sound_slots': 50, 'total_sticker_slots': 50, features: []}};
|
||||
LEVEL = GuildPowerupType.LEVEL;
|
||||
items3[2] = {'type': null, 'skuId': '3', 'title': 'Lorem ipsum', 'cost': 1, type: LEVEL, dependencies: ['2'],
|
||||
features: {'additional_emoji_slots': 50, 'additional_sound_slots': 50, 'additional_sticker_slots': 50,
|
||||
'total_emoji_slots': 50, 'total_sound_slots': 50, 'total_sticker_slots': 50, features: []}};
|
||||
let PERK = GuildPowerupType.PERK;
|
||||
const items2 = [{'type': null, 'skuId': '4', 'title': 'Lorem ipsum',
|
||||
'description': 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec placerat posuere lao', 'cost': 1,
|
||||
type: PERK, dependencies: []}];
|
||||
PERK = GuildPowerupType.PERK;
|
||||
items2[1] = {'type': null, 'skuId': '5', 'title': 'Lorem ipsum',
|
||||
'description': 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec placerat posuere lao', 'cost': 1,
|
||||
type: PERK, dependencies: []};
|
||||
PERK = GuildPowerupType.PERK;
|
||||
items2[2] = {'type': null, 'skuId': '6', 'title': 'Lorem ipsum',
|
||||
'description': 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec placerat posuere lao', 'cost': 1,
|
||||
type: PERK, dependencies: []};
|
||||
PERK = GuildPowerupType.PERK;
|
||||
items2[3] = {'type': null, 'skuId': '7', 'title': 'Lorem ipsum',
|
||||
'description': 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec placerat posuere lao', 'cost': 1,
|
||||
type: PERK, dependencies: []};
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/mocks/GuildPowerupMocks.tsx');
|
||||
exports.MOCK_LEVELS = items3;
|
||||
exports.MOCK_PERKS = items2;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
/* Metro module 14563; source: modules/premium/powerups/native/BoostProgressBarCoachmark.tsx; dependencies: [31, 27, 1376, 33, 4501, 9112, 1244, 2256, 3868, 8543, 2] */
|
||||
function _fun110123(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110123, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14760:6, offset: 0x0236b5d0, size: 232 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const env0_4 = (require(27) /* metro dependency 27 */).View;
|
||||
const env0_5 = (require(1376) /* metro dependency 1376: DismissibleContentConstants */).ContentDismissActionType;
|
||||
const env0_6 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const env0_7 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({riveContainer: {'width': 120,
|
||||
'height': 80, 'alignSelf': 'center'}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/BoostProgressBarCoachmark.tsx');
|
||||
exports.default = BoostProgressBarCoachmark;
|
||||
}
|
||||
|
||||
function BoostProgressBarCoachmark({targetRef, guild, markAsDismissed}) { // fn#110124, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14760:357, offset: 0x0236b6b8, size: 196 bytes, params: 2, frame: 20
|
||||
const styles = useStyles();
|
||||
const binding = env0_3;
|
||||
const value2 = binding.useCallback(function() {
|
||||
markAsDismissed(ContentDismissActionType.USER_DISMISS);
|
||||
}, [markAsDismissed]);
|
||||
const value3 = binding.useCallback(function() {
|
||||
markAsDismissed(ContentDismissActionType.TAKE_ACTION);
|
||||
importDefault(dependencyMap[5]).saveGuild(guild.id, {premiumProgressBarEnabled: true});
|
||||
}, [guild.id, markAsDismissed]);
|
||||
const useMemo = binding.useMemo;
|
||||
(require(8543) /* metro dependency 8543: useCoachmarkNative */).useCoachmark(targetRef, Reflect.apply(useMemo,
|
||||
binding, [_fun110127, [value2, value3, styles.riveContainer]]));
|
||||
return null;
|
||||
}
|
||||
|
||||
function _fun110127() { // fn#110127, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14760:609, offset: 0x0236b7e8, size: 228 bytes, params: 1, frame: 18
|
||||
const object2 = {'title': null, 'description': null, 'visible': true, 'position': 'bottom', 'offsetY': 8};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
object2.title = Reflect.apply(string, intl,
|
||||
[(importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).uwV2dH]);
|
||||
string = intl.string;
|
||||
const MIwlcR = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).MIwlcR;
|
||||
object2.description = Reflect.apply(string, intl, [MIwlcR]);
|
||||
object2.onDismiss = env0_3;
|
||||
object2.renderImgComponent = renderImgComponent_110128;
|
||||
object2.buttonLabel = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['0CJWP2']);
|
||||
object2.buttonVariant = 'primary';
|
||||
object2.onButtonPress = env0_4;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function renderImgComponent_110128() { // fn#110128, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14760:775, offset: 0x0236b8cc, size: 89 bytes, params: 1, frame: 16
|
||||
const BoostThisServerRive = (require(3868) /* metro dependency 3868: native */).BoostThisServerRive;
|
||||
return (
|
||||
<View style={styles.riveContainer}>
|
||||
<BoostThisServerRive stateMachine="State Machine 1" />
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,165 @@
|
||||
/* Metro module 15965; source: modules/premium/powerups/native/EnhancedRoleColorsSelectStyleModal.tsx; dependencies: [27, 15947, 15949, 15946, 482, 33, 4501, 697, 4048, 6630, 15966, 1244, 8177, 6275, 6758, 4080, 9773, 1941, 8206, 15967, 4573, 2256, 4020, 2] */
|
||||
function _fun123442(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#123442, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:6, offset: 0x0258d5f9, size: 284 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(27) /* metro dependency 27 */;
|
||||
const env0_3 = value.Pressable;
|
||||
const env0_4 = value.View;
|
||||
const env0_5 = (require(15947) /* metro dependency 15947: GuildSettingsRolesStore */).RoleColorsStyle;
|
||||
const env0_6 = (require(15949) /* metro dependency 15949: EnhancedRoleColorConstants */).HOLOGRAPHIC_ROLE_COLORS;
|
||||
const env0_7 = (require(15946) /* metro dependency 15946: GuildSettingsRoleConstants */).STYLE_CONFIGS;
|
||||
const env0_8 = (require(482) /* metro dependency 482: Constants */).ThemeTypes;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_9 = value.jsx;
|
||||
const env0_10 = value.jsxs;
|
||||
const env0_11 = (require(4501) /* metro dependency 4501: createStyles */).createStyles(_fun123443);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/EnhancedRoleColorsSelectStyleModal.tsx');
|
||||
exports.default = EnhancedRoleColorsSelectStyleModal;
|
||||
}
|
||||
|
||||
function _fun123443(a0) { // fn#123443, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:285, offset: 0x0258d715, size: 619 bytes, params: 2, frame: 19
|
||||
const object3 = {};
|
||||
const object8 = {};
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object8.marginHorizontal = PX_12;
|
||||
const PX_32 = (importDefault(697) /* metro dependency 697: native */).space.PX_32;
|
||||
object8.marginBottom = PX_32;
|
||||
object3.container = object8;
|
||||
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.stylesContainer = {'display': 'flex', 'flexDirection': 'row', gap: PX_8};
|
||||
const object9 = {'borderRadius': null, 'overflow': 'hidden', 'height': 100, 'width': 100, 'flex': 1,
|
||||
'backgroundColor': null, 'display': 'flex', 'flexDirection': 'column', 'alignItems': 'center',
|
||||
'justifyContent': 'center'};
|
||||
object9.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
const BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
|
||||
object9.backgroundColor = BACKGROUND_BASE_LOWEST;
|
||||
object3.button = object9;
|
||||
const object10 = {'width': 400, 'flex': 1, 'marginStart': null, 'marginVertical': null, 'alignSelf': 'flex-start'};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object10.marginStart = PX_8;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object10.marginVertical = PX_8;
|
||||
object3.message = object10;
|
||||
const object11 = {'width': '100%', 'textAlign': 'center'};
|
||||
let LIGHT = ThemeTypes.LIGHT;
|
||||
object11.backgroundColor = a0 === LIGHT ? (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW : (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object11.paddingVertical = PX_8;
|
||||
object3.text = object11;
|
||||
const object12 = {};
|
||||
LIGHT = ThemeTypes.LIGHT;
|
||||
object12.backgroundColor = a0 === LIGHT ? (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW : (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object12.padding = PX_8;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object12.marginTop = PX_16;
|
||||
object12.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
object3.upsellContainer = object12;
|
||||
object3.upsellText = {textAlign: 'center'};
|
||||
const BACKGROUND_BRAND = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BRAND;
|
||||
object3.selected = {borderWidth: 1, borderColor: BACKGROUND_BRAND};
|
||||
object3.disabled = {opacity: 0.5};
|
||||
return object3;
|
||||
}
|
||||
|
||||
function EnhancedRoleColorsSelectStyleModal({guildId, role, roleStyle, onStyleChanged}) { // fn#123444, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:1409, offset: 0x0258d980, size: 819 bytes, params: 2, frame: 41
|
||||
var r8;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var object2;
|
||||
var upsellText;
|
||||
var format;
|
||||
var VpEDJc;
|
||||
var object3;
|
||||
var Text2;
|
||||
var object8;
|
||||
var items3;
|
||||
var value;
|
||||
const styles = useStyles((importDefault(4048) /* metro dependency 4048: useTheme */)());
|
||||
const value3 = (require(6630) /* metro dependency 6630: useHasEnhancedRoleColors */).useHasEnhancedRoleColorsForRole(guildId,
|
||||
role);
|
||||
const useGuildSettingsRoleExampleMessageModule = require(15966) /* metro dependency 15966: useGuildSettingsRoleExampleMessage */;
|
||||
const useGuildSettingsRoleExampleMessage = useGuildSettingsRoleExampleMessageModule.useGuildSettingsRoleExampleMessage;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const string = intl.string;
|
||||
const Mi9Kbe = (require(1244) /* metro dependency 1244: indexNative */).t.Mi9Kbe;
|
||||
const env0_4 = Reflect.apply(useGuildSettingsRoleExampleMessage, useGuildSettingsRoleExampleMessageModule,
|
||||
[Reflect.apply(string, intl, [Mi9Kbe])]);
|
||||
const value5 = new (importDefault(8177) /* metro dependency 8177: RowGenerator */)();
|
||||
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
const object4 = {};
|
||||
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
|
||||
object4.header = <BottomSheetTitleHeader title={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['9wVJRB'])} />;
|
||||
const view = <View style={styles.stylesContainer}>{STYLE_CONFIGS.map(_fun123445)}</View>;
|
||||
if (value3) {
|
||||
r8 = !value3;
|
||||
} else {
|
||||
var viewBinding2Props = {style: styles.upsellContainer};
|
||||
object2 = {};
|
||||
upsellText = styles.upsellText;
|
||||
object2.style = upsellText;
|
||||
object2.variant = 'text-sm/semibold';
|
||||
format = intl.format;
|
||||
VpEDJc = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).VpEDJc;
|
||||
object3 = {};
|
||||
Text2 = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var text2Props = {gradientColors: [HOLOGRAPHIC_ROLE_COLORS.primary_color,
|
||||
HOLOGRAPHIC_ROLE_COLORS.secondary_color,
|
||||
HOLOGRAPHIC_ROLE_COLORS.tertiary_color], variant: 'text-sm/semibold'};
|
||||
value = require(4020) /* metro dependency 4020: FabricUtils */;
|
||||
text2Props.experimental_useNativeText = !value.isFabric();
|
||||
object3.magical = <Text2 {...text2Props}>{(require(1244) /* metro dependency 1244: indexNative */).intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['+/IHLl'])}</Text2>;
|
||||
value = <Text {...object2}>{Reflect.apply(format, intl, [VpEDJc, object3])}</Text>;
|
||||
items3 = [value];
|
||||
upsellText = styles.upsellText;
|
||||
items3[1] = <Text style={upsellText} variant="text-sm/normal">{intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).FJZeZF)}</Text>;
|
||||
value = <View {...viewBinding2Props}>{items3}</View>;
|
||||
r8 = value;
|
||||
}
|
||||
return (
|
||||
<BottomSheet {...object4}>
|
||||
<View style={styles.container}>
|
||||
{view}
|
||||
{r8}
|
||||
</View>
|
||||
</BottomSheet>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun123445(a0) { // fn#123445, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:1886, offset: 0x0258dcb3, size: 334 bytes, params: 2, frame: 24
|
||||
const env0_0 = a0;
|
||||
const r1 = !env0_3 && a0.id !== RoleColorsStyle.SOLID;
|
||||
const pressableProps = {style: [styles.button, roleStyle === a0.id && styles.selected, r1 && styles.disabled],
|
||||
disabled: r1, onPress: onPress_123446};
|
||||
const ChatItem = importDefault(9773) /* metro dependency 9773: ChatItem */;
|
||||
stylesBinding = styles;
|
||||
const chatItem = <ChatItem style={stylesBinding.message} message={env0_4} rowGenerator={env0_5} modifyRow={modifyRow} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const text = stylesBinding.text;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
return (
|
||||
<Pressable {...pressableProps} key={a0.id}>
|
||||
{chatItem}
|
||||
<Text style={text} variant="text-sm/normal">
|
||||
{intl.string(a0.labelString)}
|
||||
</Text>
|
||||
</Pressable>
|
||||
);
|
||||
}
|
||||
|
||||
function onPress_123446() { // fn#123446, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:1998, offset: 0x0258de01, size: 61 bytes, params: 1, frame: 12
|
||||
let value = environment.__proto__;
|
||||
onStyleChanged(env0_0.id);
|
||||
value = environment.__proto__.__proto__;
|
||||
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
|
||||
}
|
||||
|
||||
function modifyRow(a0) { // fn#123447, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16173:2112, offset: 0x0258de3e, size: 138 bytes, params: 2, frame: 16
|
||||
const enhancedRoleColorUtilsModule = require(1941) /* metro dependency 1941: EnhancedRoleColorUtils */;
|
||||
const value3 = enhancedRoleColorUtilsModule.extractColorStringsFromServerColors(env0_0.colors);
|
||||
a0.message.roleColor = undefined;
|
||||
a0.message.roleColors = (require(8206) /* metro dependency 8206: EnhancedRoleColorUtils */).processColorStrings(value3);
|
||||
a0.message.shouldShowRoleOnName = true;
|
||||
a0.message.avatarURL = importDefault(15967) /* metro dependency 15967: wumpusAvatarPng */;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
/* Metro module 14680; source: modules/premium/powerups/native/GuildPowerupsBoostButton.tsx; dependencies: [31, 1867, 1878, 7020, 661, 33, 566, 5180, 1895, 6522, 7019, 2] */
|
||||
function _fun110794(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110794, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14877:6, offset: 0x023874ff, size: 212 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
const guildBoostSlotStore = importDefault(7020) /* metro dependency 7020: GuildBoostSlotStore */;
|
||||
const env0_7 = (require(661) /* metro dependency 661: Constants */).AnalyticsSections;
|
||||
const env0_8 = (require(33) /* metro dependency 33 */).jsx;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsBoostButton.tsx');
|
||||
exports.GuildPowerupsBoostButton = GuildPowerupsBoostButton;
|
||||
}
|
||||
|
||||
function GuildPowerupsBoostButton({guildId}) { // fn#110795, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14877:300, offset: 0x023875d3, size: 367 bytes, params: 2, frame: 21
|
||||
const guild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], function() {
|
||||
return GuildStore.getGuild(guildId);
|
||||
});
|
||||
const boostSlots = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildBoostSlotStore],
|
||||
function() {
|
||||
return GuildBoostSlotStore.boostSlots;
|
||||
});
|
||||
const value2 = (importDefault(5180) /* metro dependency 5180: useFractionalPremiumInfo */)({forceFetch: true});
|
||||
const currentUser = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
|
||||
return UserStore.getCurrentUser();
|
||||
});
|
||||
const r5 = currentUser != null ? currentUser.premiumGroupRole : (require(1895) /* metro dependency 1895: user */).PremiumSubscriptionGroupRole.UNSPECIFIED;
|
||||
const binding = env0_3;
|
||||
const useMemo = binding.useMemo;
|
||||
return guild == null ? null : ((Component) => <Component guild={guild} previousGuildSubscriptionSlot={Reflect.apply(useMemo,
|
||||
binding, [_fun110799,
|
||||
[boostSlots]])} analyticsSection={AnalyticsSections.GUILD_POWERUPS_OVERVIEW_SIDEBAR} fractionalPremiumState={value2.fractionalState} onAvailableSlotPress={binding.useCallback(_fun110801,
|
||||
[])} premiumGroupRole={r5} />)(importDefault(7019) /* metro dependency 7019: GuildBoostingSubscribeButton */);
|
||||
}
|
||||
|
||||
function _fun110799() { // fn#110799, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14877:635, offset: 0x02387751, size: 47 bytes, params: 1, frame: 11
|
||||
const Object = global.Object;
|
||||
return Object.values(boostSlots).find(function(a0) {
|
||||
return a0.isAvailable();
|
||||
});
|
||||
}
|
||||
|
||||
function _fun110801(a0, a1) { // fn#110801, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14877:706, offset: 0x02387780, size: 71 bytes, params: 3, frame: 13
|
||||
var value;
|
||||
if (a1 != null) {
|
||||
value = environment.__proto__;
|
||||
value = require(6522) /* metro dependency 6522: BoostingActionCreators */;
|
||||
value.openTransferModal({guildBoostSlots: [a1], guildId: a0});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
/* Metro module 14641; source: modules/premium/powerups/native/GuildPowerupsBoostGem.tsx; dependencies: [27, 33, 4501, 697, 14642, 2] */
|
||||
function _fun110639(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110639, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14838:6, offset: 0x02380e2b, size: 241 bytes, params: 8, frame: 22
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = (require(27) /* metro dependency 27 */).View;
|
||||
const env0_3 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const object = {'width': 100, 'height': 100, 'borderRadius': null, 'backgroundColor': null, 'alignItems': 'center',
|
||||
'justifyContent': 'center', 'alignSelf': 'center'};
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
const BACKGROUND_SECONDARY_ALT = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SECONDARY_ALT;
|
||||
object.backgroundColor = BACKGROUND_SECONDARY_ALT;
|
||||
const env0_4 = Reflect.apply(createStyles, createStylesModule, [{boostGemContainer: object}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsBoostGem.tsx');
|
||||
exports.default = GuildPowerupsBoostGem;
|
||||
}
|
||||
|
||||
function GuildPowerupsBoostGem({style, gemWidth, gemHeight}) { // fn#110640, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14838:445, offset: 0x02380f1c, size: 113 bytes, params: 2, frame: 19
|
||||
const styles = useStyles();
|
||||
return (
|
||||
<View style={[styles.boostGemContainer, style]}>
|
||||
{((Component) => <Component width={gemWidth} height={gemHeight} />)(importDefault(14642) /* metro dependency 14642: BoostGem */)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,60 @@
|
||||
/* Metro module 14620; source: modules/premium/powerups/native/GuildPowerupsBoostInfo.tsx; dependencies: [27, 8259, 33, 4501, 697, 14621, 7958, 4573, 2] */
|
||||
function _fun110544(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110544, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14817:6, offset: 0x0237c878, size: 268 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const env0_4 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).BoostInfoType;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_5 = value.jsx;
|
||||
const env0_6 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
const env0_7 = Reflect.apply(createStyles, value, [{container: {'flex': 1, 'alignItems': 'center',
|
||||
'justifyContent': 'center', paddingVertical: PX_12}, headerContainer: {'flexDirection': 'row',
|
||||
'alignItems': 'center', 'justifyContent': 'center', 'display': 'flex'}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsBoostInfo.tsx');
|
||||
exports.default = GuildPowerupsBoostInfo;
|
||||
}
|
||||
|
||||
function GuildPowerupsBoostInfo({count, type}) { // fn#110545, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14817:486, offset: 0x0237c984, size: 444 bytes, params: 2, frame: 26
|
||||
const styles = useStyles();
|
||||
const guildPowerupsBoostInfoText = (require(14621) /* metro dependency 14621: getGuildPowerupsBoostInfoText */).getGuildPowerupsBoostInfoText(count,
|
||||
type);
|
||||
const BoostGemIcon = (require(7958) /* metro dependency 7958: BoostGemIcon */).BoostGemIcon;
|
||||
let AVAILABLE = BoostInfoType.AVAILABLE;
|
||||
const boostGemIcon = <BoostGemIcon size="sm" color={type === AVAILABLE ? (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GUILD_BOOSTING_PINK : (importDefault(697) /* metro dependency 697: native */).colors.TEXT_MUTED} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
AVAILABLE = BoostInfoType.AVAILABLE;
|
||||
return (
|
||||
<View
|
||||
style={styles.container}
|
||||
accessible
|
||||
accessibilityLabel={'' + count + ', ' + guildPowerupsBoostInfoText}
|
||||
>
|
||||
<View
|
||||
style={styles.headerContainer}
|
||||
importantForAccessibility="no-hide-descendants"
|
||||
accessible={false}
|
||||
>
|
||||
{boostGemIcon}
|
||||
<Text
|
||||
variant="text-lg/medium"
|
||||
color={type !== AVAILABLE ? 'text-subtle' : 'text-strong'}
|
||||
importantForAccessibility="no-hide-descendants"
|
||||
>
|
||||
{count}
|
||||
</Text>
|
||||
</View>
|
||||
<Text
|
||||
variant="text-md/normal"
|
||||
color="text-subtle"
|
||||
importantForAccessibility="no-hide-descendants"
|
||||
>
|
||||
{guildPowerupsBoostInfoText}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,246 @@
|
||||
/* Metro module 14639; source: modules/premium/powerups/native/GuildPowerupsBottomSheet.tsx; dependencies: [27, 4502, 8260, 8259, 33, 4501, 697, 14635, 14636, 14640, 566, 14641, 3868, 14643, 4573, 14644, 14647, 14634, 4068, 1244, 2256, 12310, 14648, 14649, 14650, 14653, 14658, 14659, 4578, 6275, 2] */
|
||||
function _fun110626(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110626, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:6, offset: 0x023800c9, size: 763 bytes, params: 8, frame: 23
|
||||
var object3;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const env0_5 = (require(8260) /* metro dependency 8260: GameServerConstants */).GAME_SERVER_POWERUP_SKU_ID;
|
||||
let value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_6 = value.GuildPowerupType;
|
||||
const env0_7 = value.GUILD_POWERUP_CONFIGURABLE_SKUS_DESKTOP;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_8 = value.jsx;
|
||||
const env0_9 = value.jsxs;
|
||||
const env0_10 = value.Fragment;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object3 = {};
|
||||
const object4 = {};
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object4.padding = PX_16;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object4.gap = PX_16;
|
||||
object3.container = object4;
|
||||
let PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object3.headerContainer = {marginTop: PX_24, alignItems: 'center'};
|
||||
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.statusContainer = {justifyContent: 'center', gap: PX_8};
|
||||
const object6 = {flexDirection: 'column'};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object6.gap = PX_8;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object6.marginTop = PX_16;
|
||||
object3.levelContainer = object6;
|
||||
object3.perkContainer = {'flexDirection': 'row', 'alignItems': 'center', 'justifyContent': 'space-between'};
|
||||
object3.perkIcon = {'width': 20, 'height': 20};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.perkText = {marginStart: PX_8};
|
||||
const object8 = {};
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object8.gap = PX_12;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object8.marginTop = PX_8;
|
||||
object3.footerContainer = object8;
|
||||
object3.image = {'width': '100%', 'height': 160};
|
||||
PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object3.description = {marginHorizontal: PX_24, textAlign: 'center'};
|
||||
const object10 = {'flexDirection': 'row', 'alignItems': 'center', 'justifyContent': 'center'};
|
||||
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object10.gap = PX_4;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object10.marginTop = PX_8;
|
||||
object3.cooldownInfo = object10;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object3.gemContainer = {marginTop: PX_16};
|
||||
const env0_11 = Reflect.apply(createStyles, value, [object3]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsBottomSheet.tsx');
|
||||
exports.default = GuildPowerupsBottomSheet;
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheetHeader({guildId, powerup}) { // fn#110627, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:1097, offset: 0x023803c4, size: 611 bytes, params: 2, frame: 29
|
||||
const styles = useStyles();
|
||||
const value4 = (require(14636) /* metro dependency 14636: useCalculatePowerupCardStatus */).useCalculatePowerupCardStatus(powerup,
|
||||
(importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(guildId, powerup), false);
|
||||
const r8 = (importDefault(14640) /* metro dependency 14640: useGetGuildPowerupBannerImage */)(powerup, true) ?? '';
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
let skuId = powerup.skuId;
|
||||
const r14 = skuId !== GAME_SERVER_POWERUP_SKU_ID ? undefined : '+';
|
||||
skuId = powerup.skuId;
|
||||
const type = powerup.type;
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
const r5 = type === LEVEL ? ((Component) => <Component style={styles.gemContainer} />)(importDefault(14641) /* metro dependency 14641: GuildPowerupsBoostGem */) : skuId === GAME_SERVER_POWERUP_SKU_ID ? <View style={styles.image}>{((GameServerHostingRive) => <GameServerHostingRive stateMachine="SM_Auto" dataBinding={{reducedMotion: useReducedMotion}} />)((require(3868) /* metro dependency 3868: native */).GameServerHostingRive)}</View> : ((Component) => <Component imageUrl={r8} style={styles.image} isAnimated />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */);
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const text = <Text variant="heading-xl/bold" accessibilityRole="header">{powerup.title}</Text>;
|
||||
const GuildPowerupsCardFooter = (require(14644) /* metro dependency 14644: GuildPowerupsCardFooter */).GuildPowerupsCardFooter;
|
||||
return (
|
||||
<View>
|
||||
{r5}
|
||||
<View style={styles.headerContainer}>
|
||||
{text}
|
||||
<GuildPowerupsCardFooter
|
||||
cost={powerup.cost}
|
||||
costDecorator={r14}
|
||||
status={value4}
|
||||
style={styles.statusContainer}
|
||||
/>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheetLevelBody({powerup}) { // fn#110629, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:1846, offset: 0x02380627, size: 102 bytes, params: 2, frame: 17
|
||||
const styles = useStyles();
|
||||
return (
|
||||
<View style={styles.levelContainer}>
|
||||
{(importDefault(14647) /* metro dependency 14647: useGuildPowerupLevelPerks */)(powerup).map(_fun110630)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheetBody({powerup}) { // fn#110631, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:2213, offset: 0x02380763, size: 434 bytes, params: 2, frame: 28
|
||||
var r5;
|
||||
var jsxRuntimeEnv0_10Binding;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var object;
|
||||
var description;
|
||||
var items3;
|
||||
var items2;
|
||||
var intl;
|
||||
const styles = useStyles();
|
||||
const type = powerup.type;
|
||||
const PERK = GuildPowerupType.PERK;
|
||||
if (PERK === type) {
|
||||
jsxRuntimeEnv0_10Binding = jsxRuntimeEnv0_10;
|
||||
object = {};
|
||||
description = styles.description;
|
||||
object.style = description;
|
||||
object.variant = 'text-md/medium';
|
||||
description = powerup.description;
|
||||
items3 = [<Text {...object}>{description}</Text>];
|
||||
r5 = powerup.deactivationCooldownPeriodDays != null && powerup.deactivationCooldownPeriodDays > 0;
|
||||
if (r5) {
|
||||
var viewBindingProps = {style: styles.cooldownInfo};
|
||||
items2 = [((CircleInformationIcon) => <CircleInformationIcon size="xs" color={(importDefault(697) /* metro dependency 697: native */).colors.TEXT_MUTED} />)((require(4068) /* metro dependency 4068: CircleInformationIcon */).CircleInformationIcon)];
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
items2[1] = <Text variant="text-sm/medium" color="text-muted">{intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).GMhQcE,
|
||||
|
||||
|
||||
{cooldownDays: powerup.deactivationCooldownPeriodDays})}</Text>;
|
||||
r5 = <View {...viewBindingProps}>{items2}</View>;
|
||||
}
|
||||
items3[1] = r5;
|
||||
return (
|
||||
<>
|
||||
{items3}
|
||||
</>
|
||||
);
|
||||
}
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
if (LEVEL === type) {
|
||||
return <GuildPowerupsBottomSheetLevelBody powerup={powerup} />;
|
||||
}
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheetFooter({guildId, powerup}) { // fn#110632, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:2847, offset: 0x02380915, size: 779 bytes, params: 2, frame: 33
|
||||
var r8;
|
||||
var r5;
|
||||
var value7;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var string;
|
||||
var items2;
|
||||
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
const value2 = (importDefault(12310) /* metro dependency 12310: useHasAllocateBoostPermission */)(guildId);
|
||||
const {showToggleButton, showConfigureButton,
|
||||
isPowerupActive} = (importDefault(14648) /* metro dependency 14648: useGuildPowerupCardFooterConfig */)(guildId,
|
||||
powerup);
|
||||
const {disabled, reason} = (importDefault(14649) /* metro dependency 14649: useCanGuildPowerupBeToggled */)(guildId,
|
||||
powerup, isPowerupActive);
|
||||
const value5 = (importDefault(14650) /* metro dependency 14650: useGuildPowerupOnActivate */)(guildId, powerup);
|
||||
const env0_1 = value5.onActivate;
|
||||
const isLoading = value5.isLoading;
|
||||
const env0_2 = (importDefault(14653) /* metro dependency 14653: useGuildPowerupOnShowDeactivate */)(guildId,
|
||||
powerup);
|
||||
if (value2) {
|
||||
value7 = GUILD_POWERUP_CONFIGURABLE_SKUS_DESKTOP.has(powerup.skuId);
|
||||
r8 = !showConfigureButton && isPowerupActive;
|
||||
r8 = r8 && powerup.type === GuildPowerupType.PERK;
|
||||
r8 = r8 && value7;
|
||||
r8 = !r8 ? powerup.skuId === GAME_SERVER_POWERUP_SKU_ID : r8;
|
||||
var viewBindingProps = {style: styles.footerContainer};
|
||||
r8 = r8 && ((Text) => <Text style={styles.description} variant="text-md/bold">{intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['jo5++h'])}</Text>)((require(4573) /* metro dependency 4573: Text */).Text);
|
||||
items2 = [r8];
|
||||
r8 = disabled && ((Component) => <Component text={reason ?? ''} />)(importDefault(14659) /* metro dependency 14659: GuildPowerupsDisabledWarning */);
|
||||
items2[1] = r8;
|
||||
items2[2] = showConfigureButton && <Button variant="primary" text={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).g5Ds69)} onPress={(importDefault(14658) /* metro dependency 14658: useGuildPowerupConfigureCallback */)(guildId,
|
||||
|
||||
powerup)} />;
|
||||
r5 = showToggleButton && powerup.skuId !== GAME_SERVER_POWERUP_SKU_ID;
|
||||
if (r5) {
|
||||
var buttonProps = {variant: isPowerupActive ? 'secondary' : 'primary'};
|
||||
string = intl.string;
|
||||
value = importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */;
|
||||
buttonProps.text = isPowerupActive ? Reflect.apply(string, intl, [value.TZsu1U]) : Reflect.apply(string,
|
||||
intl,
|
||||
[value.gSxlHf]);
|
||||
buttonProps.loading = isLoading;
|
||||
buttonProps.disabled = disabled;
|
||||
buttonProps.onPress = onPress_110633;
|
||||
value = <Button {...buttonProps} />;
|
||||
r5 = value;
|
||||
}
|
||||
items2[3] = r5;
|
||||
return (
|
||||
<View {...viewBindingProps}>
|
||||
{items2}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheet({guildId, powerup}) { // fn#110634, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:3828, offset: 0x02380c58, size: 198 bytes, params: 2, frame: 24
|
||||
const styles = useStyles();
|
||||
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
return (
|
||||
<BottomSheet startExpanded>
|
||||
<View style={styles.container}>
|
||||
<GuildPowerupsBottomSheetHeader guildId={guildId} powerup={powerup} />
|
||||
<GuildPowerupsBottomSheetBody guildId={guildId} powerup={powerup} />
|
||||
<GuildPowerupsBottomSheetFooter guildId={guildId} powerup={powerup} />
|
||||
</View>
|
||||
</BottomSheet>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110630(a0, a1) { // fn#110630, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:1977, offset: 0x0238068d, size: 214 bytes, params: 3, frame: 22
|
||||
const iconForPerk = (require(14634) /* metro dependency 14634: GuildBoostingMarketingUtils */).getIconForPerk(a0.perkIcon);
|
||||
const stylesBinding = styles;
|
||||
const perkContainer = stylesBinding.perkContainer;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={perkContainer} key={'perk-' + a1 + '-' + a0.perkIcon}>
|
||||
<Text style={stylesBinding.perkText} variant="text-md/medium">
|
||||
{a0.description}
|
||||
</Text>
|
||||
{((Component) => <Component style={stylesBinding.perkIcon} />)(iconForPerk)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsBottomSheetFooterOnPress() { // fn#110633, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14836:3684, owner: GuildPowerupsBottomSheetFooter.onPress, offset: 0x02380c20, size: 56 bytes, params: 1, frame: 10
|
||||
if (isPowerupActive) {
|
||||
if (env0_2 != null) {
|
||||
env0_2();
|
||||
}
|
||||
} else if (onActivate != null) {
|
||||
onActivate();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,65 @@
|
||||
/* Metro module 14660; source: modules/premium/powerups/native/GuildPowerupsCard.tsx; dependencies: [31, 27, 33, 4501, 697, 674, 6239, 2] */
|
||||
function _fun110719(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110719, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14857:6, offset: 0x02383e17, size: 500 bytes, params: 8, frame: 25
|
||||
var object6;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
importAll(31) /* metro dependency 31 */;
|
||||
const env0_2 = (require(27) /* metro dependency 27 */).View;
|
||||
const env0_3 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
object6 = {};
|
||||
const object7 = {};
|
||||
object7.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
|
||||
const BACKGROUND_MOD_MUTED = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_MUTED;
|
||||
object7.borderColor = BACKGROUND_MOD_MUTED;
|
||||
object7.borderWidth = 1;
|
||||
object7.borderStyle = 'solid';
|
||||
const SHADOW_LOW = (importDefault(697) /* metro dependency 697: native */).shadows.SHADOW_LOW;
|
||||
copyDataProperties(object7, SHADOW_LOW, undefined);
|
||||
object6.cardNormal = object7;
|
||||
const object8 = {};
|
||||
const value2 = importDefault(674) /* metro dependency 674 */;
|
||||
const GREEN_360 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GREEN_360;
|
||||
object8.borderColor = value2(GREEN_360).alpha(0.35).hex();
|
||||
object6.cardActive = object8;
|
||||
const object9 = {};
|
||||
const value5 = value2;
|
||||
let YELLOW_300 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.YELLOW_300;
|
||||
object9.borderColor = value5(YELLOW_300).alpha(0.35).hex();
|
||||
object6.cardExpiring = object9;
|
||||
const object10 = {};
|
||||
const value8 = value2;
|
||||
YELLOW_300 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.YELLOW_300;
|
||||
object10.borderColor = value8(YELLOW_300).alpha(0.35).hex();
|
||||
object6.cardRemoving = object10;
|
||||
const env0_4 = Reflect.apply(createStyles, createStylesModule, [object6]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsCard.tsx');
|
||||
exports.default = GuildPowerupsCard;
|
||||
}
|
||||
|
||||
function GuildPowerupsCard(a0) { // fn#110720, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14857:675, offset: 0x0238400b, size: 284 bytes, params: 2, frame: 24
|
||||
const children = a0.children;
|
||||
const containerStyle = a0.containerStyle;
|
||||
const status = a0.status;
|
||||
const object2 = {'children': 0, 'containerStyle': 0, 'status': 0};
|
||||
silentSetPrototypeOf(object2, null, undefined);
|
||||
const value = copyDataProperties({}, a0, object2, undefined);
|
||||
const value3 = undefined;
|
||||
const styles = useStyles();
|
||||
const items2 = [styles.cardNormal];
|
||||
items2[1] = (status == null ? value3 : status.type) === 'active' && styles.cardActive;
|
||||
items2[2] = (status == null ? value3 : status.type) === 'expiring' && styles.cardExpiring;
|
||||
items2[3] = (status == null ? value3 : status.type) === 'removing' && styles.cardRemoving;
|
||||
items2[4] = containerStyle;
|
||||
const Card = (require(6239) /* metro dependency 6239: CardNative */).Card;
|
||||
return (
|
||||
<View style={items2}>
|
||||
<Card border="none" {...value}>
|
||||
{children}
|
||||
</Card>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,130 @@
|
||||
/* Metro module 14644; source: modules/premium/powerups/native/GuildPowerupsCardFooter.tsx; dependencies: [27, 33, 4501, 4073, 697, 4573, 7684, 1244, 2256, 14645, 14646, 7958, 2] */
|
||||
function _fun110646(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110646, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:6, offset: 0x02381333, size: 307 bytes, params: 8, frame: 25
|
||||
const env0_0 = require;
|
||||
const closure = GuildPowerupCardFooterActive;
|
||||
const closure2 = GuildPowerupCardFooterExpiring;
|
||||
const closure3 = GuildPowerupCardFooterRemoving;
|
||||
const closure4 = GuildPowerupCardFooterStatus;
|
||||
const closure5 = GuildPowerupCardFooterCost;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const value = require(33) /* metro dependency 33 */;
|
||||
const env0_4 = value.jsx;
|
||||
const env0_5 = value.jsxs;
|
||||
const env0_6 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({container: {justifyContent: 'space-between'},
|
||||
inline: {'flexDirection': 'row', 'alignItems': 'center', 'gap': 2}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsCardFooter.tsx');
|
||||
exports.GuildPowerupCardFooterActive = closure;
|
||||
exports.GuildPowerupCardFooterExpiring = closure2;
|
||||
exports.GuildPowerupCardFooterRemoving = closure3;
|
||||
exports.GuildPowerupCardFooterStatus = closure4;
|
||||
exports.GuildPowerupCardFooterCost = closure5;
|
||||
exports.GuildPowerupsCardFooter = GuildPowerupsCardFooter;
|
||||
}
|
||||
|
||||
function GuildPowerupCardFooterActive({text}) { // fn#110647, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:262, offset: 0x02381466, size: 187 bytes, params: 2, frame: 22
|
||||
const styles = useStyles();
|
||||
const CircleCheckIcon = (require(4073) /* metro dependency 4073: CircleCheckIcon */).CircleCheckIcon;
|
||||
const STATUS_POSITIVE = (importDefault(697) /* metro dependency 697: native */).colors.STATUS_POSITIVE;
|
||||
const circleCheckIcon = <CircleCheckIcon size="xs" color={STATUS_POSITIVE} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={styles.inline}>
|
||||
{circleCheckIcon}
|
||||
<Text color="status-positive" variant="text-sm/bold">
|
||||
{text}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupCardFooterExpiring({dateString}) { // fn#110648, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:512, offset: 0x02381521, size: 261 bytes, params: 2, frame: 25
|
||||
const styles = useStyles();
|
||||
const CircleErrorIcon = (require(7684) /* metro dependency 7684: CircleErrorIcon */).CircleErrorIcon;
|
||||
const STATUS_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.STATUS_WARNING;
|
||||
const circleErrorIcon = <CircleErrorIcon size="xs" color={STATUS_WARNING} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
return (
|
||||
<View style={styles.inline}>
|
||||
{circleErrorIcon}
|
||||
<Text color="status-warning" variant="text-sm/bold">
|
||||
{intl.formatToMarkdownString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['ol/ao/'],
|
||||
{dateString: (importDefault(14645) /* metro dependency 14645: entitlementExpirationDateToString */)(dateString)})}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupCardFooterRemoving({removingAt}) { // fn#110649, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:845, offset: 0x02381626, size: 260 bytes, params: 2, frame: 25
|
||||
const styles = useStyles();
|
||||
const CircleErrorIcon = (require(7684) /* metro dependency 7684: CircleErrorIcon */).CircleErrorIcon;
|
||||
const STATUS_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.STATUS_WARNING;
|
||||
const circleErrorIcon = <CircleErrorIcon size="xs" color={STATUS_WARNING} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
return (
|
||||
<View style={styles.inline}>
|
||||
{circleErrorIcon}
|
||||
<Text color="status-warning" variant="text-sm/bold">
|
||||
{intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['6e2ry1'],
|
||||
{dateString: (importDefault(14646) /* metro dependency 14646: getGuildPowerupFormattedDateString */)(removingAt)})}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupCardFooterStatus({status}) { // fn#110650, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:1176, offset: 0x0238172a, size: 157 bytes, params: 2, frame: 15
|
||||
if (status == null) {
|
||||
return null;
|
||||
}
|
||||
const type = status.type;
|
||||
if (type === 'expiring') {
|
||||
return <GuildPowerupCardFooterExpiring dateString={status.expiringAt} />;
|
||||
}
|
||||
if (type === 'removing') {
|
||||
return <GuildPowerupCardFooterRemoving removingAt={status.removingAt} />;
|
||||
}
|
||||
if (type === 'active') {
|
||||
return <GuildPowerupCardFooterActive text={status.statusText} />;
|
||||
}
|
||||
}
|
||||
|
||||
function GuildPowerupCardFooterCost({cost, costDecorator}) { // fn#110651, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:1501, offset: 0x023817c7, size: 282 bytes, params: 2, frame: 26
|
||||
var r0;
|
||||
var items2;
|
||||
var Text;
|
||||
var intl;
|
||||
var formatToPlainString;
|
||||
var t2Wbo1;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
if (cost == null) {
|
||||
r0 = null;
|
||||
} else {
|
||||
var viewBindingProps = {style: styles.inline};
|
||||
items2 = [((BoostGemIcon) => <BoostGemIcon size="sm" color={(importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GUILD_BOOSTING_PINK} />)((require(7958) /* metro dependency 7958: BoostGemIcon */).BoostGemIcon)];
|
||||
Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
t2Wbo1 = (require(1244) /* metro dependency 1244: indexNative */).t.t2Wbo1;
|
||||
value = '';
|
||||
items2[1] = <Text variant="heading-sm/semibold" color="text-subtle">{Reflect.apply(formatToPlainString, intl,
|
||||
[t2Wbo1, {required: cost, decorator: costDecorator ?? value}])}</Text>;
|
||||
value = <View {...viewBindingProps}>{items2}</View>;
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function GuildPowerupsCardFooter({cost, costDecorator, status, style}) { // fn#110652, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14841:2302, offset: 0x023818e1, size: 149 bytes, params: 2, frame: 21
|
||||
const styles = useStyles();
|
||||
return (
|
||||
<View style={[styles.inline, styles.container, style]}>
|
||||
<GuildPowerupCardFooterCost cost={cost} costDecorator={costDecorator} />
|
||||
<GuildPowerupCardFooterStatus status={status} />
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
/* Metro module 14597; source: modules/premium/powerups/native/GuildPowerupsChannelRow.tsx; dependencies: [31, 27, 10980, 33, 14598, 7684, 697, 1305, 4501, 14599, 6789, 14607, 14681, 11846, 1244, 2256, 14687, 2] */
|
||||
function _fun110373(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110373, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14794:6, offset: 0x02376f0a, size: 263 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 CHANNEL_MARGIN_VERTICAL = (require(10980) /* metro dependency 10980: RedesignChannelListConstants */).CHANNEL_MARGIN_VERTICAL;
|
||||
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const object = {marginVertical: CHANNEL_MARGIN_VERTICAL, marginHorizontal: 8};
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
|
||||
const env0_6 = Reflect.apply(createStyles, createStylesModule, [{container: object}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsChannelRow.tsx');
|
||||
exports.default = GuildPowerupsChannelRow;
|
||||
}
|
||||
|
||||
function GuildPowerupsChannelRowIndicator({indicator}) { // fn#110374, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14794:169, offset: 0x02377011, size: 236 bytes, params: 2, frame: 17
|
||||
if (indicator != null) {
|
||||
var type = indicator.type;
|
||||
var GuildPowerupNotificationIndicatorType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationIndicatorType;
|
||||
var WARNING = GuildPowerupNotificationIndicatorType.WARNING;
|
||||
if (WARNING === type) {
|
||||
const CircleErrorIcon = (require(7684) /* metro dependency 7684: CircleErrorIcon */).CircleErrorIcon;
|
||||
return (
|
||||
<CircleErrorIcon color={(importDefault(697) /* metro dependency 697: native */).colors.STATUS_WARNING} size="sm" />
|
||||
);
|
||||
}
|
||||
GuildPowerupNotificationIndicatorType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationIndicatorType;
|
||||
var UNREAD = GuildPowerupNotificationIndicatorType.UNREAD;
|
||||
if (UNREAD === type) {
|
||||
const Badge = (require(1305) /* metro dependency 1305: native */).Badge;
|
||||
return <Badge value={indicator.count} isMentionLowImportance />;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function GuildPowerupsChannelRow({guildId}) { // fn#110375, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14794:762, offset: 0x023770fd, size: 564 bytes, params: 2, frame: 31
|
||||
const styles = useStyles();
|
||||
const binding = env0_3;
|
||||
const value3 = binding.useRef(null);
|
||||
const value4 = binding.useCallback(_fun110376, [guildId]);
|
||||
const value5 = (importDefault(14607) /* metro dependency 14607: useGuildPowerupsNotifications */)(guildId);
|
||||
(importDefault(14681) /* metro dependency 14681: useGuildPowerupsCoachmark */)(value3, guildId, value5?.popout);
|
||||
const r13 = value5 == null ? (require(11846) /* metro dependency 11846: BaseChannelItem */).ChannelModes.DEFAULT : value5.showUnread ? (require(11846) /* metro dependency 11846: BaseChannelItem */).ChannelModes.UNREAD_IMPORTANT : (require(11846) /* metro dependency 11846: BaseChannelItem */).ChannelModes.DEFAULT;
|
||||
const BaseChannelItem = importDefault(11846) /* metro dependency 11846: BaseChannelItem */;
|
||||
const defaultImport2Props = {onPress: value4, style: styles.container, accessible: true, mode: r13,
|
||||
unread: value5?.showUnread};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
defaultImport2Props.accessibilityLabel = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).yv3DJJ);
|
||||
defaultImport2Props.accessibilityState = {selected: false};
|
||||
const BaseChannelName = (require(11846) /* metro dependency 11846: BaseChannelItem */).BaseChannelName;
|
||||
defaultImport2Props.name = <BaseChannelName name={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).yv3DJJ)} mode={r13} />;
|
||||
const BaseChannelIcon = (require(11846) /* metro dependency 11846: BaseChannelItem */).BaseChannelIcon;
|
||||
const BoostTier2Icon = (require(14687) /* metro dependency 14687: BoostTier2Icon */).BoostTier2Icon;
|
||||
defaultImport2Props.icon = <BaseChannelIcon mode={r13} IconComponent={BoostTier2Icon} />;
|
||||
defaultImport2Props.channelInfo = <GuildPowerupsChannelRowIndicator indicator={value5?.indicator} />;
|
||||
return (
|
||||
<View ref={value3} collapsable={false}>
|
||||
<BaseChannelItem {...defaultImport2Props} />
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110376() { // fn#110376, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14794:852, offset: 0x02377331, size: 68 bytes, params: 1, frame: 14
|
||||
let value = environment.__proto__;
|
||||
value = importDefault(14599) /* metro dependency 14599: openGuildPowerupsModal */;
|
||||
const object2 = {};
|
||||
object2.guildId = guildId;
|
||||
const GUILD_POWERUPS_CHANNEL_LIST_ROW = (importDefault(6789) /* metro dependency 6789: AnalyticsLocation */).GUILD_POWERUPS_CHANNEL_LIST_ROW;
|
||||
object2.analyticsLocation = GUILD_POWERUPS_CHANNEL_LIST_ROW;
|
||||
value(object2);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
/* Metro module 14654; source: modules/premium/powerups/native/GuildPowerupsDeactivateAlert.tsx; dependencies: [27, 33, 4501, 697, 14655, 14656, 14657, 4500, 7684, 1244, 2256, 4500, 4573, 2] */
|
||||
function _fun110697(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110697, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14851:6, offset: 0x02382e06, size: 300 bytes, params: 8, frame: 23
|
||||
var object3;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
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;
|
||||
object3 = {};
|
||||
const object4 = {'width': 64, 'height': 64, 'alignItems': 'center', 'justifyContent': 'center',
|
||||
'borderRadius': null, 'backgroundColor': null, 'alignSelf': 'center'};
|
||||
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
const BACKGROUND_MOD_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_SUBTLE;
|
||||
object4.backgroundColor = BACKGROUND_MOD_SUBTLE;
|
||||
object3.headerContainer = object4;
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object3.extraContentContainer = {paddingHorizontal: PX_12};
|
||||
object3.warningText = {textAlign: 'center'};
|
||||
const env0_6 = Reflect.apply(createStyles, value, [object3]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsDeactivateAlert.tsx');
|
||||
exports.default = GuildPowerupsDeactivateAlert;
|
||||
}
|
||||
|
||||
function GuildPowerupsDeactivateAlert({guildId, powerup}) { // fn#110698, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14851:554, offset: 0x02382f32, size: 914 bytes, params: 2, frame: 35
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const styles = useStyles();
|
||||
const value2 = (importDefault(14655) /* metro dependency 14655: useGuildPowerupOnDeactivate */)(guildId, powerup);
|
||||
const env0_0 = value2.onDeactivate;
|
||||
const error = value2.error;
|
||||
const {warningText,
|
||||
vanityUrlWarning} = (importDefault(14656) /* metro dependency 14656: useDeactivateWarningText */)(guildId,
|
||||
powerup);
|
||||
const guildPowerupAnalyticsModule = require(14657) /* metro dependency 14657: GuildPowerupAnalytics */;
|
||||
const useLogPowerupModalOpened = guildPowerupAnalyticsModule.useLogPowerupModalOpened;
|
||||
const ModalType = guildPowerupAnalyticsModule.ModalType;
|
||||
const DEACTIVATE = ModalType.DEACTIVATE;
|
||||
Reflect.apply(useLogPowerupModalOpened, guildPowerupAnalyticsModule, [guildId, powerup, DEACTIVATE]);
|
||||
const AlertModal = (require(4500) /* metro dependency 4500: AlertModalNative */).AlertModal;
|
||||
const object2 = {};
|
||||
const CircleErrorIcon = (require(7684) /* metro dependency 7684: CircleErrorIcon */).CircleErrorIcon;
|
||||
const INTERACTIVE_ICON_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_ICON_DEFAULT;
|
||||
object2.header = <View style={styles.headerContainer}><CircleErrorIcon color={INTERACTIVE_ICON_DEFAULT} size="custom" style={{'width': 40,
|
||||
'height': 40}} /></View>;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object2.title = intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).iEBw1M,
|
||||
{perk: powerup.title});
|
||||
object2.content = intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['7o0K+2'],
|
||||
{perk: powerup.title});
|
||||
const AlertActions = (require(4500) /* metro dependency 4500: AlertModalNative */).AlertActions;
|
||||
const items2 = [error != null && <Text style={styles.warningText} variant="text-xs/semibold" color="text-feedback-critical">{error}</Text>];
|
||||
const AlertActionButton = (require(4500) /* metro dependency 4500: AlertModalNative */).AlertActionButton;
|
||||
const string = intl.string;
|
||||
const PYPdl4 = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).PYPdl4;
|
||||
items2[1] = <AlertActionButton variant="destructive" onPress={function(a0) {
|
||||
a0.stopPropagation();
|
||||
return onDeactivate();
|
||||
}} text={Reflect.apply(string, intl, [PYPdl4])} key="deactivate" />;
|
||||
items2[2] = <AlertActionButton onPress={function() {
|
||||
}} variant="secondary" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['ETE/oC'])} key="cancel" />;
|
||||
object2.actions = <AlertActions>{items2}</AlertActions>;
|
||||
object2.extraContent = <View style={styles.extraContentContainer}><Text variant="text-sm/medium" style={styles.warningText}>{warningText}</Text>{vanityUrlWarning != null && <Text style={styles.warningText} variant="text-sm/semibold" color="text-feedback-critical">{vanityUrlWarning}</Text>}</View>;
|
||||
return <AlertModal {...object2} />;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
/* Metro module 14659; source: modules/premium/powerups/native/GuildPowerupsDisabledWarning.tsx; dependencies: [27, 33, 4501, 697, 8129, 4573, 2] */
|
||||
function _fun110717(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110717, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14856:6, offset: 0x02383c07, size: 335 bytes, params: 8, frame: 23
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
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 = {'flexDirection': 'row', 'alignItems': 'center', 'gap': null, 'borderColor': null, 'borderWidth': 1};
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object.gap = PX_8;
|
||||
const STATUS_WARNING_BACKGROUND = (importDefault(697) /* metro dependency 697: native */).colors.STATUS_WARNING_BACKGROUND;
|
||||
object.borderColor = STATUS_WARNING_BACKGROUND;
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object.padding = PX_12;
|
||||
const BACKGROUND_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_FEEDBACK_WARNING;
|
||||
object.backgroundColor = BACKGROUND_FEEDBACK_WARNING;
|
||||
const env0_6 = Reflect.apply(createStyles, value, [{container: object, text: {flex: 1}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsDisabledWarning.tsx');
|
||||
exports.default = GuildPowerupsDisabledWarning;
|
||||
}
|
||||
|
||||
function GuildPowerupsDisabledWarning({text}) { // fn#110718, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14856:545, offset: 0x02383d56, size: 193 bytes, params: 2, frame: 22
|
||||
const styles = useStyles();
|
||||
const WarningIcon = (require(8129) /* metro dependency 8129: WarningIcon */).WarningIcon;
|
||||
const TEXT_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_FEEDBACK_WARNING;
|
||||
const warningIcon = <WarningIcon color={TEXT_FEEDBACK_WARNING} size="md" />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={styles.container}>
|
||||
{warningIcon}
|
||||
<Text
|
||||
style={styles.text}
|
||||
variant="text-md/semibold"
|
||||
color="text-feedback-warning"
|
||||
>
|
||||
{text}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
/* Metro module 14671; source: modules/premium/powerups/native/GuildPowerupsGameServerCard.tsx; dependencies: [31, 27, 4502, 8255, 33, 4501, 697, 566, 14672, 12304, 14637, 14663, 3868, 2] */
|
||||
function _fun110753(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110753, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14868:6, offset: 0x02385dbc, size: 257 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const gameServerStore = importDefault(8255) /* metro dependency 8255: GameServerStore */;
|
||||
const env0_6 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
const env0_7 = Reflect.apply(createStyles, createStylesModule, [{riveContainer: {flex: 1, paddingVertical: PX_8}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsGameServerCard.tsx');
|
||||
exports.default = GuildPowerupsGameServerCard;
|
||||
}
|
||||
|
||||
function GuildPowerupsGameServerCard({guildId}) { // fn#110754, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14868:345, offset: 0x02385ebd, size: 373 bytes, params: 2, frame: 23
|
||||
const styles = useStyles();
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GameServerStore],
|
||||
function() {
|
||||
return GameServerStore.getStateForGuild(guildId);
|
||||
});
|
||||
const value2 = (importDefault(14672) /* metro dependency 14672: useGameServerPowerupStatus */)(guildId);
|
||||
const value3 = (importDefault(12304) /* metro dependency 12304: useGameServerPerk */)(guildId);
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
return stateForGuild == null || value3 == null ? null : ((Component) => <Component title={value3.title} description={value3.description} cost={value3.cost} costDecorator="+" riveComponent={<View style={styles.riveContainer}>{((GameServerHostingRive) => <GameServerHostingRive stateMachine="SM_Auto" dataBinding={{reducedMotion: useReducedMotion}} />)((require(3868) /* metro dependency 3868: native */).GameServerHostingRive)}</View>} badge="beta" status={value2} onPress={(importDefault(14637) /* metro dependency 14637: useGuildPowerupOnShowMore */)(guildId,
|
||||
value3)} />)(importDefault(14663) /* metro dependency 14663: GuildPowerupsPerkCard */);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
/* Metro module 14643; source: modules/premium/powerups/native/GuildPowerupsImage.tsx; dependencies: [4502, 33, 4501, 566, 478, 7601, 5475, 2] */
|
||||
function _fun110643(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110643, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14840:6, offset: 0x02381181, size: 186 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const env0_4 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const env0_5 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({image: {'width': '75%',
|
||||
'height': '100%', 'alignSelf': 'center', 'resizeMode': 'contain'}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsImage.tsx');
|
||||
exports.default = GuildPowerupsImage;
|
||||
}
|
||||
|
||||
function GuildPowerupsImage({imageUrl, isAnimated, style}) { // fn#110644, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14840:318, offset: 0x0238123b, size: 248 bytes, params: 2, frame: 21
|
||||
var r0;
|
||||
isAnimated = isAnimated === undefined || isAnimated;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
const platformUtilsModule = require(478) /* metro dependency 478: PlatformUtils */;
|
||||
if (platformUtilsModule.isAndroid()) {
|
||||
if (isAnimated) {
|
||||
if (useReducedMotion) {
|
||||
value = importDefault(5475) /* metro dependency 5475: FastImage */;
|
||||
value = ((Component) => <Component style={[styles.image, style]} source={{uri: imageUrl}} />)(value);
|
||||
r0 = value;
|
||||
} else {
|
||||
value = importDefault(7601) /* metro dependency 7601: APNGDecorationNativeComponent */;
|
||||
value = ((Component) => <Component style={[styles.image, style]} url={imageUrl} />)(value);
|
||||
r0 = value;
|
||||
}
|
||||
} else {
|
||||
value = importDefault(5475) /* metro dependency 5475: FastImage */;
|
||||
value = ((Component) => <Component style={[styles.image, style]} source={{uri: imageUrl}} />)(value);
|
||||
r0 = value;
|
||||
}
|
||||
} else {
|
||||
value = importDefault(5475) /* metro dependency 5475: FastImage */;
|
||||
value = ((Component) => <Component style={[styles.image, style]} source={{uri: imageUrl}} />)(value);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,261 @@
|
||||
/* Metro module 14631; source: modules/premium/powerups/native/GuildPowerupsLevelCard.tsx; dependencies: [31, 27, 8259, 661, 14632, 33, 4501, 697, 4589, 7958, 14633, 14634, 4573, 1244, 2256, 14635, 14636, 14637, 14660, 14644, 2] */
|
||||
function _fun110585(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110585, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:6, offset: 0x0237e1fe, size: 1002 bytes, params: 8, frame: 25
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const closure = GuildPowerupLevelBody;
|
||||
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;
|
||||
let value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_5 = value.LevelCardPosition;
|
||||
const env0_6 = value.PowerupActiveStatusType;
|
||||
value = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_7 = value.BoostedGuildTiers;
|
||||
const env0_8 = value.HorizontalGradient;
|
||||
const env0_9 = (require(14632) /* metro dependency 14632: GuildBoostingMarketingConstants */).TIER_CARDS;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_10 = value.jsx;
|
||||
const env0_11 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object2 = {};
|
||||
object2.cardContainer = {flex: 1};
|
||||
object2.card = {'padding': 0, 'overflow': 'hidden', 'flex': 1};
|
||||
const PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object2.progressContainer = {marginVertical: PX_24, position: 'relative'};
|
||||
let BACKGROUND_MOD_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_SUBTLE;
|
||||
object2.progress = {height: 6, backgroundColor: BACKGROUND_MOD_SUBTLE};
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.progressStart = {marginStart: PX_16};
|
||||
const object3 = {};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object3.marginEnd = PX_16;
|
||||
object3.borderTopEndRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
object3.borderBottomEndRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
object2.progressEnd = object3;
|
||||
const object4 = {'backgroundColor': null, 'width': 28, 'height': 28, 'start': null, 'top': -11};
|
||||
const CARD_BACKGROUND_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.CARD_BACKGROUND_DEFAULT;
|
||||
object4.backgroundColor = CARD_BACKGROUND_DEFAULT;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object4.start = PX_16 - 2;
|
||||
object2.boostContainerBackground = object4;
|
||||
const object5 = {'padding': null, 'borderRadius': null, 'position': 'absolute', 'width': 24, 'height': 24,
|
||||
'top': -9, 'start': null, 'alignItems': 'center', 'justifyContent': 'center'};
|
||||
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object5.padding = PX_4;
|
||||
object5.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.start = PX_16;
|
||||
BACKGROUND_MOD_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_SUBTLE;
|
||||
object5.backgroundColor = BACKGROUND_MOD_SUBTLE;
|
||||
object2.boostContainer = object5;
|
||||
const GUILD_BOOSTING_PINK = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GUILD_BOOSTING_PINK;
|
||||
object2.boostContainerActive = {backgroundColor: GUILD_BOOSTING_PINK};
|
||||
BACKGROUND_MOD_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_SUBTLE;
|
||||
object2.boostContainerInactive = {backgroundColor: BACKGROUND_MOD_SUBTLE};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.contentContainer = {'padding': null, 'paddingTop': 0, 'flex': 1, padding: PX_16};
|
||||
const object9 = {flexDirection: 'column'};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object9.marginTop = PX_16;
|
||||
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object9.gap = PX_8;
|
||||
object2.perkRowContainer = object9;
|
||||
object2.perkRow = {'flexDirection': 'row', 'alignItems': 'center'};
|
||||
object2.perkRowStyle = {'flexDirection': 'row', 'alignItems': 'center'};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object2.perkText = {marginStart: PX_8};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.footerContainer = {marginTop: 'auto', paddingTop: PX_16};
|
||||
const env0_12 = Reflect.apply(createStyles, value, [object2]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsLevelCard.tsx');
|
||||
exports.default = GuildPowerupsLevelCard;
|
||||
exports.GuildPowerupLevelBody = closure;
|
||||
}
|
||||
|
||||
function GuildLevelPowerupHeader({active, nextActive, position}) { // fn#110586, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:1616, offset: 0x0237e5e8, size: 519 bytes, params: 2, frame: 23
|
||||
var r7;
|
||||
var boostContainerInactive;
|
||||
var backgroundColor;
|
||||
var items;
|
||||
var boostContainerActive;
|
||||
const styles = useStyles();
|
||||
if (active) {
|
||||
if (nextActive !== false) {
|
||||
boostContainerActive = styles.boostContainerActive;
|
||||
backgroundColor = boostContainerActive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
boostContainerActive = styles.boostContainerActive;
|
||||
backgroundColor = boostContainerActive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
} else if (active) {
|
||||
if (nextActive === false) {
|
||||
backgroundColor = styles.boostContainerActive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
backgroundColor = styles.boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
} else {
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
}
|
||||
} else {
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
}
|
||||
} else if (active) {
|
||||
if (nextActive === false) {
|
||||
backgroundColor = styles.boostContainerActive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
backgroundColor = styles.boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
} else {
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
}
|
||||
} else {
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items = [backgroundColor];
|
||||
boostContainerInactive = styles.boostContainerInactive;
|
||||
backgroundColor = boostContainerInactive.backgroundColor;
|
||||
items[1] = backgroundColor;
|
||||
r7 = items;
|
||||
}
|
||||
const defaultImport = importDefault(4589) /* metro dependency 4589 */;
|
||||
const object3 = {};
|
||||
let START = HorizontalGradient.START;
|
||||
object3.start = START;
|
||||
let END = HorizontalGradient.END;
|
||||
object3.end = END;
|
||||
object3.colors = r7;
|
||||
START = LevelCardPosition.START;
|
||||
END = LevelCardPosition.END;
|
||||
object3.style = [styles.progress, position === START && styles.progressStart,
|
||||
position === END && styles.progressEnd];
|
||||
const items2 = [((Component) => <Component {...object3} />)(defaultImport)];
|
||||
items2[1] = <View style={[styles.boostContainer, styles.boostContainerBackground]} />;
|
||||
const items4 = [styles.boostContainer];
|
||||
items4[1] = active && styles.boostContainerActive;
|
||||
const BoostGemIcon = (require(7958) /* metro dependency 7958: BoostGemIcon */).BoostGemIcon;
|
||||
const WHITE = (importDefault(697) /* metro dependency 697: native */).colors.WHITE;
|
||||
items2[2] = <View style={items4}><BoostGemIcon size="xs" color={WHITE} /></View>;
|
||||
return (
|
||||
<View style={styles.progressContainer}>
|
||||
{items2}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupLevelBody({isActive, index}) { // fn#110587, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:2324, offset: 0x0237e7ef, size: 296 bytes, params: 2, frame: 25
|
||||
const styles = useStyles();
|
||||
const {textColor,
|
||||
iconColor} = (importDefault(14633) /* metro dependency 14633: useGuildPowerupColorConfig */)(isActive);
|
||||
const value3 = iconColor.useMemo(_fun110588, [index, iconColor, textColor, styles]);
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
return (
|
||||
<View style={styles.perkRowContainer}>
|
||||
{value3}
|
||||
<View style={styles.perkRow}>
|
||||
<Text color={textColor} variant="text-sm/medium">
|
||||
{intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).nIj3LZ)}
|
||||
</Text>
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsLevelCard({guildId, powerup, nextPowerup, index, isScrollingRef}) { // fn#110590, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:3089, offset: 0x0237ea71, size: 583 bytes, params: 2, frame: 30
|
||||
const styles = useStyles();
|
||||
const value3 = (importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(guildId, powerup);
|
||||
const value4 = (importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(guildId, nextPowerup);
|
||||
const value5 = (require(14636) /* metro dependency 14636: useCalculatePowerupCardStatus */).useCalculatePowerupCardStatus(powerup,
|
||||
value3, false);
|
||||
let type = value3.type;
|
||||
let INACTIVE = PowerupActiveStatusType.INACTIVE;
|
||||
const value6 = type !== INACTIVE;
|
||||
type = value4.type;
|
||||
INACTIVE = PowerupActiveStatusType.INACTIVE;
|
||||
const value7 = type !== INACTIVE;
|
||||
const value8 = (importDefault(14637) /* metro dependency 14637: useGuildPowerupOnShowMore */)(guildId, powerup);
|
||||
const r7 = index === 0 ? LevelCardPosition.START : nextPowerup == null ? LevelCardPosition.END : LevelCardPosition.MIDDLE;
|
||||
const value9 = env0_3.useCallback(_fun110591, [isScrollingRef, value8]);
|
||||
const GuildPowerupsCard = importDefault(14660) /* metro dependency 14660: GuildPowerupsCard */;
|
||||
const guildLevelPowerupHeader = <GuildLevelPowerupHeader position={r7} active={value6} nextActive={nextPowerup != null ? value7 : undefined} />;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const items2 = [<Text variant="heading-lg/semibold">{powerup.title}</Text>];
|
||||
items2[1] = <GuildPowerupLevelBody isActive={value6} index={index} />;
|
||||
const GuildPowerupsCardFooter = (require(14644) /* metro dependency 14644: GuildPowerupsCardFooter */).GuildPowerupsCardFooter;
|
||||
items2[2] = <View style={styles.footerContainer}><GuildPowerupsCardFooter cost={powerup.cost} status={value5} /></View>;
|
||||
return (
|
||||
<GuildPowerupsCard
|
||||
containerStyle={styles.cardContainer}
|
||||
style={styles.card}
|
||||
onPress={value9}
|
||||
status={value5}
|
||||
>
|
||||
{guildLevelPowerupHeader}
|
||||
<View style={styles.contentContainer}>
|
||||
{items2}
|
||||
</View>
|
||||
</GuildPowerupsCard>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110588() { // fn#110588, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:2442, offset: 0x0237e917, size: 113 bytes, params: 1, frame: 15
|
||||
var environment;
|
||||
const value = environment.__proto__;
|
||||
const property = TIER_CARDS[index];
|
||||
if (property == null) {
|
||||
return [];
|
||||
}
|
||||
const tier = property.tier;
|
||||
const TIER_3 = BoostedGuildTiers.TIER_3;
|
||||
return (tier === TIER_3 ? property.perks.slice(0, -1) : property.perks)?.map(_fun110589);
|
||||
}
|
||||
|
||||
function _fun110591() { // fn#110591, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:3396, offset: 0x0237ecb8, size: 29 bytes, params: 1, frame: 9
|
||||
if (!isScrollingRef.current) {
|
||||
env0_1();
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110589(a0, a1) { // fn#110589, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14828:2559, offset: 0x0237e988, size: 233 bytes, params: 3, frame: 24
|
||||
const iconForPerk = (require(14634) /* metro dependency 14634: GuildBoostingMarketingUtils */).getIconForPerk(a0.perkIcon);
|
||||
const stylesBinding = styles;
|
||||
const perkRowStyle = stylesBinding.perkRowStyle;
|
||||
const value4 = ((Component) => <Component color={iconColor} size="sm" />)(iconForPerk);
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={perkRowStyle} key={'perk-' + index + '-' + a1}>
|
||||
{value4}
|
||||
<Text
|
||||
color={textColor}
|
||||
style={stylesBinding.perkText}
|
||||
variant="text-sm/medium"
|
||||
>
|
||||
{a0.getCopy()}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
/* Metro module 14629; source: modules/premium/powerups/native/GuildPowerupsLevelsSection.tsx; dependencies: [31, 27, 33, 697, 478, 4501, 14630, 1244, 2256, 12333, 14631, 2] */
|
||||
function _fun110576(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110576, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14826:6, offset: 0x0237dcd9, size: 363 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 */;
|
||||
const env0_4 = (require(27) /* metro dependency 27 */).View;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_5 = value.jsx;
|
||||
const env0_6 = value.Fragment;
|
||||
const env0_7 = value.jsxs;
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
value = require(478) /* metro dependency 478: PlatformUtils */;
|
||||
value = value.isIOS();
|
||||
const r11 = value ? 300 : 325;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object2 = {};
|
||||
object2.cardContainer = {'width': 250, 'marginEnd': null, 'flex': 1, marginEnd: PX_16};
|
||||
const object4 = {height: r11};
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object4.paddingBottom = PX_8;
|
||||
object2.scroller = object4;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.scrollerContent = {paddingHorizontal: PX_16};
|
||||
const env0_9 = Reflect.apply(createStyles, value, [object2]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsLevelsSection.tsx');
|
||||
exports.default = GuildPowerupsLevelsSection;
|
||||
}
|
||||
|
||||
function GuildPowerupsLevelsSection({guildId, listings}) { // fn#110577, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14826:496, offset: 0x0237de44, size: 379 bytes, params: 2, frame: 29
|
||||
const styles = useStyles();
|
||||
const binding = env0_3;
|
||||
const value2 = binding.useMemo(_fun110578, [listings]);
|
||||
const env0_4 = binding.useRef(false);
|
||||
const value3 = binding.useCallback(_fun110581, []);
|
||||
const jsxRuntimeEnv0_6Binding = jsxRuntimeEnv0_6;
|
||||
const GuildPowerupsSectionHeader = importDefault(14630) /* metro dependency 14630: GuildPowerupsSectionHeader */;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const guildPowerupsSectionHeader = <GuildPowerupsSectionHeader title={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['TXY/b0'])} description={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).aJv4PB)} />;
|
||||
const MarketingCardsScroller = (require(12333) /* metro dependency 12333: MarketingCardsScroller */).MarketingCardsScroller;
|
||||
return (
|
||||
<>
|
||||
{guildPowerupsSectionHeader}
|
||||
<MarketingCardsScroller
|
||||
cardMarginRight={PX_16}
|
||||
cardWidth={250}
|
||||
contentContainerStyle={styles.scrollerContent}
|
||||
itemCount={value2.length}
|
||||
onScrollingChange={value3}
|
||||
style={styles.scroller}
|
||||
>
|
||||
{value2.map(_fun110582)}
|
||||
</MarketingCardsScroller>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110578() { // fn#110578, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14826:579, offset: 0x0237dfbf, size: 45 bytes, params: 1, frame: 12
|
||||
return listings.filter(function(a0) {
|
||||
return a0.type === 'singleLevel';
|
||||
}).map(function(a0) {
|
||||
return a0.powerup;
|
||||
});
|
||||
}
|
||||
|
||||
function _fun110582(a0, a1) { // fn#110582, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14826:1007, offset: 0x0237e00b, size: 130 bytes, params: 3, frame: 21
|
||||
const value = environment.__proto__;
|
||||
return (
|
||||
<View style={styles.cardContainer} key={a0.skuId}>
|
||||
{((Component) => <Component guildId={guildId} powerup={a0} nextPowerup={env0_3[a1 + 1]} index={a1} isScrollingRef={env0_4} />)(importDefault(14631) /* metro dependency 14631: GuildPowerupsLevelCard */)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,102 @@
|
||||
/* Metro module 12302; source: modules/premium/powerups/native/GuildPowerupsMarketingHeader.tsx; dependencies: [31, 27, 8258, 33, 4501, 697, 674, 4573, 12303, 12307, 12310, 1244, 2256, 12311, 2] */
|
||||
function _fun93964(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93964, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12488:6, offset: 0x020ccdd3, size: 376 bytes, params: 8, frame: 24
|
||||
var object4;
|
||||
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 guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const env0_6 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
object4 = {};
|
||||
const object5 = {};
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object5.padding = PX_12;
|
||||
object5.backgroundColor = (importDefault(674) /* metro dependency 674 */)('#000000').alpha(0.18).hex();
|
||||
object4.container = object5;
|
||||
const object6 = {textAlign: 'center'};
|
||||
object6.color = (importDefault(674) /* metro dependency 674 */)('#FFFFFF').alpha(0.5).hex();
|
||||
object4.text = object6;
|
||||
const env0_7 = Reflect.apply(createStyles, createStylesModule, [object4]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsMarketingHeader.tsx');
|
||||
exports.default = GuildPowerupsMarketingHeader;
|
||||
}
|
||||
|
||||
function PerkText({powerup}) { // fn#93965, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12488:330, offset: 0x020ccf4b, size: 74 bytes, params: 2, frame: 14
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<Text color="always-white" variant="text-sm/semibold">
|
||||
{powerup.title}
|
||||
</Text>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsMarketingHeader({guild}) { // fn#93966, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12488:560, offset: 0x020ccf95, size: 516 bytes, params: 2, frame: 33
|
||||
var length;
|
||||
var r12;
|
||||
var r11;
|
||||
var value4;
|
||||
var Text;
|
||||
var intl;
|
||||
var format;
|
||||
var property;
|
||||
var value5;
|
||||
var value6;
|
||||
var intl2;
|
||||
var format2;
|
||||
var MNO3sG;
|
||||
var object;
|
||||
const styles = useStyles();
|
||||
const value3 = (importDefault(12303) /* metro dependency 12303: useMarketablePowerupPerks */)(guild.id);
|
||||
env0_3.useEffect(_fun93967, [guild.id]);
|
||||
if ((importDefault(12310) /* metro dependency 12310: useHasAllocateBoostPermission */)(guild.id)) {
|
||||
length = value3?.length;
|
||||
value4 = 0;
|
||||
if (value4 !== (length ?? value4)) {
|
||||
var viewBindingProps = {style: styles.container};
|
||||
Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var textProps = {style: styles.text, variant: 'text-sm/semibold'};
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
format = intl.format;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['7lwpzR'];
|
||||
value5 = '';
|
||||
if (value3 == null) {
|
||||
r11 = value5;
|
||||
} else if (value4 === value3.length) {
|
||||
r11 = value5;
|
||||
} else {
|
||||
value6 = (importDefault(12311) /* metro dependency 12311: orderMarketablePerksForDisplay */)(value3);
|
||||
if (value6.length === 1) {
|
||||
r12 = <PerkText powerup={value6[value4]} />;
|
||||
} else {
|
||||
intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
format2 = intl2.format;
|
||||
MNO3sG = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).MNO3sG;
|
||||
object = {};
|
||||
object.perk1 = <PerkText powerup={value6[value4]} />;
|
||||
object.perk2 = <PerkText powerup={value6[1]} />;
|
||||
r12 = Reflect.apply(format2, intl2, [MNO3sG, object]);
|
||||
}
|
||||
r11 = r12;
|
||||
}
|
||||
return (
|
||||
<View {...viewBindingProps}>
|
||||
<Text {...textProps}>
|
||||
{Reflect.apply(format, intl, [property, {perks: r11}])}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function _fun93967() { // fn#93967, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12488:653, offset: 0x020cd199, size: 79 bytes, params: 1, frame: 13
|
||||
let value = environment.__proto__;
|
||||
if (GuildPowerupsStore.shouldFetchCatalogForGuild(guild.id)) {
|
||||
value = require(12307) /* metro dependency 12307: GuildPowerupsActionCreators */;
|
||||
value.fetchPowerupCatalogForGuild(guild.id);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,125 @@
|
||||
/* Metro module 14600; source: modules/premium/powerups/native/GuildPowerupsModal.tsx; dependencies: [31, 27, 8259, 33, 4501, 697, 6857, 14601, 14607, 1585, 6771, 14619, 5080, 8254, 5287, 1244, 2256, 9603, 5282, 14620, 14622, 14629, 14661, 14673, 14680, 2] */
|
||||
function _fun110380(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110380, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14797:6, offset: 0x023775a5, size: 519 bytes, params: 8, frame: 22
|
||||
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.ScrollView;
|
||||
const env0_5 = value.View;
|
||||
value = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_6 = value.BoostInfoType;
|
||||
const env0_7 = value.GuildPowerupType;
|
||||
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 BACKGROUND_BASE_LOW = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOW;
|
||||
object2.container = {flex: 1, backgroundColor: BACKGROUND_BASE_LOW};
|
||||
const object5 = {};
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.paddingHorizontal = PX_16;
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object5.paddingTop = PX_8;
|
||||
object2.headerContainer = object5;
|
||||
const object6 = {'flexDirection': 'row', 'justifyContent': 'space-between', 'borderWidth': 1,
|
||||
'borderStyle': 'solid'};
|
||||
let BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
|
||||
object6.borderColor = BORDER_SUBTLE;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object6.marginBottom = PX_16;
|
||||
object2.boostInfoContainer = object6;
|
||||
BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
|
||||
object2.boostInfoSeparator = {'width': 1, 'height': '100%', backgroundColor: BORDER_SUBTLE};
|
||||
const PX_96 = (importDefault(697) /* metro dependency 697: native */).space.PX_96;
|
||||
object2.scrollView = {paddingBottom: PX_96};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.boostButtonContainer = {'paddingHorizontal': null, 'position': 'absolute', 'bottom': 0, 'left': 0,
|
||||
'right': 0, paddingHorizontal: PX_16};
|
||||
const env0_10 = Reflect.apply(createStyles, value, [object2]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsModal.tsx');
|
||||
exports.default = GuildPowerupsModal;
|
||||
}
|
||||
|
||||
function GuildPowerupsModal({guildId, analyticsLocation}) { // fn#110381, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14797:917, offset: 0x023777ac, size: 895 bytes, params: 2, frame: 36
|
||||
const value2 = (require(6857) /* metro dependency 6857: GameServerExperiment */).useGameServerEnabled(guildId,
|
||||
'GuildPowerupsModal');
|
||||
(importDefault(14601) /* metro dependency 14601: useLoadGuildPowerups */)(guildId);
|
||||
(require(14607) /* metro dependency 14607: useGuildPowerupsNotifications */).useAutoDismissGuildPowerupsNotifications(guildId);
|
||||
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
|
||||
const styles = useStyles();
|
||||
const defaultImport = importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */;
|
||||
const r6 = analyticsLocation != null ? [analyticsLocation] : [];
|
||||
const items5 = [];
|
||||
arraySpread(items5, r6, 0, undefined);
|
||||
const analyticsLocations = apply(defaultImport, items5, undefined, undefined).analyticsLocations;
|
||||
const value3 = (require(14619) /* metro dependency 14619: powerupListing */).useBuildGuildPowerupsSections(guildId,
|
||||
value2);
|
||||
const value4 = env0_3.useCallback(_fun110382, []);
|
||||
const {available, spent,
|
||||
total} = (importDefault(8254) /* metro dependency 8254: useGuildPowerupsBoostCount */)(guildId);
|
||||
const AnalyticsLocationProvider = (require(6771) /* metro dependency 6771: useAnalyticsLocations */).AnalyticsLocationProvider;
|
||||
const Header = (require(5287) /* metro dependency 5287 */).Header;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const items6 = [<View style={styles.headerContainer}><Header title={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).hjvcLO)} headerTitle={headerTitle_110383} headerTitleAlign="center" headerLeft={(require(5282) /* metro dependency 5282: NavigatorHeaderNative */).getHeaderCloseButton(value4)} /></View>];
|
||||
const GuildPowerupsBoostInfo = importDefault(14620) /* metro dependency 14620: GuildPowerupsBoostInfo */;
|
||||
const AVAILABLE = BoostInfoType.AVAILABLE;
|
||||
const items2 = [<GuildPowerupsBoostInfo count={available} type={AVAILABLE} />];
|
||||
items2[1] = <View style={styles.boostInfoSeparator} />;
|
||||
let value = GuildPowerupsBoostInfo;
|
||||
const SPENT = BoostInfoType.SPENT;
|
||||
items2[2] = ((Component) => <Component count={spent} type={SPENT} />)(value);
|
||||
items2[3] = <View style={styles.boostInfoSeparator} />;
|
||||
value = GuildPowerupsBoostInfo;
|
||||
const TOTAL = BoostInfoType.TOTAL;
|
||||
items2[4] = ((Component) => <Component count={total} type={TOTAL} />)(value);
|
||||
const items3 = [<View style={styles.boostInfoContainer}>{items2}</View>];
|
||||
items3[1] = ((Component) => <Component guildId={guildId} />)(importDefault(14622) /* metro dependency 14622: GuildPowerupsNotificationContainer */);
|
||||
items3[2] = value3.map(_fun110384);
|
||||
items3[3] = ((Component) => <Component guildId={guildId} />)(importDefault(14673) /* metro dependency 14673: GuildPowerupsRecentActivitySection */);
|
||||
items6[1] = <ScrollView contentContainerStyle={styles.scrollView}>{items3}</ScrollView>;
|
||||
const items4 = [styles.boostButtonContainer];
|
||||
items4[1] = {paddingBottom: bottom};
|
||||
const GuildPowerupsBoostButton = (require(14680) /* metro dependency 14680: GuildPowerupsBoostButton */).GuildPowerupsBoostButton;
|
||||
items6[2] = <View style={items4}><GuildPowerupsBoostButton guildId={guildId} /></View>;
|
||||
return (
|
||||
<AnalyticsLocationProvider value={analyticsLocations}>
|
||||
<View style={styles.container}>
|
||||
{items6}
|
||||
</View>
|
||||
</AnalyticsLocationProvider>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110382() { // fn#110382, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14797:1241, offset: 0x02377b2b, size: 37 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
(importDefault(5080) /* metro dependency 5080: ModalActionCreators */).pop();
|
||||
}
|
||||
|
||||
function GuildPowerupsModalHeaderTitle() { // fn#110383, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14797:1523, owner: GuildPowerupsModal.headerTitle, offset: 0x02377b50, size: 98 bytes, params: 1, frame: 18
|
||||
const GenericHeaderTitle = (require(9603) /* metro dependency 9603: HeaderShared */).GenericHeaderTitle;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
return (
|
||||
<GenericHeaderTitle
|
||||
title={intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).hjvcLO)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110384(a0) { // fn#110384, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14797:1981, offset: 0x02377bb2, size: 171 bytes, params: 2, frame: 17
|
||||
const type = a0.type;
|
||||
const value = environment.__proto__;
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
if (LEVEL === type) {
|
||||
return ((Component) => <Component guildId={guildId} listings={a0.listings} key={a0.type} />)(importDefault(14629) /* metro dependency 14629: GuildPowerupsLevelsSection */);
|
||||
}
|
||||
const PERK = GuildPowerupType.PERK;
|
||||
if (PERK === type) {
|
||||
return ((Component) => <Component guildId={guildId} listings={a0.listings} key={a0.type} />)(importDefault(14661) /* metro dependency 14661: GuildPowerupsPerksSection */);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,180 @@
|
||||
/* Metro module 14670; source: modules/premium/powerups/native/GuildPowerupsMultiPerkBottomSheet.tsx; dependencies: [27, 33, 4501, 697, 674, 3866, 4048, 12310, 14635, 14636, 14633, 14640, 14649, 14650, 14653, 14643, 1305, 1244, 4573, 14644, 4578, 2256, 1585, 14665, 6275, 6277, 14630, 14659, 2] */
|
||||
function _fun110747(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110747, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:6, offset: 0x023853cf, size: 334 bytes, params: 8, frame: 22
|
||||
var object4;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
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 */;
|
||||
let createStyles = value.createStyles;
|
||||
const env0_6 = Reflect.apply(createStyles, value, [_fun110750]);
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
createStyles = value.createStyles;
|
||||
object4 = {};
|
||||
const object5 = {};
|
||||
const PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object5.gap = PX_24;
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.marginHorizontal = PX_16;
|
||||
object4.cardsContainer = object5;
|
||||
const object6 = {};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object6.marginHorizontal = PX_16;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object6.marginBottom = PX_16;
|
||||
object4.disabledReasonContainer = object6;
|
||||
const env0_7 = Reflect.apply(createStyles, value, [object4]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsMultiPerkBottomSheet.tsx');
|
||||
exports.default = GuildPowerupsMultiPerkBottomSheet;
|
||||
}
|
||||
|
||||
function GuildPowerupsMultiPerkCard_110748({guildId, powerup, isNewPerk, forceStaticImage}) { // fn#110748, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:1254, offset: 0x0238551d, size: 1104 bytes, params: 2, frame: 38
|
||||
var r9;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var string;
|
||||
var Button;
|
||||
var value;
|
||||
const themesModule = require(3866) /* metro dependency 3866: themes */;
|
||||
const styles = useStyles(themesModule.isThemeLight((importDefault(4048) /* metro dependency 4048: useTheme */)()));
|
||||
const value3 = (importDefault(12310) /* metro dependency 12310: useHasAllocateBoostPermission */)(guildId);
|
||||
const value4 = (importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(guildId, powerup);
|
||||
const value5 = (require(14636) /* metro dependency 14636: useCalculatePowerupCardStatus */).useCalculatePowerupCardStatus(powerup,
|
||||
value4, false);
|
||||
const isPowerupActiveStatusActive2 = (require(14635) /* metro dependency 14635: usePowerupActiveStatus */).isPowerupActiveStatusActive(value4);
|
||||
const textColor = (importDefault(14633) /* metro dependency 14633: useGuildPowerupColorConfig */)(isPowerupActiveStatusActive2).textColor;
|
||||
const value6 = (importDefault(14640) /* metro dependency 14640: useGetGuildPowerupBannerImage */)(powerup, true,
|
||||
forceStaticImage);
|
||||
const disabled = (importDefault(14649) /* metro dependency 14649: useCanGuildPowerupBeToggled */)(guildId, powerup,
|
||||
isPowerupActiveStatusActive2).disabled;
|
||||
const value7 = (importDefault(14650) /* metro dependency 14650: useGuildPowerupOnActivate */)(guildId, powerup);
|
||||
const env0_1 = value7.onActivate;
|
||||
const isLoading = value7.isLoading;
|
||||
const env0_2 = (importDefault(14653) /* metro dependency 14653: useGuildPowerupOnShowDeactivate */)(guildId,
|
||||
powerup);
|
||||
const items2 = [styles.container];
|
||||
items2[1] = disabled && value3 && styles.disabled;
|
||||
const view = <View style={[styles.imageContainer, value5?.type === 'active' && styles.imageContainerActive,
|
||||
value5?.type === 'expiring' && styles.imageContainerExpiring,
|
||||
value5?.type === 'removing' && styles.imageContainerRemoving]}>{((Component) => <Component imageUrl={value6 ?? ''} isAnimated={!forceStaticImage} style={styles.image} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */)}{isNewPerk && ((TextBadge) => <TextBadge text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.y2b7CA)} style={styles.badge} />)((require(1305) /* metro dependency 1305: native */).TextBadge)}</View>;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const view2 = <View style={styles.titleContainer}><Text variant="heading-md/semibold" color={textColor}>{powerup.title}</Text>{value5 != null ? ((GuildPowerupCardFooterStatus) => <GuildPowerupCardFooterStatus status={value5} />)((require(14644) /* metro dependency 14644: GuildPowerupsCardFooter */).GuildPowerupCardFooterStatus) : ((GuildPowerupCardFooterCost) => <GuildPowerupCardFooterCost cost={powerup.cost} />)((require(14644) /* metro dependency 14644: GuildPowerupsCardFooter */).GuildPowerupCardFooterCost)}</View>;
|
||||
if (value3) {
|
||||
Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
var buttonProps = {disabled: disabled, loading: isLoading,
|
||||
variant: isPowerupActiveStatusActive2 ? 'secondary' : 'primary'};
|
||||
string = intl.string;
|
||||
value = importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */;
|
||||
buttonProps.text = Reflect.apply(string, intl, [isPowerupActiveStatusActive2 ? value.TZsu1U : value.gSxlHf]);
|
||||
buttonProps.onPress = onPress_110749;
|
||||
value = <Button {...buttonProps} />;
|
||||
r9 = value;
|
||||
} else {
|
||||
r9 = value3;
|
||||
}
|
||||
return (
|
||||
<View style={items2}>
|
||||
{view}
|
||||
<View style={styles.bodyContainer}>
|
||||
{view2}
|
||||
{r9}
|
||||
</View>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110750(a0) { // fn#110750, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:162, offset: 0x02385991, size: 604 bytes, params: 2, frame: 18
|
||||
const object2 = {};
|
||||
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object2.container = {gap: PX_8};
|
||||
const object8 = {};
|
||||
const PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object8.gap = PX_24;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object8.marginHorizontal = PX_16;
|
||||
object2.cardsContainer = object8;
|
||||
object2.titleContainer = {'flexDirection': 'column', 'gap': 4};
|
||||
object2.bodyContainer = {'justifyContent': 'space-between', 'alignItems': 'center', 'flexDirection': 'row'};
|
||||
const object10 = {};
|
||||
object10.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
|
||||
object10.borderWidth = 1;
|
||||
const BACKGROUND_MOD_MUTED = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_MUTED;
|
||||
object10.borderColor = BACKGROUND_MOD_MUTED;
|
||||
object10.borderStyle = 'solid';
|
||||
object10.backgroundColor = (importDefault(674) /* metro dependency 674 */)(a0 ? '#000000' : '#ffffff').alpha(0.04).hex();
|
||||
object2.imageContainer = object10;
|
||||
const object11 = {};
|
||||
let value = importDefault(674) /* metro dependency 674 */;
|
||||
const GREEN_360 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GREEN_360;
|
||||
value = value(GREEN_360);
|
||||
value = value.alpha(0.35);
|
||||
object11.borderColor = value.hex();
|
||||
object2.imageContainerActive = object11;
|
||||
const object12 = {};
|
||||
value = importDefault(674) /* metro dependency 674 */;
|
||||
let YELLOW_300 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.YELLOW_300;
|
||||
value = value(YELLOW_300);
|
||||
value = value.alpha(0.35);
|
||||
object12.borderColor = value.hex();
|
||||
object2.imageContainerExpiring = object12;
|
||||
const object13 = {};
|
||||
value = importDefault(674) /* metro dependency 674 */;
|
||||
YELLOW_300 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.YELLOW_300;
|
||||
value = value(YELLOW_300);
|
||||
value = value.alpha(0.35);
|
||||
object13.borderColor = value.hex();
|
||||
object2.imageContainerRemoving = object13;
|
||||
object2.image = {'width': '75%', 'height': 180, 'resizeMode': 'contain'};
|
||||
object2.disabled = {opacity: 0.5};
|
||||
const object14 = {position: 'absolute'};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object14.top = PX_8;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object14.right = PX_8;
|
||||
object2.badge = object14;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function GuildPowerupsMultiPerkBottomSheet({guildId, listing}) { // fn#110751, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:2621, offset: 0x02385bed, size: 400 bytes, params: 2, frame: 31
|
||||
var r0;
|
||||
var BottomSheet;
|
||||
var BottomSheetScrollView;
|
||||
var items2;
|
||||
const styles = useStyles();
|
||||
const bottom = (importDefault(1585) /* metro dependency 1585: useSafeAreaInsetsNative */)().bottom;
|
||||
const value2 = (importDefault(14665) /* metro dependency 14665: usePowerupGroupConfig */)(guildId, listing);
|
||||
if (value2 == null) {
|
||||
r0 = null;
|
||||
} else {
|
||||
BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
BottomSheetScrollView = (require(6277) /* metro dependency 6277 */).BottomSheetScrollView;
|
||||
var bottomSheetScrollViewProps = {contentContainerStyle: {paddingBottom: bottom}};
|
||||
items2 = [((Component) => <Component title={value2.title} description={value2.description} />)(importDefault(14630) /* metro dependency 14630: GuildPowerupsSectionHeader */)];
|
||||
items2[1] = value2.disabledReason != null && <View style={styles.disabledReasonContainer}>{((Component) => <Component text={value2.disabledReason} />)(importDefault(14659) /* metro dependency 14659: GuildPowerupsDisabledWarning */)}</View>;
|
||||
items2[2] = <View style={styles.cardsContainer}>{listing.powerups.map(_fun110752)}</View>;
|
||||
r0 = <BottomSheet scrollable startExpanded><BottomSheetScrollView {...bottomSheetScrollViewProps}>{items2}</BottomSheetScrollView></BottomSheet>;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function GuildPowerupsMultiPerkCard_110748OnPress() { // fn#110749, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:2483, owner: GuildPowerupsMultiPerkCard_110748.onPress, offset: 0x0238596d, size: 36 bytes, params: 1, frame: 10
|
||||
if (env0_0) {
|
||||
env0_2();
|
||||
} else {
|
||||
onActivate();
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110752(a0) { // fn#110752, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14867:3116, offset: 0x02385d7d, size: 63 bytes, params: 2, frame: 16
|
||||
return (
|
||||
<GuildPowerupsMultiPerkCard_110748
|
||||
guildId={guildId}
|
||||
powerup={a0}
|
||||
forceStaticImage={env0_1.forceStaticImages}
|
||||
key={a0.skuId}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,50 @@
|
||||
/* Metro module 14664; source: modules/premium/powerups/native/GuildPowerupsMultiPerkCard.tsx; dependencies: [31, 4502, 33, 14665, 566, 14668, 14669, 14663, 2] */
|
||||
function _fun110728(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110728, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14861:6, offset: 0x02384a9a, size: 158 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsMultiPerkCard.tsx');
|
||||
exports.default = GuildPowerupsMultiPerkCard;
|
||||
}
|
||||
|
||||
function GuildPowerupsMultiPerkCard({guildId, listing}) { // fn#110729, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14861:236, offset: 0x02384b38, size: 321 bytes, params: 2, frame: 21
|
||||
var r0;
|
||||
var title;
|
||||
var description;
|
||||
var cost;
|
||||
var image;
|
||||
var value;
|
||||
const value2 = (importDefault(14665) /* metro dependency 14665: usePowerupGroupConfig */)(guildId, listing);
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
const value3 = (importDefault(14668) /* metro dependency 14668: useMultiPerkStatusValues */)({guildId: guildId,
|
||||
powerups: listing.powerups});
|
||||
if (value3 == null) {
|
||||
r0 = null;
|
||||
} else if (value2 == null) {
|
||||
r0 = null;
|
||||
} else {
|
||||
value = importDefault(14663) /* metro dependency 14663: GuildPowerupsPerkCard */;
|
||||
title = value2.title;
|
||||
description = value2.description;
|
||||
cost = value3.cost;
|
||||
image = value2.image;
|
||||
value = ((Component) => <Component title={title} description={description} cost={cost} imageUrl={useReducedMotion ? image.staticUrl : image.animatedUrl} status={value3.status} costDecorator={value3.costDecorator} onPress={env0_3.useCallback(_fun110731,
|
||||
|
||||
[guildId, listing])} badge={value2.badge} />)(value);
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110731() { // fn#110731, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14861:433, offset: 0x02384c79, size: 54 bytes, params: 1, frame: 13
|
||||
const value = environment.__proto__;
|
||||
(importDefault(14669) /* metro dependency 14669: openGuildPowerupsMultiPerkBottomSheet */)({guildId: guildId,
|
||||
listing: listing});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
/* Metro module 14622; source: modules/premium/powerups/native/GuildPowerupsNotificationContainer.tsx; dependencies: [27, 33, 4501, 697, 4573, 14623, 14624, 1244, 2256, 14627, 2] */
|
||||
function _fun110548(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110548, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14819:6, offset: 0x0237ccc3, size: 369 bytes, params: 8, frame: 23
|
||||
var object4;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
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;
|
||||
object4 = {};
|
||||
const object5 = {};
|
||||
let PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object5.gap = PX_12;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.margin = PX_16;
|
||||
object4.container = object5;
|
||||
const object6 = {};
|
||||
PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object6.padding = PX_12;
|
||||
const BACKGROUND_MOD_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_SUBTLE;
|
||||
object6.backgroundColor = BACKGROUND_MOD_SUBTLE;
|
||||
object6.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
|
||||
object6.borderWidth = 1;
|
||||
object6.borderStyle = 'solid';
|
||||
const BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
|
||||
object6.borderColor = BORDER_SUBTLE;
|
||||
object4.staffContainer = object6;
|
||||
const env0_6 = Reflect.apply(createStyles, value, [object4]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsNotificationContainer.tsx');
|
||||
exports.default = GuildPowerupsNotificationContainer;
|
||||
}
|
||||
|
||||
function Tier3OverrideNotice({text}) { // fn#110549, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14819:430, offset: 0x0237ce34, size: 104 bytes, params: 2, frame: 18
|
||||
const styles = useStyles();
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={styles.staffContainer}>
|
||||
<Text variant="text-sm/medium">
|
||||
{text}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsNotificationContainer({guildId}) { // fn#110550, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14819:694, offset: 0x0237ce9c, size: 338 bytes, params: 2, frame: 26
|
||||
var r6;
|
||||
var r0;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var items2;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
const value2 = (importDefault(14623) /* metro dependency 14623: useGuildPowerupTier3OverrideConfig */)(guildId);
|
||||
const value3 = (importDefault(14624) /* metro dependency 14624: useGuildPowerupExpiringNotificationsConfig */)(guildId);
|
||||
let shouldShow = value2.shouldShow;
|
||||
if (shouldShow) {
|
||||
var viewBindingProps = {style: styles.container};
|
||||
items2 = [<Text variant="eyebrow" color="text-subtle">{intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['3FRirU'])}</Text>];
|
||||
shouldShow = value2.shouldShow;
|
||||
r6 = shouldShow && <Tier3OverrideNotice text={value2.text} />;
|
||||
items2[1] = r6;
|
||||
shouldShow = value3.shouldShow;
|
||||
if (shouldShow) {
|
||||
value = importDefault(14627) /* metro dependency 14627: GuildPowerupsWarning */;
|
||||
value = ((Component) => <Component guildId={guildId} powerupNames={value3.expiringPowerupNames} warnings={value3.warnings} />)(value);
|
||||
r6 = value;
|
||||
} else {
|
||||
r6 = shouldShow;
|
||||
}
|
||||
items2[2] = r6;
|
||||
value = <View {...viewBindingProps}>{items2}</View>;
|
||||
r0 = value;
|
||||
} else {
|
||||
shouldShow = value3.shouldShow;
|
||||
if (shouldShow) {
|
||||
var viewBindingProps = {style: styles.container};
|
||||
items2 = [<Text variant="eyebrow" color="text-subtle">{intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['3FRirU'])}</Text>];
|
||||
shouldShow = value2.shouldShow;
|
||||
r6 = shouldShow && <Tier3OverrideNotice text={value2.text} />;
|
||||
items2[1] = r6;
|
||||
shouldShow = value3.shouldShow;
|
||||
if (shouldShow) {
|
||||
value = importDefault(14627) /* metro dependency 14627: GuildPowerupsWarning */;
|
||||
value = ((Component) => <Component guildId={guildId} powerupNames={value3.expiringPowerupNames} warnings={value3.warnings} />)(value);
|
||||
r6 = value;
|
||||
} else {
|
||||
r6 = shouldShow;
|
||||
}
|
||||
items2[2] = r6;
|
||||
value = <View {...viewBindingProps}>{items2}</View>;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = null;
|
||||
}
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
/* Metro module 14663; source: modules/premium/powerups/native/GuildPowerupsPerkCard.tsx; dependencies: [31, 27, 33, 4501, 697, 4048, 4002, 14660, 14643, 4589, 4573, 14644, 1305, 1244, 2] */
|
||||
function _fun110726(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110726, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14860:6, offset: 0x02384581, size: 433 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 */;
|
||||
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;
|
||||
object2 = {};
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object2.container = {marginHorizontal: PX_16};
|
||||
object2.card = {'padding': 0, 'overflow': 'hidden'};
|
||||
const object4 = {};
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object4.gap = PX_16;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object4.padding = PX_16;
|
||||
object2.contentContainer = object4;
|
||||
object2.imageContainer = {'width': '100%', 'height': 160};
|
||||
object2.gradient = {'position': 'absolute', 'left': 0, 'right': 0, 'top': 0, 'height': '100%'};
|
||||
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object2.headerContainer = {gap: PX_4};
|
||||
const object6 = {position: 'absolute'};
|
||||
let PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object6.top = PX_12;
|
||||
PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object6.right = PX_12;
|
||||
object2.badge = object6;
|
||||
const env0_6 = Reflect.apply(createStyles, value, [object2]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsPerkCard.tsx');
|
||||
exports.default = GuildPowerupsPerkCard;
|
||||
}
|
||||
|
||||
function GuildPowerupsPerkCard(a0) { // fn#110727, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14860:655, offset: 0x02384732, size: 872 bytes, params: 2, frame: 33
|
||||
const TextBadge = (require(1305) /* metro dependency 1305: native */).TextBadge;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const title = a0.title;
|
||||
const description = a0.description;
|
||||
const imageUrl = a0.imageUrl;
|
||||
let isImageAnimated = a0.isImageAnimated;
|
||||
isImageAnimated = isImageAnimated === undefined || isImageAnimated;
|
||||
const riveComponent = a0.riveComponent;
|
||||
const style = a0.style;
|
||||
const onPress = a0.onPress;
|
||||
const status = a0.status;
|
||||
const badge = a0.badge;
|
||||
const object2 = {'title': 0, 'description': 0, 'imageUrl': 0, 'isImageAnimated': 0, 'riveComponent': 0, 'style': 0,
|
||||
'onPress': 0, 'status': 0, 'badge': 0};
|
||||
silentSetPrototypeOf(object2, null, undefined);
|
||||
const value = copyDataProperties({}, a0, object2, undefined);
|
||||
const styles = useStyles();
|
||||
const value3 = (importDefault(4048) /* metro dependency 4048: useTheme */)();
|
||||
const sharedModule = require(4002) /* metro dependency 4002: shared */;
|
||||
const r12 = sharedModule.isThemeDark(value3) ? ['#0f101100', '#0f101166'] : ['#0f101100', '#0f10111a'];
|
||||
const GuildPowerupsCard = importDefault(14660) /* metro dependency 14660: GuildPowerupsCard */;
|
||||
const items3 = [styles.container, style];
|
||||
const items5 = [<View style={styles.imageContainer}>{riveComponent ?? ((Component) => <Component imageUrl={imageUrl ?? ''} isAnimated={isImageAnimated} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */)}{((Component) => <Component colors={r12} style={styles.gradient} />)(importDefault(4589) /* metro dependency 4589 */)}</View>];
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const view = <View style={styles.headerContainer}><Text variant="heading-md/bold">{title}</Text><Text variant="text-sm/medium">{description}</Text></View>;
|
||||
const GuildPowerupsCardFooter = (require(14644) /* metro dependency 14644: GuildPowerupsCardFooter */).GuildPowerupsCardFooter;
|
||||
items5[1] = <View style={styles.contentContainer}>{view}<GuildPowerupsCardFooter {...value} {...{['status']: status}} /></View>;
|
||||
items5[2] = badge === 'new' && <TextBadge text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.y2b7CA)} style={styles.badge} />;
|
||||
items5[3] = badge === 'beta' && <TextBadge text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.oW0eUd)} color={(require(1305) /* metro dependency 1305: native */).BadgeColors.BRAND} style={styles.badge} />;
|
||||
return (
|
||||
<GuildPowerupsCard
|
||||
containerStyle={items3}
|
||||
style={styles.card}
|
||||
status={status}
|
||||
onPress={onPress}
|
||||
>
|
||||
{items5}
|
||||
</GuildPowerupsCard>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
/* Metro module 14661; source: modules/premium/powerups/native/GuildPowerupsPerksSection.tsx; dependencies: [27, 33, 4501, 697, 14630, 1244, 2256, 14662, 14664, 14671, 2] */
|
||||
function _fun110721(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110721, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14858:6, offset: 0x02384127, size: 231 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
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.Fragment;
|
||||
const env0_6 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
const env0_7 = Reflect.apply(createStyles, value, [{container: {flexDirection: 'column', gap: PX_16}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsPerksSection.tsx');
|
||||
exports.default = GuildPowerupPerksSection;
|
||||
}
|
||||
|
||||
function GuildPowerupPerksSection({guildId, listings}) { // fn#110722, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14858:342, offset: 0x0238420e, size: 241 bytes, params: 2, frame: 28
|
||||
const styles = useStyles();
|
||||
const jsxRuntimeEnv0_5Binding = jsxRuntimeEnv0_5;
|
||||
const GuildPowerupsSectionHeader = importDefault(14630) /* metro dependency 14630: GuildPowerupsSectionHeader */;
|
||||
const object = {};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
const TV3Vm8 = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).TV3Vm8;
|
||||
object.title = Reflect.apply(string, intl, [TV3Vm8]);
|
||||
string = intl.string;
|
||||
const STx9hp = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).STx9hp;
|
||||
object.description = Reflect.apply(string, intl, [STx9hp]);
|
||||
return (
|
||||
<>
|
||||
<GuildPowerupsSectionHeader {...object} />
|
||||
<View style={styles.container}>
|
||||
{listings.map(_fun110723)}
|
||||
</View>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110723(a0, a1) { // fn#110723, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14858:574, offset: 0x023842ff, size: 295 bytes, params: 3, frame: 20
|
||||
var value;
|
||||
var object;
|
||||
var powerup;
|
||||
const type = a0.type;
|
||||
if (type === 'singlePerk') {
|
||||
value = environment.__proto__;
|
||||
value = importDefault(14662) /* metro dependency 14662: GuildPowerupsSinglePerkCard */;
|
||||
var valueProps = {guildId: guildId};
|
||||
powerup = a0.powerup;
|
||||
valueProps.powerup = powerup;
|
||||
valueProps.badge = a0.badge;
|
||||
powerup = a0.powerup;
|
||||
return ((Component) => <Component {...valueProps} key={powerup.skuId} />)(value);
|
||||
}
|
||||
if (type === 'multiPerk') {
|
||||
value = environment.__proto__;
|
||||
value = importDefault(14664) /* metro dependency 14664: GuildPowerupsMultiPerkCard */;
|
||||
return ((Component) => <Component guildId={guildId} listing={a0} key={'' + a0.group + '-' + a1} />)(value);
|
||||
}
|
||||
if (type === 'gameServer') {
|
||||
value = environment.__proto__;
|
||||
value = importDefault(14671) /* metro dependency 14671: GuildPowerupsGameServerCard */;
|
||||
return ((Component) => <Component guildId={guildId} key={'game-server-' + a1} />)(value);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,172 @@
|
||||
/* Metro module 14689; source: modules/premium/powerups/native/GuildPowerupsProgressBar.tsx; dependencies: [31, 27, 14690, 1867, 33, 697, 4017, 4589, 4501, 632, 14691, 14692, 4504, 14599, 6789, 1244, 2256, 8554, 4573, 6818, 2] */
|
||||
function _fun110832(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110832, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:6, offset: 0x02388c3a, size: 636 bytes, params: 8, frame: 26
|
||||
var object6;
|
||||
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 StyleSheet = value.StyleSheet;
|
||||
const env0_4 = value.View;
|
||||
const guildBoostingProgressBarPersistedStore = importDefault(14690) /* metro dependency 14690: GuildBoostingProgressBarPersistedStore */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_7 = value.jsx;
|
||||
const env0_8 = value.jsxs;
|
||||
let PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
value = 2 * PX_4;
|
||||
const env0_9 = ['rgba(255, 115, 250, 0.4)', 'rgba(255, 115, 250, 0.1)'];
|
||||
const env0_10 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).createAnimatedComponent(importDefault(4589) /* metro dependency 4589 */);
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
object6 = {};
|
||||
const object7 = {};
|
||||
PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object7.paddingVertical = PX_4;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object7.paddingHorizontal = PX_16;
|
||||
object6.container = object7;
|
||||
const object8 = {height: 30};
|
||||
object8.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
const BACKGROUND_MOD_NORMAL = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_NORMAL;
|
||||
object8.backgroundColor = BACKGROUND_MOD_NORMAL;
|
||||
object8.justifyContent = 'center';
|
||||
object6.track = object8;
|
||||
const object9 = {};
|
||||
copyDataProperties(object9, StyleSheet.absoluteFillObject, undefined);
|
||||
object9['padding'] = 2;
|
||||
object6.fillContainer = object9;
|
||||
const object10 = {'height': '100%', 'minWidth': 26, 'borderRadius': null, 'borderWidth': 1,
|
||||
'borderColor': 'rgba(255, 115, 250, 0.2)', 'overflow': 'hidden'};
|
||||
object10.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
object6.fill = object10;
|
||||
object6.fillShadow = {'shadowColor': 'rgba(0, 0, 0, 0.14)', 'shadowOffset': null, 'shadowOpacity': 1,
|
||||
'shadowRadius': 4, 'elevation': 2, shadowOffset: {'width': 0, 'height': 1}};
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object6.textContainer = {'flexDirection': 'row', 'justifyContent': 'space-between', 'alignItems': 'center',
|
||||
paddingHorizontal: PX_12};
|
||||
object6.rightContent = {'flexDirection': 'row', 'alignItems': 'center'};
|
||||
const env0_11 = Reflect.apply(createStyles, createStylesModule, [object6]);
|
||||
object6 = {code: 'function GuildPowerupsProgressBarTsx1(){const{animatedFillPercent,animatedFillOpacity}=this.__closure;return{width:animatedFillPercent.get()+"%",opacity:animatedFillOpacity.get()};}'};
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsProgressBar.tsx');
|
||||
exports.default = GuildPowerupsProgressBar;
|
||||
exports.BOOST_PROGRESS_BAR_HEIGHT = value + 30;
|
||||
}
|
||||
|
||||
function GuildPowerupsProgressBar({guildId}) { // fn#110833, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:1340, offset: 0x02388eb6, size: 1296 bytes, params: 2, frame: 32
|
||||
var object2;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let env0_3 = undefined;
|
||||
const styles = useStyles();
|
||||
const value3 = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildStore],
|
||||
function() {
|
||||
return GuildStore.getGuild(guildId);
|
||||
}, [guildId]);
|
||||
const value4 = (importDefault(14691) /* metro dependency 14691: useTotalPossibleBoostCount */)(value3);
|
||||
const value5 = (require(632) /* metro dependency 632: useStateFromStores */).useStateFromStores([GuildBoostingProgressBarPersistedStore],
|
||||
_fun110835, [guildId]);
|
||||
let r11 = value3?.premiumSubscriberCount ?? 0;
|
||||
let binding = env0_3;
|
||||
binding.useEffect(_fun110836, [guildId, value5, r11]);
|
||||
const r1 = value4 > 0 ? global.Math.min(value5 / value4 * 100, 100) : 0;
|
||||
env0_3 = r1;
|
||||
const value8 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(r1);
|
||||
const value10 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(r1 > 0 ? 1 : 0);
|
||||
binding = env0_3;
|
||||
binding.useEffect(_fun110837, [value8, value10, r1]);
|
||||
const reanimatedRexportModule = require(4017) /* metro dependency 4017: ReanimatedRexport */;
|
||||
const useAnimatedStyle = reanimatedRexportModule.useAnimatedStyle;
|
||||
const closure = GuildPowerupsProgressBarV;
|
||||
closure.__closure = {animatedFillPercent: value8, animatedFillOpacity: value10};
|
||||
closure.__workletHash = 6718232104000;
|
||||
closure.__initData = env0_12;
|
||||
const value11 = Reflect.apply(useAnimatedStyle, reanimatedRexportModule, [closure]);
|
||||
const value12 = binding.useCallback(_fun110840, [guildId]);
|
||||
const r18 = value5 >= value4 ? intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['Ehpq+7'],
|
||||
{appliedBoostCount: value5}) : intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['/rbPDs'],
|
||||
{appliedBoostCount: value5, maxBoostCount: value4});
|
||||
const PressableScale = (require(8554) /* metro dependency 8554: native */).PressableScale;
|
||||
object2 = {accessibilityRole: 'button'};
|
||||
const string = intl.string;
|
||||
const NI6Ihe = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).NI6Ihe;
|
||||
object2.accessibilityLabel = Reflect.apply(string, intl, [NI6Ihe]);
|
||||
object2.onPress = value12;
|
||||
object2.style = styles.container;
|
||||
const view = <View style={styles.fillContainer}>{((Component) => <Component style={[styles.fill, styles.fillShadow,
|
||||
value11]} colors={env0_9} useAngle angle={270} />)(env0_10)}</View>;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
r11 = r11 >= value4 ? '' + intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).NI6Ihe) + ' 🎉' : intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).NI6Ihe);
|
||||
const text = <Text variant="text-xs/semibold" color="text-default">{r11}</Text>;
|
||||
const text2 = <Text variant="text-xs/semibold" color="text-default" style={{opacity: 0.7}}>{r18}</Text>;
|
||||
const ChevronSmallRightIcon = (require(6818) /* metro dependency 6818: ChevronSmallRightIcon */).ChevronSmallRightIcon;
|
||||
const TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_DEFAULT;
|
||||
return (
|
||||
<PressableScale {...object2}>
|
||||
<View style={styles.track}>
|
||||
{view}
|
||||
<View style={styles.textContainer}>
|
||||
{text}
|
||||
<View style={styles.rightContent}>
|
||||
{text2}
|
||||
<ChevronSmallRightIcon size="sm" color={TEXT_DEFAULT} />
|
||||
</View>
|
||||
</View>
|
||||
</View>
|
||||
</PressableScale>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110835() { // fn#110835, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:1505, offset: 0x023893c6, size: 43 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildBoostingProgressBarPersistedStore.getCountForGuild(guildId) ?? 0;
|
||||
}
|
||||
|
||||
function _fun110836() { // fn#110836, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:1635, offset: 0x023893f1, size: 64 bytes, params: 1, frame: 13
|
||||
var value2;
|
||||
var moduleValue;
|
||||
if (env0_1 !== env0_2) {
|
||||
value2 = environment.__proto__;
|
||||
moduleValue = require(14692) /* metro dependency 14692: GuildBoostingProgressBarActionCreators */;
|
||||
moduleValue.updateGuildPremiumSubscriptionCount(guildId, env0_2);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110837() { // fn#110837, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:1817, offset: 0x02389431, size: 136 bytes, params: 1, frame: 22
|
||||
let binding = env0_4;
|
||||
let set = binding.set;
|
||||
const timingModule = require(4504) /* metro dependency 4504: timing */;
|
||||
let withTiming = timingModule.withTiming;
|
||||
Reflect.apply(set, binding, [Reflect.apply(withTiming, timingModule, [env0_3, {duration: 500}])]);
|
||||
binding = env0_5;
|
||||
set = binding.set;
|
||||
const moduleValue2 = timingModule;
|
||||
withTiming = moduleValue2.withTiming;
|
||||
const value = 0;
|
||||
Reflect.apply(set, binding, [Reflect.apply(withTiming, moduleValue2, [env0_3 > value ? 1 : value,
|
||||
{duration: 500}])]);
|
||||
return _fun110838;
|
||||
}
|
||||
|
||||
function GuildPowerupsProgressBarV() { // fn#110839, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:2026, owner: GuildPowerupsProgressBar.v, offset: 0x023894fe, size: 68 bytes, params: 1, frame: 15
|
||||
const object2 = {};
|
||||
object2.width = '' + env0_4.get() + '%';
|
||||
object2.opacity = env0_5.get();
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun110840() { // fn#110840, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:2192, offset: 0x02389542, size: 68 bytes, params: 1, frame: 14
|
||||
let value = environment.__proto__;
|
||||
value = importDefault(14599) /* metro dependency 14599: openGuildPowerupsModal */;
|
||||
const object2 = {};
|
||||
object2.guildId = guildId;
|
||||
const GUILD_BOOSTING_SIDEBAR_DISPLAY = (importDefault(6789) /* metro dependency 6789: AnalyticsLocation */).GUILD_BOOSTING_SIDEBAR_DISPLAY;
|
||||
object2.analyticsLocation = GUILD_BOOSTING_SIDEBAR_DISPLAY;
|
||||
value(object2);
|
||||
}
|
||||
|
||||
function _fun110838() { // fn#110838, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14886:1918, offset: 0x023894b9, size: 69 bytes, params: 1, frame: 16
|
||||
const value = environment.__proto__.__proto__;
|
||||
(require(4017) /* metro dependency 4017: ReanimatedRexport */).cancelAnimation(env1_4);
|
||||
(require(4017) /* metro dependency 4017: ReanimatedRexport */).cancelAnimation(env1_5);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,129 @@
|
||||
/* Metro module 14673; source: modules/premium/powerups/native/GuildPowerupsRecentActivitySection.tsx; dependencies: [27, 4502, 33, 4501, 697, 14674, 3826, 4788, 566, 8206, 7958, 14677, 12320, 1305, 4573, 14679, 14675, 1244, 2] */
|
||||
function _fun110761(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110761, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14870:6, offset: 0x02386227, size: 399 bytes, params: 8, frame: 23
|
||||
var object4;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_5 = value.jsx;
|
||||
const env0_6 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object4 = {};
|
||||
const object5 = {};
|
||||
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.marginTop = PX_16;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object5.paddingHorizontal = PX_16;
|
||||
object4.sectionContainer = object5;
|
||||
const object6 = {};
|
||||
const PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object6.gap = PX_12;
|
||||
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object6.marginTop = PX_16;
|
||||
object4.boostContainer = object6;
|
||||
object4.boostRowContainer = {'flexDirection': 'row', 'alignItems': 'center', 'gap': 8};
|
||||
object4.boostMessage = {'flex': 1, 'flexDirection': 'row', 'alignItems': 'center'};
|
||||
object4.username = {'maxWidth': 170, 'flexShrink': 1};
|
||||
object4.messageText = {flexShrink: 0};
|
||||
object4.timestamp = {flexShrink: 0};
|
||||
const env0_7 = Reflect.apply(createStyles, value, [object4]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsRecentActivitySection.tsx');
|
||||
exports.default = GuildPowerupsRecentActivitySection;
|
||||
}
|
||||
|
||||
function GuildPowerupsRecentActivityRow({row, isExpiringBoostsEnabled}) { // fn#110762, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14870:549, offset: 0x023863b6, size: 939 bytes, params: 2, frame: 34
|
||||
var r8;
|
||||
var r4;
|
||||
var moduleValue3;
|
||||
var calendarFormat;
|
||||
var Date;
|
||||
var value5;
|
||||
var date;
|
||||
var object;
|
||||
const boost = row.boost;
|
||||
const phase = row.phase;
|
||||
const sortKey = row.sortKey;
|
||||
const styles = useStyles();
|
||||
const {username, roleColor,
|
||||
roleColorStrings} = (require(14674) /* metro dependency 14674: useMaybeGetSortedBoosts */).useGetBoostUserConfig(boost);
|
||||
if (isExpiringBoostsEnabled) {
|
||||
moduleValue3 = require(3826) /* metro dependency 3826: DateUtils */;
|
||||
calendarFormat = moduleValue3.calendarFormat;
|
||||
Date = global.Date;
|
||||
value5 = Object.create(Date.prototype, {constructor: {value: Date}});
|
||||
date = new Date(sortKey);
|
||||
r8 = Reflect.apply(calendarFormat, moduleValue3, [date instanceof Object ? date : value5]);
|
||||
} else {
|
||||
r8 = (require(4788) /* metro dependency 4788: NotificationCenterUtils */).getRelativeTimestamp(sortKey, true);
|
||||
}
|
||||
const roleStyle = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.roleStyle;
|
||||
});
|
||||
const r21 = roleStyle !== 'username' ? {} : roleColor != null ? {color: roleColor} : {};
|
||||
const value8 = (require(8206) /* metro dependency 8206: EnhancedRoleColorUtils */).useProcessColorStringsArray(roleColorStrings);
|
||||
const enhancedRoleColorUtilsModule = require(8206) /* metro dependency 8206: EnhancedRoleColorUtils */;
|
||||
const useIsRoleStyleAndRoleColorsEligibleForERC = enhancedRoleColorUtilsModule.useIsRoleStyleAndRoleColorsEligibleForERC;
|
||||
const guildId = boost.guildId;
|
||||
const userId = boost.userId;
|
||||
const value9 = Reflect.apply(useIsRoleStyleAndRoleColorsEligibleForERC, enhancedRoleColorUtilsModule, [guildId,
|
||||
userId, roleStyle, value8]);
|
||||
const value10 = phase === 'gave';
|
||||
const r10 = value10 ? (require(7958) /* metro dependency 7958: BoostGemIcon */).BoostGemIcon : phase === 'expiring' ? (require(14677) /* metro dependency 14677: BoostTier1Icon */).BoostTier1Icon : (require(12320) /* metro dependency 12320: BoostGemSlashIcon */).BoostGemSlashIcon;
|
||||
if (value10) {
|
||||
object = {};
|
||||
object.color = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.GUILD_BOOSTING_PINK;
|
||||
object.size = 'sm';
|
||||
r4 = object;
|
||||
} else {
|
||||
r4 = {size: 'sm'};
|
||||
}
|
||||
const items3 = [((Component) => <Component {...r4} />)(r10)];
|
||||
const items2 = [roleStyle === 'dot' && roleColor != null && ((RoleDot) => <RoleDot size="small" color={roleColor} colors={roleColorStrings} />)((require(1305) /* metro dependency 1305: native */).RoleDot)];
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const username2 = styles.username;
|
||||
items2[1] = <Text variant="text-md/medium" color="interactive-text-active" lineClamp={1} style={[username2,
|
||||
r21]} gradientColors={value9 ? value8 : undefined}>{username}</Text>;
|
||||
items2[2] = <Text variant="text-md/medium" color="interactive-text-active">{' '}</Text>;
|
||||
items2[3] = <Text variant="text-md/medium" lineClamp={1} style={styles.messageText}>{(importDefault(14679) /* metro dependency 14679: getBoostRowMessageText */)(row)}</Text>;
|
||||
items3[1] = <View style={styles.boostMessage}>{items2}</View>;
|
||||
items3[2] = <Text variant="text-xs/semibold" style={styles.timestamp}>{r8}</Text>;
|
||||
return (
|
||||
<View style={styles.boostRowContainer}>
|
||||
{items3}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function GuildPowerupsRecentActivitySection({guildId}) { // fn#110764, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14870:1908, offset: 0x02386761, size: 296 bytes, params: 2, frame: 26
|
||||
var r0;
|
||||
var Text;
|
||||
var intl;
|
||||
const styles = useStyles();
|
||||
const value2 = (importDefault(14674) /* metro dependency 14674: useMaybeGetSortedBoosts */)(guildId, 10);
|
||||
const env0_0 = (require(14675) /* metro dependency 14675: ExpiringBoostsExperiment */).useExpiringBoostsEnabled('GuildPowerupsRecentActivity');
|
||||
if (value2.length === 0) {
|
||||
r0 = null;
|
||||
} else {
|
||||
var viewBindingProps = {style: styles.sectionContainer};
|
||||
Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
r0 = <View {...viewBindingProps}><Text variant="heading-lg/semibold" color="text-subtle">{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.yM9Krm)}</Text><View style={styles.boostContainer}>{value2.map(_fun110765)}</View></View>;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110765(a0) { // fn#110765, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14870:2285, offset: 0x02386889, size: 79 bytes, params: 2, frame: 16
|
||||
const value = environment.__proto__;
|
||||
return (
|
||||
<GuildPowerupsRecentActivityRow
|
||||
row={a0}
|
||||
isExpiringBoostsEnabled={env0_0}
|
||||
key={'boost-' + a0.boost.id}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
/* Metro module 14630; source: modules/premium/powerups/native/GuildPowerupsSectionHeader.tsx; dependencies: [27, 33, 4501, 697, 4573, 2] */
|
||||
function _fun110583(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110583, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14827:6, offset: 0x0237e08d, size: 210 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = (require(27) /* metro dependency 27 */).View;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_3 = value.jsx;
|
||||
const env0_4 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
const env0_5 = Reflect.apply(createStyles, value, [{headerContainer: {padding: PX_16}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsSectionHeader.tsx');
|
||||
exports.default = GuildPowerupsSectionHeader;
|
||||
}
|
||||
|
||||
function GuildPowerupsSectionHeader({title, description}) { // fn#110584, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14827:316, offset: 0x0237e15f, size: 159 bytes, params: 2, frame: 21
|
||||
const styles = useStyles();
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View style={styles.headerContainer}>
|
||||
<Text variant="heading-lg/semibold" accessibilityRole="header">
|
||||
{title}
|
||||
</Text>
|
||||
<Text variant="text-md/normal">
|
||||
{description}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
/* Metro module 14662; source: modules/premium/powerups/native/GuildPowerupsSinglePerkCard.tsx; dependencies: [31, 33, 14640, 14635, 14636, 14637, 14663, 2] */
|
||||
function _fun110724(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110724, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14859:6, offset: 0x02384426, size: 138 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(33) /* metro dependency 33 */).jsx;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsSinglePerkCard.tsx');
|
||||
exports.default = GuildPowerupsSinglePerkCard;
|
||||
}
|
||||
|
||||
function GuildPowerupsSinglePerkCard({guildId, powerup, badge}) { // fn#110725, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14859:225, offset: 0x023844b0, size: 209 bytes, params: 2, frame: 22
|
||||
return ((Component) => <Component title={powerup.title} description={powerup.description} cost={powerup.cost} imageUrl={(importDefault(14640) /* metro dependency 14640: useGetGuildPowerupBannerImage */)(powerup,
|
||||
true) ?? ''} status={(require(14636) /* metro dependency 14636: useCalculatePowerupCardStatus */).useCalculatePowerupCardStatus(powerup,
|
||||
(importDefault(14635) /* metro dependency 14635: usePowerupActiveStatus */)(guildId, powerup),
|
||||
false)} onPress={(importDefault(14637) /* metro dependency 14637: useGuildPowerupOnShowMore */)(guildId,
|
||||
powerup)} badge={badge} />)(importDefault(14663) /* metro dependency 14663: GuildPowerupsPerkCard */);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,81 @@
|
||||
/* Metro module 14627; source: modules/premium/powerups/native/GuildPowerupsWarning.tsx; dependencies: [31, 27, 33, 4501, 697, 14628, 7684, 4573, 2] */
|
||||
function _fun110567(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110567, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14824:6, offset: 0x0237d6a5, size: 440 bytes, params: 8, frame: 22
|
||||
var object3;
|
||||
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;
|
||||
object3 = {};
|
||||
const object4 = {'flexDirection': 'row', 'alignItems': 'flex-start', 'padding': null, 'backgroundColor': null,
|
||||
'borderWidth': 1};
|
||||
const PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object4.padding = PX_24;
|
||||
const BACKGROUND_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_FEEDBACK_WARNING;
|
||||
object4.backgroundColor = BACKGROUND_FEEDBACK_WARNING;
|
||||
const STATUS_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.STATUS_WARNING;
|
||||
object4.borderColor = STATUS_WARNING;
|
||||
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
|
||||
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object4.gap = PX_8;
|
||||
object4.overflow = 'hidden';
|
||||
object3.container = object4;
|
||||
let PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object3.contentContainer = {'flex': 1, 'gap': null, 'alignItems': 'center', gap: PX_4};
|
||||
PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object3.warningText = {marginTop: PX_4};
|
||||
object3.text = {textAlign: 'center'};
|
||||
const env0_6 = Reflect.apply(createStyles, value, [object3]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/GuildPowerupsWarning.tsx');
|
||||
exports.default = GuildPowerupsWarning;
|
||||
}
|
||||
|
||||
function GuildPowerupsWarning({guildId, powerupNames, warnings}) { // fn#110568, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14824:680, offset: 0x0237d85d, size: 362 bytes, params: 2, frame: 29
|
||||
var r0;
|
||||
var items2;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var text;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
const {shouldShow, title,
|
||||
description} = (importDefault(14628) /* metro dependency 14628: useGuildPowerupsWarningConfig */)(guildId,
|
||||
powerupNames);
|
||||
if (shouldShow) {
|
||||
var viewBindingProps = {style: styles.container};
|
||||
var viewBindingProps2 = {style: styles.contentContainer};
|
||||
const CircleErrorIcon = (require(7684) /* metro dependency 7684: CircleErrorIcon */).CircleErrorIcon;
|
||||
value = <CircleErrorIcon color={(importDefault(697) /* metro dependency 697: native */).colors.TEXT_FEEDBACK_WARNING} size="md" />;
|
||||
items2 = [value];
|
||||
text = styles.text;
|
||||
items2[1] = <Text variant="text-md/semibold" color="text-feedback-warning" style={text}>{title}</Text>;
|
||||
text = styles.text;
|
||||
items2[2] = <Text variant="text-sm/medium" style={text}>{description}</Text>;
|
||||
items2[3] = warnings?.map(_fun110569);
|
||||
value = <View {...viewBindingProps}><View {...viewBindingProps2}>{items2}</View></View>;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = null;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110569(a0, a1) { // fn#110569, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14824:1166, offset: 0x0237d9c7, size: 125 bytes, params: 3, frame: 17
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
const stylesBinding = styles;
|
||||
return (
|
||||
<Text
|
||||
variant="text-sm/medium"
|
||||
color="text-feedback-warning"
|
||||
style={[stylesBinding.warningText, stylesBinding.text]}
|
||||
key={'warning-' + a1}
|
||||
>
|
||||
{a0}
|
||||
</Text>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,185 @@
|
||||
/* Metro module 15964; source: modules/premium/powerups/native/RoleGradientPickerActionSheet.tsx; dependencies: [57, 31, 27, 15949, 33, 4501, 697, 1941, 1360, 4080, 13189, 6275, 6758, 1244, 4578, 4589, 13797, 5278, 673, 2] */
|
||||
function _fun123431(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#123431, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:6, offset: 0x0258cc87, size: 740 bytes, params: 8, frame: 24
|
||||
var object3;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_4 = importAll(31) /* metro dependency 31 */;
|
||||
let value = require(27) /* metro dependency 27 */;
|
||||
const env0_5 = value.View;
|
||||
const env0_6 = value.Pressable;
|
||||
value = require(15949) /* metro dependency 15949: EnhancedRoleColorConstants */;
|
||||
const env0_7 = value.DEFAULT_GRADIENT_ROLE_COLORS;
|
||||
const env0_8 = value.GRADIENT_PRESETS;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_9 = value.jsx;
|
||||
const env0_10 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
object3 = {};
|
||||
const object7 = {'paddingVertical': null, 'paddingHorizontal': null, 'flexGrow': 1, 'justifyContent': 'center',
|
||||
'alignItems': 'center'};
|
||||
let PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object7.paddingVertical = PX_12;
|
||||
PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
|
||||
object7.paddingHorizontal = PX_12;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object7.gap = PX_16;
|
||||
object3.body = object7;
|
||||
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.gradientContainer = {'display': 'flex', 'flexDirection': 'row', 'justifyContent': 'center',
|
||||
'alignItems': 'center', paddingHorizontal: PX_8};
|
||||
const object9 = {'left': null, 'right': null, 'position': 'absolute', 'display': 'flex', 'flexDirection': 'row',
|
||||
'justifyContent': 'space-between'};
|
||||
let PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object9.left = PX_24;
|
||||
PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
|
||||
object9.right = PX_24;
|
||||
object3.dropperContainer = object9;
|
||||
const object11 = {'borderColor': 'white', 'tintColor': 'white', 'padding': null, 'borderRadius': null,
|
||||
'borderWidth': 1};
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object11.padding = PX_8;
|
||||
object11.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
object3.dropper = object11;
|
||||
const object12 = {'height': 50, 'width': '100%'};
|
||||
object12.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
object3.gradient = object12;
|
||||
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
|
||||
object3.optionContainer = {'display': 'flex', 'flexDirection': 'row', 'gap': null, 'flexWrap': 'wrap',
|
||||
'alignItems': 'center', 'justifyContent': 'center', gap: PX_8};
|
||||
const object13 = {'width': 80, 'height': 50, 'borderRadius': null, 'overflow': 'hidden', 'padding': 2};
|
||||
object13.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
object3.pressable = object13;
|
||||
const BACKGROUND_BRAND = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BRAND;
|
||||
object3.selected = {borderWidth: 2, borderColor: BACKGROUND_BRAND};
|
||||
const object14 = {flex: 1};
|
||||
object14.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
object3.option = object14;
|
||||
const env0_11 = Reflect.apply(createStyles, value, [object3]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/RoleGradientPickerActionSheet.tsx');
|
||||
exports.default = RoleGradientPickerActionSheet;
|
||||
}
|
||||
|
||||
function RoleGradientPickerActionSheet({colors, onSelect}) { // fn#123432, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1354, offset: 0x0258cf6b, size: 957 bytes, params: 2, frame: 32
|
||||
var object2;
|
||||
let env0_3 = undefined;
|
||||
const styles = useStyles();
|
||||
let binding = undefined;
|
||||
const useState = binding.useState;
|
||||
const value3 = env0_3(Reflect.apply(useState, binding,
|
||||
[colors == null ? DEFAULT_GRADIENT_ROLE_COLORS : colors.secondary_color != null ? colors : DEFAULT_GRADIENT_ROLE_COLORS]),
|
||||
2);
|
||||
const property = value3[0];
|
||||
env0_3 = value3[1];
|
||||
const Object = global.Object;
|
||||
const values = Object.values;
|
||||
const enhancedRoleColorUtilsModule = require(1941) /* metro dependency 1941: EnhancedRoleColorUtils */;
|
||||
const value4 = Reflect.apply(values, Object,
|
||||
[enhancedRoleColorUtilsModule.extractColorStringsFromServerColors(property)]);
|
||||
const value5 = value4.filter((require(1360) /* metro dependency 1360: GlobalUtils */).isNotNullish);
|
||||
binding = undefined;
|
||||
const value6 = binding.useCallback(_fun123433, [property, onSelect]);
|
||||
const value7 = binding.useCallback(_fun123434, []);
|
||||
const value8 = binding.useCallback(_fun123435, [property, value7]);
|
||||
const value9 = binding.useCallback(_fun123437, [property, value7]);
|
||||
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
|
||||
object2 = {};
|
||||
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const string = intl.string;
|
||||
const XpWmJz = (require(1244) /* metro dependency 1244: indexNative */).t.XpWmJz;
|
||||
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
object2.header = <BottomSheetTitleHeader title={Reflect.apply(string, intl,
|
||||
[XpWmJz])} trailing={<Button variant="secondary" size="sm" text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t['R3BPH+'])} onPress={value6} />} />;
|
||||
const value10 = ((Component) => <Component style={styles.gradient} colors={value5} start={{'x': 0,
|
||||
'y': 0}} end={{'x': 1, 'y': 0}} />)(importDefault(4589) /* metro dependency 4589 */);
|
||||
const EyeDropperIcon = (require(13797) /* metro dependency 13797: EyeDropperIcon */).EyeDropperIcon;
|
||||
const items3 = [<View style={styles.gradientContainer}>{value10}<View style={styles.dropperContainer}><Pressable style={styles.dropper} onPress={value8}><EyeDropperIcon color="white" size="sm" /></Pressable><Pressable style={styles.dropper} onPress={value9}><EyeDropperIcon color="white" size="sm" /></Pressable></View></View>];
|
||||
items3[1] = <View style={styles.optionContainer}>{GRADIENT_PRESETS.map(_fun123439)}</View>;
|
||||
items3[2] = <Button text={intl.string((require(1244) /* metro dependency 1244: indexNative */).t.yBZMsQ)} onPress={onPress_123441} />;
|
||||
return (
|
||||
<BottomSheet {...object2}>
|
||||
<View style={styles.body}>
|
||||
{items3}
|
||||
</View>
|
||||
</BottomSheet>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun123433() { // fn#123433, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1610, offset: 0x0258d328, size: 53 bytes, params: 1, frame: 12
|
||||
onSelect(env0_2);
|
||||
const value = environment.__proto__;
|
||||
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
|
||||
}
|
||||
|
||||
function _fun123435() { // fn#123435, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1704, offset: 0x0258d35d, size: 97 bytes, params: 1, frame: 16
|
||||
var environment;
|
||||
let value = environment.__proto__;
|
||||
value = undefined;
|
||||
(importDefault(13189) /* metro dependency 13189: showCustomColorPickerActionSheet */)({color: (env0_2 == null ? value : env0_2.primary_color) ?? 0,
|
||||
onSelect: onSelect_123436}, 'stack');
|
||||
return value;
|
||||
}
|
||||
|
||||
function _fun123437() { // fn#123437, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1850, offset: 0x0258d3e7, size: 97 bytes, params: 1, frame: 16
|
||||
var environment;
|
||||
let value = environment.__proto__;
|
||||
value = undefined;
|
||||
(importDefault(13189) /* metro dependency 13189: showCustomColorPickerActionSheet */)({color: (env0_2 == null ? value : env0_2.secondary_color) ?? 0,
|
||||
onSelect: onSelect_123438}, 'stack');
|
||||
return value;
|
||||
}
|
||||
|
||||
function _fun123439(a0) { // fn#123439, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:2651, offset: 0x0258d471, size: 305 bytes, params: 2, frame: 24
|
||||
var environment;
|
||||
const env0_0 = a0;
|
||||
let value = environment.__proto__;
|
||||
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
|
||||
const pressableOpacityProps = {style: [styles.pressable,
|
||||
a0.start === env0_2.primary_color && a0.end === env0_2.secondary_color && styles.selected],
|
||||
onPress: onPress_123440};
|
||||
const defaultImport = importDefault(4589) /* metro dependency 4589 */;
|
||||
value = Reflect.apply((require(673) /* metro dependency 673: ColorUtils */).int2hex, value, [a0.start]);
|
||||
const items2 = [value];
|
||||
value = require(673) /* metro dependency 673: ColorUtils */;
|
||||
items2[1] = value.int2hex(a0.end);
|
||||
return (
|
||||
<PressableOpacity {...pressableOpacityProps} key={a0.name}>
|
||||
{((Component) => <Component style={styles.option} colors={items2} start={{'x': 0, 'y': 0}} end={{'x': 1,
|
||||
'y': 0}} />)(defaultImport)}
|
||||
</PressableOpacity>
|
||||
);
|
||||
}
|
||||
|
||||
function RoleGradientPickerActionSheetOnPress() { // fn#123441, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:3046, owner: RoleGradientPickerActionSheet.onPress, offset: 0x0258d5e2, size: 23 bytes, params: 1, frame: 11
|
||||
env0_3(DEFAULT_GRADIENT_ROLE_COLORS);
|
||||
}
|
||||
|
||||
function onSelect_123436(a0) { // fn#123436, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1785, offset: 0x0258d3be, size: 41 bytes, params: 2, frame: 13
|
||||
const binding = env1_4;
|
||||
const object2 = {};
|
||||
copyDataProperties(object2, env1_2, undefined);
|
||||
object2['primary_color'] = a0;
|
||||
return binding(object2);
|
||||
}
|
||||
|
||||
function onSelect_123438(a0) { // fn#123438, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:1933, offset: 0x0258d448, size: 41 bytes, params: 2, frame: 13
|
||||
const binding = env1_4;
|
||||
const object2 = {};
|
||||
copyDataProperties(object2, env1_2, undefined);
|
||||
object2['secondary_color'] = a0;
|
||||
return binding(object2);
|
||||
}
|
||||
|
||||
function onPress_123440() { // fn#123440, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16172:2776, offset: 0x0258d5a2, size: 64 bytes, params: 1, frame: 14
|
||||
const binding = env1_4;
|
||||
const object2 = {};
|
||||
copyDataProperties(object2, env1_2, undefined);
|
||||
const binding2 = env0_0;
|
||||
object2['primary_color'] = binding2.start;
|
||||
object2['secondary_color'] = binding2.end;
|
||||
return binding(object2);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
/* Metro module 14633; source: modules/premium/powerups/native/hooks/useGuildPowerupColorConfig.tsx; dependencies: [697, 2] */
|
||||
function _fun110606(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110606, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14830:6, offset: 0x0237f3eb, size: 99 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupColorConfig.tsx');
|
||||
exports.default = useGuildPowerupColorConfig;
|
||||
}
|
||||
|
||||
function useGuildPowerupColorConfig(a0) { // fn#110607, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14830:204, offset: 0x0237f44e, size: 120 bytes, params: 2, frame: 13
|
||||
const object2 = {};
|
||||
if (a0) {
|
||||
object2.textColor = 'text-default';
|
||||
object2.iconColor = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_DEFAULT;
|
||||
} else {
|
||||
object2.textColor = 'text-muted';
|
||||
object2.iconColor = (importDefault(697) /* metro dependency 697: native */).colors.TEXT_MUTED;
|
||||
}
|
||||
return object2;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
/* Metro module 14658; source: modules/premium/powerups/native/hooks/useGuildPowerupConfigureCallback.tsx; dependencies: [31, 661, 4080, 14638, 8188, 9112, 44, 2] */
|
||||
function _fun110714(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110714, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14855:6, offset: 0x02383a5c, size: 153 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 constantsModule = require(661) /* metro dependency 661: Constants */;
|
||||
const env0_4 = constantsModule.GuildSettingsSections;
|
||||
const env0_5 = constantsModule.AnalyticsSections;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupConfigureCallback.tsx');
|
||||
exports.default = useGuildPowerupConfigureCallback;
|
||||
}
|
||||
|
||||
function useGuildPowerupConfigureCallback(a0, a1) { // fn#110715, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14855:282, offset: 0x02383af5, size: 60 bytes, params: 3, frame: 15
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
return env0_3.useCallback(_fun110716, [a0, a1.skuId]);
|
||||
}
|
||||
|
||||
function _fun110716() { // fn#110716, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14855:351, offset: 0x02383b31, size: 214 bytes, params: 1, frame: 18
|
||||
var defaultImport2;
|
||||
const value = environment.__proto__;
|
||||
const defaultImport = importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */;
|
||||
const hideActionSheet = defaultImport.hideActionSheet;
|
||||
const GUILD_POWERUPS_BOTTOM_SHEET_KEY = (require(14638) /* metro dependency 14638: openGuildPowerupsBottomSheet */).GUILD_POWERUPS_BOTTOM_SHEET_KEY;
|
||||
Reflect.apply(hideActionSheet, defaultImport, [GUILD_POWERUPS_BOTTOM_SHEET_KEY]);
|
||||
const skuId = require.skuId;
|
||||
const GUILD_POWERUP_ROLE_COLOR_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_ROLE_COLOR_SKU_ID;
|
||||
if (skuId !== GUILD_POWERUP_ROLE_COLOR_SKU_ID) {
|
||||
(importDefault(44) /* metro dependency 44 */)(false, 'Unsupported powerup SKU ID: ' + require.skuId);
|
||||
} else {
|
||||
defaultImport2 = importDefault(9112) /* metro dependency 9112: GuildSettingsActionCreators */;
|
||||
defaultImport2.open(env0_0, GuildSettingsSections.ROLES, AnalyticsSections.GUILD_POWERUPS_OVERVIEW_CARD);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,113 @@
|
||||
/* Metro module 14650; source: modules/premium/powerups/native/hooks/useGuildPowerupOnActivate.tsx; dependencies: [31, 1867, 7020, 8259, 14651, 566, 14652, 6771, 12300, 8249, 4080, 14638, 6522, 7021, 5080, 7028, 2] */
|
||||
function _fun110670(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110670, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:6, offset: 0x023822f4, size: 185 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildBoostSlotStore = importDefault(7020) /* metro dependency 7020: GuildBoostSlotStore */;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_6 = guildPowerupsConstantsModule.BoostPurchaseIntent;
|
||||
const env0_7 = guildPowerupsConstantsModule.GuildPowerupType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupOnActivate.tsx');
|
||||
exports.default = useGuildPowerupOnActivate;
|
||||
}
|
||||
|
||||
function useGuildPowerupOnActivate(a0, a1) { // fn#110671, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:293, offset: 0x023823ad, size: 281 bytes, params: 3, frame: 23
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const {onToggle, isLoading,
|
||||
error} = (importDefault(14651) /* metro dependency 14651: useGuildPowerupOnToggle */)(a0, a1);
|
||||
const guild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110672);
|
||||
const env0_3 = guild;
|
||||
const value3 = (importDefault(14652) /* metro dependency 14652: useAvailableBoostCountForPowerup */)(a0, a1);
|
||||
const analyticsLocations = (importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */)().analyticsLocations;
|
||||
const {shouldUseMobileWebRedirectCheckout,
|
||||
handleMobileWebRedirectCheckout} = (importDefault(12300) /* metro dependency 12300: useGuildBoostPurchaseHandler */)('guild_powerup_activation');
|
||||
const binding = env0_3;
|
||||
const useCallback = binding.useCallback;
|
||||
return {onActivate: Reflect.apply(useCallback, binding, [_fun110673, [onToggle, a1, value3, guild,
|
||||
analyticsLocations, shouldUseMobileWebRedirectCheckout, handleMobileWebRedirectCheckout]]),
|
||||
isLoading: isLoading, error: error};
|
||||
}
|
||||
|
||||
function _fun110673() { // fn#110673, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:635, offset: 0x023824c6, size: 435 bytes, params: 1, frame: 28
|
||||
var environment;
|
||||
var r5;
|
||||
var value2;
|
||||
var value3;
|
||||
var moduleValue;
|
||||
var value4;
|
||||
var defaultImport;
|
||||
var moduleValue2;
|
||||
var object2;
|
||||
var moduleValue3;
|
||||
var openTransferModal;
|
||||
if (guild != null) {
|
||||
if (require != null) {
|
||||
if (env0_4 >= require.cost) {
|
||||
(function() {
|
||||
onToggle(true);
|
||||
})();
|
||||
} else {
|
||||
value2 = require.cost - env0_4;
|
||||
value3 = environment.__proto__;
|
||||
moduleValue = require(8249) /* metro dependency 8249: GuildBoostingUtils */;
|
||||
value4 = moduleValue.getAvailableGuildBoostSlots(GuildBoostSlotStore.boostSlots);
|
||||
r5 = require.type === GuildPowerupType.LEVEL ? BoostPurchaseIntent.LEVEL : BoostPurchaseIntent.PERK;
|
||||
defaultImport = importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */;
|
||||
defaultImport.hideActionSheet((require(14638) /* metro dependency 14638: openGuildPowerupsBottomSheet */).GUILD_POWERUPS_BOTTOM_SHEET_KEY);
|
||||
if (value4.length > 0) {
|
||||
moduleValue3 = require(6522) /* metro dependency 6522: BoostingActionCreators */;
|
||||
openTransferModal = moduleValue3.openTransferModal;
|
||||
object2 = {};
|
||||
object2.guildBoostSlots = value4.slice(0, value2);
|
||||
object2.guildId = guild.id;
|
||||
object2.intent = r5;
|
||||
object2.onResult = onResult;
|
||||
Reflect.apply(openTransferModal, moduleValue3, [object2]);
|
||||
} else if (shouldUseMobileWebRedirectCheckout) {
|
||||
handleMobileWebRedirectCheckout(analyticsLocations, guild.id);
|
||||
} else {
|
||||
moduleValue2 = require(7021) /* metro dependency 7021: GuildBoostPurchasingUtils */;
|
||||
moduleValue2.launchGuildBoostFlowOrAlert({'page': 'Guild Powerups',
|
||||
'section': 'Powerup Activation'},
|
||||
analyticsLocations, _fun110676, _fun110677, _fun110679);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function _fun110676() { // fn#110676, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:1133, offset: 0x02382679, size: 60 bytes, params: 1, frame: 14
|
||||
const defaultImport = importDefault(5080) /* metro dependency 5080: ModalActionCreators */;
|
||||
const popWithKey = defaultImport.popWithKey;
|
||||
const PREMIUM_KEY = (require(7028) /* metro dependency 7028: PremiumModal */).PREMIUM_KEY;
|
||||
return Reflect.apply(popWithKey, defaultImport, [PREMIUM_KEY]);
|
||||
}
|
||||
|
||||
function _fun110677() { // fn#110677, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:1181, offset: 0x023826b5, size: 164 bytes, params: 1, frame: 19
|
||||
var environment;
|
||||
var openTransferModal;
|
||||
var slice;
|
||||
var value4;
|
||||
let value = environment.__proto__.__proto__;
|
||||
const availableGuildBoostSlots = (require(8249) /* metro dependency 8249: GuildBoostingUtils */).getAvailableGuildBoostSlots(GuildBoostSlotStore.boostSlots);
|
||||
if (availableGuildBoostSlots.length >= env0_1) {
|
||||
value = require(6522) /* metro dependency 6522: BoostingActionCreators */;
|
||||
openTransferModal = value.openTransferModal;
|
||||
slice = availableGuildBoostSlots.slice;
|
||||
value4 = environment.__proto__;
|
||||
Reflect.apply(openTransferModal, value, [{guildBoostSlots: Reflect.apply(slice, availableGuildBoostSlots, [0,
|
||||
require.cost]), guildId: guild.id, intent: env0_2, onResult: onResult_110678}]);
|
||||
}
|
||||
}
|
||||
|
||||
function onResult_110678(a0) { // fn#110678, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14847:1348, offset: 0x02382759, size: 23 bytes, params: 2, frame: 9
|
||||
var value;
|
||||
if (a0) {
|
||||
value = environment.__proto__;
|
||||
activatePowerup();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
/* Metro module 14653; source: modules/premium/powerups/native/hooks/useGuildPowerupOnShowDeactivate.tsx; dependencies: [31, 33, 14654, 1962, 4497, 2] */
|
||||
function _fun110693(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110693, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14850:6, offset: 0x02382cb4, size: 157 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const value = importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const env0_4 = value.lazy(_fun110694);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupOnShowDeactivate.tsx');
|
||||
exports.default = useGuildPowerupOnShowDeactivate;
|
||||
}
|
||||
|
||||
function _fun110694() { // fn#110694, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14850:130, offset: 0x02382d51, size: 45 bytes, params: 1, frame: 13
|
||||
return require(dependencyMap[3])(dependencyMap[2], dependencyMap.paths);
|
||||
}
|
||||
|
||||
function useGuildPowerupOnShowDeactivate(a0, a1) { // fn#110695, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14850:275, offset: 0x02382d7e, size: 55 bytes, params: 3, frame: 15
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
return env0_2.useCallback(_fun110696, [a0, a1]);
|
||||
}
|
||||
|
||||
function _fun110696() { // fn#110696, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14850:343, offset: 0x02382db5, size: 81 bytes, params: 1, frame: 17
|
||||
const value = environment.__proto__;
|
||||
const useAlertStoreNativeModule = require(4497) /* metro dependency 4497: useAlertStoreNative */;
|
||||
useAlertStoreNativeModule.openAlert('guild-powerups-deactivate-alert',
|
||||
((Component) => <Component guildId={env0_0} powerup={require} />)(env1_4));
|
||||
}
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
/* Metro module 14637; source: modules/premium/powerups/native/hooks/useGuildPowerupOnShowMore.tsx; dependencies: [31, 14638, 2] */
|
||||
function _fun110621(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110621, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14834:6, offset: 0x0237ff1a, size: 117 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importAll(31) /* metro dependency 31 */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupOnShowMore.tsx');
|
||||
exports.default = useGuildPowerupOnShowMore;
|
||||
}
|
||||
|
||||
function useGuildPowerupOnShowMore(a0, a1) { // fn#110622, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14834:217, offset: 0x0237ff8f, size: 55 bytes, params: 3, frame: 15
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
return env0_2.useCallback(_fun110623, [a0, a1]);
|
||||
}
|
||||
|
||||
function _fun110623() { // fn#110623, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14834:279, offset: 0x0237ffc6, size: 66 bytes, params: 1, frame: 13
|
||||
var value2;
|
||||
if (require != null) {
|
||||
value2 = environment.__proto__;
|
||||
(importDefault(14638) /* metro dependency 14638: openGuildPowerupsBottomSheet */)({guildId: env0_0,
|
||||
powerup: require});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,360 @@
|
||||
/* Metro module 14681; source: modules/premium/powerups/native/hooks/useGuildPowerupsCoachmark.tsx; dependencies: [31, 4502, 1867, 8259, 1376, 482, 33, 4501, 697, 566, 4048, 14599, 14598, 14641, 1244, 2256, 14643, 14682, 14640, 8188, 14683, 14684, 14685, 14667, 14686, 8543, 2] */
|
||||
function _fun110802(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110802, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:6, offset: 0x023877c7, size: 283 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const guildStore = importDefault(1867) /* metro dependency 1867: GuildStore */;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const env0_6 = guildPowerupsConstantsModule.GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET;
|
||||
const env0_7 = guildPowerupsConstantsModule.GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET;
|
||||
const env0_8 = (require(1376) /* metro dependency 1376: DismissibleContentConstants */).ContentDismissActionType;
|
||||
const env0_9 = (require(482) /* metro dependency 482: Constants */).ThemeTypes;
|
||||
const env0_10 = (require(33) /* metro dependency 33 */).jsx;
|
||||
const env0_11 = (require(4501) /* metro dependency 4501: createStyles */).createStyles(_fun110803);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/useGuildPowerupsCoachmark.tsx');
|
||||
exports.default = useGuildPowerupsCoachmark;
|
||||
}
|
||||
|
||||
function _fun110803(a0) { // fn#110803, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:322, offset: 0x023878e2, size: 164 bytes, params: 2, frame: 17
|
||||
const object = {height: 120};
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object.width = 260 - 2 * PX_16;
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
|
||||
const LIGHT = ThemeTypes.LIGHT;
|
||||
return {coachmarkImage: object, coachmarkCover: {resizeMode: 'cover'}, boostGemBackground: {'width': 50,
|
||||
'height': 50, backgroundColor: a0 !== LIGHT ? '#0000003D' : '#0000001A'}};
|
||||
}
|
||||
|
||||
function useGuildPowerupsCoachmark(a0, a1, a2) { // fn#110804, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:661, offset: 0x02387986, size: 235 bytes, params: 4, frame: 23
|
||||
const env0_0 = a1;
|
||||
const env0_1 = a2;
|
||||
const value2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildStore], _fun110805, [a1]);
|
||||
const styles = useStyles((importDefault(4048) /* metro dependency 4048: useTheme */)());
|
||||
const env0_3 = styles;
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
const binding = env0_3;
|
||||
const useMemo = binding.useMemo;
|
||||
(require(8543) /* metro dependency 8543: useCoachmarkNative */).useCoachmark(a0, Reflect.apply(useMemo, binding,
|
||||
[_fun110807, [a1, value2, a2, styles, useReducedMotion]]));
|
||||
}
|
||||
|
||||
function _fun110805() { // fn#110805, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:741, offset: 0x02387a71, size: 43 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildStore.getGuild(require)?.name;
|
||||
}
|
||||
|
||||
function _fun110807() { // fn#110807, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:896, offset: 0x02387a9c, size: 2759 bytes, params: 1, frame: 30
|
||||
var r6;
|
||||
var r9;
|
||||
var powerups;
|
||||
var value4;
|
||||
var object7;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
var object8;
|
||||
var object13;
|
||||
var object14;
|
||||
var object15;
|
||||
var title;
|
||||
var length;
|
||||
var formatToPlainString;
|
||||
var property;
|
||||
var object16;
|
||||
var object17;
|
||||
var object18;
|
||||
var object19;
|
||||
var powerup;
|
||||
const object20 = {'title': '', 'description': '', 'position': 'bottom', 'visible': false};
|
||||
let value = '';
|
||||
object20.onDismiss = function() {
|
||||
};
|
||||
if (importDefault != null) {
|
||||
var closure = function() {
|
||||
importDefault.markAsDismissed(ContentDismissActionType.TAKE_ACTION);
|
||||
importDefault(dependencyMap[11])({guildId: require});
|
||||
};
|
||||
var closure2 = function() {
|
||||
importDefault.markAsDismissed(ContentDismissActionType.USER_DISMISS);
|
||||
};
|
||||
var type = importDefault.type;
|
||||
var GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var LEVEL_REACHED = GuildPowerupNotificationPopoutType.LEVEL_REACHED;
|
||||
if (LEVEL_REACHED === type) {
|
||||
object19 = {};
|
||||
copyDataProperties(object19, object20, undefined);
|
||||
object19['visible'] = true;
|
||||
object19['renderImgComponent'] = renderImgComponent_110811;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['Zg/m9K'];
|
||||
powerup = importDefault.powerup;
|
||||
title = powerup.title;
|
||||
value = Reflect.apply(formatToPlainString, intl, [property, {perkName: title}]);
|
||||
object19['title'] = value;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['1EGXSK'];
|
||||
powerup = importDefault.powerup;
|
||||
title = powerup.title;
|
||||
value = Reflect.apply(formatToPlainString, intl, [property, {perkName: title}]);
|
||||
object19['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object19['buttonLabel'] = value;
|
||||
object19['buttonVariant'] = 'primary';
|
||||
object19['onButtonPress'] = closure;
|
||||
object19['onDismiss'] = closure2;
|
||||
return object19;
|
||||
}
|
||||
GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var PERKS_AVAILABLE = GuildPowerupNotificationPopoutType.PERKS_AVAILABLE;
|
||||
if (PERKS_AVAILABLE === type) {
|
||||
object18 = {};
|
||||
copyDataProperties(object18, object20, undefined);
|
||||
object18['visible'] = true;
|
||||
object18['renderImgComponent'] = renderImgComponent_110812;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).QpQBPQ);
|
||||
object18['title'] = value;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['6hn0xF']);
|
||||
object18['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object18['buttonLabel'] = value;
|
||||
object18['buttonVariant'] = 'primary';
|
||||
object18['onButtonPress'] = closure;
|
||||
object18['onDismiss'] = closure2;
|
||||
return object18;
|
||||
}
|
||||
GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var PERKS_PURCHASABLE = GuildPowerupNotificationPopoutType.PERKS_PURCHASABLE;
|
||||
if (PERKS_PURCHASABLE === type) {
|
||||
powerups = importDefault.powerups;
|
||||
length = powerups.length;
|
||||
if (length === 0) {
|
||||
return object20;
|
||||
}
|
||||
length = powerups.length;
|
||||
if (length >= 3) {
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
property = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['6Sv+3M'];
|
||||
object16 = {};
|
||||
title = powerups[0].title;
|
||||
object16.perk = title;
|
||||
title = powerups[1].title;
|
||||
object16.perk2 = title;
|
||||
title = powerups[2].title;
|
||||
object16.perk3 = title;
|
||||
r9 = Reflect.apply(formatToPlainString, intl, [property, object16]);
|
||||
} else {
|
||||
r9 = powerups.length === 2 ? intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).wcQOqC,
|
||||
|
||||
|
||||
|
||||
{perks: value + powerups[0].title + ' & ' + powerups[1].title}) : intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).ZF8NT6,
|
||||
|
||||
|
||||
|
||||
{perk: powerups[0].title});
|
||||
}
|
||||
object17 = {};
|
||||
copyDataProperties(object17, object20, undefined);
|
||||
object17['visible'] = true;
|
||||
object17['renderImgComponent'] = renderImgComponent_110813;
|
||||
value = intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).LmpChE,
|
||||
|
||||
|
||||
{guildName: env0_2 ?? value});
|
||||
object17['title'] = value;
|
||||
object17['description'] = r9;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object17['buttonLabel'] = value;
|
||||
object17['buttonVariant'] = 'primary';
|
||||
object17['onButtonPress'] = closure;
|
||||
object17['onDismiss'] = closure2;
|
||||
return object17;
|
||||
}
|
||||
GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var NEW_PERK_AVAILABLE = GuildPowerupNotificationPopoutType.NEW_PERK_AVAILABLE;
|
||||
if (NEW_PERK_AVAILABLE === type) {
|
||||
powerups = importDefault.powerups;
|
||||
value4 = powerups.find(function({skuId}) {
|
||||
return skuId === require(dependencyMap[19]).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
});
|
||||
if (value4 != null) {
|
||||
object15 = {};
|
||||
copyDataProperties(object15, object20, undefined);
|
||||
object15['visible'] = true;
|
||||
object15['renderImgComponent'] = renderImgComponent_110815;
|
||||
object15['title'] = value4.title;
|
||||
object15['description'] = typeof value4.description !== 'string' ? value : value4.description;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object15['buttonLabel'] = value;
|
||||
object15['buttonVariant'] = 'primary';
|
||||
object15['onButtonPress'] = closure;
|
||||
object15['onDismiss'] = closure2;
|
||||
r6 = object15;
|
||||
} else if (powerups.find(_fun110816) != null) {
|
||||
object14 = {};
|
||||
copyDataProperties(object14, object20, undefined);
|
||||
object14['visible'] = true;
|
||||
object14['renderImgComponent'] = renderImgComponent_110817;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).Ygpx4Q);
|
||||
object14['title'] = value;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).mmNkUA);
|
||||
object14['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object14['buttonLabel'] = value;
|
||||
object14['buttonVariant'] = 'primary';
|
||||
object14['onButtonPress'] = closure;
|
||||
object14['onDismiss'] = closure2;
|
||||
r6 = object14;
|
||||
} else if (powerups.find(_fun110818) != null) {
|
||||
object13 = {};
|
||||
copyDataProperties(object13, object20, undefined);
|
||||
object13['visible'] = true;
|
||||
object13['renderImgComponent'] = renderImgComponent_110819;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['kA2c+n']);
|
||||
object13['title'] = value;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).TUilLj);
|
||||
object13['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object13['buttonLabel'] = value;
|
||||
object13['buttonVariant'] = 'primary';
|
||||
object13['onButtonPress'] = closure;
|
||||
object13['onDismiss'] = closure2;
|
||||
r6 = object13;
|
||||
} else if (powerups.find(_fun110820) != null) {
|
||||
object8 = {};
|
||||
copyDataProperties(object8, object20, undefined);
|
||||
object8['visible'] = true;
|
||||
object8['renderImgComponent'] = renderImgComponent_110821;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['kA2c+n']);
|
||||
object8['title'] = value;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).TUilLj);
|
||||
object8['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object8['buttonLabel'] = value;
|
||||
object8['buttonVariant'] = 'primary';
|
||||
object8['onButtonPress'] = closure;
|
||||
object8['onDismiss'] = closure2;
|
||||
r6 = object8;
|
||||
} else if (powerups.find(_fun110822) == null) {
|
||||
r6 = object20;
|
||||
} else {
|
||||
object7 = {};
|
||||
copyDataProperties(object7, object20, undefined);
|
||||
object7['visible'] = true;
|
||||
object7['renderImgComponent'] = renderImgComponent_110823;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).rp0Ff1);
|
||||
object7['title'] = value;
|
||||
value = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['3L/DZq']);
|
||||
object7['description'] = value;
|
||||
value = intl.string(t.RzWDqY);
|
||||
object7['buttonLabel'] = value;
|
||||
object7['buttonVariant'] = 'primary';
|
||||
object7['onButtonPress'] = closure;
|
||||
object7['onDismiss'] = closure2;
|
||||
r6 = object7;
|
||||
}
|
||||
return r6;
|
||||
}
|
||||
GuildPowerupNotificationPopoutType = (require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType;
|
||||
var GAME_SERVER_HOSTING_AVAILABLE = GuildPowerupNotificationPopoutType.GAME_SERVER_HOSTING_AVAILABLE;
|
||||
if (GAME_SERVER_HOSTING_AVAILABLE !== type) {
|
||||
if ((require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType.GAME_SERVER_HOSTING_GUILD_ELIGIBLE !== type) {
|
||||
(require(14598) /* metro dependency 14598: GuildPowerupsNotification */).GuildPowerupNotificationPopoutType.GAME_SERVER_HOSTING_ENABLED;
|
||||
}
|
||||
}
|
||||
}
|
||||
return object20;
|
||||
}
|
||||
|
||||
function renderImgComponent_110811() { // fn#110811, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:1264, offset: 0x023885cc, size: 70 bytes, params: 1, frame: 14
|
||||
const value = environment.__proto__.__proto__;
|
||||
return ((Component) => <Component style={styles.boostGemBackground} gemWidth={30} gemHeight={30} />)(importDefault(14641) /* metro dependency 14641: GuildPowerupsBoostGem */);
|
||||
}
|
||||
|
||||
function renderImgComponent_110813() { // fn#110813, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:2502, offset: 0x02388612, size: 206 bytes, params: 1, frame: 22
|
||||
var r6;
|
||||
var getGuildPowerupBannerImage;
|
||||
var property;
|
||||
var value3;
|
||||
let value = environment.__proto__.__proto__;
|
||||
const GuildPowerupsImage = importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */;
|
||||
let length = powerups.length;
|
||||
if (length > 1) {
|
||||
r6 = importDefault(14682) /* metro dependency 14682: level_backgroundPng */;
|
||||
} else {
|
||||
value = require(14640) /* metro dependency 14640: useGetGuildPowerupBannerImage */;
|
||||
getGuildPowerupBannerImage = value.getGuildPowerupBannerImage;
|
||||
property = powerups[0];
|
||||
value3 = environment.__proto__;
|
||||
value = Reflect.apply(getGuildPowerupBannerImage, value, [property, useReducedMotion, true]);
|
||||
r6 = value ?? '';
|
||||
}
|
||||
length = powerups.length;
|
||||
value = environment.__proto__;
|
||||
const stylesBinding = styles;
|
||||
return (
|
||||
<GuildPowerupsImage
|
||||
imageUrl={r6}
|
||||
isAnimated={length === 1}
|
||||
style={[stylesBinding.coachmarkImage, stylesBinding.coachmarkCover]}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function renderImgComponent_110815() { // fn#110815, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:3124, offset: 0x0238870d, size: 159 bytes, params: 1, frame: 21
|
||||
const value = environment.__proto__.__proto__;
|
||||
const GuildPowerupsImage = importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */;
|
||||
const r5 = (require(14640) /* metro dependency 14640: useGetGuildPowerupBannerImage */).getGuildPowerupBannerImage(env0_1,
|
||||
useReducedMotion, true) ?? (importDefault(14683) /* metro dependency 14683: serverThemePowerupStaticPng */);
|
||||
const stylesBinding = styles;
|
||||
return (
|
||||
<GuildPowerupsImage
|
||||
imageUrl={r5}
|
||||
isAnimated={!useReducedMotion}
|
||||
style={[stylesBinding.coachmarkImage, stylesBinding.coachmarkCover]}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun110816({skuId}) { // fn#110816, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:3508, offset: 0x023887ac, size: 45 bytes, params: 2, frame: 12
|
||||
const VANITY_URL_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).VANITY_URL_POWERUP_SKU_ID;
|
||||
return skuId === VANITY_URL_POWERUP_SKU_ID;
|
||||
}
|
||||
|
||||
function renderImgComponent_110817() { // fn#110817, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:3594, offset: 0x023887d9, size: 73 bytes, params: 1, frame: 16
|
||||
const value = environment.__proto__.__proto__;
|
||||
return ((Component) => <Component imageUrl={importDefault(14684) /* metro dependency 14684: vanity_url_powerup_2xGif */} style={styles.coachmarkImage} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */);
|
||||
}
|
||||
|
||||
function _fun110818({skuId}) { // fn#110818, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:3894, offset: 0x02388822, size: 27 bytes, params: 2, frame: 11
|
||||
return GUILD_TAG_BADGE_PACKS_WAVE_TWO_SKU_ID_SET.has(skuId);
|
||||
}
|
||||
|
||||
function renderImgComponent_110819() { // fn#110819, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:3950, offset: 0x0238883d, size: 73 bytes, params: 1, frame: 16
|
||||
const value = environment.__proto__.__proto__;
|
||||
return ((Component) => <Component imageUrl={importDefault(14685) /* metro dependency 14685: guild_tag_badge_packs_wave_two_powerup_2xPng */} style={styles.coachmarkImage} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */);
|
||||
}
|
||||
|
||||
function _fun110820({skuId}) { // fn#110820, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:4253, offset: 0x02388886, size: 27 bytes, params: 2, frame: 11
|
||||
return GUILD_TAG_BADGE_PACKS_WAVE_ONE_SKU_ID_SET.has(skuId);
|
||||
}
|
||||
|
||||
function renderImgComponent_110821() { // fn#110821, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:4309, offset: 0x023888a1, size: 73 bytes, params: 1, frame: 16
|
||||
const value = environment.__proto__.__proto__;
|
||||
return ((Component) => <Component imageUrl={importDefault(14667) /* metro dependency 14667: groupAnimatedPng */} style={styles.coachmarkImage} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */);
|
||||
}
|
||||
|
||||
function _fun110822({skuId}) { // fn#110822, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:4612, offset: 0x023888ea, size: 45 bytes, params: 2, frame: 12
|
||||
const GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID;
|
||||
return skuId === GUILD_POWERUP_MAX_FILE_SIZE_250_MB_SKU_ID;
|
||||
}
|
||||
|
||||
function renderImgComponent_110823() { // fn#110823, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14878:4714, offset: 0x02388917, size: 80 bytes, params: 1, frame: 16
|
||||
const value = environment.__proto__.__proto__;
|
||||
return ((Component) => <Component imageUrl={importDefault(14686) /* metro dependency 14686: fileUploadStatic2xPng */} isAnimated={false} style={styles.coachmarkImage} />)(importDefault(14643) /* metro dependency 14643: GuildPowerupsImage */);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,47 @@
|
||||
/* Metro module 14665; source: modules/premium/powerups/native/hooks/usePowerupGroupConfig.tsx; dependencies: [31, 8258, 566, 8188, 1244, 2256, 14666, 14667, 1360, 2] */
|
||||
function _fun110732(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110732, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14862:6, offset: 0x02384caf, size: 137 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/hooks/usePowerupGroupConfig.tsx');
|
||||
exports.default = usePowerupGroupConfig;
|
||||
}
|
||||
|
||||
function usePowerupGroupConfig(a0, a1) { // fn#110733, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14862:223, offset: 0x02384d38, size: 156 bytes, params: 3, frame: 19
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = undefined;
|
||||
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore], _fun110734);
|
||||
return env0_3.useMemo(_fun110735, [a1,
|
||||
(value3 == null ? value2 : value3[(require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_TAG_SKU_ID]) != null]);
|
||||
}
|
||||
|
||||
function _fun110734() { // fn#110734, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14862:297, offset: 0x02384dd4, size: 44 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return GuildPowerupsStore.getStateForGuild(env0_0)?.unlockedPowerups;
|
||||
}
|
||||
|
||||
function _fun110735() { // fn#110735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14862:455, offset: 0x02384e00, size: 308 bytes, params: 1, frame: 20
|
||||
var object2;
|
||||
var value3;
|
||||
var value4;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
if (require.group === 'guildTagsBadgePacks') {
|
||||
object2 = {};
|
||||
value3 = environment.__proto__;
|
||||
value4 = undefined;
|
||||
object2.title = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).KC9HRW);
|
||||
object2.description = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).GJiSmP);
|
||||
object2.image = {staticUrl: importDefault(14666) /* metro dependency 14666: groupStaticPng */,
|
||||
animatedUrl: importDefault(14667) /* metro dependency 14667: groupAnimatedPng */};
|
||||
object2.disabledReason = result ? value4 : intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).lvk1Gc);
|
||||
object2.badge = value4;
|
||||
object2.forceStaticImages = true;
|
||||
return object2;
|
||||
}
|
||||
const globalUtilsModule = require(1360) /* metro dependency 1360: GlobalUtils */;
|
||||
globalUtilsModule.assertNever(require.group);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
/* Metro module 14642; source: modules/premium/powerups/native/images/BoostGem.tsx; dependencies: [31, 33, 7744, 2] */
|
||||
function _fun110641(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110641, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14839:6, offset: 0x02380f8d, 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/premium/powerups/native/images/BoostGem.tsx');
|
||||
exports.default = BoostGem;
|
||||
}
|
||||
|
||||
function BoostGem({width, height, style}) { // fn#110642, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14839:226, offset: 0x02381020, size: 353 bytes, params: 2, frame: 20
|
||||
width = width === undefined ? 39 : width;
|
||||
height = height === undefined ? 66 : height;
|
||||
const defaultImport = importDefault(7744) /* metro dependency 7744 */;
|
||||
const Path = (require(7744) /* metro dependency 7744 */).Path;
|
||||
const items2 = [<Path d="M19.3146 0L0 19.4029V46.6865L19.3146 65.9999L38.6293 46.5969V19.388L19.3146 0ZM28.972 42.6566L19.3146 52.3432L9.65732 42.6566V23.388L19.3146 13.6865L28.972 23.388V42.6566Z" fill="#FA6EF6" />];
|
||||
items2[1] = <Path d="M19.3145 0V13.6316L28.9718 23.2941L38.6291 19.3102L19.3145 0Z" fill="#FFADFB" />;
|
||||
items2[2] = <Path d="M9.65732 42.7056L0 46.7269L19.3146 65.9996V52.3419L9.65732 42.7056Z" fill="#E655D4" />;
|
||||
items2[3] = <Path d="M9.65723 23.3317V42.6835L19.3145 52.4118L28.9719 42.6835V23.3317L19.3145 13.5884L9.65723 23.3317Z" fill="#FFCFF9" />;
|
||||
items2[4] = <Path d="M28.9719 23.1273L9.74637 42.7058H9.65723V37.3827L26.3273 20.3823L28.9719 23.1273Z" fill="white" />;
|
||||
items2[5] = <Path d="M28.9717 31.0586V36.3917L16.1689 49.4997L13.52 46.6984L28.9717 31.0586Z" fill="white" />;
|
||||
return ((Component) => <Component width={width} height={height} viewBox="0 0 39 66" fill="none" style={style}>{items2}</Component>)(defaultImport);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/* Metro module 14638; source: modules/premium/powerups/native/utils/openGuildPowerupsBottomSheet.tsx; dependencies: [4080, 14639, 1962, 2] */
|
||||
function _fun110624(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110624, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14835:6, offset: 0x02380008, size: 113 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/utils/openGuildPowerupsBottomSheet.tsx');
|
||||
exports.default = openGuildPowerupsBottomSheet;
|
||||
exports.GUILD_POWERUPS_BOTTOM_SHEET_KEY = 'GUILD_POWERUPS_BOTTOM_SHEET_KEY';
|
||||
}
|
||||
|
||||
function openGuildPowerupsBottomSheet(a0) { // fn#110625, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14835:246, offset: 0x02380079, size: 80 bytes, params: 2, frame: 16
|
||||
const defaultImport = importDefault(dependencyMap[0]);
|
||||
const openLazy = defaultImport.openLazy;
|
||||
let value = require(dependencyMap[2]);
|
||||
value = value(dependencyMap[1], dependencyMap.paths);
|
||||
Reflect.apply(openLazy, defaultImport, [value, 'GUILD_POWERUPS_BOTTOM_SHEET_KEY', a0]);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
/* Metro module 14599; source: modules/premium/powerups/native/utils/openGuildPowerupsModal.tsx; dependencies: [5080, 14600, 1962, 2] */
|
||||
function _fun110378(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110378, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14796:6, offset: 0x023774cd, size: 103 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/utils/openGuildPowerupsModal.tsx');
|
||||
exports.default = function(a0) {
|
||||
var navigationParams = a0.navigationParams;
|
||||
var value = Object.create(null);
|
||||
value.navigationParams = 0;
|
||||
value = copyDataProperties({}, a0, value, navigationParams);
|
||||
importDefault(dependencyMap[0]).pushLazy(require(dependencyMap[2])(dependencyMap[1], dependencyMap.paths),
|
||||
value,
|
||||
'guild_powerups_modal_key', navigationParams);
|
||||
};
|
||||
}
|
||||
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
/* Metro module 14669; source: modules/premium/powerups/native/utils/openGuildPowerupsMultiPerkBottomSheet.tsx; dependencies: [4080, 14670, 1962, 14638, 2] */
|
||||
function _fun110745(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110745, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14866:6, offset: 0x0238530a, size: 103 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/native/utils/openGuildPowerupsMultiPerkBottomSheet.tsx');
|
||||
exports.default = openGuildPowerupsMultiPerkBottomSheet;
|
||||
}
|
||||
|
||||
function openGuildPowerupsMultiPerkBottomSheet(a0) { // fn#110746, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14866:215, offset: 0x02385371, size: 94 bytes, params: 2, frame: 18
|
||||
const defaultImport = importDefault(dependencyMap[0]);
|
||||
const openLazy = defaultImport.openLazy;
|
||||
let value = require(dependencyMap[2]);
|
||||
value = value(dependencyMap[1], dependencyMap.paths);
|
||||
const GUILD_POWERUPS_BOTTOM_SHEET_KEY = require(dependencyMap[3]).GUILD_POWERUPS_BOTTOM_SHEET_KEY;
|
||||
Reflect.apply(openLazy, defaultImport, [value, GUILD_POWERUPS_BOTTOM_SHEET_KEY, a0]);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/* Metro module 14645; source: modules/premium/powerups/utils/entitlementExpirationDateToString.tsx; dependencies: [1949, 2] */
|
||||
function _fun110653(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110653, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14842:6, offset: 0x02381976, size: 106 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const localeStore = importDefault(1949) /* metro dependency 1949: LocaleStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/entitlementExpirationDateToString.tsx');
|
||||
exports.default = function(a0) {
|
||||
return new global.Date(a0).toLocaleDateString(LocaleStore.locale, {'month': '2-digit', 'day': '2-digit'});
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,42 @@
|
||||
/* Metro module 14676; source: modules/premium/powerups/utils/getBoostLifecyclePhase.tsx; dependencies: [21, 2] */
|
||||
function _fun110786(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110786, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14873:6, offset: 0x023870a1, size: 135 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getBoostLifecyclePhase.tsx');
|
||||
exports.BOOST_EXPIRING_DISPLAY_WINDOW_DAYS = 3;
|
||||
exports.BOOST_EXPIRING_DISPLAY_WINDOW_MS = 259200000;
|
||||
exports.getBoostLifecycleInfo = getBoostLifecycleInfo;
|
||||
exports.getBoostLifecycleTimestamp = getBoostLifecycleTimestamp;
|
||||
}
|
||||
|
||||
function getBoostLifecycleInfo(a0, a1) { // fn#110787, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14873:296, offset: 0x02387128, size: 149 bytes, params: 3, frame: 12
|
||||
return a0.ended ? {phase: 'expired'} : a0.endsAt == null ? a0.endsAt == null ? {phase: 'gave'} : a0.endsAt.getTime() - a1 <= 259200000 ? {phase: 'expiring',
|
||||
endsAt: a0.endsAt} : {phase: 'gave'} : a0.endsAt.getTime() <= a1 ? {phase: 'expired'} : a0.endsAt == null ? {phase: 'gave'} : a0.endsAt.getTime() - a1 <= 259200000 ? {phase: 'expiring',
|
||||
endsAt: a0.endsAt} : {phase: 'gave'};
|
||||
}
|
||||
|
||||
function getBoostLifecycleTimestamp(a0, a1) { // fn#110788, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14873:524, offset: 0x023871bd, size: 192 bytes, params: 3, frame: 15
|
||||
var r2;
|
||||
var endsAt;
|
||||
var value;
|
||||
const phase = a1.phase;
|
||||
if (phase === 'gave') {
|
||||
value = importDefault(21) /* metro dependency 21: SnowflakeUtils */;
|
||||
return value.extractTimestamp(a0.id);
|
||||
}
|
||||
if (phase === 'expiring') {
|
||||
return a1.endsAt.getTime() - 259200000;
|
||||
}
|
||||
if (phase === 'expired') {
|
||||
endsAt = a0.endsAt;
|
||||
value = undefined;
|
||||
r2 = endsAt == null ? value : endsAt.getTime();
|
||||
if (r2 == null) {
|
||||
value = importDefault(21) /* metro dependency 21: SnowflakeUtils */;
|
||||
value = value.extractTimestamp(a0.id);
|
||||
r2 = value;
|
||||
}
|
||||
return r2;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Metro module 14679; source: modules/premium/powerups/utils/getBoostRowMessageText.tsx; dependencies: [1244, 2256, 14676, 2] */
|
||||
function _fun110792(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110792, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14876:6, offset: 0x0238734d, size: 103 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getBoostRowMessageText.tsx');
|
||||
exports.default = getBoostRowMessageText;
|
||||
}
|
||||
|
||||
function getBoostRowMessageText(a0) { // fn#110793, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14876:193, offset: 0x023873b4, size: 331 bytes, params: 2, frame: 20
|
||||
var r4;
|
||||
var value;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var formatToPlainString;
|
||||
var vct4l8;
|
||||
var endsAt;
|
||||
var Date;
|
||||
const phase = a0.phase;
|
||||
if (phase === 'gave') {
|
||||
return intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).plwH8d);
|
||||
}
|
||||
if (phase === 'expiring') {
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
vct4l8 = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).vct4l8;
|
||||
endsAt = a0.boost.endsAt;
|
||||
if (endsAt != null) {
|
||||
r4 = endsAt;
|
||||
} else {
|
||||
Date = global.Date;
|
||||
value = a0.sortKey + (require(14676) /* metro dependency 14676: getBoostLifecyclePhase */).BOOST_EXPIRING_DISPLAY_WINDOW_MS;
|
||||
r4 = new Date();
|
||||
}
|
||||
return Reflect.apply(formatToPlainString, intl, [vct4l8, {date: r4}]);
|
||||
}
|
||||
if (phase === 'expired') {
|
||||
return intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).hSXjlI);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/* Metro module 14609; source: modules/premium/powerups/utils/getExpiringGuildEntitlements.tsx; dependencies: [2] */
|
||||
function _fun110478(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110478, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14806:6, offset: 0x0237affb, size: 87 bytes, params: 8, frame: 15
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getExpiringGuildEntitlements.tsx');
|
||||
exports.getExpiringGuildEntitlements = function(a0) {
|
||||
return a0.filter(_fun110480).sort(_fun110481);
|
||||
};
|
||||
}
|
||||
|
||||
function getExpiringGuildEntitlements(a0) { // fn#110479, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14806:221, offset: 0x0237b052, size: 42 bytes, params: 2, frame: 12
|
||||
return a0.filter(function(a0) {
|
||||
return a0.ends_at != null;
|
||||
}).sort(function({ends_at}, a1) {
|
||||
return ends_at < a1.ends_at ? -1 : 1;
|
||||
});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
/* Metro module 14646; source: modules/premium/powerups/utils/getGuildPowerupFormattedDateString.tsx; dependencies: [1949, 2] */
|
||||
function _fun110655(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110655, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14843:6, offset: 0x02381a28, size: 106 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const localeStore = importDefault(1949) /* metro dependency 1949: LocaleStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getGuildPowerupFormattedDateString.tsx');
|
||||
exports.default = function(a0) {
|
||||
var r3;
|
||||
var value = a1;
|
||||
r3 = value !== undefined ? value : {'month': 'numeric', 'day': 'numeric'};
|
||||
var Date = global.Date;
|
||||
return new Date(a0).toLocaleDateString(LocaleStore.locale, r3);
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/* Metro module 14621; source: modules/premium/powerups/utils/getGuildPowerupsBoostInfoText.tsx; dependencies: [8259, 1244, 2256, 2] */
|
||||
function _fun110546(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110546, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14818:6, offset: 0x0237cb40, size: 124 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).BoostInfoType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getGuildPowerupsBoostInfoText.tsx');
|
||||
exports.getGuildPowerupsBoostInfoText = getGuildPowerupsBoostInfoText;
|
||||
}
|
||||
|
||||
function getGuildPowerupsBoostInfoText(a0, a1) { // fn#110547, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14818:250, offset: 0x0237cbbc, size: 263 bytes, params: 3, frame: 17
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const AVAILABLE = BoostInfoType.AVAILABLE;
|
||||
if (AVAILABLE === a1) {
|
||||
return intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).BdRXZA,
|
||||
{boostCount: a0});
|
||||
}
|
||||
const SPENT = BoostInfoType.SPENT;
|
||||
if (SPENT === a1) {
|
||||
return intl.formatToPlainString((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).xvgIVG,
|
||||
{boostCount: a0});
|
||||
}
|
||||
const TOTAL = BoostInfoType.TOTAL;
|
||||
if (TOTAL === a1) {
|
||||
return intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */)['/F7Z2y']);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/* Metro module 8256; source: modules/premium/powerups/utils/getPowerupEntitlementPrice.tsx; dependencies: [2] */
|
||||
function _fun66054(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66054, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8441:6, offset: 0x01be9dcd, size: 87 bytes, params: 8, frame: 15
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/getPowerupEntitlementPrice.tsx');
|
||||
exports.default = getPowerupEntitlementPrice;
|
||||
}
|
||||
|
||||
function getPowerupEntitlementPrice(a0) { // fn#66055, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8441:197, offset: 0x01be9e24, size: 223 bytes, params: 2, frame: 7
|
||||
const value = undefined;
|
||||
const guild_monetization = a0 == null || a0.tenant_metadata == null ? value : a0.tenant_metadata.guild_monetization;
|
||||
const guild_monetization2 = a0 == null || a0.sku == null || a0.sku.tenant_metadata == null ? value : a0.sku.tenant_metadata.guild_monetization;
|
||||
let r0 = (guild_monetization == null || guild_monetization.game_server == null ? value : guild_monetization.game_server.boost_price) ?? (guild_monetization == null || guild_monetization.powerup == null ? value : guild_monetization.powerup.boost_price);
|
||||
r0 = r0 ?? (guild_monetization2 == null || guild_monetization2.game_server == null ? value : guild_monetization2.game_server.boost_price);
|
||||
r0 = r0 ?? (guild_monetization2 == null || guild_monetization2.powerup == null ? value : guild_monetization2.powerup.boost_price);
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
/* Metro module 12311; source: modules/premium/powerups/utils/orderMarketablePerksForDisplay.tsx; dependencies: [57, 8260, 8188, 2] */
|
||||
function _fun94003(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#94003, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12497:6, offset: 0x020ce5fc, size: 136 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_3 = (require(8260) /* metro dependency 8260: GameServerConstants */).GAME_SERVER_POWERUP_SKU_ID;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/orderMarketablePerksForDisplay.tsx');
|
||||
exports.default = orderMarketablePerksForDisplay;
|
||||
}
|
||||
|
||||
function orderMarketablePerksForDisplay(a0) { // fn#94004, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12497:252, offset: 0x020ce684, size: 184 bytes, params: 2, frame: 17
|
||||
const items2 = [];
|
||||
arraySpread(items2, a0, 0, undefined);
|
||||
const value = items2.reverse();
|
||||
const index = value.findIndex(function({skuId}) {
|
||||
return skuId === require(dependencyMap[2]).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
});
|
||||
if (index > 0) {
|
||||
value.unshift(env0_2(value.splice(index, 1), 1)[0]);
|
||||
}
|
||||
const index2 = value.findIndex(function({skuId}) {
|
||||
return skuId === GAME_SERVER_POWERUP_SKU_ID;
|
||||
});
|
||||
if (index2 !== -1) {
|
||||
if (index2 !== value.length - 1) {
|
||||
value.push(env0_2(value.splice(index2, 1), 1)[0]);
|
||||
}
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,393 @@
|
||||
/* Metro module 14619; source: modules/premium/powerups/utils/powerupListing.tsx; dependencies: [57, 31, 8258, 8259, 8188, 566, 2] */
|
||||
function _fun110524(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110524, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:6, offset: 0x0237c01b, size: 407 bytes, params: 8, frame: 22
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const _arrayLikeToArray_110527 = function(a0, a1) {
|
||||
var r0;
|
||||
var r1;
|
||||
var r2;
|
||||
var value3;
|
||||
var length;
|
||||
var value5;
|
||||
var value = undefined;
|
||||
var value2 = value == null;
|
||||
reducibleJoin2: while (true) {
|
||||
if (value2) {
|
||||
r0 = value2;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
value3 = value > a0.length;
|
||||
r0 = value3;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
reducibleJoin4: while (true) {
|
||||
if (r0) {
|
||||
length = a0.length;
|
||||
r1 = length;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
r1 = value;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
value = (0, global.Array)(r1);
|
||||
var value4 = 0;
|
||||
if (value4 < r1) {
|
||||
r2 = value4;
|
||||
reducibleLoop5: while (true) {
|
||||
value[r2] = a0[r2];
|
||||
value5 = typeof r2 === 'bigint' ? r2 + 1n : +r2 + 1;
|
||||
if (value5 < r1) {
|
||||
r2 = value5;
|
||||
continue reducibleLoop5;
|
||||
}
|
||||
break reducibleLoop5;
|
||||
}
|
||||
}
|
||||
return value;
|
||||
};
|
||||
const orderPowerupListings = function(a0) {
|
||||
return _fun110531(_fun110529(a0));
|
||||
};
|
||||
const closure = buildPowerupListings;
|
||||
let Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const guildPowerupsStore = importDefault(8258) /* metro dependency 8258: GuildPowerupsStore */;
|
||||
const guildPowerupsConstantsModule = require(8259) /* metro dependency 8259: GuildPowerupsConstants */;
|
||||
const GuildPowerupType = guildPowerupsConstantsModule.GuildPowerupType;
|
||||
const env0_6 = guildPowerupsConstantsModule.PERK_SKU_BADGES;
|
||||
object2 = {};
|
||||
const GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID;
|
||||
const items3 = [GUILD_TAGS_BADGE_PACK_CREEPY_CRAWLIES_POWERUP_SKU_ID];
|
||||
const GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID;
|
||||
items3[1] = GUILD_TAGS_BADGE_PACK_PETS_POWERUP_SKU_ID;
|
||||
const GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID;
|
||||
items3[2] = GUILD_TAGS_BADGE_PACK_PLANT_POWERUP_SKU_ID;
|
||||
const GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID = (require(8188) /* metro dependency 8188: Powerups */).GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID;
|
||||
items3[3] = GUILD_TAGS_BADGE_PACK_FLEX_POWERUP_SKU_ID;
|
||||
object2.guildTagsBadgePacks = items3;
|
||||
Object = global.Object;
|
||||
const env0_8 = Object.entries(object2).reduce(function(a0, a1) {
|
||||
var r1;
|
||||
var r2;
|
||||
var r3;
|
||||
var item3;
|
||||
var value3;
|
||||
var value7;
|
||||
var iterator = a1[Symbol.iterator]();
|
||||
var iterator2 = iterator.next;
|
||||
var item2 = Reflect.apply(iterator2, iterator, []);
|
||||
var item = item2.value;
|
||||
item2 = item2.done ? undefined : iterator;
|
||||
var value = undefined;
|
||||
var value2 = item2 === value;
|
||||
var r4 = value2 ? value : item;
|
||||
reducibleJoin3: while (true) {
|
||||
if (value2) {
|
||||
r1 = item2;
|
||||
r2 = value;
|
||||
r3 = value2;
|
||||
break reducibleJoin3;
|
||||
}
|
||||
item3 = Reflect.apply(iterator2, item2, []);
|
||||
item = item3.value;
|
||||
item3 = item3.done ? undefined : item2;
|
||||
value3 = item3 === value;
|
||||
if (value3) {
|
||||
r1 = item3;
|
||||
r2 = value;
|
||||
r3 = value3;
|
||||
break reducibleJoin3;
|
||||
}
|
||||
r1 = item3;
|
||||
r2 = item;
|
||||
r3 = value3;
|
||||
break reducibleJoin3;
|
||||
}
|
||||
reducibleJoin5: while (true) {
|
||||
if (r3) {
|
||||
break reducibleJoin5;
|
||||
}
|
||||
r1.return();
|
||||
break reducibleJoin5;
|
||||
}
|
||||
var value5 = _createForOfIteratorHelperLoose_110525(r2);
|
||||
var value6 = value5();
|
||||
if (!value6.done) {
|
||||
r2 = value6;
|
||||
reducibleLoop6: while (true) {
|
||||
a0[r2.value] = r4;
|
||||
value7 = value5();
|
||||
if (value7.done) {
|
||||
break reducibleLoop6;
|
||||
}
|
||||
r2 = value7;
|
||||
continue reducibleLoop6;
|
||||
}
|
||||
}
|
||||
return a0;
|
||||
}, {});
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
const items2 = [LEVEL];
|
||||
const PERK = GuildPowerupType.PERK;
|
||||
items2[1] = PERK;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/powerupListing.tsx');
|
||||
exports.POWERUP_GROUP_TO_SKU_IDS = object2;
|
||||
exports.buildPowerupListings = closure;
|
||||
exports.useBuildGuildPowerupsSections = useBuildGuildPowerupsSections;
|
||||
}
|
||||
|
||||
function _createForOfIteratorHelperLoose_110525(a0, a1) { // fn#110525, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:183, offset: 0x0237c1b2, size: 372 bytes, params: 3, frame: 20
|
||||
var r6;
|
||||
var r9;
|
||||
var r5;
|
||||
var value3;
|
||||
var regexp;
|
||||
const env0_0 = a0;
|
||||
const Symbol = global.Symbol;
|
||||
let value = typeof Symbol !== 'undefined';
|
||||
let r1 = value && a0[global.Symbol.iterator];
|
||||
r1 = !r1 ? a0['@@iterator'] : r1;
|
||||
if (r1) {
|
||||
value = r1.call(a0);
|
||||
return value.next.bind(value);
|
||||
}
|
||||
const Array = global.Array;
|
||||
if (Array.isArray(a0)) {
|
||||
if (r1) {
|
||||
}
|
||||
return _fun110526;
|
||||
}
|
||||
value = undefined;
|
||||
if (a0) {
|
||||
if (typeof a0 === 'string') {
|
||||
value = _arrayLikeToArray_110527(a0, value);
|
||||
r5 = value;
|
||||
} else {
|
||||
value3 = ({}).toString.call(a0).slice(8, -1);
|
||||
r6 = value3 === 'Object' && a0.constructor;
|
||||
r9 = r6 ? a0.constructor.name : value3;
|
||||
if (r9 === 'Map') {
|
||||
r6 = global.Array.from(a0);
|
||||
} else if (r9 === 'Set') {
|
||||
r6 = global.Array.from(a0);
|
||||
} else if (r9 === 'Arguments') {
|
||||
value = _arrayLikeToArray_110527(a0, value);
|
||||
r6 = value;
|
||||
} else {
|
||||
regexp = RegExp('^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$', '');
|
||||
if (regexp.test(r9)) {
|
||||
value = _arrayLikeToArray_110527(a0, value);
|
||||
r6 = value;
|
||||
} else {
|
||||
r6 = value;
|
||||
}
|
||||
}
|
||||
r5 = r6;
|
||||
}
|
||||
} else {
|
||||
r5 = value;
|
||||
}
|
||||
if (r5) {
|
||||
if (r5) {
|
||||
}
|
||||
return _fun110526;
|
||||
}
|
||||
const TypeError = global.TypeError;
|
||||
throw new TypeError('Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.');
|
||||
}
|
||||
|
||||
function orderPowerupListings(a0) { // fn#110528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:1470, offset: 0x0237c326, size: 33 bytes, params: 2, frame: 12
|
||||
return moveBadgePacksAfterServerTags(moveServerThemeToFront(a0));
|
||||
}
|
||||
|
||||
function buildPowerupListings(a0, a1, a2) { // fn#110535, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:2161, offset: 0x0237c4f0, size: 156 bytes, params: 4, frame: 19
|
||||
var r5;
|
||||
var r3;
|
||||
var value5;
|
||||
var value6;
|
||||
var PERK;
|
||||
var push;
|
||||
let value = a2;
|
||||
const items2 = [];
|
||||
let closure = _fun110536;
|
||||
const env0_1 = a1.reduce(closure, {});
|
||||
closure = buildPowerupListings_loop;
|
||||
const value3 = _createForOfIteratorHelperLoose_110525(a1);
|
||||
const value4 = value3();
|
||||
let done = value4.done;
|
||||
if (!done) {
|
||||
r5 = value4;
|
||||
reducibleLoop1: while (true) {
|
||||
value5 = r5.value;
|
||||
var env0_2 = value5;
|
||||
closure();
|
||||
value6 = value3();
|
||||
done = value6.done;
|
||||
if (done) {
|
||||
break reducibleLoop1;
|
||||
}
|
||||
r5 = value6;
|
||||
continue reducibleLoop1;
|
||||
}
|
||||
}
|
||||
reducibleJoin4: while (true) {
|
||||
if (value) {
|
||||
PERK = GuildPowerupType.PERK;
|
||||
value = a0 === PERK;
|
||||
r3 = value;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
r3 = value;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
reducibleJoin6: while (true) {
|
||||
if (r3) {
|
||||
push = items2.push;
|
||||
Reflect.apply(push, items2, [{type: 'gameServer'}]);
|
||||
break reducibleJoin6;
|
||||
}
|
||||
break reducibleJoin6;
|
||||
}
|
||||
return orderPowerupListings(items2);
|
||||
}
|
||||
|
||||
function useBuildGuildPowerupsSections(a0, a1) { // fn#110540, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:3020, offset: 0x0237c781, size: 126 bytes, params: 3, frame: 17
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const value2 = undefined;
|
||||
const stateForGuild = (require(566) /* metro dependency 566: flux */).useStateFromStores([GuildPowerupsStore],
|
||||
_fun110541);
|
||||
return env0_3.useMemo(_fun110542, [stateForGuild == null ? value2 : stateForGuild.powerupCatalog, a1]);
|
||||
}
|
||||
|
||||
function moveServerThemeToFront(a0) { // fn#110529, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:1509, owner: orderPowerupListings.moveServerThemeToFront, offset: 0x0237c347, size: 94 bytes, params: 2, frame: 17
|
||||
let value = a0.findIndex(_fun110530);
|
||||
if (value <= 0) {
|
||||
return a0;
|
||||
}
|
||||
const items2 = [];
|
||||
arraySpread(items2, a0, 0, undefined);
|
||||
value = items2.splice(value, 1);
|
||||
items2.unshift(env1_2(value, 1)[0]);
|
||||
return items2;
|
||||
}
|
||||
|
||||
function moveBadgePacksAfterServerTags(a0) { // fn#110531, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:1742, owner: orderPowerupListings.moveBadgePacksAfterServerTags, offset: 0x0237c3ea, size: 154 bytes, params: 2, frame: 17
|
||||
var environment;
|
||||
var items2;
|
||||
var value2;
|
||||
var property;
|
||||
let value = a0.findIndex(_fun110532);
|
||||
const index = a0.findIndex(function(a0) {
|
||||
return a0.type === 'multiPerk' && a0.group === 'guildTagsBadgePacks';
|
||||
});
|
||||
if (value !== -1) {
|
||||
if (index === -1) {
|
||||
return a0;
|
||||
}
|
||||
if (index !== value + 1) {
|
||||
items2 = [];
|
||||
arraySpread(items2, a0, 0, undefined);
|
||||
value = items2.splice(index, 1);
|
||||
value2 = environment.__proto__;
|
||||
property = env1_2(value, 1)[0];
|
||||
value = items2.findIndex(_fun110534);
|
||||
items2.splice(value + 1, 0, property);
|
||||
return items2;
|
||||
}
|
||||
}
|
||||
return a0;
|
||||
}
|
||||
|
||||
function _fun110536(a0, a1) { // fn#110536, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:2225, offset: 0x0237c58c, size: 81 bytes, params: 3, frame: 13
|
||||
const type = a1.type;
|
||||
const PERK = GuildPowerupType.PERK;
|
||||
if (type === PERK) {
|
||||
var property = env1_8[a1.skuId];
|
||||
if (property != null) {
|
||||
if (a0[property] == null) {
|
||||
a0[property] = [];
|
||||
}
|
||||
property = a0[property];
|
||||
property.push(a1);
|
||||
}
|
||||
}
|
||||
return a0;
|
||||
}
|
||||
|
||||
function buildPowerupListings_loop() { // fn#110537, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:2333, owner: buildPowerupListings._loop, offset: 0x0237c5dd, size: 249 bytes, params: 1, frame: 17
|
||||
var binding;
|
||||
var property2;
|
||||
const type = value.type;
|
||||
const LEVEL = GuildPowerupType.LEVEL;
|
||||
if (type === LEVEL) {
|
||||
env0_0.push({type: 'singleLevel', powerup: value});
|
||||
return 0;
|
||||
}
|
||||
const property = env1_8[value.skuId];
|
||||
if (property != null) {
|
||||
property2 = env0_1[property];
|
||||
if (property2 !== undefined) {
|
||||
var env0_0 = env1_7[property];
|
||||
property2.sort(_fun110538);
|
||||
binding = env0_0;
|
||||
binding.push({type: 'multiPerk', group: property, powerups: property2});
|
||||
env0_1[property] = undefined;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
env0_0.push({type: 'singlePerk', powerup: value, badge: PERK_SKU_BADGES[value.skuId]});
|
||||
}
|
||||
|
||||
function _fun110542() { // fn#110542, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:3149, offset: 0x0237c7ff, size: 34 bytes, params: 1, frame: 13
|
||||
return env1_9.reduce(_fun110543, []);
|
||||
}
|
||||
|
||||
function _fun110530(a0) { // fn#110530, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:1563, offset: 0x0237c3a5, size: 69 bytes, params: 2, frame: 13
|
||||
var r0;
|
||||
var skuId;
|
||||
let value = a0.type === 'singlePerk';
|
||||
if (value) {
|
||||
skuId = a0.powerup.skuId;
|
||||
value = environment.__proto__.__proto__;
|
||||
value = skuId === (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_GUILD_THEME_SKU_ID;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110532(a0) { // fn#110532, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:1803, offset: 0x0237c484, size: 69 bytes, params: 2, frame: 13
|
||||
var r0;
|
||||
var skuId;
|
||||
let value = a0.type === 'singlePerk';
|
||||
if (value) {
|
||||
skuId = a0.powerup.skuId;
|
||||
value = environment.__proto__.__proto__;
|
||||
value = skuId === (require(8188) /* metro dependency 8188: Powerups */).GUILD_POWERUP_TAG_SKU_ID;
|
||||
r0 = value;
|
||||
} else {
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun110538({skuId}, {skuId}) { // fn#110538, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:2486, offset: 0x0237c6d6, size: 55 bytes, params: 3, frame: 12
|
||||
let binding = env0_0;
|
||||
const value2 = binding.indexOf(skuId);
|
||||
binding = env0_0;
|
||||
return value2 - binding.indexOf(skuId);
|
||||
}
|
||||
|
||||
function _fun110543(a0, a1) { // fn#110543, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14816:3163, offset: 0x0237c821, size: 87 bytes, params: 3, frame: 17
|
||||
const value = environment.__proto__;
|
||||
const r3 = stateForGuild == null ? undefined : stateForGuild.powerupCatalog[a1];
|
||||
if (r3 != null) {
|
||||
a0.push({type: a1, listings: buildPowerupListings(a1, r3, require)});
|
||||
}
|
||||
return a0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,223 @@
|
||||
/* Metro module 12309; source: modules/premium/powerups/utils/storeListingToGuildPowerup.tsx; dependencies: [1880, 8259, 1881, 2] */
|
||||
function _fun93996(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93996, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12495:6, offset: 0x020ce063, size: 163 bytes, params: 8, frame: 18
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const premiumConstantsModule = require(1880) /* metro dependency 1880: PremiumConstants */;
|
||||
const env0_0 = premiumConstantsModule.DEFAULT_SOUND_SLOTS;
|
||||
const env0_1 = premiumConstantsModule.DEFAULT_STICKER_SLOTS;
|
||||
const env0_2 = (require(8259) /* metro dependency 8259: GuildPowerupsConstants */).GuildPowerupType;
|
||||
const env0_3 = (require(1881) /* metro dependency 1881: EmojiConstants */).DEFAULT_EMOJI_SLOTS;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/storeListingToGuildPowerup.tsx');
|
||||
exports.default = storeListingToGuildPowerup;
|
||||
}
|
||||
|
||||
function storeListingToGuildPowerup(a0, a1) { // fn#93997, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12495:318, offset: 0x020ce106, size: 893 bytes, params: 3, frame: 32
|
||||
var r22;
|
||||
var r5;
|
||||
var guild_features;
|
||||
var r11;
|
||||
var r12;
|
||||
var r13;
|
||||
var additional_emoji_slots;
|
||||
var r1;
|
||||
var additional_sound_slots;
|
||||
var additional_sticker_slots;
|
||||
var r6;
|
||||
var r7;
|
||||
var object5;
|
||||
var value3;
|
||||
var value4;
|
||||
var value5;
|
||||
var value6;
|
||||
var guild_features2;
|
||||
var value7;
|
||||
var value8;
|
||||
var guild_features3;
|
||||
var value9;
|
||||
var guild_features4;
|
||||
var value10;
|
||||
var value11;
|
||||
var object6;
|
||||
var object7;
|
||||
let powerup_metadata = a1.powerup_metadata;
|
||||
const value = undefined;
|
||||
const category_type = powerup_metadata == null ? value : powerup_metadata.category_type;
|
||||
if (category_type != null) {
|
||||
var sku = a1.sku;
|
||||
powerup_metadata = sku == null ? value : sku.powerup_metadata;
|
||||
if (powerup_metadata == null) {
|
||||
return value;
|
||||
}
|
||||
var object8 = {};
|
||||
object8.title = a1.summary;
|
||||
object8.skuId = a1.sku.id;
|
||||
object8.cost = powerup_metadata.boost_price;
|
||||
var dependent_sku_id = a1.sku.dependent_sku_id;
|
||||
object8.dependencies = dependent_sku_id != null ? [a1.sku.dependent_sku_id] : [];
|
||||
var powerup_metadata2 = a1.powerup_metadata;
|
||||
var animated_image_url = powerup_metadata2 == null ? value : powerup_metadata2.animated_image_url;
|
||||
animated_image_url = animated_image_url ?? powerup_metadata.animated_image_url;
|
||||
object8.animatedImageUrl = animated_image_url;
|
||||
var powerup_metadata3 = a1.powerup_metadata;
|
||||
var static_image_url = powerup_metadata3 == null ? value : powerup_metadata3.static_image_url;
|
||||
static_image_url = static_image_url ?? powerup_metadata.static_image_url;
|
||||
object8.staticImageUrl = static_image_url;
|
||||
powerup_metadata = a1.powerup_metadata;
|
||||
object8.storeRemovalDate = powerup_metadata == null ? value : powerup_metadata.store_removal_date;
|
||||
powerup_metadata = a1.powerup_metadata;
|
||||
object8.deactivationCooldownPeriodDays = powerup_metadata == null ? value : powerup_metadata.deactivation_cooldown_period_days;
|
||||
var LEVEL = GuildPowerupType.LEVEL;
|
||||
if (LEVEL === category_type) {
|
||||
sku = a1.sku;
|
||||
powerup_metadata = sku.powerup_metadata;
|
||||
guild_features = powerup_metadata == null ? value : powerup_metadata.guild_features;
|
||||
if (guild_features == null) {
|
||||
return value;
|
||||
}
|
||||
additional_emoji_slots = guild_features.additional_emoji_slots;
|
||||
value3 = DEFAULT_EMOJI_SLOTS + additional_emoji_slots;
|
||||
additional_sound_slots = guild_features.additional_sound_slots;
|
||||
value4 = DEFAULT_SOUND_SLOTS + additional_sound_slots;
|
||||
additional_sticker_slots = guild_features.additional_sticker_slots;
|
||||
value5 = DEFAULT_STICKER_SLOTS + additional_sticker_slots;
|
||||
sku = a1.sku;
|
||||
dependent_sku_id = sku.dependent_sku_id;
|
||||
var env0_0;
|
||||
if (dependent_sku_id != null) {
|
||||
r11 = value5;
|
||||
r12 = value4;
|
||||
r13 = value3;
|
||||
while (true) {
|
||||
value6 = a0.find(function(a0) {
|
||||
return dependent_sku_id === a0.sku.id;
|
||||
});
|
||||
if (value6 != null) {
|
||||
sku = value6.sku;
|
||||
if (sku == null) {
|
||||
additional_emoji_slots = value;
|
||||
break;
|
||||
}
|
||||
powerup_metadata = sku.powerup_metadata;
|
||||
if (powerup_metadata == null) {
|
||||
additional_emoji_slots = value;
|
||||
break;
|
||||
}
|
||||
guild_features2 = powerup_metadata.guild_features;
|
||||
if (guild_features2 == null) {
|
||||
additional_emoji_slots = value;
|
||||
break;
|
||||
}
|
||||
additional_emoji_slots = guild_features2.additional_emoji_slots;
|
||||
break;
|
||||
}
|
||||
additional_emoji_slots = value;
|
||||
value7 = 0;
|
||||
if (additional_emoji_slots != null) {
|
||||
r1 = additional_emoji_slots;
|
||||
continue;
|
||||
}
|
||||
r1 = value7;
|
||||
continue;
|
||||
value8 = r13 + r1;
|
||||
if (value6 == null) {
|
||||
additional_sound_slots = value;
|
||||
continue;
|
||||
}
|
||||
sku = value6.sku;
|
||||
if (sku == null) {
|
||||
additional_sound_slots = value;
|
||||
continue;
|
||||
}
|
||||
powerup_metadata = sku.powerup_metadata;
|
||||
if (powerup_metadata == null) {
|
||||
additional_sound_slots = value;
|
||||
continue;
|
||||
}
|
||||
guild_features3 = powerup_metadata.guild_features;
|
||||
if (guild_features3 == null) {
|
||||
additional_sound_slots = value;
|
||||
continue;
|
||||
}
|
||||
additional_sound_slots = guild_features3.additional_sound_slots;
|
||||
if (additional_sound_slots != null) {
|
||||
r1 = additional_sound_slots;
|
||||
continue;
|
||||
}
|
||||
r1 = value7;
|
||||
continue;
|
||||
value9 = r12 + r1;
|
||||
if (value6 == null) {
|
||||
additional_sticker_slots = value;
|
||||
continue;
|
||||
}
|
||||
sku = value6.sku;
|
||||
if (sku == null) {
|
||||
additional_sticker_slots = value;
|
||||
continue;
|
||||
}
|
||||
powerup_metadata = sku.powerup_metadata;
|
||||
if (powerup_metadata == null) {
|
||||
additional_sticker_slots = value;
|
||||
continue;
|
||||
}
|
||||
guild_features4 = powerup_metadata.guild_features;
|
||||
if (guild_features4 == null) {
|
||||
additional_sticker_slots = value;
|
||||
continue;
|
||||
}
|
||||
additional_sticker_slots = guild_features4.additional_sticker_slots;
|
||||
if (additional_sticker_slots != null) {
|
||||
r1 = additional_sticker_slots;
|
||||
continue;
|
||||
}
|
||||
r1 = value7;
|
||||
continue;
|
||||
value10 = r11 + r1;
|
||||
value11 = value6 == null;
|
||||
if (value11) {
|
||||
dependent_sku_id = value;
|
||||
continue;
|
||||
}
|
||||
sku = value6.sku;
|
||||
dependent_sku_id = sku.dependent_sku_id;
|
||||
env0_0 = dependent_sku_id;
|
||||
if (dependent_sku_id != null) {
|
||||
r11 = value10;
|
||||
r12 = value9;
|
||||
r13 = value8;
|
||||
continue;
|
||||
}
|
||||
r5 = value10;
|
||||
r6 = value9;
|
||||
r7 = value8;
|
||||
r22 = value11;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
r5 = value5;
|
||||
r6 = value4;
|
||||
r7 = value3;
|
||||
}
|
||||
object6 = {};
|
||||
object6.type = GuildPowerupType.LEVEL;
|
||||
object7 = {};
|
||||
copyDataProperties(object7, guild_features, r22);
|
||||
object7['total_emoji_slots'] = r7;
|
||||
object7['total_sound_slots'] = r6;
|
||||
object7['total_sticker_slots'] = r5;
|
||||
object6.features = object7;
|
||||
copyDataProperties(object6, object8, r22);
|
||||
return object6;
|
||||
}
|
||||
var PERK = GuildPowerupType.PERK;
|
||||
if (PERK === category_type) {
|
||||
object5 = {};
|
||||
object5.type = GuildPowerupType.PERK;
|
||||
object5.description = a1.description ?? '';
|
||||
copyDataProperties(object5, object8, r22);
|
||||
return object5;
|
||||
}
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,73 @@
|
||||
/* Metro module 14636; source: modules/premium/powerups/utils/useCalculatePowerupCardStatus.tsx; dependencies: [31, 8259, 1244, 2256, 2] */
|
||||
function _fun110618(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#110618, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14833:6, offset: 0x0237fc9a, size: 143 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(8259) /* metro dependency 8259: GuildPowerupsConstants */).PowerupActiveStatusType;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/powerups/utils/useCalculatePowerupCardStatus.tsx');
|
||||
exports.useCalculatePowerupCardStatus = useCalculatePowerupCardStatus;
|
||||
}
|
||||
|
||||
function useCalculatePowerupCardStatus(a0, a1, a2) { // fn#110619, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14833:270, offset: 0x0237fd29, size: 66 bytes, params: 4, frame: 16
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const env0_2 = a2;
|
||||
return env0_3.useMemo(_fun110620, [a1, a2, a0]);
|
||||
}
|
||||
|
||||
function _fun110620() { // fn#110620, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14833:334, offset: 0x0237fd6b, size: 431 bytes, params: 1, frame: 23
|
||||
var r0;
|
||||
var type;
|
||||
var value3;
|
||||
var object2;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var formatToPlainString;
|
||||
var WRRYUT;
|
||||
var sourcePowerup;
|
||||
const intl2 = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
const sourceEntitlement = require.sourceEntitlement;
|
||||
const value2 = undefined;
|
||||
if ((sourceEntitlement == null ? value2 : sourceEntitlement.ends_at) != null) {
|
||||
r0 = {type: 'expiring', expiringAt: require.sourceEntitlement.ends_at};
|
||||
} else if (importDefault) {
|
||||
if (env0_0.storeRemovalDate != null) {
|
||||
r0 = {type: 'removing', removingAt: env0_0.storeRemovalDate};
|
||||
} else {
|
||||
type = require.type;
|
||||
value3 = environment.__proto__;
|
||||
if (type === PowerupActiveStatusType.LEVEL_ACTIVATED) {
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
WRRYUT = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).WRRYUT;
|
||||
sourcePowerup = require.sourcePowerup;
|
||||
r0 = {type: 'active', statusText: Reflect.apply(formatToPlainString, intl, [WRRYUT,
|
||||
{perkName: (sourcePowerup == null ? value2 : sourcePowerup.title) ?? intl2.string(t.BfF6ED)}])};
|
||||
} else if (require.type === PowerupActiveStatusType.INACTIVE) {
|
||||
r0 = value2;
|
||||
} else {
|
||||
object2 = {type: 'active'};
|
||||
object2.statusText = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).FFLkmx);
|
||||
r0 = object2;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
type = require.type;
|
||||
value3 = environment.__proto__;
|
||||
if (type === PowerupActiveStatusType.LEVEL_ACTIVATED) {
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
WRRYUT = (importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).WRRYUT;
|
||||
sourcePowerup = require.sourcePowerup;
|
||||
r0 = {type: 'active', statusText: Reflect.apply(formatToPlainString, intl, [WRRYUT,
|
||||
{perkName: (sourcePowerup == null ? value2 : sourcePowerup.title) ?? intl2.string(t.BfF6ED)}])};
|
||||
} else if (require.type === PowerupActiveStatusType.INACTIVE) {
|
||||
r0 = value2;
|
||||
} else {
|
||||
object2 = {type: 'active'};
|
||||
object2.statusText = intl.string((importDefault(2256) /* metro dependency 2256: GuildPowerupsMessages */).FFLkmx);
|
||||
r0 = object2;
|
||||
}
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user