@redneckz/wildless-cms-uni-blocks 0.14.200 → 0.14.201

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.
Files changed (35) hide show
  1. package/bundle/bundle.umd.js +10 -7
  2. package/bundle/bundle.umd.min.js +1 -1
  3. package/dist/components/ApplicationFormCustom/getField.js +7 -6
  4. package/dist/components/ApplicationFormCustom/getField.js.map +1 -1
  5. package/dist/components/ApplicationFormCustom/getInitialFormState.js +1 -0
  6. package/dist/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  7. package/dist/components/ApplicationFormCustom/getObjectValidator.js +1 -0
  8. package/dist/components/ApplicationFormCustom/getObjectValidator.js.map +1 -1
  9. package/lib/components/ApplicationFormCustom/getField.js +7 -6
  10. package/lib/components/ApplicationFormCustom/getField.js.map +1 -1
  11. package/lib/components/ApplicationFormCustom/getInitialFormState.js +1 -0
  12. package/lib/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  13. package/lib/components/ApplicationFormCustom/getObjectValidator.js +1 -0
  14. package/lib/components/ApplicationFormCustom/getObjectValidator.js.map +1 -1
  15. package/mobile/bundle/bundle.umd.js +10 -7
  16. package/mobile/bundle/bundle.umd.min.js +1 -1
  17. package/mobile/dist/components/ApplicationFormCustom/getField.js +7 -6
  18. package/mobile/dist/components/ApplicationFormCustom/getField.js.map +1 -1
  19. package/mobile/dist/components/ApplicationFormCustom/getInitialFormState.js +1 -0
  20. package/mobile/dist/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  21. package/mobile/dist/components/ApplicationFormCustom/getObjectValidator.js +1 -0
  22. package/mobile/dist/components/ApplicationFormCustom/getObjectValidator.js.map +1 -1
  23. package/mobile/lib/components/ApplicationFormCustom/getField.js +7 -6
  24. package/mobile/lib/components/ApplicationFormCustom/getField.js.map +1 -1
  25. package/mobile/lib/components/ApplicationFormCustom/getInitialFormState.js +1 -0
  26. package/mobile/lib/components/ApplicationFormCustom/getInitialFormState.js.map +1 -1
  27. package/mobile/lib/components/ApplicationFormCustom/getObjectValidator.js +1 -0
  28. package/mobile/lib/components/ApplicationFormCustom/getObjectValidator.js.map +1 -1
  29. package/mobile/src/components/ApplicationFormCustom/getField.tsx +7 -11
  30. package/mobile/src/components/ApplicationFormCustom/getInitialFormState.tsx +1 -0
  31. package/mobile/src/components/ApplicationFormCustom/getObjectValidator.tsx +1 -0
  32. package/package.json +1 -1
  33. package/src/components/ApplicationFormCustom/getField.tsx +7 -11
  34. package/src/components/ApplicationFormCustom/getInitialFormState.tsx +1 -0
  35. package/src/components/ApplicationFormCustom/getObjectValidator.tsx +1 -0
@@ -1926,16 +1926,17 @@
1926
1926
  const CheckboxWithError = JSX(({ className, text, value, key, disabled, error, onChange }) => (jsxs("div", { className: style('shrink-0 w-full', className), children: [jsx(Checkbox, { text: text, value: value, disabled: disabled, onChange: onChange }, key), renderErrorText(error)] })));
1927
1927
 
1928
1928
  const getField = (input, field) => {
1929
+ const { required } = input;
1929
1930
  const InputsMap = {
1930
- surname: (jsx(InputControl, { label: "\u0424\u0430\u043C\u0438\u043B\u0438\u044F", ...getValidation(field('surname'), nameValidator, input?.required) })),
1931
- name: (jsx(InputControl, { label: "\u0418\u043C\u044F", ...getValidation(field('name'), nameValidator, input?.required) })),
1931
+ surname: (jsx(InputControl, { label: "\u0424\u0430\u043C\u0438\u043B\u0438\u044F", ...getValidation(field('surname'), nameValidator, required) })),
1932
+ name: jsx(InputControl, { label: "\u0418\u043C\u044F", ...getValidation(field('name'), nameValidator, required) }),
1932
1933
  middleName: (jsx(InputControl, { label: "\u041E\u0442\u0447\u0435\u0441\u0442\u0432\u043E (\u041E\u0431\u044F\u0437\u0430\u0442\u0435\u043B\u044C\u043D\u043E, \u043F\u0440\u0438 \u043D\u0430\u043B\u0438\u0447\u0438\u0438)", ...field('middleName') })),
1933
- phone: (jsx(PhoneInputControl, { label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...getValidation(field('phone'), phoneValidator, input?.required) })),
1934
- email: (jsx(InputControl, { label: "\u042D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u0430\u044F \u043F\u043E\u0447\u0442\u0430", ...getValidation(field('email'), defaultValidator, input?.required) })),
1935
- comment: (jsx(InputControl, { className: "col-span-2", ...getValidation(field('comment'), defaultValidator, input?.required), placeholder: "\u0412\u0430\u0448\u0435 \u0441\u043E\u043E\u0431\u0449\u0435\u043D\u0438\u0435", isTextarea: true })),
1934
+ phone: (jsx(PhoneInputControl, { label: "\u0422\u0435\u043B\u0435\u0444\u043E\u043D", ...getValidation(field('phone'), phoneValidator, required) })),
1935
+ email: (jsx(InputControl, { label: "\u042D\u043B\u0435\u043A\u0442\u0440\u043E\u043D\u043D\u0430\u044F \u043F\u043E\u0447\u0442\u0430", ...getValidation(field('email'), defaultValidator, required) })),
1936
+ comment: (jsx(InputControl, { className: "col-span-2", ...getValidation(field('comment'), defaultValidator, required), placeholder: "\u0412\u0430\u0448\u0435 \u0441\u043E\u043E\u0431\u0449\u0435\u043D\u0438\u0435", isTextarea: true })),
1936
1937
  region: jsx(RegionField, { field: field }),
1937
1938
  client: (jsx(CheckboxWithError, { ...field('isClient'), text: '\u042F\u0432\u043B\u044F\u044E\u0441\u044C \u043A\u043B\u0438\u0435\u043D\u0442\u043E\u043C \u0431\u0430\u043D\u043A\u0430 \u0410\u041E "\u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A"' })),
1938
- birthday: (jsx(DatePickerControl, { label: "\u0414\u0430\u0442\u0430 \u0440\u043E\u0436\u0434\u0435\u043D\u0438\u044F", ...getValidation(field('birthday'), defaultValidator) })),
1939
+ birthday: (jsx(DatePickerControl, { label: "\u0414\u0430\u0442\u0430 \u0440\u043E\u0436\u0434\u0435\u043D\u0438\u044F", ...getValidation(field('birthday'), defaultValidator, required) })),
1939
1940
  legend: (jsx("legend", { className: "w-full col-span-2", children: jsx(Heading, { title: input.label, headingType: "h6", className: "@xl:text-center" }) })),
1940
1941
  };
1941
1942
  return InputsMap[input.name];
@@ -1952,6 +1953,7 @@
1952
1953
  middleName: '',
1953
1954
  phone: '',
1954
1955
  email: '',
1956
+ birthday: undefined,
1955
1957
  comment: '',
1956
1958
  consentDataProcessing: false,
1957
1959
  };
@@ -1966,6 +1968,7 @@
1966
1968
  name: nameValidator,
1967
1969
  region: defaultValidator,
1968
1970
  phone: phoneValidator,
1971
+ birthday: defaultValidator,
1969
1972
  email: defaultValidator,
1970
1973
  comment: defaultValidator,
1971
1974
  consentDataProcessing: checkboxValidator,
@@ -6072,7 +6075,7 @@
6072
6075
  slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
6073
6076
  });
6074
6077
 
6075
- const packageVersion = "0.14.199";
6078
+ const packageVersion = "0.14.200";
6076
6079
 
6077
6080
  exports.Blocks = Blocks;
6078
6081
  exports.ContentPage = ContentPage;