tg-core-components 6.3.4-3.9 → 6.3.4

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/auth ADDED
@@ -0,0 +1,51 @@
1
+
2
+ <!DOCTYPE html>
3
+ <html lang="sv">
4
+
5
+ <head>
6
+ <meta charset="utf-8">
7
+ <meta name="referrer" content="no-referrer">
8
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
9
+ <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
10
+ <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500" rel="stylesheet">
11
+ <title>Bethard</title>
12
+ <script src="https://cdn.polyfill.io/v2/polyfill.min.js"></script>
13
+ <script src="https://cdn.ravenjs.com/3.26.4/raven.min.js" crossorigin="anonymous"></script>
14
+ <style type="text/css">
15
+
16
+ @font-face {
17
+ font-family: Futura;
18
+ font-style: normal;
19
+ font-weight: 400;
20
+ src: url("https://static.gii.cloud/futura_lt/Futura LT Medium.woff") format("woff"),url("https://static.gii.cloud/futura_lt/Futura LT Medium.ttf") format("truetype")
21
+ }
22
+ @font-face {
23
+ font-family: Futura;
24
+ src: local("Futura LT Bold"),local("Futura-LT-Bold"),url("https://static.gii.cloud/futura_lt/Futura LT Bold.woff") format("woff"),url("https://static.gii.cloud/futura_lt/Futura LT Bold.ttf") format("truetype");
25
+ font-weight: 600;
26
+ font-style: normal
27
+ }
28
+ @font-face {
29
+ font-family: Futura;
30
+ src: local("Futura LT Bold"),local("Futura-LT-Bold"),url("https://static.gii.cloud/futura_lt/Futura LT Bold.woff") format("woff"),url("https://static.gii.cloud/futura_lt/Futura LT Bold.ttf") format("truetype");
31
+ font-weight: 700;
32
+ font-style: normal
33
+ }
34
+
35
+ </style>
36
+ </head>
37
+
38
+ <body>
39
+ <main>
40
+ <div class="bankid-se-config" bankid-se-config="{&quot;relyingPartyName&quot;:&quot;Bethard&quot;,&quot;relyingPartyAvatar&quot;:&quot;https://www.icelondon.uk.com/__media/libraries/exhibitor-press-releases/8FA2DD80-5056-B779-246F1902D15A57A0-image.png&quot;,&quot;relyingPartyURL&quot;:&quot;https://www.bethard.com&quot;,&quot;theme&quot;:&quot;dark&quot;,&quot;themeConfig&quot;:&quot;\n\t\t{\n\t\t \&quot;shadows\&quot;: [],\n\t\t \&quot;props\&quot;: {\n\t\t \&quot;MuiButtonBase\&quot;: {\n\t\t \&quot;disableRipple\&quot;: true\n\t\t },\n\t\t \&quot;MuiPaper\&quot;: {\n\t\t \&quot;square\&quot;: true\n\t\t }\n\t\t },\n\t\t \&quot;typography\&quot;: {\n\t\t\t\t\&quot;fontFamily\&quot;: \&quot;Futura, sans-serif\&quot;,\n\t\t\t\t\&quot;fontSize\&quot;: 12\n\t\t\t},\n\t\t\t\&quot;palette\&quot;: {\n\t\t\t\t\&quot;type\&quot;: \&quot;dark\&quot;,\n\t\t\t\t\&quot;background\&quot;:{\n\t\t\t\t\t\&quot;default\&quot;: \&quot;#1a1a1a\&quot;\n\t\t\t\t},\n\t\t\t\t\&quot;primary\&quot;: {\n\t\t\t\t\t\&quot;main\&quot;: \&quot;#f7d146\&quot;\n\t\t\t\t},\n\t\t\t\t\&quot;secondary\&quot;: {\n\t\t\t\t\t\&quot;main\&quot;: \&quot;#C4A638\&quot;\n\t\t\t\t}\n\t\t\t},\n\t\t\t\&quot;shape\&quot;: {\n\t\t\t\t\&quot;borderRadius\&quot;: 0\n\t\t\t},\n\t\t \&quot;overrides\&quot;: {\n\t\t \&quot;MuiPaper\&quot;: {\n\t\t \&quot;root\&quot;: {\n\t\t\t\t\t\t\&quot;background\&quot;: \&quot;#1a1a1a!important\&quot;,\n\t\t\t\t\t\t\&quot;color\&quot;: \&quot;#dedede\&quot;\n\t\t }\n\t\t },\n\t\t \&quot;MuiTypography\&quot;: {\n\t\t \&quot;display1\&quot;: {\n\t\t \&quot;color\&quot;: \&quot;#f7d146!important\&quot;,\n\t\t \&quot;fontWeight\&quot;: \&quot;bold\&quot;,\n\t\t \&quot;textTransform\&quot;: \&quot;uppercase\&quot;\n\t\t },\n\t\t \&quot;title\&quot;: {\n\t\t \&quot;fontWeight\&quot;: \&quot;bold\&quot;,\n\t\t \&quot;textTransform\&quot;: \&quot;uppercase\&quot;\n\t\t },\n\t\t \&quot;headline\&quot;: {\n\t\t \&quot;fontWeight\&quot;: \&quot;bold\&quot;,\n\t\t \&quot;textTransform\&quot;: \&quot;uppercase\&quot;\n\t\t }\n\t\t },\n\t\t \&quot;MuiBottomNavigation\&quot;: {\n\t\t \&quot;root\&quot;: {\n\t\t \&quot;background\&quot;: \&quot;#282828!important\&quot;\n\t\t }\n\t\t },\n\t\t \&quot;MuiBottomNavigationAction\&quot;: {\n\t\t \&quot;selected\&quot;: {\n\t\t \&quot;color\&quot;: \&quot;#f7d146!important\&quot;\n\t\t },\n\t\t \&quot;label\&quot;: {\n\t\t \&quot;color\&quot;: \&quot;#dedede!important\&quot;\n\t\t }\n\t\t },\n\t\t \&quot;MuiButton\&quot;: {\n\t\t \&quot;root\&quot;: {\n\t\t \&quot;_fontWeight\&quot;: \&quot;bold\&quot;,\n\t\t \&quot;paddingLeft\&quot;: \&quot;3em!important\&quot;,\n\t\t \&quot;paddingRight\&quot;: \&quot;3em!important\&quot;\n\t\t },\n\t\t \&quot;outlined\&quot;: {\n\t\t \&quot;borderWidth\&quot;: 1.5,\n\t\t \&quot;borderColor\&quot;: \&quot;inherit\&quot;\n\t\t\t\t\t},\n\t\t\t\t\t\&quot;raised\&quot;: {\n\t\t\t\t\t\t\&quot;fontWeight\&quot;: \&quot;bold\&quot;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t\&quot;MuiInputLabel\&quot;: {\n\t\t\t\t\t\&quot;root\&quot;: {\n\t\t\t\t\t\t\&quot;color\&quot;: \&quot;#dedede!important\&quot;\n\t\t\t\t\t},\n\t\t\t\t\t\&quot;shrink\&quot;: {\n\t\t\t\t\t\t\&quot;transform\&quot;: \&quot;translate(0, 1.5px) scale(0.875)\&quot;,\n\t\t\t\t\t\t\&quot;transformOrigin\&quot;: \&quot;top left\&quot;\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\t\&quot;MuiCircularProgress\&quot;: {\n\t\t\t\t\t\&quot;_colorPrimary\&quot;: \&quot;#f7d14666\&quot;,\n\t\t\t\t\t\&quot;root\&quot;: {\n\t\t\t\t\t\t\&quot;width\&quot;: \&quot;70px!important\&quot;,\n \t\t \&quot;height\&quot;: \&quot;70px!important\&quot;,\n\t\t\t\t\t\t\&quot;color\&quot;: \&quot;#f7d146\&quot;\n\t\t\t\t\t},\n\t\t\t\t\t\&quot;circle\&quot;: {\n\t\t\t\t\t\t\&quot;strokeWidth\&quot;: 2\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t }\n\t\t}&quot;,&quot;fontURL&quot;:&quot;&quot;,&quot;faviconURL&quot;:&quot;&quot;,&quot;isIframe&quot;:true,&quot;isInline&quot;:false,&quot;css&quot;:&quot;&quot;,&quot;cssURL&quot;:&quot;&quot;,&quot;isPartial&quot;:false,&quot;hasFixedSSN&quot;:true,&quot;csrfToken&quot;:&quot;FQC/JSj+/5Knv6FcyGEwio+ILW161vDZsLzNhbt82EI=&quot;,&quot;collectURL&quot;:&quot;https://demo-api.gii.cloud/api/ip/bankid-se/auth/collect?id=880035236545495042\u0026csrfToken=FQC%2FJSj%2B%2F5Knv6FcyGEwio%2BILW161vDZsLzNhbt82EI%3D\u0026sessionID=96872c4a0e5e982ead7066a63ae065b231f5b3b03e6e4e58ffb2ea33ea86fa1a\u0026authRequestID=880035236525965314%2C341305621978906625%2CVqAgTCpjgN2%2B%2FjlHfeU9qoEqZdHNwFhBS5lc5VmQBUQ%3D&quot;,&quot;initSameDeviceURL&quot;:&quot;https://demo-api.gii.cloud/api/ip/bankid-se/auth/initSameDevice?id=880035236545495042\u0026csrfToken=FQC%2FJSj%2B%2F5Knv6FcyGEwio%2BILW161vDZsLzNhbt82EI%3D\u0026sessionID=96872c4a0e5e982ead7066a63ae065b231f5b3b03e6e4e58ffb2ea33ea86fa1a\u0026authRequestID=880035236525965314%2C341305621978906625%2CVqAgTCpjgN2%2B%2FjlHfeU9qoEqZdHNwFhBS5lc5VmQBUQ%3D&quot;,&quot;initOtherDeviceURL&quot;:&quot;https://demo-api.gii.cloud/api/ip/bankid-se/auth/initOtherDevice?id=880035236545495042\u0026csrfToken=FQC%2FJSj%2B%2F5Knv6FcyGEwio%2BILW161vDZsLzNhbt82EI%3D\u0026sessionID=96872c4a0e5e982ead7066a63ae065b231f5b3b03e6e4e58ffb2ea33ea86fa1a\u0026authRequestID=880035236525965314%2C341305621978906625%2CVqAgTCpjgN2%2B%2FjlHfeU9qoEqZdHNwFhBS5lc5VmQBUQ%3D&quot;,&quot;isSign&quot;:false,&quot;hasPersonalNumber&quot;:true,&quot;device&quot;:&quot;OTHER&quot;,&quot;other&quot;:&quot;&quot;,&quot;QR&quot;:&quot;FALSE&quot;,&quot;lang&quot;:&quot;sv&quot;,&quot;ssn&quot;:&quot;199202143112&quot;,&quot;isNativePlatform&quot;:false,&quot;redirectURL&quot;:&quot;&quot;,&quot;redirect&quot;:false,&quot;referer&quot;:&quot;&quot;,&quot;isPhone&quot;:false,&quot;cancelURL&quot;:&quot;https://demo-api.gii.cloud/api/ip/bankid-se/auth/cancel?id=880035236545495042\u0026csrfToken=FQC%2FJSj%2B%2F5Knv6FcyGEwio%2BILW161vDZsLzNhbt82EI%3D\u0026sessionID=96872c4a0e5e982ead7066a63ae065b231f5b3b03e6e4e58ffb2ea33ea86fa1a\u0026authRequestID=880035236525965314%2C341305621978906625%2CVqAgTCpjgN2%2B%2FjlHfeU9qoEqZdHNwFhBS5lc5VmQBUQ%3D&quot;}"></div>
41
+ <div class="bankid-se-lang" bankid-se-lang="{}"></div>
42
+
43
+ <script src="https://demo-api.gii.cloud/static/ip/bankidse/iframeResizer.contentWindow.min.js?rev=e05483705b84562824d8cb5f2ee1ce4657f40e18"></script>
44
+ <script src="https://demo-api.gii.cloud/static/ip/bankidse/bankidse-iframe.js?rev=e05483705b84562824d8cb5f2ee1ce4657f40e18"></script>
45
+
46
+ </main>
47
+
48
+
49
+ </body>
50
+
51
+ </html>
@@ -242,7 +242,6 @@ var DefaultTimespan = function DefaultTimespan(_ref10) {
242
242
  hideRemainingLimit = _ref10.hideRemainingLimit,
243
243
  showCurrentValue = _ref10.showCurrentValue,
244
244
  hideOther = _ref10.hideOther,
245
- maxAmounts = _ref10.maxAmounts,
246
245
  values = _ref10.values,
247
246
  messages = _ref10.messages,
248
247
  isTime = _ref10.isTime,
@@ -255,13 +254,7 @@ var DefaultTimespan = function DefaultTimespan(_ref10) {
255
254
 
256
255
  useEffect(function () {
257
256
  if (newLimit) {
258
- var _console, _console2;
259
-
260
257
  setValue(newLimit.Amount);
261
- (_console = console).log.apply(_console, _toConsumableArray(getValues(maxAmounts, currency, timespan)));
262
- (_console2 = console).log.apply(_console2, _toConsumableArray(getValues(newLimit.MaxAmount, currency, timespan)));
263
- console.log(maxAmounts);
264
- console.log(values);
265
258
  }
266
259
  }, [newLimit]);
267
260
 
@@ -16,7 +16,6 @@ import messages from './messages';
16
16
  import Timespan from './Timespan';
17
17
  import getByPath from 'lodash/get';
18
18
  import marked from 'marked';
19
- import { getValues } from './helpers';
20
19
 
21
20
  var ResponsibleGaming = function ResponsibleGaming(_ref) {
22
21
  var limits = _ref.limits,
@@ -104,7 +103,7 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
104
103
  * Add a new limit with status "NewLimit"
105
104
  * There can only be one limit with status "NewLimit" for each type/timespan
106
105
  */
107
- var onChangeLimit = function onChangeLimit(type, product, maxAmounts) {
106
+ var onChangeLimit = function onChangeLimit(type, product) {
108
107
  return function (timespan) {
109
108
  return function (amount) {
110
109
  var newLimit = {
@@ -113,7 +112,6 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
113
112
  Product: product,
114
113
  Timespan: timespan,
115
114
  Amount: amount,
116
- MaxAmount: getValues(maxAmounts, currency, timespan),
117
115
  Status: 'NewLimit'
118
116
  };
119
117
  var limits = localLimits.filter(function (l) {
@@ -124,8 +122,6 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
124
122
  };
125
123
  };
126
124
 
127
- console.log(normalizedLimits);
128
-
129
125
  return React.createElement(
130
126
  'div',
131
127
  { className: cn('ResponsibleGamingWidget', className) },
@@ -143,8 +139,8 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
143
139
  tooltipOpen: normalizedLimits.tooltipOpen
144
140
  }),
145
141
  React.createElement(LimitContent, _extends({
146
- onSubmitLimits: onSubmitLimits(normalizedLimits.type, normalizedLimits.product, normalizedLimits.maxAmounts),
147
- onChangeLimit: onChangeLimit(normalizedLimits.type, normalizedLimits.product, normalizedLimits.maxAmounts),
142
+ onSubmitLimits: onSubmitLimits(normalizedLimits.type, normalizedLimits.product),
143
+ onChangeLimit: onChangeLimit(normalizedLimits.type, normalizedLimits.product),
148
144
  hideSubmit: hideSubmit,
149
145
  onConfirmLimit: onConfirmLimit,
150
146
  onDeclineLimit: onDeclineLimit,
@@ -182,7 +178,6 @@ var LimitContent = function LimitContent(_ref3) {
182
178
  getAlerts = _ref3.getAlerts,
183
179
  isLoading = _ref3.isLoading,
184
180
  currency = _ref3.currency,
185
- maxAmounts = _ref3.maxAmounts,
186
181
  values = _ref3.values,
187
182
  valueType = _ref3.valueType,
188
183
  hideRemainingLimit = _ref3.hideRemainingLimit,
@@ -196,8 +191,6 @@ var LimitContent = function LimitContent(_ref3) {
196
191
 
197
192
  var alerts = getAlerts(Object.keys(timespans));
198
193
 
199
- console.log(Object.values);
200
-
201
194
  var onSubmit = function onSubmit(e) {
202
195
  e.preventDefault();
203
196
  var limits = Object.values(timespans).filter(function (t) {
@@ -230,36 +223,30 @@ var LimitContent = function LimitContent(_ref3) {
230
223
  currency: currency
231
224
  }),
232
225
  Object.values(timespans).map(function (t) {
233
- return React.createElement(
234
- 'div',
235
- null,
236
- console.log(t),
237
- React.createElement(Timespan, _extends({
238
- key: t.timespan,
239
- title: Object.values(timespans).length > 1 && messages.get('header.responsible-gaming.timespan.' + t.timespan),
240
- onChangeLimit: onChangeLimit(t.timespan),
241
- onResetLimit: function onResetLimit() {
242
- return onSubmitLimits([t.currentLimit]);
243
- },
244
- onConfirmLimit: onConfirmLimit,
245
- onDeclineLimit: onDeclineLimit,
246
- onPickLimit: function onPickLimit(id) {
247
- return onSubmitLimits(t.pickLimits.filter(function (l) {
248
- return l.Id !== id;
249
- }).map(function (l) {
250
- return _extends({}, l, { Amount: 0 });
251
- }));
252
- },
253
- validationState: getValidationState(t.timespan),
254
- currency: currency,
255
- maxAmounts: maxAmounts,
256
- values: values,
257
- valueType: valueType,
258
- hideRemainingLimit: hideRemainingLimit,
259
- showCurrentValue: showCurrentValue,
260
- hideOther: hideOther
261
- }, t))
262
- );
226
+ return React.createElement(Timespan, _extends({
227
+ key: t.timespan,
228
+ title: Object.values(timespans).length > 1 && messages.get('header.responsible-gaming.timespan.' + t.timespan),
229
+ onChangeLimit: onChangeLimit(t.timespan),
230
+ onResetLimit: function onResetLimit() {
231
+ return onSubmitLimits([t.currentLimit]);
232
+ },
233
+ onConfirmLimit: onConfirmLimit,
234
+ onDeclineLimit: onDeclineLimit,
235
+ onPickLimit: function onPickLimit(id) {
236
+ return onSubmitLimits(t.pickLimits.filter(function (l) {
237
+ return l.Id !== id;
238
+ }).map(function (l) {
239
+ return _extends({}, l, { Amount: 0 });
240
+ }));
241
+ },
242
+ validationState: getValidationState(t.timespan),
243
+ currency: currency,
244
+ values: values,
245
+ valueType: valueType,
246
+ hideRemainingLimit: hideRemainingLimit,
247
+ showCurrentValue: showCurrentValue,
248
+ hideOther: hideOther
249
+ }, t));
263
250
  }),
264
251
  !hideSubmit && React.createElement(
265
252
  Button,
@@ -42,14 +42,10 @@ var validate = function validate(_ref) {
42
42
  return getByPath(t, 'newLimit.Type') === 'Deposit' && t.timespan === 30;
43
43
  });
44
44
 
45
- var exceedingMaxLimitAmount = timespans.find(function (t) {
46
- return getByPath(t, 'newLimit.Amount') > getByPath(t, 'newLimit.MaxAmount');
47
- });
48
-
49
45
  /**
50
46
  * Compose jurisdictions with rules
51
47
  */
52
- var common = (_common = {}, _defineProperty(_common, 'show-confirm-on-submit', type === 'Block' || type === 'SelfExclude'), _defineProperty(_common, 'insufficient-limit-count', false), _defineProperty(_common, 'limits-are-pristine', limitsArePristine), _defineProperty(_common, 'limit-increase-blocked', false), _defineProperty(_common, 'limit-remove-blocked', false), _defineProperty(_common, 'limit-above-maxlimit', exceedingMaxLimitAmount), _defineProperty(_common, 'isValid', function isValid() {
48
+ var common = (_common = {}, _defineProperty(_common, 'show-confirm-on-submit', type === 'Block' || type === 'SelfExclude'), _defineProperty(_common, 'insufficient-limit-count', false), _defineProperty(_common, 'limits-are-pristine', limitsArePristine), _defineProperty(_common, 'limit-increase-blocked', false), _defineProperty(_common, 'limit-remove-blocked', false), _defineProperty(_common, 'isValid', function isValid() {
53
49
  return !this['insufficient-limit-count'] && !(this['limit-increase-blocked'] && isIncreasingLimit) && !(this['limit-remove-blocked'] && isRemovingLimit);
54
50
  }), _common);
55
51
  var mga = {};
@@ -273,7 +273,6 @@ var DefaultTimespan = function DefaultTimespan(_ref10) {
273
273
  hideRemainingLimit = _ref10.hideRemainingLimit,
274
274
  showCurrentValue = _ref10.showCurrentValue,
275
275
  hideOther = _ref10.hideOther,
276
- maxAmounts = _ref10.maxAmounts,
277
276
  values = _ref10.values,
278
277
  messages = _ref10.messages,
279
278
  isTime = _ref10.isTime,
@@ -286,13 +285,7 @@ var DefaultTimespan = function DefaultTimespan(_ref10) {
286
285
 
287
286
  (0, _react.useEffect)(function () {
288
287
  if (newLimit) {
289
- var _console, _console2;
290
-
291
288
  setValue(newLimit.Amount);
292
- (_console = console).log.apply(_console, _toConsumableArray((0, _helpers.getValues)(maxAmounts, currency, timespan)));
293
- (_console2 = console).log.apply(_console2, _toConsumableArray((0, _helpers.getValues)(newLimit.MaxAmount, currency, timespan)));
294
- console.log(maxAmounts);
295
- console.log(values);
296
289
  }
297
290
  }, [newLimit]);
298
291
 
@@ -55,8 +55,6 @@ var _marked = require('marked');
55
55
 
56
56
  var _marked2 = _interopRequireDefault(_marked);
57
57
 
58
- var _helpers = require('./helpers');
59
-
60
58
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
61
59
 
62
60
  function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
@@ -147,7 +145,7 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
147
145
  * Add a new limit with status "NewLimit"
148
146
  * There can only be one limit with status "NewLimit" for each type/timespan
149
147
  */
150
- var onChangeLimit = function onChangeLimit(type, product, maxAmounts) {
148
+ var onChangeLimit = function onChangeLimit(type, product) {
151
149
  return function (timespan) {
152
150
  return function (amount) {
153
151
  var newLimit = {
@@ -156,7 +154,6 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
156
154
  Product: product,
157
155
  Timespan: timespan,
158
156
  Amount: amount,
159
- MaxAmount: (0, _helpers.getValues)(maxAmounts, currency, timespan),
160
157
  Status: 'NewLimit'
161
158
  };
162
159
  var limits = localLimits.filter(function (l) {
@@ -167,8 +164,6 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
167
164
  };
168
165
  };
169
166
 
170
- console.log(normalizedLimits);
171
-
172
167
  return _react2.default.createElement(
173
168
  'div',
174
169
  { className: (0, _classnames2.default)('ResponsibleGamingWidget', className) },
@@ -186,8 +181,8 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
186
181
  tooltipOpen: normalizedLimits.tooltipOpen
187
182
  }),
188
183
  _react2.default.createElement(LimitContent, _extends({
189
- onSubmitLimits: onSubmitLimits(normalizedLimits.type, normalizedLimits.product, normalizedLimits.maxAmounts),
190
- onChangeLimit: onChangeLimit(normalizedLimits.type, normalizedLimits.product, normalizedLimits.maxAmounts),
184
+ onSubmitLimits: onSubmitLimits(normalizedLimits.type, normalizedLimits.product),
185
+ onChangeLimit: onChangeLimit(normalizedLimits.type, normalizedLimits.product),
191
186
  hideSubmit: hideSubmit,
192
187
  onConfirmLimit: onConfirmLimit,
193
188
  onDeclineLimit: onDeclineLimit,
@@ -225,7 +220,6 @@ var LimitContent = function LimitContent(_ref3) {
225
220
  getAlerts = _ref3.getAlerts,
226
221
  isLoading = _ref3.isLoading,
227
222
  currency = _ref3.currency,
228
- maxAmounts = _ref3.maxAmounts,
229
223
  values = _ref3.values,
230
224
  valueType = _ref3.valueType,
231
225
  hideRemainingLimit = _ref3.hideRemainingLimit,
@@ -239,8 +233,6 @@ var LimitContent = function LimitContent(_ref3) {
239
233
 
240
234
  var alerts = getAlerts(Object.keys(timespans));
241
235
 
242
- console.log(Object.values);
243
-
244
236
  var onSubmit = function onSubmit(e) {
245
237
  e.preventDefault();
246
238
  var limits = Object.values(timespans).filter(function (t) {
@@ -273,36 +265,30 @@ var LimitContent = function LimitContent(_ref3) {
273
265
  currency: currency
274
266
  }),
275
267
  Object.values(timespans).map(function (t) {
276
- return _react2.default.createElement(
277
- 'div',
278
- null,
279
- console.log(t),
280
- _react2.default.createElement(_Timespan2.default, _extends({
281
- key: t.timespan,
282
- title: Object.values(timespans).length > 1 && _messages2.default.get('header.responsible-gaming.timespan.' + t.timespan),
283
- onChangeLimit: onChangeLimit(t.timespan),
284
- onResetLimit: function onResetLimit() {
285
- return onSubmitLimits([t.currentLimit]);
286
- },
287
- onConfirmLimit: onConfirmLimit,
288
- onDeclineLimit: onDeclineLimit,
289
- onPickLimit: function onPickLimit(id) {
290
- return onSubmitLimits(t.pickLimits.filter(function (l) {
291
- return l.Id !== id;
292
- }).map(function (l) {
293
- return _extends({}, l, { Amount: 0 });
294
- }));
295
- },
296
- validationState: getValidationState(t.timespan),
297
- currency: currency,
298
- maxAmounts: maxAmounts,
299
- values: values,
300
- valueType: valueType,
301
- hideRemainingLimit: hideRemainingLimit,
302
- showCurrentValue: showCurrentValue,
303
- hideOther: hideOther
304
- }, t))
305
- );
268
+ return _react2.default.createElement(_Timespan2.default, _extends({
269
+ key: t.timespan,
270
+ title: Object.values(timespans).length > 1 && _messages2.default.get('header.responsible-gaming.timespan.' + t.timespan),
271
+ onChangeLimit: onChangeLimit(t.timespan),
272
+ onResetLimit: function onResetLimit() {
273
+ return onSubmitLimits([t.currentLimit]);
274
+ },
275
+ onConfirmLimit: onConfirmLimit,
276
+ onDeclineLimit: onDeclineLimit,
277
+ onPickLimit: function onPickLimit(id) {
278
+ return onSubmitLimits(t.pickLimits.filter(function (l) {
279
+ return l.Id !== id;
280
+ }).map(function (l) {
281
+ return _extends({}, l, { Amount: 0 });
282
+ }));
283
+ },
284
+ validationState: getValidationState(t.timespan),
285
+ currency: currency,
286
+ values: values,
287
+ valueType: valueType,
288
+ hideRemainingLimit: hideRemainingLimit,
289
+ showCurrentValue: showCurrentValue,
290
+ hideOther: hideOther
291
+ }, t));
306
292
  }),
307
293
  !hideSubmit && _react2.default.createElement(
308
294
  _Button2.default,
@@ -52,14 +52,10 @@ var validate = function validate(_ref) {
52
52
  return (0, _get2.default)(t, 'newLimit.Type') === 'Deposit' && t.timespan === 30;
53
53
  });
54
54
 
55
- var exceedingMaxLimitAmount = timespans.find(function (t) {
56
- return (0, _get2.default)(t, 'newLimit.Amount') > (0, _get2.default)(t, 'newLimit.MaxAmount');
57
- });
58
-
59
55
  /**
60
56
  * Compose jurisdictions with rules
61
57
  */
62
- var common = (_common = {}, _defineProperty(_common, 'show-confirm-on-submit', type === 'Block' || type === 'SelfExclude'), _defineProperty(_common, 'insufficient-limit-count', false), _defineProperty(_common, 'limits-are-pristine', limitsArePristine), _defineProperty(_common, 'limit-increase-blocked', false), _defineProperty(_common, 'limit-remove-blocked', false), _defineProperty(_common, 'limit-above-maxlimit', exceedingMaxLimitAmount), _defineProperty(_common, 'isValid', function isValid() {
58
+ var common = (_common = {}, _defineProperty(_common, 'show-confirm-on-submit', type === 'Block' || type === 'SelfExclude'), _defineProperty(_common, 'insufficient-limit-count', false), _defineProperty(_common, 'limits-are-pristine', limitsArePristine), _defineProperty(_common, 'limit-increase-blocked', false), _defineProperty(_common, 'limit-remove-blocked', false), _defineProperty(_common, 'isValid', function isValid() {
63
59
  return !this['insufficient-limit-count'] && !(this['limit-increase-blocked'] && isIncreasingLimit) && !(this['limit-remove-blocked'] && isRemovingLimit);
64
60
  }), _common);
65
61
  var mga = {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tg-core-components",
3
- "version": "6.3.4-3.9",
3
+ "version": "6.3.4",
4
4
  "description": "tg-core-components",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",