@alfalab/core-components-select 14.3.4 → 15.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.desktop.d.ts +19 -0
- package/{Component.js → Component.desktop.js} +6 -6
- package/Component.mobile-ebda875c.d.ts +6 -0
- package/Component.mobile-f1f15074.d.ts +387 -0
- package/Component.mobile.d.ts +41 -0
- package/Component.mobile.js +62 -0
- package/Component.modal.mobile.d.ts +60 -0
- package/Component.modal.mobile.js +62 -0
- package/Component.responsive.d.ts +1 -1
- package/Component.responsive.js +26 -25
- package/components/arrow/Component.d.ts +2 -1
- package/components/arrow/Component.js +1 -1
- package/components/arrow/index.css +3 -3
- package/components/base-checkmark/Component.d.ts +2 -1
- package/components/base-checkmark/Component.js +1 -1
- package/components/base-checkmark/index.css +4 -4
- package/components/base-option/Component.js +1 -1
- package/components/base-option/index.css +13 -13
- package/components/base-select/Component.js +6 -6
- package/components/base-select/index.css +8 -8
- package/components/base-select/index.js +1 -1
- package/components/base-select-mobile/Component.d.ts +3 -3
- package/components/base-select-mobile/Component.js +13 -9
- package/components/base-select-mobile/footer/Component.d.ts +2 -1
- package/components/base-select-mobile/footer/Component.js +4 -4
- package/components/base-select-mobile/footer/index.css +5 -5
- package/components/base-select-mobile/footer/index.js +1 -1
- package/components/base-select-mobile/index.css +13 -11
- package/components/base-select-mobile/index.js +1 -2
- package/components/checkmark/Component.d.ts +2 -1
- package/components/checkmark/Component.js +1 -1
- package/components/checkmark/index.css +10 -10
- package/components/checkmark-mobile/Component.d.ts +2 -1
- package/components/checkmark-mobile/Component.js +1 -1
- package/components/checkmark-mobile/index.css +6 -6
- package/components/field/Component.d.ts +9 -1
- package/components/field/Component.js +19 -16
- package/components/field/index.css +38 -11
- package/components/field/index.js +0 -1
- package/components/index.d.ts +0 -2
- package/components/index.js +4 -19
- package/components/optgroup/Component.d.ts +2 -1
- package/components/optgroup/Component.js +1 -1
- package/components/optgroup/index.css +6 -6
- package/components/option/Component.js +1 -1
- package/components/option/index.css +20 -20
- package/components/options-list/Component.js +1 -1
- package/components/options-list/index.css +9 -9
- package/components/virtual-options-list/Component.js +1 -1
- package/components/virtual-options-list/index.css +15 -15
- package/cssm/Component.desktop.d.ts +19 -0
- package/cssm/{Component.js → Component.desktop.js} +6 -6
- package/cssm/Component.mobile-ebda875c.d.ts +6 -0
- package/cssm/Component.mobile-f1f15074.d.ts +387 -0
- package/cssm/Component.mobile.d.ts +41 -0
- package/cssm/Component.mobile.js +74 -0
- package/cssm/Component.modal.mobile.d.ts +60 -0
- package/cssm/Component.modal.mobile.js +74 -0
- package/cssm/Component.responsive.d.ts +1 -1
- package/cssm/Component.responsive.js +30 -33
- package/cssm/components/arrow/Component.d.ts +2 -1
- package/cssm/components/base-checkmark/Component.d.ts +2 -1
- package/cssm/components/base-select/Component.js +5 -5
- package/cssm/components/base-select/index.js +1 -1
- package/cssm/components/base-select-mobile/Component.d.ts +3 -3
- package/cssm/components/base-select-mobile/Component.js +12 -8
- package/cssm/components/base-select-mobile/footer/Component.d.ts +2 -1
- package/cssm/components/base-select-mobile/footer/Component.js +3 -3
- package/cssm/components/base-select-mobile/footer/index.js +1 -1
- package/cssm/components/base-select-mobile/index.js +1 -2
- package/cssm/components/base-select-mobile/index.module.css +4 -2
- package/cssm/components/checkmark/Component.d.ts +2 -1
- package/cssm/components/checkmark-mobile/Component.d.ts +2 -1
- package/cssm/components/field/Component.d.ts +9 -1
- package/cssm/components/field/Component.js +18 -15
- package/cssm/components/field/index.js +0 -1
- package/cssm/components/field/index.module.css +31 -4
- package/cssm/components/index.d.ts +0 -2
- package/cssm/components/index.js +7 -28
- package/cssm/components/optgroup/Component.d.ts +2 -1
- package/cssm/desktop-63dec22f.d.ts +6 -0
- package/cssm/desktop.d.ts +2 -0
- package/cssm/desktop.js +44 -0
- package/cssm/hook-97e6e688.d.ts +16 -0
- package/cssm/hook-97e6e688.js +110 -0
- package/{esm/hook-b4e70cb0.d.ts → cssm/hook-9ea9e32c.d.ts} +9 -7
- package/cssm/index-ebda875c.d.ts +20 -60
- package/cssm/index.d.ts +2 -5
- package/cssm/index.js +34 -61
- package/cssm/mobile-96988a65.d.ts +2 -0
- package/cssm/mobile.d.ts +5 -4
- package/cssm/mobile.js +15 -24
- package/cssm/presets/index.d.ts +1 -1
- package/cssm/presets/index.js +8 -36
- package/cssm/presets/useLazyLoading/hook.d.ts +1 -1
- package/cssm/presets/useLazyLoading/hook.js +900 -4
- package/cssm/presets/useSelectWithApply/hook.js +9 -48
- package/cssm/presets/useSelectWithApply/options-list-with-apply/Component.js +3 -42
- package/cssm/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +2 -1
- package/cssm/presets/useSelectWithApply/options-list-with-apply/footer/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 +10 -49
- package/cssm/presets/useSelectWithLoading/hook.d.ts +1 -1
- package/cssm/shared.d.ts +5 -0
- package/cssm/shared.js +77 -0
- package/cssm/typings-9211a437.d.ts +95 -0
- package/cssm/typings-baf4875b.d.ts +52 -0
- package/desktop-63dec22f.d.ts +6 -0
- package/desktop.d.ts +2 -0
- package/{responsive.js → desktop.js} +5 -19
- package/esm/Component.desktop.d.ts +19 -0
- package/esm/{Component.js → Component.desktop.js} +6 -6
- package/esm/Component.mobile-ebda875c.d.ts +6 -0
- package/esm/Component.mobile-f1f15074.d.ts +387 -0
- package/esm/Component.mobile.d.ts +41 -0
- package/esm/Component.mobile.js +54 -0
- package/esm/Component.modal.mobile.d.ts +60 -0
- package/esm/Component.modal.mobile.js +54 -0
- package/esm/Component.responsive.d.ts +1 -1
- package/esm/Component.responsive.js +26 -25
- package/esm/components/arrow/Component.d.ts +2 -1
- package/esm/components/arrow/Component.js +1 -1
- package/esm/components/arrow/index.css +3 -3
- package/esm/components/base-checkmark/Component.d.ts +2 -1
- package/esm/components/base-checkmark/Component.js +1 -1
- package/esm/components/base-checkmark/index.css +4 -4
- package/esm/components/base-option/Component.js +1 -1
- package/esm/components/base-option/index.css +13 -13
- package/esm/components/base-select/Component.js +2 -2
- package/esm/components/base-select/index.css +8 -8
- package/esm/components/base-select/index.js +1 -1
- package/esm/components/base-select-mobile/Component.d.ts +3 -3
- package/esm/components/base-select-mobile/Component.js +9 -5
- package/esm/components/base-select-mobile/footer/Component.d.ts +2 -1
- package/esm/components/base-select-mobile/footer/Component.js +4 -4
- package/esm/components/base-select-mobile/footer/index.css +5 -5
- package/esm/components/base-select-mobile/footer/index.js +1 -1
- package/esm/components/base-select-mobile/index.css +13 -11
- package/esm/components/base-select-mobile/index.js +1 -2
- package/esm/components/checkmark/Component.d.ts +2 -1
- package/esm/components/checkmark/Component.js +1 -1
- package/esm/components/checkmark/index.css +10 -10
- package/esm/components/checkmark-mobile/Component.d.ts +2 -1
- package/esm/components/checkmark-mobile/Component.js +1 -1
- package/esm/components/checkmark-mobile/index.css +6 -6
- package/esm/components/field/Component.d.ts +9 -1
- package/esm/components/field/Component.js +19 -16
- package/esm/components/field/index.css +38 -11
- package/esm/components/field/index.js +0 -1
- package/esm/components/index.d.ts +0 -2
- package/esm/components/index.js +4 -17
- package/esm/components/optgroup/Component.d.ts +2 -1
- package/esm/components/optgroup/Component.js +1 -1
- package/esm/components/optgroup/index.css +6 -6
- package/esm/components/option/Component.js +1 -1
- package/esm/components/option/index.css +20 -20
- package/esm/components/options-list/Component.js +1 -1
- package/esm/components/options-list/index.css +9 -9
- package/esm/components/virtual-options-list/Component.js +1 -1
- package/esm/components/virtual-options-list/index.css +15 -15
- package/esm/desktop-63dec22f.d.ts +6 -0
- package/esm/desktop.d.ts +2 -0
- package/esm/{responsive.js → desktop.js} +4 -18
- package/esm/hook-326a5cea.d.ts +16 -0
- package/esm/hook-326a5cea.js +102 -0
- package/{cssm/hook-b4e70cb0.d.ts → esm/hook-9ea9e32c.d.ts} +9 -7
- package/esm/index-ebda875c.d.ts +20 -60
- package/esm/index.d.ts +2 -5
- package/esm/index.js +27 -29
- package/esm/mobile-96988a65.d.ts +2 -0
- package/esm/mobile.d.ts +5 -4
- package/esm/mobile.js +12 -16
- package/esm/presets/index.d.ts +1 -1
- package/esm/presets/index.js +6 -25
- package/esm/presets/useLazyLoading/hook.d.ts +1 -1
- package/esm/presets/useLazyLoading/hook.js +899 -4
- package/esm/presets/useSelectWithApply/hook.js +7 -33
- package/esm/presets/useSelectWithApply/options-list-with-apply/Component.js +2 -28
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +2 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +4 -4
- package/esm/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/esm/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/esm/presets/useSelectWithApply/options-list-with-apply/index.js +8 -34
- package/esm/presets/useSelectWithLoading/hook.d.ts +1 -1
- package/esm/presets/useSelectWithLoading/hook.js +1 -1
- package/esm/presets/useSelectWithLoading/index.css +2 -2
- package/esm/shared.d.ts +5 -0
- package/esm/shared.js +37 -0
- package/esm/typings-9211a437.d.ts +95 -0
- package/esm/typings-baf4875b.d.ts +52 -0
- package/hook-6e94be9c.d.ts +16 -0
- package/hook-6e94be9c.js +110 -0
- package/{hook-b4e70cb0.d.ts → hook-9ea9e32c.d.ts} +9 -7
- package/index-ebda875c.d.ts +20 -60
- package/index.d.ts +2 -5
- package/index.js +28 -51
- package/mobile-96988a65.d.ts +2 -0
- package/mobile.d.ts +5 -4
- package/mobile.js +14 -18
- package/modern/Component.desktop.d.ts +19 -0
- package/modern/{Component.js → Component.desktop.js} +7 -4
- package/modern/Component.mobile-ebda875c.d.ts +6 -0
- package/modern/Component.mobile-f1f15074.d.ts +387 -0
- package/modern/Component.mobile.d.ts +41 -0
- package/modern/Component.mobile.js +61 -0
- package/modern/Component.modal.mobile.d.ts +60 -0
- package/modern/Component.modal.mobile.js +61 -0
- package/modern/Component.responsive.d.ts +1 -1
- package/modern/Component.responsive.js +26 -25
- package/modern/components/arrow/Component.d.ts +2 -1
- package/modern/components/arrow/Component.js +1 -1
- package/modern/components/arrow/index.css +3 -3
- package/modern/components/base-checkmark/Component.d.ts +2 -1
- package/modern/components/base-checkmark/Component.js +1 -1
- package/modern/components/base-checkmark/index.css +4 -4
- package/modern/components/base-option/Component.js +1 -1
- package/modern/components/base-option/index.css +13 -13
- package/modern/components/base-select/Component.js +2 -2
- package/modern/components/base-select/index.css +8 -8
- package/modern/components/base-select/index.js +1 -1
- package/modern/components/base-select-mobile/Component.d.ts +3 -3
- package/modern/components/base-select-mobile/Component.js +9 -5
- package/modern/components/base-select-mobile/footer/Component.d.ts +2 -1
- package/modern/components/base-select-mobile/footer/Component.js +4 -4
- package/modern/components/base-select-mobile/footer/index.css +5 -5
- package/modern/components/base-select-mobile/footer/index.js +1 -1
- package/modern/components/base-select-mobile/index.css +13 -11
- package/modern/components/base-select-mobile/index.js +1 -2
- package/modern/components/checkmark/Component.d.ts +2 -1
- package/modern/components/checkmark/Component.js +1 -1
- package/modern/components/checkmark/index.css +10 -10
- package/modern/components/checkmark-mobile/Component.d.ts +2 -1
- package/modern/components/checkmark-mobile/Component.js +1 -1
- package/modern/components/checkmark-mobile/index.css +6 -6
- package/modern/components/field/Component.d.ts +9 -1
- package/modern/components/field/Component.js +17 -14
- package/modern/components/field/index.css +38 -11
- package/modern/components/field/index.js +0 -1
- package/modern/components/index.d.ts +0 -2
- package/modern/components/index.js +4 -17
- package/modern/components/optgroup/Component.d.ts +2 -1
- package/modern/components/optgroup/Component.js +1 -1
- package/modern/components/optgroup/index.css +6 -6
- package/modern/components/option/Component.js +1 -1
- package/modern/components/option/index.css +20 -20
- package/modern/components/options-list/Component.js +1 -1
- package/modern/components/options-list/index.css +9 -9
- package/modern/components/virtual-options-list/Component.js +1 -1
- package/modern/components/virtual-options-list/index.css +15 -15
- package/modern/desktop-63dec22f.d.ts +6 -0
- package/modern/desktop.d.ts +2 -0
- package/modern/{responsive.js → desktop.js} +4 -18
- package/modern/{hook-b4e70cb0.d.ts → hook-9ea9e32c.d.ts} +9 -7
- package/modern/hook-e0fd0350.d.ts +16 -0
- package/modern/{Component-ecb2a41a.js → hook-e0fd0350.js} +3 -66
- package/modern/index-ebda875c.d.ts +20 -60
- package/modern/index.d.ts +2 -5
- package/modern/index.js +27 -29
- package/modern/mobile-96988a65.d.ts +2 -0
- package/modern/mobile.d.ts +5 -4
- package/modern/mobile.js +12 -16
- package/modern/presets/index.d.ts +1 -1
- package/modern/presets/index.js +6 -25
- package/modern/presets/useLazyLoading/hook.d.ts +1 -1
- package/modern/presets/useLazyLoading/hook.js +899 -4
- package/modern/presets/useSelectWithApply/hook.js +7 -33
- package/modern/presets/useSelectWithApply/options-list-with-apply/Component.js +2 -28
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +2 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +4 -4
- package/modern/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/modern/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/modern/presets/useSelectWithApply/options-list-with-apply/index.js +8 -34
- package/modern/presets/useSelectWithLoading/hook.d.ts +1 -1
- package/modern/presets/useSelectWithLoading/hook.js +1 -1
- package/modern/presets/useSelectWithLoading/index.css +2 -2
- package/modern/shared.d.ts +5 -0
- package/modern/shared.js +36 -0
- package/modern/typings-9211a437.d.ts +95 -0
- package/modern/typings-baf4875b.d.ts +52 -0
- package/package.json +37 -12
- package/presets/index.d.ts +1 -1
- package/presets/index.js +6 -25
- package/presets/useLazyLoading/hook.d.ts +1 -1
- package/presets/useLazyLoading/hook.js +899 -4
- package/presets/useSelectWithApply/hook.js +7 -33
- package/presets/useSelectWithApply/options-list-with-apply/Component.js +2 -28
- package/presets/useSelectWithApply/options-list-with-apply/footer/Component.d.ts +2 -1
- package/presets/useSelectWithApply/options-list-with-apply/footer/Component.js +4 -4
- package/presets/useSelectWithApply/options-list-with-apply/footer/index.css +3 -3
- package/presets/useSelectWithApply/options-list-with-apply/header/Component.js +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/header/index.css +3 -3
- package/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/presets/useSelectWithApply/options-list-with-apply/index.js +8 -34
- package/presets/useSelectWithLoading/hook.d.ts +1 -1
- package/presets/useSelectWithLoading/hook.js +1 -1
- package/presets/useSelectWithLoading/index.css +2 -2
- package/shared.d.ts +5 -0
- package/shared.js +63 -0
- package/src/Component.desktop.tsx +52 -0
- package/src/Component.mobile.tsx +149 -0
- package/src/Component.modal.mobile.tsx +144 -0
- package/src/Component.responsive.tsx +59 -0
- package/src/components/arrow/Component.tsx +12 -0
- package/src/components/arrow/index.module.css +15 -0
- package/src/components/arrow/index.ts +1 -0
- package/src/components/base-checkmark/Component.tsx +33 -0
- package/src/components/base-checkmark/index.module.css +18 -0
- package/src/components/base-checkmark/index.ts +1 -0
- package/src/components/base-option/Component.tsx +57 -0
- package/src/components/base-option/index.module.css +67 -0
- package/src/components/base-option/index.ts +1 -0
- package/src/components/base-select/Component.tsx +478 -0
- package/src/components/base-select/index.module.css +68 -0
- package/src/components/base-select/index.ts +1 -0
- package/src/components/base-select-mobile/Component.tsx +486 -0
- package/src/components/base-select-mobile/footer/Component.tsx +46 -0
- package/src/components/base-select-mobile/footer/index.module.css +23 -0
- package/src/components/base-select-mobile/footer/index.ts +1 -0
- package/src/components/base-select-mobile/index.module.css +48 -0
- package/src/components/base-select-mobile/index.ts +1 -0
- package/src/components/checkmark/Component.tsx +56 -0
- package/src/components/checkmark/index.module.css +48 -0
- package/src/components/checkmark/index.ts +1 -0
- package/src/components/checkmark-mobile/Component.tsx +18 -0
- package/src/components/checkmark-mobile/index.module.css +28 -0
- package/src/components/checkmark-mobile/index.ts +1 -0
- package/src/components/field/Component.tsx +110 -0
- package/src/components/field/index.module.css +60 -0
- package/src/components/field/index.ts +1 -0
- package/src/components/index.ts +8 -0
- package/src/components/native-select/Component.tsx +60 -0
- package/src/components/native-select/index.ts +1 -0
- package/src/components/optgroup/Component.tsx +15 -0
- package/src/components/optgroup/index.module.css +30 -0
- package/src/components/optgroup/index.ts +1 -0
- package/src/components/option/Component.tsx +65 -0
- package/src/components/option/index.module.css +108 -0
- package/src/components/option/index.ts +1 -0
- package/src/components/options-list/Component.tsx +140 -0
- package/src/components/options-list/index.module.css +40 -0
- package/src/components/options-list/index.ts +1 -0
- package/src/components/virtual-options-list/Component.tsx +217 -0
- package/src/components/virtual-options-list/index.module.css +76 -0
- package/src/components/virtual-options-list/index.ts +1 -0
- package/src/consts.ts +1 -0
- package/src/desktop.ts +1 -0
- package/src/index.ts +4 -0
- package/src/mobile.ts +5 -0
- package/src/presets/index.ts +3 -0
- package/src/presets/useLazyLoading/hook.tsx +309 -0
- package/src/presets/useSelectWithApply/hook.tsx +154 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/Component.tsx +106 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/footer/Component.tsx +37 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/footer/index.module.css +11 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/header/Component.tsx +26 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/header/index.module.css +9 -0
- package/src/presets/useSelectWithApply/options-list-with-apply/index.ts +1 -0
- package/src/presets/useSelectWithLoading/hook.tsx +40 -0
- package/src/shared.ts +5 -0
- package/src/typings.ts +691 -0
- package/src/utils.ts +154 -0
- package/src/vars.css +57 -0
- package/typings-9211a437.d.ts +95 -0
- package/typings-baf4875b.d.ts +52 -0
- package/Component-01f08370.d.ts +0 -108
- package/Component-01f08370.js +0 -165
- package/Component-3885b0d7.d.ts +0 -169
- package/Component.d.ts +0 -104
- package/Component.mobile-b2c0420d.d.ts +0 -93
- package/components/select-mobile/Component.d.ts +0 -0
- package/components/select-mobile/Component.js +0 -49
- package/components/select-mobile/index.d.ts +0 -1
- package/components/select-mobile/index.js +0 -49
- package/components/select-modal-mobile/Component.d.ts +0 -0
- package/components/select-modal-mobile/Component.js +0 -49
- package/components/select-modal-mobile/index.d.ts +0 -1
- package/components/select-modal-mobile/index.js +0 -49
- package/cssm/Component-3885b0d7.d.ts +0 -169
- package/cssm/Component-4727d474.d.ts +0 -108
- package/cssm/Component-4727d474.js +0 -175
- package/cssm/Component.d.ts +0 -104
- package/cssm/Component.mobile-b2c0420d.d.ts +0 -93
- package/cssm/components/select-mobile/Component.d.ts +0 -0
- package/cssm/components/select-mobile/Component.js +0 -66
- package/cssm/components/select-mobile/index.d.ts +0 -1
- package/cssm/components/select-mobile/index.js +0 -66
- package/cssm/components/select-modal-mobile/Component.d.ts +0 -0
- package/cssm/components/select-modal-mobile/Component.js +0 -66
- package/cssm/components/select-modal-mobile/index.d.ts +0 -1
- package/cssm/components/select-modal-mobile/index.js +0 -66
- package/cssm/getDataTestId-5c876d98.d.ts +0 -2
- package/cssm/getDataTestId-5c876d98.js +0 -8
- package/cssm/index-3885b0d7.d.ts +0 -3
- package/cssm/intersection-observer-9ec5cf59.d.ts +0 -1
- package/cssm/intersection-observer-9ec5cf59.js +0 -893
- package/cssm/responsive.d.ts +0 -2
- package/cssm/responsive.js +0 -67
- package/cssm/types-ebda875c.d.ts +0 -113
- package/esm/Component-3885b0d7.d.ts +0 -169
- package/esm/Component-5e2bc757.d.ts +0 -108
- package/esm/Component-5e2bc757.js +0 -155
- package/esm/Component.d.ts +0 -104
- package/esm/Component.mobile-b2c0420d.d.ts +0 -93
- package/esm/components/select-mobile/Component.d.ts +0 -0
- package/esm/components/select-mobile/Component.js +0 -41
- package/esm/components/select-mobile/index.d.ts +0 -1
- package/esm/components/select-mobile/index.js +0 -41
- package/esm/components/select-modal-mobile/Component.d.ts +0 -0
- package/esm/components/select-modal-mobile/Component.js +0 -41
- package/esm/components/select-modal-mobile/index.d.ts +0 -1
- package/esm/components/select-modal-mobile/index.js +0 -41
- package/esm/getDataTestId-fc7d4653.d.ts +0 -2
- package/esm/getDataTestId-fc7d4653.js +0 -6
- package/esm/index-3885b0d7.d.ts +0 -3
- package/esm/intersection-observer-6768cbd0.d.ts +0 -1
- package/esm/intersection-observer-6768cbd0.js +0 -891
- package/esm/presets/useLazyLoading/index.css +0 -8
- package/esm/responsive.d.ts +0 -2
- package/esm/types-ebda875c.d.ts +0 -113
- package/getDataTestId-18fbdb35.d.ts +0 -2
- package/getDataTestId-18fbdb35.js +0 -8
- package/index-3885b0d7.d.ts +0 -3
- package/intersection-observer-0413a170.d.ts +0 -1
- package/intersection-observer-0413a170.js +0 -893
- package/modern/Component-3885b0d7.d.ts +0 -169
- package/modern/Component-ecb2a41a.d.ts +0 -108
- package/modern/Component.d.ts +0 -104
- package/modern/Component.mobile-b2c0420d.d.ts +0 -93
- package/modern/components/select-mobile/Component.d.ts +0 -0
- package/modern/components/select-mobile/Component.js +0 -40
- package/modern/components/select-mobile/index.d.ts +0 -1
- package/modern/components/select-mobile/index.js +0 -40
- package/modern/components/select-modal-mobile/Component.d.ts +0 -0
- package/modern/components/select-modal-mobile/Component.js +0 -40
- package/modern/components/select-modal-mobile/index.d.ts +0 -1
- package/modern/components/select-modal-mobile/index.js +0 -40
- package/modern/getDataTestId-6120c308.d.ts +0 -2
- package/modern/getDataTestId-6120c308.js +0 -6
- package/modern/index-3885b0d7.d.ts +0 -3
- package/modern/intersection-observer-6768cbd0.d.ts +0 -1
- package/modern/intersection-observer-6768cbd0.js +0 -891
- package/modern/presets/useLazyLoading/index.css +0 -8
- package/modern/responsive.d.ts +0 -2
- package/modern/types-ebda875c.d.ts +0 -113
- package/presets/useLazyLoading/index.css +0 -8
- package/responsive.d.ts +0 -2
- package/types-ebda875c.d.ts +0 -113
- /package/{cssm/presets/useLazyLoading → src/presets/useSelectWithLoading}/index.module.css +0 -0
|
@@ -1,50 +1,51 @@
|
|
|
1
1
|
import React, { forwardRef } from 'react';
|
|
2
2
|
import { useMedia } from '@alfalab/hooks';
|
|
3
|
-
import {
|
|
3
|
+
import { SelectDesktop } from './Component.desktop.js';
|
|
4
|
+
import { SelectMobile } from './Component.mobile.js';
|
|
5
|
+
import '@alfalab/core-components-form-control/modern/desktop';
|
|
6
|
+
import './components/arrow/Component.js';
|
|
4
7
|
import 'classnames';
|
|
5
8
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
6
9
|
import './components/base-select/Component.js';
|
|
7
|
-
import { S as SelectMobile } from './Component-ecb2a41a.js';
|
|
8
|
-
import '@alfalab/core-components-form-control/modern';
|
|
9
|
-
import '@alfalab/core-components-badge/modern';
|
|
10
|
-
import '@alfalab/core-components-checkbox/modern';
|
|
11
|
-
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
12
|
-
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
13
|
-
import './components/options-list/Component.js';
|
|
14
|
-
import './components/virtual-options-list/Component.js';
|
|
15
|
-
import './components/arrow/Component.js';
|
|
16
|
-
import './components/field/Component.js';
|
|
17
|
-
import './utils.js';
|
|
18
|
-
import './components/optgroup/Component.js';
|
|
19
|
-
import './components/option/Component.js';
|
|
20
|
-
import './components/checkmark/Component.js';
|
|
21
|
-
import './components/checkmark-mobile/Component.js';
|
|
22
10
|
import 'react-merge-refs';
|
|
23
11
|
import '@juggle/resize-observer';
|
|
24
12
|
import 'downshift';
|
|
25
13
|
import '@alfalab/core-components-popover/modern';
|
|
26
|
-
import '
|
|
14
|
+
import '@alfalab/core-components-shared/modern';
|
|
15
|
+
import './utils.js';
|
|
27
16
|
import './components/native-select/Component.js';
|
|
28
|
-
import './
|
|
17
|
+
import './components/field/Component.js';
|
|
18
|
+
import './components/optgroup/Component.js';
|
|
19
|
+
import './components/option/Component.js';
|
|
20
|
+
import './components/checkmark/Component.js';
|
|
21
|
+
import '@alfalab/core-components-badge/modern';
|
|
22
|
+
import '@alfalab/core-components-checkbox/modern';
|
|
23
|
+
import '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
24
|
+
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
25
|
+
import './components/checkmark-mobile/Component.js';
|
|
26
|
+
import './components/options-list/Component.js';
|
|
27
|
+
import '@alfalab/core-components-scrollbar/modern';
|
|
28
|
+
import './consts.js';
|
|
29
|
+
import '@alfalab/core-components-form-control/modern/mobile';
|
|
29
30
|
import './components/base-select-mobile/Component.js';
|
|
30
31
|
import '@alfalab/core-components-bottom-sheet/modern';
|
|
31
32
|
import '@alfalab/core-components-modal/modern/mobile';
|
|
32
33
|
import './components/base-select-mobile/footer/Component.js';
|
|
33
34
|
import '@alfalab/core-components-base-modal/modern';
|
|
34
|
-
import '@alfalab/core-components-button/modern';
|
|
35
|
-
import '
|
|
36
|
-
import './intersection-observer-6768cbd0.js';
|
|
37
|
-
import './consts.js';
|
|
38
|
-
import './presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
39
|
-
import '@alfalab/core-components-scrollbar/modern';
|
|
35
|
+
import '@alfalab/core-components-button/modern/mobile';
|
|
36
|
+
import './components/virtual-options-list/Component.js';
|
|
40
37
|
import 'react-virtual';
|
|
38
|
+
import './hook-e0fd0350.js';
|
|
39
|
+
import './presets/useSelectWithApply/options-list-with-apply/footer/Component.js';
|
|
40
|
+
import '@alfalab/core-components-button/modern/desktop';
|
|
41
|
+
import './presets/useSelectWithApply/options-list-with-apply/header/Component.js';
|
|
41
42
|
|
|
42
43
|
const SelectResponsive = forwardRef(({ footer, swipeable, bottomSheetProps, OptionsList, onScroll, fieldProps, breakpoint = 1024, ...restProps }, ref) => {
|
|
43
44
|
const [view] = useMedia([
|
|
44
45
|
['mobile', `(max-width: ${breakpoint - 1}px)`],
|
|
45
46
|
['desktop', `(min-width: ${breakpoint}px)`],
|
|
46
47
|
], 'desktop');
|
|
47
|
-
return view === 'desktop' ? (React.createElement(
|
|
48
|
+
return view === 'desktop' ? (React.createElement(SelectDesktop, { OptionsList: OptionsList, onScroll: onScroll, ...restProps, ref: ref, fieldProps: fieldProps })) : (React.createElement(SelectMobile, { footer: footer, swipeable: swipeable, bottomSheetProps: bottomSheetProps, fieldProps: fieldProps, ...restProps, ref: ref }));
|
|
48
49
|
});
|
|
49
50
|
|
|
50
51
|
export { SelectResponsive };
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
import { ArrowProps } from "../../typings";
|
|
3
|
-
declare const Arrow: ({ open, className }: ArrowProps) => JSX.Element;
|
|
4
|
+
declare const Arrow: ({ open, className }: ArrowProps) => React.JSX.Element;
|
|
4
5
|
export { Arrow };
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { ChevronDownMIcon } from '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
4
4
|
|
|
5
|
-
const styles = {"arrow":"
|
|
5
|
+
const styles = {"arrow":"select__arrow_1hzcy","open":"select__open_1hzcy"};
|
|
6
6
|
require('./index.css')
|
|
7
7
|
|
|
8
8
|
const Arrow = ({ open, className }) => (React.createElement(ChevronDownMIcon, { className: cn(styles.arrow, className, { [styles.open]: open }) }));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: niexi */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-graphic-primary: #0e0e0e; /* 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 */
|
|
@@ -26,13 +26,13 @@
|
|
|
26
26
|
/* checkmark */
|
|
27
27
|
|
|
28
28
|
/* optgroup */
|
|
29
|
-
} .
|
|
29
|
+
} .select__arrow_1hzcy {
|
|
30
30
|
display: block;
|
|
31
31
|
width: 24px;
|
|
32
32
|
height: 24px;
|
|
33
33
|
color: var(--select-arrow-color);
|
|
34
34
|
|
|
35
35
|
transition: transform 0.15s ease-in-out, opacity 0.2s ease;
|
|
36
|
-
} .
|
|
36
|
+
} .select__open_1hzcy {
|
|
37
37
|
transform: var(--arrow-transform);
|
|
38
38
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
import { CheckmarkProps } from "../../typings";
|
|
3
|
-
declare const BaseCheckmark: ({ selected, disabled, className, multiple, }: CheckmarkProps) => JSX.Element;
|
|
4
|
+
declare const BaseCheckmark: ({ selected, disabled, className, multiple, }: CheckmarkProps) => React.JSX.Element;
|
|
4
5
|
export { BaseCheckmark };
|
|
@@ -3,7 +3,7 @@ import cn from 'classnames';
|
|
|
3
3
|
import { Checkbox } from '@alfalab/core-components-checkbox/modern';
|
|
4
4
|
import { CheckmarkMIcon } from '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
5
5
|
|
|
6
|
-
const styles = {"checkmark":"
|
|
6
|
+
const styles = {"checkmark":"select__checkmark_12dqe","single":"select__single_12dqe","selected":"select__selected_12dqe"};
|
|
7
7
|
require('./index.css')
|
|
8
8
|
|
|
9
9
|
const BaseCheckmark = ({ selected, disabled = false, className, multiple, }) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: kmmfi */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -23,14 +23,14 @@
|
|
|
23
23
|
/* checkmark */
|
|
24
24
|
|
|
25
25
|
/* optgroup */
|
|
26
|
-
} .
|
|
26
|
+
} .select__checkmark_12dqe {
|
|
27
27
|
flex-shrink: 0;
|
|
28
28
|
box-sizing: border-box;
|
|
29
|
-
} .
|
|
29
|
+
} .select__single_12dqe {
|
|
30
30
|
display: flex;
|
|
31
31
|
align-items: center;
|
|
32
32
|
justify-content: center;
|
|
33
33
|
opacity: 0
|
|
34
|
-
} .
|
|
34
|
+
} .select__single_12dqe.select__selected_12dqe {
|
|
35
35
|
opacity: 1;
|
|
36
36
|
}
|
|
@@ -4,7 +4,7 @@ import { BaseCheckmark } from '../base-checkmark/Component.js';
|
|
|
4
4
|
import '@alfalab/core-components-checkbox/modern';
|
|
5
5
|
import '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
6
6
|
|
|
7
|
-
const styles = {"option":"
|
|
7
|
+
const styles = {"option":"select__option_4pn0p","disabled":"select__disabled_4pn0p","checkmarkBefore":"select__checkmarkBefore_4pn0p","mobile":"select__mobile_4pn0p","checkmarkAfter":"select__checkmarkAfter_4pn0p","textContent":"select__textContent_4pn0p","selected":"select__selected_4pn0p","highlighted":"select__highlighted_4pn0p","content":"select__content_4pn0p"};
|
|
8
8
|
require('./index.css')
|
|
9
9
|
|
|
10
10
|
const BaseOption = ({ className, option, children, selected, highlighted, disabled, multiple, Checkmark = BaseCheckmark, checkmarkPosition = multiple ? 'before' : 'after', innerProps, dataTestId, mobile = false, }) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 18cgn */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
/* checkmark */
|
|
44
44
|
|
|
45
45
|
/* optgroup */
|
|
46
|
-
} .
|
|
46
|
+
} .select__option_4pn0p {
|
|
47
47
|
font-size: 16px;
|
|
48
48
|
line-height: 20px;
|
|
49
49
|
font-weight: 400;
|
|
@@ -60,32 +60,32 @@
|
|
|
60
60
|
position: relative;
|
|
61
61
|
cursor: pointer;
|
|
62
62
|
min-height: var(--size-s-height)
|
|
63
|
-
} .
|
|
63
|
+
} .select__option_4pn0p:not(.select__disabled_4pn0p):active {
|
|
64
64
|
background: var(--select-option-active-background);
|
|
65
65
|
color: var(--select-option-active-color);
|
|
66
|
-
} .
|
|
66
|
+
} .select__option_4pn0p.select__checkmarkBefore_4pn0p {
|
|
67
67
|
padding: 0 0 0 var(--gap-s)
|
|
68
|
-
} .
|
|
68
|
+
} .select__option_4pn0p.select__checkmarkBefore_4pn0p.select__mobile_4pn0p {
|
|
69
69
|
padding-left: var(--gap-m);
|
|
70
|
-
} .
|
|
70
|
+
} .select__option_4pn0p.select__checkmarkAfter_4pn0p {
|
|
71
71
|
padding: 0 var(--gap-s) 0 0
|
|
72
|
-
} .
|
|
72
|
+
} .select__option_4pn0p.select__checkmarkAfter_4pn0p.select__mobile_4pn0p {
|
|
73
73
|
padding-right: var(--gap-l);
|
|
74
|
-
} .
|
|
74
|
+
} .select__option_4pn0p.select__textContent_4pn0p {
|
|
75
75
|
padding: var(--gap-s)
|
|
76
|
-
} .
|
|
76
|
+
} .select__option_4pn0p.select__textContent_4pn0p.select__mobile_4pn0p {
|
|
77
77
|
padding: var(--gap-m) var(--gap-l) var(--gap-m) var(--gap-m);
|
|
78
|
-
} .
|
|
78
|
+
} .select__selected_4pn0p {
|
|
79
79
|
background: var(--select-option-selected-background);
|
|
80
80
|
color: var(--select-option-selected-color);
|
|
81
81
|
cursor: default;
|
|
82
|
-
} .
|
|
82
|
+
} .select__highlighted_4pn0p {
|
|
83
83
|
background: var(--select-option-hover-background);
|
|
84
84
|
color: var(--select-option-hover-color);
|
|
85
|
-
} .
|
|
85
|
+
} .select__disabled_4pn0p {
|
|
86
86
|
cursor: var(--disabled-cursor);
|
|
87
87
|
background: var(--select-option-disabled-background);
|
|
88
88
|
color: var(--select-option-disabled-color);
|
|
89
|
-
} .
|
|
89
|
+
} .select__content_4pn0p {
|
|
90
90
|
flex: 1;
|
|
91
91
|
}
|
|
@@ -4,12 +4,12 @@ import { ResizeObserver } from '@juggle/resize-observer';
|
|
|
4
4
|
import cn from 'classnames';
|
|
5
5
|
import { useMultipleSelection, useCombobox } from 'downshift';
|
|
6
6
|
import { Popover } from '@alfalab/core-components-popover/modern';
|
|
7
|
+
import { getDataTestId } from '@alfalab/core-components-shared/modern';
|
|
7
8
|
import { useLayoutEffect_SAFE_FOR_SSR } from '@alfalab/hooks';
|
|
8
|
-
import { g as getDataTestId } from '../../getDataTestId-6120c308.js';
|
|
9
9
|
import { processOptions } from '../../utils.js';
|
|
10
10
|
import { NativeSelect } from '../native-select/Component.js';
|
|
11
11
|
|
|
12
|
-
const styles = {"component":"
|
|
12
|
+
const styles = {"component":"select__component_9le18","popoverInner":"select__popoverInner_9le18","optionsList":"select__optionsList_9le18","optionsListBorder":"select__optionsListBorder_9le18","nativeSelect":"select__nativeSelect_9le18","block":"select__block_9le18"};
|
|
13
13
|
require('./index.css')
|
|
14
14
|
|
|
15
15
|
/* eslint-disable no-nested-ternary */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: ul4l3 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -36,11 +36,11 @@
|
|
|
36
36
|
/* checkmark */
|
|
37
37
|
|
|
38
38
|
/* optgroup */
|
|
39
|
-
} .
|
|
39
|
+
} .select__component_9le18 {
|
|
40
40
|
width: max-content;
|
|
41
41
|
position: relative;
|
|
42
42
|
outline: 0;
|
|
43
|
-
} .
|
|
43
|
+
} .select__popoverInner_9le18 {
|
|
44
44
|
padding-top: var(--select-options-list-offset);
|
|
45
45
|
padding-bottom: var(--select-options-list-offset);
|
|
46
46
|
box-shadow: none;
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
background: transparent;
|
|
49
49
|
border-radius: 0;
|
|
50
50
|
position: relative;
|
|
51
|
-
} .
|
|
51
|
+
} .select__optionsList_9le18 {
|
|
52
52
|
position: relative;
|
|
53
53
|
padding-top: var(--select-options-list-top-padding);
|
|
54
54
|
padding-bottom: var(--select-options-list-bottom-padding);
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
background: var(--select-option-background);
|
|
58
58
|
overflow: hidden;
|
|
59
59
|
will-change: transform;
|
|
60
|
-
} .
|
|
60
|
+
} .select__optionsListBorder_9le18 {
|
|
61
61
|
position: absolute;
|
|
62
62
|
top: 0;
|
|
63
63
|
right: 0;
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
box-shadow: inset 0 0 0 1px var(--color-light-border-secondary);
|
|
67
67
|
border-radius: inherit;
|
|
68
68
|
pointer-events: none;
|
|
69
|
-
} .
|
|
69
|
+
} .select__nativeSelect_9le18 {
|
|
70
70
|
opacity: 0;
|
|
71
71
|
overflow: hidden;
|
|
72
72
|
position: absolute;
|
|
@@ -79,10 +79,10 @@
|
|
|
79
79
|
height: 100%;
|
|
80
80
|
cursor: pointer;
|
|
81
81
|
z-index: 1;
|
|
82
|
-
} .
|
|
82
|
+
} .select__block_9le18 {
|
|
83
83
|
width: 100%;
|
|
84
84
|
} /* width: max-content; fix for IE */ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
85
|
-
.
|
|
85
|
+
.select__component_9le18 {
|
|
86
86
|
float: left;
|
|
87
87
|
clear: left;
|
|
88
88
|
}
|
|
@@ -5,7 +5,7 @@ import '@juggle/resize-observer';
|
|
|
5
5
|
import 'classnames';
|
|
6
6
|
import 'downshift';
|
|
7
7
|
import '@alfalab/core-components-popover/modern';
|
|
8
|
+
import '@alfalab/core-components-shared/modern';
|
|
8
9
|
import '@alfalab/hooks';
|
|
9
|
-
import '../../getDataTestId-6120c308.js';
|
|
10
10
|
import '../../utils.js';
|
|
11
11
|
import '../native-select/Component.js';
|
|
@@ -57,14 +57,14 @@ declare const BaseSelectMobile: React.ForwardRefExoticComponent<Omit<BaseSelectP
|
|
|
57
57
|
/**
|
|
58
58
|
* Дополнительные пропсы модалки
|
|
59
59
|
*/
|
|
60
|
-
modalProps?: Partial<
|
|
60
|
+
modalProps?: Partial<ModalMobileProps & React.RefAttributes<HTMLDivElement>> | undefined;
|
|
61
61
|
/**
|
|
62
62
|
* Дополнительные пропсы шапки модалки
|
|
63
63
|
*/
|
|
64
|
-
modalHeaderProps?: Partial<import("../../Component.mobile-
|
|
64
|
+
modalHeaderProps?: Partial<import("../../Component.mobile-f1f15074").HeaderProps> | undefined;
|
|
65
65
|
/**
|
|
66
66
|
* Дополнительные пропсы футера модалки
|
|
67
67
|
*/
|
|
68
|
-
modalFooterProps?: Partial<import("../../Component.mobile-
|
|
68
|
+
modalFooterProps?: Partial<import("../../Component.mobile-f1f15074").FooterProps> | undefined;
|
|
69
69
|
} & React.RefAttributes<unknown>>;
|
|
70
70
|
export { SelectMobileProps, BaseSelectMobile };
|
|
@@ -4,7 +4,7 @@ import cn from 'classnames';
|
|
|
4
4
|
import { useMultipleSelection, useCombobox } from 'downshift';
|
|
5
5
|
import { BottomSheet } from '@alfalab/core-components-bottom-sheet/modern';
|
|
6
6
|
import { ModalMobile } from '@alfalab/core-components-modal/modern/mobile';
|
|
7
|
-
import {
|
|
7
|
+
import { getDataTestId } from '@alfalab/core-components-shared/modern';
|
|
8
8
|
import { processOptions } from '../../utils.js';
|
|
9
9
|
import { Arrow } from '../arrow/Component.js';
|
|
10
10
|
import { Field } from '../field/Component.js';
|
|
@@ -12,7 +12,6 @@ import { Optgroup } from '../optgroup/Component.js';
|
|
|
12
12
|
import { Option } from '../option/Component.js';
|
|
13
13
|
import { OptionsList } from '../options-list/Component.js';
|
|
14
14
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
15
|
-
import '@alfalab/core-components-form-control/modern';
|
|
16
15
|
import '@alfalab/hooks';
|
|
17
16
|
import '../checkmark/Component.js';
|
|
18
17
|
import '@alfalab/core-components-badge/modern';
|
|
@@ -23,10 +22,10 @@ import '../checkmark-mobile/Component.js';
|
|
|
23
22
|
import '@alfalab/core-components-scrollbar/modern';
|
|
24
23
|
import '../../consts.js';
|
|
25
24
|
|
|
26
|
-
const styles = {"component":"
|
|
25
|
+
const styles = {"component":"select__component_1dqk4","sheet":"select__sheet_1dqk4","sheetContent":"select__sheetContent_1dqk4","modalContent":"select__modalContent_1dqk4","sheetContainer":"select__sheetContainer_1dqk4","block":"select__block_1dqk4","option":"select__option_1dqk4","optionGroup":"select__optionGroup_1dqk4"};
|
|
27
26
|
require('./index.css')
|
|
28
27
|
|
|
29
|
-
const BaseSelectMobile = forwardRef(({ dataTestId, className, fieldClassName, optionsListClassName, optionClassName, optionGroupClassName, optionsListProps, options = [], autocomplete = false, multiple = false, allowUnselect = false, disabled = false, closeOnSelect = !multiple, circularNavigation = false, defaultOpen = false, open: openProp, optionsListWidth = 'content', name, id, selected = [], size = 'm', optionsSize = 'm', error, hint, block, label, labelView, placeholder, fieldProps = {}, optionProps = {}, valueRenderer, onChange, onOpen, onFocus, Arrow: Arrow$1 = Arrow, Field: Field$1 = Field, Optgroup: Optgroup$1 = Optgroup, Option: Option$1 = Option, OptionsList: OptionsList$1 = OptionsList, swipeable, footer, isBottomSheet, bottomSheetProps, modalProps, modalHeaderProps, modalFooterProps, showEmptyOptionsList = false, }, ref) => {
|
|
28
|
+
const BaseSelectMobile = forwardRef(({ dataTestId, className, fieldClassName, optionsListClassName, optionClassName, optionGroupClassName, optionsListProps, options = [], autocomplete = false, multiple = false, allowUnselect = false, disabled = false, closeOnSelect = !multiple, circularNavigation = false, defaultOpen = false, open: openProp, optionsListWidth = 'content', name, id, selected = [], size = 'm', optionsSize = 'm', error, hint, block, label, labelView, placeholder, fieldProps = {}, optionProps = {}, valueRenderer, onChange, onOpen, onFocus, onBlur, Arrow: Arrow$1 = Arrow, Field: Field$1 = Field, Optgroup: Optgroup$1 = Optgroup, Option: Option$1 = Option, OptionsList: OptionsList$1 = OptionsList, swipeable, footer, isBottomSheet, bottomSheetProps, modalProps, modalHeaderProps, modalFooterProps, showEmptyOptionsList = false, }, ref) => {
|
|
30
29
|
const rootRef = useRef(null);
|
|
31
30
|
const fieldRef = useRef(null);
|
|
32
31
|
const listRef = useRef(null);
|
|
@@ -141,6 +140,10 @@ const BaseSelectMobile = forwardRef(({ dataTestId, className, fieldClassName, op
|
|
|
141
140
|
openMenu();
|
|
142
141
|
}
|
|
143
142
|
};
|
|
143
|
+
const handleFieldBlur = (event) => {
|
|
144
|
+
if (!open && onBlur)
|
|
145
|
+
onBlur(event);
|
|
146
|
+
};
|
|
144
147
|
const handleFieldKeyDown = (event) => {
|
|
145
148
|
inputProps.onKeyDown(event);
|
|
146
149
|
if (autocomplete && !open && (event.key.length === 1 || event.key === 'Backspace')) {
|
|
@@ -213,6 +216,7 @@ const BaseSelectMobile = forwardRef(({ dataTestId, className, fieldClassName, op
|
|
|
213
216
|
className: cn(styles.component, { [styles.block]: block }, className),
|
|
214
217
|
}), onKeyDown: disabled ? undefined : handleFieldKeyDown, tabIndex: -1, "data-test-id": getDataTestId(dataTestId) },
|
|
215
218
|
React.createElement(Field$1, { selectedMultiple: selectedItems, selected: selectedItems[0], setSelectedItems: setSelectedItems, toggleMenu: toggleMenu, multiple: multiple, open: open, disabled: disabled, size: size, placeholder: placeholder, label: label && React.createElement("span", { ...getLabelProps() }, label), labelView: labelView, Arrow: Arrow$1 && React.createElement(Arrow$1, { open: open }), error: error, hint: hint, valueRenderer: valueRenderer, className: fieldClassName, innerProps: {
|
|
219
|
+
onBlur: handleFieldBlur,
|
|
216
220
|
onFocus: disabled ? undefined : handleFieldFocus,
|
|
217
221
|
onClick: disabled ? undefined : handleFieldClick,
|
|
218
222
|
tabIndex: disabled ? -1 : 0,
|
|
@@ -233,7 +237,7 @@ const BaseSelectMobile = forwardRef(({ dataTestId, className, fieldClassName, op
|
|
|
233
237
|
modalProps?.ref,
|
|
234
238
|
]) },
|
|
235
239
|
React.createElement(ModalMobile.Header, { hasCloser: true, sticky: true, ...modalHeaderProps }, label || placeholder),
|
|
236
|
-
renderOptionsList(),
|
|
240
|
+
React.createElement(ModalMobile.Content, { flex: true, className: styles.modalContent }, renderOptionsList()),
|
|
237
241
|
modalFooterProps?.children && React.createElement(ModalMobile.Footer, { ...modalFooterProps })))));
|
|
238
242
|
});
|
|
239
243
|
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
type FooterProps = {
|
|
3
4
|
handleClear?: () => void;
|
|
4
5
|
handleApply?: () => void;
|
|
5
6
|
showClear?: boolean;
|
|
6
7
|
};
|
|
7
|
-
declare const Footer: ({ handleApply, handleClear, showClear }: FooterProps) => JSX.Element;
|
|
8
|
+
declare const Footer: ({ handleApply, handleClear, showClear }: FooterProps) => React.JSX.Element;
|
|
8
9
|
export { FooterProps, Footer };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { useContext, useEffect } from 'react';
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { BaseModalContext } from '@alfalab/core-components-base-modal/modern';
|
|
4
|
-
import {
|
|
4
|
+
import { ButtonMobile } from '@alfalab/core-components-button/modern/mobile';
|
|
5
5
|
|
|
6
|
-
const styles = {"footer":"
|
|
6
|
+
const styles = {"footer":"select__footer_dct7k","button":"select__button_dct7k","highlighted":"select__highlighted_dct7k"};
|
|
7
7
|
require('./index.css')
|
|
8
8
|
|
|
9
9
|
const Footer = ({ handleApply, handleClear, showClear }) => {
|
|
@@ -16,8 +16,8 @@ const Footer = ({ handleApply, handleClear, showClear }) => {
|
|
|
16
16
|
tabIndex: 0, className: cn(styles.footer, {
|
|
17
17
|
[styles.highlighted]: footerHighlighted,
|
|
18
18
|
}) },
|
|
19
|
-
showClear && (React.createElement(
|
|
20
|
-
React.createElement(
|
|
19
|
+
showClear && (React.createElement(ButtonMobile, { size: 'm', view: 'secondary', className: styles.button, onClick: handleClear }, "\u0421\u0431\u0440\u043E\u0441\u0438\u0442\u044C")),
|
|
20
|
+
React.createElement(ButtonMobile, { size: 'm', view: 'primary', className: styles.button, onClick: handleApply }, "\u041F\u0440\u0438\u043C\u0435\u043D\u0438\u0442\u044C")));
|
|
21
21
|
};
|
|
22
22
|
|
|
23
23
|
export { Footer };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1rj12 */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-bg-primary: #fff;
|
|
@@ -26,17 +26,17 @@
|
|
|
26
26
|
/* checkmark */
|
|
27
27
|
|
|
28
28
|
/* optgroup */
|
|
29
|
-
} .
|
|
29
|
+
} .select__footer_dct7k {
|
|
30
30
|
display: flex;
|
|
31
31
|
box-sizing: border-box;
|
|
32
32
|
width: 100%;
|
|
33
33
|
padding: var(--gap-m) var(--gap-m);
|
|
34
34
|
background-color: var(--color-light-bg-primary)
|
|
35
|
-
} .
|
|
35
|
+
} .select__footer_dct7k .select__button_dct7k:first-of-type {
|
|
36
36
|
margin-right: var(--gap-m);
|
|
37
|
-
} .
|
|
37
|
+
} .select__button_dct7k {
|
|
38
38
|
width: 50%;
|
|
39
|
-
} .
|
|
39
|
+
} .select__highlighted_dct7k {
|
|
40
40
|
border-top: 1px solid var(--color-light-border-primary);
|
|
41
41
|
background-color: var(--color-light-bg-primary);
|
|
42
42
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1vevp */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -27,27 +27,29 @@
|
|
|
27
27
|
/* checkmark */
|
|
28
28
|
|
|
29
29
|
/* optgroup */
|
|
30
|
-
} .
|
|
30
|
+
} .select__component_1dqk4 {
|
|
31
31
|
width: max-content;
|
|
32
32
|
position: relative;
|
|
33
33
|
outline: 0;
|
|
34
|
-
} .
|
|
34
|
+
} .select__sheet_1dqk4 {
|
|
35
35
|
overflow: hidden;
|
|
36
|
-
} .
|
|
36
|
+
} .select__sheetContent_1dqk4 {
|
|
37
|
+
padding: 0
|
|
38
|
+
} .select__sheetContent_1dqk4 .select__modalContent_1dqk4 {
|
|
39
|
+
padding: 0;
|
|
40
|
+
} .select__sheetContainer_1dqk4 {
|
|
37
41
|
padding: 0;
|
|
38
|
-
} .
|
|
39
|
-
padding: 0;
|
|
40
|
-
} .select__block_ufgv3 {
|
|
42
|
+
} .select__block_1dqk4 {
|
|
41
43
|
width: 100%;
|
|
42
44
|
} /* width: max-content; fix for IE */ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) {
|
|
43
|
-
.
|
|
45
|
+
.select__component_1dqk4 {
|
|
44
46
|
float: left;
|
|
45
47
|
clear: left;
|
|
46
48
|
}
|
|
47
|
-
} .
|
|
49
|
+
} .select__option_1dqk4 {
|
|
48
50
|
padding: var(--gap-2xs) var(--gap-l) var(--gap-2xs) var(--gap-m)
|
|
49
|
-
} .
|
|
51
|
+
} .select__option_1dqk4:before {
|
|
50
52
|
display: none;
|
|
51
|
-
} .
|
|
53
|
+
} .select__optionGroup_1dqk4 {
|
|
52
54
|
padding: var(--gap-m) var(--gap-m) var(--gap-xs);
|
|
53
55
|
}
|
|
@@ -5,12 +5,11 @@ import 'classnames';
|
|
|
5
5
|
import 'downshift';
|
|
6
6
|
import '@alfalab/core-components-bottom-sheet/modern';
|
|
7
7
|
import '@alfalab/core-components-modal/modern/mobile';
|
|
8
|
-
import '
|
|
8
|
+
import '@alfalab/core-components-shared/modern';
|
|
9
9
|
import '../../utils.js';
|
|
10
10
|
import '../arrow/Component.js';
|
|
11
11
|
import '@alfalab/icons-glyph/ChevronDownMIcon';
|
|
12
12
|
import '../field/Component.js';
|
|
13
|
-
import '@alfalab/core-components-form-control/modern';
|
|
14
13
|
import '@alfalab/hooks';
|
|
15
14
|
import '../optgroup/Component.js';
|
|
16
15
|
import '../option/Component.js';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
import { CheckmarkProps } from "../../typings";
|
|
3
|
-
declare const Checkmark: ({ selected, disabled, className, multiple, position, }: CheckmarkProps) => JSX.Element;
|
|
4
|
+
declare const Checkmark: ({ selected, disabled, className, multiple, position, }: CheckmarkProps) => React.JSX.Element;
|
|
4
5
|
export { Checkmark };
|
|
@@ -5,7 +5,7 @@ import { Checkbox } from '@alfalab/core-components-checkbox/modern';
|
|
|
5
5
|
import { CheckmarkCircleMIcon } from '@alfalab/icons-glyph/CheckmarkCircleMIcon';
|
|
6
6
|
import CheckmarkMIcon from '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
7
7
|
|
|
8
|
-
const styles = {"checkmark":"
|
|
8
|
+
const styles = {"checkmark":"select__checkmark_g5hu8","after":"select__after_g5hu8","single":"select__single_g5hu8","selected":"select__selected_g5hu8","before":"select__before_g5hu8","multiple":"select__multiple_g5hu8","colorIcon":"select__colorIcon_g5hu8"};
|
|
9
9
|
require('./index.css')
|
|
10
10
|
|
|
11
11
|
const Checkmark = ({ selected, disabled = false, className, multiple, position = 'before', }) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 5v1bg */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-graphic-positive: #2fc26e;
|
|
@@ -39,12 +39,12 @@
|
|
|
39
39
|
--select-checkmark-border-radius: var(--border-radius-circle);
|
|
40
40
|
|
|
41
41
|
/* optgroup */
|
|
42
|
-
} .
|
|
42
|
+
} .select__checkmark_g5hu8 {
|
|
43
43
|
flex-shrink: 0;
|
|
44
44
|
margin: var(--select-checkmark-margin)
|
|
45
|
-
} .
|
|
45
|
+
} .select__checkmark_g5hu8.select__after_g5hu8 {
|
|
46
46
|
margin: var(--select-checkmark-margin-after);
|
|
47
|
-
} .
|
|
47
|
+
} .select__single_g5hu8 {
|
|
48
48
|
display: flex;
|
|
49
49
|
align-items: center;
|
|
50
50
|
justify-content: center;
|
|
@@ -54,17 +54,17 @@
|
|
|
54
54
|
border-radius: var(--select-checkmark-border-radius);
|
|
55
55
|
width: var(--select-checkmark-size);
|
|
56
56
|
height: var(--select-checkmark-size)
|
|
57
|
-
} .
|
|
57
|
+
} .select__single_g5hu8.select__selected_g5hu8 {
|
|
58
58
|
opacity: 1;
|
|
59
|
-
} .
|
|
59
|
+
} .select__before_g5hu8 {
|
|
60
60
|
display: var(--select-checkmark-before-display)
|
|
61
|
-
} .
|
|
61
|
+
} .select__before_g5hu8.select__multiple_g5hu8 {
|
|
62
62
|
margin-right: var(--gap-s);
|
|
63
63
|
display: var(--select-checkmark-before-display-multiple);
|
|
64
|
-
} .
|
|
64
|
+
} .select__after_g5hu8 {
|
|
65
65
|
display: var(--select-checkmark-after-display)
|
|
66
|
-
} .
|
|
66
|
+
} .select__after_g5hu8.select__single_g5hu8 {
|
|
67
67
|
display: var(--select-checkmark-after-display-single);
|
|
68
|
-
} .
|
|
68
|
+
} .select__colorIcon_g5hu8 {
|
|
69
69
|
color: var(--color-light-graphic-positive);
|
|
70
70
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
import React from 'react';
|
|
2
3
|
import { CheckmarkProps } from "../../typings";
|
|
3
|
-
declare const Checkmark: ({ selected, className }: CheckmarkProps) => JSX.Element;
|
|
4
|
+
declare const Checkmark: ({ selected, className }: CheckmarkProps) => React.JSX.Element;
|
|
4
5
|
export { Checkmark };
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import cn from 'classnames';
|
|
3
3
|
import { CheckmarkMIcon } from '@alfalab/icons-glyph/CheckmarkMIcon';
|
|
4
4
|
|
|
5
|
-
const styles = {"checkmark":"
|
|
5
|
+
const styles = {"checkmark":"select__checkmark_zed9f","selected":"select__selected_zed9f","displayIcon":"select__displayIcon_zed9f","displayBadge":"select__displayBadge_zed9f"};
|
|
6
6
|
require('./index.css')
|
|
7
7
|
|
|
8
8
|
const Checkmark = ({ selected, className }) => (React.createElement("div", { className: cn(styles.checkmark, className, {
|