49 lines
1.9 KiB
TypeScript
49 lines
1.9 KiB
TypeScript
// Module ID: 6199
|
|
// Function ID: 55607
|
|
// Name: isSpendingLimitError
|
|
// Dependencies: [4030, 3799, 6200, 4472, 1212, 5817, 4141, 2]
|
|
// Exports: isSpendingLimitError, showSpendingLimitReachedAlert
|
|
|
|
// Module 6199 (isSpendingLimitError)
|
|
const result = require("useUserIdsForLinkStatus").fileFinishedImporting("modules/parent_tools/native/showSpendingLimitReachedAlert.tsx");
|
|
|
|
export const isSpendingLimitError = function isSpendingLimitError(billingError) {
|
|
let tmp = billingError instanceof require(4030) /* V6OrEarlierAPIError */.BillingError;
|
|
if (tmp) {
|
|
let tmp4 = billingError.code === require(3799) /* _isNativeReflectConstruct */.ErrorCodes.BILLING_SPENDING_LIMIT_REACHED;
|
|
if (!tmp4) {
|
|
tmp4 = billingError.code === require(3799) /* _isNativeReflectConstruct */.ErrorCodes.BILLING_SPENDING_LIMIT_WILL_EXCEED;
|
|
}
|
|
tmp = tmp4;
|
|
}
|
|
return tmp;
|
|
};
|
|
export const showSpendingLimitReachedAlert = function showSpendingLimitReachedAlert() {
|
|
let obj = activeLinkUserIds(6200);
|
|
activeLinkUserIds = obj.getActiveLinkUserIds();
|
|
let obj1 = importDefault(4472);
|
|
obj = {};
|
|
const intl = activeLinkUserIds(1212).intl;
|
|
obj.title = intl.string(activeLinkUserIds(1212).t.QJKKrT);
|
|
const intl2 = activeLinkUserIds(1212).intl;
|
|
obj.body = intl2.string(activeLinkUserIds(1212).t["73Islf"]);
|
|
obj.isDismissable = true;
|
|
if (activeLinkUserIds.length > 0) {
|
|
obj = {};
|
|
const intl3 = activeLinkUserIds(1212).intl;
|
|
obj.confirmText = intl3.string(activeLinkUserIds(1212).t.GF9RCX);
|
|
obj.onConfirm = function onConfirm() {
|
|
let obj = activeLinkUserIds(outer1_2[5]);
|
|
obj.popLayer();
|
|
obj = { recipientIds: activeLinkUserIds };
|
|
outer1_1(outer1_2[6]).openPrivateChannel(obj);
|
|
};
|
|
const intl4 = activeLinkUserIds(1212).intl;
|
|
obj.cancelText = intl4.string(activeLinkUserIds(1212).t.L5eIZ2);
|
|
obj1 = obj;
|
|
} else {
|
|
obj1 = {};
|
|
}
|
|
const merged = Object.assign(obj1);
|
|
obj1.show(obj);
|
|
};
|