@open-tender/utils 0.1.143 → 0.1.145

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.
@@ -87,9 +87,6 @@ const useSignUpGuestForm = (email, guest, loading, error, guestErrors, signUp, s
87
87
  else if (guestErrors) {
88
88
  setErrors(guestErrors);
89
89
  }
90
- else {
91
- setErrors({});
92
- }
93
90
  }
94
91
  }, [loading, error, guestErrors]);
95
92
  (0, react_1.useEffect)(() => {
@@ -1,4 +1,4 @@
1
- import { CheckoutError, CheckoutErrorMessages, CheckoutErrorParams, RequestError } from '@open-tender/types';
1
+ import { CheckoutError, CheckoutErrorMessages, CheckoutErrorParams, RecordInterface, RequestError } from '@open-tender/types';
2
2
  export declare const handleRespError: (err: RequestError) => {
3
3
  title: string;
4
4
  detail: string | undefined;
@@ -9,9 +9,6 @@ export declare const handleRespError: (err: RequestError) => {
9
9
  err: RequestError;
10
10
  };
11
11
  export declare const processError: (msg: string | null) => string;
12
- interface RecordInterface {
13
- [name: string]: string | RecordInterface;
14
- }
15
12
  export declare const handleFormErrorsNested: (params: Record<string, string | null>) => RecordInterface;
16
13
  export declare const makeFormErrorsNested: (error: RequestError) => RecordInterface;
17
14
  export declare const handleFormErrors: (params: Record<string, string | null>) => Record<string, string>;
@@ -52,4 +49,3 @@ export declare const errMessages: {
52
49
  distanceSurcharge: string;
53
50
  missingAddressDeliveryZone: string;
54
51
  };
55
- export {};
@@ -84,9 +84,6 @@ export const useSignUpGuestForm = (email, guest, loading, error, guestErrors, si
84
84
  else if (guestErrors) {
85
85
  setErrors(guestErrors);
86
86
  }
87
- else {
88
- setErrors({});
89
- }
90
87
  }
91
88
  }, [loading, error, guestErrors]);
92
89
  useEffect(() => {
@@ -1,4 +1,4 @@
1
- import { CheckoutError, CheckoutErrorMessages, CheckoutErrorParams, RequestError } from '@open-tender/types';
1
+ import { CheckoutError, CheckoutErrorMessages, CheckoutErrorParams, RecordInterface, RequestError } from '@open-tender/types';
2
2
  export declare const handleRespError: (err: RequestError) => {
3
3
  title: string;
4
4
  detail: string | undefined;
@@ -9,9 +9,6 @@ export declare const handleRespError: (err: RequestError) => {
9
9
  err: RequestError;
10
10
  };
11
11
  export declare const processError: (msg: string | null) => string;
12
- interface RecordInterface {
13
- [name: string]: string | RecordInterface;
14
- }
15
12
  export declare const handleFormErrorsNested: (params: Record<string, string | null>) => RecordInterface;
16
13
  export declare const makeFormErrorsNested: (error: RequestError) => RecordInterface;
17
14
  export declare const handleFormErrors: (params: Record<string, string | null>) => Record<string, string>;
@@ -52,4 +49,3 @@ export declare const errMessages: {
52
49
  distanceSurcharge: string;
53
50
  missingAddressDeliveryZone: string;
54
51
  };
55
- export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@open-tender/utils",
3
- "version": "0.1.143",
3
+ "version": "0.1.145",
4
4
  "description": "A library of utils for use with Open Tender applications that utilize our cloud-based Order API.",
5
5
  "main": "./dist/cjs/index.js",
6
6
  "module": "./dist/esm/index.js",