decord/alpha/source/components_native/common/MessagePreview.tsx
github-actions c6aa9eb120 chore: update source for alpha 349.3
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/05xxx/module_5030.js (118.4 MB)
2026-10-01 06:55:13 +00:00

38 lines
1.7 KiB
TypeScript

// Module ID: 16884
// Function ID: 16885
// Name: MessagePreview
// Dependencies: [19, 7992, 1074, 21, 504, 1115, 16707, 13030, 2]
// Exports: default
// Module 16884 (MessagePreview)
import util from "util" /* 1115 */;
import noop from "module_19" /* 19 */;
import MessagePreviewStore from "MessagePreviewStore" /* 7992 */;
require = fn;
const Constants = fn(1074);
({ AnalyticsSections, AnalyticsObjects } = Constants);
const jsx = fn(21).jsx;
const analyticsLocation = { section: AnalyticsSections.CHANNEL_SEARCH, object: AnalyticsObjects.CHANNEL_SEARCH };
const size = fn(2);
const result = size.fileFinishedImporting("components_native/common/MessagePreview.tsx");
export default function MessagePreview(channelId) {
const onBeforeJumpToMessage = channelId.onBeforeJumpToMessage;
const items = [MessagePreviewStore];
const stateFromStoresObject = onBeforeJumpToMessage(504).useStateFromStoresObject(items, () => ({ messages: MessagePreviewStore.messages, jumpTargetId: MessagePreviewStore.jumpTargetId }));
const jumpTargetId = stateFromStoresObject.jumpTargetId;
const items1 = [jumpTargetId, onBeforeJumpToMessage];
const memo = noop.useMemo(() => {
const obj = { jumpToChatText: null, jumpTargetId: null, onBeforeJumpToMessage: null };
const intl = util.intl;
obj.jumpToChatText = intl.string(util.t["+TSRGD"]);
obj.jumpTargetId = jumpTargetId;
obj.onBeforeJumpToMessage = onBeforeJumpToMessage;
return obj;
}, items1);
const effect = noop.useEffect(() => () => {
jumpTargetId(closure_1_2[6]).clearMessages();
}, []);
return jsx(onBeforeJumpToMessage(13030).ChatPreview, { channelId: channelId.channelId, messages: stateFromStoresObject.messages, jumpToChatProps: memo, analyticsLocation });
};