decord/source/modules/oauth2/Utils.tsx

59 lines
2.7 KiB
TypeScript
Raw Normal View History

2026-08-05 07:35:12 +00:00
// Module ID: 10401
// Function ID: 10402
2026-07-20 16:05:17 +00:00
// Name: getApplicationDetailsText
2026-08-05 07:35:12 +00:00
// Dependencies: [676, 10402, 1236, 4787, 2]
2026-07-20 16:05:17 +00:00
// Exports: getApplicationDetailsText, isContentClassificationRestricted
2026-08-05 07:35:12 +00:00
// Module 10401 (getApplicationDetailsText)
2026-07-23 10:11:24 +00:00
import { MarketingURLs } from "ME";
let result = require("getSystemLocale").fileFinishedImporting("modules/oauth2/Utils.tsx");
2026-07-20 16:05:17 +00:00
export const getApplicationDetailsText = function getApplicationDetailsText(application) {
2026-08-05 07:35:12 +00:00
let obj = require(10402) /* useIsSocialLayerParentApplication */;
2026-07-20 16:05:17 +00:00
const isSocialLayerParentApplication = obj.getIsSocialLayerParentApplication(application);
if (null != application.privacy_policy_url) {
if (null != application.terms_of_service_url) {
2026-07-29 08:29:29 +00:00
const t4 = tmp(1236).t;
const intl4 = tmp(1236).intl;
obj = { application: null, privacyPolicyURL: null, termsOfServiceURL: null, discordPrivacyPolicyURL: null };
({ name: obj5[0], privacy_policy_url: obj5[1], terms_of_service_url: obj5[2] } = application);
obj[3] = MarketingURLs.PRIVACY;
2026-07-20 16:05:17 +00:00
return intl4.format(isSocialLayerParentApplication ? t4.yVfotv : t4.rxlyKL, obj);
}
}
if (null != application.privacy_policy_url) {
2026-07-29 08:29:29 +00:00
const t3 = tmp(1236).t;
const intl3 = tmp(1236).intl;
obj = { application: null, privacyPolicyURL: null, discordPrivacyPolicyURL: null };
({ name: obj4[0], privacy_policy_url: obj4[1] } = application);
obj[2] = MarketingURLs.PRIVACY;
2026-07-20 16:05:17 +00:00
return intl3.format(isSocialLayerParentApplication ? t3.pYVSah : t3.TBvmM2, obj);
} else if (null != application.terms_of_service_url) {
2026-07-29 08:29:29 +00:00
const t2 = tmp(1236).t;
const intl2 = tmp(1236).intl;
const obj1 = { application: null, termsOfServiceURL: null, discordPrivacyPolicyURL: null };
({ name: obj3[0], terms_of_service_url: obj3[1] } = application);
obj1[2] = MarketingURLs.PRIVACY;
2026-07-23 10:11:24 +00:00
return intl2.format(isSocialLayerParentApplication ? t2.nBLOp5 : t2["q0T/Q1"], obj1);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
const t = tmp(1236).t;
const intl = tmp(1236).intl;
const obj2 = { application: null, discordPrivacyPolicyURL: null };
obj2[0] = application.name;
obj2[1] = MarketingURLs.PRIVACY;
2026-07-23 10:11:24 +00:00
return intl.format(isSocialLayerParentApplication ? t["8LemYv"] : t["3Ywek3"], obj2);
2026-07-20 16:05:17 +00:00
}
};
2026-07-29 08:29:29 +00:00
export const isContentClassificationRestricted = function isContentClassificationRestricted(content_classification, closure_32) {
2026-07-20 16:05:17 +00:00
let result = null != content_classification;
if (result) {
2026-08-05 07:35:12 +00:00
result = require(4787) /* isAgeRestrictedContentClassification */.isAgeRestrictedContentClassification(content_classification);
const obj = require(4787) /* isAgeRestrictedContentClassification */;
2026-07-20 16:05:17 +00:00
}
if (result) {
2026-07-29 08:29:29 +00:00
result = false === closure_32;
2026-07-20 16:05:17 +00:00
}
return result;
};