@alfalab/core-components-select 13.2.15 → 13.2.17
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-71240601.js → Component-342bab38.js} +6 -9
- package/{Component-001db41f.js → Component-9475069a.js} +3 -2
- package/Component.js +1 -1
- package/Component.responsive.js +3 -3
- package/components/arrow/Component.js +1 -1
- package/components/arrow/index.css +5 -5
- package/components/base-checkmark/Component.js +1 -1
- package/components/base-checkmark/index.css +6 -6
- package/components/base-option/Component.js +1 -1
- package/components/base-option/index.css +15 -15
- package/components/base-select/Component.js +1 -1
- package/components/base-select/index.css +19 -8
- package/components/base-select/index.d.ts +1 -1
- package/components/base-select/index.js +1 -1
- package/components/base-select-mobile/Component.js +3 -3
- package/components/base-select-mobile/checkmark/Component.js +1 -1
- package/components/base-select-mobile/checkmark/index.css +8 -8
- package/components/base-select-mobile/index.css +13 -13
- package/components/base-select-mobile/index.d.ts +1 -1
- package/components/base-select-mobile/index.js +3 -3
- package/components/base-select-mobile/options-list/Component.js +1 -1
- package/components/base-select-mobile/options-list/index.css +11 -11
- package/components/base-select-mobile/virtual-options-list/Component.js +1 -1
- package/components/base-select-mobile/virtual-options-list/index.css +17 -17
- package/components/checkmark/Component.js +1 -1
- package/components/checkmark/index.css +12 -12
- package/components/field/Component.js +1 -1
- package/components/field/index.css +11 -11
- package/components/index.js +3 -3
- package/components/optgroup/Component.js +1 -1
- package/components/optgroup/index.css +8 -8
- package/components/option/Component.js +1 -1
- package/components/option/index.css +22 -22
- package/components/options-list/Component.js +7 -4
- package/components/options-list/index.css +17 -8
- package/components/select-mobile/Component.js +3 -3
- package/components/select-mobile/index.d.ts +1 -1
- package/components/select-mobile/index.js +3 -3
- package/components/select-modal-mobile/Component.js +3 -3
- package/components/select-modal-mobile/index.d.ts +1 -1
- package/components/select-modal-mobile/index.js +3 -3
- package/components/virtual-options-list/Component.js +8 -5
- package/components/virtual-options-list/index.css +23 -14
- package/cssm/{Component-aaa9f3a7.js → Component-31b4153d.js} +2 -1
- package/cssm/{Component-e9709f88.js → Component-afba64fc.js} +3 -6
- package/cssm/Component.js +1 -1
- package/cssm/Component.responsive.js +2 -2
- package/cssm/components/arrow/index.module.css +2 -2
- package/cssm/components/base-checkmark/index.module.css +2 -2
- package/cssm/components/base-option/index.module.css +2 -2
- package/cssm/components/base-select/Component.js +1 -1
- package/cssm/components/base-select/index.d.ts +1 -1
- package/cssm/components/base-select/index.js +1 -1
- package/cssm/components/base-select/index.module.css +12 -1
- package/cssm/components/base-select-mobile/Component.js +2 -2
- package/cssm/components/base-select-mobile/checkmark/index.module.css +2 -2
- package/cssm/components/base-select-mobile/index.d.ts +1 -1
- package/cssm/components/base-select-mobile/index.js +2 -2
- package/cssm/components/base-select-mobile/index.module.css +2 -2
- package/cssm/components/base-select-mobile/options-list/index.module.css +2 -2
- package/cssm/components/base-select-mobile/virtual-options-list/index.module.css +2 -2
- package/cssm/components/checkmark/index.module.css +2 -2
- package/cssm/components/field/index.module.css +2 -2
- package/cssm/components/index.js +2 -2
- package/cssm/components/optgroup/index.module.css +2 -2
- package/cssm/components/option/index.module.css +2 -2
- package/cssm/components/options-list/Component.js +6 -3
- package/cssm/components/options-list/index.module.css +12 -3
- package/cssm/components/select-mobile/Component.js +2 -2
- package/cssm/components/select-mobile/index.d.ts +1 -1
- package/cssm/components/select-mobile/index.js +2 -2
- package/cssm/components/select-modal-mobile/Component.js +2 -2
- package/cssm/components/select-modal-mobile/index.d.ts +1 -1
- package/cssm/components/select-modal-mobile/index.js +2 -2
- package/cssm/components/virtual-options-list/Component.js +7 -4
- package/cssm/components/virtual-options-list/index.module.css +12 -3
- package/cssm/index-3885b0d7.d.ts +1 -1
- package/cssm/index.js +2 -2
- package/cssm/presets/index.js +2 -2
- package/cssm/presets/useSelectWithApply/hook.js +2 -2
- package/cssm/presets/useSelectWithApply/options-list-with-apply/Component.js +3 -3
- package/cssm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/cssm/presets/useSelectWithApply/options-list-with-apply/index.js +2 -2
- package/cssm/presets/useSelectWithApply/options-list-with-apply/index.module.css +3 -6
- package/cssm/responsive.js +2 -2
- package/esm/{Component-0a180244.js → Component-802d1cff.js} +6 -9
- package/esm/{Component-4bb3c303.js → Component-9468a354.js} +3 -2
- package/esm/Component.js +1 -1
- package/esm/Component.responsive.js +3 -3
- package/esm/components/arrow/Component.js +1 -1
- package/esm/components/arrow/index.css +5 -5
- package/esm/components/base-checkmark/Component.js +1 -1
- package/esm/components/base-checkmark/index.css +6 -6
- package/esm/components/base-option/Component.js +1 -1
- package/esm/components/base-option/index.css +15 -15
- package/esm/components/base-select/Component.js +1 -1
- package/esm/components/base-select/index.css +19 -8
- package/esm/components/base-select/index.d.ts +1 -1
- package/esm/components/base-select/index.js +1 -1
- package/esm/components/base-select-mobile/Component.js +3 -3
- package/esm/components/base-select-mobile/checkmark/Component.js +1 -1
- package/esm/components/base-select-mobile/checkmark/index.css +8 -8
- package/esm/components/base-select-mobile/index.css +13 -13
- package/esm/components/base-select-mobile/index.d.ts +1 -1
- package/esm/components/base-select-mobile/index.js +3 -3
- package/esm/components/base-select-mobile/options-list/Component.js +1 -1
- package/esm/components/base-select-mobile/options-list/index.css +11 -11
- package/esm/components/base-select-mobile/virtual-options-list/Component.js +1 -1
- package/esm/components/base-select-mobile/virtual-options-list/index.css +17 -17
- package/esm/components/checkmark/Component.js +1 -1
- package/esm/components/checkmark/index.css +12 -12
- package/esm/components/field/Component.js +1 -1
- package/esm/components/field/index.css +11 -11
- package/esm/components/index.js +3 -3
- package/esm/components/optgroup/Component.js +1 -1
- package/esm/components/optgroup/index.css +8 -8
- package/esm/components/option/Component.js +1 -1
- package/esm/components/option/index.css +22 -22
- package/esm/components/options-list/Component.js +7 -4
- package/esm/components/options-list/index.css +17 -8
- package/esm/components/select-mobile/Component.js +3 -3
- package/esm/components/select-mobile/index.d.ts +1 -1
- package/esm/components/select-mobile/index.js +3 -3
- package/esm/components/select-modal-mobile/Component.js +3 -3
- package/esm/components/select-modal-mobile/index.d.ts +1 -1
- package/esm/components/select-modal-mobile/index.js +3 -3
- package/esm/components/virtual-options-list/Component.js +8 -5
- package/esm/components/virtual-options-list/index.css +23 -14
- package/esm/index-3885b0d7.d.ts +1 -1
- package/esm/index.js +3 -3
- package/esm/presets/index.js +3 -3
- package/esm/presets/useLazyLoading/hook.js +2 -2
- package/esm/presets/useLazyLoading/index.css +2 -2
- package/esm/presets/useSelectWithApply/hook.js +3 -3
- package/esm/presets/useSelectWithApply/options-list-with-apply/Component.js +4 -4
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.css +6 -9
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.js +3 -3
- package/esm/presets/useSelectWithLoading/hook.js +1 -1
- package/esm/presets/useSelectWithLoading/index.css +2 -2
- package/esm/responsive.js +3 -3
- package/index-3885b0d7.d.ts +1 -1
- package/index.js +3 -3
- package/modern/{Component-d9a7d67e.js → Component-7337e799.js} +5 -7
- package/modern/{Component-77e84ddc.js → Component-c73c1b2e.js} +3 -2
- package/modern/Component.js +1 -1
- package/modern/Component.responsive.js +3 -3
- package/modern/components/arrow/Component.js +1 -1
- package/modern/components/arrow/index.css +5 -5
- package/modern/components/base-checkmark/Component.js +1 -1
- package/modern/components/base-checkmark/index.css +6 -6
- package/modern/components/base-option/Component.js +1 -1
- package/modern/components/base-option/index.css +15 -15
- package/modern/components/base-select/Component.js +1 -1
- package/modern/components/base-select/index.css +19 -8
- package/modern/components/base-select/index.d.ts +1 -1
- package/modern/components/base-select/index.js +1 -1
- package/modern/components/base-select-mobile/Component.js +3 -3
- package/modern/components/base-select-mobile/checkmark/Component.js +1 -1
- package/modern/components/base-select-mobile/checkmark/index.css +8 -8
- package/modern/components/base-select-mobile/index.css +13 -13
- package/modern/components/base-select-mobile/index.d.ts +1 -1
- package/modern/components/base-select-mobile/index.js +3 -3
- package/modern/components/base-select-mobile/options-list/Component.js +1 -1
- package/modern/components/base-select-mobile/options-list/index.css +11 -11
- package/modern/components/base-select-mobile/virtual-options-list/Component.js +1 -1
- package/modern/components/base-select-mobile/virtual-options-list/index.css +17 -17
- package/modern/components/checkmark/Component.js +1 -1
- package/modern/components/checkmark/index.css +12 -12
- package/modern/components/field/Component.js +1 -1
- package/modern/components/field/index.css +11 -11
- package/modern/components/index.js +3 -3
- package/modern/components/optgroup/Component.js +1 -1
- package/modern/components/optgroup/index.css +8 -8
- package/modern/components/option/Component.js +1 -1
- package/modern/components/option/index.css +22 -22
- package/modern/components/options-list/Component.js +6 -4
- package/modern/components/options-list/index.css +17 -8
- package/modern/components/select-mobile/Component.js +3 -3
- package/modern/components/select-mobile/index.d.ts +1 -1
- package/modern/components/select-mobile/index.js +3 -3
- package/modern/components/select-modal-mobile/Component.js +3 -3
- package/modern/components/select-modal-mobile/index.d.ts +1 -1
- package/modern/components/select-modal-mobile/index.js +3 -3
- package/modern/components/virtual-options-list/Component.js +5 -3
- package/modern/components/virtual-options-list/index.css +23 -14
- package/modern/index-3885b0d7.d.ts +1 -1
- package/modern/index.js +3 -3
- package/modern/presets/index.js +3 -3
- package/modern/presets/useLazyLoading/hook.js +2 -2
- package/modern/presets/useLazyLoading/index.css +2 -2
- package/modern/presets/useSelectWithApply/hook.js +3 -3
- package/modern/presets/useSelectWithApply/options-list-with-apply/Component.js +4 -4
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.css +6 -9
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.js +3 -3
- package/modern/presets/useSelectWithLoading/hook.js +1 -1
- package/modern/presets/useSelectWithLoading/index.css +2 -2
- package/modern/responsive.js +3 -3
- package/package.json +4 -4
- package/presets/index.js +3 -3
- package/presets/useLazyLoading/hook.js +2 -2
- package/presets/useLazyLoading/index.css +2 -2
- package/presets/useSelectWithApply/hook.js +3 -3
- package/presets/useSelectWithApply/options-list-with-apply/Component.js +4 -4
- package/presets/useSelectWithApply/options-list-with-apply/index.css +6 -9
- package/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/index.js +3 -3
- package/presets/useSelectWithLoading/hook.js +1 -1
- package/presets/useSelectWithLoading/index.css +2 -2
- package/responsive.js +3 -3
- /package/{Component-71240601.d.ts → Component-342bab38.d.ts} +0 -0
- /package/{Component-001db41f.d.ts → Component-9475069a.d.ts} +0 -0
- /package/cssm/{Component-aaa9f3a7.d.ts → Component-31b4153d.d.ts} +0 -0
- /package/cssm/{Component-e9709f88.d.ts → Component-afba64fc.d.ts} +0 -0
- /package/esm/{Component-0a180244.d.ts → Component-802d1cff.d.ts} +0 -0
- /package/esm/{Component-4bb3c303.d.ts → Component-9468a354.d.ts} +0 -0
- /package/esm/{intersection-observer-6d12bd0a.d.ts → intersection-observer-3bb4ad40.d.ts} +0 -0
- /package/esm/{intersection-observer-6d12bd0a.js → intersection-observer-3bb4ad40.js} +0 -0
- /package/{intersection-observer-dd747820.d.ts → intersection-observer-28a79b27.d.ts} +0 -0
- /package/{intersection-observer-dd747820.js → intersection-observer-28a79b27.js} +0 -0
- /package/modern/{Component-d9a7d67e.d.ts → Component-7337e799.d.ts} +0 -0
- /package/modern/{Component-77e84ddc.d.ts → Component-c73c1b2e.d.ts} +0 -0
- /package/modern/{intersection-observer-6d12bd0a.d.ts → intersection-observer-3bb4ad40.d.ts} +0 -0
- /package/modern/{intersection-observer-6d12bd0a.js → intersection-observer-3bb4ad40.js} +0 -0
|
@@ -7,7 +7,7 @@ import { useMedia } from '@alfalab/hooks';
|
|
|
7
7
|
import { useVisibleOptions, isGroup } from '../../utils.js';
|
|
8
8
|
import { Optgroup } from '../optgroup/Component.js';
|
|
9
9
|
|
|
10
|
-
var styles = {"optionsList":"
|
|
10
|
+
var styles = {"optionsList":"select__optionsList_25n14","optionsListHeader":"select__optionsListHeader_25n14","optionsListFooter":"select__optionsListFooter_25n14","withBorder":"select__withBorder_25n14","scrollable":"select__scrollable_25n14","emptyPlaceholder":"select__emptyPlaceholder_25n14","l":"select__l_25n14","xl":"select__xl_25n14"};
|
|
11
11
|
require('./index.css')
|
|
12
12
|
|
|
13
13
|
var createCounter = function () {
|
|
@@ -16,7 +16,8 @@ var createCounter = function () {
|
|
|
16
16
|
return function () { return count++; };
|
|
17
17
|
};
|
|
18
18
|
var OptionsList = forwardRef(function (_a, ref) {
|
|
19
|
-
var _b
|
|
19
|
+
var _b;
|
|
20
|
+
var _c = _a.size, size = _c === void 0 ? 's' : _c, className = _a.className, optionGroupClassName = _a.optionGroupClassName, 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 ? 5 : _f, onScroll = _a.onScroll, open = _a.open, header = _a.header, footer = _a.footer, optionsListWidth = _a.optionsListWidth, nativeScrollbarProp = _a.nativeScrollbar, _g = _a.flatOptions, flatOptions = _g === void 0 ? [] : _g;
|
|
20
21
|
var nativeScrollbar = useMedia([[true, '(max-width: 1023px)']], false)[0];
|
|
21
22
|
nativeScrollbar = Boolean(nativeScrollbarProp !== null && nativeScrollbarProp !== void 0 ? nativeScrollbarProp : nativeScrollbar);
|
|
22
23
|
var renderOption = function (option, index) { return (React.createElement(Option, __assign({ key: option.key }, getOptionProps(option, index)))); };
|
|
@@ -43,9 +44,11 @@ var OptionsList = forwardRef(function (_a, ref) {
|
|
|
43
44
|
};
|
|
44
45
|
var renderWithNativeScrollbar = function () { return (React.createElement("div", { className: styles.scrollable, ref: mergeRefs([listRef, ref]), onScroll: onScroll }, renderListItems())); };
|
|
45
46
|
return (React.createElement("div", __assign({}, (nativeScrollbar && { 'data-test-id': dataTestId }), { className: cn(styles.optionsList, styles[size], className) }),
|
|
46
|
-
header,
|
|
47
|
+
header && React.createElement("div", { className: styles.optionsListHeader }, header),
|
|
47
48
|
nativeScrollbar ? renderWithNativeScrollbar() : renderWithCustomScrollbar(),
|
|
48
|
-
footer
|
|
49
|
+
footer && (React.createElement("div", { className: cn(styles.optionsListFooter, (_b = {},
|
|
50
|
+
_b[styles.withBorder] = visibleOptions && flatOptions.length > visibleOptions,
|
|
51
|
+
_b)) }, footer))));
|
|
49
52
|
});
|
|
50
53
|
|
|
51
54
|
export { OptionsList };
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: sxfme */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
|
-
--color-light-
|
|
5
|
-
|
|
4
|
+
--color-light-border-secondary: #e7e9eb;
|
|
5
|
+
--color-light-text-secondary: rgba(11, 31, 53, 0.7); /* 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 */
|
|
6
|
+
} :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 */
|
|
6
7
|
} :root {
|
|
7
8
|
} :root {
|
|
8
9
|
|
|
@@ -28,18 +29,26 @@
|
|
|
28
29
|
/* checkmark */
|
|
29
30
|
|
|
30
31
|
/* optgroup */
|
|
31
|
-
} .
|
|
32
|
+
} .select__optionsList_25n14 {
|
|
32
33
|
overflow: auto;
|
|
33
34
|
width: 100%;
|
|
34
35
|
outline: none;
|
|
35
36
|
box-sizing: border-box;
|
|
36
|
-
} .
|
|
37
|
+
} .select__optionsListHeader_25n14 {
|
|
38
|
+
box-sizing: border-box;
|
|
39
|
+
border-bottom: 1px solid var(--color-light-border-secondary);
|
|
40
|
+
} .select__optionsListFooter_25n14 {
|
|
41
|
+
box-sizing: border-box;
|
|
42
|
+
border-top: 1px solid transparent
|
|
43
|
+
} .select__optionsListFooter_25n14.select__withBorder_25n14 {
|
|
44
|
+
border-top: 1px solid var(--color-light-border-secondary);
|
|
45
|
+
} .select__scrollable_25n14 {
|
|
37
46
|
overflow: auto;
|
|
38
47
|
width: 100%;
|
|
39
|
-
} .
|
|
48
|
+
} .select__emptyPlaceholder_25n14 {
|
|
40
49
|
padding: var(--gap-m) var(--gap-s);
|
|
41
50
|
color: var(--select-options-list-empty-placeholder-color);
|
|
42
|
-
} .
|
|
43
|
-
.
|
|
51
|
+
} .select__l_25n14 .select__emptyPlaceholder_25n14,
|
|
52
|
+
.select__xl_25n14 .select__emptyPlaceholder_25n14 {
|
|
44
53
|
padding: var(--gap-xl) var(--gap-m);
|
|
45
54
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import 'tslib';
|
|
2
2
|
import 'react';
|
|
3
3
|
import '../arrow/Component.js';
|
|
4
|
-
export { S as SelectMobile } from '../../Component-
|
|
4
|
+
export { S as SelectMobile } from '../../Component-802d1cff.js';
|
|
5
5
|
import '../field/Component.js';
|
|
6
6
|
import '../optgroup/Component.js';
|
|
7
7
|
import '../option/Component.js';
|
|
@@ -12,7 +12,7 @@ import 'downshift';
|
|
|
12
12
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
13
13
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
14
14
|
import '../../Component.js';
|
|
15
|
-
import '../../Component-
|
|
15
|
+
import '../../Component-9468a354.js';
|
|
16
16
|
import '@juggle/resize-observer';
|
|
17
17
|
import '@alfalab/core-components-popover/esm';
|
|
18
18
|
import '@alfalab/hooks';
|
|
@@ -31,7 +31,7 @@ import 'react-virtual';
|
|
|
31
31
|
import '../base-option/Component.js';
|
|
32
32
|
import '../base-checkmark/Component.js';
|
|
33
33
|
import '@alfalab/core-components-skeleton/esm';
|
|
34
|
-
import '../../intersection-observer-
|
|
34
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
35
35
|
import '@alfalab/core-components-button/esm';
|
|
36
36
|
import '../base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "../../Component-
|
|
1
|
+
export * from "../../Component-802d1cff";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { S as SelectMobile } from '../../Component-
|
|
1
|
+
export { S as SelectMobile } from '../../Component-802d1cff.js';
|
|
2
2
|
import 'tslib';
|
|
3
3
|
import 'react';
|
|
4
4
|
import '../arrow/Component.js';
|
|
@@ -9,7 +9,7 @@ import 'downshift';
|
|
|
9
9
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
10
10
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
11
11
|
import '../../Component.js';
|
|
12
|
-
import '../../Component-
|
|
12
|
+
import '../../Component-9468a354.js';
|
|
13
13
|
import '@juggle/resize-observer';
|
|
14
14
|
import '@alfalab/core-components-popover/esm';
|
|
15
15
|
import '@alfalab/hooks';
|
|
@@ -31,7 +31,7 @@ import 'react-virtual';
|
|
|
31
31
|
import '../base-option/Component.js';
|
|
32
32
|
import '../base-checkmark/Component.js';
|
|
33
33
|
import '@alfalab/core-components-skeleton/esm';
|
|
34
|
-
import '../../intersection-observer-
|
|
34
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
35
35
|
import '@alfalab/core-components-button/esm';
|
|
36
36
|
import '../base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import 'tslib';
|
|
2
2
|
import 'react';
|
|
3
3
|
import '../arrow/Component.js';
|
|
4
|
-
export { a as SelectModalMobile } from '../../Component-
|
|
4
|
+
export { a as SelectModalMobile } from '../../Component-802d1cff.js';
|
|
5
5
|
import '../field/Component.js';
|
|
6
6
|
import '../optgroup/Component.js';
|
|
7
7
|
import '../option/Component.js';
|
|
@@ -12,7 +12,7 @@ import 'downshift';
|
|
|
12
12
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
13
13
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
14
14
|
import '../../Component.js';
|
|
15
|
-
import '../../Component-
|
|
15
|
+
import '../../Component-9468a354.js';
|
|
16
16
|
import '@juggle/resize-observer';
|
|
17
17
|
import '@alfalab/core-components-popover/esm';
|
|
18
18
|
import '@alfalab/hooks';
|
|
@@ -31,7 +31,7 @@ import 'react-virtual';
|
|
|
31
31
|
import '../base-option/Component.js';
|
|
32
32
|
import '../base-checkmark/Component.js';
|
|
33
33
|
import '@alfalab/core-components-skeleton/esm';
|
|
34
|
-
import '../../intersection-observer-
|
|
34
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
35
35
|
import '@alfalab/core-components-button/esm';
|
|
36
36
|
import '../base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "../../Component-
|
|
1
|
+
export * from "../../Component-802d1cff";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { a as SelectModalMobile } from '../../Component-
|
|
1
|
+
export { a as SelectModalMobile } from '../../Component-802d1cff.js';
|
|
2
2
|
import 'tslib';
|
|
3
3
|
import 'react';
|
|
4
4
|
import '../arrow/Component.js';
|
|
@@ -9,7 +9,7 @@ import 'downshift';
|
|
|
9
9
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
10
10
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
11
11
|
import '../../Component.js';
|
|
12
|
-
import '../../Component-
|
|
12
|
+
import '../../Component-9468a354.js';
|
|
13
13
|
import '@juggle/resize-observer';
|
|
14
14
|
import '@alfalab/core-components-popover/esm';
|
|
15
15
|
import '@alfalab/hooks';
|
|
@@ -31,7 +31,7 @@ import 'react-virtual';
|
|
|
31
31
|
import '../base-option/Component.js';
|
|
32
32
|
import '../base-checkmark/Component.js';
|
|
33
33
|
import '@alfalab/core-components-skeleton/esm';
|
|
34
|
-
import '../../intersection-observer-
|
|
34
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
35
35
|
import '@alfalab/core-components-button/esm';
|
|
36
36
|
import '../base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
@@ -7,17 +7,18 @@ import { useMedia } from '@alfalab/hooks';
|
|
|
7
7
|
import { usePrevious, lastIndexOf, useVisibleOptions, isGroup } from '../../utils.js';
|
|
8
8
|
import { Optgroup } from '../optgroup/Component.js';
|
|
9
9
|
|
|
10
|
-
var styles = {"virtualOptionsList":"
|
|
10
|
+
var styles = {"virtualOptionsList":"select__virtualOptionsList_rpejv","virtualOptionsListHeader":"select__virtualOptionsListHeader_rpejv","virtualOptionsListFooter":"select__virtualOptionsListFooter_rpejv","withBorder":"select__withBorder_rpejv","scrollable":"select__scrollable_rpejv","inner":"select__inner_rpejv","virtualRow":"select__virtualRow_rpejv","highlighted":"select__highlighted_rpejv","emptyPlaceholder":"select__emptyPlaceholder_rpejv","l":"select__l_rpejv","xl":"select__xl_rpejv"};
|
|
11
11
|
require('./index.css')
|
|
12
12
|
|
|
13
13
|
/* eslint-disable react-hooks/exhaustive-deps */
|
|
14
14
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
15
15
|
var VirtualOptionsList = function (_a) {
|
|
16
|
-
var _b
|
|
16
|
+
var _b;
|
|
17
|
+
var _c = _a.size, size = _c === void 0 ? 's' : _c, _d = _a.flatOptions, flatOptions = _d === void 0 ? [] : _d, _e = _a.highlightedIndex, highlightedIndex = _e === void 0 ? -1 : _e, className = _a.className, getOptionProps = _a.getOptionProps, Option = _a.Option, open = _a.open, _f = _a.options, options = _f === void 0 ? [] : _f, _g = _a.overscan, overscan = _g === void 0 ? 10 : _g, _h = _a.Optgroup, Optgroup$1 = _h === void 0 ? Optgroup : _h, dataTestId = _a.dataTestId, emptyPlaceholder = _a.emptyPlaceholder, _j = _a.visibleOptions, visibleOptions = _j === void 0 ? 5 : _j, onScroll = _a.onScroll, header = _a.header, footer = _a.footer, nativeScrollbarProp = _a.nativeScrollbar;
|
|
17
18
|
var listRef = useRef(null);
|
|
18
19
|
var parentRef = useRef(null);
|
|
19
20
|
var scrollbarRef = useRef(null);
|
|
20
|
-
var
|
|
21
|
+
var _k = useState(0), visibleOptionsInvalidateKey = _k[0], setVisibleOptionsInvalidateKey = _k[1];
|
|
21
22
|
var prevHighlightedIndex = usePrevious(highlightedIndex) || -1;
|
|
22
23
|
var rowVirtualizer = useVirtual({
|
|
23
24
|
size: flatOptions.length,
|
|
@@ -106,10 +107,12 @@ var VirtualOptionsList = function (_a) {
|
|
|
106
107
|
var renderWithNativeScrollbar = function () { return (React.createElement("div", { className: styles.scrollable, ref: parentRef, onScroll: onScroll },
|
|
107
108
|
React.createElement("div", __assign({}, contentNodeProps), renderList()))); };
|
|
108
109
|
return (React.createElement("div", { className: cn(styles.virtualOptionsList, styles[size], className), "data-test-id": dataTestId },
|
|
109
|
-
header,
|
|
110
|
+
header && React.createElement("div", { className: styles.virtualOptionsListHeader }, header),
|
|
110
111
|
nativeScrollbar ? renderWithNativeScrollbar() : renderWithCustomScrollbar(),
|
|
111
112
|
emptyPlaceholder && options.length === 0 && (React.createElement("div", { className: styles.emptyPlaceholder }, emptyPlaceholder)),
|
|
112
|
-
footer
|
|
113
|
+
footer && (React.createElement("div", { className: cn(styles.virtualOptionsListFooter, (_b = {},
|
|
114
|
+
_b[styles.withBorder] = visibleOptions && flatOptions.length > visibleOptions,
|
|
115
|
+
_b)) }, footer))));
|
|
113
116
|
};
|
|
114
117
|
|
|
115
118
|
export { VirtualOptionsList };
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 16f78 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-border-primary: #dbdee1;
|
|
5
|
-
--color-light-
|
|
6
|
-
|
|
5
|
+
--color-light-border-secondary: #e7e9eb;
|
|
6
|
+
--color-light-text-secondary: rgba(11, 31, 53, 0.7); /* 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 */
|
|
7
|
+
} :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 */
|
|
7
8
|
} :root {
|
|
8
9
|
} :root {
|
|
9
10
|
|
|
@@ -34,23 +35,31 @@
|
|
|
34
35
|
/* checkmark */
|
|
35
36
|
|
|
36
37
|
/* optgroup */
|
|
37
|
-
} .
|
|
38
|
+
} .select__virtualOptionsList_rpejv {
|
|
38
39
|
width: 100%;
|
|
39
40
|
outline: none;
|
|
40
41
|
box-sizing: border-box;
|
|
41
42
|
position: relative;
|
|
42
|
-
} .
|
|
43
|
+
} .select__virtualOptionsListHeader_rpejv {
|
|
44
|
+
box-sizing: border-box;
|
|
45
|
+
border-bottom: 1px solid var(--color-light-border-secondary);
|
|
46
|
+
} .select__virtualOptionsListFooter_rpejv {
|
|
47
|
+
box-sizing: border-box;
|
|
48
|
+
border-top: 1px solid transparent
|
|
49
|
+
} .select__virtualOptionsListFooter_rpejv.select__withBorder_rpejv {
|
|
50
|
+
border-top: 1px solid var(--color-light-border-secondary);
|
|
51
|
+
} .select__scrollable_rpejv {
|
|
43
52
|
overflow: auto;
|
|
44
53
|
width: 100%;
|
|
45
|
-
} .
|
|
54
|
+
} .select__inner_rpejv {
|
|
46
55
|
position: relative;
|
|
47
56
|
width: 100%;
|
|
48
|
-
} .
|
|
57
|
+
} .select__virtualRow_rpejv {
|
|
49
58
|
position: absolute;
|
|
50
59
|
top: 0;
|
|
51
60
|
left: 0;
|
|
52
61
|
width: 100%
|
|
53
|
-
} .
|
|
62
|
+
} .select__virtualRow_rpejv:before {
|
|
54
63
|
content: '';
|
|
55
64
|
position: absolute;
|
|
56
65
|
z-index: 1;
|
|
@@ -60,15 +69,15 @@
|
|
|
60
69
|
height: 1px;
|
|
61
70
|
background: var(--select-option-divider-background);
|
|
62
71
|
display: var(--select-option-divider-display);
|
|
63
|
-
} .
|
|
72
|
+
} .select__virtualRow_rpejv:first-child:before {
|
|
64
73
|
display: none;
|
|
65
|
-
} .
|
|
66
|
-
.
|
|
74
|
+
} .select__highlighted_rpejv:before,
|
|
75
|
+
.select__highlighted_rpejv + .select__virtualRow_rpejv:before {
|
|
67
76
|
display: none;
|
|
68
|
-
} .
|
|
77
|
+
} .select__emptyPlaceholder_rpejv {
|
|
69
78
|
padding: var(--gap-m) var(--gap-s);
|
|
70
79
|
color: var(--select-options-list-empty-placeholder-color);
|
|
71
|
-
} .
|
|
72
|
-
.
|
|
80
|
+
} .select__l_rpejv .select__emptyPlaceholder_rpejv,
|
|
81
|
+
.select__xl_rpejv .select__emptyPlaceholder_rpejv {
|
|
73
82
|
padding: var(--gap-xl) var(--gap-m);
|
|
74
83
|
}
|
package/esm/index-3885b0d7.d.ts
CHANGED
package/esm/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { Select } from './Component.js';
|
|
2
2
|
export { Arrow } from './components/arrow/Component.js';
|
|
3
|
-
export { B as BaseSelect } from './Component-
|
|
4
|
-
export { b as SELECT_ALL_KEY, S as SelectMobile, a as SelectModalMobile, u as useSelectWithApply } from './Component-
|
|
3
|
+
export { B as BaseSelect } from './Component-9468a354.js';
|
|
4
|
+
export { b as SELECT_ALL_KEY, S as SelectMobile, a as SelectModalMobile, u as useSelectWithApply } from './Component-802d1cff.js';
|
|
5
5
|
export { Field } from './components/field/Component.js';
|
|
6
6
|
export { Optgroup } from './components/optgroup/Component.js';
|
|
7
7
|
export { Option } from './components/option/Component.js';
|
|
@@ -33,7 +33,7 @@ import '@alfalab/core-components-bottom-sheet/esm';
|
|
|
33
33
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
34
34
|
import 'react-virtual';
|
|
35
35
|
import '@alfalab/core-components-skeleton/esm';
|
|
36
|
-
import './intersection-observer-
|
|
36
|
+
import './intersection-observer-3bb4ad40.js';
|
|
37
37
|
import '@alfalab/core-components-button/esm';
|
|
38
38
|
import './components/base-checkmark/Component.js';
|
|
39
39
|
import './components/base-select-mobile/options-list/Component.js';
|
package/esm/presets/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { useSelectWithLoading } from './useSelectWithLoading/hook.js';
|
|
2
2
|
export { useLazyLoading } from './useLazyLoading/hook.js';
|
|
3
|
-
export { b as SELECT_ALL_KEY, u as useSelectWithApply } from '../Component-
|
|
3
|
+
export { b as SELECT_ALL_KEY, u as useSelectWithApply } from '../Component-802d1cff.js';
|
|
4
4
|
import 'tslib';
|
|
5
5
|
import 'react';
|
|
6
6
|
import '@alfalab/core-components-skeleton/esm';
|
|
@@ -12,7 +12,7 @@ import '../components/checkmark/Component.js';
|
|
|
12
12
|
import '@alfalab/core-components-badge/esm';
|
|
13
13
|
import '@alfalab/core-components-checkbox/esm';
|
|
14
14
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
15
|
-
import '../intersection-observer-
|
|
15
|
+
import '../intersection-observer-3bb4ad40.js';
|
|
16
16
|
import '../components/arrow/Component.js';
|
|
17
17
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
18
18
|
import 'react-merge-refs';
|
|
@@ -20,7 +20,7 @@ import 'downshift';
|
|
|
20
20
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
21
21
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
22
22
|
import '../Component.js';
|
|
23
|
-
import '../Component-
|
|
23
|
+
import '../Component-9468a354.js';
|
|
24
24
|
import '@juggle/resize-observer';
|
|
25
25
|
import '@alfalab/core-components-popover/esm';
|
|
26
26
|
import '@alfalab/hooks';
|
|
@@ -2,7 +2,7 @@ import { __spreadArray, __assign } from 'tslib';
|
|
|
2
2
|
import React, { useReducer, useRef, useCallback, useEffect, useMemo } from 'react';
|
|
3
3
|
import { Skeleton } from '@alfalab/core-components-skeleton/esm';
|
|
4
4
|
import { Option } from '../../components/option/Component.js';
|
|
5
|
-
import '../../intersection-observer-
|
|
5
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
6
6
|
import 'classnames';
|
|
7
7
|
import '../../components/base-select-mobile/checkmark/Component.js';
|
|
8
8
|
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
@@ -11,7 +11,7 @@ import '@alfalab/core-components-badge/esm';
|
|
|
11
11
|
import '@alfalab/core-components-checkbox/esm';
|
|
12
12
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
13
13
|
|
|
14
|
-
var styles = {"skeleton":"
|
|
14
|
+
var styles = {"skeleton":"select__skeleton_sjzac"};
|
|
15
15
|
require('./index.css')
|
|
16
16
|
|
|
17
17
|
var DEBOUNCE_TIMEOUT = 300;
|
|
@@ -3,8 +3,8 @@ import 'react';
|
|
|
3
3
|
import '../../Component.js';
|
|
4
4
|
import 'classnames';
|
|
5
5
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
6
|
-
import '../../Component-
|
|
7
|
-
export { b as SELECT_ALL_KEY, u as useSelectWithApply } from '../../Component-
|
|
6
|
+
import '../../Component-9468a354.js';
|
|
7
|
+
export { b as SELECT_ALL_KEY, u as useSelectWithApply } from '../../Component-802d1cff.js';
|
|
8
8
|
import '@alfalab/core-components-form-control/esm';
|
|
9
9
|
import '@alfalab/hooks';
|
|
10
10
|
import '../../utils.js';
|
|
@@ -16,7 +16,7 @@ import '../../components/options-list/Component.js';
|
|
|
16
16
|
import 'react-virtual';
|
|
17
17
|
import '@alfalab/core-components-scrollbar/esm';
|
|
18
18
|
import '@alfalab/core-components-skeleton/esm';
|
|
19
|
-
import '../../intersection-observer-
|
|
19
|
+
import '../../intersection-observer-3bb4ad40.js';
|
|
20
20
|
import '../../components/arrow/Component.js';
|
|
21
21
|
import '../../components/field/Component.js';
|
|
22
22
|
import '../../components/optgroup/Component.js';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import 'tslib';
|
|
2
2
|
import 'react';
|
|
3
|
-
import 'classnames';
|
|
4
3
|
import '@alfalab/core-components-button/esm';
|
|
4
|
+
import 'classnames';
|
|
5
5
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
6
|
-
import '../../../Component-
|
|
7
|
-
export { O as OptionsListWithApply } from '../../../Component-
|
|
6
|
+
import '../../../Component-9468a354.js';
|
|
7
|
+
export { O as OptionsListWithApply } from '../../../Component-802d1cff.js';
|
|
8
8
|
import '@alfalab/core-components-form-control/esm';
|
|
9
9
|
import '@alfalab/hooks';
|
|
10
10
|
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
@@ -32,7 +32,7 @@ import '../../../components/checkmark/Component.js';
|
|
|
32
32
|
import '../../../components/base-option/Component.js';
|
|
33
33
|
import '../../../components/base-checkmark/Component.js';
|
|
34
34
|
import '@alfalab/core-components-skeleton/esm';
|
|
35
|
-
import '../../../intersection-observer-
|
|
35
|
+
import '../../../intersection-observer-3bb4ad40.js';
|
|
36
36
|
import '../../../components/base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
38
38
|
import '../../../components/base-select-mobile/virtual-options-list/Component.js';
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: w1bg3 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
|
-
--color-light-bg-primary: #fff;
|
|
5
|
-
|
|
6
|
-
} :root {
|
|
4
|
+
--color-light-bg-primary: #fff; /* 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 */
|
|
5
|
+
} :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 */
|
|
7
6
|
} :root {
|
|
8
7
|
} :root {
|
|
9
8
|
|
|
@@ -27,12 +26,10 @@
|
|
|
27
26
|
/* checkmark */
|
|
28
27
|
|
|
29
28
|
/* optgroup */
|
|
30
|
-
} .
|
|
29
|
+
} .select__footer_158zs {
|
|
31
30
|
background: var(--color-light-bg-primary);
|
|
32
31
|
padding: var(--gap-s);
|
|
33
32
|
outline: none
|
|
34
|
-
} .
|
|
33
|
+
} .select__footer_158zs > * + * {
|
|
35
34
|
margin-left: var(--gap-xs);
|
|
36
|
-
}
|
|
37
|
-
box-shadow: inset 0 1px 0 var(--color-light-border-secondary);
|
|
38
|
-
}
|
|
35
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "../../../Component-
|
|
1
|
+
export * from "../../../Component-802d1cff";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { O as OptionsListWithApply } from '../../../Component-
|
|
1
|
+
export { O as OptionsListWithApply } from '../../../Component-802d1cff.js';
|
|
2
2
|
import 'tslib';
|
|
3
3
|
import 'react';
|
|
4
4
|
import '../../../components/arrow/Component.js';
|
|
@@ -9,7 +9,7 @@ import 'downshift';
|
|
|
9
9
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
10
10
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
11
11
|
import '../../../Component.js';
|
|
12
|
-
import '../../../Component-
|
|
12
|
+
import '../../../Component-9468a354.js';
|
|
13
13
|
import '@juggle/resize-observer';
|
|
14
14
|
import '@alfalab/core-components-popover/esm';
|
|
15
15
|
import '@alfalab/hooks';
|
|
@@ -31,7 +31,7 @@ import 'react-virtual';
|
|
|
31
31
|
import '../../../components/base-option/Component.js';
|
|
32
32
|
import '../../../components/base-checkmark/Component.js';
|
|
33
33
|
import '@alfalab/core-components-skeleton/esm';
|
|
34
|
-
import '../../../intersection-observer-
|
|
34
|
+
import '../../../intersection-observer-3bb4ad40.js';
|
|
35
35
|
import '@alfalab/core-components-button/esm';
|
|
36
36
|
import '../../../components/base-select-mobile/options-list/Component.js';
|
|
37
37
|
import '@alfalab/core-components-base-modal/esm';
|
|
@@ -10,7 +10,7 @@ import '@alfalab/core-components-badge/esm';
|
|
|
10
10
|
import '@alfalab/core-components-checkbox/esm';
|
|
11
11
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
12
12
|
|
|
13
|
-
var styles = {"skeleton":"
|
|
13
|
+
var styles = {"skeleton":"select__skeleton_193ma"};
|
|
14
14
|
require('./index.css')
|
|
15
15
|
|
|
16
16
|
function useSelectWithLoading(_a) {
|
package/esm/responsive.js
CHANGED
|
@@ -6,7 +6,7 @@ import './Component.js';
|
|
|
6
6
|
import './components/arrow/Component.js';
|
|
7
7
|
import 'classnames';
|
|
8
8
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
9
|
-
import './Component-
|
|
9
|
+
import './Component-9468a354.js';
|
|
10
10
|
import 'react-merge-refs';
|
|
11
11
|
import '@juggle/resize-observer';
|
|
12
12
|
import 'downshift';
|
|
@@ -25,14 +25,14 @@ import '@alfalab/core-components-checkbox/esm';
|
|
|
25
25
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
26
26
|
import './components/options-list/Component.js';
|
|
27
27
|
import '@alfalab/core-components-scrollbar/esm';
|
|
28
|
-
import './Component-
|
|
28
|
+
import './Component-802d1cff.js';
|
|
29
29
|
import '@alfalab/core-components-bottom-sheet/esm';
|
|
30
30
|
import '@alfalab/core-components-modal/esm/mobile';
|
|
31
31
|
import 'react-virtual';
|
|
32
32
|
import './components/base-option/Component.js';
|
|
33
33
|
import './components/base-checkmark/Component.js';
|
|
34
34
|
import '@alfalab/core-components-skeleton/esm';
|
|
35
|
-
import './intersection-observer-
|
|
35
|
+
import './intersection-observer-3bb4ad40.js';
|
|
36
36
|
import '@alfalab/core-components-button/esm';
|
|
37
37
|
import './components/base-select-mobile/options-list/Component.js';
|
|
38
38
|
import '@alfalab/core-components-base-modal/esm';
|
package/index-3885b0d7.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
var Component = require('./Component.js');
|
|
4
4
|
var components_arrow_Component = require('./components/arrow/Component.js');
|
|
5
|
-
var components_baseSelect_Component = require('./Component-
|
|
6
|
-
var presets_useSelectWithApply_optionsListWithApply_Component = require('./Component-
|
|
5
|
+
var components_baseSelect_Component = require('./Component-9475069a.js');
|
|
6
|
+
var presets_useSelectWithApply_optionsListWithApply_Component = require('./Component-342bab38.js');
|
|
7
7
|
var components_field_Component = require('./components/field/Component.js');
|
|
8
8
|
var components_optgroup_Component = require('./components/optgroup/Component.js');
|
|
9
9
|
var components_option_Component = require('./components/option/Component.js');
|
|
@@ -35,7 +35,7 @@ require('@alfalab/core-components-bottom-sheet');
|
|
|
35
35
|
require('@alfalab/core-components-modal/mobile');
|
|
36
36
|
require('react-virtual');
|
|
37
37
|
require('@alfalab/core-components-skeleton');
|
|
38
|
-
require('./intersection-observer-
|
|
38
|
+
require('./intersection-observer-28a79b27.js');
|
|
39
39
|
require('@alfalab/core-components-button');
|
|
40
40
|
require('./components/base-checkmark/Component.js');
|
|
41
41
|
require('./components/base-select-mobile/options-list/Component.js');
|
|
@@ -6,7 +6,7 @@ import { useMultipleSelection, useCombobox } from 'downshift';
|
|
|
6
6
|
import { BottomSheet } from '@alfalab/core-components-bottom-sheet/modern';
|
|
7
7
|
import { ModalMobile } from '@alfalab/core-components-modal/modern/mobile';
|
|
8
8
|
import './Component.js';
|
|
9
|
-
import { g as getDataTestId } from './Component-
|
|
9
|
+
import { g as getDataTestId } from './Component-c73c1b2e.js';
|
|
10
10
|
import { Field } from './components/field/Component.js';
|
|
11
11
|
import { Optgroup } from './components/optgroup/Component.js';
|
|
12
12
|
import { Option } from './components/option/Component.js';
|
|
@@ -17,7 +17,7 @@ import '@alfalab/hooks';
|
|
|
17
17
|
import { processOptions } from './utils.js';
|
|
18
18
|
import { BaseOption } from './components/base-option/Component.js';
|
|
19
19
|
import '@alfalab/core-components-skeleton/modern';
|
|
20
|
-
import './intersection-observer-
|
|
20
|
+
import './intersection-observer-3bb4ad40.js';
|
|
21
21
|
import { Button } from '@alfalab/core-components-button/modern';
|
|
22
22
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
23
23
|
import '@alfalab/core-components-form-control/modern';
|
|
@@ -30,7 +30,7 @@ import { Checkmark } from './components/base-select-mobile/checkmark/Component.j
|
|
|
30
30
|
import { OptionsList as OptionsList$1 } from './components/base-select-mobile/options-list/Component.js';
|
|
31
31
|
import { VirtualOptionsList } from './components/base-select-mobile/virtual-options-list/Component.js';
|
|
32
32
|
|
|
33
|
-
const styles$1 = {"footer":"
|
|
33
|
+
const styles$1 = {"footer":"select__footer_158zs"};
|
|
34
34
|
require('./presets/useSelectWithApply/options-list-with-apply/index.css')
|
|
35
35
|
|
|
36
36
|
const OptionsListWithApply = forwardRef(({ toggleMenu, OptionsList: OptionsList$1 = OptionsList, getOptionProps: defaultGetOptionProps, showClear = true, selectedDraft = [], flatOptions = [], onApply = () => null, onClear = () => null, onClose = () => null, visibleOptions = 5, ...restProps }, ref) => {
|
|
@@ -70,9 +70,7 @@ const OptionsListWithApply = forwardRef(({ toggleMenu, OptionsList: OptionsList$
|
|
|
70
70
|
}, []);
|
|
71
71
|
return (React.createElement(OptionsList$1, { ...restProps, ref: ref, visibleOptions: visibleOptions, toggleMenu: toggleMenu, flatOptions: flatOptions, getOptionProps: getOptionProps, onApply: handleApply, onClear: handleClear, footer: React.createElement("div", {
|
|
72
72
|
// eslint-disable-next-line jsx-a11y/no-noninteractive-tabindex
|
|
73
|
-
tabIndex: 0, className:
|
|
74
|
-
[styles$1.withBorder]: visibleOptions && flatOptions.length > visibleOptions,
|
|
75
|
-
}), ref: footerRef },
|
|
73
|
+
tabIndex: 0, className: styles$1.footer, ref: footerRef },
|
|
76
74
|
React.createElement(Button, { size: 'xxs', view: 'primary', onClick: handleApply }, "\u041F\u0440\u0438\u043C\u0435\u043D\u0438\u0442\u044C"),
|
|
77
75
|
showClear && (React.createElement(Button, { size: 'xxs', view: 'secondary', onClick: handleClear }, "\u0421\u0431\u0440\u043E\u0441\u0438\u0442\u044C"))) }));
|
|
78
76
|
});
|
|
@@ -143,7 +141,7 @@ function useSelectWithApply({ options, selected, onChange = () => null, OptionsL
|
|
|
143
141
|
};
|
|
144
142
|
}
|
|
145
143
|
|
|
146
|
-
const styles = {"component":"
|
|
144
|
+
const styles = {"component":"select__component_13ayh","popoverInner":"select__popoverInner_13ayh","sheet":"select__sheet_13ayh","sheetContent":"select__sheetContent_13ayh","sheetContainer":"select__sheetContainer_13ayh","block":"select__block_13ayh","option":"select__option_13ayh","optionGroup":"select__optionGroup_13ayh"};
|
|
147
145
|
require('./components/base-select-mobile/index.css')
|
|
148
146
|
|
|
149
147
|
const VIRTUAL_OPTIONS_LIST_THRESHOLD = 30;
|