Add isLocation to ComposerEvent analytics events (#11187)
This commit is contained in:
parent
90b572f074
commit
54ffce9d20
3 changed files with 4 additions and 0 deletions
|
@ -308,6 +308,7 @@ class EditMessageComposer extends React.Component<IEditMessageComposerProps, ISt
|
||||||
PosthogAnalytics.instance.trackEvent<ComposerEvent>({
|
PosthogAnalytics.instance.trackEvent<ComposerEvent>({
|
||||||
eventName: "Composer",
|
eventName: "Composer",
|
||||||
isEditing: true,
|
isEditing: true,
|
||||||
|
isLocation: false,
|
||||||
inThread: !!editedEvent?.getThread(),
|
inThread: !!editedEvent?.getThread(),
|
||||||
isReply: !!editedEvent.replyEventId,
|
isReply: !!editedEvent.replyEventId,
|
||||||
});
|
});
|
||||||
|
|
|
@ -447,6 +447,7 @@ export class SendMessageComposer extends React.Component<ISendMessageComposerPro
|
||||||
const posthogEvent: ComposerEvent = {
|
const posthogEvent: ComposerEvent = {
|
||||||
eventName: "Composer",
|
eventName: "Composer",
|
||||||
isEditing: false,
|
isEditing: false,
|
||||||
|
isLocation: false,
|
||||||
isReply: !!this.props.replyToEvent,
|
isReply: !!this.props.replyToEvent,
|
||||||
inThread: this.props.relation?.rel_type === THREAD_RELATION_TYPE.name,
|
inThread: this.props.relation?.rel_type === THREAD_RELATION_TYPE.name,
|
||||||
};
|
};
|
||||||
|
|
|
@ -64,6 +64,7 @@ export async function sendMessage(
|
||||||
const posthogEvent: ComposerEvent = {
|
const posthogEvent: ComposerEvent = {
|
||||||
eventName: "Composer",
|
eventName: "Composer",
|
||||||
isEditing: false,
|
isEditing: false,
|
||||||
|
isLocation: false,
|
||||||
isReply: Boolean(replyToEvent),
|
isReply: Boolean(replyToEvent),
|
||||||
// TODO thread
|
// TODO thread
|
||||||
inThread: relation?.rel_type === THREAD_RELATION_TYPE.name,
|
inThread: relation?.rel_type === THREAD_RELATION_TYPE.name,
|
||||||
|
@ -199,6 +200,7 @@ export async function editMessage(
|
||||||
PosthogAnalytics.instance.trackEvent<ComposerEvent>({
|
PosthogAnalytics.instance.trackEvent<ComposerEvent>({
|
||||||
eventName: "Composer",
|
eventName: "Composer",
|
||||||
isEditing: true,
|
isEditing: true,
|
||||||
|
isLocation: false,
|
||||||
inThread: Boolean(editedEvent?.getThread()),
|
inThread: Boolean(editedEvent?.getThread()),
|
||||||
isReply: Boolean(editedEvent.replyEventId),
|
isReply: Boolean(editedEvent.replyEventId),
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue