decord/source/components_native/premium/PremiumActivatedAlert.tsx

243 lines
9.6 KiB
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 7522
// Function ID: 7523
2026-07-29 08:29:29 +00:00
// Name: PremiumActivatedAlert
2026-08-25 06:04:03 +00:00
// Dependencies: [19, 17, 676, 21, 4380, 5265, 4043, 7523, 7524, 7525, 7526, 7527, 7472, 7473, 7528, 7529, 7530, 7531, 7532, 7533, 7534, 1363, 7535, 7536, 7537, 7538, 7539, 7540, 7541, 7542, 7543, 1236, 4315, 4833, 7544, 7545, 1297, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-08-25 06:04:03 +00:00
// Module 7522 (PremiumActivatedAlert)
2026-08-24 06:08:38 +00:00
import noopAll from "noop" /* 19 */;
import getSystemLocale from "getSystemLocale" /* 1236 */;
2026-08-25 06:04:03 +00:00
import getPremiumPlanItem from "getPremiumPlanItem" /* 4043 */;
import useThemeDefault from "useTheme" /* 4315 */;
2026-08-24 06:08:38 +00:00
import get_ActivityIndicator from "get ActivityIndicator" /* 17 */;
import { SubscriptionStatusTypes } from "ME" /* 676 */;
import jsxProd from "jsxProd" /* 21 */;
2026-08-25 06:04:03 +00:00
import createCacheKey from "createCacheKey" /* 4380 */;
2026-07-23 10:11:24 +00:00
2026-08-24 06:08:38 +00:00
require = arg1;
noopAll;
2026-07-29 08:29:29 +00:00
({ Image: c3, ImageBackground: c4, View: c5 } = get_ActivityIndicator);
2026-08-24 06:08:38 +00:00
({ jsx: error, jsxs: closure_8 } = jsxProd);
2026-07-29 08:29:29 +00:00
createCacheKey = { alert: { overflow: "hidden", paddingBottom: 24 }, header: { alignSelf: "stretch", margin: -16, padding: 16, height: 100, position: "relative" }, headerImage: { position: "absolute", left: "50%" }, body: { paddingHorizontal: 16, marginTop: 40, maxWidth: 300, alignSelf: "center", alignItems: "center" }, logoPlusPremiumGuild: { marginTop: 3, width: 101, height: 19 }, description: null };
createCacheKey = { fontSize: 14, lineHeight: 16, textAlign: "center", marginTop: 20, color: require("result").DARK_PRIMARY_300_LIGHT_PRIMARY_400 };
createCacheKey[5] = createCacheKey;
2026-08-24 06:08:38 +00:00
let closure_9 = createCacheKey.createStyles(createCacheKey);
2026-07-29 08:29:29 +00:00
let closure_10 = createCacheKey.createStyles((arg0) => {
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === arg0) {
2026-07-29 08:29:29 +00:00
let obj = { headerImage: null };
obj[0] = { marginLeft: -27, width: 88, top: 18 };
2026-07-20 16:05:17 +00:00
return obj;
2026-08-25 06:04:03 +00:00
} else if (tmp(4043).Branding.TIER_1 === arg0) {
2026-07-29 08:29:29 +00:00
obj = { headerImage: null };
obj[0] = { marginLeft: -27, width: 87, top: 18 };
2026-07-20 16:05:17 +00:00
return obj;
2026-08-25 06:04:03 +00:00
} else if (tmp(4043).Branding.BUNDLE === arg0) {
2026-08-24 06:08:38 +00:00
obj1 = { headerImage: null };
2026-07-29 08:29:29 +00:00
obj1[0] = { marginLeft: -29.5, width: 91, top: 18 };
2026-07-20 16:05:17 +00:00
return obj1;
2026-08-25 06:04:03 +00:00
} else if (tmp(4043).Branding.TIER_2 === arg0) {
2026-07-29 08:29:29 +00:00
const obj2 = { headerImage: null };
obj2[0] = { marginLeft: -58, width: 122, height: 90, top: 18 };
2026-07-20 16:05:17 +00:00
return obj2;
2026-08-25 06:04:03 +00:00
} else if (tmp(4043).Branding.PREMIUM_GUILD === arg0) {
2026-07-29 08:29:29 +00:00
obj = { headerImage: null };
obj[0] = { marginLeft: -54, width: 140, top: 18 };
2026-07-20 16:05:17 +00:00
return obj;
}
});
2026-07-29 08:29:29 +00:00
let closure_11 = createCacheKey.createStyles((arg0) => {
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.BUNDLE === arg0) {
2026-07-29 08:29:29 +00:00
let obj = { animation: null };
obj[0] = { borderRadius: 6 };
2026-07-20 16:05:17 +00:00
return obj;
} else {
2026-08-25 06:04:03 +00:00
if (tmp(4043).Branding.TIER_0 !== arg0) {
if (tmp(4043).Branding.TIER_1 !== arg0) {
if (tmp(4043).Branding.TIER_2 !== arg0) {
if (tmp(4043).Branding.PREMIUM_GUILD === arg0) {
2026-07-29 08:29:29 +00:00
obj = { animation: null };
obj[0] = { borderRadius: 9 };
2026-07-20 16:05:17 +00:00
return obj;
}
}
}
}
2026-07-29 08:29:29 +00:00
obj = { animation: null };
obj[0] = { borderRadius: 5 };
return obj;
2026-07-20 16:05:17 +00:00
}
});
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("components_native/premium/PremiumActivatedAlert.tsx");
2026-07-20 16:05:17 +00:00
export default function PremiumActivatedAlert(onClose) {
const subscription = onClose.subscription;
2026-08-24 06:08:38 +00:00
const tmp = callback();
2026-07-20 16:05:17 +00:00
let renewalMutations = subscription;
if (null != subscription.renewalMutations) {
const _Object = Object;
renewalMutations = subscription;
if (0 !== Object.keys(subscription.renewalMutations).length) {
renewalMutations = subscription;
if (subscription.renewalMutations.paymentGatewayPlanId !== subscription.paymentGatewayPlanId) {
renewalMutations = subscription;
if (subscription.status !== SubscriptionStatusTypes.CANCELED) {
renewalMutations = subscription.renewalMutations;
}
}
}
}
2026-08-24 06:08:38 +00:00
const tmp6 = useThemeDefault();
let obj = getPremiumPlanItem;
2026-07-20 16:05:17 +00:00
const premiumBranding = obj.getPremiumBranding(renewalMutations);
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === premiumBranding) {
2026-07-29 08:29:29 +00:00
obj = { logo: null };
obj[0] = { width: 82, height: 44 };
let tmp9 = obj;
2026-08-25 06:04:03 +00:00
} else if (tmp7(4043).Branding.TIER_1 === premiumBranding) {
2026-07-29 08:29:29 +00:00
obj = { logo: null };
obj[0] = { width: 82, height: 32 };
tmp9 = obj;
2026-07-20 16:05:17 +00:00
} else {
2026-08-25 06:04:03 +00:00
if (tmp7(4043).Branding.BUNDLE !== premiumBranding) {
if (tmp7(4043).Branding.TIER_2 !== premiumBranding) {
if (tmp7(4043).Branding.PREMIUM_GUILD === premiumBranding) {
2026-08-24 06:08:38 +00:00
obj1 = { logo: null };
2026-07-29 08:29:29 +00:00
obj1[0] = { width: 82, height: 18 };
tmp9 = obj1;
2026-07-20 16:05:17 +00:00
}
}
}
2026-07-29 08:29:29 +00:00
const obj2 = { logo: null };
obj2[0] = { width: 79, height: 32 };
tmp9 = obj2;
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
const tmp10 = callback2(premiumBranding);
2026-07-29 08:29:29 +00:00
const obj3 = { onClose: onClose.onClose, confirmText: null, style: null, children: null };
2026-08-25 06:04:03 +00:00
let tmp4Result = tmp4(4833);
2026-07-29 08:29:29 +00:00
const intl = tmp7(1236).intl;
2026-08-24 06:08:38 +00:00
obj3[1] = intl.string(getSystemLocale.t.TkTvBz);
2026-07-29 08:29:29 +00:00
obj3[2] = tmp.alert;
const obj4 = { style: tmp.header, source: null, children: null };
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === premiumBranding) {
2026-08-25 06:04:03 +00:00
tmp4Result = tmp4(7523);
} else if (tmp7(4043).Branding.TIER_1 === premiumBranding) {
tmp4Result = tmp4(7524);
} else if (tmp7(4043).Branding.TIER_2 === premiumBranding) {
tmp4Result = tmp4(7525);
} else if (tmp7(4043).Branding.BUNDLE === premiumBranding) {
tmp4Result = tmp4(7526);
} else if (tmp7(4043).Branding.PREMIUM_GUILD === premiumBranding) {
tmp4Result = tmp4(7527);
2026-07-29 08:29:29 +00:00
}
obj4[1] = tmp4Result;
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === premiumBranding) {
2026-08-25 06:04:03 +00:00
let tmp4Result1 = tmp4(7531);
} else if (tmp7(4043).Branding.TIER_1 === premiumBranding) {
tmp4Result1 = tmp4(7532);
2026-07-29 08:29:29 +00:00
} else {
2026-08-25 06:04:03 +00:00
if (tmp7(4043).Branding.BUNDLE !== premiumBranding) {
if (tmp7(4043).Branding.TIER_2 !== premiumBranding) {
if (tmp7(4043).Branding.PREMIUM_GUILD === premiumBranding) {
tmp4Result1 = tmp4(7534);
2026-07-29 08:29:29 +00:00
}
}
}
2026-08-25 06:04:03 +00:00
tmp4Result1 = tmp4(7533);
2026-07-29 08:29:29 +00:00
}
const items = [closure_7(closure_3, { source: tmp4Result1, style: tmp9.logo }), , ];
let tmp16Result = null;
2026-08-24 06:08:38 +00:00
if (premiumBranding === getPremiumPlanItem.Branding.BUNDLE) {
2026-07-29 08:29:29 +00:00
const obj6 = { source: null, style: null };
2026-08-25 06:04:03 +00:00
obj6[0] = tmp4(7544);
2026-07-29 08:29:29 +00:00
obj6[1] = tmp.logoPlusPremiumGuild;
tmp16Result = tmp16(tmp17, obj6);
}
items[1] = tmp16Result;
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === premiumBranding) {
2026-08-25 06:04:03 +00:00
let tmp4Result2 = tmp4(7472);
} else if (tmp7(4043).Branding.TIER_1 === premiumBranding) {
tmp4Result2 = tmp4(7473);
} else if (tmp7(4043).Branding.TIER_2 === premiumBranding) {
tmp4Result2 = tmp4(7528);
} else if (tmp7(4043).Branding.BUNDLE === premiumBranding) {
tmp4Result2 = tmp4(7529);
} else if (tmp7(4043).Branding.PREMIUM_GUILD === premiumBranding) {
tmp4Result2 = tmp4(7530);
2026-07-29 08:29:29 +00:00
}
const items1 = [tmp10.headerImage, tmp.headerImage];
items[2] = closure_7(closure_3, { source: tmp4Result2, style: items1 });
obj4[2] = items;
const items2 = [closure_8(closure_4, obj4), ];
const obj7 = { style: tmp.body, children: null };
const obj5 = { source: tmp4Result1, style: tmp9.logo };
2026-08-24 06:08:38 +00:00
const tmp11 = callback3(premiumBranding);
2026-07-29 08:29:29 +00:00
const tmp14 = closure_4;
const tmp21 = closure_5;
2026-08-24 06:08:38 +00:00
if (getPremiumPlanItem.Branding.TIER_0 === premiumBranding) {
2026-08-11 06:20:06 +00:00
let tmp7Result = tmp7(1363);
2026-07-29 08:29:29 +00:00
if (tmp7Result.isThemeDark(tmp6)) {
2026-08-25 06:04:03 +00:00
let tmp4Result4 = tmp4(7535);
2026-07-29 08:29:29 +00:00
} else {
2026-08-25 06:04:03 +00:00
tmp4Result4 = tmp4(7536);
2026-07-29 08:29:29 +00:00
}
} else {
2026-08-25 06:04:03 +00:00
if (tmp7(4043).Branding.TIER_1 === premiumBranding) {
2026-08-11 06:20:06 +00:00
tmp7Result = tmp7(1363);
2026-07-29 08:29:29 +00:00
if (tmp7Result.isThemeDark(tmp6)) {
2026-08-25 06:04:03 +00:00
let tmp4Result5 = tmp4(7537);
2026-07-29 08:29:29 +00:00
} else {
2026-08-25 06:04:03 +00:00
tmp4Result5 = tmp4(7538);
2026-07-29 08:29:29 +00:00
}
let tmp4Result8 = tmp4Result5;
2026-08-25 06:04:03 +00:00
} else if (tmp7(4043).Branding.TIER_2 === premiumBranding) {
2026-07-29 08:29:29 +00:00
if (tmp7Result1.isThemeDark(tmp6)) {
2026-08-25 06:04:03 +00:00
let tmp4Result6 = tmp4(7539);
2026-07-29 08:29:29 +00:00
} else {
2026-08-25 06:04:03 +00:00
tmp4Result6 = tmp4(7540);
2026-07-29 08:29:29 +00:00
}
tmp4Result8 = tmp4Result6;
2026-08-11 06:20:06 +00:00
tmp7Result1 = tmp7(1363);
2026-08-25 06:04:03 +00:00
} else if (tmp7(4043).Branding.BUNDLE === premiumBranding) {
2026-07-29 08:29:29 +00:00
if (tmp7Result2.isThemeDark(tmp6)) {
2026-08-25 06:04:03 +00:00
let tmp4Result7 = tmp4(7541);
2026-07-29 08:29:29 +00:00
} else {
2026-08-25 06:04:03 +00:00
tmp4Result7 = tmp4(7542);
2026-07-29 08:29:29 +00:00
}
tmp4Result8 = tmp4Result7;
2026-08-11 06:20:06 +00:00
tmp7Result2 = tmp7(1363);
2026-08-25 06:04:03 +00:00
} else if (tmp7(4043).Branding.PREMIUM_GUILD === premiumBranding) {
tmp4Result8 = tmp4(7543);
2026-07-29 08:29:29 +00:00
}
const obj8 = { source: null, style: null };
obj8[0] = tmp4Result8;
obj8[1] = tmp11.animation;
const items3 = [tmp16(tmp4Result3, obj8), ];
const obj9 = { style: null, children: null };
obj9[0] = tmp.description;
2026-08-25 06:04:03 +00:00
if (tmp7(4043).Branding.TIER_0 !== premiumBranding) {
if (tmp7(4043).Branding.TIER_1 !== premiumBranding) {
if (tmp7(4043).Branding.TIER_2 === premiumBranding) {
2026-07-29 08:29:29 +00:00
const intl3 = tmp7(1236).intl;
let stringResult = intl3.string(tmp7(1236).t.aTUr3Z);
2026-08-25 06:04:03 +00:00
} else if (tmp7(4043).Branding.BUNDLE === premiumBranding) {
2026-07-29 08:29:29 +00:00
const intl2 = tmp7(1236).intl;
const obj10 = { planName: null };
({ planId: obj19[0], additionalPlans: obj19[1] } = renewalMutations);
2026-08-25 06:04:03 +00:00
obj10[0] = tmp7(4043).getExternalPlanDisplayName({ planId: null, additionalPlans: null });
2026-07-29 08:29:29 +00:00
stringResult = intl2.format(tmp7(1236).t.YJUUH3, obj10);
const obj11 = { planId: null, additionalPlans: null };
2026-08-25 06:04:03 +00:00
const tmp7Result3 = tmp7(4043);
2026-07-29 08:29:29 +00:00
}
}
obj9[1] = stringResult;
items3[1] = tmp16(tmp7(1297).LegacyText, obj9);
obj7[1] = items3;
items2[1] = tmp12(tmp21, obj7);
obj3[3] = items2;
return tmp12(tmp4Result, obj3);
}
const intl4 = tmp7(1236).intl;
stringResult = intl4.string(tmp7(1236).t.knvOVz);
2026-07-20 16:05:17 +00:00
}
};