decord/source/modules/chat/useTypingUsersIds.tsx

62 lines
1.8 KiB
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 11534
// Function ID: 11535
2026-07-20 16:05:17 +00:00
// Name: useTypingUserIds
2026-08-25 06:04:03 +00:00
// Dependencies: [4034, 11533, 1922, 589, 2]
2026-07-20 16:05:17 +00:00
// Exports: useTypingUserIds
2026-08-25 06:04:03 +00:00
// Module 11534 (useTypingUserIds)
import closure_2 from "markAllUserIdListsStale" /* 4034 */;
import closure_3 from "handleTypingStart" /* 11533 */;
2026-08-24 06:08:38 +00:00
import closure_4 from "mergeGuildAvatar" /* 1922 */;
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/chat/useTypingUsersIds.tsx");
2026-07-20 16:05:17 +00:00
export const useTypingUserIds = function useTypingUserIds(id, arg1) {
2026-07-23 10:11:24 +00:00
const _require = id;
2026-07-29 08:29:29 +00:00
let MAX_SAFE_INTEGER = arg1;
2026-07-20 16:05:17 +00:00
if (arg1 === undefined) {
const _Number = Number;
MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER;
}
2026-08-24 06:08:38 +00:00
let items = [closure_4, closure_3, closure_2];
2026-07-20 16:05:17 +00:00
const items1 = [id, MAX_SAFE_INTEGER];
2026-07-23 10:11:24 +00:00
return _require(MAX_SAFE_INTEGER[3]).useStateFromStoresArray(items, () => {
2026-08-24 06:08:38 +00:00
const currentUser = closure_1_4.getCurrentUser();
2026-07-29 08:29:29 +00:00
if (currentUser != null) {
2026-08-24 06:08:38 +00:00
id = currentUser.id;
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
const typingUsers = closure_1_3.getTypingUsers(closure_0);
2026-07-20 16:05:17 +00:00
const items = [];
for (const key10013 in typingUsers) {
let tmp7 = key10013;
2026-07-23 10:11:24 +00:00
let tmp8 = MAX_SAFE_INTEGER;
if (items.length >= MAX_SAFE_INTEGER) {
2026-07-20 16:05:17 +00:00
break;
} else {
2026-08-24 06:08:38 +00:00
let tmp3 = closure_1_4;
let user = closure_1_4.getUser(key10013);
2026-07-20 16:05:17 +00:00
if (null == user) {
continue;
} else {
if (user.id === id) {
continue;
} else {
2026-08-24 06:08:38 +00:00
let tmp5 = closure_1_2;
if (closure_1_2.isBlockedOrIgnored(user.id)) {
2026-07-20 16:05:17 +00:00
continue;
} else {
let arr = items.push(user.id);
2026-07-23 10:11:24 +00:00
continue;
2026-07-20 16:05:17 +00:00
}
continue;
}
continue;
}
continue;
}
}
return items;
}, items1);
};