@compilacion/colleciones-clientos 1.0.11 → 1.0.12

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.
@@ -2,6 +2,12 @@
2
2
  'use strict';
3
3
 
4
4
  // helper 'private' functions
5
+ /**
6
+ * Converts a snake_case string to camelCase.
7
+ * Removes non-ASCII characters.
8
+ * @param {string} str
9
+ * @returns {string}
10
+ */
5
11
  const underscoreToCamelCase = function (str) {
6
12
  str = str.replace(/[^\x00-\x7F_]/g, '');
7
13
  return str
@@ -15,8 +21,14 @@
15
21
  .join('');
16
22
  };
17
23
 
24
+ /**
25
+ * Formats adjectives by converting them to camelCase strings.
26
+ * Accepts a single string or an array of strings.
27
+ * @param {string|string[]|undefined} adjectiveParameter
28
+ * @returns {string[]|undefined}
29
+ */
18
30
  const formatAdjectives = function (adjectiveParameter) {
19
- let errorMsg = new Error('Adjective must be a string, an array of strings, or undefined');
31
+ const errorMsg = new Error('Adjective must be a string, an array of strings, or undefined');
20
32
  if (typeof adjectiveParameter === 'undefined') {
21
33
  return undefined;
22
34
  }
@@ -24,18 +36,17 @@
24
36
  return [underscoreToCamelCase(adjectiveParameter)];
25
37
  }
26
38
  if (Array.isArray(adjectiveParameter) && adjectiveParameter.every(item => typeof item === 'string')) {
27
- let returnValue = [];
28
- adjectiveParameter.forEach((adjectiveParameter) => {
29
- if (!typeof item === 'string') {
30
- throw errorMsg;
31
- }
32
- returnValue.push(underscoreToCamelCase(adjectiveParameter));
33
- });
34
- return returnValue;
39
+ return adjectiveParameter.map(adjective => underscoreToCamelCase(adjective));
35
40
  }
36
41
  throw errorMsg;
37
42
  };
38
43
 
44
+ /**
45
+ * Converts an array of adjective strings to a dot-prefixed, dot-separated string.
46
+ * Removes duplicates and sorts alphabetically.
47
+ * @param {string[]} adjective
48
+ * @returns {string|undefined}
49
+ */
39
50
  const stringifyAdjectives = function (adjective) {
40
51
  if (!Array.isArray(adjective) || adjective.length === 0) {
41
52
  return undefined;
@@ -44,14 +55,25 @@
44
55
  return '.' + uniqueSorted.join('.');
45
56
  };
46
57
 
58
+ /**
59
+ * Encodes a string to Base64.
60
+ * Uses browser or Node.js method depending on environment.
61
+ * @param {string} str
62
+ * @returns {string}
63
+ */
47
64
  const toBase64 = function (str) {
48
- if (typeof window !== 'undefined' && window.btoa) {
65
+ if (typeof window !== 'undefined' && typeof window.btoa === 'function') {
49
66
  return window.btoa(unescape(encodeURIComponent(str)));
50
67
  } else {
51
68
  return Buffer.from(str, 'utf-8').toString('base64');
52
69
  }
53
70
  };
54
71
 
72
+ /**
73
+ * Collects browser-related context values like screen size, language, etc.
74
+ * Returns an empty object if not in browser environment.
75
+ * @returns {Object}
76
+ */
55
77
  const getBrowserContext = function() {
56
78
  if (typeof window === 'undefined' || typeof navigator === 'undefined') {
57
79
  return {};
@@ -71,8 +93,14 @@
71
93
  };
72
94
  };
73
95
 
96
+ /**
97
+ * Base class representing a structured event with timestamp, identifiers, and data fields.
98
+ */
74
99
  class CollecionesBaseEvent {
75
100
 
101
+ /**
102
+ * Constructs a new event with default metadata and timestamps.
103
+ */
76
104
  constructor() {
77
105
  this.eventName = '';
78
106
  this.data = {};
@@ -92,32 +120,62 @@
92
120
  }
93
121
  }
94
122
 
123
+ /**
124
+ * Sets the event name.
125
+ * @param {string} name
126
+ */
95
127
  setEventName(name) {
96
128
  this.eventName = name;
97
129
  }
98
130
 
131
+ /**
132
+ * Returns the event name.
133
+ * @returns {string}
134
+ */
99
135
  getEventName() {
100
136
  return this.eventName;
101
137
  }
102
138
 
139
+ /**
140
+ * Gets the format of the event.
141
+ * @returns {string}
142
+ */
103
143
  getEventFormat() {
104
144
  let v = this.data?.meta?.eventFormat;
105
145
  return (typeof v !== 'undefined') ? v : '1';
106
146
  }
107
147
 
148
+ /**
149
+ * Gets the version of the event format.
150
+ * @returns {string}
151
+ */
108
152
  getEventFormatVersion() {
109
153
  let v = this.data?.meta?.eventFormatVersion;
110
154
  return (typeof v !== 'undefined') ? v : 'CollecionesBaseEvent';
111
155
  }
112
156
 
157
+ /**
158
+ * Replaces the entire data object.
159
+ * @param {object} data
160
+ */
113
161
  setData(data) {
114
162
  this.data = data;
115
163
  }
116
164
 
165
+ /**
166
+ * Adds a field to the event's custom fields section.
167
+ * @param {string} name
168
+ * @param {*} value
169
+ */
117
170
  addAttribute(name, value) {
118
171
  return this.addField(name, value);
119
172
  }
120
173
 
174
+ /**
175
+ * Adds a key-value pair to the custom fields.
176
+ * @param {string} name
177
+ * @param {*} value
178
+ */
121
179
  addField(name, value) {
122
180
  if (typeof this.data.fields !== 'object' || this.data.fields === null) {
123
181
  this.data.fields = {};
@@ -125,14 +183,26 @@
125
183
  this.data.fields[name] = value;
126
184
  }
127
185
 
186
+ /**
187
+ * Sets the name of the tracker used to generate the event.
188
+ * @param {string} name
189
+ */
128
190
  setTracker(name) {
129
191
  this.data.tracker = name;
130
192
  }
131
193
 
194
+ /**
195
+ * Sets the name of the application that created the event.
196
+ * @param {string} name
197
+ */
132
198
  setAppName(name) {
133
199
  this.data.appName = name;
134
200
  }
135
201
 
202
+ /**
203
+ * Adds multiple identifiers from an object.
204
+ * @param {object} param
205
+ */
136
206
  convertParamIdentifiers(param) {
137
207
  if (typeof param === 'object' && param !== null && !Array.isArray(param)) {
138
208
  for (const [key, value] of Object.entries(param)) {
@@ -141,6 +211,11 @@
141
211
  }
142
212
  }
143
213
 
214
+ /**
215
+ * Adds a single identifier to the event.
216
+ * @param {string} name
217
+ * @param {*} value
218
+ */
144
219
  addIdentifier(name, value) {
145
220
  if (typeof this.data.identifiers !== 'object' || this.data.identifiers === null) {
146
221
  this.data.identifiers = {};
@@ -148,6 +223,10 @@
148
223
  this.data.identifiers[name] = value;
149
224
  }
150
225
 
226
+ /**
227
+ * Constructs the postable event object with metadata and encoded payload.
228
+ * @returns {object}
229
+ */
151
230
  getPostObject() {
152
231
  this.data.timestamps.sendDatetimeUtc = new Date().toISOString();
153
232
  this.data.timestamps.sendDatetimeLocal = new Date(Date.now() - new Date().getTimezoneOffset() * 60000).toISOString();
@@ -159,20 +238,37 @@
159
238
  };
160
239
  }
161
240
 
241
+ /**
242
+ * Overrides or extends the timestamp fields of the event.
243
+ * @param {object} dateTimeObject
244
+ */
162
245
  overrideDatetime(dateTimeObject = {}) {
163
246
  for (const [key, value] of Object.entries(dateTimeObject)) {
164
247
  this.data.timestamps[key] = value;
165
248
  }
166
249
  }
167
250
 
251
+ /**
252
+ * Serializes the event data to a JSON string.
253
+ * @returns {string}
254
+ */
168
255
  getPayload() {
169
256
  return JSON.stringify(this.data);
170
257
  }
171
258
 
172
259
  }
173
260
 
261
+ /**
262
+ * Emitter class responsible for batching and sending events to a configured endpoint.
263
+ */
174
264
  class CollecionesEmitter {
175
265
 
266
+ /**
267
+ * Initializes the emitter with buffering settings.
268
+ * @param {string} [endpoint='/collect'] - The URL to send events to.
269
+ * @param {number} [flushSize=10] - Number of events to buffer before flushing.
270
+ * @param {number|boolean} [flushInterval=false] - Time in ms to flush events periodically.
271
+ */
176
272
  constructor(endpoint = '/collect', flushSize = 10, flushInterval = false) {
177
273
  this.endpoint = endpoint;
178
274
  this.flushInterval = flushInterval;
@@ -181,6 +277,9 @@
181
277
  this.timer = null;
182
278
  }
183
279
 
280
+ /**
281
+ * Starts the flush timer if a valid interval is set.
282
+ */
184
283
  startTimer() {
185
284
  this.stopTimer();
186
285
  if (typeof this.flushInterval == 'number' && this.flushInterval > 0) {
@@ -188,12 +287,18 @@
188
287
  }
189
288
  }
190
289
 
290
+ /**
291
+ * Starts the flush timer only if not already running.
292
+ */
191
293
  startTimerIfStopped() {
192
294
  if (!this.timer) {
193
295
  this.startTimer();
194
296
  }
195
297
  }
196
298
 
299
+ /**
300
+ * Stops the active flush timer.
301
+ */
197
302
  stopTimer() {
198
303
  if (this.timer) {
199
304
  clearInterval(this.timer);
@@ -201,6 +306,10 @@
201
306
  this.timer = null;
202
307
  }
203
308
 
309
+ /**
310
+ * Adds an event to the buffer and flushes if threshold is reached.
311
+ * @param {CollecionesBaseEvent} event
312
+ */
204
313
  track(event) {
205
314
  if (!(event instanceof CollecionesBaseEvent)) {
206
315
  throw new Error('Event must be an instance of CollecionesBaseEvent');
@@ -208,6 +317,11 @@
208
317
  this.trackAsync(event);
209
318
  }
210
319
 
320
+ /**
321
+ * Asynchronously adds an event and flushes if the buffer size is exceeded.
322
+ * @param {CollecionesBaseEvent} event
323
+ * @returns {Promise<void>}
324
+ */
211
325
  async trackAsync(event) {
212
326
  if (!(event instanceof CollecionesBaseEvent)) {
213
327
  throw new Error('Event must be an instance of CollecionesBaseEvent');
@@ -217,6 +331,10 @@
217
331
  return (this.buffer.length >= this.flushSize) ? this.flush() : Promise.resolve();
218
332
  }
219
333
 
334
+ /**
335
+ * Sends the buffered events to the server and clears the buffer.
336
+ * @returns {Promise<boolean|undefined>}
337
+ */
220
338
  async flush() {
221
339
  if (this.buffer.length === 0) return;
222
340
  const eventsToSend = [...this.buffer];
@@ -245,8 +363,17 @@
245
363
  }
246
364
  }
247
365
 
366
+ /**
367
+ * Tracks events by enriching them with shared identifiers and routing through configured emitters.
368
+ */
248
369
  class CollecionesTracker {
249
-
370
+
371
+ /**
372
+ * Constructs a new tracker instance.
373
+ * @param {Array} emitters - Array of emitter instances responsible for sending events.
374
+ * @param {string} trackerName - Name identifying this tracker.
375
+ * @param {string} appName - Name of the application generating events.
376
+ */
250
377
  constructor(emitters, trackerName, appName) {
251
378
  this.emitters = emitters;
252
379
  this.trackerName = trackerName;
@@ -254,10 +381,20 @@
254
381
  this.identifiers = {};
255
382
  }
256
383
 
384
+ /**
385
+ * Adds a global identifier to be included with every event.
386
+ * @param {string} name - Identifier key.
387
+ * @param {*} value - Identifier value.
388
+ */
257
389
  addIdentifier(name, value) {
258
390
  this.identifiers[name] = value;
259
391
  }
260
392
 
393
+ /**
394
+ * Sends an event to all emitters after enriching it with identifiers and metadata.
395
+ * @param {CollecionesBaseEvent} collecionesEvent - The event to be sent.
396
+ * @throws {Error} If the input is not an instance of CollecionesBaseEvent.
397
+ */
261
398
  track(collecionesEvent) {
262
399
  if (!(collecionesEvent instanceof CollecionesBaseEvent)) {
263
400
  throw new Error('Event must be of type CollecionesEvent');
@@ -270,16 +407,29 @@
270
407
  this.emitters.forEach(element => {
271
408
  element.track(collecionesEvent, this.trackerName, this.appName);
272
409
  });
273
-
274
410
  }
275
411
  }
276
412
 
413
+ /**
414
+ * Web-specific tracker that enriches events with browser context before sending them.
415
+ * Extends the base CollecionesTracker.
416
+ */
277
417
  class CollecionesWebTracker extends CollecionesTracker {
278
-
418
+ /**
419
+ * Creates a new instance of CollecionesWebTracker.
420
+ * @param {Array} emitters - A list of emitter instances used to send the event.
421
+ * @param {string} trackerName - The name of the tracker.
422
+ * @param {string} appName - The name of the application generating events.
423
+ */
279
424
  constructor(emitters, trackerName, appName) {
280
425
  super(emitters, trackerName, appName);
281
426
  }
282
427
 
428
+ /**
429
+ * Tracks an event, enriching it with browser context information.
430
+ * @param {CollecionesBaseEvent} collecionesEvent - The event object to track.
431
+ * @throws {Error} If the event is not an instance of CollecionesBaseEvent.
432
+ */
283
433
  track(collecionesEvent) {
284
434
  if (!(collecionesEvent instanceof CollecionesBaseEvent)) {
285
435
  throw new Error('Event must be of type CollecionesEvent');
@@ -289,8 +439,18 @@
289
439
  }
290
440
  }
291
441
 
442
+ /**
443
+ * Represents a semantic event with a name, data payload, and identifiers.
444
+ * Extends CollecionesBaseEvent.
445
+ */
292
446
  class CollecionesEvent extends CollecionesBaseEvent {
293
447
 
448
+ /**
449
+ * Constructs a new CollecionesEvent instance.
450
+ * @param {string} name - The name of the event.
451
+ * @param {object} data - The main data payload of the event.
452
+ * @param {object} identifiers - A set of identifiers to associate with the event.
453
+ */
294
454
  constructor(name, data, identifiers) {
295
455
  super();
296
456
  this.setEventName(name);
@@ -356,8 +516,20 @@
356
516
  return unsafeStringify(rnds);
357
517
  }
358
518
 
519
+ /**
520
+ * Represents a structured semantic event with entity, action, and optional adjective.
521
+ * Includes automatic naming and identifier mapping.
522
+ * Extends CollecionesBaseEvent.
523
+ */
359
524
  class CollecionesSemanticEvent extends CollecionesBaseEvent {
360
525
 
526
+ /**
527
+ * Constructs a new semantic event.
528
+ * @param {string} entity - The entity involved in the event.
529
+ * @param {string} action - The action performed on the entity.
530
+ * @param {string|string[]|undefined} adjective - Optional adjective(s) modifying the event.
531
+ * @param {object} identifiers - Key-value pairs to be added as identifiers.
532
+ */
361
533
  constructor(entity, action, adjective, identifiers) {
362
534
  super();
363
535
  this.entity = underscoreToCamelCase(entity);
@@ -375,10 +547,20 @@
375
547
  };
376
548
  }
377
549
 
550
+ /**
551
+ * This method is deprecated in semantic events and will throw if called.
552
+ * @throws {Error}
553
+ */
378
554
  setData() {
379
555
  throw new Error('setData deprecated in semantic events');
380
556
  }
381
557
 
558
+ /**
559
+ * Adds a key-value pair as an identifier for the semantic entity.
560
+ * @param {string} key - The identifier name.
561
+ * @param {string|number} value - The identifier value.
562
+ * @throws Will throw if key is not a string or value is not a string or number.
563
+ */
382
564
  addEntityIdentifier(key, value) {
383
565
  if (typeof key !== 'string') {
384
566
  throw new Error('Entity identifier key must be a string');
@@ -391,10 +573,22 @@
391
573
 
392
574
  }
393
575
 
576
+ /**
577
+ * Represents a semantic event related to a collection of entities.
578
+ * Extends CollecionesSemanticEvent and adds item-level detail and identifiers.
579
+ */
394
580
  class CollecionesSemanticCollectionEvent extends CollecionesSemanticEvent {
395
581
 
582
+ /**
583
+ * Constructs a new CollecionesSemanticCollectionEvent.
584
+ * @param {string} itemEntity - The name of the item entity being acted on.
585
+ * @param {string} action - The action performed.
586
+ * @param {string|string[]|undefined} adjective - Optional adjective(s) describing the action.
587
+ * @param {object} identifiers - Identifiers associated with the event.
588
+ * @param {string} [collectionEntity] - Optional collection name, defaults to `${itemEntity}Collection`.
589
+ */
396
590
  constructor(itemEntity, action, adjective, identifiers, collectionEntity) {
397
- if(typeof collectionEntity == 'undefined') {
591
+ if (typeof collectionEntity == 'undefined') {
398
592
  collectionEntity = `${itemEntity}Collection`;
399
593
  }
400
594
  super(collectionEntity, action, undefined, identifiers);
@@ -410,6 +604,12 @@
410
604
  this.data.entityItemIdentifiers = {};
411
605
  }
412
606
 
607
+ /**
608
+ * Adds an identifier value (or values) for a specific entity item key.
609
+ * @param {string} key - The identifier name.
610
+ * @param {string|number|Array<string|number>} value - The identifier value(s).
611
+ * @throws Will throw if key is not a string or value is of invalid type.
612
+ */
413
613
  addEntityItemIdentifier(key, value) {
414
614
  if (typeof key !== 'string') {
415
615
  throw new Error('Entity identifier key must be a string');
@@ -417,11 +617,11 @@
417
617
  if (typeof value !== 'string' && typeof value !== 'number' && !Array.isArray(value)) {
418
618
  throw new Error('Entity identifier value must be a string or number');
419
619
  }
420
- if(typeof this.data.entityItemIdentifiers[key] == 'undefined') {
620
+ if (typeof this.data.entityItemIdentifiers[key] == 'undefined') {
421
621
  this.data.entityItemIdentifiers[key] = [];
422
622
  }
423
- if(Array.isArray(value)) {
424
- value.forEach((v)=> {
623
+ if (Array.isArray(value)) {
624
+ value.forEach((v) => {
425
625
  this.data.entityItemIdentifiers[key].push(v);
426
626
  });
427
627
  } else {
@@ -429,7 +629,6 @@
429
629
  }
430
630
  }
431
631
 
432
-
433
632
  }
434
633
 
435
634
  (function(global) {
@@ -1 +1 @@
1
- {"version":3,"file":"collecionesClientos.iife.js","sources":["../src/utils/utils.js","../src/CollecionesBaseEvent.js","../src/CollecionesEmitter.js","../src/CollecionesTracker.js","../src/CollecionesWebTracker.js","../src/CollecionesEvent.js","../node_modules/uuid/dist/esm-browser/stringify.js","../node_modules/uuid/dist/esm-browser/rng.js","../node_modules/uuid/dist/esm-browser/native.js","../node_modules/uuid/dist/esm-browser/v4.js","../src/CollecionesSemanticEvent.js","../src/CollecionesSemanticCollectionEvent.js","../src/collecionesClientos.js"],"sourcesContent":["// helper 'private' functions\nconst underscoreToCamelCase = function (str) {\n str = str.replace(/[^\\x00-\\x7F_]/g, '');\n return str\n .split('_')\n .map((word, index) => {\n if (index === 0) {\n return word;\n }\n return word.charAt(0).toUpperCase() + word.slice(1).toLowerCase();\n })\n .join('');\n}\n\nconst formatAdjectives = function (adjectiveParameter) {\n let errorMsg = new Error('Adjective must be a string, an array of strings, or undefined');\n if (typeof adjectiveParameter === 'undefined') {\n return undefined;\n }\n if (typeof adjectiveParameter === 'string') {\n return [underscoreToCamelCase(adjectiveParameter)];\n }\n if (Array.isArray(adjectiveParameter) && adjectiveParameter.every(item => typeof item === 'string')) {\n let returnValue = [];\n adjectiveParameter.forEach((adjectiveParameter) => {\n if (!typeof item === 'string') {\n throw errorMsg;\n }\n returnValue.push(underscoreToCamelCase(adjectiveParameter));\n });\n return returnValue;\n }\n throw errorMsg;\n}\n\nconst stringifyAdjectives = function (adjective) {\n if (!Array.isArray(adjective) || adjective.length === 0) {\n return undefined;\n }\n const uniqueSorted = [...new Set(adjective)].sort();\n return '.' + uniqueSorted.join('.');\n}\n\nconst toBase64 = function (str) {\n if (typeof window !== 'undefined' && window.btoa) {\n return window.btoa(unescape(encodeURIComponent(str)));\n } else {\n return Buffer.from(str, 'utf-8').toString('base64');\n }\n}\n\nconst fromBase64 = function (b64) {\n if (typeof window !== 'undefined' && window.atob) {\n return decodeURIComponent(escape(window.atob(b64)));\n } else {\n return Buffer.from(b64, 'base64').toString('utf-8');\n }\n}\n\nconst getBrowserContext = function() {\n if (typeof window === 'undefined' || typeof navigator === 'undefined') {\n return {};\n }\n return {\n hasFocus: document.hasFocus(),\n language: navigator.language,\n platform: navigator.platform,\n referrer: document.referrer,\n screenHeight: window.screen.height,\n screenWidth: window.screen.width,\n timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,\n url: window.location.href,\n userAgent: navigator.userAgent,\n viewportHeight: window.innerHeight,\n viewportWidth: window.innerWidth,\n };\n}\n\nexport {\n formatAdjectives,\n fromBase64,\n getBrowserContext,\n stringifyAdjectives,\n toBase64,\n underscoreToCamelCase\n};","import { toBase64 } from './utils/utils.js';\n\nclass CollecionesBaseEvent {\n\n constructor() {\n this.eventName = '';\n this.data = {};\n this.data.meta = {\n eventFormat: 'CollecionesBaseEvent',\n eventFormatVersion: '1'\n };\n const now = new Date();\n this.data.timestamps = {};\n this.data.timestamps.clientDatetimeUtc = new Date().toISOString();\n if (typeof window !== 'undefined' && typeof navigator !== 'undefined' && navigator.language) {\n this.data.timestamps.clientDatetimeLocal = new Date(Date.now() - new Date().getTimezoneOffset() * 60000).toISOString();\n this.data.timestamps.timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;\n this.data.timestamps.timeZoneOffset = new Date().getTimezoneOffset()\n } else {\n this.data.timestamps.clientDatetimeLocal = new Date().toISOString();\n this.data.timestamps.timeZone = 'UTC';\n }\n }\n\n setEventName(name) {\n this.eventName = name;\n }\n\n getEventName() {\n return this.eventName;\n }\n\n getEventFormat() {\n let v = this.data?.meta?.eventFormat;\n return (typeof v !== 'undefined') ? v : '1';\n }\n\n getEventFormatVersion() {\n let v = this.data?.meta?.eventFormatVersion;\n return (typeof v !== 'undefined') ? v : 'CollecionesBaseEvent';\n }\n\n setData(data) {\n this.data = data;\n }\n\n addAttribute(name, value) {\n return this.addField(name, value);\n }\n\n addField(name, value) {\n if (typeof this.data.fields !== 'object' || this.data.fields === null) {\n this.data.fields = {};\n }\n this.data.fields[name] = value;\n }\n\n setTracker(name) {\n this.data.tracker = name;\n }\n\n setAppName(name) {\n this.data.appName = name;\n }\n\n convertParamIdentifiers(param) {\n if (typeof param === 'object' && param !== null && !Array.isArray(param)) {\n for (const [key, value] of Object.entries(param)) {\n this.addIdentifier(key, value);\n }\n }\n }\n\n addIdentifier(name, value) {\n if (typeof this.data.identifiers !== 'object' || this.data.identifiers === null) {\n this.data.identifiers = {};\n }\n this.data.identifiers[name] = value;\n }\n\n getPostObject() {\n this.data.timestamps.sendDatetimeUtc = new Date().toISOString();\n this.data.timestamps.sendDatetimeLocal = new Date(Date.now() - new Date().getTimezoneOffset() * 60000).toISOString();\n return {\n eventname: this.getEventName(),\n eventFormat: this.getEventFormat(),\n eventFormatVersion: this.getEventFormatVersion(),\n payload: toBase64(this.getPayload())\n };\n }\n\n overrideDatetime(dateTimeObject = {}) {\n for (const [key, value] of Object.entries(dateTimeObject)) {\n this.data.timestamps[key] = value;\n }\n }\n\n getPayload() {\n return JSON.stringify(this.data);\n }\n\n}\n\nexport default CollecionesBaseEvent;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\nimport {toBase64} from './utils/utils.js';\n\nclass CollecionesEmitter {\n\n constructor(endpoint = '/collect', flushSize = 10, flushInterval = false) {\n this.endpoint = endpoint;\n this.flushInterval = flushInterval;\n this.flushSize = flushSize;\n this.buffer = [];\n this.timer = null;\n }\n\n startTimer() {\n this.stopTimer();\n if (typeof this.flushInterval == 'number' && this.flushInterval > 0) {\n this.timer = setInterval(() => this.flush(), this.flushInterval);\n }\n }\n\n startTimerIfStopped() {\n if (!this.timer) {\n this.startTimer();\n }\n }\n\n stopTimer() {\n if (this.timer) {\n clearInterval(this.timer);\n }\n this.timer = null;\n }\n\n track(event) {\n if (!(event instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be an instance of CollecionesBaseEvent');\n }\n this.trackAsync(event);\n }\n\n async trackAsync(event) {\n if (!(event instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be an instance of CollecionesBaseEvent');\n }\n this.startTimerIfStopped();\n this.buffer.push(event);\n return (this.buffer.length >= this.flushSize) ? this.flush() : Promise.resolve();\n }\n\n async flush() {\n if (this.buffer.length === 0) return;\n const eventsToSend = [...this.buffer];\n this.buffer = [];\n let postPayload = [];\n eventsToSend.forEach((e) => {\n postPayload.push( e.getPostObject() );\n });\n this.stopTimer();\n try {\n const response = await fetch(this.endpoint, {\n method: 'POST',\n credentials: 'include',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify(postPayload)\n });\n if (!response.ok) {\n console.log(`Failed to send events: ${response.statusText}`);\n }\n return true;\n } catch (error) {\n console.log(`Network error sending events: ${error.message}`);\n } \n }\n}\n\nexport default CollecionesEmitter;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\nclass CollecionesTracker {\n \n constructor(emitters, trackerName, appName) {\n this.emitters = emitters;\n this.trackerName = trackerName;\n this.appName = appName;\n this.identifiers = {};\n }\n\n addIdentifier(name, value) {\n this.identifiers[name] = value;\n }\n\n track(collecionesEvent) {\n if (!(collecionesEvent instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be of type CollecionesEvent');\n }\n for (const [key, value] of Object.entries(this.identifiers)) {\n collecionesEvent.addIdentifier(key, value);\n }\n collecionesEvent.setTracker(this.trackerName);\n collecionesEvent.setAppName(this.appName); \n this.emitters.forEach(element => {\n element.track(collecionesEvent, this.trackerName, this.appName);\n });\n \n }\n}\n\nexport default CollecionesTracker;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\nimport CollecionesTracker from './CollecionesTracker.js';\nimport { getBrowserContext } from './utils/utils.js';\n\nclass CollecionesWebTracker extends CollecionesTracker {\n \n constructor(emitters, trackerName, appName) {\n super(emitters, trackerName, appName);\n }\n\n track(collecionesEvent) {\n if (!(collecionesEvent instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be of type CollecionesEvent');\n }\n collecionesEvent.addField('browserContext', getBrowserContext());\n super.track(collecionesEvent); \n }\n}\n\nexport default CollecionesWebTracker;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\nclass CollecionesEvent extends CollecionesBaseEvent {\n\n constructor(name, data, identifiers) {\n super();\n this.setEventName(name);\n Object.assign(this.data, data);\n this.convertParamIdentifiers(identifiers);\n }\n\n}\n\nexport default CollecionesEvent;","import validate from './validate.js';\nconst byteToHex = [];\nfor (let i = 0; i < 256; ++i) {\n byteToHex.push((i + 0x100).toString(16).slice(1));\n}\nexport function unsafeStringify(arr, offset = 0) {\n return (byteToHex[arr[offset + 0]] +\n byteToHex[arr[offset + 1]] +\n byteToHex[arr[offset + 2]] +\n byteToHex[arr[offset + 3]] +\n '-' +\n byteToHex[arr[offset + 4]] +\n byteToHex[arr[offset + 5]] +\n '-' +\n byteToHex[arr[offset + 6]] +\n byteToHex[arr[offset + 7]] +\n '-' +\n byteToHex[arr[offset + 8]] +\n byteToHex[arr[offset + 9]] +\n '-' +\n byteToHex[arr[offset + 10]] +\n byteToHex[arr[offset + 11]] +\n byteToHex[arr[offset + 12]] +\n byteToHex[arr[offset + 13]] +\n byteToHex[arr[offset + 14]] +\n byteToHex[arr[offset + 15]]).toLowerCase();\n}\nfunction stringify(arr, offset = 0) {\n const uuid = unsafeStringify(arr, offset);\n if (!validate(uuid)) {\n throw TypeError('Stringified UUID is invalid');\n }\n return uuid;\n}\nexport default stringify;\n","let getRandomValues;\nconst rnds8 = new Uint8Array(16);\nexport default function rng() {\n if (!getRandomValues) {\n if (typeof crypto === 'undefined' || !crypto.getRandomValues) {\n throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');\n }\n getRandomValues = crypto.getRandomValues.bind(crypto);\n }\n return getRandomValues(rnds8);\n}\n","const randomUUID = typeof crypto !== 'undefined' && crypto.randomUUID && crypto.randomUUID.bind(crypto);\nexport default { randomUUID };\n","import native from './native.js';\nimport rng from './rng.js';\nimport { unsafeStringify } from './stringify.js';\nfunction v4(options, buf, offset) {\n if (native.randomUUID && !buf && !options) {\n return native.randomUUID();\n }\n options = options || {};\n const rnds = options.random ?? options.rng?.() ?? rng();\n if (rnds.length < 16) {\n throw new Error('Random bytes length must be >= 16');\n }\n rnds[6] = (rnds[6] & 0x0f) | 0x40;\n rnds[8] = (rnds[8] & 0x3f) | 0x80;\n if (buf) {\n offset = offset || 0;\n if (offset < 0 || offset + 16 > buf.length) {\n throw new RangeError(`UUID byte range ${offset}:${offset + 15} is out of buffer bounds`);\n }\n for (let i = 0; i < 16; ++i) {\n buf[offset + i] = rnds[i];\n }\n return buf;\n }\n return unsafeStringify(rnds);\n}\nexport default v4;\n","import { v4 as uuidv4 } from 'uuid';\nimport {underscoreToCamelCase, formatAdjectives, stringifyAdjectives } from './utils/utils.js';\nimport CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\nclass CollecionesSemanticEvent extends CollecionesBaseEvent {\n\n constructor(entity, action, adjective, identifiers) {\n super();\n this.entity = underscoreToCamelCase(entity);\n this.action = underscoreToCamelCase(action);\n this.adjective = formatAdjectives(adjective);\n let adjectiveString = stringifyAdjectives(this.adjective);\n this.eventName = `${this.entity}${(adjectiveString !== undefined) ? adjectiveString : ''}__${this.action}`;\n this.convertParamIdentifiers(identifiers);\n this.data.entityIdentifiers = {};\n this.data.attributes = {};\n this.data.clientEventId = uuidv4();\n this.data.meta = {\n eventFormat: 'CollecionesSemanticEvent',\n eventFormatVersion: '1'\n };\n }\n\n setData() {\n throw new Error('setData deprecated in semantic events');\n }\n\n addEntityIdentifier(key, value) {\n if (typeof key !== 'string') {\n throw new Error('Entity identifier key must be a string');\n }\n if (typeof value !== 'string' && typeof value !== 'number') {\n throw new Error('Entity identifier value must be a string or number');\n }\n this.data.entityIdentifiers[key] = value;\n }\n\n}\n\nexport default CollecionesSemanticEvent;","import {underscoreToCamelCase, formatAdjectives, stringifyAdjectives } from './utils/utils.js';\nimport CollecionesSemanticEvent from './CollecionesSemanticEvent.js';\n\nclass CollecionesSemanticCollectionEvent extends CollecionesSemanticEvent {\n\n constructor(itemEntity, action, adjective, identifiers, collectionEntity) {\n if(typeof collectionEntity == 'undefined') {\n collectionEntity = `${itemEntity}Collection`;\n }\n super(collectionEntity, action, undefined, identifiers);\n this.data.meta = {\n eventFormat: 'CollecionesSemanticCollectionEvent',\n eventFormatVersion: '1'\n };\n this.adjective = formatAdjectives(adjective);\n let adjectiveString = stringifyAdjectives(this.adjective);\n itemEntity = underscoreToCamelCase(itemEntity);\n this.data.itemEntity = itemEntity;\n this.data.itemEventName = `${itemEntity}${(adjectiveString !== undefined) ? adjectiveString : ''}__${this.action}`;\n this.data.entityItemIdentifiers = {};\n }\n\n addEntityItemIdentifier(key, value) {\n if (typeof key !== 'string') {\n throw new Error('Entity identifier key must be a string');\n }\n if (typeof value !== 'string' && typeof value !== 'number' && !Array.isArray(value)) {\n throw new Error('Entity identifier value must be a string or number');\n }\n if(typeof this.data.entityItemIdentifiers[key] == 'undefined') {\n this.data.entityItemIdentifiers[key] = [];\n }\n if(Array.isArray(value)) {\n value.forEach((v)=> {\n this.data.entityItemIdentifiers[key].push(v);\n });\n } else {\n this.data.entityItemIdentifiers[key].push(value);\n }\n }\n\n \n}\n\nexport default CollecionesSemanticCollectionEvent;","import CollecionesEmitter from './CollecionesEmitter.js';\nimport CollecionesTracker from './CollecionesTracker.js';\nimport CollecionesWebTracker from './CollecionesWebTracker.js';\nimport CollecionesEvent from './CollecionesEvent.js';\nimport CollecionesSemanticEvent from './CollecionesSemanticEvent.js';\nimport CollecionesSemanticCollectionEvent from './CollecionesSemanticCollectionEvent.js';\n\n(function(global) {\n global.CollecionesEmitter = CollecionesEmitter;\n global.CollecionesTracker = CollecionesTracker;\n global.CollecionesWebTracker = CollecionesWebTracker;\n global.CollecionesEvent = CollecionesEvent;\n global.CollecionesSemanticEvent = CollecionesSemanticEvent;\n global.CollecionesSemanticCollectionEvent = CollecionesSemanticCollectionEvent;\n})(typeof window !== 'undefined' ? window : globalThis);"],"names":["uuidv4"],"mappings":";;;IAAA;IACA,MAAM,qBAAqB,GAAG,UAAU,GAAG,EAAE;IAC7C,IAAI,GAAG,GAAG,GAAG,CAAC,OAAO,CAAC,gBAAgB,EAAE,EAAE,CAAC;IAC3C,IAAI,OAAO;IACX,SAAS,KAAK,CAAC,GAAG;IAClB,SAAS,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,KAAK;IAC9B,YAAY,IAAI,KAAK,KAAK,CAAC,EAAE;IAC7B,gBAAgB,OAAO,IAAI;IAC3B;IACA,YAAY,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE;IAC7E,SAAS;IACT,SAA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AM,IAAI,KAAK,CAAC,oDAAoD,CAAC;IACjF;IACA,QAAQ,GAAG,OAAO,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,IAAI,WAAW,EAAE;IACvE,YAAY,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,GAAG,EAAE;IACrD;IACA,QAAQ,GAAG,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;IACjC,YAAY,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI;IAChC,gBAAgB,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;IAC5D,aAAa,CAAC;IACd,SAAS,MAAM;IACf,YAAY,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC;IAC5D;IACA;;IAEA;IACA;;ICnCA,CAAC,SAAS,MAAM,EAAE;IAClB,EAAE,MAAM,CAAC,kBAAkB,GAAG,kBAAkB;IAChD,EAAE,MAAM,CAAC,kBAAkB,GAAG,kBAAkB;IAChD,EAAE,MAAM,CAAC,qBAAqB,GAAG,qBAAqB;IACtD,EAAE,MAAM,CAAC,gBAAgB,GAAG,gBAAgB;IAC5C,EAAE,MAAM,CAAC,wBAAwB,GAAG,wBAAwB;IAC5D,EAAE,MAAM,CAAC,kCAAkC,GAAG,kCAAkC;IAChF,CAAC,EAAE,OAAO,MAAM,KAAK,WAAW,GAAG,MAAM,GAAG,UAAU,CAAC;;;;;;","x_google_ignoreList":[6,7,8,9]}
1
+ {"version":3,"file":"collecionesClientos.iife.js","sources":["../src/utils/utils.js","../src/CollecionesBaseEvent.js","../src/CollecionesEmitter.js","../src/CollecionesTracker.js","../src/CollecionesWebTracker.js","../src/CollecionesEvent.js","../node_modules/uuid/dist/esm-browser/stringify.js","../node_modules/uuid/dist/esm-browser/rng.js","../node_modules/uuid/dist/esm-browser/native.js","../node_modules/uuid/dist/esm-browser/v4.js","../src/CollecionesSemanticEvent.js","../src/CollecionesSemanticCollectionEvent.js","../src/collecionesClientos.js"],"sourcesContent":["// helper 'private' functions\n/**\n * Converts a snake_case string to camelCase.\n * Removes non-ASCII characters.\n * @param {string} str\n * @returns {string}\n */\nconst underscoreToCamelCase = function (str) {\n str = str.replace(/[^\\x00-\\x7F_]/g, '');\n return str\n .split('_')\n .map((word, index) => {\n if (index === 0) {\n return word;\n }\n return word.charAt(0).toUpperCase() + word.slice(1).toLowerCase();\n })\n .join('');\n}\n\n/**\n * Formats adjectives by converting them to camelCase strings.\n * Accepts a single string or an array of strings.\n * @param {string|string[]|undefined} adjectiveParameter\n * @returns {string[]|undefined}\n */\nconst formatAdjectives = function (adjectiveParameter) {\n const errorMsg = new Error('Adjective must be a string, an array of strings, or undefined');\n if (typeof adjectiveParameter === 'undefined') {\n return undefined;\n }\n if (typeof adjectiveParameter === 'string') {\n return [underscoreToCamelCase(adjectiveParameter)];\n }\n if (Array.isArray(adjectiveParameter) && adjectiveParameter.every(item => typeof item === 'string')) {\n return adjectiveParameter.map(adjective => underscoreToCamelCase(adjective));\n }\n throw errorMsg;\n}\n\n/**\n * Converts an array of adjective strings to a dot-prefixed, dot-separated string.\n * Removes duplicates and sorts alphabetically.\n * @param {string[]} adjective\n * @returns {string|undefined}\n */\nconst stringifyAdjectives = function (adjective) {\n if (!Array.isArray(adjective) || adjective.length === 0) {\n return undefined;\n }\n const uniqueSorted = [...new Set(adjective)].sort();\n return '.' + uniqueSorted.join('.');\n}\n\n/**\n * Encodes a string to Base64.\n * Uses browser or Node.js method depending on environment.\n * @param {string} str\n * @returns {string}\n */\nconst toBase64 = function (str) {\n if (typeof window !== 'undefined' && typeof window.btoa === 'function') {\n return window.btoa(unescape(encodeURIComponent(str)));\n } else {\n return Buffer.from(str, 'utf-8').toString('base64');\n }\n}\n\n/**\n * Decodes a Base64 string to UTF-8.\n * Uses browser or Node.js method depending on environment.\n * @param {string} b64\n * @returns {string}\n */\nconst fromBase64 = function (b64) {\n if (typeof window !== 'undefined' && typeof window.atob === 'function') {\n return decodeURIComponent(escape(window.atob(b64)));\n } else {\n return Buffer.from(b64, 'base64').toString('utf-8');\n }\n}\n\n/**\n * Collects browser-related context values like screen size, language, etc.\n * Returns an empty object if not in browser environment.\n * @returns {Object}\n */\nconst getBrowserContext = function() {\n if (typeof window === 'undefined' || typeof navigator === 'undefined') {\n return {};\n }\n return {\n hasFocus: document.hasFocus(),\n language: navigator.language,\n platform: navigator.platform,\n referrer: document.referrer,\n screenHeight: window.screen.height,\n screenWidth: window.screen.width,\n timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,\n url: window.location.href,\n userAgent: navigator.userAgent,\n viewportHeight: window.innerHeight,\n viewportWidth: window.innerWidth,\n };\n}\n\nexport {\n formatAdjectives,\n fromBase64,\n getBrowserContext,\n stringifyAdjectives,\n toBase64,\n underscoreToCamelCase\n};","import { toBase64 } from './utils/utils.js';\n\n/**\n * Base class representing a structured event with timestamp, identifiers, and data fields.\n */\nclass CollecionesBaseEvent {\n\n /**\n * Constructs a new event with default metadata and timestamps.\n */\n constructor() {\n this.eventName = '';\n this.data = {};\n this.data.meta = {\n eventFormat: 'CollecionesBaseEvent',\n eventFormatVersion: '1'\n };\n const now = new Date();\n this.data.timestamps = {};\n this.data.timestamps.clientDatetimeUtc = new Date().toISOString();\n if (typeof window !== 'undefined' && typeof navigator !== 'undefined' && navigator.language) {\n this.data.timestamps.clientDatetimeLocal = new Date(Date.now() - new Date().getTimezoneOffset() * 60000).toISOString();\n this.data.timestamps.timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;\n this.data.timestamps.timeZoneOffset = new Date().getTimezoneOffset()\n } else {\n this.data.timestamps.clientDatetimeLocal = new Date().toISOString();\n this.data.timestamps.timeZone = 'UTC';\n }\n }\n\n /**\n * Sets the event name.\n * @param {string} name\n */\n setEventName(name) {\n this.eventName = name;\n }\n\n /**\n * Returns the event name.\n * @returns {string}\n */\n getEventName() {\n return this.eventName;\n }\n\n /**\n * Gets the format of the event.\n * @returns {string}\n */\n getEventFormat() {\n let v = this.data?.meta?.eventFormat;\n return (typeof v !== 'undefined') ? v : '1';\n }\n\n /**\n * Gets the version of the event format.\n * @returns {string}\n */\n getEventFormatVersion() {\n let v = this.data?.meta?.eventFormatVersion;\n return (typeof v !== 'undefined') ? v : 'CollecionesBaseEvent';\n }\n\n /**\n * Replaces the entire data object.\n * @param {object} data\n */\n setData(data) {\n this.data = data;\n }\n\n /**\n * Adds a field to the event's custom fields section.\n * @param {string} name\n * @param {*} value\n */\n addAttribute(name, value) {\n return this.addField(name, value);\n }\n\n /**\n * Adds a key-value pair to the custom fields.\n * @param {string} name\n * @param {*} value\n */\n addField(name, value) {\n if (typeof this.data.fields !== 'object' || this.data.fields === null) {\n this.data.fields = {};\n }\n this.data.fields[name] = value;\n }\n\n /**\n * Sets the name of the tracker used to generate the event.\n * @param {string} name\n */\n setTracker(name) {\n this.data.tracker = name;\n }\n\n /**\n * Sets the name of the application that created the event.\n * @param {string} name\n */\n setAppName(name) {\n this.data.appName = name;\n }\n\n /**\n * Adds multiple identifiers from an object.\n * @param {object} param\n */\n convertParamIdentifiers(param) {\n if (typeof param === 'object' && param !== null && !Array.isArray(param)) {\n for (const [key, value] of Object.entries(param)) {\n this.addIdentifier(key, value);\n }\n }\n }\n\n /**\n * Adds a single identifier to the event.\n * @param {string} name\n * @param {*} value\n */\n addIdentifier(name, value) {\n if (typeof this.data.identifiers !== 'object' || this.data.identifiers === null) {\n this.data.identifiers = {};\n }\n this.data.identifiers[name] = value;\n }\n\n /**\n * Constructs the postable event object with metadata and encoded payload.\n * @returns {object}\n */\n getPostObject() {\n this.data.timestamps.sendDatetimeUtc = new Date().toISOString();\n this.data.timestamps.sendDatetimeLocal = new Date(Date.now() - new Date().getTimezoneOffset() * 60000).toISOString();\n return {\n eventname: this.getEventName(),\n eventFormat: this.getEventFormat(),\n eventFormatVersion: this.getEventFormatVersion(),\n payload: toBase64(this.getPayload())\n };\n }\n\n /**\n * Overrides or extends the timestamp fields of the event.\n * @param {object} dateTimeObject\n */\n overrideDatetime(dateTimeObject = {}) {\n for (const [key, value] of Object.entries(dateTimeObject)) {\n this.data.timestamps[key] = value;\n }\n }\n\n /**\n * Serializes the event data to a JSON string.\n * @returns {string}\n */\n getPayload() {\n return JSON.stringify(this.data);\n }\n\n}\n\nexport default CollecionesBaseEvent;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\n/**\n * Emitter class responsible for batching and sending events to a configured endpoint.\n */\nclass CollecionesEmitter {\n\n /**\n * Initializes the emitter with buffering settings.\n * @param {string} [endpoint='/collect'] - The URL to send events to.\n * @param {number} [flushSize=10] - Number of events to buffer before flushing.\n * @param {number|boolean} [flushInterval=false] - Time in ms to flush events periodically.\n */\n constructor(endpoint = '/collect', flushSize = 10, flushInterval = false) {\n this.endpoint = endpoint;\n this.flushInterval = flushInterval;\n this.flushSize = flushSize;\n this.buffer = [];\n this.timer = null;\n }\n\n /**\n * Starts the flush timer if a valid interval is set.\n */\n startTimer() {\n this.stopTimer();\n if (typeof this.flushInterval == 'number' && this.flushInterval > 0) {\n this.timer = setInterval(() => this.flush(), this.flushInterval);\n }\n }\n\n /**\n * Starts the flush timer only if not already running.\n */\n startTimerIfStopped() {\n if (!this.timer) {\n this.startTimer();\n }\n }\n\n /**\n * Stops the active flush timer.\n */\n stopTimer() {\n if (this.timer) {\n clearInterval(this.timer);\n }\n this.timer = null;\n }\n\n /**\n * Adds an event to the buffer and flushes if threshold is reached.\n * @param {CollecionesBaseEvent} event\n */\n track(event) {\n if (!(event instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be an instance of CollecionesBaseEvent');\n }\n this.trackAsync(event);\n }\n\n /**\n * Asynchronously adds an event and flushes if the buffer size is exceeded.\n * @param {CollecionesBaseEvent} event\n * @returns {Promise<void>}\n */\n async trackAsync(event) {\n if (!(event instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be an instance of CollecionesBaseEvent');\n }\n this.startTimerIfStopped();\n this.buffer.push(event);\n return (this.buffer.length >= this.flushSize) ? this.flush() : Promise.resolve();\n }\n\n /**\n * Sends the buffered events to the server and clears the buffer.\n * @returns {Promise<boolean|undefined>}\n */\n async flush() {\n if (this.buffer.length === 0) return;\n const eventsToSend = [...this.buffer];\n this.buffer = [];\n let postPayload = [];\n eventsToSend.forEach((e) => {\n postPayload.push( e.getPostObject() );\n });\n this.stopTimer();\n try {\n const response = await fetch(this.endpoint, {\n method: 'POST',\n credentials: 'include',\n headers: {\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify(postPayload)\n });\n if (!response.ok) {\n console.log(`Failed to send events: ${response.statusText}`);\n }\n return true;\n } catch (error) {\n console.log(`Network error sending events: ${error.message}`);\n } \n }\n}\n\nexport default CollecionesEmitter;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\n/**\n * Tracks events by enriching them with shared identifiers and routing through configured emitters.\n */\nclass CollecionesTracker {\n\n /**\n * Constructs a new tracker instance.\n * @param {Array} emitters - Array of emitter instances responsible for sending events.\n * @param {string} trackerName - Name identifying this tracker.\n * @param {string} appName - Name of the application generating events.\n */\n constructor(emitters, trackerName, appName) {\n this.emitters = emitters;\n this.trackerName = trackerName;\n this.appName = appName;\n this.identifiers = {};\n }\n\n /**\n * Adds a global identifier to be included with every event.\n * @param {string} name - Identifier key.\n * @param {*} value - Identifier value.\n */\n addIdentifier(name, value) {\n this.identifiers[name] = value;\n }\n\n /**\n * Sends an event to all emitters after enriching it with identifiers and metadata.\n * @param {CollecionesBaseEvent} collecionesEvent - The event to be sent.\n * @throws {Error} If the input is not an instance of CollecionesBaseEvent.\n */\n track(collecionesEvent) {\n if (!(collecionesEvent instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be of type CollecionesEvent');\n }\n for (const [key, value] of Object.entries(this.identifiers)) {\n collecionesEvent.addIdentifier(key, value);\n }\n collecionesEvent.setTracker(this.trackerName);\n collecionesEvent.setAppName(this.appName); \n this.emitters.forEach(element => {\n element.track(collecionesEvent, this.trackerName, this.appName);\n });\n }\n}\n\nexport default CollecionesTracker;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\nimport CollecionesTracker from './CollecionesTracker.js';\nimport { getBrowserContext } from './utils/utils.js';\n\n/**\n * Web-specific tracker that enriches events with browser context before sending them.\n * Extends the base CollecionesTracker.\n */\nclass CollecionesWebTracker extends CollecionesTracker {\n /**\n * Creates a new instance of CollecionesWebTracker.\n * @param {Array} emitters - A list of emitter instances used to send the event.\n * @param {string} trackerName - The name of the tracker.\n * @param {string} appName - The name of the application generating events.\n */\n constructor(emitters, trackerName, appName) {\n super(emitters, trackerName, appName);\n }\n\n /**\n * Tracks an event, enriching it with browser context information.\n * @param {CollecionesBaseEvent} collecionesEvent - The event object to track.\n * @throws {Error} If the event is not an instance of CollecionesBaseEvent.\n */\n track(collecionesEvent) {\n if (!(collecionesEvent instanceof CollecionesBaseEvent)) {\n throw new Error('Event must be of type CollecionesEvent');\n }\n collecionesEvent.addField('browserContext', getBrowserContext());\n super.track(collecionesEvent); \n }\n}\n\nexport default CollecionesWebTracker;","import CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\n/**\n * Represents a semantic event with a name, data payload, and identifiers.\n * Extends CollecionesBaseEvent.\n */\nclass CollecionesEvent extends CollecionesBaseEvent {\n\n /**\n * Constructs a new CollecionesEvent instance.\n * @param {string} name - The name of the event.\n * @param {object} data - The main data payload of the event.\n * @param {object} identifiers - A set of identifiers to associate with the event.\n */\n constructor(name, data, identifiers) {\n super();\n this.setEventName(name);\n Object.assign(this.data, data);\n this.convertParamIdentifiers(identifiers);\n }\n\n}\n\nexport default CollecionesEvent;","import validate from './validate.js';\nconst byteToHex = [];\nfor (let i = 0; i < 256; ++i) {\n byteToHex.push((i + 0x100).toString(16).slice(1));\n}\nexport function unsafeStringify(arr, offset = 0) {\n return (byteToHex[arr[offset + 0]] +\n byteToHex[arr[offset + 1]] +\n byteToHex[arr[offset + 2]] +\n byteToHex[arr[offset + 3]] +\n '-' +\n byteToHex[arr[offset + 4]] +\n byteToHex[arr[offset + 5]] +\n '-' +\n byteToHex[arr[offset + 6]] +\n byteToHex[arr[offset + 7]] +\n '-' +\n byteToHex[arr[offset + 8]] +\n byteToHex[arr[offset + 9]] +\n '-' +\n byteToHex[arr[offset + 10]] +\n byteToHex[arr[offset + 11]] +\n byteToHex[arr[offset + 12]] +\n byteToHex[arr[offset + 13]] +\n byteToHex[arr[offset + 14]] +\n byteToHex[arr[offset + 15]]).toLowerCase();\n}\nfunction stringify(arr, offset = 0) {\n const uuid = unsafeStringify(arr, offset);\n if (!validate(uuid)) {\n throw TypeError('Stringified UUID is invalid');\n }\n return uuid;\n}\nexport default stringify;\n","let getRandomValues;\nconst rnds8 = new Uint8Array(16);\nexport default function rng() {\n if (!getRandomValues) {\n if (typeof crypto === 'undefined' || !crypto.getRandomValues) {\n throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');\n }\n getRandomValues = crypto.getRandomValues.bind(crypto);\n }\n return getRandomValues(rnds8);\n}\n","const randomUUID = typeof crypto !== 'undefined' && crypto.randomUUID && crypto.randomUUID.bind(crypto);\nexport default { randomUUID };\n","import native from './native.js';\nimport rng from './rng.js';\nimport { unsafeStringify } from './stringify.js';\nfunction v4(options, buf, offset) {\n if (native.randomUUID && !buf && !options) {\n return native.randomUUID();\n }\n options = options || {};\n const rnds = options.random ?? options.rng?.() ?? rng();\n if (rnds.length < 16) {\n throw new Error('Random bytes length must be >= 16');\n }\n rnds[6] = (rnds[6] & 0x0f) | 0x40;\n rnds[8] = (rnds[8] & 0x3f) | 0x80;\n if (buf) {\n offset = offset || 0;\n if (offset < 0 || offset + 16 > buf.length) {\n throw new RangeError(`UUID byte range ${offset}:${offset + 15} is out of buffer bounds`);\n }\n for (let i = 0; i < 16; ++i) {\n buf[offset + i] = rnds[i];\n }\n return buf;\n }\n return unsafeStringify(rnds);\n}\nexport default v4;\n","import { v4 as uuidv4 } from 'uuid';\nimport {underscoreToCamelCase, formatAdjectives, stringifyAdjectives } from './utils/utils.js';\nimport CollecionesBaseEvent from './CollecionesBaseEvent.js';\n\n/**\n * Represents a structured semantic event with entity, action, and optional adjective.\n * Includes automatic naming and identifier mapping.\n * Extends CollecionesBaseEvent.\n */\nclass CollecionesSemanticEvent extends CollecionesBaseEvent {\n\n /**\n * Constructs a new semantic event.\n * @param {string} entity - The entity involved in the event.\n * @param {string} action - The action performed on the entity.\n * @param {string|string[]|undefined} adjective - Optional adjective(s) modifying the event.\n * @param {object} identifiers - Key-value pairs to be added as identifiers.\n */\n constructor(entity, action, adjective, identifiers) {\n super();\n this.entity = underscoreToCamelCase(entity);\n this.action = underscoreToCamelCase(action);\n this.adjective = formatAdjectives(adjective);\n let adjectiveString = stringifyAdjectives(this.adjective);\n this.eventName = `${this.entity}${(adjectiveString !== undefined) ? adjectiveString : ''}__${this.action}`;\n this.convertParamIdentifiers(identifiers);\n this.data.entityIdentifiers = {};\n this.data.attributes = {};\n this.data.clientEventId = uuidv4();\n this.data.meta = {\n eventFormat: 'CollecionesSemanticEvent',\n eventFormatVersion: '1'\n };\n }\n\n /**\n * This method is deprecated in semantic events and will throw if called.\n * @throws {Error}\n */\n setData() {\n throw new Error('setData deprecated in semantic events');\n }\n\n /**\n * Adds a key-value pair as an identifier for the semantic entity.\n * @param {string} key - The identifier name.\n * @param {string|number} value - The identifier value.\n * @throws Will throw if key is not a string or value is not a string or number.\n */\n addEntityIdentifier(key, value) {\n if (typeof key !== 'string') {\n throw new Error('Entity identifier key must be a string');\n }\n if (typeof value !== 'string' && typeof value !== 'number') {\n throw new Error('Entity identifier value must be a string or number');\n }\n this.data.entityIdentifiers[key] = value;\n }\n\n}\n\nexport default CollecionesSemanticEvent;","import { underscoreToCamelCase, formatAdjectives, stringifyAdjectives } from './utils/utils.js';\nimport CollecionesSemanticEvent from './CollecionesSemanticEvent.js';\n\n/**\n * Represents a semantic event related to a collection of entities.\n * Extends CollecionesSemanticEvent and adds item-level detail and identifiers.\n */\nclass CollecionesSemanticCollectionEvent extends CollecionesSemanticEvent {\n\n /**\n * Constructs a new CollecionesSemanticCollectionEvent.\n * @param {string} itemEntity - The name of the item entity being acted on.\n * @param {string} action - The action performed.\n * @param {string|string[]|undefined} adjective - Optional adjective(s) describing the action.\n * @param {object} identifiers - Identifiers associated with the event.\n * @param {string} [collectionEntity] - Optional collection name, defaults to `${itemEntity}Collection`.\n */\n constructor(itemEntity, action, adjective, identifiers, collectionEntity) {\n if (typeof collectionEntity == 'undefined') {\n collectionEntity = `${itemEntity}Collection`;\n }\n super(collectionEntity, action, undefined, identifiers);\n this.data.meta = {\n eventFormat: 'CollecionesSemanticCollectionEvent',\n eventFormatVersion: '1'\n };\n this.adjective = formatAdjectives(adjective);\n let adjectiveString = stringifyAdjectives(this.adjective);\n itemEntity = underscoreToCamelCase(itemEntity);\n this.data.itemEntity = itemEntity;\n this.data.itemEventName = `${itemEntity}${(adjectiveString !== undefined) ? adjectiveString : ''}__${this.action}`;\n this.data.entityItemIdentifiers = {};\n }\n\n /**\n * Adds an identifier value (or values) for a specific entity item key.\n * @param {string} key - The identifier name.\n * @param {string|number|Array<string|number>} value - The identifier value(s).\n * @throws Will throw if key is not a string or value is of invalid type.\n */\n addEntityItemIdentifier(key, value) {\n if (typeof key !== 'string') {\n throw new Error('Entity identifier key must be a string');\n }\n if (typeof value !== 'string' && typeof value !== 'number' && !Array.isArray(value)) {\n throw new Error('Entity identifier value must be a string or number');\n }\n if (typeof this.data.entityItemIdentifiers[key] == 'undefined') {\n this.data.entityItemIdentifiers[key] = [];\n }\n if (Array.isArray(value)) {\n value.forEach((v) => {\n this.data.entityItemIdentifiers[key].push(v);\n });\n } else {\n this.data.entityItemIdentifiers[key].push(value);\n }\n }\n\n}\n\nexport default CollecionesSemanticCollectionEvent;","import CollecionesEmitter from './CollecionesEmitter.js';\nimport CollecionesTracker from './CollecionesTracker.js';\nimport CollecionesWebTracker from './CollecionesWebTracker.js';\nimport CollecionesEvent from './CollecionesEvent.js';\nimport CollecionesSemanticEvent from './CollecionesSemanticEvent.js';\nimport CollecionesSemanticCollectionEvent from './CollecionesSemanticCollectionEvent.js';\n\n(function(global) {\n global.CollecionesEmitter = CollecionesEmitter;\n global.CollecionesTracker = CollecionesTracker;\n global.CollecionesWebTracker = CollecionesWebTracker;\n global.CollecionesEvent = CollecionesEvent;\n global.CollecionesSemanticEvent = CollecionesSemanticEvent;\n global.CollecionesSemanticCollectionEvent = CollecionesSemanticCollectionEvent;\n})(typeof window !== 'undefined' ? window : globalThis);"],"names":["uuidv4"],"mappings":";;;IAAA;IACA;IACA;IACA;IACA;IACA;IACA;IACA,MAAM,qBAAqB,GAAG,UAAU,GAAG,EAAE;IAC7C,IAAI,GAAG,GAAG,GAAG,CAAC,OAAO,CAAC,gBAAgB,EAAE,EAAE,CAAC;IAC3C,IAAI,OAAO;IACX,SAAS,KAAK,CAAC,GAAG;IAClB,SAAS,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,KAAK;IAC9B,YAAY,IAAI,KAAK,KAAK,CAAC,EAAE;IAC7B,gBAAgB,OAAO,IAAI;IAC3B;IACA,YAAY,OAAO,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,WAAW,EAAE;IAC7E,SAAS;IACT,SAAS,IAAI,CAAC,EAAE,CAAC;IACjB;;IAEA;IACA;IACA;IACA;IACA;IACA;IACA,MAAM,gBAAgB,GAAG,UAAU,kBAAkB,EAAE;IACvD,IAAI,MAAM,QAAQ,GAAG,IAAI,KAAK,CAAC,+DAA+D,CAAC;IAC/F,IAAI,IAAI,OAAO,kBAAkB,KAAK,WAAW,EAAE;IACnD,QAAQ,OAAO,SAAS;IACxB;IACA,IAAI,IAAI,OAAO,kBAAkB,KAAK,QAAQ,EAAE;IAChD,QAAQ,OAAO,CAAC,qBAAqB,CAAC,kBAAkB,CAAC,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