@redneckz/wildless-cms-uni-blocks 0.6.18 → 0.6.20
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.6.19.js +21 -0
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +129 -77
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/Blocks.d.ts +2 -41
- package/bundle/components/Blocks.mobile.d.ts +2 -18
- package/bundle/components/ContentPage/ContentPage.d.ts +2 -2
- package/bundle/components/ContentPage/mapSlot.d.ts +2 -0
- package/bundle/components/ContentPage/normalizeBlock.d.ts +3 -11
- package/bundle/components/ContentPage/normalizeBlock.mobile.d.ts +3 -2
- package/bundle/components/ContentPage/renderBlock.d.ts +7 -3
- package/bundle/components/ContentPage/renderBlockList.d.ts +14 -0
- package/bundle/components/ContentPage/renderSlots.d.ts +12 -0
- package/bundle/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/bundle/components/TariffsTable/EmbeddableCellData.d.ts +7 -1
- package/bundle/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/bundle/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/bundle/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/bundle/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/bundle/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/bundle/model/BlockDecorator.d.ts +4 -3
- package/bundle/model/BlocksRegistry.d.ts +1 -1
- package/bundle/model/ContentPageDef.d.ts +1 -4
- package/bundle/model/JSXBlock.d.ts +3 -1
- package/bundle/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/bundle/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/dist/components/Blocks.d.ts +2 -41
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Blocks.mobile.d.ts +2 -18
- package/dist/components/Blocks.mobile.js.map +1 -1
- package/dist/components/Bonus/Bonus.js +1 -1
- package/dist/components/Bonus/Bonus.js.map +1 -1
- package/dist/components/ContentPage/ContentPage.d.ts +2 -2
- package/dist/components/ContentPage/ContentPage.js +12 -11
- package/dist/components/ContentPage/ContentPage.js.map +1 -1
- package/dist/components/ContentPage/mapSlot.d.ts +2 -0
- package/dist/components/ContentPage/mapSlot.js +14 -0
- package/dist/components/ContentPage/mapSlot.js.map +1 -0
- package/dist/components/ContentPage/normalizeBlock.d.ts +3 -11
- package/dist/components/ContentPage/normalizeBlock.js +13 -3
- package/dist/components/ContentPage/normalizeBlock.js.map +1 -1
- package/dist/components/ContentPage/normalizeBlock.mobile.d.ts +3 -2
- package/dist/components/ContentPage/normalizeBlock.mobile.js +18 -3
- package/dist/components/ContentPage/normalizeBlock.mobile.js.map +1 -1
- package/dist/components/ContentPage/normalizePage.js +2 -14
- package/dist/components/ContentPage/normalizePage.js.map +1 -1
- package/dist/components/ContentPage/renderBlock.d.ts +7 -3
- package/dist/components/ContentPage/renderBlock.js +9 -9
- package/dist/components/ContentPage/renderBlock.js.map +1 -1
- package/dist/components/ContentPage/renderBlockList.d.ts +14 -0
- package/dist/components/ContentPage/renderBlockList.js +18 -0
- package/dist/components/ContentPage/renderBlockList.js.map +1 -0
- package/dist/components/ContentPage/renderSlots.d.ts +12 -0
- package/dist/components/ContentPage/renderSlots.js +17 -0
- package/dist/components/ContentPage/renderSlots.js.map +1 -0
- package/dist/components/ProductBlock/renderBackwardButton.js +1 -1
- package/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/dist/components/SafeDepositRental/SafeDepositRental.js +1 -1
- package/dist/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlock.js +3 -3
- package/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/dist/components/StepsBlock/renderItems.js +1 -4
- package/dist/components/StepsBlock/renderItems.js.map +1 -1
- package/dist/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/dist/components/StepsBlock/renderStepContent.js +13 -8
- package/dist/components/StepsBlock/renderStepContent.js.map +1 -1
- package/dist/components/TariffsTable/EmbeddableCellData.d.ts +7 -1
- package/dist/components/TariffsTable/EmbeddableCellData.js +4 -11
- package/dist/components/TariffsTable/EmbeddableCellData.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTable.js +1 -1
- package/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/dist/components/TariffsTable/TariffsTableCell.js +13 -18
- package/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/dist/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/dist/components/TariffsTable/TariffsTableRenderCell.js +42 -0
- package/dist/components/TariffsTable/TariffsTableRenderCell.js.map +1 -0
- package/dist/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/dist/components/TariffsTable/TariffsTableRow.js +6 -2
- package/dist/components/TariffsTable/TariffsTableRow.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/dist/components/TariffsTable/TariffsTableRowContainer.js +2 -8
- package/dist/components/TariffsTable/TariffsTableRowContainer.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableTileCell.js +1 -1
- package/dist/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
- package/dist/model/BlockDecorator.d.ts +4 -3
- package/dist/model/BlockDecorator.js +1 -2
- package/dist/model/BlockDecorator.js.map +1 -1
- package/dist/model/BlocksRegistry.d.ts +1 -1
- package/dist/model/ContentPageDef.d.ts +1 -4
- package/dist/model/JSXBlock.d.ts +3 -1
- package/dist/model/getParentBlockDef.js +5 -2
- package/dist/model/getParentBlockDef.js.map +1 -1
- package/dist/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/dist/ui-kit/InnerTable/InnerTable.js +3 -2
- package/dist/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/dist/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/dist/ui-kit/InnerTable/InnerTableButton.js +2 -6
- package/dist/ui-kit/InnerTable/InnerTableButton.js.map +1 -1
- package/dist/ui-kit/InputRange/InputRange.js +1 -1
- package/dist/ui-kit/InputRange/InputRange.js.map +1 -1
- package/dist/ui-kit/Radio/Radio.js +1 -1
- package/dist/ui-kit/Radio/Radio.js.map +1 -1
- package/dist/ui-kit/Select/Select.js +1 -1
- package/dist/ui-kit/Select/Select.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/Blocks.d.ts +2 -41
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Blocks.mobile.d.ts +2 -18
- package/lib/components/Blocks.mobile.js.map +1 -1
- package/lib/components/Bonus/Bonus.js +1 -1
- package/lib/components/Bonus/Bonus.js.map +1 -1
- package/lib/components/ContentPage/ContentPage.d.ts +2 -2
- package/lib/components/ContentPage/ContentPage.js +12 -11
- package/lib/components/ContentPage/ContentPage.js.map +1 -1
- package/lib/components/ContentPage/mapSlot.d.ts +2 -0
- package/lib/components/ContentPage/mapSlot.js +11 -0
- package/lib/components/ContentPage/mapSlot.js.map +1 -0
- package/lib/components/ContentPage/normalizeBlock.d.ts +3 -11
- package/lib/components/ContentPage/normalizeBlock.js +13 -3
- package/lib/components/ContentPage/normalizeBlock.js.map +1 -1
- package/lib/components/ContentPage/normalizeBlock.mobile.d.ts +3 -2
- package/lib/components/ContentPage/normalizeBlock.mobile.js +18 -3
- package/lib/components/ContentPage/normalizeBlock.mobile.js.map +1 -1
- package/lib/components/ContentPage/normalizePage.js +2 -14
- package/lib/components/ContentPage/normalizePage.js.map +1 -1
- package/lib/components/ContentPage/renderBlock.d.ts +7 -3
- package/lib/components/ContentPage/renderBlock.js +9 -9
- package/lib/components/ContentPage/renderBlock.js.map +1 -1
- package/lib/components/ContentPage/renderBlockList.d.ts +14 -0
- package/lib/components/ContentPage/renderBlockList.js +15 -0
- package/lib/components/ContentPage/renderBlockList.js.map +1 -0
- package/lib/components/ContentPage/renderSlots.d.ts +12 -0
- package/lib/components/ContentPage/renderSlots.js +14 -0
- package/lib/components/ContentPage/renderSlots.js.map +1 -0
- package/lib/components/ProductBlock/renderBackwardButton.js +1 -1
- package/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/lib/components/SafeDepositRental/SafeDepositRental.js +1 -1
- package/lib/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlock.fixture.d.ts +6 -2
- package/lib/components/StepsBlock/StepsBlock.js +3 -3
- package/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/lib/components/StepsBlock/renderItems.js +1 -4
- package/lib/components/StepsBlock/renderItems.js.map +1 -1
- package/lib/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/lib/components/StepsBlock/renderStepContent.js +14 -9
- package/lib/components/StepsBlock/renderStepContent.js.map +1 -1
- package/lib/components/TariffsTable/EmbeddableCellData.d.ts +7 -1
- package/lib/components/TariffsTable/EmbeddableCellData.js +4 -11
- package/lib/components/TariffsTable/EmbeddableCellData.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTable.js +1 -1
- package/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/lib/components/TariffsTable/TariffsTableCell.js +14 -19
- package/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/lib/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/lib/components/TariffsTable/TariffsTableRenderCell.js +39 -0
- package/lib/components/TariffsTable/TariffsTableRenderCell.js.map +1 -0
- package/lib/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/lib/components/TariffsTable/TariffsTableRow.js +6 -2
- package/lib/components/TariffsTable/TariffsTableRow.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/lib/components/TariffsTable/TariffsTableRowContainer.js +2 -8
- package/lib/components/TariffsTable/TariffsTableRowContainer.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableTileCell.js +1 -1
- package/lib/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
- package/lib/model/BlockDecorator.d.ts +4 -3
- package/lib/model/BlockDecorator.js +0 -1
- package/lib/model/BlockDecorator.js.map +1 -1
- package/lib/model/BlocksRegistry.d.ts +1 -1
- package/lib/model/ContentPageDef.d.ts +1 -4
- package/lib/model/JSXBlock.d.ts +3 -1
- package/lib/model/getParentBlockDef.js +5 -2
- package/lib/model/getParentBlockDef.js.map +1 -1
- package/lib/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/lib/ui-kit/InnerTable/InnerTable.js +3 -2
- package/lib/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/lib/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/lib/ui-kit/InnerTable/InnerTableButton.js +2 -6
- package/lib/ui-kit/InnerTable/InnerTableButton.js.map +1 -1
- package/lib/ui-kit/InputRange/InputRange.js +1 -1
- package/lib/ui-kit/InputRange/InputRange.js.map +1 -1
- package/lib/ui-kit/Radio/Radio.js +1 -1
- package/lib/ui-kit/Radio/Radio.js.map +1 -1
- package/lib/ui-kit/Select/Select.js +1 -1
- package/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +50 -23
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/Blocks.d.ts +2 -18
- package/mobile/bundle/components/ContentPage/ContentPage.d.ts +2 -2
- package/mobile/bundle/components/ContentPage/mapSlot.d.ts +2 -0
- package/mobile/bundle/components/ContentPage/normalizeBlock.d.ts +3 -2
- package/mobile/bundle/components/ContentPage/renderBlock.d.ts +7 -3
- package/mobile/bundle/components/ContentPage/renderBlockList.d.ts +14 -0
- package/mobile/bundle/components/ContentPage/renderSlots.d.ts +12 -0
- package/mobile/bundle/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/mobile/bundle/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/mobile/bundle/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/mobile/bundle/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/mobile/bundle/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/mobile/bundle/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/mobile/bundle/model/BlockDecorator.d.ts +4 -3
- package/mobile/bundle/model/BlocksRegistry.d.ts +1 -1
- package/mobile/bundle/model/ContentPageDef.d.ts +1 -4
- package/mobile/bundle/model/JSXBlock.d.ts +3 -1
- package/mobile/bundle/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/mobile/bundle/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/mobile/dist/components/Blocks.d.ts +2 -18
- package/mobile/dist/components/Blocks.js.map +1 -1
- package/mobile/dist/components/Bonus/Bonus.js +1 -1
- package/mobile/dist/components/Bonus/Bonus.js.map +1 -1
- package/mobile/dist/components/ContentPage/ContentPage.d.ts +2 -2
- package/mobile/dist/components/ContentPage/ContentPage.js +12 -11
- package/mobile/dist/components/ContentPage/ContentPage.js.map +1 -1
- package/mobile/dist/components/ContentPage/mapSlot.d.ts +2 -0
- package/mobile/dist/components/ContentPage/mapSlot.js +14 -0
- package/mobile/dist/components/ContentPage/mapSlot.js.map +1 -0
- package/mobile/dist/components/ContentPage/normalizeBlock.d.ts +3 -2
- package/mobile/dist/components/ContentPage/normalizeBlock.js +18 -3
- package/mobile/dist/components/ContentPage/normalizeBlock.js.map +1 -1
- package/mobile/dist/components/ContentPage/normalizePage.js +2 -14
- package/mobile/dist/components/ContentPage/normalizePage.js.map +1 -1
- package/mobile/dist/components/ContentPage/renderBlock.d.ts +7 -3
- package/mobile/dist/components/ContentPage/renderBlock.js +9 -9
- package/mobile/dist/components/ContentPage/renderBlock.js.map +1 -1
- package/mobile/dist/components/ContentPage/renderBlockList.d.ts +14 -0
- package/mobile/dist/components/ContentPage/renderBlockList.js +18 -0
- package/mobile/dist/components/ContentPage/renderBlockList.js.map +1 -0
- package/mobile/dist/components/ContentPage/renderSlots.d.ts +12 -0
- package/mobile/dist/components/ContentPage/renderSlots.js +17 -0
- package/mobile/dist/components/ContentPage/renderSlots.js.map +1 -0
- package/mobile/dist/components/ProductBlock/renderBackwardButton.js +1 -1
- package/mobile/dist/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/dist/components/SafeDepositRental/SafeDepositRental.js +1 -1
- package/mobile/dist/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
- package/mobile/dist/components/StepsBlock/renderItems.js +1 -4
- package/mobile/dist/components/StepsBlock/renderItems.js.map +1 -1
- package/mobile/dist/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/mobile/dist/components/StepsBlock/renderStepContent.js +13 -8
- package/mobile/dist/components/StepsBlock/renderStepContent.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/mobile/dist/components/TariffsTable/TariffsTableCell.js +13 -18
- package/mobile/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/mobile/dist/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/mobile/dist/components/TariffsTable/TariffsTableRenderCell.js +42 -0
- package/mobile/dist/components/TariffsTable/TariffsTableRenderCell.js.map +1 -0
- package/mobile/dist/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/mobile/dist/components/TariffsTable/TariffsTableRow.js +6 -2
- package/mobile/dist/components/TariffsTable/TariffsTableRow.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/mobile/dist/components/TariffsTable/TariffsTableRowContainer.js +2 -8
- package/mobile/dist/components/TariffsTable/TariffsTableRowContainer.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableTileCell.js +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
- package/mobile/dist/model/BlockDecorator.d.ts +4 -3
- package/mobile/dist/model/BlockDecorator.js +1 -2
- package/mobile/dist/model/BlockDecorator.js.map +1 -1
- package/mobile/dist/model/BlocksRegistry.d.ts +1 -1
- package/mobile/dist/model/ContentPageDef.d.ts +1 -4
- package/mobile/dist/model/JSXBlock.d.ts +3 -1
- package/mobile/dist/model/getParentBlockDef.js +5 -2
- package/mobile/dist/model/getParentBlockDef.js.map +1 -1
- package/mobile/dist/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/mobile/dist/ui-kit/InnerTable/InnerTable.js +3 -2
- package/mobile/dist/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/mobile/dist/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/mobile/dist/ui-kit/InnerTable/InnerTableButton.js +2 -6
- package/mobile/dist/ui-kit/InnerTable/InnerTableButton.js.map +1 -1
- package/mobile/dist/ui-kit/InputRange/InputRange.js +1 -1
- package/mobile/dist/ui-kit/InputRange/InputRange.js.map +1 -1
- package/mobile/dist/ui-kit/Radio/Radio.js +1 -1
- package/mobile/dist/ui-kit/Radio/Radio.js.map +1 -1
- package/mobile/dist/ui-kit/Select/Select.js +1 -1
- package/mobile/dist/ui-kit/Select/Select.js.map +1 -1
- package/mobile/lib/components/Blocks.d.ts +2 -18
- package/mobile/lib/components/Blocks.js.map +1 -1
- package/mobile/lib/components/Bonus/Bonus.js +1 -1
- package/mobile/lib/components/Bonus/Bonus.js.map +1 -1
- package/mobile/lib/components/ContentPage/ContentPage.d.ts +2 -2
- package/mobile/lib/components/ContentPage/ContentPage.js +12 -11
- package/mobile/lib/components/ContentPage/ContentPage.js.map +1 -1
- package/mobile/lib/components/ContentPage/mapSlot.d.ts +2 -0
- package/mobile/lib/components/ContentPage/mapSlot.js +11 -0
- package/mobile/lib/components/ContentPage/mapSlot.js.map +1 -0
- package/mobile/lib/components/ContentPage/normalizeBlock.d.ts +3 -2
- package/mobile/lib/components/ContentPage/normalizeBlock.js +18 -3
- package/mobile/lib/components/ContentPage/normalizeBlock.js.map +1 -1
- package/mobile/lib/components/ContentPage/normalizePage.js +2 -14
- package/mobile/lib/components/ContentPage/normalizePage.js.map +1 -1
- package/mobile/lib/components/ContentPage/renderBlock.d.ts +7 -3
- package/mobile/lib/components/ContentPage/renderBlock.js +9 -9
- package/mobile/lib/components/ContentPage/renderBlock.js.map +1 -1
- package/mobile/lib/components/ContentPage/renderBlockList.d.ts +14 -0
- package/mobile/lib/components/ContentPage/renderBlockList.js +15 -0
- package/mobile/lib/components/ContentPage/renderBlockList.js.map +1 -0
- package/mobile/lib/components/ContentPage/renderSlots.d.ts +12 -0
- package/mobile/lib/components/ContentPage/renderSlots.js +14 -0
- package/mobile/lib/components/ContentPage/renderSlots.js.map +1 -0
- package/mobile/lib/components/ProductBlock/renderBackwardButton.js +1 -1
- package/mobile/lib/components/ProductBlock/renderBackwardButton.js.map +1 -1
- package/mobile/lib/components/SafeDepositRental/SafeDepositRental.js +1 -1
- package/mobile/lib/components/SafeDepositRental/SafeDepositRental.js.map +1 -1
- package/mobile/lib/components/StepsBlock/renderItems.js +1 -4
- package/mobile/lib/components/StepsBlock/renderItems.js.map +1 -1
- package/mobile/lib/components/StepsBlock/renderStepContent.d.ts +2 -2
- package/mobile/lib/components/StepsBlock/renderStepContent.js +14 -9
- package/mobile/lib/components/StepsBlock/renderStepContent.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableCell.d.ts +8 -2
- package/mobile/lib/components/TariffsTable/TariffsTableCell.js +14 -19
- package/mobile/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableContent.d.ts +3 -4
- package/mobile/lib/components/TariffsTable/TariffsTableRenderCell.d.ts +11 -0
- package/mobile/lib/components/TariffsTable/TariffsTableRenderCell.js +39 -0
- package/mobile/lib/components/TariffsTable/TariffsTableRenderCell.js.map +1 -0
- package/mobile/lib/components/TariffsTable/TariffsTableRow.d.ts +0 -1
- package/mobile/lib/components/TariffsTable/TariffsTableRow.js +6 -2
- package/mobile/lib/components/TariffsTable/TariffsTableRow.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableRowContainer.d.ts +3 -1
- package/mobile/lib/components/TariffsTable/TariffsTableRowContainer.js +2 -8
- package/mobile/lib/components/TariffsTable/TariffsTableRowContainer.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableTileCell.js +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableTileCell.js.map +1 -1
- package/mobile/lib/model/BlockDecorator.d.ts +4 -3
- package/mobile/lib/model/BlockDecorator.js +0 -1
- package/mobile/lib/model/BlockDecorator.js.map +1 -1
- package/mobile/lib/model/BlocksRegistry.d.ts +1 -1
- package/mobile/lib/model/ContentPageDef.d.ts +1 -4
- package/mobile/lib/model/JSXBlock.d.ts +3 -1
- package/mobile/lib/model/getParentBlockDef.js +5 -2
- package/mobile/lib/model/getParentBlockDef.js.map +1 -1
- package/mobile/lib/ui-kit/InnerTable/InnerTable.d.ts +1 -0
- package/mobile/lib/ui-kit/InnerTable/InnerTable.js +3 -2
- package/mobile/lib/ui-kit/InnerTable/InnerTable.js.map +1 -1
- package/mobile/lib/ui-kit/InnerTable/InnerTableButton.d.ts +1 -0
- package/mobile/lib/ui-kit/InnerTable/InnerTableButton.js +2 -6
- package/mobile/lib/ui-kit/InnerTable/InnerTableButton.js.map +1 -1
- package/mobile/lib/ui-kit/InputRange/InputRange.js +1 -1
- package/mobile/lib/ui-kit/InputRange/InputRange.js.map +1 -1
- package/mobile/lib/ui-kit/Radio/Radio.js +1 -1
- package/mobile/lib/ui-kit/Radio/Radio.js.map +1 -1
- package/mobile/lib/ui-kit/Select/Select.js +1 -1
- package/mobile/lib/ui-kit/Select/Select.js.map +1 -1
- package/mobile/src/components/Blocks.ts +2 -1
- package/mobile/src/components/Bonus/Bonus.tsx +1 -1
- package/mobile/src/components/ContentPage/ContentPage.page.json +7 -10
- package/mobile/src/components/ContentPage/ContentPage.tsx +24 -28
- package/mobile/src/components/ContentPage/mapSlot.ts +17 -0
- package/mobile/src/components/ContentPage/normalizeBlock.ts +26 -4
- package/mobile/src/components/ContentPage/normalizePage.ts +3 -20
- package/mobile/src/components/ContentPage/renderBlock.tsx +16 -18
- package/mobile/src/components/ContentPage/renderBlockList.tsx +39 -0
- package/mobile/src/components/ContentPage/renderSlots.tsx +33 -0
- package/mobile/src/components/ProductBlock/renderBackwardButton.tsx +5 -1
- package/mobile/src/components/SafeDepositRental/SafeDepositRental.tsx +6 -1
- package/mobile/src/components/StepsBlock/renderItems.tsx +5 -8
- package/mobile/src/components/StepsBlock/renderStepContent.tsx +40 -15
- package/mobile/src/components/TariffsTable/TariffsTableCell.tsx +39 -45
- package/mobile/src/components/TariffsTable/TariffsTableContent.ts +3 -4
- package/mobile/src/components/TariffsTable/TariffsTableRenderCell.tsx +88 -0
- package/mobile/src/components/TariffsTable/TariffsTableRow.tsx +18 -9
- package/mobile/src/components/TariffsTable/TariffsTableRowContainer.tsx +5 -20
- package/mobile/src/components/TariffsTable/TariffsTableTileCell.tsx +3 -1
- package/mobile/src/model/BlockDecorator.ts +4 -4
- package/mobile/src/model/BlocksRegistry.ts +1 -1
- package/mobile/src/model/ContentPageDef.ts +1 -5
- package/mobile/src/model/JSXBlock.ts +3 -1
- package/mobile/src/model/getParentBlockDef.ts +6 -2
- package/mobile/src/ui-kit/InnerTable/InnerTable.tsx +13 -4
- package/mobile/src/ui-kit/InnerTable/InnerTableButton.tsx +20 -26
- package/mobile/src/ui-kit/InputRange/InputRange.tsx +1 -1
- package/mobile/src/ui-kit/Radio/Radio.tsx +2 -2
- package/mobile/src/ui-kit/Select/Select.tsx +1 -1
- package/package.json +1 -1
- package/src/components/Accordion/Accordion.fixture.mobile.tsx +16 -4
- package/src/components/Blocks.mobile.ts +2 -1
- package/src/components/Blocks.ts +2 -1
- package/src/components/Bonus/Bonus.tsx +1 -1
- package/src/components/ContentPage/ContentPage.page.json +7 -10
- package/src/components/ContentPage/ContentPage.tsx +24 -28
- package/src/components/ContentPage/mapSlot.ts +17 -0
- package/src/components/ContentPage/normalizeBlock.mobile.ts +26 -4
- package/src/components/ContentPage/normalizeBlock.ts +17 -4
- package/src/components/ContentPage/normalizePage.ts +3 -20
- package/src/components/ContentPage/renderBlock.tsx +16 -18
- package/src/components/ContentPage/renderBlockList.tsx +39 -0
- package/src/components/ContentPage/renderSlots.tsx +33 -0
- package/src/components/ProductBlock/renderBackwardButton.tsx +5 -1
- package/src/components/SafeDepositRental/SafeDepositRental.tsx +6 -1
- package/src/components/StepsBlock/StepsBlock.fixture.tsx +72 -81
- package/src/components/StepsBlock/StepsBlock.tsx +3 -3
- package/src/components/StepsBlock/renderItems.tsx +5 -8
- package/src/components/StepsBlock/renderStepContent.tsx +40 -15
- package/src/components/TariffsTable/EmbeddableCellData.tsx +20 -18
- package/src/components/TariffsTable/TariffsTable.tsx +1 -2
- package/src/components/TariffsTable/TariffsTableCell.tsx +39 -45
- package/src/components/TariffsTable/TariffsTableContent.ts +3 -4
- package/src/components/TariffsTable/TariffsTableRenderCell.tsx +88 -0
- package/src/components/TariffsTable/TariffsTableRow.tsx +18 -9
- package/src/components/TariffsTable/TariffsTableRowContainer.tsx +5 -20
- package/src/components/TariffsTable/TariffsTableTileCell.tsx +3 -1
- package/src/model/BlockDecorator.ts +4 -4
- package/src/model/BlocksRegistry.ts +1 -1
- package/src/model/ContentPageDef.ts +1 -5
- package/src/model/JSXBlock.ts +3 -1
- package/src/model/getParentBlockDef.ts +6 -2
- package/src/ui-kit/InnerTable/InnerTable.tsx +13 -4
- package/src/ui-kit/InnerTable/InnerTableButton.tsx +20 -26
- package/src/ui-kit/InputRange/InputRange.tsx +1 -1
- package/src/ui-kit/Radio/Radio.tsx +2 -2
- package/src/ui-kit/Select/Select.tsx +1 -1
- package/bundle/components/ContentPage/filterBlocks.d.ts +0 -12
- package/bundle/components/ContentPage/filterBlocks.mobile.d.ts +0 -12
- package/dist/components/ContentPage/filterBlocks.d.ts +0 -12
- package/dist/components/ContentPage/filterBlocks.js +0 -6
- package/dist/components/ContentPage/filterBlocks.js.map +0 -1
- package/dist/components/ContentPage/filterBlocks.mobile.d.ts +0 -12
- package/dist/components/ContentPage/filterBlocks.mobile.js +0 -8
- package/dist/components/ContentPage/filterBlocks.mobile.js.map +0 -1
- package/lib/components/ContentPage/filterBlocks.d.ts +0 -12
- package/lib/components/ContentPage/filterBlocks.js +0 -3
- package/lib/components/ContentPage/filterBlocks.js.map +0 -1
- package/lib/components/ContentPage/filterBlocks.mobile.d.ts +0 -12
- package/lib/components/ContentPage/filterBlocks.mobile.js +0 -5
- package/lib/components/ContentPage/filterBlocks.mobile.js.map +0 -1
- package/mobile/bundle/components/ContentPage/filterBlocks.d.ts +0 -3
- package/mobile/dist/components/ContentPage/filterBlocks.d.ts +0 -3
- package/mobile/dist/components/ContentPage/filterBlocks.js +0 -8
- package/mobile/dist/components/ContentPage/filterBlocks.js.map +0 -1
- package/mobile/lib/components/ContentPage/filterBlocks.d.ts +0 -3
- package/mobile/lib/components/ContentPage/filterBlocks.js +0 -5
- package/mobile/lib/components/ContentPage/filterBlocks.js.map +0 -1
- package/mobile/src/components/ContentPage/filterBlocks.ts +0 -11
- package/src/components/ContentPage/filterBlocks.mobile.ts +0 -11
- package/src/components/ContentPage/filterBlocks.ts +0 -6
|
@@ -1,9 +1,19 @@
|
|
|
1
1
|
import { context } from '../../react/setup-fixture';
|
|
2
2
|
import { StepsBlock } from './StepsBlock';
|
|
3
|
+
import type { StepsBlockProps } from './StepsBlock';
|
|
3
4
|
import type { Step } from './StepsBlockContent';
|
|
4
5
|
|
|
5
|
-
const
|
|
6
|
-
|
|
6
|
+
const TITLE =
|
|
7
|
+
'Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит';
|
|
8
|
+
|
|
9
|
+
const ITEMS: Step['items'] = ['item1', 'item2', 'item3', 'item4', 'item5'];
|
|
10
|
+
const COMMON_PROPS: StepsBlockProps = {
|
|
11
|
+
className: 'col-span-12',
|
|
12
|
+
context,
|
|
13
|
+
title: TITLE,
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
const STEPS: Step[] = [
|
|
7
17
|
{
|
|
8
18
|
label: 'Заявка на кредит',
|
|
9
19
|
description: 'Оставьте онлайн-заявку на потребительский кредит',
|
|
@@ -22,93 +32,71 @@ const STEPS = [
|
|
|
22
32
|
},
|
|
23
33
|
];
|
|
24
34
|
|
|
25
|
-
const
|
|
35
|
+
const STEPS_WITH_ICONS: Step[] = [
|
|
26
36
|
{
|
|
27
37
|
label: 'В мобильном приложении или интернет-банке',
|
|
28
38
|
description: 'Для всех клиентов Россельхозбанка',
|
|
29
39
|
icon: { icon: 'SignDocsIcon' },
|
|
30
|
-
items: ITEMS,
|
|
31
40
|
},
|
|
32
41
|
{
|
|
33
42
|
label: 'Через Госуслуги',
|
|
34
43
|
description: 'При наличии данных в Единой биометрической системе',
|
|
35
44
|
icon: { icon: 'ClockIcon' },
|
|
36
|
-
items: ITEMS,
|
|
37
45
|
},
|
|
38
46
|
{
|
|
39
47
|
label: 'В офисах Россельхозбанка',
|
|
40
48
|
description: 'Откройте вклад',
|
|
41
49
|
icon: { icon: 'ComfortableCompIcon' },
|
|
42
|
-
items: ITEMS,
|
|
43
50
|
},
|
|
44
51
|
];
|
|
45
52
|
|
|
53
|
+
const BUTTONS: Step['button'][] = [
|
|
54
|
+
{ text: 'Войти в интернет-банк' },
|
|
55
|
+
{ text: 'Оформить' },
|
|
56
|
+
{ text: 'Офисы на карте' },
|
|
57
|
+
];
|
|
58
|
+
|
|
59
|
+
const STEPS_WITH_BUTTONS_AND_ICONS: Step[] = STEPS_WITH_ICONS.map((step, i) => ({
|
|
60
|
+
...step,
|
|
61
|
+
button: BUTTONS[i],
|
|
62
|
+
}));
|
|
63
|
+
|
|
64
|
+
const STEPS_WITH_LIST_PROPS: StepsBlockProps = {
|
|
65
|
+
...COMMON_PROPS,
|
|
66
|
+
steps: STEPS_WITH_ICONS.map((step) => ({ ...step, description: '', items: ITEMS })),
|
|
67
|
+
};
|
|
68
|
+
|
|
69
|
+
const STEPS_WITH_LIST_AND_DESC_PROPS: StepsBlockProps = {
|
|
70
|
+
...COMMON_PROPS,
|
|
71
|
+
steps: STEPS_WITH_ICONS.map((step) => ({ ...step, items: ITEMS })),
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
const STEPS_WITH_BUTTON_PROPS: StepsBlockProps = {
|
|
75
|
+
...COMMON_PROPS,
|
|
76
|
+
steps: STEPS.map((step) => ({
|
|
77
|
+
...step,
|
|
78
|
+
button: { text: 'Оформить' },
|
|
79
|
+
})),
|
|
80
|
+
title: TITLE,
|
|
81
|
+
};
|
|
82
|
+
|
|
46
83
|
export default {
|
|
47
84
|
default: (
|
|
48
85
|
<div className="container grid grid-cols-12">
|
|
49
|
-
<StepsBlock
|
|
50
|
-
className="col-span-12"
|
|
51
|
-
context={context}
|
|
52
|
-
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
53
|
-
steps={STEPS.slice(0, 3)}
|
|
54
|
-
version="secondary"
|
|
55
|
-
/>
|
|
86
|
+
<StepsBlock {...COMMON_PROPS} steps={STEPS.slice(0, 3)} version="secondary" />
|
|
56
87
|
</div>
|
|
57
88
|
),
|
|
58
89
|
'steps-img': (
|
|
59
90
|
<div className="container grid grid-cols-12">
|
|
60
|
-
<StepsBlock
|
|
61
|
-
className="col-span-12"
|
|
62
|
-
context={context}
|
|
63
|
-
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
64
|
-
showLines={false}
|
|
65
|
-
steps={[
|
|
66
|
-
{
|
|
67
|
-
label: 'В мобильном приложении или интернет-банке',
|
|
68
|
-
description: 'Для всех клиентов Россельхозбанка',
|
|
69
|
-
icon: { icon: 'SignDocsIcon' },
|
|
70
|
-
button: { text: 'Войти в интернет-банк' },
|
|
71
|
-
},
|
|
72
|
-
{
|
|
73
|
-
label: 'Через Госуслуги',
|
|
74
|
-
description: 'При наличии данных в Единой биометрической системе',
|
|
75
|
-
icon: { icon: 'ClockIcon' },
|
|
76
|
-
button: { text: 'Оформить' },
|
|
77
|
-
},
|
|
78
|
-
{
|
|
79
|
-
label: 'В офисах Россельхозбанка',
|
|
80
|
-
description: 'Откройте вклад',
|
|
81
|
-
icon: { icon: 'ComfortableCompIcon' },
|
|
82
|
-
button: { text: 'Офисы на карте' },
|
|
83
|
-
},
|
|
84
|
-
]}
|
|
85
|
-
/>
|
|
91
|
+
<StepsBlock {...COMMON_PROPS} showLines={false} steps={STEPS_WITH_BUTTONS_AND_ICONS} />
|
|
86
92
|
</div>
|
|
87
93
|
),
|
|
88
94
|
'steps-with-btn': (
|
|
89
95
|
<div className="container grid grid-cols-12">
|
|
90
96
|
<StepsBlock
|
|
91
|
-
|
|
92
|
-
context={context}
|
|
93
|
-
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
97
|
+
{...COMMON_PROPS}
|
|
94
98
|
showLines={false}
|
|
95
|
-
steps={
|
|
96
|
-
{
|
|
97
|
-
label: 'В мобильном приложении или интернет-банке',
|
|
98
|
-
description: 'Для всех клиентов Россельхозбанка',
|
|
99
|
-
icon: { icon: 'SignDocsIcon' },
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
label: 'Через Госуслуги',
|
|
103
|
-
description: 'При наличии данных в Единой биометрической системе',
|
|
104
|
-
icon: { icon: 'ClockIcon' },
|
|
105
|
-
},
|
|
106
|
-
{
|
|
107
|
-
label: 'В офисах Россельхозбанка',
|
|
108
|
-
description: 'Откройте вклад',
|
|
109
|
-
icon: { icon: 'ComfortableCompIcon' },
|
|
110
|
-
},
|
|
111
|
-
]}
|
|
99
|
+
steps={STEPS_WITH_ICONS}
|
|
112
100
|
button={{
|
|
113
101
|
text: 'Отправить заявку',
|
|
114
102
|
href: 'https://www.rshb.ru/',
|
|
@@ -121,34 +109,37 @@ export default {
|
|
|
121
109
|
),
|
|
122
110
|
'4 steps': (
|
|
123
111
|
<div className="container grid grid-cols-12">
|
|
124
|
-
<StepsBlock
|
|
125
|
-
className="col-span-12"
|
|
126
|
-
context={context}
|
|
127
|
-
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
128
|
-
steps={STEPS}
|
|
129
|
-
/>
|
|
112
|
+
<StepsBlock {...COMMON_PROPS} steps={STEPS} />
|
|
130
113
|
</div>
|
|
131
114
|
),
|
|
132
|
-
|
|
133
|
-
'with list': (
|
|
115
|
+
'with list and description': (
|
|
134
116
|
<div className="container grid grid-cols-12">
|
|
135
|
-
<StepsBlock
|
|
136
|
-
className="col-span-12"
|
|
137
|
-
context={context}
|
|
138
|
-
title="Рассчитайте условия на онлайн-калькуляторе и оставьте заявку на потребительский кредит"
|
|
139
|
-
steps={STEPS_WITH_LIST}
|
|
140
|
-
/>
|
|
117
|
+
<StepsBlock {...STEPS_WITH_LIST_PROPS} version="primary" />
|
|
141
118
|
</div>
|
|
142
119
|
),
|
|
143
|
-
'with list secondary': (
|
|
120
|
+
'with list and description secondary': (
|
|
144
121
|
<div className="container grid grid-cols-12">
|
|
145
|
-
<StepsBlock
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
122
|
+
<StepsBlock {...STEPS_WITH_LIST_AND_DESC_PROPS} version="secondary" />
|
|
123
|
+
</div>
|
|
124
|
+
),
|
|
125
|
+
'with list, no description': (
|
|
126
|
+
<div className="container grid grid-cols-12">
|
|
127
|
+
<StepsBlock {...STEPS_WITH_LIST_AND_DESC_PROPS} version="primary" />
|
|
128
|
+
</div>
|
|
129
|
+
),
|
|
130
|
+
'with list, no description secondary': (
|
|
131
|
+
<div className="container grid grid-cols-12">
|
|
132
|
+
<StepsBlock {...STEPS_WITH_LIST_PROPS} version="secondary" />
|
|
133
|
+
</div>
|
|
134
|
+
),
|
|
135
|
+
'with button primary': (
|
|
136
|
+
<div className="container grid grid-cols-12">
|
|
137
|
+
<StepsBlock {...STEPS_WITH_BUTTON_PROPS} version="primary" />
|
|
138
|
+
</div>
|
|
139
|
+
),
|
|
140
|
+
'with button secondary': (
|
|
141
|
+
<div className="container grid grid-cols-12">
|
|
142
|
+
<StepsBlock {...STEPS_WITH_BUTTON_PROPS} version="secondary" />
|
|
152
143
|
</div>
|
|
153
144
|
),
|
|
154
145
|
};
|
|
@@ -41,9 +41,9 @@ export const StepsBlock = JSX<StepsBlockProps>(
|
|
|
41
41
|
return (
|
|
42
42
|
<BlockWrapper
|
|
43
43
|
className={[
|
|
44
|
-
'box-border font-sans
|
|
44
|
+
'box-border py-[50px] font-sans',
|
|
45
45
|
shortGaps ? 'px-20' : 'px-[70px]',
|
|
46
|
-
'
|
|
46
|
+
'flex flex-col items-center',
|
|
47
47
|
styleMap.background,
|
|
48
48
|
styleMap.title,
|
|
49
49
|
className,
|
|
@@ -61,7 +61,7 @@ export const StepsBlock = JSX<StepsBlockProps>(
|
|
|
61
61
|
steps.map(renderStepIcon(styleMap)),
|
|
62
62
|
)}
|
|
63
63
|
</div>
|
|
64
|
-
<div className={`flex justify-between ${shortGaps ? 'gap-x-3' : 'gap-x-[101px]'}`}>
|
|
64
|
+
<div className={`flex justify-between mt-4 ${shortGaps ? 'gap-x-3' : 'gap-x-[101px]'}`}>
|
|
65
65
|
{steps.map(
|
|
66
66
|
renderStepContent({
|
|
67
67
|
styleMap,
|
|
@@ -11,16 +11,13 @@ export const renderItems = ({
|
|
|
11
11
|
isDotted?: boolean;
|
|
12
12
|
version?: BlockVersion;
|
|
13
13
|
className?: string;
|
|
14
|
-
}) =>
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
return items ? (
|
|
14
|
+
}) =>
|
|
15
|
+
items ? (
|
|
18
16
|
<List
|
|
19
|
-
className={
|
|
20
|
-
version={
|
|
17
|
+
className={className}
|
|
18
|
+
version={version}
|
|
21
19
|
items={items}
|
|
22
|
-
listItemSize="
|
|
20
|
+
listItemSize="M"
|
|
23
21
|
isDotted={isDotted}
|
|
24
22
|
/>
|
|
25
23
|
) : null;
|
|
26
|
-
};
|
|
@@ -3,6 +3,7 @@ import type { BlockVersion } from '../../model/BlockVersion';
|
|
|
3
3
|
import type { HandlerDecorator, Router } from '../ContentPage/ContentPageContext';
|
|
4
4
|
import type { Step } from './StepsBlockContent';
|
|
5
5
|
import type { StyleType } from './StepsBlockStyleMaps';
|
|
6
|
+
import type { VNode } from '../../model/VNode';
|
|
6
7
|
import { renderItems } from './renderItems';
|
|
7
8
|
import { useLink } from '../../hooks/useLink';
|
|
8
9
|
|
|
@@ -20,39 +21,48 @@ export const renderStepContent =
|
|
|
20
21
|
router: Router;
|
|
21
22
|
handlerDecorator?: HandlerDecorator;
|
|
22
23
|
}) =>
|
|
23
|
-
(step: Step, i: number, { length }: { length: number }) => {
|
|
24
|
+
(step: Step, i: number, { length }: { length: number }): VNode => {
|
|
24
25
|
const { label, description, button, items, isDotted } = step;
|
|
25
26
|
|
|
26
|
-
const
|
|
27
|
-
const widthContainer = length < 5 ? 'w-[276px]' : 'w-[210px]';
|
|
27
|
+
const contentMarginClass = label && (description || items) ? 'mt-2' : '';
|
|
28
28
|
|
|
29
29
|
return (
|
|
30
30
|
<div
|
|
31
31
|
key={String(i)}
|
|
32
|
-
className={`flex flex-col items-center text-center
|
|
33
|
-
|
|
32
|
+
className={`relative flex flex-col items-center text-center whitespace-pre-line overflow-hidden ${getContainerWidth(
|
|
33
|
+
length,
|
|
34
|
+
)}`}
|
|
34
35
|
>
|
|
35
|
-
{
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
36
|
+
<div className={`${button?.text ? 'mb-8' : ''} text-center`}>
|
|
37
|
+
{renderStepLabel(label)}
|
|
38
|
+
<div className={`${contentMarginClass} flex flex-col items-center`}>
|
|
39
|
+
{renderStepDescription({
|
|
40
|
+
description,
|
|
41
|
+
className: styleMap.description,
|
|
42
|
+
})}
|
|
43
|
+
{renderItems({
|
|
44
|
+
items,
|
|
45
|
+
isDotted,
|
|
46
|
+
version,
|
|
47
|
+
className: getItemsClasses({ className: 'text-left', description, styleMap }),
|
|
48
|
+
})}
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
41
51
|
{button?.text && !isMainButton ? (
|
|
42
52
|
<Button
|
|
43
53
|
className="box-border py-3 h-12 w-full max-w-[240px] mt-auto"
|
|
44
54
|
{...useLink({ router, handlerDecorator }, button)}
|
|
45
55
|
version={version}
|
|
46
56
|
>
|
|
47
|
-
{button
|
|
57
|
+
{button?.text}
|
|
48
58
|
</Button>
|
|
49
59
|
) : null}
|
|
50
60
|
</div>
|
|
51
61
|
);
|
|
52
62
|
};
|
|
53
63
|
|
|
54
|
-
const renderStepLabel = (label?: string) =>
|
|
55
|
-
label ? <div className="text-
|
|
64
|
+
const renderStepLabel = (label?: string): VNode =>
|
|
65
|
+
label ? <div className="text-h6">{label}</div> : null;
|
|
56
66
|
|
|
57
67
|
const renderStepDescription = ({
|
|
58
68
|
description,
|
|
@@ -60,4 +70,19 @@ const renderStepDescription = ({
|
|
|
60
70
|
}: {
|
|
61
71
|
description?: string;
|
|
62
72
|
className?: string;
|
|
63
|
-
}) => (description ? <div className={className}>{description}</div> : null);
|
|
73
|
+
}): VNode => (description ? <div className={className}>{description}</div> : null);
|
|
74
|
+
|
|
75
|
+
const getItemsClasses = ({
|
|
76
|
+
className,
|
|
77
|
+
description,
|
|
78
|
+
styleMap,
|
|
79
|
+
}: {
|
|
80
|
+
className?: string;
|
|
81
|
+
description?: string;
|
|
82
|
+
styleMap: StyleType;
|
|
83
|
+
}): string =>
|
|
84
|
+
[description ? styleMap.description : 'text-h6', description ? 'mt-0.5' : '', className].join(
|
|
85
|
+
' ',
|
|
86
|
+
);
|
|
87
|
+
|
|
88
|
+
const getContainerWidth = (length: number): string => (length < 5 ? 'w-[276px]' : 'w-[210px]');
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
|
-
import { useEffect, useState } from '@redneckz/uni-jsx/lib/hooks';
|
|
3
|
-
import { EventBus } from '../../EventBus/EventBus';
|
|
4
2
|
import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
|
|
5
3
|
import { renderButton } from '../../ui-kit/Button/ButtonSection';
|
|
6
4
|
import { Img } from '../../ui-kit/Img/Img';
|
|
7
5
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
8
6
|
import { TableInnerButton, TableInnerButtonProps } from '../../ui-kit/InnerTable/InnerTableButton';
|
|
9
|
-
import {
|
|
7
|
+
import type { TariffsTableInnerContent } from '../../ui-kit/InnerTable/InnerTableProps';
|
|
10
8
|
import { List } from '../../ui-kit/List/List';
|
|
11
9
|
import type { ListProps } from '../../ui-kit/List/ListProps';
|
|
12
|
-
import type { LabelDescriptionCell
|
|
10
|
+
import type { LabelDescriptionCell } from './TariffsTableContent';
|
|
13
11
|
|
|
14
12
|
export type EmbeddableCellDataType =
|
|
15
13
|
| LabelDescriptionCell
|
|
@@ -18,6 +16,11 @@ export type EmbeddableCellDataType =
|
|
|
18
16
|
| ListProps
|
|
19
17
|
| TableInnerButtonProps;
|
|
20
18
|
|
|
19
|
+
interface TableCellDataProps extends TableInnerButtonProps {
|
|
20
|
+
isVisible?: boolean;
|
|
21
|
+
displayTable: (props: TariffsTableInnerContent) => void;
|
|
22
|
+
}
|
|
23
|
+
|
|
21
24
|
const renderButtonsCellData = ({ buttons }: ButtonContent) =>
|
|
22
25
|
buttons && buttons?.length ? (
|
|
23
26
|
<div>
|
|
@@ -52,20 +55,19 @@ const renderListCellData = ({ isDotted, ...rest }: ListProps) => (
|
|
|
52
55
|
/>
|
|
53
56
|
);
|
|
54
57
|
|
|
55
|
-
const renderTableCellData = JSX(
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
});
|
|
58
|
+
const renderTableCellData = JSX<TableCellDataProps>(
|
|
59
|
+
({ isVisible, displayTable, dataUrl, pdfUrl, isOpen, context }) => {
|
|
60
|
+
return isVisible ? (
|
|
61
|
+
<TableInnerButton
|
|
62
|
+
isOpen={isOpen}
|
|
63
|
+
context={context}
|
|
64
|
+
onClick={() => {
|
|
65
|
+
displayTable({ dataUrl, pdfUrl });
|
|
66
|
+
}}
|
|
67
|
+
/>
|
|
68
|
+
) : null;
|
|
69
|
+
},
|
|
70
|
+
);
|
|
69
71
|
|
|
70
72
|
export const EmbeddableCellData = {
|
|
71
73
|
Buttons: renderButtonsCellData,
|
|
@@ -43,12 +43,11 @@ export const TariffsTable = JSX<TariffsTableProps>(
|
|
|
43
43
|
setActiveCardIndex,
|
|
44
44
|
});
|
|
45
45
|
|
|
46
|
-
const rows = (rowData || []).map((row, i
|
|
46
|
+
const rows = (rowData || []).map((row, i) => (
|
|
47
47
|
<TariffsTableRow
|
|
48
48
|
context={context}
|
|
49
49
|
key={String(i)}
|
|
50
50
|
row={row}
|
|
51
|
-
isLastRow={i + 1 === length}
|
|
52
51
|
activeCardIndex={activeCardIndex}
|
|
53
52
|
rowIdx={i}
|
|
54
53
|
/>
|
|
@@ -1,59 +1,53 @@
|
|
|
1
1
|
import { JSX } from '@redneckz/uni-jsx';
|
|
2
2
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
3
|
-
import type {
|
|
4
|
-
import { EmbeddableCellData } from './EmbeddableCellData';
|
|
5
|
-
import type { CellDef, TariffsTableCellIndexProps } from './TariffsTableContent';
|
|
3
|
+
import type { TariffsTableInnerContent } from '../../ui-kit/InnerTable/InnerTableProps';
|
|
6
4
|
|
|
7
|
-
|
|
5
|
+
import type { CellDef } from './TariffsTableContent';
|
|
6
|
+
import { renderCellInner } from './TariffsTableRenderCell';
|
|
7
|
+
|
|
8
|
+
export interface TariffTableContentProps {
|
|
9
|
+
openTableInnerIdx?: number;
|
|
10
|
+
setOpenTableInnerIdx: (props?: number) => void;
|
|
11
|
+
setTableInner: (props?: TariffsTableInnerContent) => void;
|
|
12
|
+
tableInner?: TariffsTableInnerContent;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export interface TariffsTableCellProps extends TariffTableContentProps, UniBlockProps {
|
|
8
16
|
rowIdx: number;
|
|
9
17
|
cellIdx: number;
|
|
10
18
|
cells: CellDef[];
|
|
11
|
-
isLastRow: boolean;
|
|
12
19
|
}
|
|
13
20
|
|
|
14
21
|
export const TariffsTableCell = JSX<TariffsTableCellProps>(
|
|
15
|
-
({
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
},
|
|
26
|
-
);
|
|
27
|
-
|
|
28
|
-
const renderCellInner =
|
|
29
|
-
(rowIdx: number, context: ContentPageContext, cellIdx: number) => (cell: CellDef, i: number) => {
|
|
22
|
+
({
|
|
23
|
+
context,
|
|
24
|
+
cells,
|
|
25
|
+
rowIdx,
|
|
26
|
+
cellIdx,
|
|
27
|
+
setTableInner,
|
|
28
|
+
tableInner,
|
|
29
|
+
openTableInnerIdx,
|
|
30
|
+
setOpenTableInnerIdx,
|
|
31
|
+
}) => {
|
|
30
32
|
return (
|
|
31
33
|
<div
|
|
32
|
-
|
|
33
|
-
|
|
34
|
+
className="first:pl-0 w-80 flex-grow flex flex-col border-solid border-main-divider border border-t-0 border-x-0"
|
|
35
|
+
role="cell"
|
|
34
36
|
>
|
|
35
|
-
{
|
|
36
|
-
|
|
37
|
+
{cells?.length
|
|
38
|
+
? cells.map(
|
|
39
|
+
renderCellInner({
|
|
40
|
+
rowIdx,
|
|
41
|
+
context,
|
|
42
|
+
cellIdx,
|
|
43
|
+
setTableInner,
|
|
44
|
+
tableInner,
|
|
45
|
+
openTableInnerIdx,
|
|
46
|
+
setOpenTableInnerIdx,
|
|
47
|
+
}),
|
|
48
|
+
)
|
|
49
|
+
: null}
|
|
37
50
|
</div>
|
|
38
51
|
);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
const renderCell = (
|
|
42
|
-
cell: CellDef,
|
|
43
|
-
context: ContentPageContext,
|
|
44
|
-
indexes: TariffsTableCellIndexProps,
|
|
45
|
-
) => {
|
|
46
|
-
if (!cell) {
|
|
47
|
-
return null;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
const { tableCellType: type, ...rest } = cell;
|
|
51
|
-
|
|
52
|
-
if (!type || !(type in EmbeddableCellData)) {
|
|
53
|
-
return null;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
const EmbeddableCellInner = EmbeddableCellData[type];
|
|
57
|
-
|
|
58
|
-
return <EmbeddableCellInner context={context} {...rest} {...indexes} />;
|
|
59
|
-
};
|
|
52
|
+
},
|
|
53
|
+
);
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import type { EmptyOption } from '../../model/EmptyOptionType';
|
|
2
|
-
import type { DescriptionProps, LabelProps } from '../../model/HeadlineType';
|
|
2
|
+
import type { DescriptionProps, LabelProps, TitleProps } from '../../model/HeadlineType';
|
|
3
3
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
4
4
|
import type { ListOrientation } from '../../model/ListOrientation';
|
|
5
5
|
import type { Picture } from '../../model/Picture';
|
|
6
6
|
import type { ButtonContent } from '../../ui-kit/Button/ButtonProps';
|
|
7
|
-
import type { HeadingProps } from '../../ui-kit/Heading/HeadingProps';
|
|
8
7
|
import type { TariffsTableInnerContent } from '../../ui-kit/InnerTable/InnerTableProps';
|
|
9
8
|
import type { ListProps } from '../../ui-kit/List/ListProps';
|
|
10
9
|
|
|
@@ -43,7 +42,7 @@ export type Data = {
|
|
|
43
42
|
/**
|
|
44
43
|
* @title Параметр
|
|
45
44
|
*/
|
|
46
|
-
export type TariffsTableRowHeader =
|
|
45
|
+
export type TariffsTableRowHeader = TitleProps & {
|
|
47
46
|
/** @default { "format": "webp", "size": { "width": 24, "height": 24 } } */
|
|
48
47
|
icon?: Picture;
|
|
49
48
|
};
|
|
@@ -117,7 +116,7 @@ export interface TariffsTableColumn {
|
|
|
117
116
|
/**
|
|
118
117
|
* @title Таблица тарифов
|
|
119
118
|
*/
|
|
120
|
-
export type TariffsTableContent =
|
|
119
|
+
export type TariffsTableContent = TitleProps &
|
|
121
120
|
DescriptionProps & {
|
|
122
121
|
/** @title Колонки */
|
|
123
122
|
tariffsColumns?: TariffsTableColumn[];
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { useEffect, useState } from '@redneckz/uni-jsx/lib/hooks';
|
|
2
|
+
import type { TariffsTableInnerContent } from '../../ui-kit/InnerTable/InnerTableProps';
|
|
3
|
+
import type { ContentPageContext } from '../ContentPage/ContentPageContext';
|
|
4
|
+
import { EmbeddableCellData } from './EmbeddableCellData';
|
|
5
|
+
import type { TariffTableContentProps } from './TariffsTableCell';
|
|
6
|
+
import type { CellDef } from './TariffsTableContent';
|
|
7
|
+
|
|
8
|
+
interface TariffTableCellInnerProps extends TariffTableContentProps {
|
|
9
|
+
cellIdx: number;
|
|
10
|
+
context: ContentPageContext;
|
|
11
|
+
rowIdx: number;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
interface RenderCellProps {
|
|
15
|
+
cell: CellDef;
|
|
16
|
+
cellProps: CellProps;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
interface CellProps {
|
|
20
|
+
isVisible?: boolean;
|
|
21
|
+
cellIdx: number;
|
|
22
|
+
context: ContentPageContext;
|
|
23
|
+
rowIdx: number;
|
|
24
|
+
fieldIdx: number;
|
|
25
|
+
displayTable: (props: TariffsTableInnerContent) => void;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export const renderCellInner =
|
|
29
|
+
({
|
|
30
|
+
rowIdx,
|
|
31
|
+
context,
|
|
32
|
+
cellIdx,
|
|
33
|
+
setTableInner,
|
|
34
|
+
tableInner,
|
|
35
|
+
openTableInnerIdx,
|
|
36
|
+
setOpenTableInnerIdx,
|
|
37
|
+
}: TariffTableCellInnerProps) =>
|
|
38
|
+
(cell: CellDef, i: number) => {
|
|
39
|
+
const [isVisible, setVisibility] = useState(true);
|
|
40
|
+
|
|
41
|
+
useEffect(() => {
|
|
42
|
+
if (cellIdx !== openTableInnerIdx || !tableInner) {
|
|
43
|
+
setVisibility(true);
|
|
44
|
+
}
|
|
45
|
+
}, [tableInner, openTableInnerIdx]);
|
|
46
|
+
|
|
47
|
+
const displayTable = (props: TariffsTableInnerContent) => {
|
|
48
|
+
setVisibility(false);
|
|
49
|
+
setOpenTableInnerIdx(cellIdx);
|
|
50
|
+
setTableInner(props);
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
return (
|
|
54
|
+
<div
|
|
55
|
+
key={String(i)}
|
|
56
|
+
className={cell?.tableCellType === 'Table' ? 'ml-10' : `first:pt-5 last:pb-5 pl-10`}
|
|
57
|
+
>
|
|
58
|
+
{i > 0 ? <div className="h-5" /> : null}
|
|
59
|
+
{renderCell({
|
|
60
|
+
cell,
|
|
61
|
+
cellProps: {
|
|
62
|
+
rowIdx,
|
|
63
|
+
cellIdx,
|
|
64
|
+
fieldIdx: i,
|
|
65
|
+
displayTable,
|
|
66
|
+
isVisible,
|
|
67
|
+
context,
|
|
68
|
+
},
|
|
69
|
+
})}
|
|
70
|
+
</div>
|
|
71
|
+
);
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
const renderCell = ({ cell, cellProps }: RenderCellProps) => {
|
|
75
|
+
if (!cell) {
|
|
76
|
+
return null;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
const { tableCellType: type, ...rest } = cell;
|
|
80
|
+
|
|
81
|
+
if (!type || !(type in EmbeddableCellData)) {
|
|
82
|
+
return null;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
const EmbeddableCellInner = EmbeddableCellData[type];
|
|
86
|
+
|
|
87
|
+
return <EmbeddableCellInner {...cellProps} {...rest} />;
|
|
88
|
+
};
|