decord/source/modules/emojis/useTrackOpenPopout.tsx
github-actions 03cf168fbc chore: update source for alpha 347.3
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4825.js (118.4 MB)
2026-09-17 08:17:09 +00:00

43 lines
1.8 KiB
TypeScript

// Module ID: 10480
// Function ID: 10481
// Name: useTrackOpenPopout
// Dependencies: [19, 1958, 2012, 1375, 1074, 4820, 5079, 10481, 1241, 2]
// Exports: useTrackOpenPopout
// Module 10480 (useTrackOpenPopout)
import AnalyticsUtilsDefault from "AnalyticsUtils" /* 1241 */;
import AppAnalyticsUtils from "AppAnalyticsUtils" /* 4820 */;
import useMountEffectDefault from "useMountEffect" /* 5079 */;
import emojis_EmojiActionCreators from "emojis/EmojiActionCreators" /* 10481 */;
import noop from "module_19" /* 19 */;
import ChannelStore from "ChannelStore" /* 1958 */;
import SelectedChannelStore from "SelectedChannelStore" /* 2012 */;
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;
};