@thecb/components 4.0.9 → 4.0.10
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 +15 -15
- package/package.json +1 -1
- package/src/components/atoms/button-with-action/ButtonWithAction.js +3 -1
- package/src/components/atoms/heading/Heading.js +1 -1
- package/src/components/atoms/paragraph/Paragraph.js +2 -0
- package/src/components/atoms/text/Text.js +2 -0
- package/src/components/molecules/collapsible-section/CollapsibleSection.js +1 -1
- package/src/components/molecules/editable-list/EditableList.js +0 -1
- package/src/components/molecules/editable-table/TableListItem.js +1 -1
- package/src/components/molecules/obligation/modules/TitleModule.js +2 -2
- package/src/components/molecules/radio-section/RadioSection.js +1 -1
- package/src/components/molecules/welcome-module/WelcomeModule.js +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -6119,15 +6119,17 @@ var Text = function Text(_ref) {
|
|
|
6119
6119
|
extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles,
|
|
6120
6120
|
hoverStyles = _ref.hoverStyles,
|
|
6121
6121
|
onClick = _ref.onClick,
|
|
6122
|
+
as = _ref.as,
|
|
6122
6123
|
dataQa = _ref.dataQa,
|
|
6123
6124
|
children = _ref.children,
|
|
6124
|
-
rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "extraStyles", "hoverStyles", "onClick", "dataQa", "children"]);
|
|
6125
|
+
rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "extraStyles", "hoverStyles", "onClick", "as", "dataQa", "children"]);
|
|
6125
6126
|
|
|
6126
6127
|
return /*#__PURE__*/React__default.createElement(TextSpan, _extends({
|
|
6127
6128
|
fontSize: themeValues.fontSize,
|
|
6128
6129
|
weight: weight,
|
|
6129
6130
|
color: color,
|
|
6130
6131
|
fontFamily: themeValues.fontFamily,
|
|
6132
|
+
as: as,
|
|
6131
6133
|
extraStyles: extraStyles,
|
|
6132
6134
|
hoverStyles: hoverStyles,
|
|
6133
6135
|
onClick: onClick,
|
|
@@ -12630,7 +12632,7 @@ var ButtonWithAction = function ButtonWithAction(_ref) {
|
|
|
12630
12632
|
children = _ref.children;
|
|
12631
12633
|
var themeContext = React.useContext(styled.ThemeContext);
|
|
12632
12634
|
var themeValues = createThemeValues(themeContext, fallbackValues$1, "Button", variant);
|
|
12633
|
-
var loadingExtraStyles = "".concat(extraStyles, "; padding-top: 0.75rem; padding-bottom: 0.75rem;");
|
|
12635
|
+
var loadingExtraStyles = "".concat(extraStyles, "; padding-top: 0.75rem; padding-bottom: 0.75rem; height: ").concat(themeContext.isMobile ? "50px" : "57px", " ");
|
|
12634
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 ");
|
|
12635
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 ");
|
|
12636
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 ";
|
|
@@ -14337,7 +14339,7 @@ var Heading = function Heading(_ref) {
|
|
|
14337
14339
|
_ref$variant = _ref.variant,
|
|
14338
14340
|
variant = _ref$variant === void 0 ? "h1" : _ref$variant,
|
|
14339
14341
|
_ref$as = _ref.as,
|
|
14340
|
-
as = _ref$as === void 0 ?
|
|
14342
|
+
as = _ref$as === void 0 ? variant : _ref$as,
|
|
14341
14343
|
dataQa = _ref.dataQa,
|
|
14342
14344
|
children = _ref.children,
|
|
14343
14345
|
rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "margin", "textAlign", "extraStyles", "className", "variant", "as", "dataQa", "children"]);
|
|
@@ -18196,7 +18198,8 @@ var Paragraph = function Paragraph(_ref) {
|
|
|
18196
18198
|
extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles,
|
|
18197
18199
|
dataQa = _ref.dataQa,
|
|
18198
18200
|
children = _ref.children,
|
|
18199
|
-
|
|
18201
|
+
as = _ref.as,
|
|
18202
|
+
rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "margin", "extraStyles", "dataQa", "children", "as"]);
|
|
18200
18203
|
|
|
18201
18204
|
return /*#__PURE__*/React__default.createElement(ParagraphText, _extends({
|
|
18202
18205
|
weight: weight,
|
|
@@ -18204,6 +18207,7 @@ var Paragraph = function Paragraph(_ref) {
|
|
|
18204
18207
|
margin: margin,
|
|
18205
18208
|
fontFamily: themeValues.fontFamily,
|
|
18206
18209
|
fontSize: themeValues.fontSize,
|
|
18210
|
+
as: as,
|
|
18207
18211
|
extraStyles: extraStyles,
|
|
18208
18212
|
"data-qa": dataQa
|
|
18209
18213
|
}, rest), safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
|
|
@@ -33411,7 +33415,7 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
|
|
|
33411
33415
|
variant: "h6",
|
|
33412
33416
|
weight: FONT_WEIGHT_SEMIBOLD,
|
|
33413
33417
|
color: themeValues.titleColor,
|
|
33414
|
-
|
|
33418
|
+
as: "h6"
|
|
33415
33419
|
}, title), /*#__PURE__*/React__default.createElement(Motion, {
|
|
33416
33420
|
variants: icon,
|
|
33417
33421
|
style: {
|
|
@@ -33555,8 +33559,7 @@ var EditableList = function EditableList(_ref) {
|
|
|
33555
33559
|
variant: "pL",
|
|
33556
33560
|
weight: titleWeight,
|
|
33557
33561
|
color: CHARADE_GREY,
|
|
33558
|
-
extraStyles: "letter-spacing: 0.29px;"
|
|
33559
|
-
"aria-level": "3"
|
|
33562
|
+
extraStyles: "letter-spacing: 0.29px;"
|
|
33560
33563
|
}, title)), /*#__PURE__*/React__default.createElement(Box, {
|
|
33561
33564
|
padding: "0",
|
|
33562
33565
|
borderRadius: "4px",
|
|
@@ -33799,8 +33802,7 @@ var TableListItem = function TableListItem(_ref) {
|
|
|
33799
33802
|
isMobile: isMobile
|
|
33800
33803
|
}, /*#__PURE__*/React__default.createElement(Text$1, {
|
|
33801
33804
|
variant: "pS",
|
|
33802
|
-
color: CHARADE_GREY
|
|
33803
|
-
"aria-level": "3"
|
|
33805
|
+
color: CHARADE_GREY
|
|
33804
33806
|
}, title)), /*#__PURE__*/React__default.createElement(TableItemValue, {
|
|
33805
33807
|
isMobile: isMobile
|
|
33806
33808
|
}, /*#__PURE__*/React__default.createElement(Text$1, {
|
|
@@ -36983,11 +36985,10 @@ var TitleModule = function TitleModule(_ref) {
|
|
|
36983
36985
|
variant: "h6",
|
|
36984
36986
|
weight: FONT_WEIGHT_SEMIBOLD,
|
|
36985
36987
|
color: titleColor,
|
|
36986
|
-
|
|
36988
|
+
as: "h2"
|
|
36987
36989
|
}, title), /*#__PURE__*/React__default.createElement(Text$1, {
|
|
36988
36990
|
variant: "pS",
|
|
36989
|
-
color: subtitleColor
|
|
36990
|
-
"aria-level": "3"
|
|
36991
|
+
color: subtitleColor
|
|
36991
36992
|
}, subtitle)));
|
|
36992
36993
|
};
|
|
36993
36994
|
|
|
@@ -38416,8 +38417,7 @@ var RadioSection = function RadioSection(_ref) {
|
|
|
38416
38417
|
padding: section.titleIcon ? "0 0 0 8px" : "0"
|
|
38417
38418
|
}, /*#__PURE__*/React__default.createElement(Text$1, {
|
|
38418
38419
|
variant: "p",
|
|
38419
|
-
color: CHARADE_GREY
|
|
38420
|
-
"aria-level": "3"
|
|
38420
|
+
color: CHARADE_GREY
|
|
38421
38421
|
}, section.title))), section.rightIcons && /*#__PURE__*/React__default.createElement(Cluster, {
|
|
38422
38422
|
childGap: "0.5rem"
|
|
38423
38423
|
}, section.rightIcons.map(function (icon) {
|
|
@@ -39050,7 +39050,7 @@ var WelcomeModule = function WelcomeModule(_ref) {
|
|
|
39050
39050
|
weight: themeValues.fontWeight,
|
|
39051
39051
|
color: themeValues.fontColor,
|
|
39052
39052
|
textAlign: themeValues.textAlign,
|
|
39053
|
-
|
|
39053
|
+
as: "h5"
|
|
39054
39054
|
}, heading)), !isMobile && /*#__PURE__*/React__default.createElement(Box, {
|
|
39055
39055
|
padding: "0",
|
|
39056
39056
|
background: themeValues.imageBackgroundColor
|
package/package.json
CHANGED
|
@@ -82,7 +82,9 @@ const ButtonWithAction = ({
|
|
|
82
82
|
"Button",
|
|
83
83
|
variant
|
|
84
84
|
);
|
|
85
|
-
const loadingExtraStyles = `${extraStyles}; padding-top: 0.75rem; padding-bottom: 0.75rem
|
|
85
|
+
const loadingExtraStyles = `${extraStyles}; padding-top: 0.75rem; padding-bottom: 0.75rem; height: ${
|
|
86
|
+
themeContext.isMobile ? "50px" : "57px"
|
|
87
|
+
} `;
|
|
86
88
|
const hoverStyles = `
|
|
87
89
|
outline: none;
|
|
88
90
|
background-color: ${themeValues.hoverBackgroundColor};
|
|
@@ -14,6 +14,7 @@ const Paragraph = ({
|
|
|
14
14
|
extraStyles = ``,
|
|
15
15
|
dataQa,
|
|
16
16
|
children,
|
|
17
|
+
as,
|
|
17
18
|
...rest
|
|
18
19
|
}) => (
|
|
19
20
|
<ParagraphText
|
|
@@ -22,6 +23,7 @@ const Paragraph = ({
|
|
|
22
23
|
margin={margin}
|
|
23
24
|
fontFamily={themeValues.fontFamily}
|
|
24
25
|
fontSize={themeValues.fontSize}
|
|
26
|
+
as={as}
|
|
25
27
|
extraStyles={extraStyles}
|
|
26
28
|
data-qa={dataQa}
|
|
27
29
|
{...rest}
|
|
@@ -13,6 +13,7 @@ const Text = ({
|
|
|
13
13
|
extraStyles = ``,
|
|
14
14
|
hoverStyles,
|
|
15
15
|
onClick,
|
|
16
|
+
as,
|
|
16
17
|
dataQa,
|
|
17
18
|
children,
|
|
18
19
|
...rest
|
|
@@ -22,6 +23,7 @@ const Text = ({
|
|
|
22
23
|
weight={weight}
|
|
23
24
|
color={color}
|
|
24
25
|
fontFamily={themeValues.fontFamily}
|
|
26
|
+
as={as}
|
|
25
27
|
extraStyles={extraStyles}
|
|
26
28
|
hoverStyles={hoverStyles}
|
|
27
29
|
onClick={onClick}
|
|
@@ -29,7 +29,7 @@ const TableListItem = ({
|
|
|
29
29
|
<ItemWrapper>
|
|
30
30
|
<EditableTableListItem isMobile={isMobile}>
|
|
31
31
|
<TableItemKey isMobile={isMobile}>
|
|
32
|
-
<Text variant="pS" color={CHARADE_GREY}
|
|
32
|
+
<Text variant="pS" color={CHARADE_GREY}>
|
|
33
33
|
{title}
|
|
34
34
|
</Text>
|
|
35
35
|
</TableItemKey>
|
|
@@ -11,11 +11,11 @@ const TitleModule = ({ title, subtitle, titleColor, subtitleColor }) => (
|
|
|
11
11
|
variant="h6"
|
|
12
12
|
weight={FONT_WEIGHT_SEMIBOLD}
|
|
13
13
|
color={titleColor}
|
|
14
|
-
|
|
14
|
+
as="h2"
|
|
15
15
|
>
|
|
16
16
|
{title}
|
|
17
17
|
</Heading>
|
|
18
|
-
<Text variant="pS" color={subtitleColor}
|
|
18
|
+
<Text variant="pS" color={subtitleColor}>
|
|
19
19
|
{subtitle}
|
|
20
20
|
</Text>
|
|
21
21
|
</Stack>
|
|
@@ -168,7 +168,7 @@ const RadioSection = ({
|
|
|
168
168
|
<Cluster align="center">{section.titleIcon}</Cluster>
|
|
169
169
|
)}
|
|
170
170
|
<Box padding={section.titleIcon ? "0 0 0 8px" : "0"}>
|
|
171
|
-
<Text variant="p" color={CHARADE_GREY}
|
|
171
|
+
<Text variant="p" color={CHARADE_GREY}>
|
|
172
172
|
{section.title}
|
|
173
173
|
</Text>
|
|
174
174
|
</Box>
|