@megafon/ui-shared 6.4.0 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/es/components/AccordionBox/AccordionBox.css +1 -15
- package/dist/es/components/AccordionBox/AccordionBox.d.ts +2 -2
- package/dist/es/components/AccordionBox/AccordionBox.js +6 -49
- package/dist/es/components/AudioPlayer/AudioPlayer.d.ts +2 -2
- package/dist/es/components/AudioPlayer/AudioPlayer.js +11 -27
- package/dist/es/components/AudioPlayer/AudioProgress.d.ts +1 -1
- package/dist/es/components/AudioPlayer/AudioProgress.js +10 -22
- package/dist/es/components/AudioPlayer/AudioRange.d.ts +1 -1
- package/dist/es/components/AudioPlayer/AudioRange.js +8 -10
- package/dist/es/components/AudioPlayer/AudioVolume.d.ts +1 -1
- package/dist/es/components/AudioPlayer/AudioVolume.js +3 -12
- package/dist/es/components/AudioPlayer/hooks/useTrackDuration.js +4 -10
- package/dist/es/components/AudioPlayer/style/AudioPlayer.css +1 -58
- package/dist/es/components/AudioPlayer/style/AudioProgress.css +1 -35
- package/dist/es/components/AudioPlayer/style/AudioRange.css +1 -68
- package/dist/es/components/AudioPlayer/style/AudioVolume.css +1 -34
- package/dist/es/components/AudioPlayer/timerFormatUtil.js +1 -9
- package/dist/es/components/BannerBox/BannerBox.d.ts +1 -1
- package/dist/es/components/BannerBox/BannerBox.js +3 -12
- package/dist/es/components/BenefitsIcons/BenefitsIcons.d.ts +1 -1
- package/dist/es/components/BenefitsIcons/BenefitsIcons.js +23 -64
- package/dist/es/components/BenefitsIcons/BenefitsIconsTile.d.ts +1 -1
- package/dist/es/components/BenefitsIcons/BenefitsIconsTile.js +9 -36
- package/dist/es/components/BenefitsIcons/helpers.d.ts +3 -3
- package/dist/es/components/BenefitsIcons/helpers.js +6 -20
- package/dist/es/components/BenefitsIcons/style/BenefitsIcons.css +1 -38
- package/dist/es/components/BenefitsIcons/style/BenefitsIconsTile.css +1 -90
- package/dist/es/components/BenefitsIcons/types.d.ts +5 -6
- package/dist/es/components/BenefitsPictures/BenefitsPictures.d.ts +1 -1
- package/dist/es/components/BenefitsPictures/BenefitsPictures.js +19 -49
- package/dist/es/components/BenefitsPictures/BenfitsPictures.css +1 -43
- package/dist/es/components/BenefitsPictures/helpers.js +0 -14
- package/dist/es/components/BenefitsPictures/types.d.ts +3 -4
- package/dist/es/components/BenefitsPictures/types.js +1 -0
- package/dist/es/components/BlogBox/BlogBox.css +1 -92
- package/dist/es/components/BlogBox/BlogBox.d.ts +2 -2
- package/dist/es/components/BlogBox/BlogBox.js +10 -44
- package/dist/es/components/BlogBox/components/BlogBoxTile.css +1 -197
- package/dist/es/components/BlogBox/components/BlogBoxTile.d.ts +4 -4
- package/dist/es/components/BlogBox/components/BlogBoxTile.js +13 -20
- package/dist/es/components/BlogBox/types.d.ts +5 -5
- package/dist/es/components/BlogBox/types.js +1 -0
- package/dist/es/components/Breadcrumbs/Breadcrumbs.css +1 -43
- package/dist/es/components/Breadcrumbs/Breadcrumbs.d.ts +6 -6
- package/dist/es/components/Breadcrumbs/Breadcrumbs.js +10 -39
- package/dist/es/components/Breadcrumbs/components/BreadcrumbsItem.css +1 -16
- package/dist/es/components/Breadcrumbs/components/BreadcrumbsItem.d.ts +4 -4
- package/dist/es/components/Breadcrumbs/components/BreadcrumbsItem.js +11 -36
- package/dist/es/components/ButtonBanner/ButtonBanner.css +1 -122
- package/dist/es/components/ButtonBanner/ButtonBanner.d.ts +7 -7
- package/dist/es/components/ButtonBanner/ButtonBanner.js +22 -53
- package/dist/es/components/ButtonLinkBox/ButtonLinkBox.css +1 -19
- package/dist/es/components/ButtonLinkBox/ButtonLinkBox.d.ts +3 -3
- package/dist/es/components/ButtonLinkBox/ButtonLinkBox.js +20 -51
- package/dist/es/components/Card/Card.css +1 -354
- package/dist/es/components/Card/Card.d.ts +4 -4
- package/dist/es/components/Card/Card.js +25 -115
- package/dist/es/components/Card/types.d.ts +10 -11
- package/dist/es/components/Card/types.js +1 -0
- package/dist/es/components/CardsBox/CardsBox.js +3 -14
- package/dist/es/components/CardsBox/helpers.d.ts +2 -2
- package/dist/es/components/CardsBox/helpers.js +0 -4
- package/dist/es/components/CarouselBox/CarouselBox.d.ts +2 -2
- package/dist/es/components/CarouselBox/CarouselBox.js +11 -24
- package/dist/es/components/Container/Container.css +1 -4178
- package/dist/es/components/Container/Container.d.ts +7 -5
- package/dist/es/components/Container/Container.js +10 -25
- package/dist/es/components/DownloadLinks/DownloadLink.css +1 -37
- package/dist/es/components/DownloadLinks/DownloadLink.d.ts +1 -1
- package/dist/es/components/DownloadLinks/DownloadLink.js +13 -44
- package/dist/es/components/DownloadLinks/DownloadLinks.css +1 -36
- package/dist/es/components/DownloadLinks/DownloadLinks.d.ts +3 -3
- package/dist/es/components/DownloadLinks/DownloadLinks.js +2 -13
- package/dist/es/components/FaqWrapper/FaqWrapper.d.ts +5 -2
- package/dist/es/components/FaqWrapper/FaqWrapper.js +1 -3
- package/dist/es/components/ImageBanner/ImageBanner.css +1 -252
- package/dist/es/components/ImageBanner/ImageBanner.d.ts +8 -7
- package/dist/es/components/ImageBanner/ImageBanner.js +37 -88
- package/dist/es/components/InfoCards/InfoCards.css +1 -75
- package/dist/es/components/InfoCards/InfoCards.d.ts +1 -1
- package/dist/es/components/InfoCards/InfoCards.js +10 -37
- package/dist/es/components/InfoCards/components/InfoCard/InfoCard.css +1 -237
- package/dist/es/components/InfoCards/components/InfoCard/InfoCard.d.ts +1 -1
- package/dist/es/components/InfoCards/components/InfoCard/InfoCard.js +17 -46
- package/dist/es/components/InfoCards/types.js +1 -0
- package/dist/es/components/Instructions/Instructions.css +1 -827
- package/dist/es/components/Instructions/Instructions.d.ts +11 -11
- package/dist/es/components/Instructions/Instructions.js +56 -96
- package/dist/es/components/NotificationBox/NotificationBox.css +1 -0
- package/dist/es/components/NotificationBox/NotificationBox.d.ts +4 -4
- package/dist/es/components/NotificationBox/NotificationBox.js +5 -19
- package/dist/es/components/PageTitle/PageTitle.css +1 -80
- package/dist/es/components/PageTitle/PageTitle.d.ts +2 -2
- package/dist/es/components/PageTitle/PageTitle.js +12 -37
- package/dist/es/components/Partners/Partners.css +1 -53
- package/dist/es/components/Partners/Partners.d.ts +2 -2
- package/dist/es/components/Partners/Partners.js +17 -48
- package/dist/es/components/PictureWithDescription/PictureWithDescription.css +1 -80
- package/dist/es/components/PictureWithDescription/PictureWithDescription.d.ts +4 -2
- package/dist/es/components/PictureWithDescription/PictureWithDescription.js +10 -28
- package/dist/es/components/Property/Property.css +1 -156
- package/dist/es/components/Property/Property.d.ts +4 -4
- package/dist/es/components/Property/Property.js +37 -81
- package/dist/es/components/Property/PropertyDescription.css +1 -17
- package/dist/es/components/Property/PropertyDescription.d.ts +3 -3
- package/dist/es/components/Property/PropertyDescription.js +8 -28
- package/dist/es/components/Property/types.d.ts +7 -5
- package/dist/es/components/Property/types.js +1 -0
- package/dist/es/components/SidePictureCards/SidePictureCards.d.ts +1 -1
- package/dist/es/components/SidePictureCards/SidePictureCards.js +8 -41
- package/dist/es/components/SidePictureCards/components/SidePictureCard.css +1 -183
- package/dist/es/components/SidePictureCards/components/SidePictureCard.d.ts +2 -2
- package/dist/es/components/SidePictureCards/components/SidePictureCard.js +21 -23
- package/dist/es/components/SidePictureCards/types.d.ts +8 -8
- package/dist/es/components/SidePictureCards/types.js +1 -0
- package/dist/es/components/Steps/Steps.css +1 -41
- package/dist/es/components/Steps/Steps.d.ts +2 -1
- package/dist/es/components/Steps/Steps.js +4 -19
- package/dist/es/components/Steps/StepsItem.css +1 -42
- package/dist/es/components/Steps/StepsItem.d.ts +2 -2
- package/dist/es/components/Steps/StepsItem.js +2 -9
- package/dist/es/components/StoreBanner/StoreBanner.css +1 -346
- package/dist/es/components/StoreBanner/StoreBanner.d.ts +5 -5
- package/dist/es/components/StoreBanner/StoreBanner.js +41 -97
- package/dist/es/components/StoreButton/StoreButton.css +1 -327
- package/dist/es/components/StoreButton/StoreButton.d.ts +3 -3
- package/dist/es/components/StoreButton/StoreButton.js +13 -44
- package/dist/es/components/Table/Table.css +1 -157
- package/dist/es/components/Table/Table.d.ts +1 -1
- package/dist/es/components/Table/Table.js +31 -51
- package/dist/es/components/Table/TableCell.js +0 -6
- package/dist/es/components/Table/TableRow.js +1 -10
- package/dist/es/components/TabsBox/TabsBox.d.ts +1 -1
- package/dist/es/components/TabsBox/TabsBox.js +4 -13
- package/dist/es/components/TextBox/TextBox.css +1 -25
- package/dist/es/components/TextBox/TextBox.d.ts +2 -1
- package/dist/es/components/TextBox/TextBox.js +8 -23
- package/dist/es/components/TextBox/TextBoxPicture.css +1 -27
- package/dist/es/components/TextBox/TextBoxPicture.d.ts +2 -2
- package/dist/es/components/TextBox/TextBoxPicture.js +5 -14
- package/dist/es/components/TextWithIcon/TextWithIcon.css +1 -10
- package/dist/es/components/TextWithIcon/TextWithIcon.d.ts +1 -1
- package/dist/es/components/TextWithIcon/TextWithIcon.js +6 -24
- package/dist/es/components/TextWithIcon/TextWithIconItem.css +1 -38
- package/dist/es/components/TextWithIcon/TextWithIconItem.d.ts +1 -1
- package/dist/es/components/TextWithIcon/TextWithIconItem.js +8 -24
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.css +1 -31
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.d.ts +1 -1
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.js +6 -23
- package/dist/es/components/VideoBanner/VideoBanner.css +1 -225
- package/dist/es/components/VideoBanner/VideoBanner.d.ts +7 -7
- package/dist/es/components/VideoBanner/VideoBanner.js +47 -110
- package/dist/es/components/VideoBlock/VideoBlock.css +1 -106
- package/dist/es/components/VideoBlock/VideoBlock.d.ts +4 -4
- package/dist/es/components/VideoBlock/VideoBlock.js +37 -77
- package/dist/es/helpers/getColumnConfig.d.ts +5 -1
- package/dist/es/helpers/setRelAttribute.d.ts +3 -1
- package/dist/es/helpers/setRelAttribute.js +0 -2
- package/dist/es/hooks/useResolutions.d.ts +1 -1
- package/dist/es/hooks/useResolutions.js +13 -21
- package/dist/lib/components/AccordionBox/AccordionBox.css +1 -15
- package/dist/lib/components/AccordionBox/AccordionBox.d.ts +2 -2
- package/dist/lib/components/AccordionBox/AccordionBox.js +11 -67
- package/dist/lib/components/AudioPlayer/AudioPlayer.d.ts +2 -2
- package/dist/lib/components/AudioPlayer/AudioPlayer.js +33 -57
- package/dist/lib/components/AudioPlayer/AudioProgress.d.ts +1 -1
- package/dist/lib/components/AudioPlayer/AudioProgress.js +13 -44
- package/dist/lib/components/AudioPlayer/AudioRange.d.ts +1 -1
- package/dist/lib/components/AudioPlayer/AudioRange.js +10 -18
- package/dist/lib/components/AudioPlayer/AudioVolume.d.ts +1 -1
- package/dist/lib/components/AudioPlayer/AudioVolume.js +5 -24
- package/dist/lib/components/AudioPlayer/hooks/useTrackDuration.js +6 -17
- package/dist/lib/components/AudioPlayer/style/AudioPlayer.css +1 -58
- package/dist/lib/components/AudioPlayer/style/AudioProgress.css +1 -35
- package/dist/lib/components/AudioPlayer/style/AudioRange.css +1 -68
- package/dist/lib/components/AudioPlayer/style/AudioVolume.css +1 -34
- package/dist/lib/components/AudioPlayer/timerFormatUtil.js +2 -13
- package/dist/lib/components/BannerBox/BannerBox.d.ts +1 -1
- package/dist/lib/components/BannerBox/BannerBox.js +7 -25
- package/dist/lib/components/BenefitsIcons/BenefitsIcons.d.ts +1 -1
- package/dist/lib/components/BenefitsIcons/BenefitsIcons.js +27 -87
- package/dist/lib/components/BenefitsIcons/BenefitsIconsTile.d.ts +1 -1
- package/dist/lib/components/BenefitsIcons/BenefitsIconsTile.js +14 -54
- package/dist/lib/components/BenefitsIcons/helpers.d.ts +3 -3
- package/dist/lib/components/BenefitsIcons/helpers.js +11 -38
- package/dist/lib/components/BenefitsIcons/style/BenefitsIcons.css +1 -38
- package/dist/lib/components/BenefitsIcons/style/BenefitsIconsTile.css +1 -90
- package/dist/lib/components/BenefitsIcons/types.d.ts +5 -6
- package/dist/lib/components/BenefitsIcons/types.js +5 -8
- package/dist/lib/components/BenefitsPictures/BenefitsPictures.d.ts +1 -1
- package/dist/lib/components/BenefitsPictures/BenefitsPictures.js +25 -72
- package/dist/lib/components/BenefitsPictures/BenfitsPictures.css +1 -43
- package/dist/lib/components/BenefitsPictures/helpers.js +10 -41
- package/dist/lib/components/BenefitsPictures/types.d.ts +3 -4
- package/dist/lib/components/BenefitsPictures/types.js +5 -1
- package/dist/lib/components/BlogBox/BlogBox.css +1 -92
- package/dist/lib/components/BlogBox/BlogBox.d.ts +2 -2
- package/dist/lib/components/BlogBox/BlogBox.js +21 -65
- package/dist/lib/components/BlogBox/components/BlogBoxTile.css +1 -197
- package/dist/lib/components/BlogBox/components/BlogBoxTile.d.ts +4 -4
- package/dist/lib/components/BlogBox/components/BlogBoxTile.js +27 -38
- package/dist/lib/components/BlogBox/types.d.ts +5 -5
- package/dist/lib/components/BlogBox/types.js +5 -1
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.css +1 -43
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.d.ts +6 -6
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.js +19 -61
- package/dist/lib/components/Breadcrumbs/components/BreadcrumbsItem.css +1 -16
- package/dist/lib/components/Breadcrumbs/components/BreadcrumbsItem.d.ts +4 -4
- package/dist/lib/components/Breadcrumbs/components/BreadcrumbsItem.js +23 -56
- package/dist/lib/components/ButtonBanner/ButtonBanner.css +1 -122
- package/dist/lib/components/ButtonBanner/ButtonBanner.d.ts +7 -7
- package/dist/lib/components/ButtonBanner/ButtonBanner.js +41 -90
- package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.css +1 -19
- package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.d.ts +3 -3
- package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.js +30 -73
- package/dist/lib/components/Card/Card.css +1 -354
- package/dist/lib/components/Card/Card.d.ts +4 -4
- package/dist/lib/components/Card/Card.js +68 -165
- package/dist/lib/components/Card/types.d.ts +10 -11
- package/dist/lib/components/Card/types.js +5 -1
- package/dist/lib/components/CardsBox/CardsBox.js +8 -32
- package/dist/lib/components/CardsBox/helpers.d.ts +2 -2
- package/dist/lib/components/CardsBox/helpers.js +2 -9
- package/dist/lib/components/CarouselBox/CarouselBox.d.ts +2 -2
- package/dist/lib/components/CarouselBox/CarouselBox.js +16 -40
- package/dist/lib/components/Container/Container.css +1 -4178
- package/dist/lib/components/Container/Container.d.ts +7 -5
- package/dist/lib/components/Container/Container.js +18 -40
- package/dist/lib/components/DownloadLinks/DownloadLink.css +1 -37
- package/dist/lib/components/DownloadLinks/DownloadLink.d.ts +1 -1
- package/dist/lib/components/DownloadLinks/DownloadLink.js +18 -61
- package/dist/lib/components/DownloadLinks/DownloadLinks.css +1 -36
- package/dist/lib/components/DownloadLinks/DownloadLinks.d.ts +3 -3
- package/dist/lib/components/DownloadLinks/DownloadLinks.js +9 -34
- package/dist/lib/components/FaqWrapper/FaqWrapper.d.ts +5 -2
- package/dist/lib/components/FaqWrapper/FaqWrapper.js +6 -9
- package/dist/lib/components/ImageBanner/ImageBanner.css +1 -252
- package/dist/lib/components/ImageBanner/ImageBanner.d.ts +8 -7
- package/dist/lib/components/ImageBanner/ImageBanner.js +62 -139
- package/dist/lib/components/InfoCards/InfoCards.css +1 -75
- package/dist/lib/components/InfoCards/InfoCards.d.ts +1 -1
- package/dist/lib/components/InfoCards/InfoCards.js +15 -55
- package/dist/lib/components/InfoCards/components/InfoCard/InfoCard.css +1 -237
- package/dist/lib/components/InfoCards/components/InfoCard/InfoCard.d.ts +1 -1
- package/dist/lib/components/InfoCards/components/InfoCard/InfoCard.js +22 -63
- package/dist/lib/components/InfoCards/types.js +5 -1
- package/dist/lib/components/Instructions/Instructions.css +1 -827
- package/dist/lib/components/Instructions/Instructions.d.ts +11 -11
- package/dist/lib/components/Instructions/Instructions.js +121 -191
- package/dist/lib/components/NotificationBox/NotificationBox.css +1 -0
- package/dist/lib/components/NotificationBox/NotificationBox.d.ts +4 -4
- package/dist/lib/components/NotificationBox/NotificationBox.js +10 -38
- package/dist/lib/components/PageTitle/PageTitle.css +1 -80
- package/dist/lib/components/PageTitle/PageTitle.d.ts +2 -2
- package/dist/lib/components/PageTitle/PageTitle.js +16 -53
- package/dist/lib/components/Partners/Partners.css +1 -53
- package/dist/lib/components/Partners/Partners.d.ts +2 -2
- package/dist/lib/components/Partners/Partners.js +22 -66
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.css +1 -80
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.d.ts +4 -2
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.js +16 -46
- package/dist/lib/components/Property/Property.css +1 -156
- package/dist/lib/components/Property/Property.d.ts +4 -4
- package/dist/lib/components/Property/Property.js +61 -121
- package/dist/lib/components/Property/PropertyDescription.css +1 -17
- package/dist/lib/components/Property/PropertyDescription.d.ts +3 -3
- package/dist/lib/components/Property/PropertyDescription.js +16 -47
- package/dist/lib/components/Property/types.d.ts +7 -5
- package/dist/lib/components/Property/types.js +5 -1
- package/dist/lib/components/SidePictureCards/SidePictureCards.d.ts +1 -1
- package/dist/lib/components/SidePictureCards/SidePictureCards.js +17 -58
- package/dist/lib/components/SidePictureCards/components/SidePictureCard.css +1 -183
- package/dist/lib/components/SidePictureCards/components/SidePictureCard.d.ts +2 -2
- package/dist/lib/components/SidePictureCards/components/SidePictureCard.js +23 -36
- package/dist/lib/components/SidePictureCards/types.d.ts +8 -8
- package/dist/lib/components/SidePictureCards/types.js +5 -1
- package/dist/lib/components/Steps/Steps.css +1 -41
- package/dist/lib/components/Steps/Steps.d.ts +2 -1
- package/dist/lib/components/Steps/Steps.js +8 -35
- package/dist/lib/components/Steps/StepsItem.css +1 -42
- package/dist/lib/components/Steps/StepsItem.d.ts +2 -2
- package/dist/lib/components/Steps/StepsItem.js +11 -23
- package/dist/lib/components/StoreBanner/StoreBanner.css +1 -346
- package/dist/lib/components/StoreBanner/StoreBanner.d.ts +5 -5
- package/dist/lib/components/StoreBanner/StoreBanner.js +48 -119
- package/dist/lib/components/StoreButton/StoreButton.css +1 -327
- package/dist/lib/components/StoreButton/StoreButton.d.ts +3 -3
- package/dist/lib/components/StoreButton/StoreButton.js +18 -64
- package/dist/lib/components/Table/Table.css +1 -157
- package/dist/lib/components/Table/Table.d.ts +1 -1
- package/dist/lib/components/Table/Table.js +36 -69
- package/dist/lib/components/Table/TableCell.js +4 -16
- package/dist/lib/components/Table/TableRow.js +5 -19
- package/dist/lib/components/TabsBox/TabBox.js +1 -4
- package/dist/lib/components/TabsBox/TabsBox.d.ts +1 -1
- package/dist/lib/components/TabsBox/TabsBox.js +8 -26
- package/dist/lib/components/TextBox/TextBox.css +1 -25
- package/dist/lib/components/TextBox/TextBox.d.ts +2 -1
- package/dist/lib/components/TextBox/TextBox.js +12 -36
- package/dist/lib/components/TextBox/TextBoxPicture.css +1 -27
- package/dist/lib/components/TextBox/TextBoxPicture.d.ts +2 -2
- package/dist/lib/components/TextBox/TextBoxPicture.js +11 -29
- package/dist/lib/components/TextWithIcon/TextWithIcon.css +1 -10
- package/dist/lib/components/TextWithIcon/TextWithIcon.d.ts +1 -1
- package/dist/lib/components/TextWithIcon/TextWithIcon.js +11 -40
- package/dist/lib/components/TextWithIcon/TextWithIconItem.css +1 -38
- package/dist/lib/components/TextWithIcon/TextWithIconItem.d.ts +1 -1
- package/dist/lib/components/TextWithIcon/TextWithIconItem.js +13 -41
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.css +1 -31
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.d.ts +1 -1
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.js +11 -41
- package/dist/lib/components/VideoBanner/VideoBanner.css +1 -225
- package/dist/lib/components/VideoBanner/VideoBanner.d.ts +7 -7
- package/dist/lib/components/VideoBanner/VideoBanner.js +84 -177
- package/dist/lib/components/VideoBlock/VideoBlock.css +1 -106
- package/dist/lib/components/VideoBlock/VideoBlock.d.ts +4 -4
- package/dist/lib/components/VideoBlock/VideoBlock.js +59 -115
- package/dist/lib/constants/throttleTime.js +2 -3
- package/dist/lib/helpers/getColumnConfig.d.ts +5 -1
- package/dist/lib/helpers/getColumnConfig.js +2 -5
- package/dist/lib/helpers/setRelAttribute.d.ts +3 -1
- package/dist/lib/helpers/setRelAttribute.js +2 -7
- package/dist/lib/hooks/useResolutions.d.ts +1 -1
- package/dist/lib/hooks/useResolutions.js +15 -31
- package/dist/lib/index.js +11 -64
- package/package.json +87 -92
- package/CHANGELOG.md +0 -4104
- package/dist/es/components/NotificationBox/style/NotificationBox.css +0 -28
- package/dist/es/components/StoreBanner/doc/img/android-screen.png +0 -0
- package/dist/es/components/StoreBanner/doc/img/qr-code.png +0 -0
- package/dist/es/components/StoreBanner/doc/img/screen.png +0 -0
- package/dist/lib/components/NotificationBox/style/NotificationBox.css +0 -28
- package/dist/lib/components/StoreBanner/doc/img/android-screen.png +0 -0
- package/dist/lib/components/StoreBanner/doc/img/qr-code.png +0 -0
- package/dist/lib/components/StoreBanner/doc/img/screen.png +0 -0
@@ -1,46 +1,33 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
-
function _typeof(
|
4
|
-
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
|
-
exports["default"] =
|
9
|
-
|
7
|
+
exports.pictureAlignTypes = exports["default"] = void 0;
|
10
8
|
var React = _interopRequireWildcard(require("react"));
|
11
|
-
|
12
9
|
var _uiCore = require("@megafon/ui-core");
|
13
|
-
|
14
10
|
var _uiHelpers = require("@megafon/ui-helpers");
|
15
|
-
|
16
|
-
var
|
17
|
-
|
18
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
19
|
-
|
20
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
21
|
-
|
22
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
23
|
-
|
24
|
-
var pictureAlignTypes = {
|
11
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
12
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
13
|
+
var pictureAlignTypes = exports.pictureAlignTypes = {
|
25
14
|
LEFT: 'left',
|
26
15
|
RIGHT: 'right'
|
27
16
|
};
|
28
|
-
exports.pictureAlignTypes = pictureAlignTypes;
|
29
17
|
var testIdPrefix = 'PictureWithDescription';
|
30
18
|
var cn = (0, _uiHelpers.cnCreate)('mfui-picture-with-description');
|
31
|
-
|
32
19
|
var PictureWithDescription = function PictureWithDescription(_ref) {
|
33
20
|
var rootRef = _ref.rootRef,
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
21
|
+
className = _ref.className,
|
22
|
+
_ref$classes = _ref.classes,
|
23
|
+
classes = _ref$classes === void 0 ? {} : _ref$classes,
|
24
|
+
title = _ref.title,
|
25
|
+
pictureUrl = _ref.pictureUrl,
|
26
|
+
_ref$pictureAlign = _ref.pictureAlign,
|
27
|
+
pictureAlign = _ref$pictureAlign === void 0 ? 'left' : _ref$pictureAlign,
|
28
|
+
pictureAlt = _ref.pictureAlt,
|
29
|
+
isTextTopAlign = _ref.isTextTopAlign,
|
30
|
+
children = _ref.children;
|
44
31
|
return /*#__PURE__*/React.createElement("div", {
|
45
32
|
className: cn([className, classes.root]),
|
46
33
|
ref: rootRef
|
@@ -66,21 +53,4 @@ var PictureWithDescription = function PictureWithDescription(_ref) {
|
|
66
53
|
className: cn('content')
|
67
54
|
}, children)));
|
68
55
|
};
|
69
|
-
|
70
|
-
PictureWithDescription.propTypes = {
|
71
|
-
rootRef: _propTypes["default"].oneOfType([_propTypes["default"].func, _propTypes["default"].oneOfType([_propTypes["default"].shape({
|
72
|
-
current: _propTypes["default"].elementType
|
73
|
-
}), _propTypes["default"].any])]),
|
74
|
-
className: _propTypes["default"].string,
|
75
|
-
classes: _propTypes["default"].shape({
|
76
|
-
root: _propTypes["default"].string,
|
77
|
-
title: _propTypes["default"].string
|
78
|
-
}),
|
79
|
-
title: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].node, _propTypes["default"].arrayOf(_propTypes["default"].node)]),
|
80
|
-
pictureUrl: _propTypes["default"].string.isRequired,
|
81
|
-
pictureAlign: _propTypes["default"].oneOf([pictureAlignTypes.LEFT, pictureAlignTypes.RIGHT]),
|
82
|
-
pictureAlt: _propTypes["default"].string,
|
83
|
-
isTextTopAlign: _propTypes["default"].bool
|
84
|
-
};
|
85
|
-
var _default = PictureWithDescription;
|
86
|
-
exports["default"] = _default;
|
56
|
+
var _default = exports["default"] = PictureWithDescription;
|
@@ -1,156 +1 @@
|
|
1
|
-
h1,
|
2
|
-
h2,
|
3
|
-
h3,
|
4
|
-
h4,
|
5
|
-
h5 {
|
6
|
-
margin: 0;
|
7
|
-
}
|
8
|
-
.mfui-property__wrapper {
|
9
|
-
display: -webkit-box;
|
10
|
-
display: -ms-flexbox;
|
11
|
-
display: flex;
|
12
|
-
-webkit-box-orient: vertical;
|
13
|
-
-webkit-box-direction: normal;
|
14
|
-
-ms-flex-direction: column;
|
15
|
-
flex-direction: column;
|
16
|
-
padding: 24px 0;
|
17
|
-
}
|
18
|
-
.mfui-property_border-top.mfui-property_border-color_default .mfui-property__wrapper {
|
19
|
-
border-top: 1px solid var(--spbSky1);
|
20
|
-
}
|
21
|
-
.mfui-property_border-bottom.mfui-property_border-color_default .mfui-property__wrapper {
|
22
|
-
border-bottom: 1px solid var(--spbSky1);
|
23
|
-
}
|
24
|
-
.mfui-property_border-top.mfui-property_border-color_darker .mfui-property__wrapper {
|
25
|
-
border-top: 1px solid var(--spbSky2);
|
26
|
-
}
|
27
|
-
.mfui-property_border-bottom.mfui-property_border-color_darker .mfui-property__wrapper {
|
28
|
-
border-bottom: 1px solid var(--spbSky2);
|
29
|
-
}
|
30
|
-
.mfui-property__main {
|
31
|
-
display: -webkit-box;
|
32
|
-
display: -ms-flexbox;
|
33
|
-
display: flex;
|
34
|
-
gap: 20px;
|
35
|
-
-webkit-box-align: baseline;
|
36
|
-
-ms-flex-align: baseline;
|
37
|
-
align-items: baseline;
|
38
|
-
-webkit-box-pack: justify;
|
39
|
-
-ms-flex-pack: justify;
|
40
|
-
justify-content: space-between;
|
41
|
-
}
|
42
|
-
.mfui-property__main:not(:first-child) {
|
43
|
-
margin-top: 24px;
|
44
|
-
}
|
45
|
-
.mfui-property__main_with-out-title {
|
46
|
-
margin-top: 16px !important;
|
47
|
-
}
|
48
|
-
.mfui-property__main_with-badge {
|
49
|
-
-webkit-box-align: center;
|
50
|
-
-ms-flex-align: center;
|
51
|
-
align-items: center;
|
52
|
-
}
|
53
|
-
.mfui-property__title-item_size_default {
|
54
|
-
font-size: 15px;
|
55
|
-
line-height: 24px;
|
56
|
-
font-weight: 500;
|
57
|
-
}
|
58
|
-
.mfui-property__title-item_size_big {
|
59
|
-
font-weight: 500;
|
60
|
-
font-size: 18px;
|
61
|
-
line-height: 24px;
|
62
|
-
letter-spacing: 0.5px;
|
63
|
-
}
|
64
|
-
@media screen and (min-width: 1280px) {
|
65
|
-
.mfui-property__title-item_size_big {
|
66
|
-
font-size: 20px;
|
67
|
-
line-height: 28px;
|
68
|
-
}
|
69
|
-
}
|
70
|
-
@media screen and (max-width: 767px) {
|
71
|
-
.mfui-property__title-item {
|
72
|
-
font-size: 15px;
|
73
|
-
line-height: 24px;
|
74
|
-
font-weight: 500;
|
75
|
-
}
|
76
|
-
}
|
77
|
-
.mfui-property__icon {
|
78
|
-
display: inline-block;
|
79
|
-
width: 24px;
|
80
|
-
height: 24px;
|
81
|
-
margin-right: 8px;
|
82
|
-
margin-left: 1px;
|
83
|
-
overflow: hidden;
|
84
|
-
vertical-align: bottom;
|
85
|
-
}
|
86
|
-
.mfui-property__badge {
|
87
|
-
margin-bottom: 8px;
|
88
|
-
}
|
89
|
-
@media screen and (min-width: 768px) {
|
90
|
-
.mfui-property__title .mfui-property__desc {
|
91
|
-
width: 100%;
|
92
|
-
}
|
93
|
-
}
|
94
|
-
.mfui-property__tooltip {
|
95
|
-
display: inline-block;
|
96
|
-
width: 20px;
|
97
|
-
height: 20px;
|
98
|
-
margin-left: 8px;
|
99
|
-
vertical-align: text-bottom;
|
100
|
-
cursor: pointer;
|
101
|
-
fill: var(--spbSky2);
|
102
|
-
}
|
103
|
-
.mfui-property__tooltip-inner {
|
104
|
-
max-width: 350px;
|
105
|
-
}
|
106
|
-
.mfui-property__desc {
|
107
|
-
margin-top: 12px;
|
108
|
-
}
|
109
|
-
@media screen and (min-width: 768px) {
|
110
|
-
.mfui-property__desc {
|
111
|
-
width: 70%;
|
112
|
-
}
|
113
|
-
}
|
114
|
-
.mfui-property__desc_collapsible {
|
115
|
-
margin-top: 12px;
|
116
|
-
}
|
117
|
-
.mfui-property__value-wrapper {
|
118
|
-
display: -webkit-box;
|
119
|
-
display: -ms-flexbox;
|
120
|
-
display: flex;
|
121
|
-
-webkit-box-align: baseline;
|
122
|
-
-ms-flex-align: baseline;
|
123
|
-
align-items: baseline;
|
124
|
-
padding: 4px 8px;
|
125
|
-
border-radius: 8px;
|
126
|
-
white-space: pre-line;
|
127
|
-
text-align: right;
|
128
|
-
}
|
129
|
-
.mfui-property__value-wrapper_frame_default {
|
130
|
-
background: var(--base);
|
131
|
-
}
|
132
|
-
.mfui-property__value-wrapper_frame_gray {
|
133
|
-
background: var(--spbSky0);
|
134
|
-
}
|
135
|
-
.mfui-property__value {
|
136
|
-
font-weight: 500;
|
137
|
-
font-size: 18px;
|
138
|
-
line-height: 24px;
|
139
|
-
letter-spacing: 0.5px;
|
140
|
-
}
|
141
|
-
@media screen and (min-width: 1280px) {
|
142
|
-
.mfui-property__value {
|
143
|
-
font-size: 20px;
|
144
|
-
line-height: 28px;
|
145
|
-
}
|
146
|
-
}
|
147
|
-
@media screen and (max-width: 767px) {
|
148
|
-
.mfui-property__value {
|
149
|
-
font-size: 15px;
|
150
|
-
line-height: 24px;
|
151
|
-
font-weight: 500;
|
152
|
-
}
|
153
|
-
}
|
154
|
-
.mfui-property__value-unit:before {
|
155
|
-
content: '\00a0';
|
156
|
-
}
|
1
|
+
@charset "UTF-8";h1,h2,h3,h4,h5{margin:0}.mfui-property__wrapper{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;padding:24px 0}.mfui-property_border-top.mfui-property_border-color_default .mfui-property__wrapper{border-top:1px solid var(--spbSky1)}.mfui-property_border-bottom.mfui-property_border-color_default .mfui-property__wrapper{border-bottom:1px solid var(--spbSky1)}.mfui-property_border-top.mfui-property_border-color_darker .mfui-property__wrapper{border-top:1px solid var(--spbSky2)}.mfui-property_border-bottom.mfui-property_border-color_darker .mfui-property__wrapper{border-bottom:1px solid var(--spbSky2)}.mfui-property__main{display:-webkit-box;display:-ms-flexbox;display:flex;gap:20px;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.mfui-property__main:not(:first-child){margin-top:24px}.mfui-property__main_with-out-title{margin-top:16px!important}.mfui-property__main_with-badge{-webkit-box-align:center;-ms-flex-align:center;align-items:center}.mfui-property__title-item_size_default{font-size:15px;font-weight:500;line-height:24px}.mfui-property__title-item_size_big{font-size:18px;font-weight:500;letter-spacing:.5px;line-height:24px}@media screen and (min-width:1280px){.mfui-property__title-item_size_big{font-size:20px;line-height:28px}}@media screen and (max-width:767px){.mfui-property__title-item{font-size:15px;font-weight:500;line-height:24px}}.mfui-property__icon{display:inline-block;height:24px;margin-left:1px;margin-right:8px;overflow:hidden;vertical-align:bottom;width:24px}.mfui-property__badge{margin-bottom:8px}@media screen and (min-width:768px){.mfui-property__title .mfui-property__desc{width:100%}}.mfui-property__tooltip{cursor:pointer;display:inline-block;height:20px;margin-left:8px;vertical-align:text-bottom;width:20px;fill:var(--spbSky2)}.mfui-property__tooltip-inner{max-width:350px}.mfui-property__desc{margin-top:12px}@media screen and (min-width:768px){.mfui-property__desc{width:70%}}.mfui-property__desc_collapsible{margin-top:12px}.mfui-property__value-wrapper{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:baseline;-ms-flex-align:baseline;align-items:baseline;border-radius:8px;padding:4px 8px;text-align:right;white-space:pre-line}.mfui-property__value-wrapper_frame_default{background:var(--base)}.mfui-property__value-wrapper_frame_gray{background:var(--spbSky0)}.mfui-property__value{font-size:18px;font-weight:500;letter-spacing:.5px;line-height:24px}@media screen and (min-width:1280px){.mfui-property__value{font-size:20px;line-height:28px}}@media screen and (max-width:767px){.mfui-property__value{font-size:15px;font-weight:500;line-height:24px}}.mfui-property__value-unit:before{content:" "}
|
@@ -1,10 +1,10 @@
|
|
1
|
-
import
|
1
|
+
import * as React from 'react';
|
2
2
|
import { PromoBadge } from '@megafon/ui-core';
|
3
|
-
import './Property.
|
3
|
+
import './Property.scss';
|
4
4
|
import { Item } from './types';
|
5
5
|
export interface IProperty {
|
6
6
|
/** Ссылка на корневой элемент */
|
7
|
-
rootRef?: Ref<HTMLDivElement>;
|
7
|
+
rootRef?: React.Ref<HTMLDivElement>;
|
8
8
|
/** Массив с данными для строки */
|
9
9
|
items: Item[];
|
10
10
|
/** Дополнительный класс для основного контейнера */
|
@@ -12,7 +12,7 @@ export interface IProperty {
|
|
12
12
|
/** Текст для бейджа */
|
13
13
|
badge?: string;
|
14
14
|
/** Тип бейджа */
|
15
|
-
badgeType?: ComponentProps<typeof PromoBadge>['type'];
|
15
|
+
badgeType?: React.ComponentProps<typeof PromoBadge>['type'];
|
16
16
|
/** Текст тултипа */
|
17
17
|
tooltip?: string;
|
18
18
|
/** Отключить верхнюю границу */
|
@@ -1,106 +1,85 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
|
-
function _typeof(
|
4
|
-
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
6
5
|
value: true
|
7
6
|
});
|
8
|
-
exports["default"] =
|
9
|
-
|
7
|
+
exports.testIdPrefix = exports["default"] = void 0;
|
10
8
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
11
|
-
|
12
|
-
require("core-js/modules/es.array.map.js");
|
13
|
-
|
14
9
|
require("core-js/modules/es.symbol.js");
|
15
|
-
|
16
10
|
require("core-js/modules/es.symbol.description.js");
|
17
|
-
|
18
|
-
var
|
19
|
-
|
11
|
+
require("core-js/modules/es.array.map.js");
|
12
|
+
var React = _interopRequireWildcard(require("react"));
|
20
13
|
var _uiCore = require("@megafon/ui-core");
|
21
|
-
|
22
14
|
var _uiHelpers = require("@megafon/ui-helpers");
|
23
|
-
|
24
|
-
var _propTypes = _interopRequireDefault(require("prop-types"));
|
25
|
-
|
26
15
|
var _getColumnConfig = require("../../helpers/getColumnConfig");
|
27
|
-
|
28
16
|
var _PropertyDescription = _interopRequireDefault(require("./PropertyDescription"));
|
29
|
-
|
30
|
-
function
|
31
|
-
|
32
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
33
|
-
|
34
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
35
|
-
|
17
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
18
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
19
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
36
20
|
var InfoIcon = function InfoIcon(props) {
|
37
|
-
return /*#__PURE__*/
|
21
|
+
return /*#__PURE__*/React.createElement("svg", (0, _extends2["default"])({
|
38
22
|
viewBox: "0 0 20 20"
|
39
|
-
}, props), /*#__PURE__*/
|
23
|
+
}, props), /*#__PURE__*/React.createElement("path", {
|
40
24
|
d: "M10 2c4.4 0 8 3.6 8 8s-3.6 8-8 8-8-3.6-8-8 3.6-8 8-8zm0 5c.6 0 1-.4 1-1s-.4-1-1-1-1 .4-1 1 .4 1 1 1zm1 8V9H9v6h2z"
|
41
25
|
}));
|
42
26
|
};
|
43
|
-
|
44
|
-
var testIdPrefix = 'Property';
|
45
|
-
exports.testIdPrefix = testIdPrefix;
|
27
|
+
var testIdPrefix = exports.testIdPrefix = 'Property';
|
46
28
|
var cn = (0, _uiHelpers.cnCreate)('mfui-property');
|
47
|
-
|
48
29
|
var Property = function Property(_ref) {
|
49
30
|
var rootRef = _ref.rootRef,
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
var tooltipRef =
|
72
|
-
|
73
|
-
|
74
|
-
return title && title.map(function (titleItem, i) {
|
31
|
+
items = _ref.items,
|
32
|
+
className = _ref.className,
|
33
|
+
_ref$badge = _ref.badge,
|
34
|
+
badge = _ref$badge === void 0 ? '' : _ref$badge,
|
35
|
+
_ref$badgeType = _ref.badgeType,
|
36
|
+
badgeType = _ref$badgeType === void 0 ? 'popular' : _ref$badgeType,
|
37
|
+
tooltip = _ref.tooltip,
|
38
|
+
icon = _ref.icon,
|
39
|
+
_ref$disableBorderTop = _ref.disableBorderTop,
|
40
|
+
disableBorderTop = _ref$disableBorderTop === void 0 ? false : _ref$disableBorderTop,
|
41
|
+
_ref$borderBottom = _ref.borderBottom,
|
42
|
+
borderBottom = _ref$borderBottom === void 0 ? false : _ref$borderBottom,
|
43
|
+
_ref$borderColor = _ref.borderColor,
|
44
|
+
borderColor = _ref$borderColor === void 0 ? 'default' : _ref$borderColor,
|
45
|
+
_ref$mergedValue = _ref.mergedValue,
|
46
|
+
mergedValue = _ref$mergedValue === void 0 ? '' : _ref$mergedValue,
|
47
|
+
_ref$fullWidth = _ref.fullWidth,
|
48
|
+
fullWidth = _ref$fullWidth === void 0 ? false : _ref$fullWidth,
|
49
|
+
_ref$classes = _ref.classes,
|
50
|
+
classes = _ref$classes === void 0 ? {} : _ref$classes,
|
51
|
+
dataAttrs = _ref.dataAttrs;
|
52
|
+
var tooltipRef = React.useRef(null);
|
53
|
+
var renderTitle = function renderTitle(titles, titleSize, isFirstItem) {
|
54
|
+
return titles === null || titles === void 0 ? void 0 : titles.map(function (titleItem, i) {
|
75
55
|
var isFirstTitle = i === 0;
|
76
|
-
return /*#__PURE__*/
|
56
|
+
return /*#__PURE__*/React.createElement("div", {
|
77
57
|
key: i,
|
78
58
|
className: cn('title-item', {
|
79
59
|
size: titleSize
|
80
60
|
}, [classes.title]),
|
81
61
|
"data-testid": "".concat(testIdPrefix, "-title-item")
|
82
|
-
}, icon && isFirstTitle && /*#__PURE__*/
|
62
|
+
}, icon && isFirstTitle && /*#__PURE__*/React.createElement("div", {
|
83
63
|
className: cn('icon')
|
84
|
-
}, icon), titleItem, tooltip && isFirstItem && isFirstTitle && /*#__PURE__*/
|
64
|
+
}, icon), titleItem, tooltip && isFirstItem && isFirstTitle && /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
85
65
|
className: cn('tooltip'),
|
86
66
|
ref: tooltipRef
|
87
|
-
}, /*#__PURE__*/
|
67
|
+
}, /*#__PURE__*/React.createElement(InfoIcon, null)), /*#__PURE__*/React.createElement(_uiCore.Tooltip, {
|
88
68
|
className: cn('tooltip-inner'),
|
89
69
|
triggerElement: tooltipRef
|
90
70
|
}, tooltip)));
|
91
71
|
});
|
92
72
|
};
|
93
|
-
|
94
73
|
var renderDescription = function renderDescription(description) {
|
95
|
-
return description
|
74
|
+
return description === null || description === void 0 ? void 0 : description.map(function (_ref2, j) {
|
96
75
|
var value = _ref2.value,
|
97
|
-
|
98
|
-
return /*#__PURE__*/
|
76
|
+
isCollapsible = _ref2.isCollapsible;
|
77
|
+
return /*#__PURE__*/React.createElement("div", {
|
99
78
|
className: cn('desc', {
|
100
79
|
collapsible: isCollapsible
|
101
80
|
}),
|
102
81
|
key: j
|
103
|
-
}, /*#__PURE__*/
|
82
|
+
}, /*#__PURE__*/React.createElement(_PropertyDescription["default"], {
|
104
83
|
value: value,
|
105
84
|
isCollapsible: isCollapsible,
|
106
85
|
dataAttrs: {
|
@@ -113,98 +92,59 @@ var Property = function Property(_ref) {
|
|
113
92
|
}));
|
114
93
|
});
|
115
94
|
};
|
116
|
-
|
117
95
|
var renderValue = function renderValue(valueFrameColor, value, valueUnit) {
|
118
|
-
return /*#__PURE__*/
|
96
|
+
return /*#__PURE__*/React.createElement("div", {
|
119
97
|
className: cn('value-wrapper', {
|
120
98
|
frame: valueFrameColor
|
121
99
|
}),
|
122
100
|
"data-testid": "".concat(testIdPrefix, "-value")
|
123
|
-
}, /*#__PURE__*/
|
101
|
+
}, /*#__PURE__*/React.createElement("div", {
|
124
102
|
className: cn('value')
|
125
|
-
}, typeof value === 'string' ? (0, _uiHelpers.convert)(value, {}) : value), valueUnit && /*#__PURE__*/
|
103
|
+
}, typeof value === 'string' ? (0, _uiHelpers.convert)(value, {}) : value), valueUnit && /*#__PURE__*/React.createElement(_uiCore.Caption, {
|
126
104
|
className: cn('value-unit'),
|
127
105
|
hasMargin: false
|
128
106
|
}, (0, _uiHelpers.convert)(valueUnit, {})));
|
129
107
|
};
|
130
|
-
|
131
|
-
return /*#__PURE__*/_react["default"].createElement("div", (0, _extends2["default"])({
|
108
|
+
return /*#__PURE__*/React.createElement("div", (0, _extends2["default"])({
|
132
109
|
className: cn({
|
133
110
|
'border-top': !disableBorderTop,
|
134
111
|
'border-bottom': borderBottom,
|
135
112
|
'border-color': borderColor
|
136
113
|
}, [className]),
|
137
114
|
ref: rootRef
|
138
|
-
}, (0, _uiHelpers.filterDataAttrs)(dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.root)), /*#__PURE__*/
|
115
|
+
}, (0, _uiHelpers.filterDataAttrs)(dataAttrs === null || dataAttrs === void 0 ? void 0 : dataAttrs.root)), /*#__PURE__*/React.createElement(_uiCore.Grid, null, /*#__PURE__*/React.createElement(_uiCore.GridColumn, (0, _extends2["default"])({}, (0, _getColumnConfig.getColumnConfig)(fullWidth), {
|
139
116
|
dataAttrs: {
|
140
117
|
root: {
|
141
118
|
'data-testid': "".concat(testIdPrefix, "-gridColumn")
|
142
119
|
}
|
143
120
|
}
|
144
|
-
}), /*#__PURE__*/
|
121
|
+
}), /*#__PURE__*/React.createElement("div", {
|
145
122
|
className: cn('wrapper')
|
146
123
|
}, items.map(function (_ref3, i) {
|
147
124
|
var title = _ref3.title,
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
125
|
+
value = _ref3.value,
|
126
|
+
description = _ref3.description,
|
127
|
+
_ref3$valueUnit = _ref3.valueUnit,
|
128
|
+
valueUnit = _ref3$valueUnit === void 0 ? '' : _ref3$valueUnit,
|
129
|
+
_ref3$titleSize = _ref3.titleSize,
|
130
|
+
titleSize = _ref3$titleSize === void 0 ? 'default' : _ref3$titleSize,
|
131
|
+
_ref3$valueFrameColor = _ref3.valueFrameColor,
|
132
|
+
valueFrameColor = _ref3$valueFrameColor === void 0 ? 'none' : _ref3$valueFrameColor;
|
156
133
|
var isFirstItem = i === 0;
|
157
134
|
var isRenderBadge = isFirstItem && !!badge;
|
158
|
-
return /*#__PURE__*/
|
135
|
+
return /*#__PURE__*/React.createElement(React.Fragment, {
|
159
136
|
key: i
|
160
|
-
}, /*#__PURE__*/
|
137
|
+
}, /*#__PURE__*/React.createElement("div", {
|
161
138
|
className: cn('main', {
|
162
139
|
'with-badge': isRenderBadge,
|
163
140
|
'with-out-title': !title
|
164
141
|
})
|
165
|
-
}, /*#__PURE__*/
|
142
|
+
}, /*#__PURE__*/React.createElement("div", {
|
166
143
|
className: cn('title')
|
167
|
-
}, isRenderBadge && /*#__PURE__*/
|
144
|
+
}, isRenderBadge && /*#__PURE__*/React.createElement(_uiCore.PromoBadge, {
|
168
145
|
className: cn('badge'),
|
169
146
|
type: badgeType
|
170
147
|
}, badge), title ? renderTitle(title, titleSize, isFirstItem) : renderDescription(description)), mergedValue && isFirstItem && renderValue(valueFrameColor, mergedValue, valueUnit), !mergedValue && value && renderValue(valueFrameColor, value, valueUnit)), title && renderDescription(description));
|
171
148
|
})))));
|
172
149
|
};
|
173
|
-
|
174
|
-
Property.propTypes = {
|
175
|
-
rootRef: _propTypes["default"].oneOfType([_propTypes["default"].func, _propTypes["default"].oneOfType([_propTypes["default"].shape({
|
176
|
-
current: _propTypes["default"].elementType
|
177
|
-
}), _propTypes["default"].any])]),
|
178
|
-
items: _propTypes["default"].arrayOf(_propTypes["default"].shape({
|
179
|
-
title: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].arrayOf(_propTypes["default"].node)]),
|
180
|
-
description: _propTypes["default"].arrayOf(_propTypes["default"].shape({
|
181
|
-
value: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].arrayOf(_propTypes["default"].node)]).isRequired,
|
182
|
-
isCollapsible: _propTypes["default"].bool
|
183
|
-
})),
|
184
|
-
value: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].node]),
|
185
|
-
titleSize: _propTypes["default"].oneOf(['default', 'big']),
|
186
|
-
valueUnit: _propTypes["default"].string,
|
187
|
-
valueFrameColor: _propTypes["default"].oneOf(['none', 'default', 'gray'])
|
188
|
-
}).isRequired).isRequired,
|
189
|
-
className: _propTypes["default"].string,
|
190
|
-
badge: _propTypes["default"].string,
|
191
|
-
badgeType: _propTypes["default"].oneOf(['hit', 'new', 'vip', 'popular', 'user-choice', 'interests']),
|
192
|
-
tooltip: _propTypes["default"].string,
|
193
|
-
disableBorderTop: _propTypes["default"].bool,
|
194
|
-
borderBottom: _propTypes["default"].bool,
|
195
|
-
borderColor: _propTypes["default"].oneOf(['default', 'darker']),
|
196
|
-
mergedValue: _propTypes["default"].string,
|
197
|
-
icon: _propTypes["default"].node,
|
198
|
-
fullWidth: _propTypes["default"].bool,
|
199
|
-
dataAttrs: _propTypes["default"].shape({
|
200
|
-
root: _propTypes["default"].objectOf(_propTypes["default"].string.isRequired),
|
201
|
-
moreLink: _propTypes["default"].objectOf(_propTypes["default"].string.isRequired)
|
202
|
-
}),
|
203
|
-
classes: _propTypes["default"].shape({
|
204
|
-
title: _propTypes["default"].string,
|
205
|
-
openedDescription: _propTypes["default"].string,
|
206
|
-
toggleDescription: _propTypes["default"].string
|
207
|
-
})
|
208
|
-
};
|
209
|
-
var _default = Property;
|
210
|
-
exports["default"] = _default;
|
150
|
+
var _default = exports["default"] = Property;
|
@@ -1,17 +1 @@
|
|
1
|
-
h1,
|
2
|
-
h2,
|
3
|
-
h3,
|
4
|
-
h4,
|
5
|
-
h5 {
|
6
|
-
margin: 0;
|
7
|
-
}
|
8
|
-
.mfui-property-description__collapse {
|
9
|
-
color: var(--systemBlue);
|
10
|
-
font-size: 12px;
|
11
|
-
-webkit-text-decoration: underline dashed var(--systemBlue);
|
12
|
-
text-decoration: underline dashed var(--systemBlue);
|
13
|
-
cursor: pointer;
|
14
|
-
}
|
15
|
-
.mfui-property-description__content-inner {
|
16
|
-
margin-bottom: 8px;
|
17
|
-
}
|
1
|
+
h1,h2,h3,h4,h5{margin:0}.mfui-property-description__collapse{color:var(--systemBlue);cursor:pointer;font-size:12px;-webkit-text-decoration:underline dashed var(--systemBlue);text-decoration:underline dashed var(--systemBlue)}.mfui-property-description__content-inner{margin-bottom:8px}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import * as React from 'react';
|
2
|
-
import './PropertyDescription.
|
3
|
-
import {
|
2
|
+
import './PropertyDescription.scss';
|
3
|
+
import { DescriptionType } from './types';
|
4
4
|
export declare const testIdPrefix = "PropertyDescription";
|
5
|
-
declare const PropertyDescription: React.FC<
|
5
|
+
declare const PropertyDescription: React.FC<DescriptionType>;
|
6
6
|
export default PropertyDescription;
|