decord/source/modules/premium/native/launchPremiumPlanSelect.tsx

85 lines
3.1 KiB
TypeScript
Raw Normal View History

2026-08-05 07:35:12 +00:00
// Module ID: 6767
// Function ID: 6768
2026-07-20 16:05:17 +00:00
// Name: launchPremiumPlanSelect
2026-08-05 07:35:12 +00:00
// Dependencies: [676, 6765, 4460, 6768, 1959, 6768, 5907, 2]
2026-07-20 16:05:17 +00:00
// Exports: launchPremiumPlanSelect
2026-08-05 07:35:12 +00:00
// Module 6767 (launchPremiumPlanSelect)
2026-07-23 10:11:24 +00:00
import { UserSettingsSections } from "ME";
2026-08-05 07:35:12 +00:00
let result = require("module_4460").fileFinishedImporting("modules/premium/native/launchPremiumPlanSelect.tsx");
2026-07-20 16:05:17 +00:00
export const launchPremiumPlanSelect = function launchPremiumPlanSelect(isBoostPurchaseFlow) {
let analyticsLocation;
let analyticsLocations;
let applicationId;
let guildId;
let navigation;
let onPaymentDismiss;
let onPaymentSuccess;
let planId;
2026-07-23 10:11:24 +00:00
let require;
2026-07-20 16:05:17 +00:00
let showCurrentPlan;
2026-07-23 10:11:24 +00:00
({ predicate: require, navigation, showCurrentPlan } = isBoostPurchaseFlow);
2026-07-20 16:05:17 +00:00
if (showCurrentPlan === undefined) {
showCurrentPlan = true;
}
let flag = isBoostPurchaseFlow.isBoostPurchaseFlow;
if (flag === undefined) {
flag = false;
}
2026-07-31 08:44:05 +00:00
let flag2 = isBoostPurchaseFlow.allowYearlyBundles;
if (flag2 === undefined) {
flag2 = false;
}
2026-07-20 16:05:17 +00:00
({ analyticsLocation, analyticsLocations, planId, applicationId, guildId, onPaymentSuccess, onPaymentDismiss } = isBoostPurchaseFlow);
function wrappedPredicate(isDeprecated) {
2026-07-31 08:44:05 +00:00
const result = outer1_0(outer1_2[1]).shouldAlwaysExcludeFromPlanSelect(isDeprecated, flag2);
2026-07-29 08:29:29 +00:00
let tmp2 = !result;
if (!result) {
let flag;
if (callback != null) {
flag = callback(isDeprecated);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (flag == null) {
flag = true;
}
tmp2 = flag;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
return tmp2;
2026-07-20 16:05:17 +00:00
}
const PREMIUM_PLAN_SELECT = UserSettingsSections.PREMIUM_PLAN_SELECT;
if (null != navigation) {
2026-07-29 08:29:29 +00:00
let obj = { predicate: null, analyticsLocation: null, analyticsLocations: null, showCurrentPlan: null, isBoostPurchaseFlow: null, planId: null, applicationId: null, guildId: null, onPaymentSuccess: null, onPaymentDismiss: null };
obj[0] = wrappedPredicate;
obj[1] = analyticsLocation;
obj[2] = analyticsLocations;
obj[3] = showCurrentPlan;
obj[4] = flag;
obj[5] = planId;
obj[6] = applicationId;
obj[7] = guildId;
obj[8] = onPaymentSuccess;
obj[9] = onPaymentDismiss;
2026-07-20 16:05:17 +00:00
navigation.push(PREMIUM_PLAN_SELECT, obj);
} else {
2026-07-29 08:29:29 +00:00
obj = { initialRoute: null, analyticsLocation: null, analyticsLocations: null, predicate: null, showCurrentPlan: null, isBoostPurchaseFlow: null, planId: null, applicationId: null, guildId: null, onBack: null, onPaymentSuccess: null, onPaymentDismiss: null };
obj[0] = PREMIUM_PLAN_SELECT;
obj[1] = analyticsLocation;
obj[2] = analyticsLocations;
obj[3] = wrappedPredicate;
obj[4] = showCurrentPlan;
obj[5] = flag;
obj[6] = planId;
obj[7] = applicationId;
obj[8] = guildId;
obj[9] = tmp;
obj[10] = onPaymentSuccess;
obj[11] = onPaymentDismiss;
2026-08-05 07:35:12 +00:00
const obj3 = flag2(4460);
obj3.pushLazy(require(1959) /* asyncRequireImpl */(6768, dependencyMap.paths), obj, require(6768) /* PremiumModal */.PREMIUM_KEY);
const tmp7 = require(1959) /* asyncRequireImpl */(6768, dependencyMap.paths);
2026-07-20 16:05:17 +00:00
}
2026-08-05 07:35:12 +00:00
let result = require(5907) /* getSanitizedRestrictedGuilds */.trackUserSettingsPaneViewed({ destinationPane: PREMIUM_PLAN_SELECT });
2026-07-20 16:05:17 +00:00
};