@itcase/ui 1.3.31 → 1.3.32
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/dist/Badge-BX4N91_C.js +250 -0
- package/dist/Badge-CGHosmYx.js +246 -0
- package/dist/Button-D1m2MxZA.js +291 -0
- package/dist/Button-DZ3z7f-A.js +287 -0
- package/dist/Divider-BQcBkzt1.js +30 -0
- package/dist/Divider-ImOOytuN.js +34 -0
- package/dist/{DropdownItem-FNOztnTT.js → DropdownItem-BiiEhR49.js} +12 -16
- package/dist/{DropdownItem-Bq-oPnWX.js → DropdownItem-g5jWbyJy.js} +12 -16
- package/dist/{Group-c3ZkPu8e.js → Group-BKJmVwPZ.js} +4 -4
- package/dist/{Group-BY8OkVsS.js → Group-Bkz3RO18.js} +4 -4
- package/dist/{Icon-pUvizy3W.js → Icon-GVGrUu_Z.js} +6 -6
- package/dist/{Icon-BdHr6E6M.js → Icon-htF_V35Y.js} +7 -7
- package/dist/{Image-BbBG_UGI.js → Image-BEGwuGBM.js} +4 -4
- package/dist/{Image-D-QHhsrC.js → Image-DWfyapuD.js} +4 -4
- package/dist/{Input-BrV5_NoV.js → Input-COFdaiTe.js} +3 -3
- package/dist/{Input-ffioh1sj.js → Input-Dwvk-poq.js} +3 -3
- package/dist/Label-Dpeq55TV.js +233 -0
- package/dist/Label-XTFwl1aq.js +237 -0
- package/dist/{Link-CxWmYMyL.js → Link-B38Hn4G2.js} +5 -5
- package/dist/{Link-DN2LhPjD.js → Link-BhJ5BdyS.js} +6 -6
- package/dist/Loader-CBEbIRnd.js +69 -0
- package/dist/Loader-CsPvc-9g.js +65 -0
- package/dist/{MenuItem-CLDNk2l8.js → MenuItem-Cjlnmfwh.js} +6 -6
- package/dist/{MenuItem-amqx61Y0.js → MenuItem-PJkuGghn.js} +6 -6
- package/dist/{Overlay-B9nOIfLe.js → Overlay-BKh07Vb2.js} +4 -4
- package/dist/{Overlay-Yf9EEclM.js → Overlay-DiCjwUv4.js} +4 -4
- package/dist/{Text-Beslj4Ns.js → Text-C49zj3jO.js} +7 -7
- package/dist/{Text-JayJa3hj.js → Text-C6NSmetx.js} +7 -7
- package/dist/{Title-BfKF5WvZ.js → Title-BWWyRwLY.js} +4 -4
- package/dist/{Title-C7Qv9WfS.js → Title-Dck3eHNM.js} +4 -4
- package/dist/{Tooltip-AodzD-7D.js → Tooltip-BYgzNVYI.js} +18 -14
- package/dist/{Tooltip-BDEyAnd-.js → Tooltip-DpBQQoNo.js} +18 -14
- package/dist/cjs/components/Accordion.js +15 -15
- package/dist/cjs/components/Avatar.js +22 -20
- package/dist/cjs/components/Badge.js +12 -7
- package/dist/cjs/components/Breadcrumbs.js +16 -21
- package/dist/cjs/components/Button.js +13 -13
- package/dist/cjs/components/Card.js +9 -9
- package/dist/cjs/components/Cell.js +32 -17
- package/dist/cjs/components/Checkbox.js +13 -13
- package/dist/cjs/components/Checkmark.js +25 -23
- package/dist/cjs/components/Chips.js +22 -17
- package/dist/cjs/components/Choice.js +13 -13
- package/dist/cjs/components/Code.js +9 -19
- package/dist/cjs/components/CookiesWarning.js +15 -15
- package/dist/cjs/components/DadataHintField.js +4 -3
- package/dist/cjs/components/DatePicker.js +43 -19
- package/dist/cjs/components/Divider.js +7 -7
- package/dist/cjs/components/Dot.js +7 -7
- package/dist/cjs/components/Dropdown.js +9 -9
- package/dist/cjs/components/Flex.js +12 -11
- package/dist/cjs/components/Grid.js +12 -12
- package/dist/cjs/components/Group.js +6 -6
- package/dist/cjs/components/HTMLContent.js +7 -7
- package/dist/cjs/components/HeroTitle.js +9 -9
- package/dist/cjs/components/Icon.js +10 -10
- package/dist/cjs/components/Image.js +6 -6
- package/dist/cjs/components/Input.js +4 -3
- package/dist/cjs/components/InputMask.js +16 -15
- package/dist/cjs/components/InputPassword.js +12 -16
- package/dist/cjs/components/Label.js +10 -10
- package/dist/cjs/components/Link.js +6 -6
- package/dist/cjs/components/List.js +13 -12
- package/dist/cjs/components/Loader.js +8 -8
- package/dist/cjs/components/Logo.js +17 -15
- package/dist/cjs/components/Menu.js +11 -15
- package/dist/cjs/components/MenuItem.js +8 -8
- package/dist/cjs/components/Modal.js +11 -16
- package/dist/cjs/components/ModalSheetBottom.js +3 -3
- package/dist/cjs/components/Notification.js +8 -8
- package/dist/cjs/components/Overlay.js +6 -6
- package/dist/cjs/components/Pagination.js +14 -14
- package/dist/cjs/components/Panel.js +9 -9
- package/dist/cjs/components/Radio.js +16 -19
- package/dist/cjs/components/RangeSlider.js +7 -7
- package/dist/cjs/components/Response.js +15 -15
- package/dist/cjs/components/SVGContent.js +7 -7
- package/dist/cjs/components/ScrollOnDrag.js +8 -11
- package/dist/cjs/components/ScrollToView.js +9 -9
- package/dist/cjs/components/Search.js +16 -19
- package/dist/cjs/components/Segmented.js +8 -8
- package/dist/cjs/components/Select.js +34 -34
- package/dist/cjs/components/Swiper.js +11 -14
- package/dist/cjs/components/Switch.js +1 -1
- package/dist/cjs/components/Tab.js +17 -13
- package/dist/cjs/components/Text.js +6 -6
- package/dist/cjs/components/Textarea.js +8 -11
- package/dist/cjs/components/Tile.js +24 -20
- package/dist/cjs/components/Title.js +8 -8
- package/dist/cjs/components/Tooltip.js +9 -9
- package/dist/cjs/components/Video.js +4 -3
- package/dist/cjs/context/UIContext.js +48 -17
- package/dist/cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +120 -0
- package/dist/cjs/hooks/useDevicePropsGenerator.js +17 -0
- package/dist/cjs/hooks/useDeviceTargetClass.js +8 -3
- package/dist/cjs/hooks/useMediaQueries/useMediaQueries.js +129 -0
- package/dist/cjs/hooks/useMediaQueries.js +4 -122
- package/dist/cjs/hooks/{styleAttributes.js → useStyles/styleAttributes.js} +8 -1
- package/dist/cjs/hooks/useStyles/useStyles.js +190 -0
- package/dist/cjs/hooks/useStyles.js +10 -174
- package/dist/components/Accordion.js +16 -16
- package/dist/components/Avatar.js +22 -20
- package/dist/components/Badge.js +13 -8
- package/dist/components/Breadcrumbs.js +17 -22
- package/dist/components/Button.js +13 -13
- package/dist/components/Card.js +10 -10
- package/dist/components/Cell.js +33 -18
- package/dist/components/Checkbox.js +14 -14
- package/dist/components/Checkmark.js +25 -23
- package/dist/components/Chips.js +22 -17
- package/dist/components/Choice.js +14 -14
- package/dist/components/Code.js +10 -20
- package/dist/components/CookiesWarning.js +16 -16
- package/dist/components/DadataHintField.js +5 -4
- package/dist/components/DatePicker.js +44 -20
- package/dist/components/Divider.js +7 -7
- package/dist/components/Dot.js +8 -8
- package/dist/components/Dropdown.js +10 -10
- package/dist/components/Flex.js +13 -12
- package/dist/components/Grid.js +13 -13
- package/dist/components/Group.js +7 -7
- package/dist/components/HTMLContent.js +8 -8
- package/dist/components/HeroTitle.js +9 -9
- package/dist/components/Icon.js +11 -11
- package/dist/components/Image.js +7 -7
- package/dist/components/Input.js +5 -4
- package/dist/components/InputMask.js +17 -16
- package/dist/components/InputPassword.js +13 -17
- package/dist/components/Label.js +10 -10
- package/dist/components/Link.js +7 -7
- package/dist/components/List.js +14 -13
- package/dist/components/Loader.js +8 -8
- package/dist/components/Logo.js +17 -15
- package/dist/components/Menu.js +12 -16
- package/dist/components/MenuItem.js +9 -9
- package/dist/components/Modal.js +12 -17
- package/dist/components/ModalSheetBottom.js +4 -4
- package/dist/components/Notification.js +9 -9
- package/dist/components/Overlay.js +7 -7
- package/dist/components/Pagination.js +15 -15
- package/dist/components/Panel.js +10 -10
- package/dist/components/Radio.js +17 -20
- package/dist/components/RangeSlider.js +8 -8
- package/dist/components/Response.js +16 -16
- package/dist/components/SVGContent.js +8 -8
- package/dist/components/ScrollOnDrag.js +9 -12
- package/dist/components/ScrollToView.js +10 -10
- package/dist/components/Search.js +17 -20
- package/dist/components/Segmented.js +9 -9
- package/dist/components/Select.js +35 -35
- package/dist/components/Swiper.js +12 -15
- package/dist/components/Switch.js +1 -1
- package/dist/components/Tab.js +18 -14
- package/dist/components/Text.js +7 -7
- package/dist/components/Textarea.js +9 -12
- package/dist/components/Tile.js +24 -20
- package/dist/components/Title.js +8 -8
- package/dist/components/Tooltip.js +9 -9
- package/dist/components/Video.js +4 -3
- package/dist/context/Notifications.js +1 -1
- package/dist/context/UIContext.js +50 -18
- package/dist/css/components/Avatar/Avatar.css +8 -8
- package/dist/css/components/Badge/Badge.css +48 -26
- package/dist/css/components/Badge/Badge.tokens.css +48 -18
- package/dist/css/components/Button/Button.css +67 -303
- package/dist/css/components/Button/Button.tokens.css +37 -115
- package/dist/css/components/Cell/Cell.css +2 -2
- package/dist/css/components/Checkbox/Checkbox.css +6 -4
- package/dist/css/components/Checkmark/Checkmark.css +11 -10
- package/dist/css/components/Checkmark/Checkmark.tokens.css +20 -14
- package/dist/css/components/Chips/Chips.css +0 -10
- package/dist/css/components/DadataHintField/DadataHintField.css +0 -8
- package/dist/css/components/DadataHintField/DadataHintField.tokens.css +7 -2
- package/dist/css/components/DatePicker/DatePicker.css +102 -69
- package/dist/css/components/DatePicker/DatePicker.tokens.css +7 -2
- package/dist/css/components/Divider/Divider.css +0 -12
- package/dist/css/components/Divider/Divider.tokens.css +12 -0
- package/dist/css/components/Flex/Flex.css +0 -1
- package/dist/css/components/Grid/Grid.css +1 -5
- package/dist/css/components/HeroTitle/HeroTitle.css +2 -2
- package/dist/css/components/Icon/Icon.css +13 -14
- package/dist/css/components/Icon/Icon.tokens.css +2 -1
- package/dist/css/components/Image/Image.css +3 -3
- package/dist/css/components/Label/Label.css +2 -2
- package/dist/css/components/Loader/Loader.css +12 -5
- package/dist/css/components/Logo/Logo.css +3 -19
- package/dist/css/components/Menu/Menu.css +9 -1
- package/dist/css/components/MenuItem/MenuItem.css +0 -10
- package/dist/css/components/MenuItem/MenuItem.tokens.css +9 -1
- package/dist/css/components/Radio/Radio.css +0 -3
- package/dist/css/components/Radio/Radio.tokens.css +2 -1
- package/dist/css/components/ScrollToView/ScrollToView.css +4 -4
- package/dist/css/components/Swiper/Swiper.css +2 -3
- package/dist/css/components/Switch/Switch.css +0 -7
- package/dist/css/components/Text/Text.css +2 -2
- package/dist/css/components/Title/Title.css +2 -2
- package/dist/css/components/Tooltip/Tooltip.css +15 -21
- package/dist/css/components/Tooltip/Tooltip.tokens.css +13 -0
- package/dist/css/styles/fill/fill.css +14 -9
- package/dist/css/styles/fill/fill_active.css +6 -3
- package/dist/css/styles/fill/fill_active_hover.css +8 -6
- package/dist/css/styles/fill/fill_disabled.css +6 -3
- package/dist/css/styles/fill/fill_hover.css +6 -3
- package/dist/css/styles/shape-strength/shape-strength.css +22 -0
- package/dist/css/styles/svg-color/svg_fill.css +27 -17
- package/dist/css/styles/svg-color/svg_fill_hover.css +12 -10
- package/dist/css/styles/svg-color/svg_path_fill.css +13 -9
- package/dist/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +118 -0
- package/dist/hooks/useDevicePropsGenerator.js +11 -0
- package/dist/hooks/useDeviceTargetClass.js +8 -3
- package/dist/hooks/useMediaQueries/useMediaQueries.js +127 -0
- package/dist/hooks/useMediaQueries.js +3 -125
- package/dist/hooks/{styleAttributes.js → useStyles/styleAttributes.js} +8 -1
- package/dist/hooks/useStyles/useStyles.js +188 -0
- package/dist/hooks/useStyles.js +9 -177
- package/dist/stories/AlignContent.mdx +1 -1
- package/dist/stories/AlignItems.mdx +1 -1
- package/dist/stories/AlignSelf.mdx +1 -1
- package/dist/stories/Appearance.mdx +1 -1
- package/dist/stories/Avatar.mdx +1 -1
- package/dist/stories/Checkbox.mdx +1 -1
- package/dist/stories/Checkmark.mdx +7 -3
- package/dist/stories/Chips.mdx +1 -1
- package/dist/stories/Choice.mdx +1 -1
- package/dist/stories/Code.mdx +1 -1
- package/dist/stories/Columns.mdx +1 -1
- package/dist/stories/Components.mdx +197 -0
- package/dist/stories/DatePicker.mdx +1 -1
- package/dist/stories/Dev.mdx +1 -1
- package/dist/stories/DevMode.mdx +1 -1
- package/dist/stories/Direction.mdx +1 -1
- package/dist/stories/Divider.mdx +1 -1
- package/dist/stories/Dot.mdx +1 -1
- package/dist/stories/Drawer.mdx +1 -1
- package/dist/stories/Dropdown.mdx +2 -2
- package/dist/stories/DropdownItem.mdx +1 -1
- package/dist/stories/Group.mdx +1 -1
- package/dist/stories/Grow.mdx +1 -1
- package/dist/stories/HeroTitle.mdx +1 -1
- package/dist/stories/Icon.mdx +1 -1
- package/dist/stories/Image.mdx +1 -1
- package/dist/stories/Input.mdx +1 -1
- package/dist/stories/InputPassword.mdx +1 -1
- package/dist/stories/JustifyContent.mdx +1 -1
- package/dist/stories/Label.mdx +1 -1
- package/dist/stories/Loader.mdx +1 -1
- package/dist/stories/Logo.mdx +1 -1
- package/dist/stories/MenuItem.mdx +1 -1
- package/dist/stories/Message.mdx +1 -1
- package/dist/stories/Notification.mdx +1 -1
- package/dist/stories/Order.mdx +1 -1
- package/dist/stories/Overview.mdx +1 -1
- package/dist/stories/Pagination.mdx +1 -1
- package/dist/stories/Playground.mdx +1 -1
- package/dist/stories/Radio.mdx +1 -1
- package/dist/stories/Response.mdx +1 -1
- package/dist/stories/SearchInput.mdx +1 -1
- package/dist/stories/Segmented.mdx +1 -1
- package/dist/stories/Size.mdx +1 -1
- package/dist/stories/Skeleton.mdx +1 -1
- package/dist/stories/State.mdx +1 -1
- package/dist/stories/Switch.mdx +1 -1
- package/dist/stories/Text.mdx +1 -1
- package/dist/stories/Textarea.mdx +1 -1
- package/dist/stories/Tile.mdx +1 -1
- package/dist/stories/Title.mdx +1 -1
- package/dist/stories/Tooltip.mdx +1 -1
- package/dist/stories/WithTooltip.mdx +1 -1
- package/dist/stories/Wrap.mdx +1 -1
- package/dist/{tslib.es6-Bwu1Cn-t.js → tslib.es6-5FtW-kfi.js} +1 -1
- package/dist/types/appearance/defaultAppearance.d.ts +33 -0
- package/dist/types/appearance/index.d.ts +3 -0
- package/dist/types/appearance/styleAppearance.d.ts +14 -0
- package/dist/types/components/Accordion/Accordion.interface.d.ts +1 -1
- package/dist/types/components/Avatar/Avatar.interface.d.ts +1 -1
- package/dist/types/components/Badge/Badge.d.ts +0 -6
- package/dist/types/components/Badge/Badge.interface.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeAccent.d.ts +39 -0
- package/dist/types/components/Badge/appearance/badgeDanger.d.ts +11 -0
- package/dist/types/components/Badge/appearance/badgeDisabled.d.ts +10 -0
- package/dist/types/components/Badge/appearance/badgeError.d.ts +12 -0
- package/dist/types/components/Badge/appearance/badgeInfo.d.ts +18 -0
- package/dist/types/components/Badge/appearance/badgePrimary.d.ts +11 -0
- package/dist/types/components/Badge/appearance/badgeSecondary.d.ts +11 -0
- package/dist/types/components/Badge/appearance/badgeSize.d.ts +32 -0
- package/dist/types/components/Badge/appearance/badgeStyle.d.ts +16 -0
- package/dist/types/components/Badge/appearance/badgeSuccess.d.ts +11 -0
- package/dist/types/components/Badge/appearance/badgeSurface.d.ts +29 -0
- package/dist/types/components/Badge/appearance/badgeWarning.d.ts +11 -0
- package/dist/types/components/Breadcrumbs/Breadcrumbs.d.ts +0 -5
- package/dist/types/components/Breadcrumbs/Breadcrumbs.interface.d.ts +1 -1
- package/dist/types/components/Button/Button.interface.d.ts +1 -1
- package/dist/types/components/Button/appearance/buttonAccent.d.ts +50 -0
- package/dist/types/components/Button/appearance/buttonDanger.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonError.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonInfo.d.ts +21 -0
- package/dist/types/components/Button/appearance/buttonPrimary.d.ts +8 -0
- package/dist/types/components/Button/appearance/buttonSecondary.d.ts +8 -0
- package/dist/types/components/Button/appearance/buttonSize.d.ts +59 -0
- package/dist/types/components/Button/appearance/buttonStyle.d.ts +16 -0
- package/dist/types/components/Button/appearance/buttonSuccess.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonSurface.d.ts +25 -0
- package/dist/types/components/Button/appearance/buttonWarning.d.ts +11 -0
- package/dist/types/components/Button/stories/args.d.ts +49 -49
- package/dist/types/components/Card/Card.interface.d.ts +1 -1
- package/dist/types/components/Cell/Cell.interface.d.ts +1 -1
- package/dist/types/components/Checkbox/Checkbox.interface.d.ts +1 -1
- package/dist/types/components/Checkmark/Checkmark.interface.d.ts +1 -1
- package/dist/types/components/Chips/Chips.interface.d.ts +1 -1
- package/dist/types/components/Chips/stories/args.d.ts +2 -2
- package/dist/types/components/Choice/Choice.interface.d.ts +1 -1
- package/dist/types/components/Code/Code.d.ts +0 -15
- package/dist/types/components/Code/Code.interface.d.ts +1 -1
- package/dist/types/components/DadataHintField/DadataHintField.interface.d.ts +1 -1
- package/dist/types/components/Divider/Divider.d.ts +0 -5
- package/dist/types/components/Divider/Divider.interface.d.ts +1 -1
- package/dist/types/components/Dot/Dot.interface.d.ts +1 -1
- package/dist/types/components/Drawer/Drawer.interface.d.ts +1 -1
- package/dist/types/components/Dropdown/Dropdown.interface.d.ts +1 -1
- package/dist/types/components/Dropdown/DropdownItem.d.ts +0 -7
- package/dist/types/components/Flex/Flex.interface.d.ts +1 -1
- package/dist/types/components/Flex/stories/args.d.ts +1 -1
- package/dist/types/components/Grid/Grid.interface.d.ts +1 -1
- package/dist/types/components/Grid/stories/args.d.ts +2 -2
- package/dist/types/components/Group/Group.interface.d.ts +1 -1
- package/dist/types/components/Group/stories/args.d.ts +2 -2
- package/dist/types/components/HTMLContent/HTMLContent.interface.d.ts +1 -1
- package/dist/types/components/HeroTitle/HeroTitle.interface.d.ts +1 -1
- package/dist/types/components/Icon/Icon.interface.d.ts +1 -1
- package/dist/types/components/Image/Image.interface.d.ts +1 -1
- package/dist/types/components/Input/Input.interface.d.ts +1 -1
- package/dist/types/components/InputMask/Input.interface.d.ts +1 -1
- package/dist/types/components/InputPassword/InputPassword.d.ts +0 -6
- package/dist/types/components/InputPassword/InputPassword.interface.d.ts +1 -1
- package/dist/types/components/Label/Label.interface.d.ts +1 -1
- package/dist/types/components/Label/appearance/labelAccent.d.ts +13 -0
- package/dist/types/components/Label/appearance/labelDanger.d.ts +11 -0
- package/dist/types/components/Label/appearance/labelError.d.ts +11 -0
- package/dist/types/components/Label/appearance/labelGradient.d.ts +11 -0
- package/dist/types/components/Label/appearance/labelInfo.d.ts +21 -0
- package/dist/types/components/Label/appearance/labelPrimary.d.ts +8 -0
- package/dist/types/components/Label/appearance/labelSecondary.d.ts +8 -0
- package/dist/types/components/Label/appearance/labelSize.d.ts +59 -0
- package/dist/types/components/Label/appearance/labelStyle.d.ts +16 -0
- package/dist/types/components/Label/appearance/labelSuccess.d.ts +11 -0
- package/dist/types/components/Label/appearance/labelSurface.d.ts +24 -0
- package/dist/types/components/Label/appearance/labelWarning.d.ts +11 -0
- package/dist/types/components/Link/Link.interface.d.ts +1 -1
- package/dist/types/components/List/List.interface.d.ts +1 -1
- package/dist/types/components/Loader/Loader.interface.d.ts +1 -1
- package/dist/types/components/Loader/appearance/loaderAccent.d.ts +7 -0
- package/dist/types/components/Loader/appearance/loaderPrimary.d.ts +7 -0
- package/dist/types/components/Loader/appearance/loaderSecondary.d.ts +7 -0
- package/dist/types/components/Loader/appearance/loaderSurface.d.ts +15 -0
- package/dist/types/components/Logo/Logo.interface.d.ts +1 -1
- package/dist/types/components/Menu/Menu.d.ts +0 -5
- package/dist/types/components/Menu/Menu.interface.d.ts +1 -1
- package/dist/types/components/MenuItem/MenuItem.interface.d.ts +1 -1
- package/dist/types/components/Modal/Modal.interface.d.ts +1 -1
- package/dist/types/components/Notification/Notification.interface.d.ts +1 -1
- package/dist/types/components/Overlay/Overlay.interface.d.ts +1 -1
- package/dist/types/components/Pagination/Pagination.interface.d.ts +1 -1
- package/dist/types/components/Panel/Panel.interface.d.ts +1 -1
- package/dist/types/components/Radio/Radio.d.ts +0 -5
- package/dist/types/components/Radio/Radio.interface.d.ts +1 -1
- package/dist/types/components/RangeSlider/RangeSlider.interface.d.ts +1 -1
- package/dist/types/components/Response/Response.interface.d.ts +1 -1
- package/dist/types/components/Response/stories/args.d.ts +4 -4
- package/dist/types/components/SVGContent/SVGContent.interface.d.ts +1 -1
- package/dist/types/components/ScrollOnDrag/ScrollOnDrag.d.ts +0 -5
- package/dist/types/components/ScrollOnDrag/ScrollOnDrag.interface.d.ts +1 -1
- package/dist/types/components/Scrollbar/Scrollbar.interface.d.ts +1 -1
- package/dist/types/components/Search/Search.interface.d.ts +1 -1
- package/dist/types/components/Segmented/Segmented.interface.d.ts +1 -1
- package/dist/types/components/Swiper/Swiper.d.ts +0 -5
- package/dist/types/components/Swiper/Swiper.interface.d.ts +1 -1
- package/dist/types/components/Switch/Switch.interface.d.ts +1 -1
- package/dist/types/components/Tab/Tab.interface.d.ts +1 -1
- package/dist/types/components/Tab/stories/args.d.ts +3 -3
- package/dist/types/components/Text/Text.interface.d.ts +1 -1
- package/dist/types/components/Textarea/Textarea.d.ts +0 -5
- package/dist/types/components/Textarea/Textarea.interface.d.ts +1 -1
- package/dist/types/components/Tile/Tile.d.ts +0 -5
- package/dist/types/components/Tile/Tile.interface.d.ts +1 -1
- package/dist/types/components/Title/Title.interface.d.ts +1 -1
- package/dist/types/components/Tooltip/Tooltip.interface.d.ts +1 -1
- package/dist/types/components/Video/Video.interface.d.ts +1 -1
- package/dist/types/context/UIContext.d.ts +8 -12
- package/dist/types/hooks/useDevicePropsGenerator/index.d.ts +1 -0
- package/dist/types/hooks/useDevicePropsGenerator/useDevicePropsGenerator.d.ts +3 -0
- package/dist/types/hooks/{useDeviceTargetClassGenerator.interface.d.ts → useDevicePropsGenerator/useDevicePropsGenerator.interface.d.ts} +2 -2
- package/dist/types/hooks/useMediaQueries/index.d.ts +1 -0
- package/dist/types/hooks/useStyles/index.d.ts +1 -0
- package/dist/types/hooks/useStyles/styleAttributes.d.ts +4 -0
- package/dist/types/types/componentProps/appearanceKeys.d.ts +1 -1
- package/dist/types/types/componentProps/borderColor.d.ts +1 -1
- package/dist/types/types/componentProps/fill.d.ts +1 -1
- package/package.json +15 -12
- package/dist/Badge-5gtVywXB.js +0 -111
- package/dist/Badge-DhOJoJgc.js +0 -115
- package/dist/Button-BSnodY9v.js +0 -103
- package/dist/Button-Kcw2DdY0.js +0 -99
- package/dist/Divider-DBvDCUqP.js +0 -30
- package/dist/Divider-Goh6mpPK.js +0 -34
- package/dist/Label-CBwPiUuf.js +0 -97
- package/dist/Label-DgyUhGTQ.js +0 -93
- package/dist/Loader-Dn036JwE.js +0 -56
- package/dist/Loader-K_DJmah6.js +0 -52
- package/dist/cjs/hooks/useDeviceTargetClassGenerator.interface.js +0 -3
- package/dist/cjs/hooks/useDeviceTargetClassGenerator.js +0 -98
- package/dist/css/styles/gap/gap.css +0 -7
- package/dist/hooks/useDeviceTargetClassGenerator.interface.js +0 -1
- package/dist/hooks/useDeviceTargetClassGenerator.js +0 -96
- package/dist/stories/Badge.mdx +0 -20
- package/dist/stories/Button.mdx +0 -47
- package/dist/types/components/Badge/stories/args.d.ts +0 -69
- package/dist/types/hooks/styleAttributes.d.ts +0 -2
- package/dist/types/hooks/useDeviceTargetClassGenerator.d.ts +0 -3
- /package/dist/cjs/{hooks.js → hooks/useDevicePropsGenerator/useDevicePropsGenerator.interface.js} +0 -0
- /package/dist/cjs/hooks/{styleAttributes.interface.js → useStyles/styleAttributes.interface.js} +0 -0
- /package/dist/{hooks.js → hooks/useDevicePropsGenerator/useDevicePropsGenerator.interface.js} +0 -0
- /package/dist/hooks/{styleAttributes.interface.js → useStyles/styleAttributes.interface.js} +0 -0
- /package/dist/types/hooks/{useMediaQueries.d.ts → useMediaQueries/useMediaQueries.d.ts} +0 -0
- /package/dist/types/hooks/{styleAttributes.interface.d.ts → useStyles/styleAttributes.interface.d.ts} +0 -0
- /package/dist/types/hooks/{useStyles.d.ts → useStyles/useStyles.d.ts} +0 -0
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
export { B as Button, a as buttonAppearance, b as buttonConfig } from '../Button-
|
|
1
|
+
export { B as Button, a as buttonAppearance, b as buttonConfig } from '../Button-DZ3z7f-A.js';
|
|
2
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
2
3
|
import 'react/jsx-runtime';
|
|
3
4
|
import 'react';
|
|
4
5
|
import 'clsx';
|
|
5
|
-
import '../hooks/
|
|
6
|
-
import '../tslib.es6-Bwu1Cn-t.js';
|
|
6
|
+
import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
7
|
import 'lodash/camelCase';
|
|
8
8
|
import 'lodash/castArray';
|
|
9
|
+
import 'lodash/upperFirst';
|
|
9
10
|
import '../context/UIContext.js';
|
|
10
|
-
import '../hooks/useMediaQueries.js';
|
|
11
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
11
12
|
import 'react-responsive';
|
|
12
13
|
import '../utils/setViewportProperty.js';
|
|
13
|
-
import '../hooks/useStyles.js';
|
|
14
|
+
import '../hooks/useStyles/useStyles.js';
|
|
14
15
|
import 'lodash/maxBy';
|
|
15
|
-
import '
|
|
16
|
-
import '../
|
|
17
|
-
import '../Icon-BdHr6E6M.js';
|
|
16
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
17
|
+
import '../Icon-htF_V35Y.js';
|
|
18
18
|
import 'react-inlinesvg';
|
|
19
|
-
import '../Link-
|
|
20
|
-
import '../Tooltip-
|
|
21
|
-
import '../Text-
|
|
22
|
-
import '../Title-
|
|
23
|
-
import '../Loader-
|
|
19
|
+
import '../Link-BhJ5BdyS.js';
|
|
20
|
+
import '../Tooltip-BYgzNVYI.js';
|
|
21
|
+
import '../Text-C6NSmetx.js';
|
|
22
|
+
import '../Title-Dck3eHNM.js';
|
|
23
|
+
import '../Loader-CsPvc-9g.js';
|
package/dist/components/Card.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import clsx from 'clsx';
|
|
3
|
-
import {
|
|
4
|
-
import { I as Image } from '../Image-
|
|
5
|
-
import { T as Text } from '../Text-
|
|
6
|
-
import '../tslib.es6-
|
|
3
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
4
|
+
import { I as Image } from '../Image-DWfyapuD.js';
|
|
5
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
6
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
7
7
|
import 'react';
|
|
8
8
|
import 'lodash/camelCase';
|
|
9
9
|
import 'lodash/castArray';
|
|
10
|
+
import 'lodash/upperFirst';
|
|
10
11
|
import '../context/UIContext.js';
|
|
11
|
-
import '../hooks/useMediaQueries.js';
|
|
12
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
12
13
|
import 'react-responsive';
|
|
13
14
|
import '../utils/setViewportProperty.js';
|
|
14
|
-
import '../hooks/useStyles.js';
|
|
15
|
+
import '../hooks/useStyles/useStyles.js';
|
|
15
16
|
import 'lodash/maxBy';
|
|
16
|
-
import '
|
|
17
|
-
import '../hooks/styleAttributes.js';
|
|
17
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
18
18
|
|
|
19
19
|
function Card(props) {
|
|
20
20
|
var children = props.children, className = props.className, image = props.image, _a = props.imageShape, imageShape = _a === void 0 ? 'rounded' : _a, size = props.size, src = props.src, text = props.text, _b = props.textColor, textColor = _b === void 0 ? 'surfaceTextPrimary' : _b, _c = props.textSize, textSize = _c === void 0 ? 'p' : _c, textTag = props.textTag, title = props.title, _d = props.titleColor, titleColor = _d === void 0 ? 'surfaceTextPrimary' : _d, _e = props.titleSize, titleSize = _e === void 0 ? 'h5' : _e, _f = props.titleTag, titleTag = _f === void 0 ? 'span' : _f, type = props.type, onClick = props.onClick;
|
|
21
|
-
var
|
|
22
|
-
var shapeClass =
|
|
21
|
+
var propsGenerator = useDevicePropsGenerator(props);
|
|
22
|
+
var shapeClass = propsGenerator.shapeClass, widthClass = propsGenerator.widthClass;
|
|
23
23
|
return (jsx("div", { className: clsx(className, 'card', shapeClass && "card_shape_".concat(shapeClass), size && "card_size_".concat(size), type && "card_type_".concat(type), widthClass && "resize-horizontal_".concat(widthClass)), onClick: onClick, children: jsxs("div", { className: "card__wrapper", children: [image, src && jsx(Image, { className: "card__image", shape: imageShape, src: src }), jsxs("div", { className: "card__data", children: [title && (jsx(Text, { className: "card__data-title", size: titleSize, tag: titleTag, textColor: titleColor, children: title })), text && (jsx(Text, { className: "card__data-desc", size: textSize, tag: textTag, textColor: textColor, children: text }))] }), children] }) }));
|
|
24
24
|
}
|
|
25
25
|
|
package/dist/components/Cell.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import clsx from 'clsx';
|
|
3
|
-
import {
|
|
4
|
-
import { useStyles } from '../hooks/useStyles.js';
|
|
5
|
-
import { I as Icon } from '../Icon-
|
|
6
|
-
import { L as Label } from '../Label-
|
|
7
|
-
import { T as Text } from '../Text-
|
|
8
|
-
import '../tslib.es6-
|
|
3
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
4
|
+
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
5
|
+
import { I as Icon } from '../Icon-htF_V35Y.js';
|
|
6
|
+
import { L as Label } from '../Label-Dpeq55TV.js';
|
|
7
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
8
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
9
9
|
import 'react';
|
|
10
10
|
import 'lodash/camelCase';
|
|
11
11
|
import 'lodash/castArray';
|
|
12
|
+
import 'lodash/upperFirst';
|
|
12
13
|
import '../context/UIContext.js';
|
|
13
|
-
import '../hooks/useMediaQueries.js';
|
|
14
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
14
15
|
import 'react-responsive';
|
|
15
16
|
import '../utils/setViewportProperty.js';
|
|
16
17
|
import 'lodash/maxBy';
|
|
17
|
-
import '
|
|
18
|
-
import '../hooks/styleAttributes.js';
|
|
18
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
19
19
|
import 'react-inlinesvg';
|
|
20
|
-
import '../Link-
|
|
21
|
-
import '../Tooltip-
|
|
22
|
-
import '../Title-
|
|
20
|
+
import '../Link-BhJ5BdyS.js';
|
|
21
|
+
import '../Tooltip-BYgzNVYI.js';
|
|
22
|
+
import '../Title-Dck3eHNM.js';
|
|
23
23
|
|
|
24
24
|
var cellAppearance = {
|
|
25
25
|
dev: {},
|
|
@@ -27,19 +27,34 @@ var cellAppearance = {
|
|
|
27
27
|
|
|
28
28
|
var cellConfig = {
|
|
29
29
|
appearance: cellAppearance,
|
|
30
|
-
setAppearance: function (
|
|
31
|
-
cellConfig.appearance =
|
|
30
|
+
setAppearance: function (appearanceConfig) {
|
|
31
|
+
cellConfig.appearance = appearanceConfig;
|
|
32
32
|
},
|
|
33
33
|
};
|
|
34
34
|
function Cell(props) {
|
|
35
|
-
var isActive = props.isActive, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a, isEqual = props.isEqual, after = props.after, appearance = props.appearance, before = props.before, className = props.className, mode = props.mode, reverse = props.reverse, set = props.set, showTitleLabel = props.showTitleLabel, showValueLabel = props.showValueLabel, size = props.size, title = props.title, titleIcon = props.titleIcon, titleIconFill = props.titleIconFill, titleIconFillHover = props.titleIconFillHover, titleIconFillSize = props.titleIconFillSize, titleIconItemFill = props.titleIconItemFill, titleIconShape = props.titleIconShape, titleIconSrc = props.titleIconSrc, titleLabel = props.titleLabel, titleLabelAppearance = props.titleLabelAppearance, titleLabelShape = props.titleLabelShape, titleLabelSize = props.titleLabelSize,
|
|
35
|
+
var isActive = props.isActive, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a, isEqual = props.isEqual, after = props.after, appearance = props.appearance, before = props.before, className = props.className, mode = props.mode, reverse = props.reverse, set = props.set, showTitleLabel = props.showTitleLabel, showValueLabel = props.showValueLabel, size = props.size, title = props.title, titleIcon = props.titleIcon, titleIconFill = props.titleIconFill, titleIconFillHover = props.titleIconFillHover, titleIconFillSize = props.titleIconFillSize, titleIconItemFill = props.titleIconItemFill, titleIconShape = props.titleIconShape, titleIconSrc = props.titleIconSrc, titleLabel = props.titleLabel, titleLabelAppearance = props.titleLabelAppearance, titleLabelShape = props.titleLabelShape, titleLabelSize = props.titleLabelSize,
|
|
36
|
+
// titleLabelTextSize,
|
|
37
|
+
titleTag = props.titleTag, titleTextColor = props.titleTextColor,
|
|
38
|
+
// titleTextSize,
|
|
39
|
+
titleTextTruncate = props.titleTextTruncate, titleTextWeight = props.titleTextWeight, titleTextWrap = props.titleTextWrap, value = props.value, valueIcon = props.valueIcon, valueIconFill = props.valueIconFill, valueIconFillHover = props.valueIconFillHover, valueIconFillSize = props.valueIconFillSize, valueIconItemFill = props.valueIconItemFill, valueIconShape = props.valueIconShape, valueIconSrc = props.valueIconSrc, valueLabel = props.valueLabel, valueLabelAppearance = props.valueLabelAppearance, valueLabelShape = props.valueLabelShape, valueLabelSize = props.valueLabelSize,
|
|
40
|
+
// valueLabelTextSize,
|
|
41
|
+
valueTag = props.valueTag, valueTextAlign = props.valueTextAlign, valueTextColor = props.valueTextColor,
|
|
42
|
+
// valueTextSize,
|
|
43
|
+
valueTextTruncate = props.valueTextTruncate, valueTextWeight = props.valueTextWeight, valueTextWrap = props.valueTextWrap, zeroGap = props.zeroGap, zeroPadding = props.zeroPadding, onClick = props.onClick, onMouseEnter = props.onMouseEnter;
|
|
36
44
|
// @ts-expect-error
|
|
37
45
|
var appearanceConfig = cellConfig.appearance && cellConfig.appearance[appearance];
|
|
38
|
-
var
|
|
39
|
-
|
|
46
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
47
|
+
/* eslint-disable perfectionist/sort-objects */
|
|
48
|
+
// Values for "Desktop*" or "Tablet*" or "Mobile*" device type
|
|
49
|
+
var
|
|
50
|
+
// Properties for current device media queries
|
|
51
|
+
titleLabelTextSize = propsGenerator.titleLabelTextSize, titleTextSize = propsGenerator.titleTextSize, valueLabelTextSize = propsGenerator.valueLabelTextSize, valueTextSize = propsGenerator.valueTextSize,
|
|
52
|
+
// Classes for current device media queries
|
|
53
|
+
bgFillActiveClass = propsGenerator.bgFillActiveClass, bgFillClass = propsGenerator.bgFillClass, bgFillDisabledClass = propsGenerator.bgFillDisabledClass, bgFillHoverClass = propsGenerator.bgFillHoverClass, bgShapeClass = propsGenerator.bgShapeClass, directionClass = propsGenerator.directionClass, fillActiveClass = propsGenerator.fillActiveClass, fillClass = propsGenerator.fillClass, fillDisabledClass = propsGenerator.fillDisabledClass, fillHoverClass = propsGenerator.fillHoverClass, shapeClass = propsGenerator.shapeClass, widthClass = propsGenerator.widthClass;
|
|
54
|
+
/* eslint-enable perfectionist/sort-objects */
|
|
40
55
|
// @ts-expect-error
|
|
41
56
|
var _b = useStyles(props), dataStyles = _b.data, cellStyles = _b.styles;
|
|
42
|
-
return (jsxs("div", { className: clsx(className, 'cell', mode && "cell_mode_".concat(mode), size && "cell_size_".concat(size), set && "cell_set_".concat(set), bgFillClass && "fill_".concat(bgFillClass), bgFillHoverClass && "fill_hover_".concat(bgFillHoverClass), isActive && bgFillActiveClass && "fill_active_".concat(bgFillActiveClass), isDisabled && bgFillDisabledClass && "fill_disabled_".concat(bgFillDisabledClass), bgShapeClass && "cell_shape_".concat(bgShapeClass), widthClass &&
|
|
57
|
+
return (jsxs("div", { className: clsx(className, 'cell', mode && "cell_mode_".concat(mode), size && "cell_size_".concat(size), set && "cell_set_".concat(set), bgFillClass && "fill_".concat(bgFillClass), bgFillHoverClass && "fill_hover_".concat(bgFillHoverClass), isActive && bgFillActiveClass && "fill_active_".concat(bgFillActiveClass), isDisabled && bgFillDisabledClass && "fill_disabled_".concat(bgFillDisabledClass), bgShapeClass && "cell_shape_".concat(bgShapeClass), widthClass && !cellStyles.width && "width_".concat(widthClass), zeroPadding && 'cell_reset-padding', zeroGap && 'cell_reset-gap', reverse && 'cell_reverse'), style: cellStyles, onClick: onClick, onMouseEnter: onMouseEnter, children: [before && jsx("div", { className: "cell__before", children: before }), jsxs("div", { className: clsx('cell__wrapper', directionClass && "cell__wrapper_direction_".concat(directionClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), isActive && fillActiveClass && "fill_active_".concat(fillActiveClass), isDisabled && fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), shapeClass && "cell__wrapper_shape_".concat(shapeClass), isEqual && 'cell__wrapper-equal'), children: [title && (jsxs("div", { className: "cell__data", style: dataStyles, children: [jsx(Text, { className: "cell__title", size: titleTextSize, tag: titleTag, textColor: titleTextColor, textTruncate: titleTextTruncate, textWeight: titleTextWeight, textWrap: titleTextWrap, children: title }), (titleIcon || titleIconSrc) && (jsx(Icon, { className: "cell__icon", fill: titleIconFill, fillSize: titleIconFillSize, iconFill: titleIconItemFill, iconFillHover: titleIconFillHover, imageSrc: titleIconSrc, shape: titleIconShape, SvgImage: titleIcon })), showTitleLabel && (jsx(Label, { labelTextSize: titleLabelTextSize, appearance: titleLabelAppearance, label: titleLabel, shape: titleLabelShape, size: titleLabelSize }))] })), value && (jsxs("div", { className: "cell__data", style: dataStyles, children: [jsx(Text, { className: "cell__value", size: valueTextSize, tag: valueTag, textAlign: valueTextAlign, textColor: valueTextColor, textTruncate: valueTextTruncate, textWeight: valueTextWeight, textWrap: valueTextWrap, children: value }), (valueIcon || valueIconSrc) && (jsx(Icon, { className: "cell__icon", fill: valueIconFill, fillSize: valueIconFillSize, iconFill: valueIconItemFill, iconFillHover: valueIconFillHover, imageSrc: valueIconSrc, shape: valueIconShape, SvgImage: valueIcon })), showValueLabel && (jsx(Label, { labelTextSize: valueLabelTextSize, appearance: valueLabelAppearance, label: valueLabel, shape: valueLabelShape, size: valueLabelSize }))] }))] }), after && jsx("div", { className: "cell__after", children: after })] }));
|
|
43
58
|
}
|
|
44
59
|
|
|
45
60
|
export { Cell, cellAppearance, cellConfig };
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import clsx from 'clsx';
|
|
3
|
-
import {
|
|
4
|
-
import { T as Text } from '../Text-
|
|
5
|
-
import '../tslib.es6-
|
|
3
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
4
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
5
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
6
6
|
import 'react';
|
|
7
7
|
import 'lodash/camelCase';
|
|
8
8
|
import 'lodash/castArray';
|
|
9
|
+
import 'lodash/upperFirst';
|
|
9
10
|
import '../context/UIContext.js';
|
|
10
|
-
import '../hooks/useMediaQueries.js';
|
|
11
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
11
12
|
import 'react-responsive';
|
|
12
13
|
import '../utils/setViewportProperty.js';
|
|
13
|
-
import '../hooks/useStyles.js';
|
|
14
|
+
import '../hooks/useStyles/useStyles.js';
|
|
14
15
|
import 'lodash/maxBy';
|
|
15
|
-
import '
|
|
16
|
-
import '../hooks/styleAttributes.js';
|
|
16
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
17
17
|
|
|
18
18
|
var checkboxAppearance = {
|
|
19
19
|
dev: {
|
|
@@ -49,15 +49,15 @@ var checkboxConfig = {
|
|
|
49
49
|
function Checkbox(props) {
|
|
50
50
|
var id = props.id, after = props.after, appearance = props.appearance, before = props.before, checked = props.checked, className = props.className, desc = props.desc, descTextColor = props.descTextColor, descTextSize = props.descTextSize, descTextWeight = props.descTextWeight, disabled = props.disabled, label = props.label, labelTextColor = props.labelTextColor, labelTextSize = props.labelTextSize, labelTextWeight = props.labelTextWeight, _a = props.Tag, Tag = _a === void 0 ? 'label' : _a, value = props.value, onBlur = props.onBlur, onChange = props.onChange, onFocus = props.onFocus;
|
|
51
51
|
var appearanceConfig = checkboxConfig.appearance && checkboxConfig.appearance[appearance];
|
|
52
|
-
var
|
|
53
|
-
var fillClass =
|
|
54
|
-
var stateFillClass =
|
|
52
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
53
|
+
var fillClass = propsGenerator.fillClass, shapeClass = propsGenerator.shapeClass, stateBorderWidthClass = propsGenerator.stateBorderWidthClass, stateShapeClass = propsGenerator.stateShapeClass, widthClass = propsGenerator.widthClass;
|
|
54
|
+
var stateFillClass = propsGenerator.getClassName(checked ? 'stateFillChecked' : 'stateFill', {
|
|
55
55
|
prefix: 'fill_',
|
|
56
56
|
});
|
|
57
|
-
var stateFillDisabledClass =
|
|
58
|
-
var stateCheckmarkFillClass =
|
|
59
|
-
var stateBorderColorClass =
|
|
60
|
-
var stateBorderColorDisabledClass =
|
|
57
|
+
var stateFillDisabledClass = propsGenerator.getClassName(checked ? 'stateFillDisabledChecked' : 'stateFillDisabled', { prefix: 'fill_' });
|
|
58
|
+
var stateCheckmarkFillClass = propsGenerator.getClassName(disabled ? 'stateCheckmarkFillDisabled' : 'stateCheckmarkFill', { prefix: 'checkbox_checkmark_fill_' });
|
|
59
|
+
var stateBorderColorClass = propsGenerator.getClassName(checked ? 'stateBorderColorChecked' : 'stateBorderColor', { prefix: 'border-color_' });
|
|
60
|
+
var stateBorderColorDisabledClass = propsGenerator.getClassName(checked ? 'stateBorderColorDisabledChecked' : 'stateBorderColorDisabled', { prefix: 'border-color_' });
|
|
61
61
|
return (jsxs(Tag, { className: clsx(className, 'checkbox', fillClass && "fill_".concat(fillClass), shapeClass && "checkbox_shape_".concat(shapeClass), widthClass && "width_".concat(widthClass)), htmlFor: Tag === 'label' && id, children: [before, jsxs("div", { className: clsx('checkbox__item', stateCheckmarkFillClass), children: [jsx("input", { className: "checkbox__input", checked: checked, disabled: disabled,
|
|
62
62
|
// @ts-expect-error
|
|
63
63
|
id: id, type: "checkbox", value: value, onBlur: onBlur, onChange: onChange, onFocus: onFocus }), jsx("div", { className: clsx('checkbox__state', disabled ? stateFillDisabledClass : stateFillClass, disabled ? stateBorderColorDisabledClass : stateBorderColorClass, stateShapeClass && "checkbox__state_shape_".concat(stateShapeClass), stateBorderWidthClass && "border-width_".concat(stateBorderWidthClass)), children: "\u00A0" }), jsx("div", { className: "checkbox__state-checkmark", children: "\u00A0" })] }), label && (jsx(Text, { className: "checkbox__label", size: labelTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextSize), textColor: labelTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextColor), textWeight: labelTextWeight, children: label })), desc && (jsx(Text, { className: "checkbox__desc", size: descTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextSize), textColor: descTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextColor), textWeight: descTextWeight, children: desc })), after && jsx("div", { className: "checkbox__after", children: after })] }));
|
|
@@ -1,55 +1,57 @@
|
|
|
1
|
+
import { _ as __assign } from '../tslib.es6-5FtW-kfi.js';
|
|
1
2
|
import { jsx } from 'react/jsx-runtime';
|
|
2
3
|
import clsx from 'clsx';
|
|
3
|
-
import {
|
|
4
|
-
import { useStyles } from '../hooks/useStyles.js';
|
|
5
|
-
import '../tslib.es6-Bwu1Cn-t.js';
|
|
4
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
|
+
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
6
|
import 'react';
|
|
7
7
|
import 'lodash/camelCase';
|
|
8
8
|
import 'lodash/castArray';
|
|
9
|
+
import 'lodash/upperFirst';
|
|
9
10
|
import '../context/UIContext.js';
|
|
10
|
-
import '../hooks/useMediaQueries.js';
|
|
11
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
11
12
|
import 'react-responsive';
|
|
12
13
|
import '../utils/setViewportProperty.js';
|
|
13
14
|
import 'lodash/maxBy';
|
|
14
|
-
import '
|
|
15
|
-
import '../hooks/styleAttributes.js';
|
|
15
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
16
16
|
|
|
17
17
|
var checkmarkAppearance = {
|
|
18
18
|
accent: {
|
|
19
|
-
borderWidth: '4',
|
|
20
|
-
borderColor: 'accentBorderPrimary',
|
|
21
19
|
fill: 'accentPrimary',
|
|
22
|
-
|
|
20
|
+
borderColor: 'accentBorderPrimary',
|
|
21
|
+
borderWidth: '4',
|
|
22
|
+
checkmarkFill: 'accentItemPrimary',
|
|
23
23
|
},
|
|
24
24
|
disabled: {
|
|
25
|
-
borderWidth: '4',
|
|
26
|
-
borderColor: 'surfaceBorderTertiary',
|
|
27
25
|
fill: 'surfaceItemSecondary',
|
|
28
|
-
|
|
26
|
+
borderColor: 'surfaceBorderTertiary',
|
|
27
|
+
borderWidth: '4',
|
|
28
|
+
checkmarkFill: '#surfaceItemSecondary',
|
|
29
29
|
},
|
|
30
30
|
surface: {
|
|
31
|
-
borderWidth: '4',
|
|
32
|
-
borderColor: 'surfaceBorderTertiary',
|
|
33
31
|
fill: 'surfacePrimary',
|
|
34
|
-
|
|
32
|
+
borderColor: 'surfaceBorderTertiary',
|
|
33
|
+
borderWidth: '4',
|
|
34
|
+
checkmarkFill: 'surfaceItemPrimary',
|
|
35
35
|
},
|
|
36
36
|
};
|
|
37
37
|
|
|
38
38
|
var checkmarkConfig = {
|
|
39
39
|
appearance: checkmarkAppearance,
|
|
40
|
-
setAppearance: function (
|
|
41
|
-
checkmarkConfig.appearance =
|
|
40
|
+
setAppearance: function (appearanceConfig) {
|
|
41
|
+
checkmarkConfig.appearance = appearanceConfig;
|
|
42
42
|
},
|
|
43
43
|
};
|
|
44
44
|
function Checkmark(props) {
|
|
45
|
-
var isChecked = props.isChecked, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a,
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
45
|
+
var className = props.className, appearance = props.appearance, isChecked = props.isChecked, _a = props.isDisabled, isDisabled = _a === void 0 ? false : _a, onClick = props.onClick;
|
|
46
|
+
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultApperance, appearance) {
|
|
47
|
+
var _a;
|
|
48
|
+
return (__assign(__assign({}, resultApperance), (_a = checkmarkConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearance]));
|
|
49
|
+
}, {});
|
|
50
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
51
|
+
var fillClass = propsGenerator.fillClass, borderColorClass = propsGenerator.borderColorClass, borderWidthClass = propsGenerator.borderWidthClass, checkmarkFillClass = propsGenerator.checkmarkFillClass, sizeClass = propsGenerator.sizeClass;
|
|
50
52
|
// @ts-expect-error
|
|
51
53
|
var checkmarkStyles = useStyles(props).styles;
|
|
52
|
-
return (jsx("div", { className: clsx(className, 'checkmark', sizeClass && "checkmark_size_".concat(sizeClass), fillClass && "fill_".concat(fillClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderColorClass && "border-color_".concat(borderColorClass), isDisabled), style: checkmarkStyles, onClick: onClick, children: isChecked && (jsx("
|
|
54
|
+
return (jsx("div", { className: clsx(className, 'checkmark', sizeClass && "checkmark_size_".concat(sizeClass), fillClass && "fill_".concat(fillClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderColorClass && "border-color_".concat(borderColorClass), isDisabled), style: checkmarkStyles, onClick: onClick, children: isChecked && (jsx("div", { className: clsx('checkmark__icon', "svg_fill_".concat(checkmarkFillClass)), children: jsx("svg", { width: "32", height: "24", fill: "none", viewBox: "0 0 32 24", xmlns: "http://www.w3.org/2000/svg", children: jsx("path", { fill: "none", d: "M28.0896 0.706312L11.4967 18.1772L3.9104 10.1895C3.01576 9.24775 1.56549 9.24775 0.670845 10.1895C-0.223615 11.1315 -0.223615 12.6585 0.670845 13.6005L9.87695 23.2936C10.3243 23.7644 10.9105 24 11.4967 24C12.083 24 12.6692 23.7644 13.1165 23.2936L31.3292 4.11744C32.2236 3.17547 32.2236 1.64848 31.3292 0.706504C30.4345 -0.235469 28.9841 -0.235469 28.0896 0.706312Z" }) }) })) }));
|
|
53
55
|
}
|
|
54
56
|
|
|
55
57
|
export { Checkmark, checkmarkAppearance, checkmarkConfig };
|
package/dist/components/Chips.js
CHANGED
|
@@ -1,19 +1,24 @@
|
|
|
1
|
+
import { _ as __assign } from '../tslib.es6-5FtW-kfi.js';
|
|
1
2
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
3
|
import clsx from 'clsx';
|
|
3
|
-
import {
|
|
4
|
-
import { useStyles } from '../hooks/useStyles.js';
|
|
5
|
-
import {
|
|
6
|
-
import '../
|
|
4
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
|
+
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
|
+
import { I as Icon } from '../Icon-htF_V35Y.js';
|
|
7
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
7
8
|
import 'react';
|
|
8
9
|
import 'lodash/camelCase';
|
|
9
10
|
import 'lodash/castArray';
|
|
11
|
+
import 'lodash/upperFirst';
|
|
10
12
|
import '../context/UIContext.js';
|
|
11
|
-
import '../hooks/useMediaQueries.js';
|
|
13
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
12
14
|
import 'react-responsive';
|
|
13
15
|
import '../utils/setViewportProperty.js';
|
|
14
16
|
import 'lodash/maxBy';
|
|
15
|
-
import '
|
|
16
|
-
import '
|
|
17
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
18
|
+
import 'react-inlinesvg';
|
|
19
|
+
import '../Link-BhJ5BdyS.js';
|
|
20
|
+
import '../Tooltip-BYgzNVYI.js';
|
|
21
|
+
import '../Title-Dck3eHNM.js';
|
|
17
22
|
|
|
18
23
|
var chipsAppearance = {
|
|
19
24
|
accent: {
|
|
@@ -56,23 +61,23 @@ var chipsAppearance = {
|
|
|
56
61
|
|
|
57
62
|
var chipsConfig = {
|
|
58
63
|
appearance: chipsAppearance,
|
|
59
|
-
setAppearance: function (
|
|
60
|
-
chipsConfig.appearance =
|
|
64
|
+
setAppearance: function (appearanceConfig) {
|
|
65
|
+
chipsConfig.appearance = appearanceConfig;
|
|
61
66
|
},
|
|
62
67
|
};
|
|
63
68
|
function Chips(props) {
|
|
64
|
-
var
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
+
var className = props.className, appearance = props.appearance, children = props.children, _a = props.label, label = _a === void 0 ? '' : _a, dataTestId = props.dataTestId, dataTour = props.dataTour, iconAfter = props.iconAfter, iconAfterSrc = props.iconAfterSrc, iconBefore = props.iconBefore, iconBeforeSrc = props.iconBeforeSrc, isActive = props.isActive, onClick = props.onClick;
|
|
70
|
+
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultApperance, appearance) {
|
|
71
|
+
var _a;
|
|
72
|
+
return (__assign(__assign({}, resultApperance), (_a = chipsConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearance]));
|
|
73
|
+
}, {});
|
|
74
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
75
|
+
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillActiveClass = propsGenerator.fillActiveClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, labelTextActiveColor = propsGenerator.labelTextActiveColor, labelTextColor = propsGenerator.labelTextColor, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, cursorClass = propsGenerator.cursorClass, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterFillSize = propsGenerator.iconAfterFillSize, iconAfterShape = propsGenerator.iconAfterShape, iconAfterSize = propsGenerator.iconAfterSize, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeFillSize = propsGenerator.iconBeforeFillSize, iconBeforeShape = propsGenerator.iconBeforeShape, iconBeforeSize = propsGenerator.iconBeforeSize, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, isDisabled = propsGenerator.isDisabled;
|
|
69
76
|
// @ts-expect-error
|
|
70
77
|
var chipsStyles = useStyles(props).styles;
|
|
71
78
|
return (jsx("div", { className: clsx(className, 'chips', isActive && 'chips_state_active', isActive
|
|
72
79
|
? fillActiveClass && "fill_active_".concat(fillActiveClass)
|
|
73
|
-
: fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "chips_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "chips_size_".concat(sizeClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass),
|
|
74
|
-
? labelTextActiveColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextActiveColor)
|
|
75
|
-
: labelTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextColor), children: label })) : (jsx("div", { className: "chips__label", children: label })), children] }) }));
|
|
80
|
+
: fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "chips_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "chips_size_".concat(sizeClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), isDisabled && "chips_state_disabled", cursorClass && "cursor_".concat(cursorClass), onClick && 'cursor_type_pointer'), "data-testid": dataTestId && "".concat(dataTestId, "Button"), "data-tour": dataTour, style: chipsStyles, onClick: onClick, children: jsxs("div", { className: "chips__inner", children: [(iconBefore || iconBeforeSrc) && (jsx(Icon, { className: "chips__icon_before", fill: iconBeforeFill, fillSize: iconBeforeFillSize, iconFill: iconBeforeFillIcon, imageSrc: iconBeforeSrc, shape: iconBeforeShape, size: iconBeforeSize, SvgImage: iconBefore })), typeof label === 'string' ? (jsx(Text, { className: "chips__label", textColor: isActive ? labelTextActiveColor : labelTextColor, textWeight: labelTextWeight, textWrap: labelTextWrap, size: labelTextSize, children: label })) : (jsx("div", { className: "chips__label", children: label })), children, (iconAfter || iconAfterSrc) && (jsx(Icon, { className: "chips__icon_after", fill: iconAfterFill, fillSize: iconAfterFillSize, iconFill: iconAfterFillIcon, imageSrc: iconAfterSrc, shape: iconAfterShape, size: iconAfterSize, SvgImage: iconAfter }))] }) }));
|
|
76
81
|
}
|
|
77
82
|
|
|
78
83
|
export { Chips, chipsAppearance, chipsConfig };
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
2
|
import { useRef, useMemo, createRef, useCallback } from 'react';
|
|
3
3
|
import clsx from 'clsx';
|
|
4
|
-
import {
|
|
5
|
-
import { I as Icon } from '../Icon-
|
|
6
|
-
import { L as Loader } from '../Loader-
|
|
7
|
-
import { T as Text } from '../Text-
|
|
8
|
-
import '../tslib.es6-
|
|
4
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
|
+
import { I as Icon } from '../Icon-htF_V35Y.js';
|
|
6
|
+
import { L as Loader } from '../Loader-CsPvc-9g.js';
|
|
7
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
8
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
9
9
|
import 'lodash/camelCase';
|
|
10
10
|
import 'lodash/castArray';
|
|
11
|
+
import 'lodash/upperFirst';
|
|
11
12
|
import '../context/UIContext.js';
|
|
12
|
-
import '../hooks/useMediaQueries.js';
|
|
13
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
13
14
|
import 'react-responsive';
|
|
14
15
|
import '../utils/setViewportProperty.js';
|
|
15
16
|
import 'react-inlinesvg';
|
|
16
|
-
import '../hooks/useStyles.js';
|
|
17
|
+
import '../hooks/useStyles/useStyles.js';
|
|
17
18
|
import 'lodash/maxBy';
|
|
18
|
-
import '
|
|
19
|
-
import '../
|
|
20
|
-
import '../
|
|
21
|
-
import '../
|
|
22
|
-
import '../Title-C7Qv9WfS.js';
|
|
19
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
20
|
+
import '../Link-BhJ5BdyS.js';
|
|
21
|
+
import '../Tooltip-BYgzNVYI.js';
|
|
22
|
+
import '../Title-Dck3eHNM.js';
|
|
23
23
|
|
|
24
24
|
var choiceAppearance = {
|
|
25
25
|
accent: {
|
|
@@ -61,8 +61,8 @@ function Choice(props) {
|
|
|
61
61
|
}, [isCheckbox, setActiveSegment]);
|
|
62
62
|
// @ts-expect-error
|
|
63
63
|
var appearanceConfig = choiceConfig.appearance && choiceConfig.appearance[appearance];
|
|
64
|
-
var
|
|
65
|
-
var borderColorClass =
|
|
64
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
65
|
+
var borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, columnGapClass = propsGenerator.columnGapClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveDisabledClass = propsGenerator.fillActiveDisabledClass, fillClass = propsGenerator.fillClass, fillDisabledClass = propsGenerator.fillDisabledClass, fillHoverClass = propsGenerator.fillHoverClass, gapClass = propsGenerator.gapClass, rowGapClass = propsGenerator.rowGapClass, shapeClass = propsGenerator.shapeClass, wrapClass = propsGenerator.wrapClass;
|
|
66
66
|
return (jsx("div", { className: clsx(className, 'choice', shapeClass && "choice_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), set && "choice_set_".concat(set), size && "choice_size_".concat(size), type && "choice_type_".concat(type)), ref: controlRef, children: isLoading ? (jsx(Loader, { width: "fill", height: "fill", fill: "surfacePrimary", itemFill: "surfaceItemAccent", set: "simple" })) : (jsx("div", { className: clsx(className, 'choice__wrapper', gapClass && "gap_".concat(gapClass), rowGapClass && "row-gap_".concat(rowGapClass), columnGapClass && "column-gap_".concat(columnGapClass), wrapClass && "choice_wrap_".concat(wrapClass)), children: options.map(function (item) {
|
|
67
67
|
// prettier-ignore
|
|
68
68
|
var isActive = typeof active === 'object'
|
package/dist/components/Code.js
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import { _ as __assign } from '../tslib.es6-
|
|
1
|
+
import { _ as __assign } from '../tslib.es6-5FtW-kfi.js';
|
|
2
2
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
3
|
import { useState, useEffect } from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import OtpInput from 'react-otp-input';
|
|
6
|
-
import {
|
|
6
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
7
|
import 'lodash/camelCase';
|
|
8
8
|
import 'lodash/castArray';
|
|
9
|
+
import 'lodash/upperFirst';
|
|
9
10
|
import '../context/UIContext.js';
|
|
10
|
-
import '../hooks/useMediaQueries.js';
|
|
11
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
11
12
|
import 'react-responsive';
|
|
12
13
|
import '../utils/setViewportProperty.js';
|
|
13
14
|
|
|
@@ -22,16 +23,18 @@ var codeConfig = {
|
|
|
22
23
|
},
|
|
23
24
|
};
|
|
24
25
|
function Code(props) {
|
|
25
|
-
var
|
|
26
|
+
var className = props.className, appearance = props.appearance, inputAutoFocus = props.inputAutoFocus, _a = props.inputCount, inputCount = _a === void 0 ? 6 : _a, _b = props.inputPlaceholder, inputPlaceholder = _b === void 0 ? 0 : _b, _c = props.inputType, inputType = _c === void 0 ? 'number' : _c, separatorComponent = props.separatorComponent, before = props.before, after = props.after, onBlur = props.onBlur, onChange = props.onChange, onFocus = props.onFocus;
|
|
26
27
|
var _d = useState(''), otp = _d[0], setOtp = _d[1];
|
|
27
28
|
// @ts-expect-error
|
|
28
29
|
var appearanceConfig = codeConfig.appearance && codeConfig.appearance[appearance];
|
|
29
|
-
var
|
|
30
|
-
var gapClass =
|
|
30
|
+
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
31
|
+
var gapClass = propsGenerator.gapClass, _e = propsGenerator.inputBorderColorClass, inputBorderColorClass = _e === void 0 ? 'surfaceBorderTertiary' : _e, _f = propsGenerator.inputBorderColorHoverClass, inputBorderColorHoverClass = _f === void 0 ? 'surfaceBorderQuaternary' : _f, _g = propsGenerator.inputBorderFocusColorClass, inputBorderFocusColorClass = _g === void 0 ? 'surfaceBorderAccent' : _g, _h = propsGenerator.inputBorderWidthClass, inputBorderWidthClass = _h === void 0 ? 1 : _h, _j = propsGenerator.inputCaretColorClass, inputCaretColorClass = _j === void 0 ? 'surfaceItemAccent' : _j, _k = propsGenerator.inputFillClass, inputFillClass = _k === void 0 ? 'surfacePrimary' : _k, _l = propsGenerator.inputFillHoverClass, inputFillHoverClass = _l === void 0 ? 'surfaceSecondary' : _l, inputPlaceholderTextColorClass = propsGenerator.inputPlaceholderTextColorClass, _m = propsGenerator.inputShapeClass, inputShapeClass = _m === void 0 ? 'rounded' : _m, _o = propsGenerator.inputSizeClass, inputSizeClass = _o === void 0 ? 'normal' : _o, _p = propsGenerator.inputTextColorClass, inputTextColorClass = _p === void 0 ? 'xxl' : _p, _q = propsGenerator.inputTextSizeClass, inputTextSizeClass = _q === void 0 ? 'surfaceTextPrimary' : _q, inputTextWeightClass = propsGenerator.inputTextWeightClass, widthClass = propsGenerator.widthClass;
|
|
31
32
|
// NOTE: too many dependencies for "useCallback" and possible too many checks
|
|
32
33
|
var renderInput = function (otpInputProps, index) {
|
|
33
34
|
return (jsx("input", __assign({}, otpInputProps, { className: clsx('code__input', inputCaretColorClass && "caret-color_".concat(inputCaretColorClass), inputFillClass && "fill_".concat(inputFillClass), inputFillHoverClass && "fill_hover_".concat(inputFillHoverClass), inputPlaceholderTextColorClass &&
|
|
34
|
-
"placeholder-text-color_".concat(inputPlaceholderTextColorClass), inputShapeClass && "code__input_shape_".concat(inputShapeClass), inputTextSizeClass && "text_size_".concat(inputTextSizeClass), inputTextColorClass && "text-color_".concat(inputTextColorClass), inputTextWeightClass && "text-weight_".concat(inputTextWeightClass), inputBorderWidthClass && "border-width_".concat(inputBorderWidthClass), inputBorderColorClass && "border-color_".concat(inputBorderColorClass), inputBorderColorHoverClass &&
|
|
35
|
+
"placeholder-text-color_".concat(inputPlaceholderTextColorClass), inputShapeClass && "code__input_shape_".concat(inputShapeClass), inputTextSizeClass && "text_size_".concat(inputTextSizeClass), inputTextColorClass && "text-color_".concat(inputTextColorClass), inputTextWeightClass && "text-weight_".concat(inputTextWeightClass), inputBorderWidthClass && "border-width_".concat(inputBorderWidthClass), inputBorderColorClass && "border-color_".concat(inputBorderColorClass), inputBorderColorHoverClass &&
|
|
36
|
+
"border-color_hover_".concat(inputBorderColorHoverClass), inputBorderFocusColorClass &&
|
|
37
|
+
"border-color_focus_".concat(inputBorderFocusColorClass), inputSizeClass && "code__input_size_".concat(inputSizeClass), widthClass && "width_".concat(widthClass)), name: "code-".concat(index), autoComplete: "one-time-code", onBlur: function (event) {
|
|
35
38
|
onBlur && onBlur(event);
|
|
36
39
|
otpInputProps.onBlur(event);
|
|
37
40
|
}, onFocus: function (event) {
|
|
@@ -44,18 +47,5 @@ function Code(props) {
|
|
|
44
47
|
}, [otp]);
|
|
45
48
|
return (jsxs("div", { className: clsx(className, 'code', widthClass), children: [before, jsx(OtpInput, { containerStyle: clsx(className, 'code__wrapper', gapClass && "gap_".concat(gapClass)), inputType: inputType, numInputs: inputCount, placeholder: inputPlaceholder, renderInput: renderInput, renderSeparator: separatorComponent || null, shouldAutoFocus: inputAutoFocus, value: otp, onChange: setOtp }), after] }));
|
|
46
49
|
}
|
|
47
|
-
Code.defaultProps = {
|
|
48
|
-
inputBorderColor: 'surfaceBorderTertiary',
|
|
49
|
-
inputBorderColorHover: 'surfaceBorderQuaternary',
|
|
50
|
-
inputBorderFocusColor: 'surfaceBorderAccent',
|
|
51
|
-
inputBorderWidth: 1,
|
|
52
|
-
inputCaretColor: 'surfaceItemAccent',
|
|
53
|
-
inputFill: 'surfacePrimary',
|
|
54
|
-
inputFillHover: 'surfaceSecondary',
|
|
55
|
-
inputShape: 'rounded',
|
|
56
|
-
inputSize: 'normal',
|
|
57
|
-
inputTextColor: 'surfaceTextPrimary',
|
|
58
|
-
inputTextSize: 'xxl',
|
|
59
|
-
};
|
|
60
50
|
|
|
61
51
|
export { Code, codeAppearance, codeConfig };
|
|
@@ -2,27 +2,27 @@ import { jsx, jsxs } from 'react/jsx-runtime';
|
|
|
2
2
|
import { useRef, useMemo, useCallback, useEffect } from 'react';
|
|
3
3
|
import clsx from 'clsx';
|
|
4
4
|
import Cookies from 'js-cookie';
|
|
5
|
-
import {
|
|
6
|
-
import { B as Button } from '../Button-
|
|
7
|
-
import { G as Group } from '../Group-
|
|
8
|
-
import { T as Text } from '../Text-
|
|
9
|
-
import '../tslib.es6-
|
|
5
|
+
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
6
|
+
import { B as Button } from '../Button-DZ3z7f-A.js';
|
|
7
|
+
import { G as Group } from '../Group-BKJmVwPZ.js';
|
|
8
|
+
import { T as Text } from '../Text-C6NSmetx.js';
|
|
9
|
+
import '../tslib.es6-5FtW-kfi.js';
|
|
10
10
|
import 'lodash/camelCase';
|
|
11
11
|
import 'lodash/castArray';
|
|
12
|
+
import 'lodash/upperFirst';
|
|
12
13
|
import '../context/UIContext.js';
|
|
13
|
-
import '../hooks/useMediaQueries.js';
|
|
14
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
14
15
|
import 'react-responsive';
|
|
15
16
|
import '../utils/setViewportProperty.js';
|
|
16
|
-
import '../hooks/useStyles.js';
|
|
17
|
+
import '../hooks/useStyles/useStyles.js';
|
|
17
18
|
import 'lodash/maxBy';
|
|
18
|
-
import '
|
|
19
|
-
import '../
|
|
20
|
-
import '../Icon-BdHr6E6M.js';
|
|
19
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
20
|
+
import '../Icon-htF_V35Y.js';
|
|
21
21
|
import 'react-inlinesvg';
|
|
22
|
-
import '../Link-
|
|
23
|
-
import '../Tooltip-
|
|
24
|
-
import '../Title-
|
|
25
|
-
import '../Loader-
|
|
22
|
+
import '../Link-BhJ5BdyS.js';
|
|
23
|
+
import '../Tooltip-BYgzNVYI.js';
|
|
24
|
+
import '../Title-Dck3eHNM.js';
|
|
25
|
+
import '../Loader-CsPvc-9g.js';
|
|
26
26
|
|
|
27
27
|
function CookiesWarning(props) {
|
|
28
28
|
var _a = props.isHideOnScroll, isHideOnScroll = _a === void 0 ? false : _a, buttonFill = props.buttonFill, buttonFillHover = props.buttonFillHover, _b = props.buttonLabel, buttonLabel = _b === void 0 ? 'I agree' : _b, buttonLabelSize = props.buttonLabelSize, buttonLabelTextColor = props.buttonLabelTextColor, buttonShape = props.buttonShape, buttonSize = props.buttonSize, buttonWidth = props.buttonWidth, className = props.className, _c = props.message, message = _c === void 0 ? 'The site uses cookies to collect technical information, to optimize the design and improvement of the website, and to provide certain functions. By using the website, you agree to the use of «cookies».' : _c, textColor = props.textColor, textSize = props.textSize;
|
|
@@ -47,8 +47,8 @@ function CookiesWarning(props) {
|
|
|
47
47
|
window.removeEventListener('scroll', closeCookiesWarning, true);
|
|
48
48
|
}
|
|
49
49
|
}, [isOpen]);
|
|
50
|
-
var
|
|
51
|
-
var fillClass =
|
|
50
|
+
var propsGenerator = useDevicePropsGenerator(props);
|
|
51
|
+
var fillClass = propsGenerator.fillClass, fillGradientClass = propsGenerator.fillGradientClass, gapClass = propsGenerator.gapClass;
|
|
52
52
|
return isOpen ? (jsx("div", { className: clsx('cookies-warning', className, fillClass && "fill_".concat(fillClass), fillGradientClass && "fill-gradient_".concat(fillGradientClass)), ref: cookiesWarningRef, children: jsxs(Group, { className: clsx('cookies-warning__inner', gapClass && "gap_".concat(gapClass)), direction: "vertical", children: [jsx(Text, { size: textSize, textColor: textColor, children: message }), jsx(Button, { width: buttonWidth, labelTextColor: buttonLabelTextColor, labelTextSize: buttonLabelSize, fill: buttonFill, fillHover: buttonFillHover, shape: buttonShape, size: buttonSize, onClick: closeCookiesWarning, children: buttonLabel })] }) })) : null;
|
|
53
53
|
}
|
|
54
54
|
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import { _ as __assign,
|
|
1
|
+
import { _ as __assign, a as __rest } from '../tslib.es6-5FtW-kfi.js';
|
|
2
2
|
import { jsx } from 'react/jsx-runtime';
|
|
3
3
|
import { useMemo } from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import { PartySuggestions } from 'react-dadata';
|
|
6
|
-
import { I as Input } from '../Input-
|
|
7
|
-
import '../hooks/
|
|
6
|
+
import { I as Input } from '../Input-COFdaiTe.js';
|
|
7
|
+
import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
8
8
|
import 'lodash/camelCase';
|
|
9
9
|
import 'lodash/castArray';
|
|
10
|
+
import 'lodash/upperFirst';
|
|
10
11
|
import '../context/UIContext.js';
|
|
11
|
-
import '../hooks/useMediaQueries.js';
|
|
12
|
+
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
12
13
|
import 'react-responsive';
|
|
13
14
|
import '../utils/setViewportProperty.js';
|
|
14
15
|
|