@redneckz/wildless-cms-uni-blocks 0.6.28 → 0.6.29
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/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +161 -100
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Carousel/Carousel.d.ts +5 -0
- package/bundle/components/Carousel/CarouselContainer.d.ts +6 -0
- package/bundle/components/Carousel/CarouselContent.d.ts +10 -0
- package/bundle/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/bundle/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/bundle/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/bundle/components/Header/HeaderContent.d.ts +0 -6
- package/bundle/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/bundle/components/RollupItem/RollupItem.d.ts +3 -0
- package/bundle/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/bundle/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/bundle/hooks/useCarousel.d.ts +14 -0
- package/bundle/icons/IconName.d.ts +4 -2
- package/bundle/model/CarouselCardVersion.d.ts +1 -0
- package/bundle/services/sitemap/SitemapProps.d.ts +5 -0
- package/bundle/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/bundle/ui-kit/Input/InputProps.d.ts +1 -2
- package/bundle/ui-kit/Select/Select.d.ts +3 -3
- package/cosmos-static/icons/HuaweiIcon.svg +1 -0
- package/dist/components/Blocks.js +7 -1
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Carousel/Carousel.d.ts +5 -0
- package/dist/components/Carousel/Carousel.js +28 -0
- package/dist/components/Carousel/Carousel.js.map +1 -0
- package/dist/components/Carousel/CarouselContainer.d.ts +6 -0
- package/dist/components/Carousel/CarouselContainer.js +11 -0
- package/dist/components/Carousel/CarouselContainer.js.map +1 -0
- package/dist/components/Carousel/CarouselContent.d.ts +10 -0
- package/dist/components/Carousel/CarouselContent.js +2 -0
- package/dist/components/Carousel/CarouselContent.js.map +1 -0
- package/dist/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/dist/components/CarouselCard/CarouselCard.js +20 -0
- package/dist/components/CarouselCard/CarouselCard.js.map +1 -0
- package/dist/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/dist/components/CarouselCard/CarouselCardContent.js +2 -0
- package/dist/components/CarouselCard/CarouselCardContent.js.map +1 -0
- package/dist/components/ComparisonTable/ComparisonTableBody.js +6 -6
- package/dist/components/ComparisonTable/ComparisonTableBody.js.map +1 -1
- package/dist/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/dist/components/ComparisonTable/ComparisonTableRows.js +10 -3
- package/dist/components/ComparisonTable/ComparisonTableRows.js.map +1 -1
- package/dist/components/Header/Header.js +2 -2
- package/dist/components/Header/Header.js.map +1 -1
- package/dist/components/Header/Header.mobile.js +2 -2
- package/dist/components/Header/Header.mobile.js.map +1 -1
- package/dist/components/Header/HeaderContent.d.ts +0 -6
- package/dist/components/Header/HeaderSecondaryMenu.js +1 -1
- package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
- package/dist/components/Recommendation/RecommendationCard.js +3 -2
- package/dist/components/Recommendation/RecommendationCard.js.map +1 -1
- package/dist/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/dist/components/RollupItem/RollupItem.d.ts +3 -0
- package/dist/components/RollupItem/RollupItem.js +18 -0
- package/dist/components/RollupItem/RollupItem.js.map +1 -0
- package/dist/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/dist/components/RollupItem/RollupItemContent.js +2 -0
- package/dist/components/RollupItem/RollupItemContent.js.map +1 -0
- package/dist/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/dist/components/RollupItem/RollupItemProps.js +2 -0
- package/dist/components/RollupItem/RollupItemProps.js.map +1 -0
- package/dist/components/TariffsTable/TariffsTable.js +16 -11
- package/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/dist/components/VerticalLayout/VerticalLayout.js +1 -1
- package/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/dist/hooks/useCarousel.d.ts +14 -0
- package/dist/hooks/useCarousel.js +24 -0
- package/dist/hooks/useCarousel.js.map +1 -0
- package/dist/icons/IconName.d.ts +4 -2
- package/dist/icons/IconName.js +3 -1
- package/dist/icons/IconName.js.map +1 -1
- package/dist/model/BlurVersion.d.ts +0 -0
- package/dist/model/BlurVersion.js +1 -0
- package/dist/model/BlurVersion.js.map +1 -0
- package/dist/model/CarouselCardVersion.d.ts +1 -0
- package/dist/model/CarouselCardVersion.js +2 -0
- package/dist/model/CarouselCardVersion.js.map +1 -0
- package/dist/services/sitemap/SitemapProps.d.ts +5 -0
- package/dist/ui-kit/Foldable/DefaultFoldButton.js +1 -1
- package/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/dist/ui-kit/InnerTable/InnerTable.js +1 -1
- package/dist/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/dist/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/dist/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.js +0 -0
- package/dist/ui-kit/InnerTable/useTariffsInnerTableData.js.map +1 -0
- package/dist/ui-kit/Input/InputProps.d.ts +1 -2
- package/dist/ui-kit/Logo/Logo.js +4 -1
- package/dist/ui-kit/Logo/Logo.js.map +1 -1
- package/dist/ui-kit/Select/Select.d.ts +3 -3
- package/dist/ui-kit/Select/Select.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Blocks.js +7 -1
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Carousel/Carousel.d.ts +5 -0
- package/lib/components/Carousel/Carousel.fixture.d.ts +7 -0
- package/lib/components/Carousel/Carousel.js +26 -0
- package/lib/components/Carousel/Carousel.js.map +1 -0
- package/lib/components/Carousel/CarouselContainer.d.ts +6 -0
- package/lib/components/Carousel/CarouselContainer.js +9 -0
- package/lib/components/Carousel/CarouselContainer.js.map +1 -0
- package/lib/components/Carousel/CarouselContent.d.ts +10 -0
- package/lib/components/Carousel/CarouselContent.js +2 -0
- package/lib/components/Carousel/CarouselContent.js.map +1 -0
- package/lib/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/lib/components/CarouselCard/CarouselCard.fixture.d.ts +11 -0
- package/lib/components/CarouselCard/CarouselCard.js +18 -0
- package/lib/components/CarouselCard/CarouselCard.js.map +1 -0
- package/lib/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/lib/components/CarouselCard/CarouselCardContent.js +2 -0
- package/lib/components/CarouselCard/CarouselCardContent.js.map +1 -0
- package/lib/components/ComparisonTable/ComparisonTableBody.js +6 -6
- package/lib/components/ComparisonTable/ComparisonTableBody.js.map +1 -1
- package/lib/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/lib/components/ComparisonTable/ComparisonTableRows.js +10 -3
- package/lib/components/ComparisonTable/ComparisonTableRows.js.map +1 -1
- package/lib/components/Header/Header.js +2 -2
- package/lib/components/Header/Header.js.map +1 -1
- package/lib/components/Header/Header.mobile.js +2 -2
- package/lib/components/Header/Header.mobile.js.map +1 -1
- package/lib/components/Header/HeaderContent.d.ts +0 -6
- package/lib/components/Header/HeaderSecondaryMenu.js +1 -1
- package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
- package/lib/components/Recommendation/RecommendationCard.js +3 -2
- package/lib/components/Recommendation/RecommendationCard.js.map +1 -1
- package/lib/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/lib/components/RollupItem/RollupItem.d.ts +3 -0
- package/lib/components/RollupItem/RollupItem.fixture.d.ts +7 -0
- package/lib/components/RollupItem/RollupItem.js +16 -0
- package/lib/components/RollupItem/RollupItem.js.map +1 -0
- package/lib/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/lib/components/RollupItem/RollupItemContent.js +2 -0
- package/lib/components/RollupItem/RollupItemContent.js.map +1 -0
- package/lib/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/lib/components/RollupItem/RollupItemProps.js +2 -0
- package/lib/components/RollupItem/RollupItemProps.js.map +1 -0
- package/lib/components/TariffsTable/TariffsTable.js +16 -11
- package/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/lib/components/VerticalLayout/VerticalLayout.fixture.d.ts +4 -0
- package/lib/components/VerticalLayout/VerticalLayout.js +1 -1
- package/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/lib/hooks/useCarousel.d.ts +14 -0
- package/lib/hooks/useCarousel.js +21 -0
- package/lib/hooks/useCarousel.js.map +1 -0
- package/lib/icons/IconName.d.ts +4 -2
- package/lib/icons/IconName.js +3 -1
- package/lib/icons/IconName.js.map +1 -1
- package/lib/model/BlurVersion.d.ts +0 -0
- package/lib/model/BlurVersion.js +1 -0
- package/lib/model/BlurVersion.js.map +1 -0
- package/lib/model/CarouselCardVersion.d.ts +1 -0
- package/lib/model/CarouselCardVersion.js +2 -0
- package/lib/model/CarouselCardVersion.js.map +1 -0
- package/lib/services/sitemap/SitemapProps.d.ts +5 -0
- package/lib/ui-kit/Foldable/DefaultFoldButton.js +1 -1
- package/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/lib/ui-kit/InnerTable/InnerTable.js +1 -1
- package/lib/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/lib/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/lib/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.js +0 -0
- package/lib/ui-kit/InnerTable/useTariffsInnerTableData.js.map +1 -0
- package/lib/ui-kit/Input/InputProps.d.ts +1 -2
- package/lib/ui-kit/Logo/Logo.js +4 -1
- package/lib/ui-kit/Logo/Logo.js.map +1 -1
- package/lib/ui-kit/Select/Select.d.ts +3 -3
- package/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +3 -3
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Carousel/Carousel.d.ts +5 -0
- package/mobile/bundle/components/Carousel/CarouselContainer.d.ts +6 -0
- package/mobile/bundle/components/Carousel/CarouselContent.d.ts +10 -0
- package/mobile/bundle/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/mobile/bundle/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/mobile/bundle/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/mobile/bundle/components/Header/HeaderContent.d.ts +0 -6
- package/mobile/bundle/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/mobile/bundle/components/RollupItem/RollupItem.d.ts +3 -0
- package/mobile/bundle/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/mobile/bundle/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/mobile/bundle/hooks/useCarousel.d.ts +14 -0
- package/mobile/bundle/icons/IconName.d.ts +4 -2
- package/mobile/bundle/model/CarouselCardVersion.d.ts +1 -0
- package/mobile/bundle/services/sitemap/SitemapProps.d.ts +5 -0
- package/mobile/bundle/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/mobile/bundle/ui-kit/Input/InputProps.d.ts +1 -2
- package/mobile/bundle/ui-kit/Select/Select.d.ts +3 -3
- package/mobile/dist/components/Carousel/Carousel.d.ts +5 -0
- package/mobile/dist/components/Carousel/Carousel.js +28 -0
- package/mobile/dist/components/Carousel/Carousel.js.map +1 -0
- package/mobile/dist/components/Carousel/CarouselContainer.d.ts +6 -0
- package/mobile/dist/components/Carousel/CarouselContainer.js +11 -0
- package/mobile/dist/components/Carousel/CarouselContainer.js.map +1 -0
- package/mobile/dist/components/Carousel/CarouselContent.d.ts +10 -0
- package/mobile/dist/components/Carousel/CarouselContent.js +2 -0
- package/mobile/dist/components/Carousel/CarouselContent.js.map +1 -0
- package/mobile/dist/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/mobile/dist/components/CarouselCard/CarouselCard.js +20 -0
- package/mobile/dist/components/CarouselCard/CarouselCard.js.map +1 -0
- package/mobile/dist/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/mobile/dist/components/CarouselCard/CarouselCardContent.js +2 -0
- package/mobile/dist/components/CarouselCard/CarouselCardContent.js.map +1 -0
- package/mobile/dist/components/ComparisonTable/ComparisonTableBody.js +6 -6
- package/mobile/dist/components/ComparisonTable/ComparisonTableBody.js.map +1 -1
- package/mobile/dist/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/mobile/dist/components/ComparisonTable/ComparisonTableRows.js +10 -3
- package/mobile/dist/components/ComparisonTable/ComparisonTableRows.js.map +1 -1
- package/mobile/dist/components/Header/Header.js +2 -2
- package/mobile/dist/components/Header/Header.js.map +1 -1
- package/mobile/dist/components/Header/HeaderContent.d.ts +0 -6
- package/mobile/dist/components/Header/HeaderSecondaryMenu.js +1 -1
- package/mobile/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
- package/mobile/dist/components/Recommendation/RecommendationCard.js +3 -2
- package/mobile/dist/components/Recommendation/RecommendationCard.js.map +1 -1
- package/mobile/dist/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/mobile/dist/components/RollupItem/RollupItem.d.ts +3 -0
- package/mobile/dist/components/RollupItem/RollupItem.js +18 -0
- package/mobile/dist/components/RollupItem/RollupItem.js.map +1 -0
- package/mobile/dist/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/mobile/dist/components/RollupItem/RollupItemContent.js +2 -0
- package/mobile/dist/components/RollupItem/RollupItemContent.js.map +1 -0
- package/mobile/dist/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/mobile/dist/components/RollupItem/RollupItemProps.js +2 -0
- package/mobile/dist/components/RollupItem/RollupItemProps.js.map +1 -0
- package/mobile/dist/components/VerticalLayout/VerticalLayout.js +1 -1
- package/mobile/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/mobile/dist/hooks/useCarousel.d.ts +14 -0
- package/mobile/dist/hooks/useCarousel.js +24 -0
- package/mobile/dist/hooks/useCarousel.js.map +1 -0
- package/mobile/dist/icons/IconName.d.ts +4 -2
- package/mobile/dist/icons/IconName.js +3 -1
- package/mobile/dist/icons/IconName.js.map +1 -1
- package/mobile/dist/model/BlurVersion.d.ts +0 -0
- package/mobile/dist/model/BlurVersion.js +1 -0
- package/mobile/dist/model/BlurVersion.js.map +1 -0
- package/mobile/dist/model/CarouselCardVersion.d.ts +1 -0
- package/mobile/dist/model/CarouselCardVersion.js +2 -0
- package/mobile/dist/model/CarouselCardVersion.js.map +1 -0
- package/mobile/dist/services/sitemap/SitemapProps.d.ts +5 -0
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js +1 -1
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/mobile/dist/ui-kit/InnerTable/InnerTable.js +1 -1
- package/mobile/dist/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/mobile/dist/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/mobile/dist/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.js +0 -0
- package/mobile/dist/ui-kit/InnerTable/useTariffsInnerTableData.js.map +1 -0
- package/mobile/dist/ui-kit/Input/InputProps.d.ts +1 -2
- package/mobile/dist/ui-kit/Select/Select.d.ts +3 -3
- package/mobile/dist/ui-kit/Select/Select.js.map +1 -1
- package/mobile/lib/components/Carousel/Carousel.d.ts +5 -0
- package/mobile/lib/components/Carousel/Carousel.js +26 -0
- package/mobile/lib/components/Carousel/Carousel.js.map +1 -0
- package/mobile/lib/components/Carousel/CarouselContainer.d.ts +6 -0
- package/mobile/lib/components/Carousel/CarouselContainer.js +9 -0
- package/mobile/lib/components/Carousel/CarouselContainer.js.map +1 -0
- package/mobile/lib/components/Carousel/CarouselContent.d.ts +10 -0
- package/mobile/lib/components/Carousel/CarouselContent.js +2 -0
- package/mobile/lib/components/Carousel/CarouselContent.js.map +1 -0
- package/mobile/lib/components/CarouselCard/CarouselCard.d.ts +7 -0
- package/mobile/lib/components/CarouselCard/CarouselCard.js +18 -0
- package/mobile/lib/components/CarouselCard/CarouselCard.js.map +1 -0
- package/mobile/lib/components/CarouselCard/CarouselCardContent.d.ts +14 -0
- package/mobile/lib/components/CarouselCard/CarouselCardContent.js +2 -0
- package/mobile/lib/components/CarouselCard/CarouselCardContent.js.map +1 -0
- package/mobile/lib/components/ComparisonTable/ComparisonTableBody.js +6 -6
- package/mobile/lib/components/ComparisonTable/ComparisonTableBody.js.map +1 -1
- package/mobile/lib/components/ComparisonTable/ComparisonTableRows.d.ts +4 -2
- package/mobile/lib/components/ComparisonTable/ComparisonTableRows.js +10 -3
- package/mobile/lib/components/ComparisonTable/ComparisonTableRows.js.map +1 -1
- package/mobile/lib/components/Header/Header.js +2 -2
- package/mobile/lib/components/Header/Header.js.map +1 -1
- package/mobile/lib/components/Header/HeaderContent.d.ts +0 -6
- package/mobile/lib/components/Header/HeaderSecondaryMenu.js +1 -1
- package/mobile/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
- package/mobile/lib/components/Recommendation/RecommendationCard.js +3 -2
- package/mobile/lib/components/Recommendation/RecommendationCard.js.map +1 -1
- package/mobile/lib/components/Recommendation/RecommendationContent.d.ts +8 -0
- package/mobile/lib/components/RollupItem/RollupItem.d.ts +3 -0
- package/mobile/lib/components/RollupItem/RollupItem.js +16 -0
- package/mobile/lib/components/RollupItem/RollupItem.js.map +1 -0
- package/mobile/lib/components/RollupItem/RollupItemContent.d.ts +12 -0
- package/mobile/lib/components/RollupItem/RollupItemContent.js +2 -0
- package/mobile/lib/components/RollupItem/RollupItemContent.js.map +1 -0
- package/mobile/lib/components/RollupItem/RollupItemProps.d.ts +4 -0
- package/mobile/lib/components/RollupItem/RollupItemProps.js +2 -0
- package/mobile/lib/components/RollupItem/RollupItemProps.js.map +1 -0
- package/mobile/lib/components/VerticalLayout/VerticalLayout.js +1 -1
- package/mobile/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/mobile/lib/hooks/useCarousel.d.ts +14 -0
- package/mobile/lib/hooks/useCarousel.js +21 -0
- package/mobile/lib/hooks/useCarousel.js.map +1 -0
- package/mobile/lib/icons/IconName.d.ts +4 -2
- package/mobile/lib/icons/IconName.js +3 -1
- package/mobile/lib/icons/IconName.js.map +1 -1
- package/mobile/lib/model/BlurVersion.d.ts +0 -0
- package/mobile/lib/model/BlurVersion.js +1 -0
- package/mobile/lib/model/BlurVersion.js.map +1 -0
- package/mobile/lib/model/CarouselCardVersion.d.ts +1 -0
- package/mobile/lib/model/CarouselCardVersion.js +2 -0
- package/mobile/lib/model/CarouselCardVersion.js.map +1 -0
- package/mobile/lib/services/sitemap/SitemapProps.d.ts +5 -0
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js +1 -1
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/mobile/lib/ui-kit/InnerTable/InnerTable.js +1 -1
- package/mobile/lib/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/mobile/lib/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.d.ts +0 -0
- package/mobile/lib/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.js +0 -0
- package/mobile/lib/ui-kit/InnerTable/useTariffsInnerTableData.js.map +1 -0
- package/mobile/lib/ui-kit/Input/InputProps.d.ts +1 -2
- package/mobile/lib/ui-kit/Select/Select.d.ts +3 -3
- package/mobile/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/src/components/Carousel/Carousel.example.json +6 -0
- package/mobile/src/components/Carousel/Carousel.tsx +70 -0
- package/mobile/src/components/Carousel/CarouselContainer.tsx +26 -0
- package/mobile/src/components/Carousel/CarouselContent.ts +10 -0
- package/mobile/src/components/CarouselCard/CarouselCard.example.json +11 -0
- package/mobile/src/components/CarouselCard/CarouselCard.tsx +49 -0
- package/mobile/src/components/CarouselCard/CarouselCard.ui.json +1 -0
- package/mobile/src/components/CarouselCard/CarouselCardContent.ts +15 -0
- package/mobile/src/components/ComparisonTable/ComparisonTableBody.tsx +10 -10
- package/mobile/src/components/ComparisonTable/ComparisonTableRows.tsx +20 -6
- package/mobile/src/components/Header/Header.tsx +49 -51
- package/mobile/src/components/Header/HeaderContent.ts +0 -6
- package/mobile/src/components/Header/HeaderSecondaryMenu.tsx +1 -1
- package/mobile/src/components/MobileAppTile/MobileAppTile.example.json +3 -5
- package/mobile/src/components/Recommendation/RecommendationCard.tsx +5 -1
- package/mobile/src/components/Recommendation/RecommendationContent.ts +8 -0
- package/mobile/src/components/RollupItem/RollupItem.example.json +23 -0
- package/mobile/src/components/RollupItem/RollupItem.tsx +86 -0
- package/mobile/src/components/RollupItem/RollupItem.ui.json +1 -0
- package/mobile/src/components/RollupItem/RollupItemContent.ts +13 -0
- package/mobile/src/components/RollupItem/RollupItemProps.ts +4 -0
- package/mobile/src/components/VerticalLayout/VerticalLayout.tsx +1 -1
- package/mobile/src/hooks/useCarousel.ts +55 -0
- package/mobile/src/icons/HuaweiIcon.svg +1 -0
- package/mobile/src/icons/IconName.ts +5 -5
- package/mobile/src/model/BlurVersion.ts +0 -0
- package/mobile/src/model/CarouselCardVersion.ts +1 -0
- package/mobile/src/services/sitemap/SitemapProps.ts +5 -0
- package/mobile/src/ui-kit/Foldable/DefaultFoldButton.tsx +1 -1
- package/mobile/src/ui-kit/InnerTable/InnerTable.tsx +1 -1
- package/mobile/src/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.ts +0 -0
- package/mobile/src/ui-kit/Input/InputProps.ts +1 -2
- package/mobile/src/ui-kit/Select/Select.tsx +3 -3
- package/package.json +1 -1
- package/src/components/Blocks.ts +7 -1
- package/src/components/Carousel/Carousel.example.json +6 -0
- package/src/components/Carousel/Carousel.fixture.tsx +48 -0
- package/src/components/Carousel/Carousel.tsx +70 -0
- package/src/components/Carousel/CarouselContainer.tsx +26 -0
- package/src/components/Carousel/CarouselContent.ts +10 -0
- package/src/components/CarouselCard/CarouselCard.example.json +11 -0
- package/src/components/CarouselCard/CarouselCard.fixture.tsx +47 -0
- package/src/components/CarouselCard/CarouselCard.tsx +49 -0
- package/src/components/CarouselCard/CarouselCard.ui.json +1 -0
- package/src/components/CarouselCard/CarouselCardContent.ts +15 -0
- package/src/components/ComparisonTable/ComparisonTableBody.tsx +10 -10
- package/src/components/ComparisonTable/ComparisonTableRows.tsx +20 -6
- package/src/components/Header/Header.fixture.mobile.tsx +2 -2
- package/src/components/Header/Header.fixture.tsx +3 -3
- package/src/components/Header/Header.mobile.tsx +49 -51
- package/src/components/Header/Header.tsx +2 -9
- package/src/components/Header/HeaderContent.ts +0 -6
- package/src/components/Header/HeaderSecondaryMenu.tsx +1 -1
- package/src/components/MobileAppTile/MobileAppTile.example.json +3 -5
- package/src/components/Recommendation/RecommendationCard.tsx +5 -1
- package/src/components/Recommendation/RecommendationContent.ts +8 -0
- package/src/components/RollupItem/RollupItem.example.json +23 -0
- package/src/components/RollupItem/RollupItem.fixture.tsx +23 -0
- package/src/components/RollupItem/RollupItem.tsx +86 -0
- package/src/components/RollupItem/RollupItem.ui.json +1 -0
- package/src/components/RollupItem/RollupItemContent.ts +13 -0
- package/src/components/RollupItem/RollupItemProps.ts +4 -0
- package/src/components/TariffsTable/TariffsTable.tsx +30 -13
- package/src/components/VerticalLayout/VerticalLayout.fixture.tsx +46 -1
- package/src/components/VerticalLayout/VerticalLayout.tsx +1 -1
- package/src/hooks/useCarousel.ts +55 -0
- package/src/icons/HuaweiIcon.svg +1 -0
- package/src/icons/IconName.ts +5 -5
- package/src/model/BlurVersion.ts +0 -0
- package/src/model/CarouselCardVersion.ts +1 -0
- package/src/services/sitemap/SitemapProps.ts +5 -0
- package/src/ui-kit/Foldable/DefaultFoldButton.tsx +1 -1
- package/src/ui-kit/InnerTable/InnerTable.tsx +1 -1
- package/src/{hooks → ui-kit/InnerTable}/useTariffsInnerTableData.ts +0 -0
- package/src/ui-kit/Input/InputProps.ts +1 -2
- package/src/ui-kit/Logo/Logo.tsx +4 -1
- package/src/ui-kit/Select/Select.tsx +3 -3
- package/bundle/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/dist/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/dist/hooks/useTableArrowScrollControl.js +0 -21
- package/dist/hooks/useTableArrowScrollControl.js.map +0 -1
- package/dist/hooks/useTariffsInnerTableData.js.map +0 -1
- package/lib/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/lib/hooks/useTableArrowScrollControl.js +0 -18
- package/lib/hooks/useTableArrowScrollControl.js.map +0 -1
- package/lib/hooks/useTariffsInnerTableData.js.map +0 -1
- package/mobile/bundle/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/mobile/dist/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/mobile/dist/hooks/useTableArrowScrollControl.js +0 -21
- package/mobile/dist/hooks/useTableArrowScrollControl.js.map +0 -1
- package/mobile/dist/hooks/useTariffsInnerTableData.js.map +0 -1
- package/mobile/lib/hooks/useTableArrowScrollControl.d.ts +0 -5
- package/mobile/lib/hooks/useTableArrowScrollControl.js +0 -18
- package/mobile/lib/hooks/useTableArrowScrollControl.js.map +0 -1
- package/mobile/lib/hooks/useTariffsInnerTableData.js.map +0 -1
- package/mobile/src/hooks/useTableArrowScrollControl.ts +0 -28
- package/src/hooks/useTableArrowScrollControl.ts +0 -28
package/bundle/bundle.umd.js
CHANGED
|
@@ -446,9 +446,9 @@
|
|
|
446
446
|
});
|
|
447
447
|
|
|
448
448
|
const icons$1 = ['PlusIcon', 'MinusIcon'];
|
|
449
|
-
const AccordionItem = JSX(({ className = '', label = '', isExpanded, children }) => (jsx("li", { className: `border-0 border-b border-solid border-main-divider last:border-b-0 ${className}`, children: jsx(Foldable, { isFoldButtonOnTop: true, unfoldedByDefault: isExpanded, renderFoldableSection: ({ isUnfolded }) => (jsx(FoldableSection, { className: "grid grid-cols-12 gap-5 [&>*]:p-0", isUnfolded: isUnfolded, children: children })), renderFoldButton: ({ isUnfolded, onToggle }) => (jsx(FoldButton, { label: label, icon: icons$1[Number(isUnfolded)], onClick: onToggle })) }) })));
|
|
449
|
+
const AccordionItem = JSX(({ className = '', label = '', isExpanded, children }) => (jsx("li", { className: `border-0 border-b border-solid border-main-divider last:border-b-0 ${className}`, children: jsx(Foldable, { isFoldButtonOnTop: true, unfoldedByDefault: isExpanded, renderFoldableSection: ({ isUnfolded }) => (jsx(FoldableSection, { className: "grid grid-cols-12 gap-5 [&>*]:p-0", isUnfolded: isUnfolded, children: children })), renderFoldButton: ({ isUnfolded, onToggle }) => (jsx(FoldButton$1, { label: label, icon: icons$1[Number(isUnfolded)], onClick: onToggle })) }) })));
|
|
450
450
|
AccordionItem.childrenTypes = [];
|
|
451
|
-
const FoldButton = JSX(({ label, icon, onClick }) => (jsxs("button", { className: "border-none bg-transparent px-0 pt-5 pb-3.5 flex justify-between text-left w-full font-sans text-h6 group cursor-pointer", onClick: onClick, children: [jsx("span", { className: "text-xl font-medium pr-2.5", children: label }), jsx(ImgInner, { image: icon, className: "text-primary-main flex-shrink-0", width: "24", height: "24", asSVG: true })] })));
|
|
451
|
+
const FoldButton$1 = JSX(({ label, icon, onClick }) => (jsxs("button", { className: "border-none bg-transparent px-0 pt-5 pb-3.5 flex justify-between text-left w-full font-sans text-h6 group cursor-pointer", onClick: onClick, children: [jsx("span", { className: "text-xl font-medium pr-2.5", children: label }), jsx(ImgInner, { image: icon, className: "text-primary-main flex-shrink-0", width: "24", height: "24", asSVG: true })] })));
|
|
452
452
|
|
|
453
453
|
const VersionStyleMap = {
|
|
454
454
|
primary: 'bg-white text-primary-text',
|
|
@@ -1267,21 +1267,24 @@
|
|
|
1267
1267
|
}), jsx("div", { className: `${BLUR_BLOCK_CLASSES$2} left-0 bg-opacity-from-white` }), jsx("div", { className: `${BLUR_BLOCK_CLASSES$2} right-0 bg-opacity-to-white` })] }));
|
|
1268
1268
|
});
|
|
1269
1269
|
|
|
1270
|
-
const
|
|
1271
|
-
const [
|
|
1272
|
-
const
|
|
1273
|
-
const
|
|
1274
|
-
const isScrollAvailable =
|
|
1275
|
-
const
|
|
1276
|
-
const
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1270
|
+
const useCarouselControl = ({ itemsCount, visibleItemCount = itemsCount, isCyclic, }) => {
|
|
1271
|
+
const [activeIndex, setActiveIndex] = useState(0);
|
|
1272
|
+
const inc = useCallback(() => setActiveIndex((_) => (isCyclic ? (_ + 1) % itemsCount : Math.min(_ + 1, itemsCount - 1))), []);
|
|
1273
|
+
const dec = useCallback(() => setActiveIndex((_) => (isCyclic ? (itemsCount + _ - 1) % itemsCount : Math.max(_ - 1, 0))), []);
|
|
1274
|
+
const isScrollAvailable = itemsCount > visibleItemCount;
|
|
1275
|
+
const isCyclicAndScrollAvailable = isCyclic && isScrollAvailable;
|
|
1276
|
+
const canInc = isCyclicAndScrollAvailable ||
|
|
1277
|
+
(isScrollAvailable && itemsCount - activeIndex > visibleItemCount);
|
|
1278
|
+
const canDec = isCyclicAndScrollAvailable || Boolean(isScrollAvailable && activeIndex > 0);
|
|
1279
|
+
return [
|
|
1280
|
+
activeIndex,
|
|
1281
|
+
{
|
|
1282
|
+
inc,
|
|
1283
|
+
dec,
|
|
1284
|
+
canInc,
|
|
1285
|
+
canDec,
|
|
1286
|
+
},
|
|
1287
|
+
];
|
|
1285
1288
|
};
|
|
1286
1289
|
|
|
1287
1290
|
const GRADIENT = 'bg-gradient-to-r from-main-gradient-start to-main-gradient-end';
|
|
@@ -1303,16 +1306,6 @@
|
|
|
1303
1306
|
|
|
1304
1307
|
const ComparisonTableColumnHeaders = JSX(({ colHeaders, activeCardIndex }) => (jsxs(TableRowContainer, { children: [jsx("div", { className: FIRST_CELL_CLASSES$1, role: "columnheader" }), jsx(TableCarouselContainer, { activeCardIndex: activeCardIndex, columnWidth: COLUMN_WIDTH$2, children: colHeaders.map((header, i) => (jsx(HeaderCell, { ...header }, String(i)))) })] })));
|
|
1305
1308
|
|
|
1306
|
-
const TableArrowScrollControl = JSX(({ isScrollAvailable, onNextClick, onPrevClick, showNextButton, showPrevButton }) => {
|
|
1307
|
-
return isScrollAvailable ? (jsx("div", { children: renderArrows({
|
|
1308
|
-
handler: [onPrevClick, onNextClick],
|
|
1309
|
-
isShown: [showPrevButton, showNextButton],
|
|
1310
|
-
btnClass: ['top-[108px]', 'top-11'],
|
|
1311
|
-
className: 'right-7',
|
|
1312
|
-
isDisabled: true,
|
|
1313
|
-
}) })) : null;
|
|
1314
|
-
});
|
|
1315
|
-
|
|
1316
1309
|
const TableCell = JSX(({ cell, isFirstRow, isLastRow, isFillGradient }) => {
|
|
1317
1310
|
const cellWrapperClasses = `w-80 box-border flex flex-col ${BORDER_CLASSES$1} ${!isLastRow ? 'border-y-0' : 'border-t-0 rounded-b-md'} ${isFillGradient ? GRADIENT : ''}`;
|
|
1318
1311
|
const cellClasses = `mx-7 h-full ${DIVIDER_CLASSES$1} ${isFillGradient && isFirstRow ? 'border-t' : ''} ${!isLastRow ? 'border-solid' : 'border-b-0'}`;
|
|
@@ -1325,8 +1318,15 @@
|
|
|
1325
1318
|
const titleStyle = (isLastRow = false) => `text-s py-7 ${DIVIDER_CLASSES$1} ${FIRST_CELL_CLASSES$1} ${isLastRow ? 'border-b-0' : 'border-solid'}`;
|
|
1326
1319
|
const TableRow = JSX(({ row: { header, data }, activeCardIndex, isColoredFirstColumn, isFirstRow, isLastRow }) => (jsxs(TableRowContainer, { children: [header?.title ? jsx("div", { className: titleStyle(isLastRow), children: header.title }) : null, data?.length ? (jsx(TableCarouselContainer, { activeCardIndex: activeCardIndex, columnWidth: COLUMN_WIDTH$2, children: data.map((cell, i) => (jsx(TableCell, { cell: cell, isFirstRow: isFirstRow, isLastRow: isLastRow, isFillGradient: isColoredFirstColumn && i === 0 }, String(i)))) })) : null] })));
|
|
1327
1320
|
|
|
1328
|
-
const ComparisonTableRows = JSX(({ rowData, isColoredFirstColumn,
|
|
1329
|
-
|
|
1321
|
+
const ComparisonTableRows = JSX(({ rowData, isColoredFirstColumn, activeCardIndex, controls, isScrollAvailable }) => {
|
|
1322
|
+
const { inc, dec, canDec, canInc } = controls;
|
|
1323
|
+
return (jsxs("div", { className: "relative", children: [rowData.map((row, i, { length }) => (jsx(TableRow, { row: row, isFirstRow: i === 0, isLastRow: i + 1 === length, activeCardIndex: activeCardIndex, isColoredFirstColumn: isColoredFirstColumn }, String(i)))), isScrollAvailable ? (jsx("div", { children: renderArrows({
|
|
1324
|
+
handler: [inc, dec],
|
|
1325
|
+
isShown: [canDec, canInc],
|
|
1326
|
+
btnClass: ['top-[108px]', 'top-11'],
|
|
1327
|
+
className: 'right-7',
|
|
1328
|
+
isDisabled: true,
|
|
1329
|
+
}) })) : null] }));
|
|
1330
1330
|
});
|
|
1331
1331
|
|
|
1332
1332
|
const ComparisonTableBody = JSX(({ columns, rowHeaders, isShowAllRow, visibleRowLength, isColoredFirstColumn }) => {
|
|
@@ -1338,12 +1338,12 @@
|
|
|
1338
1338
|
data: colData.map((col) => col?.[i] || [{}]),
|
|
1339
1339
|
}))
|
|
1340
1340
|
.slice(0, isShowAllRow ? rowHeaders.length : visibleRowLength);
|
|
1341
|
-
const
|
|
1342
|
-
|
|
1343
|
-
|
|
1341
|
+
const isScrollAvailable = colData.length > COLS_LENGTH_FOR_SCROLL$1;
|
|
1342
|
+
const [activeIndex, controls] = useCarouselControl({
|
|
1343
|
+
itemsCount: colData.length,
|
|
1344
|
+
visibleItemCount: COLS_LENGTH_FOR_SCROLL$1,
|
|
1344
1345
|
});
|
|
1345
|
-
|
|
1346
|
-
return (jsxs("div", { children: [jsxs("div", { role: "table", children: [colHeaders?.length ? (jsx(ComparisonTableColumnHeaders, { colHeaders: colHeaders, activeCardIndex: activeCardIndex })) : null, rowData?.length ? (jsx(ComparisonTableRows, { rowData: rowData, isColoredFirstColumn: isColoredFirstColumn, ...tableArrowScrollProps })) : null] }), isScrollAvailable ? (jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })) : null] }));
|
|
1346
|
+
return (jsxs("div", { children: [jsxs("div", { role: "table", children: [colHeaders?.length ? (jsx(ComparisonTableColumnHeaders, { colHeaders: colHeaders, activeCardIndex: activeIndex })) : null, rowData?.length ? (jsx(ComparisonTableRows, { rowData: rowData, isColoredFirstColumn: isColoredFirstColumn, activeCardIndex: activeIndex, controls: controls, isScrollAvailable: isScrollAvailable })) : null] }), isScrollAvailable ? (jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })) : null] }));
|
|
1347
1347
|
});
|
|
1348
1348
|
|
|
1349
1349
|
const ComparisonTable = JSX(({ className = '', title, rowHeaders, columns, visibleRowLength = 0, isColoredFirstColumn = false, ...rest }) => {
|
|
@@ -1620,7 +1620,10 @@
|
|
|
1620
1620
|
transparent: 'text-white',
|
|
1621
1621
|
};
|
|
1622
1622
|
const Logo = JSX(({ className = '', href, logo, children = logo?.title, targetBlank, bgColor = 'bg-white', showTitle = true, }) => {
|
|
1623
|
-
return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className}`, href: href || '/', target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title || 'Россельхозбанк', children: [logo?.image?.src ? (jsx(ImgInner, { image: logo.image, className: SVG_COLOR[bgColor], width: "40", height: "45", asSVG: true })) : (jsx(ImgInner, { image: {
|
|
1623
|
+
return (jsxs("a", { className: `inline-flex items-center font-sans no-underline ${className}`, href: href || '/', target: targetBlank ? '_blank' : '_self', "aria-label": logo?.title || 'Россельхозбанк', children: [logo?.image?.src ? (jsx(ImgInner, { image: logo.image, className: SVG_COLOR[bgColor], width: "40", height: "45", asSVG: true })) : (jsx(ImgInner, { image: {
|
|
1624
|
+
icon: logo?.image?.icon || 'LogoIcon',
|
|
1625
|
+
iconVersion: ICON_VERSION_MAP[bgColor],
|
|
1626
|
+
}, className: `${SVG_COLOR[bgColor]} w-10`, width: "40", height: "45", asSVG: true })), showTitle ? renderTitle$2(children, bgColor, logo?.title) : null] }));
|
|
1624
1627
|
});
|
|
1625
1628
|
const renderTitle$2 = (children, bgColor, title) => {
|
|
1626
1629
|
const text = children || title || 'Россельхозбанк';
|
|
@@ -1924,7 +1927,7 @@
|
|
|
1924
1927
|
'bg-white': 'black',
|
|
1925
1928
|
transparent: 'white',
|
|
1926
1929
|
};
|
|
1927
|
-
const HeaderSecondaryMenu = JSX(({ className, defaultLocation = '', bgColor = 'bg-white' }) => {
|
|
1930
|
+
const HeaderSecondaryMenu = JSX(({ className, defaultLocation = 'Москва', bgColor = 'bg-white' }) => {
|
|
1928
1931
|
const [city, getCity] = useGeolocation(defaultLocation);
|
|
1929
1932
|
return (jsxs("div", { className: `flex items-center ${className || ''}`, children: [jsx(TopItem, { className: "mr-5", flat: true, href: "#", text: city, ariaLabel: "\u041C\u0435\u0441\u0442\u043E\u043F\u043E\u043B\u043E\u0436\u0435\u043D\u0438\u0435", onClick: getCity, bgColor: bgColor }), jsx(TopItem, { className: "mr-7", flat: true, href: "#", text: "\u041E\u0444\u0438\u0441\u044B \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u044B", ariaLabel: "\u0421\u043F\u0438\u0441\u043E\u043A \u0432\u0441\u0435\u0445 \u0434\u043E\u0441\u0442\u0443\u043F\u043D\u044B\u0445 \u043E\u0444\u0438\u0441\u043E\u0432 \u0438 \u0431\u0430\u043D\u043A\u043E\u043C\u0430\u0442\u043E\u0432", bgColor: bgColor }), jsx(HeaderSecondaryMenuButton, { className: `mr-5 group ${COLORS_MAP[bgColor]}`, ariaLabel: "\u041F\u043E\u0438\u0441\u043A \u043F\u043E \u0441\u0430\u0439\u0442\u0443", children: jsx(ImgInner, { image: { icon: 'LoupeIcon', iconVersion: LINKS_ICON_VERSION_MAP[bgColor] }, className: "h-full pointer-events-none", imageClassName: "group-hover:text-primary-hover group-hover:invert-0 pointer-events-none", asSVG: true }) }), jsx(HeaderSecondaryMenuButton, { className: `${LINKS_COLORS_MAP[bgColor]} group min-w-[32px] min-h-[32px]`, ariaLabel: "\u0414\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u044B\u0435 \u0441\u0441\u044B\u043B\u043A\u0438", children: jsx(ImgInner, { image: { icon: 'GridIcon', iconVersion: LINKS_ICON_VERSION_MAP[bgColor] }, className: "h-full bg-main-divider/20 rounded-full pointer-events-none", imageClassName: "group-hover:text-primary-hover group-hover:invert-0", asSVG: true }) })] }));
|
|
1930
1933
|
});
|
|
@@ -2007,9 +2010,9 @@
|
|
|
2007
2010
|
'bg-white': 'bg-main-divider',
|
|
2008
2011
|
transparent: 'bg-main-divider opacity-30',
|
|
2009
2012
|
};
|
|
2010
|
-
const Header = JSX(({ bgColor = 'bg-white', className = '',
|
|
2013
|
+
const Header = JSX(({ bgColor = 'bg-white', className = '', showSubMenu = true, ...rest }) => {
|
|
2011
2014
|
const router = useRouter();
|
|
2012
|
-
const { topItems } = useSWRResource(projectSettings.SITEMAP || 'sitemap', rest.page?.fallback);
|
|
2015
|
+
const { topItems, logo, defaultLocation } = useSWRResource(projectSettings.SITEMAP || 'sitemap', rest.page?.fallback);
|
|
2013
2016
|
const activeTopItem = showSubMenu ? getActiveItem(topItems, router) : null;
|
|
2014
2017
|
const topMenu = topItems?.map((_, i) => (jsx(TopItem, { active: _ === activeTopItem, "aria-label": _.text, bgColor: bgColor, ..._ }, String(i))));
|
|
2015
2018
|
return (jsx(BlockWrapper, { tag: "header", className: `pt-6 px-20 ${bgColor} ${className} ${showSubMenu && activeTopItem?.items?.length ? 'pb-4' : 'pb-5'}`, ...rest, children: jsxs("div", { className: "container", children: [jsxs("div", { className: "flex items-center", children: [jsx(Logo, { className: "mr-8", bgColor: bgColor, logo: logo }), topMenu, jsx(HeaderSecondaryMenu, { className: "ml-auto", defaultLocation: defaultLocation, bgColor: bgColor })] }), jsx("div", { className: `mt-6 h-[1px] ${BORDER_COLORS[bgColor]}` }), showSubMenu && activeTopItem?.items?.length ? (jsx(HeaderSubMenu, { subItems: activeTopItem.items, bgColor: bgColor })) : null] }) }));
|
|
@@ -2096,6 +2099,52 @@
|
|
|
2096
2099
|
return (jsx("button", { type: "button", onClick: onClick, "aria-label": title, className: `box-border px-4 py-3 text-m-light ${btnClassName}`, children: title }, String(i)));
|
|
2097
2100
|
}
|
|
2098
2101
|
|
|
2102
|
+
const BorderVersionStyleMap = {
|
|
2103
|
+
primary: 'border-main-stroke',
|
|
2104
|
+
secondary: 'border-white/50',
|
|
2105
|
+
};
|
|
2106
|
+
|
|
2107
|
+
const getItemListFontSize = (colValue) => (colValue === 'single' ? 'text-h6' : 'text-l');
|
|
2108
|
+
const cardColumnsModeStyleMap = {
|
|
2109
|
+
double: 'flex gap-y-2 gap-x-10 flex-wrap',
|
|
2110
|
+
single: 'flex gap-y-2 flex-col',
|
|
2111
|
+
};
|
|
2112
|
+
const InvestmentGalleryCard = JSX(({ className = '', columnsMode = 'double', description, additionalDescription, image, cardList, title, version = 'primary', }) => {
|
|
2113
|
+
const tileTitle = title ? (jsx(Heading, { headingType: "h4", as: "h3", className: "mb-3.5 z-10", title: title })) : null;
|
|
2114
|
+
const tileImage = image?.src ? (jsx(ImgInner, { className: "absolute bottom-0 right-0 m-0", image: image })) : null;
|
|
2115
|
+
return (jsx("section", { className: `relative overflow-hidden text-left border border-solid box-border
|
|
2116
|
+
p-9 min-w-[697px] min-h-[319px]
|
|
2117
|
+
${BorderVersionStyleMap[version]}
|
|
2118
|
+
${className}`, role: "listitem", children: jsx(BaseTile, { className: "flex justify-between", title: tileTitle, image: tileImage, children: jsxs("div", { className: "flex flex-col justify-between", children: [jsxs("div", { className: "flex itens-center justify-between mb-4", children: [description ? jsx(Description, { className: "text-h6", description: description }) : null, additionalDescription ? (jsxs("div", { className: "text-m-light text-secondary-text", children: [" ", additionalDescription, " "] })) : null] }), cardList?.length ? (jsx("div", { className: `${cardColumnsModeStyleMap[columnsMode]}`, role: "list", children: renderCardList(cardList, columnsMode) })) : null] }) }) }));
|
|
2119
|
+
});
|
|
2120
|
+
const renderCardList = (cardList, columnsMode) => cardList.map((item, i) => (jsxs("div", { className: columnsMode === 'double' ? 'basis-[calc(50%-20px)]' : '', role: "listitem", children: [item?.parameter ? (jsx("span", { className: `pr-2.5 ${getItemListFontSize(columnsMode)}`, children: item.parameter })) : null, item?.parameterDesccription ? (jsx("span", { className: "text-m-light text-secondary-text", children: item.parameterDesccription })) : null] }, String(i))));
|
|
2121
|
+
|
|
2122
|
+
const BLUR_BLOCK_CLASSES$1 = 'absolute top-0 bottom-0 w-[84px]';
|
|
2123
|
+
const CARD_FULL_VIEW_COUNT$1 = 1;
|
|
2124
|
+
const InvestmentGallery = JSX(({ cards = [], className = '', title, version = 'primary', ...rest }) => {
|
|
2125
|
+
const [activeCardIndex, setActiveCardIndex] = useState(0);
|
|
2126
|
+
const cardWidth = 525;
|
|
2127
|
+
return (jsxs(BlockWrapper, { className: `relative font-sans p-9 overflow-hidden text-center ${VersionStyleMap[version]} ${className}`, ...rest, children: [title ? jsx(Heading, { headingType: "h3", className: "mb-9", title: title }) : null, jsxs("div", { children: [jsx("div", { className: "flex duration-1000 gap-3.5", style: { transform: `translateX(-${activeCardIndex * cardWidth}px)` }, role: "list", children: cards?.length ? cards.map(renderInvestmentGalleryCard(className, version)) : null }), renderNavButtons$1({
|
|
2128
|
+
cardsCount: cards.length,
|
|
2129
|
+
activeCardIndex,
|
|
2130
|
+
setActiveCardIndex,
|
|
2131
|
+
})] }), jsx("div", { className: `${BLUR_BLOCK_CLASSES$1} left-0 ${version === 'secondary' ? 'bg-opacity-from-main' : 'bg-opacity-from-white'}` }), jsx("div", { className: `${BLUR_BLOCK_CLASSES$1} right-0 ${version === 'secondary' ? 'bg-opacity-to-main' : 'bg-opacity-to-white'}` })] }));
|
|
2132
|
+
});
|
|
2133
|
+
const renderInvestmentGalleryCard = (className, version) => (card, i) => jsx(InvestmentGalleryCard, { className: className, version: version, ...card }, String(i));
|
|
2134
|
+
const renderNavButtons$1 = ({ cardsCount, activeCardIndex, setActiveCardIndex }) => {
|
|
2135
|
+
const isUseSlider = cardsCount > CARD_FULL_VIEW_COUNT$1;
|
|
2136
|
+
const showNextButton = isUseSlider && cardsCount - activeCardIndex > CARD_FULL_VIEW_COUNT$1;
|
|
2137
|
+
const showPrevButton = isUseSlider && activeCardIndex > 0;
|
|
2138
|
+
const handleNextClick = () => setActiveCardIndex(activeCardIndex + 1);
|
|
2139
|
+
const handlePrevClick = () => setActiveCardIndex(activeCardIndex - 1);
|
|
2140
|
+
return (jsx("div", { children: renderArrows({
|
|
2141
|
+
handler: [handlePrevClick, handleNextClick],
|
|
2142
|
+
isShown: [showPrevButton, showNextButton],
|
|
2143
|
+
btnClass: ['left-8', 'right-8'],
|
|
2144
|
+
className: 'top-1/2 mt-3',
|
|
2145
|
+
}) }));
|
|
2146
|
+
};
|
|
2147
|
+
|
|
2099
2148
|
function joinList(sep) {
|
|
2100
2149
|
return (list) => list.reduce((acc, el, i) => (acc.length ? acc.concat({ ...sep, key: i }, el) : [el]), []);
|
|
2101
2150
|
}
|
|
@@ -2632,7 +2681,7 @@
|
|
|
2632
2681
|
|
|
2633
2682
|
const DefaultFoldButton = JSX(({ className = '', label, icon, dataTheme = '', onClick }) => {
|
|
2634
2683
|
const STATE_STYLE = 'hover:bg-primary-hover focus:border-primary-text active:bg-primary-active outline-none';
|
|
2635
|
-
const DIMENSIONS_STYLE = 'flex justify-center w-full px-0 py-5
|
|
2684
|
+
const DIMENSIONS_STYLE = 'flex justify-center w-full px-0 py-5';
|
|
2636
2685
|
return (jsxs("button", { className: [
|
|
2637
2686
|
'border border-transparent bg-primary-main font-sans text-white cursor-pointer',
|
|
2638
2687
|
STATE_STYLE,
|
|
@@ -2764,11 +2813,6 @@
|
|
|
2764
2813
|
: null, breadcrumbs?.length ? (jsx("div", { className: "text-xs-light mb-6", children: joinList(jsx("span", { className: `mx-2 ${breadcrumbsStyleMap[version]}`, children: "/" }))(breadcrumbs.map((breadcrumb, i) => (jsx(Breadcrumb, { className: breadcrumbsStyleMap[version], ...breadcrumb }, String(i))))) })) : null, jsx(ProductBlockInner, { version: version, ...rest })] }));
|
|
2765
2814
|
});
|
|
2766
2815
|
|
|
2767
|
-
const BorderVersionStyleMap = {
|
|
2768
|
-
primary: 'border-main-stroke',
|
|
2769
|
-
secondary: 'border-white/50',
|
|
2770
|
-
};
|
|
2771
|
-
|
|
2772
2816
|
const productBlockStyleMap = {
|
|
2773
2817
|
primary: { title: 'text-secondary-text', text: 'text-secondary-text' },
|
|
2774
2818
|
secondary: { title: 'text-white', text: 'text-white/80' },
|
|
@@ -2852,30 +2896,30 @@
|
|
|
2852
2896
|
return dateObj.toLocaleString('ru-RU', dateFormat).replace('г.', '');
|
|
2853
2897
|
}
|
|
2854
2898
|
|
|
2855
|
-
const RecommendationCard = JSX(({ className = '', title, description, items, image, version, socialMedia }) => {
|
|
2899
|
+
const RecommendationCard = JSX(({ className = '', title, description, items, image, version, socialMedia, button }) => {
|
|
2856
2900
|
const tileTitle = title ? (jsx(Heading, { headingType: "h5", as: "h3", className: "mb-3.5 z-10", title: title })) : null;
|
|
2857
2901
|
const tileImage = image?.src ? (jsx(ImgInner, { className: "absolute bottom-0 right-0 m-0", image: image })) : null;
|
|
2858
|
-
return (jsx("section", { className: `relative overflow-hidden text-left border border-solid box-border p-7 min-w-[524px] min-h-[218px] ${className}`, role: "listitem", children: jsx(BaseTile, { className: "flex justify-between", title: tileTitle, image: tileImage, children: jsxs("div", { className: "h-full flex flex-col justify-between", children: [description ? jsx(Description, { className: "mb-2", description: description }) : null, items?.length ? (jsx(List, { className: "text-xl-light flex flex-col flex-1 gap-2 max-w-[236px]", items: items, version: version })) : null, socialMedia ? (jsx(SocialMedia, { className: "pt-10 pb-0", media: socialMedia, version: version })) : null] }) }) }));
|
|
2902
|
+
return (jsx("section", { className: `relative overflow-hidden text-left border border-solid box-border p-7 min-w-[524px] min-h-[218px] ${className}`, role: "listitem", children: jsx(BaseTile, { className: "flex justify-between", title: tileTitle, image: tileImage, children: jsxs("div", { className: "h-full flex flex-col justify-between", children: [description ? jsx(Description, { className: "mb-2", description: description }) : null, items?.length ? (jsx(List, { className: "text-xl-light flex flex-col flex-1 gap-2 max-w-[236px]", items: items, version: version })) : null, socialMedia ? (jsx(SocialMedia, { className: "pt-10 pb-0", media: socialMedia, version: version })) : null, button?.text ? (jsx("div", { className: "pt-2", children: renderButton({ button, buttonClassName: 'mt-16' }) })) : null] }) }) }));
|
|
2859
2903
|
});
|
|
2860
2904
|
|
|
2861
|
-
const BLUR_BLOCK_CLASSES
|
|
2862
|
-
const CARD_FULL_VIEW_COUNT
|
|
2905
|
+
const BLUR_BLOCK_CLASSES = 'absolute top-0 bottom-0 w-[84px]';
|
|
2906
|
+
const CARD_FULL_VIEW_COUNT = 2;
|
|
2863
2907
|
const CARD_SHIFT = 525;
|
|
2864
2908
|
const Recommendation = JSX(({ recommendations = [], className = '', title, version = 'primary', ...rest }) => {
|
|
2865
2909
|
const [activeCardIndex, setActiveCardIndex] = useState(0);
|
|
2866
2910
|
return (jsxs(BlockWrapper, { className: `relative font-sans p-9 overflow-hidden text-center ${VersionStyleMap[version]} ${className}`, ...rest, children: [title ? jsx(Heading, { headingType: "h3", className: "mb-6", title: title }) : null, jsxs("div", { children: [jsx("div", { className: "flex duration-1000 gap-3.5", style: { transform: `translateX(-${activeCardIndex * CARD_SHIFT}px)` }, role: "list", children: recommendations?.length
|
|
2867
2911
|
? recommendations.map((card, i) => (jsx(RecommendationCard, { version: version, className: BorderVersionStyleMap[version], ...card }, String(i))))
|
|
2868
|
-
: null }), renderNavButtons
|
|
2912
|
+
: null }), renderNavButtons({
|
|
2869
2913
|
cardsCount: recommendations.length,
|
|
2870
2914
|
activeCardIndex,
|
|
2871
2915
|
setActiveCardIndex,
|
|
2872
|
-
})] }), jsx("div", { className: `${BLUR_BLOCK_CLASSES
|
|
2916
|
+
})] }), jsx("div", { className: `${BLUR_BLOCK_CLASSES} left-0 ${version === 'secondary' ? 'bg-opacity-from-main' : 'bg-opacity-from-white'}` }), jsx("div", { className: `${BLUR_BLOCK_CLASSES} right-0 ${version === 'secondary' ? 'bg-opacity-to-main' : 'bg-opacity-to-white'}` })] }));
|
|
2873
2917
|
});
|
|
2874
|
-
const renderNavButtons
|
|
2918
|
+
const renderNavButtons = ({ cardsCount, activeCardIndex, setActiveCardIndex, }) => {
|
|
2875
2919
|
const handleNextClick = () => setActiveCardIndex(activeCardIndex + 1);
|
|
2876
2920
|
const handlePrevClick = () => setActiveCardIndex(activeCardIndex - 1);
|
|
2877
|
-
const isUseSlider = cardsCount > CARD_FULL_VIEW_COUNT
|
|
2878
|
-
const showNextButton = isUseSlider && cardsCount - activeCardIndex > CARD_FULL_VIEW_COUNT
|
|
2921
|
+
const isUseSlider = cardsCount > CARD_FULL_VIEW_COUNT;
|
|
2922
|
+
const showNextButton = isUseSlider && cardsCount - activeCardIndex > CARD_FULL_VIEW_COUNT;
|
|
2879
2923
|
const showPrevButton = isUseSlider && activeCardIndex > 0;
|
|
2880
2924
|
return (jsx("div", { children: renderArrows({
|
|
2881
2925
|
handler: [handlePrevClick, handleNextClick],
|
|
@@ -2885,6 +2929,15 @@
|
|
|
2885
2929
|
}) }));
|
|
2886
2930
|
};
|
|
2887
2931
|
|
|
2932
|
+
const RollupItem = JSX(({ className = '', label = 'Развернуть', isExpanded, isFoldButtonOnTop = true, version = 'primary', children, }) => (jsx("div", { className: `border-b border-solid border-main-divider w-full ${className}`, children: jsx(Foldable, { isFoldButtonOnTop: isFoldButtonOnTop, unfoldedByDefault: isExpanded, renderFoldableSection: ({ isUnfolded }) => (jsx("div", { className: "box-border", children: jsx(FoldableSection, { className: `grid grid-cols-12 gap-1 border-box`, isUnfolded: isUnfolded, children: children }) })), renderFoldButton: ({ isUnfolded, onToggle }) => renderFoldButton({ isUnfolded, onToggle, label, version }) }) })));
|
|
2933
|
+
RollupItem.childrenTypes = [];
|
|
2934
|
+
const renderFoldButton = ({ isUnfolded, onToggle, label, version }) => {
|
|
2935
|
+
const icons = ['PlusIcon', 'MinusIcon'];
|
|
2936
|
+
const labels = label ? [label, label] : ['Развернуть', 'Скрыть'];
|
|
2937
|
+
return version === 'primary' ? (jsx(FoldButton, { icon: icons[Number(isUnfolded)], label: labels[Number(isUnfolded)], onClick: onToggle })) : (jsx(DefaultFoldButton, { icon: icons[Number(isUnfolded)], label: labels[Number(isUnfolded)], onClick: onToggle }));
|
|
2938
|
+
};
|
|
2939
|
+
const FoldButton = JSX(({ label, icon, onClick }) => (jsxs("button", { className: "border-none bg-transparent px-9 pt-5 pb-3.5 flex justify-between text-left w-full font-sans text-h6 group cursor-pointer", onClick: onClick, children: [jsx("span", { className: "text-xl font-medium pr-2.5", children: label }), icon ? jsx(ImgInner, { image: getIconWithVersion({ icon }), width: "24", height: "24", asSVG: true }) : null] })));
|
|
2940
|
+
|
|
2888
2941
|
const SAFEBOXES_URL = '/api/v1/safeboxes';
|
|
2889
2942
|
const EMPTY_VALUE = [];
|
|
2890
2943
|
function useSafeBoxes(regionCode) {
|
|
@@ -3329,14 +3382,14 @@
|
|
|
3329
3382
|
data: colData.map((col) => col?.[i] || []),
|
|
3330
3383
|
}));
|
|
3331
3384
|
const columnsLength = colData.length;
|
|
3332
|
-
const
|
|
3333
|
-
|
|
3334
|
-
|
|
3385
|
+
const [activeIndex, controls] = useCarouselControl({
|
|
3386
|
+
itemsCount: colData.length,
|
|
3387
|
+
visibleItemCount: COLS_LENGTH_FOR_SCROLL,
|
|
3335
3388
|
});
|
|
3336
|
-
const
|
|
3337
|
-
const rows = (rowData || []).map((row, i) => (jsx(TariffsTableRow, { row: row, activeCardIndex:
|
|
3389
|
+
const isScrollAvailable = colData.length > COLS_LENGTH_FOR_SCROLL;
|
|
3390
|
+
const rows = (rowData || []).map((row, i) => (jsx(TariffsTableRow, { row: row, activeCardIndex: activeIndex, rowIdx: i, ...rest }, String(i))));
|
|
3338
3391
|
const [visibleRows, hiddenRows] = hiddenRowsNum > 0 ? [rows.slice(0, -hiddenRowsNum), rows.slice(-hiddenRowsNum)] : [rows, []];
|
|
3339
|
-
return (jsxs(BlockWrapper, { className: `bg-white font-sans p-[50px] overflow-hidden text-primary-text relative ${columnsLength > 1 ? 'pr-0' : ''} ${className}`, ...rest, children: [renderTitle({ title, description }), renderDescription(description), hiddenRowsNum > 0 ? (jsx(Foldable, { renderFoldableSection: ({ isUnfolded }) => (jsxs(Wrapper, {
|
|
3392
|
+
return (jsxs(BlockWrapper, { className: `bg-white font-sans p-[50px] overflow-hidden text-primary-text relative ${columnsLength > 1 ? 'pr-0' : ''} ${className}`, ...rest, children: [renderTitle({ title, description }), renderDescription(description), hiddenRowsNum > 0 ? (jsx(Foldable, { renderFoldableSection: ({ isUnfolded }) => (jsxs(Wrapper, { controls: controls, isScrollAvailable: isScrollAvailable, children: [visibleRows, jsx(FoldableSection, { isUnfolded: isUnfolded, children: hiddenRows })] })), renderFoldButton: renderDefaultFoldButton })) : (jsx(Wrapper, { controls: controls, isScrollAvailable: isScrollAvailable, children: rows }))] }));
|
|
3340
3393
|
});
|
|
3341
3394
|
function renderTitle({ title, description }) {
|
|
3342
3395
|
return title ? (jsx(Heading, { headingType: "h3", className: `text-center ${description ? 'mb-2.5' : 'mb-8'}`, title: title })) : null;
|
|
@@ -3344,9 +3397,14 @@
|
|
|
3344
3397
|
function renderDescription(description) {
|
|
3345
3398
|
return description ? jsx("div", { className: "mb-9 text-center text-l", children: description }) : null;
|
|
3346
3399
|
}
|
|
3347
|
-
const Wrapper = JSX(({ children,
|
|
3348
|
-
const {
|
|
3349
|
-
return (jsxs("div", { role: "table", children: [jsxs("div", { className: "relative", children: [children,
|
|
3400
|
+
const Wrapper = JSX(({ children, controls, isScrollAvailable }) => {
|
|
3401
|
+
const { inc, dec, canDec, canInc } = controls;
|
|
3402
|
+
return (jsxs("div", { role: "table", children: [jsxs("div", { className: "relative", children: [children, isScrollAvailable ? (jsx("div", { children: renderArrows({
|
|
3403
|
+
handler: [inc, dec],
|
|
3404
|
+
isShown: [canDec, canInc],
|
|
3405
|
+
btnClass: ['top-[108px]', 'top-11'],
|
|
3406
|
+
className: 'right-7',
|
|
3407
|
+
}) })) : null] }), isScrollAvailable ? (jsx("div", { className: "absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white" })) : null] }));
|
|
3350
3408
|
});
|
|
3351
3409
|
|
|
3352
3410
|
const textBlockStyleMaps = {
|
|
@@ -3414,7 +3472,7 @@
|
|
|
3414
3472
|
primary: 'bg-white',
|
|
3415
3473
|
secondary: 'bg-primary-main',
|
|
3416
3474
|
};
|
|
3417
|
-
const VerticalLayout = JSX(({ className = '', children, gap = '', align = 'left', version = '
|
|
3475
|
+
const VerticalLayout = JSX(({ className = '', children, gap = '', align = 'left', version = 'transparent', ...rest }) => (jsx(BlockWrapper, { className: [
|
|
3418
3476
|
'flex flex-col',
|
|
3419
3477
|
gapStyleMap[gap],
|
|
3420
3478
|
alignStyle[align],
|
|
@@ -3425,46 +3483,46 @@
|
|
|
3425
3483
|
exclude: ['VerticalLayout'],
|
|
3426
3484
|
};
|
|
3427
3485
|
|
|
3428
|
-
const
|
|
3429
|
-
const
|
|
3430
|
-
|
|
3431
|
-
|
|
3486
|
+
const BLOCK_CLASSES = 'absolute border border-solid border-main-stroke w-[100%] h-[100%]';
|
|
3487
|
+
const CARD_STYLE_MAP = {
|
|
3488
|
+
normal: 'min-w-[100%] justify-center items-center my-7 col-span-12',
|
|
3489
|
+
mini: 'w-1/3 justify-center items-center mx-4 my-9 col-span-4',
|
|
3432
3490
|
};
|
|
3433
|
-
const
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
|
|
3437
|
-
|
|
3438
|
-
|
|
3439
|
-
|
|
3491
|
+
const CARD_WIDTH_MAP = {
|
|
3492
|
+
normal: 'w-[1007px]',
|
|
3493
|
+
mini: 'w-[350px]',
|
|
3494
|
+
};
|
|
3495
|
+
const CarouselCard = JSX(({ button, className = '', description, title, version = 'normal' }) => {
|
|
3496
|
+
return (jsx("section", { className: `flex ${CARD_STYLE_MAP[version]}`, children: jsxs("div", { className: `relative ${CARD_WIDTH_MAP[version]}`, children: [jsxs("div", { className: `relative bg-white py-6 px-10 z-10
|
|
3497
|
+
border border-solid border-green-light ${className}`, children: [jsx(Headline, { className: "!p-0", title: title, description: description, headlineVersion: "M", align: "center" }), button ? renderButton({ button, buttonClassName: 'mt-6 w-[158px]' }) : null] }), jsx("div", { className: `top-9 right-12 bg-green-dark ${BLOCK_CLASSES}` }), jsx("div", { className: `top-6 right-8 bg-green ${BLOCK_CLASSES}` }), jsx("div", { className: `top-3 right-4 bg-green-light ${BLOCK_CLASSES}` })] }) }));
|
|
3440
3498
|
});
|
|
3441
|
-
const renderCardList = (cardList, columnsMode) => cardList.map((item, i) => (jsxs("div", { className: columnsMode === 'double' ? 'basis-[calc(50%-20px)]' : '', role: "listitem", children: [item?.parameter ? (jsx("span", { className: `pr-2.5 ${getItemListFontSize(columnsMode)}`, children: item.parameter })) : null, item?.parameterDesccription ? (jsx("span", { className: "text-m-light text-secondary-text", children: item.parameterDesccription })) : null] }, String(i))));
|
|
3442
3499
|
|
|
3443
|
-
const
|
|
3444
|
-
|
|
3445
|
-
|
|
3446
|
-
|
|
3447
|
-
|
|
3448
|
-
return (jsxs(BlockWrapper, { className: `relative font-sans p-9 overflow-hidden text-center ${VersionStyleMap[version]} ${className}`, ...rest, children: [title ? jsx(Heading, { headingType: "h3", className: "mb-9", title: title }) : null, jsxs("div", { children: [jsx("div", { className: "flex duration-1000 gap-3.5", style: { transform: `translateX(-${activeCardIndex * cardWidth}px)` }, role: "list", children: cards?.length ? cards.map(renderInvestmentGalleryCard(className, version)) : null }), renderNavButtons({
|
|
3449
|
-
cardsCount: cards.length,
|
|
3450
|
-
activeCardIndex,
|
|
3451
|
-
setActiveCardIndex,
|
|
3452
|
-
})] }), jsx("div", { className: `${BLUR_BLOCK_CLASSES} left-0 ${version === 'secondary' ? 'bg-opacity-from-main' : 'bg-opacity-from-white'}` }), jsx("div", { className: `${BLUR_BLOCK_CLASSES} right-0 ${version === 'secondary' ? 'bg-opacity-to-main' : 'bg-opacity-to-white'}` })] }));
|
|
3500
|
+
const CarouselContainer = JSX(({ children, activeItem, cardFullViewCount, cardWidth }) => {
|
|
3501
|
+
const cardFullViewStyles = cardFullViewCount === 1
|
|
3502
|
+
? `translateX(-${activeItem}00%)`
|
|
3503
|
+
: `translateX(-${activeItem * cardWidth}px)`;
|
|
3504
|
+
return (jsx("div", { className: "w-auto flex flex-1 duration-1000", style: { transform: `${cardFullViewStyles}` }, role: "list", children: children }));
|
|
3453
3505
|
});
|
|
3454
|
-
|
|
3455
|
-
const
|
|
3456
|
-
const
|
|
3457
|
-
const
|
|
3458
|
-
const
|
|
3459
|
-
const
|
|
3460
|
-
const
|
|
3461
|
-
|
|
3462
|
-
|
|
3463
|
-
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
|
|
3506
|
+
|
|
3507
|
+
const Carousel = JSX(({ cardFullViewCount = 1, children, cardWidth = 1007, className = '', isBlur = true, isCyclic = false, block, ...rest }) => {
|
|
3508
|
+
const blurClasses = isBlur ? 'absolute top-0 bottom-0 w-[84px]' : '';
|
|
3509
|
+
const { blocks: childBlocks } = block || {};
|
|
3510
|
+
const childBlocksLength = childBlocks !== undefined ? childBlocks.length : 0;
|
|
3511
|
+
const isScrollAvailable = childBlocksLength > cardFullViewCount;
|
|
3512
|
+
const [activeIndex, controls] = useCarouselControl({
|
|
3513
|
+
itemsCount: childBlocksLength,
|
|
3514
|
+
visibleItemCount: cardFullViewCount,
|
|
3515
|
+
isCyclic,
|
|
3516
|
+
});
|
|
3517
|
+
const { inc, dec, canDec, canInc } = controls;
|
|
3518
|
+
return (jsxs(BlockWrapper, { className: `box-border h-full relative font-sans flex flex-col justify-center overflow-hidden ${className}`, ...rest, children: [jsx(CarouselContainer, { activeItem: activeIndex, cardFullViewCount: cardFullViewCount, cardWidth: cardWidth, children: children }), isScrollAvailable ? (jsx("div", { children: renderArrows({
|
|
3519
|
+
handler: [dec, inc],
|
|
3520
|
+
isShown: [canDec, canInc],
|
|
3521
|
+
btnClass: ['left-8', 'right-8'],
|
|
3522
|
+
className: 'top-1/2 z-10',
|
|
3523
|
+
}) })) : null, isScrollAvailable ? (jsxs("div", { children: [jsx("div", { className: `${blurClasses} left-0 bg-opacity-from-white` }), jsx("div", { className: `${blurClasses} right-0 bg-opacity-to-white` })] })) : null] }));
|
|
3524
|
+
});
|
|
3525
|
+
Carousel.childrenTypes = ['CarouselCard'];
|
|
3468
3526
|
|
|
3469
3527
|
const Blocks = {
|
|
3470
3528
|
Accordion,
|
|
@@ -3502,6 +3560,7 @@
|
|
|
3502
3560
|
OtherProducts,
|
|
3503
3561
|
OtherProductsItem,
|
|
3504
3562
|
Recommendation,
|
|
3563
|
+
RollupItem,
|
|
3505
3564
|
SafeDepositRental,
|
|
3506
3565
|
StepsBlock,
|
|
3507
3566
|
Tabs,
|
|
@@ -3509,6 +3568,8 @@
|
|
|
3509
3568
|
TextBlock,
|
|
3510
3569
|
Tile,
|
|
3511
3570
|
VerticalLayout,
|
|
3571
|
+
CarouselCard,
|
|
3572
|
+
Carousel,
|
|
3512
3573
|
};
|
|
3513
3574
|
|
|
3514
3575
|
function style2className(style) {
|
|
@@ -3616,7 +3677,7 @@
|
|
|
3616
3677
|
return (jsx("div", { className: "flex items-end absolute bottom-0 right-0 h-full pointer-events-none", children: jsx(LikeControl, { className: "rounded-tl-lg sticky bottom-0 pointer-events-auto" }) }));
|
|
3617
3678
|
}
|
|
3618
3679
|
|
|
3619
|
-
const packageVersion = "0.6.
|
|
3680
|
+
const packageVersion = "0.6.29";
|
|
3620
3681
|
|
|
3621
3682
|
exports.Blocks = Blocks;
|
|
3622
3683
|
exports.ContentPage = ContentPage;
|