@redneckz/wildless-cms-uni-blocks 0.13.3 → 0.13.4
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.11.js +28 -0
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +114 -87
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/bundle/components/Carousel/Carousel.d.ts +1 -1
- package/bundle/components/Carousel/renderCardHighlight.d.ts +7 -0
- package/bundle/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/bundle/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/bundle/components/Carousel/visibleItemCountStyle.mobile.d.ts +1 -0
- package/bundle/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/bundle/components/MobileAppTile/buttonsConditionStyle.mobile.d.ts +3 -0
- package/bundle/components/RollupItem/RollupItem.d.ts +6 -1
- package/bundle/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/bundle/utils/style.d.ts +2 -1
- package/dist/components/Bonus/Bonus.js +6 -4
- package/dist/components/Bonus/Bonus.js.map +1 -1
- package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +1 -1
- package/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/dist/components/Calculator/BusinessDepositCalculatorForm.js +1 -1
- package/dist/components/Calculator/BusinessDepositCalculatorForm.js.map +1 -1
- package/dist/components/CardTransfer/CardTransfer.js +9 -6
- package/dist/components/CardTransfer/CardTransfer.js.map +1 -1
- package/dist/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/dist/components/Carousel/Carousel.d.ts +1 -1
- package/dist/components/Carousel/Carousel.js +8 -12
- package/dist/components/Carousel/Carousel.js.map +1 -1
- package/dist/components/Carousel/renderCardHighlight.d.ts +7 -0
- package/dist/components/Carousel/renderCardHighlight.js +9 -0
- package/dist/components/Carousel/renderCardHighlight.js.map +1 -0
- package/dist/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/dist/components/Carousel/renderCarouselCards.js +28 -0
- package/dist/components/Carousel/renderCarouselCards.js.map +1 -0
- package/dist/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/dist/components/Carousel/visibleItemCountStyle.js +4 -0
- package/dist/components/Carousel/visibleItemCountStyle.js.map +1 -0
- package/dist/components/Carousel/visibleItemCountStyle.mobile.d.ts +1 -0
- package/dist/components/Carousel/visibleItemCountStyle.mobile.js +4 -0
- package/dist/components/Carousel/visibleItemCountStyle.mobile.js.map +1 -0
- package/dist/components/CarouselCard/CarouselCard.js +2 -2
- package/dist/components/CarouselCard/CarouselCard.js.map +1 -1
- package/dist/components/CarouselLinks/CarouselLinks.js +1 -1
- package/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +3 -6
- package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/dist/components/MobileAppTile/MobileAppTile.js +2 -2
- package/dist/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/dist/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/dist/components/MobileAppTile/buttonsConditionStyle.js +6 -0
- package/dist/components/MobileAppTile/buttonsConditionStyle.js.map +1 -0
- package/dist/components/MobileAppTile/buttonsConditionStyle.mobile.d.ts +3 -0
- package/dist/components/MobileAppTile/buttonsConditionStyle.mobile.js +13 -0
- package/dist/components/MobileAppTile/buttonsConditionStyle.mobile.js.map +1 -0
- package/dist/components/RollupItem/RollupItem.d.ts +6 -1
- package/dist/components/RollupItem/RollupItem.js +2 -2
- package/dist/components/RollupItem/RollupItem.js.map +1 -1
- package/dist/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/dist/components/SafeDepositRental/SafeDepositRentalTotal.js +1 -1
- package/dist/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
- package/dist/ui-kit/BaseTile/BaseTile.js +6 -2
- package/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/dist/utils/style.d.ts +2 -1
- package/dist/utils/style.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Bonus/Bonus.js +6 -4
- package/lib/components/Bonus/Bonus.js.map +1 -1
- package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +1 -1
- package/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/lib/components/Calculator/BusinessDepositCalculatorForm.js +1 -1
- package/lib/components/Calculator/BusinessDepositCalculatorForm.js.map +1 -1
- package/lib/components/CardTransfer/CardTransfer.js +9 -6
- package/lib/components/CardTransfer/CardTransfer.js.map +1 -1
- package/lib/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/lib/components/Carousel/Carousel.d.ts +1 -1
- package/lib/components/Carousel/Carousel.js +8 -12
- package/lib/components/Carousel/Carousel.js.map +1 -1
- package/lib/components/Carousel/renderCardHighlight.d.ts +6 -0
- package/lib/components/Carousel/renderCardHighlight.js +6 -0
- package/lib/components/Carousel/renderCardHighlight.js.map +1 -0
- package/lib/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/lib/components/Carousel/renderCarouselCards.js +25 -0
- package/lib/components/Carousel/renderCarouselCards.js.map +1 -0
- package/lib/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/lib/components/Carousel/visibleItemCountStyle.js +2 -0
- package/lib/components/Carousel/visibleItemCountStyle.js.map +1 -0
- package/lib/components/Carousel/visibleItemCountStyle.mobile.d.ts +1 -0
- package/lib/components/Carousel/visibleItemCountStyle.mobile.js +2 -0
- package/lib/components/Carousel/visibleItemCountStyle.mobile.js.map +1 -0
- package/lib/components/CarouselCard/CarouselCard.js +2 -2
- package/lib/components/CarouselCard/CarouselCard.js.map +1 -1
- package/lib/components/CarouselLinks/CarouselLinks.js +1 -1
- package/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.fixture.d.ts +0 -1
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.fixture.mobile.d.ts +0 -1
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +3 -6
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/lib/components/MobileAppTile/MobileAppTile.js +2 -2
- package/lib/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/lib/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/lib/components/MobileAppTile/buttonsConditionStyle.js +3 -0
- package/lib/components/MobileAppTile/buttonsConditionStyle.js.map +1 -0
- package/lib/components/MobileAppTile/buttonsConditionStyle.mobile.d.ts +2 -0
- package/lib/components/MobileAppTile/buttonsConditionStyle.mobile.js +10 -0
- package/lib/components/MobileAppTile/buttonsConditionStyle.mobile.js.map +1 -0
- package/lib/components/RollupItem/RollupItem.d.ts +6 -1
- package/lib/components/RollupItem/RollupItem.js +2 -2
- package/lib/components/RollupItem/RollupItem.js.map +1 -1
- package/lib/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/lib/components/SafeDepositRental/SafeDepositRentalTotal.js +1 -1
- package/lib/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
- package/lib/ui-kit/BaseTile/BaseTile.js +6 -2
- package/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/lib/utils/style.d.ts +2 -1
- package/lib/utils/style.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +113 -82
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/mobile/bundle/components/Carousel/Carousel.d.ts +1 -1
- package/mobile/bundle/components/Carousel/renderCardHighlight.d.ts +7 -0
- package/mobile/bundle/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/mobile/bundle/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/mobile/bundle/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/mobile/bundle/components/RollupItem/RollupItem.d.ts +6 -1
- package/mobile/bundle/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/mobile/bundle/utils/style.d.ts +2 -1
- package/mobile/dist/components/Bonus/Bonus.js +6 -4
- package/mobile/dist/components/Bonus/Bonus.js.map +1 -1
- package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js +1 -1
- package/mobile/dist/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/mobile/dist/components/Calculator/BusinessDepositCalculatorForm.js +1 -1
- package/mobile/dist/components/Calculator/BusinessDepositCalculatorForm.js.map +1 -1
- package/mobile/dist/components/CardTransfer/CardTransfer.js +9 -6
- package/mobile/dist/components/CardTransfer/CardTransfer.js.map +1 -1
- package/mobile/dist/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/mobile/dist/components/Carousel/Carousel.d.ts +1 -1
- package/mobile/dist/components/Carousel/Carousel.js +8 -12
- package/mobile/dist/components/Carousel/Carousel.js.map +1 -1
- package/mobile/dist/components/Carousel/renderCardHighlight.d.ts +7 -0
- package/mobile/dist/components/Carousel/renderCardHighlight.js +9 -0
- package/mobile/dist/components/Carousel/renderCardHighlight.js.map +1 -0
- package/mobile/dist/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/mobile/dist/components/Carousel/renderCarouselCards.js +28 -0
- package/mobile/dist/components/Carousel/renderCarouselCards.js.map +1 -0
- package/mobile/dist/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/mobile/dist/components/Carousel/visibleItemCountStyle.js +4 -0
- package/mobile/dist/components/Carousel/visibleItemCountStyle.js.map +1 -0
- package/mobile/dist/components/CarouselCard/CarouselCard.js +2 -2
- package/mobile/dist/components/CarouselCard/CarouselCard.js.map +1 -1
- package/mobile/dist/components/CarouselLinks/CarouselLinks.js +1 -1
- package/mobile/dist/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +3 -6
- package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/mobile/dist/components/MobileAppTile/MobileAppTile.js +2 -2
- package/mobile/dist/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/mobile/dist/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/mobile/dist/components/MobileAppTile/buttonsConditionStyle.js +13 -0
- package/mobile/dist/components/MobileAppTile/buttonsConditionStyle.js.map +1 -0
- package/mobile/dist/components/RollupItem/RollupItem.d.ts +6 -1
- package/mobile/dist/components/RollupItem/RollupItem.js +2 -2
- package/mobile/dist/components/RollupItem/RollupItem.js.map +1 -1
- package/mobile/dist/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/mobile/dist/components/SafeDepositRental/SafeDepositRentalTotal.js +1 -1
- package/mobile/dist/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js +6 -2
- package/mobile/dist/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/dist/utils/style.d.ts +2 -1
- package/mobile/dist/utils/style.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/Bonus/Bonus.js +6 -4
- package/mobile/lib/components/Bonus/Bonus.js.map +1 -1
- package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js +1 -1
- package/mobile/lib/components/BonusBenefitsBlock/BonusBenefitsBlock.js.map +1 -1
- package/mobile/lib/components/Calculator/BusinessDepositCalculatorForm.js +1 -1
- package/mobile/lib/components/Calculator/BusinessDepositCalculatorForm.js.map +1 -1
- package/mobile/lib/components/CardTransfer/CardTransfer.js +9 -6
- package/mobile/lib/components/CardTransfer/CardTransfer.js.map +1 -1
- package/mobile/lib/components/CardTransfer/CardTransferContent.d.ts +5 -0
- package/mobile/lib/components/Carousel/Carousel.d.ts +1 -1
- package/mobile/lib/components/Carousel/Carousel.js +8 -12
- package/mobile/lib/components/Carousel/Carousel.js.map +1 -1
- package/mobile/lib/components/Carousel/renderCardHighlight.d.ts +7 -0
- package/mobile/lib/components/Carousel/renderCardHighlight.js +6 -0
- package/mobile/lib/components/Carousel/renderCardHighlight.js.map +1 -0
- package/mobile/lib/components/Carousel/renderCarouselCards.d.ts +5 -0
- package/mobile/lib/components/Carousel/renderCarouselCards.js +25 -0
- package/mobile/lib/components/Carousel/renderCarouselCards.js.map +1 -0
- package/mobile/lib/components/Carousel/visibleItemCountStyle.d.ts +1 -0
- package/mobile/lib/components/Carousel/visibleItemCountStyle.js +2 -0
- package/mobile/lib/components/Carousel/visibleItemCountStyle.js.map +1 -0
- package/mobile/lib/components/CarouselCard/CarouselCard.js +2 -2
- package/mobile/lib/components/CarouselCard/CarouselCard.js.map +1 -1
- package/mobile/lib/components/CarouselLinks/CarouselLinks.js +1 -1
- package/mobile/lib/components/CarouselLinks/CarouselLinks.js.map +1 -1
- package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +3 -6
- package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/mobile/lib/components/MobileAppTile/MobileAppTile.js +2 -2
- package/mobile/lib/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/mobile/lib/components/MobileAppTile/buttonsConditionStyle.d.ts +3 -0
- package/mobile/lib/components/MobileAppTile/buttonsConditionStyle.js +10 -0
- package/mobile/lib/components/MobileAppTile/buttonsConditionStyle.js.map +1 -0
- package/mobile/lib/components/RollupItem/RollupItem.d.ts +6 -1
- package/mobile/lib/components/RollupItem/RollupItem.js +2 -2
- package/mobile/lib/components/RollupItem/RollupItem.js.map +1 -1
- package/mobile/lib/components/RollupItem/RollupItemContent.d.ts +0 -4
- package/mobile/lib/components/SafeDepositRental/SafeDepositRentalTotal.js +1 -1
- package/mobile/lib/components/SafeDepositRental/SafeDepositRentalTotal.js.map +1 -1
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js +6 -2
- package/mobile/lib/ui-kit/BaseTile/BaseTile.js.map +1 -1
- package/mobile/lib/utils/style.d.ts +2 -1
- package/mobile/lib/utils/style.js.map +1 -1
- package/mobile/src/components/Bonus/Bonus.tsx +25 -21
- package/mobile/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +1 -2
- package/mobile/src/components/Calculator/BusinessDepositCalculatorForm.tsx +1 -0
- package/mobile/src/components/CardTransfer/CardTransfer.example.json +2 -1
- package/mobile/src/components/CardTransfer/CardTransfer.tsx +13 -7
- package/mobile/src/components/CardTransfer/CardTransferContent.ts +5 -0
- package/mobile/src/components/Carousel/Carousel.tsx +11 -20
- package/mobile/src/components/Carousel/renderCardHighlight.tsx +22 -0
- package/mobile/src/components/Carousel/renderCarouselCards.tsx +58 -0
- package/mobile/src/components/Carousel/visibleItemCountStyle.tsx +1 -0
- package/mobile/src/components/CarouselCard/CarouselCard.tsx +4 -2
- package/mobile/src/components/CarouselLinks/CarouselLinks.tsx +3 -3
- package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +3 -30
- package/mobile/src/components/MobileAppTile/MobileAppTile.tsx +2 -2
- package/mobile/src/components/MobileAppTile/buttonsConditionStyle.tsx +12 -0
- package/mobile/src/components/RollupItem/RollupItem.tsx +9 -6
- package/mobile/src/components/RollupItem/RollupItem.ui.json +1 -5
- package/mobile/src/components/RollupItem/RollupItemContent.ts +0 -4
- package/mobile/src/components/SafeDepositRental/SafeDepositRentalTotal.tsx +1 -1
- package/mobile/src/ui-kit/BaseTile/BaseTile.tsx +15 -4
- package/mobile/src/utils/style.ts +2 -1
- package/package.json +1 -1
- package/src/components/Bonus/Bonus.tsx +25 -21
- package/src/components/BonusBenefitsBlock/BonusBenefitsBlock.tsx +1 -2
- package/src/components/Calculator/BusinessDepositCalculatorForm.tsx +1 -0
- package/src/components/CardTransfer/CardTransfer.example.json +2 -1
- package/src/components/CardTransfer/CardTransfer.tsx +13 -7
- package/src/components/CardTransfer/CardTransferContent.ts +5 -0
- package/src/components/Carousel/Carousel.tsx +11 -20
- package/src/components/Carousel/renderCardHighlight.tsx +22 -0
- package/src/components/Carousel/renderCarouselCards.tsx +58 -0
- package/src/components/Carousel/visibleItemCountStyle.mobile.tsx +1 -0
- package/src/components/Carousel/visibleItemCountStyle.tsx +1 -0
- package/src/components/CarouselCard/CarouselCard.tsx +4 -2
- package/src/components/CarouselInvestmentCard/CarouselInvestmentCard.fixture.tsx +6 -6
- package/src/components/CarouselLinks/CarouselLinks.fixture.tsx +10 -13
- package/src/components/CarouselLinks/CarouselLinks.tsx +3 -3
- package/src/components/CarouselTariffsCard/CarouselTariffsCard.fixture.mobile.tsx +1 -6
- package/src/components/CarouselTariffsCard/CarouselTariffsCard.fixture.tsx +0 -5
- package/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +3 -30
- package/src/components/MobileAppTile/MobileAppTile.tsx +2 -2
- package/src/components/MobileAppTile/buttonsConditionStyle.mobile.tsx +12 -0
- package/src/components/MobileAppTile/buttonsConditionStyle.tsx +5 -0
- package/src/components/RollupItem/RollupItem.fixture.mobile.tsx +6 -3
- package/src/components/RollupItem/RollupItem.tsx +9 -6
- package/src/components/RollupItem/RollupItem.ui.json +1 -5
- package/src/components/RollupItem/RollupItemContent.ts +0 -4
- package/src/components/SafeDepositRental/SafeDepositRentalTotal.tsx +1 -1
- package/src/ui-kit/BaseTile/BaseTile.tsx +15 -4
- package/src/utils/style.ts +2 -1
- package/bundle/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/bundle/components/CarouselTariffsCard/getPaddingStyle.mobile.d.ts +0 -1
- package/dist/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/dist/components/CarouselTariffsCard/getPaddingStyle.js +0 -5
- package/dist/components/CarouselTariffsCard/getPaddingStyle.js.map +0 -1
- package/dist/components/CarouselTariffsCard/getPaddingStyle.mobile.d.ts +0 -1
- package/dist/components/CarouselTariffsCard/getPaddingStyle.mobile.js +0 -5
- package/dist/components/CarouselTariffsCard/getPaddingStyle.mobile.js.map +0 -1
- package/lib/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/lib/components/CarouselTariffsCard/getPaddingStyle.js +0 -2
- package/lib/components/CarouselTariffsCard/getPaddingStyle.js.map +0 -1
- package/lib/components/CarouselTariffsCard/getPaddingStyle.mobile.d.ts +0 -1
- package/lib/components/CarouselTariffsCard/getPaddingStyle.mobile.js +0 -2
- package/lib/components/CarouselTariffsCard/getPaddingStyle.mobile.js.map +0 -1
- package/mobile/bundle/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/mobile/dist/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/mobile/dist/components/CarouselTariffsCard/getPaddingStyle.js +0 -5
- package/mobile/dist/components/CarouselTariffsCard/getPaddingStyle.js.map +0 -1
- package/mobile/lib/components/CarouselTariffsCard/getPaddingStyle.d.ts +0 -1
- package/mobile/lib/components/CarouselTariffsCard/getPaddingStyle.js +0 -2
- package/mobile/lib/components/CarouselTariffsCard/getPaddingStyle.js.map +0 -1
- package/mobile/src/components/CarouselTariffsCard/getPaddingStyle.tsx +0 -2
- package/src/components/CarouselTariffsCard/getPaddingStyle.mobile.tsx +0 -2
- package/src/components/CarouselTariffsCard/getPaddingStyle.tsx +0 -2
|
@@ -53,16 +53,16 @@ const renderLinks = (links: LinkProps[], maxLinksCount: number) => {
|
|
|
53
53
|
|
|
54
54
|
return (
|
|
55
55
|
<Carousel
|
|
56
|
-
className="
|
|
56
|
+
className="sm:w-2/3 w-full p-0 sm:p-xs"
|
|
57
57
|
version="secondary"
|
|
58
58
|
itemCount={itemCount}
|
|
59
59
|
arrowsPadded={false}
|
|
60
|
-
showDots={
|
|
60
|
+
showDots={false}
|
|
61
61
|
>
|
|
62
62
|
{new Array(itemCount).fill(null).map((_, groupIndex) => (
|
|
63
63
|
<div
|
|
64
64
|
key={String(groupIndex)}
|
|
65
|
-
className={style('flex flex-wrap self-start sm:w-[672px]
|
|
65
|
+
className={style('flex flex-wrap self-start w-full sm:w-[672px]')}
|
|
66
66
|
>
|
|
67
67
|
{links
|
|
68
68
|
.slice(groupIndex * maxLinksCount, (groupIndex + 1) * maxLinksCount)
|
|
@@ -10,10 +10,8 @@ import { FoldableSection } from '../../ui-kit/Foldable/FoldableSection';
|
|
|
10
10
|
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
11
11
|
import { Icon } from '../../ui-kit/Icon/Icon';
|
|
12
12
|
import { Img } from '../../ui-kit/Img/Img';
|
|
13
|
-
import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
|
|
14
13
|
import { style } from '../../utils/style';
|
|
15
14
|
import type { CarouselTariffsCardContent } from './CarouselTariffsCardContent';
|
|
16
|
-
import { getPaddingStyle } from './getPaddingStyle';
|
|
17
15
|
import { renderCardInfo } from './renderCardInfo';
|
|
18
16
|
|
|
19
17
|
export interface CarouselTariffsCardProps extends CarouselTariffsCardContent, UniBlockProps {}
|
|
@@ -21,27 +19,13 @@ export interface CarouselTariffsCardProps extends CarouselTariffsCardContent, Un
|
|
|
21
19
|
const VISIBLE_CELLS_COUNT = 1;
|
|
22
20
|
|
|
23
21
|
export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
|
|
24
|
-
({
|
|
25
|
-
className = '',
|
|
26
|
-
title,
|
|
27
|
-
align = 'text-center',
|
|
28
|
-
icon,
|
|
29
|
-
isHighlighting = false,
|
|
30
|
-
button,
|
|
31
|
-
cardCells = [],
|
|
32
|
-
...rest
|
|
33
|
-
}) => {
|
|
22
|
+
({ className = '', title, align = 'text-center', icon, button, cardCells = [], ...rest }) => {
|
|
34
23
|
const cellsNode = cardCells.map(renderCardInfo);
|
|
35
24
|
const visibleCells = cellsNode.slice(0, VISIBLE_CELLS_COUNT);
|
|
36
25
|
const hiddenCells = cellsNode.slice(VISIBLE_CELLS_COUNT);
|
|
37
26
|
|
|
38
27
|
return (
|
|
39
|
-
<BlockWrapper
|
|
40
|
-
className={style('relative flex flex-col', className)}
|
|
41
|
-
defaultPadding={getPaddingStyle(isHighlighting)}
|
|
42
|
-
{...rest}
|
|
43
|
-
>
|
|
44
|
-
{isHighlighting ? renderHitIcon() : null}
|
|
28
|
+
<BlockWrapper className={style('flex flex-col', className)} defaultPadding="p-3xl" {...rest}>
|
|
45
29
|
{renderIconBlock(icon)}
|
|
46
30
|
{title ? (
|
|
47
31
|
<Heading className={style('pt-xs', align)} headingType="h5" title={title} />
|
|
@@ -64,9 +48,7 @@ export const CarouselTariffsCard = JSX<CarouselTariffsCardProps>(
|
|
|
64
48
|
);
|
|
65
49
|
|
|
66
50
|
const renderIconBlock = (icon?: Picture) => (
|
|
67
|
-
<div className="
|
|
68
|
-
{icon?.src || icon?.icon ? <Img image={icon} /> : null}
|
|
69
|
-
</div>
|
|
51
|
+
<div className="self-center">{icon?.src || icon?.icon ? <Img image={icon} /> : null}</div>
|
|
70
52
|
);
|
|
71
53
|
|
|
72
54
|
const renderFoldButton = ({ isUnfolded, onToggle }: FoldablePartProps): VNode => (
|
|
@@ -83,12 +65,3 @@ const renderFoldButton = ({ isUnfolded, onToggle }: FoldablePartProps): VNode =>
|
|
|
83
65
|
/>
|
|
84
66
|
</button>
|
|
85
67
|
);
|
|
86
|
-
|
|
87
|
-
const renderHitIcon = (): VNode => (
|
|
88
|
-
<div className="absolute -top-6 -right-4 h-14 w-14 bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]">
|
|
89
|
-
<Icon iconVersion="black" name="HeartIcon" width="24" height="24" />
|
|
90
|
-
<Paragraph size="text-s" font="font-normal" align="text-center" color="text-primary-text">
|
|
91
|
-
ХИТ
|
|
92
|
-
</Paragraph>
|
|
93
|
-
</div>
|
|
94
|
-
);
|
|
@@ -3,13 +3,13 @@ import { AlignText } from '../../model/AlignText';
|
|
|
3
3
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
4
4
|
import { BaseTile } from '../../ui-kit/BaseTile/BaseTile';
|
|
5
5
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
6
|
-
import { renderButtonsSection } from '../../ui-kit/Button/renderButtonsSection';
|
|
7
6
|
import { Heading } from '../../ui-kit/Heading/Heading';
|
|
8
7
|
import { Img } from '../../ui-kit/Img/Img';
|
|
9
8
|
import { style } from '../../utils/style';
|
|
10
9
|
import type { MobileAppTileContent } from './MobileAppTileContent';
|
|
11
10
|
import { renderDescription } from './renderDescription';
|
|
12
11
|
import { renderList } from './renderList';
|
|
12
|
+
import { buttonsConditionStyle } from './buttonsConditionStyle';
|
|
13
13
|
|
|
14
14
|
export interface MobileAppTileProps extends MobileAppTileContent, UniBlockProps {}
|
|
15
15
|
|
|
@@ -51,7 +51,7 @@ export const MobileAppTile = JSX<MobileAppTileProps>(
|
|
|
51
51
|
) : null
|
|
52
52
|
}
|
|
53
53
|
rightImage={image?.src ? <Img className="hidden lg:block" image={image} /> : null}
|
|
54
|
-
buttons={
|
|
54
|
+
buttons={buttonsConditionStyle(buttons)}
|
|
55
55
|
>
|
|
56
56
|
{renderDescription(description)}
|
|
57
57
|
<div className="flex flex-1 flex-wrap gap-m items-center">
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { renderButtonsSection } from '../../ui-kit/Button/renderButtonsSection';
|
|
2
|
+
import type { ButtonProps } from '../../ui-kit/Button/ButtonProps';
|
|
3
|
+
import { style } from '../../utils/style';
|
|
4
|
+
|
|
5
|
+
export const buttonsConditionStyle = (buttons: ButtonProps[]) => {
|
|
6
|
+
const buttonsLengthMoreThanTwo = buttons.length > 2;
|
|
7
|
+
|
|
8
|
+
return renderButtonsSection(buttons, {
|
|
9
|
+
className: style(buttonsLengthMoreThanTwo ? 'w-full' : 'flex-nowrap'),
|
|
10
|
+
isVertical: buttonsLengthMoreThanTwo,
|
|
11
|
+
});
|
|
12
|
+
};
|
|
@@ -2,33 +2,36 @@ import { JSX } from '@redneckz/uni-jsx';
|
|
|
2
2
|
import { renderChildren } from '../../BlockRenderer/renderChildren';
|
|
3
3
|
import type { BlockVersion } from '../../model/BlockVersion';
|
|
4
4
|
import type { JSXBlock, UniBlockProps } from '../../model/JSXBlock';
|
|
5
|
-
import type { Picture } from '../../model/Picture';
|
|
6
5
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
7
6
|
import { DefaultFoldButton } from '../../ui-kit/Foldable/DefaultFoldButton';
|
|
8
7
|
import { Foldable } from '../../ui-kit/Foldable/Foldable';
|
|
9
8
|
import type { FoldablePartProps } from '../../ui-kit/Foldable/FoldablePartProps';
|
|
10
9
|
import { FoldableSection } from '../../ui-kit/Foldable/FoldableSection';
|
|
11
10
|
import { Icon } from '../../ui-kit/Icon/Icon';
|
|
12
|
-
import type {
|
|
11
|
+
import type { IconName, IconBgVersion, IconProps } from '../../ui-kit/Icon/IconProps';
|
|
13
12
|
import { Text } from '../../ui-kit/Text/Text';
|
|
14
13
|
import { style } from '../../utils/style';
|
|
15
14
|
import { foldableSectionStyles } from './foldableSectionStyles';
|
|
16
15
|
import { getIconName } from './getIconName';
|
|
17
|
-
import { renderRoundedIcon } from './renderRoundedIcon';
|
|
18
16
|
import { rollupIconVersion } from './rollupIconVersion';
|
|
19
17
|
import type { RollupItemContent } from './RollupItemContent';
|
|
20
18
|
import { rollupItemStyles } from './rollupItemStyles';
|
|
19
|
+
import type { Picture } from '../../model/Picture';
|
|
20
|
+
import { renderRoundedIcon } from './renderRoundedIcon';
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
interface RollupItemProps extends RollupItemContent, UniBlockProps {
|
|
23
|
+
labelIcon?: Picture;
|
|
24
|
+
labelIconBgVersion?: IconBgVersion;
|
|
25
|
+
}
|
|
23
26
|
|
|
24
27
|
export const RollupItem: JSXBlock<RollupItemProps> = JSX<RollupItemProps>(
|
|
25
28
|
({
|
|
26
29
|
className = '',
|
|
30
|
+
isExpanded,
|
|
31
|
+
isFoldButtonOnTop = true,
|
|
27
32
|
label = 'Развернуть',
|
|
28
33
|
labelIcon,
|
|
29
34
|
labelIconBgVersion,
|
|
30
|
-
isExpanded,
|
|
31
|
-
isFoldButtonOnTop = true,
|
|
32
35
|
version = 'primary',
|
|
33
36
|
...rest
|
|
34
37
|
}) => {
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import type { LabelProps } from '../../model/HeadlineType';
|
|
2
2
|
import type { UniBlockContent } from '../../model/JSXBlock';
|
|
3
|
-
import type { Picture } from '../../model/Picture';
|
|
4
|
-
import type { IconBgVersion } from '../../ui-kit/Icon/IconProps';
|
|
5
3
|
|
|
6
4
|
/**
|
|
7
5
|
* @title Сворачивающаяся секция
|
|
@@ -12,6 +10,4 @@ export type RollupItemContent = UniBlockContent &
|
|
|
12
10
|
isExpanded?: boolean;
|
|
13
11
|
/** @title Кнопка сверху */
|
|
14
12
|
isFoldButtonOnTop?: boolean;
|
|
15
|
-
labelIcon?: Picture; // TODO: только для мобильной версии
|
|
16
|
-
labelIconBgVersion?: IconBgVersion;
|
|
17
13
|
};
|
|
@@ -17,7 +17,7 @@ export const SafeDepositRentalTotal = JSX<SafeDepositRentalTotalProps>(({ days,
|
|
|
17
17
|
{renderTotal('Аренда за', days)}
|
|
18
18
|
{renderTotal('Цена', price + ' ₽')}
|
|
19
19
|
</div>
|
|
20
|
-
<span className="sm:hidden order-3 mb-xs text-s-light text-secondary-text">
|
|
20
|
+
<span className="sm:hidden order-3 mb-xs text-s font-light text-secondary-text">
|
|
21
21
|
{imageDescription}
|
|
22
22
|
</span>
|
|
23
23
|
<div className="flex flex-col items-center gap-s order-3 sm:order-none mb-xl sm:mb-0 bg-primary-main py-s sm:p-3xl text-center">
|
|
@@ -46,7 +46,7 @@ export const BaseTile = JSX<BaseTileProps>(
|
|
|
46
46
|
{renderImageContainer(leftImage, { imageAlign })}
|
|
47
47
|
<div
|
|
48
48
|
className={style(
|
|
49
|
-
'flex flex-col gap-3xl max-w-[600px] xl:max-w-[728px]',
|
|
49
|
+
'flex flex-col gap-3xl max-w-[600px] @xl:max-w-[728px]',
|
|
50
50
|
leftImage ? '' : 'grow',
|
|
51
51
|
)}
|
|
52
52
|
>
|
|
@@ -66,9 +66,20 @@ export const BaseTile = JSX<BaseTileProps>(
|
|
|
66
66
|
const renderImageContainer = (
|
|
67
67
|
image: VNode | undefined,
|
|
68
68
|
{ className, imageAlign }: { className?: string; imageAlign?: Align },
|
|
69
|
-
) =>
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
) => {
|
|
70
|
+
//TODO Спорное решение
|
|
71
|
+
const fullWidth = image?.props?.image.size?.width > 400;
|
|
72
|
+
|
|
73
|
+
return image ? (
|
|
74
|
+
<div
|
|
75
|
+
className={style(
|
|
76
|
+
'flex-shrink-0',
|
|
77
|
+
fullWidth ? 'w-full @xl:w-auto' : '',
|
|
78
|
+
imageAlign && imageAlignmentMap[imageAlign],
|
|
79
|
+
className,
|
|
80
|
+
)}
|
|
81
|
+
>
|
|
72
82
|
{image}
|
|
73
83
|
</div>
|
|
74
84
|
) : null;
|
|
85
|
+
};
|
package/package.json
CHANGED
|
@@ -3,8 +3,8 @@ import type { UniBlockProps } from '../../model/JSXBlock';
|
|
|
3
3
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
4
4
|
import { renderButtonsSection } from '../../ui-kit/Button/renderButtonsSection';
|
|
5
5
|
import { Img } from '../../ui-kit/Img/Img';
|
|
6
|
-
import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
|
|
7
6
|
import { Text } from '../../ui-kit/Text/Text';
|
|
7
|
+
import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
|
|
8
8
|
import { Headline } from '../Headline/Headline';
|
|
9
9
|
import type { BonusContent, BonusCountDef, BonusImageDef } from './BonusContent';
|
|
10
10
|
|
|
@@ -12,7 +12,7 @@ export interface BonusProps extends BonusContent, UniBlockProps {}
|
|
|
12
12
|
|
|
13
13
|
export const Bonus = JSX<BonusProps>(
|
|
14
14
|
({ className = '', title, description, bonusItems = [], ...rest }) => (
|
|
15
|
-
<BlockWrapper className={className} defaultPadding="p-
|
|
15
|
+
<BlockWrapper className={className} defaultPadding="p-6xl" {...rest}>
|
|
16
16
|
<div className="container">
|
|
17
17
|
<Headline
|
|
18
18
|
className="mb-xl"
|
|
@@ -26,20 +26,23 @@ export const Bonus = JSX<BonusProps>(
|
|
|
26
26
|
? bonusItems.map((_, i) => (
|
|
27
27
|
<div
|
|
28
28
|
key={String(i)}
|
|
29
|
-
className="space-y-xs flex-grow w-full sm:w-[49%] border border-gray p-m"
|
|
29
|
+
className="space-y-xs flex flex-col grow w-full sm:w-[49%] border border-gray p-m"
|
|
30
30
|
>
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
<
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
31
|
+
<div className="grow">
|
|
32
|
+
{_?.title ? (
|
|
33
|
+
<div className="mb-xs last:mb-0">
|
|
34
|
+
<Text size="text-h4">{_.title}</Text>
|
|
35
|
+
</div>
|
|
36
|
+
) : null}
|
|
37
|
+
{_?.description ? (
|
|
38
|
+
<div className="mb-text last:mb-0">
|
|
39
|
+
<Paragraph size="text-xl" font="font-light">
|
|
40
|
+
{_.description}
|
|
41
|
+
</Paragraph>
|
|
42
|
+
</div>
|
|
43
|
+
) : null}
|
|
44
|
+
</div>
|
|
45
|
+
<div className="flex justify-center sm:justify-between sm:items-end">
|
|
43
46
|
<div className="hidden sm:block">{renderButtonsSection(_?.buttons)}</div>
|
|
44
47
|
{_.bonusItemContent?.bonusType
|
|
45
48
|
? renderBonusItemContent(_.bonusItemContent)
|
|
@@ -56,18 +59,19 @@ export const Bonus = JSX<BonusProps>(
|
|
|
56
59
|
|
|
57
60
|
const renderBonusItemContent = (bonusItemContent: BonusImageDef | BonusCountDef) =>
|
|
58
61
|
bonusItemContent.bonusType === 'count'
|
|
59
|
-
? renderBonusCount(bonusItemContent)
|
|
62
|
+
? renderBonusCount(bonusItemContent as BonusCountDef)
|
|
60
63
|
: renderBonusImage(bonusItemContent as BonusImageDef);
|
|
61
64
|
|
|
62
65
|
const renderBonusCount = (_: BonusCountDef) => (
|
|
63
|
-
<div className="w-full pt-default mt-s flex items-end">
|
|
66
|
+
<div className="w-full pt-default mt-s flex justify-center sm:justify-end items-end">
|
|
64
67
|
{_.bonusCount ? (
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
+
// -mb-10 добавлен для выравнивания bonusCount относительно bonusName, тк шрифт font-mohave неправильно высчитывает line-height
|
|
69
|
+
<div className="shrink-0 -mb-10">
|
|
70
|
+
<span className="font-mohave text-title-extra gradient-color-text">{_.bonusCount}</span>
|
|
71
|
+
</div>
|
|
68
72
|
) : null}
|
|
69
73
|
{_.bonusName ? (
|
|
70
|
-
<div className="
|
|
74
|
+
<div className="shrink-0 gradient-color-text">
|
|
71
75
|
<Text size="text-h2">{_.bonusName}</Text>
|
|
72
76
|
</div>
|
|
73
77
|
) : null}
|
|
@@ -19,8 +19,7 @@ export const BonusBenefitsBlock = JSX<BenefitsBlockProps>(
|
|
|
19
19
|
}) => (
|
|
20
20
|
<BlockWrapper className={className} defaultPadding="p-6xl" {...rest}>
|
|
21
21
|
<Headline
|
|
22
|
-
className="mb-
|
|
23
|
-
isEmbedded={true}
|
|
22
|
+
className="mb-4xl sm:mb-3xl"
|
|
24
23
|
title={title}
|
|
25
24
|
description={subtitle}
|
|
26
25
|
headlineVersion="M"
|
|
@@ -71,6 +71,7 @@ export const BusinessDepositCalculatorForm = JSX<BusinessDepositCalculatorProp>(
|
|
|
71
71
|
{renderDepositResults(finalSum, income)}
|
|
72
72
|
{renderButtonsSection(buttons, { isVertical: true })}
|
|
73
73
|
{renderFootnote(footnote)}
|
|
74
|
+
{renderFootnote(bottomFootnote)}
|
|
74
75
|
</div>
|
|
75
76
|
</section>
|
|
76
77
|
);
|
|
@@ -14,10 +14,14 @@ const DEFAULT_TITLE = 'Укажите сумму перевода';
|
|
|
14
14
|
const DEFAULT_LABEL = 'Сумма перевода';
|
|
15
15
|
const DEFAULT_PLACEHOLDER = '1500';
|
|
16
16
|
|
|
17
|
-
const
|
|
18
|
-
|
|
17
|
+
const FORM_URL_MAP = {
|
|
18
|
+
private: 'https://old.rshb.ru/p2p/',
|
|
19
|
+
business: 'https://old.rshb.ru/smallbusiness/p2p/',
|
|
20
|
+
};
|
|
21
|
+
|
|
19
22
|
const INITIAL_FORM_STATE = {
|
|
20
|
-
|
|
23
|
+
amount: 1500,
|
|
24
|
+
_amount: 1500,
|
|
21
25
|
};
|
|
22
26
|
|
|
23
27
|
export interface CardTransferProps extends CardTransferContent, UniBlockProps {}
|
|
@@ -29,9 +33,10 @@ export const CardTransfer = JSX<CardTransferProps>(
|
|
|
29
33
|
label = DEFAULT_LABEL,
|
|
30
34
|
placeholder = DEFAULT_PLACEHOLDER,
|
|
31
35
|
button,
|
|
36
|
+
formType = 'private',
|
|
32
37
|
...rest
|
|
33
38
|
}) => {
|
|
34
|
-
const [{ amount }, { field }] = useForm(INITIAL_FORM_STATE);
|
|
39
|
+
const [{ amount, _amount }, { field }] = useForm(INITIAL_FORM_STATE);
|
|
35
40
|
|
|
36
41
|
const isDisabled = amount <= 0;
|
|
37
42
|
|
|
@@ -54,14 +59,15 @@ export const CardTransfer = JSX<CardTransferProps>(
|
|
|
54
59
|
title={title}
|
|
55
60
|
/>
|
|
56
61
|
) : null}
|
|
57
|
-
<form className="w-full xl:max-w-[468px]" method="POST" action={
|
|
62
|
+
<form className="w-full xl:max-w-[468px]" method="POST" action={FORM_URL_MAP[formType]}>
|
|
58
63
|
<CurrencyInput
|
|
59
|
-
name=
|
|
64
|
+
name="_amount"
|
|
60
65
|
valid={!isDisabled}
|
|
61
66
|
placeholder={placeholder}
|
|
62
67
|
label={label}
|
|
63
|
-
{...field(
|
|
68
|
+
{...field('_amount', { parse: Number, format: String })}
|
|
64
69
|
/>
|
|
70
|
+
<input type="hidden" name="amount" value={_amount} />
|
|
65
71
|
{button?.text ? (
|
|
66
72
|
<button
|
|
67
73
|
type="submit"
|
|
@@ -11,4 +11,9 @@ export type CardTransferContent = UniBlockContent &
|
|
|
11
11
|
/** @title Плейсхолдер */
|
|
12
12
|
placeholder?: string;
|
|
13
13
|
button?: ButtonContent;
|
|
14
|
+
/**
|
|
15
|
+
* @title Тип формы
|
|
16
|
+
* @enumNames ['Частные клиенты', 'Бизнес-клиенты']
|
|
17
|
+
*/
|
|
18
|
+
formType?: 'private' | 'business';
|
|
14
19
|
};
|
|
@@ -1,18 +1,15 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
-
import { renderBlock } from '../../BlockRenderer/renderBlock';
|
|
3
|
-
import { renderChildren } from '../../BlockRenderer/renderChildren';
|
|
4
2
|
import { useCarouselControls } from '../../hooks/useCarouselControls';
|
|
3
|
+
import type { JSXBlock, UniBlockProps } from '../../model/JSXBlock';
|
|
5
4
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
6
5
|
import { SwipeListContainer } from '../../ui-kit/SwipeListControl/SwipeListContainer';
|
|
7
6
|
import { SwipeListControlDots } from '../../ui-kit/SwipeListControl/SwipeListControlDots';
|
|
8
7
|
import { useSwipeListScroll } from '../../ui-kit/SwipeListControl/useSwipeListScroll';
|
|
9
8
|
import { style } from '../../utils/style';
|
|
9
|
+
import type { CarouselContent } from './CarouselContent';
|
|
10
10
|
import { CarouselScrollButtons } from './CarouselScrollButtons';
|
|
11
11
|
import { ITEMS_GAP } from './itemsGap';
|
|
12
|
-
import
|
|
13
|
-
import type { BlockDef } from '../../model/ContentPageDef';
|
|
14
|
-
import type { BlockRendererOptions } from '../../BlockRenderer/BlockRendererOptions';
|
|
15
|
-
import type { JSXBlock, UniBlockProps } from '../../model/JSXBlock';
|
|
12
|
+
import { renderCarouselCards } from './renderCarouselCards';
|
|
16
13
|
|
|
17
14
|
export interface CarouselProps extends CarouselContent, UniBlockProps {
|
|
18
15
|
itemCount?: number;
|
|
@@ -58,20 +55,7 @@ export const Carousel: JSXBlock<CarouselProps> = JSX<CarouselProps>(
|
|
|
58
55
|
gap={isGap ? ITEMS_GAP : undefined}
|
|
59
56
|
onVisibleIndicesChange={scroll.handleVisibleIndicesChange}
|
|
60
57
|
>
|
|
61
|
-
{
|
|
62
|
-
...rest,
|
|
63
|
-
renderProps: (block: BlockDef, options: BlockRendererOptions, blockIndex) =>
|
|
64
|
-
renderBlock(block, options, {
|
|
65
|
-
className: style(
|
|
66
|
-
'h-full min-w-80 sm:min-w-96',
|
|
67
|
-
noCardBorder
|
|
68
|
-
? ''
|
|
69
|
-
: 'border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider',
|
|
70
|
-
),
|
|
71
|
-
blockIndex,
|
|
72
|
-
isActive: activeIndex === blockIndex,
|
|
73
|
-
}),
|
|
74
|
-
})}
|
|
58
|
+
{renderCarouselCards({ noCardBorder, activeIndex, ...rest })}
|
|
75
59
|
</SwipeListContainer>
|
|
76
60
|
<CarouselScrollButtons
|
|
77
61
|
scroll={scroll}
|
|
@@ -109,3 +93,10 @@ Carousel.childrenTypes = [
|
|
|
109
93
|
'CarouselInvestmentCard',
|
|
110
94
|
'CarouselEventCard',
|
|
111
95
|
];
|
|
96
|
+
|
|
97
|
+
Carousel.childSchema = () => ({
|
|
98
|
+
isHighlighting: {
|
|
99
|
+
title: 'Выделить карточку',
|
|
100
|
+
type: 'boolean',
|
|
101
|
+
},
|
|
102
|
+
});
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Icon } from '../../ui-kit/Icon/Icon';
|
|
2
|
+
import { Paragraph } from '../../ui-kit/Paragraph/Paragraph';
|
|
3
|
+
import { style } from '../../utils/style';
|
|
4
|
+
|
|
5
|
+
interface CardHighlightProps {
|
|
6
|
+
className?: string;
|
|
7
|
+
text?: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export const renderCardHighlight = ({ className, text = 'ХИТ' }: CardHighlightProps = {}) => (
|
|
11
|
+
<div
|
|
12
|
+
className={style(
|
|
13
|
+
'w-14 h-14 bg-white flex flex-col items-center justify-center rounded-md shadow-[0_4px_25px_rgba(0,0,0,0.07)]',
|
|
14
|
+
className,
|
|
15
|
+
)}
|
|
16
|
+
>
|
|
17
|
+
<Icon iconVersion="black" name="HeartIcon" width="24" height="24" />
|
|
18
|
+
<Paragraph size="text-s" font="font-normal" align="text-center" color="text-primary-text">
|
|
19
|
+
{text}
|
|
20
|
+
</Paragraph>
|
|
21
|
+
</div>
|
|
22
|
+
);
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { BlockRendererOptions } from '../../BlockRenderer/BlockRendererOptions';
|
|
2
|
+
import { renderBlock } from '../../BlockRenderer/renderBlock';
|
|
3
|
+
import { renderChildren } from '../../BlockRenderer/renderChildren';
|
|
4
|
+
import type { BlockDef } from '../../model/ContentPageDef';
|
|
5
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
6
|
+
import { style } from '../../utils/style';
|
|
7
|
+
import { renderCardHighlight } from './renderCardHighlight';
|
|
8
|
+
|
|
9
|
+
const cardBaseStyle = 'relative h-full';
|
|
10
|
+
|
|
11
|
+
export const renderCarouselCards = ({
|
|
12
|
+
noCardBorder,
|
|
13
|
+
activeIndex,
|
|
14
|
+
...rest
|
|
15
|
+
}: UniBlockProps & { noCardBorder?: boolean; activeIndex?: number }) => {
|
|
16
|
+
const { blocks: childBlocks } = rest.block || {};
|
|
17
|
+
const someCardsHighlighted = childBlocks?.some(isCardHighlighted);
|
|
18
|
+
|
|
19
|
+
return renderChildren({
|
|
20
|
+
...rest,
|
|
21
|
+
renderProps: (block: BlockDef, options: BlockRendererOptions, blockIndex) => (
|
|
22
|
+
<div className={cardWrapperStyle(block, { someCardsHighlighted })}>
|
|
23
|
+
{renderBlock(block, options, {
|
|
24
|
+
className: cardStyle(block, { someCardsHighlighted, showBorder: !noCardBorder }),
|
|
25
|
+
blockIndex,
|
|
26
|
+
isActive: blockIndex === activeIndex,
|
|
27
|
+
})}
|
|
28
|
+
{isCardHighlighted(block)
|
|
29
|
+
? renderCardHighlight({ className: 'absolute top-0 -right-4 z-40' })
|
|
30
|
+
: null}
|
|
31
|
+
</div>
|
|
32
|
+
),
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
const cardWrapperStyle = (
|
|
37
|
+
_: BlockDef | undefined,
|
|
38
|
+
{ someCardsHighlighted }: { someCardsHighlighted?: boolean },
|
|
39
|
+
) =>
|
|
40
|
+
style(
|
|
41
|
+
cardBaseStyle,
|
|
42
|
+
someCardsHighlighted && (isCardHighlighted(_) ? 'pt-3xl' : 'pt-3xl sm:pt-16'),
|
|
43
|
+
);
|
|
44
|
+
|
|
45
|
+
const cardStyle = (
|
|
46
|
+
_: BlockDef | undefined,
|
|
47
|
+
{ someCardsHighlighted, showBorder }: { someCardsHighlighted?: boolean; showBorder?: boolean },
|
|
48
|
+
) =>
|
|
49
|
+
style(
|
|
50
|
+
cardBaseStyle,
|
|
51
|
+
'min-w-80 sm:min-w-96',
|
|
52
|
+
someCardsHighlighted && (isCardHighlighted(_) ? 'pt-3xl sm:pt-16' : 'pt-3xl'),
|
|
53
|
+
showBorder &&
|
|
54
|
+
'border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider',
|
|
55
|
+
);
|
|
56
|
+
|
|
57
|
+
const isCardHighlighted = (_: BlockDef | undefined) =>
|
|
58
|
+
_?.content && 'isHighlighting' in _.content && _.content.isHighlighting;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const visibleItemCountStyle = 'auto';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const visibleItemCountStyle = 0;
|
|
@@ -23,7 +23,9 @@ export const CarouselCard = JSX<CarouselCardProps>(
|
|
|
23
23
|
<div className={style(layerStyle, 'top-9 right-12 bg-green-dark')} />
|
|
24
24
|
<div className={style(layerStyle, 'top-6 right-8 bg-green')} />
|
|
25
25
|
<div className={style(layerStyle, 'top-3 right-4 bg-green-light')} />
|
|
26
|
-
<div
|
|
26
|
+
<div
|
|
27
|
+
className={style(layerBaseStyle, 'relative p-xl sm:p-5xl bg-white border-green-light')}
|
|
28
|
+
>
|
|
27
29
|
<Headline
|
|
28
30
|
title={title}
|
|
29
31
|
description={description}
|
|
@@ -32,7 +34,7 @@ export const CarouselCard = JSX<CarouselCardProps>(
|
|
|
32
34
|
isEmbedded={true}
|
|
33
35
|
/>
|
|
34
36
|
{renderButtonsSection([button], {
|
|
35
|
-
className: 'mt-6xl sm:justify-center',
|
|
37
|
+
className: 'mt-m sm:mt-6xl sm:justify-center',
|
|
36
38
|
isVertical: true,
|
|
37
39
|
})}
|
|
38
40
|
</div>
|
|
@@ -17,27 +17,27 @@ const five: Picture = {
|
|
|
17
17
|
const cardsList = [
|
|
18
18
|
{
|
|
19
19
|
parameter: 'IR',
|
|
20
|
-
|
|
20
|
+
parameterDescription: 'cтрана эмитента',
|
|
21
21
|
},
|
|
22
22
|
{
|
|
23
23
|
parameter: 'RU',
|
|
24
|
-
|
|
24
|
+
parameterDescription: 'страна риска',
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
parameter: '09.03.2022',
|
|
28
|
-
|
|
28
|
+
parameterDescription: 'дата погашения',
|
|
29
29
|
},
|
|
30
30
|
{
|
|
31
31
|
parameter: 'Ba3',
|
|
32
|
-
|
|
32
|
+
parameterDescription: 'рейтинг MOODY’S',
|
|
33
33
|
},
|
|
34
34
|
{
|
|
35
35
|
parameter: 'BB-',
|
|
36
|
-
|
|
36
|
+
parameterDescription: 'рейтинг FITCH',
|
|
37
37
|
},
|
|
38
38
|
{
|
|
39
39
|
parameter: 'Borets Finance Designated Activity Company',
|
|
40
|
-
|
|
40
|
+
parameterDescription: 'эмитент',
|
|
41
41
|
},
|
|
42
42
|
];
|
|
43
43
|
|