@thecb/components 4.0.13 → 4.0.14-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 +17 -29
- package/package.json +1 -1
- package/src/components/atoms/button-with-action/ButtonWithAction.js +1 -0
- package/src/components/atoms/button-with-link/ButtonWithLink.js +2 -1
- package/src/components/molecules/collapsible-section/CollapsibleSection.js +3 -2
- package/src/components/molecules/collapsible-section/CollapsibleSection.theme.js +1 -3
- package/src/components/molecules/payment-form-ach/PaymentFormACH.js +1 -20
- package/src/components/molecules/payment-form-card/PaymentFormCard.js +1 -4
- package/src/components/molecules/reset-confirmation-form/ResetConfirmationForm.js +1 -0
- package/src/components/molecules/reset-password-success/ResetPasswordSuccess.js +1 -0
- package/src/components/molecules/welcome-module/WelcomeModule.js +1 -1
- package/.tool-versions +0 -1
package/dist/index.cjs.js
CHANGED
|
@@ -12633,7 +12633,7 @@ var ButtonWithAction = function ButtonWithAction(_ref) {
|
|
|
12633
12633
|
var themeContext = React.useContext(styled.ThemeContext);
|
|
12634
12634
|
var themeValues = createThemeValues(themeContext, fallbackValues$1, "Button", variant);
|
|
12635
12635
|
var loadingExtraStyles = "".concat(extraStyles, "; padding-top: 0.75rem; padding-bottom: 0.75rem; height: ").concat(themeContext.isMobile ? "50px" : "57px", " ");
|
|
12636
|
-
var hoverStyles = "\n outline: none;\n background-color: ".concat(themeValues.hoverBackgroundColor, ";\n border-color: ").concat(themeValues.hoverBorderColor, ";\n color: ").concat(themeValues.hoverColor, ";\n text-decoration: ").concat(variant === "ghost" || variant === "smallGhost" ? "underline" : "none", ";\n ");
|
|
12636
|
+
var hoverStyles = "\n outline: none;\n background-color: ".concat(themeValues.hoverBackgroundColor, ";\n border-color: ").concat(themeValues.hoverBorderColor, ";\n color: ").concat(themeValues.hoverColor, ";\n text-decoration: ").concat(variant === "ghost" || variant === "smallGhost" ? "underline" : "none", ";\n cursor: pointer;\n ");
|
|
12637
12637
|
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 ");
|
|
12638
12638
|
var disabledStyles = "\n background-clor: #6E727E;\n border-color: #6E727E;\n color: #FFFFFF;\n &:focus {\n box-shadow: 0 0 10px #6E727E;\n outline: none;\n }\n ";
|
|
12639
12639
|
return /*#__PURE__*/React__default.createElement(Box, {
|
|
@@ -16293,9 +16293,10 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
16293
16293
|
_ref$fileLink = _ref.fileLink,
|
|
16294
16294
|
fileLink = _ref$fileLink === void 0 ? false : _ref$fileLink,
|
|
16295
16295
|
extraStyles = _ref.extraStyles,
|
|
16296
|
+
linkExtraStyles = _ref.linkExtraStyles,
|
|
16296
16297
|
_ref$newTab = _ref.newTab,
|
|
16297
16298
|
newTab = _ref$newTab === void 0 ? false : _ref$newTab,
|
|
16298
|
-
otherProps = _objectWithoutProperties(_ref, ["url", "disabled", "fileLink", "extraStyles", "newTab"]);
|
|
16299
|
+
otherProps = _objectWithoutProperties(_ref, ["url", "disabled", "fileLink", "extraStyles", "linkExtraStyles", "newTab"]);
|
|
16299
16300
|
|
|
16300
16301
|
var ButtonWithLinkWrapper = function ButtonWithLinkWrapper(_ref2) {
|
|
16301
16302
|
var children = _ref2.children,
|
|
@@ -16324,7 +16325,7 @@ var ButtonWithLink = function ButtonWithLink(_ref) {
|
|
|
16324
16325
|
url: url,
|
|
16325
16326
|
disabled: disabled,
|
|
16326
16327
|
newTab: newTab,
|
|
16327
|
-
extraStyles: "text-decoration: none; &:hover {\n text-decoration: none; }"
|
|
16328
|
+
extraStyles: "".concat(linkExtraStyles, " text-decoration: none; &:hover {\n text-decoration: none; }")
|
|
16328
16329
|
}, /*#__PURE__*/React__default.createElement(ButtonWithAction, _extends({}, otherProps, {
|
|
16329
16330
|
extraStyles: extraStyles
|
|
16330
16331
|
})));
|
|
@@ -19916,9 +19917,7 @@ var ERRORS = {
|
|
|
19916
19917
|
"71": "Passed invalid pixel value %s to %s(), please pass a value like \"12px\" or 12.\n\n",
|
|
19917
19918
|
"72": "Passed invalid base value %s to %s(), please pass a value like \"12px\" or 12.\n\n",
|
|
19918
19919
|
"73": "Please provide a valid CSS variable.\n\n",
|
|
19919
|
-
"74": "CSS variable not found
|
|
19920
|
-
"75": "important requires a valid style object, got a %s instead.\n\n",
|
|
19921
|
-
"76": "fromSize and toSize must be provided as stringified numbers with the same units as minScreen and maxScreen.\n"
|
|
19920
|
+
"74": "CSS variable not found.\n"
|
|
19922
19921
|
};
|
|
19923
19922
|
/**
|
|
19924
19923
|
* super basic version of sprintf
|
|
@@ -33396,12 +33395,10 @@ ChangePasswordForm.mapDispatchToProps = mapDispatchToProps$1;
|
|
|
33396
33395
|
var titleColor = "#292A33";
|
|
33397
33396
|
var headingBackgroundColor = "transparent";
|
|
33398
33397
|
var bodyBackgroundColor = "transparent";
|
|
33399
|
-
var focusStyles = "outline: none;";
|
|
33400
33398
|
var fallbackValues$q = {
|
|
33401
33399
|
titleColor: titleColor,
|
|
33402
33400
|
headingBackgroundColor: headingBackgroundColor,
|
|
33403
|
-
bodyBackgroundColor: bodyBackgroundColor
|
|
33404
|
-
focusStyles: focusStyles
|
|
33401
|
+
bodyBackgroundColor: bodyBackgroundColor
|
|
33405
33402
|
};
|
|
33406
33403
|
|
|
33407
33404
|
var CollapsibleSection = function CollapsibleSection(_ref) {
|
|
@@ -33459,7 +33456,7 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
|
|
|
33459
33456
|
padding: "0",
|
|
33460
33457
|
tabIndex: "0",
|
|
33461
33458
|
onKeyDown: handleKeyDown,
|
|
33462
|
-
hoverStyles:
|
|
33459
|
+
hoverStyles: "outline: none;",
|
|
33463
33460
|
animate: isOpen ? "open" : "closed",
|
|
33464
33461
|
positionTransition: true
|
|
33465
33462
|
}, /*#__PURE__*/React__default.createElement(Stack, {
|
|
@@ -33469,7 +33466,8 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
|
|
|
33469
33466
|
background: themeValues.headingBackgroundColor,
|
|
33470
33467
|
onClick: isMobile && supportsTouch ? noop : toggleSection,
|
|
33471
33468
|
onTouchEnd: isMobile && supportsTouch ? toggleSection : noop,
|
|
33472
|
-
key: "header"
|
|
33469
|
+
key: "header",
|
|
33470
|
+
hoverStyles: "cursor: pointer;"
|
|
33473
33471
|
}, /*#__PURE__*/React__default.createElement(Cluster, {
|
|
33474
33472
|
justify: "space-between",
|
|
33475
33473
|
align: "center"
|
|
@@ -33483,10 +33481,7 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
|
|
|
33483
33481
|
as: "h6"
|
|
33484
33482
|
}, title), /*#__PURE__*/React__default.createElement(Motion, {
|
|
33485
33483
|
variants: icon,
|
|
33486
|
-
|
|
33487
|
-
display: "flex",
|
|
33488
|
-
alignItems: "center"
|
|
33489
|
-
}
|
|
33484
|
+
extraStyles: "display: flex; align-items: center;"
|
|
33490
33485
|
}, /*#__PURE__*/React__default.createElement(ChevronIcon$1, null)))), /*#__PURE__*/React__default.createElement(AnimatePresence, {
|
|
33491
33486
|
initial: false
|
|
33492
33487
|
}, isOpen && /*#__PURE__*/React__default.createElement(Motion, {
|
|
@@ -37963,7 +37958,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
37963
37958
|
fields = _ref.fields,
|
|
37964
37959
|
actions = _ref.actions,
|
|
37965
37960
|
showErrors = _ref.showErrors,
|
|
37966
|
-
fees = _ref.fees,
|
|
37967
37961
|
_ref$handleSubmit = _ref.handleSubmit,
|
|
37968
37962
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit;
|
|
37969
37963
|
|
|
@@ -38098,13 +38092,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
38098
38092
|
onChange: toggleCheckbox,
|
|
38099
38093
|
checked: defaultMethod.value,
|
|
38100
38094
|
hidden: hideDefaultPayment
|
|
38101
|
-
}), !!(fees === null || fees === void 0 ? void 0 : fees.value) && /*#__PURE__*/React__default.createElement(Alert$1, {
|
|
38102
|
-
heading: "Processing Fee",
|
|
38103
|
-
text: "There is a processing fee of ".concat(fees.type === "FLAT" ? "".concat(displayCurrency(fees.value)) : "".concat(fees.value * 100, "%"), " ").concat(ifElse(isNil, always(""), function (a) {
|
|
38104
|
-
return "with a minimum of ".concat(displayCurrency(a), " ");
|
|
38105
|
-
})(fees.minimumInCents), "on all bank account payments."),
|
|
38106
|
-
variant: "info",
|
|
38107
|
-
showQuitLink: false
|
|
38108
38095
|
})));
|
|
38109
38096
|
};
|
|
38110
38097
|
|
|
@@ -38161,7 +38148,6 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
38161
38148
|
fields = _ref.fields,
|
|
38162
38149
|
actions = _ref.actions,
|
|
38163
38150
|
showErrors = _ref.showErrors,
|
|
38164
|
-
fees = _ref.fees,
|
|
38165
38151
|
_ref$handleSubmit = _ref.handleSubmit,
|
|
38166
38152
|
handleSubmit = _ref$handleSubmit === void 0 ? noop : _ref$handleSubmit,
|
|
38167
38153
|
isMobile = _ref.isMobile;
|
|
@@ -38321,13 +38307,13 @@ var headingBackgroundColor$1 = "".concat(WHITE);
|
|
|
38321
38307
|
var headingDisabledColor = "".concat(ATHENS_GREY);
|
|
38322
38308
|
var bodyBackgroundColor$1 = "#eeeeee";
|
|
38323
38309
|
var borderColor$2 = "".concat(GREY_CHATEAU);
|
|
38324
|
-
var focusStyles
|
|
38310
|
+
var focusStyles = "outline: none;";
|
|
38325
38311
|
var fallbackValues$x = {
|
|
38326
38312
|
headingBackgroundColor: headingBackgroundColor$1,
|
|
38327
38313
|
headingDisabledColor: headingDisabledColor,
|
|
38328
38314
|
bodyBackgroundColor: bodyBackgroundColor$1,
|
|
38329
38315
|
borderColor: borderColor$2,
|
|
38330
|
-
focusStyles: focusStyles
|
|
38316
|
+
focusStyles: focusStyles
|
|
38331
38317
|
};
|
|
38332
38318
|
|
|
38333
38319
|
function _templateObject$A() {
|
|
@@ -38671,7 +38657,8 @@ var ResetConfirmationForm = function ResetConfirmationForm() {
|
|
|
38671
38657
|
url: "/login",
|
|
38672
38658
|
text: "Back to Login",
|
|
38673
38659
|
variant: "primary",
|
|
38674
|
-
extraStyles: "width: 100%;"
|
|
38660
|
+
extraStyles: "width: 100%;",
|
|
38661
|
+
linkExtraStyles: "width: 100%;"
|
|
38675
38662
|
})))));
|
|
38676
38663
|
};
|
|
38677
38664
|
|
|
@@ -38791,7 +38778,8 @@ var ResetConfirmationForm$2 = function ResetConfirmationForm() {
|
|
|
38791
38778
|
url: "/login",
|
|
38792
38779
|
text: "Log in",
|
|
38793
38780
|
variant: "primary",
|
|
38794
|
-
extraStyles: "width: 100%;"
|
|
38781
|
+
extraStyles: "width: 100%;",
|
|
38782
|
+
linkExtraStyles: "width: 100%;"
|
|
38795
38783
|
}))))));
|
|
38796
38784
|
};
|
|
38797
38785
|
|
|
@@ -39113,7 +39101,7 @@ var WelcomeModule = function WelcomeModule(_ref) {
|
|
|
39113
39101
|
}, /*#__PURE__*/React__default.createElement(WelcomeImage, {
|
|
39114
39102
|
src: welcomeImage
|
|
39115
39103
|
}))), /*#__PURE__*/React__default.createElement(Box, {
|
|
39116
|
-
padding: "0.875rem 1.5rem",
|
|
39104
|
+
padding: isMobile ? "0.875rem 1rem" : "0.875rem 1.5rem",
|
|
39117
39105
|
background: themeValues.headerBackgroundColor
|
|
39118
39106
|
}, /*#__PURE__*/React__default.createElement(Heading$1, {
|
|
39119
39107
|
variant: "h6",
|
package/package.json
CHANGED
|
@@ -10,6 +10,7 @@ const ButtonWithLink = ({
|
|
|
10
10
|
disabled = false,
|
|
11
11
|
fileLink = false,
|
|
12
12
|
extraStyles,
|
|
13
|
+
linkExtraStyles,
|
|
13
14
|
newTab = false,
|
|
14
15
|
...otherProps
|
|
15
16
|
}) => {
|
|
@@ -44,7 +45,7 @@ const ButtonWithLink = ({
|
|
|
44
45
|
url={url}
|
|
45
46
|
disabled={disabled}
|
|
46
47
|
newTab={newTab}
|
|
47
|
-
extraStyles={
|
|
48
|
+
extraStyles={`${linkExtraStyles} text-decoration: none; &:hover {
|
|
48
49
|
text-decoration: none; }`}
|
|
49
50
|
>
|
|
50
51
|
<ButtonWithAction {...otherProps} extraStyles={extraStyles} />
|
|
@@ -64,7 +64,7 @@ const CollapsibleSection = ({
|
|
|
64
64
|
padding="0"
|
|
65
65
|
tabIndex="0"
|
|
66
66
|
onKeyDown={handleKeyDown}
|
|
67
|
-
hoverStyles={
|
|
67
|
+
hoverStyles={`outline: none;`}
|
|
68
68
|
animate={isOpen ? "open" : "closed"}
|
|
69
69
|
positionTransition
|
|
70
70
|
>
|
|
@@ -75,6 +75,7 @@ const CollapsibleSection = ({
|
|
|
75
75
|
onClick={isMobile && supportsTouch ? noop : toggleSection}
|
|
76
76
|
onTouchEnd={isMobile && supportsTouch ? toggleSection : noop}
|
|
77
77
|
key="header"
|
|
78
|
+
hoverStyles={`cursor: pointer;`}
|
|
78
79
|
>
|
|
79
80
|
<Cluster justify="space-between" align="center">
|
|
80
81
|
{customTitle ? (
|
|
@@ -93,7 +94,7 @@ const CollapsibleSection = ({
|
|
|
93
94
|
)}
|
|
94
95
|
<Motion
|
|
95
96
|
variants={icon}
|
|
96
|
-
|
|
97
|
+
extraStyles={`display: flex; align-items: center;`}
|
|
97
98
|
>
|
|
98
99
|
<ChevronIcon />
|
|
99
100
|
</Motion>
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
const titleColor = "#292A33";
|
|
2
2
|
const headingBackgroundColor = "transparent";
|
|
3
3
|
const bodyBackgroundColor = "transparent";
|
|
4
|
-
const focusStyles = `outline: none;`;
|
|
5
4
|
|
|
6
5
|
export const fallbackValues = {
|
|
7
6
|
titleColor,
|
|
8
7
|
headingBackgroundColor,
|
|
9
|
-
bodyBackgroundColor
|
|
10
|
-
focusStyles
|
|
8
|
+
bodyBackgroundColor
|
|
11
9
|
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React, { useEffect, useState } from "react";
|
|
2
2
|
import styled from "styled-components";
|
|
3
|
-
import { ifElse, isNil, always } from "ramda";
|
|
4
3
|
import Checkbox from "../../atoms/checkbox";
|
|
5
4
|
import {
|
|
6
5
|
required,
|
|
@@ -14,9 +13,8 @@ import {
|
|
|
14
13
|
FormInputColumn,
|
|
15
14
|
FormContainer
|
|
16
15
|
} from "../../atoms/form-layouts";
|
|
17
|
-
import Alert from "../../atoms/alert";
|
|
18
16
|
import AccountAndRoutingModal from "../account-and-routing-modal";
|
|
19
|
-
import {
|
|
17
|
+
import { noop } from "../../../util/general";
|
|
20
18
|
|
|
21
19
|
const ModalWrapper = styled.div``;
|
|
22
20
|
|
|
@@ -30,7 +28,6 @@ const PaymentFormACH = ({
|
|
|
30
28
|
fields,
|
|
31
29
|
actions,
|
|
32
30
|
showErrors,
|
|
33
|
-
fees,
|
|
34
31
|
handleSubmit = noop
|
|
35
32
|
}) => {
|
|
36
33
|
if (clearOnDismount) {
|
|
@@ -165,22 +162,6 @@ const PaymentFormACH = ({
|
|
|
165
162
|
hidden={hideDefaultPayment}
|
|
166
163
|
/>
|
|
167
164
|
)}
|
|
168
|
-
{!!fees?.value && (
|
|
169
|
-
<Alert
|
|
170
|
-
heading="Processing Fee"
|
|
171
|
-
text={`There is a processing fee of ${
|
|
172
|
-
fees.type === "FLAT"
|
|
173
|
-
? `${displayCurrency(fees.value)}`
|
|
174
|
-
: `${fees.value * 100}%`
|
|
175
|
-
} ${ifElse(
|
|
176
|
-
isNil,
|
|
177
|
-
always(""),
|
|
178
|
-
a => `with a minimum of ${displayCurrency(a)} `
|
|
179
|
-
)(fees.minimumInCents)}on all bank account payments.`}
|
|
180
|
-
variant="info"
|
|
181
|
-
showQuitLink={false}
|
|
182
|
-
/>
|
|
183
|
-
)}
|
|
184
165
|
</FormInputColumn>
|
|
185
166
|
</FormContainer>
|
|
186
167
|
);
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React, { useEffect } from "react";
|
|
2
2
|
import { required, hasLength, matchesRegex } from "redux-freeform";
|
|
3
|
-
import {
|
|
4
|
-
import { checkCardBrand, displayCurrency, noop } from "../../../util/general";
|
|
3
|
+
import { checkCardBrand, noop } from "../../../util/general";
|
|
5
4
|
import { expirationDateFormat, creditCardFormat } from "../../../util/formats";
|
|
6
5
|
import {
|
|
7
6
|
FormInput,
|
|
@@ -10,7 +9,6 @@ import {
|
|
|
10
9
|
FormInputRow
|
|
11
10
|
} from "../../atoms/form-layouts";
|
|
12
11
|
import { Box } from "../../atoms/layouts";
|
|
13
|
-
import Alert from "../../atoms/alert";
|
|
14
12
|
|
|
15
13
|
const nameOnCardErrors = {
|
|
16
14
|
[required.error]: "Name is required"
|
|
@@ -40,7 +38,6 @@ const PaymentFormCard = ({
|
|
|
40
38
|
fields,
|
|
41
39
|
actions,
|
|
42
40
|
showErrors,
|
|
43
|
-
fees,
|
|
44
41
|
handleSubmit = noop,
|
|
45
42
|
isMobile
|
|
46
43
|
}) => {
|
package/.tool-versions
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
nodejs 10.15.3
|