bhl-forms 0.0.18 → 0.0.21
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/dist/bhl-forms.es.js +7 -4
- package/dist/bhl-forms.iife.js +3 -3
- package/dist/bhl-forms.umd.js +3 -3
- package/dist/forms/childAndFamily.es.js +17 -0
- package/dist/forms/childAndFamily.iife.js +1 -1
- package/dist/forms/childAndFamily.json +1 -1
- package/dist/main.css +1 -1
- package/package.json +1 -1
package/dist/bhl-forms.es.js
CHANGED
|
@@ -10698,14 +10698,17 @@ function prepData(formData) {
|
|
|
10698
10698
|
};
|
|
10699
10699
|
return data;
|
|
10700
10700
|
}
|
|
10701
|
+
const isMobile = window.matchMedia("only screen and (max-width: 480px)").matches;
|
|
10701
10702
|
const fireStepEvent = (formNode) => (stepResult, stepHistory2, stepQueue2) => {
|
|
10702
10703
|
if (!stepResult) {
|
|
10703
10704
|
return;
|
|
10704
10705
|
}
|
|
10705
|
-
|
|
10706
|
-
|
|
10707
|
-
|
|
10708
|
-
|
|
10706
|
+
const anchorId = formNode.attrs.anchorElement || formNode.id;
|
|
10707
|
+
if (anchorId && isMobile) {
|
|
10708
|
+
const anchor = document.getElementById(anchorId);
|
|
10709
|
+
if (anchor) {
|
|
10710
|
+
anchor.scrollIntoView(true);
|
|
10711
|
+
}
|
|
10709
10712
|
}
|
|
10710
10713
|
const form_id = formNode.attrs.formId || window.location.hostname + "-" + formNode.id;
|
|
10711
10714
|
if (typeof window._analytics !== "undefined") {
|