carbon-react 104.30.0 → 104.32.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/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js +1 -1
- package/lib/components/definition-list/definition-list.style.js +26 -30
- package/lib/components/numeral-date/numeral-date.style.js +1 -20
- package/lib/components/select/__internal__/select-text/select-text.style.js +2 -8
- package/lib/components/select/select-list/select-list-container.style.js +1 -8
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.component.d.ts +3 -0
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.component.js +8 -2
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.d.ts +2 -0
- package/lib/components/tabs/__internal__/tab-title/tab-title.component.js +1 -0
- package/lib/components/tabs/__internal__/tab-title/tab-title.style.js +122 -175
- package/lib/style/themes/base/base-theme.config.d.ts +0 -5
- package/lib/style/themes/base/base-theme.config.js +0 -5
- package/lib/style/themes/base/index.d.ts +0 -6
- package/lib/style/themes/sage/index.d.ts +0 -5
- package/package.json +1 -1
package/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js
CHANGED
|
@@ -41,7 +41,7 @@ const StyledNavigationItem = _styledComponents.default.li`
|
|
|
41
41
|
${({
|
|
42
42
|
isSelected
|
|
43
43
|
}) => isSelected && (0, _styledComponents.css)`
|
|
44
|
-
background-color: var(--
|
|
44
|
+
background-color: var(--colorsActionMajorYang100);
|
|
45
45
|
border-left-color: var(--colorsActionMajor500);
|
|
46
46
|
`}
|
|
47
47
|
}
|
|
@@ -9,12 +9,12 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
9
9
|
|
|
10
10
|
var _styledSystem = require("styled-system");
|
|
11
11
|
|
|
12
|
-
var _themes = require("../../style/themes");
|
|
13
|
-
|
|
14
12
|
var _button = _interopRequireDefault(require("../button/button.style"));
|
|
15
13
|
|
|
16
14
|
var _link = require("../link/link.style");
|
|
17
15
|
|
|
16
|
+
var _themes = require("../../style/themes");
|
|
17
|
+
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
|
|
20
20
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -44,6 +44,9 @@ const StyledDl = _styledComponents.default.dl`
|
|
|
44
44
|
background-color: transparent;
|
|
45
45
|
`;
|
|
46
46
|
exports.StyledDl = StyledDl;
|
|
47
|
+
StyledDl.defaultProps = {
|
|
48
|
+
theme: _themes.baseTheme
|
|
49
|
+
};
|
|
47
50
|
const StyledDtDiv = _styledComponents.default.div`
|
|
48
51
|
${_styledSystem.space}
|
|
49
52
|
${({
|
|
@@ -53,6 +56,9 @@ const StyledDtDiv = _styledComponents.default.div`
|
|
|
53
56
|
`}
|
|
54
57
|
`;
|
|
55
58
|
exports.StyledDtDiv = StyledDtDiv;
|
|
59
|
+
StyledDtDiv.defaultProps = {
|
|
60
|
+
theme: _themes.baseTheme
|
|
61
|
+
};
|
|
56
62
|
const StyledDdDiv = _styledComponents.default.div`
|
|
57
63
|
${({
|
|
58
64
|
ddTextAlign
|
|
@@ -63,42 +69,32 @@ const StyledDdDiv = _styledComponents.default.div`
|
|
|
63
69
|
exports.StyledDdDiv = StyledDdDiv;
|
|
64
70
|
const StyledDt = _styledComponents.default.dt`
|
|
65
71
|
${_styledSystem.space}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
font-size: 14px
|
|
70
|
-
font-weight: 700;
|
|
71
|
-
color: ${theme.definitionList.dtTextDark};
|
|
72
|
-
`}
|
|
72
|
+
font-size: 14px;
|
|
73
|
+
font-weight: 700;
|
|
74
|
+
color: var(--colorsUtilityYin090);
|
|
73
75
|
`;
|
|
74
76
|
exports.StyledDt = StyledDt;
|
|
75
77
|
StyledDt.defaultProps = {
|
|
76
78
|
theme: _themes.baseTheme
|
|
77
79
|
};
|
|
78
80
|
const StyledDd = _styledComponents.default.dd`
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
font-weight: 700;
|
|
84
|
-
color: ${theme.definitionList.ddText};
|
|
85
|
-
margin-left: 0px;
|
|
81
|
+
font-size: 14px;
|
|
82
|
+
font-weight: 700;
|
|
83
|
+
color: var(--colorsUtilityYin065);
|
|
84
|
+
margin-left: 0px;
|
|
86
85
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
86
|
+
${_button.default} {
|
|
87
|
+
padding: 0;
|
|
88
|
+
border: none;
|
|
89
|
+
}
|
|
91
90
|
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
91
|
+
${_link.StyledLink} {
|
|
92
|
+
a,
|
|
93
|
+
button {
|
|
94
|
+
font-weight: 700px;
|
|
95
|
+
text-decoration: none;
|
|
97
96
|
}
|
|
98
|
-
|
|
97
|
+
}
|
|
99
98
|
${_styledSystem.space}
|
|
100
99
|
`;
|
|
101
|
-
exports.StyledDd = StyledDd;
|
|
102
|
-
StyledDd.defaultProps = {
|
|
103
|
-
theme: _themes.baseTheme
|
|
104
|
-
};
|
|
100
|
+
exports.StyledDd = StyledDd;
|
|
@@ -11,14 +11,10 @@ var _validationIcon = _interopRequireDefault(require("../../__internal__/validat
|
|
|
11
11
|
|
|
12
12
|
var _inputIconToggle = _interopRequireDefault(require("../../__internal__/input-icon-toggle/input-icon-toggle.style"));
|
|
13
13
|
|
|
14
|
-
var _themes = require("../../style/themes");
|
|
15
|
-
|
|
16
14
|
var _inputPresentation = _interopRequireDefault(require("../../__internal__/input/input-presentation.style"));
|
|
17
15
|
|
|
18
16
|
var _formField = _interopRequireDefault(require("../../__internal__/form-field/form-field.style"));
|
|
19
17
|
|
|
20
|
-
var _icon = _interopRequireDefault(require("../icon/icon.style"));
|
|
21
|
-
|
|
22
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
19
|
|
|
24
20
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -39,13 +35,9 @@ const StyledNumeralDate = _styledComponents.default.div`
|
|
|
39
35
|
}
|
|
40
36
|
`;
|
|
41
37
|
exports.StyledNumeralDate = StyledNumeralDate;
|
|
42
|
-
StyledNumeralDate.defaultProps = {
|
|
43
|
-
theme: _themes.baseTheme
|
|
44
|
-
};
|
|
45
38
|
const StyledDateField = _styledComponents.default.div`
|
|
46
39
|
${({
|
|
47
40
|
isYearInput,
|
|
48
|
-
theme,
|
|
49
41
|
isEnd,
|
|
50
42
|
hasValidationIcon,
|
|
51
43
|
isMiddle
|
|
@@ -61,14 +53,6 @@ const StyledDateField = _styledComponents.default.div`
|
|
|
61
53
|
margin-left: -1px;
|
|
62
54
|
`}
|
|
63
55
|
|
|
64
|
-
${_icon.default} {
|
|
65
|
-
display: flex;
|
|
66
|
-
color: ${theme.numeralDate.error};
|
|
67
|
-
width: 16px;
|
|
68
|
-
height: 16px;
|
|
69
|
-
cursor: pointer;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
56
|
${_inputIconToggle.default} {
|
|
73
57
|
width: 32px;
|
|
74
58
|
z-index: 999;
|
|
@@ -80,7 +64,4 @@ const StyledDateField = _styledComponents.default.div`
|
|
|
80
64
|
`;
|
|
81
65
|
}}
|
|
82
66
|
`;
|
|
83
|
-
exports.StyledDateField = StyledDateField;
|
|
84
|
-
StyledDateField.defaultProps = {
|
|
85
|
-
theme: _themes.baseTheme
|
|
86
|
-
};
|
|
67
|
+
exports.StyledDateField = StyledDateField;
|
|
@@ -7,8 +7,6 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
9
|
|
|
10
|
-
var _themes = require("../../../../style/themes");
|
|
11
|
-
|
|
12
10
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
13
11
|
|
|
14
12
|
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -18,7 +16,6 @@ const StyledSelectText = _styledComponents.default.span`
|
|
|
18
16
|
disabled,
|
|
19
17
|
hasPlaceholder,
|
|
20
18
|
readOnly,
|
|
21
|
-
theme,
|
|
22
19
|
transparent
|
|
23
20
|
}) => (0, _styledComponents.css)`
|
|
24
21
|
align-items: center;
|
|
@@ -40,7 +37,7 @@ const StyledSelectText = _styledComponents.default.span`
|
|
|
40
37
|
`}
|
|
41
38
|
|
|
42
39
|
${hasPlaceholder && (0, _styledComponents.css)`
|
|
43
|
-
color:
|
|
40
|
+
color: var(--colorsUtilityYin055);
|
|
44
41
|
font-weight: normal;
|
|
45
42
|
user-select: none;
|
|
46
43
|
`}
|
|
@@ -53,13 +50,10 @@ const StyledSelectText = _styledComponents.default.span`
|
|
|
53
50
|
|
|
54
51
|
${readOnly && (0, _styledComponents.css)`
|
|
55
52
|
cursor: default;
|
|
56
|
-
color: var(--
|
|
53
|
+
color: var(--colorsUtilityYin065);
|
|
57
54
|
text-shadow: none;
|
|
58
55
|
`}
|
|
59
56
|
`}
|
|
60
57
|
`;
|
|
61
|
-
StyledSelectText.defaultProps = {
|
|
62
|
-
theme: _themes.baseTheme
|
|
63
|
-
};
|
|
64
58
|
var _default = StyledSelectText;
|
|
65
59
|
exports.default = _default;
|
|
@@ -7,15 +7,11 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
9
9
|
|
|
10
|
-
var _themes = require("../../../style/themes");
|
|
11
|
-
|
|
12
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
11
|
|
|
14
12
|
const StyledSelectListContainer = _styledComponents.default.div`
|
|
15
13
|
background-color: white;
|
|
16
|
-
box-shadow:
|
|
17
|
-
theme
|
|
18
|
-
}) => `${theme.shadows.depth1}`};
|
|
14
|
+
box-shadow: var(--boxShadow100);
|
|
19
15
|
position: absolute;
|
|
20
16
|
${({
|
|
21
17
|
placement
|
|
@@ -37,8 +33,5 @@ const StyledSelectListContainer = _styledComponents.default.div`
|
|
|
37
33
|
}
|
|
38
34
|
}
|
|
39
35
|
`;
|
|
40
|
-
StyledSelectListContainer.defaultProps = {
|
|
41
|
-
theme: _themes.baseTheme
|
|
42
|
-
};
|
|
43
36
|
var _default = StyledSelectListContainer;
|
|
44
37
|
exports.default = _default;
|
|
@@ -4,6 +4,7 @@ declare namespace StepSequenceItem {
|
|
|
4
4
|
namespace propTypes {
|
|
5
5
|
const children: PropTypes.Validator<string | number | boolean | {} | PropTypes.ReactElementLike | PropTypes.ReactNodeArray>;
|
|
6
6
|
const indicator: PropTypes.Validator<string>;
|
|
7
|
+
const hideIndicator: PropTypes.Requireable<boolean>;
|
|
7
8
|
const ariaLabel: PropTypes.Requireable<string>;
|
|
8
9
|
const status: PropTypes.Requireable<string>;
|
|
9
10
|
const hiddenCompleteLabel: PropTypes.Requireable<string>;
|
|
@@ -12,6 +13,8 @@ declare namespace StepSequenceItem {
|
|
|
12
13
|
namespace defaultProps {
|
|
13
14
|
const status_1: string;
|
|
14
15
|
export { status_1 as status };
|
|
16
|
+
const hideIndicator_1: boolean;
|
|
17
|
+
export { hideIndicator_1 as hideIndicator };
|
|
15
18
|
}
|
|
16
19
|
}
|
|
17
20
|
import PropTypes from "prop-types";
|
|
@@ -24,7 +24,9 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
24
24
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25
25
|
|
|
26
26
|
const StepSequenceItem = props => {
|
|
27
|
-
const indicatorText = () =>
|
|
27
|
+
const indicatorText = () => {
|
|
28
|
+
return !props.hideIndicator ? /*#__PURE__*/_react.default.createElement(_stepSequenceItemIndicator.default, null, props.indicator) : null;
|
|
29
|
+
};
|
|
28
30
|
|
|
29
31
|
const icon = () => props.status === "complete" ? /*#__PURE__*/_react.default.createElement(_icon.default, {
|
|
30
32
|
type: "tick"
|
|
@@ -62,6 +64,9 @@ StepSequenceItem.propTypes = {
|
|
|
62
64
|
/** Value to be displayed before text for uncompleted steps */
|
|
63
65
|
indicator: _propTypes.default.string.isRequired,
|
|
64
66
|
|
|
67
|
+
/** Flag to hide the indicator for uncompleted steps */
|
|
68
|
+
hideIndicator: _propTypes.default.bool,
|
|
69
|
+
|
|
65
70
|
/** Aria label */
|
|
66
71
|
ariaLabel: _propTypes.default.string,
|
|
67
72
|
|
|
@@ -75,7 +80,8 @@ StepSequenceItem.propTypes = {
|
|
|
75
80
|
hiddenCurrentLabel: _propTypes.default.string
|
|
76
81
|
};
|
|
77
82
|
StepSequenceItem.defaultProps = {
|
|
78
|
-
status: "incomplete"
|
|
83
|
+
status: "incomplete",
|
|
84
|
+
hideIndicator: false
|
|
79
85
|
};
|
|
80
86
|
var _default = StepSequenceItem;
|
|
81
87
|
exports.default = _default;
|
|
@@ -9,6 +9,8 @@ export interface StepSequenceItemProps {
|
|
|
9
9
|
hiddenCurrentLabel?: string;
|
|
10
10
|
/** Value to be displayed before text for uncomplete steps */
|
|
11
11
|
indicator: string;
|
|
12
|
+
/** Flag to hide the indicator for uncomplete steps */
|
|
13
|
+
hideIndicator?: boolean;
|
|
12
14
|
/** Status for the step */
|
|
13
15
|
status?: "complete" | "current" | "incomplete";
|
|
14
16
|
}
|
|
@@ -137,6 +137,7 @@ const TabTitle = /*#__PURE__*/_react.default.forwardRef(({
|
|
|
137
137
|
warning: warning,
|
|
138
138
|
info: info,
|
|
139
139
|
noRightBorder: noRightBorder,
|
|
140
|
+
noLeftBorder: noLeftBorder,
|
|
140
141
|
alternateStyling: alternateStyling || isInSidebar,
|
|
141
142
|
borders: borders,
|
|
142
143
|
isInSidebar: isInSidebar
|
|
@@ -22,21 +22,25 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
22
22
|
const StyledTitleContent = _styledComponents.default.span`
|
|
23
23
|
outline: none;
|
|
24
24
|
display: inline-block;
|
|
25
|
+
line-height: 20px;
|
|
26
|
+
margin: 0;
|
|
25
27
|
|
|
26
28
|
${({
|
|
29
|
+
hasCustomLayout,
|
|
30
|
+
error,
|
|
31
|
+
warning,
|
|
32
|
+
info,
|
|
27
33
|
size,
|
|
34
|
+
isTabSelected,
|
|
35
|
+
hasSiblings,
|
|
28
36
|
borders,
|
|
29
37
|
position,
|
|
30
38
|
noLeftBorder,
|
|
31
39
|
noRightBorder,
|
|
32
|
-
isTabSelected,
|
|
33
40
|
hasHref,
|
|
34
|
-
error,
|
|
35
41
|
alternateStyling,
|
|
36
42
|
align
|
|
37
43
|
}) => (0, _styledComponents.css)`
|
|
38
|
-
line-height: 20px;
|
|
39
|
-
margin: 0;
|
|
40
44
|
text-align: ${align};
|
|
41
45
|
|
|
42
46
|
${position === "left" && (0, _styledComponents.css)`
|
|
@@ -60,7 +64,7 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
60
64
|
`}
|
|
61
65
|
|
|
62
66
|
${!hasHref && (0, _styledComponents.css)`
|
|
63
|
-
[data-component="icon"] {
|
|
67
|
+
[data-component="icon"]:not([color]) {
|
|
64
68
|
color: var(--colorsActionMinorYin065);
|
|
65
69
|
}
|
|
66
70
|
`}
|
|
@@ -97,27 +101,16 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
97
101
|
${size === "large" && position === "left" && (0, _styledComponents.css)`
|
|
98
102
|
font-size: 16px;
|
|
99
103
|
padding: 14px 24px;
|
|
100
|
-
${!isTabSelected && !alternateStyling && error && `margin-right: -2px;`}
|
|
101
104
|
`}
|
|
102
105
|
|
|
103
106
|
${size === "default" && (0, _styledComponents.css)`
|
|
104
107
|
padding: 10px 16px;
|
|
105
108
|
|
|
106
109
|
${borders && `padding-bottom: 9px;`}
|
|
107
|
-
|
|
108
|
-
${position === "left" && !isTabSelected && !alternateStyling && error && `
|
|
109
|
-
margin-right: -2px;
|
|
110
|
-
`}
|
|
111
110
|
`}
|
|
112
|
-
|
|
111
|
+
|
|
113
112
|
|
|
114
|
-
|
|
115
|
-
position,
|
|
116
|
-
warning,
|
|
117
|
-
info,
|
|
118
|
-
size,
|
|
119
|
-
hasCustomLayout
|
|
120
|
-
}) => (warning || info) && (0, _styledComponents.css)`
|
|
113
|
+
${(warning || info) && (0, _styledComponents.css)`
|
|
121
114
|
outline: 1px solid;
|
|
122
115
|
outline-offset: -1px;
|
|
123
116
|
|
|
@@ -129,11 +122,11 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
129
122
|
outline-color: var(--colorsSemanticCaution500);
|
|
130
123
|
`}
|
|
131
124
|
|
|
132
|
-
|
|
125
|
+
${position === "top" && (0, _styledComponents.css)`
|
|
133
126
|
border-bottom-color: transparent;
|
|
134
127
|
`}
|
|
135
128
|
|
|
136
|
-
|
|
129
|
+
${position === "left" && (0, _styledComponents.css)`
|
|
137
130
|
border-right-color: transparent;
|
|
138
131
|
padding-right: ${size === "large" ? "26px" : "18px"};
|
|
139
132
|
`}
|
|
@@ -150,7 +143,7 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
150
143
|
outline-color: var(--colorsSemanticCaution500);
|
|
151
144
|
`}
|
|
152
145
|
|
|
153
|
-
|
|
146
|
+
${position === "top" && (0, _styledComponents.css)`
|
|
154
147
|
border-bottom-color: transparent;
|
|
155
148
|
|
|
156
149
|
${hasCustomLayout && (0, _styledComponents.css)`
|
|
@@ -158,19 +151,14 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
158
151
|
`}
|
|
159
152
|
`}
|
|
160
153
|
|
|
161
|
-
|
|
154
|
+
${position === "left" && (0, _styledComponents.css)`
|
|
162
155
|
border-right-color: transparent;
|
|
163
156
|
padding-right: ${size === "large" ? "26px" : "18px"};
|
|
164
157
|
`}
|
|
165
158
|
}
|
|
166
159
|
`}
|
|
167
160
|
|
|
168
|
-
|
|
169
|
-
error,
|
|
170
|
-
position,
|
|
171
|
-
size,
|
|
172
|
-
hasCustomLayout
|
|
173
|
-
}) => error && (0, _styledComponents.css)`
|
|
161
|
+
${error && (0, _styledComponents.css)`
|
|
174
162
|
outline: 2px solid var(--colorsSemanticNegative500);
|
|
175
163
|
outline-offset: -2px;
|
|
176
164
|
|
|
@@ -201,32 +189,11 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
201
189
|
}
|
|
202
190
|
`}
|
|
203
191
|
|
|
204
|
-
|
|
205
|
-
hasSiblings,
|
|
206
|
-
hasCustomLayout,
|
|
207
|
-
error,
|
|
208
|
-
warning,
|
|
209
|
-
info,
|
|
210
|
-
size,
|
|
211
|
-
isTabSelected,
|
|
212
|
-
position
|
|
213
|
-
}) => hasSiblings && !hasCustomLayout && position === "top" && (0, _styledComponents.css)`
|
|
192
|
+
${hasSiblings && !hasCustomLayout && position === "top" && (0, _styledComponents.css)`
|
|
214
193
|
height: 20px;
|
|
215
|
-
|
|
216
|
-
${size === "large" && !(error || warning || info) && isTabSelected && (0, _styledComponents.css)`
|
|
217
|
-
padding-bottom: 6px;
|
|
218
|
-
`}
|
|
219
194
|
`}
|
|
220
195
|
|
|
221
|
-
|
|
222
|
-
hasCustomLayout,
|
|
223
|
-
error,
|
|
224
|
-
warning,
|
|
225
|
-
info,
|
|
226
|
-
position,
|
|
227
|
-
size,
|
|
228
|
-
isTabSelected
|
|
229
|
-
}) => hasCustomLayout && (0, _styledComponents.css)`
|
|
196
|
+
${hasCustomLayout && (0, _styledComponents.css)`
|
|
230
197
|
display: flex;
|
|
231
198
|
|
|
232
199
|
${position === "left" && (0, _styledComponents.css)`
|
|
@@ -251,9 +218,10 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
251
218
|
&:hover {
|
|
252
219
|
padding-bottom: ${size === "large" ? "4px" : "2px"};
|
|
253
220
|
}
|
|
254
|
-
`}
|
|
221
|
+
`}
|
|
255
222
|
`}
|
|
256
223
|
`}
|
|
224
|
+
`}
|
|
257
225
|
`;
|
|
258
226
|
exports.StyledTitleContent = StyledTitleContent;
|
|
259
227
|
const StyledTabTitle = _styledComponents.default.button`
|
|
@@ -268,131 +236,114 @@ const StyledTabTitle = _styledComponents.default.button`
|
|
|
268
236
|
text-decoration: none;
|
|
269
237
|
outline-offset: 0px;
|
|
270
238
|
margin: 0;
|
|
271
|
-
height: ${({
|
|
272
|
-
size
|
|
273
|
-
}) => size === "large" ? "var(--sizing600)" : "var(--sizing500)"};
|
|
274
239
|
|
|
275
240
|
a:visited {
|
|
276
241
|
color: inherit;
|
|
277
242
|
}
|
|
278
243
|
|
|
279
244
|
${({
|
|
245
|
+
size,
|
|
280
246
|
position,
|
|
281
247
|
borders,
|
|
282
248
|
noRightBorder,
|
|
283
|
-
noLeftBorder
|
|
249
|
+
noLeftBorder,
|
|
250
|
+
isTabSelected,
|
|
251
|
+
alternateStyling,
|
|
252
|
+
error,
|
|
253
|
+
warning,
|
|
254
|
+
info,
|
|
255
|
+
isInSidebar
|
|
284
256
|
}) => (0, _styledComponents.css)`
|
|
257
|
+
height: ${size === "large" ? "var(--sizing600)" : "var(--sizing500)"};
|
|
258
|
+
|
|
285
259
|
${position === "top" && (0, _styledComponents.css)`
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
260
|
+
${borders && !(noRightBorder || noLeftBorder) && (0, _styledComponents.css)`
|
|
261
|
+
&:nth-of-type(n + 1) {
|
|
262
|
+
margin-left: -1px;
|
|
263
|
+
}
|
|
264
|
+
&:first-child {
|
|
265
|
+
margin-left: 0;
|
|
266
|
+
}
|
|
267
|
+
`}
|
|
293
268
|
`}
|
|
294
|
-
`}
|
|
295
269
|
${position === "left" && (0, _styledComponents.css)`
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
270
|
+
${borders && (0, _styledComponents.css)`
|
|
271
|
+
&:nth-of-type(n + 1) {
|
|
272
|
+
margin-top: -1px;
|
|
273
|
+
}
|
|
274
|
+
&:first-child {
|
|
275
|
+
margin-top: 0;
|
|
276
|
+
}
|
|
277
|
+
`}
|
|
303
278
|
`}
|
|
304
|
-
`}
|
|
305
|
-
`}
|
|
306
279
|
|
|
307
|
-
|
|
308
|
-
isTabSelected
|
|
309
|
-
}) => !isTabSelected && (0, _styledComponents.css)`
|
|
310
|
-
color: var(--colorsActionMinorYin090);
|
|
311
|
-
|
|
312
|
-
&:hover {
|
|
313
|
-
background: var(--colorsActionMinor100);
|
|
314
|
-
color: var(--colorsActionMinorYin090);
|
|
315
|
-
outline: none;
|
|
316
|
-
}
|
|
317
|
-
&:focus {
|
|
280
|
+
${!isTabSelected && (0, _styledComponents.css)`
|
|
318
281
|
color: var(--colorsActionMinorYin090);
|
|
319
|
-
outline: none;
|
|
320
|
-
}
|
|
321
|
-
`}
|
|
322
|
-
|
|
323
|
-
${({
|
|
324
|
-
isTabSelected,
|
|
325
|
-
alternateStyling,
|
|
326
|
-
error,
|
|
327
|
-
warning,
|
|
328
|
-
info
|
|
329
|
-
}) => isTabSelected && (0, _styledComponents.css)`
|
|
330
|
-
color: var(--colorsActionMajorYin090);
|
|
331
|
-
background-color: var(--colorsActionMajorYang100);
|
|
332
282
|
|
|
333
|
-
|
|
334
|
-
|
|
283
|
+
&:hover {
|
|
284
|
+
background: var(--colorsActionMinor100);
|
|
285
|
+
color: var(--colorsActionMinorYin090);
|
|
286
|
+
outline: none;
|
|
287
|
+
}
|
|
288
|
+
&:focus {
|
|
289
|
+
color: var(--colorsActionMinorYin090);
|
|
290
|
+
outline: none;
|
|
291
|
+
}
|
|
335
292
|
`}
|
|
336
293
|
|
|
337
|
-
|
|
338
|
-
background-color: var(--colorsActionMajorYang100);
|
|
339
|
-
border-bottom-color: ${alternateStyling ? "var(--colorsActionMinor100)" : "var(--colorsActionMajor500)"};
|
|
294
|
+
${isTabSelected && (0, _styledComponents.css)`
|
|
340
295
|
color: var(--colorsActionMajorYin090);
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
296
|
+
background-color: var(--colorsActionMajorYang100);
|
|
297
|
+
|
|
298
|
+
${(error || warning || info) && (0, _styledComponents.css)`
|
|
299
|
+
padding-bottom: 0px;
|
|
300
|
+
`}
|
|
301
|
+
|
|
302
|
+
&:hover {
|
|
303
|
+
background-color: var(--colorsActionMajorYang100);
|
|
304
|
+
border-bottom-color: ${alternateStyling ? "var(--colorsActionMinor100)" : "var(--colorsActionMajor500)"};
|
|
305
|
+
color: var(--colorsActionMajorYin090);
|
|
306
|
+
cursor: default;
|
|
307
|
+
}
|
|
308
|
+
`}
|
|
344
309
|
|
|
345
|
-
${({
|
|
346
|
-
isInSidebar
|
|
347
|
-
}) => `
|
|
348
310
|
&:focus {
|
|
349
311
|
outline: ${isInSidebar ? "none;" : "var(--borderWidth300) solid var(--colorsSemanticFocus500);"}
|
|
350
312
|
z-index: 2;
|
|
351
313
|
}
|
|
352
|
-
`}
|
|
353
|
-
|
|
354
|
-
${({
|
|
355
|
-
position,
|
|
356
|
-
borders,
|
|
357
|
-
alternateStyling,
|
|
358
|
-
error,
|
|
359
|
-
warning,
|
|
360
|
-
info,
|
|
361
|
-
isInSidebar
|
|
362
|
-
}) => position === "left" && (0, _styledComponents.css)`
|
|
363
|
-
background-color: transparent;
|
|
364
|
-
border-bottom: 0px;
|
|
365
314
|
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
`}
|
|
315
|
+
${position === "left" && (0, _styledComponents.css)`
|
|
316
|
+
background-color: transparent;
|
|
317
|
+
border-bottom: 0px;
|
|
370
318
|
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
}
|
|
375
|
-
|
|
319
|
+
${!isInSidebar && !error && (0, _styledComponents.css)`
|
|
320
|
+
border-right: ${alternateStyling ? "1px" : "2px"} solid
|
|
321
|
+
var(--colorsActionMinor100);
|
|
322
|
+
`}
|
|
323
|
+
|
|
324
|
+
${!borders && (0, _styledComponents.css)`
|
|
325
|
+
${StyledTitleContent} {
|
|
326
|
+
border-bottom: none;
|
|
327
|
+
}
|
|
328
|
+
`}
|
|
376
329
|
|
|
377
330
|
display: flex;
|
|
378
|
-
|
|
379
|
-
|
|
331
|
+
height: auto;
|
|
332
|
+
margin-left: 0px;
|
|
380
333
|
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
334
|
+
&:first-child {
|
|
335
|
+
margin-top: 0;
|
|
336
|
+
}
|
|
384
337
|
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
338
|
+
&:hover {
|
|
339
|
+
${alternateStyling && "border-right-color: var(--colorsActionMinor100)"}
|
|
340
|
+
}
|
|
388
341
|
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
342
|
+
${(warning || info) && (0, _styledComponents.css)`
|
|
343
|
+
border-right: none;
|
|
344
|
+
`}
|
|
392
345
|
|
|
393
|
-
|
|
394
|
-
isTabSelected
|
|
395
|
-
}) => isTabSelected && (0, _styledComponents.css)`
|
|
346
|
+
${isTabSelected && (0, _styledComponents.css)`
|
|
396
347
|
${alternateStyling && (0, _styledComponents.css)`
|
|
397
348
|
border-right-color: var(--colorsActionMinor100);
|
|
398
349
|
`}
|
|
@@ -406,8 +357,8 @@ const StyledTabTitle = _styledComponents.default.button`
|
|
|
406
357
|
border-right: none;
|
|
407
358
|
}
|
|
408
359
|
`}
|
|
409
|
-
|
|
410
|
-
|
|
360
|
+
|
|
361
|
+
background-color: var(--colorsActionMajorYang100);
|
|
411
362
|
|
|
412
363
|
&:hover {
|
|
413
364
|
${alternateStyling && "border-right-color: var(--colorsActionMinor100);"}
|
|
@@ -419,43 +370,38 @@ const StyledTabTitle = _styledComponents.default.button`
|
|
|
419
370
|
${(error || warning || info) && "border-right-color: var(--colorsSemanticNegative500);"}
|
|
420
371
|
}
|
|
421
372
|
`}
|
|
422
|
-
|
|
373
|
+
`}
|
|
423
374
|
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
}) => alternateStyling && (0, _styledComponents.css)`
|
|
429
|
-
&:focus {
|
|
430
|
-
background-color: var(--colorsActionMinor100);
|
|
431
|
-
}
|
|
375
|
+
${alternateStyling && (0, _styledComponents.css)`
|
|
376
|
+
&:focus {
|
|
377
|
+
background-color: var(--colorsActionMinor100);
|
|
378
|
+
}
|
|
432
379
|
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
380
|
+
&:hover {
|
|
381
|
+
background-color: ${isTabSelected ? "var(--colorsActionMinor100)" : "var(--colorsActionMinor150)"};
|
|
382
|
+
}
|
|
436
383
|
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
384
|
+
${isTabSelected && (0, _styledComponents.css)`
|
|
385
|
+
background-color: var(--colorsActionMinor100);
|
|
386
|
+
`}
|
|
440
387
|
|
|
441
|
-
|
|
442
|
-
|
|
388
|
+
${isInSidebar && `padding-bottom: 1px;`}
|
|
389
|
+
`}
|
|
390
|
+
`}
|
|
443
391
|
`;
|
|
444
392
|
exports.StyledTabTitle = StyledTabTitle;
|
|
445
393
|
const StyledLayoutWrapper = _styledComponents.default.div`
|
|
446
|
-
${({
|
|
447
|
-
hasCustomLayout
|
|
448
|
-
}) => hasCustomLayout && (0, _styledComponents.css)`
|
|
449
|
-
flex-grow: 2;
|
|
450
|
-
min-width: 100px;
|
|
451
|
-
`}
|
|
452
|
-
|
|
453
394
|
${({
|
|
454
395
|
hasCustomLayout,
|
|
455
396
|
titlePosition,
|
|
456
397
|
hasCustomSibling,
|
|
457
398
|
position
|
|
458
|
-
}) =>
|
|
399
|
+
}) => (0, _styledComponents.css)`
|
|
400
|
+
${hasCustomLayout && (0, _styledComponents.css)`
|
|
401
|
+
flex-grow: 2;
|
|
402
|
+
`}
|
|
403
|
+
|
|
404
|
+
${!hasCustomLayout && (0, _styledComponents.css)`
|
|
459
405
|
display: inline-flex;
|
|
460
406
|
|
|
461
407
|
position: relative;
|
|
@@ -481,6 +427,7 @@ const StyledLayoutWrapper = _styledComponents.default.div`
|
|
|
481
427
|
}
|
|
482
428
|
}
|
|
483
429
|
`}
|
|
430
|
+
`}
|
|
484
431
|
`;
|
|
485
432
|
exports.StyledLayoutWrapper = StyledLayoutWrapper;
|
|
486
433
|
const StyledSelectedIndicator = _styledComponents.default.div`
|
|
@@ -489,7 +436,8 @@ const StyledSelectedIndicator = _styledComponents.default.div`
|
|
|
489
436
|
|
|
490
437
|
${({
|
|
491
438
|
position
|
|
492
|
-
}) =>
|
|
439
|
+
}) => (0, _styledComponents.css)`
|
|
440
|
+
${position === "top" && (0, _styledComponents.css)`
|
|
493
441
|
bottom: 0px;
|
|
494
442
|
left: 0px;
|
|
495
443
|
box-shadow: inset 0px calc(-1 * var(--sizing025)) 0px
|
|
@@ -498,9 +446,7 @@ const StyledSelectedIndicator = _styledComponents.default.div`
|
|
|
498
446
|
height: var(--sizing025);
|
|
499
447
|
`}
|
|
500
448
|
|
|
501
|
-
|
|
502
|
-
position
|
|
503
|
-
}) => position === "left" && (0, _styledComponents.css)`
|
|
449
|
+
${position === "left" && (0, _styledComponents.css)`
|
|
504
450
|
top: 0px;
|
|
505
451
|
right: 0px;
|
|
506
452
|
box-shadow: inset calc(-1 * var(--sizing025)) 0px 0px 0px
|
|
@@ -508,6 +454,7 @@ const StyledSelectedIndicator = _styledComponents.default.div`
|
|
|
508
454
|
height: 100%;
|
|
509
455
|
width: var(--sizing025);
|
|
510
456
|
`}
|
|
457
|
+
`}
|
|
511
458
|
`;
|
|
512
459
|
exports.StyledSelectedIndicator = StyledSelectedIndicator;
|
|
513
460
|
StyledTabTitle.propTypes = {
|
|
@@ -198,11 +198,6 @@ var _default = palette => {
|
|
|
198
198
|
content: {
|
|
199
199
|
secondaryColor: palette.slateTint(40)
|
|
200
200
|
},
|
|
201
|
-
definitionList: {
|
|
202
|
-
dtTextDark: palette.blackOpacity(0.9),
|
|
203
|
-
dtTextLight: palette.blackOpacity(0.65),
|
|
204
|
-
ddText: palette.blackOpacity(0.65)
|
|
205
|
-
},
|
|
206
201
|
disabled: {
|
|
207
202
|
border: palette.slateTint(80),
|
|
208
203
|
button: palette.slateTint(90),
|