bhl-forms 0.0.47 → 0.0.50

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.
@@ -18003,10 +18003,7 @@ function getCoords(elem) {
18003
18003
  left: box2.left + window.pageXOffset
18004
18004
  };
18005
18005
  }
18006
- var fireStepEvent = (formNode) => (stepResult, stepHistory2, stepQueue2) => {
18007
- if (!stepResult) {
18008
- return;
18009
- }
18006
+ var scrollAnchor = (formNode) => () => {
18010
18007
  var anchorId = formNode.attrs.anchorElement || formNode.id;
18011
18008
  if (anchorId) {
18012
18009
  var anchor = document.getElementById(anchorId);
@@ -18015,6 +18012,12 @@ var fireStepEvent = (formNode) => (stepResult, stepHistory2, stepQueue2) => {
18015
18012
  window.scrollTo(pos.right, pos.top);
18016
18013
  }
18017
18014
  }
18015
+ };
18016
+ var fireStepEvent = (formNode) => (stepResult, stepHistory2, stepQueue2) => {
18017
+ if (!stepResult) {
18018
+ return;
18019
+ }
18020
+ scrollAnchor(formNode)();
18018
18021
  var step_values = null;
18019
18022
  if (stepHistory2.value.length > 0) {
18020
18023
  step_values = flattenObj(formNode.value[stepHistory2.value[stepHistory2.value.length - 1]] || {});
@@ -18108,7 +18111,7 @@ var theme = {
18108
18111
  tel: textClassification,
18109
18112
  text: textClassification,
18110
18113
  textarea: _objectSpread2(_objectSpread2({}, textClassification), {}, {
18111
- input: "t-block t-w-full t-h-48 t-px-3 t-pt-1 t-border-none t-text-base t-text-gray-700 t-placeholder-gray-400 placeholder:t-text-base focus:t-shadow-outline"
18114
+ input: "t-block t-w-full t-h-40 t-px-3 t-pt-1 t-border-none t-text-base t-text-gray-700 t-placeholder-gray-400 placeholder:t-text-base focus:t-shadow-outline"
18112
18115
  }),
18113
18116
  time: textClassification,
18114
18117
  url: textClassification,
@@ -22404,6 +22407,7 @@ var init = () => {
22404
22407
  data2.submitUrl = data2.submitUrl || defaultSubmitUrl;
22405
22408
  data2.prepData = data2.prepData || prepData;
22406
22409
  data2.fireStepEvent = data2.fireStepEvent || fireStepEvent;
22410
+ data2.scrollAnchor = data2.scrollAnchor || scrollAnchor;
22407
22411
  data2.onEnter = (callback) => (e3) => {
22408
22412
  if (e3.key === "Enter" || e3.keyCode === 13) {
22409
22413
  callback();