decord/source/modules/launchpad/native/shared/DMChannel.tsx

90 lines
3.5 KiB
TypeScript
Raw Normal View History

2026-09-02 09:53:35 +00:00
// Module ID: 16807
// Function ID: 16808
// Dependencies: [19, 4702, 21, 4489, 10872, 4478, 709, 16793, 16165, 15142, 11, 4935, 16794, 5076, 16806, 16797, 10214, 4171, 4674, 2]
2026-07-20 16:05:17 +00:00
2026-09-02 09:53:35 +00:00
// Module 16807
import ThemesDefault from "Themes" /* 709 */;
2026-08-24 06:08:38 +00:00
import importAllResult from "noop" /* 19 */;
2026-09-01 10:26:29 +00:00
import { UnreadSetting } from "ReadStateTypes" /* 4702 */;
2026-08-24 06:08:38 +00:00
import { jsx } from "jsxProd" /* 21 */;
2026-09-01 10:26:29 +00:00
import createCacheKey from "createCacheKey" /* 4478 */;
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-07-29 08:29:29 +00:00
let c3 = importAllResult;
let obj = { pressable: { flex: 1 }, pressableUnderlayColor: null };
2026-08-24 06:08:38 +00:00
obj = { backgroundColor: ThemesDefault.colors.INTERACTIVE_BACKGROUND_ACTIVE };
2026-07-29 08:29:29 +00:00
obj[1] = obj;
let closure_6 = createCacheKey.createStyles(obj);
2026-07-22 07:54:56 +00:00
const memoResult = importAllResult.memo(function DMChannel(navigationReplace) {
2026-07-20 16:05:17 +00:00
({ channel, muted } = navigationReplace);
if (muted === undefined) {
muted = false;
}
let flag = navigationReplace.navigationReplace;
if (flag === undefined) {
flag = false;
}
const tmp = callback();
2026-09-02 09:53:35 +00:00
let obj = channel(16165);
2026-07-20 16:05:17 +00:00
const baseChannelUnreadBadgeState = obj.useBaseChannelUnreadBadgeState(channel, muted);
2026-07-29 08:29:29 +00:00
({ unread, mentionCount } = baseChannelUnreadBadgeState);
2026-09-02 09:53:35 +00:00
const tmp7 = flag(15142)(channel, { unread });
2026-07-20 16:05:17 +00:00
let extractTimestampResult;
2026-07-29 08:29:29 +00:00
if (null != tmp7) {
let tmp2Result = tmp2(11);
extractTimestampResult = tmp2Result.extractTimestamp(tmp7.id);
2026-07-20 16:05:17 +00:00
}
let str = "text-muted";
if (unread) {
str = "text-muted";
if (!muted) {
str = "text-default";
}
}
2026-09-02 09:53:35 +00:00
const tmp4 = flag(16793)();
2026-09-01 10:26:29 +00:00
const fontScale = channel(4935).useFontScale();
2026-09-02 09:53:35 +00:00
tmp2Result = tmp2(16794);
2026-07-20 16:05:17 +00:00
obj = { style: items, underlayColor: tmp.pressableUnderlayColor.backgroundColor };
2026-07-29 08:29:29 +00:00
items = [tmp.pressable, { borderRadius: tmp4.container.borderRadius }];
2026-08-24 06:08:38 +00:00
obj = {
onPress: importAllResult.useCallback(() => {
let obj = channel(closure_1_2[3]);
obj = { navigationReplace: flag };
obj.transitionToChannel(channel.id, obj);
}, items1),
onLongPress: importAllResult.useCallback(() => channel(closure_1_2[4]).openChannelLongPressActionSheet(channel.id), items2)
};
items1 = [channel.id, flag];
items2 = [channel.id];
2026-07-29 08:29:29 +00:00
const merged = Object.assign(obj);
2026-08-24 06:08:38 +00:00
obj1 = { channel, unread, resolvedUnreadSetting: UnreadSetting.ALL_MESSAGES, muted, mentionCount, unreadBadge: null, subtitle: null, latestMessageTimestamp: null, channelName: null, fontScale: null };
2026-09-01 10:26:29 +00:00
const tmp5Result = channel(4935);
2026-09-02 09:53:35 +00:00
obj1[5] = jsx(flag(16797), { unread, resolvedUnreadSetting: UnreadSetting.ALL_MESSAGES, muted });
2026-07-29 08:29:29 +00:00
let tmp11Result = null != tmp7;
if (tmp11Result) {
const obj3 = { channel: null, message: null, color: null, muted: null, layout: null };
obj3[0] = channel;
obj3[1] = tmp7;
obj3[2] = str;
obj3[3] = muted;
2026-09-01 10:26:29 +00:00
obj3[4] = tmp5(4171).ChannelListLayoutTypes.COMPACT;
2026-09-02 09:53:35 +00:00
tmp11Result = tmp11(tmp5(10214).ChannelRowPreview, obj3);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj1[6] = tmp11Result;
obj1[7] = extractTimestampResult;
2026-09-01 10:26:29 +00:00
obj1[8] = flag(4674)(channel);
2026-07-29 08:29:29 +00:00
obj1[9] = fontScale;
2026-09-02 09:53:35 +00:00
obj.children = flag(16806)(obj1);
return tmp2Result(jsx(channel(5076).PressableHighlight, {
2026-08-24 06:08:38 +00:00
onPress: importAllResult.useCallback(() => {
let obj = channel(closure_1_2[3]);
obj = { navigationReplace: flag };
obj.transitionToChannel(channel.id, obj);
}, items1),
onLongPress: importAllResult.useCallback(() => channel(closure_1_2[4]).openChannelLongPressActionSheet(channel.id), items2)
}));
2026-07-20 16:05:17 +00:00
});
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/launchpad/native/shared/DMChannel.tsx");
2026-07-22 07:54:56 +00:00
export default memoResult;