@alfalab/core-components 45.8.0-beta.5 → 45.9.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/bank-card/Component.d.ts +6 -0
- package/bank-card/Component.js +14 -9
- package/bank-card/cssm/Component.d.ts +6 -0
- package/bank-card/cssm/Component.js +14 -9
- package/bank-card/cssm/enums.d.ts +6 -0
- package/bank-card/cssm/enums.js +8 -0
- package/bank-card/cssm/helpers/getDefaultInputLabel.d.ts +3 -0
- package/bank-card/cssm/helpers/getDefaultInputLabel.js +17 -0
- package/bank-card/cssm/types.d.ts +2 -0
- package/bank-card/cssm/types.js +1 -0
- package/bank-card/enums.d.ts +6 -0
- package/bank-card/enums.js +8 -0
- package/bank-card/esm/Component.d.ts +6 -0
- package/bank-card/esm/Component.js +14 -9
- package/bank-card/esm/enums.d.ts +6 -0
- package/bank-card/esm/enums.js +8 -0
- package/bank-card/esm/helpers/getDefaultInputLabel.d.ts +3 -0
- package/bank-card/esm/helpers/getDefaultInputLabel.js +15 -0
- package/bank-card/esm/index.js +2 -0
- package/bank-card/esm/types.d.ts +2 -0
- package/bank-card/esm/types.js +1 -0
- package/bank-card/helpers/getDefaultInputLabel.d.ts +3 -0
- package/bank-card/helpers/getDefaultInputLabel.js +17 -0
- package/bank-card/modern/Component.d.ts +6 -0
- package/bank-card/modern/Component.js +14 -7
- package/bank-card/modern/enums.d.ts +6 -0
- package/bank-card/modern/enums.js +8 -0
- package/bank-card/modern/helpers/getDefaultInputLabel.d.ts +3 -0
- package/bank-card/modern/helpers/getDefaultInputLabel.js +15 -0
- package/bank-card/modern/index.js +2 -0
- package/bank-card/modern/types.d.ts +2 -0
- package/bank-card/modern/types.js +1 -0
- package/bank-card/types.d.ts +2 -0
- package/bank-card/types.js +1 -0
- package/bottom-sheet/component.js +22 -12
- package/bottom-sheet/consts/swipeConsts.d.ts +2 -0
- package/bottom-sheet/consts/swipeConsts.js +7 -0
- package/bottom-sheet/cssm/component.js +22 -12
- package/bottom-sheet/cssm/consts/swipeConsts.d.ts +2 -0
- package/bottom-sheet/cssm/consts/swipeConsts.js +7 -0
- package/bottom-sheet/cssm/enums/swipeEnums.d.ts +7 -0
- package/bottom-sheet/cssm/enums/swipeEnums.js +9 -0
- package/bottom-sheet/cssm/types/swipeTypes.d.ts +9 -0
- package/bottom-sheet/cssm/types/swipeTypes.js +1 -0
- package/bottom-sheet/enums/swipeEnums.d.ts +7 -0
- package/bottom-sheet/enums/swipeEnums.js +9 -0
- package/bottom-sheet/esm/component.js +23 -12
- package/bottom-sheet/esm/consts/swipeConsts.d.ts +2 -0
- package/bottom-sheet/esm/consts/swipeConsts.js +5 -0
- package/bottom-sheet/esm/enums/swipeEnums.d.ts +7 -0
- package/bottom-sheet/esm/enums/swipeEnums.js +9 -0
- package/bottom-sheet/esm/index.js +2 -0
- package/bottom-sheet/esm/types/swipeTypes.d.ts +9 -0
- package/bottom-sheet/esm/types/swipeTypes.js +1 -0
- package/bottom-sheet/modern/component.js +23 -9
- package/bottom-sheet/modern/consts/swipeConsts.d.ts +2 -0
- package/bottom-sheet/modern/consts/swipeConsts.js +5 -0
- package/bottom-sheet/modern/enums/swipeEnums.d.ts +7 -0
- package/bottom-sheet/modern/enums/swipeEnums.js +9 -0
- package/bottom-sheet/modern/index.js +2 -0
- package/bottom-sheet/modern/types/swipeTypes.d.ts +9 -0
- package/bottom-sheet/modern/types/swipeTypes.js +1 -0
- package/bottom-sheet/types/swipeTypes.d.ts +9 -0
- package/bottom-sheet/types/swipeTypes.js +1 -0
- package/confirmation/components/screens/initial/component.js +1 -1
- package/confirmation/components/screens/initial/countdown-section.js +1 -1
- package/confirmation/esm/component.responsive.js +1 -1
- package/confirmation/esm/components/base-confirmation/component.js +1 -1
- package/confirmation/esm/components/base-confirmation/index.js +1 -1
- package/confirmation/esm/components/index.js +1 -1
- package/confirmation/esm/components/screens/index.js +1 -1
- package/confirmation/esm/components/screens/initial/component.js +1 -1
- package/confirmation/esm/components/screens/initial/countdown-section.js +1 -1
- package/confirmation/esm/components/screens/initial/index.js +1 -1
- package/confirmation/esm/desktop/component.desktop.js +1 -1
- package/confirmation/esm/desktop/index.js +1 -1
- package/confirmation/esm/index.js +1 -1
- package/confirmation/esm/mobile/component.mobile.js +1 -1
- package/confirmation/esm/mobile/index.js +1 -1
- package/confirmation/esm/shared/index.js +1 -1
- package/confirmation/modern/component.responsive.js +1 -1
- package/confirmation/modern/components/base-confirmation/component.js +1 -1
- package/confirmation/modern/components/base-confirmation/index.js +1 -1
- package/confirmation/modern/components/index.js +1 -1
- package/confirmation/modern/components/screens/index.js +1 -1
- package/confirmation/modern/components/screens/initial/component.js +1 -1
- package/confirmation/modern/components/screens/initial/countdown-section.js +1 -1
- package/confirmation/modern/components/screens/initial/index.js +1 -1
- package/confirmation/modern/desktop/component.desktop.js +1 -1
- package/confirmation/modern/desktop/index.js +1 -1
- package/confirmation/modern/index.js +1 -1
- package/confirmation/modern/mobile/component.mobile.js +1 -1
- package/confirmation/modern/mobile/index.js +1 -1
- package/confirmation/modern/shared/index.js +1 -1
- package/international-phone-input/cssm/typings-57569e57.d.ts +18 -2
- package/international-phone-input/esm/typings-57569e57.d.ts +18 -2
- package/international-phone-input/modern/typings-57569e57.d.ts +18 -2
- package/international-phone-input/typings-57569e57.d.ts +18 -2
- package/modal/components/controls/Component.js +1 -1
- package/modal/components/footer/Component.js +1 -1
- package/modal/esm/Component.responsive.js +1 -1
- package/modal/esm/components/controls/Component.js +1 -1
- package/modal/esm/components/controls/index.js +1 -1
- package/modal/esm/components/footer/Component.js +1 -1
- package/modal/esm/desktop/Component.desktop.js +1 -1
- package/modal/esm/desktop/index.js +1 -1
- package/modal/esm/index.js +1 -1
- package/modal/esm/mobile/Component.mobile.js +1 -1
- package/modal/esm/mobile/index.js +1 -1
- package/modal/modern/Component.responsive.js +1 -1
- package/modal/modern/components/controls/Component.js +1 -1
- package/modal/modern/components/controls/index.js +1 -1
- package/modal/modern/components/footer/Component.js +1 -1
- package/modal/modern/desktop/Component.desktop.js +1 -1
- package/modal/modern/desktop/index.js +1 -1
- package/modal/modern/index.js +1 -1
- package/modal/modern/mobile/Component.mobile.js +1 -1
- package/modal/modern/mobile/index.js +1 -1
- package/package.json +2 -2
- package/picker-button/cssm/typings-57569e57.d.ts +18 -2
- package/picker-button/esm/typings-57569e57.d.ts +18 -2
- package/picker-button/modern/typings-57569e57.d.ts +18 -2
- package/picker-button/typings-57569e57.d.ts +18 -2
- package/pure-cell/{component-911cc97f.js → component-1b03bea6.js} +1 -1
- package/pure-cell/component.js +1 -1
- package/pure-cell/components/addon/component.js +1 -1
- package/pure-cell/components/addon/index.d.ts +1 -1
- package/pure-cell/components/addon/index.js +1 -1
- package/pure-cell/components/amount/component.js +1 -1
- package/pure-cell/components/amount/index.d.ts +1 -1
- package/pure-cell/components/amount/index.js +1 -1
- package/pure-cell/components/amount-title/component.js +1 -1
- package/pure-cell/components/amount-title/index.d.ts +1 -1
- package/pure-cell/components/amount-title/index.js +1 -1
- package/pure-cell/components/category/component.js +1 -1
- package/pure-cell/components/category/index.d.ts +1 -1
- package/pure-cell/components/category/index.js +1 -1
- package/pure-cell/components/content/component.js +1 -1
- package/pure-cell/components/content/index.d.ts +1 -1
- package/pure-cell/components/content/index.js +1 -1
- package/pure-cell/components/footer/component.js +1 -1
- package/pure-cell/components/footer/index.d.ts +1 -1
- package/pure-cell/components/footer/index.js +1 -1
- package/pure-cell/components/footer-button/component.js +1 -1
- package/pure-cell/components/footer-button/index.d.ts +1 -1
- package/pure-cell/components/footer-button/index.js +1 -1
- package/pure-cell/components/footer-text/component.js +1 -1
- package/pure-cell/components/footer-text/index.d.ts +1 -1
- package/pure-cell/components/footer-text/index.js +1 -1
- package/pure-cell/components/graphics/component.js +1 -1
- package/pure-cell/components/graphics/index.d.ts +1 -1
- package/pure-cell/components/graphics/index.js +1 -1
- package/pure-cell/components/main/component.js +1 -1
- package/pure-cell/components/main/index.d.ts +1 -1
- package/pure-cell/components/main/index.js +1 -1
- package/pure-cell/components/text/component.js +1 -1
- package/pure-cell/components/text/index.d.ts +1 -1
- package/pure-cell/components/text/index.js +1 -1
- package/pure-cell/cssm/{component-719b272a.js → component-e3105fca.js} +1 -1
- package/pure-cell/cssm/component.js +1 -1
- package/pure-cell/cssm/components/addon/component.js +1 -1
- package/pure-cell/cssm/components/addon/index.d.ts +1 -1
- package/pure-cell/cssm/components/addon/index.js +1 -1
- package/pure-cell/cssm/components/amount/component.js +1 -1
- package/pure-cell/cssm/components/amount/index.d.ts +1 -1
- package/pure-cell/cssm/components/amount/index.js +1 -1
- package/pure-cell/cssm/components/amount-title/component.js +1 -1
- package/pure-cell/cssm/components/amount-title/index.d.ts +1 -1
- package/pure-cell/cssm/components/amount-title/index.js +1 -1
- package/pure-cell/cssm/components/category/component.js +1 -1
- package/pure-cell/cssm/components/category/index.d.ts +1 -1
- package/pure-cell/cssm/components/category/index.js +1 -1
- package/pure-cell/cssm/components/content/component.js +1 -1
- package/pure-cell/cssm/components/content/index.d.ts +1 -1
- package/pure-cell/cssm/components/content/index.js +1 -1
- package/pure-cell/cssm/components/footer/component.js +1 -1
- package/pure-cell/cssm/components/footer/index.d.ts +1 -1
- package/pure-cell/cssm/components/footer/index.js +1 -1
- package/pure-cell/cssm/components/footer-button/component.js +1 -1
- package/pure-cell/cssm/components/footer-button/index.d.ts +1 -1
- package/pure-cell/cssm/components/footer-button/index.js +1 -1
- package/pure-cell/cssm/components/footer-text/component.js +1 -1
- package/pure-cell/cssm/components/footer-text/index.d.ts +1 -1
- package/pure-cell/cssm/components/footer-text/index.js +1 -1
- package/pure-cell/cssm/components/graphics/component.js +1 -1
- package/pure-cell/cssm/components/graphics/index.d.ts +1 -1
- package/pure-cell/cssm/components/graphics/index.js +1 -1
- package/pure-cell/cssm/components/main/component.js +1 -1
- package/pure-cell/cssm/components/main/index.d.ts +1 -1
- package/pure-cell/cssm/components/main/index.js +1 -1
- package/pure-cell/cssm/components/text/component.js +1 -1
- package/pure-cell/cssm/components/text/index.d.ts +1 -1
- package/pure-cell/cssm/components/text/index.js +1 -1
- package/pure-cell/cssm/index.js +1 -1
- package/pure-cell/esm/{component-53618056.js → component-02d56ae7.js} +1 -1
- package/pure-cell/esm/component.js +1 -1
- package/pure-cell/esm/components/addon/component.js +1 -1
- package/pure-cell/esm/components/addon/index.d.ts +1 -1
- package/pure-cell/esm/components/addon/index.js +1 -1
- package/pure-cell/esm/components/amount/component.js +1 -1
- package/pure-cell/esm/components/amount/index.d.ts +1 -1
- package/pure-cell/esm/components/amount/index.js +1 -1
- package/pure-cell/esm/components/amount-title/component.js +1 -1
- package/pure-cell/esm/components/amount-title/index.d.ts +1 -1
- package/pure-cell/esm/components/amount-title/index.js +1 -1
- package/pure-cell/esm/components/category/component.js +1 -1
- package/pure-cell/esm/components/category/index.d.ts +1 -1
- package/pure-cell/esm/components/category/index.js +1 -1
- package/pure-cell/esm/components/content/component.js +1 -1
- package/pure-cell/esm/components/content/index.d.ts +1 -1
- package/pure-cell/esm/components/content/index.js +1 -1
- package/pure-cell/esm/components/footer/component.js +1 -1
- package/pure-cell/esm/components/footer/index.d.ts +1 -1
- package/pure-cell/esm/components/footer/index.js +1 -1
- package/pure-cell/esm/components/footer-button/component.js +1 -1
- package/pure-cell/esm/components/footer-button/index.d.ts +1 -1
- package/pure-cell/esm/components/footer-button/index.js +1 -1
- package/pure-cell/esm/components/footer-text/component.js +1 -1
- package/pure-cell/esm/components/footer-text/index.d.ts +1 -1
- package/pure-cell/esm/components/footer-text/index.js +1 -1
- package/pure-cell/esm/components/graphics/component.js +1 -1
- package/pure-cell/esm/components/graphics/index.d.ts +1 -1
- package/pure-cell/esm/components/graphics/index.js +1 -1
- package/pure-cell/esm/components/main/component.js +1 -1
- package/pure-cell/esm/components/main/index.d.ts +1 -1
- package/pure-cell/esm/components/main/index.js +1 -1
- package/pure-cell/esm/components/text/component.js +1 -1
- package/pure-cell/esm/components/text/index.d.ts +1 -1
- package/pure-cell/esm/components/text/index.js +1 -1
- package/pure-cell/esm/index.js +1 -1
- package/pure-cell/index.js +1 -1
- package/pure-cell/modern/{component-254f4794.js → component-766c0ee4.js} +1 -1
- package/pure-cell/modern/component.js +1 -1
- package/pure-cell/modern/components/addon/component.js +1 -1
- package/pure-cell/modern/components/addon/index.d.ts +1 -1
- package/pure-cell/modern/components/addon/index.js +1 -1
- package/pure-cell/modern/components/amount/component.js +1 -1
- package/pure-cell/modern/components/amount/index.d.ts +1 -1
- package/pure-cell/modern/components/amount/index.js +1 -1
- package/pure-cell/modern/components/amount-title/component.js +1 -1
- package/pure-cell/modern/components/amount-title/index.d.ts +1 -1
- package/pure-cell/modern/components/amount-title/index.js +1 -1
- package/pure-cell/modern/components/category/component.js +1 -1
- package/pure-cell/modern/components/category/index.d.ts +1 -1
- package/pure-cell/modern/components/category/index.js +1 -1
- package/pure-cell/modern/components/content/component.js +1 -1
- package/pure-cell/modern/components/content/index.d.ts +1 -1
- package/pure-cell/modern/components/content/index.js +1 -1
- package/pure-cell/modern/components/footer/component.js +1 -1
- package/pure-cell/modern/components/footer/index.d.ts +1 -1
- package/pure-cell/modern/components/footer/index.js +1 -1
- package/pure-cell/modern/components/footer-button/component.js +1 -1
- package/pure-cell/modern/components/footer-button/index.d.ts +1 -1
- package/pure-cell/modern/components/footer-button/index.js +1 -1
- package/pure-cell/modern/components/footer-text/component.js +1 -1
- package/pure-cell/modern/components/footer-text/index.d.ts +1 -1
- package/pure-cell/modern/components/footer-text/index.js +1 -1
- package/pure-cell/modern/components/graphics/component.js +1 -1
- package/pure-cell/modern/components/graphics/index.d.ts +1 -1
- package/pure-cell/modern/components/graphics/index.js +1 -1
- package/pure-cell/modern/components/main/component.js +1 -1
- package/pure-cell/modern/components/main/index.d.ts +1 -1
- package/pure-cell/modern/components/main/index.js +1 -1
- package/pure-cell/modern/components/text/component.js +1 -1
- package/pure-cell/modern/components/text/index.d.ts +1 -1
- package/pure-cell/modern/components/text/index.js +1 -1
- package/pure-cell/modern/index.js +1 -1
- package/select/components/base-option/Component.js +6 -2
- package/select/components/base-option/index.css +4 -3
- package/select/cssm/components/base-option/Component.js +5 -1
- package/select/cssm/components/base-option/index.module.css +4 -2
- package/select/esm/Component.responsive.js +1 -1
- package/select/esm/components/base-option/Component.js +6 -2
- package/select/esm/components/base-option/index.css +4 -3
- package/select/esm/index.js +1 -1
- package/select/esm/mobile/Component.mobile.js +1 -1
- package/select/esm/mobile/Component.modal.mobile.js +1 -1
- package/select/esm/mobile/index.js +1 -1
- package/select/esm/presets/index.js +1 -1
- package/select/esm/presets/useSelectWithApply/hook.js +1 -1
- package/select/esm/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/select/esm/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/select/esm/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/select/esm/shared/index.js +1 -1
- package/select/mobile/Component.mobile.js +1 -1
- package/select/modern/Component.responsive.js +1 -1
- package/select/modern/components/base-option/Component.js +5 -2
- package/select/modern/components/base-option/index.css +4 -3
- package/select/modern/index.js +1 -1
- package/select/modern/mobile/Component.mobile.js +1 -1
- package/select/modern/mobile/Component.modal.mobile.js +1 -1
- package/select/modern/mobile/index.js +1 -1
- package/select/modern/presets/index.js +1 -1
- package/select/modern/presets/useSelectWithApply/hook.js +1 -1
- package/select/modern/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/select/modern/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/select/modern/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/select/modern/shared/index.js +1 -1
- package/select/presets/index.js +1 -1
- package/select/presets/useSelectWithApply/hook.js +1 -1
- package/select/presets/useSelectWithApply/options-list-with-apply/Component.js +1 -1
- package/select/presets/useSelectWithApply/options-list-with-apply/index.d.ts +1 -1
- package/select/presets/useSelectWithApply/options-list-with-apply/index.js +1 -1
- package/select/shared/index.js +1 -1
- package/tabs/components/primary-tablist/Component.collapsible.js +1 -1
- package/tabs/components/primary-tablist/Component.desktop.js +1 -1
- package/tabs/components/primary-tablist/Component.mobile.js +1 -1
- package/tabs/components/secondary-tablist/Component.desktop.js +1 -1
- package/tabs/components/secondary-tablist/Component.mobile.js +1 -1
- package/tabs/esm/collapsible/index.js +1 -1
- package/tabs/esm/components/primary-tablist/Component.collapsible.js +1 -1
- package/tabs/esm/components/primary-tablist/Component.desktop.js +1 -1
- package/tabs/esm/components/primary-tablist/Component.mobile.js +1 -1
- package/tabs/esm/components/primary-tablist/Component.responsive.js +1 -1
- package/tabs/esm/components/secondary-tablist/Component.desktop.js +1 -1
- package/tabs/esm/components/secondary-tablist/Component.mobile.js +1 -1
- package/tabs/esm/components/secondary-tablist/Component.responsive.js +1 -1
- package/tabs/esm/components/tabs/Component.collapsible.js +1 -1
- package/tabs/esm/components/tabs/Component.desktop.js +2 -2
- package/tabs/esm/components/tabs/Component.mobile.js +2 -2
- package/tabs/esm/components/tabs/Component.responsive.js +2 -2
- package/tabs/esm/desktop/index.js +2 -2
- package/tabs/esm/index.js +2 -2
- package/tabs/esm/mobile/index.js +2 -2
- package/tabs/modern/collapsible/index.js +1 -1
- package/tabs/modern/components/primary-tablist/Component.collapsible.js +1 -1
- package/tabs/modern/components/primary-tablist/Component.desktop.js +1 -1
- package/tabs/modern/components/primary-tablist/Component.mobile.js +1 -1
- package/tabs/modern/components/primary-tablist/Component.responsive.js +1 -1
- package/tabs/modern/components/secondary-tablist/Component.desktop.js +1 -1
- package/tabs/modern/components/secondary-tablist/Component.mobile.js +1 -1
- package/tabs/modern/components/secondary-tablist/Component.responsive.js +1 -1
- package/tabs/modern/components/tabs/Component.collapsible.js +1 -1
- package/tabs/modern/components/tabs/Component.desktop.js +2 -2
- package/tabs/modern/components/tabs/Component.mobile.js +2 -2
- package/tabs/modern/components/tabs/Component.responsive.js +2 -2
- package/tabs/modern/desktop/index.js +2 -2
- package/tabs/modern/index.js +2 -2
- package/tabs/modern/mobile/index.js +2 -2
- package/textarea/Component.js +2 -2
- package/textarea/cssm/Component.js +2 -2
- package/textarea/cssm/typings.d.ts +5 -0
- package/textarea/esm/Component.js +2 -2
- package/textarea/esm/typings.d.ts +5 -0
- package/textarea/modern/Component.js +2 -2
- package/textarea/modern/typings.d.ts +5 -0
- package/textarea/typings.d.ts +5 -0
- package/themes/compiled/mobile-dark-bluetint.css +30 -169
- package/typography/esm/component.js +2 -2
- package/typography/esm/index.js +2 -2
- package/typography/esm/text/component.js +1 -1
- package/typography/esm/text/index.js +1 -1
- package/typography/esm/title/component.js +1 -1
- package/typography/esm/title/index.js +2 -2
- package/typography/esm/title-mobile/component.js +2 -2
- package/typography/esm/title-mobile/index.js +2 -2
- package/typography/esm/title-responsive/component.js +2 -2
- package/typography/esm/title-responsive/index.js +2 -2
- package/typography/modern/component.js +2 -2
- package/typography/modern/index.js +2 -2
- package/typography/modern/text/component.js +1 -1
- package/typography/modern/text/index.js +1 -1
- package/typography/modern/title/component.js +1 -1
- package/typography/modern/title/index.js +2 -2
- package/typography/modern/title-mobile/component.js +2 -2
- package/typography/modern/title-mobile/index.js +2 -2
- package/typography/modern/title-responsive/component.js +2 -2
- package/typography/modern/title-responsive/index.js +2 -2
- package/typography/text/component.js +1 -1
- package/typography/title/component.js +1 -1
- package/typography/title/index.js +1 -1
- package/typography/title-mobile/component.js +1 -1
- package/typography/title-responsive/component.js +1 -1
- /package/confirmation/{countdown-section-5581379b.d.ts → countdown-section-b30d5212.d.ts} +0 -0
- /package/confirmation/{countdown-section-5581379b.js → countdown-section-b30d5212.js} +0 -0
- /package/confirmation/esm/{countdown-section-2f02c020.d.ts → countdown-section-c4f73a77.d.ts} +0 -0
- /package/confirmation/esm/{countdown-section-2f02c020.js → countdown-section-c4f73a77.js} +0 -0
- /package/confirmation/modern/{countdown-section-27ad8a44.d.ts → countdown-section-f3215ad8.d.ts} +0 -0
- /package/confirmation/modern/{countdown-section-27ad8a44.js → countdown-section-f3215ad8.js} +0 -0
- /package/modal/esm/{layout.module-ec4a90b6.js → layout.module-95a81cec.js} +0 -0
- /package/modal/{layout.module-0786cc33.js → layout.module-7688fd0c.js} +0 -0
- /package/modal/modern/{layout.module-8379050e.js → layout.module-5b92887c.js} +0 -0
- /package/pure-cell/{component-911cc97f.d.ts → component-1b03bea6.d.ts} +0 -0
- /package/pure-cell/cssm/{component-719b272a.d.ts → component-e3105fca.d.ts} +0 -0
- /package/pure-cell/esm/{component-53618056.d.ts → component-02d56ae7.d.ts} +0 -0
- /package/pure-cell/modern/{component-254f4794.d.ts → component-766c0ee4.d.ts} +0 -0
- /package/select/esm/{hook-234f7a67.d.ts → hook-bff79f71.d.ts} +0 -0
- /package/select/esm/{hook-234f7a67.js → hook-bff79f71.js} +0 -0
- /package/select/{hook-5f6e7b13.d.ts → hook-54f25d8f.d.ts} +0 -0
- /package/select/{hook-5f6e7b13.js → hook-54f25d8f.js} +0 -0
- /package/select/modern/{hook-46a9009f.d.ts → hook-c270fa38.d.ts} +0 -0
- /package/select/modern/{hook-46a9009f.js → hook-c270fa38.js} +0 -0
- /package/tabs/esm/{index.module-a60afb2d.js → index.module-0655283c.js} +0 -0
- /package/tabs/esm/{index.module-e6c5bf7b.js → index.module-7ff70640.js} +0 -0
- /package/tabs/{index.module-2a9c83e8.js → index.module-5e2c2277.js} +0 -0
- /package/tabs/{index.module-a4d37ad2.js → index.module-c171ff65.js} +0 -0
- /package/tabs/modern/{index.module-7ddd604e.js → index.module-65b2af6e.js} +0 -0
- /package/tabs/modern/{index.module-f30fb0bd.js → index.module-d1b9db81.js} +0 -0
- /package/typography/{colors.module-a11b73e9.js → colors.module-1425c827.js} +0 -0
- /package/typography/{common.module-25e7ce83.js → common.module-7149df75.js} +0 -0
- /package/typography/esm/{colors.module-e5414e42.js → colors.module-2c5f7086.js} +0 -0
- /package/typography/esm/{common.module-bd07cc74.js → common.module-34c95dd1.js} +0 -0
- /package/typography/modern/{colors.module-9fa7fdee.js → colors.module-dfec17f2.js} +0 -0
- /package/typography/modern/{common.module-e73684d9.js → common.module-6efdb2ce.js} +0 -0
package/bank-card/Component.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ChangeEvent, MouseEvent, ReactNode } from "react";
|
|
4
|
+
import { MaskType } from "./types";
|
|
4
5
|
type BankCardProps = {
|
|
5
6
|
/**
|
|
6
7
|
* Дополнительный класс
|
|
@@ -36,6 +37,11 @@ type BankCardProps = {
|
|
|
36
37
|
* Идентификатор для систем автоматизированного тестирования
|
|
37
38
|
*/
|
|
38
39
|
dataTestId?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Тип вводимой маски. Позволяет устанавливать необходимый тип номера (номер карты или номер счёта)
|
|
42
|
+
* Если параметр не передавать - работает с обоими типами номеров
|
|
43
|
+
*/
|
|
44
|
+
maskType?: MaskType;
|
|
39
45
|
};
|
|
40
46
|
declare const BankCard: React.ForwardRefExoticComponent<BankCardProps & React.RefAttributes<HTMLInputElement>>;
|
|
41
47
|
export { BankCardProps, BankCard };
|
package/bank-card/Component.js
CHANGED
|
@@ -8,6 +8,8 @@ var AlfaBankLIcon = require('@alfalab/icons-logotype/AlfaBankLIcon');
|
|
|
8
8
|
var MastercardLIcon = require('@alfalab/icons-logotype/MastercardLIcon');
|
|
9
9
|
var MirXxlIcon = require('@alfalab/icons-logotype/MirXxlIcon');
|
|
10
10
|
var VisaXxlIcon = require('@alfalab/icons-logotype/VisaXxlIcon');
|
|
11
|
+
var helpers_getDefaultInputLabel = require('./helpers/getDefaultInputLabel.js');
|
|
12
|
+
var enums = require('./enums.js');
|
|
11
13
|
var utils = require('./utils.js');
|
|
12
14
|
|
|
13
15
|
function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
|
|
@@ -38,12 +40,20 @@ var getBrandIcon = function (value) {
|
|
|
38
40
|
return null;
|
|
39
41
|
};
|
|
40
42
|
var BankCard = React__default.default.forwardRef(function (_a, ref) {
|
|
41
|
-
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c,
|
|
43
|
+
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c, value = _a.value, className = _a.className, onUsePhoto = _a.onUsePhoto, onChange = _a.onChange, dataTestId = _a.dataTestId, _d = _a.maskType, maskType = _d === void 0 ? enums.MaskTypeEnum.Default : _d, _e = _a.inputLabel, inputLabel = _e === void 0 ? helpers_getDefaultInputLabel.getDefaultInputLabel(maskType) : _e;
|
|
42
44
|
var uncontrolled = value === undefined;
|
|
43
|
-
var
|
|
45
|
+
var _f = React.useState(getBrandIcon(value)), brandIcon = _f[0], setBrandIcon = _f[1];
|
|
44
46
|
var getMask = React.useCallback(function (newValue) {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
+
switch (maskType) {
|
|
48
|
+
case enums.MaskTypeEnum.Card:
|
|
49
|
+
return cardMask;
|
|
50
|
+
case enums.MaskTypeEnum.AccountNumber:
|
|
51
|
+
return accountNumberMask;
|
|
52
|
+
case enums.MaskTypeEnum.Default:
|
|
53
|
+
default:
|
|
54
|
+
return newValue.length <= cardMask.length ? cardMask : accountNumberMask;
|
|
55
|
+
}
|
|
56
|
+
}, [maskType]);
|
|
47
57
|
var handleInputChange = React.useCallback(function (event, payload) {
|
|
48
58
|
if (uncontrolled) {
|
|
49
59
|
setBrandIcon(getBrandIcon(event.target.value));
|
|
@@ -64,10 +74,5 @@ var BankCard = React__default.default.forwardRef(function (_a, ref) {
|
|
|
64
74
|
React__default.default.createElement(coreComponentsMaskedInput.MaskedInput, { ref: ref, value: value, mask: getMask, block: true, label: inputLabel, size: 'm', rightAddons: renderRightAddons(), inputClassName: styles.input, labelClassName: styles.label, filledClassName: styles.filled, focusedClassName: styles.focused, onChange: handleInputChange, dataTestId: dataTestId, inputMode: 'numeric', pattern: '[0-9]*', breakpoint: 1 }),
|
|
65
75
|
brandIcon && React__default.default.createElement("div", { className: styles.brandLogo }, brandIcon)))));
|
|
66
76
|
});
|
|
67
|
-
BankCard.defaultProps = {
|
|
68
|
-
bankLogo: React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null),
|
|
69
|
-
backgroundColor: '#EF3124',
|
|
70
|
-
inputLabel: 'Номер карты или счёта',
|
|
71
|
-
};
|
|
72
77
|
|
|
73
78
|
exports.BankCard = BankCard;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ChangeEvent, MouseEvent, ReactNode } from "react";
|
|
4
|
+
import { MaskType } from "./types";
|
|
4
5
|
type BankCardProps = {
|
|
5
6
|
/**
|
|
6
7
|
* Дополнительный класс
|
|
@@ -36,6 +37,11 @@ type BankCardProps = {
|
|
|
36
37
|
* Идентификатор для систем автоматизированного тестирования
|
|
37
38
|
*/
|
|
38
39
|
dataTestId?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Тип вводимой маски. Позволяет устанавливать необходимый тип номера (номер карты или номер счёта)
|
|
42
|
+
* Если параметр не передавать - работает с обоими типами номеров
|
|
43
|
+
*/
|
|
44
|
+
maskType?: MaskType;
|
|
39
45
|
};
|
|
40
46
|
declare const BankCard: React.ForwardRefExoticComponent<BankCardProps & React.RefAttributes<HTMLInputElement>>;
|
|
41
47
|
export { BankCardProps, BankCard };
|
|
@@ -8,6 +8,8 @@ var AlfaBankLIcon = require('@alfalab/icons-logotype/AlfaBankLIcon');
|
|
|
8
8
|
var MastercardLIcon = require('@alfalab/icons-logotype/MastercardLIcon');
|
|
9
9
|
var MirXxlIcon = require('@alfalab/icons-logotype/MirXxlIcon');
|
|
10
10
|
var VisaXxlIcon = require('@alfalab/icons-logotype/VisaXxlIcon');
|
|
11
|
+
var helpers_getDefaultInputLabel = require('./helpers/getDefaultInputLabel.js');
|
|
12
|
+
var enums = require('./enums.js');
|
|
11
13
|
var utils = require('./utils.js');
|
|
12
14
|
var styles = require('./index.module.css');
|
|
13
15
|
|
|
@@ -37,12 +39,20 @@ var getBrandIcon = function (value) {
|
|
|
37
39
|
return null;
|
|
38
40
|
};
|
|
39
41
|
var BankCard = React__default.default.forwardRef(function (_a, ref) {
|
|
40
|
-
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c,
|
|
42
|
+
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c, value = _a.value, className = _a.className, onUsePhoto = _a.onUsePhoto, onChange = _a.onChange, dataTestId = _a.dataTestId, _d = _a.maskType, maskType = _d === void 0 ? enums.MaskTypeEnum.Default : _d, _e = _a.inputLabel, inputLabel = _e === void 0 ? helpers_getDefaultInputLabel.getDefaultInputLabel(maskType) : _e;
|
|
41
43
|
var uncontrolled = value === undefined;
|
|
42
|
-
var
|
|
44
|
+
var _f = React.useState(getBrandIcon(value)), brandIcon = _f[0], setBrandIcon = _f[1];
|
|
43
45
|
var getMask = React.useCallback(function (newValue) {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
+
switch (maskType) {
|
|
47
|
+
case enums.MaskTypeEnum.Card:
|
|
48
|
+
return cardMask;
|
|
49
|
+
case enums.MaskTypeEnum.AccountNumber:
|
|
50
|
+
return accountNumberMask;
|
|
51
|
+
case enums.MaskTypeEnum.Default:
|
|
52
|
+
default:
|
|
53
|
+
return newValue.length <= cardMask.length ? cardMask : accountNumberMask;
|
|
54
|
+
}
|
|
55
|
+
}, [maskType]);
|
|
46
56
|
var handleInputChange = React.useCallback(function (event, payload) {
|
|
47
57
|
if (uncontrolled) {
|
|
48
58
|
setBrandIcon(getBrandIcon(event.target.value));
|
|
@@ -63,10 +73,5 @@ var BankCard = React__default.default.forwardRef(function (_a, ref) {
|
|
|
63
73
|
React__default.default.createElement(coreComponentsMaskedInput.MaskedInput, { ref: ref, value: value, mask: getMask, block: true, label: inputLabel, size: 'm', rightAddons: renderRightAddons(), inputClassName: styles__default.default.input, labelClassName: styles__default.default.label, filledClassName: styles__default.default.filled, focusedClassName: styles__default.default.focused, onChange: handleInputChange, dataTestId: dataTestId, inputMode: 'numeric', pattern: '[0-9]*', breakpoint: 1 }),
|
|
64
74
|
brandIcon && React__default.default.createElement("div", { className: styles__default.default.brandLogo }, brandIcon)))));
|
|
65
75
|
});
|
|
66
|
-
BankCard.defaultProps = {
|
|
67
|
-
bankLogo: React__default.default.createElement(AlfaBankLIcon.AlfaBankLIcon, null),
|
|
68
|
-
backgroundColor: '#EF3124',
|
|
69
|
-
inputLabel: 'Номер карты или счёта',
|
|
70
|
-
};
|
|
71
76
|
|
|
72
77
|
exports.BankCard = BankCard;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
+
|
|
3
|
+
exports.MaskTypeEnum = void 0;
|
|
4
|
+
(function (MaskTypeEnum) {
|
|
5
|
+
MaskTypeEnum["Card"] = "card";
|
|
6
|
+
MaskTypeEnum["AccountNumber"] = "account-number";
|
|
7
|
+
MaskTypeEnum["Default"] = "default";
|
|
8
|
+
})(exports.MaskTypeEnum || (exports.MaskTypeEnum = {}));
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
+
|
|
3
|
+
var enums = require('../enums.js');
|
|
4
|
+
|
|
5
|
+
var getDefaultInputLabel = function (maskType) {
|
|
6
|
+
switch (maskType) {
|
|
7
|
+
case enums.MaskTypeEnum.Card:
|
|
8
|
+
return 'Номер карты';
|
|
9
|
+
case enums.MaskTypeEnum.AccountNumber:
|
|
10
|
+
return 'Номер счёта';
|
|
11
|
+
case enums.MaskTypeEnum.Default:
|
|
12
|
+
default:
|
|
13
|
+
return 'Номер карты или счёта';
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
exports.getDefaultInputLabel = getDefaultInputLabel;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
+
|
|
3
|
+
exports.MaskTypeEnum = void 0;
|
|
4
|
+
(function (MaskTypeEnum) {
|
|
5
|
+
MaskTypeEnum["Card"] = "card";
|
|
6
|
+
MaskTypeEnum["AccountNumber"] = "account-number";
|
|
7
|
+
MaskTypeEnum["Default"] = "default";
|
|
8
|
+
})(exports.MaskTypeEnum || (exports.MaskTypeEnum = {}));
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ChangeEvent, MouseEvent, ReactNode } from "react";
|
|
4
|
+
import { MaskType } from "./types";
|
|
4
5
|
type BankCardProps = {
|
|
5
6
|
/**
|
|
6
7
|
* Дополнительный класс
|
|
@@ -36,6 +37,11 @@ type BankCardProps = {
|
|
|
36
37
|
* Идентификатор для систем автоматизированного тестирования
|
|
37
38
|
*/
|
|
38
39
|
dataTestId?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Тип вводимой маски. Позволяет устанавливать необходимый тип номера (номер карты или номер счёта)
|
|
42
|
+
* Если параметр не передавать - работает с обоими типами номеров
|
|
43
|
+
*/
|
|
44
|
+
maskType?: MaskType;
|
|
39
45
|
};
|
|
40
46
|
declare const BankCard: React.ForwardRefExoticComponent<BankCardProps & React.RefAttributes<HTMLInputElement>>;
|
|
41
47
|
export { BankCardProps, BankCard };
|
|
@@ -6,6 +6,8 @@ import { AlfaBankLIcon } from '@alfalab/icons-logotype/AlfaBankLIcon';
|
|
|
6
6
|
import { MastercardLIcon } from '@alfalab/icons-logotype/MastercardLIcon';
|
|
7
7
|
import { MirXxlIcon } from '@alfalab/icons-logotype/MirXxlIcon';
|
|
8
8
|
import { VisaXxlIcon } from '@alfalab/icons-logotype/VisaXxlIcon';
|
|
9
|
+
import { getDefaultInputLabel } from './helpers/getDefaultInputLabel.js';
|
|
10
|
+
import { MaskTypeEnum } from './enums.js';
|
|
9
11
|
import { validateCardNumber } from './utils.js';
|
|
10
12
|
|
|
11
13
|
var styles = {"component":"bank-card__component_k6v85","aspectRatioContainer":"bank-card__aspectRatioContainer_k6v85","content":"bank-card__content_k6v85","label":"bank-card__label_k6v85","focused":"bank-card__focused_k6v85","filled":"bank-card__filled_k6v85","input":"bank-card__input_k6v85","bankLogo":"bank-card__bankLogo_k6v85","brandLogo":"bank-card__brandLogo_k6v85","usePhoto":"bank-card__usePhoto_k6v85"};
|
|
@@ -31,12 +33,20 @@ var getBrandIcon = function (value) {
|
|
|
31
33
|
return null;
|
|
32
34
|
};
|
|
33
35
|
var BankCard = React.forwardRef(function (_a, ref) {
|
|
34
|
-
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React.createElement(AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c,
|
|
36
|
+
var _b = _a.bankLogo, bankLogo = _b === void 0 ? React.createElement(AlfaBankLIcon, null) : _b, _c = _a.backgroundColor, backgroundColor = _c === void 0 ? '#EF3124' : _c, value = _a.value, className = _a.className, onUsePhoto = _a.onUsePhoto, onChange = _a.onChange, dataTestId = _a.dataTestId, _d = _a.maskType, maskType = _d === void 0 ? MaskTypeEnum.Default : _d, _e = _a.inputLabel, inputLabel = _e === void 0 ? getDefaultInputLabel(maskType) : _e;
|
|
35
37
|
var uncontrolled = value === undefined;
|
|
36
|
-
var
|
|
38
|
+
var _f = useState(getBrandIcon(value)), brandIcon = _f[0], setBrandIcon = _f[1];
|
|
37
39
|
var getMask = useCallback(function (newValue) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
+
switch (maskType) {
|
|
41
|
+
case MaskTypeEnum.Card:
|
|
42
|
+
return cardMask;
|
|
43
|
+
case MaskTypeEnum.AccountNumber:
|
|
44
|
+
return accountNumberMask;
|
|
45
|
+
case MaskTypeEnum.Default:
|
|
46
|
+
default:
|
|
47
|
+
return newValue.length <= cardMask.length ? cardMask : accountNumberMask;
|
|
48
|
+
}
|
|
49
|
+
}, [maskType]);
|
|
40
50
|
var handleInputChange = useCallback(function (event, payload) {
|
|
41
51
|
if (uncontrolled) {
|
|
42
52
|
setBrandIcon(getBrandIcon(event.target.value));
|
|
@@ -57,10 +67,5 @@ var BankCard = React.forwardRef(function (_a, ref) {
|
|
|
57
67
|
React.createElement(MaskedInput, { ref: ref, value: value, mask: getMask, block: true, label: inputLabel, size: 'm', rightAddons: renderRightAddons(), inputClassName: styles.input, labelClassName: styles.label, filledClassName: styles.filled, focusedClassName: styles.focused, onChange: handleInputChange, dataTestId: dataTestId, inputMode: 'numeric', pattern: '[0-9]*', breakpoint: 1 }),
|
|
58
68
|
brandIcon && React.createElement("div", { className: styles.brandLogo }, brandIcon)))));
|
|
59
69
|
});
|
|
60
|
-
BankCard.defaultProps = {
|
|
61
|
-
bankLogo: React.createElement(AlfaBankLIcon, null),
|
|
62
|
-
backgroundColor: '#EF3124',
|
|
63
|
-
inputLabel: 'Номер карты или счёта',
|
|
64
|
-
};
|
|
65
70
|
|
|
66
71
|
export { BankCard };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { MaskTypeEnum } from '../enums.js';
|
|
2
|
+
|
|
3
|
+
var getDefaultInputLabel = function (maskType) {
|
|
4
|
+
switch (maskType) {
|
|
5
|
+
case MaskTypeEnum.Card:
|
|
6
|
+
return 'Номер карты';
|
|
7
|
+
case MaskTypeEnum.AccountNumber:
|
|
8
|
+
return 'Номер счёта';
|
|
9
|
+
case MaskTypeEnum.Default:
|
|
10
|
+
default:
|
|
11
|
+
return 'Номер карты или счёта';
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export { getDefaultInputLabel };
|
package/bank-card/esm/index.js
CHANGED
|
@@ -7,4 +7,6 @@ import '@alfalab/icons-logotype/AlfaBankLIcon';
|
|
|
7
7
|
import '@alfalab/icons-logotype/MastercardLIcon';
|
|
8
8
|
import '@alfalab/icons-logotype/MirXxlIcon';
|
|
9
9
|
import '@alfalab/icons-logotype/VisaXxlIcon';
|
|
10
|
+
import './helpers/getDefaultInputLabel.js';
|
|
11
|
+
import './enums.js';
|
|
10
12
|
import './utils.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
+
|
|
3
|
+
var enums = require('../enums.js');
|
|
4
|
+
|
|
5
|
+
var getDefaultInputLabel = function (maskType) {
|
|
6
|
+
switch (maskType) {
|
|
7
|
+
case enums.MaskTypeEnum.Card:
|
|
8
|
+
return 'Номер карты';
|
|
9
|
+
case enums.MaskTypeEnum.AccountNumber:
|
|
10
|
+
return 'Номер счёта';
|
|
11
|
+
case enums.MaskTypeEnum.Default:
|
|
12
|
+
default:
|
|
13
|
+
return 'Номер карты или счёта';
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
exports.getDefaultInputLabel = getDefaultInputLabel;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ChangeEvent, MouseEvent, ReactNode } from "react";
|
|
4
|
+
import { MaskType } from "./types";
|
|
4
5
|
type BankCardProps = {
|
|
5
6
|
/**
|
|
6
7
|
* Дополнительный класс
|
|
@@ -36,6 +37,11 @@ type BankCardProps = {
|
|
|
36
37
|
* Идентификатор для систем автоматизированного тестирования
|
|
37
38
|
*/
|
|
38
39
|
dataTestId?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Тип вводимой маски. Позволяет устанавливать необходимый тип номера (номер карты или номер счёта)
|
|
42
|
+
* Если параметр не передавать - работает с обоими типами номеров
|
|
43
|
+
*/
|
|
44
|
+
maskType?: MaskType;
|
|
39
45
|
};
|
|
40
46
|
declare const BankCard: React.ForwardRefExoticComponent<BankCardProps & React.RefAttributes<HTMLInputElement>>;
|
|
41
47
|
export { BankCardProps, BankCard };
|
|
@@ -6,6 +6,8 @@ import { AlfaBankLIcon } from '@alfalab/icons-logotype/AlfaBankLIcon';
|
|
|
6
6
|
import { MastercardLIcon } from '@alfalab/icons-logotype/MastercardLIcon';
|
|
7
7
|
import { MirXxlIcon } from '@alfalab/icons-logotype/MirXxlIcon';
|
|
8
8
|
import { VisaXxlIcon } from '@alfalab/icons-logotype/VisaXxlIcon';
|
|
9
|
+
import { getDefaultInputLabel } from './helpers/getDefaultInputLabel.js';
|
|
10
|
+
import { MaskTypeEnum } from './enums.js';
|
|
9
11
|
import { validateCardNumber } from './utils.js';
|
|
10
12
|
|
|
11
13
|
const styles = {"component":"bank-card__component_k6v85","aspectRatioContainer":"bank-card__aspectRatioContainer_k6v85","content":"bank-card__content_k6v85","label":"bank-card__label_k6v85","focused":"bank-card__focused_k6v85","filled":"bank-card__filled_k6v85","input":"bank-card__input_k6v85","bankLogo":"bank-card__bankLogo_k6v85","brandLogo":"bank-card__brandLogo_k6v85","usePhoto":"bank-card__usePhoto_k6v85"};
|
|
@@ -29,10 +31,20 @@ const getBrandIcon = (value = '') => {
|
|
|
29
31
|
}
|
|
30
32
|
return null;
|
|
31
33
|
};
|
|
32
|
-
const BankCard = React.forwardRef(({ bankLogo = React.createElement(AlfaBankLIcon, null), backgroundColor = '#EF3124',
|
|
34
|
+
const BankCard = React.forwardRef(({ bankLogo = React.createElement(AlfaBankLIcon, null), backgroundColor = '#EF3124', value, className, onUsePhoto, onChange, dataTestId, maskType = MaskTypeEnum.Default, inputLabel = getDefaultInputLabel(maskType), }, ref) => {
|
|
33
35
|
const uncontrolled = value === undefined;
|
|
34
36
|
const [brandIcon, setBrandIcon] = useState(getBrandIcon(value));
|
|
35
|
-
const getMask = useCallback((newValue) =>
|
|
37
|
+
const getMask = useCallback((newValue) => {
|
|
38
|
+
switch (maskType) {
|
|
39
|
+
case MaskTypeEnum.Card:
|
|
40
|
+
return cardMask;
|
|
41
|
+
case MaskTypeEnum.AccountNumber:
|
|
42
|
+
return accountNumberMask;
|
|
43
|
+
case MaskTypeEnum.Default:
|
|
44
|
+
default:
|
|
45
|
+
return newValue.length <= cardMask.length ? cardMask : accountNumberMask;
|
|
46
|
+
}
|
|
47
|
+
}, [maskType]);
|
|
36
48
|
const handleInputChange = useCallback((event, payload) => {
|
|
37
49
|
if (uncontrolled) {
|
|
38
50
|
setBrandIcon(getBrandIcon(event.target.value));
|
|
@@ -53,10 +65,5 @@ const BankCard = React.forwardRef(({ bankLogo = React.createElement(AlfaBankLIco
|
|
|
53
65
|
React.createElement(MaskedInput, { ref: ref, value: value, mask: getMask, block: true, label: inputLabel, size: 'm', rightAddons: renderRightAddons(), inputClassName: styles.input, labelClassName: styles.label, filledClassName: styles.filled, focusedClassName: styles.focused, onChange: handleInputChange, dataTestId: dataTestId, inputMode: 'numeric', pattern: '[0-9]*', breakpoint: 1 }),
|
|
54
66
|
brandIcon && React.createElement("div", { className: styles.brandLogo }, brandIcon)))));
|
|
55
67
|
});
|
|
56
|
-
BankCard.defaultProps = {
|
|
57
|
-
bankLogo: React.createElement(AlfaBankLIcon, null),
|
|
58
|
-
backgroundColor: '#EF3124',
|
|
59
|
-
inputLabel: 'Номер карты или счёта',
|
|
60
|
-
};
|
|
61
68
|
|
|
62
69
|
export { BankCard };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { MaskTypeEnum } from '../enums.js';
|
|
2
|
+
|
|
3
|
+
const getDefaultInputLabel = (maskType) => {
|
|
4
|
+
switch (maskType) {
|
|
5
|
+
case MaskTypeEnum.Card:
|
|
6
|
+
return 'Номер карты';
|
|
7
|
+
case MaskTypeEnum.AccountNumber:
|
|
8
|
+
return 'Номер счёта';
|
|
9
|
+
case MaskTypeEnum.Default:
|
|
10
|
+
default:
|
|
11
|
+
return 'Номер карты или счёта';
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export { getDefaultInputLabel };
|
|
@@ -7,4 +7,6 @@ import '@alfalab/icons-logotype/AlfaBankLIcon';
|
|
|
7
7
|
import '@alfalab/icons-logotype/MastercardLIcon';
|
|
8
8
|
import '@alfalab/icons-logotype/MirXxlIcon';
|
|
9
9
|
import '@alfalab/icons-logotype/VisaXxlIcon';
|
|
10
|
+
import './helpers/getDefaultInputLabel.js';
|
|
11
|
+
import './enums.js';
|
|
10
12
|
import './utils.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -11,6 +11,7 @@ var coreComponentsShared = require('../shared');
|
|
|
11
11
|
var components_footer_Component = require('./components/footer/Component.js');
|
|
12
12
|
var components_header_Component = require('./components/header/Component.js');
|
|
13
13
|
var components_swipeableBackdrop_Component = require('./components/swipeable-backdrop/Component.js');
|
|
14
|
+
var consts_swipeConsts = require('./consts/swipeConsts.js');
|
|
14
15
|
var utils = require('./utils.js');
|
|
15
16
|
|
|
16
17
|
function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
|
|
@@ -188,8 +189,9 @@ var BottomSheet = React.forwardRef(function (_a, ref) {
|
|
|
188
189
|
* Если контент внутри шторки скроллится - то шторка не должна свайпаться
|
|
189
190
|
* Если шапка внутри шторки зафиксирована - то шторка должна свайпаться только в области шапки
|
|
190
191
|
*/
|
|
191
|
-
var shouldSkipSwiping = function (
|
|
192
|
+
var shouldSkipSwiping = function (swipeParams) {
|
|
192
193
|
var _a;
|
|
194
|
+
var deltaY = swipeParams.deltaY, startY = swipeParams.startY, event = swipeParams.event, dir = swipeParams.dir;
|
|
193
195
|
if (scrollLockedProp || swipingInProgress)
|
|
194
196
|
return false;
|
|
195
197
|
if (!swipeableContent && ((_a = contentRef.current) === null || _a === void 0 ? void 0 : _a.contains(event.target))) {
|
|
@@ -214,18 +216,24 @@ var BottomSheet = React.forwardRef(function (_a, ref) {
|
|
|
214
216
|
if (!scrollOccurred.current && shouldScroll) {
|
|
215
217
|
scrollOccurred.current = true;
|
|
216
218
|
}
|
|
219
|
+
// Если контент внутри шторки скроллится горизонально - то шторка не должна закрываться
|
|
220
|
+
if (consts_swipeConsts.horizontalDirections.includes(dir)) {
|
|
221
|
+
return true;
|
|
222
|
+
}
|
|
217
223
|
return shouldScroll;
|
|
218
224
|
};
|
|
219
|
-
var
|
|
220
|
-
var initial =
|
|
221
|
-
|
|
225
|
+
var handleSheetSwipeEnd = function (swipeParams) {
|
|
226
|
+
var initial = swipeParams.initial, velocity = swipeParams.velocity, deltaY = swipeParams.deltaY, event = swipeParams.event, dir = swipeParams.dir;
|
|
227
|
+
var shouldPreventSwipe = scrollOccurred.current ||
|
|
228
|
+
shouldSkipSwiping({ deltaY: deltaY, startY: initial[1], event: event, dir: dir });
|
|
229
|
+
if (shouldPreventSwipe) {
|
|
222
230
|
return;
|
|
223
231
|
}
|
|
224
232
|
magnetize(velocity, deltaY);
|
|
225
233
|
};
|
|
226
|
-
var handleSheetSwipeStart = function (
|
|
227
|
-
var deltaY =
|
|
228
|
-
if (shouldSkipSwiping(deltaY, initial[1], event)) {
|
|
234
|
+
var handleSheetSwipeStart = function (swipeParams) {
|
|
235
|
+
var deltaY = swipeParams.deltaY, initial = swipeParams.initial, event = swipeParams.event, dir = swipeParams.dir;
|
|
236
|
+
if (shouldSkipSwiping({ deltaY: deltaY, startY: initial[1], event: event, dir: dir })) {
|
|
229
237
|
return;
|
|
230
238
|
}
|
|
231
239
|
startSwiping(event);
|
|
@@ -234,9 +242,11 @@ var BottomSheet = React.forwardRef(function (_a, ref) {
|
|
|
234
242
|
var event = _a.event;
|
|
235
243
|
return stopSwiping(event);
|
|
236
244
|
};
|
|
237
|
-
var
|
|
238
|
-
var initial =
|
|
239
|
-
|
|
245
|
+
var handleSheetSwipeMove = function (swipeParams) {
|
|
246
|
+
var initial = swipeParams.initial, deltaY = swipeParams.deltaY, event = swipeParams.event, dir = swipeParams.dir;
|
|
247
|
+
var shouldPreventSwipe = scrollOccurred.current ||
|
|
248
|
+
shouldSkipSwiping({ deltaY: deltaY, startY: initial[1], event: event, dir: dir });
|
|
249
|
+
if (shouldPreventSwipe) {
|
|
240
250
|
return;
|
|
241
251
|
}
|
|
242
252
|
if (!swipingInProgress) {
|
|
@@ -249,8 +259,8 @@ var BottomSheet = React.forwardRef(function (_a, ref) {
|
|
|
249
259
|
};
|
|
250
260
|
var sheetSwipeableHandlers = reactSwipeable.useSwipeable({
|
|
251
261
|
onSwipeStart: handleSheetSwipeStart,
|
|
252
|
-
onSwiping:
|
|
253
|
-
onSwiped:
|
|
262
|
+
onSwiping: handleSheetSwipeMove,
|
|
263
|
+
onSwiped: handleSheetSwipeEnd,
|
|
254
264
|
onTouchEndOrOnMouseUp: handleTouchEnd,
|
|
255
265
|
trackMouse: swipeable,
|
|
256
266
|
trackTouch: swipeable,
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
2
|
+
|
|
3
|
+
var enums_swipeEnums = require('../enums/swipeEnums.js');
|
|
4
|
+
|
|
5
|
+
var horizontalDirections = [enums_swipeEnums.SwipeDirection.Left, enums_swipeEnums.SwipeDirection.Right];
|
|
6
|
+
|
|
7
|
+
exports.horizontalDirections = horizontalDirections;
|