decord/beta/source/utils/getDeprecatedModalData.tsx

60 lines
1.5 KiB
TypeScript
Raw Permalink Normal View History

2026-10-12 16:32:48 +00:00
// Module ID: 5936
// Function ID: 5937
// Name: getDeprecatedModalData
2026-10-12 16:32:48 +00:00
// Dependencies: [5081, 1085, 2]
// Exports: default
2026-10-12 16:32:48 +00:00
// Module 5936 (getDeprecatedModalData)
2026-10-07 22:43:51 +00:00
import Constants from "Constants" /* 1085 */;
2026-10-12 16:32:48 +00:00
import AccessibilityStore from "AccessibilityStore" /* 5081 */;
2026-10-01 14:13:23 +00:00
import size from "module_2" /* 2 */;
2026-10-01 14:13:23 +00:00
const ModalAnimation = Constants.ModalAnimation;
const result = size.fileFinishedImporting("utils/getDeprecatedModalData.tsx");
export default function getDeprecatedModalData(modal, key, props) {
2026-10-01 14:13:23 +00:00
let animation;
let backdropStyle;
let flag;
let flag2;
let flag3;
let str2;
let tmp = arg3;
if (arg3 === undefined) {
tmp = null;
}
let str = key.key;
if (str == null) {
str = tmp;
}
if (str == null) {
str = "modal";
}
2026-10-01 14:13:23 +00:00
const obj = { key: str, modal, animation, shouldPersistUnderModals: flag, props, backdropStyle, backdropInstant: flag2, disableAnimation: flag3, closable: typeof key.closable !== "boolean" || key.closable, label: str2, callbacks: {} };
animation = key.animation;
if (animation == null) {
animation = AccessibilityStore.useReducedMotion ? tmp3.FADE : tmp3.SLIDE_UP;
}
2026-10-01 14:13:23 +00:00
flag = key.shouldPersistUnderModals;
if (flag == null) {
flag = false;
}
backdropStyle = key.backdropStyle;
if (backdropStyle == null) {
backdropStyle = null;
}
flag2 = key.backdropInstant;
if (flag2 == null) {
flag2 = false;
}
flag3 = key.disableAnimation;
if (flag3 == null) {
flag3 = false;
}
str2 = key.label;
if (str2 == null) {
str2 = "";
}
return obj;
};