@alfalab/core-components-select 13.2.20 → 14.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Component-3885b0d7.d.ts +1 -1
- package/Component-f1a1856f.d.ts +61 -0
- package/Component-f1a1856f.js +158 -0
- package/Component.js +4 -3
- package/Component.responsive.js +14 -13
- 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.d.ts +5 -0
- package/components/base-select/Component.js +242 -12
- package/components/base-select/index.css +8 -8
- package/components/base-select/index.d.ts +1 -1
- package/components/base-select/index.js +2 -1
- package/components/base-select-mobile/Component.d.ts +46 -0
- package/components/base-select-mobile/Component.js +209 -33
- package/components/base-select-mobile/footer/Component.d.ts +8 -0
- package/components/base-select-mobile/footer/Component.js +34 -0
- package/components/base-select-mobile/footer/index.css +42 -0
- package/components/base-select-mobile/footer/index.js +13 -0
- package/components/base-select-mobile/index.css +10 -19
- package/components/base-select-mobile/index.d.ts +1 -1
- package/components/base-select-mobile/index.js +9 -22
- package/components/checkmark/Component.js +1 -1
- package/components/checkmark/index.css +10 -10
- package/{cssm/components/base-select-mobile/checkmark → components/checkmark-mobile}/Component.d.ts +1 -1
- package/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.js +1 -1
- package/components/{base-select-mobile/checkmark → checkmark-mobile}/index.css +6 -6
- package/components/{base-select-mobile/checkmark → checkmark-mobile}/index.js +2 -2
- package/components/field/Component.js +1 -1
- package/components/field/index.css +9 -9
- package/components/index.js +15 -13
- package/components/optgroup/Component.js +1 -1
- package/components/optgroup/index.css +6 -6
- package/components/option/Component.js +4 -4
- package/components/option/index.css +20 -20
- package/components/option/index.js +2 -2
- package/components/options-list/Component.d.ts +1 -1
- package/components/options-list/Component.js +1 -1
- package/components/options-list/index.css +12 -10
- package/components/select-mobile/Component.js +19 -18
- package/components/select-mobile/index.d.ts +1 -1
- package/components/select-mobile/index.js +16 -15
- package/components/select-modal-mobile/Component.js +19 -18
- package/components/select-modal-mobile/index.d.ts +1 -1
- package/components/select-modal-mobile/index.js +16 -15
- package/components/virtual-options-list/Component.d.ts +2 -7
- package/components/virtual-options-list/Component.js +31 -19
- package/components/virtual-options-list/index.css +19 -16
- package/components/virtual-options-list/index.js +1 -0
- package/cssm/Component-3885b0d7.d.ts +1 -1
- package/cssm/Component-610b3743.d.ts +61 -0
- package/cssm/Component-610b3743.js +168 -0
- package/cssm/Component.js +5 -4
- package/cssm/Component.responsive.js +18 -18
- package/cssm/components/base-select/Component.d.ts +5 -0
- package/cssm/components/base-select/Component.js +241 -13
- package/cssm/components/base-select/index.d.ts +1 -1
- package/cssm/components/base-select/index.js +2 -1
- package/cssm/components/base-select-mobile/Component.d.ts +46 -0
- package/cssm/components/base-select-mobile/Component.js +209 -44
- package/cssm/components/base-select-mobile/footer/Component.d.ts +8 -0
- package/cssm/components/base-select-mobile/footer/Component.js +33 -0
- package/cssm/components/base-select-mobile/footer/index.js +14 -0
- package/cssm/components/base-select-mobile/footer/index.module.css +41 -0
- package/cssm/components/base-select-mobile/index.d.ts +1 -1
- package/cssm/components/base-select-mobile/index.js +11 -33
- package/cssm/components/base-select-mobile/index.module.css +0 -9
- package/{components/base-select-mobile/checkmark → cssm/components/checkmark-mobile}/Component.d.ts +1 -1
- package/cssm/components/{base-select-mobile/checkmark → checkmark-mobile}/index.js +2 -2
- package/cssm/components/index.js +22 -21
- package/cssm/components/option/Component.js +4 -4
- package/cssm/components/option/index.js +3 -3
- package/cssm/components/options-list/Component.d.ts +1 -1
- package/cssm/components/options-list/index.module.css +3 -1
- package/cssm/components/select-mobile/Component.js +26 -26
- package/cssm/components/select-mobile/index.d.ts +1 -1
- package/cssm/components/select-mobile/index.js +19 -19
- package/cssm/components/select-modal-mobile/Component.js +26 -26
- package/cssm/components/select-modal-mobile/index.d.ts +1 -1
- package/cssm/components/select-modal-mobile/index.js +19 -19
- package/cssm/components/virtual-options-list/Component.d.ts +2 -7
- package/cssm/components/virtual-options-list/Component.js +30 -18
- package/cssm/components/virtual-options-list/index.js +1 -0
- package/cssm/components/virtual-options-list/index.module.css +4 -1
- package/cssm/getDataTestId-5c876d98.d.ts +2 -0
- package/cssm/getDataTestId-5c876d98.js +8 -0
- package/{esm/hook-edac5428.d.ts → cssm/hook-4b555174.d.ts} +11 -6
- package/cssm/index-3885b0d7.d.ts +1 -1
- package/cssm/index.js +21 -20
- package/cssm/presets/index.d.ts +1 -1
- package/cssm/presets/index.js +19 -19
- package/cssm/presets/useLazyLoading/hook.js +3 -3
- package/cssm/presets/useSelectWithApply/hook.js +17 -17
- package/cssm/presets/useSelectWithApply/options-list-with-apply/Component.js +35 -35
- package/cssm/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +10 -0
- package/cssm/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +23 -0
- package/cssm/presets/useSelectWithApply/options-list-with-apply/{index.module.css → footer/index.module.css} +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 +19 -19
- package/cssm/presets/useSelectWithLoading/hook.js +3 -3
- package/cssm/responsive.js +15 -15
- package/cssm/types-ebda875c.d.ts +1 -1
- package/cssm/typings.d.ts +1 -1
- package/esm/Component-3885b0d7.d.ts +1 -1
- package/esm/Component-b5248298.d.ts +61 -0
- package/esm/Component-b5248298.js +148 -0
- package/esm/Component.js +4 -3
- package/esm/Component.responsive.js +14 -13
- 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.d.ts +5 -0
- package/esm/components/base-select/Component.js +239 -11
- package/esm/components/base-select/index.css +8 -8
- package/esm/components/base-select/index.d.ts +1 -1
- package/esm/components/base-select/index.js +2 -1
- package/esm/components/base-select-mobile/Component.d.ts +46 -0
- package/esm/components/base-select-mobile/Component.js +206 -32
- package/esm/components/base-select-mobile/footer/Component.d.ts +8 -0
- package/esm/components/base-select-mobile/footer/Component.js +25 -0
- package/esm/components/base-select-mobile/footer/index.css +42 -0
- package/esm/components/base-select-mobile/{options-list → footer}/index.js +1 -4
- package/esm/components/base-select-mobile/index.css +10 -19
- package/esm/components/base-select-mobile/index.d.ts +1 -1
- package/esm/components/base-select-mobile/index.js +8 -21
- package/esm/components/checkmark/Component.js +1 -1
- package/esm/components/checkmark/index.css +10 -10
- package/esm/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.d.ts +1 -1
- package/esm/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.js +1 -1
- package/esm/components/{base-select-mobile/checkmark → checkmark-mobile}/index.css +6 -6
- package/esm/components/field/Component.js +1 -1
- package/esm/components/field/index.css +9 -9
- package/esm/components/index.js +15 -13
- package/esm/components/optgroup/Component.js +1 -1
- package/esm/components/optgroup/index.css +6 -6
- package/esm/components/option/Component.js +3 -3
- package/esm/components/option/index.css +20 -20
- package/esm/components/option/index.js +2 -2
- package/esm/components/options-list/Component.d.ts +1 -1
- package/esm/components/options-list/Component.js +1 -1
- package/esm/components/options-list/index.css +12 -10
- package/esm/components/select-mobile/Component.js +19 -18
- package/esm/components/select-mobile/index.d.ts +1 -1
- package/esm/components/select-mobile/index.js +16 -15
- package/esm/components/select-modal-mobile/Component.js +19 -18
- package/esm/components/select-modal-mobile/index.d.ts +1 -1
- package/esm/components/select-modal-mobile/index.js +16 -15
- package/esm/components/virtual-options-list/Component.d.ts +2 -7
- package/esm/components/virtual-options-list/Component.js +31 -20
- package/esm/components/virtual-options-list/index.css +19 -16
- package/esm/components/virtual-options-list/index.js +1 -0
- package/esm/getDataTestId-015e89f1.d.ts +2 -0
- package/esm/getDataTestId-015e89f1.js +6 -0
- package/{hook-edac5428.d.ts → esm/hook-4b555174.d.ts} +11 -6
- package/esm/index-3885b0d7.d.ts +1 -1
- package/esm/index.js +14 -12
- package/esm/presets/index.d.ts +1 -1
- package/esm/presets/index.js +16 -15
- package/esm/presets/useLazyLoading/hook.js +4 -4
- package/esm/presets/useLazyLoading/index.css +2 -2
- package/esm/presets/useSelectWithApply/hook.js +13 -12
- package/esm/presets/useSelectWithApply/options-list-with-apply/Component.js +27 -26
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +10 -0
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +16 -0
- package/esm/presets/useSelectWithApply/options-list-with-apply/{index.css → footer/index.css} +4 -4
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.js +16 -15
- package/esm/presets/useSelectWithLoading/hook.js +3 -3
- package/esm/presets/useSelectWithLoading/index.css +2 -2
- package/esm/responsive.js +12 -11
- package/esm/types-ebda875c.d.ts +1 -1
- package/esm/typings.d.ts +1 -1
- package/getDataTestId-3deaae20.d.ts +2 -0
- package/getDataTestId-3deaae20.js +8 -0
- package/{cssm/hook-edac5428.d.ts → hook-4b555174.d.ts} +11 -6
- package/index-3885b0d7.d.ts +1 -1
- package/index.js +14 -12
- package/modern/Component-29d24a9b.d.ts +61 -0
- package/modern/Component-29d24a9b.js +162 -0
- package/modern/Component-3885b0d7.d.ts +1 -1
- package/modern/Component.js +4 -3
- package/modern/Component.responsive.js +14 -13
- 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.d.ts +5 -0
- package/modern/components/base-select/Component.js +251 -10
- package/modern/components/base-select/index.css +8 -8
- package/modern/components/base-select/index.d.ts +1 -1
- package/modern/components/base-select/index.js +2 -1
- package/modern/components/base-select-mobile/Component.d.ts +46 -0
- package/modern/components/base-select-mobile/Component.js +220 -31
- package/modern/components/base-select-mobile/footer/Component.d.ts +8 -0
- package/modern/components/base-select-mobile/footer/Component.js +23 -0
- package/modern/components/base-select-mobile/footer/index.css +42 -0
- package/modern/components/base-select-mobile/{options-list → footer}/index.js +1 -3
- package/modern/components/base-select-mobile/index.css +10 -19
- package/modern/components/base-select-mobile/index.d.ts +1 -1
- package/modern/components/base-select-mobile/index.js +8 -21
- package/modern/components/checkmark/Component.js +1 -1
- package/modern/components/checkmark/index.css +10 -10
- package/modern/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.d.ts +1 -1
- package/modern/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.js +1 -1
- package/modern/components/{base-select-mobile/checkmark → checkmark-mobile}/index.css +6 -6
- package/modern/components/field/Component.js +1 -1
- package/modern/components/field/index.css +9 -9
- package/modern/components/index.js +15 -13
- package/modern/components/optgroup/Component.js +1 -1
- package/modern/components/optgroup/index.css +6 -6
- package/modern/components/option/Component.js +3 -3
- package/modern/components/option/index.css +20 -20
- package/modern/components/option/index.js +2 -2
- package/modern/components/options-list/Component.d.ts +1 -1
- package/modern/components/options-list/Component.js +1 -1
- package/modern/components/options-list/index.css +12 -10
- package/modern/components/select-mobile/Component.js +19 -18
- package/modern/components/select-mobile/index.d.ts +1 -1
- package/modern/components/select-mobile/index.js +16 -15
- package/modern/components/select-modal-mobile/Component.js +19 -18
- package/modern/components/select-modal-mobile/index.d.ts +1 -1
- package/modern/components/select-modal-mobile/index.js +16 -15
- package/modern/components/virtual-options-list/Component.d.ts +2 -7
- package/modern/components/virtual-options-list/Component.js +29 -18
- package/modern/components/virtual-options-list/index.css +19 -16
- package/modern/components/virtual-options-list/index.js +1 -0
- package/modern/getDataTestId-b257b571.d.ts +2 -0
- package/modern/getDataTestId-b257b571.js +6 -0
- package/modern/{hook-edac5428.d.ts → hook-4b555174.d.ts} +11 -6
- package/modern/index-3885b0d7.d.ts +1 -1
- package/modern/index.js +14 -12
- package/modern/presets/index.d.ts +1 -1
- package/modern/presets/index.js +16 -15
- package/modern/presets/useLazyLoading/hook.js +4 -4
- package/modern/presets/useLazyLoading/index.css +2 -2
- package/modern/presets/useSelectWithApply/hook.js +13 -12
- package/modern/presets/useSelectWithApply/options-list-with-apply/Component.js +27 -26
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +10 -0
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +13 -0
- package/modern/presets/useSelectWithApply/options-list-with-apply/{index.css → footer/index.css} +4 -4
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.js +16 -15
- package/modern/presets/useSelectWithLoading/hook.js +3 -3
- package/modern/presets/useSelectWithLoading/index.css +2 -2
- package/modern/responsive.js +12 -11
- package/modern/types-ebda875c.d.ts +1 -1
- package/modern/typings.d.ts +1 -1
- package/package.json +4 -4
- package/presets/index.d.ts +1 -1
- package/presets/index.js +16 -15
- package/presets/useLazyLoading/hook.js +4 -4
- package/presets/useLazyLoading/index.css +2 -2
- package/presets/useSelectWithApply/hook.js +13 -12
- package/presets/useSelectWithApply/options-list-with-apply/Component.js +27 -26
- package/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +10 -0
- package/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +24 -0
- package/presets/useSelectWithApply/options-list-with-apply/{index.css → footer/index.css} +4 -4
- package/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/index.js +16 -15
- package/presets/useSelectWithLoading/hook.js +3 -3
- package/presets/useSelectWithLoading/index.css +2 -2
- package/responsive.js +12 -11
- package/types-ebda875c.d.ts +1 -1
- package/typings.d.ts +1 -1
- package/Component-44ef3579.d.ts +0 -6
- package/Component-44ef3579.js +0 -252
- package/Component-ab39b2d3.d.ts +0 -142
- package/Component-ab39b2d3.js +0 -373
- package/components/base-select-mobile/options-list/Component.d.ts +0 -4
- package/components/base-select-mobile/options-list/Component.js +0 -51
- package/components/base-select-mobile/options-list/index.css +0 -60
- package/components/base-select-mobile/options-list/index.js +0 -16
- package/components/base-select-mobile/virtual-options-list/Component.d.ts +0 -5
- package/components/base-select-mobile/virtual-options-list/Component.js +0 -114
- package/components/base-select-mobile/virtual-options-list/index.css +0 -89
- package/components/base-select-mobile/virtual-options-list/index.js +0 -18
- package/cssm/Component-e0df017c.d.ts +0 -6
- package/cssm/Component-e0df017c.js +0 -251
- package/cssm/Component-e4ef870b.d.ts +0 -142
- package/cssm/Component-e4ef870b.js +0 -382
- package/cssm/components/base-select-mobile/options-list/Component.d.ts +0 -4
- package/cssm/components/base-select-mobile/options-list/Component.js +0 -51
- package/cssm/components/base-select-mobile/options-list/index.js +0 -18
- package/cssm/components/base-select-mobile/options-list/index.module.css +0 -59
- package/cssm/components/base-select-mobile/virtual-options-list/Component.d.ts +0 -5
- package/cssm/components/base-select-mobile/virtual-options-list/Component.js +0 -114
- package/cssm/components/base-select-mobile/virtual-options-list/index.js +0 -20
- package/cssm/components/base-select-mobile/virtual-options-list/index.module.css +0 -88
- package/esm/Component-1830cf5e.d.ts +0 -142
- package/esm/Component-1830cf5e.js +0 -360
- package/esm/Component-578c3e05.d.ts +0 -6
- package/esm/Component-578c3e05.js +0 -243
- package/esm/components/base-select-mobile/options-list/Component.d.ts +0 -4
- package/esm/components/base-select-mobile/options-list/Component.js +0 -42
- package/esm/components/base-select-mobile/options-list/index.css +0 -60
- package/esm/components/base-select-mobile/virtual-options-list/Component.d.ts +0 -5
- package/esm/components/base-select-mobile/virtual-options-list/Component.js +0 -105
- package/esm/components/base-select-mobile/virtual-options-list/index.css +0 -89
- package/esm/components/base-select-mobile/virtual-options-list/index.d.ts +0 -1
- package/esm/components/base-select-mobile/virtual-options-list/index.js +0 -10
- package/modern/Component-a4a8e905.d.ts +0 -6
- package/modern/Component-a4a8e905.js +0 -255
- package/modern/Component-ae787d42.d.ts +0 -142
- package/modern/Component-ae787d42.js +0 -370
- package/modern/components/base-select-mobile/checkmark/index.d.ts +0 -1
- package/modern/components/base-select-mobile/options-list/Component.d.ts +0 -4
- package/modern/components/base-select-mobile/options-list/Component.js +0 -37
- package/modern/components/base-select-mobile/options-list/index.css +0 -60
- package/modern/components/base-select-mobile/options-list/index.d.ts +0 -1
- package/modern/components/base-select-mobile/virtual-options-list/Component.d.ts +0 -5
- package/modern/components/base-select-mobile/virtual-options-list/Component.js +0 -99
- package/modern/components/base-select-mobile/virtual-options-list/index.css +0 -89
- package/modern/components/base-select-mobile/virtual-options-list/index.d.ts +0 -1
- package/modern/components/base-select-mobile/virtual-options-list/index.js +0 -9
- /package/components/base-select-mobile/{checkmark → footer}/index.d.ts +0 -0
- /package/components/{base-select-mobile/options-list → checkmark-mobile}/index.d.ts +0 -0
- /package/{components/base-select-mobile/virtual-options-list → cssm/components/base-select-mobile/footer}/index.d.ts +0 -0
- /package/cssm/components/{base-select-mobile/checkmark → checkmark-mobile}/Component.js +0 -0
- /package/cssm/components/{base-select-mobile/checkmark → checkmark-mobile}/index.d.ts +0 -0
- /package/cssm/components/{base-select-mobile/checkmark → checkmark-mobile}/index.module.css +0 -0
- /package/{cssm/components/base-select-mobile/options-list → esm/components/base-select-mobile/footer}/index.d.ts +0 -0
- /package/{cssm/components/base-select-mobile/virtual-options-list → esm/components/checkmark-mobile}/index.d.ts +0 -0
- /package/esm/components/{base-select-mobile/checkmark → checkmark-mobile}/index.js +0 -0
- /package/esm/{intersection-observer-55833352.d.ts → intersection-observer-961b54c8.d.ts} +0 -0
- /package/esm/{intersection-observer-55833352.js → intersection-observer-961b54c8.js} +0 -0
- /package/{intersection-observer-959eb559.d.ts → intersection-observer-d5f3e178.d.ts} +0 -0
- /package/{intersection-observer-959eb559.js → intersection-observer-d5f3e178.js} +0 -0
- /package/{esm/components/base-select-mobile/checkmark → modern/components/base-select-mobile/footer}/index.d.ts +0 -0
- /package/{esm/components/base-select-mobile/options-list → modern/components/checkmark-mobile}/index.d.ts +0 -0
- /package/modern/components/{base-select-mobile/checkmark → checkmark-mobile}/index.js +0 -0
- /package/modern/{intersection-observer-55833352.d.ts → intersection-observer-961b54c8.d.ts} +0 -0
- /package/modern/{intersection-observer-55833352.js → intersection-observer-961b54c8.js} +0 -0
|
@@ -1,37 +1,38 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
+
export { S as SelectMobile } from '../../Component-29d24a9b.js';
|
|
2
3
|
import '../arrow/Component.js';
|
|
3
|
-
|
|
4
|
+
import '../base-select-mobile/Component.js';
|
|
5
|
+
import '../base-select-mobile/footer/Component.js';
|
|
4
6
|
import '../field/Component.js';
|
|
5
7
|
import '../optgroup/Component.js';
|
|
6
8
|
import '../option/Component.js';
|
|
7
|
-
import '
|
|
8
|
-
import '
|
|
9
|
-
import 'react-merge-refs';
|
|
10
|
-
import 'downshift';
|
|
11
|
-
import '@alfalab/core-components-bottom-sheet/modern';
|
|
12
|
-
import '@alfalab/core-components-modal/modern/mobile';
|
|
9
|
+
import '../options-list/Component.js';
|
|
10
|
+
import '../virtual-options-list/Component.js';
|
|
13
11
|
import '../../Component.js';
|
|
14
|
-
import '
|
|
12
|
+
import '../base-select/Component.js';
|
|
13
|
+
import 'react-merge-refs';
|
|
15
14
|
import '@juggle/resize-observer';
|
|
15
|
+
import 'classnames';
|
|
16
|
+
import 'downshift';
|
|
16
17
|
import '@alfalab/core-components-popover/modern';
|
|
17
18
|
import '@alfalab/hooks';
|
|
19
|
+
import '../../getDataTestId-b257b571.js';
|
|
18
20
|
import '../../utils.js';
|
|
19
21
|
import '../native-select/Component.js';
|
|
20
|
-
import '
|
|
21
|
-
import '@alfalab/core-components-scrollbar/modern';
|
|
22
|
+
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
22
23
|
import '@alfalab/core-components-form-control/modern';
|
|
23
|
-
import '../base-select-mobile/checkmark/Component.js';
|
|
24
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
25
24
|
import '../checkmark/Component.js';
|
|
26
25
|
import '@alfalab/core-components-badge/modern';
|
|
27
26
|
import '@alfalab/core-components-checkbox/modern';
|
|
28
27
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
29
|
-
import '
|
|
30
|
-
import '../
|
|
31
|
-
import '
|
|
28
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
29
|
+
import '../checkmark-mobile/Component.js';
|
|
30
|
+
import '@alfalab/core-components-scrollbar/modern';
|
|
32
31
|
import '@alfalab/core-components-skeleton/modern';
|
|
33
|
-
import '../../intersection-observer-
|
|
32
|
+
import '../../intersection-observer-961b54c8.js';
|
|
33
|
+
import '../../presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
34
34
|
import '@alfalab/core-components-button/modern';
|
|
35
|
-
import '
|
|
35
|
+
import '@alfalab/core-components-bottom-sheet/modern';
|
|
36
|
+
import '@alfalab/core-components-modal/modern/mobile';
|
|
36
37
|
import '@alfalab/core-components-base-modal/modern';
|
|
37
|
-
import '
|
|
38
|
+
import 'react-virtual';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "../../Component-
|
|
1
|
+
export * from "../../Component-29d24a9b";
|
|
@@ -1,37 +1,38 @@
|
|
|
1
|
-
export { S as SelectMobile } from '../../Component-
|
|
1
|
+
export { S as SelectMobile } from '../../Component-29d24a9b.js';
|
|
2
2
|
import 'react';
|
|
3
|
+
import '../../Component.js';
|
|
3
4
|
import '../arrow/Component.js';
|
|
4
5
|
import 'classnames';
|
|
5
6
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
7
|
+
import '../base-select/Component.js';
|
|
6
8
|
import 'react-merge-refs';
|
|
7
|
-
import 'downshift';
|
|
8
|
-
import '@alfalab/core-components-bottom-sheet/modern';
|
|
9
|
-
import '@alfalab/core-components-modal/modern/mobile';
|
|
10
|
-
import '../../Component.js';
|
|
11
|
-
import '../../Component-a4a8e905.js';
|
|
12
9
|
import '@juggle/resize-observer';
|
|
10
|
+
import 'downshift';
|
|
13
11
|
import '@alfalab/core-components-popover/modern';
|
|
14
12
|
import '@alfalab/hooks';
|
|
13
|
+
import '../../getDataTestId-b257b571.js';
|
|
15
14
|
import '../../utils.js';
|
|
16
15
|
import '../native-select/Component.js';
|
|
17
16
|
import '../field/Component.js';
|
|
18
17
|
import '@alfalab/core-components-form-control/modern';
|
|
19
18
|
import '../optgroup/Component.js';
|
|
20
19
|
import '../option/Component.js';
|
|
21
|
-
import '../base-select-mobile/checkmark/Component.js';
|
|
22
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
23
20
|
import '../checkmark/Component.js';
|
|
24
21
|
import '@alfalab/core-components-badge/modern';
|
|
25
22
|
import '@alfalab/core-components-checkbox/modern';
|
|
26
23
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
24
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
25
|
+
import '../checkmark-mobile/Component.js';
|
|
27
26
|
import '../options-list/Component.js';
|
|
28
27
|
import '@alfalab/core-components-scrollbar/modern';
|
|
28
|
+
import '../base-select-mobile/Component.js';
|
|
29
|
+
import '@alfalab/core-components-bottom-sheet/modern';
|
|
30
|
+
import '@alfalab/core-components-modal/modern/mobile';
|
|
31
|
+
import '../base-select-mobile/footer/Component.js';
|
|
32
|
+
import '@alfalab/core-components-base-modal/modern';
|
|
33
|
+
import '@alfalab/core-components-button/modern';
|
|
34
|
+
import '../virtual-options-list/Component.js';
|
|
29
35
|
import 'react-virtual';
|
|
30
|
-
import '../base-option/Component.js';
|
|
31
|
-
import '../base-checkmark/Component.js';
|
|
32
36
|
import '@alfalab/core-components-skeleton/modern';
|
|
33
|
-
import '../../intersection-observer-
|
|
34
|
-
import '
|
|
35
|
-
import '../base-select-mobile/options-list/Component.js';
|
|
36
|
-
import '@alfalab/core-components-base-modal/modern';
|
|
37
|
-
import '../base-select-mobile/virtual-options-list/Component.js';
|
|
37
|
+
import '../../intersection-observer-961b54c8.js';
|
|
38
|
+
import '../../presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
@@ -1,37 +1,38 @@
|
|
|
1
1
|
import 'react';
|
|
2
|
+
export { a as SelectModalMobile } from '../../Component-29d24a9b.js';
|
|
2
3
|
import '../arrow/Component.js';
|
|
3
|
-
|
|
4
|
+
import '../base-select-mobile/Component.js';
|
|
5
|
+
import '../base-select-mobile/footer/Component.js';
|
|
4
6
|
import '../field/Component.js';
|
|
5
7
|
import '../optgroup/Component.js';
|
|
6
8
|
import '../option/Component.js';
|
|
7
|
-
import '
|
|
8
|
-
import '
|
|
9
|
-
import 'react-merge-refs';
|
|
10
|
-
import 'downshift';
|
|
11
|
-
import '@alfalab/core-components-bottom-sheet/modern';
|
|
12
|
-
import '@alfalab/core-components-modal/modern/mobile';
|
|
9
|
+
import '../options-list/Component.js';
|
|
10
|
+
import '../virtual-options-list/Component.js';
|
|
13
11
|
import '../../Component.js';
|
|
14
|
-
import '
|
|
12
|
+
import '../base-select/Component.js';
|
|
13
|
+
import 'react-merge-refs';
|
|
15
14
|
import '@juggle/resize-observer';
|
|
15
|
+
import 'classnames';
|
|
16
|
+
import 'downshift';
|
|
16
17
|
import '@alfalab/core-components-popover/modern';
|
|
17
18
|
import '@alfalab/hooks';
|
|
19
|
+
import '../../getDataTestId-b257b571.js';
|
|
18
20
|
import '../../utils.js';
|
|
19
21
|
import '../native-select/Component.js';
|
|
20
|
-
import '
|
|
21
|
-
import '@alfalab/core-components-scrollbar/modern';
|
|
22
|
+
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
22
23
|
import '@alfalab/core-components-form-control/modern';
|
|
23
|
-
import '../base-select-mobile/checkmark/Component.js';
|
|
24
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
25
24
|
import '../checkmark/Component.js';
|
|
26
25
|
import '@alfalab/core-components-badge/modern';
|
|
27
26
|
import '@alfalab/core-components-checkbox/modern';
|
|
28
27
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
29
|
-
import '
|
|
30
|
-
import '../
|
|
31
|
-
import '
|
|
28
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
29
|
+
import '../checkmark-mobile/Component.js';
|
|
30
|
+
import '@alfalab/core-components-scrollbar/modern';
|
|
32
31
|
import '@alfalab/core-components-skeleton/modern';
|
|
33
|
-
import '../../intersection-observer-
|
|
32
|
+
import '../../intersection-observer-961b54c8.js';
|
|
33
|
+
import '../../presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
34
34
|
import '@alfalab/core-components-button/modern';
|
|
35
|
-
import '
|
|
35
|
+
import '@alfalab/core-components-bottom-sheet/modern';
|
|
36
|
+
import '@alfalab/core-components-modal/modern/mobile';
|
|
36
37
|
import '@alfalab/core-components-base-modal/modern';
|
|
37
|
-
import '
|
|
38
|
+
import 'react-virtual';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from "../../Component-
|
|
1
|
+
export * from "../../Component-29d24a9b";
|
|
@@ -1,37 +1,38 @@
|
|
|
1
|
-
export { a as SelectModalMobile } from '../../Component-
|
|
1
|
+
export { a as SelectModalMobile } from '../../Component-29d24a9b.js';
|
|
2
2
|
import 'react';
|
|
3
|
+
import '../../Component.js';
|
|
3
4
|
import '../arrow/Component.js';
|
|
4
5
|
import 'classnames';
|
|
5
6
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
7
|
+
import '../base-select/Component.js';
|
|
6
8
|
import 'react-merge-refs';
|
|
7
|
-
import 'downshift';
|
|
8
|
-
import '@alfalab/core-components-bottom-sheet/modern';
|
|
9
|
-
import '@alfalab/core-components-modal/modern/mobile';
|
|
10
|
-
import '../../Component.js';
|
|
11
|
-
import '../../Component-a4a8e905.js';
|
|
12
9
|
import '@juggle/resize-observer';
|
|
10
|
+
import 'downshift';
|
|
13
11
|
import '@alfalab/core-components-popover/modern';
|
|
14
12
|
import '@alfalab/hooks';
|
|
13
|
+
import '../../getDataTestId-b257b571.js';
|
|
15
14
|
import '../../utils.js';
|
|
16
15
|
import '../native-select/Component.js';
|
|
17
16
|
import '../field/Component.js';
|
|
18
17
|
import '@alfalab/core-components-form-control/modern';
|
|
19
18
|
import '../optgroup/Component.js';
|
|
20
19
|
import '../option/Component.js';
|
|
21
|
-
import '../base-select-mobile/checkmark/Component.js';
|
|
22
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
23
20
|
import '../checkmark/Component.js';
|
|
24
21
|
import '@alfalab/core-components-badge/modern';
|
|
25
22
|
import '@alfalab/core-components-checkbox/modern';
|
|
26
23
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
24
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
25
|
+
import '../checkmark-mobile/Component.js';
|
|
27
26
|
import '../options-list/Component.js';
|
|
28
27
|
import '@alfalab/core-components-scrollbar/modern';
|
|
28
|
+
import '../base-select-mobile/Component.js';
|
|
29
|
+
import '@alfalab/core-components-bottom-sheet/modern';
|
|
30
|
+
import '@alfalab/core-components-modal/modern/mobile';
|
|
31
|
+
import '../base-select-mobile/footer/Component.js';
|
|
32
|
+
import '@alfalab/core-components-base-modal/modern';
|
|
33
|
+
import '@alfalab/core-components-button/modern';
|
|
34
|
+
import '../virtual-options-list/Component.js';
|
|
29
35
|
import 'react-virtual';
|
|
30
|
-
import '../base-option/Component.js';
|
|
31
|
-
import '../base-checkmark/Component.js';
|
|
32
36
|
import '@alfalab/core-components-skeleton/modern';
|
|
33
|
-
import '../../intersection-observer-
|
|
34
|
-
import '
|
|
35
|
-
import '../base-select-mobile/options-list/Component.js';
|
|
36
|
-
import '@alfalab/core-components-base-modal/modern';
|
|
37
|
-
import '../base-select-mobile/virtual-options-list/Component.js';
|
|
37
|
+
import '../../intersection-observer-961b54c8.js';
|
|
38
|
+
import '../../presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
@@ -1,10 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
import { OptionsListProps } from "../../typings";
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Число отрисованных пунктов до\после видимого окна
|
|
6
|
-
*/
|
|
7
|
-
overscan?: number;
|
|
8
|
-
};
|
|
9
|
-
declare const VirtualOptionsList: ({ size, flatOptions, highlightedIndex, className, getOptionProps, Option, open, options, overscan, Optgroup, dataTestId, emptyPlaceholder, visibleOptions, onScroll, header, footer, nativeScrollbar: nativeScrollbarProp, }: VirtualOptionsList) => JSX.Element;
|
|
4
|
+
declare const VirtualOptionsList: React.ForwardRefExoticComponent<OptionsListProps & React.RefAttributes<HTMLDivElement>>;
|
|
10
5
|
export { VirtualOptionsList };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import React, { useRef, useState, useEffect, useMemo } from 'react';
|
|
1
|
+
import React, { forwardRef, useRef, useState, useEffect, useMemo } from 'react';
|
|
2
|
+
import mergeRefs from 'react-merge-refs';
|
|
2
3
|
import { useVirtual } from 'react-virtual';
|
|
3
4
|
import cn from 'classnames';
|
|
4
5
|
import { Scrollbar } from '@alfalab/core-components-scrollbar/modern';
|
|
@@ -6,29 +7,29 @@ import { useMedia } from '@alfalab/hooks';
|
|
|
6
7
|
import { usePrevious, lastIndexOf, useVisibleOptions, isGroup } from '../../utils.js';
|
|
7
8
|
import { Optgroup } from '../optgroup/Component.js';
|
|
8
9
|
|
|
9
|
-
const styles = {"virtualOptionsList":"
|
|
10
|
+
const styles = {"virtualOptionsList":"select__virtualOptionsList_8klep","virtualOptionsListHeader":"select__virtualOptionsListHeader_8klep","virtualOptionsListFooter":"select__virtualOptionsListFooter_8klep","withBorder":"select__withBorder_8klep","scrollable":"select__scrollable_8klep","inner":"select__inner_8klep","virtualRow":"select__virtualRow_8klep","highlighted":"select__highlighted_8klep","emptyPlaceholder":"select__emptyPlaceholder_8klep","l":"select__l_8klep","xl":"select__xl_8klep"};
|
|
10
11
|
require('./index.css')
|
|
11
12
|
|
|
12
|
-
|
|
13
|
-
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
14
|
-
const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -1, className, getOptionProps, Option, open, options = [], overscan = 10, Optgroup: Optgroup$1 = Optgroup, dataTestId, emptyPlaceholder, visibleOptions = 5, onScroll, header, footer, nativeScrollbar: nativeScrollbarProp, }) => {
|
|
13
|
+
const VirtualOptionsList = forwardRef(({ size = 's', flatOptions = [], highlightedIndex = -1, className, getOptionProps, Option, open, options = [], Optgroup: Optgroup$1 = Optgroup, dataTestId, emptyPlaceholder, visibleOptions = 5, header, footer, optionsListWidth, onScroll, nativeScrollbar: nativeScrollbarProp, }, ref) => {
|
|
15
14
|
const listRef = useRef(null);
|
|
16
15
|
const parentRef = useRef(null);
|
|
17
16
|
const scrollbarRef = useRef(null);
|
|
18
17
|
const [visibleOptionsInvalidateKey, setVisibleOptionsInvalidateKey] = useState(0);
|
|
19
18
|
const prevHighlightedIndex = usePrevious(highlightedIndex) || -1;
|
|
19
|
+
let [nativeScrollbar] = useMedia([[true, '(max-width: 1023px)']], false);
|
|
20
20
|
const rowVirtualizer = useVirtual({
|
|
21
21
|
size: flatOptions.length,
|
|
22
|
-
parentRef,
|
|
23
|
-
overscan,
|
|
22
|
+
parentRef: (ref || parentRef),
|
|
23
|
+
overscan: 15,
|
|
24
24
|
});
|
|
25
|
-
|
|
25
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
26
26
|
nativeScrollbar = Boolean(nativeScrollbarProp ?? nativeScrollbar);
|
|
27
27
|
// Сколл к выбранному пункту при открытии меню
|
|
28
28
|
useEffect(() => {
|
|
29
29
|
if (open) {
|
|
30
30
|
rowVirtualizer.scrollToIndex(highlightedIndex, { align: 'end' });
|
|
31
31
|
}
|
|
32
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
32
33
|
}, [open]);
|
|
33
34
|
// Скролл к пункту, которого нет на экране
|
|
34
35
|
useEffect(() => {
|
|
@@ -37,6 +38,7 @@ const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -
|
|
|
37
38
|
if (!rowVirtualizer.virtualItems.some((option) => option.index === highlightedIndex)) {
|
|
38
39
|
rowVirtualizer.scrollToIndex(highlightedIndex, { align: 'end' });
|
|
39
40
|
}
|
|
41
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
40
42
|
}, [highlightedIndex]);
|
|
41
43
|
// Циклическая навигация
|
|
42
44
|
useEffect(() => {
|
|
@@ -50,6 +52,7 @@ const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -
|
|
|
50
52
|
if (prevHighlightedIndex >= lastNonDisabled && highlightedIndex === 0) {
|
|
51
53
|
rowVirtualizer.scrollToIndex(0);
|
|
52
54
|
}
|
|
55
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
53
56
|
}, [prevHighlightedIndex, highlightedIndex]);
|
|
54
57
|
useEffect(() => {
|
|
55
58
|
setVisibleOptionsInvalidateKey(
|
|
@@ -81,11 +84,6 @@ const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -
|
|
|
81
84
|
return acc;
|
|
82
85
|
}, {});
|
|
83
86
|
}, [options]);
|
|
84
|
-
const contentNodeProps = {
|
|
85
|
-
className: styles.inner,
|
|
86
|
-
style: { height: `${rowVirtualizer.totalSize}px` },
|
|
87
|
-
ref: listRef,
|
|
88
|
-
};
|
|
89
87
|
const renderList = () => rowVirtualizer.virtualItems.map((virtualRow) => {
|
|
90
88
|
const option = flatOptions[virtualRow.index];
|
|
91
89
|
const group = options[groupStartIndexes[virtualRow.index]];
|
|
@@ -95,11 +93,24 @@ const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -
|
|
|
95
93
|
transform: `translateY(${virtualRow.start}px)`,
|
|
96
94
|
} },
|
|
97
95
|
group && React.createElement(Optgroup$1, { label: group.label }),
|
|
98
|
-
!isGroup(option) && React.createElement(Option, { ...getOptionProps(option, virtualRow.index) })));
|
|
96
|
+
!isGroup(option) && (React.createElement(Option, { ...getOptionProps(option, virtualRow.index) }))));
|
|
99
97
|
});
|
|
100
|
-
const
|
|
101
|
-
|
|
102
|
-
|
|
98
|
+
const contentNodeProps = {
|
|
99
|
+
className: styles.inner,
|
|
100
|
+
style: { height: `${rowVirtualizer.totalSize}px` },
|
|
101
|
+
ref: listRef,
|
|
102
|
+
};
|
|
103
|
+
const renderWithCustomScrollbar = () => (React.createElement(Scrollbar, { className: styles.scrollable, ref: scrollbarRef, horizontalAutoStretch: optionsListWidth === 'content', scrollableNodeProps: { onScroll, ref: parentRef }, contentNodeProps: contentNodeProps }, renderList()));
|
|
104
|
+
const renderWithNativeScrollbar = () => {
|
|
105
|
+
if (visibleOptions) {
|
|
106
|
+
return (React.createElement("div", { className: styles.scrollable, ref: mergeRefs([parentRef, ref]), onScroll: onScroll },
|
|
107
|
+
React.createElement("div", { ...contentNodeProps }, renderList())));
|
|
108
|
+
}
|
|
109
|
+
return React.createElement("div", { ...contentNodeProps }, renderList());
|
|
110
|
+
};
|
|
111
|
+
if (options.length === 0 && !emptyPlaceholder) {
|
|
112
|
+
return null;
|
|
113
|
+
}
|
|
103
114
|
return (React.createElement("div", { className: cn(styles.virtualOptionsList, styles[size], className), "data-test-id": dataTestId },
|
|
104
115
|
header && React.createElement("div", { className: styles.virtualOptionsListHeader }, header),
|
|
105
116
|
nativeScrollbar ? renderWithNativeScrollbar() : renderWithCustomScrollbar(),
|
|
@@ -107,6 +118,6 @@ const VirtualOptionsList = ({ size = 's', flatOptions = [], highlightedIndex = -
|
|
|
107
118
|
footer && (React.createElement("div", { className: cn(styles.virtualOptionsListFooter, {
|
|
108
119
|
[styles.withBorder]: visibleOptions && flatOptions.length > visibleOptions,
|
|
109
120
|
}) }, footer))));
|
|
110
|
-
};
|
|
121
|
+
});
|
|
111
122
|
|
|
112
123
|
export { VirtualOptionsList };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: y762s */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-border-primary: #dcdcdd;
|
|
@@ -35,31 +35,34 @@
|
|
|
35
35
|
/* checkmark */
|
|
36
36
|
|
|
37
37
|
/* optgroup */
|
|
38
|
-
} .
|
|
38
|
+
} .select__virtualOptionsList_8klep {
|
|
39
39
|
width: 100%;
|
|
40
40
|
outline: none;
|
|
41
41
|
box-sizing: border-box;
|
|
42
|
-
position:
|
|
43
|
-
} .
|
|
42
|
+
position: sticky;
|
|
43
|
+
} .select__virtualOptionsListHeader_8klep {
|
|
44
44
|
box-sizing: border-box;
|
|
45
45
|
border-bottom: 1px solid var(--color-light-border-secondary);
|
|
46
|
-
} .
|
|
46
|
+
} .select__virtualOptionsListFooter_8klep {
|
|
47
|
+
position: sticky;
|
|
48
|
+
bottom: 0;
|
|
47
49
|
box-sizing: border-box;
|
|
48
50
|
border-top: 1px solid transparent
|
|
49
|
-
} .
|
|
51
|
+
} .select__virtualOptionsListFooter_8klep.select__withBorder_8klep {
|
|
50
52
|
border-top: 1px solid var(--color-light-border-secondary);
|
|
51
|
-
} .
|
|
53
|
+
} .select__scrollable_8klep {
|
|
54
|
+
position: relative;
|
|
52
55
|
overflow: auto;
|
|
53
56
|
width: 100%;
|
|
54
|
-
} .
|
|
57
|
+
} .select__inner_8klep {
|
|
55
58
|
position: relative;
|
|
56
59
|
width: 100%;
|
|
57
|
-
} .
|
|
60
|
+
} .select__virtualRow_8klep {
|
|
58
61
|
position: absolute;
|
|
59
62
|
top: 0;
|
|
60
63
|
left: 0;
|
|
61
64
|
width: 100%
|
|
62
|
-
} .
|
|
65
|
+
} .select__virtualRow_8klep:before {
|
|
63
66
|
content: '';
|
|
64
67
|
position: absolute;
|
|
65
68
|
z-index: 1;
|
|
@@ -69,15 +72,15 @@
|
|
|
69
72
|
height: 1px;
|
|
70
73
|
background: var(--select-option-divider-background);
|
|
71
74
|
display: var(--select-option-divider-display);
|
|
72
|
-
} .
|
|
75
|
+
} .select__virtualRow_8klep:first-child:before {
|
|
73
76
|
display: none;
|
|
74
|
-
} .
|
|
75
|
-
.
|
|
77
|
+
} .select__highlighted_8klep:before,
|
|
78
|
+
.select__highlighted_8klep + .select__virtualRow_8klep:before {
|
|
76
79
|
display: none;
|
|
77
|
-
} .
|
|
80
|
+
} .select__emptyPlaceholder_8klep {
|
|
78
81
|
padding: var(--gap-m) var(--gap-s);
|
|
79
82
|
color: var(--select-options-list-empty-placeholder-color);
|
|
80
|
-
} .
|
|
81
|
-
.
|
|
83
|
+
} .select__l_8klep .select__emptyPlaceholder_8klep,
|
|
84
|
+
.select__xl_8klep .select__emptyPlaceholder_8klep {
|
|
82
85
|
padding: var(--gap-xl) var(--gap-m);
|
|
83
86
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { BaseSelectProps, OptionShape } from "./index";
|
|
3
|
-
type
|
|
3
|
+
type UseSelectWithApplyProps = {
|
|
4
4
|
/**
|
|
5
5
|
* Список выбранных пунктов
|
|
6
6
|
*/
|
|
@@ -17,6 +17,10 @@ type useSelectWithApplyProps = {
|
|
|
17
17
|
* Компонент выпадающего меню
|
|
18
18
|
*/
|
|
19
19
|
OptionsList?: BaseSelectProps['OptionsList'];
|
|
20
|
+
/**
|
|
21
|
+
* Пропсы, которые будут прокинуты в компонент списка
|
|
22
|
+
*/
|
|
23
|
+
optionsListProps?: BaseSelectProps['optionsListProps'];
|
|
20
24
|
/**
|
|
21
25
|
* Показывать кнопку очистки
|
|
22
26
|
*/
|
|
@@ -27,15 +31,16 @@ type useSelectWithApplyProps = {
|
|
|
27
31
|
showSelectAll?: boolean;
|
|
28
32
|
};
|
|
29
33
|
declare const SELECT_ALL_KEY = "select_all";
|
|
30
|
-
declare function useSelectWithApply({ options, selected, onChange, OptionsList, showClear, showSelectAll, }:
|
|
34
|
+
declare function useSelectWithApply({ options, selected, onChange, OptionsList, optionsListProps, showClear, showSelectAll, }: UseSelectWithApplyProps): {
|
|
31
35
|
OptionsList: import("react").ForwardRefExoticComponent<import("./index").OptionsListProps & {
|
|
32
36
|
showClear?: boolean | undefined;
|
|
33
37
|
onClose?: (() => void) | undefined;
|
|
34
38
|
selectedDraft?: OptionShape[] | undefined;
|
|
35
|
-
OptionsList?: import("react").FC<import("./index").OptionsListProps & import("react").RefAttributes<
|
|
36
|
-
|
|
39
|
+
OptionsList?: import("react").FC<import("./index").OptionsListProps & import("react").RefAttributes<HTMLDivElement>> | undefined;
|
|
40
|
+
Footer?: import("react").FC<import("./presets/useSelectWithApply/options-list-with-apply/footer/Component").FooterProps> | undefined;
|
|
41
|
+
} & import("react").RefAttributes<HTMLDivElement>>;
|
|
37
42
|
optionsListProps: {
|
|
38
|
-
OptionsList: import("react").FC<import("./index").OptionsListProps
|
|
43
|
+
OptionsList: import("react").FC<import("./index").OptionsListProps & import("react").RefAttributes<HTMLDivElement>> | undefined;
|
|
39
44
|
showClear: boolean;
|
|
40
45
|
onClear: () => void;
|
|
41
46
|
onApply: () => void;
|
|
@@ -51,4 +56,4 @@ declare function useSelectWithApply({ options, selected, onChange, OptionsList,
|
|
|
51
56
|
onChange: (payload: import("./index").BaseSelectChangePayload) => void;
|
|
52
57
|
selected: string | OptionShape | (string | OptionShape)[] | null | undefined;
|
|
53
58
|
};
|
|
54
|
-
export { SELECT_ALL_KEY, useSelectWithApply };
|
|
59
|
+
export { UseSelectWithApplyProps, SELECT_ALL_KEY, useSelectWithApply };
|
package/modern/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 {
|
|
4
|
-
export { b as SELECT_ALL_KEY, S as SelectMobile, a as SelectModalMobile, u as useSelectWithApply } from './Component-
|
|
3
|
+
export { BaseSelect } from './components/base-select/Component.js';
|
|
4
|
+
export { b as SELECT_ALL_KEY, S as SelectMobile, a as SelectModalMobile, u as useSelectWithApply } from './Component-29d24a9b.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';
|
|
@@ -19,22 +19,24 @@ import '@juggle/resize-observer';
|
|
|
19
19
|
import 'downshift';
|
|
20
20
|
import '@alfalab/core-components-popover/modern';
|
|
21
21
|
import '@alfalab/hooks';
|
|
22
|
+
import './getDataTestId-b257b571.js';
|
|
22
23
|
import './components/native-select/Component.js';
|
|
24
|
+
import './components/base-select-mobile/Component.js';
|
|
23
25
|
import '@alfalab/core-components-bottom-sheet/modern';
|
|
24
26
|
import '@alfalab/core-components-modal/modern/mobile';
|
|
25
|
-
import '
|
|
26
|
-
import '@alfalab/core-components-
|
|
27
|
-
import '@alfalab/core-components-skeleton/modern';
|
|
28
|
-
import './intersection-observer-55833352.js';
|
|
27
|
+
import './components/base-select-mobile/footer/Component.js';
|
|
28
|
+
import '@alfalab/core-components-base-modal/modern';
|
|
29
29
|
import '@alfalab/core-components-button/modern';
|
|
30
30
|
import '@alfalab/core-components-form-control/modern';
|
|
31
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
32
31
|
import '@alfalab/core-components-badge/modern';
|
|
33
32
|
import '@alfalab/core-components-checkbox/modern';
|
|
34
33
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
35
|
-
import '
|
|
36
|
-
import '
|
|
37
|
-
import './
|
|
38
|
-
import '
|
|
39
|
-
import './components/base-select-mobile/virtual-options-list/Component.js';
|
|
34
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
35
|
+
import '@alfalab/core-components-skeleton/modern';
|
|
36
|
+
import './intersection-observer-961b54c8.js';
|
|
37
|
+
import './presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
40
38
|
import './components/checkmark/Component.js';
|
|
39
|
+
import './components/checkmark-mobile/Component.js';
|
|
40
|
+
import '@alfalab/core-components-scrollbar/modern';
|
|
41
|
+
import 'react-virtual';
|
|
42
|
+
import './components/base-checkmark/Component.js';
|
package/modern/presets/index.js
CHANGED
|
@@ -1,28 +1,27 @@
|
|
|
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-29d24a9b.js';
|
|
4
4
|
import 'react';
|
|
5
5
|
import '@alfalab/core-components-skeleton/modern';
|
|
6
6
|
import '../components/option/Component.js';
|
|
7
7
|
import 'classnames';
|
|
8
|
-
import '../components/base-select-mobile/checkmark/Component.js';
|
|
9
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
10
8
|
import '../components/checkmark/Component.js';
|
|
11
9
|
import '@alfalab/core-components-badge/modern';
|
|
12
10
|
import '@alfalab/core-components-checkbox/modern';
|
|
13
11
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
14
|
-
import '
|
|
12
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
13
|
+
import '../components/checkmark-mobile/Component.js';
|
|
14
|
+
import '../intersection-observer-961b54c8.js';
|
|
15
|
+
import '../Component.js';
|
|
15
16
|
import '../components/arrow/Component.js';
|
|
16
17
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
18
|
+
import '../components/base-select/Component.js';
|
|
17
19
|
import 'react-merge-refs';
|
|
18
|
-
import 'downshift';
|
|
19
|
-
import '@alfalab/core-components-bottom-sheet/modern';
|
|
20
|
-
import '@alfalab/core-components-modal/modern/mobile';
|
|
21
|
-
import '../Component.js';
|
|
22
|
-
import '../Component-a4a8e905.js';
|
|
23
20
|
import '@juggle/resize-observer';
|
|
21
|
+
import 'downshift';
|
|
24
22
|
import '@alfalab/core-components-popover/modern';
|
|
25
23
|
import '@alfalab/hooks';
|
|
24
|
+
import '../getDataTestId-b257b571.js';
|
|
26
25
|
import '../utils.js';
|
|
27
26
|
import '../components/native-select/Component.js';
|
|
28
27
|
import '../components/field/Component.js';
|
|
@@ -30,10 +29,12 @@ import '@alfalab/core-components-form-control/modern';
|
|
|
30
29
|
import '../components/optgroup/Component.js';
|
|
31
30
|
import '../components/options-list/Component.js';
|
|
32
31
|
import '@alfalab/core-components-scrollbar/modern';
|
|
33
|
-
import '
|
|
34
|
-
import '
|
|
35
|
-
import '
|
|
36
|
-
import '
|
|
37
|
-
import '../components/base-select-mobile/options-list/Component.js';
|
|
32
|
+
import '../components/base-select-mobile/Component.js';
|
|
33
|
+
import '@alfalab/core-components-bottom-sheet/modern';
|
|
34
|
+
import '@alfalab/core-components-modal/modern/mobile';
|
|
35
|
+
import '../components/base-select-mobile/footer/Component.js';
|
|
38
36
|
import '@alfalab/core-components-base-modal/modern';
|
|
39
|
-
import '
|
|
37
|
+
import '@alfalab/core-components-button/modern';
|
|
38
|
+
import '../components/virtual-options-list/Component.js';
|
|
39
|
+
import 'react-virtual';
|
|
40
|
+
import './useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import React, { useReducer, useRef, useCallback, useEffect, useMemo } from 'react';
|
|
2
2
|
import { Skeleton } from '@alfalab/core-components-skeleton/modern';
|
|
3
3
|
import { Option } from '../../components/option/Component.js';
|
|
4
|
-
import '../../intersection-observer-
|
|
4
|
+
import '../../intersection-observer-961b54c8.js';
|
|
5
5
|
import 'classnames';
|
|
6
|
-
import '../../components/base-select-mobile/checkmark/Component.js';
|
|
7
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
8
6
|
import '../../components/checkmark/Component.js';
|
|
9
7
|
import '@alfalab/core-components-badge/modern';
|
|
10
8
|
import '@alfalab/core-components-checkbox/modern';
|
|
11
9
|
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
10
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
11
|
+
import '../../components/checkmark-mobile/Component.js';
|
|
12
12
|
|
|
13
|
-
const styles = {"skeleton":"
|
|
13
|
+
const styles = {"skeleton":"select__skeleton_2ycp0"};
|
|
14
14
|
require('./index.css')
|
|
15
15
|
|
|
16
16
|
const DEBOUNCE_TIMEOUT = 300;
|