@thecb/components 9.1.1-beta.3 → 9.1.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/dist/index.cjs.js +279 -296
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +279 -296
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/checkbox/Checkbox.js +1 -3
- package/src/components/atoms/country-dropdown/CountryDropdown.js +1 -3
- package/src/components/atoms/form-layouts/FormInput.js +3 -11
- package/src/components/atoms/radio-button-with-label/RadioButtonWithLabel.js +1 -3
- package/src/components/molecules/address-form/AddressForm.js +0 -6
- package/src/components/molecules/edit-name-form/EditNameForm.js +0 -2
- package/src/components/molecules/email-form/EmailForm.js +2 -5
- package/src/components/molecules/payment-form-ach/PaymentFormACH.js +0 -6
- package/src/components/molecules/payment-form-card/PaymentFormCard.js +0 -6
- package/src/components/molecules/phone-form/PhoneForm.js +1 -3
- package/src/components/molecules/radio-group/RadioGroup.js +7 -12
- package/src/components/molecules/radio-group/RadioGroup.stories.js +0 -2
- package/src/components/molecules/radio-section/RadioSection.js +2 -9
- package/src/components/molecules/radio-section/RadioSection.stories.js +4 -7
- package/src/components/molecules/radio-section/radio-button/RadioButton.js +1 -3
- package/src/components/templates/center-single/CenterSingle.js +2 -6
- package/src/components/templates/center-stack/CenterStack.js +4 -2
- package/src/components/templates/default-page-template/DefaultPageTemplate.js +1 -2
- package/dist/src/apps/checkout/pages/payment/sub-pages/payment-amount/PaymentAmount_old.js +0 -49322
- package/src/.DS_Store +0 -0
- package/src/components/.DS_Store +0 -0
- package/src/components/atoms/.DS_Store +0 -0
- package/src/components/atoms/icons/.DS_Store +0 -0
package/dist/index.cjs.js
CHANGED
|
@@ -22104,8 +22104,7 @@ var StyledCheckbox = styled__default.div.withConfig({
|
|
|
22104
22104
|
focusedStyles = _ref3.focusedStyles,
|
|
22105
22105
|
errorStyles = _ref3.errorStyles,
|
|
22106
22106
|
disabledStyles = _ref3.disabledStyles,
|
|
22107
|
-
disabledCheckedStyles = _ref3.disabledCheckedStyles
|
|
22108
|
-
_ref3$required = _ref3.required;
|
|
22107
|
+
disabledCheckedStyles = _ref3.disabledCheckedStyles;
|
|
22109
22108
|
return error ? styled.css(["", " ", ""], errorStyles, focused && focusedStyles) : disabled ? styled.css(["", ""], checked ? disabledCheckedStyles : disabledStyles) : checked ? styled.css(["", " ", ""], checkedStyles, focused && focusedStyles) : styled.css(["", " ", ""], defaultStyles, focused && focusedStyles);
|
|
22110
22109
|
});
|
|
22111
22110
|
|
|
@@ -22168,8 +22167,7 @@ var Checkbox = function Checkbox(_ref4) {
|
|
|
22168
22167
|
onChange: onChange,
|
|
22169
22168
|
tabIndex: "-1",
|
|
22170
22169
|
"aria-invalid": error,
|
|
22171
|
-
"aria-describedby": error ? "".concat(name, "-error-message") : ""
|
|
22172
|
-
required: required
|
|
22170
|
+
"aria-describedby": error ? "".concat(name, "-error-message") : ""
|
|
22173
22171
|
}), /*#__PURE__*/React__default.createElement(StyledCheckbox, {
|
|
22174
22172
|
role: "checkbox",
|
|
22175
22173
|
error: error,
|
|
@@ -22421,17 +22419,18 @@ var DropdownIcon = function DropdownIcon() {
|
|
|
22421
22419
|
};
|
|
22422
22420
|
|
|
22423
22421
|
var check = function (it) {
|
|
22424
|
-
return it && it.Math
|
|
22422
|
+
return it && it.Math === Math && it;
|
|
22425
22423
|
};
|
|
22426
22424
|
|
|
22427
22425
|
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
22428
22426
|
var global_1 =
|
|
22429
|
-
// eslint-disable-next-line es
|
|
22427
|
+
// eslint-disable-next-line es/no-global-this -- safe
|
|
22430
22428
|
check(typeof globalThis == 'object' && globalThis) ||
|
|
22431
22429
|
check(typeof window == 'object' && window) ||
|
|
22432
22430
|
// eslint-disable-next-line no-restricted-globals -- safe
|
|
22433
22431
|
check(typeof self == 'object' && self) ||
|
|
22434
22432
|
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
22433
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
22435
22434
|
// eslint-disable-next-line no-new-func -- fallback
|
|
22436
22435
|
(function () { return this; })() || Function('return this')();
|
|
22437
22436
|
|
|
@@ -22445,12 +22444,12 @@ var fails = function (exec) {
|
|
|
22445
22444
|
|
|
22446
22445
|
// Detect IE8's incomplete defineProperty implementation
|
|
22447
22446
|
var descriptors = !fails(function () {
|
|
22448
|
-
// eslint-disable-next-line es
|
|
22449
|
-
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1]
|
|
22447
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22448
|
+
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
22450
22449
|
});
|
|
22451
22450
|
|
|
22452
22451
|
var functionBindNative = !fails(function () {
|
|
22453
|
-
// eslint-disable-next-line es
|
|
22452
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
22454
22453
|
var test = (function () { /* empty */ }).bind();
|
|
22455
22454
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
22456
22455
|
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
@@ -22463,7 +22462,7 @@ var functionCall = functionBindNative ? call.bind(call) : function () {
|
|
|
22463
22462
|
};
|
|
22464
22463
|
|
|
22465
22464
|
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
22466
|
-
// eslint-disable-next-line es
|
|
22465
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22467
22466
|
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
22468
22467
|
|
|
22469
22468
|
// Nashorn ~ JDK8 bug
|
|
@@ -22490,14 +22489,11 @@ var createPropertyDescriptor = function (bitmap, value) {
|
|
|
22490
22489
|
};
|
|
22491
22490
|
|
|
22492
22491
|
var FunctionPrototype = Function.prototype;
|
|
22493
|
-
var bind$1 = FunctionPrototype.bind;
|
|
22494
22492
|
var call$1 = FunctionPrototype.call;
|
|
22495
|
-
var
|
|
22493
|
+
var uncurryThisWithBind = functionBindNative && FunctionPrototype.bind.bind(call$1, call$1);
|
|
22496
22494
|
|
|
22497
|
-
var functionUncurryThis = functionBindNative ? function (fn) {
|
|
22498
|
-
return
|
|
22499
|
-
} : function (fn) {
|
|
22500
|
-
return fn && function () {
|
|
22495
|
+
var functionUncurryThis = functionBindNative ? uncurryThisWithBind : function (fn) {
|
|
22496
|
+
return function () {
|
|
22501
22497
|
return call$1.apply(fn, arguments);
|
|
22502
22498
|
};
|
|
22503
22499
|
};
|
|
@@ -22518,15 +22514,21 @@ var indexedObject = fails(function () {
|
|
|
22518
22514
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
22519
22515
|
return !$Object('z').propertyIsEnumerable(0);
|
|
22520
22516
|
}) ? function (it) {
|
|
22521
|
-
return classofRaw(it)
|
|
22517
|
+
return classofRaw(it) === 'String' ? split(it, '') : $Object(it);
|
|
22522
22518
|
} : $Object;
|
|
22523
22519
|
|
|
22520
|
+
// we can't use just `it == null` since of `document.all` special case
|
|
22521
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
22522
|
+
var isNullOrUndefined = function (it) {
|
|
22523
|
+
return it === null || it === undefined;
|
|
22524
|
+
};
|
|
22525
|
+
|
|
22524
22526
|
var $TypeError = TypeError;
|
|
22525
22527
|
|
|
22526
22528
|
// `RequireObjectCoercible` abstract operation
|
|
22527
22529
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
22528
22530
|
var requireObjectCoercible = function (it) {
|
|
22529
|
-
if (it
|
|
22531
|
+
if (isNullOrUndefined(it)) throw new $TypeError("Can't call method on " + it);
|
|
22530
22532
|
return it;
|
|
22531
22533
|
};
|
|
22532
22534
|
|
|
@@ -22538,13 +22540,32 @@ var toIndexedObject = function (it) {
|
|
|
22538
22540
|
return indexedObject(requireObjectCoercible(it));
|
|
22539
22541
|
};
|
|
22540
22542
|
|
|
22543
|
+
var documentAll = typeof document == 'object' && document.all;
|
|
22544
|
+
|
|
22545
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
22546
|
+
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
22547
|
+
var IS_HTMLDDA = typeof documentAll == 'undefined' && documentAll !== undefined;
|
|
22548
|
+
|
|
22549
|
+
var documentAll_1 = {
|
|
22550
|
+
all: documentAll,
|
|
22551
|
+
IS_HTMLDDA: IS_HTMLDDA
|
|
22552
|
+
};
|
|
22553
|
+
|
|
22554
|
+
var documentAll$1 = documentAll_1.all;
|
|
22555
|
+
|
|
22541
22556
|
// `IsCallable` abstract operation
|
|
22542
22557
|
// https://tc39.es/ecma262/#sec-iscallable
|
|
22543
|
-
var isCallable = function (argument) {
|
|
22558
|
+
var isCallable = documentAll_1.IS_HTMLDDA ? function (argument) {
|
|
22559
|
+
return typeof argument == 'function' || argument === documentAll$1;
|
|
22560
|
+
} : function (argument) {
|
|
22544
22561
|
return typeof argument == 'function';
|
|
22545
22562
|
};
|
|
22546
22563
|
|
|
22547
|
-
var
|
|
22564
|
+
var documentAll$2 = documentAll_1.all;
|
|
22565
|
+
|
|
22566
|
+
var isObject = documentAll_1.IS_HTMLDDA ? function (it) {
|
|
22567
|
+
return typeof it == 'object' ? it !== null : isCallable(it) || it === documentAll$2;
|
|
22568
|
+
} : function (it) {
|
|
22548
22569
|
return typeof it == 'object' ? it !== null : isCallable(it);
|
|
22549
22570
|
};
|
|
22550
22571
|
|
|
@@ -22558,7 +22579,7 @@ var getBuiltIn = function (namespace, method) {
|
|
|
22558
22579
|
|
|
22559
22580
|
var objectIsPrototypeOf = functionUncurryThis({}.isPrototypeOf);
|
|
22560
22581
|
|
|
22561
|
-
var engineUserAgent =
|
|
22582
|
+
var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
22562
22583
|
|
|
22563
22584
|
var process$1 = global_1.process;
|
|
22564
22585
|
var Deno = global_1.Deno;
|
|
@@ -22585,24 +22606,29 @@ if (!version && engineUserAgent) {
|
|
|
22585
22606
|
|
|
22586
22607
|
var engineV8Version = version;
|
|
22587
22608
|
|
|
22588
|
-
/* eslint-disable es
|
|
22609
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
22589
22610
|
|
|
22590
22611
|
|
|
22591
22612
|
|
|
22592
|
-
|
|
22593
|
-
var
|
|
22594
|
-
|
|
22613
|
+
|
|
22614
|
+
var $String = global_1.String;
|
|
22615
|
+
|
|
22616
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
22617
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails(function () {
|
|
22618
|
+
var symbol = Symbol('symbol detection');
|
|
22595
22619
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
22596
22620
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
22597
|
-
|
|
22621
|
+
// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
|
|
22622
|
+
// of course, fail.
|
|
22623
|
+
return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
22598
22624
|
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
22599
22625
|
!Symbol.sham && engineV8Version && engineV8Version < 41;
|
|
22600
22626
|
});
|
|
22601
22627
|
|
|
22602
|
-
/* eslint-disable es
|
|
22628
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
22603
22629
|
|
|
22604
22630
|
|
|
22605
|
-
var useSymbolAsUid =
|
|
22631
|
+
var useSymbolAsUid = symbolConstructorDetection
|
|
22606
22632
|
&& !Symbol.sham
|
|
22607
22633
|
&& typeof Symbol.iterator == 'symbol';
|
|
22608
22634
|
|
|
@@ -22615,11 +22641,11 @@ var isSymbol = useSymbolAsUid ? function (it) {
|
|
|
22615
22641
|
return isCallable($Symbol) && objectIsPrototypeOf($Symbol.prototype, $Object$1(it));
|
|
22616
22642
|
};
|
|
22617
22643
|
|
|
22618
|
-
var $String = String;
|
|
22644
|
+
var $String$1 = String;
|
|
22619
22645
|
|
|
22620
22646
|
var tryToString = function (argument) {
|
|
22621
22647
|
try {
|
|
22622
|
-
return $String(argument);
|
|
22648
|
+
return $String$1(argument);
|
|
22623
22649
|
} catch (error) {
|
|
22624
22650
|
return 'Object';
|
|
22625
22651
|
}
|
|
@@ -22630,14 +22656,14 @@ var $TypeError$1 = TypeError;
|
|
|
22630
22656
|
// `Assert: IsCallable(argument) is true`
|
|
22631
22657
|
var aCallable = function (argument) {
|
|
22632
22658
|
if (isCallable(argument)) return argument;
|
|
22633
|
-
throw $TypeError$1(tryToString(argument) + ' is not a function');
|
|
22659
|
+
throw new $TypeError$1(tryToString(argument) + ' is not a function');
|
|
22634
22660
|
};
|
|
22635
22661
|
|
|
22636
22662
|
// `GetMethod` abstract operation
|
|
22637
22663
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
22638
22664
|
var getMethod = function (V, P) {
|
|
22639
22665
|
var func = V[P];
|
|
22640
|
-
return func
|
|
22666
|
+
return isNullOrUndefined(func) ? undefined : aCallable(func);
|
|
22641
22667
|
};
|
|
22642
22668
|
|
|
22643
22669
|
var $TypeError$2 = TypeError;
|
|
@@ -22649,10 +22675,10 @@ var ordinaryToPrimitive = function (input, pref) {
|
|
|
22649
22675
|
if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
22650
22676
|
if (isCallable(fn = input.valueOf) && !isObject(val = functionCall(fn, input))) return val;
|
|
22651
22677
|
if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
22652
|
-
throw $TypeError$2("Can't convert object to primitive value");
|
|
22678
|
+
throw new $TypeError$2("Can't convert object to primitive value");
|
|
22653
22679
|
};
|
|
22654
22680
|
|
|
22655
|
-
// eslint-disable-next-line es
|
|
22681
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22656
22682
|
var defineProperty = Object.defineProperty;
|
|
22657
22683
|
|
|
22658
22684
|
var defineGlobalProperty = function (key, value) {
|
|
@@ -22669,13 +22695,16 @@ var store = global_1[SHARED] || defineGlobalProperty(SHARED, {});
|
|
|
22669
22695
|
var sharedStore = store;
|
|
22670
22696
|
|
|
22671
22697
|
var shared = createCommonjsModule(function (module) {
|
|
22698
|
+
|
|
22699
|
+
|
|
22700
|
+
|
|
22672
22701
|
(module.exports = function (key, value) {
|
|
22673
22702
|
return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
|
|
22674
22703
|
})('versions', []).push({
|
|
22675
|
-
version: '3.
|
|
22704
|
+
version: '3.33.3',
|
|
22676
22705
|
mode: 'global',
|
|
22677
|
-
copyright: '© 2014-
|
|
22678
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.
|
|
22706
|
+
copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
|
|
22707
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.33.3/LICENSE',
|
|
22679
22708
|
source: 'https://github.com/zloirock/core-js'
|
|
22680
22709
|
});
|
|
22681
22710
|
});
|
|
@@ -22692,7 +22721,7 @@ var hasOwnProperty = functionUncurryThis({}.hasOwnProperty);
|
|
|
22692
22721
|
|
|
22693
22722
|
// `HasOwnProperty` abstract operation
|
|
22694
22723
|
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
22695
|
-
// eslint-disable-next-line es
|
|
22724
|
+
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
22696
22725
|
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
22697
22726
|
return hasOwnProperty(toObject(it), key);
|
|
22698
22727
|
};
|
|
@@ -22705,21 +22734,15 @@ var uid = function (key) {
|
|
|
22705
22734
|
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$3(++id + postfix, 36);
|
|
22706
22735
|
};
|
|
22707
22736
|
|
|
22708
|
-
var WellKnownSymbolsStore = shared('wks');
|
|
22709
22737
|
var Symbol$1 = global_1.Symbol;
|
|
22710
|
-
var
|
|
22711
|
-
var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
|
|
22738
|
+
var WellKnownSymbolsStore = shared('wks');
|
|
22739
|
+
var createWellKnownSymbol = useSymbolAsUid ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
|
|
22712
22740
|
|
|
22713
22741
|
var wellKnownSymbol = function (name) {
|
|
22714
|
-
if (!hasOwnProperty_1(WellKnownSymbolsStore, name)
|
|
22715
|
-
|
|
22716
|
-
|
|
22717
|
-
|
|
22718
|
-
} else if (useSymbolAsUid && symbolFor) {
|
|
22719
|
-
WellKnownSymbolsStore[name] = symbolFor(description);
|
|
22720
|
-
} else {
|
|
22721
|
-
WellKnownSymbolsStore[name] = createWellKnownSymbol(description);
|
|
22722
|
-
}
|
|
22742
|
+
if (!hasOwnProperty_1(WellKnownSymbolsStore, name)) {
|
|
22743
|
+
WellKnownSymbolsStore[name] = symbolConstructorDetection && hasOwnProperty_1(Symbol$1, name)
|
|
22744
|
+
? Symbol$1[name]
|
|
22745
|
+
: createWellKnownSymbol('Symbol.' + name);
|
|
22723
22746
|
} return WellKnownSymbolsStore[name];
|
|
22724
22747
|
};
|
|
22725
22748
|
|
|
@@ -22736,7 +22759,7 @@ var toPrimitive = function (input, pref) {
|
|
|
22736
22759
|
if (pref === undefined) pref = 'default';
|
|
22737
22760
|
result = functionCall(exoticToPrim, input, pref);
|
|
22738
22761
|
if (!isObject(result) || isSymbol(result)) return result;
|
|
22739
|
-
throw $TypeError$3("Can't convert object to primitive value");
|
|
22762
|
+
throw new $TypeError$3("Can't convert object to primitive value");
|
|
22740
22763
|
}
|
|
22741
22764
|
if (pref === undefined) pref = 'number';
|
|
22742
22765
|
return ordinaryToPrimitive(input, pref);
|
|
@@ -22759,13 +22782,13 @@ var documentCreateElement = function (it) {
|
|
|
22759
22782
|
|
|
22760
22783
|
// Thanks to IE8 for its funny defineProperty
|
|
22761
22784
|
var ie8DomDefine = !descriptors && !fails(function () {
|
|
22762
|
-
// eslint-disable-next-line es
|
|
22785
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22763
22786
|
return Object.defineProperty(documentCreateElement('div'), 'a', {
|
|
22764
22787
|
get: function () { return 7; }
|
|
22765
|
-
}).a
|
|
22788
|
+
}).a !== 7;
|
|
22766
22789
|
});
|
|
22767
22790
|
|
|
22768
|
-
// eslint-disable-next-line es
|
|
22791
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22769
22792
|
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
22770
22793
|
|
|
22771
22794
|
// `Object.getOwnPropertyDescriptor` method
|
|
@@ -22786,26 +22809,26 @@ var objectGetOwnPropertyDescriptor = {
|
|
|
22786
22809
|
// V8 ~ Chrome 36-
|
|
22787
22810
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
22788
22811
|
var v8PrototypeDefineBug = descriptors && fails(function () {
|
|
22789
|
-
// eslint-disable-next-line es
|
|
22812
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22790
22813
|
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
22791
22814
|
value: 42,
|
|
22792
22815
|
writable: false
|
|
22793
|
-
}).prototype
|
|
22816
|
+
}).prototype !== 42;
|
|
22794
22817
|
});
|
|
22795
22818
|
|
|
22796
|
-
var $String$
|
|
22819
|
+
var $String$2 = String;
|
|
22797
22820
|
var $TypeError$4 = TypeError;
|
|
22798
22821
|
|
|
22799
22822
|
// `Assert: Type(argument) is Object`
|
|
22800
22823
|
var anObject = function (argument) {
|
|
22801
22824
|
if (isObject(argument)) return argument;
|
|
22802
|
-
throw $TypeError$4($String$
|
|
22825
|
+
throw new $TypeError$4($String$2(argument) + ' is not an object');
|
|
22803
22826
|
};
|
|
22804
22827
|
|
|
22805
22828
|
var $TypeError$5 = TypeError;
|
|
22806
|
-
// eslint-disable-next-line es
|
|
22829
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22807
22830
|
var $defineProperty = Object.defineProperty;
|
|
22808
|
-
// eslint-disable-next-line es
|
|
22831
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22809
22832
|
var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
22810
22833
|
var ENUMERABLE = 'enumerable';
|
|
22811
22834
|
var CONFIGURABLE = 'configurable';
|
|
@@ -22835,7 +22858,7 @@ var f$2 = descriptors ? v8PrototypeDefineBug ? function defineProperty(O, P, Att
|
|
|
22835
22858
|
if (ie8DomDefine) try {
|
|
22836
22859
|
return $defineProperty(O, P, Attributes);
|
|
22837
22860
|
} catch (error) { /* empty */ }
|
|
22838
|
-
if ('get' in Attributes || 'set' in Attributes) throw $TypeError$5('Accessors not supported');
|
|
22861
|
+
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$5('Accessors not supported');
|
|
22839
22862
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
22840
22863
|
return O;
|
|
22841
22864
|
};
|
|
@@ -22852,7 +22875,7 @@ var createNonEnumerableProperty = descriptors ? function (object, key, value) {
|
|
|
22852
22875
|
};
|
|
22853
22876
|
|
|
22854
22877
|
var FunctionPrototype$1 = Function.prototype;
|
|
22855
|
-
// eslint-disable-next-line es
|
|
22878
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22856
22879
|
var getDescriptor = descriptors && Object.getOwnPropertyDescriptor;
|
|
22857
22880
|
|
|
22858
22881
|
var EXISTS$1 = hasOwnProperty_1(FunctionPrototype$1, 'name');
|
|
@@ -22879,7 +22902,7 @@ var inspectSource = sharedStore.inspectSource;
|
|
|
22879
22902
|
|
|
22880
22903
|
var WeakMap$1 = global_1.WeakMap;
|
|
22881
22904
|
|
|
22882
|
-
var
|
|
22905
|
+
var weakMapBasicDetection = isCallable(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
22883
22906
|
|
|
22884
22907
|
var keys$1 = shared('keys');
|
|
22885
22908
|
|
|
@@ -22902,27 +22925,29 @@ var getterFor = function (TYPE) {
|
|
|
22902
22925
|
return function (it) {
|
|
22903
22926
|
var state;
|
|
22904
22927
|
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
22905
|
-
throw TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
22928
|
+
throw new TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
22906
22929
|
} return state;
|
|
22907
22930
|
};
|
|
22908
22931
|
};
|
|
22909
22932
|
|
|
22910
|
-
if (
|
|
22933
|
+
if (weakMapBasicDetection || sharedStore.state) {
|
|
22911
22934
|
var store$1 = sharedStore.state || (sharedStore.state = new WeakMap$2());
|
|
22912
|
-
|
|
22913
|
-
|
|
22914
|
-
|
|
22935
|
+
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
22936
|
+
store$1.get = store$1.get;
|
|
22937
|
+
store$1.has = store$1.has;
|
|
22938
|
+
store$1.set = store$1.set;
|
|
22939
|
+
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
22915
22940
|
set = function (it, metadata) {
|
|
22916
|
-
if (
|
|
22941
|
+
if (store$1.has(it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
22917
22942
|
metadata.facade = it;
|
|
22918
|
-
|
|
22943
|
+
store$1.set(it, metadata);
|
|
22919
22944
|
return metadata;
|
|
22920
22945
|
};
|
|
22921
22946
|
get = function (it) {
|
|
22922
|
-
return
|
|
22947
|
+
return store$1.get(it) || {};
|
|
22923
22948
|
};
|
|
22924
22949
|
has = function (it) {
|
|
22925
|
-
return
|
|
22950
|
+
return store$1.has(it);
|
|
22926
22951
|
};
|
|
22927
22952
|
} else {
|
|
22928
22953
|
var STATE = sharedKey('state');
|
|
@@ -22950,14 +22975,23 @@ var internalState = {
|
|
|
22950
22975
|
};
|
|
22951
22976
|
|
|
22952
22977
|
var makeBuiltIn_1 = createCommonjsModule(function (module) {
|
|
22978
|
+
|
|
22979
|
+
|
|
22980
|
+
|
|
22981
|
+
|
|
22982
|
+
|
|
22953
22983
|
var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
|
|
22954
22984
|
|
|
22955
22985
|
|
|
22956
22986
|
|
|
22957
22987
|
var enforceInternalState = internalState.enforce;
|
|
22958
22988
|
var getInternalState = internalState.get;
|
|
22959
|
-
|
|
22989
|
+
var $String = String;
|
|
22990
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22960
22991
|
var defineProperty = Object.defineProperty;
|
|
22992
|
+
var stringSlice = functionUncurryThis(''.slice);
|
|
22993
|
+
var replace = functionUncurryThis(''.replace);
|
|
22994
|
+
var join = functionUncurryThis([].join);
|
|
22961
22995
|
|
|
22962
22996
|
var CONFIGURABLE_LENGTH = descriptors && !fails(function () {
|
|
22963
22997
|
return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
@@ -22966,8 +23000,8 @@ var CONFIGURABLE_LENGTH = descriptors && !fails(function () {
|
|
|
22966
23000
|
var TEMPLATE = String(String).split('String');
|
|
22967
23001
|
|
|
22968
23002
|
var makeBuiltIn = module.exports = function (value, name, options) {
|
|
22969
|
-
if (String(name)
|
|
22970
|
-
name = '[' + String(name)
|
|
23003
|
+
if (stringSlice($String(name), 0, 7) === 'Symbol(') {
|
|
23004
|
+
name = '[' + replace($String(name), /^Symbol\(([^)]*)\)/, '$1') + ']';
|
|
22971
23005
|
}
|
|
22972
23006
|
if (options && options.getter) name = 'get ' + name;
|
|
22973
23007
|
if (options && options.setter) name = 'set ' + name;
|
|
@@ -22986,7 +23020,7 @@ var makeBuiltIn = module.exports = function (value, name, options) {
|
|
|
22986
23020
|
} catch (error) { /* empty */ }
|
|
22987
23021
|
var state = enforceInternalState(value);
|
|
22988
23022
|
if (!hasOwnProperty_1(state, 'source')) {
|
|
22989
|
-
state.source =
|
|
23023
|
+
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
22990
23024
|
} return value;
|
|
22991
23025
|
};
|
|
22992
23026
|
|
|
@@ -23025,7 +23059,7 @@ var floor = Math.floor;
|
|
|
23025
23059
|
|
|
23026
23060
|
// `Math.trunc` method
|
|
23027
23061
|
// https://tc39.es/ecma262/#sec-math.trunc
|
|
23028
|
-
// eslint-disable-next-line es
|
|
23062
|
+
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
23029
23063
|
var mathTrunc = Math.trunc || function trunc(x) {
|
|
23030
23064
|
var n = +x;
|
|
23031
23065
|
return (n > 0 ? floor : ceil)(n);
|
|
@@ -23073,10 +23107,10 @@ var createMethod = function (IS_INCLUDES) {
|
|
|
23073
23107
|
var value;
|
|
23074
23108
|
// Array#includes uses SameValueZero equality algorithm
|
|
23075
23109
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
23076
|
-
if (IS_INCLUDES && el
|
|
23110
|
+
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
23077
23111
|
value = O[index++];
|
|
23078
23112
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
23079
|
-
if (value
|
|
23113
|
+
if (value !== value) return true;
|
|
23080
23114
|
// Array#indexOf ignores holes, Array#includes - not
|
|
23081
23115
|
} else for (;length > index; index++) {
|
|
23082
23116
|
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
@@ -23126,7 +23160,7 @@ var hiddenKeys$1 = enumBugKeys.concat('length', 'prototype');
|
|
|
23126
23160
|
|
|
23127
23161
|
// `Object.getOwnPropertyNames` method
|
|
23128
23162
|
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
23129
|
-
// eslint-disable-next-line es
|
|
23163
|
+
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
23130
23164
|
var f$3 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
23131
23165
|
return objectKeysInternal(O, hiddenKeys$1);
|
|
23132
23166
|
};
|
|
@@ -23135,7 +23169,7 @@ var objectGetOwnPropertyNames = {
|
|
|
23135
23169
|
f: f$3
|
|
23136
23170
|
};
|
|
23137
23171
|
|
|
23138
|
-
// eslint-disable-next-line es
|
|
23172
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
23139
23173
|
var f$4 = Object.getOwnPropertySymbols;
|
|
23140
23174
|
|
|
23141
23175
|
var objectGetOwnPropertySymbols = {
|
|
@@ -23167,8 +23201,8 @@ var replacement = /#|\.prototype\./;
|
|
|
23167
23201
|
|
|
23168
23202
|
var isForced = function (feature, detection) {
|
|
23169
23203
|
var value = data[normalize(feature)];
|
|
23170
|
-
return value
|
|
23171
|
-
: value
|
|
23204
|
+
return value === POLYFILL ? true
|
|
23205
|
+
: value === NATIVE ? false
|
|
23172
23206
|
: isCallable(detection) ? fails(detection)
|
|
23173
23207
|
: !!detection;
|
|
23174
23208
|
};
|
|
@@ -23248,7 +23282,7 @@ var TO_STRING_TAG$1 = wellKnownSymbol('toStringTag');
|
|
|
23248
23282
|
var $Object$3 = Object;
|
|
23249
23283
|
|
|
23250
23284
|
// ES3 wrong here
|
|
23251
|
-
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }())
|
|
23285
|
+
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
|
|
23252
23286
|
|
|
23253
23287
|
// fallback for IE11 Script Access Denied error
|
|
23254
23288
|
var tryGet = function (it, key) {
|
|
@@ -23266,25 +23300,25 @@ var classof = toStringTagSupport ? classofRaw : function (it) {
|
|
|
23266
23300
|
// builtinTag case
|
|
23267
23301
|
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
23268
23302
|
// ES3 arguments fallback
|
|
23269
|
-
: (result = classofRaw(O))
|
|
23303
|
+
: (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;
|
|
23270
23304
|
};
|
|
23271
23305
|
|
|
23272
|
-
var $String$
|
|
23306
|
+
var $String$3 = String;
|
|
23273
23307
|
|
|
23274
23308
|
var toString_1 = function (argument) {
|
|
23275
|
-
if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
|
|
23276
|
-
return $String$
|
|
23309
|
+
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
|
|
23310
|
+
return $String$3(argument);
|
|
23277
23311
|
};
|
|
23278
23312
|
|
|
23279
23313
|
var charAt = functionUncurryThis(''.charAt);
|
|
23280
23314
|
|
|
23281
23315
|
var FORCED = fails(function () {
|
|
23282
|
-
// eslint-disable-next-line es
|
|
23316
|
+
// eslint-disable-next-line es/no-array-string-prototype-at -- safe
|
|
23283
23317
|
return '𠮷'.at(-2) !== '\uD842';
|
|
23284
23318
|
});
|
|
23285
23319
|
|
|
23286
23320
|
// `String.prototype.at` method
|
|
23287
|
-
// https://
|
|
23321
|
+
// https://tc39.es/ecma262/#sec-string.prototype.at
|
|
23288
23322
|
_export({ target: 'String', proto: true, forced: FORCED }, {
|
|
23289
23323
|
at: function at(index) {
|
|
23290
23324
|
var S = toString_1(requireObjectCoercible(this));
|
|
@@ -23297,14 +23331,14 @@ _export({ target: 'String', proto: true, forced: FORCED }, {
|
|
|
23297
23331
|
|
|
23298
23332
|
// `Object.keys` method
|
|
23299
23333
|
// https://tc39.es/ecma262/#sec-object.keys
|
|
23300
|
-
// eslint-disable-next-line es
|
|
23334
|
+
// eslint-disable-next-line es/no-object-keys -- safe
|
|
23301
23335
|
var objectKeys = Object.keys || function keys(O) {
|
|
23302
23336
|
return objectKeysInternal(O, enumBugKeys);
|
|
23303
23337
|
};
|
|
23304
23338
|
|
|
23305
23339
|
// `Object.defineProperties` method
|
|
23306
23340
|
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
23307
|
-
// eslint-disable-next-line es
|
|
23341
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
23308
23342
|
var f$5 = descriptors && !v8PrototypeDefineBug ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
23309
23343
|
anObject(O);
|
|
23310
23344
|
var props = toIndexedObject(Properties);
|
|
@@ -23393,7 +23427,7 @@ hiddenKeys[IE_PROTO] = true;
|
|
|
23393
23427
|
|
|
23394
23428
|
// `Object.create` method
|
|
23395
23429
|
// https://tc39.es/ecma262/#sec-object.create
|
|
23396
|
-
// eslint-disable-next-line es
|
|
23430
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
23397
23431
|
var objectCreate = Object.create || function create(O, Properties) {
|
|
23398
23432
|
var result;
|
|
23399
23433
|
if (O !== null) {
|
|
@@ -23413,7 +23447,7 @@ var ArrayPrototype = Array.prototype;
|
|
|
23413
23447
|
|
|
23414
23448
|
// Array.prototype[@@unscopables]
|
|
23415
23449
|
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
23416
|
-
if (ArrayPrototype[UNSCOPABLES]
|
|
23450
|
+
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
23417
23451
|
defineProperty$1(ArrayPrototype, UNSCOPABLES, {
|
|
23418
23452
|
configurable: true,
|
|
23419
23453
|
value: objectCreate(null)
|
|
@@ -23426,7 +23460,7 @@ var addToUnscopables = function (key) {
|
|
|
23426
23460
|
};
|
|
23427
23461
|
|
|
23428
23462
|
// `Array.prototype.at` method
|
|
23429
|
-
// https://
|
|
23463
|
+
// https://tc39.es/ecma262/#sec-array.prototype.at
|
|
23430
23464
|
_export({ target: 'Array', proto: true }, {
|
|
23431
23465
|
at: function at(index) {
|
|
23432
23466
|
var O = toObject(this);
|
|
@@ -23439,13 +23473,19 @@ _export({ target: 'Array', proto: true }, {
|
|
|
23439
23473
|
|
|
23440
23474
|
addToUnscopables('at');
|
|
23441
23475
|
|
|
23442
|
-
// eslint-disable-next-line es
|
|
23443
|
-
var
|
|
23476
|
+
// eslint-disable-next-line es/no-typed-arrays -- safe
|
|
23477
|
+
var arrayBufferBasicDetection = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';
|
|
23478
|
+
|
|
23479
|
+
var defineBuiltInAccessor = function (target, name, descriptor) {
|
|
23480
|
+
if (descriptor.get) makeBuiltIn_1(descriptor.get, name, { getter: true });
|
|
23481
|
+
if (descriptor.set) makeBuiltIn_1(descriptor.set, name, { setter: true });
|
|
23482
|
+
return objectDefineProperty.f(target, name, descriptor);
|
|
23483
|
+
};
|
|
23444
23484
|
|
|
23445
23485
|
var correctPrototypeGetter = !fails(function () {
|
|
23446
23486
|
function F() { /* empty */ }
|
|
23447
23487
|
F.prototype.constructor = null;
|
|
23448
|
-
// eslint-disable-next-line es
|
|
23488
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
23449
23489
|
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
23450
23490
|
});
|
|
23451
23491
|
|
|
@@ -23455,7 +23495,7 @@ var ObjectPrototype = $Object$4.prototype;
|
|
|
23455
23495
|
|
|
23456
23496
|
// `Object.getPrototypeOf` method
|
|
23457
23497
|
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
23458
|
-
// eslint-disable-next-line es
|
|
23498
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
23459
23499
|
var objectGetPrototypeOf = correctPrototypeGetter ? $Object$4.getPrototypeOf : function (O) {
|
|
23460
23500
|
var object = toObject(O);
|
|
23461
23501
|
if (hasOwnProperty_1(object, IE_PROTO$1)) return object[IE_PROTO$1];
|
|
@@ -23465,12 +23505,19 @@ var objectGetPrototypeOf = correctPrototypeGetter ? $Object$4.getPrototypeOf : f
|
|
|
23465
23505
|
} return object instanceof $Object$4 ? ObjectPrototype : null;
|
|
23466
23506
|
};
|
|
23467
23507
|
|
|
23468
|
-
var
|
|
23508
|
+
var functionUncurryThisAccessor = function (object, key, method) {
|
|
23509
|
+
try {
|
|
23510
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
23511
|
+
return functionUncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
23512
|
+
} catch (error) { /* empty */ }
|
|
23513
|
+
};
|
|
23514
|
+
|
|
23515
|
+
var $String$4 = String;
|
|
23469
23516
|
var $TypeError$6 = TypeError;
|
|
23470
23517
|
|
|
23471
23518
|
var aPossiblePrototype = function (argument) {
|
|
23472
23519
|
if (typeof argument == 'object' || isCallable(argument)) return argument;
|
|
23473
|
-
throw $TypeError$6("Can't set " + $String$
|
|
23520
|
+
throw new $TypeError$6("Can't set " + $String$4(argument) + ' as a prototype');
|
|
23474
23521
|
};
|
|
23475
23522
|
|
|
23476
23523
|
/* eslint-disable no-proto -- safe */
|
|
@@ -23481,14 +23528,13 @@ var aPossiblePrototype = function (argument) {
|
|
|
23481
23528
|
// `Object.setPrototypeOf` method
|
|
23482
23529
|
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
23483
23530
|
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
23484
|
-
// eslint-disable-next-line es
|
|
23531
|
+
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
23485
23532
|
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
23486
23533
|
var CORRECT_SETTER = false;
|
|
23487
23534
|
var test = {};
|
|
23488
23535
|
var setter;
|
|
23489
23536
|
try {
|
|
23490
|
-
|
|
23491
|
-
setter = functionUncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
|
|
23537
|
+
setter = functionUncurryThisAccessor(Object.prototype, '__proto__', 'set');
|
|
23492
23538
|
setter(test, []);
|
|
23493
23539
|
CORRECT_SETTER = test instanceof Array;
|
|
23494
23540
|
} catch (error) { /* empty */ }
|
|
@@ -23501,14 +23547,6 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
|
|
|
23501
23547
|
};
|
|
23502
23548
|
}() : undefined);
|
|
23503
23549
|
|
|
23504
|
-
var defineProperty$2 = objectDefineProperty.f;
|
|
23505
|
-
|
|
23506
|
-
|
|
23507
|
-
|
|
23508
|
-
|
|
23509
|
-
|
|
23510
|
-
|
|
23511
|
-
|
|
23512
23550
|
var enforceInternalState = internalState.enforce;
|
|
23513
23551
|
var getInternalState = internalState.get;
|
|
23514
23552
|
var Int8Array = global_1.Int8Array;
|
|
@@ -23524,7 +23562,7 @@ var TO_STRING_TAG$2 = wellKnownSymbol('toStringTag');
|
|
|
23524
23562
|
var TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG');
|
|
23525
23563
|
var TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor';
|
|
23526
23564
|
// Fixing native typed arrays in Opera Presto crashes the browser, see #595
|
|
23527
|
-
var NATIVE_ARRAY_BUFFER_VIEWS =
|
|
23565
|
+
var NATIVE_ARRAY_BUFFER_VIEWS = arrayBufferBasicDetection && !!objectSetPrototypeOf && classof(global_1.opera) !== 'Opera';
|
|
23528
23566
|
var TYPED_ARRAY_TAG_REQUIRED = false;
|
|
23529
23567
|
var NAME, Constructor, Prototype;
|
|
23530
23568
|
|
|
@@ -23569,12 +23607,12 @@ var isTypedArray = function (it) {
|
|
|
23569
23607
|
|
|
23570
23608
|
var aTypedArray = function (it) {
|
|
23571
23609
|
if (isTypedArray(it)) return it;
|
|
23572
|
-
throw TypeError$2('Target is not a typed array');
|
|
23610
|
+
throw new TypeError$2('Target is not a typed array');
|
|
23573
23611
|
};
|
|
23574
23612
|
|
|
23575
23613
|
var aTypedArrayConstructor = function (C) {
|
|
23576
23614
|
if (isCallable(C) && (!objectSetPrototypeOf || objectIsPrototypeOf(TypedArray, C))) return C;
|
|
23577
|
-
throw TypeError$2(tryToString(C) + ' is not a typed array constructor');
|
|
23615
|
+
throw new TypeError$2(tryToString(C) + ' is not a typed array constructor');
|
|
23578
23616
|
};
|
|
23579
23617
|
|
|
23580
23618
|
var exportTypedArrayMethod = function (KEY, property, forced, options) {
|
|
@@ -23638,7 +23676,7 @@ for (NAME in BigIntArrayConstructorsList) {
|
|
|
23638
23676
|
if (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) {
|
|
23639
23677
|
// eslint-disable-next-line no-shadow -- safe
|
|
23640
23678
|
TypedArray = function TypedArray() {
|
|
23641
|
-
throw TypeError$2('Incorrect invocation');
|
|
23679
|
+
throw new TypeError$2('Incorrect invocation');
|
|
23642
23680
|
};
|
|
23643
23681
|
if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
|
|
23644
23682
|
if (global_1[NAME]) objectSetPrototypeOf(global_1[NAME], TypedArray);
|
|
@@ -23659,9 +23697,12 @@ if (NATIVE_ARRAY_BUFFER_VIEWS && objectGetPrototypeOf(Uint8ClampedArrayPrototype
|
|
|
23659
23697
|
|
|
23660
23698
|
if (descriptors && !hasOwnProperty_1(TypedArrayPrototype, TO_STRING_TAG$2)) {
|
|
23661
23699
|
TYPED_ARRAY_TAG_REQUIRED = true;
|
|
23662
|
-
|
|
23663
|
-
|
|
23664
|
-
|
|
23700
|
+
defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG$2, {
|
|
23701
|
+
configurable: true,
|
|
23702
|
+
get: function () {
|
|
23703
|
+
return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined;
|
|
23704
|
+
}
|
|
23705
|
+
});
|
|
23665
23706
|
for (NAME in TypedArrayConstructorsList) if (global_1[NAME]) {
|
|
23666
23707
|
createNonEnumerableProperty(global_1[NAME], TYPED_ARRAY_TAG, NAME);
|
|
23667
23708
|
}
|
|
@@ -23685,7 +23726,7 @@ var aTypedArray$1 = arrayBufferViewCore.aTypedArray;
|
|
|
23685
23726
|
var exportTypedArrayMethod$1 = arrayBufferViewCore.exportTypedArrayMethod;
|
|
23686
23727
|
|
|
23687
23728
|
// `%TypedArray%.prototype.at` method
|
|
23688
|
-
// https://
|
|
23729
|
+
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.at
|
|
23689
23730
|
exportTypedArrayMethod$1('at', function at(index) {
|
|
23690
23731
|
var O = aTypedArray$1(this);
|
|
23691
23732
|
var len = lengthOfArrayLike(O);
|
|
@@ -25033,9 +25074,7 @@ var CountryDropdown = function CountryDropdown(_ref) {
|
|
|
25033
25074
|
showErrors = _ref.showErrors,
|
|
25034
25075
|
onChange = _ref.onChange,
|
|
25035
25076
|
_ref$dataQa = _ref.dataQa,
|
|
25036
|
-
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa
|
|
25037
|
-
_ref$isRequired = _ref.isRequired,
|
|
25038
|
-
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
25077
|
+
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa;
|
|
25039
25078
|
return /*#__PURE__*/React__default.createElement(FormSelect$1, {
|
|
25040
25079
|
options: options,
|
|
25041
25080
|
field: field,
|
|
@@ -25045,8 +25084,7 @@ var CountryDropdown = function CountryDropdown(_ref) {
|
|
|
25045
25084
|
errorMessages: errorMessages,
|
|
25046
25085
|
showErrors: showErrors,
|
|
25047
25086
|
onChange: onChange,
|
|
25048
|
-
autocompleteValue: "country-name"
|
|
25049
|
-
required: isRequired
|
|
25087
|
+
autocompleteValue: "country-name"
|
|
25050
25088
|
});
|
|
25051
25089
|
};
|
|
25052
25090
|
|
|
@@ -25891,7 +25929,7 @@ var fallbackValues$k = {
|
|
|
25891
25929
|
};
|
|
25892
25930
|
|
|
25893
25931
|
var _excluded$p = ["showErrors", "themeValues"],
|
|
25894
|
-
_excluded2 = ["type", "labelTextWhenNoError", "errorMessages", "isNum", "isEmail", "helperModal", "field", "fieldActions", "showErrors", "formatter", "decorator", "themeValues", "background", "customHeight", "autocompleteValue", "extraStyles", "removeFromValue", "dataQa"
|
|
25932
|
+
_excluded2 = ["type", "labelTextWhenNoError", "errorMessages", "isNum", "isEmail", "helperModal", "field", "fieldActions", "showErrors", "formatter", "decorator", "themeValues", "background", "customHeight", "autocompleteValue", "extraStyles", "removeFromValue", "dataQa"];
|
|
25895
25933
|
var InputField = styled__default.input.withConfig({
|
|
25896
25934
|
displayName: "FormInput__InputField",
|
|
25897
25935
|
componentId: "sc-l094r1-0"
|
|
@@ -25926,10 +25964,7 @@ var FormattedInputField = styled__default(function (_ref8) {
|
|
|
25926
25964
|
themeValues = _ref8.themeValues,
|
|
25927
25965
|
props = _objectWithoutProperties(_ref8, _excluded$p);
|
|
25928
25966
|
|
|
25929
|
-
|
|
25930
|
-
return /*#__PURE__*/React__default.createElement(FormattedInput, isRequired ? _objectSpread2(_objectSpread2({}, props), {}, {
|
|
25931
|
-
required: true
|
|
25932
|
-
}) : _objectSpread2({}, props));
|
|
25967
|
+
return /*#__PURE__*/React__default.createElement(FormattedInput, props);
|
|
25933
25968
|
}).withConfig({
|
|
25934
25969
|
displayName: "FormInput__FormattedInputField",
|
|
25935
25970
|
componentId: "sc-l094r1-1"
|
|
@@ -25981,8 +26016,6 @@ var FormInput = function FormInput(_ref15) {
|
|
|
25981
26016
|
removeFromValue = _ref15.removeFromValue,
|
|
25982
26017
|
_ref15$dataQa = _ref15.dataQa,
|
|
25983
26018
|
dataQa = _ref15$dataQa === void 0 ? null : _ref15$dataQa,
|
|
25984
|
-
_ref15$isRequired = _ref15.isRequired,
|
|
25985
|
-
isRequired = _ref15$isRequired === void 0 ? false : _ref15$isRequired,
|
|
25986
26019
|
props = _objectWithoutProperties(_ref15, _excluded2);
|
|
25987
26020
|
|
|
25988
26021
|
var _useState = React.useState(false),
|
|
@@ -26069,8 +26102,7 @@ var FormInput = function FormInput(_ref15) {
|
|
|
26069
26102
|
$customHeight: customHeight,
|
|
26070
26103
|
$extraStyles: extraStyles,
|
|
26071
26104
|
"data-qa": dataQa || labelTextWhenNoError,
|
|
26072
|
-
autoComplete: autocompleteValue
|
|
26073
|
-
required: isRequired
|
|
26105
|
+
autoComplete: autocompleteValue
|
|
26074
26106
|
}, props)) : /*#__PURE__*/React__default.createElement(InputField, _extends({
|
|
26075
26107
|
"aria-labelledby": createIdFromString(labelTextWhenNoError),
|
|
26076
26108
|
"aria-describedby": createIdFromString(labelTextWhenNoError, "error message"),
|
|
@@ -26089,8 +26121,7 @@ var FormInput = function FormInput(_ref15) {
|
|
|
26089
26121
|
$customHeight: customHeight,
|
|
26090
26122
|
$extraStyles: extraStyles,
|
|
26091
26123
|
"data-qa": dataQa || labelTextWhenNoError,
|
|
26092
|
-
autoComplete: autocompleteValue
|
|
26093
|
-
required: isRequired
|
|
26124
|
+
autoComplete: autocompleteValue
|
|
26094
26125
|
}, props))), /*#__PURE__*/React__default.createElement(Stack, {
|
|
26095
26126
|
direction: "row",
|
|
26096
26127
|
justify: "space-between",
|
|
@@ -27196,9 +27227,7 @@ var RadioButtonWithLabel = function RadioButtonWithLabel(_ref5) {
|
|
|
27196
27227
|
_ref5$handleChange = _ref5.handleChange,
|
|
27197
27228
|
handleChange = _ref5$handleChange === void 0 ? noop : _ref5$handleChange,
|
|
27198
27229
|
field = _ref5.field,
|
|
27199
|
-
config = _ref5.config
|
|
27200
|
-
_ref5$required = _ref5.required,
|
|
27201
|
-
required = _ref5$required === void 0 ? false : _ref5$required;
|
|
27230
|
+
config = _ref5.config;
|
|
27202
27231
|
|
|
27203
27232
|
var getDefaultChecked = function getDefaultChecked(value, idx) {
|
|
27204
27233
|
var selectionExistsInConfig = config === null || config === void 0 ? void 0 : config.map(function (c) {
|
|
@@ -27231,8 +27260,7 @@ var RadioButtonWithLabel = function RadioButtonWithLabel(_ref5) {
|
|
|
27231
27260
|
setValue(e.target.value);
|
|
27232
27261
|
handleChange(e);
|
|
27233
27262
|
},
|
|
27234
|
-
defaultChecked: getDefaultChecked(value, index)
|
|
27235
|
-
required: required
|
|
27263
|
+
defaultChecked: getDefaultChecked(value, index)
|
|
27236
27264
|
}), /*#__PURE__*/React__default.createElement(Text$1, {
|
|
27237
27265
|
as: "label",
|
|
27238
27266
|
htmlFor: id,
|
|
@@ -27275,9 +27303,7 @@ var RadioButton$1 = function RadioButton(_ref2) {
|
|
|
27275
27303
|
_ref2$ariaLabelledBy = _ref2.ariaLabelledBy,
|
|
27276
27304
|
ariaLabelledBy = _ref2$ariaLabelledBy === void 0 ? "" : _ref2$ariaLabelledBy,
|
|
27277
27305
|
_ref2$ariaLabel = _ref2.ariaLabel,
|
|
27278
|
-
ariaLabel = _ref2$ariaLabel === void 0 ? null : _ref2$ariaLabel
|
|
27279
|
-
_ref2$isRequired = _ref2.isRequired,
|
|
27280
|
-
isRequired = _ref2$isRequired === void 0 ? false : _ref2$isRequired;
|
|
27306
|
+
ariaLabel = _ref2$ariaLabel === void 0 ? null : _ref2$ariaLabel;
|
|
27281
27307
|
var buttonBorder = {
|
|
27282
27308
|
onFocused: {
|
|
27283
27309
|
borderColor: themeValues.activeColor,
|
|
@@ -27337,8 +27363,7 @@ var RadioButton$1 = function RadioButton(_ref2) {
|
|
|
27337
27363
|
disabled: disabled,
|
|
27338
27364
|
onClick: toggleRadio,
|
|
27339
27365
|
"aria-describedby": ariaDescribedBy,
|
|
27340
|
-
tabIndex: "-1"
|
|
27341
|
-
required: isRequired
|
|
27366
|
+
tabIndex: "-1"
|
|
27342
27367
|
}, extraProps)), /*#__PURE__*/React__default.createElement(Motion, {
|
|
27343
27368
|
borderWidth: "1px",
|
|
27344
27369
|
borderStyle: "solid",
|
|
@@ -38731,7 +38756,7 @@ validatorFns[INCLUDED_IN] = (value, args, form) =>
|
|
|
38731
38756
|
|
|
38732
38757
|
const REQUIRED = 'validator/REQUIRED';
|
|
38733
38758
|
const REQUIRED_ERROR = 'error/REQUIRED';
|
|
38734
|
-
const required
|
|
38759
|
+
const required = createValidator(REQUIRED, REQUIRED_ERROR);
|
|
38735
38760
|
validatorFns[REQUIRED] = (value, args, form) => value !== '';
|
|
38736
38761
|
|
|
38737
38762
|
const ONLY_INTEGERS = 'validator/ONLY_INTEGERS';
|
|
@@ -39344,15 +39369,15 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39344
39369
|
}, []);
|
|
39345
39370
|
}
|
|
39346
39371
|
|
|
39347
|
-
var street1ErrorMessages = _defineProperty({}, required
|
|
39372
|
+
var street1ErrorMessages = _defineProperty({}, required.error, "Street is required");
|
|
39348
39373
|
|
|
39349
|
-
var cityErrorMessages = _defineProperty({}, required
|
|
39374
|
+
var cityErrorMessages = _defineProperty({}, required.error, "City is required");
|
|
39350
39375
|
|
|
39351
|
-
var zipErrorMessages = (_zipErrorMessages = {}, _defineProperty(_zipErrorMessages, required
|
|
39376
|
+
var zipErrorMessages = (_zipErrorMessages = {}, _defineProperty(_zipErrorMessages, required.error, "Zip code is required"), _defineProperty(_zipErrorMessages, hasLength.error, "Zip code must be 5 or 9 digits"), _zipErrorMessages);
|
|
39352
39377
|
|
|
39353
|
-
var stateProvinceErrorMessages = _defineProperty({}, required
|
|
39378
|
+
var stateProvinceErrorMessages = _defineProperty({}, required.error, "State or Province is required");
|
|
39354
39379
|
|
|
39355
|
-
var countryErrorMessages = _defineProperty({}, required
|
|
39380
|
+
var countryErrorMessages = _defineProperty({}, required.error, "Country is required");
|
|
39356
39381
|
|
|
39357
39382
|
var isUS = fields.country.rawValue === "US";
|
|
39358
39383
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
@@ -39377,8 +39402,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39377
39402
|
}
|
|
39378
39403
|
},
|
|
39379
39404
|
showErrors: showErrors,
|
|
39380
|
-
dataQa: "Country"
|
|
39381
|
-
isRequired: true
|
|
39405
|
+
dataQa: "Country"
|
|
39382
39406
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
39383
39407
|
labelTextWhenNoError: "Address",
|
|
39384
39408
|
errorMessages: street1ErrorMessages,
|
|
@@ -39389,8 +39413,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39389
39413
|
return e.key === "Enter" && handleSubmit(e);
|
|
39390
39414
|
},
|
|
39391
39415
|
autocompleteValue: "address-line1",
|
|
39392
|
-
dataQa: "Address"
|
|
39393
|
-
required: true
|
|
39416
|
+
dataQa: "Address"
|
|
39394
39417
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
39395
39418
|
labelTextWhenNoError: "Apt, Suite, Unit, Floor, etc. (Optional)",
|
|
39396
39419
|
field: fields.street2,
|
|
@@ -39400,8 +39423,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39400
39423
|
return e.key === "Enter" && handleSubmit(e);
|
|
39401
39424
|
},
|
|
39402
39425
|
autocompleteValue: "address-line2",
|
|
39403
|
-
dataQa: "Address Line 2"
|
|
39404
|
-
required: true
|
|
39426
|
+
dataQa: "Address Line 2"
|
|
39405
39427
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
39406
39428
|
labelTextWhenNoError: "City",
|
|
39407
39429
|
errorMessages: cityErrorMessages,
|
|
@@ -39412,8 +39434,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39412
39434
|
return e.key === "Enter" && handleSubmit(e);
|
|
39413
39435
|
},
|
|
39414
39436
|
autocompleteValue: "address-level2",
|
|
39415
|
-
dataQa: "City"
|
|
39416
|
-
required: true
|
|
39437
|
+
dataQa: "City"
|
|
39417
39438
|
}), /*#__PURE__*/React__default.createElement(FormStateDropdown, {
|
|
39418
39439
|
labelTextWhenNoError: isUS ? "State" : "State or Province",
|
|
39419
39440
|
errorMessages: stateProvinceErrorMessages,
|
|
@@ -39424,8 +39445,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39424
39445
|
onKeyDown: function onKeyDown(e) {
|
|
39425
39446
|
return e.key === "Enter" && handleSubmit(e);
|
|
39426
39447
|
},
|
|
39427
|
-
dataQa: "State or Province"
|
|
39428
|
-
required: true
|
|
39448
|
+
dataQa: "State or Province"
|
|
39429
39449
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
39430
39450
|
isNum: isUS,
|
|
39431
39451
|
formatter: isUS ? zipFormat : null,
|
|
@@ -39438,8 +39458,7 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39438
39458
|
return e.key === "Enter" && handleSubmit(e);
|
|
39439
39459
|
},
|
|
39440
39460
|
autocompleteValue: "postal-code",
|
|
39441
|
-
dataQa: "Zip code"
|
|
39442
|
-
required: true
|
|
39461
|
+
dataQa: "Zip code"
|
|
39443
39462
|
}), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
|
|
39444
39463
|
name: "address checkbox",
|
|
39445
39464
|
title: "Save address to wallet",
|
|
@@ -39450,23 +39469,23 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39450
39469
|
|
|
39451
39470
|
var formConfig = {
|
|
39452
39471
|
street1: {
|
|
39453
|
-
validators: [required
|
|
39472
|
+
validators: [required()]
|
|
39454
39473
|
},
|
|
39455
39474
|
street2: {
|
|
39456
39475
|
validators: []
|
|
39457
39476
|
},
|
|
39458
39477
|
city: {
|
|
39459
|
-
validators: [required
|
|
39478
|
+
validators: [required()]
|
|
39460
39479
|
},
|
|
39461
39480
|
stateProvince: {
|
|
39462
|
-
validators: [required
|
|
39481
|
+
validators: [required()]
|
|
39463
39482
|
},
|
|
39464
39483
|
country: {
|
|
39465
39484
|
defaultValue: "US",
|
|
39466
|
-
validators: [required
|
|
39485
|
+
validators: [required()]
|
|
39467
39486
|
},
|
|
39468
39487
|
zip: {
|
|
39469
|
-
validators: [required
|
|
39488
|
+
validators: [required(), validateWhen(validateWhen(hasLength(5, 5), hasLength(0, 5)), matchesRegex("US"), "country"), validateWhen(validateWhen(hasLength(9, 9), hasLength(6, 9)), matchesRegex("US"), "country")],
|
|
39470
39489
|
constraints: [validateWhen(onlyIntegers(), matchesRegex("US"), "country"), validateWhen(hasLength(0, 9), matchesRegex("US"), "country")]
|
|
39471
39490
|
}
|
|
39472
39491
|
};
|
|
@@ -39558,9 +39577,9 @@ var ChangePasswordForm = function ChangePasswordForm(_ref) {
|
|
|
39558
39577
|
}, []);
|
|
39559
39578
|
}
|
|
39560
39579
|
|
|
39561
|
-
var currentPasswordErrorMessages = _defineProperty({}, required
|
|
39580
|
+
var currentPasswordErrorMessages = _defineProperty({}, required.error, "Current Password is required");
|
|
39562
39581
|
|
|
39563
|
-
var newPasswordErrorMessages = (_newPasswordErrorMess = {}, _defineProperty(_newPasswordErrorMess, required
|
|
39582
|
+
var newPasswordErrorMessages = (_newPasswordErrorMess = {}, _defineProperty(_newPasswordErrorMess, required.error, "New Password field is required."), _defineProperty(_newPasswordErrorMess, hasLength.error, "Your new password must have at least 8 characters"), _defineProperty(_newPasswordErrorMess, hasNumber.error, "Your new password must contain at least one number"), _defineProperty(_newPasswordErrorMess, hasLowercaseLetter.error, "Your new password must contain at least one lowercase letter"), _defineProperty(_newPasswordErrorMess, hasUppercaseLetter.error, "Your new password must contain at least one uppercase letter"), _defineProperty(_newPasswordErrorMess, hasSpecialCharacter.error, "Your new password must contain at least one special character (!@#$%^&*.?)"), _newPasswordErrorMess);
|
|
39564
39583
|
|
|
39565
39584
|
var confirmNewPasswordErrorMessages = _defineProperty({}, matchesField.error, "Confirm password must match your new password");
|
|
39566
39585
|
|
|
@@ -39653,13 +39672,13 @@ var ChangePasswordForm = function ChangePasswordForm(_ref) {
|
|
|
39653
39672
|
|
|
39654
39673
|
var formConfig$1 = {
|
|
39655
39674
|
currentPassword: {
|
|
39656
|
-
validators: [required
|
|
39675
|
+
validators: [required()]
|
|
39657
39676
|
},
|
|
39658
39677
|
newPassword: {
|
|
39659
|
-
validators: [required
|
|
39678
|
+
validators: [required(), hasLength(8, 100), hasNumber(), hasLowercaseLetter(), hasUppercaseLetter(), hasSpecialCharacter()]
|
|
39660
39679
|
},
|
|
39661
39680
|
confirmNewPassword: {
|
|
39662
|
-
validators: [required
|
|
39681
|
+
validators: [required(), matchesField("newPassword")]
|
|
39663
39682
|
}
|
|
39664
39683
|
};
|
|
39665
39684
|
|
|
@@ -40002,9 +40021,9 @@ var EditNameForm = function EditNameForm(_ref) {
|
|
|
40002
40021
|
}, []);
|
|
40003
40022
|
}
|
|
40004
40023
|
|
|
40005
|
-
var firstNameErrorMessages = _defineProperty({}, required
|
|
40024
|
+
var firstNameErrorMessages = _defineProperty({}, required.error, "First name is required");
|
|
40006
40025
|
|
|
40007
|
-
var lastNameErrorMessages = _defineProperty({}, required
|
|
40026
|
+
var lastNameErrorMessages = _defineProperty({}, required.error, "Last name is required");
|
|
40008
40027
|
|
|
40009
40028
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
40010
40029
|
role: "form",
|
|
@@ -40019,8 +40038,7 @@ var EditNameForm = function EditNameForm(_ref) {
|
|
|
40019
40038
|
onKeyDown: function onKeyDown(e) {
|
|
40020
40039
|
return e.key === "Enter" && handleSubmit(e);
|
|
40021
40040
|
},
|
|
40022
|
-
autocompleteValue: "given-name"
|
|
40023
|
-
isRequired: true
|
|
40041
|
+
autocompleteValue: "given-name"
|
|
40024
40042
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
40025
40043
|
labelTextWhenNoError: "Last Name",
|
|
40026
40044
|
dataQa: "Edit Last Name",
|
|
@@ -40031,17 +40049,16 @@ var EditNameForm = function EditNameForm(_ref) {
|
|
|
40031
40049
|
onKeyDown: function onKeyDown(e) {
|
|
40032
40050
|
return e.key === "Enter" && handleSubmit(e);
|
|
40033
40051
|
},
|
|
40034
|
-
autocompleteValue: "family-name"
|
|
40035
|
-
isRequired: true
|
|
40052
|
+
autocompleteValue: "family-name"
|
|
40036
40053
|
})));
|
|
40037
40054
|
};
|
|
40038
40055
|
|
|
40039
40056
|
var formConfig$2 = {
|
|
40040
40057
|
firstName: {
|
|
40041
|
-
validators: [required
|
|
40058
|
+
validators: [required()]
|
|
40042
40059
|
},
|
|
40043
40060
|
lastName: {
|
|
40044
|
-
validators: [required
|
|
40061
|
+
validators: [required()]
|
|
40045
40062
|
}
|
|
40046
40063
|
};
|
|
40047
40064
|
|
|
@@ -40344,9 +40361,7 @@ var EmailForm = function EmailForm(_ref) {
|
|
|
40344
40361
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
|
|
40345
40362
|
showWalletCheckbox = _ref.showWalletCheckbox,
|
|
40346
40363
|
saveToWallet = _ref.saveToWallet,
|
|
40347
|
-
walletCheckboxMarked = _ref.walletCheckboxMarked
|
|
40348
|
-
_ref$isRequired = _ref.isRequired,
|
|
40349
|
-
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
40364
|
+
walletCheckboxMarked = _ref.walletCheckboxMarked;
|
|
40350
40365
|
|
|
40351
40366
|
if (clearOnDismount) {
|
|
40352
40367
|
React.useEffect(function () {
|
|
@@ -40356,14 +40371,13 @@ var EmailForm = function EmailForm(_ref) {
|
|
|
40356
40371
|
}, []);
|
|
40357
40372
|
}
|
|
40358
40373
|
|
|
40359
|
-
var emailFieldErrorMessages = (_emailFieldErrorMessa = {}, _defineProperty(_emailFieldErrorMessa, required
|
|
40374
|
+
var emailFieldErrorMessages = (_emailFieldErrorMessa = {}, _defineProperty(_emailFieldErrorMessa, required.error, "Email address is required"), _defineProperty(_emailFieldErrorMessa, isProbablyEmail.error, "Invalid email address"), _emailFieldErrorMessa);
|
|
40360
40375
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
40361
40376
|
variant: variant,
|
|
40362
40377
|
role: "form",
|
|
40363
40378
|
"aria-label": "Email address"
|
|
40364
40379
|
}, guestCheckout && /*#__PURE__*/React__default.createElement(Paragraph$1, {
|
|
40365
|
-
margin: "0 0 1.125rem 0"
|
|
40366
|
-
id: "explanation"
|
|
40380
|
+
margin: "0 0 1.125rem 0"
|
|
40367
40381
|
}, "If desired, you can create a wallet later for faster checkout"), /*#__PURE__*/React__default.createElement(FormInputColumn, null, /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
40368
40382
|
labelTextWhenNoError: "Email address",
|
|
40369
40383
|
errorMessages: emailFieldErrorMessages,
|
|
@@ -40376,20 +40390,18 @@ var EmailForm = function EmailForm(_ref) {
|
|
|
40376
40390
|
},
|
|
40377
40391
|
isEmail: true,
|
|
40378
40392
|
autocompleteValue: "email",
|
|
40379
|
-
dataQa: "Email address"
|
|
40380
|
-
required: isRequired
|
|
40393
|
+
dataQa: "Email address"
|
|
40381
40394
|
}), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
|
|
40382
40395
|
name: "email checkbox",
|
|
40383
40396
|
title: "Save email address to wallet",
|
|
40384
40397
|
checked: walletCheckboxMarked,
|
|
40385
|
-
onChange: saveToWallet
|
|
40386
|
-
"aria-describedby": "explanation"
|
|
40398
|
+
onChange: saveToWallet
|
|
40387
40399
|
})));
|
|
40388
40400
|
};
|
|
40389
40401
|
|
|
40390
40402
|
var formConfig$3 = {
|
|
40391
40403
|
email: {
|
|
40392
|
-
validators: [required
|
|
40404
|
+
validators: [required(), isProbablyEmail()]
|
|
40393
40405
|
}
|
|
40394
40406
|
};
|
|
40395
40407
|
|
|
@@ -40456,7 +40468,7 @@ var ForgotPasswordForm = function ForgotPasswordForm(_ref) {
|
|
|
40456
40468
|
}, []);
|
|
40457
40469
|
}
|
|
40458
40470
|
|
|
40459
|
-
var EmailErrorMessages = (_EmailErrorMessages = {}, _defineProperty(_EmailErrorMessages, required
|
|
40471
|
+
var EmailErrorMessages = (_EmailErrorMessages = {}, _defineProperty(_EmailErrorMessages, required.error, "Email address is required"), _defineProperty(_EmailErrorMessages, isProbablyEmail.error, "Email address is not valid"), _EmailErrorMessages);
|
|
40460
40472
|
return /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
40461
40473
|
labelTextWhenNoError: "Email address",
|
|
40462
40474
|
errorMessages: EmailErrorMessages,
|
|
@@ -40473,7 +40485,7 @@ var ForgotPasswordForm = function ForgotPasswordForm(_ref) {
|
|
|
40473
40485
|
|
|
40474
40486
|
var formConfig$4 = {
|
|
40475
40487
|
email: {
|
|
40476
|
-
validators: [required
|
|
40488
|
+
validators: [required(), isProbablyEmail()]
|
|
40477
40489
|
}
|
|
40478
40490
|
};
|
|
40479
40491
|
|
|
@@ -42135,9 +42147,9 @@ var LoginForm = function LoginForm(_ref) {
|
|
|
42135
42147
|
}, []);
|
|
42136
42148
|
}
|
|
42137
42149
|
|
|
42138
|
-
var emailErrorMessages = (_emailErrorMessages = {}, _defineProperty(_emailErrorMessages, required
|
|
42150
|
+
var emailErrorMessages = (_emailErrorMessages = {}, _defineProperty(_emailErrorMessages, required.error, "Email address is required"), _defineProperty(_emailErrorMessages, isProbablyEmail.error, "Invalid email address"), _emailErrorMessages);
|
|
42139
42151
|
|
|
42140
|
-
var passwordErrorMessages = _defineProperty({}, required
|
|
42152
|
+
var passwordErrorMessages = _defineProperty({}, required.error, "Password is required");
|
|
42141
42153
|
|
|
42142
42154
|
return /*#__PURE__*/React__default.createElement(FormInputColumn, {
|
|
42143
42155
|
role: "form",
|
|
@@ -42170,10 +42182,10 @@ var LoginForm = function LoginForm(_ref) {
|
|
|
42170
42182
|
|
|
42171
42183
|
var formConfig$5 = {
|
|
42172
42184
|
email: {
|
|
42173
|
-
validators: [required
|
|
42185
|
+
validators: [required(), isProbablyEmail()]
|
|
42174
42186
|
},
|
|
42175
42187
|
password: {
|
|
42176
|
-
validators: [required
|
|
42188
|
+
validators: [required()]
|
|
42177
42189
|
}
|
|
42178
42190
|
};
|
|
42179
42191
|
|
|
@@ -46778,7 +46790,7 @@ var PartialAmountForm = function PartialAmountForm(_ref) {
|
|
|
46778
46790
|
}, []);
|
|
46779
46791
|
}
|
|
46780
46792
|
|
|
46781
|
-
var amountErrors = (_amountErrors = {}, _defineProperty(_amountErrors, required
|
|
46793
|
+
var amountErrors = (_amountErrors = {}, _defineProperty(_amountErrors, required.error, "Amount is required"), _defineProperty(_amountErrors, numberGreaterThanOrEqualTo.error, "There is a minimum payment of ".concat(displayCurrency(minimum))), _defineProperty(_amountErrors, numberLessThanOrEqualTo.error, "There is a maximum payment of ".concat(displayCurrency(maximum))), _amountErrors);
|
|
46782
46794
|
|
|
46783
46795
|
var getPartialAmountFormErrors = function getPartialAmountFormErrors(itemAmount) {
|
|
46784
46796
|
var errorMessages = amountErrors;
|
|
@@ -46852,7 +46864,7 @@ var createPartialAmountFormState = function createPartialAmountFormState(lineIte
|
|
|
46852
46864
|
var createPartialAmountFormValidators = function createPartialAmountFormValidators(item, lineItems, maximum) {
|
|
46853
46865
|
var minimum = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 1;
|
|
46854
46866
|
var blockPartialPaymentOverpay = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
|
|
46855
|
-
var validators = [required
|
|
46867
|
+
var validators = [required(), validateSum(numberGreaterThanOrEqualTo(minimum), lineItems.filter(function (lineItem) {
|
|
46856
46868
|
return lineItem != item;
|
|
46857
46869
|
}).reduce(function (acc, curr) {
|
|
46858
46870
|
return [].concat(_toConsumableArray(acc), [curr.id]);
|
|
@@ -47914,17 +47926,17 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47914
47926
|
|
|
47915
47927
|
var showTerms = !!termsContent;
|
|
47916
47928
|
|
|
47917
|
-
var nameErrors = _defineProperty({}, required
|
|
47929
|
+
var nameErrors = _defineProperty({}, required.error, "Name is required");
|
|
47918
47930
|
|
|
47919
|
-
var routingNumberErrors = (_routingNumberErrors = {}, _defineProperty(_routingNumberErrors, required
|
|
47931
|
+
var routingNumberErrors = (_routingNumberErrors = {}, _defineProperty(_routingNumberErrors, required.error, "Routing number is required"), _defineProperty(_routingNumberErrors, hasLength.error, "Routing number must be 9 digits"), _defineProperty(_routingNumberErrors, isRoutingNumber.error, "Invalid routing number"), _routingNumberErrors);
|
|
47920
47932
|
|
|
47921
47933
|
var confirmRoutingNumberErrors = _defineProperty({}, matchesField.error, "Confirm routing number field must match routing number");
|
|
47922
47934
|
|
|
47923
|
-
var accountNumberErrors = (_accountNumberErrors = {}, _defineProperty(_accountNumberErrors, required
|
|
47935
|
+
var accountNumberErrors = (_accountNumberErrors = {}, _defineProperty(_accountNumberErrors, required.error, "Account number is required"), _defineProperty(_accountNumberErrors, hasLength.error, "Account number must be between 5 and 17 digits"), _accountNumberErrors);
|
|
47924
47936
|
|
|
47925
47937
|
var confirmAccountNumberErrors = _defineProperty({}, matchesField.error, "Confirm account number field must match account number");
|
|
47926
47938
|
|
|
47927
|
-
var accountTypeErrors = _defineProperty({}, required
|
|
47939
|
+
var accountTypeErrors = _defineProperty({}, required.error, "Account type is required");
|
|
47928
47940
|
|
|
47929
47941
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
47930
47942
|
variant: variant,
|
|
@@ -47940,8 +47952,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47940
47952
|
onKeyDown: function onKeyDown(e) {
|
|
47941
47953
|
return e.key === "Enter" && handleSubmit(e);
|
|
47942
47954
|
},
|
|
47943
|
-
autocompleteValue: "name"
|
|
47944
|
-
isRequired: true
|
|
47955
|
+
autocompleteValue: "name"
|
|
47945
47956
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
47946
47957
|
labelTextWhenNoError: "Routing number",
|
|
47947
47958
|
dataQa: "Routing number",
|
|
@@ -47963,8 +47974,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47963
47974
|
},
|
|
47964
47975
|
onKeyDown: function onKeyDown(e) {
|
|
47965
47976
|
return e.key === "Enter" && handleSubmit(e);
|
|
47966
|
-
}
|
|
47967
|
-
isRequired: true
|
|
47977
|
+
}
|
|
47968
47978
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
47969
47979
|
labelTextWhenNoError: "Confirm routing number",
|
|
47970
47980
|
dataQa: "Confirm routing number",
|
|
@@ -47975,7 +47985,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47975
47985
|
onKeyDown: function onKeyDown(e) {
|
|
47976
47986
|
return e.key === "Enter" && handleSubmit(e);
|
|
47977
47987
|
},
|
|
47978
|
-
isRequired: true,
|
|
47979
47988
|
isNum: true
|
|
47980
47989
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
47981
47990
|
labelTextWhenNoError: "Account number",
|
|
@@ -47984,7 +47993,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47984
47993
|
field: fields.accountNumber,
|
|
47985
47994
|
fieldActions: actions.fields.accountNumber,
|
|
47986
47995
|
showErrors: showErrors,
|
|
47987
|
-
isRequired: true,
|
|
47988
47996
|
isNum: true,
|
|
47989
47997
|
helperModal: function helperModal() {
|
|
47990
47998
|
return /*#__PURE__*/React__default.createElement(AccountAndRoutingModal$1, {
|
|
@@ -48002,7 +48010,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48002
48010
|
}
|
|
48003
48011
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
48004
48012
|
labelTextWhenNoError: "Confirm account number",
|
|
48005
|
-
isRequired: true,
|
|
48006
48013
|
dataQa: "Confirm account number",
|
|
48007
48014
|
errorMessages: confirmAccountNumberErrors,
|
|
48008
48015
|
field: fields.confirmAccountNumber,
|
|
@@ -48031,7 +48038,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48031
48038
|
field: fields.accountType
|
|
48032
48039
|
}), !hideDefaultPayment && /*#__PURE__*/React__default.createElement(Checkbox$1, {
|
|
48033
48040
|
title: "Save as Default Payment Method",
|
|
48034
|
-
required: true,
|
|
48035
48041
|
dataQa: "default-payment-ach",
|
|
48036
48042
|
name: "default-payment-ach",
|
|
48037
48043
|
onChange: toggleCheckbox,
|
|
@@ -48058,10 +48064,10 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48058
48064
|
|
|
48059
48065
|
var formConfig$6 = {
|
|
48060
48066
|
name: {
|
|
48061
|
-
validators: [required
|
|
48067
|
+
validators: [required()]
|
|
48062
48068
|
},
|
|
48063
48069
|
routingNumber: {
|
|
48064
|
-
validators: [required
|
|
48070
|
+
validators: [required(), hasLength(9, 9), isRoutingNumber()],
|
|
48065
48071
|
constraints: [onlyIntegers(), hasLength(0, 9)]
|
|
48066
48072
|
},
|
|
48067
48073
|
confirmRoutingNumber: {
|
|
@@ -48069,7 +48075,7 @@ var formConfig$6 = {
|
|
|
48069
48075
|
constraints: [onlyIntegers(), hasLength(0, 9)]
|
|
48070
48076
|
},
|
|
48071
48077
|
accountNumber: {
|
|
48072
|
-
validators: [required
|
|
48078
|
+
validators: [required(), hasLength(5, 17)],
|
|
48073
48079
|
constraints: [onlyIntegers(), hasLength(0, 17)]
|
|
48074
48080
|
},
|
|
48075
48081
|
confirmAccountNumber: {
|
|
@@ -48078,7 +48084,7 @@ var formConfig$6 = {
|
|
|
48078
48084
|
},
|
|
48079
48085
|
accountType: {
|
|
48080
48086
|
defaultValue: "CHECKING",
|
|
48081
|
-
validators: [required
|
|
48087
|
+
validators: [required()]
|
|
48082
48088
|
}
|
|
48083
48089
|
};
|
|
48084
48090
|
|
|
@@ -48129,14 +48135,14 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48129
48135
|
}
|
|
48130
48136
|
}, []);
|
|
48131
48137
|
|
|
48132
|
-
var nameOnCardErrors = _defineProperty({}, required
|
|
48138
|
+
var nameOnCardErrors = _defineProperty({}, required.error, "Name is required");
|
|
48133
48139
|
|
|
48134
|
-
var creditCardNumberErrors = (_creditCardNumberErro = {}, _defineProperty(_creditCardNumberErro, required
|
|
48135
|
-
var expirationDateErrors = (_expirationDateErrors = {}, _defineProperty(_expirationDateErrors, required
|
|
48136
|
-
var cvvErrors = (_cvvErrors = {}, _defineProperty(_cvvErrors, required
|
|
48137
|
-
var zipCodeErrors = (_zipCodeErrors = {}, _defineProperty(_zipCodeErrors, required
|
|
48140
|
+
var creditCardNumberErrors = (_creditCardNumberErro = {}, _defineProperty(_creditCardNumberErro, required.error, "Credit card number is required"), _defineProperty(_creditCardNumberErro, hasLength.error, "Credit card number is invalid"), _defineProperty(_creditCardNumberErro, matchesRegex.error, "".concat(displayCardBrand(fields.creditCardNumber.rawValue), " is not accepted")), _creditCardNumberErro);
|
|
48141
|
+
var expirationDateErrors = (_expirationDateErrors = {}, _defineProperty(_expirationDateErrors, required.error, "Expiration date is required"), _defineProperty(_expirationDateErrors, hasLength.error, "Expiration date is invalid"), _defineProperty(_expirationDateErrors, isValidMonth.error, "Expiration month is invalid"), _defineProperty(_expirationDateErrors, dateAfterToday.error, "Expiration date is invalid"), _expirationDateErrors);
|
|
48142
|
+
var cvvErrors = (_cvvErrors = {}, _defineProperty(_cvvErrors, required.error, "CVV is required"), _defineProperty(_cvvErrors, hasLength.error, "CVV is invalid"), _cvvErrors);
|
|
48143
|
+
var zipCodeErrors = (_zipCodeErrors = {}, _defineProperty(_zipCodeErrors, required.error, "Zip code is required"), _defineProperty(_zipCodeErrors, hasLength.error, "Zip code is invalid"), _zipCodeErrors);
|
|
48138
48144
|
|
|
48139
|
-
var countryErrorMessages = _defineProperty({}, required
|
|
48145
|
+
var countryErrorMessages = _defineProperty({}, required.error, "Country is required");
|
|
48140
48146
|
|
|
48141
48147
|
var isUS = fields.country.rawValue === "US";
|
|
48142
48148
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
@@ -48156,8 +48162,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48156
48162
|
}
|
|
48157
48163
|
},
|
|
48158
48164
|
showErrors: showErrors,
|
|
48159
|
-
dataQa: "Country"
|
|
48160
|
-
isRequired: true
|
|
48165
|
+
dataQa: "Country"
|
|
48161
48166
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
48162
48167
|
labelTextWhenNoError: "Name on card",
|
|
48163
48168
|
dataQa: "Name on card",
|
|
@@ -48168,8 +48173,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48168
48173
|
onKeyDown: function onKeyDown(e) {
|
|
48169
48174
|
return e.key === "Enter" && handleSubmit(e);
|
|
48170
48175
|
},
|
|
48171
|
-
autocompleteValue: "cc-name"
|
|
48172
|
-
required: true
|
|
48176
|
+
autocompleteValue: "cc-name"
|
|
48173
48177
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
48174
48178
|
labelTextWhenNoError: "Credit card number",
|
|
48175
48179
|
dataQa: "Credit card number",
|
|
@@ -48182,8 +48186,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48182
48186
|
return e.key === "Enter" && handleSubmit(e);
|
|
48183
48187
|
},
|
|
48184
48188
|
isNum: true,
|
|
48185
|
-
autocompleteValue: "cc-number"
|
|
48186
|
-
required: true
|
|
48189
|
+
autocompleteValue: "cc-number"
|
|
48187
48190
|
}), /*#__PURE__*/React__default.createElement(FormInputRow, {
|
|
48188
48191
|
breakpoint: isMobile ? "1000rem" : "21rem",
|
|
48189
48192
|
childGap: isMobile ? "0rem" : "1rem"
|
|
@@ -48201,8 +48204,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48201
48204
|
isNum: true,
|
|
48202
48205
|
removeFromValue: /\// // removes "/" from browser autofill
|
|
48203
48206
|
,
|
|
48204
|
-
autocompleteValue: "cc-exp"
|
|
48205
|
-
required: true
|
|
48207
|
+
autocompleteValue: "cc-exp"
|
|
48206
48208
|
}), /*#__PURE__*/React__default.createElement(FormInput$1, {
|
|
48207
48209
|
labelTextWhenNoError: "CVV",
|
|
48208
48210
|
dataQa: "CVV",
|
|
@@ -48215,8 +48217,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48215
48217
|
onKeyDown: function onKeyDown(e) {
|
|
48216
48218
|
return e.key === "Enter" && handleSubmit(e);
|
|
48217
48219
|
},
|
|
48218
|
-
autocompleteValue: "cc-csc"
|
|
48219
|
-
required: true
|
|
48220
|
+
autocompleteValue: "cc-csc"
|
|
48220
48221
|
})), !hideZipCode && /*#__PURE__*/React__default.createElement(Box, {
|
|
48221
48222
|
padding: isMobile ? "0" : "0 0.5rem 0 0",
|
|
48222
48223
|
width: isMobile ? "100%" : "50%"
|
|
@@ -48232,8 +48233,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48232
48233
|
onKeyDown: function onKeyDown(e) {
|
|
48233
48234
|
return e.key === "Enter" && handleSubmit(e);
|
|
48234
48235
|
},
|
|
48235
|
-
autocompleteValue: "billing postal-code"
|
|
48236
|
-
required: true
|
|
48236
|
+
autocompleteValue: "billing postal-code"
|
|
48237
48237
|
})), (showWalletCheckbox || showTerms) && /*#__PURE__*/React__default.createElement(Cluster, {
|
|
48238
48238
|
childGap: "4px",
|
|
48239
48239
|
align: "center"
|
|
@@ -48258,25 +48258,25 @@ var PaymentFormCard$1 = withWindowSize(PaymentFormCard);
|
|
|
48258
48258
|
var formConfig$7 = {
|
|
48259
48259
|
country: {
|
|
48260
48260
|
defaultValue: "US",
|
|
48261
|
-
validators: [required
|
|
48261
|
+
validators: [required()]
|
|
48262
48262
|
},
|
|
48263
48263
|
nameOnCard: {
|
|
48264
|
-
validators: [required
|
|
48264
|
+
validators: [required()]
|
|
48265
48265
|
},
|
|
48266
48266
|
creditCardNumber: {
|
|
48267
|
-
validators: [required
|
|
48267
|
+
validators: [required(), hasLength(15, 16)],
|
|
48268
48268
|
constraints: [onlyIntegers(), hasLength(0, 16)]
|
|
48269
48269
|
},
|
|
48270
48270
|
expirationDate: {
|
|
48271
|
-
validators: [required
|
|
48271
|
+
validators: [required(), hasLength(4, 4), isValidMonth(0), dateAfterToday("MMYY", "month", true)],
|
|
48272
48272
|
constraints: [onlyExpirationDate(), hasLength(0, 4)]
|
|
48273
48273
|
},
|
|
48274
48274
|
cvv: {
|
|
48275
|
-
validators: [required
|
|
48275
|
+
validators: [required(), hasLength(3, 4)],
|
|
48276
48276
|
constraints: [onlyIntegers(), hasLength(0, 4)]
|
|
48277
48277
|
},
|
|
48278
48278
|
zipCode: {
|
|
48279
|
-
validators: [required
|
|
48279
|
+
validators: [required(), validateWhen(validateWhen(hasLength(5, 5), hasLength(0, 5)), matchesRegex("US"), "country"), validateWhen(validateWhen(hasLength(9, 9), hasLength(6, 9)), matchesRegex("US"), "country")],
|
|
48280
48280
|
constraints: [validateWhen(onlyIntegers(), matchesRegex("US"), "country"), validateWhen(hasLength(0, 9), matchesRegex("US"), "country")]
|
|
48281
48281
|
}
|
|
48282
48282
|
};
|
|
@@ -48426,9 +48426,7 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48426
48426
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
|
|
48427
48427
|
showWalletCheckbox = _ref.showWalletCheckbox,
|
|
48428
48428
|
saveToWallet = _ref.saveToWallet,
|
|
48429
|
-
walletCheckboxMarked = _ref.walletCheckboxMarked
|
|
48430
|
-
_ref$isRequired = _ref.isRequired,
|
|
48431
|
-
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
48429
|
+
walletCheckboxMarked = _ref.walletCheckboxMarked;
|
|
48432
48430
|
|
|
48433
48431
|
if (clearOnDismount) {
|
|
48434
48432
|
React.useEffect(function () {
|
|
@@ -48438,7 +48436,7 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48438
48436
|
}, []);
|
|
48439
48437
|
}
|
|
48440
48438
|
|
|
48441
|
-
var phoneErrorMessage = (_phoneErrorMessage = {}, _defineProperty(_phoneErrorMessage, required
|
|
48439
|
+
var phoneErrorMessage = (_phoneErrorMessage = {}, _defineProperty(_phoneErrorMessage, required.error, "Phone number is required"), _defineProperty(_phoneErrorMessage, hasLength.error, "Phone number must be 10 digits"), _phoneErrorMessage);
|
|
48442
48440
|
return /*#__PURE__*/React__default.createElement(FormContainer$1, {
|
|
48443
48441
|
variant: variant,
|
|
48444
48442
|
role: "form",
|
|
@@ -48455,8 +48453,7 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48455
48453
|
},
|
|
48456
48454
|
autocompleteValue: "tel-national",
|
|
48457
48455
|
dataQa: "Phone number",
|
|
48458
|
-
isNum: true
|
|
48459
|
-
required: isRequired
|
|
48456
|
+
isNum: true
|
|
48460
48457
|
}), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
|
|
48461
48458
|
name: "phone checkbox",
|
|
48462
48459
|
title: "Save phone number to wallet",
|
|
@@ -48467,7 +48464,7 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48467
48464
|
|
|
48468
48465
|
var formConfig$8 = {
|
|
48469
48466
|
phone: {
|
|
48470
|
-
validators: [required
|
|
48467
|
+
validators: [required(), hasLength(10, 10)],
|
|
48471
48468
|
constraints: [onlyIntegers(), hasLength(0, 10)]
|
|
48472
48469
|
}
|
|
48473
48470
|
};
|
|
@@ -48505,27 +48502,20 @@ var RadioGroup = function RadioGroup(_ref) {
|
|
|
48505
48502
|
_ref$handleChange = _ref.handleChange,
|
|
48506
48503
|
handleChange = _ref$handleChange === void 0 ? noop : _ref$handleChange,
|
|
48507
48504
|
field = _ref.field,
|
|
48508
|
-
fieldActions = _ref.fieldActions
|
|
48509
|
-
_ref$role = _ref.role,
|
|
48510
|
-
role = _ref$role === void 0 ? "radiogroup" : _ref$role,
|
|
48511
|
-
_ref$isRequired = _ref.isRequired,
|
|
48512
|
-
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
48505
|
+
fieldActions = _ref.fieldActions;
|
|
48513
48506
|
|
|
48514
48507
|
var setValue = function setValue(value) {
|
|
48515
48508
|
return fieldActions.set(value);
|
|
48516
48509
|
};
|
|
48517
48510
|
|
|
48518
48511
|
return /*#__PURE__*/React__default.createElement(StyledFieldset, {
|
|
48512
|
+
role: "radiogroup",
|
|
48513
|
+
"aria-labelledby": "radio-group-".concat(groupName, "-heading"),
|
|
48519
48514
|
$extraStyles: extraStyles
|
|
48520
48515
|
}, Heading !== null && Heading, /*#__PURE__*/React__default.createElement(Stack, {
|
|
48521
|
-
childGap: "4px"
|
|
48522
|
-
role: role,
|
|
48523
|
-
required: isRequired,
|
|
48524
|
-
"aria-labelledby": "radio-group-".concat(groupName, "-heading")
|
|
48516
|
+
childGap: "4px"
|
|
48525
48517
|
}, config.map(function (c, idx) {
|
|
48526
48518
|
return /*#__PURE__*/React__default.createElement(RadioButtonWithLabel$1, _extends({
|
|
48527
|
-
required: isRequired,
|
|
48528
|
-
role: "radio",
|
|
48529
48519
|
index: idx,
|
|
48530
48520
|
key: c.id
|
|
48531
48521
|
}, c, {
|
|
@@ -48596,13 +48586,7 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48596
48586
|
openHeight = _ref$openHeight === void 0 ? "auto" : _ref$openHeight,
|
|
48597
48587
|
_ref$containerStyles = _ref.containerStyles,
|
|
48598
48588
|
containerStyles = _ref$containerStyles === void 0 ? "" : _ref$containerStyles,
|
|
48599
|
-
ariaDescribedBy = _ref.ariaDescribedBy
|
|
48600
|
-
_ref$role = _ref.role,
|
|
48601
|
-
role = _ref$role === void 0 ? "radiogroup" : _ref$role,
|
|
48602
|
-
_ref$required = _ref.required,
|
|
48603
|
-
required = _ref$required === void 0 ? false : _ref$required,
|
|
48604
|
-
_ref$label = _ref.label,
|
|
48605
|
-
label = _ref$label === void 0 ? "" : _ref$label;
|
|
48589
|
+
ariaDescribedBy = _ref.ariaDescribedBy;
|
|
48606
48590
|
|
|
48607
48591
|
var handleKeyDown = function handleKeyDown(id, e) {
|
|
48608
48592
|
if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13 || (e === null || e === void 0 ? void 0 : e.keyCode) === 32) {
|
|
@@ -48655,11 +48639,10 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48655
48639
|
padding: "1px",
|
|
48656
48640
|
border: "1px solid ".concat(themeValues.borderColor),
|
|
48657
48641
|
borderRadius: "4px",
|
|
48658
|
-
extraStyles: containerStyles
|
|
48659
|
-
role: role,
|
|
48660
|
-
required: required
|
|
48642
|
+
extraStyles: containerStyles
|
|
48661
48643
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
48662
|
-
childGap: "0"
|
|
48644
|
+
childGap: "0",
|
|
48645
|
+
role: "radiogroup"
|
|
48663
48646
|
}, sections.filter(function (section) {
|
|
48664
48647
|
return !section.hidden;
|
|
48665
48648
|
}).map(function (section) {
|
|
@@ -48681,8 +48664,7 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48681
48664
|
extraStyles: borderStyles,
|
|
48682
48665
|
role: "radio",
|
|
48683
48666
|
"aria-checked": openSection === section.id,
|
|
48684
|
-
"aria-disabled": section.disabled
|
|
48685
|
-
"aria-label": label || section.title
|
|
48667
|
+
"aria-disabled": section.disabled
|
|
48686
48668
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
48687
48669
|
childGap: "0"
|
|
48688
48670
|
}, /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -48720,8 +48702,7 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48720
48702
|
toggleRadio: section.disabled ? noop : function () {
|
|
48721
48703
|
return toggleOpenSection(section.id);
|
|
48722
48704
|
},
|
|
48723
|
-
tabIndex: "-1"
|
|
48724
|
-
isRequired: required
|
|
48705
|
+
tabIndex: "-1"
|
|
48725
48706
|
})), section.titleIcon && /*#__PURE__*/React__default.createElement(Cluster, {
|
|
48726
48707
|
align: "center"
|
|
48727
48708
|
}, section.titleIcon), /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -48780,12 +48761,12 @@ var RegistrationForm = function RegistrationForm(_ref) {
|
|
|
48780
48761
|
}, []);
|
|
48781
48762
|
}
|
|
48782
48763
|
|
|
48783
|
-
var firstNameErrorMessages = _defineProperty({}, required
|
|
48764
|
+
var firstNameErrorMessages = _defineProperty({}, required.error, "First name is required");
|
|
48784
48765
|
|
|
48785
|
-
var lastNameErrorMessages = _defineProperty({}, required
|
|
48766
|
+
var lastNameErrorMessages = _defineProperty({}, required.error, "Last name is required");
|
|
48786
48767
|
|
|
48787
|
-
var emailErrorMessages = (_emailErrorMessages = {}, _defineProperty(_emailErrorMessages, required
|
|
48788
|
-
var passwordErrorMessages = (_passwordErrorMessage = {}, _defineProperty(_passwordErrorMessage, required
|
|
48768
|
+
var emailErrorMessages = (_emailErrorMessages = {}, _defineProperty(_emailErrorMessages, required.error, "Email is required"), _defineProperty(_emailErrorMessages, isProbablyEmail.error, "Invalid email address"), _emailErrorMessages);
|
|
48769
|
+
var passwordErrorMessages = (_passwordErrorMessage = {}, _defineProperty(_passwordErrorMessage, required.error, "Password is required"), _defineProperty(_passwordErrorMessage, hasLength.error, "Password must have at least 8 characters"), _defineProperty(_passwordErrorMessage, hasNumber.error, "Password must contain at least one number"), _defineProperty(_passwordErrorMessage, hasLowercaseLetter.error, "Password must contain at least one lowercase letter"), _defineProperty(_passwordErrorMessage, hasUppercaseLetter.error, "Password must contain at least one uppercase letter"), _defineProperty(_passwordErrorMessage, hasSpecialCharacter.error, "Password must contain at least one special character (!@#$%^&*.?)"), _passwordErrorMessage);
|
|
48789
48770
|
|
|
48790
48771
|
var confirmPasswordErrorMessages = _defineProperty({}, matchesField.error, "Confirm password must match password");
|
|
48791
48772
|
|
|
@@ -48861,19 +48842,19 @@ var RegistrationForm = function RegistrationForm(_ref) {
|
|
|
48861
48842
|
|
|
48862
48843
|
var formConfig$9 = {
|
|
48863
48844
|
firstName: {
|
|
48864
|
-
validators: [required
|
|
48845
|
+
validators: [required()]
|
|
48865
48846
|
},
|
|
48866
48847
|
lastName: {
|
|
48867
|
-
validators: [required
|
|
48848
|
+
validators: [required()]
|
|
48868
48849
|
},
|
|
48869
48850
|
email: {
|
|
48870
|
-
validators: [required
|
|
48851
|
+
validators: [required(), isProbablyEmail()]
|
|
48871
48852
|
},
|
|
48872
48853
|
password: {
|
|
48873
|
-
validators: [required
|
|
48854
|
+
validators: [required(), hasLength(8, 100), hasNumber(), hasLowercaseLetter(), hasUppercaseLetter(), hasSpecialCharacter()]
|
|
48874
48855
|
},
|
|
48875
48856
|
confirmPassword: {
|
|
48876
|
-
validators: [required
|
|
48857
|
+
validators: [required(), matchesField("password")]
|
|
48877
48858
|
}
|
|
48878
48859
|
};
|
|
48879
48860
|
|
|
@@ -48954,7 +48935,7 @@ var ResetPasswordForm = function ResetPasswordForm(_ref) {
|
|
|
48954
48935
|
}, []);
|
|
48955
48936
|
}
|
|
48956
48937
|
|
|
48957
|
-
var passwordErrorMessages = (_passwordErrorMessage = {}, _defineProperty(_passwordErrorMessage, required
|
|
48938
|
+
var passwordErrorMessages = (_passwordErrorMessage = {}, _defineProperty(_passwordErrorMessage, required.error, "Password is required"), _defineProperty(_passwordErrorMessage, hasLength.error, "Password must have at least 8 characters"), _defineProperty(_passwordErrorMessage, hasNumber.error, "Password must contain at least one number"), _defineProperty(_passwordErrorMessage, hasLowercaseLetter.error, "Password must contain at least one lowercase letter"), _defineProperty(_passwordErrorMessage, hasUppercaseLetter.error, "Password must contain at least one uppercase letter"), _defineProperty(_passwordErrorMessage, hasSpecialCharacter.error, "Password must contain at least one special character (!@#$%^&*.?)"), _passwordErrorMessage);
|
|
48958
48939
|
|
|
48959
48940
|
var confirmPasswordErrorMessages = _defineProperty({}, matchesField.error, "Confirm password must match password");
|
|
48960
48941
|
|
|
@@ -48993,10 +48974,10 @@ var ResetPasswordForm = function ResetPasswordForm(_ref) {
|
|
|
48993
48974
|
|
|
48994
48975
|
var formConfig$a = {
|
|
48995
48976
|
password: {
|
|
48996
|
-
validators: [required
|
|
48977
|
+
validators: [required(), hasLength(8, 100), hasNumber(), hasLowercaseLetter(), hasUppercaseLetter(), hasSpecialCharacter()]
|
|
48997
48978
|
},
|
|
48998
48979
|
confirmPassword: {
|
|
48999
|
-
validators: [required
|
|
48980
|
+
validators: [required(), matchesField("password")]
|
|
49000
48981
|
}
|
|
49001
48982
|
};
|
|
49002
48983
|
|
|
@@ -49381,11 +49362,11 @@ var CenterSingle = function CenterSingle(_ref) {
|
|
|
49381
49362
|
}), /*#__PURE__*/React__default.createElement(Box, {
|
|
49382
49363
|
padding: "0",
|
|
49383
49364
|
minWidth: "100%",
|
|
49384
|
-
extraStyles: "z-index: 1;"
|
|
49385
|
-
role: "main"
|
|
49365
|
+
extraStyles: "z-index: 1;"
|
|
49386
49366
|
}, subHeader && !(isMobile && hideMobileSubHeader) ? subHeader : /*#__PURE__*/React__default.createElement(React.Fragment, null), /*#__PURE__*/React__default.createElement(Center, {
|
|
49387
49367
|
maxWidth: isMobile && fullWidthMobile ? "100%" : maxContentWidth,
|
|
49388
|
-
intrinsic: !isMobile
|
|
49368
|
+
intrinsic: !isMobile,
|
|
49369
|
+
role: "main"
|
|
49389
49370
|
}, centeredMobileContent ? /*#__PURE__*/React__default.createElement(Cover, {
|
|
49390
49371
|
minHeight: "100%",
|
|
49391
49372
|
singleChild: true
|
|
@@ -49411,7 +49392,9 @@ var CenterStack = function CenterStack(_ref) {
|
|
|
49411
49392
|
_ref$fullWidthMobile = _ref.fullWidthMobile,
|
|
49412
49393
|
fullWidthMobile = _ref$fullWidthMobile === void 0 ? true : _ref$fullWidthMobile,
|
|
49413
49394
|
content = _ref.content,
|
|
49414
|
-
themeValues = _ref.themeValues
|
|
49395
|
+
themeValues = _ref.themeValues,
|
|
49396
|
+
_ref$role = _ref.role,
|
|
49397
|
+
role = _ref$role === void 0 ? "main" : _ref$role;
|
|
49415
49398
|
var themeContext = React.useContext(styled.ThemeContext);
|
|
49416
49399
|
var isMobile = themeContext.isMobile;
|
|
49417
49400
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -49423,11 +49406,11 @@ var CenterStack = function CenterStack(_ref) {
|
|
|
49423
49406
|
padding: "0"
|
|
49424
49407
|
}), /*#__PURE__*/React__default.createElement(Box, {
|
|
49425
49408
|
padding: "0",
|
|
49426
|
-
minWidth: "100%"
|
|
49427
|
-
role: "main"
|
|
49409
|
+
minWidth: "100%"
|
|
49428
49410
|
}, subHeader && !(isMobile && hideMobileSubHeader) ? subHeader : /*#__PURE__*/React__default.createElement(React.Fragment, null), /*#__PURE__*/React__default.createElement(Center, {
|
|
49429
49411
|
maxWidth: isMobile && fullWidthMobile ? "100%" : maxContentWidth,
|
|
49430
|
-
intrinsic: !isMobile
|
|
49412
|
+
intrinsic: !isMobile,
|
|
49413
|
+
role: role
|
|
49431
49414
|
}, /*#__PURE__*/React__default.createElement(Cover, {
|
|
49432
49415
|
minHeight: "100%",
|
|
49433
49416
|
singleChild: true
|
|
@@ -49473,11 +49456,11 @@ var CenterSingle$2 = function CenterSingle(_ref) {
|
|
|
49473
49456
|
padding: "0",
|
|
49474
49457
|
minWidth: "100%",
|
|
49475
49458
|
minHeight: "100%",
|
|
49476
|
-
extraStyles: "z-index: 1;"
|
|
49477
|
-
role: "main"
|
|
49459
|
+
extraStyles: "z-index: 1;"
|
|
49478
49460
|
}, subHeader && !(isMobile && hideMobileSubHeader) ? subHeader : /*#__PURE__*/React__default.createElement(React.Fragment, null), /*#__PURE__*/React__default.createElement(Center, {
|
|
49479
49461
|
maxWidth: maxWidth,
|
|
49480
|
-
gutters: gutters
|
|
49462
|
+
gutters: gutters,
|
|
49463
|
+
role: "main"
|
|
49481
49464
|
}, content)), footer ? footer : /*#__PURE__*/React__default.createElement(Box, {
|
|
49482
49465
|
padding: "0"
|
|
49483
49466
|
})));
|