@thecb/components 9.3.1-beta.0 → 9.3.4-beta.0
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 +865 -583
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +171 -60
- package/dist/index.esm.js +862 -583
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/.DS_Store +0 -0
- package/src/components/atoms/button-with-action/ButtonWithAction.js +76 -70
- package/src/components/atoms/checkbox/Checkbox.js +8 -1
- package/src/components/atoms/checkbox/Checkbox.stories.js +1 -0
- package/src/components/atoms/country-dropdown/CountryDropdown.js +2 -0
- package/src/components/atoms/dropdown/Dropdown.js +78 -41
- package/src/components/atoms/dropdown/Dropdown.theme.js +8 -2
- package/src/components/atoms/form-layouts/FormInput.js +3 -0
- package/src/components/atoms/form-select/FormSelect.js +19 -15
- package/src/components/atoms/icons/AccountNumberImage.js +2 -0
- package/src/components/atoms/icons/BankIcon.js +2 -0
- package/src/components/atoms/icons/CheckmarkIcon.js +2 -0
- package/src/components/atoms/icons/GenericCard.js +2 -0
- package/src/components/atoms/icons/GenericCardLarge.js +2 -0
- package/src/components/atoms/icons/KebabMenuIcon.d.ts +1 -0
- package/src/components/atoms/icons/KebabMenuIcon.js +38 -0
- package/src/components/atoms/icons/RoutingNumberImage.js +2 -0
- package/src/components/atoms/icons/TrashIcon.js +42 -40
- package/src/components/atoms/icons/icons.stories.js +3 -1
- package/src/components/atoms/icons/index.d.ts +1 -0
- package/src/components/atoms/icons/index.js +3 -1
- package/src/components/atoms/state-province-dropdown/StateProvinceDropdown.js +3 -1
- package/src/components/molecules/address-form/AddressForm.js +5 -0
- package/src/components/molecules/email-form/EmailForm.js +3 -1
- package/src/components/molecules/index.d.ts +1 -0
- package/src/components/molecules/index.js +1 -0
- package/src/components/molecules/modal/Modal.js +2 -1
- package/src/components/molecules/payment-form-ach/PaymentFormACH.js +6 -0
- package/src/components/molecules/payment-form-card/PaymentFormCard.js +5 -0
- package/src/components/molecules/phone-form/PhoneForm.js +3 -1
- package/src/components/molecules/popover/Popover.js +1 -1
- package/src/components/molecules/popup-menu/PopupMenu.js +152 -0
- package/src/components/molecules/popup-menu/PopupMenu.stories.js +40 -0
- package/src/components/molecules/popup-menu/PopupMenu.styled.js +20 -0
- package/src/components/molecules/popup-menu/PopupMenu.theme.js +11 -0
- package/src/components/molecules/popup-menu/index.d.ts +25 -0
- package/src/components/molecules/popup-menu/index.js +3 -0
- package/src/components/molecules/popup-menu/popup-menu-item/PopupMenuItem.js +79 -0
- package/src/components/molecules/popup-menu/popup-menu-item/PopupMenuItem.styled.js +27 -0
- package/src/components/molecules/popup-menu/popup-menu-item/PopupMenuItem.theme.js +23 -0
- package/src/components/molecules/radio-section/RadioSection.js +8 -2
- package/src/components/molecules/radio-section/RadioSection.stories.js +4 -2
- package/src/components/molecules/radio-section/radio-button/RadioButton.js +3 -1
- package/src/components/molecules/terms-and-conditions/TermsAndConditions.stories.js +3 -1
- package/src/components/molecules/terms-and-conditions/TermsAndConditionsControlV2.js +5 -1
- package/src/components/molecules/toast-notification/ToastNotification.js +75 -0
- package/src/components/molecules/toast-notification/ToastNotification.stories.js +67 -0
- package/src/components/molecules/toast-notification/index.d.ts +18 -0
- package/src/components/molecules/toast-notification/index.js +3 -0
- package/src/constants/colors.d.ts +1 -0
- package/src/constants/colors.js +5 -1
- package/src/hooks/index.js +3 -0
- package/src/hooks/use-toast-notification/index.d.ts +23 -0
- package/src/hooks/use-toast-notification/index.js +38 -0
- package/src/index.d.ts +2 -1
- package/src/index.js +2 -1
- package/src/types/common/ToastVariants.ts +6 -0
- package/src/types/common/index.ts +1 -0
- package/src/util/index.js +10 -2
- package/dist/src/apps/checkout/pages/payment/sub-pages/payment-amount/PaymentAmount_old.js +0 -49322
- 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/src/{util/useOutsideClick.js → hooks/use-outside-click/index.js} +0 -0
- /package/src/{util/useScrollTo.js → hooks/use-scroll-to/index.js} +0 -0
package/dist/index.esm.js
CHANGED
|
@@ -5011,6 +5011,7 @@ var INFO_BLUE = "#E4F4FD";
|
|
|
5011
5011
|
var CORNFLOWER_BLUE = "#EBEFFB";
|
|
5012
5012
|
var HOVER_LIGHT_BLUE = "#EFFAFF";
|
|
5013
5013
|
var MATISSE_BLUE = "#15749D";
|
|
5014
|
+
var MATISSE_BLUE_DARK = "#105C7D";
|
|
5014
5015
|
var ROYAL_BLUE = "#3181E3";
|
|
5015
5016
|
var ROYAL_BLUE_VIVID = "#3B5BDB";
|
|
5016
5017
|
var ASTRAL_BLUE = "#3176AA";
|
|
@@ -5043,7 +5044,8 @@ var FANTASY_RED = "#FCF4F4";
|
|
|
5043
5044
|
var COSMOS_RED = "#FFD0D3";
|
|
5044
5045
|
var BLUSH_RED = "#FFF0F5"; // Second level color constants
|
|
5045
5046
|
|
|
5046
|
-
var ERROR_COLOR = RAZZMATAZZ_RED;
|
|
5047
|
+
var ERROR_COLOR = RAZZMATAZZ_RED;
|
|
5048
|
+
var ERROR_BACKGROUND_COLOR = "#FFF4F8"; // These colors are sequestered so that the alert component can reference them // by type of alert
|
|
5047
5049
|
|
|
5048
5050
|
var ALERT_COLORS = {
|
|
5049
5051
|
warn: {
|
|
@@ -5145,6 +5147,7 @@ var colors = /*#__PURE__*/Object.freeze({
|
|
|
5145
5147
|
BOSTON_BLUE: BOSTON_BLUE,
|
|
5146
5148
|
HOVER_LIGHT_BLUE: HOVER_LIGHT_BLUE,
|
|
5147
5149
|
MATISSE_BLUE: MATISSE_BLUE,
|
|
5150
|
+
MATISSE_BLUE_DARK: MATISSE_BLUE_DARK,
|
|
5148
5151
|
ROYAL_BLUE: ROYAL_BLUE,
|
|
5149
5152
|
ROYAL_BLUE_VIVID: ROYAL_BLUE_VIVID,
|
|
5150
5153
|
ASTRAL_BLUE: ASTRAL_BLUE,
|
|
@@ -5174,7 +5177,8 @@ var colors = /*#__PURE__*/Object.freeze({
|
|
|
5174
5177
|
RASPBERRY: RASPBERRY,
|
|
5175
5178
|
ALERT_COLORS: ALERT_COLORS,
|
|
5176
5179
|
PILL_COLORS: PILL_COLORS,
|
|
5177
|
-
ERROR_COLOR: ERROR_COLOR
|
|
5180
|
+
ERROR_COLOR: ERROR_COLOR,
|
|
5181
|
+
ERROR_BACKGROUND_COLOR: ERROR_BACKGROUND_COLOR
|
|
5178
5182
|
});
|
|
5179
5183
|
|
|
5180
5184
|
var TextSpan = styled.span.withConfig({
|
|
@@ -12914,7 +12918,7 @@ var Spinner = function Spinner(_ref) {
|
|
|
12914
12918
|
*/
|
|
12915
12919
|
|
|
12916
12920
|
|
|
12917
|
-
var ButtonWithAction = function
|
|
12921
|
+
var ButtonWithAction = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
12918
12922
|
var _ref2$action = _ref2.action,
|
|
12919
12923
|
action = _ref2$action === void 0 ? noop : _ref2$action,
|
|
12920
12924
|
_ref2$variant = _ref2.variant,
|
|
@@ -12945,6 +12949,7 @@ var ButtonWithAction = function ButtonWithAction(_ref2) {
|
|
|
12945
12949
|
var activeStyles = "\n outline: none;\n background-color: ".concat(themeValues.activeBackgroundColor, ";\n border-color: ").concat(themeValues.activeBorderColor, ";\n color: ").concat(themeValues.activeColor, ";\n text-decoration: ").concat(variant === "ghost" || variant === "smallGhost" ? "underline" : "none", ";\n ");
|
|
12946
12950
|
var disabledStyles = "\n background-color: #6D717E;\n border-color: #6D717E;\n color: #FFFFFF;\n cursor: default;\n &:focus {\n box-shadow: 0 0 10px #6D717E;\n outline: none;\n }\n ".concat(extraDisabledStyles, "\n ");
|
|
12947
12951
|
return /*#__PURE__*/React.createElement(Box, _extends({
|
|
12952
|
+
ref: ref,
|
|
12948
12953
|
variant: variant,
|
|
12949
12954
|
padding: themeValues.padding,
|
|
12950
12955
|
minHeight: themeValues.height,
|
|
@@ -12973,7 +12978,7 @@ var ButtonWithAction = function ButtonWithAction(_ref2) {
|
|
|
12973
12978
|
textWrap: textWrap,
|
|
12974
12979
|
extraStyles: textExtraStyles
|
|
12975
12980
|
}, text)));
|
|
12976
|
-
};
|
|
12981
|
+
});
|
|
12977
12982
|
|
|
12978
12983
|
var primaryColor = {
|
|
12979
12984
|
info: "".concat(WHITE),
|
|
@@ -13671,7 +13676,9 @@ var AccountNumberImage = function AccountNumberImage() {
|
|
|
13671
13676
|
xmlns: "http://www.w3.org/2000/svg",
|
|
13672
13677
|
width: "371",
|
|
13673
13678
|
height: "164",
|
|
13674
|
-
viewBox: "0 0 371 164"
|
|
13679
|
+
viewBox: "0 0 371 164",
|
|
13680
|
+
role: "img",
|
|
13681
|
+
"aria-label": "A check with the account number highlighted in the bottom center"
|
|
13675
13682
|
}, /*#__PURE__*/React.createElement("g", {
|
|
13676
13683
|
fill: "none",
|
|
13677
13684
|
fillRule: "evenodd",
|
|
@@ -13752,7 +13759,9 @@ var RoutingNumberImage = function RoutingNumberImage() {
|
|
|
13752
13759
|
xmlns: "http://www.w3.org/2000/svg",
|
|
13753
13760
|
width: "371",
|
|
13754
13761
|
height: "164",
|
|
13755
|
-
viewBox: "0 0 371 164"
|
|
13762
|
+
viewBox: "0 0 371 164",
|
|
13763
|
+
role: "img",
|
|
13764
|
+
"aria-label": "A check with the routing number highlighted in the lower left hand corner"
|
|
13756
13765
|
}, /*#__PURE__*/React.createElement("g", {
|
|
13757
13766
|
fill: "none",
|
|
13758
13767
|
fillRule: "evenodd",
|
|
@@ -13835,7 +13844,9 @@ var CheckmarkIcon = function CheckmarkIcon() {
|
|
|
13835
13844
|
viewBox: "0 0 98 98",
|
|
13836
13845
|
version: "1.1",
|
|
13837
13846
|
xmlns: "http://www.w3.org/2000/svg",
|
|
13838
|
-
xmlnsXlink: "http://www.w3.org/1999/xlink"
|
|
13847
|
+
xmlnsXlink: "http://www.w3.org/1999/xlink",
|
|
13848
|
+
role: "img",
|
|
13849
|
+
"aria-label": "Successful payment, green checkmark"
|
|
13839
13850
|
}, /*#__PURE__*/React.createElement("g", {
|
|
13840
13851
|
id: "Cityville-Checkout---Desktop---Logged-In",
|
|
13841
13852
|
stroke: "none",
|
|
@@ -13880,7 +13891,9 @@ var BankIcon = function BankIcon() {
|
|
|
13880
13891
|
height: "18",
|
|
13881
13892
|
viewBox: "0 0 28 18",
|
|
13882
13893
|
fill: "none",
|
|
13883
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
13894
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
13895
|
+
role: "img",
|
|
13896
|
+
"aria-label": "Check Payment"
|
|
13884
13897
|
}, /*#__PURE__*/React.createElement("path", {
|
|
13885
13898
|
d: "M0 2.25C0 1.00736 1.04467 0 2.33333 0H25.6667C26.9553 0 28 1.00736 28 2.25V15.75C28 16.9926 26.9553 18 25.6667 18H2.33333C1.04467 18 0 16.9926 0 15.75V2.25Z",
|
|
13886
13899
|
fill: "#E4F4FD"
|
|
@@ -13927,7 +13940,9 @@ var GenericCard = function GenericCard() {
|
|
|
13927
13940
|
height: "18",
|
|
13928
13941
|
viewBox: "0 0 28 18",
|
|
13929
13942
|
fill: "none",
|
|
13930
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
13943
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
13944
|
+
role: "img",
|
|
13945
|
+
"aria-label": "Card Payment"
|
|
13931
13946
|
}, /*#__PURE__*/React.createElement("rect", {
|
|
13932
13947
|
width: "28",
|
|
13933
13948
|
height: "18",
|
|
@@ -15186,7 +15201,9 @@ var GenericCardLarge = function GenericCardLarge() {
|
|
|
15186
15201
|
height: "24",
|
|
15187
15202
|
viewBox: "0 0 36 24",
|
|
15188
15203
|
fill: "none",
|
|
15189
|
-
xmlns: "http://www.w3.org/2000/svg"
|
|
15204
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
15205
|
+
role: "img",
|
|
15206
|
+
"aria-label": "Card Payment"
|
|
15190
15207
|
}, /*#__PURE__*/React.createElement("rect", {
|
|
15191
15208
|
width: "36",
|
|
15192
15209
|
height: "24",
|
|
@@ -15275,7 +15292,8 @@ var ShoppingCartIcon = function ShoppingCartIcon() {
|
|
|
15275
15292
|
};
|
|
15276
15293
|
|
|
15277
15294
|
var TrashIcon = function TrashIcon(_ref) {
|
|
15278
|
-
var themeValues = _ref.themeValues
|
|
15295
|
+
var themeValues = _ref.themeValues,
|
|
15296
|
+
iconFill = _ref.iconFill;
|
|
15279
15297
|
return /*#__PURE__*/React.createElement("svg", {
|
|
15280
15298
|
width: "20px",
|
|
15281
15299
|
height: "20px",
|
|
@@ -15299,12 +15317,12 @@ var TrashIcon = function TrashIcon(_ref) {
|
|
|
15299
15317
|
xlinkHref: "#trash-path-1"
|
|
15300
15318
|
})), /*#__PURE__*/React.createElement("use", {
|
|
15301
15319
|
id: "trash-Mask",
|
|
15302
|
-
fill: themeValues.singleIconColor,
|
|
15320
|
+
fill: iconFill !== null && iconFill !== void 0 ? iconFill : themeValues.singleIconColor,
|
|
15303
15321
|
fillRule: "nonzero",
|
|
15304
15322
|
xlinkHref: "#trash-path-1"
|
|
15305
15323
|
}), /*#__PURE__*/React.createElement("polygon", {
|
|
15306
15324
|
id: "trash-Path",
|
|
15307
|
-
fill: themeValues.singleIconColor,
|
|
15325
|
+
fill: iconFill !== null && iconFill !== void 0 ? iconFill : themeValues.singleIconColor,
|
|
15308
15326
|
fillRule: "nonzero",
|
|
15309
15327
|
mask: "url(#trash-mask-2)",
|
|
15310
15328
|
points: "0 0 20 0 20 20 0 20"
|
|
@@ -18235,6 +18253,34 @@ var PlusCircleIcon = function PlusCircleIcon(_ref) {
|
|
|
18235
18253
|
}));
|
|
18236
18254
|
};
|
|
18237
18255
|
|
|
18256
|
+
var KebabMenuIcon = function KebabMenuIcon() {
|
|
18257
|
+
return /*#__PURE__*/React.createElement("svg", {
|
|
18258
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
18259
|
+
width: "21",
|
|
18260
|
+
height: "32",
|
|
18261
|
+
viewBox: "0 0 21 32",
|
|
18262
|
+
fill: "none"
|
|
18263
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
18264
|
+
d: "M0 4C0 1.79086 1.79086 0 4 0L17 0C19.2091 0 21 1.79086 21 4V28C21 30.2091 19.2091 32 17 32H4C1.79086 32 0 30.2091 0 28L0 4Z",
|
|
18265
|
+
fill: "none"
|
|
18266
|
+
}), /*#__PURE__*/React.createElement("path", {
|
|
18267
|
+
fillRule: "evenodd",
|
|
18268
|
+
clipRule: "evenodd",
|
|
18269
|
+
d: "M10.5 6C9.39333 6 8.5 6.89333 8.5 8C8.5 9.10667 9.39333 10 10.5 10C11.6067 10 12.5 9.10667 12.5 8C12.5 6.89333 11.6067 6 10.5 6Z",
|
|
18270
|
+
fill: "#3B5BDB"
|
|
18271
|
+
}), /*#__PURE__*/React.createElement("path", {
|
|
18272
|
+
fillRule: "evenodd",
|
|
18273
|
+
clipRule: "evenodd",
|
|
18274
|
+
d: "M10.5 14C9.39333 14 8.5 14.8933 8.5 16C8.5 17.1067 9.39333 18 10.5 18C11.6067 18 12.5 17.1067 12.5 16C12.5 14.8933 11.6067 14 10.5 14Z",
|
|
18275
|
+
fill: "#3B5BDB"
|
|
18276
|
+
}), /*#__PURE__*/React.createElement("path", {
|
|
18277
|
+
fillRule: "evenodd",
|
|
18278
|
+
clipRule: "evenodd",
|
|
18279
|
+
d: "M10.5 22C9.39333 22 8.5 22.9067 8.5 24C8.5 25.0933 9.40667 26 10.5 26C11.5933 26 12.5 25.0933 12.5 24C12.5 22.9067 11.6067 22 10.5 22Z",
|
|
18280
|
+
fill: "#3B5BDB"
|
|
18281
|
+
}));
|
|
18282
|
+
};
|
|
18283
|
+
|
|
18238
18284
|
var color$2 = "#15749D";
|
|
18239
18285
|
var hoverColor$1 = "#116285";
|
|
18240
18286
|
var activeColor$1 = "#0E506D";
|
|
@@ -22121,6 +22167,7 @@ var Checkbox = function Checkbox(_ref4) {
|
|
|
22121
22167
|
checkboxMargin = _ref4$checkboxMargin === void 0 ? "0 16px 0 0" : _ref4$checkboxMargin,
|
|
22122
22168
|
extraStyles = _ref4.extraStyles,
|
|
22123
22169
|
textExtraStyles = _ref4.textExtraStyles,
|
|
22170
|
+
labelledById = _ref4.labelledById,
|
|
22124
22171
|
_ref4$dataQa = _ref4.dataQa,
|
|
22125
22172
|
dataQa = _ref4$dataQa === void 0 ? null : _ref4$dataQa;
|
|
22126
22173
|
|
|
@@ -22135,6 +22182,9 @@ var Checkbox = function Checkbox(_ref4) {
|
|
|
22135
22182
|
}
|
|
22136
22183
|
};
|
|
22137
22184
|
|
|
22185
|
+
var titleId = title ? "checkboxlabel-".concat(name) : undefined;
|
|
22186
|
+
var ariaLabelledById = labelledById !== null && labelledById !== void 0 ? labelledById : titleId;
|
|
22187
|
+
var ariaLabel = ariaLabelledById ? undefined : name;
|
|
22138
22188
|
return /*#__PURE__*/React.createElement(Box, {
|
|
22139
22189
|
padding: "0",
|
|
22140
22190
|
tabIndex: "0",
|
|
@@ -22158,7 +22208,8 @@ var Checkbox = function Checkbox(_ref4) {
|
|
|
22158
22208
|
id: "checkbox-".concat(name),
|
|
22159
22209
|
disabled: disabled,
|
|
22160
22210
|
name: name,
|
|
22161
|
-
"aria-label":
|
|
22211
|
+
"aria-label": ariaLabel,
|
|
22212
|
+
"aria-labelledby": ariaLabelledById,
|
|
22162
22213
|
checked: checked,
|
|
22163
22214
|
onChange: onChange,
|
|
22164
22215
|
tabIndex: "-1",
|
|
@@ -22185,6 +22236,7 @@ var Checkbox = function Checkbox(_ref4) {
|
|
|
22185
22236
|
}, /*#__PURE__*/React.createElement("polyline", {
|
|
22186
22237
|
points: "20 6 9 17 4 12"
|
|
22187
22238
|
})))), title && /*#__PURE__*/React.createElement(Text$1, {
|
|
22239
|
+
id: titleId,
|
|
22188
22240
|
variant: "p",
|
|
22189
22241
|
weight: themeValues.textFontWeight,
|
|
22190
22242
|
color: themeValues.textColor,
|
|
@@ -22415,17 +22467,18 @@ var DropdownIcon = function DropdownIcon() {
|
|
|
22415
22467
|
};
|
|
22416
22468
|
|
|
22417
22469
|
var check = function (it) {
|
|
22418
|
-
return it && it.Math
|
|
22470
|
+
return it && it.Math === Math && it;
|
|
22419
22471
|
};
|
|
22420
22472
|
|
|
22421
22473
|
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
22422
22474
|
var global_1 =
|
|
22423
|
-
// eslint-disable-next-line es
|
|
22475
|
+
// eslint-disable-next-line es/no-global-this -- safe
|
|
22424
22476
|
check(typeof globalThis == 'object' && globalThis) ||
|
|
22425
22477
|
check(typeof window == 'object' && window) ||
|
|
22426
22478
|
// eslint-disable-next-line no-restricted-globals -- safe
|
|
22427
22479
|
check(typeof self == 'object' && self) ||
|
|
22428
22480
|
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
22481
|
+
check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
|
|
22429
22482
|
// eslint-disable-next-line no-new-func -- fallback
|
|
22430
22483
|
(function () { return this; })() || Function('return this')();
|
|
22431
22484
|
|
|
@@ -22439,12 +22492,12 @@ var fails = function (exec) {
|
|
|
22439
22492
|
|
|
22440
22493
|
// Detect IE8's incomplete defineProperty implementation
|
|
22441
22494
|
var descriptors = !fails(function () {
|
|
22442
|
-
// eslint-disable-next-line es
|
|
22443
|
-
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1]
|
|
22495
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22496
|
+
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
22444
22497
|
});
|
|
22445
22498
|
|
|
22446
22499
|
var functionBindNative = !fails(function () {
|
|
22447
|
-
// eslint-disable-next-line es
|
|
22500
|
+
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
22448
22501
|
var test = (function () { /* empty */ }).bind();
|
|
22449
22502
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
22450
22503
|
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
@@ -22457,7 +22510,7 @@ var functionCall = functionBindNative ? call.bind(call) : function () {
|
|
|
22457
22510
|
};
|
|
22458
22511
|
|
|
22459
22512
|
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
22460
|
-
// eslint-disable-next-line es
|
|
22513
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22461
22514
|
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
22462
22515
|
|
|
22463
22516
|
// Nashorn ~ JDK8 bug
|
|
@@ -22484,14 +22537,11 @@ var createPropertyDescriptor = function (bitmap, value) {
|
|
|
22484
22537
|
};
|
|
22485
22538
|
|
|
22486
22539
|
var FunctionPrototype = Function.prototype;
|
|
22487
|
-
var bind$1 = FunctionPrototype.bind;
|
|
22488
22540
|
var call$1 = FunctionPrototype.call;
|
|
22489
|
-
var
|
|
22541
|
+
var uncurryThisWithBind = functionBindNative && FunctionPrototype.bind.bind(call$1, call$1);
|
|
22490
22542
|
|
|
22491
|
-
var functionUncurryThis = functionBindNative ? function (fn) {
|
|
22492
|
-
return
|
|
22493
|
-
} : function (fn) {
|
|
22494
|
-
return fn && function () {
|
|
22543
|
+
var functionUncurryThis = functionBindNative ? uncurryThisWithBind : function (fn) {
|
|
22544
|
+
return function () {
|
|
22495
22545
|
return call$1.apply(fn, arguments);
|
|
22496
22546
|
};
|
|
22497
22547
|
};
|
|
@@ -22512,15 +22562,21 @@ var indexedObject = fails(function () {
|
|
|
22512
22562
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
22513
22563
|
return !$Object('z').propertyIsEnumerable(0);
|
|
22514
22564
|
}) ? function (it) {
|
|
22515
|
-
return classofRaw(it)
|
|
22565
|
+
return classofRaw(it) === 'String' ? split(it, '') : $Object(it);
|
|
22516
22566
|
} : $Object;
|
|
22517
22567
|
|
|
22568
|
+
// we can't use just `it == null` since of `document.all` special case
|
|
22569
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
22570
|
+
var isNullOrUndefined = function (it) {
|
|
22571
|
+
return it === null || it === undefined;
|
|
22572
|
+
};
|
|
22573
|
+
|
|
22518
22574
|
var $TypeError = TypeError;
|
|
22519
22575
|
|
|
22520
22576
|
// `RequireObjectCoercible` abstract operation
|
|
22521
22577
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
22522
22578
|
var requireObjectCoercible = function (it) {
|
|
22523
|
-
if (it
|
|
22579
|
+
if (isNullOrUndefined(it)) throw new $TypeError("Can't call method on " + it);
|
|
22524
22580
|
return it;
|
|
22525
22581
|
};
|
|
22526
22582
|
|
|
@@ -22532,13 +22588,32 @@ var toIndexedObject = function (it) {
|
|
|
22532
22588
|
return indexedObject(requireObjectCoercible(it));
|
|
22533
22589
|
};
|
|
22534
22590
|
|
|
22591
|
+
var documentAll = typeof document == 'object' && document.all;
|
|
22592
|
+
|
|
22593
|
+
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
22594
|
+
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
22595
|
+
var IS_HTMLDDA = typeof documentAll == 'undefined' && documentAll !== undefined;
|
|
22596
|
+
|
|
22597
|
+
var documentAll_1 = {
|
|
22598
|
+
all: documentAll,
|
|
22599
|
+
IS_HTMLDDA: IS_HTMLDDA
|
|
22600
|
+
};
|
|
22601
|
+
|
|
22602
|
+
var documentAll$1 = documentAll_1.all;
|
|
22603
|
+
|
|
22535
22604
|
// `IsCallable` abstract operation
|
|
22536
22605
|
// https://tc39.es/ecma262/#sec-iscallable
|
|
22537
|
-
var isCallable = function (argument) {
|
|
22606
|
+
var isCallable = documentAll_1.IS_HTMLDDA ? function (argument) {
|
|
22607
|
+
return typeof argument == 'function' || argument === documentAll$1;
|
|
22608
|
+
} : function (argument) {
|
|
22538
22609
|
return typeof argument == 'function';
|
|
22539
22610
|
};
|
|
22540
22611
|
|
|
22541
|
-
var
|
|
22612
|
+
var documentAll$2 = documentAll_1.all;
|
|
22613
|
+
|
|
22614
|
+
var isObject = documentAll_1.IS_HTMLDDA ? function (it) {
|
|
22615
|
+
return typeof it == 'object' ? it !== null : isCallable(it) || it === documentAll$2;
|
|
22616
|
+
} : function (it) {
|
|
22542
22617
|
return typeof it == 'object' ? it !== null : isCallable(it);
|
|
22543
22618
|
};
|
|
22544
22619
|
|
|
@@ -22552,7 +22627,7 @@ var getBuiltIn = function (namespace, method) {
|
|
|
22552
22627
|
|
|
22553
22628
|
var objectIsPrototypeOf = functionUncurryThis({}.isPrototypeOf);
|
|
22554
22629
|
|
|
22555
|
-
var engineUserAgent =
|
|
22630
|
+
var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
22556
22631
|
|
|
22557
22632
|
var process$1 = global_1.process;
|
|
22558
22633
|
var Deno = global_1.Deno;
|
|
@@ -22579,24 +22654,29 @@ if (!version && engineUserAgent) {
|
|
|
22579
22654
|
|
|
22580
22655
|
var engineV8Version = version;
|
|
22581
22656
|
|
|
22582
|
-
/* eslint-disable es
|
|
22657
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
22658
|
+
|
|
22583
22659
|
|
|
22584
22660
|
|
|
22585
22661
|
|
|
22586
|
-
|
|
22587
|
-
|
|
22588
|
-
|
|
22662
|
+
var $String = global_1.String;
|
|
22663
|
+
|
|
22664
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
22665
|
+
var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails(function () {
|
|
22666
|
+
var symbol = Symbol('symbol detection');
|
|
22589
22667
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
22590
22668
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
22591
|
-
|
|
22669
|
+
// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
|
|
22670
|
+
// of course, fail.
|
|
22671
|
+
return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
22592
22672
|
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
22593
22673
|
!Symbol.sham && engineV8Version && engineV8Version < 41;
|
|
22594
22674
|
});
|
|
22595
22675
|
|
|
22596
|
-
/* eslint-disable es
|
|
22676
|
+
/* eslint-disable es/no-symbol -- required for testing */
|
|
22597
22677
|
|
|
22598
22678
|
|
|
22599
|
-
var useSymbolAsUid =
|
|
22679
|
+
var useSymbolAsUid = symbolConstructorDetection
|
|
22600
22680
|
&& !Symbol.sham
|
|
22601
22681
|
&& typeof Symbol.iterator == 'symbol';
|
|
22602
22682
|
|
|
@@ -22609,11 +22689,11 @@ var isSymbol = useSymbolAsUid ? function (it) {
|
|
|
22609
22689
|
return isCallable($Symbol) && objectIsPrototypeOf($Symbol.prototype, $Object$1(it));
|
|
22610
22690
|
};
|
|
22611
22691
|
|
|
22612
|
-
var $String = String;
|
|
22692
|
+
var $String$1 = String;
|
|
22613
22693
|
|
|
22614
22694
|
var tryToString = function (argument) {
|
|
22615
22695
|
try {
|
|
22616
|
-
return $String(argument);
|
|
22696
|
+
return $String$1(argument);
|
|
22617
22697
|
} catch (error) {
|
|
22618
22698
|
return 'Object';
|
|
22619
22699
|
}
|
|
@@ -22624,14 +22704,14 @@ var $TypeError$1 = TypeError;
|
|
|
22624
22704
|
// `Assert: IsCallable(argument) is true`
|
|
22625
22705
|
var aCallable = function (argument) {
|
|
22626
22706
|
if (isCallable(argument)) return argument;
|
|
22627
|
-
throw $TypeError$1(tryToString(argument) + ' is not a function');
|
|
22707
|
+
throw new $TypeError$1(tryToString(argument) + ' is not a function');
|
|
22628
22708
|
};
|
|
22629
22709
|
|
|
22630
22710
|
// `GetMethod` abstract operation
|
|
22631
22711
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
22632
22712
|
var getMethod = function (V, P) {
|
|
22633
22713
|
var func = V[P];
|
|
22634
|
-
return func
|
|
22714
|
+
return isNullOrUndefined(func) ? undefined : aCallable(func);
|
|
22635
22715
|
};
|
|
22636
22716
|
|
|
22637
22717
|
var $TypeError$2 = TypeError;
|
|
@@ -22643,10 +22723,10 @@ var ordinaryToPrimitive = function (input, pref) {
|
|
|
22643
22723
|
if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
22644
22724
|
if (isCallable(fn = input.valueOf) && !isObject(val = functionCall(fn, input))) return val;
|
|
22645
22725
|
if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = functionCall(fn, input))) return val;
|
|
22646
|
-
throw $TypeError$2("Can't convert object to primitive value");
|
|
22726
|
+
throw new $TypeError$2("Can't convert object to primitive value");
|
|
22647
22727
|
};
|
|
22648
22728
|
|
|
22649
|
-
// eslint-disable-next-line es
|
|
22729
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22650
22730
|
var defineProperty = Object.defineProperty;
|
|
22651
22731
|
|
|
22652
22732
|
var defineGlobalProperty = function (key, value) {
|
|
@@ -22663,13 +22743,16 @@ var store = global_1[SHARED] || defineGlobalProperty(SHARED, {});
|
|
|
22663
22743
|
var sharedStore = store;
|
|
22664
22744
|
|
|
22665
22745
|
var shared = createCommonjsModule(function (module) {
|
|
22746
|
+
|
|
22747
|
+
|
|
22748
|
+
|
|
22666
22749
|
(module.exports = function (key, value) {
|
|
22667
22750
|
return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {});
|
|
22668
22751
|
})('versions', []).push({
|
|
22669
|
-
version: '3.
|
|
22752
|
+
version: '3.33.3',
|
|
22670
22753
|
mode: 'global',
|
|
22671
|
-
copyright: '© 2014-
|
|
22672
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.
|
|
22754
|
+
copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
|
|
22755
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.33.3/LICENSE',
|
|
22673
22756
|
source: 'https://github.com/zloirock/core-js'
|
|
22674
22757
|
});
|
|
22675
22758
|
});
|
|
@@ -22686,7 +22769,7 @@ var hasOwnProperty = functionUncurryThis({}.hasOwnProperty);
|
|
|
22686
22769
|
|
|
22687
22770
|
// `HasOwnProperty` abstract operation
|
|
22688
22771
|
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
22689
|
-
// eslint-disable-next-line es
|
|
22772
|
+
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
22690
22773
|
var hasOwnProperty_1 = Object.hasOwn || function hasOwn(it, key) {
|
|
22691
22774
|
return hasOwnProperty(toObject(it), key);
|
|
22692
22775
|
};
|
|
@@ -22699,21 +22782,15 @@ var uid = function (key) {
|
|
|
22699
22782
|
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString$3(++id + postfix, 36);
|
|
22700
22783
|
};
|
|
22701
22784
|
|
|
22702
|
-
var WellKnownSymbolsStore = shared('wks');
|
|
22703
22785
|
var Symbol$1 = global_1.Symbol;
|
|
22704
|
-
var
|
|
22705
|
-
var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
|
|
22786
|
+
var WellKnownSymbolsStore = shared('wks');
|
|
22787
|
+
var createWellKnownSymbol = useSymbolAsUid ? Symbol$1['for'] || Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid;
|
|
22706
22788
|
|
|
22707
22789
|
var wellKnownSymbol = function (name) {
|
|
22708
|
-
if (!hasOwnProperty_1(WellKnownSymbolsStore, name)
|
|
22709
|
-
|
|
22710
|
-
|
|
22711
|
-
|
|
22712
|
-
} else if (useSymbolAsUid && symbolFor) {
|
|
22713
|
-
WellKnownSymbolsStore[name] = symbolFor(description);
|
|
22714
|
-
} else {
|
|
22715
|
-
WellKnownSymbolsStore[name] = createWellKnownSymbol(description);
|
|
22716
|
-
}
|
|
22790
|
+
if (!hasOwnProperty_1(WellKnownSymbolsStore, name)) {
|
|
22791
|
+
WellKnownSymbolsStore[name] = symbolConstructorDetection && hasOwnProperty_1(Symbol$1, name)
|
|
22792
|
+
? Symbol$1[name]
|
|
22793
|
+
: createWellKnownSymbol('Symbol.' + name);
|
|
22717
22794
|
} return WellKnownSymbolsStore[name];
|
|
22718
22795
|
};
|
|
22719
22796
|
|
|
@@ -22730,7 +22807,7 @@ var toPrimitive = function (input, pref) {
|
|
|
22730
22807
|
if (pref === undefined) pref = 'default';
|
|
22731
22808
|
result = functionCall(exoticToPrim, input, pref);
|
|
22732
22809
|
if (!isObject(result) || isSymbol(result)) return result;
|
|
22733
|
-
throw $TypeError$3("Can't convert object to primitive value");
|
|
22810
|
+
throw new $TypeError$3("Can't convert object to primitive value");
|
|
22734
22811
|
}
|
|
22735
22812
|
if (pref === undefined) pref = 'number';
|
|
22736
22813
|
return ordinaryToPrimitive(input, pref);
|
|
@@ -22753,13 +22830,13 @@ var documentCreateElement = function (it) {
|
|
|
22753
22830
|
|
|
22754
22831
|
// Thanks to IE8 for its funny defineProperty
|
|
22755
22832
|
var ie8DomDefine = !descriptors && !fails(function () {
|
|
22756
|
-
// eslint-disable-next-line es
|
|
22833
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22757
22834
|
return Object.defineProperty(documentCreateElement('div'), 'a', {
|
|
22758
22835
|
get: function () { return 7; }
|
|
22759
|
-
}).a
|
|
22836
|
+
}).a !== 7;
|
|
22760
22837
|
});
|
|
22761
22838
|
|
|
22762
|
-
// eslint-disable-next-line es
|
|
22839
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22763
22840
|
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
22764
22841
|
|
|
22765
22842
|
// `Object.getOwnPropertyDescriptor` method
|
|
@@ -22780,26 +22857,26 @@ var objectGetOwnPropertyDescriptor = {
|
|
|
22780
22857
|
// V8 ~ Chrome 36-
|
|
22781
22858
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
22782
22859
|
var v8PrototypeDefineBug = descriptors && fails(function () {
|
|
22783
|
-
// eslint-disable-next-line es
|
|
22860
|
+
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
22784
22861
|
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
22785
22862
|
value: 42,
|
|
22786
22863
|
writable: false
|
|
22787
|
-
}).prototype
|
|
22864
|
+
}).prototype !== 42;
|
|
22788
22865
|
});
|
|
22789
22866
|
|
|
22790
|
-
var $String$
|
|
22867
|
+
var $String$2 = String;
|
|
22791
22868
|
var $TypeError$4 = TypeError;
|
|
22792
22869
|
|
|
22793
22870
|
// `Assert: Type(argument) is Object`
|
|
22794
22871
|
var anObject = function (argument) {
|
|
22795
22872
|
if (isObject(argument)) return argument;
|
|
22796
|
-
throw $TypeError$4($String$
|
|
22873
|
+
throw new $TypeError$4($String$2(argument) + ' is not an object');
|
|
22797
22874
|
};
|
|
22798
22875
|
|
|
22799
22876
|
var $TypeError$5 = TypeError;
|
|
22800
|
-
// eslint-disable-next-line es
|
|
22877
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22801
22878
|
var $defineProperty = Object.defineProperty;
|
|
22802
|
-
// eslint-disable-next-line es
|
|
22879
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22803
22880
|
var $getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor;
|
|
22804
22881
|
var ENUMERABLE = 'enumerable';
|
|
22805
22882
|
var CONFIGURABLE = 'configurable';
|
|
@@ -22829,7 +22906,7 @@ var f$2 = descriptors ? v8PrototypeDefineBug ? function defineProperty(O, P, Att
|
|
|
22829
22906
|
if (ie8DomDefine) try {
|
|
22830
22907
|
return $defineProperty(O, P, Attributes);
|
|
22831
22908
|
} catch (error) { /* empty */ }
|
|
22832
|
-
if ('get' in Attributes || 'set' in Attributes) throw $TypeError$5('Accessors not supported');
|
|
22909
|
+
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError$5('Accessors not supported');
|
|
22833
22910
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
22834
22911
|
return O;
|
|
22835
22912
|
};
|
|
@@ -22846,7 +22923,7 @@ var createNonEnumerableProperty = descriptors ? function (object, key, value) {
|
|
|
22846
22923
|
};
|
|
22847
22924
|
|
|
22848
22925
|
var FunctionPrototype$1 = Function.prototype;
|
|
22849
|
-
// eslint-disable-next-line es
|
|
22926
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
22850
22927
|
var getDescriptor = descriptors && Object.getOwnPropertyDescriptor;
|
|
22851
22928
|
|
|
22852
22929
|
var EXISTS$1 = hasOwnProperty_1(FunctionPrototype$1, 'name');
|
|
@@ -22873,7 +22950,7 @@ var inspectSource = sharedStore.inspectSource;
|
|
|
22873
22950
|
|
|
22874
22951
|
var WeakMap$1 = global_1.WeakMap;
|
|
22875
22952
|
|
|
22876
|
-
var
|
|
22953
|
+
var weakMapBasicDetection = isCallable(WeakMap$1) && /native code/.test(String(WeakMap$1));
|
|
22877
22954
|
|
|
22878
22955
|
var keys$1 = shared('keys');
|
|
22879
22956
|
|
|
@@ -22896,27 +22973,29 @@ var getterFor = function (TYPE) {
|
|
|
22896
22973
|
return function (it) {
|
|
22897
22974
|
var state;
|
|
22898
22975
|
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
22899
|
-
throw TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
22976
|
+
throw new TypeError$1('Incompatible receiver, ' + TYPE + ' required');
|
|
22900
22977
|
} return state;
|
|
22901
22978
|
};
|
|
22902
22979
|
};
|
|
22903
22980
|
|
|
22904
|
-
if (
|
|
22981
|
+
if (weakMapBasicDetection || sharedStore.state) {
|
|
22905
22982
|
var store$1 = sharedStore.state || (sharedStore.state = new WeakMap$2());
|
|
22906
|
-
|
|
22907
|
-
|
|
22908
|
-
|
|
22983
|
+
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
22984
|
+
store$1.get = store$1.get;
|
|
22985
|
+
store$1.has = store$1.has;
|
|
22986
|
+
store$1.set = store$1.set;
|
|
22987
|
+
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
22909
22988
|
set = function (it, metadata) {
|
|
22910
|
-
if (
|
|
22989
|
+
if (store$1.has(it)) throw new TypeError$1(OBJECT_ALREADY_INITIALIZED);
|
|
22911
22990
|
metadata.facade = it;
|
|
22912
|
-
|
|
22991
|
+
store$1.set(it, metadata);
|
|
22913
22992
|
return metadata;
|
|
22914
22993
|
};
|
|
22915
22994
|
get = function (it) {
|
|
22916
|
-
return
|
|
22995
|
+
return store$1.get(it) || {};
|
|
22917
22996
|
};
|
|
22918
22997
|
has = function (it) {
|
|
22919
|
-
return
|
|
22998
|
+
return store$1.has(it);
|
|
22920
22999
|
};
|
|
22921
23000
|
} else {
|
|
22922
23001
|
var STATE = sharedKey('state');
|
|
@@ -22944,14 +23023,23 @@ var internalState = {
|
|
|
22944
23023
|
};
|
|
22945
23024
|
|
|
22946
23025
|
var makeBuiltIn_1 = createCommonjsModule(function (module) {
|
|
23026
|
+
|
|
23027
|
+
|
|
23028
|
+
|
|
23029
|
+
|
|
23030
|
+
|
|
22947
23031
|
var CONFIGURABLE_FUNCTION_NAME = functionName.CONFIGURABLE;
|
|
22948
23032
|
|
|
22949
23033
|
|
|
22950
23034
|
|
|
22951
23035
|
var enforceInternalState = internalState.enforce;
|
|
22952
23036
|
var getInternalState = internalState.get;
|
|
22953
|
-
|
|
23037
|
+
var $String = String;
|
|
23038
|
+
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
22954
23039
|
var defineProperty = Object.defineProperty;
|
|
23040
|
+
var stringSlice = functionUncurryThis(''.slice);
|
|
23041
|
+
var replace = functionUncurryThis(''.replace);
|
|
23042
|
+
var join = functionUncurryThis([].join);
|
|
22955
23043
|
|
|
22956
23044
|
var CONFIGURABLE_LENGTH = descriptors && !fails(function () {
|
|
22957
23045
|
return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
@@ -22960,8 +23048,8 @@ var CONFIGURABLE_LENGTH = descriptors && !fails(function () {
|
|
|
22960
23048
|
var TEMPLATE = String(String).split('String');
|
|
22961
23049
|
|
|
22962
23050
|
var makeBuiltIn = module.exports = function (value, name, options) {
|
|
22963
|
-
if (String(name)
|
|
22964
|
-
name = '[' + String(name)
|
|
23051
|
+
if (stringSlice($String(name), 0, 7) === 'Symbol(') {
|
|
23052
|
+
name = '[' + replace($String(name), /^Symbol\(([^)]*)\)/, '$1') + ']';
|
|
22965
23053
|
}
|
|
22966
23054
|
if (options && options.getter) name = 'get ' + name;
|
|
22967
23055
|
if (options && options.setter) name = 'set ' + name;
|
|
@@ -22980,7 +23068,7 @@ var makeBuiltIn = module.exports = function (value, name, options) {
|
|
|
22980
23068
|
} catch (error) { /* empty */ }
|
|
22981
23069
|
var state = enforceInternalState(value);
|
|
22982
23070
|
if (!hasOwnProperty_1(state, 'source')) {
|
|
22983
|
-
state.source =
|
|
23071
|
+
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
22984
23072
|
} return value;
|
|
22985
23073
|
};
|
|
22986
23074
|
|
|
@@ -23019,7 +23107,7 @@ var floor = Math.floor;
|
|
|
23019
23107
|
|
|
23020
23108
|
// `Math.trunc` method
|
|
23021
23109
|
// https://tc39.es/ecma262/#sec-math.trunc
|
|
23022
|
-
// eslint-disable-next-line es
|
|
23110
|
+
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
23023
23111
|
var mathTrunc = Math.trunc || function trunc(x) {
|
|
23024
23112
|
var n = +x;
|
|
23025
23113
|
return (n > 0 ? floor : ceil)(n);
|
|
@@ -23067,10 +23155,10 @@ var createMethod = function (IS_INCLUDES) {
|
|
|
23067
23155
|
var value;
|
|
23068
23156
|
// Array#includes uses SameValueZero equality algorithm
|
|
23069
23157
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
23070
|
-
if (IS_INCLUDES && el
|
|
23158
|
+
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
23071
23159
|
value = O[index++];
|
|
23072
23160
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
23073
|
-
if (value
|
|
23161
|
+
if (value !== value) return true;
|
|
23074
23162
|
// Array#indexOf ignores holes, Array#includes - not
|
|
23075
23163
|
} else for (;length > index; index++) {
|
|
23076
23164
|
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
@@ -23120,7 +23208,7 @@ var hiddenKeys$1 = enumBugKeys.concat('length', 'prototype');
|
|
|
23120
23208
|
|
|
23121
23209
|
// `Object.getOwnPropertyNames` method
|
|
23122
23210
|
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
23123
|
-
// eslint-disable-next-line es
|
|
23211
|
+
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
23124
23212
|
var f$3 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
23125
23213
|
return objectKeysInternal(O, hiddenKeys$1);
|
|
23126
23214
|
};
|
|
@@ -23129,7 +23217,7 @@ var objectGetOwnPropertyNames = {
|
|
|
23129
23217
|
f: f$3
|
|
23130
23218
|
};
|
|
23131
23219
|
|
|
23132
|
-
// eslint-disable-next-line es
|
|
23220
|
+
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
23133
23221
|
var f$4 = Object.getOwnPropertySymbols;
|
|
23134
23222
|
|
|
23135
23223
|
var objectGetOwnPropertySymbols = {
|
|
@@ -23161,8 +23249,8 @@ var replacement = /#|\.prototype\./;
|
|
|
23161
23249
|
|
|
23162
23250
|
var isForced = function (feature, detection) {
|
|
23163
23251
|
var value = data[normalize(feature)];
|
|
23164
|
-
return value
|
|
23165
|
-
: value
|
|
23252
|
+
return value === POLYFILL ? true
|
|
23253
|
+
: value === NATIVE ? false
|
|
23166
23254
|
: isCallable(detection) ? fails(detection)
|
|
23167
23255
|
: !!detection;
|
|
23168
23256
|
};
|
|
@@ -23242,7 +23330,7 @@ var TO_STRING_TAG$1 = wellKnownSymbol('toStringTag');
|
|
|
23242
23330
|
var $Object$3 = Object;
|
|
23243
23331
|
|
|
23244
23332
|
// ES3 wrong here
|
|
23245
|
-
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }())
|
|
23333
|
+
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
|
|
23246
23334
|
|
|
23247
23335
|
// fallback for IE11 Script Access Denied error
|
|
23248
23336
|
var tryGet = function (it, key) {
|
|
@@ -23260,25 +23348,25 @@ var classof = toStringTagSupport ? classofRaw : function (it) {
|
|
|
23260
23348
|
// builtinTag case
|
|
23261
23349
|
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
23262
23350
|
// ES3 arguments fallback
|
|
23263
|
-
: (result = classofRaw(O))
|
|
23351
|
+
: (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;
|
|
23264
23352
|
};
|
|
23265
23353
|
|
|
23266
|
-
var $String$
|
|
23354
|
+
var $String$3 = String;
|
|
23267
23355
|
|
|
23268
23356
|
var toString_1 = function (argument) {
|
|
23269
|
-
if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');
|
|
23270
|
-
return $String$
|
|
23357
|
+
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
|
|
23358
|
+
return $String$3(argument);
|
|
23271
23359
|
};
|
|
23272
23360
|
|
|
23273
23361
|
var charAt = functionUncurryThis(''.charAt);
|
|
23274
23362
|
|
|
23275
23363
|
var FORCED = fails(function () {
|
|
23276
|
-
// eslint-disable-next-line es
|
|
23364
|
+
// eslint-disable-next-line es/no-array-string-prototype-at -- safe
|
|
23277
23365
|
return '𠮷'.at(-2) !== '\uD842';
|
|
23278
23366
|
});
|
|
23279
23367
|
|
|
23280
23368
|
// `String.prototype.at` method
|
|
23281
|
-
// https://
|
|
23369
|
+
// https://tc39.es/ecma262/#sec-string.prototype.at
|
|
23282
23370
|
_export({ target: 'String', proto: true, forced: FORCED }, {
|
|
23283
23371
|
at: function at(index) {
|
|
23284
23372
|
var S = toString_1(requireObjectCoercible(this));
|
|
@@ -23291,14 +23379,14 @@ _export({ target: 'String', proto: true, forced: FORCED }, {
|
|
|
23291
23379
|
|
|
23292
23380
|
// `Object.keys` method
|
|
23293
23381
|
// https://tc39.es/ecma262/#sec-object.keys
|
|
23294
|
-
// eslint-disable-next-line es
|
|
23382
|
+
// eslint-disable-next-line es/no-object-keys -- safe
|
|
23295
23383
|
var objectKeys = Object.keys || function keys(O) {
|
|
23296
23384
|
return objectKeysInternal(O, enumBugKeys);
|
|
23297
23385
|
};
|
|
23298
23386
|
|
|
23299
23387
|
// `Object.defineProperties` method
|
|
23300
23388
|
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
23301
|
-
// eslint-disable-next-line es
|
|
23389
|
+
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
23302
23390
|
var f$5 = descriptors && !v8PrototypeDefineBug ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
23303
23391
|
anObject(O);
|
|
23304
23392
|
var props = toIndexedObject(Properties);
|
|
@@ -23387,7 +23475,7 @@ hiddenKeys[IE_PROTO] = true;
|
|
|
23387
23475
|
|
|
23388
23476
|
// `Object.create` method
|
|
23389
23477
|
// https://tc39.es/ecma262/#sec-object.create
|
|
23390
|
-
// eslint-disable-next-line es
|
|
23478
|
+
// eslint-disable-next-line es/no-object-create -- safe
|
|
23391
23479
|
var objectCreate = Object.create || function create(O, Properties) {
|
|
23392
23480
|
var result;
|
|
23393
23481
|
if (O !== null) {
|
|
@@ -23407,7 +23495,7 @@ var ArrayPrototype = Array.prototype;
|
|
|
23407
23495
|
|
|
23408
23496
|
// Array.prototype[@@unscopables]
|
|
23409
23497
|
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
23410
|
-
if (ArrayPrototype[UNSCOPABLES]
|
|
23498
|
+
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
23411
23499
|
defineProperty$1(ArrayPrototype, UNSCOPABLES, {
|
|
23412
23500
|
configurable: true,
|
|
23413
23501
|
value: objectCreate(null)
|
|
@@ -23420,7 +23508,7 @@ var addToUnscopables = function (key) {
|
|
|
23420
23508
|
};
|
|
23421
23509
|
|
|
23422
23510
|
// `Array.prototype.at` method
|
|
23423
|
-
// https://
|
|
23511
|
+
// https://tc39.es/ecma262/#sec-array.prototype.at
|
|
23424
23512
|
_export({ target: 'Array', proto: true }, {
|
|
23425
23513
|
at: function at(index) {
|
|
23426
23514
|
var O = toObject(this);
|
|
@@ -23433,13 +23521,19 @@ _export({ target: 'Array', proto: true }, {
|
|
|
23433
23521
|
|
|
23434
23522
|
addToUnscopables('at');
|
|
23435
23523
|
|
|
23436
|
-
// eslint-disable-next-line es
|
|
23437
|
-
var
|
|
23524
|
+
// eslint-disable-next-line es/no-typed-arrays -- safe
|
|
23525
|
+
var arrayBufferBasicDetection = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';
|
|
23526
|
+
|
|
23527
|
+
var defineBuiltInAccessor = function (target, name, descriptor) {
|
|
23528
|
+
if (descriptor.get) makeBuiltIn_1(descriptor.get, name, { getter: true });
|
|
23529
|
+
if (descriptor.set) makeBuiltIn_1(descriptor.set, name, { setter: true });
|
|
23530
|
+
return objectDefineProperty.f(target, name, descriptor);
|
|
23531
|
+
};
|
|
23438
23532
|
|
|
23439
23533
|
var correctPrototypeGetter = !fails(function () {
|
|
23440
23534
|
function F() { /* empty */ }
|
|
23441
23535
|
F.prototype.constructor = null;
|
|
23442
|
-
// eslint-disable-next-line es
|
|
23536
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
23443
23537
|
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
23444
23538
|
});
|
|
23445
23539
|
|
|
@@ -23449,7 +23543,7 @@ var ObjectPrototype = $Object$4.prototype;
|
|
|
23449
23543
|
|
|
23450
23544
|
// `Object.getPrototypeOf` method
|
|
23451
23545
|
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
23452
|
-
// eslint-disable-next-line es
|
|
23546
|
+
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
23453
23547
|
var objectGetPrototypeOf = correctPrototypeGetter ? $Object$4.getPrototypeOf : function (O) {
|
|
23454
23548
|
var object = toObject(O);
|
|
23455
23549
|
if (hasOwnProperty_1(object, IE_PROTO$1)) return object[IE_PROTO$1];
|
|
@@ -23459,12 +23553,19 @@ var objectGetPrototypeOf = correctPrototypeGetter ? $Object$4.getPrototypeOf : f
|
|
|
23459
23553
|
} return object instanceof $Object$4 ? ObjectPrototype : null;
|
|
23460
23554
|
};
|
|
23461
23555
|
|
|
23462
|
-
var
|
|
23556
|
+
var functionUncurryThisAccessor = function (object, key, method) {
|
|
23557
|
+
try {
|
|
23558
|
+
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
23559
|
+
return functionUncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
23560
|
+
} catch (error) { /* empty */ }
|
|
23561
|
+
};
|
|
23562
|
+
|
|
23563
|
+
var $String$4 = String;
|
|
23463
23564
|
var $TypeError$6 = TypeError;
|
|
23464
23565
|
|
|
23465
23566
|
var aPossiblePrototype = function (argument) {
|
|
23466
23567
|
if (typeof argument == 'object' || isCallable(argument)) return argument;
|
|
23467
|
-
throw $TypeError$6("Can't set " + $String$
|
|
23568
|
+
throw new $TypeError$6("Can't set " + $String$4(argument) + ' as a prototype');
|
|
23468
23569
|
};
|
|
23469
23570
|
|
|
23470
23571
|
/* eslint-disable no-proto -- safe */
|
|
@@ -23475,14 +23576,13 @@ var aPossiblePrototype = function (argument) {
|
|
|
23475
23576
|
// `Object.setPrototypeOf` method
|
|
23476
23577
|
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
23477
23578
|
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
23478
|
-
// eslint-disable-next-line es
|
|
23579
|
+
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
23479
23580
|
var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
23480
23581
|
var CORRECT_SETTER = false;
|
|
23481
23582
|
var test = {};
|
|
23482
23583
|
var setter;
|
|
23483
23584
|
try {
|
|
23484
|
-
|
|
23485
|
-
setter = functionUncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);
|
|
23585
|
+
setter = functionUncurryThisAccessor(Object.prototype, '__proto__', 'set');
|
|
23486
23586
|
setter(test, []);
|
|
23487
23587
|
CORRECT_SETTER = test instanceof Array;
|
|
23488
23588
|
} catch (error) { /* empty */ }
|
|
@@ -23495,14 +23595,6 @@ var objectSetPrototypeOf = Object.setPrototypeOf || ('__proto__' in {} ? functio
|
|
|
23495
23595
|
};
|
|
23496
23596
|
}() : undefined);
|
|
23497
23597
|
|
|
23498
|
-
var defineProperty$2 = objectDefineProperty.f;
|
|
23499
|
-
|
|
23500
|
-
|
|
23501
|
-
|
|
23502
|
-
|
|
23503
|
-
|
|
23504
|
-
|
|
23505
|
-
|
|
23506
23598
|
var enforceInternalState = internalState.enforce;
|
|
23507
23599
|
var getInternalState = internalState.get;
|
|
23508
23600
|
var Int8Array = global_1.Int8Array;
|
|
@@ -23518,7 +23610,7 @@ var TO_STRING_TAG$2 = wellKnownSymbol('toStringTag');
|
|
|
23518
23610
|
var TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG');
|
|
23519
23611
|
var TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor';
|
|
23520
23612
|
// Fixing native typed arrays in Opera Presto crashes the browser, see #595
|
|
23521
|
-
var NATIVE_ARRAY_BUFFER_VIEWS =
|
|
23613
|
+
var NATIVE_ARRAY_BUFFER_VIEWS = arrayBufferBasicDetection && !!objectSetPrototypeOf && classof(global_1.opera) !== 'Opera';
|
|
23522
23614
|
var TYPED_ARRAY_TAG_REQUIRED = false;
|
|
23523
23615
|
var NAME, Constructor, Prototype;
|
|
23524
23616
|
|
|
@@ -23563,12 +23655,12 @@ var isTypedArray = function (it) {
|
|
|
23563
23655
|
|
|
23564
23656
|
var aTypedArray = function (it) {
|
|
23565
23657
|
if (isTypedArray(it)) return it;
|
|
23566
|
-
throw TypeError$2('Target is not a typed array');
|
|
23658
|
+
throw new TypeError$2('Target is not a typed array');
|
|
23567
23659
|
};
|
|
23568
23660
|
|
|
23569
23661
|
var aTypedArrayConstructor = function (C) {
|
|
23570
23662
|
if (isCallable(C) && (!objectSetPrototypeOf || objectIsPrototypeOf(TypedArray, C))) return C;
|
|
23571
|
-
throw TypeError$2(tryToString(C) + ' is not a typed array constructor');
|
|
23663
|
+
throw new TypeError$2(tryToString(C) + ' is not a typed array constructor');
|
|
23572
23664
|
};
|
|
23573
23665
|
|
|
23574
23666
|
var exportTypedArrayMethod = function (KEY, property, forced, options) {
|
|
@@ -23632,7 +23724,7 @@ for (NAME in BigIntArrayConstructorsList) {
|
|
|
23632
23724
|
if (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) {
|
|
23633
23725
|
// eslint-disable-next-line no-shadow -- safe
|
|
23634
23726
|
TypedArray = function TypedArray() {
|
|
23635
|
-
throw TypeError$2('Incorrect invocation');
|
|
23727
|
+
throw new TypeError$2('Incorrect invocation');
|
|
23636
23728
|
};
|
|
23637
23729
|
if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
|
|
23638
23730
|
if (global_1[NAME]) objectSetPrototypeOf(global_1[NAME], TypedArray);
|
|
@@ -23653,9 +23745,12 @@ if (NATIVE_ARRAY_BUFFER_VIEWS && objectGetPrototypeOf(Uint8ClampedArrayPrototype
|
|
|
23653
23745
|
|
|
23654
23746
|
if (descriptors && !hasOwnProperty_1(TypedArrayPrototype, TO_STRING_TAG$2)) {
|
|
23655
23747
|
TYPED_ARRAY_TAG_REQUIRED = true;
|
|
23656
|
-
|
|
23657
|
-
|
|
23658
|
-
|
|
23748
|
+
defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG$2, {
|
|
23749
|
+
configurable: true,
|
|
23750
|
+
get: function () {
|
|
23751
|
+
return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined;
|
|
23752
|
+
}
|
|
23753
|
+
});
|
|
23659
23754
|
for (NAME in TypedArrayConstructorsList) if (global_1[NAME]) {
|
|
23660
23755
|
createNonEnumerableProperty(global_1[NAME], TYPED_ARRAY_TAG, NAME);
|
|
23661
23756
|
}
|
|
@@ -23679,7 +23774,7 @@ var aTypedArray$1 = arrayBufferViewCore.aTypedArray;
|
|
|
23679
23774
|
var exportTypedArrayMethod$1 = arrayBufferViewCore.exportTypedArrayMethod;
|
|
23680
23775
|
|
|
23681
23776
|
// `%TypedArray%.prototype.at` method
|
|
23682
|
-
// https://
|
|
23777
|
+
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.at
|
|
23683
23778
|
exportTypedArrayMethod$1('at', function at(index) {
|
|
23684
23779
|
var O = aTypedArray$1(this);
|
|
23685
23780
|
var len = lengthOfArrayLike(O);
|
|
@@ -23690,9 +23785,11 @@ exportTypedArrayMethod$1('at', function at(index) {
|
|
|
23690
23785
|
|
|
23691
23786
|
var selectedColor = "".concat(MATISSE_BLUE);
|
|
23692
23787
|
var hoverColor$3 = "".concat(HOVER_LIGHT_BLUE);
|
|
23788
|
+
var focusColor = "".concat(MATISSE_BLUE_DARK);
|
|
23693
23789
|
var fallbackValues$f = {
|
|
23694
23790
|
selectedColor: selectedColor,
|
|
23695
|
-
hoverColor: hoverColor$3
|
|
23791
|
+
hoverColor: hoverColor$3,
|
|
23792
|
+
focusColor: focusColor
|
|
23696
23793
|
};
|
|
23697
23794
|
|
|
23698
23795
|
var IconWrapper = styled.div.withConfig({
|
|
@@ -23715,7 +23812,7 @@ var DropdownContentWrapper = styled.div.withConfig({
|
|
|
23715
23812
|
var DropdownItemWrapper = styled.li.withConfig({
|
|
23716
23813
|
displayName: "Dropdown__DropdownItemWrapper",
|
|
23717
23814
|
componentId: "sc-pn6m0h-2"
|
|
23718
|
-
})(["
|
|
23815
|
+
})(["text-align:start;border-width:2px;border-style:solid;border-color:", ";box-shadow:none;box-sizing:border-box;width:100%;list-style:none;cursor:", ";&:hover{border-color:", ";> *{background:", ";border-color:", ";}}&:focus{outline:none;border-color:", ";> *{background:", ";border-color:white;outline:none;}}"], function (_ref4) {
|
|
23719
23816
|
var selected = _ref4.selected,
|
|
23720
23817
|
themeValues = _ref4.themeValues;
|
|
23721
23818
|
return selected ? themeValues.selectedColor : WHITE;
|
|
@@ -23723,44 +23820,71 @@ var DropdownItemWrapper = styled.li.withConfig({
|
|
|
23723
23820
|
var disabled = _ref5.disabled;
|
|
23724
23821
|
return disabled ? "default" : "pointer";
|
|
23725
23822
|
}, function (_ref6) {
|
|
23726
|
-
var
|
|
23727
|
-
|
|
23823
|
+
var disabled = _ref6.disabled,
|
|
23824
|
+
selected = _ref6.selected,
|
|
23728
23825
|
themeValues = _ref6.themeValues;
|
|
23729
|
-
return selected ? themeValues.
|
|
23826
|
+
return selected ? themeValues.focusColor : disabled ? WHITE : themeValues.hoverColor;
|
|
23730
23827
|
}, function (_ref7) {
|
|
23731
23828
|
var selected = _ref7.selected,
|
|
23732
23829
|
disabled = _ref7.disabled,
|
|
23733
23830
|
themeValues = _ref7.themeValues;
|
|
23734
|
-
return selected ? themeValues.
|
|
23831
|
+
return selected ? themeValues.focusColor : disabled ? WHITE : themeValues.hoverColor;
|
|
23832
|
+
}, function (_ref8) {
|
|
23833
|
+
var selected = _ref8.selected,
|
|
23834
|
+
disabled = _ref8.disabled,
|
|
23835
|
+
themeValues = _ref8.themeValues;
|
|
23836
|
+
return selected ? themeValues.focusColor : disabled ? WHITE : themeValues.hoverColor;
|
|
23837
|
+
}, function (_ref9) {
|
|
23838
|
+
var themeValues = _ref9.themeValues;
|
|
23839
|
+
return themeValues.selectedColor;
|
|
23840
|
+
}, function (_ref10) {
|
|
23841
|
+
var selected = _ref10.selected,
|
|
23842
|
+
disabled = _ref10.disabled,
|
|
23843
|
+
themeValues = _ref10.themeValues;
|
|
23844
|
+
return selected ? themeValues.focusColor : disabled ? WHITE : themeValues.hoverColor;
|
|
23845
|
+
});
|
|
23846
|
+
var DropdownItemBorder = styled.div.withConfig({
|
|
23847
|
+
displayName: "Dropdown__DropdownItemBorder",
|
|
23848
|
+
componentId: "sc-pn6m0h-3"
|
|
23849
|
+
})(["background:", ";border-color:", ";border-width:2px;border-style:solid;padding:12px;"], function (_ref11) {
|
|
23850
|
+
var selected = _ref11.selected,
|
|
23851
|
+
themeValues = _ref11.themeValues;
|
|
23852
|
+
return selected ? themeValues.selectedColor : WHITE;
|
|
23853
|
+
}, function (_ref12) {
|
|
23854
|
+
var selected = _ref12.selected,
|
|
23855
|
+
themeValues = _ref12.themeValues;
|
|
23856
|
+
return selected ? themeValues.selectedColor : WHITE;
|
|
23735
23857
|
});
|
|
23736
23858
|
|
|
23737
|
-
var Dropdown = function Dropdown(
|
|
23738
|
-
var placeholder =
|
|
23739
|
-
options =
|
|
23740
|
-
value =
|
|
23741
|
-
isOpen =
|
|
23742
|
-
isError =
|
|
23743
|
-
onSelect =
|
|
23744
|
-
|
|
23745
|
-
disabledValues =
|
|
23746
|
-
|
|
23747
|
-
_onClick =
|
|
23748
|
-
themeValues =
|
|
23749
|
-
maxHeight =
|
|
23750
|
-
|
|
23751
|
-
widthFitOptions =
|
|
23752
|
-
disabled =
|
|
23753
|
-
|
|
23754
|
-
hasTitles =
|
|
23755
|
-
|
|
23756
|
-
autoEraseTypeAhead =
|
|
23757
|
-
ariaLabelledby =
|
|
23758
|
-
ariaDescribedby =
|
|
23759
|
-
autocompleteValue =
|
|
23760
|
-
|
|
23761
|
-
smoothScroll =
|
|
23762
|
-
|
|
23763
|
-
ariaInvalid =
|
|
23859
|
+
var Dropdown = function Dropdown(_ref13) {
|
|
23860
|
+
var placeholder = _ref13.placeholder,
|
|
23861
|
+
options = _ref13.options,
|
|
23862
|
+
value = _ref13.value,
|
|
23863
|
+
isOpen = _ref13.isOpen,
|
|
23864
|
+
isError = _ref13.isError,
|
|
23865
|
+
onSelect = _ref13.onSelect,
|
|
23866
|
+
_ref13$disabledValues = _ref13.disabledValues,
|
|
23867
|
+
disabledValues = _ref13$disabledValues === void 0 ? [] : _ref13$disabledValues,
|
|
23868
|
+
_ref13$onClick = _ref13.onClick,
|
|
23869
|
+
_onClick = _ref13$onClick === void 0 ? noop : _ref13$onClick,
|
|
23870
|
+
themeValues = _ref13.themeValues,
|
|
23871
|
+
maxHeight = _ref13.maxHeight,
|
|
23872
|
+
_ref13$widthFitOption = _ref13.widthFitOptions,
|
|
23873
|
+
widthFitOptions = _ref13$widthFitOption === void 0 ? false : _ref13$widthFitOption,
|
|
23874
|
+
disabled = _ref13.disabled,
|
|
23875
|
+
_ref13$hasTitles = _ref13.hasTitles,
|
|
23876
|
+
hasTitles = _ref13$hasTitles === void 0 ? false : _ref13$hasTitles,
|
|
23877
|
+
_ref13$autoEraseTypeA = _ref13.autoEraseTypeAhead,
|
|
23878
|
+
autoEraseTypeAhead = _ref13$autoEraseTypeA === void 0 ? true : _ref13$autoEraseTypeA,
|
|
23879
|
+
ariaLabelledby = _ref13.ariaLabelledby,
|
|
23880
|
+
ariaDescribedby = _ref13.ariaDescribedby,
|
|
23881
|
+
autocompleteValue = _ref13.autocompleteValue,
|
|
23882
|
+
_ref13$smoothScroll = _ref13.smoothScroll,
|
|
23883
|
+
smoothScroll = _ref13$smoothScroll === void 0 ? true : _ref13$smoothScroll,
|
|
23884
|
+
_ref13$ariaInvalid = _ref13.ariaInvalid,
|
|
23885
|
+
ariaInvalid = _ref13$ariaInvalid === void 0 ? false : _ref13$ariaInvalid,
|
|
23886
|
+
_ref13$isRequired = _ref13.isRequired,
|
|
23887
|
+
isRequired = _ref13$isRequired === void 0 ? false : _ref13$isRequired;
|
|
23764
23888
|
|
|
23765
23889
|
var _useState = useState(""),
|
|
23766
23890
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -23953,11 +24077,13 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
23953
24077
|
clearTimeout(timer);
|
|
23954
24078
|
setTimer(setTimeout(function () {
|
|
23955
24079
|
return setInputValue("");
|
|
23956
|
-
},
|
|
24080
|
+
}, 20000));
|
|
23957
24081
|
}
|
|
23958
24082
|
|
|
23959
24083
|
setFilteredOptions(options.filter(function (option) {
|
|
23960
|
-
|
|
24084
|
+
var _option$value, _option$value$toLower, _option$text, _option$text$toLowerC;
|
|
24085
|
+
|
|
24086
|
+
return (option === null || option === void 0 ? void 0 : (_option$value = option.value) === null || _option$value === void 0 ? void 0 : (_option$value$toLower = _option$value.toLowerCase()) === null || _option$value$toLower === void 0 ? void 0 : _option$value$toLower.indexOf(inputValue === null || inputValue === void 0 ? void 0 : inputValue.toLowerCase())) >= 0 || ((_option$text = option.text) === null || _option$text === void 0 ? void 0 : (_option$text$toLowerC = _option$text.toLowerCase()) === null || _option$text$toLowerC === void 0 ? void 0 : _option$text$toLowerC.indexOf(inputValue === null || inputValue === void 0 ? void 0 : inputValue.toLowerCase())) >= 0;
|
|
23961
24087
|
}));
|
|
23962
24088
|
}, [inputValue]);
|
|
23963
24089
|
useEffect$1(function () {
|
|
@@ -24031,7 +24157,7 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
24031
24157
|
},
|
|
24032
24158
|
padding: "12px",
|
|
24033
24159
|
placeholder: getSelection(),
|
|
24034
|
-
required: options.required,
|
|
24160
|
+
required: options.required || isRequired,
|
|
24035
24161
|
role: "combobox",
|
|
24036
24162
|
themeValues: themeValues,
|
|
24037
24163
|
title: hasTitles ? getSelection() : null,
|
|
@@ -24082,11 +24208,15 @@ var Dropdown = function Dropdown(_ref8) {
|
|
|
24082
24208
|
onFocus: function onFocus() {
|
|
24083
24209
|
return setFocusedRef(optionRefs.current[i]);
|
|
24084
24210
|
}
|
|
24211
|
+
}, /*#__PURE__*/React.createElement(DropdownItemBorder, {
|
|
24212
|
+
disabled: disabledValues.includes(choice.value),
|
|
24213
|
+
selected: choice.value === value,
|
|
24214
|
+
themeValues: themeValues
|
|
24085
24215
|
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
24086
24216
|
variant: "p",
|
|
24087
24217
|
color: choice.value === value ? WHITE : disabledValues.includes(choice.value) ? STORM_GREY : MINESHAFT_GREY,
|
|
24088
|
-
extraStyles: "padding-left: 16px;\n
|
|
24089
|
-
}, choice.text));
|
|
24218
|
+
extraStyles: "padding-left: 16px;\n cursor: ".concat(disabledValues.includes(choice.value) ? "default" : "pointer", ";\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;")
|
|
24219
|
+
}, choice.text)));
|
|
24090
24220
|
}))) : /*#__PURE__*/React.createElement(Fragment$1, null)));
|
|
24091
24221
|
};
|
|
24092
24222
|
|
|
@@ -24195,7 +24325,9 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24195
24325
|
_ref$dataQa = _ref.dataQa,
|
|
24196
24326
|
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa,
|
|
24197
24327
|
_ref$widthFitOptions = _ref.widthFitOptions,
|
|
24198
|
-
widthFitOptions = _ref$widthFitOptions === void 0 ? false : _ref$widthFitOptions
|
|
24328
|
+
widthFitOptions = _ref$widthFitOptions === void 0 ? false : _ref$widthFitOptions,
|
|
24329
|
+
_ref$isRequired = _ref.isRequired,
|
|
24330
|
+
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
24199
24331
|
|
|
24200
24332
|
var _useState = useState(false),
|
|
24201
24333
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -24257,11 +24389,12 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24257
24389
|
},
|
|
24258
24390
|
disabled: disabled,
|
|
24259
24391
|
autocompleteValue: autocompleteValue,
|
|
24260
|
-
smoothScroll: smoothScroll
|
|
24392
|
+
smoothScroll: smoothScroll,
|
|
24393
|
+
isRequired: isRequired
|
|
24261
24394
|
}), /*#__PURE__*/React.createElement(Stack, {
|
|
24262
24395
|
direction: "row",
|
|
24263
24396
|
justify: "space-between"
|
|
24264
|
-
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
24397
|
+
}, field.hasErrors && field.dirty || field.hasErrors && showErrors ? /*#__PURE__*/React.createElement(Text$1, {
|
|
24265
24398
|
color: ERROR_COLOR,
|
|
24266
24399
|
variant: "pXS",
|
|
24267
24400
|
weight: themeValues.fontWeight,
|
|
@@ -24270,7 +24403,9 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24270
24403
|
"aria-live": "polite",
|
|
24271
24404
|
"aria-atomic": true,
|
|
24272
24405
|
"data-qa": createIdFromString(labelTextWhenNoError, "error message")
|
|
24273
|
-
},
|
|
24406
|
+
}, errorMessages[field.errors[0]]) : /*#__PURE__*/React.createElement(Text$1, {
|
|
24407
|
+
extraStyles: "height: ".concat(themeValues.lineHeight, ";")
|
|
24408
|
+
})));
|
|
24274
24409
|
};
|
|
24275
24410
|
|
|
24276
24411
|
var FormSelect$1 = themeComponent(FormSelect, "FormSelect", fallbackValues$g, "default");
|
|
@@ -25026,6 +25161,8 @@ var CountryDropdown = function CountryDropdown(_ref) {
|
|
|
25026
25161
|
fieldActions = _ref.fieldActions,
|
|
25027
25162
|
showErrors = _ref.showErrors,
|
|
25028
25163
|
onChange = _ref.onChange,
|
|
25164
|
+
_ref$isRequired = _ref.isRequired,
|
|
25165
|
+
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired,
|
|
25029
25166
|
_ref$dataQa = _ref.dataQa,
|
|
25030
25167
|
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa;
|
|
25031
25168
|
return /*#__PURE__*/React.createElement(FormSelect$1, {
|
|
@@ -25037,7 +25174,8 @@ var CountryDropdown = function CountryDropdown(_ref) {
|
|
|
25037
25174
|
errorMessages: errorMessages,
|
|
25038
25175
|
showErrors: showErrors,
|
|
25039
25176
|
onChange: onChange,
|
|
25040
|
-
autocompleteValue: "country-name"
|
|
25177
|
+
autocompleteValue: "country-name",
|
|
25178
|
+
isRequired: isRequired
|
|
25041
25179
|
});
|
|
25042
25180
|
};
|
|
25043
25181
|
|
|
@@ -25201,6 +25339,346 @@ var DisplayBox = function DisplayBox(_ref) {
|
|
|
25201
25339
|
|
|
25202
25340
|
var DisplayBox$1 = themeComponent(DisplayBox, "DisplayBox", fallbackValues$i);
|
|
25203
25341
|
|
|
25342
|
+
/*
|
|
25343
|
+
Hook that assigns a click event listener to the main document element
|
|
25344
|
+
Returns a ref to attach to another element (like an icon/button that triggers a popover)
|
|
25345
|
+
If a click event gets captured by the document and the assigned element isn't the target
|
|
25346
|
+
hook will run whatever handler is passed (eg a function that closes a popover)
|
|
25347
|
+
|
|
25348
|
+
See popover component for implementation
|
|
25349
|
+
|
|
25350
|
+
*/
|
|
25351
|
+
|
|
25352
|
+
var useOutsideClickHook = function useOutsideClickHook(handler) {
|
|
25353
|
+
var ref = useRef();
|
|
25354
|
+
useEffect$1(function () {
|
|
25355
|
+
}, [ref]);
|
|
25356
|
+
return ref;
|
|
25357
|
+
};
|
|
25358
|
+
|
|
25359
|
+
/*
|
|
25360
|
+
Hook that takes an ID selector for an element on the screen
|
|
25361
|
+
And optionally values for top position, left position, smooth behavior
|
|
25362
|
+
Finds element on screen and scrolls it to the provided coordinates
|
|
25363
|
+
|
|
25364
|
+
(string, number, number, string, number) => undefined;
|
|
25365
|
+
*/
|
|
25366
|
+
var useScrollTo = function useScrollTo(id) {
|
|
25367
|
+
var top = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
25368
|
+
var left = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
|
25369
|
+
var behavior = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "auto";
|
|
25370
|
+
var delay = arguments.length > 4 ? arguments[4] : undefined;
|
|
25371
|
+
var scrollItem;
|
|
25372
|
+
|
|
25373
|
+
if (delay) {
|
|
25374
|
+
setTimeout(function () {
|
|
25375
|
+
var _scrollItem;
|
|
25376
|
+
|
|
25377
|
+
scrollItem = document.getElementById(id);
|
|
25378
|
+
(_scrollItem = scrollItem) === null || _scrollItem === void 0 ? void 0 : _scrollItem.scrollTo({
|
|
25379
|
+
top: top,
|
|
25380
|
+
left: left,
|
|
25381
|
+
behavior: behavior
|
|
25382
|
+
});
|
|
25383
|
+
}, delay);
|
|
25384
|
+
} else {
|
|
25385
|
+
var _scrollItem2;
|
|
25386
|
+
|
|
25387
|
+
scrollItem = document.getElementById(id);
|
|
25388
|
+
(_scrollItem2 = scrollItem) === null || _scrollItem2 === void 0 ? void 0 : _scrollItem2.scrollTo({
|
|
25389
|
+
top: top,
|
|
25390
|
+
left: left,
|
|
25391
|
+
behavior: behavior
|
|
25392
|
+
});
|
|
25393
|
+
}
|
|
25394
|
+
};
|
|
25395
|
+
|
|
25396
|
+
var initialToastState = {
|
|
25397
|
+
isOpen: false,
|
|
25398
|
+
variant: "",
|
|
25399
|
+
message: ""
|
|
25400
|
+
};
|
|
25401
|
+
|
|
25402
|
+
var useToastNotification = function useToastNotification() {
|
|
25403
|
+
var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
25404
|
+
_ref$timeout = _ref.timeout,
|
|
25405
|
+
timeout = _ref$timeout === void 0 ? 5000 : _ref$timeout;
|
|
25406
|
+
|
|
25407
|
+
var _useState = useState(initialToastState),
|
|
25408
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
25409
|
+
toastState = _useState2[0],
|
|
25410
|
+
setToastState = _useState2[1];
|
|
25411
|
+
|
|
25412
|
+
useEffect$1(function () {
|
|
25413
|
+
if (toastState.isOpen) {
|
|
25414
|
+
setTimeout(function () {
|
|
25415
|
+
setToastState(initialToastState);
|
|
25416
|
+
}, timeout);
|
|
25417
|
+
}
|
|
25418
|
+
}, [timeout, toastState.isOpen]);
|
|
25419
|
+
|
|
25420
|
+
var showToast = function showToast(_ref2) {
|
|
25421
|
+
var message = _ref2.message,
|
|
25422
|
+
variant = _ref2.variant;
|
|
25423
|
+
return setToastState({
|
|
25424
|
+
isOpen: true,
|
|
25425
|
+
variant: variant,
|
|
25426
|
+
message: message
|
|
25427
|
+
});
|
|
25428
|
+
};
|
|
25429
|
+
|
|
25430
|
+
var hideToast = function hideToast() {
|
|
25431
|
+
return setToastState(initialToastState);
|
|
25432
|
+
};
|
|
25433
|
+
|
|
25434
|
+
return {
|
|
25435
|
+
isToastOpen: toastState.isOpen,
|
|
25436
|
+
toastVariant: toastState.variant,
|
|
25437
|
+
toastMessage: toastState.message,
|
|
25438
|
+
showToast: showToast,
|
|
25439
|
+
hideToast: hideToast
|
|
25440
|
+
};
|
|
25441
|
+
};
|
|
25442
|
+
|
|
25443
|
+
|
|
25444
|
+
|
|
25445
|
+
var index$4 = /*#__PURE__*/Object.freeze({
|
|
25446
|
+
__proto__: null,
|
|
25447
|
+
useOutsideClick: useOutsideClickHook,
|
|
25448
|
+
useScrollTo: useScrollTo,
|
|
25449
|
+
useToastNotification: useToastNotification
|
|
25450
|
+
});
|
|
25451
|
+
|
|
25452
|
+
var hoverColor$4 = "#116285";
|
|
25453
|
+
var activeColor$4 = "#0E506D";
|
|
25454
|
+
var popoverTriggerColor = "#15749D";
|
|
25455
|
+
var fallbackValues$j = {
|
|
25456
|
+
hoverColor: hoverColor$4,
|
|
25457
|
+
activeColor: activeColor$4,
|
|
25458
|
+
popoverTriggerColor: popoverTriggerColor
|
|
25459
|
+
};
|
|
25460
|
+
|
|
25461
|
+
var arrowBorder = function arrowBorder(borderColor, direction) {
|
|
25462
|
+
var width = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "8px";
|
|
25463
|
+
var angle = "".concat(width, " solid transparent");
|
|
25464
|
+
var straight = "".concat(width, " solid ").concat(borderColor);
|
|
25465
|
+
|
|
25466
|
+
if (direction == "down") {
|
|
25467
|
+
return "border-left: ".concat(angle, "; border-right: ").concat(angle, "; border-top: ").concat(straight);
|
|
25468
|
+
} else if (direction == "up") {
|
|
25469
|
+
return "border-left: ".concat(angle, "; border-right: ").concat(angle, "; border-bottom: ").concat(straight);
|
|
25470
|
+
} else if (direction == "left") {
|
|
25471
|
+
return "border-top: ".concat(angle, "; border-bottom: ").concat(angle, "; border-right: ").concat(straight);
|
|
25472
|
+
} else if (direction == "right") {
|
|
25473
|
+
return "border-top: ".concat(angle, "; border-bottom: ").concat(angle, "; border-left: ").concat(straight);
|
|
25474
|
+
}
|
|
25475
|
+
};
|
|
25476
|
+
|
|
25477
|
+
var Popover = function Popover(_ref) {
|
|
25478
|
+
var themeValues = _ref.themeValues,
|
|
25479
|
+
_ref$triggerText = _ref.triggerText,
|
|
25480
|
+
triggerText = _ref$triggerText === void 0 ? "" : _ref$triggerText,
|
|
25481
|
+
_ref$content = _ref.content,
|
|
25482
|
+
content = _ref$content === void 0 ? "" : _ref$content,
|
|
25483
|
+
_ref$hasIcon = _ref.hasIcon,
|
|
25484
|
+
hasIcon = _ref$hasIcon === void 0 ? false : _ref$hasIcon,
|
|
25485
|
+
Icon = _ref.icon,
|
|
25486
|
+
_ref$iconHelpText = _ref.iconHelpText,
|
|
25487
|
+
iconHelpText = _ref$iconHelpText === void 0 ? "" : _ref$iconHelpText,
|
|
25488
|
+
_ref$popoverID = _ref.popoverID,
|
|
25489
|
+
popoverID = _ref$popoverID === void 0 ? 0 : _ref$popoverID,
|
|
25490
|
+
_ref$popoverFocus = _ref.popoverFocus,
|
|
25491
|
+
popoverFocus = _ref$popoverFocus === void 0 ? false : _ref$popoverFocus,
|
|
25492
|
+
extraStyles = _ref.extraStyles,
|
|
25493
|
+
textExtraStyles = _ref.textExtraStyles,
|
|
25494
|
+
_ref$minWidth = _ref.minWidth,
|
|
25495
|
+
minWidth = _ref$minWidth === void 0 ? "250px" : _ref$minWidth,
|
|
25496
|
+
_ref$maxWidth = _ref.maxWidth,
|
|
25497
|
+
maxWidth = _ref$maxWidth === void 0 ? "300px" : _ref$maxWidth,
|
|
25498
|
+
_ref$height = _ref.height,
|
|
25499
|
+
height = _ref$height === void 0 ? "auto" : _ref$height,
|
|
25500
|
+
position = _ref.position,
|
|
25501
|
+
arrowPosition = _ref.arrowPosition,
|
|
25502
|
+
_ref$arrowDirection = _ref.arrowDirection,
|
|
25503
|
+
arrowDirection = _ref$arrowDirection === void 0 ? "down" : _ref$arrowDirection,
|
|
25504
|
+
_ref$transform = _ref.transform,
|
|
25505
|
+
transform = _ref$transform === void 0 ? "none" : _ref$transform,
|
|
25506
|
+
buttonExtraStyles = _ref.buttonExtraStyles,
|
|
25507
|
+
_ref$backgroundColor = _ref.backgroundColor,
|
|
25508
|
+
backgroundColor = _ref$backgroundColor === void 0 ? "white" : _ref$backgroundColor,
|
|
25509
|
+
_ref$borderColor = _ref.borderColor,
|
|
25510
|
+
borderColor = _ref$borderColor === void 0 ? "rgba(255, 255, 255, 0.85)" : _ref$borderColor,
|
|
25511
|
+
popoverExtraStyles = _ref.popoverExtraStyles;
|
|
25512
|
+
var hoverColor = themeValues.hoverColor,
|
|
25513
|
+
activeColor = themeValues.activeColor,
|
|
25514
|
+
popoverTriggerColor = themeValues.popoverTriggerColor;
|
|
25515
|
+
|
|
25516
|
+
var _ref2 = position !== null && position !== void 0 ? position : {},
|
|
25517
|
+
_ref2$top = _ref2.top,
|
|
25518
|
+
top = _ref2$top === void 0 ? "-110px" : _ref2$top,
|
|
25519
|
+
_ref2$right = _ref2.right,
|
|
25520
|
+
right = _ref2$right === void 0 ? "auto" : _ref2$right,
|
|
25521
|
+
_ref2$bottom = _ref2.bottom,
|
|
25522
|
+
bottom = _ref2$bottom === void 0 ? "auto" : _ref2$bottom,
|
|
25523
|
+
_ref2$left = _ref2.left,
|
|
25524
|
+
left = _ref2$left === void 0 ? "-225px" : _ref2$left;
|
|
25525
|
+
|
|
25526
|
+
var _ref3 = arrowPosition !== null && arrowPosition !== void 0 ? arrowPosition : {},
|
|
25527
|
+
_ref3$arrowTop = _ref3.arrowTop,
|
|
25528
|
+
arrowTop = _ref3$arrowTop === void 0 ? "auto" : _ref3$arrowTop,
|
|
25529
|
+
_ref3$arrowRight = _ref3.arrowRight,
|
|
25530
|
+
arrowRight = _ref3$arrowRight === void 0 ? "10px" : _ref3$arrowRight,
|
|
25531
|
+
_ref3$arrowBottom = _ref3.arrowBottom,
|
|
25532
|
+
arrowBottom = _ref3$arrowBottom === void 0 ? "-8px" : _ref3$arrowBottom,
|
|
25533
|
+
_ref3$arrowLeft = _ref3.arrowLeft,
|
|
25534
|
+
arrowLeft = _ref3$arrowLeft === void 0 ? "auto" : _ref3$arrowLeft;
|
|
25535
|
+
|
|
25536
|
+
var _useState = useState(false),
|
|
25537
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
25538
|
+
popoverOpen = _useState2[0],
|
|
25539
|
+
togglePopover = _useState2[1];
|
|
25540
|
+
|
|
25541
|
+
var handleTogglePopover = function handleTogglePopover(popoverState) {
|
|
25542
|
+
if (popoverOpen !== popoverState) {
|
|
25543
|
+
togglePopover(popoverState);
|
|
25544
|
+
}
|
|
25545
|
+
};
|
|
25546
|
+
|
|
25547
|
+
var triggerRef = useOutsideClickHook();
|
|
25548
|
+
return /*#__PURE__*/React.createElement(Box, {
|
|
25549
|
+
padding: "0",
|
|
25550
|
+
extraStyles: "position: relative; ".concat(extraStyles)
|
|
25551
|
+
}, /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
25552
|
+
action: function action() {
|
|
25553
|
+
return noop;
|
|
25554
|
+
},
|
|
25555
|
+
onFocus: function onFocus() {
|
|
25556
|
+
handleTogglePopover(true);
|
|
25557
|
+
},
|
|
25558
|
+
onBlur: function onBlur() {
|
|
25559
|
+
handleTogglePopover(false);
|
|
25560
|
+
},
|
|
25561
|
+
onKeyDown: function onKeyDown(e) {
|
|
25562
|
+
if (e.keyCode === 27) {
|
|
25563
|
+
handleTogglePopover(false);
|
|
25564
|
+
}
|
|
25565
|
+
},
|
|
25566
|
+
onTouchStart: function onTouchStart() {
|
|
25567
|
+
return handleTogglePopover(true);
|
|
25568
|
+
},
|
|
25569
|
+
onTouchEnd: function onTouchEnd() {
|
|
25570
|
+
return handleTogglePopover(false);
|
|
25571
|
+
},
|
|
25572
|
+
onMouseEnter: function onMouseEnter() {
|
|
25573
|
+
return handleTogglePopover(true);
|
|
25574
|
+
},
|
|
25575
|
+
onMouseLeave: function onMouseLeave() {
|
|
25576
|
+
return handleTogglePopover(false);
|
|
25577
|
+
},
|
|
25578
|
+
contentOverride: true,
|
|
25579
|
+
variant: "smallGhost",
|
|
25580
|
+
tabIndex: "0",
|
|
25581
|
+
id: "btnPopover".concat(popoverID),
|
|
25582
|
+
"aria-expanded": popoverOpen,
|
|
25583
|
+
"aria-labelledby": "btnPopover".concat(popoverID, "_info Disclosure").concat(popoverID),
|
|
25584
|
+
"aria-describedby": "Disclosure".concat(popoverID),
|
|
25585
|
+
"aria-controls": "Disclosed".concat(popoverID),
|
|
25586
|
+
ref: triggerRef,
|
|
25587
|
+
extraStyles: buttonExtraStyles
|
|
25588
|
+
}, hasIcon && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Icon, null), /*#__PURE__*/React.createElement(Box, {
|
|
25589
|
+
padding: "0",
|
|
25590
|
+
srOnly: true
|
|
25591
|
+
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
25592
|
+
id: "btnPopover".concat(popoverID, "_info")
|
|
25593
|
+
}, iconHelpText))), !hasIcon && /*#__PURE__*/React.createElement(Text$1, {
|
|
25594
|
+
color: popoverTriggerColor,
|
|
25595
|
+
extraStyles: "&:active { color: ".concat(activeColor, "; } &:hover { color: ").concat(hoverColor, " }; ").concat(textExtraStyles)
|
|
25596
|
+
}, triggerText)), /*#__PURE__*/React.createElement(Box, {
|
|
25597
|
+
background: backgroundColor,
|
|
25598
|
+
borderRadius: "4px",
|
|
25599
|
+
boxShadow: "0px 2px 14px 0px rgb(246, 246, 249), 0px 3px 8px 0px rgb(202, 206, 216)",
|
|
25600
|
+
id: "Disclosed".concat(popoverID),
|
|
25601
|
+
role: "region",
|
|
25602
|
+
"aria-describedby": "Disclosure".concat(popoverID),
|
|
25603
|
+
tabIndex: popoverFocus && popoverOpen ? "0" : "-1",
|
|
25604
|
+
minWidth: minWidth,
|
|
25605
|
+
maxWidth: maxWidth,
|
|
25606
|
+
extraStyles: "\n display: ".concat(popoverOpen ? "block" : "none", "; \n position: absolute; \n top: ").concat(top, "; \n right: ").concat(right, "; \n bottom: ").concat(bottom, "; \n left: ").concat(left, ";\n height: ").concat(height, ";\n transform: ").concat(transform, ";\n ").concat(popoverExtraStyles, ";\n ")
|
|
25607
|
+
}, /*#__PURE__*/React.createElement(Paragraph$1, null, content), /*#__PURE__*/React.createElement(Box, {
|
|
25608
|
+
padding: "0",
|
|
25609
|
+
extraStyles: "\n position: absolute;\n content: \"\";\n width: 0;\n height: 0;\n ".concat(arrowBorder(borderColor, arrowDirection, "8px"), ";\n filter: drop-shadow(2px 8px 14px black);\n bottom: ").concat(arrowBottom, ";\n right: ").concat(arrowRight, ";\n top: ").concat(arrowTop, ";\n left: ").concat(arrowLeft, ";\n ")
|
|
25610
|
+
})));
|
|
25611
|
+
};
|
|
25612
|
+
|
|
25613
|
+
var Popover$1 = themeComponent(Popover, "Popover", fallbackValues$j);
|
|
25614
|
+
|
|
25615
|
+
var DisplayCard = function DisplayCard(_ref) {
|
|
25616
|
+
var title = _ref.title,
|
|
25617
|
+
item = _ref.item,
|
|
25618
|
+
buttonText = _ref.buttonText,
|
|
25619
|
+
buttonAction = _ref.buttonAction,
|
|
25620
|
+
url = _ref.url,
|
|
25621
|
+
_ref$link = _ref.link,
|
|
25622
|
+
link = _ref$link === void 0 ? false : _ref$link,
|
|
25623
|
+
helpText = _ref.helpText,
|
|
25624
|
+
_ref$hasPopover = _ref.hasPopover,
|
|
25625
|
+
hasPopover = _ref$hasPopover === void 0 ? false : _ref$hasPopover,
|
|
25626
|
+
_ref$popoverTriggerTe = _ref.popoverTriggerText,
|
|
25627
|
+
popoverTriggerText = _ref$popoverTriggerTe === void 0 ? "" : _ref$popoverTriggerTe,
|
|
25628
|
+
_ref$popoverContent = _ref.popoverContent,
|
|
25629
|
+
popoverContent = _ref$popoverContent === void 0 ? "" : _ref$popoverContent,
|
|
25630
|
+
popoverExtraStyles = _ref.popoverExtraStyles,
|
|
25631
|
+
popoverTextExtraStyles = _ref.popoverTextExtraStyles;
|
|
25632
|
+
return /*#__PURE__*/React.createElement(Box, {
|
|
25633
|
+
padding: "0 0 16px"
|
|
25634
|
+
}, /*#__PURE__*/React.createElement(Stack, {
|
|
25635
|
+
childGap: "0rem"
|
|
25636
|
+
}, /*#__PURE__*/React.createElement(Box, {
|
|
25637
|
+
padding: "0 0 8px 0"
|
|
25638
|
+
}, /*#__PURE__*/React.createElement(Cluster, {
|
|
25639
|
+
justify: "space-between",
|
|
25640
|
+
align: "center",
|
|
25641
|
+
overflow: true
|
|
25642
|
+
}, /*#__PURE__*/React.createElement(Paragraph$1, {
|
|
25643
|
+
variant: "pL",
|
|
25644
|
+
color: CHARADE_GREY,
|
|
25645
|
+
extraStyles: "letter-spacing: 0.29px"
|
|
25646
|
+
}, title), hasPopover && /*#__PURE__*/React.createElement(Popover$1, {
|
|
25647
|
+
triggerText: popoverTriggerText,
|
|
25648
|
+
content: popoverContent,
|
|
25649
|
+
popoverExtraStyles: popoverExtraStyles,
|
|
25650
|
+
popoverTextExtraStyles: popoverTextExtraStyles
|
|
25651
|
+
}))), /*#__PURE__*/React.createElement(Box, {
|
|
25652
|
+
padding: "0"
|
|
25653
|
+
}, /*#__PURE__*/React.createElement(Box, {
|
|
25654
|
+
padding: "24px",
|
|
25655
|
+
borderSize: "1px",
|
|
25656
|
+
borderRadius: "4px",
|
|
25657
|
+
background: WHITE,
|
|
25658
|
+
boxShadow: "0px 2px 14px 0px rgb(246, 246, 249), 0px 3px 8px 0px rgb(202, 206, 216)"
|
|
25659
|
+
}, /*#__PURE__*/React.createElement(Cluster, {
|
|
25660
|
+
justify: "space-between",
|
|
25661
|
+
align: "center"
|
|
25662
|
+
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
25663
|
+
color: CHARADE_GREY
|
|
25664
|
+
}, item), link ? /*#__PURE__*/React.createElement(ButtonWithLink, {
|
|
25665
|
+
text: buttonText,
|
|
25666
|
+
url: url,
|
|
25667
|
+
variant: "smallGhost",
|
|
25668
|
+
dataQa: buttonText,
|
|
25669
|
+
extraStyles: "min-width: 0;"
|
|
25670
|
+
}) : buttonAction ? /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
25671
|
+
text: buttonText,
|
|
25672
|
+
action: buttonAction,
|
|
25673
|
+
variant: "smallGhost",
|
|
25674
|
+
dataQa: buttonText,
|
|
25675
|
+
extraStyles: "min-width: 0;"
|
|
25676
|
+
}) : helpText ? /*#__PURE__*/React.createElement(Text$1, {
|
|
25677
|
+
color: STORM_GREY,
|
|
25678
|
+
extraStyles: "font-style: italic;"
|
|
25679
|
+
}, helpText) : /*#__PURE__*/React.createElement(Fragment$1, null))))));
|
|
25680
|
+
};
|
|
25681
|
+
|
|
25204
25682
|
function _extends$2() {
|
|
25205
25683
|
_extends$2 = Object.assign || function (target) {
|
|
25206
25684
|
for (var i = 1; i < arguments.length; i++) {
|
|
@@ -25479,344 +25957,6 @@ var FormattedInput = function FormattedInput(_ref) {
|
|
|
25479
25957
|
}));
|
|
25480
25958
|
};
|
|
25481
25959
|
|
|
25482
|
-
var formatDelimiter = "_";
|
|
25483
|
-
var phoneFormats = ["", "_", "__", "(___) ", "(___) _", "(___) __", "(___) ___-", "(___) ___-_", "(___) ___-__", "(___) ___-___", "(___) ___-____"];
|
|
25484
|
-
var zipFormats = ["", "_", "__", "___", "____", "_____", "______", "_____-__", "_____-___", "_____-____"];
|
|
25485
|
-
var creditCardFormats = ["", "_", "__", "___", "____", "____ _", "____ __", "____ ___", "____ ____", "____ ____ _", "____ ____ __", "____ ____ ___", "____ ____ ____", "____ ____ ____ _", "____ ____ ____ __", "____ ____ ____ ___", "____ ____ ____ ____"];
|
|
25486
|
-
var moneyFormats = ["", "$0.0_", "$0.__", "$_.__", "$__.__", "$___.__", "$_,___.__", "$__,___.__", "$___,___.__", "$_,___,___.__", "$__,___,___.__", "$___,___,___.__", "$_,___,___,___.__", "$__,___,___,___.__", "$___,___,___,___.__", "$_,___,___,___,___.__"];
|
|
25487
|
-
var expirationDateFormats = ["", "_", "__/", "__/_", "__/__"];
|
|
25488
|
-
var zipFormat = createFormat(zipFormats, formatDelimiter);
|
|
25489
|
-
var creditCardFormat = createFormat(creditCardFormats, formatDelimiter);
|
|
25490
|
-
var expirationDateFormat = createFormat(expirationDateFormats, formatDelimiter);
|
|
25491
|
-
var phoneFormat = createFormat(phoneFormats, formatDelimiter);
|
|
25492
|
-
var moneyFormat = createFormat(moneyFormats, formatDelimiter);
|
|
25493
|
-
var renderCardStatus = function renderCardStatus(expirationStatus, expireDate) {
|
|
25494
|
-
var textAlign = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "right";
|
|
25495
|
-
var as = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "span";
|
|
25496
|
-
var ACTIVE = "ACTIVE";
|
|
25497
|
-
var EXPIRING_SOON = "EXPIRING_SOON";
|
|
25498
|
-
var EXPIRED = "EXPIRED";
|
|
25499
|
-
var textMargin = textAlign === "right" ? "auto" : "0";
|
|
25500
|
-
|
|
25501
|
-
switch (expirationStatus) {
|
|
25502
|
-
case ACTIVE:
|
|
25503
|
-
return /*#__PURE__*/React.createElement(Text$1, {
|
|
25504
|
-
as: as,
|
|
25505
|
-
variant: "pXS",
|
|
25506
|
-
color: ASH_GREY,
|
|
25507
|
-
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
25508
|
-
}, "Exp Date ", expireDate);
|
|
25509
|
-
|
|
25510
|
-
case EXPIRING_SOON:
|
|
25511
|
-
return /*#__PURE__*/React.createElement(Text$1, {
|
|
25512
|
-
as: as,
|
|
25513
|
-
variant: "pXS",
|
|
25514
|
-
color: FIRE_YELLOW,
|
|
25515
|
-
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
25516
|
-
}, "Expiring Soon ", expireDate);
|
|
25517
|
-
|
|
25518
|
-
case EXPIRED:
|
|
25519
|
-
return /*#__PURE__*/React.createElement(Text$1, {
|
|
25520
|
-
as: as,
|
|
25521
|
-
variant: "pXS",
|
|
25522
|
-
color: ASH_GREY,
|
|
25523
|
-
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
25524
|
-
}, "Expired");
|
|
25525
|
-
}
|
|
25526
|
-
};
|
|
25527
|
-
|
|
25528
|
-
var formats = /*#__PURE__*/Object.freeze({
|
|
25529
|
-
__proto__: null,
|
|
25530
|
-
formatDelimiter: formatDelimiter,
|
|
25531
|
-
phoneFormats: phoneFormats,
|
|
25532
|
-
moneyFormats: moneyFormats,
|
|
25533
|
-
expirationDateFormats: expirationDateFormats,
|
|
25534
|
-
zipFormat: zipFormat,
|
|
25535
|
-
creditCardFormat: creditCardFormat,
|
|
25536
|
-
expirationDateFormat: expirationDateFormat,
|
|
25537
|
-
phoneFormat: phoneFormat,
|
|
25538
|
-
moneyFormat: moneyFormat,
|
|
25539
|
-
renderCardStatus: renderCardStatus
|
|
25540
|
-
});
|
|
25541
|
-
|
|
25542
|
-
var useFocusInvalidInput = function useFocusInvalidInput(hasErrors) {
|
|
25543
|
-
var resetHasErrors = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
|
|
25544
|
-
// Only move focus when "hasErrors" is true
|
|
25545
|
-
// "hasErrors" is managed by container page of form
|
|
25546
|
-
// typically set to "true" on attempted form submission, if errors exist
|
|
25547
|
-
// Reset errors, if provided, resets the error state tracking in order to properly re-run
|
|
25548
|
-
useEffect$1(function () {
|
|
25549
|
-
if (hasErrors) {
|
|
25550
|
-
var _inputsWithErrors$;
|
|
25551
|
-
|
|
25552
|
-
var inputsWithErrors = document.querySelectorAll("input[aria-invalid=true]");
|
|
25553
|
-
inputsWithErrors === null || inputsWithErrors === void 0 ? void 0 : (_inputsWithErrors$ = inputsWithErrors[0]) === null || _inputsWithErrors$ === void 0 ? void 0 : _inputsWithErrors$.focus();
|
|
25554
|
-
}
|
|
25555
|
-
|
|
25556
|
-
return function () {
|
|
25557
|
-
return resetHasErrors(false);
|
|
25558
|
-
};
|
|
25559
|
-
});
|
|
25560
|
-
};
|
|
25561
|
-
|
|
25562
|
-
/*
|
|
25563
|
-
Hook that assigns a click event listener to the main document element
|
|
25564
|
-
Returns a ref to attach to another element (like an icon/button that triggers a popover)
|
|
25565
|
-
If a click event gets captured by the document and the assigned element isn't the target
|
|
25566
|
-
hook will run whatever handler is passed (eg a function that closes a popover)
|
|
25567
|
-
|
|
25568
|
-
See popover component for implementation
|
|
25569
|
-
|
|
25570
|
-
*/
|
|
25571
|
-
|
|
25572
|
-
var useOutsideClickHook = function useOutsideClickHook(handler) {
|
|
25573
|
-
var ref = useRef();
|
|
25574
|
-
useEffect$1(function () {
|
|
25575
|
-
}, [ref]);
|
|
25576
|
-
return ref;
|
|
25577
|
-
};
|
|
25578
|
-
|
|
25579
|
-
|
|
25580
|
-
|
|
25581
|
-
var index$4 = /*#__PURE__*/Object.freeze({
|
|
25582
|
-
__proto__: null,
|
|
25583
|
-
formats: formats,
|
|
25584
|
-
general: general,
|
|
25585
|
-
theme: themeUtils,
|
|
25586
|
-
useFocusInvalidInput: useFocusInvalidInput,
|
|
25587
|
-
useOutsideClick: useOutsideClickHook
|
|
25588
|
-
});
|
|
25589
|
-
|
|
25590
|
-
var hoverColor$4 = "#116285";
|
|
25591
|
-
var activeColor$4 = "#0E506D";
|
|
25592
|
-
var popoverTriggerColor = "#15749D";
|
|
25593
|
-
var fallbackValues$j = {
|
|
25594
|
-
hoverColor: hoverColor$4,
|
|
25595
|
-
activeColor: activeColor$4,
|
|
25596
|
-
popoverTriggerColor: popoverTriggerColor
|
|
25597
|
-
};
|
|
25598
|
-
|
|
25599
|
-
var arrowBorder = function arrowBorder(borderColor, direction) {
|
|
25600
|
-
var width = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "8px";
|
|
25601
|
-
var angle = "".concat(width, " solid transparent");
|
|
25602
|
-
var straight = "".concat(width, " solid ").concat(borderColor);
|
|
25603
|
-
|
|
25604
|
-
if (direction == "down") {
|
|
25605
|
-
return "border-left: ".concat(angle, "; border-right: ").concat(angle, "; border-top: ").concat(straight);
|
|
25606
|
-
} else if (direction == "up") {
|
|
25607
|
-
return "border-left: ".concat(angle, "; border-right: ").concat(angle, "; border-bottom: ").concat(straight);
|
|
25608
|
-
} else if (direction == "left") {
|
|
25609
|
-
return "border-top: ".concat(angle, "; border-bottom: ").concat(angle, "; border-right: ").concat(straight);
|
|
25610
|
-
} else if (direction == "right") {
|
|
25611
|
-
return "border-top: ".concat(angle, "; border-bottom: ").concat(angle, "; border-left: ").concat(straight);
|
|
25612
|
-
}
|
|
25613
|
-
};
|
|
25614
|
-
|
|
25615
|
-
var Popover = function Popover(_ref) {
|
|
25616
|
-
var themeValues = _ref.themeValues,
|
|
25617
|
-
_ref$triggerText = _ref.triggerText,
|
|
25618
|
-
triggerText = _ref$triggerText === void 0 ? "" : _ref$triggerText,
|
|
25619
|
-
_ref$content = _ref.content,
|
|
25620
|
-
content = _ref$content === void 0 ? "" : _ref$content,
|
|
25621
|
-
_ref$hasIcon = _ref.hasIcon,
|
|
25622
|
-
hasIcon = _ref$hasIcon === void 0 ? false : _ref$hasIcon,
|
|
25623
|
-
Icon = _ref.icon,
|
|
25624
|
-
_ref$iconHelpText = _ref.iconHelpText,
|
|
25625
|
-
iconHelpText = _ref$iconHelpText === void 0 ? "" : _ref$iconHelpText,
|
|
25626
|
-
_ref$popoverID = _ref.popoverID,
|
|
25627
|
-
popoverID = _ref$popoverID === void 0 ? 0 : _ref$popoverID,
|
|
25628
|
-
_ref$popoverFocus = _ref.popoverFocus,
|
|
25629
|
-
popoverFocus = _ref$popoverFocus === void 0 ? false : _ref$popoverFocus,
|
|
25630
|
-
extraStyles = _ref.extraStyles,
|
|
25631
|
-
textExtraStyles = _ref.textExtraStyles,
|
|
25632
|
-
_ref$minWidth = _ref.minWidth,
|
|
25633
|
-
minWidth = _ref$minWidth === void 0 ? "250px" : _ref$minWidth,
|
|
25634
|
-
_ref$maxWidth = _ref.maxWidth,
|
|
25635
|
-
maxWidth = _ref$maxWidth === void 0 ? "300px" : _ref$maxWidth,
|
|
25636
|
-
_ref$height = _ref.height,
|
|
25637
|
-
height = _ref$height === void 0 ? "auto" : _ref$height,
|
|
25638
|
-
position = _ref.position,
|
|
25639
|
-
arrowPosition = _ref.arrowPosition,
|
|
25640
|
-
_ref$arrowDirection = _ref.arrowDirection,
|
|
25641
|
-
arrowDirection = _ref$arrowDirection === void 0 ? "down" : _ref$arrowDirection,
|
|
25642
|
-
_ref$transform = _ref.transform,
|
|
25643
|
-
transform = _ref$transform === void 0 ? "none" : _ref$transform,
|
|
25644
|
-
buttonExtraStyles = _ref.buttonExtraStyles,
|
|
25645
|
-
_ref$backgroundColor = _ref.backgroundColor,
|
|
25646
|
-
backgroundColor = _ref$backgroundColor === void 0 ? "white" : _ref$backgroundColor,
|
|
25647
|
-
_ref$borderColor = _ref.borderColor,
|
|
25648
|
-
borderColor = _ref$borderColor === void 0 ? "rgba(255, 255, 255, 0.85)" : _ref$borderColor,
|
|
25649
|
-
popoverExtraStyles = _ref.popoverExtraStyles;
|
|
25650
|
-
var hoverColor = themeValues.hoverColor,
|
|
25651
|
-
activeColor = themeValues.activeColor,
|
|
25652
|
-
popoverTriggerColor = themeValues.popoverTriggerColor;
|
|
25653
|
-
|
|
25654
|
-
var _ref2 = position !== null && position !== void 0 ? position : {},
|
|
25655
|
-
_ref2$top = _ref2.top,
|
|
25656
|
-
top = _ref2$top === void 0 ? "-110px" : _ref2$top,
|
|
25657
|
-
_ref2$right = _ref2.right,
|
|
25658
|
-
right = _ref2$right === void 0 ? "auto" : _ref2$right,
|
|
25659
|
-
_ref2$bottom = _ref2.bottom,
|
|
25660
|
-
bottom = _ref2$bottom === void 0 ? "auto" : _ref2$bottom,
|
|
25661
|
-
_ref2$left = _ref2.left,
|
|
25662
|
-
left = _ref2$left === void 0 ? "-225px" : _ref2$left;
|
|
25663
|
-
|
|
25664
|
-
var _ref3 = arrowPosition !== null && arrowPosition !== void 0 ? arrowPosition : {},
|
|
25665
|
-
_ref3$arrowTop = _ref3.arrowTop,
|
|
25666
|
-
arrowTop = _ref3$arrowTop === void 0 ? "auto" : _ref3$arrowTop,
|
|
25667
|
-
_ref3$arrowRight = _ref3.arrowRight,
|
|
25668
|
-
arrowRight = _ref3$arrowRight === void 0 ? "10px" : _ref3$arrowRight,
|
|
25669
|
-
_ref3$arrowBottom = _ref3.arrowBottom,
|
|
25670
|
-
arrowBottom = _ref3$arrowBottom === void 0 ? "-8px" : _ref3$arrowBottom,
|
|
25671
|
-
_ref3$arrowLeft = _ref3.arrowLeft,
|
|
25672
|
-
arrowLeft = _ref3$arrowLeft === void 0 ? "auto" : _ref3$arrowLeft;
|
|
25673
|
-
|
|
25674
|
-
var _useState = useState(false),
|
|
25675
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
25676
|
-
popoverOpen = _useState2[0],
|
|
25677
|
-
togglePopover = _useState2[1];
|
|
25678
|
-
|
|
25679
|
-
var handleTogglePopover = function handleTogglePopover(popoverState) {
|
|
25680
|
-
if (popoverOpen !== popoverState) {
|
|
25681
|
-
togglePopover(popoverState);
|
|
25682
|
-
}
|
|
25683
|
-
};
|
|
25684
|
-
|
|
25685
|
-
var triggerRef = useOutsideClickHook();
|
|
25686
|
-
return /*#__PURE__*/React.createElement(Box, {
|
|
25687
|
-
padding: "0",
|
|
25688
|
-
extraStyles: "position: relative; ".concat(extraStyles)
|
|
25689
|
-
}, /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
25690
|
-
action: function action() {
|
|
25691
|
-
return noop;
|
|
25692
|
-
},
|
|
25693
|
-
onFocus: function onFocus() {
|
|
25694
|
-
handleTogglePopover(true);
|
|
25695
|
-
},
|
|
25696
|
-
onBlur: function onBlur() {
|
|
25697
|
-
handleTogglePopover(false);
|
|
25698
|
-
},
|
|
25699
|
-
onKeyDown: function onKeyDown(e) {
|
|
25700
|
-
if (e.keyCode === 27) {
|
|
25701
|
-
handleTogglePopover(false);
|
|
25702
|
-
}
|
|
25703
|
-
},
|
|
25704
|
-
onTouchStart: function onTouchStart() {
|
|
25705
|
-
return handleTogglePopover(true);
|
|
25706
|
-
},
|
|
25707
|
-
onTouchEnd: function onTouchEnd() {
|
|
25708
|
-
return handleTogglePopover(false);
|
|
25709
|
-
},
|
|
25710
|
-
onMouseEnter: function onMouseEnter() {
|
|
25711
|
-
return handleTogglePopover(true);
|
|
25712
|
-
},
|
|
25713
|
-
onMouseLeave: function onMouseLeave() {
|
|
25714
|
-
return handleTogglePopover(false);
|
|
25715
|
-
},
|
|
25716
|
-
contentOverride: true,
|
|
25717
|
-
variant: "smallGhost",
|
|
25718
|
-
tabIndex: "0",
|
|
25719
|
-
id: "btnPopover".concat(popoverID),
|
|
25720
|
-
"aria-expanded": popoverOpen,
|
|
25721
|
-
"aria-labelledby": "btnPopover".concat(popoverID, "_info Disclosure").concat(popoverID),
|
|
25722
|
-
"aria-describedby": "Disclosure".concat(popoverID),
|
|
25723
|
-
"aria-controls": "Disclosed".concat(popoverID),
|
|
25724
|
-
ref: triggerRef,
|
|
25725
|
-
extraStyles: buttonExtraStyles
|
|
25726
|
-
}, hasIcon && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Icon, null), /*#__PURE__*/React.createElement(Box, {
|
|
25727
|
-
padding: "0",
|
|
25728
|
-
srOnly: true
|
|
25729
|
-
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
25730
|
-
id: "btnPopover".concat(popoverID, "_info")
|
|
25731
|
-
}, iconHelpText))), !hasIcon && /*#__PURE__*/React.createElement(Text$1, {
|
|
25732
|
-
color: popoverTriggerColor,
|
|
25733
|
-
extraStyles: "&:active { color: ".concat(activeColor, "; } &:hover { color: ").concat(hoverColor, " }; ").concat(textExtraStyles)
|
|
25734
|
-
}, triggerText)), /*#__PURE__*/React.createElement(Box, {
|
|
25735
|
-
background: backgroundColor,
|
|
25736
|
-
borderRadius: "4px",
|
|
25737
|
-
boxShadow: "0px 2px 14px 0px rgb(246, 246, 249), 0px 3px 8px 0px rgb(202, 206, 216)",
|
|
25738
|
-
id: "Disclosed".concat(popoverID),
|
|
25739
|
-
role: "region",
|
|
25740
|
-
"aria-describedby": "Disclosure".concat(popoverID),
|
|
25741
|
-
tabIndex: popoverFocus && popoverOpen ? "0" : "-1",
|
|
25742
|
-
minWidth: minWidth,
|
|
25743
|
-
maxWidth: maxWidth,
|
|
25744
|
-
extraStyles: "\n display: ".concat(popoverOpen ? "block" : "none", "; \n position: absolute; \n top: ").concat(top, "; \n right: ").concat(right, "; \n bottom: ").concat(bottom, "; \n left: ").concat(left, ";\n height: ").concat(height, ";\n transform: ").concat(transform, ";\n ").concat(popoverExtraStyles, ";\n ")
|
|
25745
|
-
}, /*#__PURE__*/React.createElement(Paragraph$1, null, content), /*#__PURE__*/React.createElement(Box, {
|
|
25746
|
-
padding: "0",
|
|
25747
|
-
extraStyles: "\n position: absolute;\n content: \"\";\n width: 0;\n height: 0;\n ".concat(arrowBorder(borderColor, arrowDirection, "8px"), ";\n filter: drop-shadow(2px 8px 14px black);\n bottom: ").concat(arrowBottom, ";\n right: ").concat(arrowRight, ";\n top: ").concat(arrowTop, ";\n left: ").concat(arrowLeft, ";\n ")
|
|
25748
|
-
})));
|
|
25749
|
-
};
|
|
25750
|
-
|
|
25751
|
-
var Popover$1 = themeComponent(Popover, "Popover", fallbackValues$j);
|
|
25752
|
-
|
|
25753
|
-
var DisplayCard = function DisplayCard(_ref) {
|
|
25754
|
-
var title = _ref.title,
|
|
25755
|
-
item = _ref.item,
|
|
25756
|
-
buttonText = _ref.buttonText,
|
|
25757
|
-
buttonAction = _ref.buttonAction,
|
|
25758
|
-
url = _ref.url,
|
|
25759
|
-
_ref$link = _ref.link,
|
|
25760
|
-
link = _ref$link === void 0 ? false : _ref$link,
|
|
25761
|
-
helpText = _ref.helpText,
|
|
25762
|
-
_ref$hasPopover = _ref.hasPopover,
|
|
25763
|
-
hasPopover = _ref$hasPopover === void 0 ? false : _ref$hasPopover,
|
|
25764
|
-
_ref$popoverTriggerTe = _ref.popoverTriggerText,
|
|
25765
|
-
popoverTriggerText = _ref$popoverTriggerTe === void 0 ? "" : _ref$popoverTriggerTe,
|
|
25766
|
-
_ref$popoverContent = _ref.popoverContent,
|
|
25767
|
-
popoverContent = _ref$popoverContent === void 0 ? "" : _ref$popoverContent,
|
|
25768
|
-
popoverExtraStyles = _ref.popoverExtraStyles,
|
|
25769
|
-
popoverTextExtraStyles = _ref.popoverTextExtraStyles;
|
|
25770
|
-
return /*#__PURE__*/React.createElement(Box, {
|
|
25771
|
-
padding: "0 0 16px"
|
|
25772
|
-
}, /*#__PURE__*/React.createElement(Stack, {
|
|
25773
|
-
childGap: "0rem"
|
|
25774
|
-
}, /*#__PURE__*/React.createElement(Box, {
|
|
25775
|
-
padding: "0 0 8px 0"
|
|
25776
|
-
}, /*#__PURE__*/React.createElement(Cluster, {
|
|
25777
|
-
justify: "space-between",
|
|
25778
|
-
align: "center",
|
|
25779
|
-
overflow: true
|
|
25780
|
-
}, /*#__PURE__*/React.createElement(Paragraph$1, {
|
|
25781
|
-
variant: "pL",
|
|
25782
|
-
color: CHARADE_GREY,
|
|
25783
|
-
extraStyles: "letter-spacing: 0.29px"
|
|
25784
|
-
}, title), hasPopover && /*#__PURE__*/React.createElement(Popover$1, {
|
|
25785
|
-
triggerText: popoverTriggerText,
|
|
25786
|
-
content: popoverContent,
|
|
25787
|
-
popoverExtraStyles: popoverExtraStyles,
|
|
25788
|
-
popoverTextExtraStyles: popoverTextExtraStyles
|
|
25789
|
-
}))), /*#__PURE__*/React.createElement(Box, {
|
|
25790
|
-
padding: "0"
|
|
25791
|
-
}, /*#__PURE__*/React.createElement(Box, {
|
|
25792
|
-
padding: "24px",
|
|
25793
|
-
borderSize: "1px",
|
|
25794
|
-
borderRadius: "4px",
|
|
25795
|
-
background: WHITE,
|
|
25796
|
-
boxShadow: "0px 2px 14px 0px rgb(246, 246, 249), 0px 3px 8px 0px rgb(202, 206, 216)"
|
|
25797
|
-
}, /*#__PURE__*/React.createElement(Cluster, {
|
|
25798
|
-
justify: "space-between",
|
|
25799
|
-
align: "center"
|
|
25800
|
-
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
25801
|
-
color: CHARADE_GREY
|
|
25802
|
-
}, item), link ? /*#__PURE__*/React.createElement(ButtonWithLink, {
|
|
25803
|
-
text: buttonText,
|
|
25804
|
-
url: url,
|
|
25805
|
-
variant: "smallGhost",
|
|
25806
|
-
dataQa: buttonText,
|
|
25807
|
-
extraStyles: "min-width: 0;"
|
|
25808
|
-
}) : buttonAction ? /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
25809
|
-
text: buttonText,
|
|
25810
|
-
action: buttonAction,
|
|
25811
|
-
variant: "smallGhost",
|
|
25812
|
-
dataQa: buttonText,
|
|
25813
|
-
extraStyles: "min-width: 0;"
|
|
25814
|
-
}) : helpText ? /*#__PURE__*/React.createElement(Text$1, {
|
|
25815
|
-
color: STORM_GREY,
|
|
25816
|
-
extraStyles: "font-style: italic;"
|
|
25817
|
-
}, helpText) : /*#__PURE__*/React.createElement(Fragment$1, null))))));
|
|
25818
|
-
};
|
|
25819
|
-
|
|
25820
25960
|
var linkColor$2 = {
|
|
25821
25961
|
"default": "".concat(MATISSE_BLUE),
|
|
25822
25962
|
disabled: "".concat(MATISSE_BLUE)
|
|
@@ -25882,7 +26022,7 @@ var fallbackValues$k = {
|
|
|
25882
26022
|
};
|
|
25883
26023
|
|
|
25884
26024
|
var _excluded$p = ["showErrors", "themeValues"],
|
|
25885
|
-
_excluded2 = ["type", "labelTextWhenNoError", "errorMessages", "isNum", "isEmail", "helperModal", "field", "fieldActions", "showErrors", "formatter", "decorator", "themeValues", "background", "customHeight", "autocompleteValue", "extraStyles", "removeFromValue", "dataQa"];
|
|
26025
|
+
_excluded2 = ["type", "labelTextWhenNoError", "errorMessages", "isNum", "isEmail", "helperModal", "field", "fieldActions", "showErrors", "formatter", "decorator", "themeValues", "background", "customHeight", "autocompleteValue", "extraStyles", "removeFromValue", "dataQa", "isRequired"];
|
|
25886
26026
|
var InputField = styled.input.withConfig({
|
|
25887
26027
|
displayName: "FormInput__InputField",
|
|
25888
26028
|
componentId: "sc-l094r1-0"
|
|
@@ -25969,6 +26109,8 @@ var FormInput = function FormInput(_ref15) {
|
|
|
25969
26109
|
removeFromValue = _ref15.removeFromValue,
|
|
25970
26110
|
_ref15$dataQa = _ref15.dataQa,
|
|
25971
26111
|
dataQa = _ref15$dataQa === void 0 ? null : _ref15$dataQa,
|
|
26112
|
+
_ref15$isRequired = _ref15.isRequired,
|
|
26113
|
+
isRequired = _ref15$isRequired === void 0 ? false : _ref15$isRequired,
|
|
25972
26114
|
props = _objectWithoutProperties(_ref15, _excluded2);
|
|
25973
26115
|
|
|
25974
26116
|
var _useState = useState(false),
|
|
@@ -26055,7 +26197,8 @@ var FormInput = function FormInput(_ref15) {
|
|
|
26055
26197
|
$customHeight: customHeight,
|
|
26056
26198
|
$extraStyles: extraStyles,
|
|
26057
26199
|
"data-qa": dataQa || labelTextWhenNoError,
|
|
26058
|
-
autoComplete: autocompleteValue
|
|
26200
|
+
autoComplete: autocompleteValue,
|
|
26201
|
+
required: isRequired
|
|
26059
26202
|
}, props)) : /*#__PURE__*/React.createElement(InputField, _extends({
|
|
26060
26203
|
"aria-labelledby": createIdFromString(labelTextWhenNoError),
|
|
26061
26204
|
"aria-describedby": createIdFromString(labelTextWhenNoError, "error message"),
|
|
@@ -26074,7 +26217,8 @@ var FormInput = function FormInput(_ref15) {
|
|
|
26074
26217
|
$customHeight: customHeight,
|
|
26075
26218
|
$extraStyles: extraStyles,
|
|
26076
26219
|
"data-qa": dataQa || labelTextWhenNoError,
|
|
26077
|
-
autoComplete: autocompleteValue
|
|
26220
|
+
autoComplete: autocompleteValue,
|
|
26221
|
+
required: isRequired
|
|
26078
26222
|
}, props))), /*#__PURE__*/React.createElement(Stack, {
|
|
26079
26223
|
direction: "row",
|
|
26080
26224
|
justify: "space-between",
|
|
@@ -26283,6 +26427,66 @@ var fallbackValues$n = {
|
|
|
26283
26427
|
autopayTextColor: autopayTextColor$1
|
|
26284
26428
|
};
|
|
26285
26429
|
|
|
26430
|
+
var formatDelimiter = "_";
|
|
26431
|
+
var phoneFormats = ["", "_", "__", "(___) ", "(___) _", "(___) __", "(___) ___-", "(___) ___-_", "(___) ___-__", "(___) ___-___", "(___) ___-____"];
|
|
26432
|
+
var zipFormats = ["", "_", "__", "___", "____", "_____", "______", "_____-__", "_____-___", "_____-____"];
|
|
26433
|
+
var creditCardFormats = ["", "_", "__", "___", "____", "____ _", "____ __", "____ ___", "____ ____", "____ ____ _", "____ ____ __", "____ ____ ___", "____ ____ ____", "____ ____ ____ _", "____ ____ ____ __", "____ ____ ____ ___", "____ ____ ____ ____"];
|
|
26434
|
+
var moneyFormats = ["", "$0.0_", "$0.__", "$_.__", "$__.__", "$___.__", "$_,___.__", "$__,___.__", "$___,___.__", "$_,___,___.__", "$__,___,___.__", "$___,___,___.__", "$_,___,___,___.__", "$__,___,___,___.__", "$___,___,___,___.__", "$_,___,___,___,___.__"];
|
|
26435
|
+
var expirationDateFormats = ["", "_", "__/", "__/_", "__/__"];
|
|
26436
|
+
var zipFormat = createFormat(zipFormats, formatDelimiter);
|
|
26437
|
+
var creditCardFormat = createFormat(creditCardFormats, formatDelimiter);
|
|
26438
|
+
var expirationDateFormat = createFormat(expirationDateFormats, formatDelimiter);
|
|
26439
|
+
var phoneFormat = createFormat(phoneFormats, formatDelimiter);
|
|
26440
|
+
var moneyFormat = createFormat(moneyFormats, formatDelimiter);
|
|
26441
|
+
var renderCardStatus = function renderCardStatus(expirationStatus, expireDate) {
|
|
26442
|
+
var textAlign = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : "right";
|
|
26443
|
+
var as = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "span";
|
|
26444
|
+
var ACTIVE = "ACTIVE";
|
|
26445
|
+
var EXPIRING_SOON = "EXPIRING_SOON";
|
|
26446
|
+
var EXPIRED = "EXPIRED";
|
|
26447
|
+
var textMargin = textAlign === "right" ? "auto" : "0";
|
|
26448
|
+
|
|
26449
|
+
switch (expirationStatus) {
|
|
26450
|
+
case ACTIVE:
|
|
26451
|
+
return /*#__PURE__*/React.createElement(Text$1, {
|
|
26452
|
+
as: as,
|
|
26453
|
+
variant: "pXS",
|
|
26454
|
+
color: ASH_GREY,
|
|
26455
|
+
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
26456
|
+
}, "Exp Date ", expireDate);
|
|
26457
|
+
|
|
26458
|
+
case EXPIRING_SOON:
|
|
26459
|
+
return /*#__PURE__*/React.createElement(Text$1, {
|
|
26460
|
+
as: as,
|
|
26461
|
+
variant: "pXS",
|
|
26462
|
+
color: FIRE_YELLOW,
|
|
26463
|
+
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
26464
|
+
}, "Expiring Soon ", expireDate);
|
|
26465
|
+
|
|
26466
|
+
case EXPIRED:
|
|
26467
|
+
return /*#__PURE__*/React.createElement(Text$1, {
|
|
26468
|
+
as: as,
|
|
26469
|
+
variant: "pXS",
|
|
26470
|
+
color: ASH_GREY,
|
|
26471
|
+
extraStyles: "text-align: ".concat(textAlign, "; margin: ").concat(textMargin, ";")
|
|
26472
|
+
}, "Expired");
|
|
26473
|
+
}
|
|
26474
|
+
};
|
|
26475
|
+
|
|
26476
|
+
var formats = /*#__PURE__*/Object.freeze({
|
|
26477
|
+
__proto__: null,
|
|
26478
|
+
formatDelimiter: formatDelimiter,
|
|
26479
|
+
phoneFormats: phoneFormats,
|
|
26480
|
+
moneyFormats: moneyFormats,
|
|
26481
|
+
expirationDateFormats: expirationDateFormats,
|
|
26482
|
+
zipFormat: zipFormat,
|
|
26483
|
+
creditCardFormat: creditCardFormat,
|
|
26484
|
+
expirationDateFormat: expirationDateFormat,
|
|
26485
|
+
phoneFormat: phoneFormat,
|
|
26486
|
+
moneyFormat: moneyFormat,
|
|
26487
|
+
renderCardStatus: renderCardStatus
|
|
26488
|
+
});
|
|
26489
|
+
|
|
26286
26490
|
var CreditCardWrapper = styled.div.withConfig({
|
|
26287
26491
|
displayName: "FormattedCreditCard__CreditCardWrapper",
|
|
26288
26492
|
componentId: "sc-s0ta5l-0"
|
|
@@ -27256,7 +27460,9 @@ var RadioButton$1 = function RadioButton(_ref2) {
|
|
|
27256
27460
|
_ref2$ariaLabelledBy = _ref2.ariaLabelledBy,
|
|
27257
27461
|
ariaLabelledBy = _ref2$ariaLabelledBy === void 0 ? "" : _ref2$ariaLabelledBy,
|
|
27258
27462
|
_ref2$ariaLabel = _ref2.ariaLabel,
|
|
27259
|
-
ariaLabel = _ref2$ariaLabel === void 0 ? null : _ref2$ariaLabel
|
|
27463
|
+
ariaLabel = _ref2$ariaLabel === void 0 ? null : _ref2$ariaLabel,
|
|
27464
|
+
_ref2$isRequired = _ref2.isRequired,
|
|
27465
|
+
isRequired = _ref2$isRequired === void 0 ? false : _ref2$isRequired;
|
|
27260
27466
|
var buttonBorder = {
|
|
27261
27467
|
onFocused: {
|
|
27262
27468
|
borderColor: themeValues.activeColor,
|
|
@@ -27318,7 +27524,8 @@ var RadioButton$1 = function RadioButton(_ref2) {
|
|
|
27318
27524
|
disabled: disabled,
|
|
27319
27525
|
onClick: toggleRadio,
|
|
27320
27526
|
"aria-describedby": ariaDescribedBy,
|
|
27321
|
-
tabIndex: "-1"
|
|
27527
|
+
tabIndex: "-1",
|
|
27528
|
+
required: isRequired
|
|
27322
27529
|
}, extraProps)), /*#__PURE__*/React.createElement(Motion, {
|
|
27323
27530
|
borderWidth: "1px",
|
|
27324
27531
|
borderStyle: "solid",
|
|
@@ -38008,7 +38215,9 @@ var FormStateDropdown = function FormStateDropdown(_ref) {
|
|
|
38008
38215
|
field = _ref.field,
|
|
38009
38216
|
fieldActions = _ref.fieldActions,
|
|
38010
38217
|
showErrors = _ref.showErrors,
|
|
38011
|
-
countryCode = _ref.countryCode
|
|
38218
|
+
countryCode = _ref.countryCode,
|
|
38219
|
+
_ref$isRequired = _ref.isRequired,
|
|
38220
|
+
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
38012
38221
|
var placeholder = countryCode === "US" ? placeHolderOptionUS : placeHolderOption;
|
|
38013
38222
|
var options = [placeholder].concat(_toConsumableArray(getOptions(countryCode)));
|
|
38014
38223
|
return /*#__PURE__*/React.createElement(FormSelect$1, {
|
|
@@ -38018,7 +38227,8 @@ var FormStateDropdown = function FormStateDropdown(_ref) {
|
|
|
38018
38227
|
labelTextWhenNoError: labelTextWhenNoError,
|
|
38019
38228
|
errorMessages: errorMessages,
|
|
38020
38229
|
showErrors: showErrors,
|
|
38021
|
-
autocompleteValue: "address-level1"
|
|
38230
|
+
autocompleteValue: "address-level1",
|
|
38231
|
+
isRequired: isRequired
|
|
38022
38232
|
});
|
|
38023
38233
|
};
|
|
38024
38234
|
|
|
@@ -39357,7 +39567,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39357
39567
|
}
|
|
39358
39568
|
},
|
|
39359
39569
|
showErrors: showErrors,
|
|
39360
|
-
dataQa: "Country"
|
|
39570
|
+
dataQa: "Country",
|
|
39571
|
+
isRequired: true
|
|
39361
39572
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
39362
39573
|
labelTextWhenNoError: "Address",
|
|
39363
39574
|
errorMessages: street1ErrorMessages,
|
|
@@ -39368,7 +39579,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39368
39579
|
return e.key === "Enter" && handleSubmit(e);
|
|
39369
39580
|
},
|
|
39370
39581
|
autocompleteValue: "address-line1",
|
|
39371
|
-
dataQa: "Address"
|
|
39582
|
+
dataQa: "Address",
|
|
39583
|
+
isRequired: true
|
|
39372
39584
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
39373
39585
|
labelTextWhenNoError: "Apt, Suite, Unit, Floor, etc. (Optional)",
|
|
39374
39586
|
field: fields.street2,
|
|
@@ -39389,7 +39601,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39389
39601
|
return e.key === "Enter" && handleSubmit(e);
|
|
39390
39602
|
},
|
|
39391
39603
|
autocompleteValue: "address-level2",
|
|
39392
|
-
dataQa: "City"
|
|
39604
|
+
dataQa: "City",
|
|
39605
|
+
isRequired: true
|
|
39393
39606
|
}), /*#__PURE__*/React.createElement(FormStateDropdown, {
|
|
39394
39607
|
labelTextWhenNoError: isUS ? "State" : "State or Province",
|
|
39395
39608
|
errorMessages: stateProvinceErrorMessages,
|
|
@@ -39400,7 +39613,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39400
39613
|
onKeyDown: function onKeyDown(e) {
|
|
39401
39614
|
return e.key === "Enter" && handleSubmit(e);
|
|
39402
39615
|
},
|
|
39403
|
-
dataQa: "State or Province"
|
|
39616
|
+
dataQa: "State or Province",
|
|
39617
|
+
isRequired: true
|
|
39404
39618
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
39405
39619
|
isNum: isUS,
|
|
39406
39620
|
formatter: isUS ? zipFormat : null,
|
|
@@ -39413,7 +39627,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
39413
39627
|
return e.key === "Enter" && handleSubmit(e);
|
|
39414
39628
|
},
|
|
39415
39629
|
autocompleteValue: "postal-code",
|
|
39416
|
-
dataQa: "Zip code"
|
|
39630
|
+
dataQa: "Zip code",
|
|
39631
|
+
isRequired: true
|
|
39417
39632
|
}), showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
39418
39633
|
name: "address checkbox",
|
|
39419
39634
|
title: "Save address to wallet",
|
|
@@ -40316,7 +40531,9 @@ var EmailForm = function EmailForm(_ref) {
|
|
|
40316
40531
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
|
|
40317
40532
|
showWalletCheckbox = _ref.showWalletCheckbox,
|
|
40318
40533
|
saveToWallet = _ref.saveToWallet,
|
|
40319
|
-
walletCheckboxMarked = _ref.walletCheckboxMarked
|
|
40534
|
+
walletCheckboxMarked = _ref.walletCheckboxMarked,
|
|
40535
|
+
_ref$isRequired = _ref.isRequired,
|
|
40536
|
+
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
40320
40537
|
|
|
40321
40538
|
if (clearOnDismount) {
|
|
40322
40539
|
useEffect$1(function () {
|
|
@@ -40345,7 +40562,8 @@ var EmailForm = function EmailForm(_ref) {
|
|
|
40345
40562
|
},
|
|
40346
40563
|
isEmail: true,
|
|
40347
40564
|
autocompleteValue: "email",
|
|
40348
|
-
dataQa: "Email address"
|
|
40565
|
+
dataQa: "Email address",
|
|
40566
|
+
isRequired: isRequired
|
|
40349
40567
|
}), showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
40350
40568
|
name: "email checkbox",
|
|
40351
40569
|
title: "Save email address to wallet",
|
|
@@ -45642,7 +45860,8 @@ var Modal$1 = function Modal(_ref) {
|
|
|
45642
45860
|
alignItems: "center"
|
|
45643
45861
|
},
|
|
45644
45862
|
dialogStyle: {
|
|
45645
|
-
width: customWidth || "615px"
|
|
45863
|
+
width: customWidth || "615px",
|
|
45864
|
+
overflow: "auto"
|
|
45646
45865
|
},
|
|
45647
45866
|
underlayClickExits: underlayClickExits
|
|
45648
45867
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
@@ -47712,42 +47931,7 @@ var TermsAndConditionsControlV1 = function TermsAndConditionsControlV1(_ref) {
|
|
|
47712
47931
|
})))));
|
|
47713
47932
|
};
|
|
47714
47933
|
|
|
47715
|
-
|
|
47716
|
-
Hook that takes an ID selector for an element on the screen
|
|
47717
|
-
And optionally values for top position, left position, smooth behavior
|
|
47718
|
-
Finds element on screen and scrolls it to the provided coordinates
|
|
47719
|
-
|
|
47720
|
-
(string, number, number, string, number) => undefined;
|
|
47721
|
-
*/
|
|
47722
|
-
var useScrollTo = function useScrollTo(id) {
|
|
47723
|
-
var top = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
47724
|
-
var left = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
|
47725
|
-
var behavior = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : "auto";
|
|
47726
|
-
var delay = arguments.length > 4 ? arguments[4] : undefined;
|
|
47727
|
-
var scrollItem;
|
|
47728
|
-
|
|
47729
|
-
if (delay) {
|
|
47730
|
-
setTimeout(function () {
|
|
47731
|
-
var _scrollItem;
|
|
47732
|
-
|
|
47733
|
-
scrollItem = document.getElementById(id);
|
|
47734
|
-
(_scrollItem = scrollItem) === null || _scrollItem === void 0 ? void 0 : _scrollItem.scrollTo({
|
|
47735
|
-
top: top,
|
|
47736
|
-
left: left,
|
|
47737
|
-
behavior: behavior
|
|
47738
|
-
});
|
|
47739
|
-
}, delay);
|
|
47740
|
-
} else {
|
|
47741
|
-
var _scrollItem2;
|
|
47742
|
-
|
|
47743
|
-
scrollItem = document.getElementById(id);
|
|
47744
|
-
(_scrollItem2 = scrollItem) === null || _scrollItem2 === void 0 ? void 0 : _scrollItem2.scrollTo({
|
|
47745
|
-
top: top,
|
|
47746
|
-
left: left,
|
|
47747
|
-
behavior: behavior
|
|
47748
|
-
});
|
|
47749
|
-
}
|
|
47750
|
-
};
|
|
47934
|
+
var TermsAndConditionsTitleDivId = "terms-and-conditions-title";
|
|
47751
47935
|
|
|
47752
47936
|
var TermsAndConditionsControlV2 = function TermsAndConditionsControlV2(_ref) {
|
|
47753
47937
|
var _ref$showCheckbox = _ref.showCheckbox,
|
|
@@ -47811,7 +47995,8 @@ var TermsAndConditionsControlV2 = function TermsAndConditionsControlV2(_ref) {
|
|
|
47811
47995
|
checked: isChecked,
|
|
47812
47996
|
onChange: onCheck,
|
|
47813
47997
|
checkboxMargin: checkboxMargin,
|
|
47814
|
-
extraStyles: "align-self: flex-start;"
|
|
47998
|
+
extraStyles: "align-self: flex-start;",
|
|
47999
|
+
labelledById: TermsAndConditionsTitleDivId
|
|
47815
48000
|
}), /*#__PURE__*/React.createElement(Stack, {
|
|
47816
48001
|
childGap: "0.25rem",
|
|
47817
48002
|
fullHeight: true
|
|
@@ -47819,7 +48004,8 @@ var TermsAndConditionsControlV2 = function TermsAndConditionsControlV2(_ref) {
|
|
|
47819
48004
|
justify: "flex-start",
|
|
47820
48005
|
align: "center",
|
|
47821
48006
|
nowrap: true,
|
|
47822
|
-
extraStyles: "padding-right: 2px; > div > * { margin: 4px 2px; };"
|
|
48007
|
+
extraStyles: "padding-right: 2px; > div > * { margin: 4px 2px; };",
|
|
48008
|
+
id: TermsAndConditionsTitleDivId
|
|
47823
48009
|
}, description && /*#__PURE__*/React.createElement(Text$1, {
|
|
47824
48010
|
color: CHARADE_GREY
|
|
47825
48011
|
}, description), terms && /*#__PURE__*/React.createElement(TermsAndConditionsModal$1, {
|
|
@@ -47917,7 +48103,8 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47917
48103
|
onKeyDown: function onKeyDown(e) {
|
|
47918
48104
|
return e.key === "Enter" && handleSubmit(e);
|
|
47919
48105
|
},
|
|
47920
|
-
autocompleteValue: "name"
|
|
48106
|
+
autocompleteValue: "name",
|
|
48107
|
+
isRequired: true
|
|
47921
48108
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
47922
48109
|
labelTextWhenNoError: "Routing number",
|
|
47923
48110
|
dataQa: "Routing number",
|
|
@@ -47939,7 +48126,8 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47939
48126
|
},
|
|
47940
48127
|
onKeyDown: function onKeyDown(e) {
|
|
47941
48128
|
return e.key === "Enter" && handleSubmit(e);
|
|
47942
|
-
}
|
|
48129
|
+
},
|
|
48130
|
+
isRequired: true
|
|
47943
48131
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
47944
48132
|
labelTextWhenNoError: "Confirm routing number",
|
|
47945
48133
|
dataQa: "Confirm routing number",
|
|
@@ -47950,7 +48138,8 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47950
48138
|
onKeyDown: function onKeyDown(e) {
|
|
47951
48139
|
return e.key === "Enter" && handleSubmit(e);
|
|
47952
48140
|
},
|
|
47953
|
-
isNum: true
|
|
48141
|
+
isNum: true,
|
|
48142
|
+
isRequired: true
|
|
47954
48143
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
47955
48144
|
labelTextWhenNoError: "Account number",
|
|
47956
48145
|
dataQa: "Account number",
|
|
@@ -47972,7 +48161,8 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47972
48161
|
},
|
|
47973
48162
|
onKeyDown: function onKeyDown(e) {
|
|
47974
48163
|
return e.key === "Enter" && handleSubmit(e);
|
|
47975
|
-
}
|
|
48164
|
+
},
|
|
48165
|
+
isRequired: true
|
|
47976
48166
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
47977
48167
|
labelTextWhenNoError: "Confirm account number",
|
|
47978
48168
|
dataQa: "Confirm account number",
|
|
@@ -47983,6 +48173,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
47983
48173
|
onKeyDown: function onKeyDown(e) {
|
|
47984
48174
|
return e.key === "Enter" && handleSubmit(e);
|
|
47985
48175
|
},
|
|
48176
|
+
isRequired: true,
|
|
47986
48177
|
isNum: true
|
|
47987
48178
|
}), allowBankAccountType && /*#__PURE__*/React.createElement(FormSelect$1, {
|
|
47988
48179
|
labelTextWhenNoError: "Account type",
|
|
@@ -48000,7 +48191,8 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48000
48191
|
fieldActions: actions.fields.accountType,
|
|
48001
48192
|
showErrors: showErrors,
|
|
48002
48193
|
errorMessages: accountTypeErrors,
|
|
48003
|
-
field: fields.accountType
|
|
48194
|
+
field: fields.accountType,
|
|
48195
|
+
isRequired: true
|
|
48004
48196
|
}), !hideDefaultPayment && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
48005
48197
|
title: "Save as Default Payment Method",
|
|
48006
48198
|
dataQa: "default-payment-ach",
|
|
@@ -48138,7 +48330,8 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48138
48330
|
onKeyDown: function onKeyDown(e) {
|
|
48139
48331
|
return e.key === "Enter" && handleSubmit(e);
|
|
48140
48332
|
},
|
|
48141
|
-
autocompleteValue: "cc-name"
|
|
48333
|
+
autocompleteValue: "cc-name",
|
|
48334
|
+
isRequired: true
|
|
48142
48335
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48143
48336
|
labelTextWhenNoError: "Credit card number",
|
|
48144
48337
|
dataQa: "Credit card number",
|
|
@@ -48151,7 +48344,8 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48151
48344
|
return e.key === "Enter" && handleSubmit(e);
|
|
48152
48345
|
},
|
|
48153
48346
|
isNum: true,
|
|
48154
|
-
autocompleteValue: "cc-number"
|
|
48347
|
+
autocompleteValue: "cc-number",
|
|
48348
|
+
isRequired: true
|
|
48155
48349
|
}), /*#__PURE__*/React.createElement(FormInputRow, {
|
|
48156
48350
|
breakpoint: isMobile ? "1000rem" : "21rem",
|
|
48157
48351
|
childGap: isMobile ? "0rem" : "1rem"
|
|
@@ -48169,7 +48363,8 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48169
48363
|
isNum: true,
|
|
48170
48364
|
removeFromValue: /\// // removes "/" from browser autofill
|
|
48171
48365
|
,
|
|
48172
|
-
autocompleteValue: "cc-exp"
|
|
48366
|
+
autocompleteValue: "cc-exp",
|
|
48367
|
+
isRequired: true
|
|
48173
48368
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48174
48369
|
labelTextWhenNoError: "CVV",
|
|
48175
48370
|
dataQa: "CVV",
|
|
@@ -48182,7 +48377,8 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48182
48377
|
onKeyDown: function onKeyDown(e) {
|
|
48183
48378
|
return e.key === "Enter" && handleSubmit(e);
|
|
48184
48379
|
},
|
|
48185
|
-
autocompleteValue: "cc-csc"
|
|
48380
|
+
autocompleteValue: "cc-csc",
|
|
48381
|
+
isRequired: true
|
|
48186
48382
|
})), !hideZipCode && /*#__PURE__*/React.createElement(Box, {
|
|
48187
48383
|
padding: isMobile ? "0" : "0 0.5rem 0 0",
|
|
48188
48384
|
width: isMobile ? "100%" : "50%"
|
|
@@ -48198,7 +48394,8 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
48198
48394
|
onKeyDown: function onKeyDown(e) {
|
|
48199
48395
|
return e.key === "Enter" && handleSubmit(e);
|
|
48200
48396
|
},
|
|
48201
|
-
autocompleteValue: "billing postal-code"
|
|
48397
|
+
autocompleteValue: "billing postal-code",
|
|
48398
|
+
isRequired: true
|
|
48202
48399
|
})), (showWalletCheckbox || showTerms) && /*#__PURE__*/React.createElement(Cluster, {
|
|
48203
48400
|
childGap: "4px",
|
|
48204
48401
|
align: "center"
|
|
@@ -48391,7 +48588,9 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48391
48588
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
|
|
48392
48589
|
showWalletCheckbox = _ref.showWalletCheckbox,
|
|
48393
48590
|
saveToWallet = _ref.saveToWallet,
|
|
48394
|
-
walletCheckboxMarked = _ref.walletCheckboxMarked
|
|
48591
|
+
walletCheckboxMarked = _ref.walletCheckboxMarked,
|
|
48592
|
+
_ref$isRequired = _ref.isRequired,
|
|
48593
|
+
isRequired = _ref$isRequired === void 0 ? false : _ref$isRequired;
|
|
48395
48594
|
|
|
48396
48595
|
if (clearOnDismount) {
|
|
48397
48596
|
useEffect$1(function () {
|
|
@@ -48418,7 +48617,8 @@ var PhoneForm = function PhoneForm(_ref) {
|
|
|
48418
48617
|
},
|
|
48419
48618
|
autocompleteValue: "tel-national",
|
|
48420
48619
|
dataQa: "Phone number",
|
|
48421
|
-
isNum: true
|
|
48620
|
+
isNum: true,
|
|
48621
|
+
isRequired: isRequired
|
|
48422
48622
|
}), showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
48423
48623
|
name: "phone checkbox",
|
|
48424
48624
|
title: "Save phone number to wallet",
|
|
@@ -48552,8 +48752,8 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48552
48752
|
_ref$containerStyles = _ref.containerStyles,
|
|
48553
48753
|
containerStyles = _ref$containerStyles === void 0 ? "" : _ref$containerStyles,
|
|
48554
48754
|
ariaDescribedBy = _ref.ariaDescribedBy,
|
|
48555
|
-
_ref$
|
|
48556
|
-
|
|
48755
|
+
_ref$isSectionRequire = _ref.isSectionRequired,
|
|
48756
|
+
isSectionRequired = _ref$isSectionRequire === void 0 ? false : _ref$isSectionRequire;
|
|
48557
48757
|
|
|
48558
48758
|
var handleKeyDown = function handleKeyDown(id, e) {
|
|
48559
48759
|
if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13 || (e === null || e === void 0 ? void 0 : e.keyCode) === 32) {
|
|
@@ -48609,8 +48809,8 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48609
48809
|
extraStyles: containerStyles
|
|
48610
48810
|
}, /*#__PURE__*/React.createElement(Stack, {
|
|
48611
48811
|
childGap: "0",
|
|
48612
|
-
role: "radiogroup",
|
|
48613
|
-
"aria-
|
|
48812
|
+
"aria-role": "radiogroup",
|
|
48813
|
+
"aria-required": isSectionRequired
|
|
48614
48814
|
}, sections.filter(function (section) {
|
|
48615
48815
|
return !section.hidden;
|
|
48616
48816
|
}).map(function (section) {
|
|
@@ -48632,7 +48832,8 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48632
48832
|
extraStyles: borderStyles,
|
|
48633
48833
|
role: "radio",
|
|
48634
48834
|
"aria-checked": openSection === section.id,
|
|
48635
|
-
"aria-disabled": section.disabled
|
|
48835
|
+
"aria-disabled": section.disabled,
|
|
48836
|
+
"aria-required": section === null || section === void 0 ? void 0 : section.required
|
|
48636
48837
|
}, /*#__PURE__*/React.createElement(Stack, {
|
|
48637
48838
|
childGap: "0"
|
|
48638
48839
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
@@ -48670,7 +48871,8 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
48670
48871
|
toggleRadio: section.disabled ? noop : function () {
|
|
48671
48872
|
return toggleOpenSection(section.id);
|
|
48672
48873
|
},
|
|
48673
|
-
tabIndex: "-1"
|
|
48874
|
+
tabIndex: "-1",
|
|
48875
|
+
isRequired: section === null || section === void 0 ? void 0 : section.required
|
|
48674
48876
|
})), section.titleIcon && /*#__PURE__*/React.createElement(Cluster, {
|
|
48675
48877
|
align: "center"
|
|
48676
48878
|
}, section.titleIcon), /*#__PURE__*/React.createElement(Box, {
|
|
@@ -49189,6 +49391,51 @@ var Timeout = function Timeout(_ref) {
|
|
|
49189
49391
|
|
|
49190
49392
|
var Timeout$1 = withWindowSize(Timeout);
|
|
49191
49393
|
|
|
49394
|
+
var VARIANTS = {
|
|
49395
|
+
SUCCESS: "success",
|
|
49396
|
+
ERROR: "error"
|
|
49397
|
+
};
|
|
49398
|
+
|
|
49399
|
+
var ToastNotification = function ToastNotification(_ref) {
|
|
49400
|
+
var _ref$variant = _ref.variant,
|
|
49401
|
+
variant = _ref$variant === void 0 ? VARIANTS.SUCCESS : _ref$variant,
|
|
49402
|
+
_ref$message = _ref.message,
|
|
49403
|
+
message = _ref$message === void 0 ? "" : _ref$message,
|
|
49404
|
+
toastOpen = _ref.toastOpen,
|
|
49405
|
+
closeToastNotification = _ref.closeToastNotification,
|
|
49406
|
+
extraStyles = _ref.extraStyles,
|
|
49407
|
+
_ref$minWidth = _ref.minWidth,
|
|
49408
|
+
minWidth = _ref$minWidth === void 0 ? "112px" : _ref$minWidth,
|
|
49409
|
+
_ref$maxWidth = _ref.maxWidth,
|
|
49410
|
+
maxWidth = _ref$maxWidth === void 0 ? "350px" : _ref$maxWidth,
|
|
49411
|
+
_ref$height = _ref.height,
|
|
49412
|
+
height = _ref$height === void 0 ? "56px" : _ref$height,
|
|
49413
|
+
_ref$childGap = _ref.childGap,
|
|
49414
|
+
childGap = _ref$childGap === void 0 ? "1rem" : _ref$childGap,
|
|
49415
|
+
backgroundColor = _ref.backgroundColor;
|
|
49416
|
+
return /*#__PURE__*/React.createElement(Box, {
|
|
49417
|
+
onClick: closeToastNotification,
|
|
49418
|
+
background: backgroundColor ? backgroundColor : variant === VARIANTS.SUCCESS ? HINT_GREEN : variant === VARIANTS.ERROR ? ERROR_BACKGROUND_COLOR : WHITE,
|
|
49419
|
+
minWidth: minWidth,
|
|
49420
|
+
minHeight: height && parseInt(height) < 100 ? height : "100px",
|
|
49421
|
+
height: height ? height : "auto",
|
|
49422
|
+
tabIndex: toastOpen ? "-1" : "0",
|
|
49423
|
+
padding: "0rem 1rem",
|
|
49424
|
+
borderRadius: "4px",
|
|
49425
|
+
boxShadow: generateShadows().standard.base,
|
|
49426
|
+
extraStyles: "\n display: ".concat(toastOpen ? "block" : "none", ";\n position: fixed; bottom: 4rem; left: 4rem;\n ").concat(extraStyles, ";\n cursor: pointer;\n ")
|
|
49427
|
+
}, /*#__PURE__*/React.createElement(Cluster, {
|
|
49428
|
+
align: "center",
|
|
49429
|
+
childGap: childGap
|
|
49430
|
+
}, variant === VARIANTS.SUCCESS && /*#__PURE__*/React.createElement(SuccessfulIconMedium, null), variant === VARIANTS.ERROR && /*#__PURE__*/React.createElement(ErroredIcon, null), /*#__PURE__*/React.createElement(Box, {
|
|
49431
|
+
padding: "1rem 0",
|
|
49432
|
+
maxWidth: maxWidth
|
|
49433
|
+
}, /*#__PURE__*/React.createElement(Paragraph$1, {
|
|
49434
|
+
weight: FONT_WEIGHT_SEMIBOLD,
|
|
49435
|
+
extraStyles: "word-break: break-word;"
|
|
49436
|
+
}, message)), /*#__PURE__*/React.createElement(IconQuitLarge, null)));
|
|
49437
|
+
};
|
|
49438
|
+
|
|
49192
49439
|
var fontWeight$9 = "600";
|
|
49193
49440
|
var fontColor$1 = WHITE;
|
|
49194
49441
|
var textAlign$1 = "left";
|
|
@@ -49561,5 +49808,37 @@ var SidebarStackContent = function SidebarStackContent(_ref) {
|
|
|
49561
49808
|
|
|
49562
49809
|
var SidebarStackContent$1 = withWindowSize(themeComponent(SidebarStackContent, "Global", fallbackValues$U));
|
|
49563
49810
|
|
|
49564
|
-
|
|
49811
|
+
var useFocusInvalidInput = function useFocusInvalidInput(hasErrors) {
|
|
49812
|
+
var resetHasErrors = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : function () {};
|
|
49813
|
+
// Only move focus when "hasErrors" is true
|
|
49814
|
+
// "hasErrors" is managed by container page of form
|
|
49815
|
+
// typically set to "true" on attempted form submission, if errors exist
|
|
49816
|
+
// Reset errors, if provided, resets the error state tracking in order to properly re-run
|
|
49817
|
+
useEffect$1(function () {
|
|
49818
|
+
if (hasErrors) {
|
|
49819
|
+
var _inputsWithErrors$;
|
|
49820
|
+
|
|
49821
|
+
var inputsWithErrors = document.querySelectorAll("input[aria-invalid=true]");
|
|
49822
|
+
inputsWithErrors === null || inputsWithErrors === void 0 ? void 0 : (_inputsWithErrors$ = inputsWithErrors[0]) === null || _inputsWithErrors$ === void 0 ? void 0 : _inputsWithErrors$.focus();
|
|
49823
|
+
}
|
|
49824
|
+
|
|
49825
|
+
return function () {
|
|
49826
|
+
return resetHasErrors(false);
|
|
49827
|
+
};
|
|
49828
|
+
});
|
|
49829
|
+
};
|
|
49830
|
+
|
|
49831
|
+
|
|
49832
|
+
|
|
49833
|
+
var index$6 = /*#__PURE__*/Object.freeze({
|
|
49834
|
+
__proto__: null,
|
|
49835
|
+
formats: formats,
|
|
49836
|
+
general: general,
|
|
49837
|
+
theme: themeUtils,
|
|
49838
|
+
useFocusInvalidInput: useFocusInvalidInput,
|
|
49839
|
+
useOutsideClick: useOutsideClickHook,
|
|
49840
|
+
useToastNotification: useToastNotification
|
|
49841
|
+
});
|
|
49842
|
+
|
|
49843
|
+
export { AccountNumberImage, AccountsAddIcon$1 as AccountsAddIcon, AccountsIcon$1 as AccountsIcon, AccountsIconSmall$1 as AccountsIconSmall, AchReturnIcon, AddObligation$1 as AddObligation, AddressForm, Alert$1 as Alert, AllocatedIcon, AmountCallout$1 as AmountCallout, ArrowDownCircleIconSmall, ArrowLeftCircleIconMedium, ArrowLeftCircleIconSmall, ArrowRightCircleIconSmall, ArrowRightIcon, ArrowUpCircleIconSmall, AutopayIcon, AutopayOnIcon, Badge$1 as Badge, BankIcon, BankIconLarge, Banner$1 as Banner, Box, BoxWithShadow$1 as BoxWithShadow, Breadcrumbs as Breadcrumb, ButtonWithAction, ButtonWithLink, CalendarIcon, Card$1 as Card, CarrotIcon$1 as CarrotIcon, CashIcon, Center, CenterSingle$1 as CenterSingle, CenterStack$1 as CenterStack, ChangePasswordForm, ChargebackIcon, ChargebackIconMedium, ChargebackIconSmall, ChargebackReversalIcon, ChargebackReversalIconMedium, ChargebackReversalIconSmall, CheckIcon, Checkbox$1 as Checkbox, CheckboxList$1 as CheckboxList, CheckmarkIcon, ChevronIcon$1 as ChevronIcon, Cluster, CollapsibleSection$1 as CollapsibleSection, Copyable, CountryDropdown, Cover, CustomerSearchIcon, DefaultPageTemplate, Detail$1 as Detail, DisplayBox$1 as DisplayBox, DisplayCard, Dropdown$1 as Dropdown, DuplicateIcon, EditNameForm, EditableList, EditableTable, EmailForm, EmptyCartIcon$1 as EmptyCartIcon, ErroredIcon, ExternalLink, ExternalLinkIcon, FailedIcon, FindIconSmall$1 as FindIconSmall, FooterWithSubfooter$1 as FooterWithSubfooter, ForgotPasswordForm, ForgotPasswordIcon$1 as ForgotPasswordIcon, FormContainer$1 as FormContainer, FormFooterPanel$1 as FormFooterPanel, FormInput$1 as FormInput, FormInputColumn, FormInputRow, FormSelect$1 as FormSelect, FormattedAddress$1 as FormattedAddress, FormattedBankAccount$1 as FormattedBankAccount, FormattedCreditCard$1 as FormattedCreditCard, Frame, GenericCard, GenericCardLarge, GenericErrorIcon, GoToEmailIcon$1 as GoToEmailIcon, Grid, GuidedCheckoutImage, HamburgerButton, Heading$1 as Heading, HighlightTabRow$1 as HighlightTabRow, HistoryIconSmall$1 as HistoryIconSmall, IconAdd, IconQuitLarge, ImageBox, Imposter, InternalLink, Jumbo$1 as Jumbo, KebabMenuIcon, KioskImage, LabeledAmount$1 as LabeledAmount, LineItem$1 as LineItem, LinkCard$1 as LinkCard, Loading, LoadingLine, LoginForm, Modal$1 as Modal, Module$1 as Module, Motion, NavFooter, NavHeader, NavMenuDesktop$1 as NavMenuDesktop, NavMenuMobile$1 as NavMenuMobile, NavTabs, NoCustomerResultsIcon, NoPaymentResultsIcon, NotFoundIcon, Obligation, iconsMap as ObligationIcons, Pagination$1 as Pagination, Paragraph$1 as Paragraph, PartialAmountForm, PasswordRequirements, PaymentButtonBar, PaymentDetails$1 as PaymentDetails, PaymentFormACH, PaymentFormCard$1 as PaymentFormCard, PaymentMethodAddIcon$1 as PaymentMethodAddIcon, PaymentMethodIcon$1 as PaymentMethodIcon, PaymentSearchIcon, PaymentsIconSmall$1 as PaymentsIconSmall, PencilIcon$1 as PencilIcon, PendingIcon, PeriscopeDashboardIframe, PeriscopeFailedIcon, PhoneForm, Placeholder$1 as Placeholder, PlusCircleIcon, PointOfSaleImage, Popover$1 as Popover, ProcessingFee$1 as ProcessingFee, ProfileIcon$1 as ProfileIcon, ProfileIconSmall$1 as ProfileIconSmall, ProfileImage, PropertiesAddIcon$1 as PropertiesAddIcon, PropertiesIconSmall$1 as PropertiesIconSmall, RadioButton$2 as RadioButton, RadioButtonWithLabel$1 as RadioButtonWithLabel, RadioGroup, RadioSection$1 as RadioSection, Reel, RefundIcon, RefundIconMedium, RefundIconSmall, RegistrationForm, RejectedIcon, RejectedVelocityIcon, ResetConfirmationForm$1 as ResetConfirmationForm, ResetPasswordForm, ResetPasswordIcon, ResetPasswordSuccess, RevenueManagementImage, RoutingNumberImage, SearchIcon, SearchableSelect$1 as SearchableSelect, SettingsIconSmall$1 as SettingsIconSmall, ShoppingCartIcon, Sidebar, SidebarSingleContent$1 as SidebarSingleContent, SidebarStackContent$1 as SidebarStackContent, SolidDivider$1 as SolidDivider, Spinner$2 as Spinner, Stack, StandardCheckoutImage, FormStateDropdown as StateProvinceDropdown, StatusUnknownIcon, SuccessfulIcon, SuccessfulIconMedium, SuccessfulIconSmall, Switcher, TabSidebar$1 as TabSidebar, Table_styled as Table, TableBody_styled as TableBody, TableCell_styled as TableCell, TableHead$1 as TableHead, TableHeading_styled as TableHeading, TableListItem, TableRow$1 as TableRow, Tabs$1 as Tabs, TermsAndConditions, TermsAndConditionsModal$1 as TermsAndConditionsModal, Text$1 as Text, Timeout$1 as Timeout, TimeoutImage, Title$1 as Title, ToastNotification, ToggleSwitch$1 as ToggleSwitch, TrashIcon$1 as TrashIcon, TypeaheadInput, VerifiedEmailIcon$1 as VerifiedEmailIcon, VoidedIcon, WalletBannerIcon$1 as WalletBannerIcon, WalletIcon$1 as WalletIcon, WalletIconSmall$1 as WalletIconSmall, WarningIconXS, WelcomeModule$1 as WelcomeModule, WorkflowTile, XCircleIconMedium, XCircleIconSmall, cardRegistry, index$5 as constants, createPartialAmountFormState, createPartialAmountFormValidators, index$4 as hooks, index$6 as util, withWindowSize };
|
|
49565
49844
|
//# sourceMappingURL=index.esm.js.map
|