decord/alpha/source/modules/emojis/useTrackOpenPopout.tsx
github-actions 97fd043558 chore: update source for alpha 347.5
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4941.js (118.4 MB)
2026-09-19 06:52:51 +00:00

43 lines
1.8 KiB
TypeScript

// Module ID: 10590
// Function ID: 10591
// Name: useTrackOpenPopout
// Dependencies: [19, 2041, 2095, 1375, 1074, 4936, 5203, 10591, 1241, 2]
// Exports: useTrackOpenPopout
// Module 10590 (useTrackOpenPopout)
import AnalyticsUtilsDefault from "AnalyticsUtils" /* 1241 */;
import AppAnalyticsUtils from "AppAnalyticsUtils" /* 4936 */;
import useMountEffectDefault from "useMountEffect" /* 5203 */;
import emojis_EmojiActionCreators from "emojis/EmojiActionCreators" /* 10591 */;
import noop from "module_19" /* 19 */;
import ChannelStore from "ChannelStore" /* 2041 */;
import SelectedChannelStore from "SelectedChannelStore" /* 2095 */;
require = fn;
const EmojiInteractionPoint = fn(1375).EmojiInteractionPoint;
const AnalyticEvents = fn(1074).AnalyticEvents;
const size = fn(2);
let result = size.fileFinishedImporting("modules/emojis/useTrackOpenPopout.tsx");
export const useTrackOpenPopout = (emojiId) => {
({ currentGuildId, popoutData: require, nonce: importDefault, demoMode: dependencyMap } = emojiId);
let current;
let merged = Object.assign(AppAnalyticsUtils.collectChannelAnalyticsMetadata(ChannelStore.getChannel(SelectedChannelStore.getChannelId(currentGuildId))));
current = current.useRef({ guild_id: currentGuildId, emoji_id: emojiId.emojiId }).current;
useMountEffectDefault(() => {
const result = emojis_EmojiActionCreators.initiateEmojiInteraction(EmojiInteractionPoint.TrackOpenPopoutUsed);
if (!dependencyMap) {
let str;
if (analyticsType != null) {
str = analyticsType.analyticsType;
}
if (str == null) {
str = "Standard Emoji Popout";
}
const obj3 = { type: str, nonce };
const merged = Object.assign(current);
AnalyticsUtilsDefault.track(AnalyticEvents.OPEN_POPOUT, obj3);
}
});
return current;
};