@nommos/core 0.0.30 → 0.0.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +9 -5
- package/src/lib/constants.d.ts +5 -4
- package/src/lib/constants.js +7 -7
- package/src/lib/constants.js.map +1 -1
- package/src/lib/event-tracker.d.ts +1 -1
- package/src/lib/event-tracker.js +11 -20
- package/src/lib/event-tracker.js.map +1 -1
- package/src/lib/session-tracker.d.ts +9 -24
- package/src/lib/session-tracker.js +78 -142
- package/src/lib/session-tracker.js.map +1 -1
- package/src/lib/types.d.ts +6 -39
- package/src/lib/webSocket-client.d.ts +3 -8
- package/src/lib/webSocket-client.js +21 -20
- package/src/lib/webSocket-client.js.map +1 -1
- package/src/lib/heatmap-tracker.d.ts +0 -50
- package/src/lib/heatmap-tracker.js +0 -319
- package/src/lib/heatmap-tracker.js.map +0 -1
|
@@ -1,319 +0,0 @@
|
|
|
1
|
-
export class HeatmapTracker {
|
|
2
|
-
constructor(ws, cfg, browserId, channel) {
|
|
3
|
-
this.ws = ws;
|
|
4
|
-
this.cfg = cfg;
|
|
5
|
-
this.browserId = browserId;
|
|
6
|
-
this.channel = channel;
|
|
7
|
-
this.clicks = new Map();
|
|
8
|
-
this.movement = new Map();
|
|
9
|
-
this.scrollBands = new Map();
|
|
10
|
-
this.eventCount = 0;
|
|
11
|
-
this.lastMoveTime = 0;
|
|
12
|
-
this.lastX = -1;
|
|
13
|
-
this.lastY = -1;
|
|
14
|
-
this.moveEventCounter = 0;
|
|
15
|
-
this.maxScroll = 0;
|
|
16
|
-
this.reachedBands = new Set();
|
|
17
|
-
this.activePageKey = '';
|
|
18
|
-
this.activePagePath = '';
|
|
19
|
-
this.activePageUrl = '';
|
|
20
|
-
this.observer = null;
|
|
21
|
-
this.quiescenceTimer = null;
|
|
22
|
-
this.visibilityTimer = null;
|
|
23
|
-
this.hasFirstEvent = false;
|
|
24
|
-
}
|
|
25
|
-
/**
|
|
26
|
-
* Starts global event listeners for heatmap collection.
|
|
27
|
-
*/
|
|
28
|
-
start() {
|
|
29
|
-
if (typeof window === 'undefined')
|
|
30
|
-
return;
|
|
31
|
-
if (this.cfg.mode === 'dev') {
|
|
32
|
-
console.log('[Nommos Tracker] Heatmap Metrics Collection Started');
|
|
33
|
-
}
|
|
34
|
-
document.addEventListener('click', this.handleClick.bind(this), {
|
|
35
|
-
capture: true,
|
|
36
|
-
passive: true,
|
|
37
|
-
});
|
|
38
|
-
document.addEventListener('mousemove', this.handleMouseMove.bind(this), {
|
|
39
|
-
capture: true,
|
|
40
|
-
passive: true,
|
|
41
|
-
});
|
|
42
|
-
window.addEventListener('scroll', this.handleScroll.bind(this), {
|
|
43
|
-
capture: true,
|
|
44
|
-
passive: true,
|
|
45
|
-
});
|
|
46
|
-
window.addEventListener('visibilitychange', this.handleVisibilityChange.bind(this));
|
|
47
|
-
window.addEventListener('popstate', () => this.handleNavigation());
|
|
48
|
-
window.addEventListener('hashchange', () => this.handleNavigation());
|
|
49
|
-
window.addEventListener('beforeunload', () => this.flush());
|
|
50
|
-
this.setupMutationObserver();
|
|
51
|
-
this.patchHistoryApi();
|
|
52
|
-
this.handleNavigation();
|
|
53
|
-
}
|
|
54
|
-
patchHistoryApi() {
|
|
55
|
-
if (typeof window === 'undefined' || !window.history)
|
|
56
|
-
return;
|
|
57
|
-
const heatmap = this;
|
|
58
|
-
const originalPushState = window.history.pushState;
|
|
59
|
-
const originalReplaceState = window.history.replaceState;
|
|
60
|
-
window.history.pushState = function (...args) {
|
|
61
|
-
if (heatmap.eventCount > 0)
|
|
62
|
-
heatmap.flush();
|
|
63
|
-
const result = originalPushState.apply(this, args);
|
|
64
|
-
heatmap.updateContext();
|
|
65
|
-
return result;
|
|
66
|
-
};
|
|
67
|
-
window.history.replaceState = function (...args) {
|
|
68
|
-
if (heatmap.eventCount > 0)
|
|
69
|
-
heatmap.flush();
|
|
70
|
-
const result = originalReplaceState.apply(this, args);
|
|
71
|
-
heatmap.updateContext();
|
|
72
|
-
return result;
|
|
73
|
-
};
|
|
74
|
-
}
|
|
75
|
-
setupMutationObserver() {
|
|
76
|
-
if (typeof window === 'undefined' || typeof MutationObserver === 'undefined')
|
|
77
|
-
return;
|
|
78
|
-
this.observer = new MutationObserver(() => {
|
|
79
|
-
// If we are waiting for the page to settle, reset the timer
|
|
80
|
-
if (this.hasFirstEvent) {
|
|
81
|
-
this.resetQuiescenceTimer();
|
|
82
|
-
}
|
|
83
|
-
});
|
|
84
|
-
this.observer.observe(document.body, {
|
|
85
|
-
attributes: true,
|
|
86
|
-
childList: true,
|
|
87
|
-
subtree: true
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
resetQuiescenceTimer() {
|
|
91
|
-
if (this.quiescenceTimer)
|
|
92
|
-
clearTimeout(this.quiescenceTimer);
|
|
93
|
-
// Wait for 2 seconds of "quiet" before taking the snapshot
|
|
94
|
-
this.quiescenceTimer = setTimeout(() => {
|
|
95
|
-
if (this.cfg.mode === 'dev') {
|
|
96
|
-
console.log('[Nommos Tracker] Page reached quiescence, capturing screenshot...');
|
|
97
|
-
}
|
|
98
|
-
this.capturePageScreenshot();
|
|
99
|
-
this.quiescenceTimer = null;
|
|
100
|
-
}, 2000);
|
|
101
|
-
}
|
|
102
|
-
handleNavigation() {
|
|
103
|
-
if (typeof window === 'undefined')
|
|
104
|
-
return;
|
|
105
|
-
// Flush existing data using the context of the page we are LEAVING
|
|
106
|
-
if (this.eventCount > 0) {
|
|
107
|
-
this.flush();
|
|
108
|
-
}
|
|
109
|
-
// Now update the context for the page we are ENTERING
|
|
110
|
-
this.updateContext();
|
|
111
|
-
}
|
|
112
|
-
updateContext() {
|
|
113
|
-
if (typeof window === 'undefined')
|
|
114
|
-
return;
|
|
115
|
-
const category = this.channel === 3 ? 'mobile' : 'desktop';
|
|
116
|
-
this.activePageKey = `${window.location.pathname}_${category}`;
|
|
117
|
-
this.activePagePath = window.location.pathname;
|
|
118
|
-
this.activePageUrl = window.location.href;
|
|
119
|
-
this.hasFirstEvent = false;
|
|
120
|
-
if (this.quiescenceTimer) {
|
|
121
|
-
clearTimeout(this.quiescenceTimer);
|
|
122
|
-
this.quiescenceTimer = null;
|
|
123
|
-
}
|
|
124
|
-
if (this.cfg.mode === 'dev') {
|
|
125
|
-
console.log('[Nommos Tracker] Heatmap Context Updated:', this.activePagePath);
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
async capturePageScreenshot() {
|
|
129
|
-
if (typeof window === 'undefined')
|
|
130
|
-
return;
|
|
131
|
-
// Reuse if already captured in this session
|
|
132
|
-
if (HeatmapTracker.screenshotStore.has(this.activePageKey))
|
|
133
|
-
return;
|
|
134
|
-
try {
|
|
135
|
-
// Dynamic import to keep bundle small
|
|
136
|
-
const html2canvas = (await import('html2canvas')).default;
|
|
137
|
-
const canvas = await html2canvas(document.body, {
|
|
138
|
-
width: window.innerWidth,
|
|
139
|
-
height: window.innerHeight,
|
|
140
|
-
windowWidth: window.innerWidth,
|
|
141
|
-
windowHeight: window.innerHeight,
|
|
142
|
-
useCORS: true,
|
|
143
|
-
allowTaint: false,
|
|
144
|
-
scale: 1,
|
|
145
|
-
scrollX: 0,
|
|
146
|
-
scrollY: 0,
|
|
147
|
-
});
|
|
148
|
-
const base64Image = canvas.toDataURL('image/jpeg', 0.2);
|
|
149
|
-
HeatmapTracker.screenshotStore.set(this.activePageKey, base64Image);
|
|
150
|
-
if (this.cfg.mode === 'dev') {
|
|
151
|
-
console.log('[Nommos Tracker] Screenshot Captured for:', this.activePageKey);
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
catch (err) {
|
|
155
|
-
if (this.cfg.mode === 'dev') {
|
|
156
|
-
console.error('[Nommos Tracker] Screenshot Capture Failed:', err);
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
/**
|
|
161
|
-
* Stops listeners and flushes remaining data.
|
|
162
|
-
*/
|
|
163
|
-
stop() {
|
|
164
|
-
if (typeof window === 'undefined')
|
|
165
|
-
return;
|
|
166
|
-
document.removeEventListener('click', this.handleClick.bind(this), { capture: true });
|
|
167
|
-
document.removeEventListener('mousemove', this.handleMouseMove.bind(this), { capture: true });
|
|
168
|
-
window.removeEventListener('scroll', this.handleScroll.bind(this));
|
|
169
|
-
window.removeEventListener('visibilitychange', this.handleVisibilityChange.bind(this));
|
|
170
|
-
if (this.observer) {
|
|
171
|
-
this.observer.disconnect();
|
|
172
|
-
this.observer = null;
|
|
173
|
-
}
|
|
174
|
-
if (this.quiescenceTimer) {
|
|
175
|
-
clearTimeout(this.quiescenceTimer);
|
|
176
|
-
this.quiescenceTimer = null;
|
|
177
|
-
}
|
|
178
|
-
if (this.visibilityTimer) {
|
|
179
|
-
clearTimeout(this.visibilityTimer);
|
|
180
|
-
this.visibilityTimer = null;
|
|
181
|
-
}
|
|
182
|
-
this.flush();
|
|
183
|
-
}
|
|
184
|
-
handleClick(e) {
|
|
185
|
-
this.recordPoint(this.clicks, e.pageX, e.pageY);
|
|
186
|
-
this.incrementAndCheck();
|
|
187
|
-
}
|
|
188
|
-
handleMouseMove(e) {
|
|
189
|
-
const now = Date.now();
|
|
190
|
-
// 1. Throttling: 100ms
|
|
191
|
-
if (now - this.lastMoveTime < 100)
|
|
192
|
-
return;
|
|
193
|
-
this.lastMoveTime = now;
|
|
194
|
-
// 2. Sampling: 1 in 3
|
|
195
|
-
this.moveEventCounter++;
|
|
196
|
-
if (this.moveEventCounter % 3 !== 0)
|
|
197
|
-
return;
|
|
198
|
-
// 3. Distance filter: > 5px
|
|
199
|
-
const dx = Math.abs(e.pageX - this.lastX);
|
|
200
|
-
const dy = Math.abs(e.pageY - this.lastY);
|
|
201
|
-
if (dx < 5 && dy < 5)
|
|
202
|
-
return;
|
|
203
|
-
this.lastX = e.pageX;
|
|
204
|
-
this.lastY = e.pageY;
|
|
205
|
-
this.recordPoint(this.movement, e.pageX, e.pageY);
|
|
206
|
-
this.incrementAndCheck();
|
|
207
|
-
}
|
|
208
|
-
handleScroll() {
|
|
209
|
-
const scrollY = window.scrollY || window.pageYOffset;
|
|
210
|
-
const totalHeight = document.documentElement.scrollHeight - window.innerHeight;
|
|
211
|
-
if (totalHeight <= 0)
|
|
212
|
-
return;
|
|
213
|
-
const percent = Math.min(100, Math.max(0, (scrollY / totalHeight) * 100));
|
|
214
|
-
// Snap to 0, 25, 50, 75, 100
|
|
215
|
-
const band = Math.round(percent / 25) * 25;
|
|
216
|
-
if (band > this.maxScroll) {
|
|
217
|
-
this.maxScroll = band;
|
|
218
|
-
if (!this.reachedBands.has(band)) {
|
|
219
|
-
this.reachedBands.add(band);
|
|
220
|
-
const currentCount = this.scrollBands.get(band) || 0;
|
|
221
|
-
this.scrollBands.set(band, currentCount + 1);
|
|
222
|
-
this.incrementAndCheck();
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
}
|
|
226
|
-
handleVisibilityChange() {
|
|
227
|
-
if (document.visibilityState === 'hidden') {
|
|
228
|
-
// Grace period: wait 10 seconds before flushing background heatmaps
|
|
229
|
-
this.visibilityTimer = setTimeout(() => {
|
|
230
|
-
this.flush(true);
|
|
231
|
-
this.visibilityTimer = null;
|
|
232
|
-
}, 10000);
|
|
233
|
-
}
|
|
234
|
-
else {
|
|
235
|
-
// User came back: cancel any pending background flush
|
|
236
|
-
if (this.visibilityTimer) {
|
|
237
|
-
clearTimeout(this.visibilityTimer);
|
|
238
|
-
this.visibilityTimer = null;
|
|
239
|
-
}
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
recordPoint(map, rawX, rawY) {
|
|
243
|
-
// Grid bucket: 10px
|
|
244
|
-
const x = Math.round(rawX / 10) * 10;
|
|
245
|
-
const y = Math.round(rawY / 10) * 10;
|
|
246
|
-
const key = `${x},${y}`;
|
|
247
|
-
map.set(key, (map.get(key) || 0) + 1);
|
|
248
|
-
}
|
|
249
|
-
incrementAndCheck() {
|
|
250
|
-
if (!this.hasFirstEvent) {
|
|
251
|
-
this.hasFirstEvent = true;
|
|
252
|
-
this.resetQuiescenceTimer();
|
|
253
|
-
}
|
|
254
|
-
this.eventCount++;
|
|
255
|
-
const threshold = this.cfg.heatmapThreshold || 50;
|
|
256
|
-
if (this.eventCount >= threshold) {
|
|
257
|
-
this.flush();
|
|
258
|
-
}
|
|
259
|
-
}
|
|
260
|
-
async flush(isBackground = false) {
|
|
261
|
-
if (this.eventCount === 0) {
|
|
262
|
-
return;
|
|
263
|
-
}
|
|
264
|
-
// Optimization: If this is a background flush (tab switch),
|
|
265
|
-
// only send if we have a meaningful amount of data (min 5 events).
|
|
266
|
-
if (isBackground && this.eventCount < 5) {
|
|
267
|
-
if (this.cfg.mode === 'dev') {
|
|
268
|
-
console.log('[Nommos Tracker] Background flush skipped: only', this.eventCount, 'events collected.');
|
|
269
|
-
}
|
|
270
|
-
return;
|
|
271
|
-
}
|
|
272
|
-
// Screenshot is now handled by Quiescence logic in the background.
|
|
273
|
-
// We just pack whatever we have in the store.
|
|
274
|
-
const payload = {
|
|
275
|
-
brandId: this.cfg.brand_id || '',
|
|
276
|
-
bid: this.browserId,
|
|
277
|
-
channel: this.channel,
|
|
278
|
-
page: this.activePagePath,
|
|
279
|
-
fullUrl: this.activePageUrl,
|
|
280
|
-
timestamp: Date.now(),
|
|
281
|
-
screen: {
|
|
282
|
-
width: window.innerWidth,
|
|
283
|
-
height: window.innerHeight,
|
|
284
|
-
},
|
|
285
|
-
heatmaps: {
|
|
286
|
-
clicks: this.mapToPoints(this.clicks),
|
|
287
|
-
movement: this.mapToPoints(this.movement),
|
|
288
|
-
scroll: this.mapToScroll(this.scrollBands),
|
|
289
|
-
},
|
|
290
|
-
screenshot: HeatmapTracker.screenshotStore.get(this.activePageKey),
|
|
291
|
-
};
|
|
292
|
-
if (this.cfg.mode === 'dev') {
|
|
293
|
-
console.log('[Nommos Tracker] Sending Heatmap Batch:', payload);
|
|
294
|
-
}
|
|
295
|
-
this.ws.publishHeatmapMessage(payload);
|
|
296
|
-
// Reset buckets
|
|
297
|
-
this.clicks.clear();
|
|
298
|
-
this.movement.clear();
|
|
299
|
-
this.scrollBands.clear();
|
|
300
|
-
this.eventCount = 0;
|
|
301
|
-
}
|
|
302
|
-
mapToPoints(map) {
|
|
303
|
-
const points = [];
|
|
304
|
-
map.forEach((value, key) => {
|
|
305
|
-
const [x, y] = key.split(',').map(Number);
|
|
306
|
-
points.push({ x, y, value });
|
|
307
|
-
});
|
|
308
|
-
return points;
|
|
309
|
-
}
|
|
310
|
-
mapToScroll(map) {
|
|
311
|
-
const bands = [];
|
|
312
|
-
map.forEach((value, depth) => {
|
|
313
|
-
bands.push({ depth, value });
|
|
314
|
-
});
|
|
315
|
-
return bands;
|
|
316
|
-
}
|
|
317
|
-
}
|
|
318
|
-
HeatmapTracker.screenshotStore = new Map();
|
|
319
|
-
//# sourceMappingURL=heatmap-tracker.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"heatmap-tracker.js","sourceRoot":"","sources":["../../../../../nommos/core/src/lib/heatmap-tracker.ts"],"names":[],"mappings":"AAIA,MAAM,OAAO,cAAc;IAoBzB,YACmB,EAAmB,EACnB,GAAe,EACf,SAAiB,EACjB,OAAe;QAHf,OAAE,GAAF,EAAE,CAAiB;QACnB,QAAG,GAAH,GAAG,CAAY;QACf,cAAS,GAAT,SAAS,CAAQ;QACjB,YAAO,GAAP,OAAO,CAAQ;QAvB1B,WAAM,GAAwB,IAAI,GAAG,EAAE,CAAC;QACxC,aAAQ,GAAwB,IAAI,GAAG,EAAE,CAAC;QAC1C,gBAAW,GAAwB,IAAI,GAAG,EAAE,CAAC;QAC7C,eAAU,GAAG,CAAC,CAAC;QACf,iBAAY,GAAG,CAAC,CAAC;QACjB,UAAK,GAAG,CAAC,CAAC,CAAC;QACX,UAAK,GAAG,CAAC,CAAC,CAAC;QACX,qBAAgB,GAAG,CAAC,CAAC;QACrB,cAAS,GAAG,CAAC,CAAC;QACd,iBAAY,GAAgB,IAAI,GAAG,EAAE,CAAC;QACtC,kB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