@adobe/spacecat-shared-rum-api-client 2.23.3 → 2.23.4
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 +7 -0
- package/package.json +1 -1
- package/src/functions/form-vitals.js +14 -11
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [@adobe/spacecat-shared-rum-api-client-v2.23.4](https://github.com/adobe/spacecat-shared/compare/@adobe/spacecat-shared-rum-api-client-v2.23.3...@adobe/spacecat-shared-rum-api-client-v2.23.4) (2025-04-30)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* form source proper handling in form vitals ([#711](https://github.com/adobe/spacecat-shared/issues/711)) ([e37bf0a](https://github.com/adobe/spacecat-shared/commit/e37bf0a6df28952a0e51f8689c4016a9bbff82e0))
|
|
7
|
+
|
|
1
8
|
# [@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
9
|
|
|
3
10
|
|
package/package.json
CHANGED
|
@@ -89,7 +89,7 @@ function populateFormsInternalNavigation(bundles, formVitals) {
|
|
|
89
89
|
const fv = findByUrl(formVitals, formInternalNav.source);
|
|
90
90
|
formVital.forminternalnavigation.push({
|
|
91
91
|
url: formInternalNav.source,
|
|
92
|
-
pageview: fv
|
|
92
|
+
...(fv && { pageview: fv.pageview }),
|
|
93
93
|
});
|
|
94
94
|
}
|
|
95
95
|
});
|
|
@@ -176,16 +176,19 @@ function handler(bundles) {
|
|
|
176
176
|
// aggregates metrics per group (url and user agent)
|
|
177
177
|
dataChunks.facets.urlUserAgents.reduce((acc, { value, metrics, weight }) => {
|
|
178
178
|
const [url, userAgent] = value.split(DELIMITER);
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
179
|
+
if (formSourceMap[url].has(source)) {
|
|
180
|
+
const key = generateKey(url, source);
|
|
181
|
+
acc[key] = acc[key] || initializeResult(url);
|
|
182
|
+
acc[key].pageview[userAgent] = acc[key].pageview[userAgent] || weight;
|
|
183
|
+
// Enable traffic acquisition for persistence by uncommenting this line
|
|
184
|
+
// acc[key].trafficacquisition = trafficByUrlMap[url];
|
|
185
|
+
acc[key].formsource = source;
|
|
186
|
+
// filter out user-agents with no form vitals
|
|
187
|
+
METRICS.filter((metric) => metrics[metric].sum)
|
|
188
|
+
.forEach((metric) => {
|
|
189
|
+
acc[key][metric][userAgent] = metrics[metric].sum;
|
|
190
|
+
});
|
|
191
|
+
}
|
|
189
192
|
return acc;
|
|
190
193
|
}, formVitals);
|
|
191
194
|
});
|