@redneckz/wildless-cms-uni-blocks 0.5.12 → 0.5.13
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 +125 -69
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Accordion/AccordionContent.d.ts +9 -7
- package/bundle/components/Accordion/AccordionItem.d.ts +1 -4
- package/bundle/components/Accordion/AccordionItem.mobile.d.ts +1 -4
- package/bundle/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/bundle/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/bundle/components/Blocks.d.ts +1 -0
- package/bundle/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/bundle/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/bundle/components/StepsBlock/renderItems.d.ts +7 -2
- package/bundle/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/bundle/model/BlockDecorator.d.ts +1 -0
- package/bundle/model/BlocksRegistry.d.ts +4 -1
- package/bundle/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/bundle/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/bundle/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/bundle/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/dist/components/Accordion/Accordion.js +3 -1
- package/dist/components/Accordion/Accordion.js.map +1 -1
- package/dist/components/Accordion/Accordion.mobile.js +5 -2
- package/dist/components/Accordion/Accordion.mobile.js.map +1 -1
- package/dist/components/Accordion/AccordionContent.d.ts +9 -7
- package/dist/components/Accordion/AccordionItem.d.ts +1 -4
- package/dist/components/Accordion/AccordionItem.js +3 -8
- package/dist/components/Accordion/AccordionItem.js.map +1 -1
- package/dist/components/Accordion/AccordionItem.mobile.d.ts +1 -4
- package/dist/components/Accordion/AccordionItem.mobile.js +2 -5
- package/dist/components/Accordion/AccordionItem.mobile.js.map +1 -1
- package/dist/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/dist/components/Accordion/AccordionItemProps.js +2 -0
- package/dist/components/Accordion/AccordionItemProps.js.map +1 -0
- package/dist/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/dist/components/Accordion/AccordionItemsList.js +6 -0
- package/dist/components/Accordion/AccordionItemsList.js.map +1 -0
- package/dist/components/Blocks.d.ts +1 -0
- package/dist/components/Blocks.js +2 -0
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/ContentPage/filterBlocks.js +1 -2
- package/dist/components/ContentPage/filterBlocks.js.map +1 -1
- package/dist/components/ContentPage/filterBlocks.mobile.js +1 -3
- package/dist/components/ContentPage/filterBlocks.mobile.js.map +1 -1
- package/dist/components/ContentPage/renderBlock.js +1 -1
- package/dist/components/ContentPage/renderBlock.js.map +1 -1
- package/dist/components/Footer/Footer.mobile.js +8 -7
- package/dist/components/Footer/Footer.mobile.js.map +1 -1
- package/dist/components/Header/Header.mobile.js +5 -5
- package/dist/components/Header/Header.mobile.js.map +1 -1
- package/dist/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/dist/components/InvestmentInfo/InvestmentInfo.js +49 -0
- package/dist/components/InvestmentInfo/InvestmentInfo.js.map +1 -0
- package/dist/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/dist/components/InvestmentInfo/InvestmentInfoContent.js +2 -0
- package/dist/components/InvestmentInfo/InvestmentInfoContent.js.map +1 -0
- package/dist/components/OtherProducts/OtherProductsItem.js +4 -6
- package/dist/components/OtherProducts/OtherProductsItem.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlock.js +2 -8
- package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlockStyleMaps.js +2 -2
- package/dist/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/dist/components/StepsBlock/renderItems.d.ts +7 -2
- package/dist/components/StepsBlock/renderItems.js +5 -1
- package/dist/components/StepsBlock/renderItems.js.map +1 -1
- package/dist/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/dist/components/StepsBlock/renderStepContent.js +20 -0
- package/dist/components/StepsBlock/renderStepContent.js.map +1 -0
- package/dist/components/TariffsTable/TariffsTable.js +11 -2
- package/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/dist/model/BlockDecorator.d.ts +1 -0
- package/dist/model/BlockDecorator.js +2 -1
- package/dist/model/BlockDecorator.js.map +1 -1
- package/dist/model/BlocksRegistry.d.ts +4 -1
- package/dist/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/dist/ui-kit/Foldable/DefaultFoldButton.js +16 -0
- package/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -0
- package/dist/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/dist/ui-kit/Foldable/Foldable.js +7 -23
- package/dist/ui-kit/Foldable/Foldable.js.map +1 -1
- package/dist/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/dist/ui-kit/Foldable/{FoldButtonProps.js → FoldablePartProps.js} +1 -1
- package/dist/ui-kit/Foldable/FoldablePartProps.js.map +1 -0
- package/dist/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/dist/ui-kit/Foldable/FoldableSection.js +17 -0
- package/dist/ui-kit/Foldable/FoldableSection.js.map +1 -0
- package/lib/common.css +1 -1
- package/lib/components/Accordion/Accordion.js +3 -1
- package/lib/components/Accordion/Accordion.js.map +1 -1
- package/lib/components/Accordion/Accordion.mobile.js +5 -2
- package/lib/components/Accordion/Accordion.mobile.js.map +1 -1
- package/lib/components/Accordion/AccordionContent.d.ts +9 -7
- package/lib/components/Accordion/AccordionItem.d.ts +1 -4
- package/lib/components/Accordion/AccordionItem.js +3 -8
- package/lib/components/Accordion/AccordionItem.js.map +1 -1
- package/lib/components/Accordion/AccordionItem.mobile.d.ts +1 -4
- package/lib/components/Accordion/AccordionItem.mobile.js +2 -5
- package/lib/components/Accordion/AccordionItem.mobile.js.map +1 -1
- package/lib/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/lib/components/Accordion/AccordionItemProps.js +2 -0
- package/lib/components/Accordion/AccordionItemProps.js.map +1 -0
- package/lib/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/lib/components/Accordion/AccordionItemsList.js +4 -0
- package/lib/components/Accordion/AccordionItemsList.js.map +1 -0
- package/lib/components/Blocks.d.ts +1 -0
- package/lib/components/Blocks.js +2 -0
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/ContentPage/filterBlocks.js +1 -2
- package/lib/components/ContentPage/filterBlocks.js.map +1 -1
- package/lib/components/ContentPage/filterBlocks.mobile.js +1 -3
- package/lib/components/ContentPage/filterBlocks.mobile.js.map +1 -1
- package/lib/components/ContentPage/renderBlock.js +2 -2
- package/lib/components/ContentPage/renderBlock.js.map +1 -1
- package/lib/components/Footer/Footer.mobile.js +8 -7
- package/lib/components/Footer/Footer.mobile.js.map +1 -1
- package/lib/components/Header/Header.mobile.js +5 -5
- package/lib/components/Header/Header.mobile.js.map +1 -1
- package/lib/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/lib/components/InvestmentInfo/InvestmentInfo.fixture.d.ts +7 -0
- package/lib/components/InvestmentInfo/InvestmentInfo.js +47 -0
- package/lib/components/InvestmentInfo/InvestmentInfo.js.map +1 -0
- package/lib/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/lib/components/InvestmentInfo/InvestmentInfoContent.js +2 -0
- package/lib/components/InvestmentInfo/InvestmentInfoContent.js.map +1 -0
- package/lib/components/OtherProducts/OtherProductsItem.js +4 -6
- package/lib/components/OtherProducts/OtherProductsItem.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlock.fixture.d.ts +2 -1
- package/lib/components/StepsBlock/StepsBlock.js +2 -8
- package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlockStyleMaps.js +2 -2
- package/lib/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/lib/components/StepsBlock/renderItems.d.ts +7 -2
- package/lib/components/StepsBlock/renderItems.js +6 -2
- package/lib/components/StepsBlock/renderItems.js.map +1 -1
- package/lib/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/lib/components/StepsBlock/renderStepContent.js +17 -0
- package/lib/components/StepsBlock/renderStepContent.js.map +1 -0
- package/lib/components/TariffsTable/TariffsTable.js +11 -2
- package/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/lib/model/BlockDecorator.d.ts +1 -0
- package/lib/model/BlockDecorator.js +1 -0
- package/lib/model/BlockDecorator.js.map +1 -1
- package/lib/model/BlocksRegistry.d.ts +4 -1
- package/lib/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/lib/ui-kit/Foldable/DefaultFoldButton.js +13 -0
- package/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -0
- package/lib/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/lib/ui-kit/Foldable/Foldable.js +9 -25
- package/lib/ui-kit/Foldable/Foldable.js.map +1 -1
- package/lib/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/lib/ui-kit/Foldable/FoldablePartProps.js +2 -0
- package/lib/ui-kit/Foldable/FoldablePartProps.js.map +1 -0
- package/lib/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/lib/ui-kit/Foldable/FoldableSection.js +15 -0
- package/lib/ui-kit/Foldable/FoldableSection.js.map +1 -0
- package/mobile/bundle/bundle.umd.js +131 -153
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Accordion/AccordionContent.d.ts +9 -7
- package/mobile/bundle/components/Accordion/AccordionItem.d.ts +1 -4
- package/mobile/bundle/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/mobile/bundle/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/mobile/bundle/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/mobile/bundle/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/mobile/bundle/components/StepsBlock/renderItems.d.ts +7 -2
- package/mobile/bundle/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/mobile/bundle/model/BlockDecorator.d.ts +1 -0
- package/mobile/bundle/model/BlocksRegistry.d.ts +4 -1
- package/mobile/bundle/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/mobile/bundle/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/mobile/bundle/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/mobile/bundle/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/mobile/dist/components/Accordion/Accordion.js +5 -2
- package/mobile/dist/components/Accordion/Accordion.js.map +1 -1
- package/mobile/dist/components/Accordion/AccordionContent.d.ts +9 -7
- package/mobile/dist/components/Accordion/AccordionItem.d.ts +1 -4
- package/mobile/dist/components/Accordion/AccordionItem.js +2 -5
- package/mobile/dist/components/Accordion/AccordionItem.js.map +1 -1
- package/mobile/dist/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/mobile/dist/components/Accordion/AccordionItemProps.js +2 -0
- package/mobile/dist/components/Accordion/AccordionItemProps.js.map +1 -0
- package/mobile/dist/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/mobile/dist/components/Accordion/AccordionItemsList.js +6 -0
- package/mobile/dist/components/Accordion/AccordionItemsList.js.map +1 -0
- package/mobile/dist/components/ContentPage/filterBlocks.js +1 -3
- package/mobile/dist/components/ContentPage/filterBlocks.js.map +1 -1
- package/mobile/dist/components/ContentPage/renderBlock.js +1 -1
- package/mobile/dist/components/ContentPage/renderBlock.js.map +1 -1
- package/mobile/dist/components/Footer/Footer.js +8 -7
- package/mobile/dist/components/Footer/Footer.js.map +1 -1
- package/mobile/dist/components/Header/Header.js +5 -5
- package/mobile/dist/components/Header/Header.js.map +1 -1
- package/mobile/dist/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/mobile/dist/components/InvestmentInfo/InvestmentInfo.js +49 -0
- package/mobile/dist/components/InvestmentInfo/InvestmentInfo.js.map +1 -0
- package/mobile/dist/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/mobile/dist/components/InvestmentInfo/InvestmentInfoContent.js +2 -0
- package/mobile/dist/components/InvestmentInfo/InvestmentInfoContent.js.map +1 -0
- package/mobile/dist/components/OtherProducts/OtherProductsItem.js +4 -6
- package/mobile/dist/components/OtherProducts/OtherProductsItem.js.map +1 -1
- package/mobile/dist/components/StepsBlock/StepsBlockStyleMaps.js +2 -2
- package/mobile/dist/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/mobile/dist/components/StepsBlock/renderItems.d.ts +7 -2
- package/mobile/dist/components/StepsBlock/renderItems.js +5 -1
- package/mobile/dist/components/StepsBlock/renderItems.js.map +1 -1
- package/mobile/dist/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/mobile/dist/components/StepsBlock/renderStepContent.js +20 -0
- package/mobile/dist/components/StepsBlock/renderStepContent.js.map +1 -0
- package/mobile/dist/model/BlockDecorator.d.ts +1 -0
- package/mobile/dist/model/BlockDecorator.js +2 -1
- package/mobile/dist/model/BlockDecorator.js.map +1 -1
- package/mobile/dist/model/BlocksRegistry.d.ts +4 -1
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js +16 -0
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -0
- package/mobile/dist/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/mobile/dist/ui-kit/Foldable/Foldable.js +7 -23
- package/mobile/dist/ui-kit/Foldable/Foldable.js.map +1 -1
- package/mobile/dist/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/mobile/dist/ui-kit/Foldable/{FoldButtonProps.js → FoldablePartProps.js} +1 -1
- package/mobile/dist/ui-kit/Foldable/FoldablePartProps.js.map +1 -0
- package/mobile/dist/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/mobile/dist/ui-kit/Foldable/FoldableSection.js +17 -0
- package/mobile/dist/ui-kit/Foldable/FoldableSection.js.map +1 -0
- package/mobile/lib/components/Accordion/Accordion.js +5 -2
- package/mobile/lib/components/Accordion/Accordion.js.map +1 -1
- package/mobile/lib/components/Accordion/AccordionContent.d.ts +9 -7
- package/mobile/lib/components/Accordion/AccordionItem.d.ts +1 -4
- package/mobile/lib/components/Accordion/AccordionItem.js +2 -5
- package/mobile/lib/components/Accordion/AccordionItem.js.map +1 -1
- package/mobile/lib/components/Accordion/AccordionItemProps.d.ts +5 -0
- package/mobile/lib/components/Accordion/AccordionItemProps.js +2 -0
- package/mobile/lib/components/Accordion/AccordionItemProps.js.map +1 -0
- package/mobile/lib/components/Accordion/AccordionItemsList.d.ts +1 -0
- package/mobile/lib/components/Accordion/AccordionItemsList.js +4 -0
- package/mobile/lib/components/Accordion/AccordionItemsList.js.map +1 -0
- package/mobile/lib/components/ContentPage/filterBlocks.js +1 -3
- package/mobile/lib/components/ContentPage/filterBlocks.js.map +1 -1
- package/mobile/lib/components/ContentPage/renderBlock.js +2 -2
- package/mobile/lib/components/ContentPage/renderBlock.js.map +1 -1
- package/mobile/lib/components/Footer/Footer.js +8 -7
- package/mobile/lib/components/Footer/Footer.js.map +1 -1
- package/mobile/lib/components/Header/Header.js +5 -5
- package/mobile/lib/components/Header/Header.js.map +1 -1
- package/mobile/lib/components/InvestmentInfo/InvestmentInfo.d.ts +5 -0
- package/mobile/lib/components/InvestmentInfo/InvestmentInfo.js +47 -0
- package/mobile/lib/components/InvestmentInfo/InvestmentInfo.js.map +1 -0
- package/mobile/lib/components/InvestmentInfo/InvestmentInfoContent.d.ts +49 -0
- package/mobile/lib/components/InvestmentInfo/InvestmentInfoContent.js +2 -0
- package/mobile/lib/components/InvestmentInfo/InvestmentInfoContent.js.map +1 -0
- package/mobile/lib/components/OtherProducts/OtherProductsItem.js +4 -6
- package/mobile/lib/components/OtherProducts/OtherProductsItem.js.map +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlockStyleMaps.js +2 -2
- package/mobile/lib/components/StepsBlock/StepsBlockStyleMaps.js.map +1 -1
- package/mobile/lib/components/StepsBlock/renderItems.d.ts +7 -2
- package/mobile/lib/components/StepsBlock/renderItems.js +6 -2
- package/mobile/lib/components/StepsBlock/renderItems.js.map +1 -1
- package/mobile/lib/components/StepsBlock/renderStepContent.d.ts +14 -0
- package/mobile/lib/components/StepsBlock/renderStepContent.js +17 -0
- package/mobile/lib/components/StepsBlock/renderStepContent.js.map +1 -0
- package/mobile/lib/model/BlockDecorator.d.ts +1 -0
- package/mobile/lib/model/BlockDecorator.js +1 -0
- package/mobile/lib/model/BlockDecorator.js.map +1 -1
- package/mobile/lib/model/BlocksRegistry.d.ts +4 -1
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.d.ts +14 -0
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js +13 -0
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -0
- package/mobile/lib/ui-kit/Foldable/Foldable.d.ts +3 -10
- package/mobile/lib/ui-kit/Foldable/Foldable.js +9 -25
- package/mobile/lib/ui-kit/Foldable/Foldable.js.map +1 -1
- package/mobile/lib/ui-kit/Foldable/FoldablePartProps.d.ts +4 -0
- package/mobile/lib/ui-kit/Foldable/FoldablePartProps.js +2 -0
- package/mobile/lib/ui-kit/Foldable/FoldablePartProps.js.map +1 -0
- package/mobile/lib/ui-kit/Foldable/FoldableSection.d.ts +5 -0
- package/mobile/lib/ui-kit/Foldable/FoldableSection.js +15 -0
- package/mobile/lib/ui-kit/Foldable/FoldableSection.js.map +1 -0
- package/mobile/src/common.css +11 -3
- package/mobile/src/components/Accordion/Accordion.tsx +17 -7
- package/mobile/src/components/Accordion/AccordionContent.ts +10 -7
- package/mobile/src/components/Accordion/AccordionItem.tsx +34 -30
- package/mobile/src/components/Accordion/AccordionItemProps.ts +6 -0
- package/mobile/src/components/Accordion/AccordionItemsList.tsx +5 -0
- package/mobile/src/components/ContentPage/filterBlocks.ts +1 -3
- package/mobile/src/components/ContentPage/renderBlock.tsx +2 -2
- package/mobile/src/components/ExchangeRateTile/ExchangeRateTile.ui.json +8 -1
- package/mobile/src/components/Footer/Footer.tsx +15 -13
- package/mobile/src/components/GracePeriod/GracePeriod.ui.json +5 -0
- package/mobile/src/components/Header/Header.tsx +16 -11
- package/mobile/src/components/InvestmentInfo/InvestmentInfo.example.json +48 -0
- package/mobile/src/components/InvestmentInfo/InvestmentInfo.tsx +149 -0
- package/mobile/src/components/InvestmentInfo/InvestmentInfo.ui.json +16 -0
- package/mobile/src/components/InvestmentInfo/InvestmentInfoContent.ts +55 -0
- package/mobile/src/components/OtherProducts/OtherProductsItem.tsx +18 -15
- package/mobile/src/components/SafeDepositRental/SafeDepositRental.ui.json +8 -1
- package/mobile/src/components/StepsBlock/StepsBlockStyleMaps.ts +2 -2
- package/mobile/src/components/StepsBlock/renderItems.tsx +24 -15
- package/mobile/src/components/StepsBlock/renderStepContent.tsx +63 -0
- package/mobile/src/model/BlockDecorator.ts +2 -0
- package/mobile/src/model/BlocksRegistry.ts +4 -1
- package/mobile/src/ui-kit/Foldable/DefaultFoldButton.tsx +52 -0
- package/mobile/src/ui-kit/Foldable/Foldable.tsx +19 -67
- package/mobile/src/ui-kit/Foldable/FoldablePartProps.ts +4 -0
- package/mobile/src/ui-kit/Foldable/FoldableSection.tsx +30 -0
- package/package.json +2 -2
- package/src/common.css +11 -3
- package/src/components/Accordion/Accordion.mobile.tsx +17 -7
- package/src/components/Accordion/Accordion.tsx +12 -3
- package/src/components/Accordion/AccordionContent.ts +10 -7
- package/src/components/Accordion/AccordionItem.mobile.tsx +34 -30
- package/src/components/Accordion/AccordionItem.tsx +24 -23
- package/src/components/Accordion/AccordionItemProps.ts +6 -0
- package/src/components/Accordion/AccordionItemsList.tsx +5 -0
- package/src/components/Blocks.ts +2 -0
- package/src/components/ContentPage/filterBlocks.mobile.ts +1 -3
- package/src/components/ContentPage/filterBlocks.ts +1 -2
- package/src/components/ContentPage/renderBlock.tsx +2 -2
- package/src/components/ExchangeRateTile/ExchangeRateTile.ui.json +8 -1
- package/src/components/Footer/Footer.mobile.tsx +15 -13
- package/src/components/GracePeriod/GracePeriod.ui.json +5 -0
- package/src/components/Header/Header.mobile.tsx +16 -11
- package/src/components/InvestmentInfo/InvestmentInfo.example.json +48 -0
- package/src/components/InvestmentInfo/InvestmentInfo.fixture.tsx +107 -0
- package/src/components/InvestmentInfo/InvestmentInfo.tsx +149 -0
- package/src/components/InvestmentInfo/InvestmentInfo.ui.json +16 -0
- package/src/components/InvestmentInfo/InvestmentInfoContent.ts +55 -0
- package/src/components/OtherProducts/OtherProductsItem.tsx +18 -15
- package/src/components/SafeDepositRental/SafeDepositRental.ui.json +8 -1
- package/src/components/StepsBlock/StepsBlock.fixture.tsx +39 -25
- package/src/components/StepsBlock/StepsBlock.tsx +3 -49
- package/src/components/StepsBlock/StepsBlockStyleMaps.ts +2 -2
- package/src/components/StepsBlock/renderItems.tsx +24 -15
- package/src/components/StepsBlock/renderStepContent.tsx +63 -0
- package/src/components/TariffsTable/TariffsTable.tsx +32 -23
- package/src/model/BlockDecorator.ts +2 -0
- package/src/model/BlocksRegistry.ts +4 -1
- package/src/ui-kit/Foldable/DefaultFoldButton.tsx +52 -0
- package/src/ui-kit/Foldable/Foldable.tsx +19 -67
- package/src/ui-kit/Foldable/FoldablePartProps.ts +4 -0
- package/src/ui-kit/Foldable/FoldableSection.tsx +30 -0
- package/tailwind.config.cjs +5 -0
- package/bundle/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/bundle/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/bundle/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/bundle/utils/getAccordionItems.d.ts +0 -1
- package/dist/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/dist/components/ContentPage/isBlockInRegistry.js +0 -7
- package/dist/components/ContentPage/isBlockInRegistry.js.map +0 -1
- package/dist/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/dist/ui-kit/Foldable/DefaultButton.js +0 -12
- package/dist/ui-kit/Foldable/DefaultButton.js.map +0 -1
- package/dist/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/dist/ui-kit/Foldable/FoldButtonProps.js.map +0 -1
- package/dist/utils/getAccordionItems.d.ts +0 -1
- package/dist/utils/getAccordionItems.js +0 -13
- package/dist/utils/getAccordionItems.js.map +0 -1
- package/lib/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/lib/components/ContentPage/isBlockInRegistry.js +0 -4
- package/lib/components/ContentPage/isBlockInRegistry.js.map +0 -1
- package/lib/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/lib/ui-kit/Foldable/DefaultButton.js +0 -10
- package/lib/ui-kit/Foldable/DefaultButton.js.map +0 -1
- package/lib/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/lib/ui-kit/Foldable/FoldButtonProps.js +0 -2
- package/lib/ui-kit/Foldable/FoldButtonProps.js.map +0 -1
- package/lib/utils/getAccordionItems.d.ts +0 -1
- package/lib/utils/getAccordionItems.js +0 -10
- package/lib/utils/getAccordionItems.js.map +0 -1
- package/mobile/bundle/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/mobile/bundle/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/mobile/bundle/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/mobile/bundle/utils/getAccordionItems.d.ts +0 -1
- package/mobile/dist/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/mobile/dist/components/ContentPage/isBlockInRegistry.js +0 -7
- package/mobile/dist/components/ContentPage/isBlockInRegistry.js.map +0 -1
- package/mobile/dist/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/mobile/dist/ui-kit/Foldable/DefaultButton.js +0 -12
- package/mobile/dist/ui-kit/Foldable/DefaultButton.js.map +0 -1
- package/mobile/dist/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/mobile/dist/ui-kit/Foldable/FoldButtonProps.js.map +0 -1
- package/mobile/dist/utils/getAccordionItems.d.ts +0 -1
- package/mobile/dist/utils/getAccordionItems.js +0 -13
- package/mobile/dist/utils/getAccordionItems.js.map +0 -1
- package/mobile/lib/components/ContentPage/isBlockInRegistry.d.ts +0 -2
- package/mobile/lib/components/ContentPage/isBlockInRegistry.js +0 -4
- package/mobile/lib/components/ContentPage/isBlockInRegistry.js.map +0 -1
- package/mobile/lib/ui-kit/Foldable/DefaultButton.d.ts +0 -2
- package/mobile/lib/ui-kit/Foldable/DefaultButton.js +0 -10
- package/mobile/lib/ui-kit/Foldable/DefaultButton.js.map +0 -1
- package/mobile/lib/ui-kit/Foldable/FoldButtonProps.d.ts +0 -12
- package/mobile/lib/ui-kit/Foldable/FoldButtonProps.js +0 -2
- package/mobile/lib/ui-kit/Foldable/FoldButtonProps.js.map +0 -1
- package/mobile/lib/utils/getAccordionItems.d.ts +0 -1
- package/mobile/lib/utils/getAccordionItems.js +0 -10
- package/mobile/lib/utils/getAccordionItems.js.map +0 -1
- package/mobile/src/components/ContentPage/isBlockInRegistry.ts +0 -5
- package/mobile/src/ui-kit/Foldable/DefaultButton.tsx +0 -27
- package/mobile/src/ui-kit/Foldable/FoldButtonProps.ts +0 -13
- package/mobile/src/utils/getAccordionItems.ts +0 -10
- package/src/components/ContentPage/isBlockInRegistry.ts +0 -5
- package/src/ui-kit/Foldable/DefaultButton.tsx +0 -27
- package/src/ui-kit/Foldable/FoldButtonProps.ts +0 -13
- package/src/utils/getAccordionItems.ts +0 -10
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { context } from '../../react/setup-fixture';
|
|
2
|
+
import { InvestmentInfo } from './InvestmentInfo';
|
|
3
|
+
import type { InvestmentInfoContent } from './InvestmentInfoContent';
|
|
4
|
+
|
|
5
|
+
export const INVESTMENT_INFO: InvestmentInfoContent = {
|
|
6
|
+
items: [
|
|
7
|
+
'Качественные фермерские продукты напрямую от производителей',
|
|
8
|
+
'Самая большая база сельских туров по России',
|
|
9
|
+
'Площадки для создания комфортной жизни за городом',
|
|
10
|
+
'Подробная база вакансий для жителей сельской местности',
|
|
11
|
+
],
|
|
12
|
+
investmentZeroColumn: {
|
|
13
|
+
title: 'Открытие ИИС',
|
|
14
|
+
},
|
|
15
|
+
investmentColumns: [
|
|
16
|
+
{
|
|
17
|
+
title: '1 января года, следующего за годом открытия ИИС',
|
|
18
|
+
cells: [
|
|
19
|
+
{
|
|
20
|
+
text: 'Потенциальный доход инвестиций',
|
|
21
|
+
cellColor: 'green-light',
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
text: 'Первый взнос 400 000 ₽',
|
|
25
|
+
cellColor: 'green-dark',
|
|
26
|
+
cellSize: 'S',
|
|
27
|
+
},
|
|
28
|
+
],
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
title: '1 января второго года после открытия ИИС',
|
|
32
|
+
cells: [
|
|
33
|
+
{
|
|
34
|
+
text: 'Налоговый вычет за 1 год 52 000 ₽',
|
|
35
|
+
cellColor: 'yellow',
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
text: 'Потенциальный доход инвестиций за 2 года',
|
|
39
|
+
cellColor: 'green-light',
|
|
40
|
+
cellSize: 'S',
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
text: 'Второй взнос 400 000 ₽',
|
|
44
|
+
cellColor: 'green',
|
|
45
|
+
cellSize: 'S',
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
text: 'Первый взнос 400 000 ₽',
|
|
49
|
+
cellColor: 'green-dark',
|
|
50
|
+
cellSize: 'S',
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
title: '1 января третьего года после открытия ИИС',
|
|
56
|
+
cells: [
|
|
57
|
+
{
|
|
58
|
+
text: 'Налоговый вычет за 2 год 52 000 ₽',
|
|
59
|
+
cellColor: 'yellow',
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
text: 'Потенциальный доход инвестиций за 3 года',
|
|
63
|
+
cellColor: 'green-light',
|
|
64
|
+
cellSize: 'M',
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
text: 'Третий взнос — 0 ₽',
|
|
68
|
+
cellColor: 'green',
|
|
69
|
+
cellSize: 'S',
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
text: 'Первый и второй взносы 800 000 ₽',
|
|
73
|
+
cellColor: 'green-dark',
|
|
74
|
+
cellSize: 'L',
|
|
75
|
+
},
|
|
76
|
+
],
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
title: 'Возможный вывод средств, закрытие ИИС',
|
|
80
|
+
cells: [
|
|
81
|
+
{
|
|
82
|
+
text: 'Налоговый вычет за 3 года 156 000 ₽',
|
|
83
|
+
cellColor: 'yellow',
|
|
84
|
+
cellSize: 'S',
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
text: 'Потенциальный доход инвестиций за 3 года',
|
|
88
|
+
cellColor: 'green-light',
|
|
89
|
+
cellSize: 'M',
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
text: 'Сумма инвестиций за 3 года 1 200 000 ₽',
|
|
93
|
+
cellColor: 'green-dark',
|
|
94
|
+
cellSize: 'XL',
|
|
95
|
+
},
|
|
96
|
+
],
|
|
97
|
+
},
|
|
98
|
+
],
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
export default {
|
|
102
|
+
default: (
|
|
103
|
+
<div className="container grid grid-cols-12">
|
|
104
|
+
<InvestmentInfo className="col-span-12" context={context} {...INVESTMENT_INFO} />
|
|
105
|
+
</div>
|
|
106
|
+
),
|
|
107
|
+
};
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
+
import type { UniBlockProps } from '../../model/ContentPageDef';
|
|
3
|
+
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
4
|
+
import { List } from '../../ui-kit/List/List';
|
|
5
|
+
import { joinList } from '../../utils/joinList';
|
|
6
|
+
import type {
|
|
7
|
+
InvestmentCell,
|
|
8
|
+
InvestmentCellColor,
|
|
9
|
+
InvestmentCellSize,
|
|
10
|
+
InvestmentColumn,
|
|
11
|
+
InvestmentInfoContent,
|
|
12
|
+
InvestmentZeroColumn,
|
|
13
|
+
} from './InvestmentInfoContent';
|
|
14
|
+
|
|
15
|
+
const investmentCellColorMap: Record<InvestmentCellColor, string> = {
|
|
16
|
+
yellow: 'bg-yellow',
|
|
17
|
+
green: 'bg-green',
|
|
18
|
+
'green-light': 'bg-green-light',
|
|
19
|
+
'green-dark': 'bg-green-dark',
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
const investmentCellSizeMap: Record<InvestmentCellSize, string> = {
|
|
23
|
+
XS: 'h-[40px]',
|
|
24
|
+
S: 'h-[68px]',
|
|
25
|
+
M: 'h-[102px]',
|
|
26
|
+
L: 'h-[136px]',
|
|
27
|
+
XL: 'h-[204px]',
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export interface InvestmentInfoProps extends InvestmentInfoContent, UniBlockProps {}
|
|
31
|
+
|
|
32
|
+
export const InvestmentInfo = JSX<InvestmentInfoProps>((props) => {
|
|
33
|
+
const {
|
|
34
|
+
context,
|
|
35
|
+
className = '',
|
|
36
|
+
items,
|
|
37
|
+
isDotted,
|
|
38
|
+
investmentZeroColumn,
|
|
39
|
+
investmentColumns,
|
|
40
|
+
...rest
|
|
41
|
+
} = props;
|
|
42
|
+
const colums = investmentColumns ? [...investmentColumns] : [];
|
|
43
|
+
if (investmentZeroColumn) {
|
|
44
|
+
colums.unshift(investmentZeroColumn);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
return (
|
|
48
|
+
<BlockWrapper
|
|
49
|
+
className={`font-sans bg-white p-9 pb-9 ${className}`}
|
|
50
|
+
context={context}
|
|
51
|
+
{...rest}
|
|
52
|
+
>
|
|
53
|
+
<div className="container text-m-light">
|
|
54
|
+
{colums?.length ? (
|
|
55
|
+
<div>
|
|
56
|
+
<div className="flex items-end px-9 text-white">
|
|
57
|
+
{joinList(<div className="w-px h-4 bg-main-stroke" />)(
|
|
58
|
+
colums.map(renderInvestmentColumn),
|
|
59
|
+
)}
|
|
60
|
+
<div className="w-px h-4 bg-main-stroke" />
|
|
61
|
+
</div>
|
|
62
|
+
<div className="border-t border-main-stroke -mt-2 mx-9" />
|
|
63
|
+
<div className="flex justify-between mt-3 -mx-10">
|
|
64
|
+
{colums.map(renderInvestmentColumnTitle)}
|
|
65
|
+
</div>
|
|
66
|
+
</div>
|
|
67
|
+
) : null}
|
|
68
|
+
|
|
69
|
+
{items?.length ? (
|
|
70
|
+
<List
|
|
71
|
+
className="mt-9 text-h6"
|
|
72
|
+
items={items}
|
|
73
|
+
itemClassName="mb-[7px]"
|
|
74
|
+
isDotted={isDotted}
|
|
75
|
+
/>
|
|
76
|
+
) : null}
|
|
77
|
+
</div>
|
|
78
|
+
</BlockWrapper>
|
|
79
|
+
);
|
|
80
|
+
});
|
|
81
|
+
|
|
82
|
+
const renderInvestmentColumn = (
|
|
83
|
+
column: InvestmentColumn | InvestmentZeroColumn,
|
|
84
|
+
i: number,
|
|
85
|
+
arr: Array<InvestmentColumn>,
|
|
86
|
+
) => {
|
|
87
|
+
const isSecondColumn = i === 1;
|
|
88
|
+
const isLastColumn = i === arr.length - 1;
|
|
89
|
+
|
|
90
|
+
return (
|
|
91
|
+
<div
|
|
92
|
+
key={`column_${i}`}
|
|
93
|
+
className={`${getColumnClasses(isSecondColumn, isLastColumn, column.cells)}`}
|
|
94
|
+
>
|
|
95
|
+
{column.cells?.length ? (
|
|
96
|
+
<div className={`w-full ${isLastColumn ? 'border-4 border-green-more-dark p-1' : ''}`}>
|
|
97
|
+
{column.cells.map(renderInvestmentCell)}
|
|
98
|
+
</div>
|
|
99
|
+
) : null}
|
|
100
|
+
</div>
|
|
101
|
+
);
|
|
102
|
+
};
|
|
103
|
+
|
|
104
|
+
const getColumnClasses = (
|
|
105
|
+
isSecondColumn: boolean,
|
|
106
|
+
isLastColumn: boolean,
|
|
107
|
+
cells: InvestmentCell[] = [],
|
|
108
|
+
): string =>
|
|
109
|
+
[
|
|
110
|
+
cells.length ? 'flex-1' : 'flex-0',
|
|
111
|
+
cells.length && !isSecondColumn && !isLastColumn ? 'pl-2.5' : '',
|
|
112
|
+
cells.length && !isLastColumn ? 'pr-2.5 pb-8' : 'pb-6',
|
|
113
|
+
].join(' ');
|
|
114
|
+
|
|
115
|
+
const renderInvestmentCell = (cell: InvestmentCell, i: number) => {
|
|
116
|
+
const cellSize = cell.cellSize || 'XS';
|
|
117
|
+
const cellColor = cell.cellColor || 'green';
|
|
118
|
+
|
|
119
|
+
return cell.text ? (
|
|
120
|
+
<div
|
|
121
|
+
key={`cell_${i}`}
|
|
122
|
+
className={`flex-1 flex items-center justify-center relative py-2 ${
|
|
123
|
+
investmentCellSizeMap[cellSize]
|
|
124
|
+
} ${investmentCellColorMap[cellColor]} ${cellSize === 'XS' ? 'px-3' : 'px-11'}`}
|
|
125
|
+
>
|
|
126
|
+
<div className="text-center">{cell.text}</div>
|
|
127
|
+
</div>
|
|
128
|
+
) : null;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
const renderInvestmentColumnTitle = (
|
|
132
|
+
column: InvestmentColumn | InvestmentZeroColumn,
|
|
133
|
+
i: number,
|
|
134
|
+
arr: Array<InvestmentColumn>,
|
|
135
|
+
) => {
|
|
136
|
+
const isFirstColumn = i === 0;
|
|
137
|
+
const isLastColumn = i === arr.length - 1;
|
|
138
|
+
|
|
139
|
+
return (
|
|
140
|
+
<div
|
|
141
|
+
key={`title_${i}`}
|
|
142
|
+
className={`flex-1 max-w-[180px] text-center px-2 ${isFirstColumn ? 'pl-9' : ''} ${
|
|
143
|
+
isLastColumn ? 'pr-9' : ' '
|
|
144
|
+
}`}
|
|
145
|
+
>
|
|
146
|
+
{column.title}
|
|
147
|
+
</div>
|
|
148
|
+
);
|
|
149
|
+
};
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { ListContent } from '../../ui-kit/List/ListContent';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @title Цвет
|
|
5
|
+
* @enumNames ["Желтый", "Светло-зеленый", "Зеленый", "Тёмно-зеленый"]
|
|
6
|
+
*/
|
|
7
|
+
export type InvestmentCellColor = 'yellow' | 'green-light' | 'green' | 'green-dark';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* @title Высота
|
|
11
|
+
* @enumNames ["Очень большой", "Большой", "Средний", "Маленький", "Очень маленький"]
|
|
12
|
+
*/
|
|
13
|
+
export type InvestmentCellSize = 'XL' | 'L' | 'M' | 'S' | 'XS';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* @title Ячейка
|
|
17
|
+
*/
|
|
18
|
+
export type InvestmentCell = {
|
|
19
|
+
/** @title Текст */
|
|
20
|
+
text?: string;
|
|
21
|
+
cellColor?: InvestmentCellColor;
|
|
22
|
+
cellSize?: InvestmentCellSize;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* @title Элемент данных 1
|
|
27
|
+
*/
|
|
28
|
+
export type InvestmentZeroColumn = {
|
|
29
|
+
/** @title Название */
|
|
30
|
+
title?: string;
|
|
31
|
+
/** @hidden */
|
|
32
|
+
cells?: InvestmentCell[];
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* @title Элемент данных
|
|
37
|
+
*/
|
|
38
|
+
export type InvestmentColumn = {
|
|
39
|
+
/** @title Название */
|
|
40
|
+
title?: string;
|
|
41
|
+
/** @title Ячейки */
|
|
42
|
+
cells?: InvestmentCell[];
|
|
43
|
+
};
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* @title Блок инвестиций
|
|
47
|
+
*/
|
|
48
|
+
export type InvestmentInfoContent = ListContent & {
|
|
49
|
+
/** @title Буллиты */
|
|
50
|
+
isDotted?: boolean;
|
|
51
|
+
/** @title Элемент данных 1 */
|
|
52
|
+
investmentZeroColumn?: InvestmentZeroColumn;
|
|
53
|
+
/** @title Остальные элементы данных */
|
|
54
|
+
investmentColumns?: InvestmentColumn[];
|
|
55
|
+
};
|
|
@@ -2,8 +2,9 @@ import { JSX } from '@redneckz/uni-jsx';
|
|
|
2
2
|
import type { ColorPalette, UniBlockProps } from '../../model/ContentPageDef';
|
|
3
3
|
import type { VNode } from '../../model/VNode';
|
|
4
4
|
import { renderBlocksList } from '../../ui-kit/BlocksList/renderBlocksList';
|
|
5
|
-
import {
|
|
5
|
+
import { DefaultFoldButton } from '../../ui-kit/Foldable/DefaultFoldButton';
|
|
6
6
|
import { Foldable } from '../../ui-kit/Foldable/Foldable';
|
|
7
|
+
import { FoldableSection } from '../../ui-kit/Foldable/FoldableSection';
|
|
7
8
|
import type { IconName } from '../../ui-kit/Icon/IconProps';
|
|
8
9
|
import type { BlockItemCommonProps } from './OtherProductsContent';
|
|
9
10
|
|
|
@@ -14,7 +15,7 @@ export interface BlockItemProps extends BlockItemCommonProps, UniBlockProps {
|
|
|
14
15
|
const icons: IconName[] = ['ArrowDownIcon', 'ArrowUpIcon'];
|
|
15
16
|
|
|
16
17
|
export const OtherProductsItem = JSX<BlockItemProps>(
|
|
17
|
-
({ label = '', blocks, context, dataTheme, isUnfolded }) => {
|
|
18
|
+
({ label = '', blocks, context, dataTheme, isUnfolded: unfoldedByDefault }) => {
|
|
18
19
|
const foldableBlocks = renderBlocksList({
|
|
19
20
|
context,
|
|
20
21
|
blocks,
|
|
@@ -24,17 +25,23 @@ export const OtherProductsItem = JSX<BlockItemProps>(
|
|
|
24
25
|
<div className="˝border-0 border-b border-solid border-main-divider">
|
|
25
26
|
{blocks?.length ? (
|
|
26
27
|
<Foldable
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
28
|
+
unfoldedByDefault={unfoldedByDefault}
|
|
29
|
+
renderFoldableSection={({ isUnfolded }) => (
|
|
30
|
+
<div className="box-border">
|
|
31
|
+
<FoldableSection
|
|
32
|
+
className="grid grid-cols-12 gap-1 border-box"
|
|
33
|
+
isUnfolded={isUnfolded}
|
|
34
|
+
>
|
|
35
|
+
{foldableBlocks}
|
|
36
|
+
</FoldableSection>
|
|
37
|
+
</div>
|
|
38
|
+
)}
|
|
39
|
+
renderFoldButton={({ isUnfolded, onToggle }) => (
|
|
40
|
+
<DefaultFoldButton
|
|
35
41
|
label={label}
|
|
42
|
+
icon={icons[Number(isUnfolded)]}
|
|
36
43
|
dataTheme={dataTheme}
|
|
37
|
-
onClick={
|
|
44
|
+
onClick={onToggle}
|
|
38
45
|
/>
|
|
39
46
|
)}
|
|
40
47
|
/>
|
|
@@ -43,7 +50,3 @@ export const OtherProductsItem = JSX<BlockItemProps>(
|
|
|
43
50
|
);
|
|
44
51
|
},
|
|
45
52
|
);
|
|
46
|
-
|
|
47
|
-
const Wrapper = JSX(({ children }) => {
|
|
48
|
-
return <div className="box-border">{children}</div>;
|
|
49
|
-
});
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { context } from '../../react/setup-fixture';
|
|
2
2
|
import { StepsBlock } from './StepsBlock';
|
|
3
|
+
import type { Step } from './StepsBlockContent';
|
|
3
4
|
|
|
4
|
-
const
|
|
5
|
-
const
|
|
5
|
+
const ITEMS = ['item1', 'item2', 'item3', 'item4', 'item5'];
|
|
6
|
+
const STEPS = [
|
|
6
7
|
{
|
|
7
8
|
label: 'Заявка на кредит',
|
|
8
9
|
description: 'Оставьте онлайн-заявку на потребительский кредит',
|
|
@@ -21,6 +22,27 @@ const steps = [
|
|
|
21
22
|
},
|
|
22
23
|
];
|
|
23
24
|
|
|
25
|
+
const STEPS_WITH_LIST: Step[] = [
|
|
26
|
+
{
|
|
27
|
+
label: 'В мобильном приложении или интернет-банке',
|
|
28
|
+
description: 'Для всех клиентов Россельхозбанка',
|
|
29
|
+
icon: { icon: 'SignDocsIcon' },
|
|
30
|
+
items: ITEMS,
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
label: 'Через Госуслуги',
|
|
34
|
+
description: 'При наличии данных в Единой биометрической системе',
|
|
35
|
+
icon: { icon: 'ClockIcon' },
|
|
36
|
+
items: ITEMS,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
label: 'В офисах Россельхозбанка',
|
|
40
|
+
description: 'Откройте вклад',
|
|
41
|
+
icon: { icon: 'ComfortableCompIcon' },
|
|
42
|
+
items: ITEMS,
|
|
43
|
+
},
|
|
44
|
+
];
|
|
45
|
+
|
|
24
46
|
export default {
|
|
25
47
|
default: (
|
|
26
48
|
<div className="container grid grid-cols-12">
|
|
@@ -28,7 +50,7 @@ export default {
|
|
|
28
50
|
className="col-span-12"
|
|
29
51
|
context={context}
|
|
30
52
|
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
31
|
-
steps={
|
|
53
|
+
steps={STEPS.slice(0, 3)}
|
|
32
54
|
version="secondary"
|
|
33
55
|
/>
|
|
34
56
|
</div>
|
|
@@ -101,37 +123,29 @@ export default {
|
|
|
101
123
|
className="col-span-12"
|
|
102
124
|
context={context}
|
|
103
125
|
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
104
|
-
steps={
|
|
126
|
+
steps={STEPS}
|
|
105
127
|
/>
|
|
106
128
|
</div>
|
|
107
129
|
),
|
|
108
130
|
|
|
109
|
-
'
|
|
131
|
+
'with list': (
|
|
110
132
|
<div className="container grid grid-cols-12">
|
|
111
133
|
<StepsBlock
|
|
112
134
|
className="col-span-12"
|
|
113
135
|
context={context}
|
|
114
136
|
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
115
|
-
steps={
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
},
|
|
128
|
-
{
|
|
129
|
-
label: 'В офисах Россельхозбанка',
|
|
130
|
-
description: 'Откройте вклад',
|
|
131
|
-
icon: { icon: 'ComfortableCompIcon' },
|
|
132
|
-
items,
|
|
133
|
-
},
|
|
134
|
-
]}
|
|
137
|
+
steps={STEPS_WITH_LIST}
|
|
138
|
+
/>
|
|
139
|
+
</div>
|
|
140
|
+
),
|
|
141
|
+
'with list secondary': (
|
|
142
|
+
<div className="container grid grid-cols-12">
|
|
143
|
+
<StepsBlock
|
|
144
|
+
className="col-span-12"
|
|
145
|
+
context={context}
|
|
146
|
+
version="secondary"
|
|
147
|
+
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
148
|
+
steps={STEPS_WITH_LIST}
|
|
135
149
|
/>
|
|
136
150
|
</div>
|
|
137
151
|
),
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import { useLink } from '../../hooks/useLink';
|
|
3
|
-
import type { BlockVersion } from '../../model/BlockVersion';
|
|
4
3
|
import type { UniBlockProps } from '../../model/ContentPageDef';
|
|
5
4
|
import { BlockWrapper } from '../../ui-kit/BlockWrapper';
|
|
6
5
|
import { Button } from '../../ui-kit/Button/Button';
|
|
@@ -8,11 +7,10 @@ import { Heading } from '../../ui-kit/Heading/Heading';
|
|
|
8
7
|
import { Img } from '../../ui-kit/Img/Img';
|
|
9
8
|
import { checkIsIconRenderable } from '../../utils/checkIsIconRenderable';
|
|
10
9
|
import { joinList } from '../../utils/joinList';
|
|
11
|
-
import type { HandlerDecorator, Router } from '../ContentPage/ContentPageContext';
|
|
12
|
-
import { renderItems } from './renderItems';
|
|
13
10
|
import type { Step, StepsBlockContent } from './StepsBlockContent';
|
|
14
11
|
import type { StyleType } from './StepsBlockStyleMaps';
|
|
15
12
|
import { STEPS_BLOCK_STYLE_MAPS } from './StepsBlockStyleMaps';
|
|
13
|
+
import { renderStepContent } from './renderStepContent';
|
|
16
14
|
|
|
17
15
|
export interface StepsBlockProps extends StepsBlockContent, UniBlockProps {}
|
|
18
16
|
|
|
@@ -54,7 +52,7 @@ export const StepsBlock = JSX<StepsBlockProps>(
|
|
|
54
52
|
{...rest}
|
|
55
53
|
>
|
|
56
54
|
{title ? (
|
|
57
|
-
<Heading headingType="
|
|
55
|
+
<Heading headingType="h3" className="max-w-[752px] text-center" title={title} />
|
|
58
56
|
) : null}
|
|
59
57
|
{steps?.length ? (
|
|
60
58
|
<div className={`box-border ${titleMargin}`}>
|
|
@@ -65,7 +63,7 @@ export const StepsBlock = JSX<StepsBlockProps>(
|
|
|
65
63
|
</div>
|
|
66
64
|
<div className={`flex justify-between ${shortGaps ? 'gap-x-3' : 'gap-x-[101px]'}`}>
|
|
67
65
|
{steps.map(
|
|
68
|
-
|
|
66
|
+
renderStepContent({
|
|
69
67
|
styleMap,
|
|
70
68
|
isMainButton: Boolean(button?.text),
|
|
71
69
|
version,
|
|
@@ -106,47 +104,3 @@ const renderStepIcon =
|
|
|
106
104
|
</div>
|
|
107
105
|
);
|
|
108
106
|
};
|
|
109
|
-
|
|
110
|
-
const renderStepTitle =
|
|
111
|
-
({
|
|
112
|
-
styleMap,
|
|
113
|
-
isMainButton,
|
|
114
|
-
version,
|
|
115
|
-
router,
|
|
116
|
-
handlerDecorator,
|
|
117
|
-
}: {
|
|
118
|
-
styleMap: StyleType;
|
|
119
|
-
isMainButton: boolean;
|
|
120
|
-
version: BlockVersion;
|
|
121
|
-
router: Router;
|
|
122
|
-
handlerDecorator?: HandlerDecorator;
|
|
123
|
-
}) =>
|
|
124
|
-
(step: Step, i: number, { length }: { length: number }) => {
|
|
125
|
-
const additionalMarginClass = step?.label ? 'mt-2' : 'mt-4';
|
|
126
|
-
const widthContainer = length < 5 ? 'w-[276px]' : 'w-[210px]';
|
|
127
|
-
|
|
128
|
-
return (
|
|
129
|
-
<div
|
|
130
|
-
key={String(i)}
|
|
131
|
-
className={`flex flex-col items-center text-center relative
|
|
132
|
-
whitespace-pre-line overflow-hidden ${widthContainer}`}
|
|
133
|
-
>
|
|
134
|
-
{step?.label ? <div className="text-xl m-0 mt-4">{step.label}</div> : null}
|
|
135
|
-
{step?.description ? (
|
|
136
|
-
<div className={`text-l-light ${styleMap.description} ${additionalMarginClass}`}>
|
|
137
|
-
{step.description}
|
|
138
|
-
</div>
|
|
139
|
-
) : null}
|
|
140
|
-
{renderItems(step?.items, styleMap, step?.isDotted)}
|
|
141
|
-
{step.button?.text && !isMainButton ? (
|
|
142
|
-
<Button
|
|
143
|
-
className="box-border mt-8 py-3 h-12 w-full max-w-[240px]"
|
|
144
|
-
{...useLink({ router, handlerDecorator }, step.button)}
|
|
145
|
-
version={version}
|
|
146
|
-
>
|
|
147
|
-
{step.button.text}
|
|
148
|
-
</Button>
|
|
149
|
-
) : null}
|
|
150
|
-
</div>
|
|
151
|
-
);
|
|
152
|
-
};
|
|
@@ -14,7 +14,7 @@ export const STEPS_BLOCK_STYLE_MAPS: Record<BlockVersion, StyleType> = {
|
|
|
14
14
|
primary: {
|
|
15
15
|
background: 'bg-white',
|
|
16
16
|
title: 'text-primary-text',
|
|
17
|
-
description: 'text-secondary-text',
|
|
17
|
+
description: '!text-secondary-text text-l-light',
|
|
18
18
|
iconText: 'text-secondary-text',
|
|
19
19
|
iconBackground: 'bg-main-divider',
|
|
20
20
|
iconConnector: 'bg-secondary-light',
|
|
@@ -23,7 +23,7 @@ export const STEPS_BLOCK_STYLE_MAPS: Record<BlockVersion, StyleType> = {
|
|
|
23
23
|
secondary: {
|
|
24
24
|
background: 'bg-primary-main',
|
|
25
25
|
title: 'text-white',
|
|
26
|
-
description: 'text-white/80',
|
|
26
|
+
description: '!text-white/80 text-l-light',
|
|
27
27
|
iconText: 'text-white',
|
|
28
28
|
iconBackground: 'bg-white/30',
|
|
29
29
|
iconConnector: 'bg-white',
|
|
@@ -1,17 +1,26 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { List } from '../../ui-kit/List/List';
|
|
2
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
3
|
|
|
3
|
-
export const renderItems = (
|
|
4
|
-
items
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
4
|
+
export const renderItems = ({
|
|
5
|
+
items,
|
|
6
|
+
isDotted = true,
|
|
7
|
+
version = 'primary',
|
|
8
|
+
className = '',
|
|
9
|
+
}: {
|
|
10
|
+
items?: string[];
|
|
11
|
+
isDotted?: boolean;
|
|
12
|
+
version?: BlockVersion;
|
|
13
|
+
className?: string;
|
|
14
|
+
}) => {
|
|
15
|
+
const listVersion = version === 'primary' ? 'gray' : version;
|
|
16
|
+
|
|
17
|
+
return items ? (
|
|
18
|
+
<List
|
|
19
|
+
className={`mt-4 ${className}`}
|
|
20
|
+
version={listVersion}
|
|
21
|
+
items={items}
|
|
22
|
+
listItemSize="S"
|
|
23
|
+
isDotted={isDotted}
|
|
24
|
+
/>
|
|
17
25
|
) : null;
|
|
26
|
+
};
|