@megafon/ui-shared 2.0.0-beta.24 → 2.0.0-beta.240
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/CHANGELOG.md +2292 -0
- package/README.md +0 -5
- package/dist/es/components/AccordionBox/AccordionBox.css +13 -0
- package/dist/es/components/AccordionBox/AccordionBox.d.ts +33 -0
- package/dist/es/components/AccordionBox/AccordionBox.js +62 -0
- package/dist/es/components/BannerBox/BannerBox.d.ts +5 -0
- package/dist/es/components/BannerBox/BannerBox.js +31 -0
- package/dist/es/components/BenefitsIcons/BenefitsIcons.d.ts +16 -5
- package/dist/es/components/BenefitsIcons/BenefitsIcons.js +79 -14
- package/dist/es/components/BenefitsIcons/BenefitsIconsTile.d.ts +3 -2
- package/dist/es/components/BenefitsIcons/BenefitsIconsTile.js +13 -12
- package/dist/es/components/BenefitsIcons/style/BenefitsIcons.css +1 -1
- package/dist/es/components/BenefitsIcons/style/BenefitsIconsTile.css +11 -4
- package/dist/es/components/BenefitsIcons/types.d.ts +16 -7
- package/dist/es/components/BenefitsIcons/types.js +9 -7
- package/dist/es/components/BenefitsPictures/BenefitsPictures.d.ts +12 -3
- package/dist/es/components/BenefitsPictures/BenefitsPictures.js +25 -11
- package/dist/es/components/BenefitsPictures/BenfitsPictures.css +1 -1
- package/dist/es/components/BenefitsPictures/types.d.ts +3 -0
- package/dist/es/components/Breadcrumbs/Breadcrumbs.css +46 -0
- package/dist/es/components/Breadcrumbs/Breadcrumbs.d.ts +21 -0
- package/dist/es/components/Breadcrumbs/Breadcrumbs.js +49 -0
- package/dist/es/components/ButtonBanner/ButtonBanner.css +122 -0
- package/dist/es/components/ButtonBanner/ButtonBanner.d.ts +54 -0
- package/dist/es/components/ButtonBanner/ButtonBanner.js +107 -0
- package/dist/es/components/ButtonLinkBox/ButtonLinkBox.d.ts +32 -8
- package/dist/es/components/ButtonLinkBox/ButtonLinkBox.js +45 -10
- package/dist/es/components/Card/Card.css +130 -0
- package/dist/es/components/Card/Card.d.ts +67 -0
- package/dist/es/components/Card/Card.js +176 -0
- package/dist/es/components/CardsBox/CardsBox.d.ts +15 -0
- package/dist/es/components/CardsBox/CardsBox.js +80 -0
- package/dist/es/components/CarouselBox/CarouselBox.d.ts +5 -0
- package/dist/es/components/CarouselBox/CarouselBox.js +31 -0
- package/dist/es/components/Container/Container.css +2830 -0
- package/dist/es/components/Container/Container.d.ts +26 -0
- package/dist/es/components/Container/Container.js +46 -0
- package/dist/es/components/DownloadLinks/DownloadLink.css +36 -0
- package/dist/es/components/DownloadLinks/DownloadLink.d.ts +25 -0
- package/dist/es/components/DownloadLinks/DownloadLink.js +62 -0
- package/dist/es/components/DownloadLinks/DownloadLinks.css +36 -0
- package/dist/es/components/DownloadLinks/DownloadLinks.d.ts +10 -0
- package/dist/es/components/DownloadLinks/DownloadLinks.js +75 -0
- package/dist/es/components/Instructions/Instructions.css +489 -0
- package/dist/es/components/Instructions/Instructions.d.ts +52 -0
- package/dist/es/components/Instructions/Instructions.js +229 -0
- package/dist/es/components/Instructions/img/android.png +0 -0
- package/dist/es/components/Instructions/img/blackIphone.png +0 -0
- package/dist/es/components/Instructions/img/iphone12.png +0 -0
- package/dist/es/components/Instructions/img/laptop.png +0 -0
- package/dist/es/components/Instructions/img/newIphone.png +0 -0
- package/dist/es/components/Instructions/img/whiteIphone.png +0 -0
- package/dist/es/components/PageTitle/PageTitle.css +80 -0
- package/dist/es/components/PageTitle/PageTitle.d.ts +23 -0
- package/dist/es/components/PageTitle/PageTitle.js +65 -0
- package/dist/es/components/Partners/Partners.css +53 -0
- package/dist/es/components/Partners/Partners.d.ts +32 -0
- package/dist/es/components/Partners/Partners.js +114 -0
- package/dist/es/components/PictureWithDescription/PictureWithDescription.css +80 -0
- package/dist/es/components/PictureWithDescription/PictureWithDescription.d.ts +28 -0
- package/dist/es/components/PictureWithDescription/PictureWithDescription.js +61 -0
- package/dist/es/components/Property/Property.css +125 -0
- package/dist/es/components/Property/Property.d.ts +33 -0
- package/dist/es/components/Property/Property.js +130 -0
- package/dist/es/components/Property/PropertyDescription.css +17 -0
- package/dist/es/components/Property/PropertyDescription.d.ts +5 -0
- package/dist/es/components/Property/PropertyDescription.js +51 -0
- package/dist/es/components/Property/types.d.ts +14 -0
- package/dist/es/components/Property/types.js +0 -0
- package/dist/es/components/Steps/Steps.css +41 -0
- package/dist/es/components/Steps/Steps.d.ts +10 -0
- package/dist/es/components/Steps/Steps.js +35 -0
- package/dist/es/components/Steps/StepsItem.css +37 -0
- package/dist/es/components/Steps/StepsItem.d.ts +10 -0
- package/dist/es/components/Steps/StepsItem.js +26 -0
- package/dist/es/components/StoreBanner/StoreBanner.css +289 -0
- package/dist/es/components/StoreBanner/StoreBanner.d.ts +65 -0
- package/dist/es/components/StoreBanner/StoreBanner.js +145 -0
- package/dist/es/components/StoreBanner/doc/img/new-iphone-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/es/components/StoreBanner/img/android.png +0 -0
- package/dist/es/components/StoreBanner/img/black-iphone.png +0 -0
- package/dist/es/components/StoreBanner/img/new-iphone.png +0 -0
- package/dist/es/components/StoreBanner/img/white-iphone.png +0 -0
- package/dist/es/components/StoreButton/StoreButton.css +15 -0
- package/dist/es/components/StoreButton/StoreButton.d.ts +17 -0
- package/dist/es/components/StoreButton/StoreButton.js +37 -0
- package/dist/es/components/StoreButton/img/app-store.png +0 -0
- package/dist/es/components/StoreButton/img/google-play.png +0 -0
- package/dist/es/components/StoreButton/img/huawei-store.png +0 -0
- package/dist/es/components/Table/Table.css +153 -0
- package/dist/es/components/Table/Table.d.ts +14 -0
- package/dist/es/components/Table/Table.js +124 -0
- package/dist/es/components/Table/TableCell.d.ts +6 -0
- package/dist/es/components/Table/TableCell.js +12 -0
- package/dist/es/components/Table/TableRow.d.ts +9 -0
- package/dist/es/components/Table/TableRow.js +13 -0
- package/dist/es/components/TabsBox/TabBox.d.ts +2 -0
- package/dist/es/components/TabsBox/TabBox.js +2 -0
- package/dist/es/components/TabsBox/TabsBox.d.ts +8 -0
- package/dist/es/components/TabsBox/TabsBox.js +32 -0
- package/dist/es/components/TextBox/TextBox.css +16 -0
- package/dist/es/components/TextBox/TextBox.d.ts +16 -0
- package/dist/es/components/TextBox/TextBox.js +53 -0
- package/dist/es/components/TextBox/TextBoxPicture.css +24 -0
- package/dist/es/components/TextBox/TextBoxPicture.d.ts +17 -0
- package/dist/es/components/TextBox/TextBoxPicture.js +31 -0
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.css +11 -0
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.d.ts +13 -7
- package/dist/es/components/TitleDescriptionBox/TitleDescriptionBox.js +33 -13
- package/dist/es/components/VideoBanner/VideoBanner.css +216 -0
- package/dist/es/components/VideoBanner/VideoBanner.d.ts +90 -0
- package/dist/es/components/VideoBanner/VideoBanner.js +272 -0
- package/dist/es/components/VideoBlock/VideoBlock.css +127 -0
- package/dist/es/components/VideoBlock/VideoBlock.d.ts +49 -0
- package/dist/es/components/VideoBlock/VideoBlock.js +147 -0
- package/dist/es/constants/throttleTime.d.ts +4 -0
- package/dist/es/constants/throttleTime.js +3 -0
- package/dist/es/index.d.ts +29 -17
- package/dist/es/index.js +30 -18
- package/dist/lib/components/AccordionBox/AccordionBox.css +13 -0
- package/dist/lib/components/AccordionBox/AccordionBox.d.ts +33 -0
- package/dist/lib/components/AccordionBox/AccordionBox.js +80 -0
- package/dist/lib/components/BannerBox/BannerBox.d.ts +5 -0
- package/dist/lib/components/BannerBox/BannerBox.js +49 -0
- package/dist/lib/components/BenefitsIcons/BenefitsIcons.d.ts +16 -5
- package/dist/lib/components/BenefitsIcons/BenefitsIcons.js +82 -17
- package/dist/lib/components/BenefitsIcons/BenefitsIconsTile.d.ts +3 -2
- package/dist/lib/components/BenefitsIcons/BenefitsIconsTile.js +14 -15
- package/dist/lib/components/BenefitsIcons/style/BenefitsIcons.css +1 -1
- package/dist/lib/components/BenefitsIcons/style/BenefitsIconsTile.css +11 -4
- package/dist/lib/components/BenefitsIcons/types.d.ts +16 -7
- package/dist/lib/components/BenefitsIcons/types.js +11 -8
- package/dist/lib/components/BenefitsPictures/BenefitsPictures.d.ts +12 -3
- package/dist/lib/components/BenefitsPictures/BenefitsPictures.js +27 -13
- package/dist/lib/components/BenefitsPictures/BenfitsPictures.css +1 -1
- package/dist/lib/components/BenefitsPictures/types.d.ts +3 -0
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.css +46 -0
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.d.ts +21 -0
- package/dist/lib/components/Breadcrumbs/Breadcrumbs.js +65 -0
- package/dist/lib/components/ButtonBanner/ButtonBanner.css +122 -0
- package/dist/lib/components/ButtonBanner/ButtonBanner.d.ts +54 -0
- package/dist/lib/components/ButtonBanner/ButtonBanner.js +133 -0
- package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.d.ts +32 -8
- package/dist/lib/components/ButtonLinkBox/ButtonLinkBox.js +53 -13
- package/dist/lib/components/Card/Card.css +130 -0
- package/dist/lib/components/Card/Card.d.ts +67 -0
- package/dist/lib/components/Card/Card.js +199 -0
- package/dist/lib/components/CardsBox/CardsBox.d.ts +15 -0
- package/dist/lib/components/CardsBox/CardsBox.js +105 -0
- package/dist/lib/components/CarouselBox/CarouselBox.d.ts +5 -0
- package/dist/lib/components/CarouselBox/CarouselBox.js +49 -0
- package/dist/lib/components/Container/Container.css +2830 -0
- package/dist/lib/components/Container/Container.d.ts +26 -0
- package/dist/lib/components/Container/Container.js +61 -0
- package/dist/lib/components/DownloadLinks/DownloadLink.css +36 -0
- package/dist/lib/components/DownloadLinks/DownloadLink.d.ts +25 -0
- package/dist/lib/components/DownloadLinks/DownloadLink.js +83 -0
- package/dist/lib/components/DownloadLinks/DownloadLinks.css +36 -0
- package/dist/lib/components/DownloadLinks/DownloadLinks.d.ts +10 -0
- package/dist/lib/components/DownloadLinks/DownloadLinks.js +95 -0
- package/dist/lib/components/Instructions/Instructions.css +489 -0
- package/dist/lib/components/Instructions/Instructions.d.ts +52 -0
- package/dist/lib/components/Instructions/Instructions.js +258 -0
- package/dist/lib/components/Instructions/img/android.png +0 -0
- package/dist/lib/components/Instructions/img/blackIphone.png +0 -0
- package/dist/lib/components/Instructions/img/iphone12.png +0 -0
- package/dist/lib/components/Instructions/img/laptop.png +0 -0
- package/dist/lib/components/Instructions/img/newIphone.png +0 -0
- package/dist/lib/components/Instructions/img/whiteIphone.png +0 -0
- package/dist/lib/components/PageTitle/PageTitle.css +80 -0
- package/dist/lib/components/PageTitle/PageTitle.d.ts +23 -0
- package/dist/lib/components/PageTitle/PageTitle.js +85 -0
- package/dist/lib/components/Partners/Partners.css +53 -0
- package/dist/lib/components/Partners/Partners.d.ts +32 -0
- package/dist/lib/components/Partners/Partners.js +136 -0
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.css +80 -0
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.d.ts +28 -0
- package/dist/lib/components/PictureWithDescription/PictureWithDescription.js +81 -0
- package/dist/lib/components/Property/Property.css +125 -0
- package/dist/lib/components/Property/Property.d.ts +33 -0
- package/dist/lib/components/Property/Property.js +152 -0
- package/dist/lib/components/Property/PropertyDescription.css +17 -0
- package/dist/lib/components/Property/PropertyDescription.d.ts +5 -0
- package/dist/lib/components/Property/PropertyDescription.js +71 -0
- package/dist/lib/components/Property/types.d.ts +14 -0
- package/dist/lib/components/Property/types.js +1 -0
- package/dist/lib/components/Steps/Steps.css +41 -0
- package/dist/lib/components/Steps/Steps.d.ts +10 -0
- package/dist/lib/components/Steps/Steps.js +55 -0
- package/dist/lib/components/Steps/StepsItem.css +37 -0
- package/dist/lib/components/Steps/StepsItem.d.ts +10 -0
- package/dist/lib/components/Steps/StepsItem.js +39 -0
- package/dist/lib/components/StoreBanner/StoreBanner.css +289 -0
- package/dist/lib/components/StoreBanner/StoreBanner.d.ts +65 -0
- package/dist/lib/components/StoreBanner/StoreBanner.js +169 -0
- package/dist/lib/components/StoreBanner/doc/img/new-iphone-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
- package/dist/lib/components/StoreBanner/img/android.png +0 -0
- package/dist/lib/components/StoreBanner/img/black-iphone.png +0 -0
- package/dist/lib/components/StoreBanner/img/new-iphone.png +0 -0
- package/dist/lib/components/StoreBanner/img/white-iphone.png +0 -0
- package/dist/lib/components/StoreButton/StoreButton.css +15 -0
- package/dist/lib/components/StoreButton/StoreButton.d.ts +17 -0
- package/dist/lib/components/StoreButton/StoreButton.js +58 -0
- package/dist/lib/components/StoreButton/img/app-store.png +0 -0
- package/dist/lib/components/StoreButton/img/google-play.png +0 -0
- package/dist/lib/components/StoreButton/img/huawei-store.png +0 -0
- package/dist/lib/components/Table/Table.css +153 -0
- package/dist/lib/components/Table/Table.d.ts +14 -0
- package/dist/lib/components/Table/Table.js +146 -0
- package/dist/lib/components/Table/TableCell.d.ts +6 -0
- package/dist/lib/components/Table/TableCell.js +27 -0
- package/dist/lib/components/Table/TableRow.d.ts +9 -0
- package/dist/lib/components/Table/TableRow.js +28 -0
- package/dist/lib/components/TabsBox/TabBox.d.ts +2 -0
- package/dist/lib/components/TabsBox/TabBox.js +11 -0
- package/dist/lib/components/TabsBox/TabsBox.d.ts +8 -0
- package/dist/lib/components/TabsBox/TabsBox.js +50 -0
- package/dist/lib/components/TextBox/TextBox.css +16 -0
- package/dist/lib/components/TextBox/TextBox.d.ts +16 -0
- package/dist/lib/components/TextBox/TextBox.js +70 -0
- package/dist/lib/components/TextBox/TextBoxPicture.css +24 -0
- package/dist/lib/components/TextBox/TextBoxPicture.d.ts +17 -0
- package/dist/lib/components/TextBox/TextBoxPicture.js +48 -0
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.css +11 -0
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.d.ts +13 -7
- package/dist/lib/components/TitleDescriptionBox/TitleDescriptionBox.js +37 -17
- package/dist/lib/components/VideoBanner/VideoBanner.css +216 -0
- package/dist/lib/components/VideoBanner/VideoBanner.d.ts +90 -0
- package/dist/lib/components/VideoBanner/VideoBanner.js +309 -0
- package/dist/lib/components/VideoBlock/VideoBlock.css +127 -0
- package/dist/lib/components/VideoBlock/VideoBlock.d.ts +49 -0
- package/dist/lib/components/VideoBlock/VideoBlock.js +170 -0
- package/dist/lib/constants/throttleTime.d.ts +4 -0
- package/dist/lib/constants/throttleTime.js +10 -0
- package/dist/lib/index.d.ts +29 -17
- package/dist/lib/index.js +147 -51
- package/package.json +22 -77
- package/dist/es/components/ProductCard/ProductCardFeatures.css +0 -35
- package/dist/es/components/ProductCard/ProductCardFeatures.d.ts +0 -61
- package/dist/es/components/ProductCard/ProductCardFeatures.js +0 -82
- package/dist/es/components/ProductCard/ProductCardFeaturesBottom.css +0 -41
- package/dist/es/components/ProductCard/ProductCardFeaturesBottom.d.ts +0 -22
- package/dist/es/components/ProductCard/ProductCardFeaturesBottom.js +0 -80
- package/dist/es/components/ProductCard/ProductCardFeaturesTop.css +0 -16
- package/dist/es/components/ProductCard/ProductCardFeaturesTop.d.ts +0 -25
- package/dist/es/components/ProductCard/ProductCardFeaturesTop.js +0 -67
- package/dist/es/components/ProductCard/ProductCardInfo.css +0 -236
- package/dist/es/components/ProductCard/ProductCardInfo.d.ts +0 -75
- package/dist/es/components/ProductCard/ProductCardInfo.js +0 -169
- package/dist/es/components/ProductCard/ProductCardTotal.css +0 -113
- package/dist/es/components/ProductCard/ProductCardTotal.d.ts +0 -86
- package/dist/es/components/ProductCard/ProductCardTotal.js +0 -161
- package/dist/es/components/ProductCard/ProductCardWrapper.css +0 -162
- package/dist/es/components/ProductCard/ProductCardWrapper.d.ts +0 -53
- package/dist/es/components/ProductCard/ProductCardWrapper.js +0 -109
- package/dist/es/components/ProductSwitcher/ProductSwitcher.css +0 -372
- package/dist/es/components/ProductSwitcher/ProductSwitcher.d.ts +0 -86
- package/dist/es/components/ProductSwitcher/ProductSwitcher.js +0 -612
- package/dist/es/components/ProductTile/ProductTile.d.ts +0 -287
- package/dist/es/components/ProductTile/ProductTile.js +0 -497
- package/dist/es/components/ProductTile/ProductTileBuy.d.ts +0 -53
- package/dist/es/components/ProductTile/ProductTileBuy.js +0 -99
- package/dist/es/components/ProductTile/ProductTileCashback.d.ts +0 -20
- package/dist/es/components/ProductTile/ProductTileCashback.js +0 -60
- package/dist/es/components/ProductTile/ProductTileDynamic.d.ts +0 -42
- package/dist/es/components/ProductTile/ProductTileDynamic.js +0 -109
- package/dist/es/components/ProductTile/ProductTileHint.d.ts +0 -24
- package/dist/es/components/ProductTile/ProductTileHint.js +0 -67
- package/dist/es/components/ProductTile/ProductTileOptions.d.ts +0 -31
- package/dist/es/components/ProductTile/ProductTileOptions.js +0 -130
- package/dist/es/components/ProductTile/ProductTilePrice.d.ts +0 -26
- package/dist/es/components/ProductTile/ProductTilePrice.js +0 -75
- package/dist/es/components/ProductTile/ProductTileStatic.d.ts +0 -20
- package/dist/es/components/ProductTile/ProductTileStatic.js +0 -60
- package/dist/es/components/ProductTile/ProductTileValue.d.ts +0 -31
- package/dist/es/components/ProductTile/ProductTileValue.js +0 -111
- package/dist/es/components/ProductTile/style/ProductTile.css +0 -146
- package/dist/es/components/ProductTile/style/ProductTileBuy.css +0 -76
- package/dist/es/components/ProductTile/style/ProductTileCashback.css +0 -23
- package/dist/es/components/ProductTile/style/ProductTileDynamic.css +0 -38
- package/dist/es/components/ProductTile/style/ProductTileHint.css +0 -93
- package/dist/es/components/ProductTile/style/ProductTileOptions.css +0 -84
- package/dist/es/components/ProductTile/style/ProductTilePrice.css +0 -105
- package/dist/es/components/ProductTile/style/ProductTileStatic.css +0 -23
- package/dist/es/components/ProductTile/style/ProductTileValue.css +0 -58
- package/dist/es/components/ProductTileRest/ProductTileRest.css +0 -226
- package/dist/es/components/ProductTileRest/ProductTileRest.d.ts +0 -109
- package/dist/es/components/ProductTileRest/ProductTileRest.js +0 -291
- package/dist/es/constants/breakpoints.d.ts +0 -1
- package/dist/es/constants/breakpoints.js +0 -1
- package/dist/lib/components/ProductCard/ProductCardFeatures.css +0 -35
- package/dist/lib/components/ProductCard/ProductCardFeatures.d.ts +0 -61
- package/dist/lib/components/ProductCard/ProductCardFeatures.js +0 -141
- package/dist/lib/components/ProductCard/ProductCardFeaturesBottom.css +0 -41
- package/dist/lib/components/ProductCard/ProductCardFeaturesBottom.d.ts +0 -22
- package/dist/lib/components/ProductCard/ProductCardFeaturesBottom.js +0 -140
- package/dist/lib/components/ProductCard/ProductCardFeaturesTop.css +0 -16
- package/dist/lib/components/ProductCard/ProductCardFeaturesTop.d.ts +0 -25
- package/dist/lib/components/ProductCard/ProductCardFeaturesTop.js +0 -124
- package/dist/lib/components/ProductCard/ProductCardInfo.css +0 -236
- package/dist/lib/components/ProductCard/ProductCardInfo.d.ts +0 -75
- package/dist/lib/components/ProductCard/ProductCardInfo.js +0 -241
- package/dist/lib/components/ProductCard/ProductCardTotal.css +0 -113
- package/dist/lib/components/ProductCard/ProductCardTotal.d.ts +0 -86
- package/dist/lib/components/ProductCard/ProductCardTotal.js +0 -218
- package/dist/lib/components/ProductCard/ProductCardWrapper.css +0 -162
- package/dist/lib/components/ProductCard/ProductCardWrapper.d.ts +0 -53
- package/dist/lib/components/ProductCard/ProductCardWrapper.js +0 -170
- package/dist/lib/components/ProductSwitcher/ProductSwitcher.css +0 -372
- package/dist/lib/components/ProductSwitcher/ProductSwitcher.d.ts +0 -86
- package/dist/lib/components/ProductSwitcher/ProductSwitcher.js +0 -686
- package/dist/lib/components/ProductTile/ProductTile.d.ts +0 -287
- package/dist/lib/components/ProductTile/ProductTile.js +0 -590
- package/dist/lib/components/ProductTile/ProductTileBuy.d.ts +0 -53
- package/dist/lib/components/ProductTile/ProductTileBuy.js +0 -156
- package/dist/lib/components/ProductTile/ProductTileCashback.d.ts +0 -20
- package/dist/lib/components/ProductTile/ProductTileCashback.js +0 -117
- package/dist/lib/components/ProductTile/ProductTileDynamic.d.ts +0 -42
- package/dist/lib/components/ProductTile/ProductTileDynamic.js +0 -174
- package/dist/lib/components/ProductTile/ProductTileHint.d.ts +0 -24
- package/dist/lib/components/ProductTile/ProductTileHint.js +0 -124
- package/dist/lib/components/ProductTile/ProductTileOptions.d.ts +0 -31
- package/dist/lib/components/ProductTile/ProductTileOptions.js +0 -193
- package/dist/lib/components/ProductTile/ProductTilePrice.d.ts +0 -26
- package/dist/lib/components/ProductTile/ProductTilePrice.js +0 -136
- package/dist/lib/components/ProductTile/ProductTileStatic.d.ts +0 -20
- package/dist/lib/components/ProductTile/ProductTileStatic.js +0 -123
- package/dist/lib/components/ProductTile/ProductTileValue.d.ts +0 -31
- package/dist/lib/components/ProductTile/ProductTileValue.js +0 -171
- package/dist/lib/components/ProductTile/style/ProductTile.css +0 -146
- package/dist/lib/components/ProductTile/style/ProductTileBuy.css +0 -76
- package/dist/lib/components/ProductTile/style/ProductTileCashback.css +0 -23
- package/dist/lib/components/ProductTile/style/ProductTileDynamic.css +0 -38
- package/dist/lib/components/ProductTile/style/ProductTileHint.css +0 -93
- package/dist/lib/components/ProductTile/style/ProductTileOptions.css +0 -84
- package/dist/lib/components/ProductTile/style/ProductTilePrice.css +0 -105
- package/dist/lib/components/ProductTile/style/ProductTileStatic.css +0 -23
- package/dist/lib/components/ProductTile/style/ProductTileValue.css +0 -58
- package/dist/lib/components/ProductTileRest/ProductTileRest.css +0 -226
- package/dist/lib/components/ProductTileRest/ProductTileRest.d.ts +0 -109
- package/dist/lib/components/ProductTileRest/ProductTileRest.js +0 -364
- package/dist/lib/constants/breakpoints.d.ts +0 -1
- package/dist/lib/constants/breakpoints.js +0 -8
@@ -0,0 +1,153 @@
|
|
1
|
+
h1,
|
2
|
+
h2,
|
3
|
+
h3,
|
4
|
+
h4,
|
5
|
+
h5 {
|
6
|
+
margin: 0;
|
7
|
+
}
|
8
|
+
.mfui-beta-table {
|
9
|
+
display: -webkit-box;
|
10
|
+
display: -ms-flexbox;
|
11
|
+
display: flex;
|
12
|
+
font-family: inherit;
|
13
|
+
font-size: 15px;
|
14
|
+
line-height: 24px;
|
15
|
+
}
|
16
|
+
.mfui-beta-table:not(.mfui-beta-table_touch) ::-webkit-scrollbar {
|
17
|
+
width: 8px;
|
18
|
+
height: 8px;
|
19
|
+
}
|
20
|
+
.mfui-beta-table:not(.mfui-beta-table_touch) ::-webkit-scrollbar-track {
|
21
|
+
background-color: #EDEDED;
|
22
|
+
}
|
23
|
+
.mfui-beta-table:not(.mfui-beta-table_touch) ::-webkit-scrollbar-thumb {
|
24
|
+
border-radius: 4px;
|
25
|
+
background-color: #D8D8D8;
|
26
|
+
}
|
27
|
+
.mfui-beta-table:not(.mfui-beta-table_touch) ::-webkit-scrollbar-corner {
|
28
|
+
background-color: #FFFFFF;
|
29
|
+
}
|
30
|
+
.mfui-beta-table:not(.mfui-beta-table_touch) .mfui-beta-table__scroll {
|
31
|
+
scrollbar-color: #D8D8D8 #EDEDED;
|
32
|
+
scrollbar-width: thin;
|
33
|
+
}
|
34
|
+
.mfui-beta-table__scroll {
|
35
|
+
position: relative;
|
36
|
+
display: grid;
|
37
|
+
grid-template-columns: auto auto auto;
|
38
|
+
max-width: 100%;
|
39
|
+
border: 1px solid #D8D8D8;
|
40
|
+
overflow: auto;
|
41
|
+
}
|
42
|
+
@media screen and (min-width: 1024px) {
|
43
|
+
.mfui-beta-table__scroll {
|
44
|
+
max-height: 500px;
|
45
|
+
}
|
46
|
+
}
|
47
|
+
.mfui-beta-table__top-shadow {
|
48
|
+
position: -webkit-sticky;
|
49
|
+
position: sticky;
|
50
|
+
top: 0;
|
51
|
+
z-index: 2;
|
52
|
+
display: block;
|
53
|
+
grid-column-start: 1;
|
54
|
+
grid-column-end: 4;
|
55
|
+
width: 100%;
|
56
|
+
height: 6px;
|
57
|
+
margin-bottom: -6px;
|
58
|
+
background: linear-gradient(359.94deg, rgba(0, 0, 0, 0.0001) 0.06%, rgba(0, 0, 0, 0.03) 38.08%, rgba(0, 0, 0, 0.08) 74.98%);
|
59
|
+
}
|
60
|
+
.mfui-beta-table__left-shadow {
|
61
|
+
position: -webkit-sticky;
|
62
|
+
position: sticky;
|
63
|
+
top: 0;
|
64
|
+
bottom: 0;
|
65
|
+
left: 0;
|
66
|
+
z-index: 2;
|
67
|
+
width: 6px;
|
68
|
+
margin-right: -6px;
|
69
|
+
background: -webkit-gradient(linear, right top, left top, color-stop(16.3%, rgba(0, 0, 0, 0.0001)), color-stop(51.81%, rgba(0, 0, 0, 0.03)), color-stop(86.27%, rgba(0, 0, 0, 0.08)));
|
70
|
+
background: linear-gradient(270deg, rgba(0, 0, 0, 0.0001) 16.3%, rgba(0, 0, 0, 0.03) 51.81%, rgba(0, 0, 0, 0.08) 86.27%);
|
71
|
+
}
|
72
|
+
.mfui-beta-table__bottom-gradient {
|
73
|
+
position: -webkit-sticky;
|
74
|
+
position: sticky;
|
75
|
+
bottom: 0;
|
76
|
+
z-index: 1;
|
77
|
+
display: block;
|
78
|
+
grid-column-start: 1;
|
79
|
+
grid-column-end: 4;
|
80
|
+
width: 100%;
|
81
|
+
height: 48px;
|
82
|
+
margin-top: -48px;
|
83
|
+
background: -webkit-gradient(linear, left bottom, left top, color-stop(25%, #FFFFFF), to(rgba(255, 255, 255, 0)));
|
84
|
+
background: linear-gradient(to top, #FFFFFF 25%, rgba(255, 255, 255, 0));
|
85
|
+
}
|
86
|
+
.mfui-beta-table__right-gradient {
|
87
|
+
position: -webkit-sticky;
|
88
|
+
position: sticky;
|
89
|
+
right: 0;
|
90
|
+
z-index: 1;
|
91
|
+
display: block;
|
92
|
+
width: 48px;
|
93
|
+
height: 100%;
|
94
|
+
margin-left: -48px;
|
95
|
+
background: -webkit-gradient(linear, right top, left top, color-stop(25%, #FFFFFF), to(rgba(255, 255, 255, 0)));
|
96
|
+
background: linear-gradient(to left, #FFFFFF 25%, rgba(255, 255, 255, 0));
|
97
|
+
}
|
98
|
+
.mfui-beta-table__table {
|
99
|
+
border-width: 0;
|
100
|
+
border-collapse: separate;
|
101
|
+
border-spacing: 0;
|
102
|
+
background-color: #FFFFFF;
|
103
|
+
}
|
104
|
+
.mfui-beta-table__cell {
|
105
|
+
-webkit-box-sizing: border-box;
|
106
|
+
box-sizing: border-box;
|
107
|
+
padding: 24px;
|
108
|
+
background-color: #FFFFFF;
|
109
|
+
}
|
110
|
+
@media screen and (max-width: 767px) {
|
111
|
+
.mfui-beta-table__cell {
|
112
|
+
padding-right: 16px;
|
113
|
+
padding-left: 16px;
|
114
|
+
}
|
115
|
+
}
|
116
|
+
.mfui-beta-table__cell:first-child {
|
117
|
+
position: relative;
|
118
|
+
left: 0;
|
119
|
+
width: 144px;
|
120
|
+
min-width: 144px;
|
121
|
+
border-right: 1px solid #D8D8D8;
|
122
|
+
}
|
123
|
+
.mfui-beta-table__cell:not(:first-child) {
|
124
|
+
max-width: 288px;
|
125
|
+
}
|
126
|
+
.mfui-beta-table__row_head .mfui-beta-table__cell {
|
127
|
+
font-size: 12px;
|
128
|
+
line-height: 16px;
|
129
|
+
height: 72px;
|
130
|
+
padding-bottom: 12px;
|
131
|
+
color: rgba(51, 51, 51, 0.5);
|
132
|
+
vertical-align: bottom;
|
133
|
+
background-color: #F6F6F6;
|
134
|
+
}
|
135
|
+
.mfui-beta-table__row:not(:last-child) .mfui-beta-table__cell {
|
136
|
+
border-bottom: 1px solid #D8D8D8;
|
137
|
+
}
|
138
|
+
.mfui-beta-table_min-cell-size_small .mfui-beta-table__cell:not(:first-child) {
|
139
|
+
min-width: 72px;
|
140
|
+
}
|
141
|
+
.mfui-beta-table_min-cell-size_large .mfui-beta-table__cell:not(:first-child) {
|
142
|
+
min-width: 144px;
|
143
|
+
}
|
144
|
+
.mfui-beta-table_fix-column .mfui-beta-table__cell:first-child {
|
145
|
+
position: -webkit-sticky;
|
146
|
+
position: sticky;
|
147
|
+
}
|
148
|
+
.mfui-beta-table_fix-column .mfui-beta-table__left-shadow {
|
149
|
+
left: 144px;
|
150
|
+
}
|
151
|
+
.mfui-beta-table_fix-column .mfui-beta-table__bottom-gradient {
|
152
|
+
z-index: 3;
|
153
|
+
}
|
@@ -0,0 +1,14 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import './Table.less';
|
3
|
+
import { ITableRow } from './TableRow';
|
4
|
+
export interface ITable {
|
5
|
+
/** Дополнительный класс корневого элемента */
|
6
|
+
className?: string;
|
7
|
+
/** Фиксация первой колонки */
|
8
|
+
fixColumn?: boolean;
|
9
|
+
/** Минимальный размер ячеек */
|
10
|
+
minCellSize?: 'small' | 'large';
|
11
|
+
children: Array<React.ReactElement<ITableRow>>;
|
12
|
+
}
|
13
|
+
declare const Table: React.FC<ITable>;
|
14
|
+
export default Table;
|
@@ -0,0 +1,124 @@
|
|
1
|
+
import "core-js/modules/es.array.map";
|
2
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
3
|
+
import * as React from 'react';
|
4
|
+
import * as PropTypes from 'prop-types';
|
5
|
+
import throttle from 'lodash.throttle';
|
6
|
+
import convert from 'htmr';
|
7
|
+
import { cnCreate, detectTouch } from '@megafon/ui-helpers';
|
8
|
+
import "./Table.css";
|
9
|
+
var cn = cnCreate('mfui-beta-table');
|
10
|
+
|
11
|
+
var Table = function Table(_ref) {
|
12
|
+
var className = _ref.className,
|
13
|
+
_ref$fixColumn = _ref.fixColumn,
|
14
|
+
fixColumn = _ref$fixColumn === void 0 ? true : _ref$fixColumn,
|
15
|
+
_ref$minCellSize = _ref.minCellSize,
|
16
|
+
minCellSize = _ref$minCellSize === void 0 ? 'large' : _ref$minCellSize,
|
17
|
+
children = _ref.children;
|
18
|
+
var scrollRef = React.useRef(null);
|
19
|
+
|
20
|
+
var _React$useState = React.useState(false),
|
21
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
22
|
+
isTopShadow = _React$useState2[0],
|
23
|
+
setTopShadow = _React$useState2[1];
|
24
|
+
|
25
|
+
var _React$useState3 = React.useState(false),
|
26
|
+
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
27
|
+
isLeftShadow = _React$useState4[0],
|
28
|
+
setLeftShadow = _React$useState4[1];
|
29
|
+
|
30
|
+
var _React$useState5 = React.useState(false),
|
31
|
+
_React$useState6 = _slicedToArray(_React$useState5, 2),
|
32
|
+
isRightGradient = _React$useState6[0],
|
33
|
+
setRightGradient = _React$useState6[1];
|
34
|
+
|
35
|
+
var _React$useState7 = React.useState(false),
|
36
|
+
_React$useState8 = _slicedToArray(_React$useState7, 2),
|
37
|
+
isBottomGradient = _React$useState8[0],
|
38
|
+
setBottomGradient = _React$useState8[1];
|
39
|
+
|
40
|
+
var _React$useState9 = React.useState(false),
|
41
|
+
_React$useState10 = _slicedToArray(_React$useState9, 2),
|
42
|
+
isTouchDevice = _React$useState10[0],
|
43
|
+
setTouchDevice = _React$useState10[1];
|
44
|
+
|
45
|
+
var handleTableScroll = React.useCallback(function () {
|
46
|
+
var scrollNode = scrollRef.current;
|
47
|
+
|
48
|
+
if (!scrollNode) {
|
49
|
+
return;
|
50
|
+
}
|
51
|
+
|
52
|
+
var scrollHeight = scrollNode.scrollHeight,
|
53
|
+
clientHeight = scrollNode.clientHeight,
|
54
|
+
scrollTop = scrollNode.scrollTop,
|
55
|
+
scrollWidth = scrollNode.scrollWidth,
|
56
|
+
clientWidth = scrollNode.clientWidth,
|
57
|
+
scrollLeft = scrollNode.scrollLeft;
|
58
|
+
var deltaHeight = scrollHeight - clientHeight;
|
59
|
+
var deltaWidth = scrollWidth - clientWidth;
|
60
|
+
setRightGradient(deltaWidth !== Math.floor(scrollLeft));
|
61
|
+
setBottomGradient(deltaHeight !== Math.floor(scrollTop));
|
62
|
+
setTopShadow(!!scrollTop);
|
63
|
+
setLeftShadow(!!scrollLeft);
|
64
|
+
}, []);
|
65
|
+
React.useEffect(function () {
|
66
|
+
var handleResize = throttle(handleTableScroll, 300);
|
67
|
+
handleTableScroll();
|
68
|
+
window.addEventListener('resize', handleResize);
|
69
|
+
return function () {
|
70
|
+
window.removeEventListener('resize', handleResize);
|
71
|
+
};
|
72
|
+
}, [handleTableScroll]);
|
73
|
+
React.useEffect(function () {
|
74
|
+
setTouchDevice(detectTouch());
|
75
|
+
}, []);
|
76
|
+
|
77
|
+
var renderRows = function renderRows() {
|
78
|
+
return React.Children.map(children, function (_ref2) {
|
79
|
+
var _ref2$props = _ref2.props,
|
80
|
+
cells = _ref2$props.children,
|
81
|
+
head = _ref2$props.head;
|
82
|
+
return /*#__PURE__*/React.createElement("tr", {
|
83
|
+
className: cn('row', {
|
84
|
+
head: head
|
85
|
+
})
|
86
|
+
}, React.Children.map(cells, function (_ref3) {
|
87
|
+
var cell = _ref3.props.children;
|
88
|
+
return /*#__PURE__*/React.createElement("td", {
|
89
|
+
className: cn('cell')
|
90
|
+
}, typeof cell === 'string' ? convert(cell) : cell);
|
91
|
+
}));
|
92
|
+
});
|
93
|
+
};
|
94
|
+
|
95
|
+
return /*#__PURE__*/React.createElement("div", {
|
96
|
+
className: cn({
|
97
|
+
'fix-column': fixColumn,
|
98
|
+
'min-cell-size': minCellSize,
|
99
|
+
touch: isTouchDevice
|
100
|
+
}, [className])
|
101
|
+
}, /*#__PURE__*/React.createElement("div", {
|
102
|
+
className: cn('scroll'),
|
103
|
+
ref: scrollRef,
|
104
|
+
onScroll: handleTableScroll
|
105
|
+
}, isTopShadow && /*#__PURE__*/React.createElement("div", {
|
106
|
+
className: cn('top-shadow')
|
107
|
+
}), isLeftShadow && /*#__PURE__*/React.createElement("div", {
|
108
|
+
className: cn('left-shadow')
|
109
|
+
}), /*#__PURE__*/React.createElement("table", {
|
110
|
+
className: cn('table')
|
111
|
+
}, /*#__PURE__*/React.createElement("tbody", null, renderRows())), isRightGradient && /*#__PURE__*/React.createElement("div", {
|
112
|
+
className: cn('right-gradient')
|
113
|
+
}), isBottomGradient && /*#__PURE__*/React.createElement("div", {
|
114
|
+
className: cn('bottom-gradient')
|
115
|
+
})));
|
116
|
+
};
|
117
|
+
|
118
|
+
Table.propTypes = {
|
119
|
+
className: PropTypes.string,
|
120
|
+
fixColumn: PropTypes.bool,
|
121
|
+
minCellSize: PropTypes.oneOf(['small', 'large']),
|
122
|
+
children: PropTypes.arrayOf(PropTypes.element.isRequired).isRequired
|
123
|
+
};
|
124
|
+
export default Table;
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import * as PropTypes from 'prop-types';
|
3
|
+
|
4
|
+
var TableCell = function TableCell(_ref) {
|
5
|
+
var children = _ref.children;
|
6
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, children && children);
|
7
|
+
};
|
8
|
+
|
9
|
+
TableCell.propTypes = {
|
10
|
+
children: PropTypes.node
|
11
|
+
};
|
12
|
+
export default TableCell;
|
@@ -0,0 +1,9 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { ITableCell } from './TableCell';
|
3
|
+
export interface ITableRow {
|
4
|
+
/** Ряд таблицы как заголовок */
|
5
|
+
head?: boolean;
|
6
|
+
children: Array<React.ReactElement<ITableCell>>;
|
7
|
+
}
|
8
|
+
declare const TableRow: React.FC<ITableRow>;
|
9
|
+
export default TableRow;
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import * as PropTypes from 'prop-types';
|
3
|
+
|
4
|
+
var TableRow = function TableRow(_ref) {
|
5
|
+
var children = _ref.children;
|
6
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, children);
|
7
|
+
};
|
8
|
+
|
9
|
+
TableRow.propTypes = {
|
10
|
+
head: PropTypes.bool,
|
11
|
+
children: PropTypes.arrayOf(PropTypes.element.isRequired).isRequired
|
12
|
+
};
|
13
|
+
export default TableRow;
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import { Tabs } from '@megafon/ui-core';
|
3
|
+
declare type TabsPropsType = React.ComponentProps<typeof Tabs> & {
|
4
|
+
/** Ссылка на корневой элемент */
|
5
|
+
rootRef?: React.Ref<HTMLDivElement>;
|
6
|
+
};
|
7
|
+
declare const TabsBox: React.FC<TabsPropsType>;
|
8
|
+
export default TabsBox;
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import "core-js/modules/es.symbol";
|
2
|
+
import "core-js/modules/es.array.index-of";
|
3
|
+
|
4
|
+
var __rest = this && this.__rest || function (s, e) {
|
5
|
+
var t = {};
|
6
|
+
|
7
|
+
for (var p in s) {
|
8
|
+
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
9
|
+
}
|
10
|
+
|
11
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
12
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
13
|
+
}
|
14
|
+
return t;
|
15
|
+
};
|
16
|
+
|
17
|
+
import * as React from 'react';
|
18
|
+
import { Tabs } from '@megafon/ui-core';
|
19
|
+
import { cnCreate } from '@megafon/ui-helpers';
|
20
|
+
var cn = cnCreate('mfui-beta-tabs-box');
|
21
|
+
|
22
|
+
var TabsBox = function TabsBox(_a) {
|
23
|
+
var rootRef = _a.rootRef,
|
24
|
+
props = __rest(_a, ["rootRef"]);
|
25
|
+
|
26
|
+
return /*#__PURE__*/React.createElement("div", {
|
27
|
+
ref: rootRef,
|
28
|
+
className: cn()
|
29
|
+
}, /*#__PURE__*/React.createElement(Tabs, props));
|
30
|
+
};
|
31
|
+
|
32
|
+
export default TabsBox;
|
@@ -0,0 +1,16 @@
|
|
1
|
+
h1,
|
2
|
+
h2,
|
3
|
+
h3,
|
4
|
+
h4,
|
5
|
+
h5 {
|
6
|
+
margin: 0;
|
7
|
+
}
|
8
|
+
.mfui-beta-text-box__content :first-child {
|
9
|
+
margin-top: 0 !important;
|
10
|
+
}
|
11
|
+
.mfui-beta-text-box__content :last-child {
|
12
|
+
margin-bottom: 0 !important;
|
13
|
+
}
|
14
|
+
.mfui-beta-text-box_text-center {
|
15
|
+
text-align: center;
|
16
|
+
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import './TextBox.less';
|
3
|
+
export interface ITextBoxProps {
|
4
|
+
/** Центрирование текста по горизонтали */
|
5
|
+
textCenter?: boolean;
|
6
|
+
/** Центрирование компонента по горизонтали при ограниченной ширине */
|
7
|
+
centeringWithLimitedWidth?: boolean;
|
8
|
+
/** Растягивание компонента на всю доступную ширину */
|
9
|
+
isFullWidth?: boolean;
|
10
|
+
/** Ссылка на корневой элемент */
|
11
|
+
rootRef?: React.Ref<HTMLDivElement>;
|
12
|
+
/** Дополнительный класс для корневого элемента */
|
13
|
+
className?: string;
|
14
|
+
}
|
15
|
+
declare const TextBox: React.FC<ITextBoxProps>;
|
16
|
+
export default TextBox;
|
@@ -0,0 +1,53 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import * as PropTypes from 'prop-types';
|
3
|
+
import { cnCreate } from '@megafon/ui-helpers';
|
4
|
+
import { Grid, GridColumn } from '@megafon/ui-core';
|
5
|
+
import "./TextBox.css";
|
6
|
+
var cn = cnCreate('mfui-beta-text-box');
|
7
|
+
|
8
|
+
var TextBox = function TextBox(_ref) {
|
9
|
+
var _ref$textCenter = _ref.textCenter,
|
10
|
+
textCenter = _ref$textCenter === void 0 ? false : _ref$textCenter,
|
11
|
+
_ref$centeringWithLim = _ref.centeringWithLimitedWidth,
|
12
|
+
centeringWithLimitedWidth = _ref$centeringWithLim === void 0 ? false : _ref$centeringWithLim,
|
13
|
+
_ref$isFullWidth = _ref.isFullWidth,
|
14
|
+
isFullWidth = _ref$isFullWidth === void 0 ? true : _ref$isFullWidth,
|
15
|
+
rootRef = _ref.rootRef,
|
16
|
+
className = _ref.className,
|
17
|
+
children = _ref.children;
|
18
|
+
|
19
|
+
var renderContent = function renderContent() {
|
20
|
+
return /*#__PURE__*/React.createElement("div", {
|
21
|
+
className: cn('content')
|
22
|
+
}, children);
|
23
|
+
};
|
24
|
+
|
25
|
+
var renderTextBoxWithGrid = function renderTextBoxWithGrid() {
|
26
|
+
return /*#__PURE__*/React.createElement(Grid, {
|
27
|
+
hAlign: centeringWithLimitedWidth ? 'center' : 'left'
|
28
|
+
}, /*#__PURE__*/React.createElement(GridColumn, {
|
29
|
+
wide: "8",
|
30
|
+
desktop: "10",
|
31
|
+
tablet: "12",
|
32
|
+
mobile: "12"
|
33
|
+
}, renderContent()));
|
34
|
+
};
|
35
|
+
|
36
|
+
return /*#__PURE__*/React.createElement("div", {
|
37
|
+
className: cn({
|
38
|
+
'text-center': textCenter
|
39
|
+
}, [className]),
|
40
|
+
ref: rootRef
|
41
|
+
}, isFullWidth ? renderContent() : renderTextBoxWithGrid());
|
42
|
+
};
|
43
|
+
|
44
|
+
TextBox.propTypes = {
|
45
|
+
textCenter: PropTypes.bool,
|
46
|
+
centeringWithLimitedWidth: PropTypes.bool,
|
47
|
+
isFullWidth: PropTypes.bool,
|
48
|
+
rootRef: PropTypes.oneOfType([PropTypes.func, PropTypes.oneOfType([PropTypes.shape({
|
49
|
+
current: PropTypes.elementType
|
50
|
+
}), PropTypes.any])]),
|
51
|
+
className: PropTypes.string
|
52
|
+
};
|
53
|
+
export default TextBox;
|
@@ -0,0 +1,24 @@
|
|
1
|
+
h1,
|
2
|
+
h2,
|
3
|
+
h3,
|
4
|
+
h4,
|
5
|
+
h5 {
|
6
|
+
margin: 0;
|
7
|
+
}
|
8
|
+
.mfui-beta-text-box-picture_margin_default {
|
9
|
+
margin: 16px 0;
|
10
|
+
}
|
11
|
+
.mfui-beta-text-box-picture_margin_big-top {
|
12
|
+
margin: 24px 0 16px;
|
13
|
+
}
|
14
|
+
.mfui-beta-text-box-picture_margin_big-bottom {
|
15
|
+
margin: 16px 0 24px;
|
16
|
+
}
|
17
|
+
.mfui-beta-text-box-picture_margin_big-vertical {
|
18
|
+
margin: 24px 0;
|
19
|
+
}
|
20
|
+
.mfui-beta-text-box-picture__img {
|
21
|
+
display: block;
|
22
|
+
max-width: 100%;
|
23
|
+
border: 1px solid #EDEDED;
|
24
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import './TextBoxPicture.less';
|
3
|
+
export declare const pictureMarginTypes: {
|
4
|
+
readonly DEFAULT: "default";
|
5
|
+
readonly BIG_TOP: "big-top";
|
6
|
+
readonly BIG_BOTTOM: "big-bottom";
|
7
|
+
readonly BIG_VERTICAL: "big-vertical";
|
8
|
+
};
|
9
|
+
declare type PictureMarginTypesType = typeof pictureMarginTypes[keyof typeof pictureMarginTypes];
|
10
|
+
export interface ITextBoxPictureProps {
|
11
|
+
/** URL картинки */
|
12
|
+
url: string;
|
13
|
+
/** Значение вертикальных отступов */
|
14
|
+
margin?: PictureMarginTypesType;
|
15
|
+
}
|
16
|
+
declare const TextBoxPicture: React.FC<ITextBoxPictureProps>;
|
17
|
+
export default TextBoxPicture;
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import * as React from 'react';
|
2
|
+
import * as PropTypes from 'prop-types';
|
3
|
+
import { cnCreate } from '@megafon/ui-helpers';
|
4
|
+
import "./TextBoxPicture.css";
|
5
|
+
export var pictureMarginTypes = {
|
6
|
+
DEFAULT: 'default',
|
7
|
+
BIG_TOP: 'big-top',
|
8
|
+
BIG_BOTTOM: 'big-bottom',
|
9
|
+
BIG_VERTICAL: 'big-vertical'
|
10
|
+
};
|
11
|
+
var cn = cnCreate('mfui-beta-text-box-picture');
|
12
|
+
|
13
|
+
var TextBoxPicture = function TextBoxPicture(_ref) {
|
14
|
+
var url = _ref.url,
|
15
|
+
_ref$margin = _ref.margin,
|
16
|
+
margin = _ref$margin === void 0 ? pictureMarginTypes.DEFAULT : _ref$margin;
|
17
|
+
return /*#__PURE__*/React.createElement("div", {
|
18
|
+
className: cn({
|
19
|
+
margin: margin
|
20
|
+
})
|
21
|
+
}, /*#__PURE__*/React.createElement("img", {
|
22
|
+
className: cn('img'),
|
23
|
+
src: url
|
24
|
+
}));
|
25
|
+
};
|
26
|
+
|
27
|
+
TextBoxPicture.propTypes = {
|
28
|
+
url: PropTypes.string.isRequired,
|
29
|
+
margin: PropTypes.oneOf([pictureMarginTypes.DEFAULT, pictureMarginTypes.BIG_TOP, pictureMarginTypes.BIG_BOTTOM, pictureMarginTypes.BIG_VERTICAL])
|
30
|
+
};
|
31
|
+
export default TextBoxPicture;
|
@@ -9,6 +9,9 @@ h5 {
|
|
9
9
|
font-family: inherit;
|
10
10
|
color: #333333;
|
11
11
|
}
|
12
|
+
.mfui-beta-title-description-box__item_header {
|
13
|
+
white-space: pre-wrap;
|
14
|
+
}
|
12
15
|
.mfui-beta-title-description-box__item:not(:last-child) {
|
13
16
|
margin-bottom: 16px;
|
14
17
|
}
|
@@ -18,3 +21,11 @@ h5 {
|
|
18
21
|
.mfui-beta-title-description-box_h-align_center {
|
19
22
|
text-align: center;
|
20
23
|
}
|
24
|
+
.mfui-beta-title-description-box__description {
|
25
|
+
font-size: 15px;
|
26
|
+
line-height: 24px;
|
27
|
+
font-weight: 400;
|
28
|
+
}
|
29
|
+
.mfui-beta-title-description-box__description :last-child {
|
30
|
+
margin-bottom: 0 !important;
|
31
|
+
}
|
@@ -1,15 +1,21 @@
|
|
1
1
|
import * as React from 'react';
|
2
2
|
import './TitleDescriptionBox.less';
|
3
3
|
export interface ITitleDescriptionBoxProps {
|
4
|
-
/**
|
4
|
+
/** Дата атрибуты для корневого элемента */
|
5
|
+
dataAttrs?: {
|
6
|
+
[key: string]: string;
|
7
|
+
};
|
8
|
+
/** Ссылка на корневой элемент */
|
9
|
+
rootRef?: React.Ref<HTMLDivElement>;
|
10
|
+
/** Дополнительный класс корневого элемента */
|
5
11
|
className?: string;
|
6
|
-
/**
|
7
|
-
title?: string;
|
8
|
-
/**
|
9
|
-
description?: string;
|
10
|
-
/**
|
12
|
+
/** Заголовок */
|
13
|
+
title?: string | React.ReactNode[] | React.ReactNode;
|
14
|
+
/** Описание */
|
15
|
+
description?: string | React.ReactNode[] | React.ReactNode;
|
16
|
+
/** Цвет текста */
|
11
17
|
textColor?: 'white';
|
12
|
-
/**
|
18
|
+
/** Горизонтальное выравнивание */
|
13
19
|
hAlign?: 'center';
|
14
20
|
}
|
15
21
|
declare const TitleDescriptionBox: React.FC<ITitleDescriptionBoxProps>;
|
@@ -1,42 +1,62 @@
|
|
1
1
|
import "core-js/modules/es.symbol";
|
2
2
|
import "core-js/modules/es.symbol.description";
|
3
|
+
import _extends from "@babel/runtime/helpers/extends";
|
3
4
|
import * as React from 'react';
|
4
5
|
import * as PropTypes from 'prop-types';
|
5
|
-
import {
|
6
|
+
import { Header, Paragraph, Grid, GridColumn } from '@megafon/ui-core';
|
7
|
+
import { cnCreate, filterDataAttrs } from '@megafon/ui-helpers';
|
6
8
|
import "./TitleDescriptionBox.css";
|
7
9
|
var cn = cnCreate('mfui-beta-title-description-box');
|
8
10
|
|
9
11
|
var TitleDescriptionBox = function TitleDescriptionBox(_ref) {
|
10
|
-
var
|
12
|
+
var dataAttrs = _ref.dataAttrs,
|
13
|
+
title = _ref.title,
|
11
14
|
description = _ref.description,
|
12
15
|
textColor = _ref.textColor,
|
13
16
|
hAlign = _ref.hAlign,
|
17
|
+
rootRef = _ref.rootRef,
|
14
18
|
className = _ref.className;
|
15
|
-
|
19
|
+
var renderDescription = React.useCallback(function () {
|
20
|
+
if (typeof description === 'string') {
|
21
|
+
return /*#__PURE__*/React.createElement(Paragraph, {
|
22
|
+
className: cn('item'),
|
23
|
+
hasMargin: false,
|
24
|
+
color: "inherit"
|
25
|
+
}, description);
|
26
|
+
}
|
27
|
+
|
28
|
+
return /*#__PURE__*/React.createElement("div", {
|
29
|
+
className: cn('description')
|
30
|
+
}, description);
|
31
|
+
}, [description]);
|
32
|
+
return /*#__PURE__*/React.createElement("div", _extends({}, filterDataAttrs(dataAttrs), {
|
16
33
|
className: cn({
|
17
34
|
'h-align': hAlign,
|
18
35
|
'text-color': textColor
|
19
|
-
}, className)
|
20
|
-
|
36
|
+
}, className),
|
37
|
+
ref: rootRef
|
38
|
+
}), /*#__PURE__*/React.createElement(Grid, {
|
21
39
|
hAlign: hAlign
|
22
40
|
}, /*#__PURE__*/React.createElement(GridColumn, {
|
23
41
|
wide: "8",
|
24
42
|
desktop: "10"
|
25
43
|
}, title && /*#__PURE__*/React.createElement(Header, {
|
26
|
-
className: cn('item'
|
44
|
+
className: cn('item', {
|
45
|
+
header: true
|
46
|
+
}),
|
27
47
|
as: "h2",
|
28
48
|
color: "inherit"
|
29
|
-
}, title), description &&
|
30
|
-
className: cn('item'),
|
31
|
-
hasMargin: false,
|
32
|
-
color: "inherit"
|
33
|
-
}, description))));
|
49
|
+
}, title), description && renderDescription())));
|
34
50
|
};
|
35
51
|
|
36
52
|
TitleDescriptionBox.propTypes = {
|
53
|
+
dataAttrs: PropTypes.objectOf(PropTypes.string.isRequired),
|
54
|
+
rootRef: PropTypes.oneOfType([PropTypes.func, PropTypes.oneOfType([PropTypes.shape({
|
55
|
+
current: PropTypes.elementType
|
56
|
+
}), PropTypes.any])]),
|
37
57
|
className: PropTypes.string,
|
38
|
-
title: PropTypes.string,
|
39
|
-
description: PropTypes.string,
|
58
|
+
title: PropTypes.oneOfType([PropTypes.string, PropTypes.arrayOf(PropTypes.node)]),
|
59
|
+
description: PropTypes.oneOfType([PropTypes.string, PropTypes.arrayOf(PropTypes.node)]),
|
40
60
|
hAlign: PropTypes.oneOf(['center']),
|
41
61
|
textColor: PropTypes.oneOf(['white'])
|
42
62
|
};
|