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

114 lines
4.1 KiB
TypeScript
Raw Normal View History

2026-08-24 06:08:38 +00:00
// Module ID: 8966
// Function ID: 8967
2026-07-29 08:29:29 +00:00
// Name: showUserProfileActionSheet
2026-08-24 06:08:38 +00:00
// Dependencies: [5, 4497, 4033, 1922, 2008, 4069, 8967, 4346, 8980, 2]
2026-07-29 08:29:29 +00:00
// Exports: getUserProfileActionSheetKey, getUserProfileBlockedSpeedBumpActionSheetKey, getUserProfileIgnoredSpeedBumpActionSheetKey, showUserProfileActionSheetPostConnection
2026-07-20 16:05:17 +00:00
2026-08-24 06:08:38 +00:00
// Module 8966 (showUserProfileActionSheet)
import asyncRequireImpl from "asyncRequireImpl" /* 2008 */;
import explicitContentFromProto from "explicitContentFromProto" /* 4069 */;
import ACTION_SHEET_HEIGHT_HALFDefault from "ACTION_SHEET_HEIGHT_HALF" /* 4346 */;
import closure_3 from "asyncGeneratorStep" /* 5 */;
import closure_5 from "markAllUserIdListsStale" /* 4033 */;
2026-07-23 10:11:24 +00:00
2026-08-24 06:08:38 +00:00
require = arg1;
2026-07-29 08:29:29 +00:00
function showUserProfileActionSheet(ignoreBlockedSpeedBump, arg1) {
2026-07-20 16:05:17 +00:00
const timestamp = Date.now();
2026-08-24 06:08:38 +00:00
const IgnoreProfileSpeedbumpDisabled = explicitContentFromProto.IgnoreProfileSpeedbumpDisabled;
2026-07-29 08:29:29 +00:00
if (!ignoreBlockedSpeedBump.ignoreBlockedSpeedBump) {
2026-08-24 06:08:38 +00:00
const isBlockedResult = closure_5.isBlocked(ignoreBlockedSpeedBump.userId);
const isIgnoredResult = closure_5.isIgnored(ignoreBlockedSpeedBump.userId);
2026-07-20 16:05:17 +00:00
if (isIgnoredResult) {
2026-08-24 06:08:38 +00:00
let obj = ACTION_SHEET_HEIGHT_HALFDefault;
2026-07-29 08:29:29 +00:00
const _HermesInternal = HermesInternal;
2026-07-20 16:05:17 +00:00
obj = {};
2026-07-29 08:29:29 +00:00
const combined = "UserProfileIgnoredSpeedBump" + ignoreBlockedSpeedBump.userId;
const merged = Object.assign(ignoreBlockedSpeedBump);
let str2 = "ignore";
2026-07-20 16:05:17 +00:00
if (isBlockedResult) {
2026-07-29 08:29:29 +00:00
str2 = "block";
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj.speedBumpType = str2;
obj.openedAt = timestamp;
2026-08-24 06:08:38 +00:00
obj.openLazy(tmp2(2008)(8967, tmp3.paths), combined, obj);
2026-07-20 16:05:17 +00:00
}
}
2026-08-24 06:08:38 +00:00
const tmp15 = asyncRequireImpl(8980, dependencyMap.paths);
2026-07-29 08:29:29 +00:00
const combined1 = "UserProfile" + ignoreBlockedSpeedBump.userId;
2026-07-20 16:05:17 +00:00
obj = {};
2026-07-29 08:29:29 +00:00
const merged1 = Object.assign(ignoreBlockedSpeedBump);
obj.openedAt = timestamp;
2026-08-24 06:08:38 +00:00
ACTION_SHEET_HEIGHT_HALFDefault.openLazy(tmp15, combined1, obj, "replaceAll");
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
require("processCallbacks").addPostConnectionCallback;
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/user_profile/native/showUserProfileActionSheet.tsx");
2026-07-20 16:05:17 +00:00
export default showUserProfileActionSheet;
2026-07-29 08:29:29 +00:00
export const getUserProfileActionSheetKey = function getUserProfileActionSheetKey(id) {
return "UserProfile" + id;
};
2026-07-20 16:05:17 +00:00
export const getUserProfileBlockedSpeedBumpActionSheetKey = function getUserProfileBlockedSpeedBumpActionSheetKey(arg0) {
return "UserProfileBlockedSpeedBump" + arg0;
};
2026-07-29 08:29:29 +00:00
export const getUserProfileIgnoredSpeedBumpActionSheetKey = function getUserProfileIgnoredSpeedBumpActionSheetKey(arg0) {
return "UserProfileIgnoredSpeedBump" + arg0;
};
2026-07-20 16:05:17 +00:00
export const showUserProfileActionSheetPostConnection = function showUserProfileActionSheetPostConnection(arg0) {
2026-08-24 06:08:38 +00:00
closure_0 = arg0;
2026-07-29 08:29:29 +00:00
addPostConnectionCallback(callback(function*() {
if (paths === 2) {
paths = 3;
HermesBuiltin.throwTypeError();
} else if (tmp3 === 3) {
if (arg0 === 1) {
throw arg1;
} else if (arg0 === 2) {
let obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
2026-08-24 06:08:38 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} else {
try {
paths = 2;
if (0 === c1) {
if (arg0 === 1) {
paths = 3;
throw arg1;
} else if (arg0 === 2) {
paths = 3;
obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
const userId = tmp4;
c1 = 1;
paths = 1;
2026-08-24 06:08:38 +00:00
obj1 = { value: null, done: false };
obj1[0] = closure_1_0(paths[4])(paths[3], paths.paths);
2026-07-29 08:29:29 +00:00
return obj1;
}
} else if (arg0 === 1) {
paths = 3;
throw arg1;
} else if (arg0 === 2) {
paths = 3;
obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
if (null != _default.getUser(userId.userId)) {
2026-08-24 06:08:38 +00:00
closure_1_6(userId);
2026-07-29 08:29:29 +00:00
}
paths = 3;
2026-08-24 06:08:38 +00:00
return { value: "HermesInternal", done: null };
2026-07-29 08:29:29 +00:00
}
} catch (tmp14) {
paths = tmp;
throw tmp14;
}
}
}));
2026-07-20 16:05:17 +00:00
};