feat(editor): add tracking for the creation of linked-doc (#9266)

close: BS-2189
This commit is contained in:
zzj3720
2024-12-24 02:49:21 +00:00
parent b29cb5945a
commit 884bbd2ada
4 changed files with 27 additions and 2 deletions

View File

@@ -7,6 +7,7 @@ import type {
DocCreatedEvent,
ElementCreationEvent,
ElementLockEvent,
LinkedDocCreatedEvent,
MindMapCollapseEvent,
TelemetryEvent,
} from './types.js';
@@ -15,7 +16,7 @@ export type TelemetryEventMap = OutDatabaseAllEvents &
LinkToolbarEvents & {
DocCreated: DocCreatedEvent;
Link: TelemetryEvent;
LinkedDocCreated: TelemetryEvent;
LinkedDocCreated: LinkedDocCreatedEvent;
SplitNote: TelemetryEvent;
CanvasElementAdded: ElementCreationEvent;
EdgelessElementLocked: ElementLockEvent;

View File

@@ -22,6 +22,10 @@ export interface TelemetryEvent {
other?: unknown;
}
export interface LinkedDocCreatedEvent extends TelemetryEvent {
parentFlavour?: string;
}
export interface DocCreatedEvent extends TelemetryEvent {
page?: 'doc editor' | 'whiteboard editor';
segment?: 'whiteboard' | 'note' | 'doc';