decord/source/modules/user_profile/native/ActionSheetBackdropToast.tsx

104 lines
4.8 KiB
TypeScript
Raw Normal View History

2026-07-29 08:29:29 +00:00
// Module ID: 12228
// Function ID: 12229
2026-07-20 16:05:17 +00:00
// Name: ActionSheetBackdropToast
2026-07-29 08:29:29 +00:00
// Dependencies: [19, 17, 5244, 21, 500, 4189, 712, 1581, 1474, 5140, 4050, 4190, 4185, 2]
2026-07-20 16:05:17 +00:00
// Exports: ActionSheetBackdropToast
2026-07-29 08:29:29 +00:00
// Module 12228 (ActionSheetBackdropToast)
import noop from "noop";
2026-07-23 10:11:24 +00:00
import get_ActivityIndicator from "get ActivityIndicator";
import { ACTION_SHEET_START_HEIGHT_RATIO as closure_5 } from "ACTION_SHEET_START_HEIGHT_RATIO";
import { jsx } from "jsxProd";
import set from "set";
2026-07-29 08:29:29 +00:00
import createCacheKey from "createCacheKey";
2026-07-23 10:11:24 +00:00
import set from "ACTION_SHEET_START_HEIGHT_RATIO";
2026-07-29 08:29:29 +00:00
let StyleSheet;
let c4;
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-07-29 08:29:29 +00:00
({ View: c4, StyleSheet } = get_ActivityIndicator);
2026-07-23 10:11:24 +00:00
set = set.isIOS();
2026-07-29 08:29:29 +00:00
set = { container: null, toast: null };
2026-07-23 10:11:24 +00:00
set = {};
2026-07-29 08:29:29 +00:00
const merged = Object.assign(StyleSheet.absoluteFillObject);
set.flex = 1;
set.alignItems = "center";
set.justifyContent = "center";
set[0] = set;
createCacheKey = { position: "absolute", bottom: 16, backgroundColor: require("Themes").colors.MOBILE_TOAST_BACKGROUND_DEFAULT, borderRadius: require("Themes").radii.round, paddingTop: 6, paddingBottom: 8, paddingHorizontal: 16 };
set[1] = createCacheKey;
set = createCacheKey.createStyles(set);
2026-07-20 16:05:17 +00:00
let closure_9 = { code: "function ActionSheetBackdropToastTsx1(){const{isInIOS,isExpanded,maxDynamicContentSize,TOAST_BOTTOM_MARGIN,nonExpandedHeight,ACTION_SHEET_START_HEIGHT_RATIO,TOAST_BOTTOM_GAP,positionDelta,TOAST_ANIMATION_Y_DELTA,opacity}=this.__closure;return{bottom:(isInIOS?isExpanded?maxDynamicContentSize+TOAST_BOTTOM_MARGIN:nonExpandedHeight+TOAST_BOTTOM_MARGIN:isExpanded?maxDynamicContentSize+TOAST_BOTTOM_MARGIN:ACTION_SHEET_START_HEIGHT_RATIO*maxDynamicContentSize+TOAST_BOTTOM_GAP)+ +(1-positionDelta.get())*TOAST_ANIMATION_Y_DELTA,opacity:opacity.get()};}" };
2026-07-23 10:11:24 +00:00
let result = set.fileFinishedImporting("modules/user_profile/native/ActionSheetBackdropToast.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export const ActionSheetBackdropToast = function ActionSheetBackdropToast(children) {
const isExpanded = children.isExpanded;
let importDefault;
let dependencyMap;
let sharedValue;
let sharedValue1;
2026-07-23 10:11:24 +00:00
const tmp = set();
2026-07-29 08:29:29 +00:00
const height = importDefault(1474)().height;
2026-07-23 10:11:24 +00:00
let result = height * closure_5;
importDefault = result;
2026-07-29 08:29:29 +00:00
const diff = height - isExpanded(5140).NAV_BAR_HEIGHT_MULTILINE - importDefault(1581)().top;
dependencyMap = diff;
let obj = isExpanded(4050);
sharedValue = obj.useSharedValue(0);
let obj1 = isExpanded(4050);
sharedValue1 = obj1.useSharedValue(0);
2026-07-20 16:05:17 +00:00
const items = [sharedValue, sharedValue1];
2026-07-23 10:11:24 +00:00
const effect = sharedValue.useEffect(() => {
2026-07-29 08:29:29 +00:00
let obj = isExpanded(_undefined[10]);
obj = { duration: 200, easing: null };
let Easing = isExpanded(_undefined[10]).Easing;
obj[1] = Easing.in(isExpanded(_undefined[10]).Easing.ease);
let result = sharedValue.set(obj.withDelay(100, isExpanded(_undefined[11]).withTiming(1, obj)));
let obj2 = isExpanded(_undefined[11]);
obj = { duration: 300, easing: null };
const Easing2 = isExpanded(_undefined[10]).Easing;
obj[1] = Easing2.in(isExpanded(_undefined[10]).Easing.linear);
let result1 = sharedValue1.set(isExpanded(_undefined[11]).withTiming(1, obj));
2026-07-20 16:05:17 +00:00
return () => {
2026-07-29 08:29:29 +00:00
let obj = outer1_0(outer1_2[10]);
const result = noop.set(obj.withDelay(200, outer1_0(outer1_2[11]).withTiming(0)));
const obj2 = outer1_0(outer1_2[11]);
obj = { duration: 200, easing: null };
const Easing = outer1_0(outer1_2[10]).Easing;
obj[1] = Easing.out(outer1_0(outer1_2[10]).Easing.exp);
const result1 = closure_4.set(outer1_0(outer1_2[11]).withTiming(0, obj));
2026-07-20 16:05:17 +00:00
};
}, items);
const fn = function x() {
2026-07-23 10:11:24 +00:00
if (outer1_7) {
2026-07-20 16:05:17 +00:00
if (tmp) {
2026-07-29 08:29:29 +00:00
let sum = c2 + 24;
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
sum = c1 + 24;
2026-07-20 16:05:17 +00:00
}
} else {
if (tmp) {
2026-07-29 08:29:29 +00:00
let sum1 = c2 + 24;
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
sum1 = outer1_5 * c2 + 46;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const obj = { bottom: null, opacity: null };
obj[0] = sum1 + 15 * (1 - sharedValue.get());
obj[1] = sharedValue1.get();
2026-07-20 16:05:17 +00:00
return obj;
}
};
2026-07-23 10:11:24 +00:00
obj = { isInIOS: set, isExpanded, maxDynamicContentSize: diff, TOAST_BOTTOM_MARGIN: 24, nonExpandedHeight: result, ACTION_SHEET_START_HEIGHT_RATIO: closure_5, TOAST_BOTTOM_GAP: 46, positionDelta: sharedValue, TOAST_ANIMATION_Y_DELTA: 15, opacity: sharedValue1 };
2026-07-20 16:05:17 +00:00
fn.__closure = obj;
fn.__workletHash = 9630436597435;
fn.__initData = closure_9;
2026-07-29 08:29:29 +00:00
obj = { style: items1, pointerEvents: "none", children: null };
2026-07-23 10:11:24 +00:00
items1 = [tmp.container];
2026-07-29 08:29:29 +00:00
const animatedStyle = isExpanded(4050).useAnimatedStyle(fn);
obj1 = { style: items2, children: null };
2026-07-23 10:11:24 +00:00
items2 = [tmp.toast, animatedStyle];
2026-07-29 08:29:29 +00:00
obj1[1] = jsx(isExpanded(4185).Text, { variant: "text-sm/medium", color: "mobile-text-heading-primary", children: children.text });
obj[2] = jsx(importDefault(4050).View, { style: items2, children: null });
return <sharedValue1 style={items1} pointerEvents="none">{null}</sharedValue1>;
2026-07-20 16:05:17 +00:00
};