@jetshop/core 5.12.4 → 5.13.0
Sign up to get free protection for your applications and to get access to all the features.
- package/components/Auth/SignupFormContainer.d.ts +3 -0
- package/components/Auth/SignupFormContainer.js +13 -5
- package/components/Auth/SignupFormContainer.js.map +1 -1
- package/components/Auth/formatSignupInput.js +4 -1
- package/components/Auth/formatSignupInput.js.map +1 -1
- package/errorReporting.server.js +2 -2
- package/errorReporting.server.js.map +1 -1
- package/hooks/useInfinitePagination.js +1 -1
- package/hooks/useInfinitePagination.js.map +1 -1
- package/package.json +1 -1
- package/types.d.ts +12 -0
@@ -1,6 +1,7 @@
|
|
1
1
|
import { SignUpInput, MaskedProperty } from '@jetshop/core/types';
|
2
2
|
import { FormikProps } from 'formik';
|
3
3
|
import React from 'react';
|
4
|
+
import { SignUpFormInput } from './formatSignupInput';
|
4
5
|
declare type LookupData = {
|
5
6
|
[key: string]: MaskedProperty;
|
6
7
|
};
|
@@ -9,6 +10,8 @@ interface SignupFormProps {
|
|
9
10
|
formik: FormikProps<SignUpInput>;
|
10
11
|
}): React.ReactChild;
|
11
12
|
lookupData: LookupData;
|
13
|
+
additionalFormatter?: (values: SignUpFormInput) => SignUpInput;
|
14
|
+
additionalInitialValues?: Partial<SignUpFormInput>;
|
12
15
|
}
|
13
16
|
declare function SignupFormProvider({ LoadingComponent, ...props }: SignupFormProps & {
|
14
17
|
LoadingComponent?: JSX.Element;
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
12
12
|
import { Form, Formik } from 'formik';
|
13
13
|
import React, { useContext, useMemo } from 'react';
|
14
14
|
import { createValidatorForFields } from './formFieldsFromSettings';
|
15
|
-
import SignupProvider, { SignupContext, SignupFormikContext
|
15
|
+
import SignupProvider, { SignupContext, SignupFormikContext } from './signup-context';
|
16
16
|
import { useSignupSubmit } from './signupSubmit';
|
17
17
|
// Get the default values from the lookupData results if there are any,
|
18
18
|
// otherwise default them to an empty string
|
@@ -47,6 +47,7 @@ function formatLookupData(signupValues, lookupData) {
|
|
47
47
|
function SignupForm(props) {
|
48
48
|
// Available using Voyado integration.
|
49
49
|
const lookupData = props === null || props === void 0 ? void 0 : props.lookupData;
|
50
|
+
const additionalFormatter = props === null || props === void 0 ? void 0 : props.additionalFormatter;
|
50
51
|
const { allFields, selectedCountry } = useContext(SignupContext);
|
51
52
|
// Create the Formik validator for all fields
|
52
53
|
const validate = createValidatorForFields(allFields);
|
@@ -54,12 +55,19 @@ function SignupForm(props) {
|
|
54
55
|
const signupSubmit = useSignupSubmit();
|
55
56
|
// Get the initial values for the form
|
56
57
|
const initialValues = useMemo(() => {
|
57
|
-
|
58
|
-
|
58
|
+
var _a;
|
59
|
+
const additionalInitialValues = (_a = props === null || props === void 0 ? void 0 : props.additionalInitialValues) !== null && _a !== void 0 ? _a : {};
|
60
|
+
return Object.assign(Object.assign(Object.assign({}, getFieldDefaultValues(allFields, lookupData)), additionalInitialValues), { country: selectedCountry.code });
|
61
|
+
}, [
|
62
|
+
allFields,
|
63
|
+
lookupData,
|
64
|
+
props === null || props === void 0 ? void 0 : props.additionalInitialValues,
|
65
|
+
selectedCountry.code
|
66
|
+
]);
|
59
67
|
return (React.createElement(Formik, { enableReinitialize: true, validateOnChange: true, onSubmit: (values, actions) => {
|
60
68
|
signupSubmit({
|
61
|
-
values: formatLookupData(values, props.lookupData),
|
62
|
-
actions
|
69
|
+
values: formatLookupData(additionalFormatter ? additionalFormatter(values) : values, props.lookupData),
|
70
|
+
actions
|
63
71
|
});
|
64
72
|
}, validate: validate, initialValues: initialValues }, (formik) => props.children({ formik })));
|
65
73
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"SignupFormContainer.js","sourceRoot":"","sources":["SignupFormContainer.tsx"],"names":[],"mappings":";;;;;;;;;;;AAKA,OAAO,EAAE,IAAI,EAAE,MAAM,EAAe,MAAM,QAAQ,CAAC;AACnD,OAAO,KAAK,EAAE,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAEnD,OAAO,E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B,EAAE,IAAI,EACxB,gBAAgB,QAChB,QAAQ,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,EAAE;YAC5B,YAAY,CAAC;gBACX,MAAM,EAAE,gBAAgB,CACtB,mBAAmB,CAAC,CAAC,CAAC,mBAAmB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,EAC1D,KAAK,CAAC,UAAU,CACjB;gBACD,OAAO;aACR,CAAC,CAAC;QACL,CAAC,EACD,QAAQ,EAAE,QAAQ,EAClB,aAAa,EAAE,aAAa,IAE3B,CAAC,MAAM,EAAE,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC,CAChC,CACV,CAAC;AACJ,CAAC;AAED,2DAA2D;AAC3D,SAAS,kBAAkB,CAAC,EAG2B;QAH3B,EAC1B,gBAAgB,OAEqC,EADlD,KAAK,cAFkB,oBAG3B,CADS;IAER,OAAO,CACL,oBAAC,cAAc,IAAC,gBAAgB,EAAE,gBAAgB;QAChD,oBAAC,UAAU,oBAAK,KAAK,GAClB,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,CACf,oBAAC,IAAI;YACH,oBAAC,mBAAmB,CAAC,QAAQ,kBAAC,KAAK,EAAE,EAAE,MAAM,EAAE,IAAM,KAAK,EAAI,CACzD,CACR,CACU,CACE,CAClB,CAAC;AACJ,CAAC;AAED,eAAe,kBAAkB,CAAC"}
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
12
12
|
// Map forms to { valuename: { value: "value" } } format required for input
|
13
13
|
// e.g. { country: { value: "Sweden" } }
|
14
14
|
export function formatSignupInput(values, { userType }) {
|
15
|
-
const { emailAddress, password, pid, organizationNumber, country, externalId = '', priceListAccessCode = undefined, consents = [] } = values, rest = __rest(values, ["emailAddress", "password", "pid", "organizationNumber", "country", "externalId", "priceListAccessCode", "consents"]);
|
15
|
+
const { emailAddress, password, pid, organizationNumber, country, externalId = '', externalAttributes = undefined, priceListAccessCode = undefined, dynamicContent = undefined, preferences = undefined, consents = [] } = values, rest = __rest(values, ["emailAddress", "password", "pid", "organizationNumber", "country", "externalId", "externalAttributes", "priceListAccessCode", "dynamicContent", "preferences", "consents"]);
|
16
16
|
// Currently passing through country.code:country.name for the country
|
17
17
|
// selector. This is a hack for now to get the code and name separately.
|
18
18
|
const [countryCode, countryName] = country.split(':');
|
@@ -33,7 +33,10 @@ export function formatSignupInput(values, { userType }) {
|
|
33
33
|
pid,
|
34
34
|
organizationNumber,
|
35
35
|
priceListAccessCode,
|
36
|
+
externalAttributes,
|
36
37
|
externalId,
|
38
|
+
dynamicContent,
|
39
|
+
preferences,
|
37
40
|
consents
|
38
41
|
};
|
39
42
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"formatSignupInput.js","sourceRoot":"","sources":["formatSignupInput.ts"],"names":[],"mappings":";;;;;;;;;;;AAOA,2EAA2E;AAC3E,wCAAwC;AACxC,MAAM,UAAU,iBAAiB,CAC/B,MAAuB,EACvB,EAAE,QAAQ,EAAuC;IAEjD,MAAM,EACJ,YAAY,EACZ,QAAQ,EACR,GAAG,EACH,kBAAkB,EAClB,OAAO,EACP,UAAU,GAAG,EAAE,EACf,mBAAmB,GAAG,SAAS,EAC/B,QAAQ,GAAG,EAAE,KAEX,MAAM,EADL,IAAI,UACL,MAAM,
|
1
|
+
{"version":3,"file":"formatSignupInput.js","sourceRoot":"","sources":["formatSignupInput.ts"],"names":[],"mappings":";;;;;;;;;;;AAOA,2EAA2E;AAC3E,wCAAwC;AACxC,MAAM,UAAU,iBAAiB,CAC/B,MAAuB,EACvB,EAAE,QAAQ,EAAuC;IAEjD,MAAM,EACJ,YAAY,EACZ,QAAQ,EACR,GAAG,EACH,kBAAkB,EAClB,OAAO,EACP,UAAU,GAAG,EAAE,EACf,kBAAkB,GAAG,SAAS,EAC9B,mBAAmB,GAAG,SAAS,EAC/B,cAAc,GAAG,SAAS,EAC1B,WAAW,GAAG,SAAS,EACvB,QAAQ,GAAG,EAAE,KAEX,MAAM,EADL,IAAI,UACL,MAAM,EAbJ,4KAaL,CAAS,CAAC;IAEX,sEAAsE;IACtE,wEAAwE;IACxE,MAAM,CAAC,WAAW,EAAE,WAAW,CAAC,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAEtD,MAAM,YAAY,GAEd;QACF,WAAW,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE;KACpC,CAAC;IAEF,MAAM,SAAS,GAAG,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IAEvC,KAAK,MAAM,CAAC,KAAK,EAAE,KAAK,CAAC,IAAI,SAAS,EAAE;QACtC,YAAY,CAAC,KAAK,CAAC,GAAG;YACpB,KAAK,EAAE,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK;SACjD,CAAC;KACH;IAED,OAAO;QACL,IAAI,EAAE,QAAwB;QAC9B,cAAc,EAAE,YAAY;QAC5B,YAAY;QACZ,QAAQ;QACR,GAAG;QACH,kBAAkB;QAClB,mBAAmB;QACnB,kBAAkB;QAClB,UAAU;QACV,cAAc;QACd,WAAW;QACX,QAAQ;KACT,CAAC;AACJ,CAAC"}
|
package/errorReporting.server.js
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
import * as Sentry from '@sentry/node';
|
2
2
|
import { convertAnyToError } from './errorReporting.shared';
|
3
3
|
export default (error, extra = {}) => {
|
4
|
-
Sentry.withScope(scope => {
|
4
|
+
Sentry.withScope((scope) => {
|
5
5
|
// https://github.com/getsentry/sentry-javascript/issues/1607#issuecomment-425974249
|
6
|
-
Object.keys(extra).forEach(key => {
|
6
|
+
Object.keys(extra).forEach((key) => {
|
7
7
|
scope.setExtra(key, extra[key]);
|
8
8
|
});
|
9
9
|
Sentry.captureException(convertAnyToError(error));
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"errorReporting.server.js","sourceRoot":"","sources":["errorReporting.server.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,cAAc,CAAC;AACvC,OAAO,EAAU,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAEpE,eAAe,CAAC,KAAY,EAAE,QAAgB,EAAE,EAAE,EAAE;IAClD,MAAM,CAAC,SAAS,CAAC,KAAK,
|
1
|
+
{"version":3,"file":"errorReporting.server.js","sourceRoot":"","sources":["errorReporting.server.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,cAAc,CAAC;AACvC,OAAO,EAAU,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAEpE,eAAe,CAAC,KAAY,EAAE,QAAgB,EAAE,EAAE,EAAE;IAClD,MAAM,CAAC,SAAS,CAAC,CAAC,KAAK,EAAE,EAAE;QACzB,oFAAoF;QACpF,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;YACjC,KAAK,CAAC,QAAQ,CAAC,GAAG,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QAClC,CAAC,CAAC,CAAC;QACH,MAAM,CAAC,gBAAgB,CAAC,iBAAiB,CAAC,KAAK,CAAC,CAAC,CAAC;IACpD,CAAC,CAAC,CAAC;AACL,CAAC,CAAC"}
|
@@ -127,7 +127,7 @@ const useInfinitePagination = ({ result, query }) => {
|
|
127
127
|
},
|
128
128
|
next: {
|
129
129
|
loadingProducts: loading.next,
|
130
|
-
hasProducts: nextOffset
|
130
|
+
hasProducts: nextOffset < totalResults,
|
131
131
|
fetchProducts: () => fetchProductsByOffset(nextOffset),
|
132
132
|
offset: nextOffset,
|
133
133
|
page: nextOffset / perPage + 1
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"useInfinitePagination.js","sourceRoot":"","sources":["useInfinitePagination.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,UAAU,EACV,SAAS,EACT,UAAU,EACV,OAAO,EACP,MAAM,EACP,MAAM,O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GAAG,OAAO,GAAG,CAAC;SAC/B;QACD,IAAI,EAAE;YACJ,eAAe,EAAE,OAAO,CAAC,IAAI;YAC7B,WAAW,EAAE,UAAU,GAAG,YAAY;YACtC,aAAa,EAAE,GAAG,EAAE,CAAC,qBAAqB,CAAC,UAAU,CAAC;YACtD,MAAM,EAAE,UAAU;YAClB,IAAI,EAAE,UAAU,GAAG,OAAO,GAAG,CAAC;SAC/B;QACD,QAAQ,EAAE,gBAAgB;KAC3B,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
|
package/package.json
CHANGED
package/types.d.ts
CHANGED
@@ -645,6 +645,11 @@ export type CustomerUpdateDeliveryAddressInput = {
|
|
645
645
|
addressName?: Maybe<Scalars['String']>;
|
646
646
|
};
|
647
647
|
|
648
|
+
export type CustomerUpdateExternalAttribute = {
|
649
|
+
name?: Maybe<Scalars['String']>;
|
650
|
+
value?: Maybe<Scalars['String']>;
|
651
|
+
};
|
652
|
+
|
648
653
|
export type CustomerUpdateInput = {
|
649
654
|
pid?: Maybe<Scalars['String']>;
|
650
655
|
organizationNumber?: Maybe<Scalars['String']>;
|
@@ -652,6 +657,7 @@ export type CustomerUpdateInput = {
|
|
652
657
|
deliveryAddresses?: Maybe<Array<Maybe<CustomerUpdateDeliveryAddressInput>>>;
|
653
658
|
preferences?: Maybe<CustomerUpdatePreferenceInput>;
|
654
659
|
consents?: Maybe<Array<Maybe<CustomerUpdateConsentInput>>>;
|
660
|
+
externalAttributes?: Maybe<Array<Maybe<CustomerUpdateExternalAttribute>>>;
|
655
661
|
dynamicContent?: Maybe<Scalars['String']>;
|
656
662
|
};
|
657
663
|
|
@@ -2292,6 +2298,11 @@ export type SignUpDeliveryAddressInput = {
|
|
2292
2298
|
addressName?: Maybe<Scalars['String']>;
|
2293
2299
|
};
|
2294
2300
|
|
2301
|
+
export type SignUpExternalAttribute = {
|
2302
|
+
name?: Maybe<Scalars['String']>;
|
2303
|
+
value?: Maybe<Scalars['String']>;
|
2304
|
+
};
|
2305
|
+
|
2295
2306
|
export type SignUpInput = {
|
2296
2307
|
type: CustomerType;
|
2297
2308
|
pid?: Maybe<Scalars['String']>;
|
@@ -2304,6 +2315,7 @@ export type SignUpInput = {
|
|
2304
2315
|
deliveryAddresses?: Maybe<Array<Maybe<SignUpDeliveryAddressInput>>>;
|
2305
2316
|
preferences?: Maybe<SignUpPreferencesInput>;
|
2306
2317
|
consents?: Maybe<Array<Maybe<SignUpConsentInput>>>;
|
2318
|
+
externalAttributes?: Maybe<Array<Maybe<SignUpExternalAttribute>>>;
|
2307
2319
|
dynamicContent?: Maybe<Scalars['String']>;
|
2308
2320
|
priceListAccessCode?: Maybe<Scalars['String']>;
|
2309
2321
|
};
|