@redneckz/wildless-cms-uni-blocks 0.14.618 → 0.14.619

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.
@@ -2714,7 +2714,7 @@
2714
2714
  const inputsFiltered = getFilteredInputs(inputs, formData);
2715
2715
  const feedbackValidator = objectValidator(getObjectValidator(inputsFiltered));
2716
2716
  if (!isValidationSuccess(feedbackValidator(formData))) {
2717
- return 'Fail';
2717
+ return console.warn('validation fail');
2718
2718
  }
2719
2719
  const formatData = getFormatData({ ...formData, ...additionalParams });
2720
2720
  const status = (await API.send(formatData, endpoint === 'lead')) ? 'OK' : 'Fail';
@@ -2740,13 +2740,11 @@
2740
2740
  return (jsxs(ApplicationFormLayout, { className: style('container space-y-m', className), title: title, ...rest, children: [jsxs("form", { onSubmit: onSubmit, children: [sections.map((_, i) => (jsxs("div", { className: style(inputColumnStyles(_.columns), 'grid gap-x-m'), children: [renderTitle(_.title), (_?.inputs || [])?.map(getField(field, typeForm))] }, `section-${i}`))), renderAgreementSubmit(fieldName ? field('consentDataProcessing') : undefined, link, button)] }), isContacts ? renderContacts() : null] }));
2741
2741
  });
2742
2742
  const getFilteredInputs = (inputs, data) => inputs
2743
- .filter((_) => _)
2743
+ .filter((_) => (_?.name === 'secondaryPhone' ? Boolean(data.secondaryPhone) : _))
2744
2744
  .filter((input) => !input?.condition ||
2745
2745
  input?.condition.values.find((_) => {
2746
2746
  const dataValue = data?.[input?.condition?.name ?? ''];
2747
- return input.name === 'secondaryPhone'
2748
- ? Boolean(data.secondaryPhone)
2749
- : _ === (dataValue?.key ?? dataValue);
2747
+ return _ === (dataValue?.key ?? dataValue);
2750
2748
  }));
2751
2749
 
2752
2750
  function useLocalStorage(key) {
@@ -8188,7 +8186,7 @@
8188
8186
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
8189
8187
  });
8190
8188
 
8191
- const packageVersion = "0.14.617";
8189
+ const packageVersion = "0.14.618";
8192
8190
 
8193
8191
  exports.Blocks = Blocks;
8194
8192
  exports.ContentPage = ContentPage;