@wix/form-public 0.13.0 → 0.14.0

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.
@@ -39,7 +39,7 @@ export declare const FileUploadMapper: PropsMapper;
39
39
 
40
40
  export declare const FixedPaymentMapper: PropsMapper;
41
41
 
42
- declare const Form: (props: FormProps) => JSX_2.Element;
42
+ declare const Form: ({ form, fields, values, onChange, errors, onValidate, }: FormProps) => JSX_2.Element;
43
43
  export { Form }
44
44
  export { Form as Form_alias_1 }
45
45
 
@@ -39,7 +39,7 @@ export declare const FileUploadMapper: PropsMapper;
39
39
 
40
40
  export declare const FixedPaymentMapper: PropsMapper;
41
41
 
42
- declare const Form: (props: FormProps) => JSX_2.Element;
42
+ declare const Form: ({ form, fields, values, onChange, errors, onValidate, }: FormProps) => JSX_2.Element;
43
43
  export { Form }
44
44
  export { Form as Form_alias_1 }
45
45
 
package/dist/index.cjs CHANGED
@@ -4473,7 +4473,7 @@ var require_react_is_development = __commonJS({
4473
4473
  var ContextProvider = REACT_PROVIDER_TYPE;
4474
4474
  var Element2 = REACT_ELEMENT_TYPE;
4475
4475
  var ForwardRef = REACT_FORWARD_REF_TYPE;
4476
- var Fragment2 = REACT_FRAGMENT_TYPE;
4476
+ var Fragment = REACT_FRAGMENT_TYPE;
4477
4477
  var Lazy = REACT_LAZY_TYPE;
4478
4478
  var Memo = REACT_MEMO_TYPE;
4479
4479
  var Portal = REACT_PORTAL_TYPE;
@@ -4532,7 +4532,7 @@ var require_react_is_development = __commonJS({
4532
4532
  exports.ContextProvider = ContextProvider;
4533
4533
  exports.Element = Element2;
4534
4534
  exports.ForwardRef = ForwardRef;
4535
- exports.Fragment = Fragment2;
4535
+ exports.Fragment = Fragment;
4536
4536
  exports.Lazy = Lazy;
4537
4537
  exports.Memo = Memo;
4538
4538
  exports.Portal = Portal;
@@ -29987,27 +29987,39 @@ var mapFieldTypes = (fields, typeMap) => ({
29987
29987
  Object.entries(typeMap).filter(([, targetType]) => fields[targetType]).map(([newName, targetType]) => [newName, fields[targetType]])
29988
29988
  )
29989
29989
  });
29990
- var Form2 = (props) => {
29990
+ var Form2 = ({
29991
+ form,
29992
+ fields,
29993
+ values,
29994
+ onChange,
29995
+ errors,
29996
+ onValidate
29997
+ }) => {
29991
29998
  const siteConfig = {
29992
29999
  locale: {
29993
30000
  languageCode: "en"
29994
30001
  }
29995
30002
  };
29996
30003
  const i18n2 = initI18n({ locale: siteConfig.locale.languageCode });
29997
- const mappedFieldProps = mapFieldProps(props.fields, FIELD_PROP_MAP);
30004
+ const mappedFieldProps = mapFieldProps(fields, FIELD_PROP_MAP);
29998
30005
  const mappedFieldTypes = mapFieldTypes(mappedFieldProps, FIELD_TYPE_MAP);
29999
- return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsx(
30006
+ return /* @__PURE__ */ jsxRuntime.jsx(
30000
30007
  FormViewerStatic,
30001
30008
  {
30002
- form: props.form || {},
30003
- values: props.values,
30004
- onChange: props.onChange,
30005
- errors: props.errors,
30006
- onValidate: props.onValidate,
30009
+ form,
30010
+ values,
30011
+ onChange,
30012
+ errors,
30013
+ onValidate,
30007
30014
  fields: mappedFieldTypes,
30008
- i18n: i18n2
30015
+ i18n: i18n2,
30016
+ WixRicosViewer: () => null,
30017
+ config: {
30018
+ locale: siteConfig.locale.languageCode,
30019
+ regionalFormat: siteConfig.locale.languageCode
30020
+ }
30009
30021
  }
30010
- ) });
30022
+ );
30011
30023
  };
30012
30024
  /*! Bundled license information:
30013
30025