@wix/headless-forms 0.0.25 → 0.0.26

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/README.md CHANGED
@@ -20,20 +20,22 @@ Headless React components for rendering and managing forms. It follows the compo
20
20
  3. **Test Changes Locally**
21
21
  Run `examples/astro-forms-demo` to test changes locally.
22
22
 
23
+ 4. Support channel `#verticals-on-wix-vibe`
24
+
25
+
23
26
  ## Documentation
24
27
 
25
28
  All changes should be documented using `jsdoc` and updating `docs/api/FORM_INTERFACE.md`.
26
29
 
27
30
  ## Publishing
28
31
 
29
- 1. **Update Version**
30
- The version will be updated automatically by Falcon after merging to master
31
-
32
- 2. **Update SDK Exports**
33
- - Go to Form app in Wix Dev Center
34
- - Update SDK exports extensions:
35
- - "Forms SDK Exports Components"
36
- - "Forms SDK Exports Services"
37
- - Release new app version
38
- - Check if update has been commited to `auto-sdk-packages` repo (might take around 20mins)
32
+ **Update SDK Exports (@wix/forms package)**
33
+ - @wix/headless-forms package npm version will be updated automatically by Falcon after merging to master
34
+ - Go to Wix Form app in Wix Dev Center
35
+ - Update @wix/headless package version in SDK exports extensions:
36
+ - "Forms SDK Exports Components"
37
+ - "Forms SDK Exports Services"
38
+ - Release new app version
39
+ - Check if update has been commited to `auto-sdk-packages` repo ±20min
40
+ - Create a PR in [Picaso project](https://github.com/wix-private/picasso/blob/master/packages/vibe-remote-machine/main/package.json#L78) with new version. This package.json is used Wix Vibe site code.
39
41
 
@@ -42,7 +42,7 @@ const essentials_1 = require("@wix/essentials");
42
42
  const Form_js_1 = require("./core/Form.js");
43
43
  const FieldContext_js_1 = require("./context/FieldContext.js");
44
44
  const FieldLayoutContext_js_1 = require("./context/FieldLayoutContext.js");
45
- const utils_1 = require("../services/utils");
45
+ const index_js_1 = require("../services/utils/index.js");
46
46
  var TestIds;
47
47
  (function (TestIds) {
48
48
  TestIds["formRoot"] = "form-root";
@@ -556,16 +556,16 @@ exports.Fields = react_1.default.forwardRef((props, ref) => {
556
556
  return ((0, jsx_runtime_1.jsx)(Form_js_1.Fields, { children: ({ form, formValues, submitForm, handleForm, addressTemplates, siteConfig, }) => {
557
557
  if (!form)
558
558
  return null;
559
- return ((0, jsx_runtime_1.jsx)("div", { ref: ref, children: (0, jsx_runtime_1.jsx)(form_public_1.FormProvider, { currency: siteConfig?.currency ?? utils_1.DEFAULT_CURRENCY, locale: currentLanguage, regionalFormat: currentLocale, addressTemplates: addressTemplates, children: (0, jsx_runtime_1.jsx)(form_public_1.UniqueFieldSuffixContextProvider, { parentId: form._id ?? '', children: (0, jsx_runtime_1.jsx)(FieldsWithForm, { form: form, values: formValues, onChange: handleForm, errors: formErrors, onValidate: handleFormValidate, fields: props.fieldMap, submitForm: submitForm, rowGapClassname: props.rowGapClassname, columnGapClassname: props.columnGapClassname, formRef: formRef }) }) }) }));
559
+ return ((0, jsx_runtime_1.jsx)("div", { ref: ref, children: (0, jsx_runtime_1.jsx)(form_public_1.FormProvider, { currency: siteConfig?.currency ?? index_js_1.DEFAULT_CURRENCY, locale: currentLanguage, regionalFormat: currentLocale, addressTemplates: addressTemplates, children: (0, jsx_runtime_1.jsx)(form_public_1.UniqueFieldSuffixContextProvider, { parentId: form._id ?? '', children: (0, jsx_runtime_1.jsx)(FieldsWithForm, { form: form, values: formValues, onChange: handleForm, errors: formErrors, onValidate: handleFormValidate, fields: props.fieldMap, submitForm: submitForm, rowGapClassname: props.rowGapClassname, columnGapClassname: props.columnGapClassname, formRef: formRef }) }) }) }));
560
560
  } }));
561
561
  });
562
562
  const FieldsWithForm = ({ form, submitForm, values, onChange, errors, onValidate, fields: fieldMap, rowGapClassname, columnGapClassname, formRef, }) => {
563
563
  const coreUploadFile = async ({ file, formId, }) => {
564
- const uploadUrl = await (0, utils_1.getUploadUrl)(formId, file);
564
+ const uploadUrl = await (0, index_js_1.getUploadUrl)(formId, file);
565
565
  if (uploadUrl === undefined) {
566
566
  return { isPrivate: false };
567
567
  }
568
- const url = await (0, utils_1.uploadFile)(file, uploadUrl);
568
+ const url = await (0, index_js_1.uploadFile)(file, uploadUrl);
569
569
  return {
570
570
  id: '123123',
571
571
  isPrivate: false,
@@ -6,7 +6,7 @@ import { i18n } from '@wix/essentials';
6
6
  import { Root as CoreRoot, Loading as CoreLoading, LoadingError as CoreLoadingError, Error as CoreError, Submitted as CoreSubmitted, Fields as CoreFields, Field as CoreField, useFormRef, } from './core/Form.js';
7
7
  import { FieldContext, useFieldContext, } from './context/FieldContext.js';
8
8
  import { FieldLayoutProvider, useFieldLayout, } from './context/FieldLayoutContext.js';
9
- import { getUploadUrl, uploadFile, DEFAULT_CURRENCY } from '../services/utils';
9
+ import { getUploadUrl, uploadFile, DEFAULT_CURRENCY, } from '../services/utils/index.js';
10
10
  var TestIds;
11
11
  (function (TestIds) {
12
12
  TestIds["formRoot"] = "form-root";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/headless-forms",
3
- "version": "0.0.25",
3
+ "version": "0.0.26",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -60,5 +60,5 @@
60
60
  "groupId": "com.wixpress.headless-components"
61
61
  }
62
62
  },
63
- "falconPackageHash": "63674d55284599c781e53c0c2c1b10129d1d759d3def8c059d30cd5e"
63
+ "falconPackageHash": "22029dcca5ca6b784b9b10ab5e50a42d7f020f1fa80a8660e9e86dc7"
64
64
  }