@redneckz/wildless-cms-uni-blocks 0.14.996 → 0.14.998
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/api/getSubmitBody.d.ts +1636 -244
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +408 -12
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/bundle/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/bundle/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/bundle/components/CalculatorRko/constants.d.ts +25 -0
- package/bundle/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/bundle/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/bundle/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/bundle/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/bundle/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/bundle/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/bundle/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/bundle/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/bundle/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/bundle/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/bundle/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/bundle/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/bundle/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/bundle/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/bundle/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/bundle/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/bundle/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/bundle/model/FormTypeFieldDef.d.ts +1 -1
- package/bundle/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/bundle/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/bundle/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/bundle/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/bundle/ui-kit/Text/Text.d.ts +2 -1
- package/dist/api/getSubmitBody.d.ts +1636 -244
- package/dist/api/getSubmitBody.js +6 -0
- package/dist/api/getSubmitBody.js.map +1 -1
- package/dist/components/Blocks.js +4 -0
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Blocks.mobile.js +4 -0
- package/dist/components/Blocks.mobile.js.map +1 -1
- package/dist/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/dist/components/CalculatorDeposit/normalize.js +1 -8
- package/dist/components/CalculatorDeposit/normalize.js.map +1 -1
- package/dist/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/dist/components/CalculatorRko/CalculatorRko.js +75 -0
- package/dist/components/CalculatorRko/CalculatorRko.js.map +1 -0
- package/dist/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/dist/components/CalculatorRko/CalculatorRkoContent.js +2 -0
- package/dist/components/CalculatorRko/CalculatorRkoContent.js.map +1 -0
- package/dist/components/CalculatorRko/constants.d.ts +25 -0
- package/dist/components/CalculatorRko/constants.js +54 -0
- package/dist/components/CalculatorRko/constants.js.map +1 -0
- package/dist/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/dist/components/CalculatorRko/filterByClientType.js +27 -0
- package/dist/components/CalculatorRko/filterByClientType.js.map +1 -0
- package/dist/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/dist/components/CalculatorRko/getCalculatedCommission.js +106 -0
- package/dist/components/CalculatorRko/getCalculatedCommission.js.map +1 -0
- package/dist/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/dist/components/CalculatorRko/getInitialRkoTariffsParams.js +15 -0
- package/dist/components/CalculatorRko/getInitialRkoTariffsParams.js.map +1 -0
- package/dist/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/dist/components/CalculatorRko/getRkoCalculatorParams.js +23 -0
- package/dist/components/CalculatorRko/getRkoCalculatorParams.js.map +1 -0
- package/dist/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/dist/components/CalculatorRko/markBestTariff.js +15 -0
- package/dist/components/CalculatorRko/markBestTariff.js.map +1 -0
- package/dist/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/dist/components/CalculatorRko/mergeTariffData.js +26 -0
- package/dist/components/CalculatorRko/mergeTariffData.js.map +1 -0
- package/dist/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/dist/components/CalculatorRko/renderCommissionSum.js +8 -0
- package/dist/components/CalculatorRko/renderCommissionSum.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCard.js +41 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCard.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.js +22 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js +2 -0
- package/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/dist/components/RkoTariffCardsTable/constants.js +20 -0
- package/dist/components/RkoTariffCardsTable/constants.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/dist/components/RkoTariffCardsTable/getCommissionTypes.js +11 -0
- package/dist/components/RkoTariffCardsTable/getCommissionTypes.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/dist/components/RkoTariffCardsTable/renderDesktopCard.js +7 -0
- package/dist/components/RkoTariffCardsTable/renderDesktopCard.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/dist/components/RkoTariffCardsTable/renderHiddenCommission.js +9 -0
- package/dist/components/RkoTariffCardsTable/renderHiddenCommission.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/dist/components/RkoTariffCardsTable/renderMobileCard.js +22 -0
- package/dist/components/RkoTariffCardsTable/renderMobileCard.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/dist/components/RkoTariffCardsTable/renderRecommendedLabel.js +9 -0
- package/dist/components/RkoTariffCardsTable/renderRecommendedLabel.js.map +1 -0
- package/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js +11 -0
- package/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js.map +1 -0
- package/dist/model/FormTypeFieldDef.d.ts +1 -1
- package/dist/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/dist/ui-kit/Button/ButtonTitle.js +1 -1
- package/dist/ui-kit/Button/ButtonTitle.js.map +1 -1
- package/dist/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/dist/ui-kit/Calculator/CalculatorStyle.js +2 -0
- package/dist/ui-kit/Calculator/CalculatorStyle.js.map +1 -1
- package/dist/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/dist/ui-kit/Calculator/renderCountInput.js +8 -0
- package/dist/ui-kit/Calculator/renderCountInput.js.map +1 -0
- package/dist/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/dist/ui-kit/Foldable/DefaultFoldButton.js +4 -1
- package/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/dist/ui-kit/Text/Text.d.ts +2 -1
- package/dist/ui-kit/Text/Text.js +1 -1
- package/dist/ui-kit/Text/Text.js.map +1 -1
- package/lib/api/getSubmitBody.d.ts +1636 -244
- package/lib/api/getSubmitBody.js +6 -0
- package/lib/api/getSubmitBody.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/ApplicationForm/ApplicationForm.fixture.d.ts +1 -0
- package/lib/components/Blocks.js +4 -0
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Blocks.mobile.js +4 -0
- package/lib/components/Blocks.mobile.js.map +1 -1
- package/lib/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/lib/components/CalculatorDeposit/normalize.js +0 -6
- package/lib/components/CalculatorDeposit/normalize.js.map +1 -1
- package/lib/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/lib/components/CalculatorRko/CalculatorRko.fixture.d.ts +6 -0
- package/lib/components/CalculatorRko/CalculatorRko.fixture.mobile.d.ts +6 -0
- package/lib/components/CalculatorRko/CalculatorRko.js +73 -0
- package/lib/components/CalculatorRko/CalculatorRko.js.map +1 -0
- package/lib/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/lib/components/CalculatorRko/CalculatorRkoContent.js +2 -0
- package/lib/components/CalculatorRko/CalculatorRkoContent.js.map +1 -0
- package/lib/components/CalculatorRko/constants.d.ts +25 -0
- package/lib/components/CalculatorRko/constants.js +52 -0
- package/lib/components/CalculatorRko/constants.js.map +1 -0
- package/lib/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/lib/components/CalculatorRko/filterByClientType.js +24 -0
- package/lib/components/CalculatorRko/filterByClientType.js.map +1 -0
- package/lib/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/lib/components/CalculatorRko/getCalculatedCommission.js +103 -0
- package/lib/components/CalculatorRko/getCalculatedCommission.js.map +1 -0
- package/lib/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/lib/components/CalculatorRko/getInitialRkoTariffsParams.js +12 -0
- package/lib/components/CalculatorRko/getInitialRkoTariffsParams.js.map +1 -0
- package/lib/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/lib/components/CalculatorRko/getRkoCalculatorParams.js +20 -0
- package/lib/components/CalculatorRko/getRkoCalculatorParams.js.map +1 -0
- package/lib/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/lib/components/CalculatorRko/markBestTariff.js +12 -0
- package/lib/components/CalculatorRko/markBestTariff.js.map +1 -0
- package/lib/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/lib/components/CalculatorRko/mergeTariffData.js +23 -0
- package/lib/components/CalculatorRko/mergeTariffData.js.map +1 -0
- package/lib/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/lib/components/CalculatorRko/renderCommissionSum.js +5 -0
- package/lib/components/CalculatorRko/renderCommissionSum.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCard.js +39 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCard.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.fixture.d.ts +4 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.fixture.mobile.d.ts +4 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.js +20 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js +2 -0
- package/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/lib/components/RkoTariffCardsTable/constants.js +18 -0
- package/lib/components/RkoTariffCardsTable/constants.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/lib/components/RkoTariffCardsTable/getCommissionTypes.js +8 -0
- package/lib/components/RkoTariffCardsTable/getCommissionTypes.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/lib/components/RkoTariffCardsTable/renderDesktopCard.js +4 -0
- package/lib/components/RkoTariffCardsTable/renderDesktopCard.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/lib/components/RkoTariffCardsTable/renderHiddenCommission.js +6 -0
- package/lib/components/RkoTariffCardsTable/renderHiddenCommission.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/lib/components/RkoTariffCardsTable/renderMobileCard.js +19 -0
- package/lib/components/RkoTariffCardsTable/renderMobileCard.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/lib/components/RkoTariffCardsTable/renderRecommendedLabel.js +6 -0
- package/lib/components/RkoTariffCardsTable/renderRecommendedLabel.js.map +1 -0
- package/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js +8 -0
- package/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js.map +1 -0
- package/lib/model/FormTypeFieldDef.d.ts +1 -1
- package/lib/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/lib/ui-kit/Button/ButtonTitle.js +1 -1
- package/lib/ui-kit/Button/ButtonTitle.js.map +1 -1
- package/lib/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/lib/ui-kit/Calculator/CalculatorStyle.js +2 -0
- package/lib/ui-kit/Calculator/CalculatorStyle.js.map +1 -1
- package/lib/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/lib/ui-kit/Calculator/renderCountInput.js +5 -0
- package/lib/ui-kit/Calculator/renderCountInput.js.map +1 -0
- package/lib/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/lib/ui-kit/Foldable/DefaultFoldButton.js +4 -1
- package/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/lib/ui-kit/Text/Text.d.ts +2 -1
- package/lib/ui-kit/Text/Text.js +1 -1
- package/lib/ui-kit/Text/Text.js.map +1 -1
- package/mobile/bundle/api/getSubmitBody.d.ts +1636 -244
- package/mobile/bundle/bundle.umd.js +408 -12
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/mobile/bundle/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/mobile/bundle/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/mobile/bundle/components/CalculatorRko/constants.d.ts +25 -0
- package/mobile/bundle/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/mobile/bundle/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/mobile/bundle/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/mobile/bundle/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/mobile/bundle/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/mobile/bundle/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/mobile/bundle/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/mobile/bundle/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/mobile/bundle/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/mobile/bundle/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/mobile/bundle/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/mobile/bundle/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/mobile/bundle/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/mobile/bundle/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/mobile/bundle/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/mobile/bundle/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/mobile/bundle/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/mobile/bundle/model/FormTypeFieldDef.d.ts +1 -1
- package/mobile/bundle/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/mobile/bundle/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/mobile/bundle/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/mobile/bundle/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/mobile/bundle/ui-kit/Text/Text.d.ts +2 -1
- package/mobile/dist/api/getSubmitBody.d.ts +1636 -244
- package/mobile/dist/api/getSubmitBody.js +6 -0
- package/mobile/dist/api/getSubmitBody.js.map +1 -1
- package/mobile/dist/components/Blocks.js +4 -0
- package/mobile/dist/components/Blocks.js.map +1 -1
- package/mobile/dist/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/mobile/dist/components/CalculatorDeposit/normalize.js +1 -8
- package/mobile/dist/components/CalculatorDeposit/normalize.js.map +1 -1
- package/mobile/dist/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/mobile/dist/components/CalculatorRko/CalculatorRko.js +75 -0
- package/mobile/dist/components/CalculatorRko/CalculatorRko.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/mobile/dist/components/CalculatorRko/CalculatorRkoContent.js +2 -0
- package/mobile/dist/components/CalculatorRko/CalculatorRkoContent.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/constants.d.ts +25 -0
- package/mobile/dist/components/CalculatorRko/constants.js +54 -0
- package/mobile/dist/components/CalculatorRko/constants.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/mobile/dist/components/CalculatorRko/filterByClientType.js +27 -0
- package/mobile/dist/components/CalculatorRko/filterByClientType.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/mobile/dist/components/CalculatorRko/getCalculatedCommission.js +106 -0
- package/mobile/dist/components/CalculatorRko/getCalculatedCommission.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/mobile/dist/components/CalculatorRko/getInitialRkoTariffsParams.js +15 -0
- package/mobile/dist/components/CalculatorRko/getInitialRkoTariffsParams.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/mobile/dist/components/CalculatorRko/getRkoCalculatorParams.js +23 -0
- package/mobile/dist/components/CalculatorRko/getRkoCalculatorParams.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/mobile/dist/components/CalculatorRko/markBestTariff.js +15 -0
- package/mobile/dist/components/CalculatorRko/markBestTariff.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/mobile/dist/components/CalculatorRko/mergeTariffData.js +26 -0
- package/mobile/dist/components/CalculatorRko/mergeTariffData.js.map +1 -0
- package/mobile/dist/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/mobile/dist/components/CalculatorRko/renderCommissionSum.js +8 -0
- package/mobile/dist/components/CalculatorRko/renderCommissionSum.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCard.js +41 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCard.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.js +22 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTable.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js +2 -0
- package/mobile/dist/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/mobile/dist/components/RkoTariffCardsTable/constants.js +20 -0
- package/mobile/dist/components/RkoTariffCardsTable/constants.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/mobile/dist/components/RkoTariffCardsTable/getCommissionTypes.js +11 -0
- package/mobile/dist/components/RkoTariffCardsTable/getCommissionTypes.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderDesktopCard.js +7 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderDesktopCard.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderHiddenCommission.js +9 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderHiddenCommission.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderMobileCard.js +22 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderMobileCard.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRecommendedLabel.js +9 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRecommendedLabel.js.map +1 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js +11 -0
- package/mobile/dist/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js.map +1 -0
- package/mobile/dist/model/FormTypeFieldDef.d.ts +1 -1
- package/mobile/dist/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/mobile/dist/ui-kit/Button/ButtonTitle.js +1 -1
- package/mobile/dist/ui-kit/Button/ButtonTitle.js.map +1 -1
- package/mobile/dist/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/mobile/dist/ui-kit/Calculator/CalculatorStyle.js +2 -0
- package/mobile/dist/ui-kit/Calculator/CalculatorStyle.js.map +1 -1
- package/mobile/dist/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/mobile/dist/ui-kit/Calculator/renderCountInput.js +8 -0
- package/mobile/dist/ui-kit/Calculator/renderCountInput.js.map +1 -0
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js +4 -1
- package/mobile/dist/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/mobile/dist/ui-kit/Text/Text.d.ts +2 -1
- package/mobile/dist/ui-kit/Text/Text.js +1 -1
- package/mobile/dist/ui-kit/Text/Text.js.map +1 -1
- package/mobile/lib/api/getSubmitBody.d.ts +1636 -244
- package/mobile/lib/api/getSubmitBody.js +6 -0
- package/mobile/lib/api/getSubmitBody.js.map +1 -1
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/Blocks.js +4 -0
- package/mobile/lib/components/Blocks.js.map +1 -1
- package/mobile/lib/components/CalculatorDeposit/normalize.d.ts +0 -3
- package/mobile/lib/components/CalculatorDeposit/normalize.js +0 -6
- package/mobile/lib/components/CalculatorDeposit/normalize.js.map +1 -1
- package/mobile/lib/components/CalculatorRko/CalculatorRko.d.ts +5 -0
- package/mobile/lib/components/CalculatorRko/CalculatorRko.js +73 -0
- package/mobile/lib/components/CalculatorRko/CalculatorRko.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/CalculatorRkoContent.d.ts +74 -0
- package/mobile/lib/components/CalculatorRko/CalculatorRkoContent.js +2 -0
- package/mobile/lib/components/CalculatorRko/CalculatorRkoContent.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/constants.d.ts +25 -0
- package/mobile/lib/components/CalculatorRko/constants.js +52 -0
- package/mobile/lib/components/CalculatorRko/constants.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/filterByClientType.d.ts +1 -0
- package/mobile/lib/components/CalculatorRko/filterByClientType.js +24 -0
- package/mobile/lib/components/CalculatorRko/filterByClientType.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/getCalculatedCommission.d.ts +9 -0
- package/mobile/lib/components/CalculatorRko/getCalculatedCommission.js +103 -0
- package/mobile/lib/components/CalculatorRko/getCalculatedCommission.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/getInitialRkoTariffsParams.d.ts +3 -0
- package/mobile/lib/components/CalculatorRko/getInitialRkoTariffsParams.js +12 -0
- package/mobile/lib/components/CalculatorRko/getInitialRkoTariffsParams.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/getRkoCalculatorParams.d.ts +2 -0
- package/mobile/lib/components/CalculatorRko/getRkoCalculatorParams.js +20 -0
- package/mobile/lib/components/CalculatorRko/getRkoCalculatorParams.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/markBestTariff.d.ts +5 -0
- package/mobile/lib/components/CalculatorRko/markBestTariff.js +12 -0
- package/mobile/lib/components/CalculatorRko/markBestTariff.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/mergeTariffData.d.ts +3 -0
- package/mobile/lib/components/CalculatorRko/mergeTariffData.js +23 -0
- package/mobile/lib/components/CalculatorRko/mergeTariffData.js.map +1 -0
- package/mobile/lib/components/CalculatorRko/renderCommissionSum.d.ts +2 -0
- package/mobile/lib/components/CalculatorRko/renderCommissionSum.js +5 -0
- package/mobile/lib/components/CalculatorRko/renderCommissionSum.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCard.d.ts +10 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCard.js +39 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCard.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.d.ts +5 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.js +20 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTable.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.d.ts +16 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js +2 -0
- package/mobile/lib/components/RkoTariffCardsTable/RkoTariffCardsTableContent.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/constants.d.ts +3 -0
- package/mobile/lib/components/RkoTariffCardsTable/constants.js +18 -0
- package/mobile/lib/components/RkoTariffCardsTable/constants.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/getCommissionTypes.d.ts +3 -0
- package/mobile/lib/components/RkoTariffCardsTable/getCommissionTypes.js +8 -0
- package/mobile/lib/components/RkoTariffCardsTable/getCommissionTypes.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderDesktopCard.d.ts +2 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderDesktopCard.js +4 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderDesktopCard.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderHiddenCommission.d.ts +9 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderHiddenCommission.js +6 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderHiddenCommission.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderMobileCard.d.ts +12 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderMobileCard.js +19 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderMobileCard.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRecommendedLabel.d.ts +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRecommendedLabel.js +6 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRecommendedLabel.js.map +1 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.d.ts +6 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js +8 -0
- package/mobile/lib/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.js.map +1 -0
- package/mobile/lib/model/FormTypeFieldDef.d.ts +1 -1
- package/mobile/lib/ui-kit/Button/ButtonTitle.d.ts +5 -1
- package/mobile/lib/ui-kit/Button/ButtonTitle.js +1 -1
- package/mobile/lib/ui-kit/Button/ButtonTitle.js.map +1 -1
- package/mobile/lib/ui-kit/Calculator/CalculatorStyle.d.ts +2 -0
- package/mobile/lib/ui-kit/Calculator/CalculatorStyle.js +2 -0
- package/mobile/lib/ui-kit/Calculator/CalculatorStyle.js.map +1 -1
- package/mobile/lib/ui-kit/Calculator/renderCountInput.d.ts +2 -0
- package/mobile/lib/ui-kit/Calculator/renderCountInput.js +5 -0
- package/mobile/lib/ui-kit/Calculator/renderCountInput.js.map +1 -0
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.d.ts +1 -0
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js +4 -1
- package/mobile/lib/ui-kit/Foldable/DefaultFoldButton.js.map +1 -1
- package/mobile/lib/ui-kit/Text/Text.d.ts +2 -1
- package/mobile/lib/ui-kit/Text/Text.js +1 -1
- package/mobile/lib/ui-kit/Text/Text.js.map +1 -1
- package/mobile/src/api/getSubmitBody.ts +8 -0
- package/mobile/src/components/ApplicationForm/ApplicationForm.example.json +44 -0
- package/mobile/src/components/Blocks.ts +4 -0
- package/mobile/src/components/CalculatorDeposit/normalize.tsx +0 -7
- package/mobile/src/components/CalculatorRko/CalculatorRko.tsx +129 -0
- package/mobile/src/components/CalculatorRko/CalculatorRkoContent.ts +96 -0
- package/mobile/src/components/CalculatorRko/constants.ts +56 -0
- package/mobile/src/components/CalculatorRko/filterByClientType.ts +31 -0
- package/mobile/src/components/CalculatorRko/getCalculatedCommission.ts +174 -0
- package/mobile/src/components/CalculatorRko/getInitialRkoTariffsParams.ts +17 -0
- package/mobile/src/components/CalculatorRko/getRkoCalculatorParams.ts +47 -0
- package/mobile/src/components/CalculatorRko/markBestTariff.ts +16 -0
- package/mobile/src/components/CalculatorRko/mergeTariffData.ts +37 -0
- package/mobile/src/components/CalculatorRko/renderCommissionSum.tsx +9 -0
- package/mobile/src/components/RkoTariffCardsTable/RkoTariffCard.tsx +93 -0
- package/mobile/src/components/RkoTariffCardsTable/RkoTariffCardsTable.tsx +45 -0
- package/mobile/src/components/RkoTariffCardsTable/RkoTariffCardsTableContent.ts +18 -0
- package/mobile/src/components/RkoTariffCardsTable/constants.ts +20 -0
- package/mobile/src/components/RkoTariffCardsTable/getCommissionTypes.ts +10 -0
- package/mobile/src/components/RkoTariffCardsTable/renderDesktopCard.tsx +7 -0
- package/mobile/src/components/RkoTariffCardsTable/renderHiddenCommission.tsx +23 -0
- package/mobile/src/components/RkoTariffCardsTable/renderMobileCard.tsx +61 -0
- package/mobile/src/components/RkoTariffCardsTable/renderRecommendedLabel.tsx +9 -0
- package/mobile/src/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.tsx +25 -0
- package/mobile/src/model/FormTypeFieldDef.ts +2 -1
- package/mobile/src/ui-kit/Button/ButtonTitle.tsx +7 -2
- package/mobile/src/ui-kit/Calculator/CalculatorStyle.tsx +2 -0
- package/mobile/src/ui-kit/Calculator/renderCountInput.tsx +13 -0
- package/mobile/src/ui-kit/Foldable/DefaultFoldButton.tsx +19 -13
- package/mobile/src/ui-kit/Text/Text.tsx +4 -3
- package/package.json +2 -2
- package/src/api/getSubmitBody.ts +8 -0
- package/src/components/ApplicationForm/ApplicationForm.example.json +44 -0
- package/src/components/ApplicationForm/ApplicationForm.fixture.tsx +26 -0
- package/src/components/Blocks.mobile.ts +4 -0
- package/src/components/Blocks.ts +4 -0
- package/src/components/CalculatorDeposit/normalize.tsx +0 -7
- package/src/components/CalculatorRko/CalculatorRko.fixture.mobile.tsx +28 -0
- package/src/components/CalculatorRko/CalculatorRko.fixture.tsx +28 -0
- package/src/components/CalculatorRko/CalculatorRko.tsx +129 -0
- package/src/components/CalculatorRko/CalculatorRkoContent.ts +96 -0
- package/src/components/CalculatorRko/constants.ts +56 -0
- package/src/components/CalculatorRko/filterByClientType.ts +31 -0
- package/src/components/CalculatorRko/getCalculatedCommission.ts +174 -0
- package/src/components/CalculatorRko/getInitialRkoTariffsParams.ts +17 -0
- package/src/components/CalculatorRko/getRkoCalculatorParams.ts +47 -0
- package/src/components/CalculatorRko/markBestTariff.ts +16 -0
- package/src/components/CalculatorRko/mergeTariffData.ts +37 -0
- package/src/components/CalculatorRko/renderCommissionSum.tsx +9 -0
- package/src/components/RkoTariffCardsTable/RkoTariffCard.tsx +93 -0
- package/src/components/RkoTariffCardsTable/RkoTariffCardsTable.fixture.mobile.tsx +60 -0
- package/src/components/RkoTariffCardsTable/RkoTariffCardsTable.fixture.tsx +60 -0
- package/src/components/RkoTariffCardsTable/RkoTariffCardsTable.tsx +45 -0
- package/src/components/RkoTariffCardsTable/RkoTariffCardsTableContent.ts +18 -0
- package/src/components/RkoTariffCardsTable/constants.ts +20 -0
- package/src/components/RkoTariffCardsTable/getCommissionTypes.ts +10 -0
- package/src/components/RkoTariffCardsTable/renderDesktopCard.tsx +7 -0
- package/src/components/RkoTariffCardsTable/renderHiddenCommission.tsx +23 -0
- package/src/components/RkoTariffCardsTable/renderMobileCard.tsx +61 -0
- package/src/components/RkoTariffCardsTable/renderRecommendedLabel.tsx +9 -0
- package/src/components/RkoTariffCardsTable/renderRkoTariffsTableHeader.tsx +25 -0
- package/src/model/FormTypeFieldDef.ts +2 -1
- package/src/ui-kit/Button/ButtonTitle.tsx +7 -2
- package/src/ui-kit/Calculator/CalculatorStyle.tsx +2 -0
- package/src/ui-kit/Calculator/renderCountInput.tsx +13 -0
- package/src/ui-kit/Foldable/DefaultFoldButton.tsx +19 -13
- package/src/ui-kit/Text/Text.tsx +4 -3
- package/tailwind.config.cjs +7 -1
package/bundle/bundle.umd.js
CHANGED
|
@@ -653,7 +653,7 @@
|
|
|
653
653
|
|
|
654
654
|
const renderBenefitDescription = (description, i) => description ? (jsx(Paragraph, { font: "font-light", size: "text-m", color: "text-secondary-text group-data-secondary:text-white", children: description }, `description-${i}`)) : null;
|
|
655
655
|
|
|
656
|
-
const Text = JSX(({ children, ...styleProps }) => (jsx("span", { className: style('font-sans', Object.values(styleProps)), children: children })));
|
|
656
|
+
const Text = JSX(({ children, className, ...styleProps }) => (jsx("span", { className: style('font-sans', Object.values(styleProps), className), children: children })));
|
|
657
657
|
|
|
658
658
|
const renderBenefitLabel = (label, i) => label ? (jsx(Text, { color: "text-primary-text group-data-secondary:text-white", size: "text-h6", children: label }, `label-${i}`)) : null;
|
|
659
659
|
|
|
@@ -1856,6 +1856,7 @@
|
|
|
1856
1856
|
partnerName,
|
|
1857
1857
|
partnerSymbolCode,
|
|
1858
1858
|
}),
|
|
1859
|
+
...getRkoTariffName(typeForm),
|
|
1859
1860
|
...staticBody,
|
|
1860
1861
|
};
|
|
1861
1862
|
};
|
|
@@ -1887,6 +1888,11 @@
|
|
|
1887
1888
|
typeForm: router?.pathname?.split('/')?.at(-1) || '/',
|
|
1888
1889
|
}
|
|
1889
1890
|
: {};
|
|
1891
|
+
const getRkoTariffName = (typeForm) => typeForm === 'CALC'
|
|
1892
|
+
? {
|
|
1893
|
+
partnerComments: globalThis?.sessionStorage.getItem('rkoTariffName') ?? 'Неизвестный тариф',
|
|
1894
|
+
}
|
|
1895
|
+
: {};
|
|
1890
1896
|
|
|
1891
1897
|
// eslint-disable-next-line max-lines-per-function
|
|
1892
1898
|
function LeadServiceAPI() {
|
|
@@ -3501,7 +3507,7 @@
|
|
|
3501
3507
|
|
|
3502
3508
|
const SubmitButton = JSX(({ disabled = false, onClick, text }) => (jsx(Button, { type: "button", onClick: onClick, disabled: disabled, children: jsx(Text, { font: "font-normal", children: text }) })));
|
|
3503
3509
|
|
|
3504
|
-
const ButtonTitle = JSX(({ className, children }) => (jsx("span", { className: style('inline-flex items-center text-start gap-s group-[]/btn-embedded:text-primary-main', className), children: children })));
|
|
3510
|
+
const ButtonTitle = JSX(({ className, labelColor, children }) => (jsx("span", { className: style('inline-flex items-center text-start gap-s', labelColor === 'white' ? 'text-white' : 'group-[]/btn-embedded:text-primary-main', className), children: children })));
|
|
3505
3511
|
|
|
3506
3512
|
const Timer = JSX(({ className, seconds }) => (jsx("span", { className: className, children: formatTimer(seconds) })));
|
|
3507
3513
|
const formatTimer = (seconds) => {
|
|
@@ -4602,7 +4608,10 @@
|
|
|
4602
4608
|
|
|
4603
4609
|
const ToggleIcon = JSX(({ isUnfolded, ...rest }) => (jsx(Icon, { name: isUnfolded ? 'ArrowUpIcon' : 'ArrowDownIcon', size: "small", iconVersion: "", ...rest })));
|
|
4604
4610
|
|
|
4605
|
-
const DefaultFoldButton = JSX(({ className, isUnfolded, short, label = isUnfolded ? 'Скрыть' : 'Развернуть', embedded,
|
|
4611
|
+
const DefaultFoldButton = JSX(({ className, isUnfolded, short, label = isUnfolded ? 'Скрыть' : 'Развернуть', embedded, labelColorStyle, ...rest }) => {
|
|
4612
|
+
const iconColor = labelColorStyle === 'white' ? '' : 'color';
|
|
4613
|
+
return (jsxs(Button, { className: style({ 'w-full': !short }, className), embedded: embedded, shape: short ? 'default' : 'square', role: "tab", "aria-label": "\u041A\u043D\u043E\u043F\u043A\u0430 \u0441\u0432\u043E\u0440\u0430\u0447\u0438\u0432\u0430\u044E\u0449\u0435\u0439\u0441\u044F \u0441\u0435\u043A\u0446\u0438\u0438", ...rest, children: [jsx(ButtonTitle, { labelColor: labelColorStyle, children: label }), jsx(ToggleIcon, { isUnfolded: isUnfolded, iconVersion: embedded ? iconColor : '' })] }));
|
|
4614
|
+
});
|
|
4606
4615
|
|
|
4607
4616
|
// TODO Не особо полезно, в итоге
|
|
4608
4617
|
const Foldable = JSX(({ className, role = 'tablist', children }) => (jsx("div", { className: style(className), role: role, children: children })));
|
|
@@ -5317,7 +5326,9 @@
|
|
|
5317
5326
|
|
|
5318
5327
|
const CalculatorStyle = {
|
|
5319
5328
|
wrapper: 'flex flex-col justify-between lg:flex-row gap-4xl',
|
|
5329
|
+
wrapperMax: 'w-full',
|
|
5320
5330
|
input: 'flex flex-col lg:w-1/2 gap-2xl',
|
|
5331
|
+
inputMax: 'grid lg:grid-cols-2 grid-cols-1 gap-4xl',
|
|
5321
5332
|
result: 'flex flex-col gap-y-xl min-w-52',
|
|
5322
5333
|
};
|
|
5323
5334
|
|
|
@@ -8834,7 +8845,6 @@
|
|
|
8834
8845
|
: {
|
|
8835
8846
|
..._,
|
|
8836
8847
|
...normalizeReplenishWithdrawn(_),
|
|
8837
|
-
...normalizeMoneyValue(_, rows),
|
|
8838
8848
|
...normalizeMonthValue(_, rows),
|
|
8839
8849
|
...normalizeCurrency(_, rows),
|
|
8840
8850
|
};
|
|
@@ -8843,11 +8853,6 @@
|
|
|
8843
8853
|
const monthsValue = _.monthsValue || Math.round((minMonths + maxMonths) / 2);
|
|
8844
8854
|
return { monthsValue: clamp(monthsValue, minMonths, maxMonths) };
|
|
8845
8855
|
};
|
|
8846
|
-
const normalizeMoneyValue = (_, rows) => {
|
|
8847
|
-
const { minSum, maxSum } = getRangeByKeys(['minSum', 'maxSum'], getRows(rows, _?.currency));
|
|
8848
|
-
const moneyValue = _.moneyValue || minSum;
|
|
8849
|
-
return { moneyValue: clamp(moneyValue, minSum, maxSum) };
|
|
8850
|
-
};
|
|
8851
8856
|
const normalizeCurrency = (_, rows) => ({
|
|
8852
8857
|
currency: _?.currency ?? rows?.map((row) => row.currency)?.[0],
|
|
8853
8858
|
});
|
|
@@ -9140,6 +9145,397 @@
|
|
|
9140
9145
|
});
|
|
9141
9146
|
const renderCreditParamsForm = (params, field) => (jsxs("div", { className: "space-y-lg sm:space-y-s", children: [params.isShowSalaryClient ? (jsx(Checkbox, { text: "\u041F\u043E\u043B\u0443\u0447\u0430\u044E \u0437\u0430\u0440\u043F\u043B\u0430\u0442\u0443 \u043D\u0430 \u0441\u0447\u0451\u0442 \u0432 \u0420\u043E\u0441\u0441\u0435\u043B\u044C\u0445\u043E\u0437\u0431\u0430\u043D\u043A\u0435", ...field('isSalaryClient'), value: params.isSalaryClient })) : null, params.isShowInsurance ? (jsx(Checkbox, { text: "\u041A\u043E\u043C\u043F\u043B\u0435\u043A\u0441\u043D\u0430\u044F \u0441\u0442\u0440\u0430\u0445\u043E\u0432\u0430\u044F \u0437\u0430\u0449\u0438\u0442\u0430", ...field('isInsurance'), value: params.isInsurance })) : null, jsx(Checkbox, { text: "\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u0434\u043E\u043F\u043E\u043B\u043D\u0438\u0442\u0435\u043B\u044C\u043D\u0443\u044E \u0441\u0443\u043C\u043C\u0443", ...field('isExtraMoney'), value: params.isExtraMoney })] }));
|
|
9142
9147
|
|
|
9148
|
+
const DEFAULT_AMOUNT_STEP = 1;
|
|
9149
|
+
const renderCountInput = ({ min = 0, max = 0, step = DEFAULT_AMOUNT_STEP, ...rest }) => (jsx(InputRange, { items: [`От ${min} шт`, `До ${max} шт`], step: step, ...rest }));
|
|
9150
|
+
|
|
9151
|
+
const capitalize = (text) => text ? `${text.charAt(0).toUpperCase()}${text.slice(1)}` : '';
|
|
9152
|
+
|
|
9153
|
+
const RKO_DEFAULT_CURRENCY = {
|
|
9154
|
+
text: '₽',
|
|
9155
|
+
key: 'rub',
|
|
9156
|
+
};
|
|
9157
|
+
const RKO_DEFAULT_TRANSFER_FL_SUM = 0;
|
|
9158
|
+
const RKO_DEFAULT_CASH_IN_SUM = 0;
|
|
9159
|
+
const RKO_DEFAULT_CASH_OUT_SUM = 0;
|
|
9160
|
+
const RKO_DEFAULT_TRANSFER_LEGAL_COUNT = 0;
|
|
9161
|
+
const COMMISSIONS_CONFIG = [
|
|
9162
|
+
{
|
|
9163
|
+
key: 'transferLegalCountCommission',
|
|
9164
|
+
valueKey: 'transferLegalCount',
|
|
9165
|
+
minKey: 'minTransferLegalCount',
|
|
9166
|
+
maxKey: 'maxTransferLegalCount',
|
|
9167
|
+
},
|
|
9168
|
+
{
|
|
9169
|
+
key: 'flTransferSumCommission',
|
|
9170
|
+
valueKey: 'flTransferSum',
|
|
9171
|
+
minKey: 'minFlTransferSum',
|
|
9172
|
+
maxKey: 'maxFlTransferSum',
|
|
9173
|
+
},
|
|
9174
|
+
{
|
|
9175
|
+
key: 'cashOutSumCommission',
|
|
9176
|
+
valueKey: 'cashOutSum',
|
|
9177
|
+
minKey: 'minCashOutSum',
|
|
9178
|
+
maxKey: 'maxCashOutSum',
|
|
9179
|
+
},
|
|
9180
|
+
{
|
|
9181
|
+
key: 'cashInSumCommission',
|
|
9182
|
+
valueKey: 'cashInSum',
|
|
9183
|
+
minKey: 'minCashInSum',
|
|
9184
|
+
maxKey: 'maxCashInSum',
|
|
9185
|
+
},
|
|
9186
|
+
];
|
|
9187
|
+
const INPUTS_CONFIG = [
|
|
9188
|
+
{
|
|
9189
|
+
key: 'flTransferSum',
|
|
9190
|
+
title: 'Сумма переводов на счета ФЛ в месяц, ₽',
|
|
9191
|
+
step: 50000,
|
|
9192
|
+
},
|
|
9193
|
+
{
|
|
9194
|
+
key: 'cashInSum',
|
|
9195
|
+
title: 'Внесение наличных через кассу в месяц, ₽',
|
|
9196
|
+
step: 50000,
|
|
9197
|
+
},
|
|
9198
|
+
{
|
|
9199
|
+
key: 'cashOutSum',
|
|
9200
|
+
title: 'Снятие наличных в кассе банка в месяц, ₽',
|
|
9201
|
+
step: 50000,
|
|
9202
|
+
},
|
|
9203
|
+
];
|
|
9204
|
+
|
|
9205
|
+
const RKO_COMMISSIONS_TITLE_MAP = {
|
|
9206
|
+
tariffName: 'Название тарифа',
|
|
9207
|
+
accountServiceFee: 'Обслуживание счета',
|
|
9208
|
+
transferLegalCountCommission: 'Переводы Юрлицам и ИП',
|
|
9209
|
+
flTransferSumCommission: 'Переводы физлицам',
|
|
9210
|
+
cashOutSumCommission: 'Снятие наличных',
|
|
9211
|
+
cashInSumCommission: 'Внесение наличных',
|
|
9212
|
+
totalCommission: 'Итоговая комиссия',
|
|
9213
|
+
};
|
|
9214
|
+
const RKO_COLUMNS_ORDER = [
|
|
9215
|
+
'accountServiceFee',
|
|
9216
|
+
'transferLegalCountCommission',
|
|
9217
|
+
'flTransferSumCommission',
|
|
9218
|
+
'cashOutSumCommission',
|
|
9219
|
+
'cashInSumCommission',
|
|
9220
|
+
'totalCommission',
|
|
9221
|
+
];
|
|
9222
|
+
|
|
9223
|
+
const getSortedCommissionTypes = (items) => {
|
|
9224
|
+
if (!items || items.length === 0) {
|
|
9225
|
+
return [];
|
|
9226
|
+
}
|
|
9227
|
+
return RKO_COLUMNS_ORDER.filter((key) => key in items[0]);
|
|
9228
|
+
};
|
|
9229
|
+
|
|
9230
|
+
const renderRkoTariffsTableHeader = ({ params, className }) => {
|
|
9231
|
+
return params ? (jsxs("div", { className: style(className), children: [jsx(Text, { size: "text-xs", font: "font-medium", className: "col-span-2", children: RKO_COMMISSIONS_TITLE_MAP['tariffName'] }), params.map((param, index) => (jsx("div", { children: jsx(Text, { size: "text-xs", font: "font-medium", children: RKO_COMMISSIONS_TITLE_MAP[param] }) }, index)))] })) : null;
|
|
9232
|
+
};
|
|
9233
|
+
|
|
9234
|
+
const renderCommissionSum = (value, currency, className) => (jsxs(Text, { className: className, children: [value?.toLocaleString(), "\u00A0", (currency ?? RKO_DEFAULT_CURRENCY).text] }));
|
|
9235
|
+
|
|
9236
|
+
const renderDesktopCard = (commissions, currency) => commissions.map((commission, index) => (jsx("div", { children: renderCommissionSum(commission, currency) }, index)));
|
|
9237
|
+
|
|
9238
|
+
const renderHiddenCommission = ({ commission, currency, commissionType, index, }) => (jsxs("div", { className: "flex justify-between align-center", children: [jsx(Text, { children: RKO_COMMISSIONS_TITLE_MAP[commissionType ?? ''] }), renderCommissionSum(commission, currency)] }, index));
|
|
9239
|
+
|
|
9240
|
+
const renderMobileCard = ({ commissions, currency, isUnfolded, handleFold, commissionTypes, isBest = false, }) => {
|
|
9241
|
+
const totalCommission = commissionTypes?.at(-1) ?? '';
|
|
9242
|
+
return (jsxs(Foldable, { className: "py-4", children: [jsxs("div", { className: "w-full space-y-xl", children: [jsx(FoldableSection, { isUnfolded: isUnfolded, className: "space-y-xl", children: commissions.map((commission, index) => index !== commissions.length - 1 &&
|
|
9243
|
+
renderHiddenCommission({
|
|
9244
|
+
commission,
|
|
9245
|
+
currency,
|
|
9246
|
+
commissionType: commissionTypes?.[index],
|
|
9247
|
+
index,
|
|
9248
|
+
})) }), jsxs("div", { className: "flex justify-between items-center", children: [jsx(Text, { font: "font-medium", children: RKO_COMMISSIONS_TITLE_MAP[totalCommission] }), renderCommissionSum(commissions.at(-1) ?? 0, currency, 'text-h2')] })] }), jsx(DefaultFoldButton, { className: "mt-m mx-auto", label: isUnfolded ? 'Скрыть' : 'Подробнее', isUnfolded: isUnfolded, embedded: true, labelColorStyle: isBest ? 'white' : '', onClick: handleFold, short: true })] }));
|
|
9249
|
+
};
|
|
9250
|
+
|
|
9251
|
+
const renderRecommendedLabel = (isBest) => {
|
|
9252
|
+
return isBest ? (jsx("div", { className: "absolute block rounded-xl min-h-xs flex justify-center align-center bg-orange py-1 px-2 lg:ml-xl top-[-10px]", children: jsx(Text, { size: "text-xs", children: "\u0420\u0435\u043A\u043E\u043C\u0435\u043D\u0434\u0443\u0435\u043C" }) })) : null;
|
|
9253
|
+
};
|
|
9254
|
+
|
|
9255
|
+
const RkoTariffCard = JSX(({ tariffName, tariffDesc, className, transferLegalCountCommission, flTransferSumCommission, cashInSumCommission, accountServiceFee, cashOutSumCommission, totalCommission, currency, isBest = false, commissionTypes, }) => {
|
|
9256
|
+
const [isUnfolded, { toggle }] = useBool(false);
|
|
9257
|
+
const tariffData = {
|
|
9258
|
+
accountServiceFee,
|
|
9259
|
+
transferLegalCountCommission,
|
|
9260
|
+
flTransferSumCommission,
|
|
9261
|
+
cashOutSumCommission,
|
|
9262
|
+
cashInSumCommission,
|
|
9263
|
+
totalCommission,
|
|
9264
|
+
};
|
|
9265
|
+
const commissions = RKO_COLUMNS_ORDER.map((key) => tariffData[key]);
|
|
9266
|
+
const isMobileMode = useMobileMode();
|
|
9267
|
+
const handleOpenDepositClick = () => globalThis?.sessionStorage.setItem('rkoTariffName', tariffName);
|
|
9268
|
+
return (jsxs("div", { className: style(className, 'rounded-xl min-h-24 items-center min-w-0 lg:p-xl p-3xl', isBest
|
|
9269
|
+
? 'bg-primary-main text-white relative'
|
|
9270
|
+
: 'bg-white text-primary-text border border-solid border-gray'), children: [jsxs("div", { className: "col-span-2", children: [jsx(Heading, { headingType: isMobileMode ? 'h2' : 'h6', title: tariffName }), jsx(Text, { size: "text-xs", children: tariffDesc })] }), isMobileMode
|
|
9271
|
+
? renderMobileCard({
|
|
9272
|
+
commissions,
|
|
9273
|
+
currency,
|
|
9274
|
+
isUnfolded,
|
|
9275
|
+
handleFold: toggle,
|
|
9276
|
+
commissionTypes,
|
|
9277
|
+
isBest,
|
|
9278
|
+
})
|
|
9279
|
+
: renderDesktopCard(commissions, currency), jsx("div", { className: "flex flex-wrap @xl:flex-nowrap gap-lg sm:gap-m w-full @lg:w-auto col-span-2", children: jsx(LinkButton, { version: isBest ? 'secondary' : 'primary', className: style('basis-full @lg:basis-auto w-full'), text: "\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0441\u0447\u0451\u0442", href: "/business/calculator-rko#opendeposit", onClick: handleOpenDepositClick }) }), renderRecommendedLabel(isBest)] }));
|
|
9280
|
+
});
|
|
9281
|
+
|
|
9282
|
+
const RkoTariffCardsTable = JSX(({ items = [], currency = RKO_DEFAULT_CURRENCY, buttons = [] }) => {
|
|
9283
|
+
const isMobileMode = useMobileMode();
|
|
9284
|
+
const commissionTypes = getSortedCommissionTypes(items) ?? [];
|
|
9285
|
+
const columnsCount = commissionTypes.length + 4; // 2 на "Название тарифа" и 2 на кнопку
|
|
9286
|
+
const tableLayoutStyle = `lg:grid lg:grid-cols-${String(columnsCount)} gap-m`;
|
|
9287
|
+
return (jsxs("div", { className: "lg:space-y-m space-y-xl w-full", children: [isMobileMode
|
|
9288
|
+
? null
|
|
9289
|
+
: renderRkoTariffsTableHeader({
|
|
9290
|
+
params: commissionTypes,
|
|
9291
|
+
className: tableLayoutStyle,
|
|
9292
|
+
}), items.map((item, index) => (jsx("div", { children: jsx(RkoTariffCard, { ...item, className: tableLayoutStyle, currency: currency, buttons: buttons, commissionTypes: commissionTypes }) }, index)))] }));
|
|
9293
|
+
});
|
|
9294
|
+
|
|
9295
|
+
const filterByClientType = (data, clientType) => {
|
|
9296
|
+
if (Array.isArray(data)) {
|
|
9297
|
+
return data.filter((item) => item?.clientType === clientType);
|
|
9298
|
+
}
|
|
9299
|
+
if (data && typeof data === 'object') {
|
|
9300
|
+
const result = {};
|
|
9301
|
+
for (const key in data) {
|
|
9302
|
+
if (Object.hasOwn(data, key)) {
|
|
9303
|
+
const value = data[key];
|
|
9304
|
+
// eslint-disable-next-line max-depth
|
|
9305
|
+
if (Array.isArray(value)) {
|
|
9306
|
+
result[key] = value.filter((item) => item?.clientType === clientType);
|
|
9307
|
+
}
|
|
9308
|
+
else {
|
|
9309
|
+
result[key] = value;
|
|
9310
|
+
}
|
|
9311
|
+
}
|
|
9312
|
+
}
|
|
9313
|
+
return result;
|
|
9314
|
+
}
|
|
9315
|
+
// На всякий случай
|
|
9316
|
+
return data;
|
|
9317
|
+
};
|
|
9318
|
+
|
|
9319
|
+
const SLICE_CORRECTION = 1; // если диапазон включает обе границы
|
|
9320
|
+
const getCalculatedCommission = ({ ranges = [], value = 0, minKey = 'min', maxKey = 'max', }) => {
|
|
9321
|
+
const amount = Number(value);
|
|
9322
|
+
if (isNaN(amount) || amount <= 0) {
|
|
9323
|
+
return 0;
|
|
9324
|
+
}
|
|
9325
|
+
const groupedTariffs = groupRangesByTariff(ranges);
|
|
9326
|
+
const result = {};
|
|
9327
|
+
for (const tariff in groupedTariffs) {
|
|
9328
|
+
result[tariff] = calculateTariffCommission({
|
|
9329
|
+
ranges: groupedTariffs[tariff],
|
|
9330
|
+
value: amount,
|
|
9331
|
+
minKey,
|
|
9332
|
+
maxKey,
|
|
9333
|
+
});
|
|
9334
|
+
}
|
|
9335
|
+
return result;
|
|
9336
|
+
};
|
|
9337
|
+
const calculateTariffCommission = ({ ranges = [], value = 0, minKey = 'min', maxKey = 'max', }) => {
|
|
9338
|
+
const validRanges = getValidTariffRanges(ranges, minKey);
|
|
9339
|
+
let totalCommission = 0;
|
|
9340
|
+
let minCommission = 0;
|
|
9341
|
+
for (const range of validRanges) {
|
|
9342
|
+
minCommission = Number(range.minCommission) ?? 0;
|
|
9343
|
+
if (!isValidRange({ range, amount: value, minKey, maxKey })) {
|
|
9344
|
+
continue;
|
|
9345
|
+
}
|
|
9346
|
+
const sliceAmount = calculateSliceAmount({ range, amount: value, minKey, maxKey });
|
|
9347
|
+
const commission = calculateCommissionByType({
|
|
9348
|
+
type: range.commissionType,
|
|
9349
|
+
sliceAmount,
|
|
9350
|
+
commissionValue: Number(range.commissionValue),
|
|
9351
|
+
context: {
|
|
9352
|
+
min: Number(range[minKey]),
|
|
9353
|
+
max: Number(range[maxKey]),
|
|
9354
|
+
amount: Number(value),
|
|
9355
|
+
},
|
|
9356
|
+
});
|
|
9357
|
+
totalCommission += commission;
|
|
9358
|
+
if (value <= range[maxKey]) {
|
|
9359
|
+
break;
|
|
9360
|
+
}
|
|
9361
|
+
}
|
|
9362
|
+
if (totalCommission < minCommission) {
|
|
9363
|
+
totalCommission = minCommission;
|
|
9364
|
+
}
|
|
9365
|
+
return Math.round(totalCommission);
|
|
9366
|
+
};
|
|
9367
|
+
const calculateSliceAmount = ({ range, amount, minKey, maxKey }) => {
|
|
9368
|
+
const min = range[minKey];
|
|
9369
|
+
const max = range[maxKey];
|
|
9370
|
+
const sliceStart = Math.max(Number(min), 0);
|
|
9371
|
+
const sliceEnd = Math.min(Number(max), amount);
|
|
9372
|
+
return sliceEnd - sliceStart + SLICE_CORRECTION;
|
|
9373
|
+
};
|
|
9374
|
+
const isValidRange = ({ range, amount, minKey, maxKey }) => {
|
|
9375
|
+
const min = range[minKey];
|
|
9376
|
+
const max = range[maxKey];
|
|
9377
|
+
const commissionValue = Number(range.commissionValue);
|
|
9378
|
+
if (min == null || max == null || isNaN(commissionValue)) {
|
|
9379
|
+
return false;
|
|
9380
|
+
}
|
|
9381
|
+
if (amount < min) {
|
|
9382
|
+
return false;
|
|
9383
|
+
}
|
|
9384
|
+
const sliceStart = Math.max(Number(min), 0);
|
|
9385
|
+
const sliceEnd = Math.min(Number(max), amount);
|
|
9386
|
+
return sliceStart <= sliceEnd;
|
|
9387
|
+
};
|
|
9388
|
+
const getValidTariffRanges = (ranges, minKey) => ranges
|
|
9389
|
+
.filter((r) => r.commissionValue != null && r.commissionType != null)
|
|
9390
|
+
.sort((a, b) => Number(a[minKey]) - Number(b[minKey]));
|
|
9391
|
+
const calculateCommissionByType = ({ type, sliceAmount, commissionValue, context, }) => {
|
|
9392
|
+
const { min, max, amount } = context;
|
|
9393
|
+
switch (type) {
|
|
9394
|
+
case 'fixedSum':
|
|
9395
|
+
if (min === 0 || amount <= max) {
|
|
9396
|
+
return commissionValue;
|
|
9397
|
+
}
|
|
9398
|
+
return 0;
|
|
9399
|
+
case 'percent':
|
|
9400
|
+
return (sliceAmount * commissionValue) / 100;
|
|
9401
|
+
case 'fixedAmount':
|
|
9402
|
+
return Math.round(sliceAmount * commissionValue);
|
|
9403
|
+
default:
|
|
9404
|
+
return 0;
|
|
9405
|
+
}
|
|
9406
|
+
};
|
|
9407
|
+
const groupRangesByTariff = (ranges) => {
|
|
9408
|
+
const tariffs = {};
|
|
9409
|
+
for (const range of ranges) {
|
|
9410
|
+
const { tariff } = range;
|
|
9411
|
+
if (!tariff) {
|
|
9412
|
+
continue;
|
|
9413
|
+
}
|
|
9414
|
+
if (!tariffs[tariff]) {
|
|
9415
|
+
tariffs[tariff] = [];
|
|
9416
|
+
}
|
|
9417
|
+
tariffs[tariff].push(range);
|
|
9418
|
+
}
|
|
9419
|
+
return tariffs;
|
|
9420
|
+
};
|
|
9421
|
+
|
|
9422
|
+
const getInitialRkoTariffsParams = (tariffs = []) => tariffs.map((tariff) => {
|
|
9423
|
+
return {
|
|
9424
|
+
...tariff,
|
|
9425
|
+
flTransferSumCommission: 0,
|
|
9426
|
+
cashOutSumCommission: 0,
|
|
9427
|
+
cashInSumCommission: 0,
|
|
9428
|
+
transferLegalCountCommission: 0,
|
|
9429
|
+
totalCommission: tariff.accountServiceFee,
|
|
9430
|
+
isBest: false,
|
|
9431
|
+
};
|
|
9432
|
+
});
|
|
9433
|
+
|
|
9434
|
+
const getRkoCalculatorParams = (userInputParams, rows, clientType) => {
|
|
9435
|
+
const commissionsRows = rows?.[0]?.commissions;
|
|
9436
|
+
const { minTransferLegalCount, maxTransferLegalCount } = getRangeByKeys(['minTransferLegalCount', 'maxTransferLegalCount'], commissionsRows?.transferLegalCountCommission.filter((item) => item.clientType === clientType));
|
|
9437
|
+
const { minFlTransferSum, maxFlTransferSum } = getRangeByKeys(['minFlTransferSum', 'maxFlTransferSum'], commissionsRows?.flTransferSumCommission.filter((item) => item.clientType === clientType));
|
|
9438
|
+
const { minCashInSum, maxCashInSum } = getRangeByKeys(['minCashInSum', 'maxCashInSum'], commissionsRows?.cashInSumCommission.filter((item) => item.clientType === clientType));
|
|
9439
|
+
const { minCashOutSum, maxCashOutSum } = getRangeByKeys(['minCashOutSum', 'maxCashOutSum'], commissionsRows?.cashOutSumCommission.filter((item) => item.clientType === clientType));
|
|
9440
|
+
return {
|
|
9441
|
+
...userInputParams,
|
|
9442
|
+
minTransferLegalCount,
|
|
9443
|
+
maxTransferLegalCount,
|
|
9444
|
+
minFlTransferSum,
|
|
9445
|
+
maxFlTransferSum,
|
|
9446
|
+
minCashInSum,
|
|
9447
|
+
maxCashInSum,
|
|
9448
|
+
minCashOutSum,
|
|
9449
|
+
maxCashOutSum,
|
|
9450
|
+
};
|
|
9451
|
+
};
|
|
9452
|
+
|
|
9453
|
+
const markBestTariff = (tariffs) => {
|
|
9454
|
+
if (tariffs.length === 0) {
|
|
9455
|
+
return tariffs;
|
|
9456
|
+
}
|
|
9457
|
+
const minCommission = Math.min(...tariffs.map((t) => t.totalCommission));
|
|
9458
|
+
const minTariffIndex = tariffs.findIndex((t) => t.totalCommission === minCommission);
|
|
9459
|
+
return tariffs.map((tariff, index) => ({
|
|
9460
|
+
...tariff,
|
|
9461
|
+
isBest: index === minTariffIndex,
|
|
9462
|
+
}));
|
|
9463
|
+
};
|
|
9464
|
+
|
|
9465
|
+
const mergeTariffData = (commissionData, tariffs = []) => {
|
|
9466
|
+
const commissionKeys = [
|
|
9467
|
+
'flTransferSumCommission',
|
|
9468
|
+
'cashOutSumCommission',
|
|
9469
|
+
'cashInSumCommission',
|
|
9470
|
+
'transferLegalCountCommission',
|
|
9471
|
+
];
|
|
9472
|
+
return tariffs.map((tariff) => {
|
|
9473
|
+
const { tariffName, accountServiceFee } = tariff;
|
|
9474
|
+
const commissions = commissionKeys.reduce((acc, key) => {
|
|
9475
|
+
acc[key] = commissionData[key]?.[tariffName] ?? 0;
|
|
9476
|
+
return acc;
|
|
9477
|
+
}, {});
|
|
9478
|
+
const totalCommission = Object.values(commissions).reduce((sum, val) => sum + val, 0) + accountServiceFee;
|
|
9479
|
+
return {
|
|
9480
|
+
...tariff,
|
|
9481
|
+
...commissions,
|
|
9482
|
+
isBest: false,
|
|
9483
|
+
totalCommission,
|
|
9484
|
+
};
|
|
9485
|
+
});
|
|
9486
|
+
};
|
|
9487
|
+
|
|
9488
|
+
const CalculatorRko = UniBlock(
|
|
9489
|
+
// eslint-disable-next-line max-lines-per-function
|
|
9490
|
+
({ className = '', title, calcSource, footnote, clientType = 'standard', ...rest }) => {
|
|
9491
|
+
const [tariffs, setTariffs] = useState([]);
|
|
9492
|
+
const [userInputParams, { field }] = useForm({
|
|
9493
|
+
transferLegalCount: RKO_DEFAULT_TRANSFER_LEGAL_COUNT,
|
|
9494
|
+
flTransferSum: RKO_DEFAULT_TRANSFER_FL_SUM,
|
|
9495
|
+
cashOutSum: RKO_DEFAULT_CASH_OUT_SUM,
|
|
9496
|
+
cashInSum: RKO_DEFAULT_CASH_IN_SUM,
|
|
9497
|
+
});
|
|
9498
|
+
const { rows } = calcSource ?? {};
|
|
9499
|
+
const calcTariffs = useMemo(() => filterByClientType(rows?.[0]?.tariffs, clientType), [rows]);
|
|
9500
|
+
const calcParams = getRkoCalculatorParams(userInputParams, rows, clientType);
|
|
9501
|
+
const calcCommissions = filterByClientType(rows?.[0]?.commissions, clientType);
|
|
9502
|
+
useEffect(() => {
|
|
9503
|
+
if (!calcCommissions) {
|
|
9504
|
+
const initialRkoTariffsParams = getInitialRkoTariffsParams(calcTariffs);
|
|
9505
|
+
setTariffs(initialRkoTariffsParams);
|
|
9506
|
+
return;
|
|
9507
|
+
}
|
|
9508
|
+
const commissions = COMMISSIONS_CONFIG.reduce((acc, config) => {
|
|
9509
|
+
acc[config.key] = getCalculatedCommission({
|
|
9510
|
+
ranges: calcCommissions?.[config.key],
|
|
9511
|
+
value: userInputParams?.[config.valueKey],
|
|
9512
|
+
minKey: config.minKey,
|
|
9513
|
+
maxKey: config.maxKey,
|
|
9514
|
+
});
|
|
9515
|
+
return acc;
|
|
9516
|
+
}, {});
|
|
9517
|
+
const mergedTariffs = mergeTariffData(commissions, calcTariffs);
|
|
9518
|
+
const result = markBestTariff(mergedTariffs);
|
|
9519
|
+
setTariffs(result);
|
|
9520
|
+
}, [userInputParams, calcTariffs]);
|
|
9521
|
+
return (jsxs("div", { className: style(className, 'bg-white'), children: [jsx(CalculatorLayout, { className: className, title: title, ...rest, children: jsxs("section", { className: style(CalculatorStyle.wrapperMax, className), children: [jsxs("div", { className: CalculatorStyle.inputMax, children: [renderCountInput({
|
|
9522
|
+
title: 'Количество внешних переводов на счета ЮЛ и ИП в месяц, шт',
|
|
9523
|
+
step: 1,
|
|
9524
|
+
min: calcParams.minTransferLegalCount,
|
|
9525
|
+
max: calcParams.maxTransferLegalCount,
|
|
9526
|
+
...field('transferLegalCount'),
|
|
9527
|
+
value: calcParams.transferLegalCount,
|
|
9528
|
+
}), INPUTS_CONFIG.map((config, index) => (jsx("div", { children: renderWantedSumInput({
|
|
9529
|
+
title: config.title,
|
|
9530
|
+
step: config.step,
|
|
9531
|
+
min: calcParams[`min${capitalize(config.key)}`],
|
|
9532
|
+
max: calcParams[`max${capitalize(config.key)}`],
|
|
9533
|
+
...field(config.key),
|
|
9534
|
+
value: calcParams[config.key],
|
|
9535
|
+
}) }, index)))] }), jsx("div", { className: style(CalculatorStyle.result), children: renderFootnote(footnote) })] }) }), jsxs(BlockWrapper, { className: style('flex flex-col gap-4xl items-center', className), defaultPadding: "p-4xl pt-0", ...rest, children: [renderHeading$1(), tariffs ? (jsx(RkoTariffCardsTable, { items: tariffs, currency: RKO_DEFAULT_CURRENCY })) : (jsx(Loader, { position: "static" }))] })] }));
|
|
9536
|
+
});
|
|
9537
|
+
const renderHeading$1 = () => (jsx(Text, { size: "text-h6", font: "font-medium", align: "text-center", className: "block lg:mb-0 mb-m", children: "\u0420\u0430\u0441\u0447\u0435\u0442\u044B \u0437\u0430 \u043E\u0434\u0438\u043D \u043C\u0435\u0441\u044F\u0446 \u043F\u043E \u0432\u0432\u0435\u0434\u0435\u043D\u043D\u044B\u043C \u0432\u044B\u0448\u0435 \u043F\u0430\u0440\u0430\u043C\u0435\u0442\u0440\u0430\u043C" }));
|
|
9538
|
+
|
|
9143
9539
|
const NumberInput = JSX((props) => {
|
|
9144
9540
|
const { onChange, min, max, defaultValue = '0', fractionDigits = 0, ...inputProps } = props;
|
|
9145
9541
|
const normalizedProps = useNormalizedInput(props, {
|
|
@@ -13035,8 +13431,6 @@
|
|
|
13035
13431
|
});
|
|
13036
13432
|
const getFiltersWithNonEmptyData = (data) => Object.keys(INITIAL_FILTRATION_STATE$1).filter((_) => data.filter((item) => FILTRATION_PREDICATES[_](item)).length);
|
|
13037
13433
|
|
|
13038
|
-
const capitalize = (text) => text ? `${text.charAt(0).toUpperCase()}${text.slice(1)}` : '';
|
|
13039
|
-
|
|
13040
13434
|
const renderAtmCard = ({ location, address, billAcceptorType, terminalType, billAcceptorEnable, atmCode = '', atmAccess = '', workTime, }, i) => {
|
|
13041
13435
|
const additionalInfo = [
|
|
13042
13436
|
{
|
|
@@ -13599,6 +13993,8 @@
|
|
|
13599
13993
|
CreditForm,
|
|
13600
13994
|
DebitForm,
|
|
13601
13995
|
CashbackCalculator,
|
|
13996
|
+
CalculatorRko,
|
|
13997
|
+
RkoTariffCardsTable,
|
|
13602
13998
|
};
|
|
13603
13999
|
|
|
13604
14000
|
const applyAspects = (aspects) => (ev) => {
|
|
@@ -13742,7 +14138,7 @@
|
|
|
13742
14138
|
slots: () => [HEADER_SLOT, FOOTER_SLOT, STICKY_FOOTER_SLOT],
|
|
13743
14139
|
});
|
|
13744
14140
|
|
|
13745
|
-
const packageVersion = "0.14.
|
|
14141
|
+
const packageVersion = "0.14.997";
|
|
13746
14142
|
|
|
13747
14143
|
exports.Blocks = Blocks;
|
|
13748
14144
|
exports.ContentPage = ContentPage;
|