@saasquatch/mint-components 2.1.8-1 → 2.1.8-2
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/dist/cjs/{ShadowViewAddon-5ce32291.js → ShadowViewAddon-a26deae6.js} +1 -90
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mint-components.cjs.js +1 -1
- package/dist/cjs/sqm-banking-info-form_10.cjs.entry.js +54 -381
- package/dist/cjs/{sqm-big-stat_46.cjs.entry.js → sqm-big-stat_45.cjs.entry.js} +9 -332
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +2 -158
- package/dist/collection/collection-manifest.json +0 -1
- package/dist/collection/components/sqm-referral-iframe/ReferralIframe.stories.js +1 -0
- package/dist/collection/components/sqm-referral-iframe/sqm-referral-iframe-view.js +1 -1
- package/dist/collection/components/sqm-referral-iframe/sqm-referral-iframe.js +27 -1
- package/dist/collection/components/sqm-stencilbook/sqm-stencilbook.js +0 -2
- package/dist/collection/components/tax-and-cash/sqm-banking-info-form/formDefinitions.js +37 -75
- package/dist/collection/components/tax-and-cash/sqm-banking-info-form/sqm-banking-info-form.js +13 -688
- package/dist/collection/components/tax-and-cash/sqm-banking-info-form/useBankingInfoForm.js +1 -95
- package/dist/collection/components/tax-and-cash/sqm-indirect-tax-form/sqm-indirect-tax-form.js +4 -4
- package/dist/collection/components/tax-and-cash/sqm-payout-details-card/sqm-payout-details-card.js +2 -2
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.js +6 -6
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.js +2 -2
- package/dist/esm/{ShadowViewAddon-9d97b5d5.js → ShadowViewAddon-47f1e579.js} +2 -90
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mint-components.js +1 -1
- package/dist/esm/sqm-banking-info-form_10.entry.js +54 -381
- package/dist/esm/{sqm-big-stat_46.entry.js → sqm-big-stat_45.entry.js} +14 -336
- package/dist/esm/sqm-stencilbook.entry.js +2 -158
- package/dist/esm-es5/{ShadowViewAddon-9d97b5d5.js → ShadowViewAddon-47f1e579.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mint-components.js +1 -1
- package/dist/esm-es5/sqm-banking-info-form_10.entry.js +1 -1
- package/dist/esm-es5/sqm-big-stat_45.entry.js +1 -0
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-0614dcbc.entry.js +9 -0
- package/dist/mint-components/{p-adc4e263.js → p-217dedde.js} +25 -25
- package/dist/mint-components/p-5492dd51.system.entry.js +1 -0
- package/dist/mint-components/p-7ee8f2ed.entry.js +273 -0
- package/dist/mint-components/p-bf545082.system.entry.js +1 -0
- package/dist/mint-components/p-ca098be1.system.js +1 -1
- package/dist/mint-components/p-ce050888.system.js +1 -0
- package/dist/mint-components/p-d4f332a7.entry.js +106 -0
- package/dist/mint-components/p-de343dd0.system.entry.js +1 -0
- package/dist/types/components/sqm-referral-iframe/sqm-referral-iframe-view.d.ts +1 -0
- package/dist/types/components/sqm-referral-iframe/sqm-referral-iframe.d.ts +5 -0
- package/dist/types/components/tax-and-cash/sqm-banking-info-form/formDefinitions.d.ts +0 -2
- package/dist/types/components/tax-and-cash/sqm-banking-info-form/sqm-banking-info-form-view.d.ts +0 -4
- package/dist/types/components/tax-and-cash/sqm-banking-info-form/sqm-banking-info-form.d.ts +0 -165
- package/dist/types/components.d.ts +10 -378
- package/docs/docs.docx +0 -0
- package/docs/raisins.json +1 -1
- package/grapesjs/grapesjs.js +1 -1
- package/package.json +1 -1
- package/dist/collection/components/sqm-partner-info-modal/PartnerInfoModal.stories.js +0 -143
- package/dist/collection/components/sqm-partner-info-modal/sqm-partner-info-modal-view.js +0 -90
- package/dist/collection/components/sqm-partner-info-modal/sqm-partner-info-modal.js +0 -462
- package/dist/collection/components/sqm-partner-info-modal/usePartnerInfoModal.js +0 -180
- package/dist/esm-es5/sqm-big-stat_46.entry.js +0 -1
- package/dist/mint-components/p-0f036907.system.js +0 -1
- package/dist/mint-components/p-22e39d2c.entry.js +0 -342
- package/dist/mint-components/p-499885aa.entry.js +0 -9
- package/dist/mint-components/p-a6621899.system.entry.js +0 -1
- package/dist/mint-components/p-b0253f4c.entry.js +0 -108
- package/dist/mint-components/p-d93e19e9.system.entry.js +0 -1
- package/dist/mint-components/p-e45a9966.system.entry.js +0 -1
- package/dist/types/components/sqm-partner-info-modal/PartnerInfoModal.stories.d.ts +0 -13
- package/dist/types/components/sqm-partner-info-modal/sqm-partner-info-modal-view.d.ts +0 -41
- package/dist/types/components/sqm-partner-info-modal/sqm-partner-info-modal.d.ts +0 -80
- package/dist/types/components/sqm-partner-info-modal/usePartnerInfoModal.d.ts +0 -16
|
@@ -22,7 +22,7 @@ const keys = require('./keys-cff24974.js');
|
|
|
22
22
|
const usePayoutStatus = require('./usePayoutStatus-0192fccd.js');
|
|
23
23
|
|
|
24
24
|
function getFormMap({ props, getValidationErrorMessage, bankCountry, }) {
|
|
25
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32
|
|
25
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32;
|
|
26
26
|
const { errors, ...formState } = props.states.formState;
|
|
27
27
|
return {
|
|
28
28
|
0: {
|
|
@@ -31,54 +31,44 @@ function getFormMap({ props, getValidationErrorMessage, bankCountry, }) {
|
|
|
31
31
|
helpText: getValidationErrorMessage({
|
|
32
32
|
type: (_c = (_b = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _b === void 0 ? void 0 : _b.beneficiaryAccountName) === null || _c === void 0 ? void 0 : _c.type,
|
|
33
33
|
label: props.text.beneficiaryAccountNameLabel,
|
|
34
|
-
errorCode: (_e = (_d = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _d === void 0 ? void 0 : _d.beneficiaryAccountName) === null || _e === void 0 ? void 0 : _e.errorCode,
|
|
35
|
-
fieldName: "beneficiaryAccountName",
|
|
36
34
|
}),
|
|
37
35
|
})))),
|
|
38
36
|
},
|
|
39
37
|
1: {
|
|
40
|
-
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.bankAccountTypeLabel, name: "/bankAccountType", id: "bankAccountType", key: "bankAccountType" }, (((
|
|
38
|
+
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.bankAccountTypeLabel, name: "/bankAccountType", id: "bankAccountType", key: "bankAccountType" }, (((_d = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _d === void 0 ? void 0 : _d.bankAccountType) && {
|
|
41
39
|
class: "error-input",
|
|
42
40
|
helpText: getValidationErrorMessage({
|
|
43
|
-
type: (
|
|
41
|
+
type: (_f = (_e = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _e === void 0 ? void 0 : _e.bankAccountType) === null || _f === void 0 ? void 0 : _f.type,
|
|
44
42
|
label: props.text.bankAccountTypeLabel,
|
|
45
|
-
errorCode: (_k = (_j = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _j === void 0 ? void 0 : _j.bankAccountType) === null || _k === void 0 ? void 0 : _k.errorCode,
|
|
46
|
-
fieldName: "bankAccountType",
|
|
47
43
|
}),
|
|
48
44
|
})),
|
|
49
45
|
index.h("sl-menu-item", { value: "CHECKING" }, props.text.checkingSelectItemLabel),
|
|
50
46
|
index.h("sl-menu-item", { value: "SAVINGS" }, props.text.savingsSelectItemLabel))),
|
|
51
47
|
},
|
|
52
48
|
2: {
|
|
53
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.bankAccountNumberLabel, name: "/bankAccountNumber", id: "bankAccountNumber", key: "bankAccountNumber", value: formState.bankAccountNumber, type: "text" }, (((
|
|
49
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.bankAccountNumberLabel, name: "/bankAccountNumber", id: "bankAccountNumber", key: "bankAccountNumber", value: formState.bankAccountNumber, type: "text" }, (((_g = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _g === void 0 ? void 0 : _g.bankAccountNumber) && {
|
|
54
50
|
class: "error-input",
|
|
55
51
|
helpText: getValidationErrorMessage({
|
|
56
|
-
type: (
|
|
52
|
+
type: (_j = (_h = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _h === void 0 ? void 0 : _h.bankAccountNumber) === null || _j === void 0 ? void 0 : _j.type,
|
|
57
53
|
label: props.text.bankAccountNumberLabel,
|
|
58
|
-
errorCode: (_q = (_p = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _p === void 0 ? void 0 : _p.bankAccountNumber) === null || _q === void 0 ? void 0 : _q.errorCode,
|
|
59
|
-
fieldName: "bankAccountNumber",
|
|
60
54
|
}),
|
|
61
55
|
})))),
|
|
62
56
|
},
|
|
63
57
|
3: {
|
|
64
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.ibanLabel, name: "/bankAccountNumber", id: "iban", key: "iban", type: "text", value: formState.bankAccountNumber }, (((
|
|
58
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.ibanLabel, name: "/bankAccountNumber", id: "iban", key: "iban", type: "text", value: formState.bankAccountNumber }, (((_k = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _k === void 0 ? void 0 : _k.bankAccountNumber) && {
|
|
65
59
|
class: "error-input",
|
|
66
60
|
helpText: getValidationErrorMessage({
|
|
67
|
-
type: (
|
|
61
|
+
type: (_m = (_l = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _l === void 0 ? void 0 : _l.bankAccountNumber) === null || _m === void 0 ? void 0 : _m.type,
|
|
68
62
|
label: props.text.ibanLabel,
|
|
69
|
-
errorCode: (_v = (_u = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _u === void 0 ? void 0 : _u.bankAccountNumber) === null || _v === void 0 ? void 0 : _v.errorCode,
|
|
70
|
-
fieldName: "bankAccountNumber",
|
|
71
63
|
}),
|
|
72
64
|
})))),
|
|
73
65
|
},
|
|
74
66
|
4: {
|
|
75
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.swiftCodeLabel, name: "/swiftCode", id: "swiftCode", key: "swiftCode", type: "text" }, (((
|
|
67
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.swiftCodeLabel, name: "/swiftCode", id: "swiftCode", key: "swiftCode", type: "text" }, (((_o = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _o === void 0 ? void 0 : _o.swiftCode) && {
|
|
76
68
|
class: "error-input",
|
|
77
69
|
helpText: getValidationErrorMessage({
|
|
78
|
-
type: (
|
|
70
|
+
type: (_q = (_p = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _p === void 0 ? void 0 : _p.swiftCode) === null || _q === void 0 ? void 0 : _q.type,
|
|
79
71
|
label: props.text.swiftCodeLabel,
|
|
80
|
-
errorCode: (_0 = (_z = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _z === void 0 ? void 0 : _z.swiftCode) === null || _0 === void 0 ? void 0 : _0.errorCode,
|
|
81
|
-
fieldName: "swiftCode",
|
|
82
72
|
}),
|
|
83
73
|
})))),
|
|
84
74
|
},
|
|
@@ -88,41 +78,35 @@ function getFormMap({ props, getValidationErrorMessage, bankCountry, }) {
|
|
|
88
78
|
defaultMessage: props.text.routingCodeLabel,
|
|
89
79
|
}, {
|
|
90
80
|
bankCountry,
|
|
91
|
-
}), name: "/routingCode", id: "routingCode", key: "routingCode", type: "text" }, (((
|
|
81
|
+
}), name: "/routingCode", id: "routingCode", key: "routingCode", type: "text" }, (((_r = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _r === void 0 ? void 0 : _r.routingCode) && {
|
|
92
82
|
class: "error-input",
|
|
93
83
|
helpText: getValidationErrorMessage({
|
|
94
|
-
type: (
|
|
84
|
+
type: (_t = (_s = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _s === void 0 ? void 0 : _s.routingCode) === null || _t === void 0 ? void 0 : _t.type,
|
|
95
85
|
label: global.intl.formatMessage({
|
|
96
86
|
id: "routingCodeErrorText",
|
|
97
87
|
defaultMessage: props.text.routingCodeLabel,
|
|
98
88
|
}, {
|
|
99
89
|
bankCountry,
|
|
100
90
|
}),
|
|
101
|
-
errorCode: (_5 = (_4 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _4 === void 0 ? void 0 : _4.routingCode) === null || _5 === void 0 ? void 0 : _5.errorCode,
|
|
102
|
-
fieldName: "routingCode",
|
|
103
91
|
}),
|
|
104
92
|
})))),
|
|
105
93
|
},
|
|
106
94
|
6: {
|
|
107
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.bankNameLabel, name: "/bankName", id: "bankName", key: "bankName", type: "text" }, (((
|
|
95
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.bankNameLabel, name: "/bankName", id: "bankName", key: "bankName", type: "text" }, (((_u = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _u === void 0 ? void 0 : _u.bankName) && {
|
|
108
96
|
class: "error-input",
|
|
109
97
|
helpText: getValidationErrorMessage({
|
|
110
|
-
type: (
|
|
98
|
+
type: (_w = (_v = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _v === void 0 ? void 0 : _v.bankName) === null || _w === void 0 ? void 0 : _w.type,
|
|
111
99
|
label: props.text.bankNameLabel,
|
|
112
|
-
errorCode: (_10 = (_9 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _9 === void 0 ? void 0 : _9.bankName) === null || _10 === void 0 ? void 0 : _10.errorCode,
|
|
113
|
-
fieldName: "bankName",
|
|
114
100
|
}),
|
|
115
101
|
})))),
|
|
116
102
|
},
|
|
117
103
|
7: {
|
|
118
104
|
input: [
|
|
119
|
-
index.h("sl-select", Object.assign({ required: true, label: props.text.classificationLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((
|
|
105
|
+
index.h("sl-select", Object.assign({ required: true, label: props.text.classificationLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((_x = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _x === void 0 ? void 0 : _x.beneficiaryClassification) && {
|
|
120
106
|
class: "error-input",
|
|
121
107
|
helpText: getValidationErrorMessage({
|
|
122
|
-
type: (
|
|
108
|
+
type: (_z = (_y = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _y === void 0 ? void 0 : _y.beneficiaryClassification) === null || _z === void 0 ? void 0 : _z.type,
|
|
123
109
|
label: props.text.classificationLabel,
|
|
124
|
-
errorCode: (_15 = (_14 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _14 === void 0 ? void 0 : _14.beneficiaryClassification) === null || _15 === void 0 ? void 0 : _15.errorCode,
|
|
125
|
-
fieldName: "beneficiaryClassification",
|
|
126
110
|
}),
|
|
127
111
|
})),
|
|
128
112
|
index.h("sl-menu-item", { value: "BUSINESS" }, props.text.businessSelectItemLabel),
|
|
@@ -133,122 +117,100 @@ function getFormMap({ props, getValidationErrorMessage, bankCountry, }) {
|
|
|
133
117
|
defaultMessage: props.text.taxPayerIdLabel,
|
|
134
118
|
}, {
|
|
135
119
|
bankCountry,
|
|
136
|
-
}), type: "text", name: "/beneficiaryTaxPayerId", id: "beneficiaryTaxPayerId", key: "beneficiaryTaxPayerId" }, (((
|
|
120
|
+
}), type: "text", name: "/beneficiaryTaxPayerId", id: "beneficiaryTaxPayerId", key: "beneficiaryTaxPayerId" }, (((_0 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _0 === void 0 ? void 0 : _0.beneficiaryTaxPayerId) && {
|
|
137
121
|
class: "error-input",
|
|
138
122
|
helpText: getValidationErrorMessage({
|
|
139
|
-
type: (
|
|
123
|
+
type: (_2 = (_1 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _1 === void 0 ? void 0 : _1.beneficiaryTaxPayerId) === null || _2 === void 0 ? void 0 : _2.type,
|
|
140
124
|
label: props.text.taxPayerIdLabel,
|
|
141
|
-
errorCode: (_20 = (_19 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _19 === void 0 ? void 0 : _19.taxPayerId) === null || _20 === void 0 ? void 0 : _20.errorCode,
|
|
142
|
-
fieldName: "taxPayerId",
|
|
143
125
|
}),
|
|
144
126
|
}))),
|
|
145
127
|
],
|
|
146
128
|
},
|
|
147
129
|
8: {
|
|
148
|
-
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.classificationCPFLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((
|
|
130
|
+
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.classificationCPFLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((_3 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _3 === void 0 ? void 0 : _3.beneficiaryClassification) && {
|
|
149
131
|
class: "error-input",
|
|
150
132
|
helpText: getValidationErrorMessage({
|
|
151
|
-
type: (
|
|
133
|
+
type: (_5 = (_4 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _4 === void 0 ? void 0 : _4.beneficiaryClassification) === null || _5 === void 0 ? void 0 : _5.type,
|
|
152
134
|
label: props.text.classificationCPFLabel,
|
|
153
|
-
errorCode: (_25 = (_24 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _24 === void 0 ? void 0 : _24.beneficiaryClassification) === null || _25 === void 0 ? void 0 : _25.errorCode,
|
|
154
|
-
fieldName: "beneficiaryClassification",
|
|
155
135
|
}),
|
|
156
136
|
})),
|
|
157
137
|
index.h("sl-menu-item", { value: "CPF" }, "CPF"),
|
|
158
138
|
index.h("sl-menu-item", { value: "CNPJ" }, "CNPJ"))),
|
|
159
139
|
},
|
|
160
140
|
9: {
|
|
161
|
-
input: (index.h("sl-input", Object.assign({ key: "patronymicName", required: true, label: props.text.patronymicNameLabel, name: "/patronymicName", id: "patronymicName", type: "text" }, (((
|
|
141
|
+
input: (index.h("sl-input", Object.assign({ key: "patronymicName", required: true, label: props.text.patronymicNameLabel, name: "/patronymicName", id: "patronymicName", type: "text" }, (((_6 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _6 === void 0 ? void 0 : _6.patronymicName) && {
|
|
162
142
|
class: "error-input",
|
|
163
143
|
helpText: getValidationErrorMessage({
|
|
164
|
-
type: (
|
|
144
|
+
type: (_8 = (_7 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _7 === void 0 ? void 0 : _7.patronymicName) === null || _8 === void 0 ? void 0 : _8.type,
|
|
165
145
|
label: props.text.patronymicNameLabel,
|
|
166
|
-
errorCode: (_30 = (_29 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _29 === void 0 ? void 0 : _29.patronymicName) === null || _30 === void 0 ? void 0 : _30.errorCode,
|
|
167
|
-
fieldName: "patronymicName",
|
|
168
146
|
}),
|
|
169
147
|
})))),
|
|
170
148
|
},
|
|
171
149
|
10: {
|
|
172
|
-
input: (index.h("sl-input", Object.assign({ key: "voCode", label: props.text.voCodeLabel, name: "/voCode", id: "voCode", type: "text" }, (((
|
|
150
|
+
input: (index.h("sl-input", Object.assign({ key: "voCode", label: props.text.voCodeLabel, name: "/voCode", id: "voCode", type: "text" }, (((_9 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _9 === void 0 ? void 0 : _9.voCode) && {
|
|
173
151
|
class: "error-input",
|
|
174
152
|
helpText: getValidationErrorMessage({
|
|
175
|
-
type: (
|
|
153
|
+
type: (_11 = (_10 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _10 === void 0 ? void 0 : _10.voCode) === null || _11 === void 0 ? void 0 : _11.type,
|
|
176
154
|
label: props.text.voCodeLabel,
|
|
177
|
-
errorCode: (_35 = (_34 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _34 === void 0 ? void 0 : _34.voCode) === null || _35 === void 0 ? void 0 : _35.errorCode,
|
|
178
|
-
fieldName: "voCode",
|
|
179
155
|
}),
|
|
180
156
|
})))),
|
|
181
157
|
},
|
|
182
158
|
11: {
|
|
183
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.agencyCodeLabel, name: "/agencyCode", id: "agencyCode", key: "agencyCode", type: "text" }, (((
|
|
159
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.agencyCodeLabel, name: "/agencyCode", id: "agencyCode", key: "agencyCode", type: "text" }, (((_12 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _12 === void 0 ? void 0 : _12.agencyCode) && {
|
|
184
160
|
class: "error-input",
|
|
185
161
|
helpText: getValidationErrorMessage({
|
|
186
|
-
type: (
|
|
162
|
+
type: (_14 = (_13 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _13 === void 0 ? void 0 : _13.agencyCode) === null || _14 === void 0 ? void 0 : _14.type,
|
|
187
163
|
label: props.text.agencyCodeLabel,
|
|
188
|
-
errorCode: (_40 = (_39 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _39 === void 0 ? void 0 : _39.agencyCode) === null || _40 === void 0 ? void 0 : _40.errorCode,
|
|
189
|
-
fieldName: "agencyCode",
|
|
190
164
|
}),
|
|
191
165
|
})))),
|
|
192
166
|
},
|
|
193
167
|
12: {
|
|
194
168
|
input: [
|
|
195
|
-
index.h("sl-input", Object.assign({ required: true, label: props.text.bankAddressLabel, name: "/bankAddress", id: "bankAddress", key: "bankAddress", type: "text" }, (((
|
|
169
|
+
index.h("sl-input", Object.assign({ required: true, label: props.text.bankAddressLabel, name: "/bankAddress", id: "bankAddress", key: "bankAddress", type: "text" }, (((_15 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _15 === void 0 ? void 0 : _15.bankAddress) && {
|
|
196
170
|
class: "error-input",
|
|
197
171
|
helpText: getValidationErrorMessage({
|
|
198
|
-
type: (
|
|
172
|
+
type: (_17 = (_16 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _16 === void 0 ? void 0 : _16.bankAddress) === null || _17 === void 0 ? void 0 : _17.type,
|
|
199
173
|
label: props.text.bankAddressLabel,
|
|
200
|
-
errorCode: (_45 = (_44 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _44 === void 0 ? void 0 : _44.bankAddress) === null || _45 === void 0 ? void 0 : _45.errorCode,
|
|
201
|
-
fieldName: "bankAddress",
|
|
202
174
|
}),
|
|
203
175
|
}))),
|
|
204
|
-
index.h("sl-input", Object.assign({ required: true, label: props.text.bankCityLabel, name: "/bankCity", id: "bankCity", key: "bankCity", type: "text" }, (((
|
|
176
|
+
index.h("sl-input", Object.assign({ required: true, label: props.text.bankCityLabel, name: "/bankCity", id: "bankCity", key: "bankCity", type: "text" }, (((_18 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _18 === void 0 ? void 0 : _18.bankCity) && {
|
|
205
177
|
class: "error-input",
|
|
206
178
|
helpText: getValidationErrorMessage({
|
|
207
|
-
type: (
|
|
179
|
+
type: (_20 = (_19 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _19 === void 0 ? void 0 : _19.bankCity) === null || _20 === void 0 ? void 0 : _20.type,
|
|
208
180
|
label: props.text.bankCityLabel,
|
|
209
|
-
errorCode: (_50 = (_49 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _49 === void 0 ? void 0 : _49.bankCity) === null || _50 === void 0 ? void 0 : _50.errorCode,
|
|
210
|
-
fieldName: "bankCity",
|
|
211
181
|
}),
|
|
212
182
|
}))),
|
|
213
|
-
index.h("sl-input", Object.assign({ required: true, label: props.text.bankStateLabel, name: "/bankState", id: "bankState", key: "bankState", type: "text" }, (((
|
|
183
|
+
index.h("sl-input", Object.assign({ required: true, label: props.text.bankStateLabel, name: "/bankState", id: "bankState", key: "bankState", type: "text" }, (((_21 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _21 === void 0 ? void 0 : _21.bankState) && {
|
|
214
184
|
class: "error-input",
|
|
215
185
|
helpText: getValidationErrorMessage({
|
|
216
|
-
type: (
|
|
186
|
+
type: (_23 = (_22 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _22 === void 0 ? void 0 : _22.bankState) === null || _23 === void 0 ? void 0 : _23.type,
|
|
217
187
|
label: props.text.bankStateLabel,
|
|
218
|
-
errorCode: (_55 = (_54 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _54 === void 0 ? void 0 : _54.bankState) === null || _55 === void 0 ? void 0 : _55.errorCode,
|
|
219
|
-
fieldName: "bankState",
|
|
220
188
|
}),
|
|
221
189
|
}))),
|
|
222
|
-
index.h("sl-input", Object.assign({ required: true, label: props.text.bankPostalCodeLabel, name: "/bankPostalCode", id: "bankPostalCode", key: "bankPostalCode", type: "text" }, (((
|
|
190
|
+
index.h("sl-input", Object.assign({ required: true, label: props.text.bankPostalCodeLabel, name: "/bankPostalCode", id: "bankPostalCode", key: "bankPostalCode", type: "text" }, (((_24 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _24 === void 0 ? void 0 : _24.bankPostalCode) && {
|
|
223
191
|
class: "error-input",
|
|
224
192
|
helpText: getValidationErrorMessage({
|
|
225
|
-
type: (
|
|
193
|
+
type: (_26 = (_25 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _25 === void 0 ? void 0 : _25.bankPostalCode) === null || _26 === void 0 ? void 0 : _26.type,
|
|
226
194
|
label: props.text.bankPostalCodeLabel,
|
|
227
|
-
errorCode: (_60 = (_59 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _59 === void 0 ? void 0 : _59.bankPostalCode) === null || _60 === void 0 ? void 0 : _60.errorCode,
|
|
228
|
-
fieldName: "bankPostalCode",
|
|
229
195
|
}),
|
|
230
196
|
}))),
|
|
231
197
|
],
|
|
232
198
|
},
|
|
233
199
|
13: {
|
|
234
|
-
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.branchCodeLabel, name: "/branchCode", id: "branchCode", key: "branchCode", type: "text" }, (((
|
|
200
|
+
input: (index.h("sl-input", Object.assign({ required: true, label: props.text.branchCodeLabel, name: "/branchCode", id: "branchCode", key: "branchCode", type: "text" }, (((_27 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _27 === void 0 ? void 0 : _27.branchCode) && {
|
|
235
201
|
class: "error-input",
|
|
236
202
|
helpText: getValidationErrorMessage({
|
|
237
|
-
type: (
|
|
203
|
+
type: (_29 = (_28 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _28 === void 0 ? void 0 : _28.branchCode) === null || _29 === void 0 ? void 0 : _29.type,
|
|
238
204
|
label: props.text.branchCodeLabel,
|
|
239
|
-
errorCode: (_65 = (_64 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _64 === void 0 ? void 0 : _64.branchCode) === null || _65 === void 0 ? void 0 : _65.errorCode,
|
|
240
|
-
fieldName: "branchCode",
|
|
241
205
|
}),
|
|
242
206
|
})))),
|
|
243
207
|
},
|
|
244
208
|
14: {
|
|
245
|
-
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.classificationLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((
|
|
209
|
+
input: (index.h("sl-select", Object.assign({ required: true, label: props.text.classificationLabel, name: "/beneficiaryClassification", id: "beneficiaryClassification", key: "beneficiaryClassification" }, (((_30 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _30 === void 0 ? void 0 : _30.beneficiaryClassification) && {
|
|
246
210
|
class: "error-input",
|
|
247
211
|
helpText: getValidationErrorMessage({
|
|
248
|
-
type: (
|
|
212
|
+
type: (_32 = (_31 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _31 === void 0 ? void 0 : _31.beneficiaryClassification) === null || _32 === void 0 ? void 0 : _32.type,
|
|
249
213
|
label: props.text.classificationLabel,
|
|
250
|
-
errorCode: (_70 = (_69 = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _69 === void 0 ? void 0 : _69.beneficiaryClassification) === null || _70 === void 0 ? void 0 : _70.errorCode,
|
|
251
|
-
fieldName: "beneficiaryClassification",
|
|
252
214
|
}),
|
|
253
215
|
})),
|
|
254
216
|
index.h("sl-menu-item", { value: "BUSINESS" }, props.text.businessSelectItemLabel),
|
|
@@ -841,95 +803,6 @@ const paypalFeeMap = {
|
|
|
841
803
|
const ACH_PAYMENT_METHOD = 3;
|
|
842
804
|
const WIRE_PAYMENT_METHOD = 5;
|
|
843
805
|
const PAYPAL_PAYMENT_METHOD = 7;
|
|
844
|
-
/**
|
|
845
|
-
* Maps GraphQL validation error field names to form field names.
|
|
846
|
-
*/
|
|
847
|
-
const API_FIELD_TO_FORM_FIELD = {
|
|
848
|
-
// bankProvinceState → form uses bankState
|
|
849
|
-
bankProvinceState: "bankState",
|
|
850
|
-
};
|
|
851
|
-
/**
|
|
852
|
-
* Maps Impact API error code paths (from validationErrors[].errorPath) to short,
|
|
853
|
-
* readable frontend error codes used in the ICU select props.
|
|
854
|
-
*/
|
|
855
|
-
const API_ERROR_PATH_TO_FRONTEND = {
|
|
856
|
-
// Beneficiary account name
|
|
857
|
-
"withdrawal.settings.error.empty_beneficiaryname": "empty",
|
|
858
|
-
"withdrawal.settings.error.invalid_character_beneficiaryname": "invalidCharacters",
|
|
859
|
-
"withdrawal.settings.error.numeric_beneficiaryname": "numeric",
|
|
860
|
-
"withdrawal_settings.error.beneficiaryname.size": "tooLong",
|
|
861
|
-
"withdrawal.settings.error.non_english_beneficiaryname": "nonEnglish",
|
|
862
|
-
"withdrawal_settings.error.business_beneficiaryname_match": "businessNameMismatch",
|
|
863
|
-
"withdrawal_settings.error.beneficiaryname_match": "nameMismatch",
|
|
864
|
-
"withdrawal_settings.error.business_checkpayeename_match": "businessPayeeMismatch",
|
|
865
|
-
"withdrawal_settings.error.checkpayeename_match": "payeeMismatch",
|
|
866
|
-
// Bank account number
|
|
867
|
-
"withdrawal.settings.error.accountnumber.empty": "empty",
|
|
868
|
-
"withdrawal.settings.error.accountnumber.uk": "invalidUk",
|
|
869
|
-
"withdrawal.settings.error.bankaccount.invalid": "invalid",
|
|
870
|
-
// IBAN
|
|
871
|
-
"withdrawal.settings.error.iban": "ibanEmpty",
|
|
872
|
-
"withdrawal.settings.error.iban.alphanumeric": "ibanAlphanumeric",
|
|
873
|
-
"withdrawal.settings.error.iban.invalid": "ibanInvalid",
|
|
874
|
-
"withdrawal.settings.error.iban.uk.country.mismatch": "ibanCountryMismatch",
|
|
875
|
-
// Routing code
|
|
876
|
-
"withdrawal.settings.error.bsbNumber": "invalidBsb",
|
|
877
|
-
"withdrawal.settings.error.sortcode": "invalidSortCode",
|
|
878
|
-
"withdrawal.settings.error.routingNumber": "empty",
|
|
879
|
-
"withdrawal.settings.error.routingcode": "invalid",
|
|
880
|
-
// SWIFT / BIC
|
|
881
|
-
"withdrawal.settings.error.bic": "empty",
|
|
882
|
-
"withdrawal.settings.error.bic.alphanumeric": "alphanumeric",
|
|
883
|
-
"withdrawal.settings.error.bic.invalid": "invalid",
|
|
884
|
-
// Bank account type
|
|
885
|
-
"global.error.invalid.accounttype": "empty",
|
|
886
|
-
// Bank name
|
|
887
|
-
"withdrawal.settings.error.bankName": "empty",
|
|
888
|
-
// Tax payer ID
|
|
889
|
-
"withdrawal.settings.error.taxPayerId": "empty",
|
|
890
|
-
"withdrawal.settings.error.taxPayerId.ar": "emptyAr",
|
|
891
|
-
"withdrawal.settings.error.taxPayerId.kr": "emptyKr",
|
|
892
|
-
"withdrawal.settings.error.taxPayerId.alphanumeric": "alphanumeric",
|
|
893
|
-
"withdrawal.settings.error.taxPayerId.alphanumeric.ar": "alphanumericAr",
|
|
894
|
-
"withdrawal.settings.error.taxPayerId.alphanumeric.kr": "alphanumericKr",
|
|
895
|
-
"withdrawal.settings.error.taxPayerId.invalid": "invalid",
|
|
896
|
-
"withdrawal.settings.error.taxPayerId.invalid.ar": "invalidAr",
|
|
897
|
-
"withdrawal.settings.error.taxPayerId.invalid.kr": "invalidKr",
|
|
898
|
-
"withdrawal.settings.error.taxPayerId.invalid.kzt": "invalidKzt",
|
|
899
|
-
"withdrawal.settings.error.taxPayerId.cnpj": "cnpjTooShort",
|
|
900
|
-
"withdrawal.settings.error.taxPayerId.cpf": "cpfTooShort",
|
|
901
|
-
// Patronymic name
|
|
902
|
-
"withdrawal.settings.error.patronymicName": "empty",
|
|
903
|
-
"withdrawal.settings.error.patronymicName.alphanumeric": "alphanumeric",
|
|
904
|
-
// VO code
|
|
905
|
-
"withdrawal.settings.error.voCode": "empty",
|
|
906
|
-
"withdrawal.settings.error.voCode.alphanumeric": "alphanumeric",
|
|
907
|
-
// Agency code
|
|
908
|
-
"withdrawal.settings.error.agencyCode": "empty",
|
|
909
|
-
"withdrawal.settings.error.agencyCode.alphanumeric": "alphanumeric",
|
|
910
|
-
"withdrawal.settings.error.agencyCode.length": "tooShort",
|
|
911
|
-
// Bank address fields
|
|
912
|
-
"withdrawal.settings.error.bankAddress": "empty",
|
|
913
|
-
"withdrawal.settings.error.bankCity": "empty",
|
|
914
|
-
"withdrawal.settings.error.bankProvinceState": "empty",
|
|
915
|
-
"withdrawal.settings.error.bankPostalCode": "empty",
|
|
916
|
-
// Branch code / name
|
|
917
|
-
"withdrawal.settings.error.branchCode": "invalid",
|
|
918
|
-
"withdrawal.settings.error.branchName": "empty",
|
|
919
|
-
// Classification code
|
|
920
|
-
"withdrawal.settings.error.classificationCode.invalid": "empty",
|
|
921
|
-
"withdrawal.settings.error.classificationCode.invalid.kzt": "invalidKzt",
|
|
922
|
-
// PayPal
|
|
923
|
-
"payment.error.email": "empty",
|
|
924
|
-
"payment.error.paypal_not_supported": "unsupportedCurrency",
|
|
925
|
-
"payment.error.email.invalid": "invalidEmail",
|
|
926
|
-
"payment.error.paypal_verification_incomplete": "verificationIncomplete",
|
|
927
|
-
// Payment schedule
|
|
928
|
-
"payment.error.no_threshold": "empty",
|
|
929
|
-
"payment.error.invalid_threshold": "invalid",
|
|
930
|
-
"payment.error.no_dayOfMonth": "empty",
|
|
931
|
-
"payment.error.invalid_dayOfMonth": "invalid",
|
|
932
|
-
};
|
|
933
806
|
function getFormInputs({ bitset, formMap }) {
|
|
934
807
|
// Convert bitset to binary representation
|
|
935
808
|
const binary = bitset.toString(2).padStart(Object.keys(formMap).length, "0");
|
|
@@ -953,7 +826,6 @@ const SAVE_WITHDRAWAL_SETTINGS = index_module.dist.gql `
|
|
|
953
826
|
validationErrors {
|
|
954
827
|
field
|
|
955
828
|
message
|
|
956
|
-
code
|
|
957
829
|
}
|
|
958
830
|
}
|
|
959
831
|
}
|
|
@@ -969,7 +841,6 @@ const UPDATE_WITHDRAWAL_SETTINGS = index_module.dist.gql `
|
|
|
969
841
|
validationErrors {
|
|
970
842
|
field
|
|
971
843
|
message
|
|
972
|
-
code
|
|
973
844
|
}
|
|
974
845
|
}
|
|
975
846
|
}
|
|
@@ -1142,13 +1013,10 @@ function useBankingInfoForm(props) {
|
|
|
1142
1013
|
else if (!success) {
|
|
1143
1014
|
console.error("Validation failed: ", validationErrors);
|
|
1144
1015
|
const mappedValidationErrors = validationErrors === null || validationErrors === void 0 ? void 0 : validationErrors.reduce((agg, error) => {
|
|
1145
|
-
const formField = API_FIELD_TO_FORM_FIELD[error.field] || error.field;
|
|
1146
|
-
const errorCode = API_ERROR_PATH_TO_FRONTEND[error.errorPath] || error.errorPath;
|
|
1147
1016
|
return {
|
|
1148
1017
|
...agg,
|
|
1149
|
-
[
|
|
1018
|
+
[error.field]: {
|
|
1150
1019
|
type: "invalid",
|
|
1151
|
-
errorCode,
|
|
1152
1020
|
},
|
|
1153
1021
|
};
|
|
1154
1022
|
}, {});
|
|
@@ -1563,156 +1431,6 @@ const BankingInfoForm = class {
|
|
|
1563
1431
|
* @uiName Information modal button text
|
|
1564
1432
|
*/
|
|
1565
1433
|
this.modalButtonText = "I understand, update my information";
|
|
1566
|
-
// ──────────────────────────────────────────────────────────────────
|
|
1567
|
-
// Per-field validation error messages
|
|
1568
|
-
// Each prop uses ICU select on {errorCode} to pick the right message.
|
|
1569
|
-
// Error codes are short frontend keys mapped from the API error codes.
|
|
1570
|
-
// The `other` branch displays the raw API message directly via {errorCode},
|
|
1571
|
-
// which is already human-readable English (e.g. "Invalid Routing Code").
|
|
1572
|
-
// ──────────────────────────────────────────────────────────────────
|
|
1573
|
-
/**
|
|
1574
|
-
* Error messages for the beneficiary / account holder name field.
|
|
1575
|
-
* Supports error codes: empty, invalidCharacters, numeric, tooLong,
|
|
1576
|
-
* nonEnglish, businessNameMismatch, nameMismatch, businessPayeeMismatch, payeeMismatch
|
|
1577
|
-
* @uiName Beneficiary account name error
|
|
1578
|
-
* @uiWidget textArea
|
|
1579
|
-
*/
|
|
1580
|
-
this.beneficiaryAccountNameError = "{errorCode, select, empty {Account holder name is required} invalidCharacters {Account holder name contains invalid characters} numeric {Account holder name cannot be purely numeric} tooLong {Account holder name must be 70 characters or fewer} nonEnglish {Account holder name must contain only English characters for this currency} businessNameMismatch {Beneficiary name must match the name on your tax document} nameMismatch {Beneficiary name must match the name on your tax document} businessPayeeMismatch {Payee name must match the name on your tax document} payeeMismatch {Payee name must match the name on your tax document} other {{errorCode}}}";
|
|
1581
|
-
/**
|
|
1582
|
-
* Error messages for the bank account number / IBAN field.
|
|
1583
|
-
* Supports error codes: empty, invalidUk, invalid, ibanEmpty,
|
|
1584
|
-
* ibanAlphanumeric, ibanInvalid, ibanCountryMismatch
|
|
1585
|
-
* @uiName Bank account number / IBAN error
|
|
1586
|
-
* @uiWidget textArea
|
|
1587
|
-
*/
|
|
1588
|
-
this.bankAccountNumberError = "{errorCode, select, empty {Account number is required} invalidUk {Please enter a valid UK account number} invalid {Account number is invalid} ibanEmpty {IBAN is required} ibanAlphanumeric {IBAN must contain only letters and numbers} ibanInvalid {IBAN is invalid} ibanCountryMismatch {UK accounts must use an IBAN starting with GB} other {{errorCode}}}";
|
|
1589
|
-
/**
|
|
1590
|
-
* Error messages for the routing code / sort code / BSB field.
|
|
1591
|
-
* Supports error codes: invalidBsb, invalidSortCode, empty, invalid
|
|
1592
|
-
* @uiName Routing code error
|
|
1593
|
-
* @uiWidget textArea
|
|
1594
|
-
*/
|
|
1595
|
-
this.routingCodeError = "{errorCode, select, invalidBsb {Please enter a valid BSB number} invalidSortCode {Please enter a valid sort code} empty {Routing number is required} invalid {Routing number is invalid} other {{errorCode}}}";
|
|
1596
|
-
/**
|
|
1597
|
-
* Error messages for the SWIFT / BIC code field.
|
|
1598
|
-
* Supports error codes: empty, alphanumeric, invalid
|
|
1599
|
-
* @uiName SWIFT code error
|
|
1600
|
-
* @uiWidget textArea
|
|
1601
|
-
*/
|
|
1602
|
-
this.swiftCodeError = "{errorCode, select, empty {SWIFT/BIC code is required} alphanumeric {SWIFT/BIC code must contain only letters and numbers} invalid {SWIFT/BIC code is invalid} other {{errorCode}}}";
|
|
1603
|
-
/**
|
|
1604
|
-
* Error messages for the bank account type field.
|
|
1605
|
-
* Supports error codes: empty
|
|
1606
|
-
* @uiName Bank account type error
|
|
1607
|
-
* @uiWidget textArea
|
|
1608
|
-
*/
|
|
1609
|
-
this.bankAccountTypeError = "{errorCode, select, empty {Bank account type is required} other {{errorCode}}}";
|
|
1610
|
-
/**
|
|
1611
|
-
* Error messages for the bank name field.
|
|
1612
|
-
* Supports error codes: empty
|
|
1613
|
-
* @uiName Bank name error
|
|
1614
|
-
* @uiWidget textArea
|
|
1615
|
-
*/
|
|
1616
|
-
this.bankNameError = "{errorCode, select, empty {Bank name is required} other {{errorCode}}}";
|
|
1617
|
-
/**
|
|
1618
|
-
* Error messages for the tax payer ID / classification entity field.
|
|
1619
|
-
* Supports error codes: empty, emptyAr, emptyKr, alphanumeric, alphanumericAr,
|
|
1620
|
-
* alphanumericKr, invalid, invalidAr, invalidKr, invalidKzt, cnpjTooShort, cpfTooShort
|
|
1621
|
-
* @uiName Tax payer ID error
|
|
1622
|
-
* @uiWidget textArea
|
|
1623
|
-
*/
|
|
1624
|
-
this.taxPayerIdError = "{errorCode, select, empty {Tax payer ID is required} emptyAr {CUIT/CUIL is required} emptyKr {Classification ID is required} alphanumeric {Tax payer ID must contain only letters and numbers} alphanumericAr {CUIT/CUIL must contain only letters and numbers} alphanumericKr {Classification ID must contain only letters and numbers} invalid {Tax payer ID is invalid} invalidAr {CUIT/CUIL must be 11 characters} invalidKr {Classification ID length is invalid} invalidKzt {Tax payer ID must be 12 characters for KZT} cnpjTooShort {CNPJ must be at least 14 characters} cpfTooShort {CPF must be at least 11 characters} other {{errorCode}}}";
|
|
1625
|
-
/**
|
|
1626
|
-
* Error messages for the patronymic name field.
|
|
1627
|
-
* Supports error codes: empty, alphanumeric
|
|
1628
|
-
* @uiName Patronymic name error
|
|
1629
|
-
* @uiWidget textArea
|
|
1630
|
-
*/
|
|
1631
|
-
this.patronymicNameError = "{errorCode, select, empty {Patronymic name is required} alphanumeric {Patronymic name must contain only letters and numbers} other {{errorCode}}}";
|
|
1632
|
-
/**
|
|
1633
|
-
* Error messages for the VO code field.
|
|
1634
|
-
* Supports error codes: empty, alphanumeric
|
|
1635
|
-
* @uiName VO code error
|
|
1636
|
-
* @uiWidget textArea
|
|
1637
|
-
*/
|
|
1638
|
-
this.voCodeError = "{errorCode, select, empty {VO code is required} alphanumeric {VO code must contain only letters and numbers} other {{errorCode}}}";
|
|
1639
|
-
/**
|
|
1640
|
-
* Error messages for the agency code field.
|
|
1641
|
-
* Supports error codes: empty, alphanumeric, tooShort
|
|
1642
|
-
* @uiName Agency code error
|
|
1643
|
-
* @uiWidget textArea
|
|
1644
|
-
*/
|
|
1645
|
-
this.agencyCodeError = "{errorCode, select, empty {Agency code is required} alphanumeric {Agency code must contain only letters and numbers} tooShort {Agency code must be at least 5 characters} other {{errorCode}}}";
|
|
1646
|
-
/**
|
|
1647
|
-
* Error messages for the bank address field.
|
|
1648
|
-
* Supports error codes: empty
|
|
1649
|
-
* @uiName Bank address error
|
|
1650
|
-
* @uiWidget textArea
|
|
1651
|
-
*/
|
|
1652
|
-
this.bankAddressError = "{errorCode, select, empty {Bank address is required} other {{errorCode}}}";
|
|
1653
|
-
/**
|
|
1654
|
-
* Error messages for the bank city field.
|
|
1655
|
-
* Supports error codes: empty
|
|
1656
|
-
* @uiName Bank city error
|
|
1657
|
-
* @uiWidget textArea
|
|
1658
|
-
*/
|
|
1659
|
-
this.bankCityError = "{errorCode, select, empty {Bank city is required} other {{errorCode}}}";
|
|
1660
|
-
/**
|
|
1661
|
-
* Error messages for the bank province/state field.
|
|
1662
|
-
* Supports error codes: empty
|
|
1663
|
-
* @uiName Bank province/state error
|
|
1664
|
-
* @uiWidget textArea
|
|
1665
|
-
*/
|
|
1666
|
-
this.bankStateError = "{errorCode, select, empty {Bank province/state is required} other {{errorCode}}}";
|
|
1667
|
-
/**
|
|
1668
|
-
* Error messages for the bank postal code field.
|
|
1669
|
-
* Supports error codes: empty
|
|
1670
|
-
* @uiName Bank postal code error
|
|
1671
|
-
* @uiWidget textArea
|
|
1672
|
-
*/
|
|
1673
|
-
this.bankPostalCodeError = "{errorCode, select, empty {Bank postal code is required} other {{errorCode}}}";
|
|
1674
|
-
/**
|
|
1675
|
-
* Error messages for the branch code field.
|
|
1676
|
-
* Supports error codes: invalid
|
|
1677
|
-
* @uiName Branch code error
|
|
1678
|
-
* @uiWidget textArea
|
|
1679
|
-
*/
|
|
1680
|
-
this.branchCodeError = "{errorCode, select, invalid {Branch code is invalid} other {{errorCode}}}";
|
|
1681
|
-
/**
|
|
1682
|
-
* Error messages for the branch name field.
|
|
1683
|
-
* Supports error codes: empty
|
|
1684
|
-
* @uiName Branch name error
|
|
1685
|
-
* @uiWidget textArea
|
|
1686
|
-
*/
|
|
1687
|
-
this.branchNameError = "{errorCode, select, empty {Branch name is required} other {{errorCode}}}";
|
|
1688
|
-
/**
|
|
1689
|
-
* Error messages for the classification code field.
|
|
1690
|
-
* Supports error codes: empty, invalidKzt
|
|
1691
|
-
* @uiName Classification code error
|
|
1692
|
-
* @uiWidget textArea
|
|
1693
|
-
*/
|
|
1694
|
-
this.classificationCodeError = "{errorCode, select, empty {Classification code is required} invalidKzt {Classification code must be exactly 2 characters} other {{errorCode}}}";
|
|
1695
|
-
/**
|
|
1696
|
-
* Error messages for the PayPal email field.
|
|
1697
|
-
* Supports error codes: empty, unsupportedCurrency, invalidEmail, verificationIncomplete
|
|
1698
|
-
* @uiName PayPal email error
|
|
1699
|
-
* @uiWidget textArea
|
|
1700
|
-
*/
|
|
1701
|
-
this.paypalEmailError = "{errorCode, select, empty {PayPal email is required} unsupportedCurrency {PayPal is not supported for this currency} invalidEmail {Please enter a valid email address} verificationIncomplete {PayPal verification is not complete} other {{errorCode}}}";
|
|
1702
|
-
/**
|
|
1703
|
-
* Error messages for the payment threshold field.
|
|
1704
|
-
* Supports error codes: empty, invalid
|
|
1705
|
-
* @uiName Payment threshold error
|
|
1706
|
-
* @uiWidget textArea
|
|
1707
|
-
*/
|
|
1708
|
-
this.paymentThresholdError = "{errorCode, select, empty {Payment threshold is required} invalid {Payment threshold is invalid} other {{errorCode}}}";
|
|
1709
|
-
/**
|
|
1710
|
-
* Error messages for the payment day field.
|
|
1711
|
-
* Supports error codes: empty, invalid
|
|
1712
|
-
* @uiName Payment day error
|
|
1713
|
-
* @uiWidget textArea
|
|
1714
|
-
*/
|
|
1715
|
-
this.paymentDayError = "{errorCode, select, empty {Payment day is required} invalid {Payment day must be the 1st or the 15th} other {{errorCode}}}";
|
|
1716
1434
|
domContextHooks_module.h$1(this);
|
|
1717
1435
|
}
|
|
1718
1436
|
disconnectedCallback() { }
|
|
@@ -1726,54 +1444,17 @@ const BankingInfoForm = class {
|
|
|
1726
1444
|
loadingErrorAlertDescription: props.loadingErrorAlertDescription,
|
|
1727
1445
|
loadingErrorAlertHeader: props.loadingErrorAlertHeader,
|
|
1728
1446
|
},
|
|
1729
|
-
errorMessages: {
|
|
1730
|
-
beneficiaryAccountName: props.beneficiaryAccountNameError,
|
|
1731
|
-
bankAccountNumber: props.bankAccountNumberError,
|
|
1732
|
-
routingCode: props.routingCodeError,
|
|
1733
|
-
swiftCode: props.swiftCodeError,
|
|
1734
|
-
bankAccountType: props.bankAccountTypeError,
|
|
1735
|
-
bankName: props.bankNameError,
|
|
1736
|
-
taxPayerId: props.taxPayerIdError,
|
|
1737
|
-
patronymicName: props.patronymicNameError,
|
|
1738
|
-
voCode: props.voCodeError,
|
|
1739
|
-
agencyCode: props.agencyCodeError,
|
|
1740
|
-
bankAddress: props.bankAddressError,
|
|
1741
|
-
bankCity: props.bankCityError,
|
|
1742
|
-
bankState: props.bankStateError,
|
|
1743
|
-
bankPostalCode: props.bankPostalCodeError,
|
|
1744
|
-
branchCode: props.branchCodeError,
|
|
1745
|
-
branchName: props.branchNameError,
|
|
1746
|
-
beneficiaryClassification: props.classificationCodeError,
|
|
1747
|
-
paypalEmailAddress: props.paypalEmailError,
|
|
1748
|
-
paymentThreshold: props.paymentThresholdError,
|
|
1749
|
-
paymentDay: props.paymentDayError,
|
|
1750
|
-
},
|
|
1751
1447
|
};
|
|
1752
1448
|
}
|
|
1753
1449
|
render() {
|
|
1754
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0
|
|
1450
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
|
|
1755
1451
|
const props = index_module.isDemo()
|
|
1756
1452
|
? useDemoBankingInfoForm(this)
|
|
1757
1453
|
: useBankingInfoForm(this);
|
|
1758
1454
|
const { errors } = props.states.formState;
|
|
1759
1455
|
const fieldRequiredError = this.fieldRequiredError;
|
|
1760
1456
|
const fieldInvalidError = this.fieldInvalidError;
|
|
1761
|
-
function getValidationErrorMessage({ type, label,
|
|
1762
|
-
var _a;
|
|
1763
|
-
// If we have a specific error code from the API, try to use
|
|
1764
|
-
// the per-field ICU error message template for a rich message
|
|
1765
|
-
if (type === "invalid" && errorCode && fieldName) {
|
|
1766
|
-
const errorTemplate = (_a = props.text.errorMessages) === null || _a === void 0 ? void 0 : _a[fieldName];
|
|
1767
|
-
if (errorTemplate) {
|
|
1768
|
-
return global.intl.formatMessage({
|
|
1769
|
-
id: `fieldError-${fieldName}-${errorCode}`,
|
|
1770
|
-
defaultMessage: errorTemplate,
|
|
1771
|
-
}, {
|
|
1772
|
-
errorCode,
|
|
1773
|
-
fieldName: label,
|
|
1774
|
-
});
|
|
1775
|
-
}
|
|
1776
|
-
}
|
|
1457
|
+
function getValidationErrorMessage({ type, label, }) {
|
|
1777
1458
|
if (type === "required") {
|
|
1778
1459
|
return global.intl.formatMessage({
|
|
1779
1460
|
id: `requiredText-${label}`,
|
|
@@ -1856,45 +1537,37 @@ const BankingInfoForm = class {
|
|
|
1856
1537
|
helpText: getValidationErrorMessage({
|
|
1857
1538
|
type: (_c = (_b = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _b === void 0 ? void 0 : _b.bankCountry) === null || _c === void 0 ? void 0 : _c.type,
|
|
1858
1539
|
label: props.text.bankLocationLabel,
|
|
1859
|
-
errorCode: (_e = (_d = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _d === void 0 ? void 0 : _d.bankCountry) === null || _e === void 0 ? void 0 : _e.errorCode,
|
|
1860
|
-
fieldName: "bankCountry",
|
|
1861
1540
|
}),
|
|
1862
1541
|
})), index.h("sl-input", { disabled: props.states.saveLoading, class: sheet.classes.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
|
|
1863
1542
|
// Stop shoelace intercepting key presses
|
|
1864
1543
|
e.stopPropagation();
|
|
1865
1544
|
}, "onSl-input": (e) => {
|
|
1866
1545
|
props.callbacks.setCountrySearch(e.target.value);
|
|
1867
|
-
} }), (
|
|
1868
|
-
|
|
1546
|
+
} }), (_d = props.states.countries) === null || _d === void 0 ? void 0 :
|
|
1547
|
+
_d.map((country) => {
|
|
1869
1548
|
return (index.h("sl-menu-item", { value: country.countryCode }, country.displayName));
|
|
1870
|
-
}), (
|
|
1871
|
-
|
|
1549
|
+
}), (_f = (_e = props.states) === null || _e === void 0 ? void 0 : _e.allCountries) === null || _f === void 0 ? void 0 :
|
|
1550
|
+
_f.map((c) => (index.h("sl-menu-item", { value: c.countryCode, style: { display: "none" } }, c.displayName))))),
|
|
1872
1551
|
paymentMethodSlot: (index.h("sl-input", { key: "paymentMethod", label: props.text.paymentMethod, placeholder: props.states.paymentMethodFeeLabel, disabled: true })),
|
|
1873
|
-
paymentThresholdSelectSlot: (index.h("sl-select", Object.assign({ required: true, disabled: props.states.saveLoading, label: props.text.paymentThresholdSelectLabel, name: "/paymentThreshold", id: "paymentThreshold", value: ((
|
|
1552
|
+
paymentThresholdSelectSlot: (index.h("sl-select", Object.assign({ required: true, disabled: props.states.saveLoading, label: props.text.paymentThresholdSelectLabel, name: "/paymentThreshold", id: "paymentThreshold", value: ((_h = (_g = props.states) === null || _g === void 0 ? void 0 : _g.formState) === null || _h === void 0 ? void 0 : _h.paymentThreshold) || "" }, (((_j = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _j === void 0 ? void 0 : _j.paymentThreshold) && {
|
|
1874
1553
|
class: "error-input",
|
|
1875
1554
|
helpText: getValidationErrorMessage({
|
|
1876
|
-
type: (
|
|
1555
|
+
type: (_l = (_k = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _k === void 0 ? void 0 : _k.paymentThreshold) === null || _l === void 0 ? void 0 : _l.type,
|
|
1877
1556
|
label: props.text.paymentThresholdSelectLabel,
|
|
1878
|
-
errorCode: (_q = (_p = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _p === void 0 ? void 0 : _p.paymentThreshold) === null || _q === void 0 ? void 0 : _q.errorCode,
|
|
1879
|
-
fieldName: "paymentThreshold",
|
|
1880
1557
|
}),
|
|
1881
1558
|
})), props.states.thresholds.map((t) => (index.h("sl-menu-item", { value: t }, `${props.states.currency}${t}`))))),
|
|
1882
|
-
paymentFixedDaySelectSlot: (index.h("sl-select", Object.assign({ required: true, disabled: props.states.saveLoading, label: props.text.paymentDaySelectLabel, value: ((
|
|
1559
|
+
paymentFixedDaySelectSlot: (index.h("sl-select", Object.assign({ required: true, disabled: props.states.saveLoading, label: props.text.paymentDaySelectLabel, value: ((_o = (_m = props.states) === null || _m === void 0 ? void 0 : _m.formState) === null || _o === void 0 ? void 0 : _o.paymentDay) || "", name: "/paymentDay", id: "paymentDay" }, (((_p = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _p === void 0 ? void 0 : _p.paymentDay) && {
|
|
1883
1560
|
class: "error-input",
|
|
1884
1561
|
helpText: getValidationErrorMessage({
|
|
1885
|
-
type: (
|
|
1562
|
+
type: (_r = (_q = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _q === void 0 ? void 0 : _q.paymentDay) === null || _r === void 0 ? void 0 : _r.type,
|
|
1886
1563
|
label: props.text.paymentDaySelectLabel,
|
|
1887
|
-
errorCode: (_x = (_w = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _w === void 0 ? void 0 : _w.paymentDay) === null || _x === void 0 ? void 0 : _x.errorCode,
|
|
1888
|
-
fieldName: "paymentDay",
|
|
1889
1564
|
}),
|
|
1890
1565
|
})), index.h("sl-menu-item", { value: "1" }, props.text.paymentDayFirstOfMonthLabelText), index.h("sl-menu-item", { value: "15" }, props.text.paymentDayFifteenthOfMonthLabelText))),
|
|
1891
|
-
paypalInputSlot: (index.h("sl-input", Object.assign({ required: true, disabled: props.states.saveLoading, value: ((
|
|
1566
|
+
paypalInputSlot: (index.h("sl-input", Object.assign({ required: true, disabled: props.states.saveLoading, value: ((_t = (_s = props.states) === null || _s === void 0 ? void 0 : _s.formState) === null || _t === void 0 ? void 0 : _t.paypalEmailAddress) || "", label: props.text.payPalInputLabel, key: "paypalEmailAddress", name: "/paypalEmailAddress", id: "paypalEmailAddress", type: "text" }, (((_w = (_v = (_u = props.states.formState) === null || _u === void 0 ? void 0 : _u.errors) === null || _v === void 0 ? void 0 : _v.inputErrors) === null || _w === void 0 ? void 0 : _w.paypalEmailAddress) && {
|
|
1892
1567
|
class: "error-input",
|
|
1893
1568
|
helpText: getValidationErrorMessage({
|
|
1894
|
-
type: (
|
|
1569
|
+
type: (_0 = (_z = (_y = (_x = props.states.formState) === null || _x === void 0 ? void 0 : _x.errors) === null || _y === void 0 ? void 0 : _y.inputErrors) === null || _z === void 0 ? void 0 : _z.paypalEmailAddress) === null || _0 === void 0 ? void 0 : _0.type,
|
|
1895
1570
|
label: props.text.payPalInputLabel,
|
|
1896
|
-
errorCode: (_10 = (_9 = (_8 = (_7 = props.states.formState) === null || _7 === void 0 ? void 0 : _7.errors) === null || _8 === void 0 ? void 0 : _8.inputErrors) === null || _9 === void 0 ? void 0 : _9.paypalEmailAddress) === null || _10 === void 0 ? void 0 : _10.errorCode,
|
|
1897
|
-
fieldName: "paypalEmailAddress",
|
|
1898
1571
|
}),
|
|
1899
1572
|
})))),
|
|
1900
1573
|
} })));
|
|
@@ -3143,7 +2816,7 @@ const IndirectTaxForm = class {
|
|
|
3143
2816
|
/**
|
|
3144
2817
|
* @uiName Indirect tax number field label
|
|
3145
2818
|
*/
|
|
3146
|
-
this.indirectTaxNumber = "{taxType, select, GST {GST number} HST {HST number} VAT {VAT number} CT {CT number} SST {SST number} GENERAL {Indirect tax number}}";
|
|
2819
|
+
this.indirectTaxNumber = "{taxType, select, GST {GST number} HST {HST number} VAT {VAT number} CT {CT number} SST {SST number} GENERAL {Indirect tax number} other {Tax number}}";
|
|
3147
2820
|
/**
|
|
3148
2821
|
* Displayed to participants registered for QST.
|
|
3149
2822
|
* @uiName QST number field label
|
|
@@ -3182,7 +2855,7 @@ const IndirectTaxForm = class {
|
|
|
3182
2855
|
/**
|
|
3183
2856
|
* @uiName Missing indirect tax number error message
|
|
3184
2857
|
*/
|
|
3185
|
-
this.indirectTaxNumberError = "{taxType, select, GST {GST number} HST {HST number} VAT {VAT number} CT {CT number} SST {SST number} GENERAL {Indirect tax number}} is required";
|
|
2858
|
+
this.indirectTaxNumberError = "{taxType, select, GST {GST number} HST {HST number} VAT {VAT number} CT {CT number} SST {SST number} GENERAL {Indirect tax number} other {Tax number}} is required";
|
|
3186
2859
|
/**
|
|
3187
2860
|
* Placeholder text displayed in the country search dropdown
|
|
3188
2861
|
* @uiName Country field placeholder text
|
|
@@ -3993,7 +3666,7 @@ const PayoutDetailsCard = class {
|
|
|
3993
3666
|
* Badge text indicating payout status
|
|
3994
3667
|
* @uiName Payout badge status text
|
|
3995
3668
|
*/
|
|
3996
|
-
this.statusBadgeText = "{badgeText, select, payoutToday {Payout Today} nextPayout {Next Payout} }";
|
|
3669
|
+
this.statusBadgeText = "{badgeText, select, payoutToday {Payout Today} nextPayout {Next Payout} other {Failed}}";
|
|
3997
3670
|
/**
|
|
3998
3671
|
* Display participants' payout preference on the payout information card, indicating the balance at which they want to get paid.
|
|
3999
3672
|
* @uiName Payout schedule by threshold text
|
|
@@ -5047,7 +4720,7 @@ const TaxAndCashDashboard = class {
|
|
|
5047
4720
|
/**
|
|
5048
4721
|
* @uiName Payout status badge
|
|
5049
4722
|
*/
|
|
5050
|
-
this.statusBadgeText = "{badgeText, select, payoutToday {Payout Today} nextPayout {Next Payout} }";
|
|
4723
|
+
this.statusBadgeText = "{badgeText, select, payoutToday {Payout Today} nextPayout {Next Payout} other {Failed} }";
|
|
5051
4724
|
/**
|
|
5052
4725
|
* Display participants' payout preference on the payout information card, indicating the balance at which they want to get paid.
|
|
5053
4726
|
* @uiName Payout schedule by threshold text
|