tg-core-components 6.3.4-2.7 → 6.3.4-2.8

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.
@@ -125,6 +125,7 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
125
125
  return React.createElement(
126
126
  'div',
127
127
  { className: cn('ResponsibleGamingWidget', className) },
128
+ console.log(normalizedLimits),
128
129
  React.createElement(
129
130
  AccordionWidget,
130
131
  {
@@ -42,12 +42,14 @@ var validate = function validate(_ref) {
42
42
  return getByPath(t, 'newLimit.Type') === 'Deposit' && t.timespan === 30;
43
43
  });
44
44
 
45
- //const exceedingMaxLimitAmount = timespans.find(t => getByPath(t, 'newLimit.'))
45
+ var exceedingMaxLimitAmount = timespans.find(function (t) {
46
+ return getByPath(t, 'newLimit.Amount') > getByPath(t, 'newLimit.MaxAmount');
47
+ });
46
48
 
47
49
  /**
48
50
  * Compose jurisdictions with rules
49
51
  */
50
- 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() {
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() {
51
53
  return !this['insufficient-limit-count'] && !(this['limit-increase-blocked'] && isIncreasingLimit) && !(this['limit-remove-blocked'] && isRemovingLimit);
52
54
  }), _common);
53
55
  var mga = {};
@@ -167,6 +167,7 @@ var ResponsibleGaming = function ResponsibleGaming(_ref) {
167
167
  return _react2.default.createElement(
168
168
  'div',
169
169
  { className: (0, _classnames2.default)('ResponsibleGamingWidget', className) },
170
+ console.log(normalizedLimits),
170
171
  _react2.default.createElement(
171
172
  _AccordionWidget2.default,
172
173
  {
@@ -52,12 +52,14 @@ var validate = function validate(_ref) {
52
52
  return (0, _get2.default)(t, 'newLimit.Type') === 'Deposit' && t.timespan === 30;
53
53
  });
54
54
 
55
- //const exceedingMaxLimitAmount = timespans.find(t => getByPath(t, 'newLimit.'))
55
+ var exceedingMaxLimitAmount = timespans.find(function (t) {
56
+ return (0, _get2.default)(t, 'newLimit.Amount') > (0, _get2.default)(t, 'newLimit.MaxAmount');
57
+ });
56
58
 
57
59
  /**
58
60
  * Compose jurisdictions with rules
59
61
  */
60
- 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() {
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() {
61
63
  return !this['insufficient-limit-count'] && !(this['limit-increase-blocked'] && isIncreasingLimit) && !(this['limit-remove-blocked'] && isRemovingLimit);
62
64
  }), _common);
63
65
  var mga = {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tg-core-components",
3
- "version": "6.3.4-2.7",
3
+ "version": "6.3.4-2.8",
4
4
  "description": "tg-core-components",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",