@newrelic/browser-agent 1.298.0-rc.3 → 1.298.0-rc.5

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.
Files changed (54) hide show
  1. package/README.md +12 -2
  2. package/dist/cjs/common/constants/env.cdn.js +1 -1
  3. package/dist/cjs/common/constants/env.npm.js +1 -1
  4. package/dist/cjs/common/dom/selector-path.js +60 -44
  5. package/dist/cjs/common/url/extract-url.js +21 -0
  6. package/dist/cjs/features/ajax/instrument/index.js +2 -9
  7. package/dist/cjs/features/generic_events/aggregate/index.js +29 -8
  8. package/dist/cjs/features/generic_events/aggregate/user-actions/aggregated-user-action.js +5 -3
  9. package/dist/cjs/features/generic_events/aggregate/user-actions/user-actions-aggregator.js +71 -33
  10. package/dist/cjs/features/generic_events/constants.js +2 -1
  11. package/dist/cjs/features/generic_events/instrument/index.js +45 -0
  12. package/dist/cjs/loaders/api/noticeError.js +1 -0
  13. package/dist/cjs/loaders/configure/configure.js +1 -0
  14. package/dist/esm/common/constants/env.cdn.js +1 -1
  15. package/dist/esm/common/constants/env.npm.js +1 -1
  16. package/dist/esm/common/dom/selector-path.js +58 -42
  17. package/dist/esm/common/url/extract-url.js +15 -0
  18. package/dist/esm/features/ajax/instrument/index.js +2 -9
  19. package/dist/esm/features/generic_events/aggregate/index.js +29 -8
  20. package/dist/esm/features/generic_events/aggregate/user-actions/aggregated-user-action.js +5 -3
  21. package/dist/esm/features/generic_events/aggregate/user-actions/user-actions-aggregator.js +72 -34
  22. package/dist/esm/features/generic_events/constants.js +1 -0
  23. package/dist/esm/features/generic_events/instrument/index.js +46 -1
  24. package/dist/esm/loaders/api/noticeError.js +1 -0
  25. package/dist/esm/loaders/configure/configure.js +1 -0
  26. package/dist/tsconfig.tsbuildinfo +1 -1
  27. package/dist/types/common/dom/selector-path.d.ts +6 -1
  28. package/dist/types/common/dom/selector-path.d.ts.map +1 -1
  29. package/dist/types/common/url/extract-url.d.ts +7 -0
  30. package/dist/types/common/url/extract-url.d.ts.map +1 -0
  31. package/dist/types/features/ajax/instrument/index.d.ts.map +1 -1
  32. package/dist/types/features/generic_events/aggregate/index.d.ts +1 -3
  33. package/dist/types/features/generic_events/aggregate/index.d.ts.map +1 -1
  34. package/dist/types/features/generic_events/aggregate/user-actions/aggregated-user-action.d.ts +3 -1
  35. package/dist/types/features/generic_events/aggregate/user-actions/aggregated-user-action.d.ts.map +1 -1
  36. package/dist/types/features/generic_events/aggregate/user-actions/user-actions-aggregator.d.ts +3 -0
  37. package/dist/types/features/generic_events/aggregate/user-actions/user-actions-aggregator.d.ts.map +1 -1
  38. package/dist/types/features/generic_events/constants.d.ts +1 -0
  39. package/dist/types/features/generic_events/constants.d.ts.map +1 -1
  40. package/dist/types/features/generic_events/instrument/index.d.ts +2 -0
  41. package/dist/types/features/generic_events/instrument/index.d.ts.map +1 -1
  42. package/dist/types/loaders/api/noticeError.d.ts.map +1 -1
  43. package/dist/types/loaders/configure/configure.d.ts.map +1 -1
  44. package/package.json +1 -1
  45. package/src/common/dom/selector-path.js +51 -39
  46. package/src/common/url/extract-url.js +17 -0
  47. package/src/features/ajax/instrument/index.js +2 -10
  48. package/src/features/generic_events/aggregate/index.js +23 -8
  49. package/src/features/generic_events/aggregate/user-actions/aggregated-user-action.js +5 -3
  50. package/src/features/generic_events/aggregate/user-actions/user-actions-aggregator.js +80 -24
  51. package/src/features/generic_events/constants.js +2 -0
  52. package/src/features/generic_events/instrument/index.js +51 -1
  53. package/src/loaders/api/noticeError.js +1 -0
  54. package/src/loaders/configure/configure.js +1 -0
@@ -4,60 +4,76 @@
4
4
  */
5
5
 
6
6
  /**
7
- * Generates a CSS selector path for the given element, if possible
7
+ * Generates a CSS selector path for the given element, if possible.
8
+ * Also gather metadata about the element's nearest fields, and whether there are any links or buttons in the path.
9
+ *
10
+ * Starts with simple cases like window or document and progresses to more complex dom-tree traversals as needed.
11
+ * Will return path: undefined if no other path can be determined.
12
+ *
8
13
  * @param {HTMLElement} elem
9
- * @param {boolean} includeId
10
- * @param {boolean} includeClass
11
- * @returns {string|undefined}
14
+ * @param {Array<string>} [targetFields=[]] specifies which fields to gather from the nearest element in the path
15
+ * @returns {{path: (undefined|string), nearestFields: {}, hasButton: boolean, hasLink: boolean}}
12
16
  */
13
- export const generateSelectorPath = (elem, targetFields = []) => {
14
- if (!elem) return {
17
+ export const analyzeElemPath = (elem, targetFields = []) => {
18
+ const result = {
15
19
  path: undefined,
16
- nearestFields: {}
17
- };
18
- const getNthOfTypeIndex = node => {
19
- try {
20
- let i = 1;
21
- const {
22
- tagName
23
- } = node;
24
- while (node.previousElementSibling) {
25
- if (node.previousElementSibling.tagName === tagName) i++;
26
- node = node.previousElementSibling;
27
- }
28
- return i;
29
- } catch (err) {
30
- // do nothing for now. An invalid child count will make the path selector not return a nth-of-type selector statement
31
- }
20
+ nearestFields: {},
21
+ hasButton: false,
22
+ hasLink: false
32
23
  };
24
+ if (!elem) return result;
25
+ if (elem === window) {
26
+ result.path = 'window';
27
+ return result;
28
+ }
29
+ if (elem === document) {
30
+ result.path = 'document';
31
+ return result;
32
+ }
33
33
  let pathSelector = '';
34
- let index = getNthOfTypeIndex(elem);
35
- const nearestFields = {};
34
+ const index = getNthOfTypeIndex(elem);
36
35
  try {
37
36
  while (elem?.tagName) {
38
- const {
39
- id,
40
- localName
41
- } = elem;
37
+ const tagName = elem.tagName.toLowerCase();
38
+ result.hasLink ||= tagName === 'a';
39
+ result.hasButton ||= tagName === 'button' || tagName === 'input' && elem.type.toLowerCase() === 'button';
42
40
  targetFields.forEach(field => {
43
- nearestFields[nearestAttrName(field)] ||= elem[field]?.baseVal || elem[field];
41
+ result.nearestFields[nearestAttrName(field)] ||= elem[field]?.baseVal || elem[field];
44
42
  });
45
- const selector = [localName, id ? "#".concat(id) : '', pathSelector ? ">".concat(pathSelector) : ''].join('');
46
- pathSelector = selector;
43
+ pathSelector = buildPathSelector(elem, pathSelector);
47
44
  elem = elem.parentNode;
48
45
  }
49
46
  } catch (err) {
50
47
  // do nothing for now
51
48
  }
52
- const path = pathSelector ? index ? "".concat(pathSelector, ":nth-of-type(").concat(index, ")") : pathSelector : undefined;
53
- return {
54
- path,
55
- nearestFields
56
- };
57
- function nearestAttrName(originalFieldName) {
58
- /** preserve original renaming structure for pre-existing field maps */
59
- if (originalFieldName === 'tagName') originalFieldName = 'tag';
60
- if (originalFieldName === 'className') originalFieldName = 'class';
61
- return "nearest".concat(originalFieldName.charAt(0).toUpperCase() + originalFieldName.slice(1));
49
+ result.path = pathSelector ? index ? "".concat(pathSelector, ":nth-of-type(").concat(index, ")") : pathSelector : undefined;
50
+ return result;
51
+ };
52
+ function buildPathSelector(elem, pathSelector) {
53
+ const {
54
+ id,
55
+ localName
56
+ } = elem;
57
+ return [localName, id ? "#".concat(id) : '', pathSelector ? ">".concat(pathSelector) : ''].join('');
58
+ }
59
+ function getNthOfTypeIndex(node) {
60
+ try {
61
+ let i = 1;
62
+ const {
63
+ tagName
64
+ } = node;
65
+ while (node.previousElementSibling) {
66
+ if (node.previousElementSibling.tagName === tagName) i++;
67
+ node = node.previousElementSibling;
68
+ }
69
+ return i;
70
+ } catch (err) {
71
+ // do nothing for now. An invalid child count will make the path selector not return a nth-of-type selector statement
62
72
  }
63
- };
73
+ }
74
+ function nearestAttrName(originalFieldName) {
75
+ /** preserve original renaming structure for pre-existing field maps */
76
+ if (originalFieldName === 'tagName') originalFieldName = 'tag';
77
+ if (originalFieldName === 'className') originalFieldName = 'class';
78
+ return "nearest".concat(originalFieldName.charAt(0).toUpperCase() + originalFieldName.slice(1));
79
+ }
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Copyright 2020-2025 New Relic, Inc. All rights reserved.
3
+ * SPDX-License-Identifier: Apache-2.0
4
+ */
5
+ import { globalScope } from '../constants/runtime';
6
+ import { gosNREUMOriginals } from '../window/nreum';
7
+
8
+ /**
9
+ * Extracts a URL from various target types.
10
+ * @param {string|Request|URL} target - The target to extract the URL from. It can be a string, a Fetch Request object, or a URL object.
11
+ * @returns {string|undefined} The extracted URL as a string, or undefined if the target type is not supported.
12
+ */
13
+ export function extractUrl(target) {
14
+ if (typeof target === 'string') return target;else if (target instanceof gosNREUMOriginals().o.REQ) return target.url;else if (globalScope?.URL && target instanceof URL) return target.href;
15
+ }
@@ -19,6 +19,7 @@ import { FEATURE_NAMES } from '../../../loaders/features/features';
19
19
  import { SUPPORTABILITY_METRIC } from '../../metrics/constants';
20
20
  import { now } from '../../../common/timing/now';
21
21
  import { hasUndefinedHostname } from '../../../common/deny-list/deny-list';
22
+ import { extractUrl } from '../../../common/url/extract-url';
22
23
  var handlers = ['load', 'error', 'abort', 'timeout'];
23
24
  var handlersLen = handlers.length;
24
25
  var origRequest = gosNREUMOriginals().o.REQ;
@@ -290,15 +291,7 @@ function subscribeToEvents(agentRef, ee, handler, dt) {
290
291
  if (fetchArguments.length >= 2) this.opts = fetchArguments[1];
291
292
  var opts = this.opts || {};
292
293
  var target = this.target;
293
- var url;
294
- if (typeof target === 'string') {
295
- url = target;
296
- } else if (typeof target === 'object' && target instanceof origRequest) {
297
- url = target.url;
298
- } else if (globalScope?.URL && typeof target === 'object' && target instanceof URL) {
299
- url = target.href;
300
- }
301
- addUrl(this, url);
294
+ addUrl(this, extractUrl(target));
302
295
  var method = ('' + (target && target instanceof origRequest && target.method || opts.method || 'GET')).toUpperCase();
303
296
  this.params.method = method;
304
297
  this.body = opts.body;
@@ -16,6 +16,7 @@ import { isIFrameWindow } from '../../../common/dom/iframe';
16
16
  import { isPureObject } from '../../../common/util/type-check';
17
17
  export class Aggregate extends AggregateBase {
18
18
  static featureName = FEATURE_NAME;
19
+ #userActionAggregator;
19
20
  constructor(agentRef) {
20
21
  super(agentRef, FEATURE_NAME);
21
22
  this.referrerUrl = isBrowserScope && document.referrer ? cleanURL(document.referrer) : undefined;
@@ -25,7 +26,7 @@ export class Aggregate extends AggregateBase {
25
26
  this.deregisterDrain();
26
27
  return;
27
28
  }
28
- this.trackSupportabilityMetrics();
29
+ this.#trackSupportabilityMetrics();
29
30
  registerHandler('api-recordCustomEvent', (timestamp, eventType, attributes) => {
30
31
  if (RESERVED_EVENT_TYPES.includes(eventType)) return warn(46);
31
32
  this.addEvent({
@@ -53,8 +54,8 @@ export class Aggregate extends AggregateBase {
53
54
  }
54
55
  let addUserAction = () => {/** no-op */};
55
56
  if (isBrowserScope && agentRef.init.user_actions.enabled) {
56
- this.userActionAggregator = new UserActionsAggregator();
57
- this.harvestOpts.beforeUnload = () => addUserAction?.(this.userActionAggregator.aggregationEvent);
57
+ this.#userActionAggregator = new UserActionsAggregator(agentRef.init.feature_flags.includes('user_frustrations'));
58
+ this.harvestOpts.beforeUnload = () => addUserAction?.(this.#userActionAggregator.aggregationEvent);
58
59
  addUserAction = aggregatedUserAction => {
59
60
  try {
60
61
  /** The aggregator process only returns an event when it is "done" aggregating -
@@ -65,7 +66,7 @@ export class Aggregate extends AggregateBase {
65
66
  timeStamp,
66
67
  type
67
68
  } = aggregatedUserAction.event;
68
- this.addEvent({
69
+ const userActionEvent = {
69
70
  eventType: 'UserAction',
70
71
  timestamp: this.toEpoch(timeStamp),
71
72
  action: type,
@@ -83,8 +84,16 @@ export class Aggregate extends AggregateBase {
83
84
  if (canTrustTargetAttribute(field)) acc[targetAttrName(field)] = String(target[field]).trim().slice(0, 128);
84
85
  return acc;
85
86
  }, {}),
86
- ...aggregatedUserAction.nearestTargetFields
87
- });
87
+ ...aggregatedUserAction.nearestTargetFields,
88
+ ...(aggregatedUserAction.deadClick && {
89
+ deadClick: true
90
+ }),
91
+ ...(aggregatedUserAction.errorClick && {
92
+ errorClick: true
93
+ })
94
+ };
95
+ this.addEvent(userActionEvent);
96
+ this.#trackUserActionSM(userActionEvent);
88
97
 
89
98
  /**
90
99
  * Returns the original target field name with `target` prepended and camelCased
@@ -114,8 +123,15 @@ export class Aggregate extends AggregateBase {
114
123
  };
115
124
  registerHandler('ua', evt => {
116
125
  /** the processor will return the previously aggregated event if it has been completed by processing the current event */
117
- addUserAction(this.userActionAggregator.process(evt, this.agentRef.init.user_actions.elementAttributes));
126
+ addUserAction(this.#userActionAggregator.process(evt, this.agentRef.init.user_actions.elementAttributes));
127
+ }, this.featureName, this.ee);
128
+ registerHandler('navChange', () => {
129
+ this.#userActionAggregator.isLiveClick();
118
130
  }, this.featureName, this.ee);
131
+ registerHandler('uaXhr', () => {
132
+ this.#userActionAggregator.isLiveClick();
133
+ }, this.featureName, this.ee);
134
+ registerHandler('uaErr', () => this.#userActionAggregator.markAsErrorClick(), this.featureName, this.ee);
119
135
  }
120
136
 
121
137
  /**
@@ -291,7 +307,7 @@ export class Aggregate extends AggregateBase {
291
307
  toEpoch(timestamp) {
292
308
  return Math.floor(this.agentRef.runtime.timeKeeper.correctRelativeTimestamp(timestamp));
293
309
  }
294
- trackSupportabilityMetrics() {
310
+ #trackSupportabilityMetrics() {
295
311
  /** track usage SMs to improve these experimental features */
296
312
  const configPerfTag = 'Config/Performance/';
297
313
  if (this.agentRef.init.performance.capture_marks) this.reportSupportabilityMetric(configPerfTag + 'CaptureMarks/Enabled');
@@ -301,4 +317,9 @@ export class Aggregate extends AggregateBase {
301
317
  if (this.agentRef.init.performance.resources.first_party_domains?.length !== 0) this.reportSupportabilityMetric(configPerfTag + 'Resources/FirstPartyDomains/Changed');
302
318
  if (this.agentRef.init.performance.resources.ignore_newrelic === false) this.reportSupportabilityMetric(configPerfTag + 'Resources/IgnoreNewrelic/Changed');
303
319
  }
320
+ #trackUserActionSM(ua) {
321
+ if (ua.rageClick) this.reportSupportabilityMetric('UserAction/RageClick/Seen');
322
+ if (ua.deadClick) this.reportSupportabilityMetric('UserAction/DeadClick/Seen');
323
+ if (ua.errorClick) this.reportSupportabilityMetric('UserAction/ErrorClick/Seen');
324
+ }
304
325
  }
@@ -5,15 +5,17 @@
5
5
  import { RAGE_CLICK_THRESHOLD_EVENTS, RAGE_CLICK_THRESHOLD_MS } from '../../constants';
6
6
  import { cleanURL } from '../../../../common/url/clean-url';
7
7
  export class AggregatedUserAction {
8
- constructor(evt, selectorPath, nearestTargetFields) {
8
+ constructor(evt, selectorInfo) {
9
9
  this.event = evt;
10
10
  this.count = 1;
11
11
  this.originMs = Math.floor(evt.timeStamp);
12
12
  this.relativeMs = [0];
13
- this.selectorPath = selectorPath;
13
+ this.selectorPath = selectorInfo.path;
14
14
  this.rageClick = undefined;
15
- this.nearestTargetFields = nearestTargetFields;
15
+ this.nearestTargetFields = selectorInfo.nearestFields;
16
16
  this.currentUrl = cleanURL('' + location);
17
+ this.deadClick = false;
18
+ this.errorClick = false;
17
19
  }
18
20
 
19
21
  /**
@@ -2,13 +2,25 @@
2
2
  * Copyright 2020-2025 New Relic, Inc. All rights reserved.
3
3
  * SPDX-License-Identifier: Apache-2.0
4
4
  */
5
- import { generateSelectorPath } from '../../../../common/dom/selector-path';
6
- import { OBSERVED_WINDOW_EVENTS } from '../../constants';
5
+ import { analyzeElemPath } from '../../../../common/dom/selector-path';
6
+ import { FRUSTRATION_TIMEOUT_MS, OBSERVED_WINDOW_EVENTS } from '../../constants';
7
7
  import { AggregatedUserAction } from './aggregated-user-action';
8
+ import { Timer } from '../../../../common/timer/timer';
9
+ import { gosNREUMOriginals } from '../../../../common/window/nreum';
8
10
  export class UserActionsAggregator {
9
11
  /** @type {AggregatedUserAction=} */
10
12
  #aggregationEvent = undefined;
11
13
  #aggregationKey = '';
14
+ #ufEnabled = false;
15
+ #deadClickTimer = undefined;
16
+ #domObserver = undefined;
17
+ #errorClickTimer = undefined;
18
+ constructor(userFrustrationsEnabled) {
19
+ if (userFrustrationsEnabled && gosNREUMOriginals().o.MO) {
20
+ this.#domObserver = new MutationObserver(this.isLiveClick.bind(this));
21
+ this.#ufEnabled = true;
22
+ }
23
+ }
12
24
  get aggregationEvent() {
13
25
  // if this is accessed externally, we need to be done aggregating on it
14
26
  // to prevent potential mutability and duplication issues, so the state is cleared upon returning.
@@ -26,49 +38,75 @@ export class UserActionsAggregator {
26
38
  */
27
39
  process(evt, targetFields) {
28
40
  if (!evt) return;
29
- const {
30
- selectorPath,
31
- nearestTargetFields
32
- } = getSelectorPath(evt, targetFields);
33
- const aggregationKey = getAggregationKey(evt, selectorPath);
41
+ const targetElem = OBSERVED_WINDOW_EVENTS.includes(evt.type) ? window : evt.target;
42
+ const selectorInfo = analyzeElemPath(targetElem, targetFields);
43
+
44
+ // if selectorInfo.path is undefined, aggregation will be skipped for this event
45
+ const aggregationKey = getAggregationKey(evt, selectorInfo.path);
34
46
  if (!!aggregationKey && aggregationKey === this.#aggregationKey) {
35
47
  // an aggregation exists already, so lets just continue to increment
36
48
  this.#aggregationEvent.aggregate(evt);
37
49
  } else {
38
50
  // return the prev existing one (if there is one)
39
51
  const finishedEvent = this.#aggregationEvent;
40
- // then set as this new event aggregation
52
+ if (this.#ufEnabled) {
53
+ this.#deadClickCleanup();
54
+ this.#errorClickCleanup();
55
+ }
56
+
57
+ // then start new event aggregation
41
58
  this.#aggregationKey = aggregationKey;
42
- this.#aggregationEvent = new AggregatedUserAction(evt, selectorPath, nearestTargetFields);
59
+ this.#aggregationEvent = new AggregatedUserAction(evt, selectorInfo);
60
+ if (this.#ufEnabled && evt.type === 'click' && (selectorInfo.hasButton || selectorInfo.hasLink)) {
61
+ this.#deadClickSetup(this.#aggregationEvent);
62
+ this.#errorClickSetup();
63
+ }
43
64
  return finishedEvent;
44
65
  }
45
66
  }
46
- }
47
-
48
- /**
49
- * Generates a selector path for the event, starting with simple cases like window or document and getting more complex for dom-tree traversals as needed.
50
- * Will return a random selector path value if no other path can be determined, to force the aggregator to skip aggregation for this event.
51
- * @param {Event} evt
52
- * @returns {string}
53
- */
54
- function getSelectorPath(evt, targetFields) {
55
- let selectorPath;
56
- let nearestTargetFields = {};
57
- if (OBSERVED_WINDOW_EVENTS.includes(evt.type) || evt.target === window) selectorPath = 'window';else if (evt.target === document) selectorPath = 'document';
58
- // if still no selectorPath, generate one from target tree that includes elem ids
59
- else {
60
- const {
61
- path,
62
- nearestFields
63
- } = generateSelectorPath(evt.target, targetFields);
64
- selectorPath = path;
65
- nearestTargetFields = nearestFields;
67
+ markAsErrorClick() {
68
+ if (this.#aggregationEvent && this.#errorClickTimer) {
69
+ this.#aggregationEvent.errorClick = true;
70
+ this.#errorClickCleanup();
71
+ }
72
+ }
73
+ #errorClickSetup() {
74
+ this.#errorClickTimer = new Timer({
75
+ onEnd: () => {
76
+ this.#errorClickCleanup();
77
+ }
78
+ }, FRUSTRATION_TIMEOUT_MS);
79
+ }
80
+ #errorClickCleanup() {
81
+ this.#errorClickTimer?.clear();
82
+ this.#errorClickTimer = undefined;
83
+ }
84
+ #deadClickSetup(userAction) {
85
+ if (this.#isEvaluatingDeadClick() || !this.#domObserver) return;
86
+ this.#domObserver.observe(document, {
87
+ attributes: true,
88
+ characterData: true,
89
+ childList: true,
90
+ subtree: true
91
+ });
92
+ this.#deadClickTimer = new Timer({
93
+ onEnd: () => {
94
+ userAction.deadClick = true;
95
+ this.#deadClickCleanup();
96
+ }
97
+ }, FRUSTRATION_TIMEOUT_MS);
98
+ }
99
+ #deadClickCleanup() {
100
+ this.#domObserver?.disconnect();
101
+ this.#deadClickTimer?.clear();
102
+ this.#deadClickTimer = undefined;
103
+ }
104
+ #isEvaluatingDeadClick() {
105
+ return this.#deadClickTimer !== undefined;
106
+ }
107
+ isLiveClick() {
108
+ if (this.#isEvaluatingDeadClick()) this.#deadClickCleanup();
66
109
  }
67
- // if STILL no selectorPath, it will return undefined which will skip aggregation for this event
68
- return {
69
- selectorPath,
70
- nearestTargetFields
71
- };
72
110
  }
73
111
 
74
112
  /**
@@ -8,6 +8,7 @@ export const OBSERVED_EVENTS = ['auxclick', 'click', 'copy', 'keydown', 'paste',
8
8
  export const OBSERVED_WINDOW_EVENTS = ['focus', 'blur'];
9
9
  export const RAGE_CLICK_THRESHOLD_EVENTS = 4;
10
10
  export const RAGE_CLICK_THRESHOLD_MS = 1000;
11
+ export const FRUSTRATION_TIMEOUT_MS = 2000;
11
12
  export const RESERVED_EVENT_TYPES = ['PageAction', 'UserAction', 'BrowserPerformance'];
12
13
  export const FEATURE_FLAGS = {
13
14
  MARKS: 'experimental.marks',
@@ -5,7 +5,7 @@
5
5
 
6
6
  import { globalScope, isBrowserScope } from '../../../common/constants/runtime';
7
7
  import { handle } from '../../../common/event-emitter/handle';
8
- import { windowAddEventListener } from '../../../common/event-listener/event-listener-opts';
8
+ import { eventListenerOpts, windowAddEventListener } from '../../../common/event-listener/event-listener-opts';
9
9
  import { debounce } from '../../../common/util/invoke';
10
10
  import { setupAddPageActionAPI } from '../../../loaders/api/addPageAction';
11
11
  import { setupFinishedAPI } from '../../../loaders/api/finished';
@@ -14,6 +14,12 @@ import { setupRegisterAPI } from '../../../loaders/api/register';
14
14
  import { setupMeasureAPI } from '../../../loaders/api/measure';
15
15
  import { InstrumentBase } from '../../utils/instrument-base';
16
16
  import { FEATURE_NAME, OBSERVED_EVENTS, OBSERVED_WINDOW_EVENTS } from '../constants';
17
+ import { FEATURE_NAMES } from '../../../loaders/features/features';
18
+ import { wrapHistory } from '../../../common/wrap/wrap-history';
19
+ import { wrapFetch } from '../../../common/wrap/wrap-fetch';
20
+ import { wrapXhr } from '../../../common/wrap/wrap-xhr';
21
+ import { parseUrl } from '../../../common/url/parse-url';
22
+ import { extractUrl } from '../../../common/url/extract-url';
17
23
  export class Instrument extends InstrumentBase {
18
24
  static featureName = FEATURE_NAME;
19
25
  constructor(agentRef) {
@@ -52,6 +58,45 @@ export class Instrument extends InstrumentBase {
52
58
  buffered: true
53
59
  });
54
60
  }
61
+ const historyEE = wrapHistory(this.ee);
62
+ historyEE.on('pushState-end', navigationChange);
63
+ historyEE.on('replaceState-end', navigationChange);
64
+ window.addEventListener('hashchange', navigationChange, eventListenerOpts(true, this.removeOnAbort?.signal));
65
+ window.addEventListener('popstate', navigationChange, eventListenerOpts(true, this.removeOnAbort?.signal));
66
+ function navigationChange() {
67
+ historyEE.emit('navChange');
68
+ }
69
+ }
70
+ try {
71
+ this.removeOnAbort = new AbortController();
72
+ } catch (e) {}
73
+ this.abortHandler = () => {
74
+ this.removeOnAbort?.abort();
75
+ this.abortHandler = undefined; // weakly allow this abort op to run only once
76
+ };
77
+ globalScope.addEventListener('error', () => {
78
+ handle('uaErr', [], undefined, FEATURE_NAMES.genericEvents, this.ee);
79
+ }, eventListenerOpts(false, this.removeOnAbort?.signal));
80
+ wrapFetch(this.ee);
81
+ wrapXhr(this.ee);
82
+ this.ee.on('open-xhr-start', (args, xhr) => {
83
+ if (!isInternalTraffic(args[1])) {
84
+ xhr.addEventListener('readystatechange', () => {
85
+ if (xhr.readyState === 2) {
86
+ // HEADERS_RECEIVED
87
+ handle('uaXhr', [], undefined, FEATURE_NAMES.genericEvents, this.ee);
88
+ }
89
+ });
90
+ }
91
+ });
92
+ this.ee.on('fetch-start', fetchArguments => {
93
+ if (fetchArguments.length >= 1 && !isInternalTraffic(extractUrl(fetchArguments[0]))) {
94
+ handle('uaXhr', [], undefined, FEATURE_NAMES.genericEvents, this.ee);
95
+ }
96
+ });
97
+ function isInternalTraffic(url) {
98
+ const parsedUrl = parseUrl(url);
99
+ return agentRef.beacons.includes(parsedUrl.hostname + ':' + parsedUrl.port);
55
100
  }
56
101
 
57
102
  /** If any of the sources are active, import the aggregator. otherwise deregister */
@@ -13,4 +13,5 @@ export function setupNoticeErrorAPI(agent) {
13
13
  export function noticeError(err, customAttributes, agentRef, targetEntityGuid, timestamp = now()) {
14
14
  if (typeof err === 'string') err = new Error(err);
15
15
  handle('err', [err, timestamp, false, customAttributes, agentRef.runtime.isRecording, undefined, targetEntityGuid], undefined, FEATURE_NAMES.jserrors, agentRef.ee);
16
+ handle('uaErr', [], undefined, FEATURE_NAMES.genericEvents, agentRef.ee);
16
17
  }
@@ -52,6 +52,7 @@ export function configure(agent, opts = {}, loaderType, forceDrain) {
52
52
  internalTrafficList.push(updatedInit.proxy.assets);
53
53
  }
54
54
  if (updatedInit.proxy.beacon) internalTrafficList.push(updatedInit.proxy.beacon);
55
+ agent.beacons = [...internalTrafficList];
55
56
  setTopLevelCallers(agent); // no need to set global APIs on newrelic obj more than once
56
57
  addToNREUM('activatedFeatures', activatedFeatures);
57
58
 
@@ -1 +1 @@
1
- {"root":["../src/index.js","../src/cdn/experimental.js","../src/cdn/lite.js","../src/cdn/pro.js","../src/cdn/spa.js","../src/common/aggregate/aggregator.js","../src/common/aggregate/event-aggregator.js","../src/common/config/configurable.js","../src/common/config/info.js","../src/common/config/init-types.js","../src/common/config/init.js","../src/common/config/loader-config.js","../src/common/config/runtime.js","../src/common/constants/agent-constants.js","../src/common/constants/env.cdn.js","../src/common/constants/env.js","../src/common/constants/env.npm.js","../src/common/constants/runtime.js","../src/common/constants/shared-channel.js","../src/common/deny-list/deny-list.js","../src/common/dispatch/global-event.js","../src/common/dom/iframe.js","../src/common/dom/query-selector.js","../src/common/dom/selector-path.js","../src/common/drain/drain.js","../src/common/event-emitter/contextual-ee.js","../src/common/event-emitter/event-context.js","../src/common/event-emitter/handle.js","../src/common/event-emitter/register-handler.js","../src/common/event-listener/event-listener-opts.js","../src/common/harvest/harvester.js","../src/common/harvest/types.js","../src/common/ids/bundle-id.js","../src/common/ids/id.js","../src/common/ids/unique-id.js","../src/common/serialize/bel-serializer.js","../src/common/session/constants.js","../src/common/session/session-entity.js","../src/common/storage/local-storage.js","../src/common/timer/interaction-timer.js","../src/common/timer/timer.js","../src/common/timing/nav-timing.js","../src/common/timing/now.js","../src/common/timing/time-keeper.js","../src/common/unload/eol.js","../src/common/url/canonicalize-url.js","../src/common/url/clean-url.js","../src/common/url/encode.js","../src/common/url/location.js","../src/common/url/parse-url.js","../src/common/url/protocol.js","../src/common/util/attribute-size.js","../src/common/util/console.js","../src/common/util/data-size.js","../src/common/util/event-origin.js","../src/common/util/feature-flags.js","../src/common/util/get-or-set.js","../src/common/util/invoke.js","../src/common/util/monkey-patched.js","../src/common/util/obfuscate.js","../src/common/util/stringify.js","../src/common/util/submit-data.js","../src/common/util/target.js","../src/common/util/text.js","../src/common/util/traverse.js","../src/common/util/type-check.js","../src/common/vitals/constants.js","../src/common/vitals/cumulative-layout-shift.js","../src/common/vitals/first-contentful-paint.js","../src/common/vitals/first-paint.js","../src/common/vitals/interaction-to-next-paint.js","../src/common/vitals/largest-contentful-paint.js","../src/common/vitals/time-to-first-byte.js","../src/common/vitals/vital-metric.js","../src/common/window/load.js","../src/common/window/nreum.js","../src/common/window/page-visibility.js","../src/common/wrap/wrap-events.js","../src/common/wrap/wrap-fetch.js","../src/common/wrap/wrap-function.js","../src/common/wrap/wrap-history.js","../src/common/wrap/wrap-jsonp.js","../src/common/wrap/wrap-logger.js","../src/common/wrap/wrap-mutation.js","../src/common/wrap/wrap-promise.js","../src/common/wrap/wrap-timer.js","../src/common/wrap/wrap-websocket.js","../src/common/wrap/wrap-xhr.js","../src/features/ajax/constants.js","../src/features/ajax/index.js","../src/features/ajax/aggregate/gql.js","../src/features/ajax/aggregate/index.js","../src/features/ajax/instrument/distributed-tracing.js","../src/features/ajax/instrument/index.js","../src/features/ajax/instrument/response-size.js","../src/features/generic_events/constants.js","../src/features/generic_events/index.js","../src/features/generic_events/aggregate/index.js","../src/features/generic_events/aggregate/user-actions/aggregated-user-action.js","../src/features/generic_events/aggregate/user-actions/user-actions-aggregator.js","../src/features/generic_events/instrument/index.js","../src/features/jserrors/constants.js","../src/features/jserrors/index.js","../src/features/jserrors/aggregate/canonical-function-name.js","../src/features/jserrors/aggregate/cause-string.js","../src/features/jserrors/aggregate/compute-stack-trace.js","../src/features/jserrors/aggregate/format-stack-trace.js","../src/features/jserrors/aggregate/index.js","../src/features/jserrors/aggregate/internal-errors.js","../src/features/jserrors/aggregate/string-hash-code.js","../src/features/jserrors/instrument/index.js","../src/features/jserrors/shared/cast-error.js","../src/features/jserrors/shared/uncaught-error.js","../src/features/logging/constants.js","../src/features/logging/index.js","../src/features/logging/aggregate/index.js","../src/features/logging/instrument/index.js","../src/features/logging/shared/log.js","../src/features/logging/shared/utils.js","../src/features/metrics/constants.js","../src/features/metrics/index.js","../src/features/metrics/aggregate/framework-detection.js","../src/features/metrics/aggregate/harvest-metadata.js","../src/features/metrics/aggregate/index.js","../src/features/metrics/aggregate/websocket-detection.js","../src/features/metrics/instrument/index.js","../src/features/page_action/constants.js","../src/features/page_action/index.js","../src/features/page_action/instrument/index.js","../src/features/page_view_event/constants.js","../src/features/page_view_event/index.js","../src/features/page_view_event/aggregate/index.js","../src/features/page_view_event/aggregate/initialized-features.js","../src/features/page_view_event/instrument/index.js","../src/features/page_view_timing/constants.js","../src/features/page_view_timing/index.js","../src/features/page_view_timing/aggregate/index.js","../src/features/page_view_timing/instrument/index.js","../src/features/session_replay/constants.js","../src/features/session_replay/index.js","../src/features/session_replay/aggregate/index.js","../src/features/session_replay/instrument/index.js","../src/features/session_replay/shared/recorder-events.js","../src/features/session_replay/shared/recorder.js","../src/features/session_replay/shared/stylesheet-evaluator.js","../src/features/session_replay/shared/utils.js","../src/features/session_trace/constants.js","../src/features/session_trace/index.js","../src/features/session_trace/aggregate/index.js","../src/features/session_trace/aggregate/trace/node.js","../src/features/session_trace/aggregate/trace/storage.js","../src/features/session_trace/aggregate/trace/utils.js","../src/features/session_trace/instrument/index.js","../src/features/soft_navigations/constants.js","../src/features/soft_navigations/index.js","../src/features/soft_navigations/aggregate/ajax-node.js","../src/features/soft_navigations/aggregate/bel-node.js","../src/features/soft_navigations/aggregate/index.js","../src/features/soft_navigations/aggregate/initial-page-load-interaction.js","../src/features/soft_navigations/aggregate/interaction.js","../src/features/soft_navigations/instrument/index.js","../src/features/spa/constants.js","../src/features/spa/index.js","../src/features/spa/aggregate/index.js","../src/features/spa/aggregate/interaction-node.js","../src/features/spa/aggregate/interaction.js","../src/features/spa/aggregate/serializer.js","../src/features/spa/instrument/index.js","../src/features/utils/agent-session.js","../src/features/utils/aggregate-base.js","../src/features/utils/entity-manager.js","../src/features/utils/event-buffer.js","../src/features/utils/event-store-manager.js","../src/features/utils/feature-base.js","../src/features/utils/feature-gates.js","../src/features/utils/instrument-base.js","../src/features/utils/nr1-debugger.js","../src/interfaces/registered-entity.js","../src/loaders/agent-base.js","../src/loaders/agent.js","../src/loaders/api-base.js","../src/loaders/browser-agent.js","../src/loaders/micro-agent-base.js","../src/loaders/micro-agent.js","../src/loaders/api/addPageAction.js","../src/loaders/api/addRelease.js","../src/loaders/api/addToTrace.js","../src/loaders/api/constants.js","../src/loaders/api/finished.js","../src/loaders/api/interaction-types.js","../src/loaders/api/interaction.js","../src/loaders/api/log.js","../src/loaders/api/measure.js","../src/loaders/api/noticeError.js","../src/loaders/api/pauseReplay.js","../src/loaders/api/recordCustomEvent.js","../src/loaders/api/recordReplay.js","../src/loaders/api/register-api-types.js","../src/loaders/api/register-api.js","../src/loaders/api/register.js","../src/loaders/api/setApplicationVersion.js","../src/loaders/api/setCustomAttribute.js","../src/loaders/api/setErrorHandler.js","../src/loaders/api/setPageViewName.js","../src/loaders/api/setUserId.js","../src/loaders/api/sharedHandlers.js","../src/loaders/api/start.js","../src/loaders/api/topLevelCallers.js","../src/loaders/api/wrapLogger.js","../src/loaders/configure/configure.js","../src/loaders/configure/nonce.js","../src/loaders/configure/public-path.js","../src/loaders/features/enabled-features.js","../src/loaders/features/featureDependencies.js","../src/loaders/features/features.js"],"version":"5.7.3"}
1
+ {"root":["../src/index.js","../src/cdn/experimental.js","../src/cdn/lite.js","../src/cdn/pro.js","../src/cdn/spa.js","../src/common/aggregate/aggregator.js","../src/common/aggregate/event-aggregator.js","../src/common/config/configurable.js","../src/common/config/info.js","../src/common/config/init-types.js","../src/common/config/init.js","../src/common/config/loader-config.js","../src/common/config/runtime.js","../src/common/constants/agent-constants.js","../src/common/constants/env.cdn.js","../src/common/constants/env.js","../src/common/constants/env.npm.js","../src/common/constants/runtime.js","../src/common/constants/shared-channel.js","../src/common/deny-list/deny-list.js","../src/common/dispatch/global-event.js","../src/common/dom/iframe.js","../src/common/dom/query-selector.js","../src/common/dom/selector-path.js","../src/common/drain/drain.js","../src/common/event-emitter/contextual-ee.js","../src/common/event-emitter/event-context.js","../src/common/event-emitter/handle.js","../src/common/event-emitter/register-handler.js","../src/common/event-listener/event-listener-opts.js","../src/common/harvest/harvester.js","../src/common/harvest/types.js","../src/common/ids/bundle-id.js","../src/common/ids/id.js","../src/common/ids/unique-id.js","../src/common/serialize/bel-serializer.js","../src/common/session/constants.js","../src/common/session/session-entity.js","../src/common/storage/local-storage.js","../src/common/timer/interaction-timer.js","../src/common/timer/timer.js","../src/common/timing/nav-timing.js","../src/common/timing/now.js","../src/common/timing/time-keeper.js","../src/common/unload/eol.js","../src/common/url/canonicalize-url.js","../src/common/url/clean-url.js","../src/common/url/encode.js","../src/common/url/extract-url.js","../src/common/url/location.js","../src/common/url/parse-url.js","../src/common/url/protocol.js","../src/common/util/attribute-size.js","../src/common/util/console.js","../src/common/util/data-size.js","../src/common/util/event-origin.js","../src/common/util/feature-flags.js","../src/common/util/get-or-set.js","../src/common/util/invoke.js","../src/common/util/monkey-patched.js","../src/common/util/obfuscate.js","../src/common/util/stringify.js","../src/common/util/submit-data.js","../src/common/util/target.js","../src/common/util/text.js","../src/common/util/traverse.js","../src/common/util/type-check.js","../src/common/vitals/constants.js","../src/common/vitals/cumulative-layout-shift.js","../src/common/vitals/first-contentful-paint.js","../src/common/vitals/first-paint.js","../src/common/vitals/interaction-to-next-paint.js","../src/common/vitals/largest-contentful-paint.js","../src/common/vitals/time-to-first-byte.js","../src/common/vitals/vital-metric.js","../src/common/window/load.js","../src/common/window/nreum.js","../src/common/window/page-visibility.js","../src/common/wrap/wrap-events.js","../src/common/wrap/wrap-fetch.js","../src/common/wrap/wrap-function.js","../src/common/wrap/wrap-history.js","../src/common/wrap/wrap-jsonp.js","../src/common/wrap/wrap-logger.js","../src/common/wrap/wrap-mutation.js","../src/common/wrap/wrap-promise.js","../src/common/wrap/wrap-timer.js","../src/common/wrap/wrap-websocket.js","../src/common/wrap/wrap-xhr.js","../src/features/ajax/constants.js","../src/features/ajax/index.js","../src/features/ajax/aggregate/gql.js","../src/features/ajax/aggregate/index.js","../src/features/ajax/instrument/distributed-tracing.js","../src/features/ajax/instrument/index.js","../src/features/ajax/instrument/response-size.js","../src/features/generic_events/constants.js","../src/features/generic_events/index.js","../src/features/generic_events/aggregate/index.js","../src/features/generic_events/aggregate/user-actions/aggregated-user-action.js","../src/features/generic_events/aggregate/user-actions/user-actions-aggregator.js","../src/features/generic_events/instrument/index.js","../src/features/jserrors/constants.js","../src/features/jserrors/index.js","../src/features/jserrors/aggregate/canonical-function-name.js","../src/features/jserrors/aggregate/cause-string.js","../src/features/jserrors/aggregate/compute-stack-trace.js","../src/features/jserrors/aggregate/format-stack-trace.js","../src/features/jserrors/aggregate/index.js","../src/features/jserrors/aggregate/internal-errors.js","../src/features/jserrors/aggregate/string-hash-code.js","../src/features/jserrors/instrument/index.js","../src/features/jserrors/shared/cast-error.js","../src/features/jserrors/shared/uncaught-error.js","../src/features/logging/constants.js","../src/features/logging/index.js","../src/features/logging/aggregate/index.js","../src/features/logging/instrument/index.js","../src/features/logging/shared/log.js","../src/features/logging/shared/utils.js","../src/features/metrics/constants.js","../src/features/metrics/index.js","../src/features/metrics/aggregate/framework-detection.js","../src/features/metrics/aggregate/harvest-metadata.js","../src/features/metrics/aggregate/index.js","../src/features/metrics/aggregate/websocket-detection.js","../src/features/metrics/instrument/index.js","../src/features/page_action/constants.js","../src/features/page_action/index.js","../src/features/page_action/instrument/index.js","../src/features/page_view_event/constants.js","../src/features/page_view_event/index.js","../src/features/page_view_event/aggregate/index.js","../src/features/page_view_event/aggregate/initialized-features.js","../src/features/page_view_event/instrument/index.js","../src/features/page_view_timing/constants.js","../src/features/page_view_timing/index.js","../src/features/page_view_timing/aggregate/index.js","../src/features/page_view_timing/instrument/index.js","../src/features/session_replay/constants.js","../src/features/session_replay/index.js","../src/features/session_replay/aggregate/index.js","../src/features/session_replay/instrument/index.js","../src/features/session_replay/shared/recorder-events.js","../src/features/session_replay/shared/recorder.js","../src/features/session_replay/shared/stylesheet-evaluator.js","../src/features/session_replay/shared/utils.js","../src/features/session_trace/constants.js","../src/features/session_trace/index.js","../src/features/session_trace/aggregate/index.js","../src/features/session_trace/aggregate/trace/node.js","../src/features/session_trace/aggregate/trace/storage.js","../src/features/session_trace/aggregate/trace/utils.js","../src/features/session_trace/instrument/index.js","../src/features/soft_navigations/constants.js","../src/features/soft_navigations/index.js","../src/features/soft_navigations/aggregate/ajax-node.js","../src/features/soft_navigations/aggregate/bel-node.js","../src/features/soft_navigations/aggregate/index.js","../src/features/soft_navigations/aggregate/initial-page-load-interaction.js","../src/features/soft_navigations/aggregate/interaction.js","../src/features/soft_navigations/instrument/index.js","../src/features/spa/constants.js","../src/features/spa/index.js","../src/features/spa/aggregate/index.js","../src/features/spa/aggregate/interaction-node.js","../src/features/spa/aggregate/interaction.js","../src/features/spa/aggregate/serializer.js","../src/features/spa/instrument/index.js","../src/features/utils/agent-session.js","../src/features/utils/aggregate-base.js","../src/features/utils/entity-manager.js","../src/features/utils/event-buffer.js","../src/features/utils/event-store-manager.js","../src/features/utils/feature-base.js","../src/features/utils/feature-gates.js","../src/features/utils/instrument-base.js","../src/features/utils/nr1-debugger.js","../src/interfaces/registered-entity.js","../src/loaders/agent-base.js","../src/loaders/agent.js","../src/loaders/api-base.js","../src/loaders/browser-agent.js","../src/loaders/micro-agent-base.js","../src/loaders/micro-agent.js","../src/loaders/api/addPageAction.js","../src/loaders/api/addRelease.js","../src/loaders/api/addToTrace.js","../src/loaders/api/constants.js","../src/loaders/api/finished.js","../src/loaders/api/interaction-types.js","../src/loaders/api/interaction.js","../src/loaders/api/log.js","../src/loaders/api/measure.js","../src/loaders/api/noticeError.js","../src/loaders/api/pauseReplay.js","../src/loaders/api/recordCustomEvent.js","../src/loaders/api/recordReplay.js","../src/loaders/api/register-api-types.js","../src/loaders/api/register-api.js","../src/loaders/api/register.js","../src/loaders/api/setApplicationVersion.js","../src/loaders/api/setCustomAttribute.js","../src/loaders/api/setErrorHandler.js","../src/loaders/api/setPageViewName.js","../src/loaders/api/setUserId.js","../src/loaders/api/sharedHandlers.js","../src/loaders/api/start.js","../src/loaders/api/topLevelCallers.js","../src/loaders/api/wrapLogger.js","../src/loaders/configure/configure.js","../src/loaders/configure/nonce.js","../src/loaders/configure/public-path.js","../src/loaders/features/enabled-features.js","../src/loaders/features/featureDependencies.js","../src/loaders/features/features.js"],"version":"5.7.3"}
@@ -1,2 +1,7 @@
1
- export function generateSelectorPath(elem: HTMLElement, targetFields?: any[]): string | undefined;
1
+ export function analyzeElemPath(elem: HTMLElement, targetFields?: Array<string>): {
2
+ path: (undefined | string);
3
+ nearestFields: {};
4
+ hasButton: boolean;
5
+ hasLink: boolean;
6
+ };
2
7
  //# sourceMappingURL=selector-path.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"selector-path.d.ts","sourceRoot":"","sources":["../../../../src/common/dom/selector-path.js"],"names":[],"mappings":"AAYO,2CALI,WAAW,yBAGT,MAAM,GAAC,SAAS,CAiD5B"}
1
+ {"version":3,"file":"selector-path.d.ts","sourceRoot":"","sources":["../../../../src/common/dom/selector-path.js"],"names":[],"mappings":"AAgBO,sCAJI,WAAW,iBACX,KAAK,CAAC,MAAM,CAAC,GACX;IAAC,IAAI,EAAE,CAAC,SAAS,GAAC,MAAM,CAAC,CAAC;IAAC,aAAa,EAAE,EAAE,CAAC;IAAC,SAAS,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,OAAO,CAAA;CAAC,CA2B/F"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Extracts a URL from various target types.
3
+ * @param {string|Request|URL} target - The target to extract the URL from. It can be a string, a Fetch Request object, or a URL object.
4
+ * @returns {string|undefined} The extracted URL as a string, or undefined if the target type is not supported.
5
+ */
6
+ export function extractUrl(target: string | Request | URL): string | undefined;
7
+ //# sourceMappingURL=extract-url.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"extract-url.d.ts","sourceRoot":"","sources":["../../../../src/common/url/extract-url.js"],"names":[],"mappings":"AAOA;;;;GAIG;AACH,mCAHW,MAAM,GAAC,OAAO,GAAC,GAAG,GAChB,MAAM,GAAC,SAAS,CAM5B"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/ajax/instrument/index.js"],"names":[],"mappings":"AA6BA;IACE,2BAAiC;IACjC,2BAkCC;IA/BC,OAA0B;IAE1B,8DAAkF;CA8BrF;AAmWD,qCAA8B;+BAtZC,6BAA6B;mBAFzC,uBAAuB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/ajax/instrument/index.js"],"names":[],"mappings":"AA8BA;IACE,2BAAiC;IACjC,2BAkCC;IA/BC,OAA0B;IAE1B,8DAAkF;CA8BrF;AA0VD,qCAA8B;+BA9YC,6BAA6B;mBAFzC,uBAAuB"}
@@ -2,7 +2,6 @@ export class Aggregate extends AggregateBase {
2
2
  static featureName: string;
3
3
  constructor(agentRef: any);
4
4
  referrerUrl: string | undefined;
5
- userActionAggregator: UserActionsAggregator;
6
5
  /** Some keys are set by the query params or request headers sent with the harvest and override the body values, so check those before adding new standard body values...
7
6
  * see harvest.js#baseQueryString for more info on the query params
8
7
  * Notably:
@@ -23,8 +22,7 @@ export class Aggregate extends AggregateBase {
23
22
  at: any;
24
23
  };
25
24
  toEpoch(timestamp: any): number;
26
- trackSupportabilityMetrics(): void;
25
+ #private;
27
26
  }
28
27
  import { AggregateBase } from '../../utils/aggregate-base';
29
- import { UserActionsAggregator } from './user-actions/user-actions-aggregator';
30
28
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/generic_events/aggregate/index.js"],"names":[],"mappings":"AAiBA;IACE,2BAAiC;IACjC,2BA2NC;IAzNC,gCAAkG;IAwC9F,4CAAuD;IAoL7D;;;;;;;;;;;;OAYG;IACH,eAJW,MAAM,YAAC,qBACP,MAAM,YAAC,QAiCjB;IAED,qCAEC;IAED;;;MAEC;IAED,gCAEC;IAED,mCASC;CACF;8BA5S6B,4BAA4B;sCAKpB,wCAAwC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/features/generic_events/aggregate/index.js"],"names":[],"mappings":"AAiBA;IACE,2BAAiC;IAGjC,2BAkOC;IAhOC,gCAAkG;IAmOpG;;;;;;;;;;;;OAYG;IACH,eAJW,MAAM,YAAC,qBACP,MAAM,YAAC,QAiCjB;IAED,qCAEC;IAED;;;MAEC;IAED,gCAEC;;CAkBF;8BA3T6B,4BAA4B"}