@itcase/ui 1.4.13 → 1.5.1
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-DnWTbwXq.js → Badge-JXM0G_0I.js} +28 -28
- package/dist/{Badge-BxT2_kz_.js → Badge-ydSHGXSG.js} +29 -29
- package/dist/{Button-BiJZz4Bx.js → Button-BmSyIDb_.js} +14 -14
- package/dist/{Button-xYLCmT3D.js → Button-DCtRrkgc.js} +15 -15
- package/dist/{Divider-ImOOytuN.js → Divider-D8hUUrwe.js} +1 -1
- package/dist/{Divider-BQcBkzt1.js → Divider-DhXzYcNF.js} +2 -2
- package/dist/DropdownItem-C8CumsgX.js +117 -0
- package/dist/DropdownItem-CBJeJPbP.js +122 -0
- package/dist/{Group-qq4Iisll.js → Group-BVlu5z77.js} +7 -3
- package/dist/{Group-BICb8bYQ.js → Group-OkygpKiJ.js} +7 -3
- package/dist/Icon-BOEOspTF.js +63 -0
- package/dist/{Icon-BcBOnVKH.js → Icon-DU2T-nfY.js} +9 -7
- package/dist/Image-CSzHhlA1.js +17 -0
- package/dist/Image-DuIBtUq5.js +19 -0
- package/dist/{Input-DHJIVk1z.js → Input-ChiH90mV.js} +33 -30
- package/dist/{Input-DiFnIFT7.js → Input-e0kLrbs6.js} +33 -30
- package/dist/{Label-D-LcvthP.js → Label-CP8IAPOM.js} +5 -5
- package/dist/{Label-y2hx5Q81.js → Label-CfE08vBy.js} +6 -6
- package/dist/{Link-BnqN6ysn.js → Link-UmzWKcxT.js} +18 -11
- package/dist/{Link-DaKqf1pb.js → Link-aBsZ1d0Q.js} +19 -13
- package/dist/{Loader-VK3q7PBN.js → Loader-CRN4MAbm.js} +2 -2
- package/dist/{Loader-DdKHrLnw.js → Loader-rzo8nnRI.js} +1 -1
- package/dist/{Overlay-CZixnXZ6.js → Overlay-CRIofShk.js} +6 -3
- package/dist/{Overlay-Myen2mqz.js → Overlay-CZFSerUl.js} +6 -3
- package/dist/{Scrollbar-Bo7z7ELm.js → Scrollbar-CThJeCLF.js} +4 -4
- package/dist/{Scrollbar-CKbA0jQU.js → Scrollbar-DcKOfcNp.js} +4 -4
- package/dist/{Text-C49zj3jO.js → Text-CEcBg-F5.js} +6 -3
- package/dist/{Text-C6NSmetx.js → Text-CI2prtf6.js} +6 -3
- package/dist/{Title-BLGDdlnX.js → Title-C4xUtigh.js} +12 -2
- package/dist/{Title-Byi9vhDt.js → Title-CaXw1KBQ.js} +13 -3
- package/dist/{Tooltip-5lQyt5-Y.js → Tooltip-EOu0a93a.js} +9 -9
- package/dist/{Tooltip-DRta8lK_.js → Tooltip-Lhx-Fefx.js} +8 -8
- package/dist/cjs/components/Accordion.js +17 -9
- package/dist/cjs/components/Avatar.js +9 -6
- package/dist/cjs/components/Badge.js +9 -6
- package/dist/cjs/components/Breadcrumbs.js +11 -8
- package/dist/cjs/components/Button.js +10 -7
- package/dist/cjs/components/Cell.js +18 -13
- package/dist/cjs/components/Checkbox.js +8 -5
- package/dist/cjs/components/Checkmark.js +5 -3
- package/dist/cjs/components/Chips.js +35 -17
- package/dist/cjs/components/Choice.js +23 -17
- package/dist/cjs/components/Code.js +9 -4
- package/dist/cjs/components/CookiesWarning.js +13 -10
- package/dist/cjs/components/DadataHintField.js +9 -4
- package/dist/cjs/components/DatePicker.js +24 -42
- package/dist/cjs/components/Divider.js +4 -1
- package/dist/cjs/components/Dot.js +3 -0
- package/dist/cjs/components/Drawer.js +3 -3
- package/dist/cjs/components/Dropdown.js +6 -4
- package/dist/cjs/components/Flex.js +7 -4
- package/dist/cjs/components/Grid.js +12 -9
- package/dist/cjs/components/Group.js +5 -2
- package/dist/cjs/components/HTMLContent.js +5 -2
- package/dist/cjs/components/HeroTitle.js +12 -6
- package/dist/cjs/components/Icon.js +8 -5
- package/dist/cjs/components/Image.js +4 -1
- package/dist/cjs/components/Input.js +5 -2
- package/dist/cjs/components/InputMask.js +11 -6
- package/dist/cjs/components/InputPassword.js +34 -28
- package/dist/cjs/components/Label.js +7 -4
- package/dist/cjs/components/Link.js +6 -5
- package/dist/cjs/components/List.js +6 -3
- package/dist/cjs/components/Loader.js +5 -2
- package/dist/cjs/components/Logo.js +7 -4
- package/dist/cjs/components/MenuItem.js +15 -13
- package/dist/cjs/components/Modal.js +11 -8
- package/dist/cjs/components/ModalSheetBottom.js +5 -2
- package/dist/cjs/components/Notification.js +15 -14
- package/dist/cjs/components/Overlay.js +5 -2
- package/dist/cjs/components/Pagination.js +54 -33
- package/dist/cjs/components/Panel.js +13 -8
- package/dist/cjs/components/Radio.js +15 -11
- package/dist/cjs/components/RangeSlider.js +8 -3
- package/dist/cjs/components/Response.js +15 -12
- package/dist/cjs/components/SVGContent.js +3 -0
- package/dist/cjs/components/ScrollOnDrag.js +4 -1
- package/dist/cjs/components/ScrollToView.js +7 -2
- package/dist/cjs/components/Scrollbar.js +1 -1
- package/dist/cjs/components/Search.js +20 -15
- package/dist/cjs/components/Segmented.js +20 -20
- package/dist/cjs/components/Select.js +28 -21
- package/dist/cjs/components/Swiper.js +7 -4
- package/dist/cjs/components/Switch.js +25 -6
- package/dist/cjs/components/Tab.js +14 -11
- package/dist/cjs/components/Text.js +5 -2
- package/dist/cjs/components/Textarea.js +26 -20
- package/dist/cjs/components/Tile.js +12 -10
- package/dist/cjs/components/Title.js +4 -1
- package/dist/cjs/components/Tooltip.js +6 -3
- package/dist/cjs/components/Video.js +4 -1
- package/dist/cjs/context/Notifications.js +2 -2
- package/dist/cjs/context/UIContext.js +2 -2
- package/dist/cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +3 -0
- package/dist/cjs/hooks/useDevicePropsGenerator.js +4 -1
- package/dist/cjs/hooks/useStyles/useStyles.js +3 -0
- package/dist/cjs/hooks/useStyles.js +4 -1
- package/dist/cjs/hooks/useViewportFix.js +1 -1
- package/dist/components/Accordion.js +18 -10
- package/dist/components/Avatar.js +10 -7
- package/dist/components/Badge.js +10 -7
- package/dist/components/Breadcrumbs.js +12 -9
- package/dist/components/Button.js +11 -8
- package/dist/components/Cell.js +18 -13
- package/dist/components/Checkbox.js +9 -6
- package/dist/components/Checkmark.js +6 -4
- package/dist/components/Chips.js +36 -18
- package/dist/components/Choice.js +23 -17
- package/dist/components/Code.js +10 -5
- package/dist/components/CookiesWarning.js +14 -11
- package/dist/components/DadataHintField.js +10 -5
- package/dist/components/DatePicker.js +25 -43
- package/dist/components/Divider.js +5 -2
- package/dist/components/Dot.js +4 -1
- package/dist/components/Drawer.js +3 -3
- package/dist/components/Dropdown.js +7 -5
- package/dist/components/Flex.js +8 -5
- package/dist/components/Grid.js +13 -10
- package/dist/components/Group.js +5 -2
- package/dist/components/HTMLContent.js +6 -3
- package/dist/components/HeroTitle.js +12 -6
- package/dist/components/Icon.js +9 -6
- package/dist/components/Image.js +5 -2
- package/dist/components/Input.js +5 -2
- package/dist/components/InputMask.js +11 -6
- package/dist/components/InputPassword.js +34 -28
- package/dist/components/Label.js +8 -5
- package/dist/components/Link.js +5 -8
- package/dist/components/List.js +7 -4
- package/dist/components/Loader.js +6 -3
- package/dist/components/Logo.js +8 -5
- package/dist/components/MenuItem.js +15 -13
- package/dist/components/Modal.js +12 -9
- package/dist/components/ModalSheetBottom.js +6 -3
- package/dist/components/Notification.js +16 -15
- package/dist/components/Overlay.js +5 -2
- package/dist/components/Pagination.js +54 -33
- package/dist/components/Panel.js +13 -8
- package/dist/components/Radio.js +15 -11
- package/dist/components/RangeSlider.js +9 -4
- package/dist/components/Response.js +16 -13
- package/dist/components/SVGContent.js +4 -1
- package/dist/components/ScrollOnDrag.js +5 -2
- package/dist/components/ScrollToView.js +8 -3
- package/dist/components/Scrollbar.js +1 -1
- package/dist/components/Search.js +20 -15
- package/dist/components/Segmented.js +20 -20
- package/dist/components/Select.js +29 -22
- package/dist/components/Swiper.js +8 -5
- package/dist/components/Switch.js +25 -6
- package/dist/components/Tab.js +15 -12
- package/dist/components/Text.js +5 -2
- package/dist/components/Textarea.js +26 -20
- package/dist/components/Tile.js +13 -11
- package/dist/components/Title.js +5 -2
- package/dist/components/Tooltip.js +7 -4
- package/dist/components/Video.js +4 -1
- package/dist/context/Notifications.js +3 -3
- package/dist/context/UIContext.js +3 -3
- package/dist/css/components/Accordion/Accordion.css +7 -5
- package/dist/css/components/Avatar/Avatar.css +5 -5
- package/dist/css/components/Checkbox/Checkbox.css +1 -1
- package/dist/css/components/Checkmark/Checkmark.css +24 -1
- package/dist/css/components/Chips/Chips.css +2 -2
- package/dist/css/components/Choice/Choice.css +3 -3
- package/dist/css/components/Code/Code.css +26 -2
- package/dist/css/components/DatePicker/DatePicker.css +23 -33
- package/dist/css/components/Divider/Divider.css +3 -3
- package/dist/css/components/Dot/Dot.css +6 -6
- package/dist/css/components/Drawer/Drawer.css +4 -1
- package/dist/css/components/Dropdown/Dropdown.css +13 -13
- package/dist/css/components/Icon/Icon.css +5 -1
- package/dist/css/components/Image/Image.css +6 -3
- package/dist/css/components/Input/Input.css +21 -35
- package/dist/css/components/InputMask/Input.css +6 -6
- package/dist/css/components/InputPassword/InputPassword.css +2 -2
- package/dist/css/components/Label/Label.css +3 -3
- package/dist/css/components/List/List.css +8 -7
- package/dist/css/components/Loader/Loader.css +0 -2
- package/dist/css/components/Logo/Logo.css +1 -1
- package/dist/css/components/MenuItem/MenuItem.css +24 -6
- package/dist/css/components/Modal/Modal.css +2 -2
- package/dist/css/components/ModalSheetBottom/ModalSheetBottom.css +1 -1
- package/dist/css/components/Notification/Notification.css +22 -10
- package/dist/css/components/Notification/css/__item/notification__item_set_float.css +2 -2
- package/dist/css/components/Notification/css/__item/notification__item_set_form.css +5 -5
- package/dist/css/components/Notification/css/__item/notification__item_set_toast.css +2 -2
- package/dist/css/components/Notification/css/__item/notification__item_set_top.css +1 -1
- package/dist/css/components/Overlay/Overlay.css +5 -1
- package/dist/css/components/Pagination/Pagination.css +16 -8
- package/dist/css/components/Pagination/css/__item/pagination__item.css +7 -4
- package/dist/css/components/Pagination/css/__item/pagination__item_state_active.css +4 -1
- package/dist/css/components/Pagination/css/__item/pagination__item_state_disabled.css +1 -1
- package/dist/css/components/Radio/Radio.css +9 -4
- package/dist/css/components/RangeSlider/RangeSlider.css +14 -8
- package/dist/css/components/ScrollToView/ScrollToView.css +2 -2
- package/dist/css/components/Search/Search.css +16 -8
- package/dist/css/components/Search/css/search-input/search-input_shape.css +1 -1
- package/dist/css/components/Search/css/search-input/search-input_size.css +1 -1
- package/dist/css/components/Segmented/Segmented.css +10 -7
- package/dist/css/components/Select/Select.css +10 -10
- package/dist/css/components/Select/css/__control/select__control_shape.css +1 -1
- package/dist/css/components/Select/css/__input-container/select__input-container.css +3 -3
- package/dist/css/components/Select/css/__menu/select__menu-list-item_size.css +2 -2
- package/dist/css/components/Select/css/__menu/select__menu.css +2 -2
- package/dist/css/components/Select/css/__multi-value/select__multi-value.css +2 -2
- package/dist/css/components/Switch/Switch.css +19 -1
- package/dist/css/components/Tab/Tab.css +2 -2
- package/dist/css/components/Text/Text.css +1 -1
- package/dist/css/components/Textarea/Textarea.css +2 -2
- package/dist/css/components/Tile/Tile.css +16 -7
- package/dist/css/components/Tooltip/Tooltip.css +16 -2
- package/dist/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +4 -1
- package/dist/hooks/useDevicePropsGenerator.js +5 -2
- package/dist/hooks/useDeviceTargetClass.js +1 -1
- package/dist/hooks/useStyles/useStyles.js +4 -1
- package/dist/hooks/useStyles.js +5 -2
- package/dist/hooks/useViewportFix.js +1 -1
- package/dist/{tslib.es6-5FtW-kfi.js → tslib.es6-Bwu1Cn-t.js} +1 -1
- package/dist/types/components/Accordion/Accordion.appearance.d.ts +3 -3
- package/dist/types/components/Accordion/Accordion.d.ts +3 -3
- package/dist/types/components/Accordion/Accordion.interface.d.ts +60 -61
- package/dist/types/components/Accordion/AccordionItem.d.ts +3 -3
- package/dist/types/components/Avatar/Avatar.appearance.d.ts +2 -2
- package/dist/types/components/Avatar/Avatar.d.ts +3 -3
- package/dist/types/components/Avatar/Avatar.interface.d.ts +24 -25
- package/dist/types/components/Badge/Badge.appearance.d.ts +2 -2
- package/dist/types/components/Badge/Badge.d.ts +3 -3
- package/dist/types/components/Badge/Badge.interface.d.ts +21 -22
- package/dist/types/components/Badge/appearance/badgeAccent.d.ts +3 -3
- package/dist/types/components/Badge/appearance/badgeDisabled.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeError.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeInfo.d.ts +2 -2
- package/dist/types/components/Badge/appearance/badgePrimary.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeSecondary.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeSize.d.ts +7 -7
- package/dist/types/components/Badge/appearance/badgeSuccess.d.ts +1 -1
- package/dist/types/components/Badge/appearance/badgeSurface.d.ts +7 -7
- package/dist/types/components/Badge/appearance/badgeWarning.d.ts +1 -1
- package/dist/types/components/Breadcrumbs/Breadcrumbs.d.ts +2 -2
- package/dist/types/components/Breadcrumbs/Breadcrumbs.interface.d.ts +49 -49
- package/dist/types/components/Breadcrumbs/BreadcrumbsItem.d.ts +2 -2
- package/dist/types/components/Button/Button.appearance.d.ts +2 -2
- package/dist/types/components/Button/Button.d.ts +3 -3
- package/dist/types/components/Button/Button.interface.d.ts +44 -45
- package/dist/types/components/Button/appearance/buttonAccent.d.ts +10 -10
- package/dist/types/components/Cell/Cell.appearance.d.ts +2 -2
- package/dist/types/components/Cell/Cell.d.ts +3 -3
- package/dist/types/components/Cell/Cell.interface.d.ts +40 -41
- package/dist/types/components/Checkbox/Checkbox.appearance.d.ts +3 -3
- package/dist/types/components/Checkbox/Checkbox.d.ts +3 -3
- package/dist/types/components/Checkbox/Checkbox.interface.d.ts +36 -37
- package/dist/types/components/Checkmark/Checkmark.appearance.d.ts +2 -2
- package/dist/types/components/Checkmark/Checkmark.d.ts +3 -3
- package/dist/types/components/Checkmark/Checkmark.interface.d.ts +15 -17
- package/dist/types/components/Chips/Chips.appearance.d.ts +2 -2
- package/dist/types/components/Chips/Chips.d.ts +3 -3
- package/dist/types/components/Chips/Chips.interface.d.ts +30 -31
- package/dist/types/components/Chips/appearance/chipsDisabled.d.ts +2 -0
- package/dist/types/components/Chips/appearance/chipsSurface.d.ts +4 -0
- package/dist/types/components/Choice/Choice.appearance.d.ts +2 -2
- package/dist/types/components/Choice/Choice.d.ts +3 -3
- package/dist/types/components/Choice/Choice.interface.d.ts +35 -36
- package/dist/types/components/Code/Code.appearance.d.ts +2 -2
- package/dist/types/components/Code/Code.d.ts +3 -3
- package/dist/types/components/Code/Code.interface.d.ts +31 -32
- package/dist/types/components/CookiesWarning/CookiesWarning.d.ts +2 -2
- package/dist/types/components/CookiesWarning/CookiesWarning.interface.d.ts +10 -10
- package/dist/types/components/DadataHintField/DadataHintField.d.ts +2 -2
- package/dist/types/components/DadataHintField/DadataHintField.interface.d.ts +3 -3
- package/dist/types/components/DatePicker/DatePicker.appearance.d.ts +2 -2
- package/dist/types/components/DatePicker/DatePicker.d.ts +3 -3
- package/dist/types/components/DatePicker/DatePicker.interface.d.ts +71 -72
- package/dist/types/components/Divider/Divider.d.ts +3 -3
- package/dist/types/components/Divider/Divider.interface.d.ts +29 -30
- package/dist/types/components/Dot/Dot.d.ts +2 -2
- package/dist/types/components/Dot/Dot.interface.d.ts +21 -21
- package/dist/types/components/Drawer/Drawer.appearance.d.ts +2 -2
- package/dist/types/components/Drawer/Drawer.d.ts +3 -3
- package/dist/types/components/Drawer/Drawer.interface.d.ts +12 -12
- package/dist/types/components/Dropdown/Dropdown.d.ts +2 -2
- package/dist/types/components/Dropdown/Dropdown.interface.d.ts +51 -53
- package/dist/types/components/Dropdown/DropdownItem.appearance.d.ts +2 -2
- package/dist/types/components/Dropdown/DropdownItem.d.ts +3 -3
- package/dist/types/components/Dropdown/appearance/dropdownSurface.d.ts +25 -0
- package/dist/types/components/Flex/Flex.d.ts +2 -2
- package/dist/types/components/Flex/Flex.interface.d.ts +83 -83
- package/dist/types/components/Flex/FlexItem.d.ts +2 -2
- package/dist/types/components/Grid/Grid.d.ts +2 -2
- package/dist/types/components/Grid/Grid.interface.d.ts +47 -47
- package/dist/types/components/Grid/GridItem.d.ts +2 -2
- package/dist/types/components/Grid/GridRow.d.ts +2 -2
- package/dist/types/components/Group/Group.appearance.d.ts +2 -2
- package/dist/types/components/Group/Group.d.ts +3 -3
- package/dist/types/components/Group/Group.interface.d.ts +28 -29
- package/dist/types/components/HTMLContent/HTMLContent.d.ts +2 -2
- package/dist/types/components/HTMLContent/HTMLContent.interface.d.ts +20 -20
- package/dist/types/components/HeroTitle/HeroTitle.appearance.d.ts +2 -2
- package/dist/types/components/HeroTitle/HeroTitle.d.ts +3 -3
- package/dist/types/components/HeroTitle/HeroTitle.interface.d.ts +27 -28
- package/dist/types/components/Icon/Icon.appearance.d.ts +2 -2
- package/dist/types/components/Icon/Icon.d.ts +3 -3
- package/dist/types/components/Icon/Icon.interface.d.ts +49 -50
- package/dist/types/components/Image/Image.d.ts +2 -2
- package/dist/types/components/Image/Image.interface.d.ts +10 -10
- package/dist/types/components/Input/Input.appearance.d.ts +3 -3
- package/dist/types/components/Input/Input.d.ts +3 -3
- package/dist/types/components/Input/Input.interface.d.ts +31 -33
- package/dist/types/components/InputMask/Input.d.ts +3 -3
- package/dist/types/components/InputMask/Input.interface.d.ts +31 -33
- package/dist/types/components/InputPassword/InputPassword.appearance.d.ts +3 -3
- package/dist/types/components/InputPassword/InputPassword.d.ts +3 -3
- package/dist/types/components/InputPassword/InputPassword.interface.d.ts +31 -33
- package/dist/types/components/Label/Label.appearance.d.ts +2 -2
- package/dist/types/components/Label/Label.d.ts +3 -3
- package/dist/types/components/Label/Label.interface.d.ts +31 -32
- package/dist/types/components/Link/Link.appearance.d.ts +2 -2
- package/dist/types/components/Link/Link.d.ts +4 -4
- package/dist/types/components/Link/Link.interface.d.ts +32 -32
- package/dist/types/components/List/List.d.ts +2 -2
- package/dist/types/components/List/List.interface.d.ts +13 -13
- package/dist/types/components/List/ListItem.d.ts +2 -2
- package/dist/types/components/Loader/Loader.d.ts +3 -3
- package/dist/types/components/Loader/Loader.interface.d.ts +18 -19
- package/dist/types/components/Logo/Logo.d.ts +3 -3
- package/dist/types/components/Logo/Logo.interface.d.ts +16 -17
- package/dist/types/components/MenuItem/MenuItem.appearance.d.ts +2 -2
- package/dist/types/components/MenuItem/MenuItem.d.ts +3 -10
- package/dist/types/components/MenuItem/MenuItem.interface.d.ts +41 -42
- package/dist/types/components/Modal/Modal.appearance.d.ts +2 -2
- package/dist/types/components/Modal/Modal.d.ts +2 -2
- package/dist/types/components/Modal/Modal.interface.d.ts +20 -21
- package/dist/types/components/Modal/ModalLoader.d.ts +1 -2
- package/dist/types/components/ModalSheetBottom/ModalSheetBottom.d.ts +2 -2
- package/dist/types/components/ModalSheetBottom/ModalSheetBottom.interface.d.ts +4 -3
- package/dist/types/components/Notification/Notification.interface.d.ts +26 -27
- package/dist/types/components/Notification/NotificationItem.appearance.d.ts +2 -2
- package/dist/types/components/Notification/NotificationItem.d.ts +3 -3
- package/dist/types/components/Notification/NotificationList.d.ts +2 -2
- package/dist/types/components/Overlay/Overlay.appearance.d.ts +2 -2
- package/dist/types/components/Overlay/Overlay.d.ts +3 -3
- package/dist/types/components/Overlay/Overlay.interface.d.ts +14 -15
- package/dist/types/components/Pagination/Pagination.appearance.d.ts +2 -2
- package/dist/types/components/Pagination/Pagination.d.ts +3 -3
- package/dist/types/components/Pagination/Pagination.interface.d.ts +37 -38
- package/dist/types/components/Panel/Panel.d.ts +3 -3
- package/dist/types/components/Panel/Panel.interface.d.ts +33 -34
- package/dist/types/components/Radio/Radio.appearance.d.ts +1 -1
- package/dist/types/components/Radio/Radio.d.ts +3 -3
- package/dist/types/components/Radio/Radio.interface.d.ts +34 -35
- package/dist/types/components/RangeSlider/RangeSlider.d.ts +2 -2
- package/dist/types/components/RangeSlider/RangeSlider.interface.d.ts +12 -12
- package/dist/types/components/Response/Response.d.ts +3 -3
- package/dist/types/components/Response/Response.interface.d.ts +41 -42
- package/dist/types/components/SVGContent/SVGContent.d.ts +2 -2
- package/dist/types/components/SVGContent/SVGContent.interface.d.ts +5 -5
- package/dist/types/components/ScrollOnDrag/ScrollOnDrag.d.ts +2 -2
- package/dist/types/components/ScrollOnDrag/ScrollOnDrag.interface.d.ts +11 -11
- package/dist/types/components/Scrollbar/Scrollbar.d.ts +2 -2
- package/dist/types/components/Scrollbar/Scrollbar.interface.d.ts +2 -2
- package/dist/types/components/Search/Search.appearance.d.ts +2 -2
- package/dist/types/components/Search/Search.interface.d.ts +36 -37
- package/dist/types/components/Search/SearchInput.d.ts +3 -3
- package/dist/types/components/Segmented/Segmented.appearance.d.ts +2 -2
- package/dist/types/components/Segmented/Segmented.d.ts +3 -3
- package/dist/types/components/Segmented/Segmented.interface.d.ts +28 -29
- package/dist/types/components/Select/Select.appearance.d.ts +2 -2
- package/dist/types/components/Select/Select.interface.d.ts +48 -49
- package/dist/types/components/Select/SelectContainer.d.ts +3 -3
- package/dist/types/components/Swiper/Swiper.d.ts +2 -2
- package/dist/types/components/Swiper/Swiper.interface.d.ts +10 -10
- package/dist/types/components/Switch/Switch.appearance.d.ts +2 -2
- package/dist/types/components/Switch/Switch.d.ts +3 -3
- package/dist/types/components/Switch/Switch.interface.d.ts +11 -11
- package/dist/types/components/Tab/Tab.appearance.d.ts +2 -2
- package/dist/types/components/Tab/Tab.d.ts +3 -3
- package/dist/types/components/Tab/Tab.interface.d.ts +55 -56
- package/dist/types/components/Tab/TabGroup.d.ts +2 -2
- package/dist/types/components/Text/Text.appearance.d.ts +2 -2
- package/dist/types/components/Text/Text.d.ts +3 -3
- package/dist/types/components/Text/Text.interface.d.ts +33 -34
- package/dist/types/components/Textarea/Textarea.appearance.d.ts +3 -3
- package/dist/types/components/Textarea/Textarea.d.ts +3 -3
- package/dist/types/components/Textarea/Textarea.interface.d.ts +27 -29
- package/dist/types/components/Tile/Tile.appearance.d.ts +2 -2
- package/dist/types/components/Tile/Tile.d.ts +3 -3
- package/dist/types/components/Tile/Tile.interface.d.ts +32 -33
- package/dist/types/components/Title/Title.appearance.d.ts +2 -2
- package/dist/types/components/Title/Title.d.ts +3 -3
- package/dist/types/components/Title/Title.interface.d.ts +27 -28
- package/dist/types/components/Tooltip/Tooltip.appearance.d.ts +2 -2
- package/dist/types/components/Tooltip/Tooltip.d.ts +3 -3
- package/dist/types/components/Tooltip/Tooltip.interface.d.ts +26 -27
- package/dist/types/components/Video/Video.d.ts +2 -2
- package/dist/types/components/Video/Video.interface.d.ts +2 -2
- package/dist/types/context/Notifications.d.ts +4 -5
- package/dist/types/context/Notifications.interface.d.ts +14 -14
- package/dist/types/hooks/useDevicePropsGenerator/useDevicePropsGenerator.d.ts +2 -2
- package/dist/types/hooks/useDevicePropsGenerator/useDevicePropsGenerator.interface.d.ts +7 -7
- package/dist/types/hooks/useStyles/styleAttributes.interface.d.ts +80 -80
- package/package.json +7 -6
- package/dist/DropdownItem-B3E-_Cwp.js +0 -88
- package/dist/DropdownItem-Qg-_2YWD.js +0 -93
- package/dist/Icon-OJ_3E3eM.js +0 -61
- package/dist/Image-BEGwuGBM.js +0 -17
- package/dist/Image-DWfyapuD.js +0 -15
- package/dist/stories/Dev.mdx +0 -9
- package/dist/types/types/componentProps/align.d.ts +0 -2
- package/dist/types/types/componentProps/alignDirection.d.ts +0 -3
- package/dist/types/types/componentProps/alignment.d.ts +0 -3
- package/dist/types/types/componentProps/appearanceKeys.d.ts +0 -1
- package/dist/types/types/componentProps/borderColor.d.ts +0 -3
- package/dist/types/types/componentProps/borderColorHover.d.ts +0 -3
- package/dist/types/types/componentProps/borderType.d.ts +0 -3
- package/dist/types/types/componentProps/borderWidth.d.ts +0 -3
- package/dist/types/types/componentProps/direction.d.ts +0 -3
- package/dist/types/types/componentProps/elevation.d.ts +0 -3
- package/dist/types/types/componentProps/fill.d.ts +0 -3
- package/dist/types/types/componentProps/fillGradient.d.ts +0 -3
- package/dist/types/types/componentProps/fillHover.d.ts +0 -3
- package/dist/types/types/componentProps/fillType.d.ts +0 -3
- package/dist/types/types/componentProps/flexAlign.d.ts +0 -3
- package/dist/types/types/componentProps/flexGrow.d.ts +0 -3
- package/dist/types/types/componentProps/flexJustifyContent.d.ts +0 -3
- package/dist/types/types/componentProps/flexWrap.d.ts +0 -3
- package/dist/types/types/componentProps/gridAlign.d.ts +0 -3
- package/dist/types/types/componentProps/gridAlignSelf.d.ts +0 -3
- package/dist/types/types/componentProps/gridJustifyItems.d.ts +0 -3
- package/dist/types/types/componentProps/gridJustifySelf.d.ts +0 -3
- package/dist/types/types/componentProps/height.d.ts +0 -3
- package/dist/types/types/componentProps/horizontalContentAlign.d.ts +0 -3
- package/dist/types/types/componentProps/horizontalResizeMode.d.ts +0 -3
- package/dist/types/types/componentProps/iconFillSize.d.ts +0 -3
- package/dist/types/types/componentProps/iconSize.d.ts +0 -3
- package/dist/types/types/componentProps/itemColor.d.ts +0 -3
- package/dist/types/types/componentProps/justifyContent.d.ts +0 -3
- package/dist/types/types/componentProps/overflow.d.ts +0 -3
- package/dist/types/types/componentProps/position.d.ts +0 -3
- package/dist/types/types/componentProps/resizeMode.d.ts +0 -3
- package/dist/types/types/componentProps/shape.d.ts +0 -3
- package/dist/types/types/componentProps/size.d.ts +0 -3
- package/dist/types/types/componentProps/sizeOption.d.ts +0 -3
- package/dist/types/types/componentProps/sizePX.d.ts +0 -3
- package/dist/types/types/componentProps/stacking.d.ts +0 -3
- package/dist/types/types/componentProps/state.d.ts +0 -3
- package/dist/types/types/componentProps/stateKeys.d.ts +0 -1
- package/dist/types/types/componentProps/svgFill.d.ts +0 -3
- package/dist/types/types/componentProps/textAlign.d.ts +0 -3
- package/dist/types/types/componentProps/textColor.d.ts +0 -3
- package/dist/types/types/componentProps/textColorActive.d.ts +0 -3
- package/dist/types/types/componentProps/textColorHover.d.ts +0 -3
- package/dist/types/types/componentProps/textGradient.d.ts +0 -3
- package/dist/types/types/componentProps/textSize.d.ts +0 -3
- package/dist/types/types/componentProps/textStyle.d.ts +0 -3
- package/dist/types/types/componentProps/textTag.d.ts +0 -3
- package/dist/types/types/componentProps/textWeight.d.ts +0 -3
- package/dist/types/types/componentProps/textWrap.d.ts +0 -3
- package/dist/types/types/componentProps/titleSize.d.ts +0 -5
- package/dist/types/types/componentProps/type.d.ts +0 -3
- package/dist/types/types/componentProps/underline.d.ts +0 -3
- package/dist/types/types/componentProps/verticalContentAlign.d.ts +0 -3
- package/dist/types/types/componentProps/verticalResizeMode.d.ts +0 -3
- package/dist/types/types/componentProps/width.d.ts +0 -3
- package/dist/types/types/componentProps/wrap.d.ts +0 -3
- package/dist/types/types/index.d.ts +0 -55
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type * as CSS from 'csstype';
|
|
2
|
-
import {
|
|
3
|
-
export interface
|
|
2
|
+
import { OverflowProps, TextAlignProps } from '@itcase/types';
|
|
3
|
+
export interface StyleAttributes {
|
|
4
4
|
/**
|
|
5
5
|
* Layout
|
|
6
6
|
*/
|
|
@@ -8,16 +8,47 @@ export interface iStyleAttributes {
|
|
|
8
8
|
alignItems?: string;
|
|
9
9
|
alignSelf?: string;
|
|
10
10
|
aspectRatio?: CSS.Property.AspectRatio;
|
|
11
|
+
/**
|
|
12
|
+
* Filter
|
|
13
|
+
*/
|
|
14
|
+
backdropFilter?: string;
|
|
15
|
+
/**
|
|
16
|
+
* View
|
|
17
|
+
*/
|
|
18
|
+
background?: string;
|
|
19
|
+
backgroundColor?: string;
|
|
11
20
|
border?: string;
|
|
21
|
+
borderBottomColor?: string;
|
|
22
|
+
borderBottomEndRadius?: string;
|
|
23
|
+
borderBottomLeftRadius?: string;
|
|
24
|
+
borderBottomRightRadius?: string;
|
|
25
|
+
borderBottomStartRadius?: string;
|
|
12
26
|
borderBottomWidth?: string;
|
|
27
|
+
borderCurve?: string;
|
|
28
|
+
borderEndColor?: string;
|
|
13
29
|
borderEndWidth?: string;
|
|
30
|
+
borderLeftColor?: string;
|
|
14
31
|
borderLeftWidth?: string;
|
|
32
|
+
borderRadius?: string;
|
|
33
|
+
borderRightColor?: string;
|
|
15
34
|
borderRightWidth?: string;
|
|
35
|
+
borderStartColor?: string;
|
|
16
36
|
borderStartWidth?: string;
|
|
37
|
+
borderStyle?: string;
|
|
38
|
+
borderTopColor?: string;
|
|
39
|
+
borderTopEndRadius?: string;
|
|
40
|
+
borderTopLeftRadius?: string;
|
|
41
|
+
borderTopRightRadius?: string;
|
|
42
|
+
borderTopStartRadius?: string;
|
|
17
43
|
borderTopWidth?: string;
|
|
18
44
|
bottom?: string;
|
|
45
|
+
/**
|
|
46
|
+
* Text
|
|
47
|
+
*/
|
|
48
|
+
color?: string;
|
|
19
49
|
columnGap?: string;
|
|
20
50
|
columnWidth?: string;
|
|
51
|
+
cursor?: string;
|
|
21
52
|
display?: CSS.Property.Display;
|
|
22
53
|
end?: string;
|
|
23
54
|
flex?: CSS.Property.Flex;
|
|
@@ -25,9 +56,31 @@ export interface iStyleAttributes {
|
|
|
25
56
|
flexDirection?: CSS.Property.FlexDirection;
|
|
26
57
|
flexShrink?: CSS.Property.FlexShrink;
|
|
27
58
|
flexWrap?: CSS.Property.FlexWrap;
|
|
59
|
+
fontFamily?: string;
|
|
60
|
+
fontSize?: string;
|
|
61
|
+
fontStyle?: CSS.Property.FontStyle;
|
|
62
|
+
fontVariant?: string;
|
|
63
|
+
fontWeight?: CSS.Property.FontWeight;
|
|
28
64
|
gap?: string;
|
|
65
|
+
/**
|
|
66
|
+
* Grid
|
|
67
|
+
*/
|
|
68
|
+
gridArea?: string;
|
|
69
|
+
gridAutoColumns?: string;
|
|
70
|
+
gridAutoFlow?: string;
|
|
71
|
+
gridAutoRows?: string;
|
|
72
|
+
gridColumn?: string;
|
|
73
|
+
gridColumnGap?: string;
|
|
74
|
+
gridRow?: string;
|
|
75
|
+
gridRowGap?: string;
|
|
76
|
+
gridTemplate?: string;
|
|
77
|
+
gridTemplateAreas?: string;
|
|
78
|
+
gridTemplateColumns?: string;
|
|
79
|
+
gridTemplateRows?: string;
|
|
29
80
|
height?: string;
|
|
30
81
|
left?: string;
|
|
82
|
+
letterSpacing?: string;
|
|
83
|
+
lineHeight?: string;
|
|
31
84
|
margin?: string;
|
|
32
85
|
marginBottom?: string;
|
|
33
86
|
marginEnd?: string;
|
|
@@ -41,8 +94,15 @@ export interface iStyleAttributes {
|
|
|
41
94
|
maxWidth?: string;
|
|
42
95
|
minHeight?: string;
|
|
43
96
|
minWidth?: string;
|
|
97
|
+
/**
|
|
98
|
+
* Image
|
|
99
|
+
*/
|
|
100
|
+
objectFit?: CSS.Property.ObjectFit;
|
|
101
|
+
objectPosition?: CSS.Property.ObjectPosition;
|
|
102
|
+
opacity?: string;
|
|
44
103
|
order?: CSS.Property.Order;
|
|
45
|
-
overflow?:
|
|
104
|
+
overflow?: OverflowProps;
|
|
105
|
+
overlayColor?: string;
|
|
46
106
|
padding?: string;
|
|
47
107
|
paddingBottom?: string;
|
|
48
108
|
paddingEnd?: string;
|
|
@@ -53,12 +113,9 @@ export interface iStyleAttributes {
|
|
|
53
113
|
paddingTop?: string;
|
|
54
114
|
paddingVertical?: string;
|
|
55
115
|
position?: string;
|
|
116
|
+
resizeMode?: string;
|
|
56
117
|
right?: string;
|
|
57
118
|
rowGap?: string;
|
|
58
|
-
start?: string;
|
|
59
|
-
top?: string;
|
|
60
|
-
width?: string;
|
|
61
|
-
zIndex?: string;
|
|
62
119
|
/**
|
|
63
120
|
* Shadow
|
|
64
121
|
*/
|
|
@@ -66,46 +123,8 @@ export interface iStyleAttributes {
|
|
|
66
123
|
shadowOffset?: string;
|
|
67
124
|
shadowOpacity?: string;
|
|
68
125
|
shadowRadius?: string;
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
*/
|
|
72
|
-
transform?: CSS.Property.Transform;
|
|
73
|
-
/**
|
|
74
|
-
* View
|
|
75
|
-
*/
|
|
76
|
-
background?: string;
|
|
77
|
-
backgroundColor?: string;
|
|
78
|
-
borderBottomColor?: string;
|
|
79
|
-
borderBottomEndRadius?: string;
|
|
80
|
-
borderBottomLeftRadius?: string;
|
|
81
|
-
borderBottomRightRadius?: string;
|
|
82
|
-
borderBottomStartRadius?: string;
|
|
83
|
-
borderCurve?: string;
|
|
84
|
-
borderEndColor?: string;
|
|
85
|
-
borderLeftColor?: string;
|
|
86
|
-
borderRadius?: string;
|
|
87
|
-
borderRightColor?: string;
|
|
88
|
-
borderStartColor?: string;
|
|
89
|
-
borderStyle?: string;
|
|
90
|
-
borderTopColor?: string;
|
|
91
|
-
borderTopEndRadius?: string;
|
|
92
|
-
borderTopLeftRadius?: string;
|
|
93
|
-
borderTopRightRadius?: string;
|
|
94
|
-
borderTopStartRadius?: string;
|
|
95
|
-
cursor?: string;
|
|
96
|
-
opacity?: string;
|
|
97
|
-
/**
|
|
98
|
-
* Text
|
|
99
|
-
*/
|
|
100
|
-
color?: string;
|
|
101
|
-
fontFamily?: string;
|
|
102
|
-
fontSize?: string;
|
|
103
|
-
fontStyle?: CSS.Property.FontStyle;
|
|
104
|
-
fontVariant?: string;
|
|
105
|
-
fontWeight?: CSS.Property.FontWeight;
|
|
106
|
-
letterSpacing?: string;
|
|
107
|
-
lineHeight?: string;
|
|
108
|
-
textAlign?: tTextAlignProps;
|
|
126
|
+
start?: string;
|
|
127
|
+
textAlign?: TextAlignProps;
|
|
109
128
|
textDecorationColor?: string;
|
|
110
129
|
textDecorationLine?: string;
|
|
111
130
|
textDecorationStyle?: string;
|
|
@@ -113,50 +132,31 @@ export interface iStyleAttributes {
|
|
|
113
132
|
textShadowOffset?: string;
|
|
114
133
|
textShadowRadius?: string;
|
|
115
134
|
textTransform?: CSS.Property.TextTransform;
|
|
116
|
-
verticalAlign?: CSS.Property.VerticalAlign;
|
|
117
|
-
writingMode?: CSS.Property.WritingMode;
|
|
118
|
-
whiteSpace?: CSS.Property.WhiteSpace;
|
|
119
|
-
/**
|
|
120
|
-
* Image
|
|
121
|
-
*/
|
|
122
|
-
objectFit?: CSS.Property.ObjectFit;
|
|
123
|
-
objectPosition?: CSS.Property.ObjectPosition;
|
|
124
|
-
overlayColor?: string;
|
|
125
|
-
resizeMode?: string;
|
|
126
135
|
tintColor?: string;
|
|
136
|
+
top?: string;
|
|
127
137
|
/**
|
|
128
|
-
*
|
|
129
|
-
*/
|
|
130
|
-
gridArea?: string;
|
|
131
|
-
gridAutoColumns?: string;
|
|
132
|
-
gridAutoFlow?: string;
|
|
133
|
-
gridAutoRows?: string;
|
|
134
|
-
gridColumn?: string;
|
|
135
|
-
gridColumnGap?: string;
|
|
136
|
-
gridRow?: string;
|
|
137
|
-
gridRowGap?: string;
|
|
138
|
-
gridTemplate?: string;
|
|
139
|
-
gridTemplateAreas?: string;
|
|
140
|
-
gridTemplateColumns?: string;
|
|
141
|
-
gridTemplateRows?: string;
|
|
142
|
-
/**
|
|
143
|
-
* Filter
|
|
138
|
+
* Transform
|
|
144
139
|
*/
|
|
145
|
-
|
|
140
|
+
transform?: CSS.Property.Transform;
|
|
141
|
+
verticalAlign?: CSS.Property.VerticalAlign;
|
|
142
|
+
whiteSpace?: CSS.Property.WhiteSpace;
|
|
143
|
+
width?: string;
|
|
144
|
+
writingMode?: CSS.Property.WritingMode;
|
|
145
|
+
zIndex?: string;
|
|
146
146
|
}
|
|
147
147
|
type WrappedInterface<T> = {
|
|
148
|
-
[P in keyof T as `${
|
|
148
|
+
[P in keyof T as `${P & string}Wrapper`]: T[P];
|
|
149
149
|
};
|
|
150
150
|
type LabelInterface<T> = {
|
|
151
|
-
[P in keyof T as `${
|
|
151
|
+
[P in keyof T as `${P & string}Label`]: T[P];
|
|
152
152
|
};
|
|
153
153
|
type ImageInterface<T> = {
|
|
154
|
-
[P in keyof T as `${
|
|
154
|
+
[P in keyof T as `${P & string}Image`]: T[P];
|
|
155
155
|
};
|
|
156
|
-
export interface TypeStyleWrapperAttributes extends WrappedInterface<
|
|
156
|
+
export interface TypeStyleWrapperAttributes extends WrappedInterface<StyleAttributes> {
|
|
157
157
|
}
|
|
158
|
-
export interface TypeStyleLabelAttributes extends LabelInterface<
|
|
158
|
+
export interface TypeStyleLabelAttributes extends LabelInterface<StyleAttributes> {
|
|
159
159
|
}
|
|
160
|
-
export interface TypeStyleImageAttributes extends ImageInterface<
|
|
160
|
+
export interface TypeStyleImageAttributes extends ImageInterface<StyleAttributes> {
|
|
161
161
|
}
|
|
162
162
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itcase/ui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.1",
|
|
4
4
|
"description": "UI components (Modal, Loader, Popup, etc)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Modal",
|
|
@@ -97,19 +97,20 @@
|
|
|
97
97
|
"dependencies": {
|
|
98
98
|
"@emotion/is-prop-valid": "^1.3.1",
|
|
99
99
|
"@itcase/common": "^1.2.22",
|
|
100
|
-
"@itcase/config": "^1.0.
|
|
100
|
+
"@itcase/config": "^1.0.40",
|
|
101
101
|
"@itcase/icons": "^1.0.29",
|
|
102
102
|
"@itcase/storybook-config": "^1.1.9",
|
|
103
103
|
"@itcase/tokens-am": "^1.1.3",
|
|
104
104
|
"@itcase/tokens-baikal": "^1.1.3",
|
|
105
|
+
"@itcase/types": "^1.0.2",
|
|
105
106
|
"clsx": "^2.1.1",
|
|
106
107
|
"date-fns": "^4.1.0",
|
|
107
108
|
"eslint-import-resolver-alias": "^1.1.2",
|
|
108
109
|
"eslint-plugin-import": "^2.31.0",
|
|
109
|
-
"framer-motion": "^12.
|
|
110
|
+
"framer-motion": "^12.9.1",
|
|
110
111
|
"js-cookie": "^3.0.5",
|
|
111
112
|
"lodash": "^4.17.21",
|
|
112
|
-
"motion": "^12.
|
|
113
|
+
"motion": "^12.9.1",
|
|
113
114
|
"rc-slider": "^11.1.8",
|
|
114
115
|
"react": "^18.3.1",
|
|
115
116
|
"react-dadata": "^2.27.4",
|
|
@@ -134,7 +135,7 @@
|
|
|
134
135
|
"@babel/preset-react": "^7.26.3",
|
|
135
136
|
"@commitlint/cli": "^19.8.0",
|
|
136
137
|
"@commitlint/config-conventional": "^19.8.0",
|
|
137
|
-
"@itcase/lint": "^1.1.
|
|
138
|
+
"@itcase/lint": "^1.1.9",
|
|
138
139
|
"@rollup/plugin-alias": "^5.1.1",
|
|
139
140
|
"@rollup/plugin-babel": "^6.0.4",
|
|
140
141
|
"@rollup/plugin-commonjs": "^28.0.3",
|
|
@@ -174,7 +175,7 @@
|
|
|
174
175
|
"rollup-preserve-directives": "^1.1.3",
|
|
175
176
|
"semantic-release": "^24.2.3",
|
|
176
177
|
"storybook": "^8.6.12",
|
|
177
|
-
"stylelint": "^16.
|
|
178
|
+
"stylelint": "^16.19.0",
|
|
178
179
|
"typescript": "^5.8.3"
|
|
179
180
|
}
|
|
180
181
|
}
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import React, { useRef, useState, useCallback, useEffect } from 'react';
|
|
3
|
-
import clsx from 'clsx';
|
|
4
|
-
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
|
-
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
6
|
-
import { D as Divider } from './Divider-BQcBkzt1.js';
|
|
7
|
-
import { a as Link } from './Link-DaKqf1pb.js';
|
|
8
|
-
import { T as Text } from './Text-C6NSmetx.js';
|
|
9
|
-
|
|
10
|
-
function Dropdown(props) {
|
|
11
|
-
var className = props.className, _a = props.animationClose, animationClose = _a === void 0 ? 'dropdown_animation_close' : _a, _b = props.animationOpen, animationOpen = _b === void 0 ? 'dropdown_animation_open' : _b, before = props.before, after = props.after, isOpen = props.isOpen, _c = props.set, set = _c === void 0 ? 'normal' : _c, setIsOpen = props.setIsOpen, children = props.children;
|
|
12
|
-
var dropdownRef = useRef(null);
|
|
13
|
-
// const [isOpen, setIsOpen] = useState(false)
|
|
14
|
-
var _d = useState({
|
|
15
|
-
className: '',
|
|
16
|
-
}), animationState = _d[0], setAnimationState = _d[1];
|
|
17
|
-
var onAnimationEnd = useCallback(function () {
|
|
18
|
-
// When component is change his visibility(display) in DOM,
|
|
19
|
-
// animation of close can run unnecessary on showing element.
|
|
20
|
-
// const dropdownElement = dropdownRef.current
|
|
21
|
-
setAnimationState(function (prevState) { return ({
|
|
22
|
-
className: isOpen ? prevState.className : '',
|
|
23
|
-
}); });
|
|
24
|
-
}, [isOpen]);
|
|
25
|
-
useEffect(function () {
|
|
26
|
-
if (animationOpen && animationClose) {
|
|
27
|
-
setAnimationState(function () { return ({
|
|
28
|
-
className: isOpen ? animationOpen : animationClose,
|
|
29
|
-
}); });
|
|
30
|
-
}
|
|
31
|
-
}, [isOpen, animationOpen, animationClose]);
|
|
32
|
-
// Close dropdown by click outside
|
|
33
|
-
useEffect(function () {
|
|
34
|
-
// Add a handler to keep track of the click target.
|
|
35
|
-
function onClickWindow(event) {
|
|
36
|
-
var dropdownElement = dropdownRef.current;
|
|
37
|
-
if (dropdownElement && animationOpen) {
|
|
38
|
-
// Is event target inside of dropdown element
|
|
39
|
-
var isContainsTarget = dropdownElement.contains(event.target);
|
|
40
|
-
// Is dropdown element has "open" class
|
|
41
|
-
var hasOpenClass = dropdownElement.classList.contains(animationOpen);
|
|
42
|
-
if (!isContainsTarget && hasOpenClass) {
|
|
43
|
-
// Trigger close event with animation
|
|
44
|
-
// dropdownElement.click() - trigger "onClickWindow" again
|
|
45
|
-
setIsOpen(false);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
// Add event listener for current dropdown on first render
|
|
50
|
-
window.addEventListener('click', onClickWindow);
|
|
51
|
-
return function () {
|
|
52
|
-
// Remove event listener for current dropdown on unmount
|
|
53
|
-
window.removeEventListener('click', onClickWindow);
|
|
54
|
-
};
|
|
55
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
56
|
-
}, []);
|
|
57
|
-
var propsGenerator = useDevicePropsGenerator(props);
|
|
58
|
-
var alignmentClass = propsGenerator.alignmentClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, elevationClass = propsGenerator.elevationClass, shapeClass = propsGenerator.shapeClass;
|
|
59
|
-
// @ts-expect-error
|
|
60
|
-
var styles = useStyles(props).styles;
|
|
61
|
-
return (jsxs("div", { className: clsx(className, 'dropdown', alignmentClass && "alignment_".concat(alignmentClass), set && "dropdown_set_".concat(set), shapeClass && "dropdown_shape_".concat(shapeClass), elevationClass && "elevation_".concat(elevationClass), isOpen ? 'dropdown_state_open' : 'dropdown_state_close', animationState.className), ref: dropdownRef, style: styles, children: [before, children && (jsx("div", { className: clsx('dropdown__wrapper', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)),
|
|
62
|
-
// Add "onAnimationEnd" only for wrapper for ignore dropdown button
|
|
63
|
-
onAnimationEnd: onAnimationEnd, children: children })), after] }));
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
var dropdownItemAppearance = {
|
|
67
|
-
dev: {},
|
|
68
|
-
};
|
|
69
|
-
|
|
70
|
-
var dropdownItemConfig = {
|
|
71
|
-
appearance: dropdownItemAppearance,
|
|
72
|
-
setAppearance: function (appearanceConfig) {
|
|
73
|
-
dropdownItemConfig.appearance = appearanceConfig;
|
|
74
|
-
},
|
|
75
|
-
};
|
|
76
|
-
function DropdownItem(props) {
|
|
77
|
-
var className = props.className, appearance = props.appearance, label = props.label, labelTextAlign = props.labelTextAlign, labelTextColor = props.labelTextColor, labelTextColorActive = props.labelTextColorActive, labelTextColorHover = props.labelTextColorHover, labelTextGradient = props.labelTextGradient, labelTextSize = props.labelTextSize, labelTextStyle = props.labelTextStyle, labelTextWeight = props.labelTextWeight, labelTextWrap = props.labelTextWrap, desc = props.desc, descTextColor = props.descTextColor, descTextColorHover = props.descTextColorHover, descTextGradient = props.descTextGradient, descTextSize = props.descTextSize, descTextStyle = props.descTextStyle, descTextWeight = props.descTextWeight, descTextWrap = props.descTextWrap, dividerDirection = props.dividerDirection, dividerFill = props.dividerFill, dividerSize = props.dividerSize, href = props.href, link = props.link, linkFill = props.linkFill, rel = props.rel, showDivider = props.showDivider, target = props.target, underline = props.underline, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, set = props.set, onClick = props.onClick, onMouseEnter = props.onMouseEnter, children = props.children;
|
|
78
|
-
// prettier-ignore
|
|
79
|
-
var appearanceConfig = (dropdownItemConfig.appearance && dropdownItemConfig.appearance[appearance]);
|
|
80
|
-
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
81
|
-
var directionClass = propsGenerator.directionClass, justifyContentClass = propsGenerator.justifyContentClass, alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, fillDisabledClass = propsGenerator.fillDisabledClass, _a = propsGenerator.shapeClass, shapeClass = _a === void 0 ? 'l' : _a, sizeClass = propsGenerator.sizeClass, typeClass = propsGenerator.typeClass, _b = propsGenerator.widthClass, widthClass = _b === void 0 ? 'fixed' : _b;
|
|
82
|
-
// @ts-expect-error
|
|
83
|
-
var dropdownItem = useStyles(props).styles;
|
|
84
|
-
return (jsxs("div", { className: clsx('dropdown__item', isActive && 'dropdown__item_state_active', isHover && 'dropdown__item_state_hover', directionClass && "dropdown__item_direction_".concat(directionClass), className, fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), fillActiveClass && "fill_active_".concat(fillActiveClass), fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), typeClass && "dropdown__item_type_".concat(typeClass), widthClass && "dropdown__item_width_".concat(widthClass), onClick && 'cursor_type_pointer', set && "dropdown__item_set_".concat(set), justifyContentClass &&
|
|
85
|
-
"dropdown__item_justify-content_".concat(justifyContentClass)), style: dropdownItem, onClick: onClick, onMouseEnter: onMouseEnter, children: [jsx("div", { className: "dropdown__item-wrapper", children: jsx(Link, { className: clsx('dropdown__item-link', alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass)), fill: linkFill, href: link || href, rel: rel, target: target, underline: underline, children: jsxs(React.Fragment, { children: [before, children || (jsxs(React.Fragment, { children: [label && (jsx(Text, { className: "dropdown__item-label", size: labelTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextSize), textAlign: labelTextAlign, textColor: labelTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextColor), textColorActive: isActive ? labelTextColorActive : undefined, textColorGradient: labelTextGradient, textColorHover: labelTextColorHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })), desc && (jsx(Text, { className: "dropdown__item-desc", size: descTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextSize), textColor: descTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextColor), textColorGradient: descTextGradient, textColorHover: descTextColorHover, textStyle: descTextStyle, textWeight: descTextWeight, textWrap: descTextWrap, children: desc }))] })), after] }) }) }), showDivider && (jsx(Divider, { width: "fill", direction: dividerDirection, size: dividerSize, fill: dividerFill || 'surfaceTertiary' }))] }));
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
export { Dropdown as D, DropdownItem as a, dropdownItemConfig as b, dropdownItemAppearance as d };
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var React = require('react');
|
|
5
|
-
var clsx = require('clsx');
|
|
6
|
-
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
|
-
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
8
|
-
var Divider = require('./Divider-ImOOytuN.js');
|
|
9
|
-
var Link = require('./Link-BnqN6ysn.js');
|
|
10
|
-
var Text = require('./Text-C49zj3jO.js');
|
|
11
|
-
|
|
12
|
-
function Dropdown(props) {
|
|
13
|
-
var className = props.className, _a = props.animationClose, animationClose = _a === void 0 ? 'dropdown_animation_close' : _a, _b = props.animationOpen, animationOpen = _b === void 0 ? 'dropdown_animation_open' : _b, before = props.before, after = props.after, isOpen = props.isOpen, _c = props.set, set = _c === void 0 ? 'normal' : _c, setIsOpen = props.setIsOpen, children = props.children;
|
|
14
|
-
var dropdownRef = React.useRef(null);
|
|
15
|
-
// const [isOpen, setIsOpen] = useState(false)
|
|
16
|
-
var _d = React.useState({
|
|
17
|
-
className: '',
|
|
18
|
-
}), animationState = _d[0], setAnimationState = _d[1];
|
|
19
|
-
var onAnimationEnd = React.useCallback(function () {
|
|
20
|
-
// When component is change his visibility(display) in DOM,
|
|
21
|
-
// animation of close can run unnecessary on showing element.
|
|
22
|
-
// const dropdownElement = dropdownRef.current
|
|
23
|
-
setAnimationState(function (prevState) { return ({
|
|
24
|
-
className: isOpen ? prevState.className : '',
|
|
25
|
-
}); });
|
|
26
|
-
}, [isOpen]);
|
|
27
|
-
React.useEffect(function () {
|
|
28
|
-
if (animationOpen && animationClose) {
|
|
29
|
-
setAnimationState(function () { return ({
|
|
30
|
-
className: isOpen ? animationOpen : animationClose,
|
|
31
|
-
}); });
|
|
32
|
-
}
|
|
33
|
-
}, [isOpen, animationOpen, animationClose]);
|
|
34
|
-
// Close dropdown by click outside
|
|
35
|
-
React.useEffect(function () {
|
|
36
|
-
// Add a handler to keep track of the click target.
|
|
37
|
-
function onClickWindow(event) {
|
|
38
|
-
var dropdownElement = dropdownRef.current;
|
|
39
|
-
if (dropdownElement && animationOpen) {
|
|
40
|
-
// Is event target inside of dropdown element
|
|
41
|
-
var isContainsTarget = dropdownElement.contains(event.target);
|
|
42
|
-
// Is dropdown element has "open" class
|
|
43
|
-
var hasOpenClass = dropdownElement.classList.contains(animationOpen);
|
|
44
|
-
if (!isContainsTarget && hasOpenClass) {
|
|
45
|
-
// Trigger close event with animation
|
|
46
|
-
// dropdownElement.click() - trigger "onClickWindow" again
|
|
47
|
-
setIsOpen(false);
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
// Add event listener for current dropdown on first render
|
|
52
|
-
window.addEventListener('click', onClickWindow);
|
|
53
|
-
return function () {
|
|
54
|
-
// Remove event listener for current dropdown on unmount
|
|
55
|
-
window.removeEventListener('click', onClickWindow);
|
|
56
|
-
};
|
|
57
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
58
|
-
}, []);
|
|
59
|
-
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props);
|
|
60
|
-
var alignmentClass = propsGenerator.alignmentClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, elevationClass = propsGenerator.elevationClass, shapeClass = propsGenerator.shapeClass;
|
|
61
|
-
// @ts-expect-error
|
|
62
|
-
var styles = useStyles.useStyles(props).styles;
|
|
63
|
-
return (jsxRuntime.jsxs("div", { className: clsx(className, 'dropdown', alignmentClass && "alignment_".concat(alignmentClass), set && "dropdown_set_".concat(set), shapeClass && "dropdown_shape_".concat(shapeClass), elevationClass && "elevation_".concat(elevationClass), isOpen ? 'dropdown_state_open' : 'dropdown_state_close', animationState.className), ref: dropdownRef, style: styles, children: [before, children && (jsxRuntime.jsx("div", { className: clsx('dropdown__wrapper', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass)),
|
|
64
|
-
// Add "onAnimationEnd" only for wrapper for ignore dropdown button
|
|
65
|
-
onAnimationEnd: onAnimationEnd, children: children })), after] }));
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
var dropdownItemAppearance = {
|
|
69
|
-
dev: {},
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
var dropdownItemConfig = {
|
|
73
|
-
appearance: dropdownItemAppearance,
|
|
74
|
-
setAppearance: function (appearanceConfig) {
|
|
75
|
-
dropdownItemConfig.appearance = appearanceConfig;
|
|
76
|
-
},
|
|
77
|
-
};
|
|
78
|
-
function DropdownItem(props) {
|
|
79
|
-
var className = props.className, appearance = props.appearance, label = props.label, labelTextAlign = props.labelTextAlign, labelTextColor = props.labelTextColor, labelTextColorActive = props.labelTextColorActive, labelTextColorHover = props.labelTextColorHover, labelTextGradient = props.labelTextGradient, labelTextSize = props.labelTextSize, labelTextStyle = props.labelTextStyle, labelTextWeight = props.labelTextWeight, labelTextWrap = props.labelTextWrap, desc = props.desc, descTextColor = props.descTextColor, descTextColorHover = props.descTextColorHover, descTextGradient = props.descTextGradient, descTextSize = props.descTextSize, descTextStyle = props.descTextStyle, descTextWeight = props.descTextWeight, descTextWrap = props.descTextWrap, dividerDirection = props.dividerDirection, dividerFill = props.dividerFill, dividerSize = props.dividerSize, href = props.href, link = props.link, linkFill = props.linkFill, rel = props.rel, showDivider = props.showDivider, target = props.target, underline = props.underline, before = props.before, after = props.after, isActive = props.isActive, isHover = props.isHover, set = props.set, onClick = props.onClick, onMouseEnter = props.onMouseEnter, children = props.children;
|
|
80
|
-
// prettier-ignore
|
|
81
|
-
var appearanceConfig = (dropdownItemConfig.appearance && dropdownItemConfig.appearance[appearance]);
|
|
82
|
-
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
83
|
-
var directionClass = propsGenerator.directionClass, justifyContentClass = propsGenerator.justifyContentClass, alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, fillDisabledClass = propsGenerator.fillDisabledClass, _a = propsGenerator.shapeClass, shapeClass = _a === void 0 ? 'l' : _a, sizeClass = propsGenerator.sizeClass, typeClass = propsGenerator.typeClass, _b = propsGenerator.widthClass, widthClass = _b === void 0 ? 'fixed' : _b;
|
|
84
|
-
// @ts-expect-error
|
|
85
|
-
var dropdownItem = useStyles.useStyles(props).styles;
|
|
86
|
-
return (jsxRuntime.jsxs("div", { className: clsx('dropdown__item', isActive && 'dropdown__item_state_active', isHover && 'dropdown__item_state_hover', directionClass && "dropdown__item_direction_".concat(directionClass), className, fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), fillActiveClass && "fill_active_".concat(fillActiveClass), fillActiveHoverClass && "fill_active_hover_".concat(fillActiveHoverClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), sizeClass && "dropdown__item_size_".concat(sizeClass), shapeClass && "dropdown__item_shape_".concat(shapeClass), typeClass && "dropdown__item_type_".concat(typeClass), widthClass && "dropdown__item_width_".concat(widthClass), onClick && 'cursor_type_pointer', set && "dropdown__item_set_".concat(set), justifyContentClass &&
|
|
87
|
-
"dropdown__item_justify-content_".concat(justifyContentClass)), style: dropdownItem, onClick: onClick, onMouseEnter: onMouseEnter, children: [jsxRuntime.jsx("div", { className: "dropdown__item-wrapper", children: jsxRuntime.jsx(Link.Link, { className: clsx('dropdown__item-link', alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass)), fill: linkFill, href: link || href, rel: rel, target: target, underline: underline, children: jsxRuntime.jsxs(React.Fragment, { children: [before, children || (jsxRuntime.jsxs(React.Fragment, { children: [label && (jsxRuntime.jsx(Text.Text, { className: "dropdown__item-label", size: labelTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextSize), textAlign: labelTextAlign, textColor: labelTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.labelTextColor), textColorActive: isActive ? labelTextColorActive : undefined, textColorGradient: labelTextGradient, textColorHover: labelTextColorHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })), desc && (jsxRuntime.jsx(Text.Text, { className: "dropdown__item-desc", size: descTextSize || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextSize), textColor: descTextColor || (appearanceConfig === null || appearanceConfig === void 0 ? void 0 : appearanceConfig.descTextColor), textColorGradient: descTextGradient, textColorHover: descTextColorHover, textStyle: descTextStyle, textWeight: descTextWeight, textWrap: descTextWrap, children: desc }))] })), after] }) }) }), showDivider && (jsxRuntime.jsx(Divider.Divider, { width: "fill", direction: dividerDirection, size: dividerSize, fill: dividerFill || 'surfaceTertiary' }))] }));
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
exports.Dropdown = Dropdown;
|
|
91
|
-
exports.DropdownItem = DropdownItem;
|
|
92
|
-
exports.dropdownItemAppearance = dropdownItemAppearance;
|
|
93
|
-
exports.dropdownItemConfig = dropdownItemConfig;
|
package/dist/Icon-OJ_3E3eM.js
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { _ as __assign } from './tslib.es6-5FtW-kfi.js';
|
|
2
|
-
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
|
-
import React, { useMemo } from 'react';
|
|
4
|
-
import clsx from 'clsx';
|
|
5
|
-
import SVG from 'react-inlinesvg';
|
|
6
|
-
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
|
-
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
8
|
-
import { L as LinkWrapper } from './Link-DaKqf1pb.js';
|
|
9
|
-
import { T as Tooltip } from './Tooltip-5lQyt5-Y.js';
|
|
10
|
-
|
|
11
|
-
var iconAppearance = {
|
|
12
|
-
accent: {
|
|
13
|
-
fill: 'accentPrimary',
|
|
14
|
-
fillHover: 'accentPrimaryHover',
|
|
15
|
-
fillSize: 40,
|
|
16
|
-
iconFill: 'accentItemPrimary',
|
|
17
|
-
iconSize: 24,
|
|
18
|
-
imageSrc: 'img/filter.svg',
|
|
19
|
-
},
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
var iconConfig = {
|
|
23
|
-
appearance: iconAppearance,
|
|
24
|
-
setAppearance: function (appearanceConfig) {
|
|
25
|
-
iconConfig.appearance = appearanceConfig;
|
|
26
|
-
},
|
|
27
|
-
};
|
|
28
|
-
var Icon = React.forwardRef(function Icon(props, ref) {
|
|
29
|
-
// TODO: Tooltip doesn't work that anymore
|
|
30
|
-
// const [isTooltipVisible, setIsTooltipVisible] = useState(false)
|
|
31
|
-
var id = props.id, width = props.width, height = props.height, after = props.after, Badge = props.Badge, before = props.before, className = props.className, dataTour = props.dataTour, href = props.href, imageSrc = props.imageSrc, link = props.link, linkRel = props.linkRel, linkTarget = props.linkTarget, showTooltip = props.showTooltip, SvgImage = props.SvgImage, tooltipAppearance = props.tooltipAppearance, tooltipText = props.tooltipText, tooltipTextSize = props.tooltipTextSize, tooltipTitle = props.tooltipTitle, tooltipTitleSize = props.tooltipTitleSize, onClick = props.onClick, onMouseEnter = props.onMouseEnter, onMouseLeave = props.onMouseLeave;
|
|
32
|
-
var ImageComponent = useMemo(function () {
|
|
33
|
-
if (SvgImage) {
|
|
34
|
-
var sizes = {};
|
|
35
|
-
if (width) {
|
|
36
|
-
sizes.width = width;
|
|
37
|
-
}
|
|
38
|
-
if (height) {
|
|
39
|
-
sizes.height = height;
|
|
40
|
-
}
|
|
41
|
-
return jsx(SvgImage, __assign({}, sizes));
|
|
42
|
-
}
|
|
43
|
-
if (imageSrc) {
|
|
44
|
-
if (imageSrc.endsWith('.svg')) {
|
|
45
|
-
return jsx(SVG, { preProcessor: removeFillStroke, src: imageSrc });
|
|
46
|
-
}
|
|
47
|
-
return jsx("img", { src: imageSrc });
|
|
48
|
-
}
|
|
49
|
-
return null;
|
|
50
|
-
}, [SvgImage, width, height, imageSrc]);
|
|
51
|
-
var propsGenerator = useDevicePropsGenerator(props);
|
|
52
|
-
var alignmentClass = propsGenerator.alignmentClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, cursorClass = propsGenerator.cursorClass, fillClass = propsGenerator.fillClass, fillDisabledClass = propsGenerator.fillDisabledClass, fillHoverClass = propsGenerator.fillHoverClass, fillSizeClass = propsGenerator.fillSizeClass, iconFillClass = propsGenerator.iconFillClass, iconFillDisabledClass = propsGenerator.iconFillDisabledClass, iconFillHoverClass = propsGenerator.iconFillHoverClass, iconSizeClass = propsGenerator.iconSizeClass, shapeClass = propsGenerator.shapeClass;
|
|
53
|
-
// @ts-expect-error
|
|
54
|
-
var iconStyles = useStyles(props).styles;
|
|
55
|
-
return (jsxs("div", { className: clsx(className, 'icon', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), fillSizeClass && "icon_fill_size_".concat(fillSizeClass), fillDisabledClass && "fill_disabled_".concat(fillDisabledClass), iconFillClass && "icon_fill_".concat(iconFillClass), iconFillHoverClass && "icon_fill_hover_".concat(iconFillHoverClass), iconFillDisabledClass && "icon_fill_disabled_".concat(iconFillDisabledClass), shapeClass && "icon_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), Badge && 'icon_type_with-badge', onClick && cursorClass && "cursor_".concat(cursorClass)), ref: ref, "data-tour": dataTour, id: id, style: iconStyles, onClick: onClick, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave, children: [before, jsxs(LinkWrapper, { className: clsx((link || href || onClick) && 'cursor_type_pointer', link || href ? 'icon__link' : 'icon__item', iconSizeClass && "icon_size_".concat(iconSizeClass)), DefaultComponent: "div", href: link || href, rel: linkRel, target: linkTarget, children: [ImageComponent, Badge, showTooltip && (jsx(Tooltip, { className: clsx(className, 'icon__tooltip', alignmentClass && "alignment_".concat(alignmentClass)), appearance: tooltipAppearance, text: tooltipText, textSize: tooltipTextSize, title: tooltipTitle, titleSize: tooltipTitleSize }))] }), after] }));
|
|
56
|
-
});
|
|
57
|
-
var removeFillStroke = function (code) {
|
|
58
|
-
return code.replace(/fill=".*?"/g, 'fill=""').replace(/stroke=".*?"/g, 'stroke=""');
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
export { Icon as I, iconAppearance as a, iconConfig as i };
|
package/dist/Image-BEGwuGBM.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var clsx = require('clsx');
|
|
5
|
-
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
6
|
-
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
7
|
-
|
|
8
|
-
function Image(props) {
|
|
9
|
-
var children = props.children, after = props.after, alt = props.alt, before = props.before, caption = props.caption, className = props.className, imageClassName = props.imageClassName, imageWrapperClassName = props.imageWrapperClassName, mode = props.mode, overlay = props.overlay, src = props.src, title = props.title, type = props.type, onClick = props.onClick, onError = props.onError;
|
|
10
|
-
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props);
|
|
11
|
-
var borderColorClass = propsGenerator.borderColorClass, borderColorImageClass = propsGenerator.borderColorImageClass, cursorClass = propsGenerator.cursorClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, heightClass = propsGenerator.heightClass, horizontalAlignClass = propsGenerator.horizontalAlignClass, imageHeightClass = propsGenerator.imageHeightClass, imageWidthClass = propsGenerator.imageWidthClass, resizeModeClass = propsGenerator.resizeModeClass, shapeClass = propsGenerator.shapeClass, verticalAlignClass = propsGenerator.verticalAlignClass, widthClass = propsGenerator.widthClass;
|
|
12
|
-
// @ts-expect-error
|
|
13
|
-
var _a = useStyles.useStyles(props), imageStyles = _a.image, styles = _a.styles, wrapperStyles = _a.wrapper;
|
|
14
|
-
return (jsxRuntime.jsxs("div", { className: clsx(className, 'image', mode && "image_mode_".concat(mode), type && "image_type_".concat(type), cursorClass && "cursor_".concat(cursorClass), horizontalAlignClass && "image_horizontal-align_".concat(horizontalAlignClass), verticalAlignClass && "image_vertical-align_".concat(verticalAlignClass), shapeClass && "image_shape_".concat(shapeClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), resizeModeClass && "image_resize-mode_".concat(resizeModeClass), widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass)), style: styles, onClick: onClick, children: [before, jsxRuntime.jsxs("div", { className: clsx('image__wrapper', imageWrapperClassName), style: wrapperStyles, children: [jsxRuntime.jsx("img", { className: clsx('image__item', imageWidthClass && "width_".concat(imageWidthClass), imageHeightClass && "height_".concat(imageHeightClass), imageClassName, borderColorClass && "border-color_".concat(borderColorClass), borderColorImageClass && "border-color-image_".concat(borderColorImageClass)), alt: alt || title, src: src, style: imageStyles, title: title || alt, onError: onError }), overlay, caption, children] }), after] }));
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
exports.Image = Image;
|
package/dist/Image-DWfyapuD.js
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
-
import clsx from 'clsx';
|
|
3
|
-
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
4
|
-
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
5
|
-
|
|
6
|
-
function Image(props) {
|
|
7
|
-
var children = props.children, after = props.after, alt = props.alt, before = props.before, caption = props.caption, className = props.className, imageClassName = props.imageClassName, imageWrapperClassName = props.imageWrapperClassName, mode = props.mode, overlay = props.overlay, src = props.src, title = props.title, type = props.type, onClick = props.onClick, onError = props.onError;
|
|
8
|
-
var propsGenerator = useDevicePropsGenerator(props);
|
|
9
|
-
var borderColorClass = propsGenerator.borderColorClass, borderColorImageClass = propsGenerator.borderColorImageClass, cursorClass = propsGenerator.cursorClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, heightClass = propsGenerator.heightClass, horizontalAlignClass = propsGenerator.horizontalAlignClass, imageHeightClass = propsGenerator.imageHeightClass, imageWidthClass = propsGenerator.imageWidthClass, resizeModeClass = propsGenerator.resizeModeClass, shapeClass = propsGenerator.shapeClass, verticalAlignClass = propsGenerator.verticalAlignClass, widthClass = propsGenerator.widthClass;
|
|
10
|
-
// @ts-expect-error
|
|
11
|
-
var _a = useStyles(props), imageStyles = _a.image, styles = _a.styles, wrapperStyles = _a.wrapper;
|
|
12
|
-
return (jsxs("div", { className: clsx(className, 'image', mode && "image_mode_".concat(mode), type && "image_type_".concat(type), cursorClass && "cursor_".concat(cursorClass), horizontalAlignClass && "image_horizontal-align_".concat(horizontalAlignClass), verticalAlignClass && "image_vertical-align_".concat(verticalAlignClass), shapeClass && "image_shape_".concat(shapeClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), resizeModeClass && "image_resize-mode_".concat(resizeModeClass), widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass)), style: styles, onClick: onClick, children: [before, jsxs("div", { className: clsx('image__wrapper', imageWrapperClassName), style: wrapperStyles, children: [jsx("img", { className: clsx('image__item', imageWidthClass && "width_".concat(imageWidthClass), imageHeightClass && "height_".concat(imageHeightClass), imageClassName, borderColorClass && "border-color_".concat(borderColorClass), borderColorImageClass && "border-color-image_".concat(borderColorImageClass)), alt: alt || title, src: src, style: imageStyles, title: title || alt, onError: onError }), overlay, caption, children] }), after] }));
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export { Image as I };
|
package/dist/stories/Dev.mdx
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type tAppearanceKeysDefault = 'accent' | 'accentPrimary' | 'accentQuaternary' | 'accentSecondary' | 'accentTertiary' | 'any' | 'cantLoadData' | 'confirm' | 'custom' | 'default' | 'disabled' | 'error' | 'fail' | 'full' | 'ghost' | 'gradientPrimary' | 'nothingFound' | 'outlined' | 'primary' | 'refresh' | 'search' | 'secondary' | 'solid' | 'success' | 'surface' | 'surfaceDisabled' | 'surfacePrimary' | 'surfaceQuaternary' | 'surfaceSecondary' | 'surfaceTertiary' | 'unableLoadData' | 'warning';
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
declare const borderColorProps: readonly ["accentBorderPrimary", "accentBorderSecondary", "accentBorderTertiary", "accentBorderQuaternary", "accentBorderDisabled", "primaryBorderPrimary", "primaryBorderSecondary", "primaryBorderTertiary", "primaryBorderQuaternary", "primaryBorderDisabled", "secondaryBorderPrimary", "secondaryBorderSecondary", "secondaryBorderTertiary", "secondaryBorderQuaternary", "secondaryBorderDisabled", "tertiaryBorderPrimary", "tertiaryBorderSecondary", "tertiaryBorderTertiary", "tertiaryBorderQuaternary", "tertiaryBorderDisabled", "surfaceBorderPrimary", "surfaceBorderSecondary", "surfaceBorderTertiary", "surfaceBorderQuaternary", "surfaceBorderDisabled", "surfaceBorderInverse", "errorBorderPrimary", "errorBorderSecondary", "errorBorderDisabled", "successBorderPrimary", "successBorderSecondary", "successBorderDisabled", "none"];
|
|
2
|
-
export type tBorderColorProps = (typeof borderColorProps)[number];
|
|
3
|
-
export { borderColorProps };
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
declare const borderColorHoverProps: readonly ["accentBorderPrimary", "accentBorderPrimaryHover", "primaryBorderPrimary", "secondaryBorderPrimary", "tertiaryBorderPrimary", "surfaceBorderPrimary", "surfaceBorderSecondary", "surfaceBorderTertiary", "errorBorderPrimary", "errorBorderPrimaryHover", "successBorderPrimary", "surfaceBorderQuaternary"];
|
|
2
|
-
export type tBorderColorHoverProps = (typeof borderColorHoverProps)[number];
|
|
3
|
-
export { borderColorHoverProps };
|