@rescui/dropdown-menu 0.9.11 → 0.9.13-RUI-226-Update-card-cn-6e43cc89.60
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/dropdown-menu.js +32 -57
- package/lib/index.css +8 -8
- package/lib/index.p.module.css.js +5 -5
- package/lib/menu-wrapper.js +6 -6
- package/lib/public-api.p.css +16 -10
- package/lib/public-api.pcss +16 -10
- package/package.json +13 -13
package/lib/dropdown-menu.js
CHANGED
|
@@ -1,20 +1,3 @@
|
|
|
1
|
-
import "core-js/modules/es.object.to-string.js";
|
|
2
|
-
import "core-js/modules/web.dom-collections.for-each.js";
|
|
3
|
-
import _Object$keys from "@babel/runtime-corejs3/core-js-stable/object/keys";
|
|
4
|
-
import _Object$getOwnPropertySymbols from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-symbols";
|
|
5
|
-
import _filterInstanceProperty from "@babel/runtime-corejs3/core-js-stable/instance/filter";
|
|
6
|
-
import _Object$getOwnPropertyDescriptor from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptor";
|
|
7
|
-
import _Object$getOwnPropertyDescriptors from "@babel/runtime-corejs3/core-js-stable/object/get-own-property-descriptors";
|
|
8
|
-
import _defineProperty from "@babel/runtime-corejs3/helpers/esm/defineProperty";
|
|
9
|
-
import _slicedToArray from "@babel/runtime-corejs3/helpers/esm/slicedToArray";
|
|
10
|
-
import _objectWithoutProperties from "@babel/runtime-corejs3/helpers/esm/objectWithoutProperties";
|
|
11
|
-
var _excluded = ["maxVisibleItems", "size", "children", "iconPlacement", "itemTag", "tag", "theme", "mode", "activateFirstItemOnOpen", "wrapItemsWithLi", "className"],
|
|
12
|
-
_excluded2 = ["maxHeight", "leastMaxHeight"];
|
|
13
|
-
|
|
14
|
-
function ownKeys(object, enumerableOnly) { var keys = _Object$keys(object); if (_Object$getOwnPropertySymbols) { var symbols = _Object$getOwnPropertySymbols(object); enumerableOnly && (symbols = _filterInstanceProperty(symbols).call(symbols, function (sym) { return _Object$getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
15
|
-
|
|
16
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : _Object$getOwnPropertyDescriptors ? Object.defineProperties(target, _Object$getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, _Object$getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
17
|
-
|
|
18
1
|
import React, { useRef, useState } from 'react';
|
|
19
2
|
import { useThemeWithUndefined } from '@rescui/ui-contexts';
|
|
20
3
|
import { Dropdown } from '@rescui/dropdown';
|
|
@@ -22,43 +5,35 @@ import { Menu } from '@rescui/menu';
|
|
|
22
5
|
import cn from 'classnames';
|
|
23
6
|
import { MenuWrapper } from './menu-wrapper.js';
|
|
24
7
|
import styles from './index.p.module.css.js';
|
|
25
|
-
|
|
8
|
+
const ITEM_HEIGHT_BY_SIZE = {
|
|
26
9
|
s: 32,
|
|
27
10
|
m: 40,
|
|
28
11
|
l: 52
|
|
29
12
|
};
|
|
30
|
-
|
|
13
|
+
const SIZE_TO_CLASS = {
|
|
31
14
|
s: styles.sizeS,
|
|
32
15
|
m: styles.sizeM,
|
|
33
16
|
l: styles.sizeL
|
|
34
17
|
};
|
|
35
18
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
var menuWrapperRef = useRef(null);
|
|
55
|
-
|
|
56
|
-
var _useState = useState(0),
|
|
57
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
58
|
-
height = _useState2[0],
|
|
59
|
-
setHeight = _useState2[1];
|
|
60
|
-
|
|
61
|
-
var itemHeightFromCss = null;
|
|
19
|
+
const DropdownMenu = _ref => {
|
|
20
|
+
let {
|
|
21
|
+
maxVisibleItems = 5,
|
|
22
|
+
size = 'm',
|
|
23
|
+
children,
|
|
24
|
+
iconPlacement,
|
|
25
|
+
itemTag,
|
|
26
|
+
tag,
|
|
27
|
+
theme: themeFromProps,
|
|
28
|
+
mode = 'classic',
|
|
29
|
+
activateFirstItemOnOpen = false,
|
|
30
|
+
wrapItemsWithLi,
|
|
31
|
+
className,
|
|
32
|
+
...restProps
|
|
33
|
+
} = _ref;
|
|
34
|
+
const menuWrapperRef = useRef(null);
|
|
35
|
+
const [height, setHeight] = useState(0);
|
|
36
|
+
let itemHeightFromCss = null;
|
|
62
37
|
|
|
63
38
|
if (menuWrapperRef.current) {
|
|
64
39
|
// In theory this part of the code might cause issues with SSR.
|
|
@@ -67,31 +42,31 @@ var DropdownMenu = function DropdownMenu(_ref) {
|
|
|
67
42
|
// Therefore, the first render on the client will be the same as on the server.
|
|
68
43
|
// Also, there will be no layout shifts on the following renders because
|
|
69
44
|
// it's a dropdown-content and in most cases it opens only on-demand
|
|
70
|
-
|
|
45
|
+
const menuWrapperStyles = getComputedStyle(menuWrapperRef.current);
|
|
71
46
|
itemHeightFromCss = parseInt(menuWrapperStyles.getPropertyValue('--_rs-dropdown-menu-item-height'), 10) || null;
|
|
72
47
|
}
|
|
73
48
|
|
|
74
|
-
|
|
49
|
+
const itemHeight = itemHeightFromCss || ITEM_HEIGHT_BY_SIZE[size]; // a little buffer of 10% here
|
|
75
50
|
|
|
76
|
-
|
|
51
|
+
const isMoreThanPlusOne = height > (Math.ceil(maxVisibleItems) + 1.1) * itemHeight; // half of item added to show that there is more items even if scroll bar hidden
|
|
77
52
|
// in case there are only 1 more item than maxVisibleItems, show it without truncating
|
|
78
53
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
54
|
+
const maxHeight = (Math.ceil(maxVisibleItems) + (isMoreThanPlusOne ? 0.5 : 1.5)) * itemHeight;
|
|
55
|
+
const {
|
|
56
|
+
maxHeight: cleanMaxHeight,
|
|
57
|
+
leastMaxHeight,
|
|
58
|
+
...cleanedRestProps
|
|
59
|
+
} = restProps; // cast to make runtime omit
|
|
85
60
|
|
|
86
|
-
|
|
87
|
-
return /*#__PURE__*/React.createElement(Dropdown,
|
|
61
|
+
const theme = useThemeWithUndefined(themeFromProps);
|
|
62
|
+
return /*#__PURE__*/React.createElement(Dropdown, { ...cleanedRestProps,
|
|
88
63
|
closeOnTab: true,
|
|
89
64
|
mode: mode,
|
|
90
65
|
theme: theme,
|
|
91
66
|
leastMaxHeight: itemHeight,
|
|
92
67
|
maxHeight: maxHeight,
|
|
93
68
|
className: cn(SIZE_TO_CLASS[size], styles.dropdownMenu, className)
|
|
94
|
-
}
|
|
69
|
+
}, /*#__PURE__*/React.createElement(MenuWrapper, {
|
|
95
70
|
ref: menuWrapperRef,
|
|
96
71
|
onHeightUpdate: setHeight
|
|
97
72
|
}, /*#__PURE__*/React.createElement(Menu, {
|
package/lib/index.css
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
.
|
|
1
|
+
._sizeS_1vy16ki_8{
|
|
2
2
|
--_rs-dropdown-menu-min-width:316px;
|
|
3
3
|
--_rs-dropdown-menu-max-width:389px;
|
|
4
4
|
}
|
|
5
|
-
.
|
|
5
|
+
._sizeS_1vy16ki_8 [data-rs-internal='dropdown-menu__menu-wrapper']{
|
|
6
6
|
--_rs-dropdown-menu-item-height:32px;
|
|
7
7
|
}
|
|
8
|
-
.
|
|
8
|
+
._sizeM_1vy16ki_11{
|
|
9
9
|
--_rs-dropdown-menu-min-width:316px;
|
|
10
10
|
--_rs-dropdown-menu-max-width:494px;
|
|
11
11
|
}
|
|
12
|
-
.
|
|
12
|
+
._sizeM_1vy16ki_11 [data-rs-internal='dropdown-menu__menu-wrapper']{
|
|
13
13
|
--_rs-dropdown-menu-item-height:40px;
|
|
14
14
|
}
|
|
15
|
-
.
|
|
15
|
+
._sizeL_1vy16ki_14{
|
|
16
16
|
--_rs-dropdown-menu-min-width:316px;
|
|
17
17
|
--_rs-dropdown-menu-max-width:494px;
|
|
18
18
|
}
|
|
19
|
-
.
|
|
19
|
+
._sizeL_1vy16ki_14 [data-rs-internal='dropdown-menu__menu-wrapper']{
|
|
20
20
|
--_rs-dropdown-menu-item-height:52px;
|
|
21
21
|
}
|
|
22
|
-
.
|
|
22
|
+
._dropdownMenu_1vy16ki_18{
|
|
23
23
|
min-width:var(--_rs-dropdown-menu-min-width);
|
|
24
24
|
max-width:var(--_rs-dropdown-menu-max-width);
|
|
25
25
|
}
|
|
26
|
-
.
|
|
26
|
+
._menu_1vy16ki_23{
|
|
27
27
|
margin:0;
|
|
28
28
|
padding:0;
|
|
29
29
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
var styles = {
|
|
2
|
-
"sizeS": "
|
|
3
|
-
"sizeM": "
|
|
4
|
-
"sizeL": "
|
|
5
|
-
"dropdownMenu": "
|
|
6
|
-
"menu": "
|
|
2
|
+
"sizeS": "_sizeS_1vy16ki_8",
|
|
3
|
+
"sizeM": "_sizeM_1vy16ki_11",
|
|
4
|
+
"sizeL": "_sizeL_1vy16ki_14",
|
|
5
|
+
"dropdownMenu": "_dropdownMenu_1vy16ki_18",
|
|
6
|
+
"menu": "_menu_1vy16ki_23"
|
|
7
7
|
};
|
|
8
8
|
export { styles as default };
|
package/lib/menu-wrapper.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useResizeObserver } from '@rescui/use-resize-observer';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
const MenuWrapper = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
4
|
+
let {
|
|
5
|
+
children,
|
|
6
|
+
onHeightUpdate
|
|
7
|
+
} = _ref;
|
|
8
|
+
useResizeObserver(ref, entry => onHeightUpdate(entry.target.offsetHeight));
|
|
9
9
|
return /*#__PURE__*/React.createElement("div", {
|
|
10
10
|
ref: ref,
|
|
11
11
|
"data-rs-internal": 'dropdown-menu__menu-wrapper'
|
package/lib/public-api.p.css
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
--_rs-menu-mi-icon-offset:8px;
|
|
11
11
|
--_rs-menu-mi-vertical-padding:6px;
|
|
12
12
|
--_rs-menu-mi-horizontal-padding:8px;
|
|
13
|
-
--_rs-typography-letter-spacing:0.0045em;
|
|
13
|
+
--_rs-typography-letter-spacing:var(--rs-text-3-letter-spacing, 0.0045em);
|
|
14
14
|
--_rs-typography-text-transform:initial;
|
|
15
15
|
--_rs-typography-font-variant-numeric:initial;
|
|
16
16
|
--_rs-typography-font-family:var(
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
47
47
|
--_rs-menu-gh-vertical-padding:6px;
|
|
48
48
|
--_rs-menu-gh-horizontal-padding:8px;
|
|
49
|
-
--_rs-typography-letter-spacing:normal;
|
|
49
|
+
--_rs-typography-letter-spacing:var(--rs-h5-letter-spacing, normal);
|
|
50
50
|
--_rs-typography-text-transform:initial;
|
|
51
51
|
--_rs-typography-font-variant-numeric:initial;
|
|
52
52
|
--_rs-typography-font-family:var(
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
--_rs-menu-mi-icon-offset:8px;
|
|
90
90
|
--_rs-menu-mi-vertical-padding:8px;
|
|
91
91
|
--_rs-menu-mi-horizontal-padding:16px;
|
|
92
|
-
--_rs-typography-letter-spacing:0.0015em;
|
|
92
|
+
--_rs-typography-letter-spacing:var(--rs-text-2-letter-spacing, 0.0015em);
|
|
93
93
|
--_rs-typography-text-transform:initial;
|
|
94
94
|
--_rs-typography-font-variant-numeric:initial;
|
|
95
95
|
--_rs-typography-font-family:var(
|
|
@@ -117,20 +117,23 @@
|
|
|
117
117
|
--_rs-typography-text-auto-offset:16px;
|
|
118
118
|
--_rs-typography-ul-list-li-padding-left:22px;
|
|
119
119
|
--_rs-typography-ol-list-li-padding-left:26px;
|
|
120
|
-
--_rs-typography-list-li-margin-top-from-text:
|
|
120
|
+
--_rs-typography-list-li-margin-top-from-text:var(
|
|
121
|
+
--_rs-typography-text-2-sm-list-li-margin-top-from-text,
|
|
122
|
+
16px
|
|
123
|
+
);
|
|
121
124
|
--_rs-typography-link-standalone-border-offset-from-text-base:1.15em;
|
|
122
125
|
--_rs-typography-link-external-standalone-border-offset-from-text-base:1.02em;
|
|
123
126
|
--_rs-typography-link-border-bottom-width-from-text:1px;
|
|
124
127
|
}
|
|
125
128
|
@media screen and (max-width: 640px){
|
|
126
129
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__menu-item"]{
|
|
127
|
-
--_rs-typography-list-li-margin-top-from-text:12px;
|
|
130
|
+
--_rs-typography-text-2-sm-list-li-margin-top-from-text:12px;
|
|
128
131
|
}
|
|
129
132
|
}
|
|
130
133
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
131
134
|
--_rs-menu-gh-vertical-padding:8px;
|
|
132
135
|
--_rs-menu-gh-horizontal-padding:16px;
|
|
133
|
-
--_rs-typography-letter-spacing:normal;
|
|
136
|
+
--_rs-typography-letter-spacing:var(--rs-h4-letter-spacing, normal);
|
|
134
137
|
--_rs-typography-text-transform:initial;
|
|
135
138
|
--_rs-typography-font-variant-numeric:initial;
|
|
136
139
|
--_rs-typography-font-family:var(
|
|
@@ -173,7 +176,7 @@
|
|
|
173
176
|
--_rs-menu-mi-icon-offset:16px;
|
|
174
177
|
--_rs-menu-mi-vertical-padding:12px;
|
|
175
178
|
--_rs-menu-mi-horizontal-padding:16px;
|
|
176
|
-
--_rs-typography-letter-spacing:normal;
|
|
179
|
+
--_rs-typography-letter-spacing:var(--rs-text-1-letter-spacing, normal);
|
|
177
180
|
--_rs-typography-text-transform:initial;
|
|
178
181
|
--_rs-typography-font-variant-numeric:initial;
|
|
179
182
|
--_rs-typography-font-family:var(
|
|
@@ -201,20 +204,23 @@
|
|
|
201
204
|
--_rs-typography-text-auto-offset:32px;
|
|
202
205
|
--_rs-typography-ul-list-li-padding-left:26px;
|
|
203
206
|
--_rs-typography-ol-list-li-padding-left:32px;
|
|
204
|
-
--_rs-typography-list-li-margin-top-from-text:
|
|
207
|
+
--_rs-typography-list-li-margin-top-from-text:var(
|
|
208
|
+
--_rs-typography-text-1-sm-list-li-margin-top-from-text,
|
|
209
|
+
24px
|
|
210
|
+
);
|
|
205
211
|
--_rs-typography-link-standalone-border-offset-from-text-base:1.15em;
|
|
206
212
|
--_rs-typography-link-external-standalone-border-offset-from-text-base:1.02em;
|
|
207
213
|
--_rs-typography-link-border-bottom-width-from-text:1px;
|
|
208
214
|
}
|
|
209
215
|
@media screen and (max-width: 640px){
|
|
210
216
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__menu-item"]{
|
|
211
|
-
--_rs-typography-list-li-margin-top-from-text:16px;
|
|
217
|
+
--_rs-typography-text-1-sm-list-li-margin-top-from-text:16px;
|
|
212
218
|
}
|
|
213
219
|
}
|
|
214
220
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
215
221
|
--_rs-menu-gh-vertical-padding:12px;
|
|
216
222
|
--_rs-menu-gh-horizontal-padding:16px;
|
|
217
|
-
--_rs-typography-letter-spacing:normal;
|
|
223
|
+
--_rs-typography-letter-spacing:var(--rs-h3-letter-spacing, normal);
|
|
218
224
|
--_rs-typography-text-transform:initial;
|
|
219
225
|
--_rs-typography-font-variant-numeric:initial;
|
|
220
226
|
--_rs-typography-font-family:var(
|
package/lib/public-api.pcss
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
--_rs-menu-mi-icon-offset:8px;
|
|
11
11
|
--_rs-menu-mi-vertical-padding:6px;
|
|
12
12
|
--_rs-menu-mi-horizontal-padding:8px;
|
|
13
|
-
--_rs-typography-letter-spacing:0.0045em;
|
|
13
|
+
--_rs-typography-letter-spacing:var(--rs-text-3-letter-spacing, 0.0045em);
|
|
14
14
|
--_rs-typography-text-transform:initial;
|
|
15
15
|
--_rs-typography-font-variant-numeric:initial;
|
|
16
16
|
--_rs-typography-font-family:var(
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
47
47
|
--_rs-menu-gh-vertical-padding:6px;
|
|
48
48
|
--_rs-menu-gh-horizontal-padding:8px;
|
|
49
|
-
--_rs-typography-letter-spacing:normal;
|
|
49
|
+
--_rs-typography-letter-spacing:var(--rs-h5-letter-spacing, normal);
|
|
50
50
|
--_rs-typography-text-transform:initial;
|
|
51
51
|
--_rs-typography-font-variant-numeric:initial;
|
|
52
52
|
--_rs-typography-font-family:var(
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
--_rs-menu-mi-icon-offset:8px;
|
|
90
90
|
--_rs-menu-mi-vertical-padding:8px;
|
|
91
91
|
--_rs-menu-mi-horizontal-padding:16px;
|
|
92
|
-
--_rs-typography-letter-spacing:0.0015em;
|
|
92
|
+
--_rs-typography-letter-spacing:var(--rs-text-2-letter-spacing, 0.0015em);
|
|
93
93
|
--_rs-typography-text-transform:initial;
|
|
94
94
|
--_rs-typography-font-variant-numeric:initial;
|
|
95
95
|
--_rs-typography-font-family:var(
|
|
@@ -117,20 +117,23 @@
|
|
|
117
117
|
--_rs-typography-text-auto-offset:16px;
|
|
118
118
|
--_rs-typography-ul-list-li-padding-left:22px;
|
|
119
119
|
--_rs-typography-ol-list-li-padding-left:26px;
|
|
120
|
-
--_rs-typography-list-li-margin-top-from-text:
|
|
120
|
+
--_rs-typography-list-li-margin-top-from-text:var(
|
|
121
|
+
--_rs-typography-text-2-sm-list-li-margin-top-from-text,
|
|
122
|
+
16px
|
|
123
|
+
);
|
|
121
124
|
--_rs-typography-link-standalone-border-offset-from-text-base:1.15em;
|
|
122
125
|
--_rs-typography-link-external-standalone-border-offset-from-text-base:1.02em;
|
|
123
126
|
--_rs-typography-link-border-bottom-width-from-text:1px;
|
|
124
127
|
}
|
|
125
128
|
@media screen and (max-width: 640px){
|
|
126
129
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__menu-item"]{
|
|
127
|
-
--_rs-typography-list-li-margin-top-from-text:12px;
|
|
130
|
+
--_rs-typography-text-2-sm-list-li-margin-top-from-text:12px;
|
|
128
131
|
}
|
|
129
132
|
}
|
|
130
133
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
131
134
|
--_rs-menu-gh-vertical-padding:8px;
|
|
132
135
|
--_rs-menu-gh-horizontal-padding:16px;
|
|
133
|
-
--_rs-typography-letter-spacing:normal;
|
|
136
|
+
--_rs-typography-letter-spacing:var(--rs-h4-letter-spacing, normal);
|
|
134
137
|
--_rs-typography-text-transform:initial;
|
|
135
138
|
--_rs-typography-font-variant-numeric:initial;
|
|
136
139
|
--_rs-typography-font-family:var(
|
|
@@ -173,7 +176,7 @@
|
|
|
173
176
|
--_rs-menu-mi-icon-offset:16px;
|
|
174
177
|
--_rs-menu-mi-vertical-padding:12px;
|
|
175
178
|
--_rs-menu-mi-horizontal-padding:16px;
|
|
176
|
-
--_rs-typography-letter-spacing:normal;
|
|
179
|
+
--_rs-typography-letter-spacing:var(--rs-text-1-letter-spacing, normal);
|
|
177
180
|
--_rs-typography-text-transform:initial;
|
|
178
181
|
--_rs-typography-font-variant-numeric:initial;
|
|
179
182
|
--_rs-typography-font-family:var(
|
|
@@ -201,20 +204,23 @@
|
|
|
201
204
|
--_rs-typography-text-auto-offset:32px;
|
|
202
205
|
--_rs-typography-ul-list-li-padding-left:26px;
|
|
203
206
|
--_rs-typography-ol-list-li-padding-left:32px;
|
|
204
|
-
--_rs-typography-list-li-margin-top-from-text:
|
|
207
|
+
--_rs-typography-list-li-margin-top-from-text:var(
|
|
208
|
+
--_rs-typography-text-1-sm-list-li-margin-top-from-text,
|
|
209
|
+
24px
|
|
210
|
+
);
|
|
205
211
|
--_rs-typography-link-standalone-border-offset-from-text-base:1.15em;
|
|
206
212
|
--_rs-typography-link-external-standalone-border-offset-from-text-base:1.02em;
|
|
207
213
|
--_rs-typography-link-border-bottom-width-from-text:1px;
|
|
208
214
|
}
|
|
209
215
|
@media screen and (max-width: 640px){
|
|
210
216
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__menu-item"]{
|
|
211
|
-
--_rs-typography-list-li-margin-top-from-text:16px;
|
|
217
|
+
--_rs-typography-text-1-sm-list-li-margin-top-from-text:16px;
|
|
212
218
|
}
|
|
213
219
|
}
|
|
214
220
|
& [data-rs-internal="dropdown-menu__menu"] [data-rs-internal="menu__group-header"]{
|
|
215
221
|
--_rs-menu-gh-vertical-padding:12px;
|
|
216
222
|
--_rs-menu-gh-horizontal-padding:16px;
|
|
217
|
-
--_rs-typography-letter-spacing:normal;
|
|
223
|
+
--_rs-typography-letter-spacing:var(--rs-h3-letter-spacing, normal);
|
|
218
224
|
--_rs-typography-text-transform:initial;
|
|
219
225
|
--_rs-typography-font-variant-numeric:initial;
|
|
220
226
|
--_rs-typography-font-family:var(
|
package/package.json
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rescui/dropdown-menu",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.13-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
4
4
|
"description": "",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "JetBrains",
|
|
7
7
|
"main": "lib/index.js",
|
|
8
|
+
"module": "lib/index.js",
|
|
8
9
|
"src:main": "src/index.ts",
|
|
9
10
|
"files": [
|
|
10
11
|
"lib",
|
|
@@ -14,12 +15,11 @@
|
|
|
14
15
|
"access": "public"
|
|
15
16
|
},
|
|
16
17
|
"dependencies": {
|
|
17
|
-
"@babel/runtime-corejs3": "^7.
|
|
18
|
-
"@rescui/dropdown": "
|
|
19
|
-
"@rescui/menu": "
|
|
20
|
-
"@rescui/use-resize-observer": "
|
|
21
|
-
"classnames": "^2.2.6"
|
|
22
|
-
"core-js": "^3.9.1"
|
|
18
|
+
"@babel/runtime-corejs3": "^7.26.0",
|
|
19
|
+
"@rescui/dropdown": "0.7.13-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
20
|
+
"@rescui/menu": "0.10.11-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
21
|
+
"@rescui/use-resize-observer": "0.2.6-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
22
|
+
"classnames": "^2.2.6"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
25
|
"@rescui/ui-contexts": "^0.5.0",
|
|
@@ -27,16 +27,16 @@
|
|
|
27
27
|
"react": ">=16.8.0 <19"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@rescui/colors": "
|
|
31
|
-
"@rescui/icons": "
|
|
32
|
-
"@rescui/scripts": "
|
|
33
|
-
"@rescui/typography": "
|
|
34
|
-
"@rescui/visual-regression": "
|
|
30
|
+
"@rescui/colors": "0.2.7-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
31
|
+
"@rescui/icons": "0.16.13-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
32
|
+
"@rescui/scripts": "0.4.0",
|
|
33
|
+
"@rescui/typography": "0.19.2-RUI-226-Update-card-cn-6e43cc89.60+6e43cc89",
|
|
34
|
+
"@rescui/visual-regression": "0.1.2"
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
37
|
"build": "rescui-scripts build && yarn run build-pcss-api",
|
|
38
38
|
"build-pcss-api": "rescui-scripts build-pcss-api --file public-api.p.css"
|
|
39
39
|
},
|
|
40
40
|
"nx": {},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "6e43cc893fafb22b990273901bc0a070fb15761f"
|
|
42
42
|
}
|