bhl-forms 0.0.45 → 0.0.46
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 +13 -3
- package/dist/bhl-forms.iife.js +6 -6
- package/dist/bhl-forms.modern.es.js +13 -3
- package/dist/bhl-forms.modern.iife.js +8 -8
- package/dist/bhl-forms.modern.umd.js +9 -9
- package/dist/bhl-forms.umd.js +6 -6
- package/dist/forms/childAndFamily.es.js +6 -5
- package/dist/forms/childAndFamily.iife.js +1 -1
- package/dist/forms/childAndFamily.json +1 -1
- package/dist/forms/generalLegal.es.js +6 -5
- package/dist/forms/generalLegal.iife.js +1 -1
- package/dist/forms/generalLegal.json +1 -1
- package/dist/forms/testForm.es.js +5 -4
- package/dist/forms/testForm.iife.js +1 -1
- package/dist/forms/testForm.json +1 -1
- package/dist/main.css +1 -1
- package/package.json +3 -2
package/dist/bhl-forms.es.js
CHANGED
|
@@ -11184,16 +11184,26 @@ function prepData(formData) {
|
|
|
11184
11184
|
};
|
|
11185
11185
|
return data;
|
|
11186
11186
|
}
|
|
11187
|
-
|
|
11187
|
+
window.matchMedia("only screen and (max-width: 480px)").matches;
|
|
11188
|
+
function getCoords(elem) {
|
|
11189
|
+
let box2 = elem.getBoundingClientRect();
|
|
11190
|
+
return {
|
|
11191
|
+
top: box2.top + window.pageYOffset,
|
|
11192
|
+
right: box2.right + window.pageXOffset,
|
|
11193
|
+
bottom: box2.bottom + window.pageYOffset,
|
|
11194
|
+
left: box2.left + window.pageXOffset
|
|
11195
|
+
};
|
|
11196
|
+
}
|
|
11188
11197
|
const fireStepEvent = (formNode) => (stepResult, stepHistory2, stepQueue2) => {
|
|
11189
11198
|
if (!stepResult) {
|
|
11190
11199
|
return;
|
|
11191
11200
|
}
|
|
11192
11201
|
const anchorId = formNode.attrs.anchorElement || formNode.id;
|
|
11193
|
-
if (anchorId
|
|
11202
|
+
if (anchorId) {
|
|
11194
11203
|
const anchor = document.getElementById(anchorId);
|
|
11195
11204
|
if (anchor) {
|
|
11196
|
-
anchor
|
|
11205
|
+
const pos = getCoords(anchor);
|
|
11206
|
+
window.scrollTo(pos.right, pos.top);
|
|
11197
11207
|
}
|
|
11198
11208
|
}
|
|
11199
11209
|
var step_values = null;
|