@redneckz/wildless-cms-uni-blocks 0.12.4 → 0.12.5
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/bin/migration-scripts/0.12.3.js +2 -0
- package/bin/migration-scripts/0.9.10.js +1 -1
- package/bundle/bundle.umd.js +43 -77
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/bundle/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/bundle/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
- package/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
- package/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
- package/bundle/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
- package/bundle/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/bundle/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +4 -0
- package/bundle/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/bundle/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/bundle/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
- package/bundle/components/Tabs/tabItemClasses.d.ts +2 -3
- package/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/dist/components/BenefitsBlock/BenefitsBlock.js +4 -6
- package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/dist/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/dist/components/BenefitsBlock/benefitImageStyles.js +4 -0
- package/dist/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
- package/dist/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
- package/dist/components/BenefitsBlock/benefitImageStyles.mobile.js +4 -0
- package/dist/components/BenefitsBlock/benefitImageStyles.mobile.js.map +1 -0
- package/dist/components/Blocks.mobile.js +6 -0
- package/dist/components/Blocks.mobile.js.map +1 -1
- package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
- package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js +4 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js +4 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js +4 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js +4 -0
- package/dist/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefit.js +11 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.js +20 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +4 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js +8 -0
- package/dist/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js.map +1 -0
- package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
- package/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/dist/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/dist/components/CarouselCatalogCard/CatalogCard.js +20 -0
- package/dist/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
- package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
- package/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
- package/dist/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/dist/components/CarouselProgramsCard/programCardStyles.js +5 -0
- package/dist/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
- package/dist/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
- package/dist/components/CarouselProgramsCard/programCardStyles.mobile.js +5 -0
- package/dist/components/CarouselProgramsCard/programCardStyles.mobile.js.map +1 -0
- package/dist/components/Tabs/LinkTab.js +2 -1
- package/dist/components/Tabs/LinkTab.js.map +1 -1
- package/dist/components/Tabs/Tabs.js +3 -2
- package/dist/components/Tabs/Tabs.js.map +1 -1
- package/dist/components/Tabs/renderGroupTab.js +7 -13
- package/dist/components/Tabs/renderGroupTab.js.map +1 -1
- package/dist/components/Tabs/tabItemClasses.d.ts +2 -3
- package/dist/components/Tabs/tabItemClasses.js +10 -46
- package/dist/components/Tabs/tabItemClasses.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTable.mobile.js +0 -1
- package/dist/components/TariffsTable/TariffsTable.mobile.js.map +1 -1
- package/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
- package/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.fixture.mobile.d.ts +6 -0
- package/lib/components/BenefitsBlock/BenefitsBlock.js +4 -6
- package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/lib/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/lib/components/BenefitsBlock/benefitImageStyles.js +2 -0
- package/lib/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
- package/lib/components/BenefitsBlock/benefitImageStyles.mobile.d.ts +1 -0
- package/lib/components/BenefitsBlock/benefitImageStyles.mobile.js +2 -0
- package/lib/components/BenefitsBlock/benefitImageStyles.mobile.js.map +1 -0
- package/lib/components/Blocks.mobile.js +6 -0
- package/lib/components/Blocks.mobile.js.map +1 -1
- package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.fixture.mobile.d.ts +7 -0
- package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
- package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js +2 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.d.ts +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js +2 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js +2 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.d.ts +1 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js +2 -0
- package/lib/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +2 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefit.js +8 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.js +17 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.d.ts +3 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js +5 -0
- package/lib/components/BonusBenefitsBlock/renderBonusBenefits.mobile.js.map +1 -0
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.fixture.d.ts +0 -11
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.fixture.mobile.d.ts +6 -0
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
- package/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/lib/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/lib/components/CarouselCatalogCard/CatalogCard.js +18 -0
- package/lib/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
- package/lib/components/CarouselProgramsCard/CarouselProgramsCard.fixture.d.ts +0 -1
- package/lib/components/CarouselProgramsCard/CarouselProgramsCard.fixture.mobile.d.ts +7 -0
- package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
- package/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
- package/lib/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/lib/components/CarouselProgramsCard/programCardStyles.js +3 -0
- package/lib/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
- package/lib/components/CarouselProgramsCard/programCardStyles.mobile.d.ts +2 -0
- package/lib/components/CarouselProgramsCard/programCardStyles.mobile.js +3 -0
- package/lib/components/CarouselProgramsCard/programCardStyles.mobile.js.map +1 -0
- package/lib/components/Tabs/LinkTab.js +3 -2
- package/lib/components/Tabs/LinkTab.js.map +1 -1
- package/lib/components/Tabs/Tabs.fixture.mobile.d.ts +8 -0
- package/lib/components/Tabs/Tabs.js +3 -2
- package/lib/components/Tabs/Tabs.js.map +1 -1
- package/lib/components/Tabs/renderGroupTab.d.ts +0 -1
- package/lib/components/Tabs/renderGroupTab.js +9 -15
- package/lib/components/Tabs/renderGroupTab.js.map +1 -1
- package/lib/components/Tabs/renderTab.d.ts +0 -1
- package/lib/components/Tabs/tabItemClasses.d.ts +2 -3
- package/lib/components/Tabs/tabItemClasses.js +8 -43
- package/lib/components/Tabs/tabItemClasses.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTable.mobile.js +0 -1
- package/lib/components/TariffsTable/TariffsTable.mobile.js.map +1 -1
- package/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
- package/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +507 -335
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/mobile/bundle/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/mobile/bundle/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/mobile/bundle/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/mobile/bundle/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
- package/mobile/bundle/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/mobile/bundle/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/mobile/bundle/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/mobile/bundle/components/Tabs/tabItemClasses.d.ts +2 -3
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js +4 -6
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/dist/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/mobile/dist/components/BenefitsBlock/benefitImageStyles.js +4 -0
- package/mobile/dist/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
- package/mobile/dist/components/Blocks.js +6 -0
- package/mobile/dist/components/Blocks.js.map +1 -1
- package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
- package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js +4 -0
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js +4 -0
- package/mobile/dist/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.js +11 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.js +8 -0
- package/mobile/dist/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
- package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
- package/mobile/dist/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/mobile/dist/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/mobile/dist/components/CarouselCatalogCard/CatalogCard.js +20 -0
- package/mobile/dist/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
- package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
- package/mobile/dist/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
- package/mobile/dist/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/mobile/dist/components/CarouselProgramsCard/programCardStyles.js +5 -0
- package/mobile/dist/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
- package/mobile/dist/components/Tabs/LinkTab.js +2 -1
- package/mobile/dist/components/Tabs/LinkTab.js.map +1 -1
- package/mobile/dist/components/Tabs/Tabs.js +3 -2
- package/mobile/dist/components/Tabs/Tabs.js.map +1 -1
- package/mobile/dist/components/Tabs/renderGroupTab.js +7 -13
- package/mobile/dist/components/Tabs/renderGroupTab.js.map +1 -1
- package/mobile/dist/components/Tabs/tabItemClasses.d.ts +2 -3
- package/mobile/dist/components/Tabs/tabItemClasses.js +10 -46
- package/mobile/dist/components/Tabs/tabItemClasses.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTable.js +0 -1
- package/mobile/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js +1 -1
- package/mobile/dist/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js +4 -6
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/lib/components/BenefitsBlock/benefitImageStyles.d.ts +1 -0
- package/mobile/lib/components/BenefitsBlock/benefitImageStyles.js +2 -0
- package/mobile/lib/components/BenefitsBlock/benefitImageStyles.js.map +1 -0
- package/mobile/lib/components/Blocks.js +6 -0
- package/mobile/lib/components/Blocks.js.map +1 -1
- package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +4 -18
- package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.d.ts +1 -0
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js +2 -0
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitAlign.js.map +1 -0
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.d.ts +1 -0
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js +2 -0
- package/mobile/lib/components/BonusBenefitsBlock/bonusBenefitStyles.js.map +1 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.d.ts +3 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.js +8 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefit.js.map +1 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.d.ts +4 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.js +5 -0
- package/mobile/lib/components/BonusBenefitsBlock/renderBonusBenefits.js.map +1 -0
- package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js +2 -2
- package/mobile/lib/components/CarouselCatalogCard/CarouselCatalogCard.js.map +1 -1
- package/mobile/lib/components/CarouselCatalogCard/CatalogCard.d.ts +9 -0
- package/mobile/lib/components/CarouselCatalogCard/CatalogCard.js +18 -0
- package/mobile/lib/components/CarouselCatalogCard/CatalogCard.js.map +1 -0
- package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js +5 -2
- package/mobile/lib/components/CarouselProgramsCard/CarouselProgramsCard.js.map +1 -1
- package/mobile/lib/components/CarouselProgramsCard/programCardStyles.d.ts +2 -0
- package/mobile/lib/components/CarouselProgramsCard/programCardStyles.js +3 -0
- package/mobile/lib/components/CarouselProgramsCard/programCardStyles.js.map +1 -0
- package/mobile/lib/components/Tabs/LinkTab.js +3 -2
- package/mobile/lib/components/Tabs/LinkTab.js.map +1 -1
- package/mobile/lib/components/Tabs/Tabs.js +3 -2
- package/mobile/lib/components/Tabs/Tabs.js.map +1 -1
- package/mobile/lib/components/Tabs/renderGroupTab.js +9 -15
- package/mobile/lib/components/Tabs/renderGroupTab.js.map +1 -1
- package/mobile/lib/components/Tabs/tabItemClasses.d.ts +2 -3
- package/mobile/lib/components/Tabs/tabItemClasses.js +8 -43
- package/mobile/lib/components/Tabs/tabItemClasses.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTable.js +0 -1
- package/mobile/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js +1 -1
- package/mobile/lib/ui-kit/PhoneInput/PhoneInput.js.map +1 -1
- package/mobile/src/common.css +3 -0
- package/mobile/src/components/BenefitsBlock/BenefitsBlock.tsx +37 -34
- package/mobile/src/components/BenefitsBlock/benefitImageStyles.tsx +1 -0
- package/mobile/src/components/Blocks.ts +6 -0
- package/mobile/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +13 -49
- package/mobile/src/components/BonusBenefitsBlock/bonusBenefitAlign.ts +1 -0
- package/mobile/src/components/BonusBenefitsBlock/bonusBenefitStyles.ts +1 -0
- package/mobile/src/components/BonusBenefitsBlock/renderBonusBenefit.tsx +29 -0
- package/mobile/src/components/BonusBenefitsBlock/renderBonusBenefits.tsx +14 -0
- package/mobile/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +3 -3
- package/mobile/src/components/CarouselCatalogCard/CatalogCard.ts +22 -0
- package/mobile/src/components/CarouselInvestmentCard/CarouselInvestmentCard.example.json +1 -11
- package/mobile/src/components/CarouselProductCard/CarouselProductCard.example.json +1 -11
- package/mobile/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +21 -11
- package/mobile/src/components/CarouselProgramsCard/programCardStyles.ts +2 -0
- package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.example.json +1 -12
- package/mobile/src/components/ErrorBlock/ErrorBlock.example.json +1 -11
- package/mobile/src/components/MobileAppTile/MobileAppTile.example.json +1 -11
- package/mobile/src/components/PictureText/PictureText.example.json +1 -11
- package/mobile/src/components/ProductBlock/ProductBlock.example.json +1 -11
- package/mobile/src/components/ProductTile/ProductTile.example.json +4 -12
- package/mobile/src/components/Tabs/LinkTab.tsx +19 -8
- package/mobile/src/components/Tabs/Tabs.tsx +7 -4
- package/mobile/src/components/Tabs/renderGroupTab.tsx +21 -33
- package/mobile/src/components/Tabs/tabItemClasses.ts +12 -45
- package/mobile/src/components/TariffsTable/TariffsTable.tsx +0 -1
- package/mobile/src/components/Tile/Tile.example.json +1 -11
- package/mobile/src/ui-kit/PhoneInput/PhoneInput.tsx +5 -1
- package/package.json +1 -1
- package/src/common.css +3 -0
- package/src/components/BenefitsBlock/BenefitsBlock.fixture.mobile.tsx +43 -0
- package/src/components/BenefitsBlock/BenefitsBlock.fixture.tsx +0 -1
- package/src/components/BenefitsBlock/BenefitsBlock.tsx +37 -34
- package/src/components/BenefitsBlock/benefitImageStyles.mobile.tsx +1 -0
- package/src/components/BenefitsBlock/benefitImageStyles.tsx +1 -0
- package/src/components/Blocks.mobile.ts +6 -0
- package/src/components/BonusBenefitsBlock/BonusBenefitsBlock.fixture.mobile.tsx +67 -0
- package/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +13 -49
- package/src/components/BonusBenefitsBlock/bonusBenefitAlign.mobile.ts +1 -0
- package/src/components/BonusBenefitsBlock/bonusBenefitAlign.ts +1 -0
- package/src/components/BonusBenefitsBlock/bonusBenefitStyles.mobile.ts +1 -0
- package/src/components/BonusBenefitsBlock/bonusBenefitStyles.ts +1 -0
- package/src/components/BonusBenefitsBlock/renderBonusBenefit.tsx +29 -0
- package/src/components/BonusBenefitsBlock/renderBonusBenefits.mobile.tsx +14 -0
- package/src/components/BonusBenefitsBlock/renderBonusBenefits.tsx +27 -0
- package/src/components/Carousel/Carousel.fixture.tsx +13 -2
- package/src/components/CarouselCatalogCard/CarouselCatalogCard.fixture.mobile.tsx +23 -0
- package/src/components/CarouselCatalogCard/CarouselCatalogCard.fixture.tsx +3 -25
- package/src/components/CarouselCatalogCard/CarouselCatalogCard.tsx +3 -3
- package/src/components/CarouselCatalogCard/CatalogCard.ts +22 -0
- package/src/components/CarouselInvestmentCard/CarouselInvestmentCard.example.json +1 -11
- package/src/components/CarouselProductCard/CarouselProductCard.example.json +1 -11
- package/src/components/CarouselProgramsCard/CarouselProgramsCard.fixture.mobile.tsx +34 -0
- package/src/components/CarouselProgramsCard/CarouselProgramsCard.fixture.tsx +2 -7
- package/src/components/CarouselProgramsCard/CarouselProgramsCard.tsx +21 -11
- package/src/components/CarouselProgramsCard/programCardStyles.mobile.ts +2 -0
- package/src/components/CarouselProgramsCard/programCardStyles.ts +2 -0
- package/src/components/CarouselRecommendationCard/CarouselRecommendationCard.example.json +1 -12
- package/src/components/ErrorBlock/ErrorBlock.example.json +1 -11
- package/src/components/MobileAppTile/MobileAppTile.example.json +1 -11
- package/src/components/PictureText/PictureText.example.json +1 -11
- package/src/components/PictureText/PictureText.fixture.mobile.tsx +0 -6
- package/src/components/PictureText/PictureText.fixture.tsx +0 -6
- package/src/components/ProductBlock/ProductBlock.example.json +1 -11
- package/src/components/ProductBlock/ProductBlock.fixture.mobile.tsx +0 -6
- package/src/components/ProductTile/ProductTile.example.json +4 -12
- package/src/components/Tabs/LinkTab.tsx +19 -8
- package/src/components/Tabs/Tabs.fixture.mobile.tsx +55 -0
- package/src/components/Tabs/Tabs.fixture.tsx +8 -17
- package/src/components/Tabs/Tabs.tsx +7 -4
- package/src/components/Tabs/renderGroupTab.tsx +21 -33
- package/src/components/Tabs/tabItemClasses.ts +12 -45
- package/src/components/TariffsTable/TariffsTable.mobile.tsx +0 -1
- package/src/components/Tile/Tile.example.json +1 -11
- package/src/ui-kit/PhoneInput/PhoneInput.tsx +5 -1
- package/tailwind.config.cjs +12 -12
package/mobile/src/components/CarouselRecommendationCard/CarouselRecommendationCard.example.json
CHANGED
|
@@ -5,18 +5,7 @@
|
|
|
5
5
|
"size": {
|
|
6
6
|
"width": 290,
|
|
7
7
|
"height": 290
|
|
8
|
-
}
|
|
9
|
-
"sources": [
|
|
10
|
-
{
|
|
11
|
-
"media": 1279,
|
|
12
|
-
"size": {
|
|
13
|
-
"width": 174,
|
|
14
|
-
"height": 174
|
|
15
|
-
},
|
|
16
|
-
"format": "webp",
|
|
17
|
-
"alignment": "southeast"
|
|
18
|
-
}
|
|
19
|
-
]
|
|
8
|
+
}
|
|
20
9
|
},
|
|
21
10
|
"title": "Заголовок 1",
|
|
22
11
|
"description": "Описание 1",
|
|
@@ -12,17 +12,7 @@
|
|
|
12
12
|
"size": {
|
|
13
13
|
"width": 234,
|
|
14
14
|
"height": 234
|
|
15
|
-
}
|
|
16
|
-
"sources": [
|
|
17
|
-
{
|
|
18
|
-
"media": 1279,
|
|
19
|
-
"size": {
|
|
20
|
-
"width": 164
|
|
21
|
-
},
|
|
22
|
-
"format": "webp",
|
|
23
|
-
"alignment": "northeast"
|
|
24
|
-
}
|
|
25
|
-
]
|
|
15
|
+
}
|
|
26
16
|
},
|
|
27
17
|
"items": ["Элемент списка 1", "Элемент списка 2", "Элемент списка 3"],
|
|
28
18
|
"isDotted": true,
|
|
@@ -7,17 +7,7 @@
|
|
|
7
7
|
"format": "webp",
|
|
8
8
|
"size": {
|
|
9
9
|
"width": 242
|
|
10
|
-
}
|
|
11
|
-
"sources": [
|
|
12
|
-
{
|
|
13
|
-
"media": 1279,
|
|
14
|
-
"size": {
|
|
15
|
-
"width": 145
|
|
16
|
-
},
|
|
17
|
-
"format": "webp",
|
|
18
|
-
"alignment": "southeast"
|
|
19
|
-
}
|
|
20
|
-
]
|
|
10
|
+
}
|
|
21
11
|
},
|
|
22
12
|
"version": "primary",
|
|
23
13
|
"benefits": [
|
|
@@ -43,6 +33,8 @@
|
|
|
43
33
|
"version": "primary"
|
|
44
34
|
}
|
|
45
35
|
],
|
|
46
|
-
"
|
|
36
|
+
"imageOptions": {
|
|
37
|
+
"directionRight": true
|
|
38
|
+
}
|
|
47
39
|
}
|
|
48
40
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import { useLink } from '../../hooks/useLink';
|
|
3
|
-
import {
|
|
3
|
+
import { style } from '../../utils/style';
|
|
4
|
+
import { getTabClassName } from './tabItemClasses';
|
|
4
5
|
import type { LinkTabData, TabData, TabsMode } from './TabsContent';
|
|
5
6
|
|
|
6
7
|
interface LinkTabProps {
|
|
@@ -23,14 +24,24 @@ export const LinkTab = JSX<LinkTabProps>((props) => {
|
|
|
23
24
|
};
|
|
24
25
|
|
|
25
26
|
return (
|
|
26
|
-
<
|
|
27
|
+
<div
|
|
28
|
+
className={getTabClassName('block', active, tabsMode)}
|
|
27
29
|
role="tab"
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
href={adjustedProps.href}
|
|
31
|
-
onClick={handleClick}
|
|
30
|
+
aria-selected={active}
|
|
31
|
+
onClick={() => onClick(tab)}
|
|
32
32
|
>
|
|
33
|
-
<
|
|
34
|
-
|
|
33
|
+
<a
|
|
34
|
+
role="tab"
|
|
35
|
+
className={style(
|
|
36
|
+
'flex flex-1 items-center justify-center h-full',
|
|
37
|
+
getTabClassName('text', active, tabsMode),
|
|
38
|
+
)}
|
|
39
|
+
target={tab.target}
|
|
40
|
+
href={adjustedProps.href}
|
|
41
|
+
onClick={handleClick}
|
|
42
|
+
>
|
|
43
|
+
<span>{tab.text}</span>
|
|
44
|
+
</a>
|
|
45
|
+
</div>
|
|
35
46
|
);
|
|
36
47
|
});
|
|
@@ -3,6 +3,7 @@ import { useCallback, useEffect, useState } from '@redneckz/uni-jsx/lib/hooks';
|
|
|
3
3
|
import { defaultEventBus } from '../../EventBus/defaultEventBus';
|
|
4
4
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
5
5
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
6
|
+
import { style } from '../../utils/style';
|
|
6
7
|
import { CenteredTabs } from './CenteredTabs';
|
|
7
8
|
import { renderTab } from './renderTab';
|
|
8
9
|
import { ScrollableTabs } from './ScrollableTabs';
|
|
@@ -16,7 +17,7 @@ interface RenderTabsProps extends TabsBlockProps {
|
|
|
16
17
|
}
|
|
17
18
|
|
|
18
19
|
export const Tabs = JSX<TabsBlockProps>((props) => {
|
|
19
|
-
const { className = '',
|
|
20
|
+
const { className = '', isSticky, tabs, ...rest } = props;
|
|
20
21
|
|
|
21
22
|
const [currentTab, setCurrentTab] = useState(tabs ? tabs[0] : undefined);
|
|
22
23
|
|
|
@@ -41,9 +42,11 @@ export const Tabs = JSX<TabsBlockProps>((props) => {
|
|
|
41
42
|
|
|
42
43
|
return (
|
|
43
44
|
<BlockWrapper
|
|
44
|
-
className={
|
|
45
|
-
|
|
46
|
-
|
|
45
|
+
className={style(
|
|
46
|
+
'relative box-border flex gap-x-1 w-full overflow-x-auto no-scrollbar',
|
|
47
|
+
isSticky ? 'sticky top-1 z-20' : '',
|
|
48
|
+
className,
|
|
49
|
+
)}
|
|
47
50
|
defaultPadding="p-0"
|
|
48
51
|
role="tablist"
|
|
49
52
|
{...rest}
|
|
@@ -1,18 +1,12 @@
|
|
|
1
|
+
import { style } from '../../utils/style';
|
|
1
2
|
import type { RenderTabProps } from './renderTab';
|
|
2
|
-
import {
|
|
3
|
-
ACTIVE_TEXT_CLASSES,
|
|
4
|
-
getGroupTabClassName,
|
|
5
|
-
INACTIVE_TEXT_CLASSES,
|
|
6
|
-
TEXT_CLASSES,
|
|
7
|
-
WHITE_ACTIVE_TEXT_CLASSES,
|
|
8
|
-
} from './tabItemClasses';
|
|
3
|
+
import { getTabClassName } from './tabItemClasses';
|
|
9
4
|
import type { GroupTabData, TabsMode } from './TabsContent';
|
|
10
5
|
|
|
11
6
|
const BADGE_CLASSES =
|
|
12
|
-
'min-w-[22px] h-[22px] rounded-full text-xs ml-2 flex justify-center items-center';
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
'bg-main-divider text-secondary-text group-hover/btn:text-primary-main';
|
|
7
|
+
'bg-main-divider min-w-[22px] h-[22px] rounded-full text-xs ml-2 flex justify-center items-center';
|
|
8
|
+
const LIGHT_BADGE_CLASSES = 'bg-white/30 text-white';
|
|
9
|
+
const DARK_BADGE_CLASSES = 'text-secondary-text group-hover/btn:text-primary-main';
|
|
16
10
|
|
|
17
11
|
export const renderGroupTab =
|
|
18
12
|
({ page, currentTab, showCounter, onClick, tabsMode }: RenderTabProps) =>
|
|
@@ -27,39 +21,33 @@ export const renderGroupTab =
|
|
|
27
21
|
return (
|
|
28
22
|
<div
|
|
29
23
|
key={`group-${String(i)}`}
|
|
30
|
-
className={
|
|
24
|
+
className={getTabClassName('block', active, tabsMode)}
|
|
31
25
|
role="tab"
|
|
32
26
|
aria-selected={active}
|
|
33
27
|
onClick={() => onClick(tab)}
|
|
34
28
|
>
|
|
35
29
|
<div
|
|
36
|
-
className={
|
|
37
|
-
'
|
|
38
|
-
active,
|
|
39
|
-
|
|
40
|
-
)}`}
|
|
30
|
+
className={style(
|
|
31
|
+
'flex flex-1 items-center justify-center h-full',
|
|
32
|
+
getTabClassName('text', active, tabsMode),
|
|
33
|
+
)}
|
|
41
34
|
>
|
|
42
|
-
{
|
|
43
|
-
{renderCount(
|
|
35
|
+
<span>{tab.title}</span>
|
|
36
|
+
{showCounter && count ? renderCount(tabsMode, count, active) : null}
|
|
44
37
|
</div>
|
|
45
38
|
</div>
|
|
46
39
|
);
|
|
47
40
|
};
|
|
48
41
|
|
|
49
|
-
const
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
const renderCount = (showCounter: boolean | undefined, count: number, active: boolean) => {
|
|
60
|
-
return showCounter && count ? (
|
|
61
|
-
<div className={`${BADGE_CLASSES} ${active ? ACTIVE_BADGE_CLASSES : INACTIVE_BADGE_CLASSES}`}>
|
|
42
|
+
const renderCount = (tabsMode: TabsMode | undefined, count: number, active: boolean) => {
|
|
43
|
+
return (
|
|
44
|
+
<div
|
|
45
|
+
className={style(
|
|
46
|
+
BADGE_CLASSES,
|
|
47
|
+
active && tabsMode !== 'scrollable' ? LIGHT_BADGE_CLASSES : DARK_BADGE_CLASSES,
|
|
48
|
+
)}
|
|
49
|
+
>
|
|
62
50
|
{count}
|
|
63
51
|
</div>
|
|
64
|
-
)
|
|
52
|
+
);
|
|
65
53
|
};
|
|
@@ -9,12 +9,12 @@ export const WIDESCREEN_ACTIVE_LINK_CLASSES = 'bg-primary-main text-white';
|
|
|
9
9
|
|
|
10
10
|
export const TEXT_CLASSES = 'font-sans text-m text-center';
|
|
11
11
|
export const ACTIVE_TEXT_CLASSES = 'text-white';
|
|
12
|
-
export const INACTIVE_TEXT_CLASSES = 'text-secondary-text group-hover/btn:text-primary-main';
|
|
12
|
+
export const INACTIVE_TEXT_CLASSES = 'text-secondary-text sm:group-hover/btn:text-primary-main';
|
|
13
13
|
|
|
14
14
|
export const WHITE_ACTIVE_TEXT_CLASSES = 'text-primary-main';
|
|
15
15
|
|
|
16
|
-
const
|
|
17
|
-
|
|
16
|
+
const TAB_CLASSES = {
|
|
17
|
+
block: {
|
|
18
18
|
scrollable: {
|
|
19
19
|
active: `inline-flex px-4 grow whitespace-nowrap ${LINK_CLASSES} ${SCROLLABLE_ACTIVE_LINK_CLASSES}`,
|
|
20
20
|
default: `inline-flex px-4 grow whitespace-nowrap ${LINK_CLASSES} ${INACTIVE_LINK_CLASSES}`,
|
|
@@ -30,37 +30,7 @@ const GROUP_TAB_CLASSES = {
|
|
|
30
30
|
},
|
|
31
31
|
text: {
|
|
32
32
|
scrollable: {
|
|
33
|
-
active:
|
|
34
|
-
default: ``,
|
|
35
|
-
},
|
|
36
|
-
centered: {
|
|
37
|
-
active: '',
|
|
38
|
-
default: '',
|
|
39
|
-
},
|
|
40
|
-
wideScreen: {
|
|
41
|
-
active: '',
|
|
42
|
-
default: '',
|
|
43
|
-
},
|
|
44
|
-
},
|
|
45
|
-
};
|
|
46
|
-
const LINK_TAB_CLASSES = {
|
|
47
|
-
link: {
|
|
48
|
-
scrollable: {
|
|
49
|
-
active: `inline-flex px-4 grow whitespace-nowrap ${LINK_CLASSES} ${SCROLLABLE_ACTIVE_LINK_CLASSES}`,
|
|
50
|
-
default: `inline-flex px-4 grow whitespace-nowrap ${LINK_CLASSES} ${INACTIVE_LINK_CLASSES}`,
|
|
51
|
-
},
|
|
52
|
-
centered: {
|
|
53
|
-
active: `px-4 rounded-md ${LINK_CLASSES} ${WIDESCREEN_ACTIVE_LINK_CLASSES} whitespace-nowrap`,
|
|
54
|
-
default: `px-4 rounded-md ${LINK_CLASSES} group/btn bg-transparent whitespace-nowrap`,
|
|
55
|
-
},
|
|
56
|
-
wideScreen: {
|
|
57
|
-
active: `${LINK_CLASSES} ${WIDESCREEN_ACTIVE_LINK_CLASSES}`,
|
|
58
|
-
default: `${LINK_CLASSES} ${INACTIVE_LINK_CLASSES}`,
|
|
59
|
-
},
|
|
60
|
-
},
|
|
61
|
-
text: {
|
|
62
|
-
scrollable: {
|
|
63
|
-
active: `${TEXT_CLASSES} flex items-center h-full border-0 border-b-2 ${WHITE_ACTIVE_TEXT_CLASSES}`,
|
|
33
|
+
active: `${TEXT_CLASSES} flex items-center h-full border-0 border-b-2`,
|
|
64
34
|
default: `${TEXT_CLASSES} ${INACTIVE_TEXT_CLASSES}`,
|
|
65
35
|
},
|
|
66
36
|
centered: {
|
|
@@ -68,22 +38,19 @@ const LINK_TAB_CLASSES = {
|
|
|
68
38
|
default: `${TEXT_CLASSES} ${INACTIVE_TEXT_CLASSES}`,
|
|
69
39
|
},
|
|
70
40
|
wideScreen: {
|
|
71
|
-
active: `${TEXT_CLASSES} ${ACTIVE_TEXT_CLASSES}`,
|
|
72
|
-
default: `${TEXT_CLASSES} ${INACTIVE_TEXT_CLASSES}`,
|
|
41
|
+
active: `${TEXT_CLASSES} ${ACTIVE_TEXT_CLASSES} text-black px-2.5 bg-white sm:bg-primary-main sm:text-white`,
|
|
42
|
+
default: `${TEXT_CLASSES} ${INACTIVE_TEXT_CLASSES} px-2.5 bg-white`,
|
|
73
43
|
},
|
|
74
44
|
},
|
|
75
45
|
};
|
|
76
46
|
|
|
77
|
-
export const
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
};
|
|
83
|
-
|
|
84
|
-
export const getLinkTabClassName = (type: string, active: boolean, tabsMode?: TabsMode) => {
|
|
47
|
+
export const getTabClassName: (type: string, active: boolean, tabsMode?: TabsMode) => string = (
|
|
48
|
+
type,
|
|
49
|
+
active,
|
|
50
|
+
tabsMode,
|
|
51
|
+
) => {
|
|
85
52
|
const styleActive = active ? 'active' : 'default';
|
|
86
53
|
const mode = tabsMode || 'wideScreen';
|
|
87
54
|
|
|
88
|
-
return
|
|
55
|
+
return TAB_CLASSES[type][mode][styleActive];
|
|
89
56
|
};
|
|
@@ -11,7 +11,11 @@ export const PhoneInput = JSX<InputProps>(({ children, onChange, ...inputProps }
|
|
|
11
11
|
);
|
|
12
12
|
|
|
13
13
|
return (
|
|
14
|
-
<Input
|
|
14
|
+
<Input
|
|
15
|
+
onChange={handleChange}
|
|
16
|
+
onFocus={(event) => handleChange((event?.target?.value as string) || '')}
|
|
17
|
+
{...inputProps}
|
|
18
|
+
>
|
|
15
19
|
{children}
|
|
16
20
|
</Input>
|
|
17
21
|
);
|
package/package.json
CHANGED
package/src/common.css
CHANGED
|
@@ -27,6 +27,7 @@ html {
|
|
|
27
27
|
--color-gradient-from: 141, 189, 76;
|
|
28
28
|
--color-gradient-to: 69, 172, 69;
|
|
29
29
|
}
|
|
30
|
+
|
|
30
31
|
/* Business clients | Light-Green */
|
|
31
32
|
[data-theme='bc'] {
|
|
32
33
|
--color-primary-main: var(--color-green-light);
|
|
@@ -37,6 +38,7 @@ html {
|
|
|
37
38
|
--color-gradient-from: 141, 189, 76; /* TODO: change color to theme bc */
|
|
38
39
|
--color-gradient-to: 69, 172, 69; /* TODO: change color to theme bc */
|
|
39
40
|
}
|
|
41
|
+
|
|
40
42
|
/* Ecosystem own | Yellow */
|
|
41
43
|
[data-theme='eo'] {
|
|
42
44
|
--color-primary-main: var(--color-yellow);
|
|
@@ -255,6 +257,7 @@ html {
|
|
|
255
257
|
table-layout: fixed;
|
|
256
258
|
text-align: left;
|
|
257
259
|
}
|
|
260
|
+
|
|
258
261
|
.striped.md-container table thead,
|
|
259
262
|
.horizontal-separator.md-container table thead {
|
|
260
263
|
color: rgb(var(--color-secondary-text));
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import '../../setup-fixture';
|
|
2
|
+
import { BenefitsBlock } from './BenefitsBlock';
|
|
3
|
+
import type { Picture } from '../../model/Picture';
|
|
4
|
+
|
|
5
|
+
const image: Picture = {
|
|
6
|
+
src: 'money-1.png',
|
|
7
|
+
format: 'webp',
|
|
8
|
+
alt: 'Потребительский кредит наличными',
|
|
9
|
+
size: {
|
|
10
|
+
width: 70,
|
|
11
|
+
height: 70,
|
|
12
|
+
},
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export default {
|
|
16
|
+
default: (
|
|
17
|
+
<div className="container grid grid-cols-12">
|
|
18
|
+
<BenefitsBlock
|
|
19
|
+
className="col-span-12"
|
|
20
|
+
title="Оформите выгодный кредит для бизнеса"
|
|
21
|
+
benefitList={[
|
|
22
|
+
{
|
|
23
|
+
label: 'Гибкий подход к обеспечению',
|
|
24
|
+
icon: image,
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
label: 'Учет индивидуальных особенностей и потребностей бизнеса',
|
|
28
|
+
icon: image,
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
label: 'Льготная ставка до 5% годовых',
|
|
32
|
+
icon: image,
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
label: 'Возможность беззалогового кредитования',
|
|
36
|
+
icon: image,
|
|
37
|
+
},
|
|
38
|
+
]}
|
|
39
|
+
version="primary"
|
|
40
|
+
/>
|
|
41
|
+
</div>
|
|
42
|
+
),
|
|
43
|
+
};
|
|
@@ -1,9 +1,3 @@
|
|
|
1
|
-
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
-
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
3
|
-
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
4
|
-
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
5
|
-
import { Img } from '../../ui-kit/Img/Img';
|
|
6
|
-
import { style } from '../../utils/style';
|
|
7
1
|
import type {
|
|
8
2
|
BenefitBlockItemProps,
|
|
9
3
|
BenefitsBlockContent,
|
|
@@ -11,47 +5,56 @@ import type {
|
|
|
11
5
|
ListBenefitDef,
|
|
12
6
|
TextBenefitDef,
|
|
13
7
|
} from './BenefitsBlockContent';
|
|
8
|
+
import { benefitImageStyles } from './benefitImageStyles';
|
|
9
|
+
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
10
|
+
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
11
|
+
import { Img } from '../../ui-kit/Img/Img';
|
|
12
|
+
import { JSX } from '@redneckz/uni-jsx';
|
|
13
|
+
import { style } from '../../utils/style';
|
|
14
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
14
15
|
|
|
15
16
|
interface BenefitsBlockProps extends BenefitsBlockContent, UniBlockProps {}
|
|
16
17
|
|
|
17
18
|
export const BenefitsBlock = JSX<BenefitsBlockProps>(
|
|
18
19
|
({ className = '', title, benefitList, ...rest }) => (
|
|
19
|
-
<BlockWrapper
|
|
20
|
-
|
|
21
|
-
defaultPadding="p-default"
|
|
22
|
-
{...rest}
|
|
23
|
-
>
|
|
24
|
-
{title ? (
|
|
25
|
-
<Heading headingType="h3" as="h2" className="max-w-[47rem] text-center" title={title} />
|
|
26
|
-
) : null}
|
|
20
|
+
<BlockWrapper className={className} defaultPadding="p-default" {...rest}>
|
|
21
|
+
{title ? <Heading headingType="h3" as="h2" className="text-center" title={title} /> : null}
|
|
27
22
|
{benefitList?.length ? (
|
|
28
|
-
<div
|
|
29
|
-
|
|
23
|
+
<div
|
|
24
|
+
className="sm:flex sm:flex-wrap w-full sm:justify-center sm:gap-x-m gap-y-lg sm:gap-y-0 mt-8"
|
|
25
|
+
role="list"
|
|
26
|
+
>
|
|
27
|
+
{benefitList.map(renderBenefit)}
|
|
30
28
|
</div>
|
|
31
29
|
) : null}
|
|
32
30
|
</BlockWrapper>
|
|
33
31
|
),
|
|
34
32
|
);
|
|
35
33
|
|
|
36
|
-
const
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
34
|
+
const renderBenefit = (benefit: BenefitBlockItemProps, i: number) => (
|
|
35
|
+
<div
|
|
36
|
+
key={String(i)}
|
|
37
|
+
className="flex items-center sm:basis-1/2 sm:max-w-[400px] mb-14"
|
|
38
|
+
role="listitem"
|
|
39
|
+
>
|
|
40
|
+
{benefit?.icon?.icon ? (
|
|
41
|
+
<Img
|
|
42
|
+
className={style(
|
|
43
|
+
'p-3 mr-5 shrink-0 bg-main-divider text-primary-main group-data-secondary:bg-white/30 group-data-secondary:text-black',
|
|
44
|
+
benefitImageStyles,
|
|
45
|
+
)}
|
|
46
|
+
image={benefit.icon}
|
|
47
|
+
/>
|
|
48
|
+
) : null}
|
|
49
|
+
{benefit?.icon?.src ? <Img className="mr-5 shrink-0" image={benefit.icon} /> : null}
|
|
50
|
+
{benefit?.label ? (
|
|
51
|
+
<div className="sm:h-full">
|
|
52
|
+
<Heading headingType="h6">{benefit.label}</Heading>
|
|
53
|
+
{renderDescription(benefit.description)}
|
|
51
54
|
</div>
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
+
) : null}
|
|
56
|
+
</div>
|
|
57
|
+
);
|
|
55
58
|
|
|
56
59
|
const renderDescription = (description: DescriptionDef | undefined) => {
|
|
57
60
|
const benefitType = description?.benefitType || null;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const benefitImageStyles = 'w-56 h-56 min-w-56';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const benefitImageStyles = 'w-12 h-12 min-w-12 rounded-full';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { BlocksRegistry } from '../model/BlocksRegistry';
|
|
2
|
+
import { BonusBenefitsBlock } from './BonusBenefitsBlock/BonusBenefitsBlock';
|
|
2
3
|
import { ButtonsBlock } from './ButtonsBlock/ButtonsBlock';
|
|
3
4
|
import { CardTransfer } from './CardTransfer/CardTransfer';
|
|
4
5
|
import { Carousel } from './Carousel/Carousel';
|
|
@@ -19,12 +20,15 @@ import { ProductGallery } from './ProductGallery/ProductGallery';
|
|
|
19
20
|
import { RichTextBlock } from './RichTextBlock/RichTextBlock';
|
|
20
21
|
import { RollupItem } from './RollupItem/RollupItem';
|
|
21
22
|
import { StepsBlock } from './StepsBlock/StepsBlock';
|
|
23
|
+
import { Tabs } from './Tabs/Tabs';
|
|
22
24
|
import { TariffsTable } from './TariffsTable/TariffsTable';
|
|
23
25
|
import { TextBlock } from './TextBlock/TextBlock';
|
|
24
26
|
import { VerticalLayout } from './VerticalLayout/VerticalLayout';
|
|
27
|
+
import { BenefitsBlock } from './BenefitsBlock/BenefitsBlock';
|
|
25
28
|
|
|
26
29
|
export const Blocks: BlocksRegistry = {
|
|
27
30
|
ButtonsBlock,
|
|
31
|
+
BonusBenefitsBlock,
|
|
28
32
|
CardTransfer,
|
|
29
33
|
Carousel,
|
|
30
34
|
CarouselTariffsCard,
|
|
@@ -39,6 +43,7 @@ export const Blocks: BlocksRegistry = {
|
|
|
39
43
|
Placeholder,
|
|
40
44
|
ProductBlock,
|
|
41
45
|
StepsBlock,
|
|
46
|
+
Tabs,
|
|
42
47
|
TariffsTable,
|
|
43
48
|
TextBlock,
|
|
44
49
|
RichTextBlock,
|
|
@@ -47,4 +52,5 @@ export const Blocks: BlocksRegistry = {
|
|
|
47
52
|
CarouselRecommendationCard,
|
|
48
53
|
CarouselProgramsCard,
|
|
49
54
|
ProductGallery,
|
|
55
|
+
BenefitsBlock,
|
|
50
56
|
};
|