tg-core-components 5.2.1-history-time-label.0 → 5.3.0-master.1
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/es/components/AcceptUpdatedTaC/index.js +8 -3
- package/es/components/Checkbox/index.js +93 -0
- package/es/components/Deposit/CardInput/index.js +1 -3
- package/es/components/Input/index.js +222 -22
- package/es/components/InputWrapper/index.js +69 -0
- package/es/components/Notification.js +4 -4
- package/es/components/Select/index.js +202 -64
- package/es/components/Select/test.js +111 -0
- package/es/index.js +2 -1
- package/es/lib/utils/translate.js +1 -8
- package/es/widgets/AccountDetail/index.js +53 -77
- package/es/widgets/ActivateWidget/index.js +59 -293
- package/es/widgets/BonusWidget/BonusCode.js +24 -17
- package/es/widgets/BonusWidget/index.js +83 -45
- package/es/widgets/Cashier/Deposit/PaymentForm/NewTab.js +28 -0
- package/es/widgets/Cashier/Deposit/PaymentForm/index.js +6 -2
- package/es/widgets/CashierAccordion/Deposit/BonusCodeInput/index.js +9 -6
- package/es/widgets/CashierAccordion/Deposit/DepositWidget/index.js +19 -29
- package/es/widgets/CashierAccordion/Payment/PaymentAccountForms/index.js +163 -347
- package/es/widgets/CashierAccordion/Payment/PaymentAccountParser.js +0 -6
- package/es/widgets/CashierAccordion/Withdraw/WithdrawWidget/index.js +8 -22
- package/es/widgets/ChangePassword/index.js +53 -40
- package/es/widgets/HistoryWidget/index.js +69 -51
- package/es/widgets/HistoryWidget/message.js +17 -20
- package/es/widgets/RequestResetPassword/index.js +15 -14
- package/es/widgets/ResetPassword/index.js +22 -18
- package/es/widgets/ResponsibleGamingAccordion/LimitStatus/index.js +5 -2
- package/es/widgets/ResponsibleGamingAccordion/PeriodItemContent/index.js +1 -2
- package/es/widgets/ResponsibleGamingSingleSignUp/AmountItem/index.js +1 -2
- package/es/widgets/ResponsibleGamingWidget/Timespan.js +14 -24
- package/es/widgets/ResponsibleGamingWidget/helpers.js +2 -2
- package/es/widgets/ResponsibleGamingWidget/validate.js +1 -1
- package/es/widgets/Settings/index.js +2 -2
- package/es/widgets/SignIn/SignInForm.js +4 -6
- package/es/widgets/SignIn/index.js +21 -21
- package/es/widgets/SignUp/ContactInfoStep.js +5 -6
- package/es/widgets/SportsbookSettings/index.js +10 -24
- package/es/widgets/Subscriptions/index.js +3 -5
- package/lib/components/AcceptUpdatedTaC/index.js +11 -3
- package/lib/components/Checkbox/index.js +106 -0
- package/lib/components/Deposit/CardInput/index.js +1 -3
- package/lib/components/Input/index.js +223 -26
- package/lib/components/InputWrapper/index.js +85 -0
- package/lib/components/Notification.js +3 -3
- package/lib/components/Select/index.js +209 -63
- package/lib/components/Select/test.js +121 -0
- package/lib/index.js +9 -4
- package/lib/lib/utils/translate.js +1 -8
- package/lib/widgets/AccountDetail/index.js +53 -86
- package/lib/widgets/ActivateWidget/index.js +58 -305
- package/lib/widgets/BonusWidget/BonusCode.js +24 -20
- package/lib/widgets/BonusWidget/index.js +85 -44
- package/lib/widgets/Cashier/Deposit/PaymentForm/NewTab.js +44 -0
- package/lib/widgets/Cashier/Deposit/PaymentForm/index.js +9 -2
- package/lib/widgets/CashierAccordion/Deposit/BonusCodeInput/index.js +13 -7
- package/lib/widgets/CashierAccordion/Deposit/DepositWidget/index.js +22 -32
- package/lib/widgets/CashierAccordion/Payment/PaymentAccountForms/index.js +195 -378
- package/lib/widgets/CashierAccordion/Payment/PaymentAccountParser.js +0 -6
- package/lib/widgets/CashierAccordion/Withdraw/WithdrawWidget/index.js +10 -24
- package/lib/widgets/ChangePassword/index.js +53 -43
- package/lib/widgets/HistoryWidget/index.js +69 -51
- package/lib/widgets/HistoryWidget/message.js +17 -20
- package/lib/widgets/RequestResetPassword/index.js +15 -17
- package/lib/widgets/ResetPassword/index.js +25 -21
- package/lib/widgets/ResponsibleGamingAccordion/LimitStatus/index.js +5 -2
- package/lib/widgets/ResponsibleGamingAccordion/PeriodItemContent/index.js +1 -2
- package/lib/widgets/ResponsibleGamingSingleSignUp/AmountItem/index.js +1 -2
- package/lib/widgets/ResponsibleGamingWidget/Timespan.js +14 -24
- package/lib/widgets/ResponsibleGamingWidget/helpers.js +2 -2
- package/lib/widgets/ResponsibleGamingWidget/validate.js +1 -1
- package/lib/widgets/Settings/index.js +6 -6
- package/lib/widgets/SignIn/SignInForm.js +7 -6
- package/lib/widgets/SignIn/index.js +25 -25
- package/lib/widgets/SignUp/ContactInfoStep.js +8 -6
- package/lib/widgets/SportsbookSettings/index.js +10 -24
- package/lib/widgets/Subscriptions/index.js +3 -11
- package/package.json +8 -3
- package/es/components/Input/BirthdateInput.js +0 -171
- package/es/components/Input/Checkbox.js +0 -51
- package/es/components/Input/Input.js +0 -73
- package/es/components/Input/PasswordInput.js +0 -84
- package/es/components/Input/PhoneNumberInput.js +0 -110
- package/es/components/Input/input.test.js +0 -80
- package/es/components/Input/old-input.test.js +0 -100
- package/es/components/common.js +0 -339
- package/lib/components/Input/BirthdateInput.js +0 -192
- package/lib/components/Input/Checkbox.js +0 -65
- package/lib/components/Input/Input.js +0 -87
- package/lib/components/Input/PasswordInput.js +0 -101
- package/lib/components/Input/PhoneNumberInput.js +0 -127
- package/lib/components/Input/input.test.js +0 -89
- package/lib/components/Input/old-input.test.js +0 -107
- package/lib/components/common.js +0 -359
|
@@ -1,18 +1,15 @@
|
|
|
1
1
|
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
|
|
2
2
|
|
|
3
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
4
|
-
|
|
5
3
|
import React from 'react';
|
|
6
4
|
import { injectIntl } from 'react-intl';
|
|
7
5
|
import identity from 'lodash/identity';
|
|
6
|
+
import Input from '../../../../components/Deposit/TextInput';
|
|
7
|
+
import Select from '../../../../components/Deposit/Select';
|
|
8
8
|
import * as Parser from '../../Payment/PaymentAccountParser';
|
|
9
|
+
import CardInput from '../../../../components/Deposit/CardInput';
|
|
9
10
|
import astroPayBankTransaltions from './astroPayBankTransaltions';
|
|
10
11
|
import getByPath from 'lodash/get';
|
|
11
12
|
import translate from '../../../../lib/utils/translate';
|
|
12
|
-
import Input from '../../../../components/Input';
|
|
13
|
-
import Select from '../../../../components/Select';
|
|
14
|
-
|
|
15
|
-
import Payment from 'payment';
|
|
16
13
|
|
|
17
14
|
var injectMethod = function injectMethod(newProps, BaseComponent) {
|
|
18
15
|
return function (props) {
|
|
@@ -20,57 +17,27 @@ var injectMethod = function injectMethod(newProps, BaseComponent) {
|
|
|
20
17
|
};
|
|
21
18
|
};
|
|
22
19
|
|
|
23
|
-
var formatCreditCardNumber = function formatCreditCardNumber(value) {
|
|
24
|
-
value = value.replace(/[^\d|\*]/g, '');
|
|
25
|
-
var issuer = Payment.fns.cardType(value);
|
|
26
|
-
switch (issuer) {
|
|
27
|
-
case 'amex':
|
|
28
|
-
value = value.slice(0, 4) + ' ' + value.slice(4, 10) + ' ' + value.slice(10, 15);
|
|
29
|
-
break;
|
|
30
|
-
case 'dinersclub':
|
|
31
|
-
value = value.slice(0, 4) + ' ' + value.slice(4, 8) + ' ' + value.slice(8, 12) + ' ' + value.slice(12, 14);
|
|
32
|
-
break;
|
|
33
|
-
default:
|
|
34
|
-
value = value.slice(0, 4) + ' ' + value.slice(4, 8) + ' ' + value.slice(8, 12) + ' ' + value.slice(12, 16);
|
|
35
|
-
break;
|
|
36
|
-
}
|
|
37
|
-
return value.trim();
|
|
38
|
-
};
|
|
39
|
-
|
|
40
20
|
var Creditcard = function Creditcard(_ref) {
|
|
41
21
|
var account = _ref.account,
|
|
42
22
|
intl = _ref.intl,
|
|
43
23
|
method = _ref.method,
|
|
44
|
-
provider = _ref.provider
|
|
45
|
-
change = _ref.change,
|
|
46
|
-
values = _ref.values;
|
|
24
|
+
provider = _ref.provider;
|
|
47
25
|
|
|
48
26
|
return React.createElement(
|
|
49
27
|
'div',
|
|
50
|
-
|
|
51
|
-
React.createElement(
|
|
28
|
+
{ className: 'payment-account-info' },
|
|
29
|
+
React.createElement(CardInput, {
|
|
30
|
+
className: 'layout-item-12',
|
|
52
31
|
disabled: account.accountId,
|
|
53
|
-
transform: function transform(creditCardNumber) {
|
|
54
|
-
return formatCreditCardNumber(creditCardNumber);
|
|
55
|
-
},
|
|
56
|
-
value: values['cardNumber'],
|
|
57
|
-
onChange: function onChange(e, creditCardNumber) {
|
|
58
|
-
return change && change('cardNumber', creditCardNumber);
|
|
59
|
-
},
|
|
60
32
|
name: 'cardNumber',
|
|
61
33
|
label: translate({ id: 'cashier.details.cardNumber' }, intl),
|
|
62
34
|
required: !account.accountId,
|
|
63
|
-
|
|
35
|
+
type: 'number',
|
|
64
36
|
autocomplete: 'cc-number',
|
|
65
37
|
autoFocus: !account.accountId
|
|
66
38
|
}),
|
|
67
|
-
React.createElement(
|
|
39
|
+
React.createElement(CardInput, {
|
|
68
40
|
disabled: account.accountId,
|
|
69
|
-
value: values['cardHolder'],
|
|
70
|
-
onChange: function onChange(e, cardHolder) {
|
|
71
|
-
return change && change('cardHolder', cardHolder);
|
|
72
|
-
},
|
|
73
|
-
pattern: '[^0-9]*',
|
|
74
41
|
name: 'cardHolder',
|
|
75
42
|
type: 'cardHolder',
|
|
76
43
|
autocomplete: 'cc-name',
|
|
@@ -80,17 +47,9 @@ var Creditcard = function Creditcard(_ref) {
|
|
|
80
47
|
React.createElement(
|
|
81
48
|
'div',
|
|
82
49
|
{ className: 'layout-item' },
|
|
83
|
-
React.createElement(
|
|
50
|
+
React.createElement(CardInput, {
|
|
51
|
+
className: method === 'deposit' ? 'layout-item-6' : 'layout-item-12',
|
|
84
52
|
name: 'expiryDate',
|
|
85
|
-
pattern: '(?:0[1-9]|1[0-2])/[0-9]{2}',
|
|
86
|
-
value: values['expiryDate'],
|
|
87
|
-
onChange: function onChange(e, expiryDate) {
|
|
88
|
-
return change && change('expiryDate', expiryDate);
|
|
89
|
-
},
|
|
90
|
-
transform: function transform(expirationDate) {
|
|
91
|
-
expirationDate = expirationDate.replace(/\D+/g, '');
|
|
92
|
-
return expirationDate.length >= 3 ? expirationDate.slice(0, 2) + '/' + expirationDate.slice(2, 4) : expirationDate;
|
|
93
|
-
},
|
|
94
53
|
disabled: account.accountId,
|
|
95
54
|
label: translate({ id: 'cashier.details.validThruDate' }, intl),
|
|
96
55
|
required: !account.accountId,
|
|
@@ -98,16 +57,9 @@ var Creditcard = function Creditcard(_ref) {
|
|
|
98
57
|
autocomplete: 'cc-exp',
|
|
99
58
|
placeholder: 'MM/YY'
|
|
100
59
|
}),
|
|
101
|
-
method === 'deposit' && React.createElement(
|
|
60
|
+
method === 'deposit' && React.createElement(CardInput, {
|
|
61
|
+
className: 'layout-item-6',
|
|
102
62
|
name: 'cvv',
|
|
103
|
-
pattern: '\\d{3,4}',
|
|
104
|
-
value: values['cvv'],
|
|
105
|
-
onChange: function onChange(e, cvv) {
|
|
106
|
-
return change && change('cvv', cvv);
|
|
107
|
-
},
|
|
108
|
-
transform: function transform(cvv) {
|
|
109
|
-
return cvv.slice(0, 4);
|
|
110
|
-
},
|
|
111
63
|
label: translate({ id: 'cashier.details.cvv' }, intl),
|
|
112
64
|
required: true,
|
|
113
65
|
type: 'cvv',
|
|
@@ -122,29 +74,19 @@ var Creditcard = function Creditcard(_ref) {
|
|
|
122
74
|
var Neteller = function Neteller(_ref2) {
|
|
123
75
|
var account = _ref2.account,
|
|
124
76
|
intl = _ref2.intl,
|
|
125
|
-
method = _ref2.method
|
|
126
|
-
change = _ref2.change,
|
|
127
|
-
values = _ref2.values;
|
|
77
|
+
method = _ref2.method;
|
|
128
78
|
|
|
129
79
|
return React.createElement(
|
|
130
80
|
'div',
|
|
131
|
-
|
|
81
|
+
{ className: 'payment-account-info' },
|
|
132
82
|
React.createElement(Input, {
|
|
133
83
|
disabled: account.accountId,
|
|
134
|
-
value: values['account'],
|
|
135
|
-
onChange: function onChange(e, account) {
|
|
136
|
-
return change('account', account);
|
|
137
|
-
},
|
|
138
84
|
name: 'account',
|
|
139
85
|
label: translate({ id: 'cashier.details.account' }, intl),
|
|
140
86
|
required: true
|
|
141
87
|
}),
|
|
142
88
|
method === 'deposit' && React.createElement(Input, {
|
|
143
89
|
name: 'secureId',
|
|
144
|
-
value: values['secureId'],
|
|
145
|
-
onChange: function onChange(e, secureId) {
|
|
146
|
-
return change('secureId', secureId);
|
|
147
|
-
},
|
|
148
90
|
label: translate({ id: 'cashier.details.secureId' }, intl),
|
|
149
91
|
type: 'number',
|
|
150
92
|
required: true
|
|
@@ -153,30 +95,21 @@ var Neteller = function Neteller(_ref2) {
|
|
|
153
95
|
};
|
|
154
96
|
|
|
155
97
|
var VenusPoint = function VenusPoint(_ref3) {
|
|
156
|
-
var _React$createElement;
|
|
157
|
-
|
|
158
98
|
var account = _ref3.account,
|
|
159
|
-
intl = _ref3.intl
|
|
160
|
-
change = _ref3.change,
|
|
161
|
-
values = _ref3.values;
|
|
99
|
+
intl = _ref3.intl;
|
|
162
100
|
|
|
163
101
|
return React.createElement(
|
|
164
102
|
'div',
|
|
165
|
-
|
|
166
|
-
React.createElement(Input,
|
|
103
|
+
{ className: 'payment-account-info' },
|
|
104
|
+
React.createElement(Input, {
|
|
167
105
|
disabled: account.accountId,
|
|
168
106
|
name: 'username',
|
|
169
|
-
value:
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
}
|
|
173
|
-
}, _defineProperty(_React$createElement, 'value', account.maskedAccount), _defineProperty(_React$createElement, 'label', translate({ id: 'cashier.details.username' }, intl)), _React$createElement)),
|
|
107
|
+
value: account.maskedAccount,
|
|
108
|
+
label: translate({ id: 'cashier.details.username' }, intl)
|
|
109
|
+
}),
|
|
174
110
|
React.createElement(Input, {
|
|
175
111
|
type: 'password',
|
|
176
112
|
name: 'password',
|
|
177
|
-
onChange: function onChange(e, password) {
|
|
178
|
-
return change('password', password);
|
|
179
|
-
},
|
|
180
113
|
label: translate({ id: 'cashier.details.password' }, intl)
|
|
181
114
|
})
|
|
182
115
|
);
|
|
@@ -185,27 +118,21 @@ var VenusPoint = function VenusPoint(_ref3) {
|
|
|
185
118
|
var PPro = function PPro() {
|
|
186
119
|
return React.createElement(
|
|
187
120
|
'div',
|
|
188
|
-
|
|
121
|
+
{ className: 'payment-account-info' },
|
|
189
122
|
React.createElement(Input, { type: 'hidden', name: 'service', value: 'GIROPAY' })
|
|
190
123
|
);
|
|
191
124
|
};
|
|
192
125
|
|
|
193
126
|
var PhoneNumber = function PhoneNumber(_ref4) {
|
|
194
127
|
var account = _ref4.account,
|
|
195
|
-
intl = _ref4.intl
|
|
196
|
-
change = _ref4.change,
|
|
197
|
-
values = _ref4.values;
|
|
128
|
+
intl = _ref4.intl;
|
|
198
129
|
|
|
199
130
|
return React.createElement(
|
|
200
131
|
'div',
|
|
201
|
-
|
|
132
|
+
{ className: 'payment-account-info' },
|
|
202
133
|
React.createElement(Input, {
|
|
203
134
|
disabled: account.accountId,
|
|
204
135
|
name: 'phoneNumber',
|
|
205
|
-
value: values['phoneNumber'],
|
|
206
|
-
onChange: function onChange(e, phoneNumber) {
|
|
207
|
-
return change('phoneNumber', phoneNumber);
|
|
208
|
-
},
|
|
209
136
|
label: translate({ id: 'cashier.details.phoneNumber' }, intl),
|
|
210
137
|
required: true
|
|
211
138
|
})
|
|
@@ -214,20 +141,14 @@ var PhoneNumber = function PhoneNumber(_ref4) {
|
|
|
214
141
|
|
|
215
142
|
var Email = function Email(_ref5) {
|
|
216
143
|
var account = _ref5.account,
|
|
217
|
-
intl = _ref5.intl
|
|
218
|
-
change = _ref5.change,
|
|
219
|
-
values = _ref5.values;
|
|
144
|
+
intl = _ref5.intl;
|
|
220
145
|
|
|
221
146
|
return React.createElement(
|
|
222
147
|
'div',
|
|
223
|
-
|
|
148
|
+
{ className: 'payment-account-info' },
|
|
224
149
|
React.createElement(Input, {
|
|
225
150
|
disabled: account.accountId,
|
|
226
151
|
name: 'email',
|
|
227
|
-
value: values['email'],
|
|
228
|
-
onChange: function onChange(e, email) {
|
|
229
|
-
return change('email', email);
|
|
230
|
-
},
|
|
231
152
|
label: translate({ id: 'cashier.details.email' }, intl),
|
|
232
153
|
required: true
|
|
233
154
|
})
|
|
@@ -236,26 +157,19 @@ var Email = function Email(_ref5) {
|
|
|
236
157
|
|
|
237
158
|
var Banklocal = function Banklocal(_ref6) {
|
|
238
159
|
var account = _ref6.account,
|
|
239
|
-
intl = _ref6.intl
|
|
240
|
-
change = _ref6.change;
|
|
160
|
+
intl = _ref6.intl;
|
|
241
161
|
|
|
242
162
|
return React.createElement(
|
|
243
163
|
'div',
|
|
244
|
-
|
|
164
|
+
{ className: 'payment-account-info' },
|
|
245
165
|
React.createElement(Input, {
|
|
246
166
|
value: account.accountId ? account.maskedAccount.replace(/-\d*/g, '') : undefined,
|
|
247
|
-
onChange: function onChange(e, clearingNumber) {
|
|
248
|
-
return change('clearingNumber', clearingNumber);
|
|
249
|
-
},
|
|
250
167
|
name: 'clearingNumber',
|
|
251
168
|
label: translate({ id: 'cashier.details.clearingNumber' }, intl),
|
|
252
169
|
disabled: account.accountId
|
|
253
170
|
}),
|
|
254
171
|
React.createElement(Input, {
|
|
255
172
|
value: account.accountId ? account.maskedAccount.replace(/\d*-/g, '') : undefined,
|
|
256
|
-
onChange: function onChange(e, accountNumber) {
|
|
257
|
-
return change('accountNumber', accountNumber);
|
|
258
|
-
},
|
|
259
173
|
name: 'accountNumber',
|
|
260
174
|
label: translate({ id: 'cashier.details.accountNumber' }, intl),
|
|
261
175
|
disabled: account.accountId
|
|
@@ -265,19 +179,14 @@ var Banklocal = function Banklocal(_ref6) {
|
|
|
265
179
|
|
|
266
180
|
var BankIBAN = function BankIBAN(_ref7) {
|
|
267
181
|
var account = _ref7.account,
|
|
268
|
-
intl = _ref7.intl
|
|
269
|
-
change = _ref7.change,
|
|
270
|
-
values = _ref7.values;
|
|
182
|
+
intl = _ref7.intl;
|
|
271
183
|
|
|
272
184
|
return React.createElement(
|
|
273
185
|
'div',
|
|
274
|
-
|
|
186
|
+
{ className: 'payment-account-info' },
|
|
275
187
|
React.createElement(Input, {
|
|
276
188
|
required: true,
|
|
277
189
|
value: account.accountId ? account.maskedAccount.replace(/^\S* /g, '') : undefined,
|
|
278
|
-
onChange: function onChange(e, iban) {
|
|
279
|
-
return change('iban', iban);
|
|
280
|
-
},
|
|
281
190
|
name: 'iban',
|
|
282
191
|
label: translate({ id: 'cashier.details.iban' }, intl),
|
|
283
192
|
disabled: account.accountId
|
|
@@ -285,28 +194,17 @@ var BankIBAN = function BankIBAN(_ref7) {
|
|
|
285
194
|
React.createElement(Input, {
|
|
286
195
|
required: true,
|
|
287
196
|
value: account.accountId ? account.maskedAccount.replace(/\s(.*)/g, '') : undefined,
|
|
288
|
-
onChange: function onChange(e, bic) {
|
|
289
|
-
return change('bic', bic);
|
|
290
|
-
},
|
|
291
197
|
name: 'bic',
|
|
292
198
|
label: translate({ id: 'cashier.details.bic' }, intl),
|
|
293
199
|
disabled: account.accountId
|
|
294
200
|
}),
|
|
295
201
|
React.createElement(Input, {
|
|
296
202
|
required: true,
|
|
297
|
-
value: values['beneficiaryName'],
|
|
298
|
-
onChange: function onChange(e, beneficiaryName) {
|
|
299
|
-
return change('beneficiaryName', beneficiaryName);
|
|
300
|
-
},
|
|
301
203
|
name: 'beneficiaryName',
|
|
302
204
|
label: translate({ id: 'cashier.details.beneficiaryName' }, intl)
|
|
303
205
|
}),
|
|
304
206
|
React.createElement(Input, {
|
|
305
207
|
required: true,
|
|
306
|
-
value: values['bankName'],
|
|
307
|
-
onChange: function onChange(e, bankName) {
|
|
308
|
-
return change('bankName', bankName);
|
|
309
|
-
},
|
|
310
208
|
name: 'bankName',
|
|
311
209
|
label: translate({ id: 'cashier.details.bankName' }, intl)
|
|
312
210
|
})
|
|
@@ -318,9 +216,7 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
318
216
|
intl = _ref8.intl,
|
|
319
217
|
country = _ref8.country,
|
|
320
218
|
method = _ref8.method,
|
|
321
|
-
detail = _ref8.detail
|
|
322
|
-
change = _ref8.change,
|
|
323
|
-
values = _ref8.values;
|
|
219
|
+
detail = _ref8.detail;
|
|
324
220
|
|
|
325
221
|
var translateMap = function translateMap(category) {
|
|
326
222
|
return function (value) {
|
|
@@ -341,188 +237,104 @@ var AstroPayBank = function AstroPayBank(_ref8) {
|
|
|
341
237
|
|
|
342
238
|
return React.createElement(
|
|
343
239
|
'div',
|
|
344
|
-
|
|
345
|
-
method === 'withdraw' && methodDetails.idTypes && methodDetails.idTypes.length > 1 && React.createElement(
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
!values['nationalIdType'] && React.createElement(
|
|
359
|
-
Select.Option,
|
|
360
|
-
{ value: '', selected: true, disabled: true },
|
|
361
|
-
translate({
|
|
362
|
-
id: 'cashier.details.idType',
|
|
363
|
-
defaultMessage: 'nationalIdType'
|
|
364
|
-
}, intl)
|
|
365
|
-
),
|
|
366
|
-
methodDetails.idTypes.map(translateMap('idTypes')).map(function (s) {
|
|
367
|
-
return React.createElement(
|
|
368
|
-
Select.Option,
|
|
369
|
-
{ value: s.value },
|
|
370
|
-
s.label
|
|
371
|
-
);
|
|
372
|
-
})
|
|
373
|
-
),
|
|
240
|
+
{ className: 'payment-account-info' },
|
|
241
|
+
method === 'withdraw' && methodDetails.idTypes && methodDetails.idTypes.length > 1 && React.createElement(Select, {
|
|
242
|
+
required: true,
|
|
243
|
+
name: 'nationalIdType',
|
|
244
|
+
label: translate({
|
|
245
|
+
id: 'cashier.details.idType',
|
|
246
|
+
defaultMessage: 'nationalIdType'
|
|
247
|
+
}, intl),
|
|
248
|
+
defaultOptionLabel: translate({
|
|
249
|
+
id: 'cashier.details.select-nationalIdType',
|
|
250
|
+
defaultMessage: 'select nationalIdType'
|
|
251
|
+
}, intl),
|
|
252
|
+
options: methodDetails.idTypes.map(translateMap('idTypes'))
|
|
253
|
+
}),
|
|
374
254
|
React.createElement(Input, {
|
|
375
255
|
required: true,
|
|
376
256
|
name: 'nationalId',
|
|
377
|
-
value: values['nationalId'],
|
|
378
|
-
onChange: function onChange(e, nationalId) {
|
|
379
|
-
return change('nationalId', nationalId);
|
|
380
|
-
},
|
|
381
257
|
label: translate({
|
|
382
258
|
id: 'cashier.details.nationalId',
|
|
383
259
|
defaultMessage: 'nationalId'
|
|
384
260
|
}, intl)
|
|
385
261
|
}),
|
|
386
|
-
method === 'withdraw' && methodDetails.banks && methodDetails.banks.length > 1 && React.createElement(
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
!values['bankCode'] && React.createElement(
|
|
400
|
-
Select.Option,
|
|
401
|
-
{ value: '', selected: true, disabled: true },
|
|
402
|
-
translate({
|
|
403
|
-
id: 'cashier.details.bankCode',
|
|
404
|
-
defaultMessage: 'bankCode'
|
|
405
|
-
}, intl)
|
|
406
|
-
),
|
|
407
|
-
methodDetails.banks.map(translateMap('banks' + country)).map(function (s) {
|
|
408
|
-
return React.createElement(
|
|
409
|
-
Select.Option,
|
|
410
|
-
{ value: s.value },
|
|
411
|
-
s.label
|
|
412
|
-
);
|
|
413
|
-
})
|
|
414
|
-
),
|
|
262
|
+
method === 'withdraw' && methodDetails.banks && methodDetails.banks.length > 1 && React.createElement(Select, {
|
|
263
|
+
required: true,
|
|
264
|
+
name: 'bankCode',
|
|
265
|
+
label: translate({
|
|
266
|
+
id: 'cashier.details.bankCode',
|
|
267
|
+
defaultMessage: 'bankCode'
|
|
268
|
+
}, intl),
|
|
269
|
+
defaultOptionLabel: translate({
|
|
270
|
+
id: 'cashier.details.select-bankCode',
|
|
271
|
+
defaultMessage: 'select bankCode'
|
|
272
|
+
}, intl),
|
|
273
|
+
options: methodDetails.banks.map(translateMap('banks' + country))
|
|
274
|
+
}),
|
|
415
275
|
method === 'withdraw' && ['BR', 'UY', 'IN'].includes(country) && React.createElement(Input, {
|
|
416
276
|
required: true,
|
|
417
277
|
name: 'bankBranch',
|
|
418
|
-
value: values['bankBranch'],
|
|
419
|
-
onChange: function onChange(e, bankBranch) {
|
|
420
|
-
return change('bankBranch', bankBranch);
|
|
421
|
-
},
|
|
422
278
|
label: translate({
|
|
423
279
|
id: 'cashier.details.bankBranch',
|
|
424
280
|
defaultMessage: 'bankBranch'
|
|
425
281
|
}, intl)
|
|
426
282
|
}),
|
|
427
|
-
method === 'withdraw' && methodDetails.accountTypes && methodDetails.accountTypes.length > 1 && React.createElement(
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
!values['accountType'] && React.createElement(
|
|
441
|
-
Select.Option,
|
|
442
|
-
{ value: '', selected: true, disabled: true },
|
|
443
|
-
translate({
|
|
444
|
-
id: 'cashier.details.accountType',
|
|
445
|
-
defaultMessage: 'account type'
|
|
446
|
-
}, intl)
|
|
447
|
-
),
|
|
448
|
-
methodDetails.accountTypes.map(translateMap('accountTypes')).map(function (s) {
|
|
449
|
-
return React.createElement(
|
|
450
|
-
Select.Option,
|
|
451
|
-
{ value: s.value },
|
|
452
|
-
s.label
|
|
453
|
-
);
|
|
454
|
-
})
|
|
455
|
-
),
|
|
283
|
+
method === 'withdraw' && methodDetails.accountTypes && methodDetails.accountTypes.length > 1 && React.createElement(Select, {
|
|
284
|
+
required: true,
|
|
285
|
+
name: 'accountType',
|
|
286
|
+
label: translate({
|
|
287
|
+
id: 'cashier.details.accountType',
|
|
288
|
+
defaultMessage: 'account type'
|
|
289
|
+
}, intl),
|
|
290
|
+
defaultOptionLabel: translate({
|
|
291
|
+
id: 'cashier.details.select-account-type',
|
|
292
|
+
defaultMessage: 'select account type'
|
|
293
|
+
}, intl),
|
|
294
|
+
options: methodDetails.accountTypes.map(translateMap('accountTypes'))
|
|
295
|
+
}),
|
|
456
296
|
method === 'withdraw' && React.createElement(Input, {
|
|
457
297
|
required: true,
|
|
458
298
|
name: 'bankAccount',
|
|
459
|
-
value: values['bankAccount'],
|
|
460
|
-
onChange: function onChange(e, bankAccount) {
|
|
461
|
-
return change('bankAccount', bankAccount);
|
|
462
|
-
},
|
|
463
299
|
label: translate({
|
|
464
300
|
id: 'cashier.details.bankAccount',
|
|
465
301
|
defaultMessage: 'bankAccount'
|
|
466
302
|
}, intl)
|
|
467
303
|
}),
|
|
468
|
-
method === 'deposit' && methodDetails.services && methodDetails.services.length > 1 && React.createElement(
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
!values['service'] && React.createElement(
|
|
482
|
-
Select.Option,
|
|
483
|
-
{ value: '', selected: true, disabled: true },
|
|
484
|
-
translate({
|
|
485
|
-
id: 'cashier.details.service',
|
|
486
|
-
defaultMessage: 'service'
|
|
487
|
-
}, intl)
|
|
488
|
-
),
|
|
489
|
-
methodDetails.services.map(translateMap('services')).map(function (s) {
|
|
490
|
-
return React.createElement(
|
|
491
|
-
Select.Option,
|
|
492
|
-
{ value: s.value },
|
|
493
|
-
s.label
|
|
494
|
-
);
|
|
495
|
-
})
|
|
496
|
-
)
|
|
304
|
+
method === 'deposit' && methodDetails.services && methodDetails.services.length > 1 && React.createElement(Select, {
|
|
305
|
+
required: true,
|
|
306
|
+
name: 'service',
|
|
307
|
+
label: translate({
|
|
308
|
+
id: 'cashier.details.service',
|
|
309
|
+
defaultMessage: 'service'
|
|
310
|
+
}, intl),
|
|
311
|
+
defaultOptionLabel: translate({
|
|
312
|
+
id: 'cashier.details.select-service',
|
|
313
|
+
defaultMessage: 'select service'
|
|
314
|
+
}, intl),
|
|
315
|
+
options: methodDetails.services.map(translateMap('services'))
|
|
316
|
+
})
|
|
497
317
|
);
|
|
498
318
|
};
|
|
499
319
|
|
|
500
320
|
var BankIntl = function BankIntl(_ref9) {
|
|
501
321
|
var account = _ref9.account,
|
|
502
|
-
intl = _ref9.intl
|
|
503
|
-
values = _ref9.values,
|
|
504
|
-
change = _ref9.change;
|
|
322
|
+
intl = _ref9.intl;
|
|
505
323
|
|
|
506
324
|
return React.createElement(
|
|
507
325
|
'div',
|
|
508
326
|
{ className: 'payment-account-info' },
|
|
509
327
|
React.createElement(Input, {
|
|
510
|
-
|
|
328
|
+
value: account.accountId ? account.maskedAccount.replace(/\d*-/g, '') : undefined,
|
|
511
329
|
name: 'accountNumber',
|
|
512
|
-
value: account.accountId ? account.maskedAccount.replace(/\d*-/g, '') : values['accountNumber'],
|
|
513
|
-
onChange: function onChange(e, accountNumber) {
|
|
514
|
-
return change('accountNumber', accountNumber);
|
|
515
|
-
},
|
|
516
330
|
label: translate({ id: 'cashier.details.accountNumber' }, intl),
|
|
517
|
-
disabled: account.accountId
|
|
331
|
+
disabled: account.accountId,
|
|
332
|
+
required: true
|
|
518
333
|
}),
|
|
519
334
|
React.createElement(Input, {
|
|
520
335
|
required: true,
|
|
336
|
+
value: account.accountId ? account.maskedAccount.replace(/\s(.*)/g, '') : undefined,
|
|
521
337
|
name: 'bic',
|
|
522
|
-
value: account.accountId ? account.maskedAccount.replace(/\s(.*)/g, '') : values['bic'],
|
|
523
|
-
onChange: function onChange(e, bic) {
|
|
524
|
-
return change('bic', bic);
|
|
525
|
-
},
|
|
526
338
|
label: translate({ id: 'cashier.details.bic' }, intl),
|
|
527
339
|
disabled: account.accountId
|
|
528
340
|
})
|
|
@@ -532,9 +344,7 @@ var BankIntl = function BankIntl(_ref9) {
|
|
|
532
344
|
var CryptoCurrency = function CryptoCurrency(_ref10) {
|
|
533
345
|
var intl = _ref10.intl,
|
|
534
346
|
detail = _ref10.detail,
|
|
535
|
-
method = _ref10.method
|
|
536
|
-
values = _ref10.values,
|
|
537
|
-
change = _ref10.change;
|
|
347
|
+
method = _ref10.method;
|
|
538
348
|
|
|
539
349
|
var methodDetails = {
|
|
540
350
|
cryptoCurrencies: getByPath(detail, 'config.cryptoCurrencies', [])
|
|
@@ -543,42 +353,27 @@ var CryptoCurrency = function CryptoCurrency(_ref10) {
|
|
|
543
353
|
return React.createElement(
|
|
544
354
|
'div',
|
|
545
355
|
{ className: 'payment-account-info' },
|
|
546
|
-
methodDetails.cryptoCurrencies.length > 0 && React.createElement(
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
translate({
|
|
563
|
-
id: 'cashier.details.select-cryptoCurrency',
|
|
564
|
-
defaultMessage: 'Select crypto currency'
|
|
565
|
-
}, intl)
|
|
566
|
-
),
|
|
567
|
-
methodDetails.cryptoCurrencies.map(function (cryptoCurrency) {
|
|
568
|
-
return React.createElement(
|
|
569
|
-
Select.Option,
|
|
570
|
-
{ value: cryptoCurrency },
|
|
571
|
-
cryptoCurrency
|
|
572
|
-
);
|
|
356
|
+
methodDetails.cryptoCurrencies.length > 0 && React.createElement(Select, {
|
|
357
|
+
required: true,
|
|
358
|
+
name: 'cryptoCurrency',
|
|
359
|
+
label: translate({
|
|
360
|
+
id: 'cashier.details.cryptoCurrency',
|
|
361
|
+
defaultMessage: 'Crypto currency'
|
|
362
|
+
}, intl),
|
|
363
|
+
defaultOptionLabel: translate({
|
|
364
|
+
id: 'cashier.details.select-cryptoCurrency',
|
|
365
|
+
defaultMessage: 'Select crypto currency'
|
|
366
|
+
}, intl),
|
|
367
|
+
options: methodDetails.cryptoCurrencies.map(function (cryptoCurrency) {
|
|
368
|
+
return {
|
|
369
|
+
label: cryptoCurrency,
|
|
370
|
+
value: cryptoCurrency
|
|
371
|
+
};
|
|
573
372
|
})
|
|
574
|
-
),
|
|
373
|
+
}),
|
|
575
374
|
method === 'withdraw' && React.createElement(Input, {
|
|
576
375
|
required: true,
|
|
577
376
|
name: 'walletAddress',
|
|
578
|
-
value: values['walletAddress'],
|
|
579
|
-
onChange: function onChange(e, walletAddress) {
|
|
580
|
-
return change('walletAddress', walletAddress);
|
|
581
|
-
},
|
|
582
377
|
label: translate({
|
|
583
378
|
id: 'cashier.details.walletAddress',
|
|
584
379
|
defaultMessage: 'Wallet address'
|
|
@@ -589,74 +384,85 @@ var CryptoCurrency = function CryptoCurrency(_ref10) {
|
|
|
589
384
|
|
|
590
385
|
var Jeton = function Jeton(_ref11) {
|
|
591
386
|
var account = _ref11.account,
|
|
592
|
-
intl = _ref11.intl
|
|
593
|
-
values = _ref11.values,
|
|
594
|
-
change = _ref11.change;
|
|
387
|
+
intl = _ref11.intl;
|
|
595
388
|
|
|
596
389
|
return React.createElement(
|
|
597
390
|
'div',
|
|
598
391
|
{ className: 'payment-account-info' },
|
|
599
392
|
React.createElement(Input, {
|
|
600
|
-
|
|
393
|
+
value: account.maskedAccount,
|
|
601
394
|
name: 'customerNumber',
|
|
602
|
-
value: account.maskedAccount || values['customerNumber'],
|
|
603
|
-
onChange: function onChange(e, customerNumber) {
|
|
604
|
-
return change('customerNumber', customerNumber);
|
|
605
|
-
},
|
|
606
395
|
label: translate({ id: 'cashier.details.customerNumber' }, intl),
|
|
607
|
-
disabled: account.accountId
|
|
396
|
+
disabled: account.accountId,
|
|
397
|
+
required: true
|
|
608
398
|
})
|
|
609
399
|
);
|
|
610
400
|
};
|
|
611
401
|
|
|
612
402
|
var BestPay = function BestPay(_ref12) {
|
|
613
403
|
var account = _ref12.account,
|
|
614
|
-
intl = _ref12.intl
|
|
615
|
-
values = _ref12.values,
|
|
616
|
-
change = _ref12.change;
|
|
404
|
+
intl = _ref12.intl;
|
|
617
405
|
|
|
618
406
|
return React.createElement(
|
|
619
407
|
'div',
|
|
620
408
|
{ className: 'payment-account-info' },
|
|
621
409
|
React.createElement(Input, {
|
|
622
|
-
|
|
410
|
+
value: account.accountId ? account.maskedAccount.replace(/\d*-/g, '') : undefined,
|
|
623
411
|
name: 'accountNumber',
|
|
624
|
-
value: account.accountId ? account.maskedAccount.replace(/\d*-/g, '') : values['accountNumber'],
|
|
625
|
-
onChange: function onChange(e, accountNumber) {
|
|
626
|
-
return change('accountNumber', accountNumber);
|
|
627
|
-
},
|
|
628
412
|
label: translate({ id: 'cashier.details.accountNumber' }, intl),
|
|
629
|
-
disabled: account.accountId
|
|
413
|
+
disabled: account.accountId,
|
|
414
|
+
required: true
|
|
630
415
|
}),
|
|
631
416
|
React.createElement(Input, {
|
|
632
|
-
required: true,
|
|
633
417
|
name: 'swiftCode',
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
return change('swiftCode', swiftCode);
|
|
637
|
-
},
|
|
638
|
-
label: translate({ id: 'cashier.details.swiftCode' }, intl)
|
|
418
|
+
label: translate({ id: 'cashier.details.swiftCode' }, intl),
|
|
419
|
+
required: true
|
|
639
420
|
})
|
|
640
421
|
);
|
|
641
422
|
};
|
|
642
423
|
|
|
643
|
-
var
|
|
424
|
+
var EzeeWallet = function EzeeWallet(_ref13) {
|
|
644
425
|
var account = _ref13.account,
|
|
645
426
|
intl = _ref13.intl,
|
|
646
|
-
|
|
647
|
-
values = _ref13.values;
|
|
427
|
+
method = _ref13.method;
|
|
648
428
|
|
|
649
429
|
return React.createElement(
|
|
650
430
|
'div',
|
|
651
|
-
|
|
431
|
+
{ className: 'payment-account-info' },
|
|
652
432
|
React.createElement(Input, {
|
|
433
|
+
required: true,
|
|
434
|
+
name: 'walletId',
|
|
435
|
+
label: translate({
|
|
436
|
+
id: 'cashier.details.walletId',
|
|
437
|
+
defaultMessage: 'Wallet ID'
|
|
438
|
+
}, intl),
|
|
653
439
|
disabled: account.accountId,
|
|
654
|
-
value:
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
440
|
+
value: account.maskedAccount
|
|
441
|
+
}),
|
|
442
|
+
method === 'deposit' && React.createElement(Input, {
|
|
443
|
+
required: true,
|
|
444
|
+
type: 'password',
|
|
445
|
+
name: 'walletPassword',
|
|
446
|
+
label: translate({
|
|
447
|
+
id: 'cashier.details.walletPassword',
|
|
448
|
+
defaultMessage: 'Wallet password'
|
|
449
|
+
}, intl)
|
|
450
|
+
})
|
|
451
|
+
);
|
|
452
|
+
};
|
|
453
|
+
|
|
454
|
+
var Mifinity = function Mifinity(_ref14) {
|
|
455
|
+
var account = _ref14.account,
|
|
456
|
+
intl = _ref14.intl;
|
|
457
|
+
|
|
458
|
+
return React.createElement(
|
|
459
|
+
'div',
|
|
460
|
+
null,
|
|
461
|
+
React.createElement(Input, {
|
|
462
|
+
value: account.maskedAccount,
|
|
658
463
|
name: 'destinationAccount',
|
|
659
|
-
label: translate({ id: 'cashier.details.
|
|
464
|
+
label: translate({ id: 'cashier.details.accountNumber' }, intl),
|
|
465
|
+
disabled: account.accountId,
|
|
660
466
|
required: true
|
|
661
467
|
})
|
|
662
468
|
);
|
|
@@ -725,6 +531,11 @@ export var CryptoCurrencyDeposit = {
|
|
|
725
531
|
parser: identity
|
|
726
532
|
};
|
|
727
533
|
|
|
534
|
+
export var EzeeWalletDeposit = {
|
|
535
|
+
component: injectMethod({ method: 'deposit' }, injectIntl(EzeeWallet)),
|
|
536
|
+
parser: identity
|
|
537
|
+
};
|
|
538
|
+
|
|
728
539
|
export var ZimplerDeposit = null;
|
|
729
540
|
export var BankDeposit = null;
|
|
730
541
|
export var TrustlyDeposit = null;
|
|
@@ -813,9 +624,14 @@ export var AstroPayBankWithdrawal = {
|
|
|
813
624
|
parser: identity
|
|
814
625
|
};
|
|
815
626
|
|
|
627
|
+
export var EzeeWalletWithdrawal = {
|
|
628
|
+
component: injectMethod({ method: 'withdraw' }, injectIntl(EzeeWallet)),
|
|
629
|
+
parser: identity
|
|
630
|
+
};
|
|
631
|
+
|
|
816
632
|
export var MiFinityEWalletWithdrawal = {
|
|
817
|
-
component:
|
|
818
|
-
parser:
|
|
633
|
+
component: injectIntl(Mifinity),
|
|
634
|
+
parser: identity
|
|
819
635
|
};
|
|
820
636
|
|
|
821
637
|
export var ZimplerWithdrawal = null;
|