carbon-react 104.21.0 → 104.23.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/__internal__/full-screen-heading/full-screen-heading.style.js +1 -10
- package/lib/__internal__/input/input-presentation.style.js +2 -3
- package/lib/__internal__/input/input.component.js +3 -0
- package/lib/components/flat-table/flat-table-checkbox/flat-table-checkbox.component.js +14 -3
- package/lib/components/heading/heading.style.js +4 -21
- package/lib/components/menu/__internal__/submenu/submenu.style.js +31 -40
- package/lib/components/menu/menu-divider/menu-divider.style.js +4 -6
- package/lib/components/menu/menu-full-screen/menu-full-screen.style.js +9 -11
- package/lib/components/menu/menu-item/menu-item.style.js +110 -80
- package/lib/components/menu/menu-segment-title/menu-segment-title.style.js +5 -7
- package/lib/components/menu/menu.config.d.ts +95 -0
- package/lib/components/menu/menu.config.js +65 -0
- package/lib/components/menu/menu.style.js +8 -10
- package/lib/components/menu/scrollable-block/scrollable-block.style.js +4 -8
- package/lib/components/menu/submenu-block/submenu-block.style.js +4 -8
- package/lib/style/themes/aegean/aegean-theme.config.d.ts +9 -0
- package/lib/style/themes/aegean/aegean-theme.config.js +9 -0
- package/lib/style/themes/mint/mint-theme.config.d.ts +9 -0
- package/lib/style/themes/mint/mint-theme.config.js +9 -0
- package/package.json +1 -1
|
@@ -9,10 +9,6 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
9
9
|
|
|
10
10
|
var _heading = require("../../components/heading/heading.style");
|
|
11
11
|
|
|
12
|
-
var _base = _interopRequireDefault(require("../../style/themes/base"));
|
|
13
|
-
|
|
14
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
-
|
|
16
12
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
17
13
|
|
|
18
14
|
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; }
|
|
@@ -26,9 +22,7 @@ const StyledFullScreenHeading = _styledComponents.default.div`
|
|
|
26
22
|
${({
|
|
27
23
|
hasContent
|
|
28
24
|
}) => hasContent && (0, _styledComponents.css)`
|
|
29
|
-
border-bottom: 1px solid
|
|
30
|
-
theme
|
|
31
|
-
}) => theme.disabled.border};
|
|
25
|
+
border-bottom: 1px solid var(--colorsUtilityMajor050);
|
|
32
26
|
`}
|
|
33
27
|
display: flex;
|
|
34
28
|
justify-content: space-between;
|
|
@@ -56,8 +50,5 @@ const StyledFullScreenHeading = _styledComponents.default.div`
|
|
|
56
50
|
}
|
|
57
51
|
}
|
|
58
52
|
`;
|
|
59
|
-
StyledFullScreenHeading.defaultProps = {
|
|
60
|
-
theme: _base.default
|
|
61
|
-
};
|
|
62
53
|
var _default = StyledFullScreenHeading;
|
|
63
54
|
exports.default = _default;
|
|
@@ -54,9 +54,8 @@ const InputPresentationStyle = _styledComponents.default.div`
|
|
|
54
54
|
`}
|
|
55
55
|
|
|
56
56
|
${({
|
|
57
|
-
hasFocus
|
|
58
|
-
|
|
59
|
-
}) => hasFocus && !disabled && (0, _styledComponents.css)`
|
|
57
|
+
hasFocus
|
|
58
|
+
}) => hasFocus && (0, _styledComponents.css)`
|
|
60
59
|
& {
|
|
61
60
|
outline: 3px solid var(--colorsSemanticFocus500);
|
|
62
61
|
z-index: 2;
|
|
@@ -53,6 +53,9 @@ const Input = /*#__PURE__*/_react.default.forwardRef(({
|
|
|
53
53
|
(0, _react.useEffect)(() => {
|
|
54
54
|
if (context.inputRef) context.inputRef(input);
|
|
55
55
|
}, [context, input]);
|
|
56
|
+
(0, _react.useEffect)(() => {
|
|
57
|
+
if (disabled && context.onBlur) context.onBlur();
|
|
58
|
+
}, [disabled, context]);
|
|
56
59
|
|
|
57
60
|
const handleClick = ev => {
|
|
58
61
|
if (onClick) onClick(ev);
|
|
@@ -37,19 +37,30 @@ const FlatTableCheckbox = ({
|
|
|
37
37
|
}
|
|
38
38
|
}, [reportCellWidth, cellIndex]);
|
|
39
39
|
const dataElement = `flat-table-checkbox-${as === "td" ? "cell" : "header"}`;
|
|
40
|
+
|
|
41
|
+
const handleClick = event => {
|
|
42
|
+
event.stopPropagation();
|
|
43
|
+
if (onClick) onClick(event);
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
const handleKeyDown = event => {
|
|
47
|
+
event.stopPropagation();
|
|
48
|
+
};
|
|
49
|
+
|
|
40
50
|
return /*#__PURE__*/_react.default.createElement(_flatTableCheckbox.default, {
|
|
41
51
|
ref: ref,
|
|
42
52
|
makeCellSticky: !!reportCellWidth,
|
|
43
53
|
leftPosition: leftPosition || 0,
|
|
44
54
|
"data-element": dataElement,
|
|
45
|
-
as: as
|
|
46
|
-
onClick: onClick
|
|
55
|
+
as: as
|
|
47
56
|
}, selectable && /*#__PURE__*/_react.default.createElement(_checkbox.Checkbox, {
|
|
48
57
|
checked: checked,
|
|
49
58
|
onChange: onChange,
|
|
50
59
|
name: "flat-table-checkbox",
|
|
51
60
|
mb: 0,
|
|
52
|
-
ariaLabelledBy: ariaLabelledBy
|
|
61
|
+
ariaLabelledBy: ariaLabelledBy,
|
|
62
|
+
onClick: handleClick,
|
|
63
|
+
onKeyDown: handleKeyDown
|
|
53
64
|
}));
|
|
54
65
|
};
|
|
55
66
|
|
|
@@ -78,9 +78,7 @@ const StyledHeadingBackButton = (0, _styledComponents.default)(_link.default)`
|
|
|
78
78
|
|
|
79
79
|
&:focus {
|
|
80
80
|
background-color: transparent;
|
|
81
|
-
outline: 3px solid
|
|
82
|
-
theme
|
|
83
|
-
}) => theme.colors.focus};
|
|
81
|
+
outline: 3px solid var(--colorsSemanticFocus500);
|
|
84
82
|
}
|
|
85
83
|
|
|
86
84
|
${_icon2.default} {
|
|
@@ -90,9 +88,6 @@ const StyledHeadingBackButton = (0, _styledComponents.default)(_link.default)`
|
|
|
90
88
|
}
|
|
91
89
|
`;
|
|
92
90
|
exports.StyledHeadingBackButton = StyledHeadingBackButton;
|
|
93
|
-
StyledHeadingBackButton.defaultProps = {
|
|
94
|
-
theme: _base.default
|
|
95
|
-
};
|
|
96
91
|
const StyledHeadingTitle = (0, _styledComponents.default)(_typography.default)`
|
|
97
92
|
line-height: 32px;
|
|
98
93
|
${({
|
|
@@ -127,9 +122,7 @@ const StyledSubHeader = _styledComponents.default.div`
|
|
|
127
122
|
`;
|
|
128
123
|
exports.StyledSubHeader = StyledSubHeader;
|
|
129
124
|
const StyledHeadingIcon = (0, _styledComponents.default)(_icon.default)`
|
|
130
|
-
color:
|
|
131
|
-
theme
|
|
132
|
-
}) => theme.colors.border};
|
|
125
|
+
color: var(--colorsActionMinor500);
|
|
133
126
|
height: 30px;
|
|
134
127
|
|
|
135
128
|
&:before,
|
|
@@ -138,19 +131,12 @@ const StyledHeadingIcon = (0, _styledComponents.default)(_icon.default)`
|
|
|
138
131
|
}
|
|
139
132
|
|
|
140
133
|
&:hover {
|
|
141
|
-
color:
|
|
142
|
-
theme
|
|
143
|
-
}) => theme.icon.focus};
|
|
134
|
+
color: var(--colorsActionMinor600);
|
|
144
135
|
}
|
|
145
136
|
`;
|
|
146
137
|
exports.StyledHeadingIcon = StyledHeadingIcon;
|
|
147
|
-
StyledHeadingIcon.defaultProps = {
|
|
148
|
-
theme: _base.default
|
|
149
|
-
};
|
|
150
138
|
const StyledSeparator = _styledComponents.default.hr`
|
|
151
|
-
border-top: 2px solid
|
|
152
|
-
theme
|
|
153
|
-
}) => theme.palette.slateTint(80)};
|
|
139
|
+
border-top: 2px solid var(--colorsUtilityMajor100);
|
|
154
140
|
margin: 10px 0 8px;
|
|
155
141
|
text-align: left;
|
|
156
142
|
width: 50px;
|
|
@@ -160,9 +146,6 @@ const StyledDivider = (0, _styledComponents.default)(_hr.default)`
|
|
|
160
146
|
margin: 15px 0 20px;
|
|
161
147
|
`;
|
|
162
148
|
exports.StyledDivider = StyledDivider;
|
|
163
|
-
StyledSeparator.defaultProps = {
|
|
164
|
-
theme: _base.default
|
|
165
|
-
};
|
|
166
149
|
const StyledHeaderHelp = (0, _styledComponents.default)(_help.default)`
|
|
167
150
|
display: inline-block;
|
|
168
151
|
margin-left: -6px;
|
|
@@ -17,10 +17,10 @@ var _menuItem = _interopRequireDefault(require("../../menu-item/menu-item.style"
|
|
|
17
17
|
|
|
18
18
|
var _icon = _interopRequireDefault(require("../../../icon/icon.style"));
|
|
19
19
|
|
|
20
|
-
var _scrollableBlock = _interopRequireDefault(require("../../scrollable-block/scrollable-block.style"));
|
|
21
|
-
|
|
22
20
|
var _search = _interopRequireDefault(require("../../../search/search.style"));
|
|
23
21
|
|
|
22
|
+
var _menu2 = _interopRequireDefault(require("../../menu.config"));
|
|
23
|
+
|
|
24
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
25
25
|
|
|
26
26
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -42,15 +42,14 @@ const StyledSubmenuWrapper = _styledComponents.default.div`
|
|
|
42
42
|
${({
|
|
43
43
|
inFullscreenView,
|
|
44
44
|
menuType,
|
|
45
|
-
asPassiveItem
|
|
46
|
-
theme
|
|
45
|
+
asPassiveItem
|
|
47
46
|
}) => inFullscreenView && (0, _styledComponents.css)`
|
|
48
47
|
width: 100%;
|
|
49
48
|
|
|
50
49
|
${asPassiveItem && (0, _styledComponents.css)`
|
|
51
50
|
${_menuItem.default} {
|
|
52
51
|
outline: none;
|
|
53
|
-
color: ${
|
|
52
|
+
color: ${_menu2.default[menuType].title};
|
|
54
53
|
}
|
|
55
54
|
`}
|
|
56
55
|
`}
|
|
@@ -59,16 +58,14 @@ exports.StyledSubmenuWrapper = StyledSubmenuWrapper;
|
|
|
59
58
|
const StyledSubmenu = _styledComponents.default.ul`
|
|
60
59
|
${({
|
|
61
60
|
menuType,
|
|
62
|
-
theme,
|
|
63
61
|
submenuDirection,
|
|
64
62
|
variant,
|
|
65
63
|
inFullscreenView
|
|
66
64
|
}) => (0, _styledComponents.css)`
|
|
67
65
|
${!inFullscreenView && (0, _styledComponents.css)`
|
|
68
|
-
box-shadow:
|
|
69
|
-
0 10px 10px 0 rgba(0, 20, 29, 0.1);
|
|
66
|
+
box-shadow: var(--boxShadow100);
|
|
70
67
|
position: absolute;
|
|
71
|
-
background: ${variant === "default" ?
|
|
68
|
+
background-color: ${variant === "default" ? _menu2.default[menuType].submenuItemBackground : _menu2.default[menuType].background};
|
|
72
69
|
a,
|
|
73
70
|
button,
|
|
74
71
|
${_link.StyledLink} a,
|
|
@@ -93,17 +90,6 @@ const StyledSubmenu = _styledComponents.default.ul`
|
|
|
93
90
|
display: none;
|
|
94
91
|
}
|
|
95
92
|
|
|
96
|
-
.carbon-menu-item--has-link:hover {
|
|
97
|
-
background: ${theme.colors.primary};
|
|
98
|
-
cursor: pointer;
|
|
99
|
-
color: white;
|
|
100
|
-
text-decoration: none;
|
|
101
|
-
|
|
102
|
-
[data-component="icon"] {
|
|
103
|
-
color: white;
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
93
|
${_menuItem.default} {
|
|
108
94
|
display: flex;
|
|
109
95
|
align-items: center;
|
|
@@ -112,13 +98,24 @@ const StyledSubmenu = _styledComponents.default.ul`
|
|
|
112
98
|
white-space: nowrap;
|
|
113
99
|
cursor: pointer;
|
|
114
100
|
|
|
115
|
-
${!inFullscreenView &&
|
|
101
|
+
${!inFullscreenView && (0, _styledComponents.css)`
|
|
102
|
+
background-color: ${_menu2.default[menuType].submenuItemBackground};
|
|
116
103
|
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
104
|
+
a:focus,
|
|
105
|
+
button:focus {
|
|
106
|
+
background-color: ${_menu2.default[menuType].submenuItemBackground};
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
a:hover,
|
|
110
|
+
button:hover {
|
|
111
|
+
background-color: ${_menu2.default[menuType].submenuItemBackgroundHover};
|
|
112
|
+
color: var(--colorsComponentsMenuYang100);
|
|
113
|
+
|
|
114
|
+
[data-component="icon"] {
|
|
115
|
+
color: var(--colorsComponentsMenuYang100);
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
`}
|
|
122
119
|
|
|
123
120
|
a {
|
|
124
121
|
text-decoration: none;
|
|
@@ -131,10 +128,16 @@ const StyledSubmenu = _styledComponents.default.ul`
|
|
|
131
128
|
}
|
|
132
129
|
|
|
133
130
|
${_search.default} span > [data-component="icon"] {
|
|
134
|
-
color:
|
|
131
|
+
color: var(--colorsUtilityMajor200);
|
|
135
132
|
|
|
136
133
|
&:hover {
|
|
137
|
-
color:
|
|
134
|
+
color: var(--colorsUtilityMajor150);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
${_search.default} {
|
|
139
|
+
:hover {
|
|
140
|
+
border-bottom-color: var(--colorsUtilityMajor150);
|
|
138
141
|
}
|
|
139
142
|
}
|
|
140
143
|
}
|
|
@@ -167,24 +170,12 @@ const StyledSubmenu = _styledComponents.default.ul`
|
|
|
167
170
|
width: 100%;
|
|
168
171
|
}
|
|
169
172
|
|
|
170
|
-
> *:not(${_menu.StyledMenuItem}):not(${_scrollableBlock.default}) {
|
|
171
|
-
padding: 8px 15px 10px;
|
|
172
|
-
background-color: ${theme.colors.white};
|
|
173
|
-
|
|
174
|
-
${menuType === "dark" && (0, _styledComponents.css)`
|
|
175
|
-
background-color: #1b1d21;
|
|
176
|
-
`}
|
|
177
|
-
}
|
|
178
|
-
|
|
179
173
|
${submenuDirection === "left" && (0, _styledComponents.css)`
|
|
180
174
|
right: 0;
|
|
181
175
|
`}
|
|
182
176
|
`}
|
|
183
177
|
`;
|
|
184
178
|
exports.StyledSubmenu = StyledSubmenu;
|
|
185
|
-
StyledSubmenu.defaultProps = {
|
|
186
|
-
theme: _themes.baseTheme
|
|
187
|
-
};
|
|
188
179
|
StyledSubmenuWrapper.defaultProps = {
|
|
189
180
|
theme: _themes.baseTheme
|
|
190
181
|
};
|
|
@@ -7,7 +7,9 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
13
|
|
|
12
14
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
13
15
|
|
|
@@ -17,16 +19,12 @@ const StyledDivider = _styledComponents.default.div`
|
|
|
17
19
|
cursor: default;
|
|
18
20
|
${({
|
|
19
21
|
menuType,
|
|
20
|
-
theme,
|
|
21
22
|
size
|
|
22
23
|
}) => (0, _styledComponents.css)`
|
|
23
24
|
margin: 0px ${size === "large" ? "" : "16px"};
|
|
24
25
|
height: ${size === "large" ? "4px" : "1px"};
|
|
25
|
-
background: ${
|
|
26
|
+
background-color: ${_menu.default[menuType].divider};
|
|
26
27
|
`}
|
|
27
28
|
`;
|
|
28
|
-
StyledDivider.defaultProps = {
|
|
29
|
-
theme: _themes.baseTheme
|
|
30
|
-
};
|
|
31
29
|
var _default = StyledDivider;
|
|
32
30
|
exports.default = _default;
|
|
@@ -19,6 +19,8 @@ var _icon = _interopRequireDefault(require("../../icon/icon.style"));
|
|
|
19
19
|
|
|
20
20
|
var _button = _interopRequireDefault(require("../../button/button.style"));
|
|
21
21
|
|
|
22
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
23
|
+
|
|
22
24
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
25
|
|
|
24
26
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -44,25 +46,25 @@ const StyledMenuFullscreen = _styledComponents.default.div`
|
|
|
44
46
|
startPosition,
|
|
45
47
|
theme
|
|
46
48
|
}) => (0, _styledComponents.css)`
|
|
47
|
-
background-color: ${
|
|
49
|
+
background-color: ${_menu.default[menuType].background};
|
|
48
50
|
z-index: ${theme.zIndex.fullScreenModal};
|
|
49
51
|
|
|
50
52
|
${menuType === "dark" && (0, _styledComponents.css)`
|
|
51
53
|
${_search.default} span > [data-component="icon"] {
|
|
52
|
-
color:
|
|
54
|
+
color: var(--colorsUtilityMajor200);
|
|
53
55
|
|
|
54
56
|
&:hover {
|
|
55
|
-
color:
|
|
57
|
+
color: var(--colorsUtilityMajor150);
|
|
56
58
|
}
|
|
57
59
|
}
|
|
58
60
|
`}
|
|
59
61
|
|
|
60
62
|
${menuType === "light" && (0, _styledComponents.css)`
|
|
61
63
|
${_search.default} span > [data-component="icon"] {
|
|
62
|
-
color:
|
|
64
|
+
color: var(--colorsUtilityMajor200);
|
|
63
65
|
|
|
64
66
|
&:hover {
|
|
65
|
-
color:
|
|
67
|
+
color: var(--colorsUtilityMajor400);
|
|
66
68
|
}
|
|
67
69
|
}
|
|
68
70
|
`}
|
|
@@ -117,16 +119,12 @@ const StyledMenuFullscreenHeader = _styledComponents.default.div`
|
|
|
117
119
|
}
|
|
118
120
|
|
|
119
121
|
${({
|
|
120
|
-
menuType
|
|
121
|
-
theme
|
|
122
|
+
menuType
|
|
122
123
|
}) => (0, _styledComponents.css)`
|
|
123
|
-
background-color: ${
|
|
124
|
+
background-color: ${_menu.default[menuType].submenuItemBackground};
|
|
124
125
|
`}
|
|
125
126
|
`;
|
|
126
127
|
exports.StyledMenuFullscreenHeader = StyledMenuFullscreenHeader;
|
|
127
128
|
StyledMenuFullscreen.defaultProps = {
|
|
128
129
|
theme: _themes.baseTheme
|
|
129
|
-
};
|
|
130
|
-
StyledMenuFullscreenHeader.defaultProps = {
|
|
131
|
-
theme: _themes.baseTheme
|
|
132
130
|
};
|
|
@@ -7,12 +7,12 @@ 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
|
var _link = require("../../link/link.style");
|
|
13
11
|
|
|
14
12
|
var _icon = _interopRequireDefault(require("../../icon/icon.style"));
|
|
15
13
|
|
|
14
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
15
|
+
|
|
16
16
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
17
17
|
|
|
18
18
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -22,7 +22,6 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
22
22
|
const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
23
23
|
${({
|
|
24
24
|
menuType,
|
|
25
|
-
theme,
|
|
26
25
|
selected,
|
|
27
26
|
hasSubmenu,
|
|
28
27
|
isOpen,
|
|
@@ -41,7 +40,7 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
41
40
|
height: 40px;
|
|
42
41
|
position: relative;
|
|
43
42
|
cursor: pointer;
|
|
44
|
-
background-color: ${
|
|
43
|
+
background-color: ${_menu.default[menuType].background};
|
|
45
44
|
|
|
46
45
|
${!inFullscreenView && (0, _styledComponents.css)`
|
|
47
46
|
max-width: inherit;
|
|
@@ -57,21 +56,27 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
57
56
|
vertical-align: bottom;
|
|
58
57
|
`}
|
|
59
58
|
}
|
|
60
|
-
`}
|
|
61
59
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
[data-component="icon"] {
|
|
72
|
-
color: ${theme.colors.white};
|
|
60
|
+
a:focus,
|
|
61
|
+
button:focus {
|
|
62
|
+
box-shadow: inset 0 0 0 var(--borderWidth300)
|
|
63
|
+
var(--colorsSemanticFocus500);
|
|
64
|
+
background-color: ${_menu.default[menuType].background};
|
|
65
|
+
color: ${_menu.default[menuType].color};
|
|
66
|
+
z-index: 1;
|
|
67
|
+
position: relative;
|
|
73
68
|
}
|
|
74
|
-
|
|
69
|
+
|
|
70
|
+
a:hover,
|
|
71
|
+
button:hover {
|
|
72
|
+
background-color: var(--colorsComponentsMenuAutumnStandard600);
|
|
73
|
+
color: var(--colorsComponentsMenuYang100);
|
|
74
|
+
|
|
75
|
+
[data-component="icon"] {
|
|
76
|
+
color: var(--colorsComponentsMenuYang100);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
`}
|
|
75
80
|
|
|
76
81
|
a,
|
|
77
82
|
${_link.StyledLink} a,
|
|
@@ -96,86 +101,93 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
96
101
|
${_link.StyledLink} [data-component="icon"] {
|
|
97
102
|
font-weight: 700;
|
|
98
103
|
text-decoration: none;
|
|
99
|
-
color: ${
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
a:hover,
|
|
103
|
-
a:focus,
|
|
104
|
-
button:hover,
|
|
105
|
-
button:focus {
|
|
106
|
-
color: ${theme.colors.white};
|
|
107
|
-
background: transparent;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
a:focus,
|
|
111
|
-
button:focus,
|
|
112
|
-
${_link.StyledLink} a:focus,
|
|
113
|
-
${_link.StyledLink} button:focus {
|
|
114
|
-
color: ${theme.colors.white};
|
|
115
|
-
box-shadow: inset 0 0 0 2px ${theme.colors.focus};
|
|
116
|
-
background: ${theme.colors.primary};
|
|
117
|
-
z-index: 1;
|
|
118
|
-
position: relative;
|
|
104
|
+
color: ${_menu.default[menuType].color};
|
|
119
105
|
}
|
|
120
106
|
|
|
121
107
|
${_icon.default} {
|
|
122
108
|
bottom: 1px;
|
|
123
109
|
}
|
|
124
110
|
|
|
125
|
-
|
|
126
|
-
background: ${
|
|
111
|
+
${selected && (0, _styledComponents.css)`
|
|
112
|
+
background-color: ${_menu.default[menuType].selected};
|
|
127
113
|
|
|
128
|
-
a,
|
|
129
|
-
button
|
|
130
|
-
|
|
131
|
-
color: ${theme.colors.white};
|
|
114
|
+
a:focus,
|
|
115
|
+
button:focus {
|
|
116
|
+
background-color: ${_menu.default[menuType].selected};
|
|
132
117
|
}
|
|
133
|
-
}
|
|
134
118
|
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
background-color:
|
|
119
|
+
a:hover,
|
|
120
|
+
button:hover {
|
|
121
|
+
background-color: var(--colorsComponentsMenuAutumnStandard600);
|
|
138
122
|
}
|
|
139
123
|
`}
|
|
140
124
|
|
|
141
|
-
${
|
|
142
|
-
|
|
125
|
+
${variant === "alternate" && !inFullscreenView && (0, _styledComponents.css)`
|
|
126
|
+
&&& {
|
|
127
|
+
background-color: ${_menu.default[menuType].alternate};
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
&&& a:focus,
|
|
131
|
+
&&& button:focus {
|
|
132
|
+
background-color: ${_menu.default[menuType].alternate};
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
&&& a:hover,
|
|
136
|
+
&&& button:hover {
|
|
137
|
+
background-color: ${_menu.default[menuType].alternateHover};
|
|
138
|
+
}
|
|
143
139
|
`}
|
|
144
140
|
|
|
145
141
|
${isOpen && (0, _styledComponents.css)`
|
|
146
|
-
|
|
147
|
-
|
|
142
|
+
a,
|
|
143
|
+
button {
|
|
144
|
+
background-color: ${_menu.default[menuType].submenuOpenedBackground};
|
|
145
|
+
color: ${_menu.default[menuType].color};
|
|
146
|
+
}
|
|
148
147
|
`}
|
|
149
148
|
|
|
150
149
|
${hasSubmenu && (0, _styledComponents.css)`
|
|
150
|
+
background-color: ${_menu.default[menuType].submenuBackground};
|
|
151
|
+
|
|
152
|
+
a:focus,
|
|
153
|
+
button:focus {
|
|
154
|
+
background-color: ${_menu.default[menuType].submenuBackground};
|
|
155
|
+
color: ${_menu.default[menuType].color};
|
|
156
|
+
|
|
157
|
+
[data-component="icon"] {
|
|
158
|
+
color: ${_menu.default[menuType].color};
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
${clickToOpen && isOpen && (0, _styledComponents.css)`
|
|
162
|
+
background-color: ${_menu.default[menuType].submenuOpenedBackground};
|
|
163
|
+
`}
|
|
164
|
+
}
|
|
165
|
+
|
|
151
166
|
a:hover,
|
|
152
167
|
button:hover {
|
|
153
168
|
${!(href || clickToOpen) && (0, _styledComponents.css)`
|
|
154
169
|
cursor: default;
|
|
155
170
|
`}
|
|
171
|
+
background-color: ${_menu.default[menuType].submenuOpenedBackground};
|
|
172
|
+
color: ${_menu.default[menuType].color};
|
|
173
|
+
|
|
174
|
+
[data-component="icon"] {
|
|
175
|
+
color: ${_menu.default[menuType].color};
|
|
176
|
+
}
|
|
156
177
|
}
|
|
157
178
|
|
|
158
|
-
${
|
|
159
|
-
|
|
160
|
-
&& button:hover {
|
|
161
|
-
background-color: ${theme.menu[menuType].submenuBackground};
|
|
162
|
-
color: ${theme.menu[menuType].text};
|
|
179
|
+
${selected && (0, _styledComponents.css)`
|
|
180
|
+
background-color: ${_menu.default[menuType].submenuSelected};
|
|
163
181
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
}
|
|
182
|
+
a:focus,
|
|
183
|
+
button:focus {
|
|
184
|
+
background-color: ${_menu.default[menuType].submenuSelected};
|
|
167
185
|
}
|
|
168
186
|
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
background-color:
|
|
172
|
-
color:
|
|
173
|
-
|
|
174
|
-
a,
|
|
175
|
-
button,
|
|
176
|
-
[data-component="icon"] {
|
|
177
|
-
color: ${theme.menu[menuType].text};
|
|
178
|
-
}
|
|
187
|
+
a:hover,
|
|
188
|
+
button:hover {
|
|
189
|
+
background-color: var(--colorsComponentsMenuAutumnStandard600);
|
|
190
|
+
color: var(--colorsComponentsMenuYang100);
|
|
179
191
|
}
|
|
180
192
|
`}
|
|
181
193
|
|
|
@@ -183,13 +195,6 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
183
195
|
> a,
|
|
184
196
|
> button {
|
|
185
197
|
padding-right: 32px;
|
|
186
|
-
|
|
187
|
-
${href && (0, _styledComponents.css)`
|
|
188
|
-
&:hover::before,
|
|
189
|
-
&:focus::before {
|
|
190
|
-
border-top-color: ${theme.colors.white};
|
|
191
|
-
}
|
|
192
|
-
`}
|
|
193
198
|
}
|
|
194
199
|
|
|
195
200
|
a::before,
|
|
@@ -204,7 +209,7 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
204
209
|
content: "";
|
|
205
210
|
width: 0;
|
|
206
211
|
height: 0;
|
|
207
|
-
border-top: 5px solid ${
|
|
212
|
+
border-top: 5px solid ${_menu.default[menuType].text};
|
|
208
213
|
border-right: 4px solid transparent;
|
|
209
214
|
border-bottom: 4px solid transparent;
|
|
210
215
|
border-left: 4px solid transparent;
|
|
@@ -225,11 +230,36 @@ const StyledMenuItemWrapper = _styledComponents.default.a`
|
|
|
225
230
|
background: transparent;
|
|
226
231
|
}
|
|
227
232
|
`}
|
|
233
|
+
|
|
234
|
+
a,
|
|
235
|
+
${_link.StyledLink} a,
|
|
236
|
+
button,
|
|
237
|
+
${_link.StyledLink} button {
|
|
238
|
+
width: 100vw;
|
|
239
|
+
box-sizing: border-box;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
a:focus,
|
|
243
|
+
button:focus {
|
|
244
|
+
box-shadow: inset 0 0 0 var(--borderWidth300)
|
|
245
|
+
var(--colorsSemanticFocus500);
|
|
246
|
+
z-index: 1;
|
|
247
|
+
position: relative;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
a:focus,
|
|
251
|
+
a:hover,
|
|
252
|
+
button:focus,
|
|
253
|
+
button:hover {
|
|
254
|
+
background-color: var(--colorsComponentsMenuAutumnStandard600);
|
|
255
|
+
color: var(--colorsComponentsMenuYang100);
|
|
256
|
+
|
|
257
|
+
[data-component="icon"] {
|
|
258
|
+
color: var(--colorsComponentsMenuYang100);
|
|
259
|
+
}
|
|
260
|
+
}
|
|
228
261
|
`}
|
|
229
262
|
`}
|
|
230
263
|
`;
|
|
231
|
-
StyledMenuItemWrapper.defaultProps = {
|
|
232
|
-
theme: _themes.baseTheme
|
|
233
|
-
};
|
|
234
264
|
var _default = StyledMenuItemWrapper;
|
|
235
265
|
exports.default = _default;
|
|
@@ -7,7 +7,9 @@ exports.default = void 0;
|
|
|
7
7
|
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
11
|
+
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
11
13
|
|
|
12
14
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
13
15
|
|
|
@@ -16,7 +18,6 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
16
18
|
const StyledTitle = _styledComponents.default.div`
|
|
17
19
|
${({
|
|
18
20
|
menuType,
|
|
19
|
-
theme,
|
|
20
21
|
variant
|
|
21
22
|
}) => (0, _styledComponents.css)`
|
|
22
23
|
padding: 16px 16px 8px;
|
|
@@ -25,12 +26,9 @@ const StyledTitle = _styledComponents.default.div`
|
|
|
25
26
|
text-transform: uppercase;
|
|
26
27
|
line-height: 12px;
|
|
27
28
|
cursor: default;
|
|
28
|
-
color: ${
|
|
29
|
-
${variant === "alternate"
|
|
29
|
+
color: ${_menu.default[menuType].title};
|
|
30
|
+
${variant === "alternate" && `background-color: ${_menu.default[menuType].alternate};`};
|
|
30
31
|
`}
|
|
31
32
|
`;
|
|
32
|
-
StyledTitle.defaultProps = {
|
|
33
|
-
theme: _themes.baseTheme
|
|
34
|
-
};
|
|
35
33
|
var _default = StyledTitle;
|
|
36
34
|
exports.default = _default;
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
namespace light {
|
|
3
|
+
const background: string;
|
|
4
|
+
const color: string;
|
|
5
|
+
const selected: string;
|
|
6
|
+
const submenuOpenedBackground: string;
|
|
7
|
+
const submenuBackground: string;
|
|
8
|
+
const submenuSelected: string;
|
|
9
|
+
const submenuItemBackground: string;
|
|
10
|
+
const submenuItemBackgroundHover: string;
|
|
11
|
+
const title: string;
|
|
12
|
+
const alternate: string;
|
|
13
|
+
const alternateHover: string;
|
|
14
|
+
const divider: string;
|
|
15
|
+
}
|
|
16
|
+
namespace dark {
|
|
17
|
+
const background_1: string;
|
|
18
|
+
export { background_1 as background };
|
|
19
|
+
const color_1: string;
|
|
20
|
+
export { color_1 as color };
|
|
21
|
+
const selected_1: string;
|
|
22
|
+
export { selected_1 as selected };
|
|
23
|
+
const submenuOpenedBackground_1: string;
|
|
24
|
+
export { submenuOpenedBackground_1 as submenuOpenedBackground };
|
|
25
|
+
const submenuBackground_1: string;
|
|
26
|
+
export { submenuBackground_1 as submenuBackground };
|
|
27
|
+
const submenuSelected_1: string;
|
|
28
|
+
export { submenuSelected_1 as submenuSelected };
|
|
29
|
+
const submenuItemBackground_1: string;
|
|
30
|
+
export { submenuItemBackground_1 as submenuItemBackground };
|
|
31
|
+
const submenuItemBackgroundHover_1: string;
|
|
32
|
+
export { submenuItemBackgroundHover_1 as submenuItemBackgroundHover };
|
|
33
|
+
const title_1: string;
|
|
34
|
+
export { title_1 as title };
|
|
35
|
+
const alternate_1: string;
|
|
36
|
+
export { alternate_1 as alternate };
|
|
37
|
+
const alternateHover_1: string;
|
|
38
|
+
export { alternateHover_1 as alternateHover };
|
|
39
|
+
const divider_1: string;
|
|
40
|
+
export { divider_1 as divider };
|
|
41
|
+
}
|
|
42
|
+
namespace black {
|
|
43
|
+
const background_2: string;
|
|
44
|
+
export { background_2 as background };
|
|
45
|
+
const color_2: string;
|
|
46
|
+
export { color_2 as color };
|
|
47
|
+
const selected_2: string;
|
|
48
|
+
export { selected_2 as selected };
|
|
49
|
+
const submenuOpenedBackground_2: string;
|
|
50
|
+
export { submenuOpenedBackground_2 as submenuOpenedBackground };
|
|
51
|
+
const submenuBackground_2: string;
|
|
52
|
+
export { submenuBackground_2 as submenuBackground };
|
|
53
|
+
const submenuSelected_2: string;
|
|
54
|
+
export { submenuSelected_2 as submenuSelected };
|
|
55
|
+
const submenuItemBackground_2: string;
|
|
56
|
+
export { submenuItemBackground_2 as submenuItemBackground };
|
|
57
|
+
const submenuItemBackgroundHover_2: string;
|
|
58
|
+
export { submenuItemBackgroundHover_2 as submenuItemBackgroundHover };
|
|
59
|
+
const title_2: string;
|
|
60
|
+
export { title_2 as title };
|
|
61
|
+
const alternate_2: string;
|
|
62
|
+
export { alternate_2 as alternate };
|
|
63
|
+
const alternateHover_2: string;
|
|
64
|
+
export { alternateHover_2 as alternateHover };
|
|
65
|
+
const divider_2: string;
|
|
66
|
+
export { divider_2 as divider };
|
|
67
|
+
}
|
|
68
|
+
namespace white {
|
|
69
|
+
const background_3: string;
|
|
70
|
+
export { background_3 as background };
|
|
71
|
+
const color_3: string;
|
|
72
|
+
export { color_3 as color };
|
|
73
|
+
const selected_3: string;
|
|
74
|
+
export { selected_3 as selected };
|
|
75
|
+
const submenuOpenedBackground_3: string;
|
|
76
|
+
export { submenuOpenedBackground_3 as submenuOpenedBackground };
|
|
77
|
+
const submenuBackground_3: string;
|
|
78
|
+
export { submenuBackground_3 as submenuBackground };
|
|
79
|
+
const submenuSelected_3: string;
|
|
80
|
+
export { submenuSelected_3 as submenuSelected };
|
|
81
|
+
const submenuItemBackground_3: string;
|
|
82
|
+
export { submenuItemBackground_3 as submenuItemBackground };
|
|
83
|
+
const submenuItemBackgroundHover_3: string;
|
|
84
|
+
export { submenuItemBackgroundHover_3 as submenuItemBackgroundHover };
|
|
85
|
+
const title_3: string;
|
|
86
|
+
export { title_3 as title };
|
|
87
|
+
const alternate_3: string;
|
|
88
|
+
export { alternate_3 as alternate };
|
|
89
|
+
const alternateHover_3: string;
|
|
90
|
+
export { alternateHover_3 as alternateHover };
|
|
91
|
+
const divider_3: string;
|
|
92
|
+
export { divider_3 as divider };
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
export default _default;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _default = {
|
|
8
|
+
light: {
|
|
9
|
+
background: "var(--colorsComponentsMenuSpringStandard500)",
|
|
10
|
+
color: "var(--colorsComponentsMenuYin090)",
|
|
11
|
+
selected: "var(--colorsComponentsMenuSpringStandard700)",
|
|
12
|
+
submenuOpenedBackground: "var(--colorsComponentsMenuSpringParent600)",
|
|
13
|
+
submenuBackground: "var(--colorsComponentsMenuSpringParent500)",
|
|
14
|
+
submenuSelected: "var(--colorsComponentsMenuSpringParent700)",
|
|
15
|
+
submenuItemBackground: "var(--colorsComponentsMenuSpringChild500)",
|
|
16
|
+
submenuItemBackgroundHover: "var(--colorsComponentsMenuSpringChild600)",
|
|
17
|
+
title: "var(--colorsComponentsMenuYin065)",
|
|
18
|
+
alternate: "var(--colorsComponentsMenuSpringChildAlt500)",
|
|
19
|
+
alternateHover: "var(--colorsComponentsMenuSpringChildAlt600)",
|
|
20
|
+
divider: "var(--colorsComponentsMenuSpringChild400)"
|
|
21
|
+
},
|
|
22
|
+
dark: {
|
|
23
|
+
background: "var(--colorsComponentsMenuAutumnStandard500)",
|
|
24
|
+
color: "var(--colorsComponentsMenuYang100)",
|
|
25
|
+
selected: "var(--colorsComponentsMenuAutumnStandard700)",
|
|
26
|
+
submenuOpenedBackground: "var(--colorsComponentsMenuAutumnParent600)",
|
|
27
|
+
submenuBackground: "var(--colorsComponentsMenuAutumnParent500)",
|
|
28
|
+
submenuSelected: "var(--colorsComponentsMenuAutumnParent700)",
|
|
29
|
+
submenuItemBackground: "var(--colorsComponentsMenuAutumnChild500)",
|
|
30
|
+
submenuItemBackgroundHover: "var(--colorsComponentsMenuAutumnChild600)",
|
|
31
|
+
title: "var(--colorsComponentsMenuYang080)",
|
|
32
|
+
alternate: "var(--colorsComponentsMenuAutumnChildAlt500)",
|
|
33
|
+
alternateHover: "var(--colorsComponentsMenuAutumnChildAlt600)",
|
|
34
|
+
divider: "var(--colorsComponentsMenuAutumnChild400)"
|
|
35
|
+
},
|
|
36
|
+
black: {
|
|
37
|
+
background: "var(--colorsComponentsMenuWinterStandard500)",
|
|
38
|
+
color: "var(--colorsComponentsMenuYang100)",
|
|
39
|
+
selected: "var(--colorsComponentsMenuWinterStandard700)",
|
|
40
|
+
submenuOpenedBackground: "var(--colorsComponentsMenuWinterParent600)",
|
|
41
|
+
submenuBackground: "var(--colorsComponentsMenuWinterParent500)",
|
|
42
|
+
submenuSelected: "var(--colorsComponentsMenuWinterParent700)",
|
|
43
|
+
submenuItemBackground: "var(--colorsComponentsMenuWinterChild500)",
|
|
44
|
+
submenuItemBackgroundHover: "var(--colorsComponentsMenuWinterChild600)",
|
|
45
|
+
title: "var(--colorsComponentsMenuYang080)",
|
|
46
|
+
alternate: "var(--colorsComponentsMenuWinterChildAlt500)",
|
|
47
|
+
alternateHover: "var(--colorsComponentsMenuWinterChildAlt600)",
|
|
48
|
+
divider: "var(--colorsComponentsMenuWinterChild400)"
|
|
49
|
+
},
|
|
50
|
+
white: {
|
|
51
|
+
background: "var(--colorsComponentsMenuSummerStandard500)",
|
|
52
|
+
color: "var(--colorsComponentsMenuYin090)",
|
|
53
|
+
selected: "var(--colorsComponentsMenuSummerStandard700)",
|
|
54
|
+
submenuOpenedBackground: "var(--colorsComponentsMenuSummerParent600)",
|
|
55
|
+
submenuBackground: "var(--colorsComponentsMenuSummerParent500)",
|
|
56
|
+
submenuSelected: "var(--colorsComponentsMenuSummerParent700)",
|
|
57
|
+
submenuItemBackground: "var(--colorsComponentsMenuSummerChild500)",
|
|
58
|
+
submenuItemBackgroundHover: "var(--colorsComponentsMenuSummerChild600)",
|
|
59
|
+
title: "var(--colorsComponentsMenuYin065)",
|
|
60
|
+
alternate: "var(--colorsComponentsMenuSummerChildAlt500)",
|
|
61
|
+
alternateHover: "var(--colorsComponentsMenuSummerChildAlt600)",
|
|
62
|
+
divider: "var(--colorsComponentsMenuSummerChild400)"
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
exports.default = _default;
|
|
@@ -9,12 +9,14 @@ var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
|
9
9
|
|
|
10
10
|
var _styledSystem = require("styled-system");
|
|
11
11
|
|
|
12
|
-
var
|
|
12
|
+
var _menu = _interopRequireDefault(require("./menu.config"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _verticalDivider = require("../vertical-divider/vertical-divider.style");
|
|
15
15
|
|
|
16
16
|
var _link = require("../link/link.style");
|
|
17
17
|
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
|
+
|
|
18
20
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
19
21
|
|
|
20
22
|
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; }
|
|
@@ -31,15 +33,14 @@ const StyledMenuWrapper = _styledComponents.default.ul`
|
|
|
31
33
|
|
|
32
34
|
${_verticalDivider.StyledVerticalWrapper} {
|
|
33
35
|
${({
|
|
34
|
-
menuType
|
|
35
|
-
theme
|
|
36
|
+
menuType
|
|
36
37
|
}) => (0, _styledComponents.css)`
|
|
37
38
|
display: inline-block;
|
|
38
39
|
vertical-align: bottom;
|
|
39
|
-
background-color: ${
|
|
40
|
+
background-color: ${_menu.default[menuType].background};
|
|
40
41
|
|
|
41
42
|
${menuType === "dark" && (0, _styledComponents.css)`
|
|
42
|
-
color: ${
|
|
43
|
+
color: ${_menu.default[menuType].color};
|
|
43
44
|
`}
|
|
44
45
|
`}
|
|
45
46
|
|
|
@@ -80,7 +81,4 @@ const StyledMenuItem = _styledComponents.default.li`
|
|
|
80
81
|
}
|
|
81
82
|
`}
|
|
82
83
|
`;
|
|
83
|
-
exports.StyledMenuItem = StyledMenuItem;
|
|
84
|
-
StyledMenuWrapper.defaultProps = {
|
|
85
|
-
theme: _themes.baseTheme
|
|
86
|
-
};
|
|
84
|
+
exports.StyledMenuItem = StyledMenuItem;
|
|
@@ -7,10 +7,10 @@ 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
|
var _menuItem = _interopRequireDefault(require("../menu-item/menu-item.style"));
|
|
13
11
|
|
|
12
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
13
|
+
|
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
15
|
|
|
16
16
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -20,16 +20,12 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
20
20
|
const StyledScrollableBlock = _styledComponents.default.div`
|
|
21
21
|
${({
|
|
22
22
|
menuType,
|
|
23
|
-
variant
|
|
24
|
-
theme
|
|
23
|
+
variant
|
|
25
24
|
}) => (0, _styledComponents.css)`
|
|
26
25
|
&& ${_menuItem.default} {
|
|
27
|
-
background-color: ${variant === "default" ?
|
|
26
|
+
background-color: ${variant === "default" ? _menu.default[menuType].submenuItemBackground : _menu.default[menuType].background};
|
|
28
27
|
}
|
|
29
28
|
`}
|
|
30
29
|
`;
|
|
31
|
-
StyledScrollableBlock.defaultProps = {
|
|
32
|
-
theme: _themes.baseTheme
|
|
33
|
-
};
|
|
34
30
|
var _default = StyledScrollableBlock;
|
|
35
31
|
exports.default = _default;
|
|
@@ -7,10 +7,10 @@ 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
|
var _menuItem = _interopRequireDefault(require("../menu-item/menu-item.style"));
|
|
13
11
|
|
|
12
|
+
var _menu = _interopRequireDefault(require("../menu.config"));
|
|
13
|
+
|
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
15
|
|
|
16
16
|
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new WeakMap(); _getRequireWildcardCache = function () { return cache; }; return cache; }
|
|
@@ -20,18 +20,14 @@ function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj;
|
|
|
20
20
|
const StyledSubmenuBlock = _styledComponents.default.div`
|
|
21
21
|
${({
|
|
22
22
|
menuType,
|
|
23
|
-
theme,
|
|
24
23
|
variant
|
|
25
24
|
}) => (0, _styledComponents.css)`
|
|
26
|
-
background-color: ${
|
|
25
|
+
background-color: ${_menu.default[menuType].submenuItemBackground};
|
|
27
26
|
|
|
28
27
|
${_menuItem.default} {
|
|
29
|
-
background-color: ${variant === "default" ? "transparent" :
|
|
28
|
+
background-color: ${variant === "default" ? "transparent" : _menu.default[menuType].alternate};
|
|
30
29
|
}
|
|
31
30
|
`}
|
|
32
31
|
`;
|
|
33
|
-
StyledSubmenuBlock.defaultProps = {
|
|
34
|
-
theme: _themes.baseTheme
|
|
35
|
-
};
|
|
36
32
|
var _default = StyledSubmenuBlock;
|
|
37
33
|
exports.default = _default;
|
|
@@ -18,6 +18,15 @@ declare function _default(palette: any): {
|
|
|
18
18
|
colorsActionMajor500: any;
|
|
19
19
|
colorsActionMajor600: any;
|
|
20
20
|
colorsActionMajor150: any;
|
|
21
|
+
colorsComponentsMenuAutumnStandard600: any;
|
|
22
|
+
colorsComponentsMenuSpringChild600: any;
|
|
23
|
+
colorsComponentsMenuAutumnChild600: any;
|
|
24
|
+
colorsComponentsMenuSummerChild600: any;
|
|
25
|
+
colorsComponentsMenuWinterChild600: any;
|
|
26
|
+
colorsComponentsMenuSpringChildAlt600: any;
|
|
27
|
+
colorsComponentsMenuAutumnChildAlt600: any;
|
|
28
|
+
colorsComponentsMenuWinterChildAlt600: any;
|
|
29
|
+
colorsComponentsMenuSummerChildAlt600: any;
|
|
21
30
|
colorsBaseTheme: any;
|
|
22
31
|
};
|
|
23
32
|
};
|
|
@@ -33,6 +33,15 @@ var _default = palette => {
|
|
|
33
33
|
colorsActionMajor500: this.colors.primary,
|
|
34
34
|
colorsActionMajor600: this.colors.secondary,
|
|
35
35
|
colorsActionMajor150: this.colors.loadingBarBackground,
|
|
36
|
+
colorsComponentsMenuAutumnStandard600: this.colors.primary,
|
|
37
|
+
colorsComponentsMenuSpringChild600: this.colors.primary,
|
|
38
|
+
colorsComponentsMenuAutumnChild600: this.colors.primary,
|
|
39
|
+
colorsComponentsMenuSummerChild600: this.colors.primary,
|
|
40
|
+
colorsComponentsMenuWinterChild600: this.colors.primary,
|
|
41
|
+
colorsComponentsMenuSpringChildAlt600: this.colors.primary,
|
|
42
|
+
colorsComponentsMenuAutumnChildAlt600: this.colors.primary,
|
|
43
|
+
colorsComponentsMenuWinterChildAlt600: this.colors.primary,
|
|
44
|
+
colorsComponentsMenuSummerChildAlt600: this.colors.primary,
|
|
36
45
|
colorsBaseTheme: this.colors.primary
|
|
37
46
|
};
|
|
38
47
|
}
|
|
@@ -17,6 +17,15 @@ declare function _default(palette: any): {
|
|
|
17
17
|
colorsActionMajor500: any;
|
|
18
18
|
colorsActionMajor600: any;
|
|
19
19
|
colorsActionMajor150: any;
|
|
20
|
+
colorsComponentsMenuAutumnStandard600: any;
|
|
21
|
+
colorsComponentsMenuSpringChild600: any;
|
|
22
|
+
colorsComponentsMenuAutumnChild600: any;
|
|
23
|
+
colorsComponentsMenuSummerChild600: any;
|
|
24
|
+
colorsComponentsMenuWinterChild600: any;
|
|
25
|
+
colorsComponentsMenuSpringChildAlt600: any;
|
|
26
|
+
colorsComponentsMenuAutumnChildAlt600: any;
|
|
27
|
+
colorsComponentsMenuWinterChildAlt600: any;
|
|
28
|
+
colorsComponentsMenuSummerChildAlt600: any;
|
|
20
29
|
colorsBaseTheme: any;
|
|
21
30
|
};
|
|
22
31
|
};
|
|
@@ -27,6 +27,15 @@ var _default = palette => {
|
|
|
27
27
|
colorsActionMajor500: this.colors.primary,
|
|
28
28
|
colorsActionMajor600: this.colors.secondary,
|
|
29
29
|
colorsActionMajor150: this.colors.loadingBarBackground,
|
|
30
|
+
colorsComponentsMenuAutumnStandard600: this.colors.primary,
|
|
31
|
+
colorsComponentsMenuSpringChild600: this.colors.primary,
|
|
32
|
+
colorsComponentsMenuAutumnChild600: this.colors.primary,
|
|
33
|
+
colorsComponentsMenuSummerChild600: this.colors.primary,
|
|
34
|
+
colorsComponentsMenuWinterChild600: this.colors.primary,
|
|
35
|
+
colorsComponentsMenuSpringChildAlt600: this.colors.primary,
|
|
36
|
+
colorsComponentsMenuAutumnChildAlt600: this.colors.primary,
|
|
37
|
+
colorsComponentsMenuWinterChildAlt600: this.colors.primary,
|
|
38
|
+
colorsComponentsMenuSummerChildAlt600: this.colors.primary,
|
|
30
39
|
colorsBaseTheme: this.colors.primary
|
|
31
40
|
};
|
|
32
41
|
}
|