@adobe/spacecat-shared-rum-api-client 2.23.1 → 2.23.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ # [@adobe/spacecat-shared-rum-api-client-v2.23.3](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-rum-api-client-v2.23.2...@adobe/spacecat-shared-rum-api-client-v2.23.3) (2025-04-26)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **deps:** update external fixes ([#708](https://github.com/adobe/spacecat-shared/issues/708)) ([57535ac](https://github.com/adobe/spacecat-shared/commit/57535ac8c636de229cec7c5cee83dead07ac09fb))
7
+
8
+ # [@adobe/spacecat-shared-rum-api-client-v2.23.2](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-rum-api-client-v2.23.1...@adobe/spacecat-shared-rum-api-client-v2.23.2) (2025-04-26)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * changing user agent categorization for forms ([#705](https://github.com/adobe/spacecat-shared/issues/705)) ([239a186](https://github.com/adobe/spacecat-shared/commit/239a18657607ba9fcc041c9b90342d173cc5b81c))
14
+
1
15
  # [@adobe/spacecat-shared-rum-api-client-v2.23.1](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-rum-api-client-v2.23.0...@adobe/spacecat-shared-rum-api-client-v2.23.1) (2025-04-25)
2
16
 
3
17
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adobe/spacecat-shared-rum-api-client",
3
- "version": "2.23.1",
3
+ "version": "2.23.3",
4
4
  "description": "Shared modules of the Spacecat Services - Rum API client",
5
5
  "type": "module",
6
6
  "engines": {
@@ -46,7 +46,7 @@
46
46
  "devDependencies": {
47
47
  "chai": "5.2.0",
48
48
  "chai-as-promised": "8.0.1",
49
- "nock": "14.0.3",
49
+ "nock": "14.0.4",
50
50
  "sinon": "20.0.0",
51
51
  "sinon-chai": "4.0.0",
52
52
  "typescript": "5.8.3"
@@ -166,7 +166,12 @@ function handler(bundles) {
166
166
  const match = source.match(/form[#.](\w+)/);
167
167
  const formsource = match ? match[1] : 'unknown';
168
168
  // groups by url and user agent
169
- dataChunks.addFacet('urlUserAgents', (bundle) => generateKey(bundle.url, bundle.userAgent));
169
+ dataChunks.addFacet('urlUserAgents', (bundle) => {
170
+ // eslint-disable-next-line no-nested-ternary
171
+ const deviceType = bundle.userAgent.startsWith('desktop') ? 'desktop' : bundle.userAgent.startsWith('mobile') ? 'mobile' : 'other';
172
+ return generateKey(bundle.url, deviceType);
173
+ });
174
+
170
175
  METRICS.forEach((metric) => dataChunks.addSeries(metric, metricFns[metric](formsource)));
171
176
  // aggregates metrics per group (url and user agent)
172
177
  dataChunks.facets.urlUserAgents.reduce((acc, { value, metrics, weight }) => {