@alfalab/core-components-select 15.2.0 → 15.2.2
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/Component-89f0cb07.d.ts +38 -0
- package/Component.mobile-ebda875c.d.ts +4 -4
- package/Component.mobile-f1f15074.d.ts +1 -1
- package/Component.mobile.js +2 -2
- package/Component.modal.mobile.js +2 -2
- package/Component.responsive.js +1 -1
- package/components/arrow/Component.js +1 -1
- package/components/arrow/index.css +3 -3
- package/components/base-checkmark/Component.js +1 -1
- package/components/base-checkmark/index.css +4 -4
- package/components/base-option/Component.js +1 -1
- package/components/base-option/index.css +13 -13
- package/components/base-select/Component.js +12 -5
- package/components/base-select/index.css +11 -11
- package/components/base-select-mobile/Component.js +13 -4
- package/components/base-select-mobile/footer/Component.js +1 -1
- package/components/base-select-mobile/footer/index.css +5 -5
- package/components/base-select-mobile/index.css +17 -18
- package/components/checkmark/Component.js +1 -1
- package/components/checkmark/index.css +10 -10
- package/components/checkmark-mobile/Component.js +1 -1
- package/components/checkmark-mobile/index.css +6 -6
- package/components/field/Component.js +1 -1
- package/components/field/index.css +12 -12
- package/components/optgroup/Component.js +1 -1
- package/components/optgroup/index.css +6 -6
- package/components/option/Component.js +1 -1
- package/components/option/index.css +20 -20
- package/components/options-list/Component.js +5 -4
- package/components/options-list/index.css +9 -9
- package/components/search/Component.js +1 -1
- package/components/search/index.css +2 -2
- package/components/virtual-options-list/Component.js +5 -4
- package/components/virtual-options-list/index.css +15 -15
- package/cssm/Component-89f0cb07.d.ts +38 -0
- package/cssm/Component.mobile-ebda875c.d.ts +4 -4
- package/cssm/Component.mobile.js +2 -2
- package/cssm/Component.modal.mobile.js +2 -2
- package/cssm/Component.responsive.js +1 -1
- package/cssm/components/base-select/Component.js +11 -4
- package/cssm/components/base-select-mobile/Component.js +12 -3
- package/cssm/components/base-select-mobile/index.module.css +1 -2
- package/cssm/components/options-list/Component.js +4 -3
- package/cssm/components/virtual-options-list/Component.js +4 -3
- package/cssm/desktop-69921c40.d.ts +6 -0
- package/{hook-45ab0a9c.js → cssm/hook-244c8d6e.js} +4 -1
- package/cssm/index-ebda875c.d.ts +1 -37
- package/cssm/index.js +1 -1
- package/cssm/mobile.js +1 -1
- package/cssm/presets/index.js +1 -1
- package/cssm/presets/useSelectWithApply/hook.js +1 -1
- package/cssm/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/cssm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/cssm/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/cssm/shared.js +1 -1
- package/{esm/typings-9211a437.d.ts → cssm/typings-89f0cb07.d.ts} +5 -7
- package/cssm/typings.d.ts +4 -0
- package/desktop-69921c40.d.ts +6 -0
- package/esm/Component-89f0cb07.d.ts +38 -0
- package/esm/Component.mobile-ebda875c.d.ts +4 -4
- package/esm/Component.mobile.js +2 -2
- package/esm/Component.modal.mobile.js +2 -2
- package/esm/Component.responsive.js +1 -1
- package/esm/components/arrow/Component.js +1 -1
- package/esm/components/arrow/index.css +3 -3
- package/esm/components/base-checkmark/Component.js +1 -1
- package/esm/components/base-checkmark/index.css +4 -4
- package/esm/components/base-option/Component.js +1 -1
- package/esm/components/base-option/index.css +13 -13
- package/esm/components/base-select/Component.js +12 -5
- package/esm/components/base-select/index.css +11 -11
- package/esm/components/base-select-mobile/Component.js +13 -4
- package/esm/components/base-select-mobile/footer/Component.js +1 -1
- package/esm/components/base-select-mobile/footer/index.css +5 -5
- package/esm/components/base-select-mobile/index.css +17 -18
- package/esm/components/checkmark/Component.js +1 -1
- package/esm/components/checkmark/index.css +10 -10
- package/esm/components/checkmark-mobile/Component.js +1 -1
- package/esm/components/checkmark-mobile/index.css +6 -6
- package/esm/components/field/Component.js +1 -1
- package/esm/components/field/index.css +12 -12
- package/esm/components/optgroup/Component.js +1 -1
- package/esm/components/optgroup/index.css +6 -6
- package/esm/components/option/Component.js +1 -1
- package/esm/components/option/index.css +20 -20
- package/esm/components/options-list/Component.js +5 -4
- package/esm/components/options-list/index.css +9 -9
- package/esm/components/search/Component.js +1 -1
- package/esm/components/search/index.css +2 -2
- package/esm/components/virtual-options-list/Component.js +5 -4
- package/esm/components/virtual-options-list/index.css +15 -15
- package/esm/desktop-69921c40.d.ts +6 -0
- package/esm/{hook-3fd6d6d4.js → hook-571dca86.js} +4 -1
- package/esm/index-ebda875c.d.ts +1 -37
- package/esm/index.js +1 -1
- package/esm/mobile.js +1 -1
- package/esm/presets/index.js +1 -1
- package/esm/presets/useSelectWithApply/hook.js +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/esm/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/esm/presets/useSelectWithLoading/hook.js +1 -1
- package/esm/presets/useSelectWithLoading/index.css +2 -2
- package/esm/shared.js +1 -1
- package/{modern/typings-9211a437.d.ts → esm/typings-89f0cb07.d.ts} +5 -7
- package/esm/typings.d.ts +4 -0
- package/{cssm/hook-d1f5dd40.js → hook-a6f060a1.js} +4 -1
- package/index-ebda875c.d.ts +1 -37
- package/index.js +1 -1
- package/mobile.js +1 -1
- package/modern/Component-89f0cb07.d.ts +38 -0
- package/modern/Component.mobile-ebda875c.d.ts +4 -4
- package/modern/Component.mobile.js +2 -2
- package/modern/Component.modal.mobile.js +2 -2
- package/modern/Component.responsive.js +1 -1
- package/modern/components/arrow/Component.js +1 -1
- package/modern/components/arrow/index.css +3 -3
- package/modern/components/base-checkmark/Component.js +1 -1
- package/modern/components/base-checkmark/index.css +4 -4
- package/modern/components/base-option/Component.js +1 -1
- package/modern/components/base-option/index.css +13 -13
- package/modern/components/base-select/Component.js +9 -5
- package/modern/components/base-select/index.css +11 -11
- package/modern/components/base-select-mobile/Component.js +10 -4
- package/modern/components/base-select-mobile/footer/Component.js +1 -1
- package/modern/components/base-select-mobile/footer/index.css +5 -5
- package/modern/components/base-select-mobile/index.css +17 -18
- package/modern/components/checkmark/Component.js +1 -1
- package/modern/components/checkmark/index.css +10 -10
- package/modern/components/checkmark-mobile/Component.js +1 -1
- package/modern/components/checkmark-mobile/index.css +6 -6
- package/modern/components/field/Component.js +1 -1
- package/modern/components/field/index.css +12 -12
- package/modern/components/optgroup/Component.js +1 -1
- package/modern/components/optgroup/index.css +6 -6
- package/modern/components/option/Component.js +1 -1
- package/modern/components/option/index.css +20 -20
- package/modern/components/options-list/Component.js +5 -4
- package/modern/components/options-list/index.css +9 -9
- package/modern/components/search/Component.js +1 -1
- package/modern/components/search/index.css +2 -2
- package/modern/components/virtual-options-list/Component.js +5 -4
- package/modern/components/virtual-options-list/index.css +15 -15
- package/modern/desktop-69921c40.d.ts +6 -0
- package/modern/{hook-5dd83d48.js → hook-7e628eb4.js} +1 -1
- package/modern/index-ebda875c.d.ts +1 -37
- package/modern/index.js +1 -1
- package/modern/mobile.js +1 -1
- package/modern/presets/index.js +1 -1
- package/modern/presets/useSelectWithApply/hook.js +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/modern/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/modern/presets/useSelectWithLoading/hook.js +1 -1
- package/modern/presets/useSelectWithLoading/index.css +2 -2
- package/modern/shared.js +1 -1
- package/{typings-9211a437.d.ts → modern/typings-89f0cb07.d.ts} +5 -7
- package/modern/typings.d.ts +4 -0
- package/package.json +7 -7
- package/presets/index.js +1 -1
- package/presets/useSelectWithApply/hook.js +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/presets/useSelectWithLoading/hook.js +1 -1
- package/presets/useSelectWithLoading/index.css +2 -2
- package/shared.js +1 -1
- package/src/Component.mobile.tsx +2 -0
- package/src/Component.modal.mobile.tsx +2 -0
- package/src/components/base-select/Component.tsx +12 -2
- package/src/components/base-select-mobile/Component.tsx +16 -3
- package/src/components/base-select-mobile/index.module.css +1 -1
- package/src/components/options-list/Component.tsx +9 -1
- package/src/components/virtual-options-list/Component.tsx +12 -1
- package/src/presets/useSelectWithApply/options-list-with-apply/Component.tsx +1 -1
- package/src/typings.ts +5 -0
- package/{cssm/typings-9211a437.d.ts → typings-89f0cb07.d.ts} +5 -7
- package/typings.d.ts +4 -0
- package/cssm/desktop-63dec22f.d.ts +0 -6
- package/desktop-63dec22f.d.ts +0 -6
- package/esm/desktop-63dec22f.d.ts +0 -6
- package/modern/desktop-63dec22f.d.ts +0 -6
- /package/cssm/{hook-d1f5dd40.d.ts → hook-244c8d6e.d.ts} +0 -0
- /package/esm/{hook-3fd6d6d4.d.ts → hook-571dca86.d.ts} +0 -0
- /package/{hook-45ab0a9c.d.ts → hook-a6f060a1.d.ts} +0 -0
- /package/modern/{hook-5dd83d48.d.ts → hook-7e628eb4.d.ts} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: xcxx3 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -37,12 +37,12 @@
|
|
|
37
37
|
/* checkmark */
|
|
38
38
|
|
|
39
39
|
/* optgroup */
|
|
40
|
-
} .
|
|
40
|
+
} .select__component_iqbbc {
|
|
41
41
|
width: max-content;
|
|
42
42
|
position: relative;
|
|
43
43
|
outline: 0;
|
|
44
44
|
max-width: 100%;
|
|
45
|
-
} .
|
|
45
|
+
} .select__popoverInner_iqbbc {
|
|
46
46
|
padding-top: var(--select-options-list-offset);
|
|
47
47
|
padding-bottom: var(--select-options-list-offset);
|
|
48
48
|
box-shadow: none;
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
background: transparent;
|
|
51
51
|
border-radius: 0;
|
|
52
52
|
position: relative;
|
|
53
|
-
} .
|
|
53
|
+
} .select__optionsList_iqbbc {
|
|
54
54
|
position: relative;
|
|
55
55
|
padding-top: var(--select-options-list-top-padding);
|
|
56
56
|
padding-bottom: var(--select-options-list-bottom-padding);
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
background: var(--select-option-background);
|
|
60
60
|
overflow: hidden;
|
|
61
61
|
will-change: transform;
|
|
62
|
-
} .
|
|
62
|
+
} .select__optionsListBorder_iqbbc {
|
|
63
63
|
position: absolute;
|
|
64
64
|
top: 0;
|
|
65
65
|
right: 0;
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
box-shadow: inset 0 0 0 1px var(--color-light-border-secondary);
|
|
69
69
|
border-radius: inherit;
|
|
70
70
|
pointer-events: none;
|
|
71
|
-
} .
|
|
71
|
+
} .select__nativeSelect_iqbbc {
|
|
72
72
|
opacity: 0;
|
|
73
73
|
overflow: hidden;
|
|
74
74
|
position: absolute;
|
|
@@ -81,16 +81,16 @@
|
|
|
81
81
|
height: 100%;
|
|
82
82
|
cursor: pointer;
|
|
83
83
|
z-index: 1;
|
|
84
|
-
} .
|
|
84
|
+
} .select__block_iqbbc {
|
|
85
85
|
width: 100%;
|
|
86
|
-
} .
|
|
86
|
+
} .select__emptySearchPlaceholder_iqbbc {
|
|
87
87
|
text-align: center;
|
|
88
|
-
} .
|
|
88
|
+
} .select__search_iqbbc {
|
|
89
89
|
margin: var(--gap-s) var(--gap-s) 0
|
|
90
|
-
} .
|
|
90
|
+
} .select__search_iqbbc:last-child {
|
|
91
91
|
margin-bottom: var(--gap-s);
|
|
92
92
|
} /* width: max-content; fix for IE */ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
93
|
-
.
|
|
93
|
+
.select__component_iqbbc {
|
|
94
94
|
float: left;
|
|
95
95
|
clear: left;
|
|
96
96
|
}
|
|
@@ -26,7 +26,7 @@ import '../../consts.js';
|
|
|
26
26
|
import '@alfalab/core-components-input/esm';
|
|
27
27
|
import '@alfalab/icons-glyph/MagnifierMIcon';
|
|
28
28
|
|
|
29
|
-
var styles = {"component":"
|
|
29
|
+
var styles = {"component":"select__component_jmk0w","sheet":"select__sheet_jmk0w","sheetContent":"select__sheetContent_jmk0w","modalContent":"select__modalContent_jmk0w","sheetContainer":"select__sheetContainer_jmk0w","block":"select__block_jmk0w","optionsListWrapper":"select__optionsListWrapper_jmk0w","optionsList":"select__optionsList_jmk0w","scrollbar":"select__scrollbar_jmk0w","emptySearchPlaceholder":"select__emptySearchPlaceholder_jmk0w","search":"select__search_jmk0w","option":"select__option_jmk0w","optionGroup":"select__optionGroup_jmk0w"};
|
|
30
30
|
require('./index.css')
|
|
31
31
|
|
|
32
32
|
var BaseSelectMobile = forwardRef(function (_a, ref) {
|
|
@@ -174,7 +174,11 @@ var BaseSelectMobile = forwardRef(function (_a, ref) {
|
|
|
174
174
|
};
|
|
175
175
|
var handleFieldKeyDown = function (event) {
|
|
176
176
|
inputProps.onKeyDown(event);
|
|
177
|
-
|
|
177
|
+
// https://caniuse.com/?search=KeyboardEvent.key
|
|
178
|
+
var isKeyUnsupported = event.key === 'Unidentified';
|
|
179
|
+
if (autocomplete &&
|
|
180
|
+
!open &&
|
|
181
|
+
(isKeyUnsupported || event.key.length === 1 || event.key === 'Backspace')) {
|
|
178
182
|
// Для автокомплита - открываем меню при начале ввода
|
|
179
183
|
openMenu();
|
|
180
184
|
}
|
|
@@ -197,7 +201,10 @@ var BaseSelectMobile = forwardRef(function (_a, ref) {
|
|
|
197
201
|
}
|
|
198
202
|
};
|
|
199
203
|
var getOptionProps = function (option, index) {
|
|
200
|
-
var selectedItem = selectedItems.
|
|
204
|
+
var selectedItem = selectedItems.some(function (_a) {
|
|
205
|
+
var key = _a.key;
|
|
206
|
+
return key === option.key;
|
|
207
|
+
});
|
|
201
208
|
return __assign(__assign({}, optionProps), { mobile: true, className: cn(styles.option, optionClassName), innerProps: getItemProps({
|
|
202
209
|
index: index,
|
|
203
210
|
item: option,
|
|
@@ -269,7 +276,9 @@ var BaseSelectMobile = forwardRef(function (_a, ref) {
|
|
|
269
276
|
scrollableContainerRef,
|
|
270
277
|
modalProps === null || modalProps === void 0 ? void 0 : modalProps.ref,
|
|
271
278
|
]) }),
|
|
272
|
-
React.createElement(ModalMobile.Header, __assign({ hasCloser: true, sticky: true
|
|
279
|
+
React.createElement(ModalMobile.Header, __assign({ hasCloser: true, sticky: true }, modalHeaderProps, { bottomAddons: React.createElement(React.Fragment, null,
|
|
280
|
+
renderSearch(), modalHeaderProps === null || modalHeaderProps === void 0 ? void 0 :
|
|
281
|
+
modalHeaderProps.bottomAddons) }), label || placeholder),
|
|
273
282
|
React.createElement(ModalMobile.Content, { flex: true, className: styles.modalContent }, renderOptionsList()),
|
|
274
283
|
(modalFooterProps === null || modalFooterProps === void 0 ? void 0 : modalFooterProps.children) && React.createElement(ModalMobile.Footer, __assign({}, modalFooterProps))))));
|
|
275
284
|
});
|
|
@@ -3,7 +3,7 @@ import cn from 'classnames';
|
|
|
3
3
|
import { BaseModalContext } from '@alfalab/core-components-base-modal/esm';
|
|
4
4
|
import { ButtonMobile } from '@alfalab/core-components-button/esm/mobile';
|
|
5
5
|
|
|
6
|
-
var styles = {"footer":"
|
|
6
|
+
var styles = {"footer":"select__footer_n468t","button":"select__button_n468t","highlighted":"select__highlighted_n468t"};
|
|
7
7
|
require('./index.css')
|
|
8
8
|
|
|
9
9
|
var Footer = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1gvmg */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -26,17 +26,17 @@
|
|
|
26
26
|
/* checkmark */
|
|
27
27
|
|
|
28
28
|
/* optgroup */
|
|
29
|
-
} .
|
|
29
|
+
} .select__footer_n468t {
|
|
30
30
|
display: flex;
|
|
31
31
|
box-sizing: border-box;
|
|
32
32
|
width: 100%;
|
|
33
33
|
padding: var(--gap-m) var(--gap-m);
|
|
34
34
|
background-color: var(--color-light-bg-primary)
|
|
35
|
-
} .
|
|
35
|
+
} .select__footer_n468t .select__button_n468t:first-of-type {
|
|
36
36
|
margin-right: var(--gap-m);
|
|
37
|
-
} .
|
|
37
|
+
} .select__button_n468t {
|
|
38
38
|
width: 50%;
|
|
39
|
-
} .
|
|
39
|
+
} .select__highlighted_n468t {
|
|
40
40
|
border-top: 1px solid var(--color-light-border-primary);
|
|
41
41
|
background-color: var(--color-light-bg-primary);
|
|
42
42
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1krh3 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
} :root {
|
|
15
15
|
--gap-2xs: 4px;
|
|
16
16
|
--gap-xs: 8px;
|
|
17
|
-
--gap-s: 12px;
|
|
18
17
|
--gap-m: 16px;
|
|
19
18
|
--gap-l: 20px;
|
|
20
19
|
} :root {
|
|
@@ -28,44 +27,44 @@
|
|
|
28
27
|
/* checkmark */
|
|
29
28
|
|
|
30
29
|
/* optgroup */
|
|
31
|
-
} .
|
|
30
|
+
} .select__component_jmk0w {
|
|
32
31
|
width: max-content;
|
|
33
32
|
position: relative;
|
|
34
33
|
outline: 0;
|
|
35
34
|
max-width: 100%;
|
|
36
|
-
} .
|
|
35
|
+
} .select__sheet_jmk0w {
|
|
37
36
|
overflow: hidden;
|
|
38
|
-
} .
|
|
37
|
+
} .select__sheetContent_jmk0w {
|
|
39
38
|
padding: 0
|
|
40
|
-
} .
|
|
39
|
+
} .select__sheetContent_jmk0w .select__modalContent_jmk0w {
|
|
41
40
|
padding: 0;
|
|
42
41
|
display: flex;
|
|
43
42
|
flex-direction: column;
|
|
44
|
-
} .
|
|
43
|
+
} .select__sheetContainer_jmk0w {
|
|
45
44
|
padding: 0;
|
|
46
|
-
} .
|
|
45
|
+
} .select__block_jmk0w {
|
|
47
46
|
width: 100%;
|
|
48
|
-
} .
|
|
47
|
+
} .select__optionsListWrapper_jmk0w {
|
|
49
48
|
flex: 1;
|
|
50
|
-
} .
|
|
49
|
+
} .select__optionsList_jmk0w {
|
|
51
50
|
height: 100%;
|
|
52
51
|
display: flex;
|
|
53
52
|
flex-direction: column;
|
|
54
|
-
} .
|
|
53
|
+
} .select__scrollbar_jmk0w {
|
|
55
54
|
flex: 1;
|
|
56
|
-
} .
|
|
55
|
+
} .select__emptySearchPlaceholder_jmk0w {
|
|
57
56
|
text-align: center;
|
|
58
|
-
} .
|
|
59
|
-
padding: var(--gap-
|
|
57
|
+
} .select__search_jmk0w {
|
|
58
|
+
padding: var(--gap-xs);
|
|
60
59
|
} /* width: max-content; fix for IE */ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
61
|
-
.
|
|
60
|
+
.select__component_jmk0w {
|
|
62
61
|
float: left;
|
|
63
62
|
clear: left;
|
|
64
63
|
}
|
|
65
|
-
} .
|
|
64
|
+
} .select__option_jmk0w {
|
|
66
65
|
padding: var(--gap-2xs) var(--gap-l) var(--gap-2xs) var(--gap-m)
|
|
67
|
-
} .
|
|
66
|
+
} .select__option_jmk0w:before {
|
|
68
67
|
display: none;
|
|
69
|
-
} .
|
|
68
|
+
} .select__optionGroup_jmk0w {
|
|
70
69
|
padding: var(--gap-m) var(--gap-m) var(--gap-xs);
|
|
71
70
|
}
|
|
@@ -5,7 +5,7 @@ import { Checkbox } from '@alfalab/core-components-checkbox/esm';
|
|
|
5
5
|
import { CheckmarkCircleMIcon } from '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
6
6
|
import CheckmarkMIcon from '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
7
7
|
|
|
8
|
-
var styles = {"checkmark":"
|
|
8
|
+
var styles = {"checkmark":"select__checkmark_1nk9m","after":"select__after_1nk9m","single":"select__single_1nk9m","selected":"select__selected_1nk9m","before":"select__before_1nk9m","multiple":"select__multiple_1nk9m","colorIcon":"select__colorIcon_1nk9m"};
|
|
9
9
|
require('./index.css')
|
|
10
10
|
|
|
11
11
|
var Checkmark = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1ffqd */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-graphic-positive: #2fc26e;
|
|
@@ -39,12 +39,12 @@
|
|
|
39
39
|
--select-checkmark-border-radius: var(--border-radius-circle);
|
|
40
40
|
|
|
41
41
|
/* optgroup */
|
|
42
|
-
} .
|
|
42
|
+
} .select__checkmark_1nk9m {
|
|
43
43
|
flex-shrink: 0;
|
|
44
44
|
margin: var(--select-checkmark-margin)
|
|
45
|
-
} .
|
|
45
|
+
} .select__checkmark_1nk9m.select__after_1nk9m {
|
|
46
46
|
margin: var(--select-checkmark-margin-after);
|
|
47
|
-
} .
|
|
47
|
+
} .select__single_1nk9m {
|
|
48
48
|
display: flex;
|
|
49
49
|
align-items: center;
|
|
50
50
|
justify-content: center;
|
|
@@ -54,17 +54,17 @@
|
|
|
54
54
|
border-radius: var(--select-checkmark-border-radius);
|
|
55
55
|
width: var(--select-checkmark-size);
|
|
56
56
|
height: var(--select-checkmark-size)
|
|
57
|
-
} .
|
|
57
|
+
} .select__single_1nk9m.select__selected_1nk9m {
|
|
58
58
|
opacity: 1;
|
|
59
|
-
} .
|
|
59
|
+
} .select__before_1nk9m {
|
|
60
60
|
display: var(--select-checkmark-before-display)
|
|
61
|
-
} .
|
|
61
|
+
} .select__before_1nk9m.select__multiple_1nk9m {
|
|
62
62
|
margin-right: var(--gap-s);
|
|
63
63
|
display: var(--select-checkmark-before-display-multiple);
|
|
64
|
-
} .
|
|
64
|
+
} .select__after_1nk9m {
|
|
65
65
|
display: var(--select-checkmark-after-display)
|
|
66
|
-
} .
|
|
66
|
+
} .select__after_1nk9m.select__single_1nk9m {
|
|
67
67
|
display: var(--select-checkmark-after-display-single);
|
|
68
|
-
} .
|
|
68
|
+
} .select__colorIcon_1nk9m {
|
|
69
69
|
color: var(--color-light-graphic-positive);
|
|
70
70
|
}
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { CheckmarkMIcon } from '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
4
4
|
|
|
5
|
-
var styles = {"checkmark":"
|
|
5
|
+
var styles = {"checkmark":"select__checkmark_1b0yc","selected":"select__selected_1b0yc","displayIcon":"select__displayIcon_1b0yc","displayBadge":"select__displayBadge_1b0yc"};
|
|
6
6
|
require('./index.css')
|
|
7
7
|
|
|
8
8
|
var Checkmark = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: ahj4r */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
--select-mobile-checkmark-display-badge: none;
|
|
26
26
|
|
|
27
27
|
/* optgroup */
|
|
28
|
-
} .
|
|
28
|
+
} .select__checkmark_1b0yc {
|
|
29
29
|
flex-shrink: 0;
|
|
30
30
|
display: flex;
|
|
31
31
|
align-items: center;
|
|
@@ -33,12 +33,12 @@
|
|
|
33
33
|
width: 24px;
|
|
34
34
|
height: 24px;
|
|
35
35
|
opacity: 0
|
|
36
|
-
} .
|
|
36
|
+
} .select__checkmark_1b0yc:first-child {
|
|
37
37
|
display: none;
|
|
38
|
-
} .
|
|
38
|
+
} .select__checkmark_1b0yc.select__selected_1b0yc {
|
|
39
39
|
opacity: 1;
|
|
40
|
-
} .
|
|
40
|
+
} .select__displayIcon_1b0yc {
|
|
41
41
|
display: var(--select-mobile-checkmark-display-icon);
|
|
42
|
-
} .
|
|
42
|
+
} .select__displayBadge_1b0yc {
|
|
43
43
|
display: var(--select-mobile-checkmark-display-badge);
|
|
44
44
|
}
|
|
@@ -5,7 +5,7 @@ import { getDataTestId } from '@alfalab/core-components-shared/esm';
|
|
|
5
5
|
import { useFocus } from '@alfalab/hooks';
|
|
6
6
|
import { joinOptions } from '../../utils.js';
|
|
7
7
|
|
|
8
|
-
var styles = {"component":"
|
|
8
|
+
var styles = {"component":"select__component_19tbv","field":"select__field_19tbv","disabled":"select__disabled_19tbv","arrow":"select__arrow_19tbv","placeholder":"select__placeholder_19tbv","show-placeholder":"select__show-placeholder_19tbv","focused":"select__focused_19tbv","contentWrapper":"select__contentWrapper_19tbv","value":"select__value_19tbv","focusVisible":"select__focusVisible_19tbv"};
|
|
9
9
|
require('./index.css')
|
|
10
10
|
|
|
11
11
|
var Field = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: bii8a */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-border-link: #0072ef;
|
|
@@ -44,22 +44,22 @@
|
|
|
44
44
|
/* checkmark */
|
|
45
45
|
|
|
46
46
|
/* optgroup */
|
|
47
|
-
} .
|
|
47
|
+
} .select__component_19tbv {
|
|
48
48
|
width: 100%;
|
|
49
49
|
outline: none;
|
|
50
|
-
} .
|
|
50
|
+
} .select__field_19tbv:not(.select__disabled_19tbv) {
|
|
51
51
|
cursor: pointer
|
|
52
|
-
} .
|
|
52
|
+
} .select__field_19tbv:not(.select__disabled_19tbv):hover .select__arrow_19tbv {
|
|
53
53
|
opacity: var(--select-arrow-hover-opacity);
|
|
54
|
-
} .
|
|
54
|
+
} .select__disabled_19tbv {
|
|
55
55
|
cursor: var(--disabled-cursor);
|
|
56
|
-
} .
|
|
56
|
+
} .select__placeholder_19tbv {
|
|
57
57
|
color: var(--input-placeholder-color);
|
|
58
58
|
transition: color 0.2s ease;
|
|
59
|
-
animation: select__show-
|
|
60
|
-
} .
|
|
59
|
+
animation: select__show-placeholder_19tbv 0.2s ease
|
|
60
|
+
} .select__placeholder_19tbv.select__focused_19tbv {
|
|
61
61
|
color: var(--input-focus-placeholder-color);
|
|
62
|
-
} .
|
|
62
|
+
} .select__contentWrapper_19tbv {
|
|
63
63
|
font-size: 16px;
|
|
64
64
|
line-height: 20px;
|
|
65
65
|
font-weight: 400;
|
|
@@ -68,14 +68,14 @@
|
|
|
68
68
|
text-overflow: ellipsis;
|
|
69
69
|
overflow: hidden;
|
|
70
70
|
width: 100%;
|
|
71
|
-
} .
|
|
71
|
+
} .select__value_19tbv {
|
|
72
72
|
overflow: hidden;
|
|
73
73
|
text-overflow: ellipsis;
|
|
74
74
|
text-align: left;
|
|
75
|
-
} .
|
|
75
|
+
} .select__focusVisible_19tbv {
|
|
76
76
|
outline: 2px solid var(--focus-color);
|
|
77
77
|
outline-offset: 2px;
|
|
78
|
-
} @keyframes select__show-
|
|
78
|
+
} @keyframes select__show-placeholder_19tbv {
|
|
79
79
|
from {
|
|
80
80
|
opacity: 0;
|
|
81
81
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
|
|
4
|
-
var styles = {"optgroup":"
|
|
4
|
+
var styles = {"optgroup":"select__optgroup_1d3m7","label":"select__label_1d3m7","l":"select__l_1d3m7","xl":"select__xl_1d3m7"};
|
|
5
5
|
require('./index.css')
|
|
6
6
|
|
|
7
7
|
var Optgroup = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: hdpux */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
--select-optgroup-right-padding: var(--gap-s);
|
|
36
36
|
--select-optgroup-l-left-padding: var(--gap-m);
|
|
37
37
|
--select-optgroup-l-right-padding: var(--gap-m);
|
|
38
|
-
} .
|
|
38
|
+
} .select__optgroup_1d3m7 {
|
|
39
39
|
position: relative;
|
|
40
40
|
display: flex;
|
|
41
41
|
align-items: center;
|
|
@@ -44,9 +44,9 @@
|
|
|
44
44
|
box-sizing: border-box;
|
|
45
45
|
background: var(--select-optgroup-background);
|
|
46
46
|
min-height: 40px
|
|
47
|
-
} .
|
|
47
|
+
} .select__optgroup_1d3m7 + *[role='option']:before {
|
|
48
48
|
display: none;
|
|
49
|
-
} .
|
|
49
|
+
} .select__label_1d3m7 {
|
|
50
50
|
font-size: 12px;
|
|
51
51
|
line-height: 16px;
|
|
52
52
|
font-weight: 500;
|
|
@@ -55,8 +55,8 @@
|
|
|
55
55
|
|
|
56
56
|
display: block;
|
|
57
57
|
color: var(--select-optgroup-color);
|
|
58
|
-
} .
|
|
59
|
-
.
|
|
58
|
+
} .select__l_1d3m7,
|
|
59
|
+
.select__xl_1d3m7 {
|
|
60
60
|
padding-left: var(--select-optgroup-l-left-padding);
|
|
61
61
|
padding-right: var(--select-optgroup-l-right-padding);
|
|
62
62
|
}
|
|
@@ -8,7 +8,7 @@ import '@alfalab/core-components-checkbox/esm';
|
|
|
8
8
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
9
9
|
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
10
10
|
|
|
11
|
-
var styles = {"option":"
|
|
11
|
+
var styles = {"option":"select__option_f9id2","disabled":"select__disabled_f9id2","s":"select__s_f9id2","m":"select__m_f9id2","l":"select__l_f9id2","xl":"select__xl_f9id2","selected":"select__selected_f9id2","highlighted":"select__highlighted_f9id2","content":"select__content_f9id2","textContent":"select__textContent_f9id2"};
|
|
12
12
|
require('./index.css')
|
|
13
13
|
|
|
14
14
|
var Option = function (_a) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 19tsb */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
/* checkmark */
|
|
54
54
|
|
|
55
55
|
/* optgroup */
|
|
56
|
-
} .
|
|
56
|
+
} .select__option_f9id2 {
|
|
57
57
|
font-size: 16px;
|
|
58
58
|
line-height: 20px;
|
|
59
59
|
font-weight: 400;
|
|
@@ -68,10 +68,10 @@
|
|
|
68
68
|
box-sizing: border-box;
|
|
69
69
|
position: relative;
|
|
70
70
|
cursor: pointer
|
|
71
|
-
} .
|
|
71
|
+
} .select__option_f9id2:not(.select__disabled_f9id2):active {
|
|
72
72
|
background: var(--select-option-active-background);
|
|
73
73
|
color: var(--select-option-active-color);
|
|
74
|
-
} .
|
|
74
|
+
} .select__option_f9id2:before {
|
|
75
75
|
content: '';
|
|
76
76
|
position: absolute;
|
|
77
77
|
left: var(--select-option-left-padding);
|
|
@@ -81,46 +81,46 @@
|
|
|
81
81
|
background: var(--select-option-divider-background);
|
|
82
82
|
display: var(--select-option-divider-display);
|
|
83
83
|
transition: opacity 0.2s ease;
|
|
84
|
-
} .
|
|
84
|
+
} .select__option_f9id2:first-child:before {
|
|
85
85
|
display: none;
|
|
86
|
-
} .
|
|
86
|
+
} .select__s_f9id2 {
|
|
87
87
|
min-height: var(--size-s-height);
|
|
88
|
-
} .
|
|
88
|
+
} .select__m_f9id2 {
|
|
89
89
|
min-height: var(--size-m-height);
|
|
90
|
-
} .
|
|
90
|
+
} .select__l_f9id2 {
|
|
91
91
|
min-height: var(--size-l-height);
|
|
92
|
-
} .
|
|
92
|
+
} .select__xl_f9id2 {
|
|
93
93
|
min-height: var(--size-xl-height);
|
|
94
|
-
} .
|
|
95
|
-
.
|
|
94
|
+
} .select__l_f9id2,
|
|
95
|
+
.select__xl_f9id2 {
|
|
96
96
|
padding-left: var(--select-option-l-left-padding);
|
|
97
97
|
padding-right: var(--select-option-l-right-padding)
|
|
98
|
-
} .
|
|
98
|
+
} .select__l_f9id2:before, .select__xl_f9id2:before {
|
|
99
99
|
left: var(--select-option-l-left-padding);
|
|
100
100
|
right: var(--select-option-l-right-padding);
|
|
101
|
-
} .
|
|
101
|
+
} .select__selected_f9id2 {
|
|
102
102
|
background: var(--select-option-selected-background);
|
|
103
103
|
color: var(--select-option-selected-color);
|
|
104
104
|
cursor: default;
|
|
105
|
-
} .
|
|
105
|
+
} .select__highlighted_f9id2 {
|
|
106
106
|
background: var(--select-option-hover-background);
|
|
107
107
|
color: var(--select-option-hover-color)
|
|
108
|
-
} .
|
|
109
|
-
.
|
|
108
|
+
} .select__highlighted_f9id2:before,
|
|
109
|
+
.select__highlighted_f9id2 + .select__option_f9id2:before {
|
|
110
110
|
opacity: 0;
|
|
111
|
-
} .
|
|
111
|
+
} .select__disabled_f9id2 {
|
|
112
112
|
cursor: var(--disabled-cursor);
|
|
113
113
|
background: var(--select-option-disabled-background);
|
|
114
114
|
color: var(--select-option-disabled-color);
|
|
115
|
-
} .
|
|
115
|
+
} .select__content_f9id2 {
|
|
116
116
|
overflow: hidden;
|
|
117
117
|
flex: 1;
|
|
118
118
|
text-overflow: ellipsis;
|
|
119
|
-
} .
|
|
119
|
+
} .select__textContent_f9id2 {
|
|
120
120
|
padding-top: var(--gap-s);
|
|
121
121
|
padding-bottom: var(--gap-s);
|
|
122
122
|
} /* IE min-height fix */ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
123
|
-
.
|
|
123
|
+
.select__option_f9id2:after {
|
|
124
124
|
min-height: inherit;
|
|
125
125
|
font-size: 0;
|
|
126
126
|
content: '';
|
|
@@ -8,7 +8,7 @@ import { DEFAULT_VISIBLE_OPTIONS } from '../../consts.js';
|
|
|
8
8
|
import { useVisibleOptions, isGroup } from '../../utils.js';
|
|
9
9
|
import { Optgroup } from '../optgroup/Component.js';
|
|
10
10
|
|
|
11
|
-
var styles = {"optionsList":"
|
|
11
|
+
var styles = {"optionsList":"select__optionsList_fttuv","optionsListHeader":"select__optionsListHeader_fttuv","optionsListFooter":"select__optionsListFooter_fttuv","withBorder":"select__withBorder_fttuv","scrollable":"select__scrollable_fttuv","emptyPlaceholder":"select__emptyPlaceholder_fttuv","l":"select__l_fttuv","xl":"select__xl_fttuv"};
|
|
12
12
|
require('./index.css')
|
|
13
13
|
|
|
14
14
|
var createCounter = function () {
|
|
@@ -18,7 +18,7 @@ var createCounter = function () {
|
|
|
18
18
|
};
|
|
19
19
|
var OptionsList = forwardRef(function (_a, ref) {
|
|
20
20
|
var _b;
|
|
21
|
-
var _c = _a.size, size = _c === void 0 ? 's' : _c, className = _a.className, optionGroupClassName = _a.optionGroupClassName, scrollbarClassName = _a.scrollbarClassName, Option = _a.Option, getOptionProps = _a.getOptionProps, _d = _a.options, options = _d === void 0 ? [] : _d, _e = _a.Optgroup, Optgroup$1 = _e === void 0 ? Optgroup : _e, dataTestId = _a.dataTestId, emptyPlaceholder = _a.emptyPlaceholder, _f = _a.visibleOptions, visibleOptions = _f === void 0 ? DEFAULT_VISIBLE_OPTIONS : _f, onScroll = _a.onScroll, open = _a.open, header = _a.header, footer = _a.footer, _g = _a.showFooter, showFooter = _g === void 0 ? true : _g, optionsListWidth = _a.optionsListWidth, nativeScrollbarProp = _a.nativeScrollbar, _h = _a.flatOptions, flatOptions = _h === void 0 ? [] : _h;
|
|
21
|
+
var _c = _a.size, size = _c === void 0 ? 's' : _c, className = _a.className, optionGroupClassName = _a.optionGroupClassName, scrollbarClassName = _a.scrollbarClassName, Option = _a.Option, getOptionProps = _a.getOptionProps, _d = _a.options, options = _d === void 0 ? [] : _d, _e = _a.Optgroup, Optgroup$1 = _e === void 0 ? Optgroup : _e, dataTestId = _a.dataTestId, emptyPlaceholder = _a.emptyPlaceholder, _f = _a.visibleOptions, visibleOptions = _f === void 0 ? DEFAULT_VISIBLE_OPTIONS : _f, onScroll = _a.onScroll, open = _a.open, header = _a.header, footer = _a.footer, _g = _a.showFooter, showFooter = _g === void 0 ? true : _g, optionsListWidth = _a.optionsListWidth, nativeScrollbarProp = _a.nativeScrollbar, _h = _a.flatOptions, flatOptions = _h === void 0 ? [] : _h, setHighlightedIndex = _a.setHighlightedIndex;
|
|
22
22
|
var nativeScrollbar = useMedia([[true, '(max-width: 1023px)']], false)[0];
|
|
23
23
|
nativeScrollbar = Boolean(nativeScrollbarProp !== null && nativeScrollbarProp !== void 0 ? nativeScrollbarProp : nativeScrollbar);
|
|
24
24
|
var renderOption = function (option, index) { return (React.createElement(Option, __assign({ key: option.key }, getOptionProps(option, index)))); };
|
|
@@ -44,10 +44,11 @@ var OptionsList = forwardRef(function (_a, ref) {
|
|
|
44
44
|
return (React.createElement(Scrollbar, { className: cn(styles.scrollable, scrollbarClassName), ref: scrollbarRef, horizontalAutoStretch: optionsListWidth === 'content', scrollableNodeProps: scrollableNodeProps, contentNodeProps: { ref: listRef } }, renderListItems()));
|
|
45
45
|
};
|
|
46
46
|
var renderWithNativeScrollbar = function () { return (React.createElement("div", { className: cn(styles.scrollable, scrollbarClassName), ref: mergeRefs([listRef, ref]), onScroll: onScroll }, renderListItems())); };
|
|
47
|
+
var resetHighlightedIndex = function () { return setHighlightedIndex === null || setHighlightedIndex === void 0 ? void 0 : setHighlightedIndex(-1); };
|
|
47
48
|
return (React.createElement("div", __assign({}, (nativeScrollbar && { 'data-test-id': dataTestId }), { className: cn(styles.optionsList, styles[size], className) }),
|
|
48
|
-
header && React.createElement("div", { className: styles.optionsListHeader }, header),
|
|
49
|
+
header && (React.createElement("div", { className: styles.optionsListHeader, onMouseEnter: resetHighlightedIndex }, header)),
|
|
49
50
|
nativeScrollbar ? renderWithNativeScrollbar() : renderWithCustomScrollbar(),
|
|
50
|
-
showFooter && footer && (React.createElement("div", { className: cn(styles.optionsListFooter, (_b = {},
|
|
51
|
+
showFooter && footer && (React.createElement("div", { onMouseEnter: resetHighlightedIndex, className: cn(styles.optionsListFooter, (_b = {},
|
|
51
52
|
_b[styles.withBorder] = visibleOptions && flatOptions.length > visibleOptions,
|
|
52
53
|
_b)) }, footer))));
|
|
53
54
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: ukhvz */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-border-secondary: #e9e9eb;
|
|
@@ -29,28 +29,28 @@
|
|
|
29
29
|
/* checkmark */
|
|
30
30
|
|
|
31
31
|
/* optgroup */
|
|
32
|
-
} .
|
|
32
|
+
} .select__optionsList_fttuv {
|
|
33
33
|
width: 100%;
|
|
34
34
|
outline: none;
|
|
35
35
|
box-sizing: border-box;
|
|
36
36
|
position: relative;
|
|
37
|
-
} .
|
|
37
|
+
} .select__optionsListHeader_fttuv {
|
|
38
38
|
box-sizing: border-box;
|
|
39
39
|
border-bottom: 1px solid var(--color-light-border-secondary);
|
|
40
|
-
} .
|
|
40
|
+
} .select__optionsListFooter_fttuv {
|
|
41
41
|
position: sticky;
|
|
42
42
|
bottom: 0;
|
|
43
43
|
box-sizing: border-box;
|
|
44
44
|
border-top: 1px solid transparent
|
|
45
|
-
} .
|
|
45
|
+
} .select__optionsListFooter_fttuv.select__withBorder_fttuv {
|
|
46
46
|
border-top: 1px solid var(--color-light-border-secondary);
|
|
47
|
-
} .
|
|
47
|
+
} .select__scrollable_fttuv {
|
|
48
48
|
overflow: auto;
|
|
49
49
|
width: 100%;
|
|
50
|
-
} .
|
|
50
|
+
} .select__emptyPlaceholder_fttuv {
|
|
51
51
|
padding: var(--gap-m) var(--gap-s);
|
|
52
52
|
color: var(--select-options-list-empty-placeholder-color);
|
|
53
|
-
} .
|
|
54
|
-
.
|
|
53
|
+
} .select__l_fttuv .select__emptyPlaceholder_fttuv,
|
|
54
|
+
.select__xl_fttuv .select__emptyPlaceholder_fttuv {
|
|
55
55
|
padding: var(--gap-xl) var(--gap-m);
|
|
56
56
|
}
|
|
@@ -4,7 +4,7 @@ import cn from 'classnames';
|
|
|
4
4
|
import { Input } from '@alfalab/core-components-input/esm';
|
|
5
5
|
import { MagnifierMIcon } from '@alfalab/icons-glyph/MagnifierMIcon';
|
|
6
6
|
|
|
7
|
-
var styles = {"component":"
|
|
7
|
+
var styles = {"component":"select__component_lcwk3"};
|
|
8
8
|
require('./index.css')
|
|
9
9
|
|
|
10
10
|
var Search = forwardRef(function (_a, ref) {
|