Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,114 @@
|
||||
/* Metro module 7644; source: modules/premium/native/utils/GiftAnimationData.tsx; dependencies: [1880, 7643, 7645, 7646, 7647, 7648, 7649, 7650, 7651, 7652, 7653, 7654, 7655, 7656, 7657, 7658, 7659, 7660, 7661, 7662, 7663, 7664, 7665, 7666, 7667, 7668, 2] */
|
||||
function _fun61202(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#61202, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7822:6, offset: 0x0171ddf5, size: 169 bytes, params: 8, frame: 18
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = (require(1880) /* metro dependency 1880: PremiumConstants */).PremiumGiftStyles;
|
||||
object2 = {JSON: 0};
|
||||
object2[0] = 'JSON';
|
||||
object2.LOTTIE = 1;
|
||||
object2[1] = 'LOTTIE';
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/native/utils/GiftAnimationData.tsx');
|
||||
exports.LottieType = object2;
|
||||
exports.getLottieType = getLottieType;
|
||||
exports.getGiftAnimationData = getGiftAnimationData;
|
||||
}
|
||||
|
||||
function getLottieType(a0) { // fn#61203, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7822:310, offset: 0x0171de9e, size: 44 bytes, params: 2, frame: 3
|
||||
const NITROWEEN_STANDARD = PremiumGiftStyles.NITROWEEN_STANDARD;
|
||||
return a0 === NITROWEEN_STANDARD ? env0_3.LOTTIE : env0_3.JSON;
|
||||
}
|
||||
|
||||
function getGiftAnimationData(a0, a1) { // fn#61204, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7822:408, offset: 0x0171deca, size: 1292 bytes, params: 3, frame: 14
|
||||
const AnimationState = (require(7643) /* metro dependency 7643: PremiumGiftingUtils */).AnimationState;
|
||||
const STANDARD_BOX = PremiumGiftStyles.STANDARD_BOX;
|
||||
if (STANDARD_BOX === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7645) /* metro dependency 7645 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7646) /* metro dependency 7646 */;
|
||||
}
|
||||
return require(7647) /* metro dependency 7647 */;
|
||||
}
|
||||
const CAKE = PremiumGiftStyles.CAKE;
|
||||
if (CAKE === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7648) /* metro dependency 7648 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7649) /* metro dependency 7649 */;
|
||||
}
|
||||
return require(7650) /* metro dependency 7650 */;
|
||||
}
|
||||
const CHEST = PremiumGiftStyles.CHEST;
|
||||
if (CHEST === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7651) /* metro dependency 7651 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7652) /* metro dependency 7652 */;
|
||||
}
|
||||
return require(7653) /* metro dependency 7653 */;
|
||||
}
|
||||
const COFFEE = PremiumGiftStyles.COFFEE;
|
||||
if (COFFEE === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7654) /* metro dependency 7654 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7655) /* metro dependency 7655 */;
|
||||
}
|
||||
return require(7656) /* metro dependency 7656 */;
|
||||
}
|
||||
const SEASONAL_STANDARD_BOX = PremiumGiftStyles.SEASONAL_STANDARD_BOX;
|
||||
if (SEASONAL_STANDARD_BOX === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7657) /* metro dependency 7657 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7658) /* metro dependency 7658 */;
|
||||
}
|
||||
return require(7659) /* metro dependency 7659 */;
|
||||
}
|
||||
const SEASONAL_CAKE = PremiumGiftStyles.SEASONAL_CAKE;
|
||||
if (SEASONAL_CAKE === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7660) /* metro dependency 7660 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7661) /* metro dependency 7661 */;
|
||||
}
|
||||
return require(7662) /* metro dependency 7662 */;
|
||||
}
|
||||
const SEASONAL_CHEST = PremiumGiftStyles.SEASONAL_CHEST;
|
||||
if (SEASONAL_CHEST === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7663) /* metro dependency 7663 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7664) /* metro dependency 7664 */;
|
||||
}
|
||||
return require(7665) /* metro dependency 7665 */;
|
||||
}
|
||||
const SEASONAL_COFFEE = PremiumGiftStyles.SEASONAL_COFFEE;
|
||||
if (SEASONAL_COFFEE === a0) {
|
||||
if (AnimationState.IDLE === a1) {
|
||||
return require(7666) /* metro dependency 7666 */;
|
||||
}
|
||||
if (AnimationState.LOOP === a1) {
|
||||
return require(7667) /* metro dependency 7667 */;
|
||||
}
|
||||
return require(7668) /* metro dependency 7668 */;
|
||||
}
|
||||
const SNOWGLOBE = PremiumGiftStyles.SNOWGLOBE;
|
||||
if (SNOWGLOBE !== a0) {
|
||||
if (PremiumGiftStyles.BOX !== a0) {
|
||||
PremiumGiftStyles.CUP;
|
||||
}
|
||||
}
|
||||
const Error = global.Error;
|
||||
throw Error();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,211 @@
|
||||
/* Metro module 7022; source: modules/premium/native/utils/PremiumManagementUtils.tsx; dependencies: [661, 482, 33, 3, 4496, 1244, 477, 1581, 7023, 7025, 2] */
|
||||
function _fun55645(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#55645, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:6, offset: 0x013acb19, size: 316 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = (require(661) /* metro dependency 661: Constants */).SubscriptionStatusTypes;
|
||||
const env0_4 = (require(482) /* metro dependency 482: Constants */).PaymentGatewayToFriendlyName;
|
||||
const env0_5 = (require(33) /* metro dependency 33 */).jsx;
|
||||
let value = importDefault(3) /* metro dependency 3: Logger */;
|
||||
value = new value('PremiumManagementUtils');
|
||||
const closure = getPremiumManagementMethod;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/native/utils/PremiumManagementUtils.tsx');
|
||||
exports.MobileWebDestinationTypes = {PREMIUM_MANAGEMENT: 'premium_management'};
|
||||
exports.PremiumManagementMethod = {IN_APP: 'manage_in_app',
|
||||
IN_EXTERNAL_MOBILE_PAYMENT_GATEWAY: 'manage_in_external_mobile_payment_gateway', IN_WEB: 'manage_in_web'};
|
||||
exports.getPremiumManagementMethod = closure;
|
||||
exports.getExternalManagementMessage = getExternalManagementMessage;
|
||||
}
|
||||
|
||||
function getPremiumManagementMethod(a0) { // fn#55646, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:480, offset: 0x013acc55, size: 90 bytes, params: 2, frame: 4
|
||||
const value = null;
|
||||
return value == a0 ? value : a0.isOnPlatformMatchingExternalPaymentGateway ? env0_7.IN_APP : a0.isPurchasedExternally && value != a0.paymentGateway ? env0_7.IN_EXTERNAL_MOBILE_PAYMENT_GATEWAY : env0_7.IN_WEB;
|
||||
}
|
||||
|
||||
function defaultMobileWebNitroManagementSuccessCallback() { // fn#55647, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:691, offset: 0x013accaf, size: 26 bytes, params: 1, frame: 11
|
||||
return env0_6.log('Successfully opened mobile web Nitro Management page');
|
||||
}
|
||||
|
||||
function defaultMobileWebNitroManagementFailureCallback(a0) { // fn#55648, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:804, offset: 0x013accc9, size: 174 bytes, params: 2, frame: 19
|
||||
env0_6.error('Failed to open mobile web Nitro Management page, error response: ', a0);
|
||||
const defaultImport = importDefault(4496) /* metro dependency 4496: AlertActionCreators */;
|
||||
const show = defaultImport.show;
|
||||
const object2 = {};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const string = intl.string;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
const NrBVjw = t.NrBVjw;
|
||||
object2.title = Reflect.apply(string, intl, [NrBVjw]);
|
||||
object2.body = intl.string(t['gD+grx']);
|
||||
object2.hideActionSheet = true;
|
||||
Reflect.apply(show, defaultImport, [object2]);
|
||||
}
|
||||
|
||||
function getExternalManagementMessage(a0) { // fn#55649, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:1248, offset: 0x013acd77, size: 708 bytes, params: 2, frame: 24
|
||||
var r1;
|
||||
var r7;
|
||||
var status;
|
||||
var r9;
|
||||
var moduleValue3;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
var closure;
|
||||
const LinkButton = (require(7025) /* metro dependency 7025: LinkButton */).LinkButton;
|
||||
const value = a1;
|
||||
const value2 = undefined;
|
||||
const env0_0 = value !== value2 ? value : null;
|
||||
const premiumManagementMethod = getPremiumManagementMethod(a0);
|
||||
if (premiumManagementMethod != null) {
|
||||
var IN_APP = env0_7.IN_APP;
|
||||
if (premiumManagementMethod === IN_APP) {
|
||||
return null;
|
||||
}
|
||||
var isIOS2 = (require(477) /* metro dependency 477: PlatformUtils */).isIOS();
|
||||
var value4 = 'iOS';
|
||||
r7 = isIOS2 ? value4 : (require(1581) /* metro dependency 1581: MetaQuestUtilsAndroid */).isMetaQuest() ? 'Meta Quest' : 'Android';
|
||||
var IN_EXTERNAL_MOBILE_PAYMENT_GATEWAY = env0_7.IN_EXTERNAL_MOBILE_PAYMENT_GATEWAY;
|
||||
if (premiumManagementMethod !== IN_EXTERNAL_MOBILE_PAYMENT_GATEWAY) {
|
||||
if (premiumManagementMethod === env0_7.IN_WEB) {
|
||||
if (r1 == null) {
|
||||
return intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.CnoyAN,
|
||||
{mobilePlatform: r7});
|
||||
}
|
||||
if (r1.shouldAllowExternalManagement) {
|
||||
if (value4 === r7) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={function() {
|
||||
return manageExternalNitroSubscription();
|
||||
}} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
moduleValue3 = require(1581) /* metro dependency 1581: MetaQuestUtilsAndroid */;
|
||||
if (moduleValue3.isMetaQuest()) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={onPress_55651} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
return null;
|
||||
}
|
||||
if (a0 == null) {
|
||||
if (premiumManagementMethod === env0_7.IN_WEB) {
|
||||
if (r1 == null) {
|
||||
return intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.CnoyAN,
|
||||
{mobilePlatform: r7});
|
||||
}
|
||||
if (r1.shouldAllowExternalManagement) {
|
||||
if (value4 === r7) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={function() {
|
||||
return manageExternalNitroSubscription();
|
||||
}} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
moduleValue3 = require(1581) /* metro dependency 1581: MetaQuestUtilsAndroid */;
|
||||
if (moduleValue3.isMetaQuest()) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={onPress_55651} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
return null;
|
||||
}
|
||||
if (a0.paymentGateway != null) {
|
||||
return intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.cFZnqX,
|
||||
{mobilePlatform: r7, externalPaymentGateway: PaymentGatewayToFriendlyName[a0.paymentGateway]});
|
||||
}
|
||||
if (premiumManagementMethod === env0_7.IN_WEB) {
|
||||
if (r1 == null) {
|
||||
return intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.CnoyAN,
|
||||
{mobilePlatform: r7});
|
||||
}
|
||||
if (r1.shouldAllowExternalManagement) {
|
||||
if (value4 === r7) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={function() {
|
||||
return manageExternalNitroSubscription();
|
||||
}} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
moduleValue3 = require(1581) /* metro dependency 1581: MetaQuestUtilsAndroid */;
|
||||
if (moduleValue3.isMetaQuest()) {
|
||||
closure = manageExternalNitroSubscription;
|
||||
status = a0 == null ? value2 : a0.status;
|
||||
r9 = status === SubscriptionStatusTypes.CANCELED || status === SubscriptionStatusTypes.PAUSE_PENDING;
|
||||
r9 = !r9 ? status === SubscriptionStatusTypes.PAST_DUE : r9;
|
||||
r1 = r1.returnCtaAsComponent ? <LinkButton containerStyle={{justifyContent: 'flex-start'}} onPress={onPress_55651} text={intl.string(r9 ? t.tqSSSA : t['olSp/D'])} variant="text-sm/semibold" /> : intl.format((require(1244) /* metro dependency 1244: indexNative */).t.IERwUb,
|
||||
|
||||
|
||||
|
||||
|
||||
{manageExternalNitroSubscription: closure});
|
||||
return r1;
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
return intl.formatToPlainString(t.CnoyAN, {mobilePlatform: r7});
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function manageExternalNitroSubscription() { // fn#55650, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7200:1773, owner: getExternalManagementMessage.manageExternalNitroSubscription, offset: 0x013ad03b, size: 133 bytes, params: 1, frame: 19
|
||||
const billingStandaloneNativeUtilsModule = require(7023) /* metro dependency 7023: BillingStandaloneNativeUtils */;
|
||||
const goToStandaloneNitroManagementFromMobileApp = billingStandaloneNativeUtilsModule.goToStandaloneNitroManagementFromMobileApp;
|
||||
const binding = env0_0;
|
||||
return Reflect.apply(goToStandaloneNitroManagementFromMobileApp, billingStandaloneNativeUtilsModule,
|
||||
['premium_external_management', {loadId: binding.loadId},
|
||||
binding.onSuccessCallback != null ? env0_0.onSuccessCallback : defaultMobileWebNitroManagementSuccessCallback,
|
||||
env0_0.onFailureCallback ?? defaultMobileWebNitroManagementFailureCallback]);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
/* Metro module 10381; source: modules/premium/native/utils/openGiftModal.tsx; dependencies: [5080, 10382, 1962, 2] */
|
||||
function _fun80410(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#80410, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10567:6, offset: 0x01e7988c, 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/native/utils/openGiftModal.tsx');
|
||||
exports.openGiftModal = 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,
|
||||
'gift_modal_key', navigationParams);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user