Files
2026-07-28 01:06:53 +03:00

98 lines
5.7 KiB
TypeScript

/* Metro module 15081; source: modules/threads/ThreadMemberListHooks.tsx; dependencies: [31, 1938, 7236, 482, 4594, 6903, 6890, 566, 1244, 2] */
import GuildRoleStore from '../../stores/GuildRoleStore.tsx'; /* Metro dependency 1938 */
import UseMountEffect from '../../hooks/useMountEffect.tsx'; /* Metro dependency 4594 */
import ThreadMemberListStore from './ThreadMemberListStore.tsx'; /* Metro dependency 7236 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactModule from '../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as ConstantsModule from '../../external/discord_common/js/shared/Constants.tsx'; /* Metro dependency 482 */
import * as FluxModule from '../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as IndexNativeModule from '../../intl/index.native.tsx'; /* Metro dependency 1244 */
function _fun114097(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#114097, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:6, offset: 0x02413eb0, size: 183 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_7 = [];
(FileImportTrackerModule).fileFinishedImporting('modules/threads/ThreadMemberListHooks.tsx');
exports.useThreadMemberListSections = useThreadMemberListSections;
function useThreadMemberListSections(a0, a1) { // fn#114098, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:258, offset: 0x02413f67, size: 221 bytes, params: 3, frame: 20
const env0_0 = a0;
const env0_1 = a1;
(UseMountEffect)(_fun114099);
const value2 = (FluxModule).useStateFromStores([GuildRoleStore], _fun114100);
const {version,
members} = (FluxModule).useStateFromStoresObject([ThreadMemberListStore],
_fun114101);
const members2 = members;
const value4 = a1 == null;
const binding = members2;
const useMemo = binding.useMemo;
return members != null ? Reflect.apply(useMemo, binding, [_fun114102, [value2, members, version, value4]]) : env0_7;
function _fun114099() { // fn#114099, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:309, offset: 0x02414044, size: 102 bytes, params: 1, frame: 18
var value3;
var moduleValue;
const value2 = undefined;
if ((require == null ? value2 : require.id) != null) {
value3 = environment.__proto__;
moduleValue = require(6903) /* metro dependency 6903: GuildSubscriptionsActionCreators */;
moduleValue.subscribeChannel(require.id, env0_0,
(require(6890) /* metro dependency 6890: GuildChannelSubscriptions */).DEFAULT_RANGES);
}
return value2;
}
function _fun114100() { // fn#114100, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:440, offset: 0x024140aa, size: 48 bytes, params: 1, frame: 12
return require != null ? GuildRoleStore.getSortedRoles(require.id) : [];
}
function _fun114101() { // fn#114101, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:520, offset: 0x024140da, size: 52 bytes, params: 1, frame: 12
const object = {};
const threadMemberListStoreBinding = ThreadMemberListStore;
const getMemberListVersion = threadMemberListStoreBinding.getMemberListVersion;
const binding = env0_0;
object.version = Reflect.apply(getMemberListVersion, threadMemberListStoreBinding, [binding]);
object.members = threadMemberListStoreBinding.getMemberListSections(binding);
return object;
}
function _fun114102() { // fn#114102, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15278:646, offset: 0x0241410e, size: 232 bytes, params: 1, frame: 21
var environment;
var value;
if (result) {
value = environment.__proto__;
return env1_7;
}
value = env0_2.filter(function(a0) {
return a0.hoist;
});
value = value.map(function(a0) {
return {id: a0.id, label: a0.name};
});
const push = value.push;
const object = {};
const ONLINE = StatusTypes.ONLINE;
object.id = ONLINE;
const intl = (IndexNativeModule).intl;
let string = intl.string;
const t = (IndexNativeModule).t;
const WbGtnH = t.WbGtnH;
object.label = Reflect.apply(string, intl, [WbGtnH]);
const OFFLINE = StatusTypes.OFFLINE;
string = intl.string;
const Vv0abJ = t.Vv0abJ;
Reflect.apply(push, value, [object, {id: OFFLINE, label: Reflect.apply(string, intl, [Vv0abJ])}]);
return value.map(function({id, label}) {
var r2;
r2 = members == null || members[id] == null ? undefined : members[id].userIds;
r2 = r2 ?? [];
return {label: label, userIds: r2, id: id, roleId: id};
});
}
}
}
global.__d(_fun114097, 15081, [31, 1938, 7236, 482, 4594, 6903, 6890, 566, 1244,
2]) /* metro module 15081, dependencies: [31, 1938, 7236, 482, 4594, 6903, 6890, 566, 1244, 2] */;