@redneckz/wildless-cms-uni-blocks 0.14.26 → 0.14.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/migration-scripts/0.12.12.js +0 -10
- package/bin/migration-scripts/0.14.26.js +3 -1
- package/bundle/api/{CorporateLeadAPI.d.ts → LeadServiceAPI.d.ts} +2 -2
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +286 -259
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/bundle/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/bundle/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/bundle/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/bundle/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/bundle/components/ApplicationForm/Footnote.d.ts +1 -0
- package/bundle/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/bundle/components/ApplicationForm/renderIndividualsFields.d.ts +4 -0
- package/bundle/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/bundle/components/Bonus/BonusContent.d.ts +1 -0
- package/bundle/components/Calculator/CalculatorContent.d.ts +3 -0
- package/bundle/components/CarouselCard/titleSize.d.ts +1 -1
- package/bundle/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/bundle/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/bundle/components/MobileAppTile/renderList.d.ts +1 -1
- package/bundle/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/bundle/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/bundle/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/bundle/icons/IconName.d.ts +16 -2
- package/bundle/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/bundle/utils/getBorderStyle.d.ts +1 -0
- package/cosmos-static/icons/CardSendIcon.svg +1 -0
- package/cosmos-static/icons/CoinIcon.svg +1 -0
- package/cosmos-static/icons/ConvertCardIcon.svg +1 -0
- package/cosmos-static/icons/DzenIcon.svg +1 -0
- package/cosmos-static/icons/HeartTickIcon.svg +1 -0
- package/cosmos-static/icons/NotificationBingIcon.svg +1 -0
- package/cosmos-static/icons/Security/320/241ardIcon.svg +1 -0
- package/{lib/api/CorporateLeadAPI.d.ts → dist/api/LeadServiceAPI.d.ts} +2 -2
- package/dist/api/{CorporateLeadAPI.js → LeadServiceAPI.js} +7 -6
- package/dist/api/LeadServiceAPI.js.map +1 -0
- package/dist/components/ApplicationForm/ApplicationForm.js +4 -4
- package/dist/components/ApplicationForm/ApplicationForm.js.map +1 -1
- package/dist/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/dist/components/ApplicationForm/ApplicationFormDeposit.js +1 -2
- package/dist/components/ApplicationForm/ApplicationFormDeposit.js.map +1 -1
- package/dist/components/ApplicationForm/ApplicationFormGrantSupport.js +1 -1
- package/dist/components/ApplicationForm/ApplicationFormGrantSupport.js.map +1 -1
- package/dist/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/dist/components/ApplicationForm/ApplicationFormIndividuals.js +52 -0
- package/dist/components/ApplicationForm/ApplicationFormIndividuals.js.map +1 -0
- package/dist/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/dist/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/dist/components/ApplicationForm/DatePickerControl.js +8 -0
- package/dist/components/ApplicationForm/DatePickerControl.js.map +1 -0
- package/dist/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/dist/components/ApplicationForm/EmbeddableForms.js +2 -0
- package/dist/components/ApplicationForm/EmbeddableForms.js.map +1 -1
- package/dist/components/ApplicationForm/Footnote.d.ts +1 -0
- package/dist/components/ApplicationForm/Footnote.js +1 -1
- package/dist/components/ApplicationForm/Footnote.js.map +1 -1
- package/dist/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/dist/components/{PromoTile/PromoTileContent.js → ApplicationForm/IndividualsFormState.js} +1 -1
- package/dist/components/ApplicationForm/IndividualsFormState.js.map +1 -0
- package/dist/components/ApplicationForm/renderIndividualsFields.d.ts +4 -0
- package/dist/components/ApplicationForm/renderIndividualsFields.js +11 -0
- package/dist/components/ApplicationForm/renderIndividualsFields.js.map +1 -0
- package/dist/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/dist/components/Blocks.js +0 -2
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Bonus/BonusContent.d.ts +1 -0
- package/dist/components/Calculator/Calculator.mobile.js +6 -5
- package/dist/components/Calculator/Calculator.mobile.js.map +1 -1
- package/dist/components/Calculator/CalculatorContent.d.ts +3 -0
- package/dist/components/Carousel/renderCarouselCards.js +2 -2
- package/dist/components/Carousel/renderCarouselCards.js.map +1 -1
- package/dist/components/CarouselCard/CarouselCard.js +1 -1
- package/dist/components/CarouselCard/CarouselCard.js.map +1 -1
- package/dist/components/CarouselCard/titleSize.d.ts +1 -1
- package/dist/components/CarouselCard/titleSize.js +1 -1
- package/dist/components/CarouselCard/titleSize.js.map +1 -1
- package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +1 -1
- package/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/dist/components/Footer/Footer.mobile.js +2 -2
- package/dist/components/Footer/Footer.mobile.js.map +1 -1
- package/dist/components/Footer/HorizontalNavigation.mobile.js +2 -1
- package/dist/components/Footer/HorizontalNavigation.mobile.js.map +1 -1
- package/dist/components/Footer/SocialMedia.js +3 -3
- package/dist/components/Footer/SocialMedia.js.map +1 -1
- package/dist/components/Footer/iconsMap.js +4 -0
- package/dist/components/Footer/iconsMap.js.map +1 -1
- package/dist/components/HorizontalLayout/HorizontalLayout.js +2 -3
- package/dist/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocItem.js +6 -14
- package/dist/components/LinkDocs/LinkDocItem.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocs.js +4 -3
- package/dist/components/LinkDocs/LinkDocs.js.map +1 -1
- package/dist/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/dist/components/LinkDocs/linkDocsContentExample.js +14 -5
- package/dist/components/LinkDocs/linkDocsContentExample.js.map +1 -1
- package/dist/components/MobileAppTile/MobileAppTile.js +2 -2
- package/dist/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/dist/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/dist/components/MobileAppTile/renderList.d.ts +1 -1
- package/dist/components/MobileAppTile/renderList.js +3 -2
- package/dist/components/MobileAppTile/renderList.js.map +1 -1
- package/dist/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/dist/components/ProductBlock/ProductBlock.js +2 -4
- package/dist/components/ProductBlock/ProductBlock.js.map +1 -1
- package/dist/components/ProductGallery/ProductGallery.js +1 -1
- package/dist/components/ProductGallery/ProductGallery.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTable.js +1 -2
- package/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/dist/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/dist/components/TariffsTable/TariffsTableVertical.js.map +1 -1
- package/dist/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/dist/components/VerticalLayout/VerticalLayout.js +6 -2
- package/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/dist/icons/IconName.d.ts +16 -2
- package/dist/icons/IconName.js +14 -0
- package/dist/icons/IconName.js.map +1 -1
- package/dist/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/dist/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/dist/ui-kit/DatePicker/DatePicker.js +4 -4
- package/dist/ui-kit/DatePicker/DatePicker.js.map +1 -1
- package/dist/ui-kit/DatePicker/getYears.js +1 -1
- package/dist/ui-kit/Input/Input.js +1 -1
- package/dist/ui-kit/Input/Input.js.map +1 -1
- package/dist/ui-kit/NotFound/NotFound.js +1 -1
- package/dist/ui-kit/NotFound/NotFound.js.map +1 -1
- package/dist/ui-kit/SearchDialog/SearchInput.js +1 -1
- package/dist/ui-kit/Select/Select.js +1 -1
- package/dist/ui-kit/Select/Select.js.map +1 -1
- package/dist/utils/getBorderStyle.d.ts +1 -0
- package/dist/utils/getBorderStyle.js +7 -0
- package/dist/utils/getBorderStyle.js.map +1 -0
- package/{mobile/bundle/api/CorporateLeadAPI.d.ts → lib/api/LeadServiceAPI.d.ts} +2 -2
- package/lib/api/{CorporateLeadAPI.js → LeadServiceAPI.js} +5 -4
- package/lib/api/LeadServiceAPI.js.map +1 -0
- package/lib/common.css +1 -1
- package/lib/components/ApplicationForm/ApplicationForm.fixture.d.ts +1 -0
- package/lib/components/ApplicationForm/ApplicationForm.fixture.mobile.d.ts +1 -0
- package/lib/components/ApplicationForm/ApplicationForm.js +4 -4
- package/lib/components/ApplicationForm/ApplicationForm.js.map +1 -1
- package/lib/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/lib/components/ApplicationForm/ApplicationFormDeposit.js +1 -2
- package/lib/components/ApplicationForm/ApplicationFormDeposit.js.map +1 -1
- package/lib/components/ApplicationForm/ApplicationFormGrantSupport.js +1 -1
- package/lib/components/ApplicationForm/ApplicationFormGrantSupport.js.map +1 -1
- package/lib/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/lib/components/ApplicationForm/ApplicationFormIndividuals.js +50 -0
- package/lib/components/ApplicationForm/ApplicationFormIndividuals.js.map +1 -0
- package/lib/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/lib/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/lib/components/ApplicationForm/DatePickerControl.js +6 -0
- package/lib/components/ApplicationForm/DatePickerControl.js.map +1 -0
- package/lib/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/lib/components/ApplicationForm/EmbeddableForms.js +2 -0
- package/lib/components/ApplicationForm/EmbeddableForms.js.map +1 -1
- package/lib/components/ApplicationForm/Footnote.d.ts +1 -0
- package/lib/components/ApplicationForm/Footnote.js +1 -1
- package/lib/components/ApplicationForm/Footnote.js.map +1 -1
- package/lib/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/lib/components/ApplicationForm/IndividualsFormState.js +2 -0
- package/lib/components/ApplicationForm/IndividualsFormState.js.map +1 -0
- package/lib/components/ApplicationForm/renderIndividualsFields.d.ts +3 -0
- package/lib/components/ApplicationForm/renderIndividualsFields.js +8 -0
- package/lib/components/ApplicationForm/renderIndividualsFields.js.map +1 -0
- package/lib/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/lib/components/Blocks.js +0 -2
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Bonus/BonusContent.d.ts +1 -0
- package/lib/components/Calculator/Calculator.mobile.js +6 -5
- package/lib/components/Calculator/Calculator.mobile.js.map +1 -1
- package/lib/components/Calculator/CalculatorContent.d.ts +3 -0
- package/lib/components/Carousel/renderCarouselCards.js +2 -2
- package/lib/components/Carousel/renderCarouselCards.js.map +1 -1
- package/lib/components/CarouselCard/CarouselCard.js +1 -1
- package/lib/components/CarouselCard/CarouselCard.js.map +1 -1
- package/lib/components/CarouselCard/titleSize.d.ts +1 -1
- package/lib/components/CarouselCard/titleSize.js +1 -1
- package/lib/components/CarouselCard/titleSize.js.map +1 -1
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +1 -1
- package/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/lib/components/Footer/Footer.mobile.js +2 -2
- package/lib/components/Footer/Footer.mobile.js.map +1 -1
- package/lib/components/Footer/HorizontalNavigation.mobile.js +2 -1
- package/lib/components/Footer/HorizontalNavigation.mobile.js.map +1 -1
- package/lib/components/Footer/SocialMedia.js +3 -3
- package/lib/components/Footer/SocialMedia.js.map +1 -1
- package/lib/components/Footer/iconsMap.js +4 -0
- package/lib/components/Footer/iconsMap.js.map +1 -1
- package/lib/components/HorizontalLayout/HorizontalLayout.js +2 -3
- package/lib/components/HorizontalLayout/HorizontalLayout.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocItem.js +6 -14
- package/lib/components/LinkDocs/LinkDocItem.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocs.js +4 -3
- package/lib/components/LinkDocs/LinkDocs.js.map +1 -1
- package/lib/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/lib/components/LinkDocs/linkDocsContentExample.js +14 -5
- package/lib/components/LinkDocs/linkDocsContentExample.js.map +1 -1
- package/lib/components/MobileAppTile/MobileAppTile.js +2 -2
- package/lib/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/lib/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/lib/components/MobileAppTile/renderList.d.ts +1 -1
- package/lib/components/MobileAppTile/renderList.js +3 -2
- package/lib/components/MobileAppTile/renderList.js.map +1 -1
- package/lib/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/lib/components/ProductBlock/ProductBlock.js +2 -4
- package/lib/components/ProductBlock/ProductBlock.js.map +1 -1
- package/lib/components/ProductGallery/ProductGallery.js +1 -1
- package/lib/components/ProductGallery/ProductGallery.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTable.js +1 -2
- package/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/lib/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/lib/components/TariffsTable/TariffsTableVertical.js.map +1 -1
- package/lib/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/lib/components/VerticalLayout/VerticalLayout.js +6 -2
- package/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/lib/icons/IconName.d.ts +16 -2
- package/lib/icons/IconName.js +14 -0
- package/lib/icons/IconName.js.map +1 -1
- package/lib/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/lib/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/lib/ui-kit/DatePicker/DatePicker.js +4 -4
- package/lib/ui-kit/DatePicker/DatePicker.js.map +1 -1
- package/lib/ui-kit/DatePicker/getYears.js +1 -1
- package/lib/ui-kit/Input/Input.js +1 -1
- package/lib/ui-kit/Input/Input.js.map +1 -1
- package/lib/ui-kit/NotFound/NotFound.js +1 -1
- package/lib/ui-kit/NotFound/NotFound.js.map +1 -1
- package/lib/ui-kit/SearchDialog/SearchInput.js +1 -1
- package/lib/ui-kit/Select/Select.js +1 -1
- package/lib/ui-kit/Select/Select.js.map +1 -1
- package/lib/utils/getBorderStyle.d.ts +1 -0
- package/lib/utils/getBorderStyle.js +4 -0
- package/lib/utils/getBorderStyle.js.map +1 -0
- package/{dist/api/CorporateLeadAPI.d.ts → mobile/bundle/api/LeadServiceAPI.d.ts} +2 -2
- package/mobile/bundle/bundle.umd.js +290 -95
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/mobile/bundle/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/mobile/bundle/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/mobile/bundle/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/mobile/bundle/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/mobile/bundle/components/ApplicationForm/Footnote.d.ts +1 -0
- package/mobile/bundle/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/mobile/bundle/components/ApplicationForm/renderIndividualsFields.d.ts +4 -0
- package/mobile/bundle/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/mobile/bundle/components/Bonus/BonusContent.d.ts +1 -0
- package/mobile/bundle/components/Calculator/CalculatorContent.d.ts +3 -0
- package/mobile/bundle/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/mobile/bundle/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/mobile/bundle/components/MobileAppTile/renderList.d.ts +1 -1
- package/mobile/bundle/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/mobile/bundle/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/mobile/bundle/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/mobile/bundle/icons/IconName.d.ts +16 -2
- package/mobile/bundle/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/mobile/bundle/utils/getBorderStyle.d.ts +1 -0
- package/mobile/dist/api/LeadServiceAPI.d.ts +15 -0
- package/mobile/dist/api/{CorporateLeadAPI.js → LeadServiceAPI.js} +7 -6
- package/mobile/dist/api/LeadServiceAPI.js.map +1 -0
- package/mobile/dist/components/ApplicationForm/ApplicationForm.js +4 -4
- package/mobile/dist/components/ApplicationForm/ApplicationForm.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormDeposit.js +1 -2
- package/mobile/dist/components/ApplicationForm/ApplicationFormDeposit.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormGrantSupport.js +1 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormGrantSupport.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/mobile/dist/components/ApplicationForm/ApplicationFormIndividuals.js +52 -0
- package/mobile/dist/components/ApplicationForm/ApplicationFormIndividuals.js.map +1 -0
- package/mobile/dist/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/mobile/dist/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/mobile/dist/components/ApplicationForm/DatePickerControl.js +8 -0
- package/mobile/dist/components/ApplicationForm/DatePickerControl.js.map +1 -0
- package/mobile/dist/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/mobile/dist/components/ApplicationForm/EmbeddableForms.js +2 -0
- package/mobile/dist/components/ApplicationForm/EmbeddableForms.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/Footnote.d.ts +1 -0
- package/mobile/dist/components/ApplicationForm/Footnote.js +1 -1
- package/mobile/dist/components/ApplicationForm/Footnote.js.map +1 -1
- package/mobile/dist/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/mobile/dist/components/{PromoTile/PromoTileContent.js → ApplicationForm/IndividualsFormState.js} +1 -1
- package/mobile/dist/components/ApplicationForm/IndividualsFormState.js.map +1 -0
- package/mobile/dist/components/ApplicationForm/renderIndividualsFields.d.ts +4 -0
- package/mobile/dist/components/ApplicationForm/renderIndividualsFields.js +11 -0
- package/mobile/dist/components/ApplicationForm/renderIndividualsFields.js.map +1 -0
- package/mobile/dist/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/mobile/dist/components/Bonus/BonusContent.d.ts +1 -0
- package/mobile/dist/components/Calculator/Calculator.js +6 -5
- package/mobile/dist/components/Calculator/Calculator.js.map +1 -1
- package/mobile/dist/components/Calculator/CalculatorContent.d.ts +3 -0
- package/mobile/dist/components/Carousel/renderCarouselCards.js +2 -2
- package/mobile/dist/components/Carousel/renderCarouselCards.js.map +1 -1
- package/mobile/dist/components/CarouselCard/CarouselCard.js +1 -1
- package/mobile/dist/components/CarouselCard/CarouselCard.js.map +1 -1
- package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js +1 -1
- package/mobile/dist/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/mobile/dist/components/Footer/Footer.js +2 -2
- package/mobile/dist/components/Footer/Footer.js.map +1 -1
- package/mobile/dist/components/Footer/HorizontalNavigation.js +2 -1
- package/mobile/dist/components/Footer/HorizontalNavigation.js.map +1 -1
- package/mobile/dist/components/Footer/SocialMedia.js +3 -3
- package/mobile/dist/components/Footer/SocialMedia.js.map +1 -1
- package/mobile/dist/components/Footer/iconsMap.js +4 -0
- package/mobile/dist/components/Footer/iconsMap.js.map +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocItem.js +6 -14
- package/mobile/dist/components/LinkDocs/LinkDocItem.js.map +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocs.js +4 -3
- package/mobile/dist/components/LinkDocs/LinkDocs.js.map +1 -1
- package/mobile/dist/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/mobile/dist/components/LinkDocs/linkDocsContentExample.js +14 -5
- package/mobile/dist/components/LinkDocs/linkDocsContentExample.js.map +1 -1
- package/mobile/dist/components/MobileAppTile/MobileAppTile.js +2 -2
- package/mobile/dist/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/mobile/dist/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/mobile/dist/components/MobileAppTile/renderList.d.ts +1 -1
- package/mobile/dist/components/MobileAppTile/renderList.js +3 -2
- package/mobile/dist/components/MobileAppTile/renderList.js.map +1 -1
- package/mobile/dist/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/mobile/dist/components/ProductBlock/ProductBlock.js +2 -4
- package/mobile/dist/components/ProductBlock/ProductBlock.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTable.js +1 -2
- package/mobile/dist/components/TariffsTable/TariffsTable.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/mobile/dist/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/mobile/dist/components/TariffsTable/TariffsTableVertical.js.map +1 -1
- package/mobile/dist/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/mobile/dist/components/VerticalLayout/VerticalLayout.js +6 -2
- package/mobile/dist/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/mobile/dist/icons/IconName.d.ts +16 -2
- package/mobile/dist/icons/IconName.js +14 -0
- package/mobile/dist/icons/IconName.js.map +1 -1
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/dist/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/mobile/dist/ui-kit/DatePicker/DatePicker.js +4 -4
- package/mobile/dist/ui-kit/DatePicker/DatePicker.js.map +1 -1
- package/mobile/dist/ui-kit/DatePicker/getYears.js +1 -1
- package/mobile/dist/ui-kit/Input/Input.js +1 -1
- package/mobile/dist/ui-kit/Input/Input.js.map +1 -1
- package/mobile/dist/ui-kit/NotFound/NotFound.js +1 -1
- package/mobile/dist/ui-kit/NotFound/NotFound.js.map +1 -1
- package/mobile/dist/ui-kit/SearchDialog/SearchInput.js +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/dist/utils/getBorderStyle.d.ts +1 -0
- package/mobile/dist/utils/getBorderStyle.js +7 -0
- package/mobile/dist/utils/getBorderStyle.js.map +1 -0
- package/mobile/lib/api/LeadServiceAPI.d.ts +15 -0
- package/mobile/lib/api/{CorporateLeadAPI.js → LeadServiceAPI.js} +5 -4
- package/mobile/lib/api/LeadServiceAPI.js.map +1 -0
- package/mobile/lib/common.css +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationForm.js +4 -4
- package/mobile/lib/components/ApplicationForm/ApplicationForm.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormContent.d.ts +11 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormDeposit.js +1 -2
- package/mobile/lib/components/ApplicationForm/ApplicationFormDeposit.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormGrantSupport.js +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormGrantSupport.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/ApplicationFormIndividuals.d.ts +2 -0
- package/mobile/lib/components/ApplicationForm/ApplicationFormIndividuals.js +50 -0
- package/mobile/lib/components/ApplicationForm/ApplicationFormIndividuals.js.map +1 -0
- package/mobile/lib/components/ApplicationForm/ApplicationFormsProps.d.ts +2 -1
- package/mobile/lib/components/ApplicationForm/DatePickerControl.d.ts +8 -0
- package/mobile/lib/components/ApplicationForm/DatePickerControl.js +6 -0
- package/mobile/lib/components/ApplicationForm/DatePickerControl.js.map +1 -0
- package/mobile/lib/components/ApplicationForm/EmbeddableForms.d.ts +1 -0
- package/mobile/lib/components/ApplicationForm/EmbeddableForms.js +2 -0
- package/mobile/lib/components/ApplicationForm/EmbeddableForms.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/Footnote.d.ts +1 -0
- package/mobile/lib/components/ApplicationForm/Footnote.js +1 -1
- package/mobile/lib/components/ApplicationForm/Footnote.js.map +1 -1
- package/mobile/lib/components/ApplicationForm/IndividualsFormState.d.ts +9 -0
- package/mobile/lib/components/ApplicationForm/IndividualsFormState.js +2 -0
- package/mobile/lib/components/ApplicationForm/IndividualsFormState.js.map +1 -0
- package/mobile/lib/components/ApplicationForm/renderIndividualsFields.d.ts +4 -0
- package/mobile/lib/components/ApplicationForm/renderIndividualsFields.js +8 -0
- package/mobile/lib/components/ApplicationForm/renderIndividualsFields.js.map +1 -0
- package/mobile/lib/components/BenefitsBlock/BenefitsBlockContent.d.ts +1 -0
- package/mobile/lib/components/Bonus/BonusContent.d.ts +1 -0
- package/mobile/lib/components/Calculator/Calculator.js +6 -5
- package/mobile/lib/components/Calculator/Calculator.js.map +1 -1
- package/mobile/lib/components/Calculator/CalculatorContent.d.ts +3 -0
- package/mobile/lib/components/Carousel/renderCarouselCards.js +2 -2
- package/mobile/lib/components/Carousel/renderCarouselCards.js.map +1 -1
- package/mobile/lib/components/CarouselCard/CarouselCard.js +1 -1
- package/mobile/lib/components/CarouselCard/CarouselCard.js.map +1 -1
- package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js +1 -1
- package/mobile/lib/components/CarouselTariffsCard/CarouselTariffsCard.js.map +1 -1
- package/mobile/lib/components/Footer/Footer.js +2 -2
- package/mobile/lib/components/Footer/Footer.js.map +1 -1
- package/mobile/lib/components/Footer/HorizontalNavigation.js +2 -1
- package/mobile/lib/components/Footer/HorizontalNavigation.js.map +1 -1
- package/mobile/lib/components/Footer/SocialMedia.js +3 -3
- package/mobile/lib/components/Footer/SocialMedia.js.map +1 -1
- package/mobile/lib/components/Footer/iconsMap.js +4 -0
- package/mobile/lib/components/Footer/iconsMap.js.map +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocItem.js +6 -14
- package/mobile/lib/components/LinkDocs/LinkDocItem.js.map +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocs.js +4 -3
- package/mobile/lib/components/LinkDocs/LinkDocs.js.map +1 -1
- package/mobile/lib/components/LinkDocs/LinkDocsContent.d.ts +6 -0
- package/mobile/lib/components/LinkDocs/linkDocsContentExample.js +14 -5
- package/mobile/lib/components/LinkDocs/linkDocsContentExample.js.map +1 -1
- package/mobile/lib/components/MobileAppTile/MobileAppTile.js +2 -2
- package/mobile/lib/components/MobileAppTile/MobileAppTile.js.map +1 -1
- package/mobile/lib/components/MobileAppTile/MobileAppTileContent.d.ts +2 -2
- package/mobile/lib/components/MobileAppTile/renderList.d.ts +1 -1
- package/mobile/lib/components/MobileAppTile/renderList.js +3 -2
- package/mobile/lib/components/MobileAppTile/renderList.js.map +1 -1
- package/mobile/lib/components/OfficesAtmsMap/OfficesAtmsMapContent.d.ts +2 -0
- package/mobile/lib/components/ProductBlock/ProductBlock.js +2 -4
- package/mobile/lib/components/ProductBlock/ProductBlock.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTable.js +1 -2
- package/mobile/lib/components/TariffsTable/TariffsTable.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableCell.js.map +1 -1
- package/mobile/lib/components/TariffsTable/TariffsTableContent.d.ts +1 -0
- package/mobile/lib/components/TariffsTable/TariffsTableVertical.js.map +1 -1
- package/mobile/lib/components/VerticalLayout/VerticalLayout.d.ts +1 -0
- package/mobile/lib/components/VerticalLayout/VerticalLayout.js +6 -2
- package/mobile/lib/components/VerticalLayout/VerticalLayout.js.map +1 -1
- package/mobile/lib/icons/IconName.d.ts +16 -2
- package/mobile/lib/icons/IconName.js +14 -0
- package/mobile/lib/icons/IconName.js.map +1 -1
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js +1 -1
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/lib/ui-kit/DatePicker/DatePicker.d.ts +1 -0
- package/mobile/lib/ui-kit/DatePicker/DatePicker.js +4 -4
- package/mobile/lib/ui-kit/DatePicker/DatePicker.js.map +1 -1
- package/mobile/lib/ui-kit/DatePicker/getYears.js +1 -1
- package/mobile/lib/ui-kit/Input/Input.js +1 -1
- package/mobile/lib/ui-kit/Input/Input.js.map +1 -1
- package/mobile/lib/ui-kit/NotFound/NotFound.js +1 -1
- package/mobile/lib/ui-kit/NotFound/NotFound.js.map +1 -1
- package/mobile/lib/ui-kit/SearchDialog/SearchInput.js +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/lib/utils/getBorderStyle.d.ts +1 -0
- package/mobile/lib/utils/getBorderStyle.js +4 -0
- package/mobile/lib/utils/getBorderStyle.js.map +1 -0
- package/mobile/src/api/{CorporateLeadAPI.ts → LeadServiceAPI.ts} +5 -3
- package/mobile/src/components/ApplicationForm/ApplicationForm.tsx +14 -8
- package/mobile/src/components/ApplicationForm/ApplicationForm.ui.json +5 -2
- package/mobile/src/components/ApplicationForm/ApplicationFormContent.ts +13 -1
- package/mobile/src/components/ApplicationForm/ApplicationFormDeposit.tsx +1 -3
- package/mobile/src/components/ApplicationForm/ApplicationFormGrantSupport.tsx +1 -1
- package/mobile/src/components/ApplicationForm/ApplicationFormIndividuals.tsx +74 -0
- package/mobile/src/components/ApplicationForm/ApplicationFormsProps.ts +2 -1
- package/mobile/src/components/ApplicationForm/DatePickerControl.tsx +33 -0
- package/mobile/src/components/ApplicationForm/EmbeddableForms.tsx +2 -0
- package/mobile/src/components/ApplicationForm/Footnote.tsx +3 -2
- package/mobile/src/components/ApplicationForm/IndividualsFormState.ts +9 -0
- package/mobile/src/components/ApplicationForm/renderIndividualsFields.tsx +46 -0
- package/mobile/src/components/BenefitsBlock/BenefitsBlockContent.ts +1 -0
- package/mobile/src/components/Bonus/BonusContent.ts +1 -0
- package/mobile/src/components/Calculator/Calculator.tsx +9 -9
- package/mobile/src/components/Calculator/CalculatorContent.ts +3 -0
- package/mobile/src/components/Carousel/renderCarouselCards.tsx +3 -2
- package/mobile/src/components/CarouselCard/CarouselCard.tsx +1 -1
- package/mobile/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +2 -2
- package/mobile/src/components/Footer/Footer.tsx +7 -5
- package/mobile/src/components/Footer/HorizontalNavigation.tsx +2 -1
- package/mobile/src/components/Footer/SocialMedia.tsx +8 -8
- package/mobile/src/components/Footer/iconsMap.ts +4 -0
- package/mobile/src/components/LinkDocs/LinkDocItem.tsx +24 -34
- package/mobile/src/components/LinkDocs/LinkDocs.example.json +4 -1
- package/mobile/src/components/LinkDocs/LinkDocs.tsx +5 -3
- package/mobile/src/components/LinkDocs/LinkDocsContent.ts +6 -0
- package/mobile/src/components/LinkDocs/linkDocsContentExample.ts +14 -5
- package/mobile/src/components/MobileAppTile/MobileAppTile.example.json +2 -1
- package/mobile/src/components/MobileAppTile/MobileAppTile.tsx +2 -1
- package/mobile/src/components/MobileAppTile/MobileAppTileContent.ts +5 -1
- package/mobile/src/components/MobileAppTile/renderList.tsx +9 -4
- package/mobile/src/components/OfficesAtmsMap/OfficesAtmsMap.ui.json +16 -1
- package/mobile/src/components/OfficesAtmsMap/OfficesAtmsMapContent.ts +2 -0
- package/mobile/src/components/ProductBlock/ProductBlock.tsx +2 -4
- package/mobile/src/components/ProductGallery/ProductGallery.example.json +1 -1
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.example.json +1 -0
- package/mobile/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.ui.json +1 -0
- package/mobile/src/components/TariffsTable/TariffsTable.tsx +2 -3
- package/mobile/src/components/TariffsTable/TariffsTableCell.tsx +0 -1
- package/mobile/src/components/TariffsTable/TariffsTableContent.ts +1 -0
- package/mobile/src/components/TariffsTable/TariffsTableVertical.tsx +0 -1
- package/mobile/src/components/VerticalLayout/VerticalLayout.tsx +9 -2
- package/mobile/src/icons/CardSendIcon.svg +9 -0
- package/mobile/src/icons/CoinIcon.svg +5 -0
- package/mobile/src/icons/ConvertCardIcon.svg +8 -0
- package/mobile/src/icons/DzenIcon.svg +4 -0
- package/mobile/src/icons/HeartTickIcon.svg +5 -0
- package/mobile/src/icons/IconName.ts +4 -4
- package/mobile/src/icons/NotificationBingIcon.svg +5 -0
- package/mobile/src/icons/Security/320/241ardIcon.svg +7 -0
- package/mobile/src/ui-kit/BenefitItem/BenefitItem.tsx +1 -7
- package/mobile/src/ui-kit/DatePicker/DatePicker.tsx +13 -5
- package/mobile/src/ui-kit/DatePicker/getYears.ts +1 -1
- package/mobile/src/ui-kit/Input/Input.tsx +1 -1
- package/mobile/src/ui-kit/NotFound/NotFound.tsx +1 -1
- package/mobile/src/ui-kit/SearchDialog/SearchInput.tsx +1 -1
- package/mobile/src/ui-kit/Select/Select.tsx +1 -1
- package/mobile/src/utils/getBorderStyle.ts +4 -0
- package/package.json +1 -1
- package/src/api/{CorporateLeadAPI.ts → LeadServiceAPI.ts} +5 -3
- package/src/components/ApplicationForm/ApplicationForm.fixture.mobile.tsx +14 -0
- package/src/components/ApplicationForm/ApplicationForm.fixture.tsx +14 -0
- package/src/components/ApplicationForm/ApplicationForm.tsx +14 -8
- package/src/components/ApplicationForm/ApplicationForm.ui.json +5 -2
- package/src/components/ApplicationForm/ApplicationFormContent.ts +13 -1
- package/src/components/ApplicationForm/ApplicationFormDeposit.tsx +1 -3
- package/src/components/ApplicationForm/ApplicationFormGrantSupport.tsx +1 -1
- package/src/components/ApplicationForm/ApplicationFormIndividuals.tsx +74 -0
- package/src/components/ApplicationForm/ApplicationFormsProps.ts +2 -1
- package/src/components/ApplicationForm/DatePickerControl.tsx +33 -0
- package/src/components/ApplicationForm/EmbeddableForms.tsx +2 -0
- package/src/components/ApplicationForm/Footnote.tsx +3 -2
- package/src/components/ApplicationForm/IndividualsFormState.ts +9 -0
- package/src/components/ApplicationForm/renderIndividualsFields.tsx +46 -0
- package/src/components/BenefitsBlock/BenefitsBlockContent.ts +1 -0
- package/src/components/Blocks.ts +0 -2
- package/src/components/Bonus/BonusContent.ts +1 -0
- package/src/components/Calculator/Calculator.mobile.tsx +9 -9
- package/src/components/Calculator/CalculatorContent.ts +3 -0
- package/src/components/Carousel/renderCarouselCards.tsx +3 -2
- package/src/components/CarouselCard/CarouselCard.tsx +1 -1
- package/src/components/CarouselCard/titleSize.tsx +1 -1
- package/src/components/CarouselTariffsCard/CarouselTariffsCard.tsx +2 -2
- package/src/components/Footer/Footer.mobile.tsx +7 -5
- package/src/components/Footer/HorizontalNavigation.mobile.tsx +2 -1
- package/src/components/Footer/SocialMedia.tsx +8 -8
- package/src/components/Footer/iconsMap.ts +4 -0
- package/src/components/HorizontalLayout/HorizontalLayout.tsx +2 -3
- package/src/components/LinkDocs/LinkDocItem.tsx +24 -34
- package/src/components/LinkDocs/LinkDocs.example.json +4 -1
- package/src/components/LinkDocs/LinkDocs.tsx +5 -3
- package/src/components/LinkDocs/LinkDocsContent.ts +6 -0
- package/src/components/LinkDocs/linkDocsContentExample.ts +14 -5
- package/src/components/MobileAppTile/MobileAppTile.example.json +2 -1
- package/src/components/MobileAppTile/MobileAppTile.fixture.mobile.tsx +3 -1
- package/src/components/MobileAppTile/MobileAppTile.tsx +2 -1
- package/src/components/MobileAppTile/MobileAppTileContent.ts +5 -1
- package/src/components/MobileAppTile/renderList.tsx +9 -4
- package/src/components/OfficesAtmsMap/OfficesAtmsMap.ui.json +16 -1
- package/src/components/OfficesAtmsMap/OfficesAtmsMapContent.ts +2 -0
- package/src/components/ProductBlock/ProductBlock.tsx +2 -4
- package/src/components/ProductGallery/ProductGallery.example.json +1 -1
- package/src/components/ProductGallery/ProductGallery.tsx +1 -1
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.example.json +1 -0
- package/src/components/RepresentativeOfficeInfo/RepresentativeOfficeInfo.ui.json +1 -0
- package/src/components/TariffsTable/TariffsTable.tsx +2 -3
- package/src/components/TariffsTable/TariffsTableCell.tsx +0 -1
- package/src/components/TariffsTable/TariffsTableContent.ts +1 -0
- package/src/components/TariffsTable/TariffsTableVertical.tsx +0 -1
- package/src/components/VerticalLayout/VerticalLayout.tsx +9 -2
- package/src/icons/CardSendIcon.svg +9 -0
- package/src/icons/CoinIcon.svg +5 -0
- package/src/icons/ConvertCardIcon.svg +8 -0
- package/src/icons/DzenIcon.svg +4 -0
- package/src/icons/HeartTickIcon.svg +5 -0
- package/src/icons/IconName.ts +22 -1
- package/src/icons/NotificationBingIcon.svg +5 -0
- package/src/icons/Security/320/241ardIcon.svg +7 -0
- package/src/ui-kit/BenefitItem/BenefitItem.tsx +1 -7
- package/src/ui-kit/DatePicker/DatePicker.tsx +13 -5
- package/src/ui-kit/DatePicker/getYears.ts +1 -1
- package/src/ui-kit/Input/Input.tsx +1 -1
- package/src/ui-kit/NotFound/NotFound.tsx +1 -1
- package/src/ui-kit/SearchDialog/SearchInput.tsx +1 -1
- package/src/ui-kit/Select/Select.tsx +1 -1
- package/src/utils/getBorderStyle.ts +4 -0
- package/bundle/components/PromoTile/PromoTile.d.ts +0 -5
- package/bundle/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/bundle/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/bundle/components/TariffsTable/headlineAlign.mobile.d.ts +0 -1
- package/dist/api/CorporateLeadAPI.js.map +0 -1
- package/dist/components/PromoTile/PromoTile.d.ts +0 -5
- package/dist/components/PromoTile/PromoTile.js +0 -20
- package/dist/components/PromoTile/PromoTile.js.map +0 -1
- package/dist/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/dist/components/PromoTile/PromoTileContent.js.map +0 -1
- package/dist/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/dist/components/TariffsTable/headlineAlign.js +0 -4
- package/dist/components/TariffsTable/headlineAlign.js.map +0 -1
- package/dist/components/TariffsTable/headlineAlign.mobile.d.ts +0 -1
- package/dist/components/TariffsTable/headlineAlign.mobile.js +0 -4
- package/dist/components/TariffsTable/headlineAlign.mobile.js.map +0 -1
- package/lib/api/CorporateLeadAPI.js.map +0 -1
- package/lib/components/PromoTile/PromoTile.d.ts +0 -5
- package/lib/components/PromoTile/PromoTile.fixture.d.ts +0 -6
- package/lib/components/PromoTile/PromoTile.js +0 -18
- package/lib/components/PromoTile/PromoTile.js.map +0 -1
- package/lib/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/lib/components/PromoTile/PromoTileContent.js +0 -2
- package/lib/components/PromoTile/PromoTileContent.js.map +0 -1
- package/lib/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/lib/components/TariffsTable/headlineAlign.js +0 -2
- package/lib/components/TariffsTable/headlineAlign.js.map +0 -1
- package/lib/components/TariffsTable/headlineAlign.mobile.d.ts +0 -1
- package/lib/components/TariffsTable/headlineAlign.mobile.js +0 -2
- package/lib/components/TariffsTable/headlineAlign.mobile.js.map +0 -1
- package/mobile/bundle/components/PromoTile/PromoTile.d.ts +0 -5
- package/mobile/bundle/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/mobile/bundle/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/mobile/dist/api/CorporateLeadAPI.d.ts +0 -15
- package/mobile/dist/api/CorporateLeadAPI.js.map +0 -1
- package/mobile/dist/components/PromoTile/PromoTile.d.ts +0 -5
- package/mobile/dist/components/PromoTile/PromoTile.js +0 -20
- package/mobile/dist/components/PromoTile/PromoTile.js.map +0 -1
- package/mobile/dist/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/mobile/dist/components/PromoTile/PromoTileContent.js.map +0 -1
- package/mobile/dist/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/mobile/dist/components/TariffsTable/headlineAlign.js +0 -4
- package/mobile/dist/components/TariffsTable/headlineAlign.js.map +0 -1
- package/mobile/lib/api/CorporateLeadAPI.d.ts +0 -15
- package/mobile/lib/api/CorporateLeadAPI.js.map +0 -1
- package/mobile/lib/components/PromoTile/PromoTile.d.ts +0 -5
- package/mobile/lib/components/PromoTile/PromoTile.js +0 -18
- package/mobile/lib/components/PromoTile/PromoTile.js.map +0 -1
- package/mobile/lib/components/PromoTile/PromoTileContent.d.ts +0 -10
- package/mobile/lib/components/PromoTile/PromoTileContent.js +0 -2
- package/mobile/lib/components/PromoTile/PromoTileContent.js.map +0 -1
- package/mobile/lib/components/TariffsTable/headlineAlign.d.ts +0 -1
- package/mobile/lib/components/TariffsTable/headlineAlign.js +0 -2
- package/mobile/lib/components/TariffsTable/headlineAlign.js.map +0 -1
- package/mobile/src/components/PromoTile/PromoTile.example.json +0 -16
- package/mobile/src/components/PromoTile/PromoTile.tsx +0 -53
- package/mobile/src/components/PromoTile/PromoTile.ui.json +0 -1
- package/mobile/src/components/PromoTile/PromoTileContent.ts +0 -14
- package/mobile/src/components/TariffsTable/headlineAlign.tsx +0 -1
- package/src/components/PromoTile/PromoTile.example.json +0 -16
- package/src/components/PromoTile/PromoTile.fixture.tsx +0 -25
- package/src/components/PromoTile/PromoTile.tsx +0 -53
- package/src/components/PromoTile/PromoTile.ui.json +0 -1
- package/src/components/PromoTile/PromoTileContent.ts +0 -14
- package/src/components/TariffsTable/headlineAlign.mobile.tsx +0 -1
- package/src/components/TariffsTable/headlineAlign.tsx +0 -1
package/bundle/bundle.umd.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";let t;const l=e=>(...l)=>t[e](...l),n=l("useState"),a=l("useEffect"),i=l("useCallback"),r=l("useMemo"),s=l("useRef");const o=e=>e&&!e.endsWith("/")?`${e}/`:e,c={PROD_BRANCH:"master"},d=new class{_=c;setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH||c.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get STICKY_MOBILE_MENU(){return this._.STICKY_MOBILE_MENU}get FOOTER(){return this._.FOOTER}get PORTAL_DATA(){return this._.PORTAL_DATA}get CHAT_BOT(){return this._.CHAT_BOT}get CDN(){return o(this._.CDN)}get BASE_PATH(){return o(this._.BASE_PATH)}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},m="likesToken";function h(){async function e(){try{const e=JSON.parse(globalThis.localStorage?.getItem(m)||"");if(e?.token)return e}catch(e){}try{const e=await fetch("/assist/v1/public/auth",{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:t,name:l}=await e.json();return globalThis.localStorage?.setItem(m,JSON.stringify({token:t,name:l})),{token:t,name:l}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:l}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l},body:JSON.stringify({node_ids:t})}),{likes:n}=await e.json();return n||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}}}}const u=(...e)=>globalThis._uni._jsx(...e),p=(...e)=>globalThis._uni._jsxs(...e),x=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:g(e)),t._tmpl},g=e=>{function t(t,l){const{children:n,...a}=t||{},i=l?.slots?.default,r=n||i&&i();return e(Object.assign(a,r&&{children:r}),l)}return t.inheritAttrs=!1,t};class f{subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]=(this.subscribers[e]||[]).concat(t);const l=this.subjectsStateMap[e];return l&&t(l),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){e in this.subjectsStateMap&&(this.subjectsStateMap[e]=t),this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=new f;function y(e,{sensitivity:t,rootRef:l}={}){const n=s(null),i=r((()=>({threshold:v(t),root:l?.current})),[t,l?.current]);return a((()=>{if(!n.current)return;const t=new IntersectionObserver(e,i);return t.observe(n.current),()=>{t.disconnect()}}),[e,i]),n}function v(e=0){const t=Math.round(10*e);return new Array(t).fill(0).map(((e,l)=>Math.min(l/t)),1).concat(1)}const N=new f;const w=(...e)=>e.flatMap((e=>e)).filter(Boolean).join(" "),k={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white",gray:"bg-main-divider text-primary-text",transparent:"bg-transparent text-primary-text","":""},C=x((({className:e,version:t="primary",isTheme:l=!0,defaultPadding:r="p-xl",padding:s,block:o,tag:c="section",role:d,children:m})=>{const h=c,p=function(e){return y(i((t=>{if(!e||!t?.length)return;const l=t[t.length-1];N.fire("intersection",{block:e,intersection:l})}),[e]),{sensitivity:1})}(o),[x,g]=n(!1);a((()=>b.subscribe("tab",(e=>{g(Boolean(e.label&&o?.labels?.length&&!o.labels.includes(e.label)))}))),[o]);const f=t&&l;return u(h,{className:w("@container font-sans",f?"group":"",k[t],x?"hidden":"",s||r,e),...f?{"data-ver":t}:{},...o?.anchor?{id:o.anchor,ref:p}:{},role:d,children:m})})),S={h0:"text-h0",h1:"text-h1",h2:"text-h2",h3:"text-h3",h4:"text-h4",h5:"text-h5",h6:"text-h6"},I=x((({className:e="",headingType:t="h3",as:l="h3",title:n,children:a})=>u(l,{className:w("font-sans m-0",S[t],e),children:n||a}))),T=e=>e,B=(e,t)=>{const[l,a]=n(e),[r,o]=n(!1),[c,d]=n({}),m=s({}),h=i(((e,t)=>{const{parse:n=T,format:i=T}=t||{};return m.current||(m.current={}),m.current[e]||=t=>{a((l=>({...l,[e]:n(t)}))),d((t=>({...t,[e]:!0})))},{value:i(l[e]),isDirty:r||c[e],onChange:m.current[e]}}),[l,r,c]),u=i((e=>{a(e),d(e)}),[]),p=i((()=>{a(e),o(!1),d({})}),[e]),x=i((e=>{e.preventDefault(),o(!0),t&&t(l)}),[t,l]);return[l,{isDirty:r||Object.values(c).some(Boolean),field:h,update:u,reset:p,onSubmit:x}]},M=e=>t=>t&&Object.entries(e).flatMap((([e,l])=>l(t[e])))||[],P=e=>!e?.length,R=e=>t=>l=>e(l)?[]:[t],V=e=>null!=e,z=new Map;function A(e,t,{fallback:l,cache:i}={}){const s=r((()=>D(e)),[e]),[o]=(e=>Boolean(e&&Array.isArray(e)&&1===e.length&&"string"==typeof e[0]))(s)?s:[],[c,d]=n(void 0),[m,h]=n(void 0);a((()=>{if(!s.some(V))return;let e=!1;const l=(t,l)=>{e||(d(t),h(l))};return(async()=>{try{l(await(o?((e,t=z)=>l=>{const n=t.get(l);if(V(n))return n;const a=e(l);return V(a)?t.set(l,Promise.resolve(a)):t.delete(l),a})(t,i)(o):t(...s)))}catch(e){l(void 0,e)}})(),()=>{e=!0}}),[t,i,s]);const u=l&&o&&l[o];return{data:!c&&u?u:c,error:m,mutate:()=>Promise.resolve(void 0)}}function D(e){return Array.isArray(e)?e:e instanceof Function?D(e()):[e]}async function _(e,t){try{return e?await j(e,t):null}catch(e){console.error(e)}return null}async function j(e,t){return(await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}})).json()}const L=[];function $(){const{data:e}=A("/api/v1/regions",j);return e||L}const O=()=>({open:(e,t={})=>b.fire("dialog",{type:"open",dialog:e,...t}),close:()=>b.fire("dialog",{type:"close"}),closeAll:()=>b.fire("dialog",{type:"close",all:!0})}),E=e=>Boolean(e?.includes(":")),F=(e,t)=>Boolean(e&&!E(e)&&(!t||"_self"===t)),U=e=>(e||"").replace(/\?.*/,"").replace(/\/$/,""),H=(...e)=>e.filter(Boolean).join("/").replace(/\/+/g,"/");var W=Object.freeze({__proto__:null,isURL:E,isLocalURL:F,isHash:e=>Boolean(e?.startsWith("#")),withoutQuery:U,joinPath:H});const X=e=>(t,l=d.BASE_PATH)=>{if(!t||E(t)||K(t,d.CDN))return t;const n=t.startsWith("/");return H(K(t,l)?"":l,n?"/":e.pathname?.split("/").slice(0,-1).join("/"),t)},K=(e,t)=>t&&e&&e.startsWith(t),Y=(e,t)=>Y._impl(e,t);function G(){return G._impl()}function q(e={}){const{isRemote:t,basePath:l}=e,n=G(),{closeAll:a}=O();return e=>({...e,href:t&&!l?e.href:X(n)(e.href,l),"aria-label":e.text,onClick:Y(i(e),e)});function i({href:e,target:l,onClick:i}){return r=>{i&&i(r),e&&!t&&F(e,l)&&(a(),r?.preventDefault(),n.push(e))}}}Y._impl=e=>e,Y.setup=e=>{Y._impl=e},G._impl=()=>({isReady:!1,href:globalThis.location?.href||"/",pathname:globalThis.location?.pathname||"/",query:{},push:()=>{},replace:()=>{},back:()=>{}}),G.setup=e=>{G._impl=e};const J={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active",white:"text-primary-main bg-white hover:text-white hover:bg-primary-hover active:bg-white active:text-primary-main",link:"text-primary-main",transparent:"",gray:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active","":""},Z="bg-main-divider text-main-disabled",Q={primary:Z,secondary:Z,white:Z,link:"",transparent:"",gray:Z,"":""},ee="text-center font-sans select-none",te={primary:"group-hover/btn:brightness-0 group-hover/btn:invert",secondary:"group-hover/btn:brightness-0 group-hover/btn:invert",white:"group-hover/btn:brightness-0 group-hover/btn:invert",link:"text-primary-main",transparent:"",gray:"group-hover/btn:brightness-0 group-hover/btn:invert","":""},le=x((e=>{const{text:t,aboveText:l,appendLeft:n,appendRight:a,version:i="primary"}=e,r=ae(e)?"hidden lg:block":"";return p("div",{className:w(ne(e),"flex gap-xs"),children:[n?u("div",{className:w(r,te[i]),children:n}):null,ae(e)?p("div",{className:"whitespace-pre",children:[l?u("div",{className:"text-xs font-light text-left",children:l}):null,u("div",{className:"text-left "+(l?"text-s -mt-3xs":"text-l"),children:t})]}):null,a?u("div",{className:w(r,te[i]),children:a}):null]})})),ne=e=>{const{version:t,aboveText:l,rounded:n}=e;if("link"===t)return"";const a=""+(l?"py-2.5 px-9":"py-4 px-9");return w("group/btn items-center justify-center",ae(e)?a:"h-12 w-12 m-auto",n?"rounded-full":"")},ae=({text:e,aboveText:t,appendLeft:l})=>Boolean(e||t||!l),ie=({className:e,rounded:t,version:l})=>["inline-block",ee,l?Q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),re=({className:e,rounded:t,version:l})=>[ee,"border border-transparent inline-block cursor-pointer no-underline focus:border-primary-text focus:border h-fit",l?J[l]:"",t?"rounded-full":"rounded-md",e].join(" "),se=x((({disabled:e,children:t,...l})=>{const n=q()(l),a=t??u(le,{...n});return u(e?ce:oe,{...n,children:a})})),oe=x((({className:e="",href:t,rel:l,target:n,ariaLabel:a,version:i,rounded:r,onClick:s,children:o})=>u("a",{className:re({className:e,version:i,rounded:r}),href:t,rel:l,target:n,"aria-label":a,role:t?"link":"button",onClick:s,children:o}))),ce=x((({className:e,ariaLabel:t,version:l,rounded:n,children:a})=>u("div",{role:"button","aria-disabled":"true","aria-label":t,tabIndex:-1,className:ie({className:e,rounded:n,version:l}),children:a}))),de=x((({children:e,...t})=>u("p",{className:w("font-sans",Object.values(t)),children:e}))),me=x((({children:e,...t})=>u("span",{className:w("font-sans",Object.values(t)),children:e}))),he=x((({link:e})=>p(de,{size:"text-s",font:"font-light",color:"text-secondary-text",children:[u(me,{children:"Нажимая кнопку, вы подтверждаете согласие с "}),e?u(se,{href:e.href,ariaLabel:"условия передачи данных",target:e.target,className:"text-primary-main",children:u(me,{children:e.text})}):null]}))),ue=(e,t)=>{const{value:l,isDirty:n}=e,a=n?t(l):[];return{...e,errors:a,error:a[0]}},pe=x((({key:e,className:t="",inputClassName:l="",id:n,name:r,type:o="text",label:c,placeholder:d,value:m="",valid:h=!0,children:x,onChange:g,onFocus:f,onBlur:b,pattern:y,autoFocus:v=!1})=>{const N=s(null),k=i((e=>{g&&g(e.target?.value||"")}),[g]);a((()=>{v&&N.current?.focus()}),[v,N]);const C=x?"pr-3xl":"",S=h?"border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text":"border-error";return p("div",{className:w("relative",t),children:[p("label",{children:[c?u("div",{className:"mb-xs",children:u(me,{size:"text-m",font:"font-light",children:c})}):null,u("input",{ref:N,className:w("w-full border rounded-md text-primary-text outline-none p-m",C,S,l),id:n,name:r||n,placeholder:d,type:o,value:m,onInput:k,onFocus:f,onBlur:b,pattern:y},e)]}),x]})})),xe=x((({className:e,label:t,value:l="",error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(pe,{type:"text","aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:n}):null})]}))),ge=e=>"_"===e,fe=e=>/\d/.test(e),be=e=>ge(e)||fe(e),ye=[..."+7 (___) ___-__-__"],ve=ye.findIndex(ge),Ne=ye.map(((e,t)=>be(e)?ye.slice(0,t).filter(be).length:-1));const we=x((({children:e,onChange:t,...l})=>{const n=i((e=>t&&t(function(e){const t=e.replace(/\D/g,""),l=ye.map(((e,l)=>fe(e)?e:t.charAt(Ne[l])||e)),n=Ne.indexOf(t.length-1)+1;return(n?l.slice(0,Math.max(ve,n)):l).join("")}(e))),[t]);return u(pe,{onChange:n,onFocus:e=>n(e?.target?.value||""),...l,children:e})})),ke=x((({className:e,label:t,value:l,error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(we,{"aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i,placeholder:"+7 (___) ___-__-__"}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:n}):null})]}))),Ce="Некорректно заполненное поле",Se=R((e=>null!=e&&""!==e))(Ce),Ie=R((e=>"string"==typeof e&&e.length>1))(Ce),Te=R((e=>"string"==typeof e&&(10===e.length||12===e.length)))(Ce),Be=(Me=/^(\+7)?[\s-]?\(?[0-9]{3}\)?[\s-]?[0-9]{3}[\s-]?[0-9]{2}[\s-]?[0-9]{2}$/,R((e=>"string"==typeof e&&Me.test(e))))(Ce);var Me;const Pe=e=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)})]})]}),Re=[{name:"Торговый эквайринг"},{name:"Мобильный эквайринг"},{name:"Интернет-эквайринг"},{name:"QR-эквайринг (СБП)"},{name:"Все виды эквайринга"}];function Ve(e=!1){const[t,l]=n(e),a=i((()=>l(!0)),[]),r=i((()=>l(!1)),[]),s=i((()=>l((e=>!e))),[]);return[t,{setValue:l,setTrue:a,setFalse:r,toggle:s}]}const ze={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},Ae=x((({className:e="",imageClassName:t="",name:l="",alt:n=`Иконка ${l}`,title:a=n,iconVersion:i="color",width:r,height:s})=>{const o=G(),c=X(o)(H(d.CDN,"/icons",`${l}.svg`));return"normal"!==i?u(je,{className:e,children:p("svg",{className:w(_e(r),ze[i],"white"===i?"invert":"",t),width:r,height:s,"aria-hidden":"true",children:[a?u("title",{children:a}):null,n?u("desc",{children:n}):null,u("use",{href:`${c}#icon`,xlinkHref:`${c}#icon`})]})}):u("img",{className:e,src:c,alt:n,title:a,"aria-hidden":"true",width:r,height:s,style:De(e,s)})})),De=(e,t)=>{return e?.includes("h-")?{}:{height:(l=t,l&&!/\D/.test(l)?`${t}px`:t),width:"auto"};var l},_e=e=>e?"":"w-full h-full",je=x((({className:e,children:t})=>e?u("div",{className:e,children:t}):t)),Le=e=>e?.text||e?.key||"";function $e(e,t,l,n){a((()=>{if(e&&l)return e.addEventListener(t,l,n),()=>{e.removeEventListener(t,l,n)}}),[e,t,l])}function Oe(e){const t=s(null),l=i((l=>{t&&t.current&&l.target instanceof Node&&!t.current.contains(l.target)&&e()}),[e]);return $e(globalThis.document,"click",l),t}const Ee=(e,t)=>e?.length&&t?.trim()?e.filter((e=>e.text?.toLocaleLowerCase().includes(t?.trim().toLocaleLowerCase()))):e,Fe=x((({popupRef:e,options:t,value:l,query:n,onChange:a})=>t?.length?u("div",{className:"bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md",role:"listbox",ref:e,children:Ee(t,n).map((e=>p("div",{className:"flex px-m py-s cursor-pointer hover:bg-main-divider pr-5xl relative",role:"option","aria-selected":e.key===l?.key,onClick:t=>{t.stopPropagation(),a&&a(e)},children:[u("span",{className:"min-h-6",children:Le(e)}),u(Ae,{name:"DoneSimpleIcon",width:"16",height:"16",className:w("absolute right-4 pt-3xs",e.key===l?.key?"":"hidden")})]},e.key)))}):null));function Ue({isOpen:e,options:t,value:l,query:n,onChange:r,onClose:o}){const c={open:(e,t)=>b.fire("popup",{type:"open",popup:e,...t}),update:(e,t)=>b.fire("popup",{type:"update",popup:e,...t}),close:()=>b.fire("popup",{type:"close"})},d=i((()=>{c.close(),o&&o()}),[o]),m=i((e=>{d(),r&&r(e)}),[d,r]),h=s(null),p=Oe(d);return a((()=>{if(!e||!h.current)return;const a=h.current,{top:i,left:r,width:s,height:o}=a.getBoundingClientRect();c.update(u(Fe,{popupRef:p,options:t,value:l,query:n,onChange:m}),{top:i+window.scrollY+o,left:r,width:s})}),[e,t,l,n,m]),h}const He=x((({className:e,label:t,options:l=[],value:a,valid:r=!0,isBorder:s=!0,placeholder:o="",isSearch:c=!1,iconVersion:d,onChange:m})=>{const[h,{setFalse:x,setTrue:g}]=Ve(),[f,b]=n(""),y=i((()=>{b(""),x()}),[]),v=Ue({isOpen:h,options:l,value:a,query:f,onChange:m,onClose:y});return p("div",{className:e,children:[We(t),p("div",{className:w("relative",h?"z-20":"z-10"),ref:v,children:[p("div",{className:w("text-l flex justify-between items-center text-primary-text cursor-pointer relative z-10",Ke(s,r)),onClick:h?y:g,children:[u("p",{className:"p-m pr-3xl flex items-center overflow-hidden text-ellipsis whitespace-nowrap",children:Le(a)||o}),Xe(h,d)]}),c&&h?u("div",{className:w("absolute top-0 w-full z-20"),children:u(pe,{type:"text",autoFocus:!0,value:f,onChange:b})}):null]})]})})),We=e=>e?u("div",{className:"mb-xs",children:u(me,{size:"text-m",color:"text-primary-text",font:"font-light",children:e})}):null,Xe=(e,t)=>u(Ae,{className:w("absolute right-3",e?"":"rotate-180"),iconVersion:t,name:"ArrowUpIcon",width:"16",height:"16"}),Ke=(e,t)=>w(e?"border rounded-md hover:border-primary-hover":"",t?" border-gray":"border-error"),Ye=x((({className:e="",error:t,...l})=>p("div",{className:e,children:[u(He,{...l,valid:!t}),u("div",{className:"h-2",children:t?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:t}):null})]}))),Ge=({regions:e,field:t})=>p("div",{className:"border-b border-b-main-divider @xl:border-none @xl:flex @xl:justify-between gap-lg ",children:[u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Вид эквайринга",placeholder:"Выберите эквайринг",options:Re.map((({name:e=""})=>({key:e,text:e}))),...ue(t("acquiringType"),Se)})}),u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Адрес",placeholder:"Выберите адрес",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})]}),qe=x((({value:e=!1,text:t,type:l="checkbox",onChange:n})=>p("div",{role:l,"aria-checked":e,className:"flex justify-start items-center w-full cursor-pointer mb-s",onClick:()=>n&&n(!e),children:[u("div",{className:w("relative flex-shrink-0 duration-300 w-9 h-5 mr-s rounded-2xl",e?"bg-primary-main":"bg-main-divider"),children:u("div",{className:w("absolute opacity-80 duration-500 top-0.5 w-4 h-4 bg-white rounded-full",e?"left-1/2":"left-[5%]")})}),u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:t})]}))),Je=e=>p("div",{children:[u(qe,{text:"Хочу купить онлайн-кассу",...e("onlineCheckout")}),u(qe,{text:"Хочу купить POS-терминал",...e("posTerminal")})]}),Ze=(e,t)=>{const l=re({className:"text-white",version:e?.version});return u("button",{type:"submit",className:w("p-m w-full @xl:w-auto",l,t),children:e?.text?e.text:"Отправить заявку"})},Qe={acquiringType:{key:"Торговый эквайринг"},fullName:"",inn:"",name:"",phone:"",onlineCheckout:!1,posTerminal:!1},et=M({acquiringType:Se,region:Se,fullName:Se,inn:Te,name:Ie,phone:Be}),tt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{acquiringType:t,region:l,fullName:a,inn:i,name:r,phone:s,onlineCheckout:o,posTerminal:c}=e;P(et(e))&&n({typeForm:"acqr",region:l?.text||"",partnerComments:`Вид эквайринга=${t?.key||""}/Онлайн касса=${o}/POS-терминал=${c}`,fullName:a,inn:i,name:r,phone:s.replace(/[^+\d]/g,"")})}),[n]),[,{field:r,...s}]=B(Qe,a),o=$();return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Вид эквайринга и регион",className:"@xl:text-center"}),Ge({regions:o,field:r}),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),Pe(r),Je(r),Ze(t),u(he,{link:l})]})})),lt=e=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)}),u(xe,{className:"shrink-0 w-full",label:"Электронная почта",...ue(e("mail"),Se)})]})]}),nt=({regions:e,field:t})=>u(Ye,{className:"w-full",label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)}),at={name:"",phone:"",inn:"",mail:""},it=M({region:Se,name:Ie,phone:Be,inn:Te,mail:Se}),rt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{region:t,name:l,phone:a,inn:i,mail:r}=e;P(it(e))&&n({typeForm:"bcrd",region:t?.text||"",name:l,inn:i,mail:r,phone:a.replace(/[^+\d]/g,"")})}),[n]),[,{field:r,...s}]=B(at,a),o=$();return p("form",{className:"container space-y-s",onSubmit:s.onSubmit,children:[nt({regions:o,field:r}),lt(r),Ze(t),u(he,{link:l})]})})),st=[];const ot=async e=>await _(e,{method:"GET"})||st,ct=["От 1 000 ₽","До 1 000 000 000 ₽"],dt=["От 1 мес","До 15 лет"],mt=e=>p("div",{className:"pb-2xs border-b border-b-main-divider @xl:flex @xl:justify-between @xl:gap-lg @xl:border-none @xl:pb-0",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Годовая выручка, ₽",...ue(e("annualRevenue"),Se)}),u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full",label:"Электронная почта",...e("mail")})]})]}),ht=(e,{normalize:t,format:l})=>{const{value:a,onFocus:r,onBlur:s,onChange:o}=e,[c,d]=n(!1),m=i((e=>{d(!0),r&&r(e)}),[]),h=i((()=>{d(!1),o&&o(t(a)),s&&s()}),[o,a]);return{value:c||!l?a:l(a),onFocus:m,onBlur:h}},ut=(e,t,l)=>Math.max(t,Math.min(e,l)),pt=(e=0)=>(t=0)=>new Intl.NumberFormat("ru-RU",{minimumFractionDigits:0,maximumFractionDigits:e}).format(Number(t)||0);function xt(e){const t=(e||"").replace(/\D/g,""),l=parseInt(t,10);return Number.isNaN(l)?0:l}function gt({list:e=[],min:t,max:l,step:n,value:a=e[0]||t,disabled:i,onChange:r}){const s=e.length?e.indexOf(a):a,o={backgroundSize:`${(100*(s>t?s-t:0)/(l-t)).toFixed(2)}% 100%`};return p("div",{children:[e.length?u("div",{className:"absolute w-full flex justify-between -bottom-[3px] px-m",children:e.map(((e,t)=>u("div",{className:w("w-2 h-2 rounded-full",s<=t||i?"bg-gray":"bg-primary-main")},String(t))))}):null,u("div",{className:"absolute inset-x-0 -bottom-1 px-m leading-[18px]",children:u("input",{className:"box-border w-full m-0 cursor-pointer slider relative z-10",style:o,type:"range",min:t,max:l,step:n,value:s,disabled:i,onInput:t=>{const l=xt(t.target?.value),n=e.length?e[l]:l;r&&r(n||0)}})})]})}const ft=1,bt=100,yt=x((e=>{const{className:t,title:l,items:n=[],list:a=[],min:r=(a.length?0:ft),max:s=(a.length?a.length-1:bt),step:o=1,value:c=a[0]||r,disabled:d=!1,onChange:m}=e,h=ht(e,{normalize:(e=0)=>a.length?vt(a)(e):ut(e,r,s),format:pt()}),x=i((e=>{m&&m(xt(e.target?.value))}),[m]);return p("div",{className:t,children:[p("label",{className:"block relative",children:[l?u(me,{size:"text-m",font:"font-light",color:"text-primary-text",children:l}):null,u("input",{className:w("mt-xs font-sans text-h3 w-full h-14","border border-solid border-gray rounded-md outline-none","pl-m box-border","text-primary-text hover:border-primary-hover focus:border-primary-text","disabled:border-gray disabled:bg-main-divider"),disabled:d,onInput:x,...h}),gt({list:a,min:r,max:s,step:o,disabled:d,value:c,onChange:m})]}),Nt(n)]})})),vt=e=>t=>e.reduce(((e,l)=>Math.abs(l-t)<Math.abs(e-t)?l:e)),Nt=e=>u("div",{className:"flex justify-between my-xs",children:e.map(((e,t)=>u(me,{size:"text-s",font:"font-light",color:"text-secondary-text",children:e},String(t))))}),wt=e=>p("div",{className:"border-b border-b-main-divider @xl:border-none @xl:flex @xl:justify-between gap-lg",children:[p("div",{className:"@xl:w-1/2",children:[u("label",{children:u(me,{size:"text-m",font:"font-light",children:"Сумма, ₽"})}),u(yt,{items:ct,min:1e3,max:1e9,...e("amount")})]}),p("div",{className:"@xl:w-1/2",children:[u("label",{children:u(me,{size:"text-m",font:"font-light",children:"Срок, месяцев"})}),u(yt,{items:dt,min:1,max:180,...e("term")})]})]}),kt=({regions:e,branches:t,field:l})=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg @xl:mb-2xl @xl:border-none @xl:pb-0",children:[u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(l("region"),Se)})}),u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Адрес",placeholder:"Выберите адрес",options:t.map((({branchCode:e="",address:t=""})=>({key:e,text:t}))),...ue(l("department"),Se)})})]}),Ct={amount:1e3,term:12,fullName:"",inn:"",name:"",phone:"",mail:"",annualRevenue:""},St=M({fullName:Se,annualRevenue:Se,inn:Te,name:Ie,phone:Be,region:Se,department:Se}),It=x((({button:e,link:t,onSubmit:l})=>{const n=i((e=>{const{amount:t,term:n,fullName:a,inn:i,name:r,phone:s,mail:o,region:c,department:d,annualRevenue:m}=e;P(St(e))&&l({typeForm:"cred",fullName:a,inn:i,name:r,phone:s.replace(/[^+\d]/g,""),mail:o,region:c?.text||"",department:d?.text||"",partnerComments:`Сумма=${t}/Срок=${n}/Выручка=${m}`})}),[l]),[a,{field:r,...s}]=B(Ct,n),o=$(),c=function(e){const{data:t}=A(e?`/api/v1/branches?regionCode=${e}`:null,ot);return t||st}(a.region?.key).filter((e=>e?.address));return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Параметры",className:"@xl:text-center"}),wt(r),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),mt(r),u(I,{headingType:"h6",title:"Офис банка",className:"@xl:text-center"}),kt({regions:o,branches:c,field:r}),Ze(e),u(he,{link:t})]})})),Tt={name:"",phone:""},Bt=M({name:Ie,phone:Be}),Mt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{name:t,phone:l}=e;P(Bt(e))&&n({typeForm:"dpst",name:t,phone:l.replace(/[^+\d]/g,"")})}),[n]),[,{field:r,...s}]=B(Tt,a);return p("form",{className:"container",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Оставьте заявку и мы ответим на любые вопросы по депозитам",className:"@xl:text-center mb-m"}),p("div",{className:"max-w-[560px] m-auto space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Имя",...ue(r("name"),Ie)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(r("phone"),Be)})]}),p("div",{className:"flex justify-between flex-col-reverse @xl:items-center @xl:flex-row max-w-[560px] m-auto",children:[u("div",{className:"flex-1",children:u(he,{link:l})}),Ze(t)]})]})})),Pt={},Rt="wcms-resources";function Vt(e,t={}){const{fallback:l=Pt,folderName:n=Rt,setBasePath:a=!1}=t,i=H("/",a?d.BASE_PATH:"",n,`${e}.json`),{data:r}=A(e?i:null,j,{fallback:l});return r||Pt}const zt=x((e=>{const{button:t,sourceBookDir:l}=e,{regions:a}=Vt(l||"regions-grant-support"),[i,r]=n({key:""}),s=re({className:"text-white",version:t?.version}),o=a?.find((e=>e.name===i.key))?.href;return p("div",{className:"container space-y-s @xl:space-y-lg",children:[a?u(Ye,{label:"Ваш регион",placeholder:"Выберите регион",isSearch:!0,options:a.map((({name:e=""})=>({key:e}))),value:i,onChange:r}):null,o?u("div",{className:"text-center",children:u(se,{href:o,target:"_blank",className:w("p-m w-full @xl:w-auto",s),children:t?.text?t.text:"Перейти"})}):null]})})),At=(e,t)=>e?.media&&t?.media?e.media-t.media:0,Dt=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n})=>{const a=G();return p("picture",{className:e,children:[t?.sources?.length?t.sources.filter((e=>e?.src)).sort(At).map((({src:e,format:l,media:i},r)=>u("source",{srcSet:jt(a,n)(e),type:Lt(l),media:i?`(max-width: ${i}px)`:"",...t.size},`${r}_${e}`))):null,t?.src?_t({...t,src:jt(a,n)(t.src)},l):null]})})),_t=(e,t="")=>u("img",{src:e.src,className:w("object-contain",t),alt:e.alt||e.title,title:e.title||"",style:{width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"auto"},...e.size}),jt=(e,t)=>l=>l&&!E(l)?X(e)(H(t,l)):l,Lt=e=>e?`image/${String(e)}`:void 0,$t=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n,...a})=>t?.src||t?.icon?t.icon?u(Ae,{className:e,imageClassName:l,iconVersion:t?.iconVersion,name:t.icon,...a}):u(Dt,{className:e,imageClassName:l,image:t,pathPrefix:n}):null)),Ot=x((({name:e,text:t,value:l,checked:n,onChange:a,className:i})=>u("div",{className:i,children:p("label",{className:"font-sans flex gap-s items-center relative cursor-pointer",children:[u("input",{className:"appearance-none flex justify-center items-center shrink-0 w-5 h-5 border border-gray hover:border-primary-hover\n checked:border-2 checked:!border-primary-main focus:checked:border-primary-main focus:border-primary-text active:border-primary-text\n after:block after:w-2.5 after:h-2.5 after:rounded-full checked:after:bg-primary-main outline-none rounded-full cursor-pointer",type:"radio",value:l,name:e,checked:n,onChange:e=>a(e.target.value)}),t?u(me,{color:"text-primary-text",children:t}):null]})}))),Et=e=>{const{value:t,onChange:l}=e("vedTypes");return u("div",{className:"space-y-m",children:p("div",{className:"@xl:flex @xl:items-center @xl:gap-xl",children:[u(Ot,{className:"mb-xs",name:"vedTypes",text:"Валютный котроль",value:"currencyControl",checked:"currencyControl"===t,onChange:e=>l&&l(e)}),u(Ot,{className:"mb-xs",name:"vedTypes",text:"Документарные операции",value:"documentOperations",checked:"documentOperations"===t,onChange:e=>l&&l(e)}),u(Ot,{className:"mb-xs",name:"vedTypes",text:"Конверсионные операции",value:"conversionTransactions",checked:"conversionTransactions"===t,onChange:e=>l&&l(e)}),u(Ot,{className:"mb-xs",name:"vedTypes",text:"Иные вопросы ВЭД",value:"otherIssues",checked:"otherIssues"===t,onChange:e=>l&&l(e)})]})})},Ft=(e,t)=>{const l="currencyControl"===e("vedTypes").value;return p("div",{children:[l?u(Ye,{className:"mb-s",label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:t.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(e("region"),Se)}):null,p("div",{className:"@xl:grid @xl:grid-cols-2 @xl:gap-x-lg",children:[l?u(xe,{className:"w-full mb-s",label:"ИНН",...ue(e("inn"),Te)}):null,u(xe,{className:"w-full mb-s",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"w-full mb-s",label:"ФИО",...ue(e("name"),Ie)}),u(ke,{className:"w-full mb-s",label:"Телефон",...ue(e("phone"),Be)}),l?null:u(xe,{className:"w-full mb-s",label:"Электронная почта",...ue(e("mail"),Se)})]})]})},Ut=e=>{const t=e("text");return p("label",{children:[u("div",{className:"mb-xs",children:u(me,{size:"text-m",font:"font-light",children:"Обращение"})}),u("textarea",{placeholder:"Укажите интересующий вас вопрос, место ведения бизнеса и удобное время для телефонного звонка",className:w("block w-full resize-y min-h-24 p-m outline-none border rounded-md border-gray","hover:border-primary-hover active:focus:border-primary-text focus:border-primary-text"),value:t.value,onInput:e=>t.onChange&&t.onChange(e.target?.value||"")})]})},Ht={fullName:"",name:"",phone:"",inn:"",vedTypes:"currencyControl",text:""},Wt={fullName:Se,name:Ie,phone:Be},Xt=M({...Wt,mail:Se}),Kt=M({...Wt,inn:Te,region:Se}),Yt=e=>"currencyControl"===e,Gt=e=>({currencyControl:"currencyControl"===e,documentOperations:"documentOperations"===e,conversionTransactions:"conversionTransactions"===e,otherIssues:"otherIssues"===e}),qt={ApplicationFormBusinessCard:rt,ApplicationFormWed:x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{fullName:t,name:l,phone:a,mail:i,inn:r,region:s,vedTypes:o,text:c}=e,d={typeForm:"KVED",fullName:t,name:l,phone:a.replace(/[^+\d]/g,""),text:c,vedTypes:Gt(o),PartnerComments:c,...Yt(o)?{inn:r,region:s?.text||""}:{mail:i}};P((e=>Yt(e)?Kt:Xt)(o)(e))&&n(d)}),[n]),[,{field:r,...s}]=B(Ht,a),o=$();return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[Et(r),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),Ft(r,o),Ut(r),p("div",{className:"flex flex-col gap-m border-b border-main-divider pb-lg @xl:items-center @xl:flex-row @xl:pb-4xl",children:[Ze(t),u(he,{link:l})]}),u(I,{headingType:"h6",title:"Или свяжитесь с нами удобным способом",className:"@xl:text-center"}),p("div",{className:"flex gap-xl",children:[p("a",{className:"flex gap-s items-center text-primary-text no-underline",href:"tel:8 (800) 200-78-70","aria-label":"8 (800) 200-78-70",children:[u($t,{image:{icon:"PhoneIcon"},width:"24",height:"24"}),u("span",{children:"8 (800) 200-78-70"})]}),p("a",{className:"flex gap-s items-center text-primary-text no-underline","aria-label":"ved@rshb.ru",href:"mailto:ved@rshb.ru",children:[u($t,{image:{icon:"MailIcon"},width:"24",height:"24"}),u("span",{children:"ved@rshb.ru"})]})]})]})})),ApplicationFormDeposit:Mt,ApplicationFormCredit:It,ApplicationFormAcquiring:tt,ApplicationFormGrantSupport:zt},Jt=x((({responseType:e})=>{const t="OK"===e;return p("div",{className:`flex items-center p-lg rounded-md space-x-m ${t?"bg-ok":"bg-fail"}`,children:[u($t,t?{image:{icon:"ResponseOKIcon"},width:"42",height:"42"}:{image:{icon:"ResponseFailIcon"},width:"37",height:"34"}),p("div",{children:[u(I,{headingType:"h6",title:t?"Ваша заявка отправлена":"Не удалось отправить заявку",className:"mb-2xs"}),u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:t?"Совсем скоро мы с вами свяжемся":"Пожалуйста, повторите позднее"})]})]})})),Zt={send:async function(e){try{const t=await fetch("/api/v1/sendcorporatelead",{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",body:JSON.stringify(e)});return t?.ok?await t.json():null}catch(e){return null}}},Qt=x((e=>{const{className:t,formBlock:l,...a}=e,[r,s]=n(""),o=i((async e=>{const t=await Zt.send(e)?"OK":"Fail";return s(t),t}),[]);return u(C,{className:t,defaultPadding:"p-6xl",...a,children:p("div",{className:"container max-w-[978px] space-y-lg",children:[l?.title?u(I,{headingType:"h3",title:l.title,className:"@xl:text-center"}):null,l?el(l,o):null,r?u(Jt,{responseType:r}):null]})})})),el=(e,t)=>{const l=e?.formType;if(!l||!(l in qt))return null;return u(qt[l],{...e,onSubmit:t})},tl="text-center",ll={"":"bg-main-divider group-data-secondary:bg-white/30",primary:"bg-main-divider",secondary:"bg-secondary-light",opacity:"bg-white/30"},nl=x((({className:e,defaultIconSize:t=44,iconBgVersion:l="primary",size:n,icon:a,...i})=>{const r=String(n?.width||t);return a?u("div",{style:{width:`${r}px`,height:`${r}px`},className:w("rounded-icon object-fit flex justify-center items-center",ll[l],e),children:u(Ae,{...i,width:"54%",height:"54%",name:a})}):null})),al=x((({className:e="",title:t,benefitList:l,...n})=>p(C,{className:e,defaultPadding:"p-6xl",...n,children:[t?u(I,{headingType:"h3",as:"h2",className:tl,title:t}):null,l?.length?u("div",{className:"flex flex-col @md:flex-row flex-wrap w-full @md:justify-center mt-xl gap-5xl",role:"list",children:l.map(il)}):null]}))),il=(e,t)=>p("div",{className:"flex gap-m items-center @md:basis-1/2 @md:max-w-[500px]",role:"listitem",children:[e?.icon?.icon?u(nl,{className:"shrink-0",defaultIconSize:44,iconBgVersion:e?.iconBgVersion||"",...e?.icon}):null,e?.icon?.src?u($t,{className:"shrink-0",image:e.icon}):null,e?.label?p("div",{className:"@sm:h-full",children:[u(I,{headingType:"h6",children:e.label}),rl(e.description)]}):null]},String(t)),rl=e=>{const t=e?.benefitType||null;return e&&t?u("div",{className:"mt-xs text-l font-light text-secondary-text group-data-secondary:text-white/80",children:"list"===t?ol(e):sl(e)}):null},sl=e=>e?.name?u(me,{size:"text-l",color:"text-secondary-text group-data-secondary:text-white/80",font:"font-light",children:e.name}):null,ol=e=>{const t=e?.bullets?"list-disc pl-3xl":"";return e?.items&&e.items.length>0?u("ul",{className:t,children:e.items.map(((e,t)=>u("li",{children:u(me,{size:"text-l",color:"text-secondary-text group-data-secondary:text-white/80",font:"font-light",children:e})},`benefitListItem-${t}`)))}):null},cl=e=>Boolean(e?.src||e?.icon),dl=(e,{className:t,buttonClassName:l,isVertical:n}={})=>e?.length&&e.some((e=>e?.text||e?.icon?.icon))?u("div",{className:w("flex",n?"flex-col gap-xs justify-items-stretch":"flex-wrap @xl:flex-nowrap gap-lg sm:gap-m",t),children:e.map(ml(l))}):null,ml=(e="")=>(t,l)=>{const{text:n,icon:a,iconRight:i,version:r,...s}=t||{},o=hl(a,r),c=hl(i,r);return n||a?.icon?u(se,{className:w("basis-full sm:basis-auto",e),appendLeft:ul({...a,iconVersion:o}),appendRight:ul({...i,iconVersion:c}),version:r,text:n,...s},l?String(l):""):null},hl=(e,t="secondary")=>{const l="secondary"===t?"color":"white";return e?.iconVersion?e?.iconVersion:l},ul=e=>cl(e)?u($t,{image:e,width:String(e?.size?.width||24),height:String(24)}):null,pl={XXL:{title:{headingType:"h0",as:"h1"},descriptionSize:"text-h5",descriptionWeight:"font-normal",descriptionStyle:"mt-xl"},XL:{title:{headingType:"h1",as:"h1"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-m"},L:{title:{headingType:"h2",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-m"},M:{title:{headingType:"h3",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-s"},S:{title:{headingType:"h4",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-xs"},XS:{title:{headingType:"h5",as:"h2"},descriptionSize:"text-m",descriptionWeight:"font-light",descriptionStyle:"mt-xs"}},xl={H6:"text-h6",XL_L:"text-xl-light",XL_R:"text-xl",L_L:"text-l-light",L_R:"text-l",M:"text-m-light",S:"text-s-light",XS:"text-xs-light"},gl=x((({className:e,version:t="",headlineVersion:l="XL",title:n,description:a,align:i="text-center",as:r,isEmbedded:s=!1,isTheme:o=!1,...c})=>{const d=pl[l],m={marginTop:d.descriptionStyle};return p(C,{className:w(s?"@container-normal":"",e),defaultPadding:s?"":"p-6xl",version:t,isTheme:o,...c,children:[n?u(I,{className:w("whitespace-pre-wrap",i),...d?.title,as:r||d?.title.as,title:n}):null,a?u(de,{size:d.descriptionSize,font:d.descriptionWeight,align:i,...m,children:a}):null]})})),fl=x((({className:e="",title:t,description:l,bonusItems:n=[],align:a=tl,...i})=>u(C,{className:e,defaultPadding:"p-6xl",...i,children:p("div",{className:"container",children:[u(gl,{className:"mb-xl",isEmbedded:!0,title:t,description:l,headlineVersion:"M",align:a}),u("div",{className:"flex flex-wrap gap-3xl gap-x-m w-full",children:n.length>0?n.map(((e,t)=>p("div",{className:"w-full @xl:w-[48%] sm:space-y-xs flex flex-col grow w-full p-xl sm:p-m border border-gray",children:[u("div",{className:"grow",children:u(gl,{title:e?.title,description:e?.description,headlineVersion:"S",isEmbedded:!0,align:"text-left"})}),p("div",{className:"flex justify-center sm:justify-between sm:items-end",children:[u("div",{className:"hidden sm:block",children:dl(e?.buttons)}),e.bonusItemContent?.bonusType?bl(e.bonusItemContent):null]})]},String(t)))):null})]})}))),bl=e=>"count"===e.bonusType?yl(e):vl(e),yl=e=>p("div",{className:"w-full pt-default @xl:mt-s @xl:mb-4 flex justify-center sm:justify-end items-end",children:[e.bonusCount?u("div",{className:"shrink-0 -mb-6 @xl:-mb-4",children:u("span",{className:"font-mohave text-title-large sm:text-title-extra gradient-color-text",children:e.bonusCount})}):null,e.bonusName?u("div",{className:"shrink-0 gradient-color-text",children:u(me,{size:"text-h2",children:e.bonusName})}):null]}),vl=e=>e.image?u($t,{className:"min-w-12 p-xs rounded-icon shrink-0",image:e.image}):null,Nl=e=>({icon:t,title:l,description:n},a)=>p("div",{className:w("flex flex-col gap-1","items-center",n||l?"":"justify-center"),children:[l?u(me,{size:"text-h6",font:"font-normal",align:e,children:l}):null,t?u($t,{image:t,height:"180",className:"w-auto"}):null,n?u(me,{size:"text-h6",font:"font-normal",align:e,children:n}):null]},String(a)),wl=(e,t,l)=>u("div",{className:`grid gap-2xs ${kl(t)}`,children:e.map(Nl(l))}),kl=e=>{switch(e){case"3":return"grid-cols-3";case"4":return"grid-cols-4";default:return"grid-cols-5"}},Cl=x((({bonusBenefits:e,cardTextAlign:t="text-center",className:l="",columnsCount:n="4",subtitle:a,title:i,...r})=>p(C,{className:l,defaultPadding:"p-6xl",...r,children:[u(gl,{title:i,description:a,headlineVersion:"M"}),e?.length?wl(e,n,t):null]}))),Sl=x((e=>{const{title:t,image:l,cardItems:n,button:a}=e;return p("div",{className:"border-gray border p-4xl w-1/2 space-y-lg",children:[l?p("div",{className:"flex justify-center",children:[l?.src?u($t,{image:l}):null,l?.icon?u($t,{image:l}):null]}):null,t?u(I,{headingType:"h4",title:t}):null,n?.length?u("ul",{className:"space-y-s",children:n.map(((e,t)=>Il(e,String(t))))}):null,dl([a])]})})),Il=(e,t)=>{const{icon:l,text:n}=e;return p("li",{className:"flex items-center gap-s",children:[l?.icon?u($t,{image:l,className:"w-12 h-12 min-w-12 p-s rounded-icon bg-main-divider"}):null,l?.src?u($t,{image:l}):null,u(me,{size:"text-xl",font:"font-light",children:n})]},t)},Tl=x((({className:e,title:t,cards:l,...n})=>p(C,{className:e,defaultPadding:"p-6xl space-y-3xl",...n,children:[u(I,{headingType:"h3",title:t,className:"text-center"}),u("div",{className:"flex gap-lg",children:l?.length?l.map(((e,t)=>u(Sl,{...e},String(t)))):null})]}))),Bl={start:"justify-start",center:"justify-center",end:"justify-end"},Ml=x((({buttons:e,className:t="",align:l,...n})=>{const a=l?w("flex",Bl[l]):"";return u(C,{className:w("!bg-transparent",a,t),defaultPadding:"p-0",...n,children:dl(e)})})),Pl=(e,t=0)=>{const{itemCount:l,visibleItemCount:a}=e,[r,s]=n(t),o=i((()=>s((e=>Math.min(e+1,l-1)))),[l]),c=i((()=>s((e=>Math.max(e-1,0)))),[l]),d=a?l>a&&r<l-a:r<l-1,m=r>0;return[r,{inc:o,dec:c,canInc:d,canDec:m,isScrollAvailable:m||d}]},Rl=x((({className:e,disabled:t,...l})=>u(se,{rounded:!0,className:w("group/btn w-12 h-12 min-h-12 max-h-12 flex items-center justify-center shadow-main-black",t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main",e||""),disabled:t,...l,children:u($t,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border",image:{icon:"ArrowLeftIcon",iconVersion:"black"},imageClassName:"group-hover/btn:text-primary-main",width:"16",height:"16"})}))),Vl=x((e=>u(Rl,{...e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left"}))),zl=x((e=>u(Rl,{...e,className:`${e.className||""} rotate-180`,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right"})));function Al({dec:e,inc:t,canDec:l,canInc:n,btnClass:a,className:i=""}){return l||n?p("div",{children:[l?u(Rl,{className:`absolute z-40 ${a[0]} ${i}`,onClick:e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left",disabled:!l}):null,n?u(Rl,{className:`absolute z-40 rotate-180 ${a[1]} ${i}`,onClick:t,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right",disabled:!n}):null]}):null}const Dl=x((({title:e,value:t,postfix:l="",prefix:n,className:a=""})=>p("div",{className:w("flex justify-between @xl:flex-col",a),children:[e?u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:e}):null,u("div",t?{children:p(me,{size:"text-h3",children:[n," ",pt(2)(Math.round(t))," ",l]})}:{children:u(me,{size:"text-h3",children:"-"})})]}))),_l=Math.round(23.5),jl={minSum:1e4,maxSum:5e6,minMonths:13,maxMonths:60,rate:0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,isInsurance:!0},Ll={minSum:1e4,maxSum:3e6,minSumOld:0,maxSumOld:25e5,minSumExtra:0,maxSumExtra:5e5,minMonths:13,maxMonths:60,rate:0,isExtraMoney:!1,isSalaryClient:!1,isInsurance:!0},$l={minSumTravel:6e3,maxSumTravel:2e5,minSumOther:6e3,maxSumOther:2e5,maxBonus:5e3,prefMonthsNum:2,prefTravelBonusRate:.015,prefRestBonusRate:.01,travelBonusRate:.015,restBonusRate:.01},Ol={minSum:5e4,maxSum:5e6,minMonths:2,maxMonths:10,rate:0,isMonthlyInterestPayment:!0,isRemoteRegistration:!0},El={minSum:1e3,maxSum:5e5,minDays:1,maxDays:1095,rate:0,isMonthlyInterestPayment:!0,isReplenished:!1,isPartialWithdrawal:!1,depositeName:"Депозит 'Стабильный'"},Fl=e=>e?u(de,{size:"text-s",font:"font-light",color:"text-secondary-text",children:e}):null,Ul=x((({rate:e,title:t="Ставка",unit:l,depositeName:n,isShowDepositeName:a,fractionDigits:i=2})=>p("div",{children:[u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:t}),p("div",{className:"relative",children:[p("div",{className:"flex justify-start gradient-color-text",children:[u("span",{className:"font-mohave text-title-huge pr-xl -mt-m tracking-[-15px]",children:String(e.toFixed(i)).replace(".",",")}),l?u("span",{className:"text-7xl",children:l}):null]}),n&&a?u("div",{className:"absolute bottom-2 w-full text-left whitespace-nowrap",children:n}):null]})]}))),Hl=x((({title:e="Ставка",isUnavailableByTerm:t=!1})=>p("div",{className:"space-y-s",children:[u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:e}),u(Ae,{className:"w-10 h-10 @5xl:h-auto @5xl:w-40",name:"PercentIcon"}),u("div",{className:"w-64",children:t?p(de,{size:"text-xl",font:"font-light",color:"text-primary-text",children:["Процентная ставка для срока ",u("strong",{children:"1-30 дней"})," устанавливается при обращении в Банк"]}):u(de,{size:"text-xl",font:"font-light",color:"text-primary-text",children:"Выберите другую сумму или срок"})})]}))),Wl=({rate:e,depositeName:t,fractionDigits:l,isShowDepositeName:n,title:a,unit:i})=>u(Ul,{rate:e,depositeName:t,fractionDigits:l,isShowDepositeName:n,unit:i,title:a}),Xl=({rate:e,title:t,unit:l})=>u(Dl,{title:t,value:e,postfix:l}),Kl=({isUnknownRateShown:e=!0,isUnavailableByTerm:t=!1,title:l="Ставка",unit:n="%",rate:a=0,...i})=>e&&0===a?u(Hl,{isUnavailableByTerm:t,title:l}):p("div",{children:[u("div",{className:"hidden @xl:block",children:Wl({title:l,unit:n,rate:a,...i})}),u("div",{className:"@xl:hidden",children:Xl({title:l,unit:n,rate:a,...i})})]});function Yl({isShowItems:e=!0,step:t=1e3,...l}){const n=[`От ${pt(2)(l.min||0)} ₽`,`До ${pt(2)(l.max||0)} ₽`];return u(yt,{items:e?n:[],step:t,...l})}function Gl(e){const{data:t}=A(`/wcms-resources/${e}.json`,j);return t}const ql=(e,t)=>{const{travelExpenseValue:l,restExpenseValue:n}=e,a=Gl(t||"bonus-calculator-data")||$l,[i,r]=((e,t,l)=>{const{minSumTravel:n,minSumOther:a,maxBonus:i,prefMonthsNum:r,prefTravelBonusRate:s,prefRestBonusRate:o,travelBonusRate:c,restBonusRate:d}=e;if(t===n&&l===a)return[0,0];const m=Math.min(Math.round(s*t)+Math.round(o*l),i);return[m,m*r+Math.min(Math.round(c*t)+Math.round(d*l),i)*(12-r)]})(a,l,n);return{...a,...e,monthBonus:i,yearBonus:r}},Jl=x((({className:e="",sourceBookDir:t,buttons:l,footnote:n})=>{const[a,{field:i}]=B({travelExpenseValue:6e3,restExpenseValue:6e3}),{minSumTravel:r,maxSumTravel:s,minSumOther:o,maxSumOther:c,monthBonus:d,yearBonus:m}=ql(a,t);return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-y-4xl",e),children:[p("div",{className:"flex flex-col @xl:max-w-md gap-2xl border-b border-b-main-divider @xl:border-none pb-3xl @xl:pb-0",children:[Yl({title:"Сумма покупок в категории путешествия, ₽",min:r,max:s,step:500,isShowItems:!1,...i("travelExpenseValue")}),Yl({title:"Сумма покупок в остальных категориях, ₽",min:o,max:c,step:500,isShowItems:!1,...i("restExpenseValue")})]}),d>=0?Kl({title:"Баллов за месяц",rate:d,fractionDigits:0,isUnknownRateShown:!1,unit:""}):null,p("div",{className:"flex flex-col gap-y-4xl @xl:w-96",children:[m>=0?u(Dl,{title:"Баллов за год",value:m}):null,dl(l,{isVertical:!0}),Fl(n)]})]})})),Zl=x((({className:e,viewBox:t,fill:l="none",width:n,height:a,paths:i,...r})=>u("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:l,width:n,height:a,children:i.map((({d:e,fill:t,...l},n)=>u("path",{d:e,fill:t||"currentColor",...r,...l},n)))}))),Ql=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],en=x((({className:e,value:t,text:l,disabled:n,isRadio:a,onChange:r})=>{const s=i((e=>{n||(e.preventDefault(),r&&r(!t))}),[r,n,t]),o=a?u("div",{className:"absolute left-1 w-3 h-3 rounded-full bg-primary-main"}):u(Zl,{paths:Ql,className:"absolute left-1 ml-px block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"});return u("div",{className:e,children:p("label",{className:"flex items-center relative cursor-pointer group/box",onClick:s,children:[u("div",{className:w("appearance-none w-5 h-5 border-solid cursor-pointer m-0",a?"rounded-full border-2":tn(t),t?"border-primary-main":"border-gray",n?"bg-main-disabled":"group-hover/box:border-primary-hover"),role:"checkbox","aria-checked":Boolean(t),"aria-disabled":Boolean(n)}),t?o:null,l?u("div",{className:"ml-s",children:u(me,{size:"text-l",font:"font-light",children:l})}):null]})})})),tn=e=>w("rounded border",e?"bg-primary-main":""),ln=e=>`${e} ${Number(e)%10==1?"дня":"дней"}`,nn={horizontal:"gap-5xl",vertical:"flex-col gap-s"},an=x((({items:e,checkedItem:t,className:l,onChange:n,orientation:a="horizontal"})=>u("div",{className:w(`flex ${nn[a]}`,l),children:e?.map((({id:e,text:l})=>u(en,{isRadio:!0,text:l,value:t===e,onChange:()=>n&&n(e)},String(e))))}))),rn=({items:e,title:t,orientation:l="horizontal",value:n,radioGroupClassName:a,onChange:i})=>p("div",{className:"space-y-s",children:[t?u("div",{children:u(me,{color:"text-secondary-text",font:"font-light",children:t})}):null,u(an,{orientation:l,items:e,checkedItem:e[n?0:1].id,className:w("flex-col sm:flex-row",a),onChange:t=>i&&i(t===e[0].id)})]}),sn=e=>rn({...e,items:[{id:"everyMonth",text:"Ежемесячно"},{id:"atEndTerm",text:"В конце срока"}]}),on=e=>e,cn=(e=on)=>t=>t.reduceRight(((t,l)=>e(t)>e(l)?t:l)),dn=cn(),mn=e=>{const t=[...e];t.sort((([e],[t])=>e-t));let l=1;for(;l<t.length;){const[e,n]=t[l-1],[a,i]=t[l];n>=a?t.splice(l-1,2,[e,Math.max(n,i)]):l++}return t},hn=(e=on)=>cn((t=>-e(t))),un=hn(),pn=([e,t],l,n=[])=>l&&l[e]&&l[t]?{[e]:l[e],[t]:l[t]}:xn([e,t],n),xn=([e,t],l=[])=>({[e]:l.length?un(l.filter((t=>"number"==typeof t[e])).map((t=>t[e]))):0,[t]:l.length?dn(l.filter((t=>"number"==typeof t[e])).map((e=>e[t]))):0}),gn=(e,[t,l],n)=>e>=n[t]&&e<=n[l],fn=(e,t)=>e?t.isReplenished&&t.isPartialWithdrawal:!t.isReplenished&&!t.isPartialWithdrawal,bn=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,daysValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a/30)-n):Math.round(n*e*a/365/100)},yn=x((({className:e="",rateParams:t,buttons:l,footnote:n,bottomFootnote:a,isShowDepositeName:i})=>{const[r,{field:s}]=B({moneyValue:1e5,daysValue:90,isReplenished:!1,isPartialWithdrawal:!1,isMonthlyInterestPayment:!1}),o=((e,t)=>{const{daysValue:l,moneyValue:n,isPartialWithdrawal:a,isReplenished:i,isMonthlyInterestPayment:r}=e,s=Gl(t||"business-calculator-data"),o=i||a,c=l<90||l>730;if(l<=30)return{...El,...e,isDisabledOperatingDeposit:c,isUnavailableByTerm:!0};const d=s?.rateRows?.find((e=>r===e.isMonthlyInterestPayment&&fn(o,e)&&gn(n,["minSum","maxSum"],e)&&gn(l,["minDays","maxDays"],e)))||El,{rate:m}=d,h=bn(m,e),u=n+h,p=s?.rateRows||[El];return{...d,...xn(["minSum","maxSum"],p),...xn(["minDays","maxDays"],p),...e,isDisabledOperatingDeposit:c,income:h,finalSum:u}})(r,t?.sourceBookDir),{income:c,finalSum:d,rate:m,isUnavailableByTerm:h,depositeName:x}=o;return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[Yl({title:"Сумма, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),(g={title:"Срок, дней",min:o.minDays,max:o.maxDays,...s("daysValue"),value:o.daysValue},u(yt,{items:[`От ${ln(g.min||0)}`,`До ${ln(g.max||0)}`],step:1,...g})),p("div",{className:"flex flex-col sm:flex-row gap-y-4 gap-x-14",children:[vn(o,s),sn({title:"Выплата процентов",orientation:"vertical",...s("isMonthlyInterestPayment"),radioGroupClassName:"sm:flex-col"})]})]}),u("div",{className:"border-b border-main-divider md:hidden"}),Kl({rate:m,depositeName:x,isShowDepositeName:i,isUnavailableByTerm:h}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[Nn(d,c),dl(l,{isVertical:!0}),Fl(n),Fl(a)]})]});var g})),vn=(e,t)=>p("div",{className:"space-y-s",children:[u(me,{color:"text-secondary-text",font:"font-light",children:"Параметры"}),p("div",{className:"flex flex-col gap-y-xl sm:gap-y-s",children:[u(en,{text:"Пополнение",disabled:e.isDisabledOperatingDeposit,...t("isReplenished"),value:e.isReplenished}),u(en,{disabled:e.isDisabledOperatingDeposit,text:"Частичное снятие",...t("isPartialWithdrawal"),value:e.isPartialWithdrawal})]})]}),Nn=(e,t)=>p("div",{className:"flex flex-col gap-2xl sm:gap-0",children:[u(Dl,{title:"Доход в конце срока",value:t,postfix:"₽",prefix:"+"}),u(Dl,{title:"Сумма в конце срока",value:e,postfix:"₽"})]}),wn=({min:e=0,max:t=0,availableMonths:l,...n})=>u(yt,{items:[`От ${kn(e)}`,`До ${kn(t)}`],step:1,...l?.length?{list:l}:{min:e,max:t},...n}),kn=e=>`${e} ${Number(e)%10==1?"месяца":"месяцев"}`,Cn=e=>rn({...e,radioGroupClassName:"sm:flex-col",items:[{id:"annuity",text:"Аннуитетный"},{id:"differential",text:"Дифференцированный"}]}),Sn=e=>In({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&In({...e,fieldKey:"isStateEmployee",viewSettingFieldKey:"isShowStateEmployee"})&&In({...e,fieldKey:"isPensionClient",viewSettingFieldKey:"isShowPensionClient"})&&In({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),In=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],Tn=(e,t)=>{const{isAnnuity:l,moneyValue:n,monthsValue:a,moneyExtra:i}=t;if(0===e)return 0;if(l){const t=e/1200;return i?(n+i)*(t+t/(Math.pow(1+t,a)-1)):n*(t+t/(Math.pow(1+t,a)-1))}return Math.round(n/a)+n*(e/1200)},Bn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=Gl(t||"credit-calculator-data"),s=i?.rateRows||[jl],o=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>Sn({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:i?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:c,maxSum:d}=pn(["minSum","maxSum"],o,s),{minMonths:m,maxMonths:h}=pn(["minMonths","maxMonths"],o,s),u=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a})=>e?.find((e=>Sn({row:e,userInputParams:t,paramsViewSettings:l})&&gn(n,["minSum","maxSum"],e)&&gn(a,["minMonths","maxMonths"],e)))||jl)({rateRows:s,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a}),{rate:p}=u,x=Tn(p,e);return r((()=>({...u,...e,minSum:c,maxSum:d,minMonths:m,maxMonths:h,moneyValue:n,monthsValue:a,monthlyPayment:x})),[e,i])},Mn=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a,isMobile:i})=>{const[r,{field:s}]=B({isAnnuity:!0,isInsurance:!0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,moneyValue:2e5,monthsValue:_l}),o=Bn(r,t,a),c=Cn({title:i?"Тип платежа":"",orientation:"vertical",...s("isAnnuity")});return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[Yl({title:"Сумма кредита, ₽",step:500,min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),wn({title:"Срок кредита, месяцев",min:o.minMonths,max:o.maxMonths,...s("monthsValue"),value:o.monthsValue}),Pn({...o,...a},s),u("div",{className:"sm:hidden",children:c})]}),u("div",{className:"border-b border-main-divider md:hidden"}),Kl({rate:o.rate}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(Dl,{title:"Ежемесячный платеж",value:o.monthlyPayment,postfix:"₽"}),u("div",{className:"hidden sm:block",children:c}),dl(l,{isVertical:!0}),Fl(n)]})]})})),Pn=(e,t)=>p("div",{className:"flex flex-col gap-y-2xl",children:[e.isShowSalaryClient?u(en,{text:"Получаю зарплату на счёт\nв Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient,className:"whitespace-pre-line sm:whitespace-normal"}):null,e.isShowStateEmployee?u(en,{text:"Работаю в бюджетной организации",...t("isStateEmployee"),value:e.isStateEmployee}):null,e.isShowPensionClient?u(en,{text:"Получаю пенсию на карту Россельхозбанка",...t("isPensionClient"),value:e.isPensionClient}):null,e.isShowInsurance?u(en,{text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null]}),Rn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=Gl(t||"deposit-calculator-data"),r=i?.rateRows?.[0]?An(i.rateRows[0].minMonths,i.rateRows[0].maxMonths):1,s=!l?.isShowMonthlyInterestPayment,o=!l?.isShowRemoteRegistration,c=i?.rateRows?.find((t=>zn({row:t,userInputParams:e,paramKey:"isMonthlyInterestPayment",isExclude:s})&&zn({row:t,userInputParams:e,paramKey:"isRemoteRegistration",isExclude:o})&&gn(n,["minSum","maxSum"],t)&&gn(a||r,["minMonths","maxMonths"],t)))||Ol,{rate:d}=c,m=Vn(d,e),h=n+m,u=i?.rateRows||[Ol];return{...c,...xn(["minSum","maxSum"],u),...xn(["minMonths","maxMonths"],u),availableMonths:mn(u.map((e=>[e.minMonths,e.maxMonths]))).flatMap((([e,t])=>((e,t,l=1)=>Array.from({length:Math.abs(t-e)/l+1},((n,a)=>t>=e?e+a*l:e-a*l)))(e,t))),...e,defaultMonth:r,income:m,finalSum:h}},Vn=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,monthsValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a)-n):Math.round(n*e*30*a/365/100)},zn=({row:e,userInputParams:t,paramKey:l,isExclude:n})=>n||t[l]===e[l],An=(e,t)=>e+Math.round((t-e)/2),Dn=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:i})=>{const[r,{field:s}]=B({moneyValue:2e4,monthsValue:0,isMonthlyInterestPayment:!1,isRemoteRegistration:!1}),o=Rn(r,t,i),{defaultMonth:c,rate:d,income:m,finalSum:h}=o,{onChange:x}=s("monthsValue");return a((()=>{x&&x(c)}),[c]),p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[Yl({title:"Сумма, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),wn({title:"Срок, месяцев",min:o.minMonths,max:o.maxMonths,availableMonths:o.availableMonths,...s("monthsValue"),value:o.monthsValue}),_n({...o,...i},s)]}),u("div",{className:"border-b border-main-divider md:hidden"}),Kl({rate:d}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(Dl,{title:"Доход в конце срока",value:m,postfix:"₽",prefix:"+"}),u(Dl,{title:"Сумма в конце срока",value:h,postfix:"₽"}),dl(l,{isVertical:!0}),Fl(n)]})]})})),_n=(e,t)=>{return p("div",{className:"flex flex-col gap-y-2xl",children:[e.isShowMonthlyInterestPayment?sn({title:"Выплата процентов",...t("isMonthlyInterestPayment"),value:e.isMonthlyInterestPayment}):null,e.isShowRemoteRegistration?(l={title:"Оформление",...t("isRemoteRegistration"),value:e.isRemoteRegistration},rn({...l,items:[{id:"remote",text:"Дистанционно"},{id:"office",text:"Офис Банка"}]})):null]});var l},jn=e=>Ln({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&Ln({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),Ln=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],$n=(e,t,l)=>{const{moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s}=e,o=Gl(t||"refinancing-calculator-data"),c=o?.rateRows||[Ll],d=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>jn({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:o?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:m,maxSum:h}=pn(["minSum","maxSum"],d,c),{minMonths:u,maxMonths:p}=pn(["minMonths","maxMonths"],d,c),x=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:r})=>e?.find((e=>jn({row:e,userInputParams:t,paramsViewSettings:l})&&gn(n+r,["minSum","maxSum"],e)&&gn(i,["minSumOld","maxSumOld"],e)&&gn(r,["minSumExtra","maxSumExtra"],e)&&gn(a,["minMonths","maxMonths"],e)))||Ll)({rateRows:c,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s}),{rate:g}=x,f=Tn(g,e),b=e.oldMonthlyPayment-f;return r((()=>({...x,...e,minSum:m,maxSum:h,minMonths:u,maxMonths:p,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s,monthlyPayment:f,benefit:b})),[e,o])},On=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a})=>{const[i,{field:r}]=B({isAnnuity:!0,isInsurance:!0,isSalaryClient:!1,isExtraMoney:!1,moneyValue:7e5,oldMonthlyPayment:0,monthsValue:48,moneyExtra:0}),s=$n(i,t,a);return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[Yl({title:"Остаток долга в других банках, ₽ ",step:500,min:s.minSum,max:s.maxSum-s.maxSumExtra,...r("moneyValue"),value:s.moneyValue}),Yl({title:"Ежемесячный платеж в других банках, ₽",step:500,min:s.minSumOld,max:s.maxSumOld,...r("oldMonthlyPayment"),value:s.oldMonthlyPayment}),wn({title:"Новый срок кредита, месяцев",min:s.minMonths,max:s.maxMonths,...r("monthsValue"),value:s.monthsValue}),En({...s,...a},r),s.isExtraMoney?Yl({title:"Дополнительная сумма, ₽ ",step:500,min:s.minSumExtra,max:s.maxSumExtra,...r("moneyExtra"),value:s.moneyExtra}):null]}),Kl({rate:s.rate,fractionDigits:1}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(Dl,{title:"Ежемесячный платеж",value:s.monthlyPayment,postfix:"₽"}),s.benefit>0?u(Dl,{title:"Выгода в месяц",value:s.benefit,postfix:"₽"}):null,Cn({orientation:"vertical",...r("isAnnuity")}),dl(l,{isVertical:!0}),Fl(n)]})]})})),En=(e,t)=>p("div",{className:"space-y-s",children:[e.isShowSalaryClient?u(en,{text:"Получаю зарплату на счёт в Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient}):null,e.isShowInsurance?u(en,{text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null,u(en,{text:"Получить дополнительную сумму",...t("isExtraMoney"),value:e.isExtraMoney})]}),Fn={CreditCalculatorForm:Mn,DepositCalculatorForm:Dn,BusinessDepositCalculatorForm:yn,BonusCalculatorForm:Jl,RefinancingCalculatorForm:On},Un=(e,t)=>{const l=e?.calcType;if(!l||!(l in Fn))return null;const n=Fn[l];return u("section",{className:"box-border relative bg-white flex shrink-0 self-start basis-full",role:"listitem",children:p("div",{className:"box-border p-4xl w-full space-y-xl",children:[e?.title?u(I,{className:"text-center",title:e.title}):null,u(n,{...e})]})},String(t))},Hn=x((({className:e="",tabAlign:t,calculatorTabs:l=[],...a})=>{const r=l.map((e=>e.nav||{})),s=l.map((({calculatorBlock:e})=>e||{})),[o,c]=n(0),d=i((e=>c(e)),[]),[m,h]=Pl({itemCount:l?.length,visibleItemCount:3});return p(C,{className:w("box-border overflow-hidden relative",e),defaultPadding:"p-0",...a,children:[p("div",{className:"bg-white",children:[r.length>1?Wn({activeIndex:m,tabsNav:r,tabAlign:t,slideIndexShift:o,onClick:d}):null,Al({...h,btnClass:["left-3","right-3"],className:"top-10"})]}),u("div",{className:"flex",style:{transform:`translateX(-${o}00%)`},role:"list",children:s?.length?s.map(Un):null})]})}));function Wn({activeIndex:e,tabsNav:t,tabAlign:l,slideIndexShift:n,onClick:a}){return p("div",{children:[u("div",{style:{transform:`translateX(-${388*e}px)`},className:"flex flex-col justify-end items-center h-32 pt-4xl box-border duration-1000",children:u("div",{className:w("w-full flex flex-nowrap items-end gap-xs",l?Bl[l]:""),children:t.map(((e,t)=>function({tab:e,i:t,isActive:l,onClick:n}){const a=l?"w-96 p-m border-none bg-primary-main text-white":"w-96 p-s ease-in duration-300 bg-white text-primary-text",i=l?"text-xl mb-xs":"text-l mb-2xs",r=l?"text-l font-light text-white":"text-m font-light text-secondary-text",s=l?"":"text-primary-main",o=e?.icon?.iconVersion,c=l?"white":"normal";return p("button",{type:"button",onClick:n,"aria-label":e?.title,className:w("box-border relative border border-gray cursor-pointer text-left border-b-0 flex space-x-m min-h-20",a),children:[u($t,{className:w("h-6 w-6 min-w-6 min-h-6",s),image:{...e?.icon,iconVersion:o??c},width:"24",height:"24"}),p("div",{className:"border-0",children:[u("div",{className:i,children:e?.title}),u("div",{className:r,children:e.description})]})]},String(t))}({tab:e,i:t,isActive:Boolean(t===n),onClick:()=>a(t)})))})}),u("div",{className:"w-full h-2 bg-primary-main"})]})}const Xn=x((e=>{const{onChange:t,min:l,max:n,defaultValue:a="0",fractionDigits:r=0,...s}=e,o=ht(e,{normalize:(e=a)=>l&&n?String(ut(Number(Kn(e)),l,n)):Kn(e),format:pt(r)}),c=i((e=>t&&t(Kn(e))),[t]);return u(pe,{onChange:c,...s,...o})})),Kn=(e="")=>e.replaceAll(",",".").replace(/[^\d.]/g,"").replace(/([^.]*\.[^.]*)\./,"$1"),Yn=x((e=>u(Xn,{...e,fractionDigits:2,children:u("div",{className:"absolute right-4 bottom-4",children:u(me,{size:"text-xl",font:"font-light",children:"₽"})})}))),Gn={private:"https://old.rshb.ru/p2p/",business:"https://old.rshb.ru/smallbusiness/p2p/"},qn={amount:1500,_amount:1500},Jn=x((({className:e="",title:t="Укажите сумму перевода",label:l="Сумма перевода",placeholder:n="1500",button:a,formType:i="private",...r})=>{const[{amount:s,_amount:o},{field:c}]=B(qn),d=s<=0,m=d?ie({version:a?.version}):re({className:"text-white",version:a?.version}),h=q();return p(C,{className:w("flex flex-col items-center",e),defaultPadding:"p-6xl",...r,children:[t?u(I,{className:"pb-lg xl:pb-4xl self-start xl:self-center",headingType:"h3",title:t}):null,p("form",{className:"w-full xl:max-w-[468px]",method:"POST",action:Gn[i],children:[u(Yn,{name:"_amount",valid:!d,placeholder:n,label:l,...c("_amount",{parse:Number,format:String})}),u("input",{type:"hidden",name:"amount",value:o}),a?.text?u("button",{type:"submit",className:w("w-full p-m mt-lg",m),disabled:d,...h(a),children:a.text}):null]})]})})),Zn=e=>({height:"calc(100vh - 242px)",minHeight:`${e||866}px`}),Qn=x((({className:e="",style:t,idx:l,activeIndex:n,observerOptions:a,children:r,onIntersection:s})=>{const o=y(i((e=>{e.length&&s&&s(l||0,e[e.length-1])}),[s,l]),a);return u("div",{className:`inline-block snap-always box-border ${e}`,style:t,"aria-current":Boolean(l===n),ref:o,children:r})})),ea=["min-w-full","@lg:min-w-[50%]","@lg:min-w-[33.3%]","@lg:min-w-[25%]"],ta=x((({className:e="",containerRef:t,activeIndex:l,visibleItemCount:n=0,gap:a=0,padding:r=0,listType:o="horizontal-list",snapAlign:c="snap-center",minHeight:d,children:m,onVisibleItemsChange:h,onVisibleIndicesChange:p})=>{const x={sensitivity:1,rootRef:t},g=s([]),f=i(((e,t)=>{const l=[...g.current||[]];l[e]=t,g.current=l,h&&h(l),p&&p(na(l))}),[h,p]),b=n>0?a*Number(n)-1:0,y="vertical-list"===o,v="horizontal-list"===o,N={...v?la(r,b):{},...y?Zn(d):{},gap:`${a}px`};return u("div",{className:w("box-border overflow-auto no-scrollbar",o,e),style:N,ref:t,children:(k=(e,t)=>u(Qn,{className:w(c,n?ea[n-1]:"",y?"h-full":""),style:v?la(r/4):{},activeIndex:l,idx:t,observerOptions:x,onIntersection:f,children:e},String(t)),e=>null==e?e:Array.isArray(e)?e.map(k):k(e,0))(m)});var k})),la=(e,t=0)=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e+t}px`}),na=e=>e.map(((e,t)=>[e,t])).filter((([e])=>e&&e.intersectionRatio>=.9)).map((([,e])=>e)),aa={"horizontal-list":"mx-auto mt-lg w-fit","vertical-list":"absolute flex-col justify-center h-full top-0 left-4"},ia={"horizontal-list":"w-6","vertical-list":"h-6"},ra=x((({className:e="",containerRef:t,activeIndex:l,dotCount:n=0,listType:a="horizontal-list",version:i})=>n?u("div",{className:w("flex gap-xs",aa[a],i?"group":"",e),...i?{"data-ver":i}:{},children:new Array(n).fill(null).map(((e,n)=>u("div",{className:`cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white group-data-transparent:bg-white ${n===l?ia[a]:"w-2 h-2 opacity-30"}`,role:"button","aria-hidden":!0,onClick:()=>(e=>{e!==l&&t?.current&&t.current.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest"})})(n)},String(n))))}):null)),sa=e=>t=>e.scrollWidth/t,oa=e=>(t,l)=>{e.scrollBy({left:l*sa(e)(t),behavior:"smooth"})},ca=({itemCount:e,onVisibleIndicesChange:t})=>{const l=s(null),[a,r]=n([]),o=i((e=>{r((t=>{return(l=t)===(n=e)||Boolean(l&&n&&l?.length===n?.length&&l.every(((e,t)=>e===n[t])))?t:e;var l,n})),t&&t(e)}),[e]),[c,d]=a.length?[hn()(a),cn()(a)]:[-1,-1],m=c>0,h=d<e-1,u=i((()=>{var t;l.current&&(m?oa(l.current)(e,-1):(t=l.current).scrollTo({left:t.scrollWidth,behavior:"smooth"}))}),[e,m]),p=i((()=>{l.current&&(h?oa(l.current)(e,1):l.current.scrollTo({left:0,behavior:"smooth"}))}),[e,h]),x=i((e=>{l?.current&&l.current.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})}),[l]);return[l,{scrollLeft:u,scrollRight:p,scrollTo:x,canScrollLeft:m,canScrollRight:h,visibleIndicesRange:[c,d],handleVisibleIndicesChange:o}]},da="absolute top-[calc(50%-24px)] z-40",ma="absolute top-0 bottom-0 z-40 hidden @lg:block w-20 pointer-events-none",ha=x((({scroll:e,activeIndex:t,itemCount:l,arrowsPadded:n,hasEdgeBlocks:a,onScrollLeft:r,onScrollRight:s})=>{const{canScrollLeft:o,canScrollRight:c,scrollLeft:d,scrollRight:m}=e,h=a?t>0:o,x=a?t<l-1:c,g=i((()=>{a?(o&&t!==l-1&&d(),r()):d()}),[d,r,a,o,t,l]),f=i((()=>{a?(c&&0!==t&&m(),s()):m()}),[m,s,a,o,t,l]);return p("div",{className:"hidden @lg:block",children:[ua(e),h?u(Vl,{className:w(da,n?"left-1 @lg:left-8":"left-0"),onClick:g}):null,x?u(zl,{className:w(da,n?"right-1 @lg:right-8":"right-0"),onClick:f}):null]})})),ua=e=>p("div",{children:[e.canScrollLeft?u("div",{className:w(ma,"left-0 bg-opacity-from-white group-data-secondary:bg-none")}):null,e.canScrollRight?u("div",{className:w(ma,"right-0 bg-opacity-to-white group-data-secondary:bg-none")}):null]}),pa=({blockClassName:e,block:t,render:l})=>l({blockClassName:e,block:t}),xa=[];function ga(e,t,{className:l,...n}={}){const{key:a,blockDecorator:i=pa,blocksRegistry:r={},ancestors:s=xa}=t,{type:o}=e;o&&o in r||console.warn(`No block with "${o}" is registered`);const c=o&&r[o];return i({blockClassName:w(e.style?.length?e.style:"col-span-12",l),block:e,ancestors:s,render:({block:l,blockClassName:i})=>{const{content:r}=l;return c?u(c,{className:i,block:e,options:t,...r,...n},a):null}},a)}const fa=[],ba=(e,{key:t,ancestors:l=fa,slotName:n=null,extraProps:a,renderProps:i=ga,...r})=>{const s=a?(e,t)=>ga(e,t,a):i;return(e||[]).map(((e,a)=>s(e,{...r,key:`${t||e.type}-${a}`,ancestors:r.parent?[...l||fa,[r.parent,n]]:l},a)))};function ya({block:e,options:t,children:l,extraProps:n,renderProps:a}){return l||(e&&t?ba(e.blocks,{...t,parent:e,extraProps:n,renderProps:a}):null)}const va=({className:e,text:t="ХИТ"}={})=>p("div",{className:w("w-14 h-14 bg-white flex flex-col items-center justify-center rounded-md shadow-main-black",e),children:[u(Ae,{iconVersion:"black",name:"HeartIcon",width:"24",height:"24"}),u(de,{size:"text-s",font:"font-normal",align:"text-center",color:"text-primary-text",children:t})]}),Na="relative h-full",wa={small:"sm:min-w-64",normal:"sm:min-w-96",big:"sm:min-w-[515px]"},ka=({noCardBorder:e,activeIndex:t,cardSize:l="normal",...n})=>{const{blocks:a}=n.block||{},i=a?.some(Ia);return ya({...n,renderProps:(n,a,r)=>p("div",{className:Ca(n,{someCardsHighlighted:i}),children:[ga(n,a,{className:Sa(n,{someCardsHighlighted:i,showBorder:!e,cardSize:l}),blockIndex:r,isActive:r===t}),Ia(n)?va({className:"absolute top-0 -right-4 z-40"}):null]},String(r))})},Ca=(e,{someCardsHighlighted:t})=>w(Na,t&&(Ia(e)?"pt-3xl":"pt-3xl sm:pt-16")),Sa=(e,{someCardsHighlighted:t,showBorder:l,cardSize:n="normal"})=>w(Na,"min-w-80",wa[n],t&&(Ia(e)?"pt-3xl sm:pt-16":"pt-3xl"),l&&"border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider"),Ia=e=>e?.content&&"isHighlighting"in e.content&&e.content.isHighlighting,Ta=x((({className:e,itemCount:t,visibleItemCount:l=1,noCardBorder:n,isAlignCenter:a,arrowsPadded:i=!0,isGap:r=!0,cardSize:s="normal",...o})=>{const{blocks:c=[]}=o.block||{},d=t||c?.length,[m,{inc:h,dec:x}]=Pl({itemCount:d,visibleItemCount:l},Math.floor(l/2)),[g,f]=ca({itemCount:d}),[b]=f.visibleIndicesRange,y=c&&"CarouselBankHistoryCard"===c[0]?.type;return p(C,{className:e,defaultPadding:"p-6xl",...o,children:[p("div",{className:w(a?"flex justify-center":"","relative max-w-full"),children:[u(ta,{containerRef:g,visibleItemCount:l,snapAlign:"snap-start",gap:r?16:void 0,onVisibleIndicesChange:f.handleVisibleIndicesChange,children:ka({noCardBorder:n,activeIndex:m,cardSize:s,...o})}),u(ha,{scroll:f,arrowsPadded:i,onScrollLeft:x,onScrollRight:h,hasEdgeBlocks:y,activeIndex:m,itemCount:d})]}),u(ra,{className:"@5xl:hidden",containerRef:g,activeIndex:b,dotCount:d,listType:"horizontal-list"})]})}));Ta.childrenTypes=["CarouselCard","CarouselBankHistoryCard","CarouselCatalogCard","CarouselInvestmentCard","CarouselProductCard","CarouselProgramsCard","CarouselRecommendationCard","CarouselTariffsCard","CarouselRichTextCard","CarouselInvestmentCard","ProductBlock"],Ta.childSchema=()=>({isHighlighting:{title:"Выделить карточку",type:"boolean"}});const Ba=x((({className:e,title:t,description:l,blockIndex:n=0,isActive:a,...i})=>u(C,{className:w("relative flex h-[485px]",a?"w-[440px] z-10":"w-[340px]",e),defaultPadding:"p-0",...i,children:u("div",{className:w("basis-full self-center",Ma(n)),children:a?u(gl,{headlineVersion:"M",title:t,description:l,padding:"p-3xl",align:"text-left",className:"h-96 text-white shadow-dark-blue"}):u("div",{className:"h-[300px] flex justify-center items-center font-mohave text-title-large",children:u("span",{className:Pa(n),children:t})})})}))),Ma=e=>["bg-primary-main","bg-green-light","bg-yellow-light"][e%3],Pa=e=>["gradient-color-text-on-green","gradient-color-text-on-yellow","gradient-color-text-on-yellow"][e%3],Ra="z-10 border border-solid w-full h-full",Va=w(Ra,"absolute hidden @xl:block border-transparent"),za=x((({className:e,title:t,description:l,button:n,...a})=>u(C,{className:w("sm:pl-6xl sm:pb-4xl @container-normal",e),defaultPadding:"p-0",...a,children:p("div",{className:"relative",children:[u("div",{className:w(Va,"top-9 right-12 bg-green-dark")}),u("div",{className:w(Va,"top-6 right-8 bg-green")}),u("div",{className:w(Va,"top-3 right-4 bg-green-light")}),p("div",{className:w(Ra,"relative p-xl sm:p-5xl bg-white border-transparent sm:border-green-light"),children:[u(gl,{title:t,description:l,headlineVersion:"L",align:"text-left",isEmbedded:!0}),dl([n],{className:"mt-m sm:mt-6xl sm:justify-center",isVertical:!0})]})]})}))),Aa={start:"@xl:self-start",center:"@xl:self-center",end:"@xl:self-end"},Da=x((({className:e,defaultPadding:t,padding:l,title:n="",insetTitle:a="",buttons:i,leftImage:r,rightImage:s,imageAlign:o,isImageAlwaysOnRight:c=!1,isImageSecondary:d=!1,children:m})=>p("div",{className:w("relative flex flex-col gap-3xl overflow-hidden",l||t,e),children:[n?u("div",{className:"relative",children:n}):null,p("div",{className:w("grow relative flex flex-col @md:flex-row gap-3xl",r?"self-start":""),children:[$a(r,{imageAlign:o,className:"m-auto"}),p("div",{className:w("grid gap-3xl",s?"@xl:grid-cols-2":"",r?"":"grow"),children:[p("div",{className:"grow space-y-lg min-w-fit",children:[a,m]}),$a(s,{className:w("@xl:justify-self-end @xl:col-start-2",i?_a(c):"",ja(c),Oa(d)),imageAlign:o}),La(i)]})]})]}))),_a=e=>e?"row-span-2":"@xl:row-span-2",ja=e=>e?"justify-self-end col-start-2 self-center":"",La=e=>e?u("div",{className:"self-end",children:e}):null,$a=(e,{className:t,imageAlign:l})=>e?u("div",{className:w("shrink-1/2 justify-self-center",l&&Aa[l],t),children:e}):null,Oa=e=>e?"hidden @md:block":"",Ea={black:"bg-black",white:"bg-white"},Fa=x((({className:e="",title:t,description:l,image:n,price:a,button:i,colors:r=[],align:s="text-left",padding:o,...c})=>u(C,{className:w("flex flex-col justify-left",e),defaultPadding:"p-2xl",...c,children:p(Da,{className:"h-full",padding:o,title:t||l?u(gl,{title:t,description:l,headlineVersion:"XS",isEmbedded:!0,align:s}):null,rightImage:n?.src?u($t,{className:"flex justify-center align-center mb-xl",image:n}):null,buttons:dl([i],{buttonClassName:"w-full self-end"}),children:[r?.length?p("div",{className:"flex text-secondary-text mb-m",children:[u("div",{className:"mr-xs",children:u(me,{size:"text-s",align:"text-left",font:"font-light",children:"Цвета:"})}),r.map(Ua)]}):null,a?p(me,{size:"text-h3",align:"text-left",children:[a," ₽"]}):null]})}))),Ua=(e,t)=>u("div",{role:"figure",className:`w-6 h-6 ml-s border border-solid border-main-divider rounded-full ${Ea[e]}`},String(t)),Ha={1:"grid-cols-1",2:"grid-cols-2"},Wa=x((({className:e,padding:t,additionalDescription:l,cardsList:n=[],columnsMode:a=1,description:i,image:r,title:s,...o})=>u(C,{className:w("text-left",e),padding:"p-0",...o,children:p(Da,{className:"h-full",defaultPadding:"p-xl",padding:t,title:s?u(I,{headingType:"h4",as:"h3",className:"mb-m z-10",title:s}):null,rightImage:r?.src?u($t,{image:r}):null,children:[p("div",{className:"flex justify-between mb-m",children:[i?u("div",{className:"w-1/3",children:u(me,{size:"text-h6",children:i})}):null,l?u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:l}):null]}),n.length?u("ul",{className:w("list-none m-0 p-0 grid gap-xs",Ha[a]),children:Xa(n)}):null]})}))),Xa=e=>e.map(((e,t)=>p("li",{children:[e?.parameter?u("div",{className:"inline pr-xs",children:u(me,{size:"text-h6",children:e.parameter})}):null,e?.parameterDescription?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e.parameterDescription}):null]},String(t)))),Ka="hidden xl:block absolute w-full h-full border border-white",Ya=x((({text:e,href:t="",target:l="",className:n=""})=>{const a=q()({href:t,target:l});return e?u("div",{className:w("flex relative group/link pl-s pb-s min-w-[16rem] xl:min-w-[20rem]",n),children:p("div",{className:"relative min-h-16 w-full",children:[p("a",{className:w("absolute border\n bg-white flex justify-between group-hover/link:text-primary-main","sm:rounded-md rounded-none w-full px-xl py-lg whitespace-nowrap z-10"),role:"link",...a,children:[u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:e}),u($t,{className:"group-hover/link:brightness-100 hidden xl:block ml-2xs",image:{icon:"ArrowRightIcon",iconVersion:"black"},imageClassName:"group-hover/link:text-primary-main hidden xl:block",width:"24",height:"24"})]}),u("div",{className:w(Ka,"-bottom-1.5 -left-1.5")}),u("div",{className:w(Ka,"-bottom-3 -left-3")})]})}):null})),Ga=x((({className:e,additionalDescription:t,description:l,links:n,title:a,...i})=>u(C,{className:w("overflow-hidden",e),...i,children:p("div",{className:"flex flex-col @6xl:flex-row gap-m",children:[p("div",{children:[u(gl,{isEmbedded:!0,title:a,description:l,as:"h1",align:"text-left"}),t?u(gl,{className:"pt-m",description:t,align:"text-left",isEmbedded:!0}):null]}),n?.length?qa(n,"@6xl:min-w-[672px] p-0 justify-self-end"):null]})}))),qa=(e,t="")=>{const l=Math.ceil(e.length/10);return u(Ta,{className:t,version:"secondary",itemCount:l,arrowsPadded:!1,padding:"p-0",children:new Array(l).fill(null).map(((t,l)=>u("div",{className:w("flex flex-wrap gap-2xs self-start xl:justify-center @5xl:grid @5xl:grid-cols-2"),children:e.slice(10*l,10*(l+1)).map(((e,t)=>u(Ya,{...e},String(t))))},String(l))))})},Ja=x((({className:e="",href:t,target:l,isRemote:n=!1,children:a})=>{const i=q({isRemote:n})({href:t,target:l});return u(t?"a":"div",{className:w("block",e),...t?i:{},children:a})})),Za={L:"w-1.5 h-1.5 mr-m",M:"w-1.5 h-1.5 mr-s",S:"w-1 h-1 mr-xs",XS:"w-1 h-1 mr-xs"},Qa=x((({className:e,isDotted:t=!0,children:l,size:n="M"})=>p("div",{className:w("font-sans flex",e),role:"listitem",children:[t?u("div",{className:"shrink-0",children:u("div",{className:w("align-middle inline-block rounded-full bg-primary-text group-data-secondary:bg-white",Za[n])})}):null,u("span",{children:l})]}))),ei={XS:"text-m font-light",S:"text-l font-light",M:"text-h6",L:"text-h5"},ti={XS:"ml-2xs",S:"ml-xs",M:"ml-s",L:"ml-m"},li=x((({className:e,hasIndent:t,isDotted:l,items:n,listItemSize:a="M"})=>n?.length?u("section",{className:w("flex flex-col gap-xs text-left text-primary-text group-data-secondary:text-white group-data-gray:text-secondary-text",ei[a],t?ti[a]:"",e),role:"list",children:n.map(((e,t)=>u(Qa,{isDotted:l,size:a,children:e},String(t))))}):null)),ni=x((({additionalDescription:e,align:t=tl,button:l={},className:n="",description:a,headlineSmallVersion:i="H6",href:r,icon:s,isDotted:o=!0,isButtonFullWidth:c=!0,isImageFullWidth:d=!1,isTopPosition:m=!1,items:h=[],target:u,title:x,version:g="primary",...f})=>p(C,{className:w("flex flex-col justify-between",n),defaultPadding:"p-0",version:g,...f,children:[p(Ja,{className:"p-m flex flex-col gap-xs",href:r,target:u,children:[ii(i,x,t),ri(a,t),oi(h,o,g),si(e,t),ai(s,d,m)]}),dl([l],{className:w("p-m pt-0",c?"":"self-center"),isVertical:c})]}))),ai=(e,t,l)=>p("div",{className:w("flex gap-y-lg justify-center",t?"min-w-full h-full":"",l?"order-first":"order-last"),children:[e?.src?u($t,{image:e}):null,e?.icon?u($t,{className:w(t?"w-full h-full":"w-8 h-8 min-w-8"),image:e}):null]}),ii=(e,t,l)=>t?u(me,{align:l,size:xl[e],children:t}):null,ri=(e,t)=>e?u(de,{align:t,size:"text-l",children:e}):null,si=(e,t)=>e?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text group-data-secondary:text-white/80",align:t,children:e}):null,oi=(e,t,l="primary")=>e?.length?u(li,{className:w("text-s","primary"===l?"!text-secondary-text":""),items:e.filter((e=>e?.text)).map((e=>e.text)),isDotted:t,listItemSize:"S"}):null,ci=(e=[])=>e.reduce(((e,t)=>e+t),0),di=(e=[])=>e?.length?ci(e)/e.length:0,mi=(e,t="normal")=>e?u("div",{className:w("sm:w-12 sm:h-12 sm:min-w-12 w-11 h-11 min-w-11 box-border flex items-center justify-center rounded-icon","normal"===t?"bg-secondary-light text-primary-main":"bg-primary-main text-black group-data-secondary:bg-white/30 group-data-secondary:text-black"),children:u($t,{className:"w-6 h-6",image:{...e,iconVersion:e.iconVersion||t}})}):null,hi=x((e=>{const{__html:t="",richVersion:l=""}=e;return t.replace(/<\/?[^>]+\/?>/g,"").trim()?u("div",{className:w(l,"md-container"),dangerouslySetInnerHTML:{__html:t}}):null})),ui=(e,t)=>e?u(de,{font:"font-light",size:"text-m",color:"text-secondary-text group-data-secondary:text-white",children:e},`description-${t}`):null,pi=(e,t)=>e?u(me,{color:"text-primary-text group-data-secondary:text-white",size:"text-h6",children:e},`label-${t}`):null,xi=(e,t)=>"rte"===e.type&&"__html"in e&&e.__html?u(hi,{...e},`rte-${t}`):["label"in e?pi(e.label,t):null,"description"in e?u("span",{className:e.descriptionClassName,children:ui(e.description,t)},String(t)):null],gi=x((({className:e,benefitsVersion:t,...l})=>p("div",{className:w("flex gap-m min-w-56","description"in l&&l.description?"items-start":"items-center",e),children:["icon"in l?mi(l.icon,t):null,u("div",{children:xi(l)})]}))),fi=e=>"rte"===e.type?e?.__html?.length||0:Math.max(e?.label?.length||0,e?.description?.length||0),bi=e=>{return((t=e.map(fi))?.length?Math.sqrt(Math.abs(di(t.map((e=>e**2)))-di(t)**2)):0)>16;var t},yi=e=>e&&"icon"in e&&e.icon&&(e.icon.icon||e.icon.src),vi=e=>!e.some(yi),Ni=x((({className:e,benefitsVersion:t="normal",benefits:l})=>l?.length?u("div",{className:w("flex gap-x-m gap-y-s",bi(l)||vi(l)?"flex-col":"flex-wrap",e),children:l.map(((e,l)=>u(gi,{benefitsVersion:t,...e},String(l))))}):null)),wi=x((({className:e,benefits:t})=>t?.length?u("div",{className:w("grid grid-cols-[max-content_1fr] auto-rows-auto items-baseline gap-x-m gap-y-xs",e),children:t.flatMap(xi)}):null)),ki=x((({isTabularBenefits:e,...t})=>u(e?wi:Ni,{...t}))),Ci=x((({className:e,tags:t})=>t?.length?u("div",{className:w("flex flex-wrap gap-xs",e),role:"list",children:t.map(Si)}):null)),Si=(e,t)=>u("div",{className:"p-xs border-solid border rounded-md border-gray",role:"listitem",children:u(me,{size:"text-m",font:"font-light",children:e})},String(t)),Ii=x((({className:e,padding:t,defaultPadding:l,title:n,description:a,headlineVersion:i="L",align:r="text-left",benefitsVersion:s,isTabularBenefits:o,benefits:c,__html:d,isFullWidthTitle:m,items:h,isDotted:x=!0,listItemSize:g,tags:f=[],buttons:b,image:y,imageOptions:{imageAlign:v="center",directionRight:N=!0,isImageAlwaysOnRight:w,isImageSecondary:k=!1}={},children:C})=>{const S=y?.src?u($t,{image:y}):null,I=Mi({title:n,description:a,headlineVersion:i,align:r}),T=c?.filter((e=>"rte"===e?.type||"label"in e||"description"in e));return u(Da,{className:e,padding:t,defaultPadding:l,...m?{title:I}:{insetTitle:I},...Ti(S,N),isImageSecondary:k,imageAlign:v,isImageAlwaysOnRight:w,buttons:dl(b),children:p("div",{className:"flex flex-col sm:gap-xl gap-4xl",children:[T?.length?u(ki,{benefitsVersion:s,isTabularBenefits:o,benefits:T}):null,d?u(hi,{__html:d}):null,h?.length?u(li,{items:h,isDotted:x,listItemSize:g}):null,C,Bi(f)]})})})),Ti=(e,t)=>t?{rightImage:e}:{leftImage:e},Bi=e=>e?.length?u(Ci,{tags:e}):null,Mi=({title:e,description:t,headlineVersion:l,align:n})=>e||t?u(gl,{title:e,description:t,headlineVersion:l,align:n,isEmbedded:!0}):null,Pi=[{origins:["t.me","telegram.org"],iconMapped:{icon:"TelegramIcon"}},{origins:["vk.com"],iconMapped:{icon:"VKIcon"}},{origins:["ok.ru"],iconMapped:{icon:"OkIcon"}},{origins:["apps.apple.com"],iconMapped:{icon:"AppleIcon"}},{origins:["play.google.com"],iconMapped:{icon:"PlayMarketIcon"}},{origins:["youtube.com"],iconMapped:{icon:"YoutubeIcon"}},{origins:["rutube.ru"],iconMapped:{icon:"RutubeIcon"}}],Ri=x((({className:e="",media:t,showButtonText:l,stretched:a,version:i="white",children:r})=>{const[s,o]=n(),c=t?.map((e=>{const{href:t,icon:n,text:a}=e,{iconMapped:r}=(e=>Pi.find((({origins:t})=>t?.some((t=>e?.includes(t)))))||{})(t),c=cl(n)?n:r,d=l?{text:a}:{text:""};return!s&&a&&o(!0),{...e,...d,icon:{...c,iconVersion:"color"},version:i}})),d=w("border border-solid hover:border-transparent group-data-primary:border-main-divider border-main-divider group-data-gray:border-green group/media",l&&s?"":" basis-auto",a?"flex-1 justify-center":"");return p("div",{className:"flex flex-col sm:flex-col-reverse gap-xs",children:[r?u(me,{size:"text-s",font:"font-light",color:"text-secondary-text",children:r}):null,u("div",{className:w("flex gap-xs",e),children:dl(c,{className:a?"w-full":"",buttonClassName:d})})]})})),Vi=x((({className:e,padding:t,description:l,href:n,icon:a,items:i=[],listItemSize:r="S",socialMedia:s=[],target:o,title:c,align:d="text-left",benefits:m,imageOptions:{directionRight:h=!0,isImageAlwaysOnRight:x=true,isImageSecondary:g=!1}={},...f})=>u(C,{className:w("relative min-h-28 group-data-gray:bg-main-divider/50",e),defaultPadding:"p-0",...f,children:u(Ja,{href:n,target:o,className:"h-full",children:p(Da,{className:"h-full",defaultPadding:"p-2xl",padding:t,insetTitle:c?u(gl,{title:c,description:l,headlineVersion:"S",isEmbedded:!0,align:d}):null,...Ti(cl(a)?u($t,{image:a}):null,h),buttons:s.length?u(Ri,{media:s,showButtonText:!0,version:f?.version}):null,isImageAlwaysOnRight:x,isImageSecondary:g,children:[u(ki,{benefits:m}),u(li,{items:i,listItemSize:r})]})})}))),zi=x((({className:e="",__html:t,richVersion:l="striped",...n})=>u(C,{className:e,...n,children:u(hi,{__html:t,richVersion:l})}))),Ai=x((({className:e="",isFoldButtonOnTop:t=!1,unfoldedByDefault:l=!1,renderFoldableSection:a,renderFoldButton:r})=>{const[s,o]=n(l),c=i((()=>{o((e=>!e))}),[]),d=a({isUnfolded:s,onToggle:c}),m=r?r({isUnfolded:s,onToggle:c}):null;return p("div",t?{className:e,children:[m,d]}:{className:e,children:[d,m]})})),Di=x((({className:e="",isUnfolded:t,children:l})=>{const n=s(null);return a((()=>{n.current&&(n.current.style.maxHeight=t?`${n.current.scrollHeight}px`:"")}),[t,l?.length]),u("div",{ref:n,className:`transition-max-h duration-300 overflow-hidden ${n.current||!t?"max-h-0":""} ${e}`,children:l})})),_i=(e,t)=>{const{title:l,description:n,buttons:a}=e;return p("div",{className:"py-lg border-b border-main-divider",children:[l?u("div",{className:"opacity-80",children:u(me,{size:"text-m",color:"text-secondary-text",children:l})}):null,n?u("div",{className:"mt-2xs",children:u(me,{size:"text-xl",color:"text-primary-text",children:n})}):null,a?.length?u("div",{className:"text-primary-main",children:dl(a)}):null]},String(t))},ji=x((({className:e="",title:t,align:l="text-center",icon:n,button:a,cardCells:i=[],...r})=>{const s=i.map(_i),o=s.slice(0,1),c=s.slice(1);return p(C,{className:w("flex flex-col",e),defaultPadding:"p-3xl",...r,children:[cl(n)?u("div",{className:"self-center",children:u($t,{image:n})}):null,t?u(I,{className:w("pt-xs",l),headingType:"h5",title:t}):null,a?u(se,{className:"w-full mt-m",...a}):null,i.length?u(Ai,{renderFoldableSection:({isUnfolded:e})=>p("div",{children:[o,u(Di,{isUnfolded:e,children:c})]}),renderFoldButton:i.length>1?Li:null}):null]})})),Li=({isUnfolded:e,onToggle:t})=>p("button",{className:"w-full cursor-pointer text-primary-main pt-lg flex justify-between items-center",onClick:t,children:[u("div",{children:e?"Скрыть":"Подробнее о тарифе"}),u(Ae,{className:"text-primary-text",name:e?"ArrowUpIcon":"ArrowDownIcon",width:"16",height:"16"})]}),$i="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",Oi="border-gray border-solid border",Ei="border-main-divider border-b",Fi="w-52",Ui=x((({icon:e,image:t,title:l,link:n})=>p("div",{className:w("w-80 box-border flex flex-col gap-m items-center rounded-t-md border-b-0 p-2xl",Oi,$i),role:"columnheader",children:[e&&!t?.src&&u($t,{className:"h-16 w-16 min-w-16 min-h-16",image:e,width:"64",height:"64"}),t?.src&&u($t,{image:t}),l?u(I,{headingType:"h4",as:"h3",className:"text-center text-white",title:l}):null,n?.text&&u("div",{className:"mt-auto w-full",children:u(se,{href:n.href,target:n.target,className:"w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:u("div",{className:"text-xs font-light font-medium py-s",children:n.text})})})]}))),Hi={comparison:"flex gap-m duration-1000",tariff:"flex gap-5xl flex-grow duration-1000"},Wi=x((({children:e,activeIndex:t,columnWidth:l,version:n="comparison"})=>u("div",{className:"flex flex-1 overflow-hidden",children:u("div",{className:Hi[n],style:{transform:`translateX(-${t*l}px)`},children:e})}))),Xi=x((({children:e})=>u("div",{className:"self-start flex flex-col",role:"row",children:u("div",{className:"flex gap-xl",children:e})}))),Ki=x((({colHeaders:e,activeIndex:t})=>p(Xi,{children:[u("div",{className:Fi,role:"columnheader"}),u(Wi,{activeIndex:t,columnWidth:336,children:e.map(((e,t)=>u(Ui,{...e},String(t))))})]}))),Yi=x((({cell:e,isFirstRow:t,isLastRow:l,isFillGradient:n})=>{const a=w("w-80 box-border flex flex-col",Oi,l?"border-t-0 rounded-b-md":"border-y-0",n?$i:""),i=w("mx-2xl h-full",Ei,n&&t?"border-t":"",l?"border-b-0":"border-solid");return u("div",{className:a,role:"cell",children:u("div",{className:i,children:e.map(((e,t)=>Ji(e,t,n)))})})})),Gi=(e=!1)=>"text-xl m-0 "+(e?"text-white":""),qi=(e=!1)=>"text-s opacity-80 "+(e?"text-white":"text-secondary-text"),Ji=({label:e,description:t},l,n)=>p("div",{className:"first:pt-2xl pt-xl last:pb-2xl",children:[e?u("h4",{className:Gi(n),children:e}):null,t?u("div",{className:qi(n),children:t}):null]},String(l)),Zi=(e=!1)=>w("text-s py-2xl",Ei,Fi,e?"border-b-0":"border-solid"),Qi=x((({row:{header:e,data:t},activeIndex:l,isColoredFirstColumn:n,isFirstRow:a,isLastRow:i})=>p(Xi,{children:[e?.title?u("div",{className:Zi(i),children:e.title}):null,t?.length?u(Wi,{activeIndex:l,columnWidth:336,children:t.map(((e,t)=>u(Yi,{cell:e,isFirstRow:a,isLastRow:i,isFillGradient:n&&0===t},String(t))))}):null]}))),er=x((({rowData:e,isColoredFirstColumn:t,activeIndex:l,controls:n})=>{const{isScrollAvailable:a}=n;return p("div",{className:"relative",children:[e.map(((e,n,{length:a})=>u(Qi,{row:e,isFirstRow:0===n,isLastRow:n+1===a,activeIndex:l,isColoredFirstColumn:t},String(n)))),a?Al({...n,btnClass:["top-28","top-12"],className:"right-7",isDisabled:!0}):null]})})),tr=x((({columns:e=[],rowHeaders:t,isShowAllRow:l,visibleRowLength:n,isColoredFirstColumn:a})=>{const i=e?.map((({header:e})=>e||{})),r=e?.map((({data:e})=>e))||[],s=t?.map(((e,t)=>({header:e,data:r.map((e=>e?.[t]||[{}]))}))).slice(0,l?t.length:n),[o,c]=Pl({itemCount:e.length,visibleItemCount:3}),{isScrollAvailable:d}=c;return p("div",{children:[p("div",{role:"table",children:[i?.length?u(Ki,{colHeaders:i,activeIndex:o}):null,s?.length?u(er,{rowData:s,isColoredFirstColumn:a,activeIndex:o,controls:c}):null]}),d?u("div",{className:"absolute top-0 right-0 bottom-0 w-20 bg-opacity-to-white"}):null]})})),lr=x((({className:e="",title:t,rowHeaders:l,columns:a,visibleRowLength:r=0,isColoredFirstColumn:s=!1,...o})=>{const[c,d]=n(!r),m=i((()=>d((e=>!e))),[]);return p(C,{className:w("overflow-hidden relative",e),defaultPadding:"p-6xl",...o,children:[u(I,{headingType:"h2",className:"text-center mb-4xl mx-auto",title:t}),u(tr,{columns:a,rowHeaders:l,isShowAllRow:c,isColoredFirstColumn:s,visibleRowLength:r}),r?nr({isShowAllRow:c,onClick:m}):null]})})),nr=({isShowAllRow:e,onClick:t})=>u("div",{className:"pr-6xl",children:p("div",{className:"flex gap-m w-full",children:[u("div",{className:Fi}),u("button",{onClick:t,className:"py-xs flex-1 border-gray border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:u(me,{size:"text-xs",font:"font-medium",children:e?"Скрыть":"Показать все параметры"})})]})}),ar=x((({className:e,contacts:t,info:l,version:n="secondary",...a})=>p(C,{className:w("flex",e),defaultPadding:"p-6xl",version:n,...a,children:[l?.length?ir(l):null,t?.length?ir(t):null]}))),ir=e=>u("div",{className:"flex gap-5xl grow basis-0",children:e.map(((e,t)=>rr({column:e,index:t})))}),rr=({column:e,index:t})=>e?u("div",{className:"flex flex-col gap-xl grow basis-0",children:e.map((({title:e="",description:t,additionalDescription:l,button:n},a)=>p("div",{children:[u(gl,{title:e,description:t,headlineVersion:"XS",align:"text-left",isEmbedded:!0}),l?u("div",{className:"mt-xs opacity-80",children:u(de,{size:"text-m",font:"font-light",children:l})}):null,n?.href?u(se,{className:"mt-xl",...n}):null]},String(a))))},`col-${String(t)}`):null,sr=x((({textNode:e,iconNode:t,tag:l,onClick:n,justifyContent:a="between",className:i,...r})=>p(l,{tag:l,className:w("flex items-center w-full gap-1","between"===a?"justify-between":"justify-center",i),onClick:n,...r,children:[e?u("div",{children:e}):null,t?u("div",{children:t}):null]}))),or=x((({className:e="",label:t,icon:l,dataTheme:n="",disabled:a=!1,onClick:i})=>u(sr,{tag:"button",onClick:i,disabled:a,"data-theme":n,justifyContent:"center",className:w("py-4 border border-transparent outline-none focus:border-primary-text",a?"bg-main-divider text-main-disabled hover:bg-main-divider":"bg-primary-main text-white hover:bg-primary-hove",e),textNode:u("span",{className:"text-h4 pr-s",children:t}),iconNode:l?u($t,{image:{icon:l,iconVersion:"white"},className:"my-auto",width:"20",height:"20"}):null}))),cr=({isUnfolded:e,onToggle:t})=>u(or,{icon:["ArrowDownIcon","ArrowUpIcon"][Number(e)],label:["Развернуть","Скрыть"][Number(e)],onClick:t}),dr=x((({title:e,description:t})=>p("div",{className:"bg-white p-6xl py-20 flex gap-s flex-col @xl:items-center",children:[u($t,{image:{icon:"MagnifierIcon"},width:"120",height:"120"}),u(gl,{title:e,description:t,headlineVersion:"S",isEmbedded:!0,align:tl})]}))),mr=["ArrowDownIcon","ArrowUpIcon"],hr="space-y-px lg:space-y-0 lg:grid lg:grid-cols-12 gap-2xs border-box",ur=x((({label:e="",blocksToRender:t=[],topItemsCount:l=0,block:n,notFound:a,...i})=>{const[r,s]=l>0?[t.slice(0,l),t.slice(l)]:[t,[]];return p("div",{children:[u("div",{className:w(t.length?"hidden":"block"),children:a?u(dr,{...a}):null}),p("div",{className:w("space-y-2xs",t.length?"":"hidden"),children:[u("div",{className:w(hr),children:ba(r,{...i.options,parent:n})}),u(Ai,{renderFoldableSection:({isUnfolded:e})=>u(Di,{className:w(hr),isUnfolded:e,children:ba(s,{...i.options,parent:n})}),renderFoldButton:({isUnfolded:t,onToggle:n})=>u(or,{className:w(l<1?"hidden":""),disabled:!s?.length,label:e,icon:mr[Number(t)],dataTheme:i.options?.page?.colorPalette,onClick:n})})]})]})})),pr=e=>null==e||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length,xr=(e,t)=>Object.entries(e).map((([l,n])=>"number"==typeof n?Array.isArray(t[l])?((e,t)=>l=>pr(t[e])||pr(l[e])||l[e]?.includes(t[e]))(l,e):((e,t)=>l=>pr(t[e])||pr(l[e])||gr(t[e])<=gr(l[e]))(l,e):"object"==typeof n&&"min"in n&&"max"in n?((e,t)=>l=>pr(t[e])||pr(l[e])||gr(t[e]?.min)>=gr(l[e]?.min)&&gr(t[e]?.min)<=gr(l[e]?.max))(l,e):Array.isArray(n)?((e,t)=>l=>pr(t[e])||pr(l[e])||t[e]?.some((t=>l[e]?.includes(t))))(l,e):((e,t)=>l=>pr(t[e])||pr(l[e])||t[e]===l[e])(l,e))).every((e=>e(t))),gr=e=>Number(e||0),fr=(e,t)=>(l=T)=>e&&e.filter((e=>xr(t,l(e.content||{})))),br=x((({value:e,onChange:t,items:l=[],multiple:n})=>l.map((l=>u(qe,{text:l.title,value:[e].flatMap((e=>e)).includes(l.value),onChange:()=>(l=>{if(t)if(n){const n=e?.includes(l);t(n?(e||[]).filter((e=>e!==l)):[...e||[],l])}else t(e===l?"":l)})(l.value),type:n?"checkbox":"radio"},l.value))))),yr=({field:e,reset:t,filtrationSchema:l,resetButton:n,children:a})=>p("form",{className:"flex flex-col @4xl:flex-row justify-between bg-white p-4xl gap-s @4xl:gap-0",children:[p("div",{className:"flex flex-col @4xl:flex-row gap-5xl",children:[a,Object.entries(l).map(vr(e))]}),n?u("div",{children:u(se,{className:"w-full @4xl:w-72 @4xl:ml-s",onClick:t,...n})}):null]}),vr=e=>([t,l])=>{const n=l?.type;return"array"===n?Nr(t,e)(l):null},Nr=(e,t)=>l=>{const n=l?.items?.enum?.map(((e,t)=>({value:e,title:l?.items?.enumNames?.[t]||""})))||[];return p("div",{children:[l?.title?u("div",{className:"mb-m",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:l.title})}):null,u(br,{items:n,multiple:!0,...t(e)})]},e)},wr=(e,t)=>e[t?.sourceBook]?.rateRows.map((e=>e.minMonths)).filter((e=>void 0!==e));async function kr(...e){const t=e.map((e=>_(e)));return Promise.all(t)}function Cr(e,...t){return e.map(((e,l)=>[e,...t.map((e=>e[l]))]))}const Sr=e=>Boolean(e&&e.content&&"string"==typeof e.content.sourceBook);function Ir(e){const{dirs:t=[],source:l=[]}=r((()=>{const t=(e=>e?.filter(Sr).map((({content:{sourceBook:e}})=>e)))(e);return{dirs:t?.map((e=>`/wcms-resources/${e}.json`)),source:t}}),[e]),{data:n=[]}=A(t,kr);return{source:Object.fromEntries(Cr(l,n).filter((([,e])=>Boolean(e)))),months:(a=n.flatMap((e=>e?.rateRows||[])).filter((e=>"number"==typeof e.minMonths&&e.minMonths===e.maxMonths)).map((e=>e.minMonths)),[...new Set(a)]).sort(((e,t)=>e-t))||[]};var a}const Tr=1e9,Br={sum:{min:1e4,max:Tr},period:3},Mr=x((({className:e,filtrationSchema:t={},resetButton:l,sumInput:n,periodInput:a,...i})=>{const{source:r,months:s}=Ir(i.block?.blocks),[o,{field:c,reset:d}]=B(Br),m=fr(i.block?.blocks,o)((e=>({...e,period:wr(r,e||{})||[]}))),h=p("div",{children:[u(Yn,{label:n?.title,min:500,max:Tr,...c("sum",{parse:e=>({min:Number(e),max:Tr}),format:({min:e})=>String(e)})}),u(yt,{title:a?.title,items:["От 3 мес","До 5 лет"],list:s,...c("period")})]});return p(C,{className:w("space-y-2xs",e),defaultPadding:"p-0",version:"transparent",...i,children:[yr({field:c,reset:d,filtrationSchema:t,resetButton:l,children:h}),u(ur,{blocksToRender:m,...i})]})})),Pr={type:"string",title:"Адрес справочника"};Mr.childrenTypes=["ProductTile"],Mr.childSchema=e=>({...e?.filtrationSchema||{},sourceBook:Pr});const Rr=[{key:"10"},{key:"50"},{key:"100"}],Vr=({itemCount:e,onItemCountChange:t})=>{const l=i((({key:e})=>t(Number(e))),[]);return p("div",{className:"flex items-center gap-s",children:[u("span",{children:"Показать по"}),u(He,{className:"min-w-20",onChange:l,value:{key:String(e)},options:Rr,iconVersion:"black"})]})},zr="py-m px-lg rounded-md cursor-pointer hover:bg-green-more-dark hover:text-white",Ar=(e,t)=>{const{currentPage:l,onPageChange:n,totalPages:a}=e,i=t+1;return i===l?u("div",{"aria-current":"true",className:"py-m px-lg bg-green-light text-white rounded-md",children:i},String(t)):1!==i&&i!==a&&((e,t,l)=>e<t&&e>=t-2||e<=t+2&&e>t||((e,t,l)=>t<=3&&e<=t+3||t>=l-1&&e>=l-4)(e,t,l))(i,l,a)?u("div",{onClick:()=>n(i),className:zr,"aria-label":`Страница ${i}`,children:i},String(t)):null},Dr={width:"24",height:"24"},_r=({currentPage:e,onPageChange:t,totalPages:l})=>{const n=r((()=>new Array(l).fill({currentPage:e,onPageChange:t,totalPages:l})),[l,e]),a=i((()=>{e>1&&t(e-1)}),[e]),s=i((()=>{e<l-1&&t(e+1)}),[e,l]),o=i((()=>t(1)),[]),c=i((()=>t(l)),[l]);return p("div",{className:"flex gap-m items-center",children:[u("div",{onClick:a,children:u(Ae,{name:"ArrowLeftIcon",iconVersion:"black",imageClassName:jr(1===e),...Dr})}),p("div",{className:"flex gap-xs",children:[e>1?u("div",{onClick:o,className:zr,"aria-label":"Страница 1",children:"1"}):null,e>4?u("div",{className:"py-m px-s",children:"..."}):null,n.map(Ar),e<l-3?u("div",{className:"py-m px-s",children:"..."}):null,e<l?u("div",{onClick:c,className:zr,"aria-label":`Страница ${l}}`,children:l}):null]}),u("div",{onClick:s,children:u(Ae,{className:"rotate-180",name:"ArrowLeftIcon",iconVersion:"black",imageClassName:jr(e===l),...Dr})})]})},jr=e=>e?"opacity-20":"cursor-pointer hover:opacity-60",Lr=({currentPage:e,onPageChange:t,totalPages:l,itemCount:n,onItemCountChange:a})=>p("div",{className:"mt-3xl flex justify-between items-center select-none",role:"navigation","aria-label":"Пагинация",children:[u(_r,{currentPage:e,onPageChange:t,totalPages:l}),n&&a?u(Vr,{itemCount:n,onItemCountChange:a}):null]}),$r=(e,t=!1)=>{if("string"==typeof e)return e.split("-").reverse().join(".");{const l=String(e.getDate()).padStart(2,"0"),n=String(e.getMonth()+1).padStart(2,"0"),a=t?String(e.getFullYear()):String(e.getFullYear()).slice(-2);return t?`${a}-${n}-${l}`:`${l}.${n}.${a}`}},Or=()=>{},Er=({today:e,firstDayOfWeek:t,totalDays:l,currentMonth:n,currentYear:a,min:i,max:r,onDateClick:s})=>{const o=[];let c=1;for(let d=0;d<6;d++){const m=[];for(let o=0;o<7;o++)if(0===d&&o<t)m.push(u("td",{},`empty-${o}`));else if(c>l)m.push(u("td",{},`empty-${o}`));else{const t=new Date(a,n,c),l=Fr(t,e),o=Ur(t,i,r);m.push(u("td",{children:u("div",{className:Hr(l,o),onClick:()=>!o&&s(t),children:c})},`day-${c}`)),c++}o.push(u("tr",{children:m},`row-${d}`))}return o},Fr=(e,t)=>t&&e.toDateString()===t.toDateString(),Ur=(e,t,l)=>t&&e.getTime()<t.getTime()||l&&e.getTime()>l.getTime(),Hr=(e,t)=>w("p-s text-center rounded-md border",e?"":"border-transparent hover:bg-gray",t?"text-gray hover:bg-transparent":"cursor-pointer"),Wr=["Пн","Вт","Ср","Чт","Пт","Сб","Вс"],Xr=x((({today:e,currentMonth:t,currentYear:l,min:n,max:a,onDateSelect:s=Or})=>{const o=i((e=>s(e)),[]),{firstDayOfWeek:c,totalDays:d}=r((()=>({firstDayOfWeek:new Date(l,t,1).getDay()-1,totalDays:new Date(l,t+1,0).getDate()})),[l,t]);return p("table",{className:"mx-auto",children:[u("thead",{className:"text-gray font-light",children:u("tr",{children:Wr.map(((e,t)=>u("th",{className:"p-s",children:e},String(t))))})}),u("tbody",{children:Er({firstDayOfWeek:c,today:e,totalDays:d,currentYear:l,currentMonth:t,min:n,max:a,onDateClick:o})})]})})),Kr=["Январь","Февраль","Март","Апрель","Май","Июнь","Июль","Август","Сентябрь","Октябрь","Ноябрь","Декабрь"],Yr=Kr.map((e=>({key:e}))),Gr=Array.from({length:(new Date).getFullYear()-1970+1},((e,t)=>1970+t)).reverse().map((e=>({key:String(e)}))),qr={name:"ArrowUpIcon",iconVersion:"black",width:"24",height:"24"},Jr={className:"min-w-32",iconVersion:"black",isBorder:!1},Zr=x((({className:e="",label:t="",value:l,minDate:a,maxDate:r,onChange:s})=>{const[o,{setValue:c}]=Ve(!1),[d,m]=n(l?.getMonth()||(new Date).getMonth()),[h,x]=n(l?.getFullYear()||(new Date).getFullYear()),{handlePrevMonth:g,handleNextMonth:f,handleSelectMonth:b,handleSelectYear:y,monthsOptions:v,yearsOptions:N,handleChangeVisibleCalendar:k,ref:C}=(({onShowCalendar:e,showCalendar:t,selectedMonth:l,onMonthSelect:n,onYearSelect:a,selectedYear:r})=>{const s=Oe(i((()=>t&&e(!1)),[t]));return{handleChangeVisibleCalendar:i((()=>e(!t)),[t]),handleNextMonth:i((()=>{l+1<=11?n(l+1):(n(0),a(r+1))}),[l]),handlePrevMonth:i((()=>{l-1>=0?n(l-1):(n(11),a(r-1))}),[l]),handleSelectMonth:i((({key:e})=>n(Kr.indexOf(e))),[]),handleSelectYear:i((({key:e})=>a(Number(e))),[]),monthsOptions:Yr,yearsOptions:Gr,ref:s}})({onYearSelect:x,onMonthSelect:m,onShowCalendar:c,selectedYear:h,selectedMonth:d,showCalendar:o});return p("div",{className:w(e,"relative"),ref:C,children:[u(me,{size:"text-m",children:t}),Qr(k,l),o?p("div",{className:"absolute bg-white z-10 select-none",children:[p("div",{className:"flex gap-s",children:[u("div",{className:"my-auto",onClick:g,children:u(Ae,{...qr,className:"-rotate-90 cursor-pointer"})}),u(He,{onChange:b,value:{key:Kr[d]},options:v,...Jr}),u(He,{onChange:y,value:{key:String(h)},options:N,...Jr}),u("div",{className:"my-auto",onClick:f,children:u(Ae,{...qr,className:"rotate-90 cursor-pointer"})})]}),u(Xr,{today:l,currentMonth:d,currentYear:h,onDateSelect:s,min:a,max:r})]}):null]})})),Qr=(e,t)=>p("div",{onClick:e,className:"flex justify-between px-m py-s border border-gray rounded-md cursor-pointer hover:border-black active:border-black focus:border-black",children:[u(de,{children:t&&$r(t)}),u(Ae,{...qr,name:"CalendarIcon"})]}),es=x((({className:e,value:t,autoFocus:l,onChange:n,onFocus:a,placeholder:r="Поиск по сайту"})=>{const s=i((e=>{n&&n(e.target?.value||"")}),[n]);return p("div",{className:w("font-sans relative",e),role:"form",children:[u("div",{className:"absolute h-full flex items-center pl-m pointer-events-none",children:u($t,{image:{icon:"LoupeIcon",iconVersion:"black"},width:"24",height:"24"})}),u("input",{className:w("h-12 w-full px-10 text-l text-black outline-none box-border border border-solid rounded-md","border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text"),value:t,type:"text",name:"search-bar-input",placeholder:r,autoFocus:l,onChange:s,onFocus:a})]})})),ts=x((({field:e,onClearFilter:t,filtrationState:l})=>p("div",{className:"grid grid-cols-12 mb-3xl space-x-xl",children:[u(es,{className:"col-span-4 mt-auto",placeholder:"Поиск",...e("query")}),u(Zr,{className:"col-span-3",label:"Период от",maxDate:l.endDate,...e("startDate")}),u(Zr,{className:"col-span-3",label:"Период до",minDate:l.startDate,...e("endDate")}),u("div",{className:"col-span-2 mt-auto",children:u("button",{className:"px-m py-s rounded-md bg-main-gray text-green cursor-pointer w-full",onClick:t,children:"Очистить фильтр"})})]}))),ls=({title:e,timestamp:t,publicId:l})=>{const n=q({basePath:"/"}),{href:a}=n({href:`/api/v1/depository/${l}/file`});return p("div",{className:"grid grid-cols-12 py-lg border-gray border-opacity-50 border-b",children:[u("div",{className:"col-span-2 text-m",children:t?u(me,{children:$r(t)}):null}),u("div",{className:"col-span-10 text-h6 hover:text-primary-active",children:u("a",{href:a,download:!0,"aria-label":"Скачать",children:e})})]},l)},ns={startDate:void 0,endDate:void 0,query:""},as=x((({className:e,...t})=>{const[l,a]=n(0),[r,s]=n(10),[o,{field:c,reset:d}]=B(ns),{totalPages:m=0,items:h}=(({size:e,page:t,query:l,startDate:n,endDate:a})=>{const{data:i}=A(`/api/v1/depository?page=${t}&size=${e}&query=${l}×tampStart=${n?$r(n,!0):""}×tampEnd=${a?$r(a,!0):""}`,j);return{items:i?.content,totalPages:i?.totalPages}})({size:r,page:l,...o}),x=i((e=>a(e-1)),[]),g=i((e=>s(e)),[]);return p(C,{className:w(e,"container p-4xl"),...t,children:[u(ts,{filtrationState:o,field:c,onClearFilter:d}),p("div",{className:"flex flex-col",children:[p("div",{className:"grid grid-cols-12 pb-lg border-gray border-opacity-50 border-b",children:[u("span",{className:"col-span-2 text-gray text-m",children:"Дата"}),u("span",{className:"col-span-10 text-gray text-m",children:"Тема"})]}),h?.length?h?.map((e=>u(ls,{...e},String(e.publicId)))):u(dr,{title:"Ничего не найдено",description:"Попробуйте очистить фильтры"}),u(Lr,{currentPage:l+1,onPageChange:x,totalPages:m+1,itemCount:r,onItemCountChange:g})]})]})})),is=e=>"Image"===e?.contentType&&e?.image?u($t,{image:e.image}):"Code"===e?.contentType&&e.code?u("div",{className:"font-mohave text-title-large sm:text-title-extra gradient-color-text",children:e.code}):null,rs=x((({className:e="",title:t,description:l,error:n,button:a,...i})=>p(C,{className:w("flex flex-col justify-center items-center",e),defaultPadding:w("p-6xl"),version:"transparent",...i,children:[u("div",{className:"flex justify-center",children:is(n)}),u(gl,{title:t,description:l,headlineVersion:"XL",isEmbedded:!0,className:"mb-2xl last:mb-0"}),a?.text?u(se,{version:a?.version,text:a?.text,...a}):null]})));var ss;!function(e){e.RUB="RUB",e.EUR="EUR",e.USD="USD"}(ss||(ss={}));const os=new Intl.NumberFormat("ru",{style:"currency",currency:ss.RUB}),cs=e=>e?os.format(e):"",ds="text-left text-m font-light text-secondary-text",ms=`${ds} pl-5xl`,hs={USD:"DollarIcon",EUR:"EuroIcon"},us=x((({className:e,exchangeCurrencyItems:t})=>p("table",{className:`h-fit w-fit ${e}`,children:[u("thead",{children:p("tr",{children:[u("th",{className:ds,children:u(me,{size:"text-m",children:"Валюта"})}),u("th",{className:ms,children:u(me,{size:"text-m",children:"Купить"})}),u("th",{className:ms,children:u(me,{size:"text-m",children:"Продать"})})]})}),u("tbody",{children:t.map(ps)})]}))),ps=e=>{const t=e?.currency?.currency;return p("tr",{className:"pb-2xs text-h6",children:[u("td",{className:"pt-m",children:p("div",{className:"flex items-center gap-xs",children:[t?u($t,{image:{icon:hs[t]},width:"24",height:"24"}):null,u(me,{size:"text-h6",children:t})]})}),u("td",{className:"pt-m pl-5xl",children:u(me,{size:"text-h6",children:cs(e?.saleExchangeRate)})}),u("td",{className:"pt-m pl-5xl",children:u(me,{size:"text-h6",children:cs(e?.buyExchangeRate)})})]},t)},xs={icon:"GpsIcon"},gs=x((({className:e="",address:t})=>p("div",{className:`flex gap-s ${e}`,children:[u(nl,{...xs,iconBgVersion:"primary"}),p("div",{className:"space-y-2xs",children:[t?u("p",{className:"text-primary-main text-l",children:t}):null,u("p",{className:"text-secondary-text text-m",children:"Курс указан для заданного офиса"})]})]}))),fs=(e,t,l)=>{const n=Number(bs(e))*Math.pow(t,l?-1:1);return Number.isInteger(n)?n:((e,t=2)=>{const l=10**t;return Math.round(parseFloat(String(e))*l)/l})(n)},bs=e=>e.replace(/[^\d.,]/g,"").replace(",","."),ys=e=>{return(t=[[e=>e.value!==ss.RUB&&e.oppositeValue!==ss.RUB,()=>e.handleConvert(e.value,ss.RUB)],[e=>e.value===ss.RUB&&e.oppositeValue===ss.RUB,()=>e.handleConvert(e.value,ss.USD)],[()=>!0,()=>e.handleConvert(e.value)]],e=>{const[,l]=t.find((([t])=>t(e)))||[];return l})(e)?.();var t};function vs(e){const{placeholder:t,rates:l,selected:n,value:a,setValue:i,setSelected:r}=e,s=l.map((e=>({key:e?.currency?.currency??"",text:e?.currency?.currency??""}))),o={key:n,text:n};return p("div",{className:"relative flex",children:[u(pe,{className:"shrink-0 text-l w-full appearance-none -mr-24",placeholder:t,type:"text",value:a,onChange:i}),s.length?u(He,{isBorder:!1,onChange:e=>r(e.key),options:s,value:o}):null]})}const Ns=x((({className:e="",currencyRatesBuy:t,currencyRatesSell:l,button:a})=>{const[r,s]=n({inputSell:"",inputBuy:"",selectSell:t?.[0]?.currency?.currency||ss.RUB,selectBuy:l?.[0]?.currency?.currency||ss.USD}),o=i((e=>s((t=>({...t,...e})))),[]);return p("div",{className:`grid gap-m pt-2xl ${e}`,children:[vs({placeholder:"Хочу продать",rates:l,selected:r.selectSell,setSelected:ws(r,o,l),value:r.inputSell,setValue:e=>Cs(o,l)(e,r.selectSell,r.selectBuy)}),vs({placeholder:"Получу",rates:t,selected:r.selectBuy,setSelected:ks(r,o,t),value:r.inputBuy,setValue:e=>Ss(o,t)(e,r.selectBuy,r.selectSell)}),a?.text?u(se,{text:a.text,version:a?.version,...a}):null]})})),ws=(e,t,l)=>n=>{t({selectSell:n}),ys({value:n,oppositeValue:e.selectBuy,handleConvert:(n=e.selectSell,a=e.selectBuy)=>{Cs(t,l)(e.inputSell,n,a)}})},ks=(e,t,l)=>n=>{t({selectBuy:n}),ys({value:n,oppositeValue:e.selectSell,handleConvert:(n=e.selectBuy,a=e.selectSell)=>Ss(t,l)(e.inputBuy,n,a)})},Cs=(e,t)=>(l,n,a)=>{e({inputSell:bs(l),selectBuy:a});const i=t.find((e=>e.currency?.currency===a))?.buyExchangeRate||t.find((e=>e.currency?.currency===n))?.saleExchangeRate;i&&e({inputBuy:String(fs(l,i,n===ss.RUB)||"")})},Ss=(e,t)=>(l,n,a)=>{e({inputBuy:bs(l),selectSell:a});const i=t.find((e=>e.currency?.currency===a))?.saleExchangeRate||t.find((e=>e.currency?.currency===n))?.buyExchangeRate;i&&e({inputSell:String(fs(l,i,n===ss.RUB)||"")})};const Is=async e=>{const t=await Ts(),l=t?.code||"000";return{region:t,exchangeRates:await Bs(e,l)}},Ts=async()=>{try{return await j("/api/v1/region",{method:"GET"})}catch(e){return console.log(e),{}}},Bs=async(e,t)=>{try{return await j(e+`?regionCode=${t}`,{method:"GET"})}catch(e){return console.log(e),{}}},Ms=x((({className:e="",title:t="Курсы обмена валют",button:l,...n})=>{const{exchangeRates:a}=function(){const{data:e}=A("/api/v1/exchangerates",Is);return e||{}}(),i=Ps(a?.exchangeRate?.currencies),r=i.filter((e=>e.buyExchangeRate));r.unshift({currency:{currency:ss.RUB}});const s=i.filter((e=>e.saleExchangeRate));return s.push({currency:{currency:ss.RUB}}),u(C,{className:w("box-border min-h-80",e),...n,children:u(Da,{className:"h-full",title:u(I,{headingType:"h4",title:t,className:"whitespace-pre-wrap"}),children:p("div",{className:"flex gap-6xl flex-wrap",children:[p("div",{children:[i?u(us,{className:"mb-xl",exchangeCurrencyItems:i}):null,u(gs,{address:a?.address})]}),i.length&&r.length&&s.length?u(Ns,{className:"grow",currencyRatesBuy:r,currencyRatesSell:s,button:l}):null]})})})})),Ps=e=>e?.filter((e=>1===e?.currency?.id||2===e?.currency?.id))||[],Rs=e=>Vt(d.SITEMAP||"sitemap",{fallback:e}),Vs={width:"40",height:"45"},zs={"bg-white":"color",transparent:"white"},As={"bg-white":"text-primary-main",transparent:"text-white"},Ds=(e,t,l)=>u($t,t?.src?{image:t,className:As[e],width:l?.width,height:l?.height,pathPrefix:"/wcms-resources/"}:{image:{icon:t?.icon||"LogoIcon",iconVersion:zs[e]},className:As[e],width:l?.width,height:l?.height}),_s={"bg-white":"text-primary-text",transparent:"text-white"},js=x((({className:e,href:t="/",logo:l,children:n,targetBlank:a,bgColor:i="bg-white",showTitle:r=!0})=>p("a",{className:w("inline-flex items-center font-sans no-underline",e),href:t,target:a?"_blank":"_self","aria-label":l?.title||"Россельхозбанк",children:[Ds(i,l?.image,Vs),r?n??u("div",{className:"ml-s",children:u(me,{font:"font-medium",color:_s[i],size:"",children:l?.title||"Россельхозбанк"})}):null]}))),Ls=x((({className:e,onClose:t})=>u("button",{className:w("flex justify-center items-center w-12 h-12 p-2xs bg-transparent border-none",e),onClick:t,title:"Закрыть",children:u($t,{image:{icon:"CloseIcon"},width:"24",height:"24"})})));function $s(e,t,l=300){a((()=>{const t=globalThis.setTimeout(e,l);return()=>{globalThis.clearTimeout(t)}}),t)}const Os=e=>t=>{if(e===t)return 1;if(!e||!t)return 0;const{m:l,s1Matches:n,s2Matches:a}=function(e,t){const l=Math.max(0,Math.floor(Math.max(e.length,t.length)/2)-1),n=new Array(e.length),a=new Array(t.length);let i=0;for(let r=0;r<e.length;r++){const s=Math.max(0,r-l),o=Math.min(r+l,t.length-1);for(let l=s;l<=o;l++)n[r]||a[l]||e[r]!==t[l]||(i++,n[r]=!0,a[l]=!0)}return{m:i,s1Matches:n,s2Matches:a}}(e,t);if(0===l)return 0;const i=function(e,t,{s1Matches:l,s2Matches:n}){let a=0;for(let i=0,r=0;i<e.length;i++){if(!l[i])continue;let s=r;for(;s<t.length;s++)if(n[s]){r=s+1;break}e[i]!==t[s]&&a++}return a}(e,t,{s1Matches:n,s2Matches:a}),r=(l/e.length+l/t.length+(l-i/2)/l)/3,s=r>.7?.1*function(e,t){let l=0;for(;e[l]===t[l]&&l<4;)l++;return l}(e,t):0;return r+s*(1-r)};const Es=(e,t)=>(l,n)=>{for(const[a,i]of n)l.set(a,e(l.get(a)||t,i));return l},Fs=e=>e.toLowerCase().split(/[^0-9a-zа-я-]+/).filter((e=>e.length>=3&&!/[0-9a-z]/.test(e))),Us=e=>t=>e.map((([e,l])=>[Os(t)(e),l])).filter((([e])=>e>=.8)).map((([e,t])=>Ws(t,e))).reduce(Es(Math.max,0),new Map),Hs=e=>t=>{return Cr(t,t.map((({title:e})=>e)).map((e=>t=>{const l=Fs(t||"");return l.length?ci(e.map((e=>dn(l.map(Os(e)))))):0})(e))).sort((n=([,e])=>e,l=(e,t)=>n(e)-n(t),(e,t)=>-l(e,t))).map((([e])=>e));var l,n},Ws=(e,t)=>new Map(e.map((e=>[e,t]))),Xs=({basePathList:e,initialQuery:t=""})=>{const[l,i]=n(t||"");a((()=>{null!=t&&i(t)}),[t]);const{data:r}=A(e?.length?e:null,Ks),[s,o]=n(null);return $s((()=>{r&&o(r.map((e=>t=>{const{corpus:l,dictionary:n}=t||{};if(!(e&&l?.length&&n&&Object.keys(n).length))return[];const a=Fs(e);if(!a.length)return[];const i=Object.entries(n),r=[...a.map(Us(i)).reduce(Es(((e,t)=>e+t),0),new Map).entries()].filter((([,e])=>e>=.799*a.length)).map((([e])=>l[e]));return Hs(a)(r)})(l)))}),[r,l]),[s,{value:l,onChange:i}]},Ks=async(...e)=>(await Promise.allSettled(e.map((e=>_(H(e,"/","search.index.json")))))).map((e=>"fulfilled"===e.status?e.value:{})),Ys=x((({className:e,head:t,children:l,onClose:n})=>{const{close:a}=O(),r=i((()=>{a(),n&&n()}),[n]);return p("div",{className:w("relative min-h-full bg-white pt-0 p-5",e),children:[p("div",{className:"sticky py-xl top-0 bg-white z-10",children:[u(Ls,{className:"absolute top-0 right-0",onClose:r}),u("div",{className:"container",children:t})]}),u("div",{className:"container pb-6xl",children:l})]})})),Gs=x((({className:e,topItems:t})=>{const l=q({isRemote:!0});return u("div",{className:w("flex items-start justify-between",e),children:t?.map(l).map(Js)})})),qs=["all","footer"],Js=(e,t)=>{const{text:l,items:n=[],href:a,target:i,onClick:r}=e,s=n.filter((e=>!e.displayArea||qs.includes(e.displayArea.toLowerCase())));return p("div",{className:"flex flex-col gap-s w-1/4",children:[u("a",{className:"leading-5 text-l text-primary-text hover:text-primary-main no-underline",href:a,target:i||"_self",onClick:r,children:l||`Раздел ${t}`}),s.map(((e,t)=>u(Zs,{...e,basePath:o(a),index:t},String(t))))]},String(t))},Zs=x((({text:e,index:t,basePath:l,...n})=>{const a=q({isRemote:!(!d.BASE_PATH||!l)&&!d.BASE_PATH.startsWith(l),basePath:l}),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-l font-light text-secondary-text hover:text-primary-main no-underline","overflow-x-hidden overflow-ellipsis whitespace-nowrap"),href:i,target:r||"_self",onClick:s,children:e||`Раздел ${t}`})})),Qs=x((({initialQuery:e})=>{const{topItems:t}=Rs(),l=r((()=>t?.map((e=>e.href||"/"))),[t]),[n,i]=Xs({basePathList:l,initialQuery:e}),s=r((()=>eo(t)(n)),[t,n]);return a((()=>function(e){for(const t of e.filter((({items:e})=>e?.length)))console.group(t.text),console.table(t.items,["text","href"]),console.groupEnd()}(s)),[s]),u(Ys,{head:u(es,{autoFocus:!0,...i}),children:u(Gs,{topItems:s})})})),eo=e=>t=>e?.length&&t?.length?Cr(e,t).map((([e,t])=>({...e,items:t?.map((({title:e,uri:t})=>({text:e,href:H("/",t)})))}))):[];const to=()=>{const{open:e,close:t}=O();return{open:(t={},l={})=>e(u(Qs,{...t}),l),close:t}},lo=x((({className:e})=>{const[t,l]=n(""),a=i((()=>l("")),[]),{open:r}=to(),s=i((e=>{l(e),no(e)&&r({initialQuery:e},{onClose:a})}),[a]);return p("div",{className:w("relative",e),children:[u(es,{value:t,onChange:s}),u(Ls,{className:"absolute top-0 right-0 sm:hidden",onClose:a})]})})),no=e=>e&&e.length>=3,ao=()=>{const e=globalThis.document?.cookie.split(";")??[];for(const t of e){const[e]=t.split("=");globalThis.document.cookie=`${e}=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/`}},io=x((({className:e="",items:t})=>p("div",{className:e,children:[t?.length?t.map(ro):null,u(se,{version:"primary",className:"w-full",href:"https://old.rshb.ru/feedback/question/",target:"_blank",ariaLabel:"Обратная связь",text:"Обратная связь"})]}))),ro=(e,t)=>p("div",{className:"mb-m",children:[u("div",{className:"mb-m",children:u(me,{size:"text-l",font:"font-medium",children:e?.title})}),u("div",{children:e.items?.map(so)})]},String(t)),so=(e,t)=>p("div",{className:"mb-m",children:[u("div",{children:oo(e.type,e.text)}),u("div",{className:"mt-2xs text-s font-light text-secondary-text",children:e.description})]},String(t)),oo=(e,t="")=>{switch(e){case"tel":return u("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${co(t)}`,children:t});case"email":return u("a",{className:"text-xl font-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return u("span",{children:t})}},co=e=>e.replaceAll(/\D/g,""),mo=x((({className:e="",index:t,text:l,...n})=>{const a=q(),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-secondary-text",e),href:i,target:r,onClick:s,children:l||`Документ ${t}`})})),ho=x((({className:e="",links:t})=>u("div",{className:e,children:t?.length?u("div",{className:"flex justify-between items-center gap-lg py-lg border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>u(mo,{index:t,className:"text-l font-light max-w-[292px]",...e},String(t))))}):null}))),uo=x((({className:e="",index:t,...l})=>{const n=q({isRemote:!0}),{href:a,target:i,text:r,onClick:s}=n(l);return u("a",{className:`text-xs font-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:a,target:i,onClick:s,children:r||`Документ ${t}`})})),po=x((({className:e="",links:t})=>p("div",{className:w("@container",e),children:[u("div",{className:"pt-lg",children:u(me,{size:"text-xs",font:"font-light",color:"text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?u("div",{className:"flex flex-col @5xl:flex-row justify-start items-start gap-x-lg gap-y-xs pt-lg",children:t.map(((e,t)=>u(uo,{index:t,...e},String(t))))}):null]}))),xo="w-52",go=x((({className:e,...t})=>{const{topItems:l,logo:n}=Rs(t.options?.page?.fallback),{documents:a,relatedEnterprises:i,contacts:r,socialMedia:s,mobileApps:o}=Vt(d.FOOTER||"footer",{fallback:t.options?.page?.fallback});return p(C,{tag:"footer",className:e,...t,children:[p("div",{className:"flex items-stretch gap-3xl pb-3xl ",children:[u(js,{className:xo,logo:n}),u(lo,{className:"grow"})]}),p("div",{className:"flex items-stretch gap-6xl",children:[p("div",{className:w(xo,"flex flex-col shrink-0 overflow-hidden space-y-xl"),children:[u(io,{items:r}),u(Ri,{media:s,children:"Соцсети"}),u(Ri,{media:o,showButtonText:!1,children:"Мобильное приложение"}),u(se,{version:"link",href:"https://old.rshb.ru",className:"!text-left text-s font-light",onClick:ao,children:"Вернуться на прежнюю версию сайта"})]}),u(Gs,{className:"flex-grow",topItems:l})]}),u(ho,{className:"mt-xl",links:i}),u(po,{links:a})]})})),fo=x((({className:e="",title:t,description:l,calendar:n,...a})=>p(C,{className:w("space-y-m",e),defaultPadding:"p-6xl",...a,children:[u(gl,{title:t,description:l,headlineVersion:"M",isEmbedded:!0}),n?bo(n):null]}))),bo=e=>{const t=100/(e.reduce(((e,t)=>t?.month?.length?e+t.month.length:e),0)||1),l=e.filter((e=>e?.month?.length)).map((e=>({...e,flexBasis:`${e?.month?.length?e.month.length*t:""}%`})));return p("div",{className:"w-full flex flex-col justify-center gap-s",children:[u("div",{className:"flex w-full text-h6 text-center",children:l.map((e=>yo(e,t)))}),u("div",{className:"flex gap-s w-full",children:l.map(((e,t)=>p("div",{className:"border-r border-main-divider last:border-r-0 space-y-s",style:{flexBasis:e.flexBasis},children:[u("div",{className:"flex gap-s",children:vo(e)}),p("div",{className:"text-s font-light text-primary-text",children:[u("span",{children:e.text})," ",u("span",{className:"text-primary-main",children:e.greenText})]})]},`monthItem-${t}`)))})]})},yo=(e,t)=>e.month?.map(((e,l)=>u("div",{style:{flexBasis:`${t}%`},children:e.text},`monthName-${l}`))),vo=e=>e.month?.map((e=>e.image?.src?u("div",{className:"h-52 border-r pr-s border-main-divider last:border-r-0",children:u($t,{image:e.image,className:"flex"})},`monthImage-${e.image.src}`):null)),No=e=>({href:t})=>!!t&&U(E(t)?e.href:e.pathname).startsWith(U(t));function wo(e=[]){const t=G(),l=e.findIndex((e=>No(d.BASE_PATH?{pathname:d.BASE_PATH}:e))(t));return[l,e[l]]}const ko=x((({className:e="",active:t,flat:l,children:n,...a})=>{const i=q({isRemote:!0}),{href:r,target:s,text:o,onClick:c}=i(a);return u("a",{className:w(Co(t,l),e),href:r,target:s,onClick:c,rel:"noopener noreferrer","aria-label":o,children:u("span",{className:So(t,l),children:o||n})})})),Co=(e=!1,t=!1)=>w("inline-block border border-solid bg-transparent text-center no-underline",e?"rounded-md border-primary-main group-data-transparent:border-white":"border-transparent",t?"":"px-m py-xs"),So=(e=!1,t=!1)=>w("font-sans text-s font-light",e?"text-primary-main":w(t?"text-primary-text":"text-secondary-text","hover:text-primary-main"),"group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),Io="location";function To(e="Москва"){const[t,l]=((e,t,l)=>{const[r,s]=n(l||null);return a((()=>e.subscribe(t,(e=>s(e)))),[e,t]),[r,i((l=>e.fire(t,l)),[e,t])]})(b,"location",Mo()??{name:e}),r=i((e=>{Po(e),l(e)}),[]),{data:s}=A("/api/v1/region",j);return a((()=>{s&&!Bo()&&l(s)}),[s]),[t??{name:e},r]}const Bo=()=>Boolean(globalThis.localStorage?.getItem(Io)),Mo=()=>{try{const e=globalThis.localStorage?.getItem(Io);return e&&JSON.parse(e)}catch(e){return null}},Po=e=>{try{globalThis.localStorage?.setItem(Io,JSON.stringify(e))}catch(e){}};const Ro=e=>e?.length?p("div",{className:"sm:border-t sm:border-main-divider mt-2xs pt-2xs",children:[u("div",{className:"mb-m",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:"Представительства за рубежом:"})}),u("div",{className:"flex flex-col sm:flex-row gap-5xl",children:e.map(((e,t)=>u(Vo,{...e},String(t))))})]}):null,Vo=x((({icon:e,...t})=>{const l=q(),{text:n,target:a,href:i,onClick:r}=l(t);return p("div",{className:"flex gap-s items-center",children:[e?u($t,{pathPrefix:"/wcms-resources/",image:e}):null,n?u("a",{className:"hover:text-primary-hover",href:i,target:a,onClick:r,children:u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:n})}):null]})})),zo=e=>t=>u("div",{className:"mb-xs sm:mb-2xs",children:u("button",{className:"cursor-pointer hover:text-primary-hover",onClick:()=>{e&&e(t)},children:u(me,{size:"text-l",font:"font-light",children:t.name||""})})},t.id),Ao=x((({className:e,searchTerm:t,onSearch:l})=>p("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-m max-w-44 gap-s pointer-events-none",children:t?null:u("label",{htmlFor:"search-bar-input",className:"text-secondary-text ",children:"Поиск по филиалам"})}),u("input",{id:"search-bar-input",className:"h-12 pl-m w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text",value:t,onChange:e=>l(e.target.value.toLowerCase()),type:"text",name:"location-search-bar-input"})]}))),Do=x((()=>{const{defaultLocation:e,foreignOffices:t}=Rs(),[l,a]=To(e),[r,s]=n(""),o=jo(function(){const{data:e}=A("/api/v1/regions",j);return e||[]}()).sort(((e,t)=>e.name.localeCompare(t.name))),c=((e,t)=>{const l=new Map;for(const n of e){const e=t(n),a=l.get(e)||[];l.set(e,[...a,n])}return l})(o,_o),{close:d}=O(),m=i((e=>{a(e),d()}),[]);return p(Ys,{className:"pb-20",head:p("div",{children:[u(me,{size:"text-h4",color:"text-primary-text",children:"Выберите филиал"}),l?p("div",{className:"mb-s",children:[u(me,{size:"text-l",font:"font-light",children:"Сейчас выбран: "}),u("button",{onClick:()=>a(l),children:u(me,{color:"text-primary-main",children:l.name})})]}):null,u(Ao,{onSearch:s,searchTerm:r})]}),children:[r&&r.length>=3?u("div",{children:o.filter((({name:e})=>e&&Os(e.toLowerCase())(r.toLowerCase())>=.8)).map(zo(m))}):u("div",{className:"columns-1 sm:columns-5",children:Array.from(c.entries()).map((h=m,([e,t])=>p("div",{className:"break-inside-avoid mb-2xl w-56",children:[u("div",{className:"mb-s",children:u(me,{size:"text-h6",children:e})}),t.map(zo(h))]},e)))}),Ro(t)]});var h})),_o=e=>e.name?.charAt(0)||"",jo=e=>e.map((e=>({...e,name:e.name?.replace(/республика|область|край'/gi,"").trim()||""}))),Lo={default:"w-6 h-6",large:"w-12 h-12"},$o=x((({className:e,isRounded:t,buttonSize:l="default",isGrayBg:n=!1,disabled:a,ariaLabel:i,image:r,onClick:s})=>u("button",{className:w("group/btn border-0 flex shrink-0 items-center",n?"p-s rounded-full":"p-0 bg-inherit",n&&!t?"bg-main-divider":"",t?"w-8 h-8 text-secondary-light hover:text-secondary-hove":`${Lo[l]} text-primary-text hover:text-primary-main`,"group-data-transparent:text-white",e),type:"button",disabled:a,"aria-label":i,onClick:s,children:u($t,{image:r,className:w("h-full",t?"bg-main-divider/20 rounded-full":""),imageClassName:"group-hover/btn:text-primary-hover group-hover/btn:invert-0"})}))),Oo=x((({className:e,version:t,officesLink:l,defaultLocation:n})=>{const a="transparent"===t?"white":"black",[r]=To(n),s=to(),o=i((()=>s.open()),[]),c=(()=>{const{open:e,close:t}=O();return{open:(t={})=>e(u(Do,{}),t),close:t}})(),d=i((()=>c.open()),[]);return p("div",{className:w("flex items-center gap-lg",e),children:[u(ko,{flat:!0,href:"#",text:r?.name,onClick:d}),l?u(ko,{flat:!0,href:l,text:"Офисы и банкоматы"}):null,u($o,{image:{icon:"LoupeIcon",iconVersion:a},ariaLabel:"Поиск",onClick:o})]})})),Eo=x((({className:e="",items:t,activeItem:l})=>{const a=q(),[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),c=Oe(i((()=>s(!1)),[]));return p("div",{className:w(r?"bg-white rounded-md shadow-blue-gray":"",e),ref:c,children:[u("button",{className:"group/btn flex justify-between items-center h-6","aria-label":""+(r?"Скрыть другие разделы":"Показать другие разделы"),onClick:o,children:Array(3).fill(null).map(((e,t)=>u("div",{className:"w-[3px] h-[3px] rounded mr-2xs bg-primary-text group-hover/btn:bg-primary-hover group-data-transparent:bg-white"},String(t))))}),u("div",{className:w("absolute flex flex-col rounded-md bg-white p-xl pb-xs",r?"":"hidden"),"aria-hidden":!r,children:t?.map(((e,t)=>{const{text:n,...i}=e;return u("a",{className:w("text-l font-light pb-m hover:text-primary-main",e===l?"text-primary-main":""),...a(i),children:n},e.href||String(t))}))})]})})),Fo=e=>globalThis[e];function Uo(e,t){const[l,r]=n(),s=i((()=>r(Fo(e))),[e]);return a((()=>{const l=document.getElementById(t);if(!l){const e=document.createElement("script");return e.src=t,e.async=!0,e.id=t,e.addEventListener("load",s),document.head.appendChild(e),()=>{document.head.removeChild(e),r(void 0)}}if(!Fo(e))return l.addEventListener("load",s),()=>{l.removeEventListener("load",s)};s()}),[e,t]),l}const Ho={personal:"//chat.mes.rshb.ru/assets/js/webchat_rshb",business:""},Wo=x((e=>{const[t,{setTrue:l}]=Ve();return t?u(Xo,{...e}):Ko({...e,onClick:l})})),Xo=x((({chat:e="personal",...t})=>((e=>{a((()=>globalThis.localStorage?.setItem("webchat-keep-open",String(Date.now()))),[]),Uo("chatbot",Ho[e])})(e),Ko(t)))),Ko=({className:e,iconVersion:t,onClick:l})=>u($o,{className:w("text-page__btn-chat",e),image:{icon:"HeadphonesIcon",iconVersion:t},ariaLabel:"Чат",onClick:l,buttonSize:"large",isGrayBg:!0}),Yo=x((({className:e="",active:t,dataItemName:l,children:n,...a})=>{const i=q(),{href:r,target:s,text:o,onClick:c}=i(a);return p("a",{className:w("relative inline-block bg-transparent text-center no-underline",e),href:r,target:s,"data-item-name":l,onClick:c,children:[u("span",{className:Go(t),children:o||n}),t?u("div",{className:"absolute left-0 right-0 -bottom-3 h-0.5 bg-primary-main group-data-transparent:bg-transparent"}):null]})})),Go=(e=!1)=>w("font-sans text-l font-light",e?"text-primary-main":"text-primary-text hover:text-primary-main","group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),qo=x((({observerOptions:e,onVisibilityChange:t,children:l,className:n,...a})=>{const r=y(i((e=>{if(!e.length||!t)return;const l=e[e.length-1];t(l.isIntersecting)}),[t]),e);return u("span",{ref:r,className:n,children:u(Yo,{...a,children:l})})})),Jo={default:"px-lg bg-main-divider rounded hover:text-primary-main",transparent:"text-white hover:text-primary-hover"},Zo=x((({version:e,internetBankUrl:t})=>t?u(se,{href:t,ariaLabel:"Интернет-банк",target:"_blank",className:w("py-s ml-s text-l font-light whitespace-nowrap hover:text-primary-main",Jo["transparent"===e?"transparent":"default"]),children:"Интернет-банк"}):null)),Qo=["all","header"],ec=x((({subItems:e=[],version:t,internetBankUrl:l})=>{const a="transparent"===t?"white":"black",i=G(),o=r((()=>e.filter((e=>!e.displayArea||Qo.includes(e.displayArea.toLowerCase())))),[e]),c=(e=>(t=[])=>{const l=t?.filter(No(e));return l?.length?cn((e=>e.href?.length||0))(l):void 0})(i)(e),[m,h]=n(o.length),x=o.slice(m),g=s(null),f={rootRef:g},b=r((()=>o.map(((e,t)=>e=>{h(e?tc(t):lc(t))}))),[o]);return p("nav",{className:"relative mt-s flex items-center justify-between",children:[u("div",{ref:g,className:"overflow-hidden whitespace-nowrap pb-s mt-xs space-x-3xl",children:o.map(((e,t)=>u(qo,{className:m-1<t?"invisible":"",active:e===c,observerOptions:f,onVisibilityChange:b[t],...e},String(t))))}),x.length?u(Eo,{className:"relative w-auto z-40",items:x,activeItem:c}):null,p("div",{className:"flex",children:[d.CHAT_BOT?u(Wo,{className:"ml-4xl",iconVersion:a,chat:d.CHAT_BOT}):null,u(Zo,{version:t,internetBankUrl:l})]})]})})),tc=e=>t=>Math.max(t,e+1),lc=e=>t=>Math.min(t,e),nc={"bg-white":"primary",transparent:"transparent"},ac=x((({className:e,bgColor:t="bg-white",version:l=nc[t],...n})=>{const{topItems:a,logo:i,officesLink:r,defaultLocation:s}=Rs(n.options?.page?.fallback),[,o]=wo(a),{internetBankUrl:c}=Vt(d.PORTAL_DATA||"portal-data",{folderName:"portal-resources",setBasePath:!0});return u(C,{tag:"header",className:w("pt-3xl px-20",o?.items?.length?"pb-m":"pb-lg",e),defaultPadding:"",version:l,...n,children:p("div",{className:"container",children:[p("div",{className:"flex items-center",children:[u(js,{className:"mr-3xl",bgColor:t,logo:i}),a?.map(((e,t)=>u(ko,{active:e===o,...e},String(t)))),u(Oo,{version:l,className:"ml-auto",officesLink:r,defaultLocation:s})]}),u("div",{className:w("mt-xl h-px bg-main-divider","transparent"===l?"opacity-30":"")}),o?.items?.length?u(ec,{subItems:o.items,version:l,internetBankUrl:c}):null]})})})),ic={XXL:"gap-6xl",XL:"gap-5xl",L:"gap-3xl",M:"gap-m",S:"gap-xs",XS:"gap-2xs","":""},rc=x((({className:e="",gap:t="XS",isPadding:l=!1,version:n="transparent",isTheme:a=!1,isCardBorder:i,...r})=>u(C,{className:w("relative","grid grid-cols-12",ic[t],e),defaultPadding:l?"p-6xl":"",version:n,isTheme:a,...r,children:ya({...r,extraProps:{className:i?"border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider":""}})})));rc.childrenTypes={exclude:["HorizontalLayout"]};const sc=x((e=>{const{className:t,image:l,...n}=e;return u(C,{className:t,defaultPadding:"p-0",...n,children:u($t,{image:l})})})),oc=x((({className:e="",cards:t=[],button:l})=>{const[a,r]=n(0),s=i((e=>r(e)),[]),o=t.length,[c,d]=Pl({itemCount:o,visibleItemCount:2}),{canDec:m,canInc:h}=d,x=t[c]?.href;return p("section",{role:"listitem",className:`min-w-full text-center ${e}`,children:[p("div",{className:"relative overflow-hidden",children:[o?cc({activeIndex:c,cards:t,selectedCardIndex:a,onClick:s}):null,Al({...d,btnClass:["left-12","right-12"],className:"top-16"}),m?u("div",{className:"absolute top-0 left-0 h-full w-32 bg-opacity-from-white"}):null,h?u("div",{className:"absolute top-0 right-0 h-full w-32 bg-opacity-to-white"}):null]}),u(se,{className:"w-60 text-center",version:"primary",...l,href:x})]})}));function cc({activeIndex:e,cards:t,selectedCardIndex:l,onClick:n}){const a=460*e,i=t.length>2?"justify-start":"justify-center";return u("div",{style:{transform:`translateX(-${a}px)`},className:"duration-1000 px-6xl",children:u("div",{className:`w-full flex flex-nowrap gap-s pb-6xl ${i}`,children:t.map(((e,t)=>function({slide:e,i:t,isActive:l,onClick:n}){return p("button",{type:"button",onClick:n,className:"p-3xl min-w-fit flex items-center gap-2xl bg-white border-solid border relative "+(l?"shadow-dark-blue border-primary-main":"ease-in duration-300 border-gray"),children:[e?.icon?u($t,{className:"p-lg rounded-full bg-secondary-light",image:e.icon,width:"108",height:"108"}):null,p("div",{className:"flex gap-s",children:[e?.sum?dc("страховая сумма",e.sum):null,e?.fee?dc("страховой взнос",e.fee):null]}),mc(l)]},String(t))}({slide:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})})}function dc(e,t){return p("div",{className:"flex flex-col text-left whitespace-pre",children:[p("span",{className:"text-h6",children:[pt(2)(t)," ₽"]}),u("span",{className:"text-secondary-text text-l mt-2xs",children:e})]})}function mc(e){return e?u($t,{className:"h-6 w-6 min-w-6 min-h-6 absolute right-4 top-4",image:{icon:"DoneIcon"},width:"24",height:"24"}):null}const hc=x((({className:e="",title:t,insuranceTabs:l=[],button:a,...r})=>{const[s,o]=n(0),c=i((e=>o(e)),[]);return p(C,{className:w("box-border overflow-hidden relative px-0 space-y-2xl",e),defaultPadding:"p-6xl",...r,children:[t?u(I,{className:"text-center",title:t,headingType:"h3"}):null,l?.length>1?u("div",{className:"p-xs bg-secondary-light w-fit mx-auto rounded-md",children:l.map(((e,t)=>function({title:e,i:t,isActive:l,onClick:n}){return u("button",{type:"button",onClick:n,"aria-label":e,className:"box-border px-m py-s text-m font-light "+(l?"bg-primary-main text-white rounded-md":"text-secondary-text"),children:e},String(t))}({title:e?.title,i:t,isActive:Boolean(t===s),onClick:()=>c(t)})))}):null,u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:uc({insuranceTabs:l,button:a})})]})})),uc=({insuranceTabs:e,button:t})=>{const l=e?.map((e=>e.cards));return l?.length?l.map(((e,l)=>u(oc,{button:t,cards:e},String(l)))):null};const pc=e=>t=>t.reduce(((t,l,n)=>t.length?t.concat({...e,key:`sep-${n}`},l):[l]),[]),xc={yellow:"bg-yellow",green:"bg-green","green-light":"bg-green-light","green-dark":"bg-green-dark"},gc={XS:"h-10",S:"h-16",M:"h-24",L:"h-32",XL:"h-52"},fc=x((e=>{const{className:t="",items:l,isDotted:n,investmentZeroColumn:a,investmentColumns:i,...r}=e,s=i?[...i]:[];return a&&s.unshift(a),u(C,{className:t,defaultPadding:"p-4xl",...r,children:p("div",{className:"container text-m font-light space-y-4xl",children:[s?.length?p("div",{children:[p("div",{className:"flex items-end relative pl-3xl pr-lg text-white",children:[pc(u("div",{className:"w-px h-4 bg-gray"}))(s.map(bc)),u("div",{className:"absolute right-3xl w-px h-4 bg-gray"})]}),u("div",{className:"border-t border-gray -mt-xs mx-3xl"}),u("div",{className:"flex justify-between text-primary-text mt-s -mx-5xl",children:s.map(Nc)})]}):null,l?.length?u(li,{className:"max-w-[657px]",items:l,isDotted:n,listItemSize:"M"}):null]})})})),bc=(e,t,l)=>{const n=1===t,a=t===l.length-1;return u("div",{className:`${yc(n,a,e.cells)}`,children:e.cells?.length?u("div",{className:"w-full "+(a?"border-4 border-green-more-dark p-2xs min-w-72":""),children:e.cells.reverse().map(vc)}):null},`column_${t}`)},yc=(e,t,l=[])=>[l.length?"flex-1":"flex-0",!l.length||e||t?"":"pl-s",l.length&&!t?"pr-s pb-3xl":"pb-xl"].join(" "),vc=(e,t)=>{const l=e.cellSize||"XS",n=e.cellColor||"green";return e.text?u("div",{className:`flex-1 flex items-center justify-center relative py-xs ${gc[l]} ${xc[n]} ${"XS"===l?"px-s":"px-5xl"}`,children:u("div",{className:"text-center",children:e.text})},`cell_${t}`):null},Nc=(e,t)=>u("div",{className:"flex-1 max-w-[180px] text-center px-xs last:pr-3xl",children:e.title},`title_${t}`),wc=["байт","Кб","Мб","Гб","Тб","Пб"],kc=x((({icon:e,text:t,fileSize:l,...n})=>p("a",{className:"flex box-border gap-s group/item h-fit w-fit text-primary-text no-underline hover:text-primary-main",role:"link",...n,children:[e,t?p(me,{size:"text-l",font:"font-light",children:[t,u(me,{color:"text-secondary-text",children:n?.href&&Cc(Sc(n.href),l)})]}):null]}))),Cc=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),Sc=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},Ic={double:"sm:flex-wrap sm:flex-row",single:"sm:flex-col"},Tc=x((({className:e="",title:t,description:l,align:n="text-center",documents:a,icon:i={icon:"DocIcon"},columnsMode:r="double",...s})=>{const o=G();return p(C,{className:w("space-y-lg",e),defaultPadding:"p-6xl",...s,children:[u(gl,{title:t,description:l,align:n,headlineVersion:"M",as:"h2",isEmbedded:!0}),a?.length?u("div",{className:w("grid gap-xl","double"===r?"@md:grid-cols-2":"grid-cols-1",Ic[r]),role:"list",children:a.map(Bc(o,r,i))}):null]})})),Bc=(e,t,l)=>(t,n)=>{const a="Attachment"===t?.docType?X(e)(t?.attachment?.src):t?.href,i="Attachment"===t?.docType?((e,t=2)=>{if(0===e)return"";const l=Math.floor(Math.log(e)/Math.log(1024));return`${parseFloat((e/Math.pow(1024,l)).toFixed(t))} ${wc[l]}`})(t?.attachment?.fileSize||0):t?.fileSize;return u("div",{role:"listitem",children:u(kc,{text:t?.text,target:t?.target,href:a,fileSize:i,icon:l?u($t,{className:"min-w-6 min-h-6",image:l,width:"24",height:"24"}):null})},String(n))},Mc=(e,t)=>e?.length?u(li,{items:e,listItemSize:t,className:"text-l font-light"}):u("span",{className:"text-m font-light text-secondary-text",children:"Наведите камеру телефона на QR-код и скачайте приложение"}),Pc=x((({className:e,padding:t,align:l="text-left",buttons:n=[],description:a,headingType:i="h4",image:r,items:s,listItemSize:o,qr:c,title:d="Мобильное приложение",version:m="primary",...h})=>{const x="secondary"===m?"p-m min-w-32":"min-w-24",g=r?.src?u($t,{className:"hidden lg:block",image:r}):null;return u(C,{className:w("min-h-80",e),padding:"p-0",version:m,...h,children:p(Da,{className:"h-full",padding:t,defaultPadding:"p-6xl",title:d?u(I,{headingType:i,title:d,className:w("whitespace-pre-wrap",l)}):null,rightImage:g,buttons:dl(n,{className:"flex-wrap"}),children:[a?u(me,{size:"text-xl","font-weight":"font-light",children:a}):null,p("div",{className:w("gap-m","flex flex-1 flex-col","flex-col items-start @xl:flex-row @xl:items-center"),children:[Mc(s,o),c?.src?u("div",{className:w("flex justify-center bg-white rounded-md @xl:-order-1",x),children:u($t,{className:"w-fit",image:c})}):null,r?.src?u($t,{className:"lg:hidden",image:r}):null]})]})})})),Rc={primary:"bg-white/30",secondary:"bg-main-divider"},Vc={primary:"text-white",secondary:"text-secondary-text"},zc=x((({count:e,version:t="secondary"})=>u("div",{className:w("w-6 h-6 rounded-full flex items-center justify-center",Rc[t]),children:u(me,{size:"text-xs",color:Vc[t],children:e})}))),Ac=(e=[],t={})=>e.filter((({content:e={}})=>xr(t,e))).length,Dc=(e,t)=>e===t;const _c=(jc=function(...e){return(t,l)=>e.some((e=>e(t,l)))}(Dc,((e=Dc)=>(t,l)=>t===l||Boolean(t&&l&&t.length===l.length&&t.every(((t,n)=>e(t,l[n])))))()),(e,t)=>e===t||Boolean(e&&t&&Object.keys(e).length===Object.keys(t).length&&Object.entries(e).every((([e,l])=>jc(l,t[e])))));var jc;const Lc=[],$c={},Oc={default:"px-xs",underlined:"px-m",rounded:"px-lg rounded-md"},Ec={default:"text-black sm:text-white",underlined:"text-primary-main border-b-2",rounded:"text-white"},Fc={default:"bg-white",underlined:"bg-white",rounded:"bg-transparent"},Uc={default:"sm:bg-primary-main",underlined:"bg-white",rounded:"bg-primary-main"},Hc=x((({tag:e="div",item:t={},isActive:l,type:n="default",onClick:a})=>{const i=e,{text:r,appendRight:s,...o}=t;return u(i,{className:w("h-12","block flex-1","cursor-pointer",Oc[n],l?Uc[n]:Fc[n]),role:"tab","aria-selected":l,onClick:a,...o,children:p("div",{className:w("h-full","flex justify-center items-center","text-center whitespace-nowrap",l?Ec[n]:"text-secondary-text hover:text-primary-main"),children:[u(me,{size:"text-m",children:r}),s?u("div",{className:"ml-xs",children:s}):null]})})})),Wc=x((e=>u(e?.item?.href?Xc:Kc,{...e}))),Xc=x((e=>{const t=q(),l=i((()=>{e.onClick&&e.onClick(e.item||{})}),[e.onClick,e.item]),{onClick:n,...a}=t({...e.item,onClick:l});return u(Hc,{...e,tag:"a",item:a,onClick:n})})),Kc=x((({item:e={},onClick:t,...l})=>{const n=i((()=>{t&&t(e)}),[t,e]);return u(Hc,{item:e,onClick:n,...l})})),Yc=(e,t,l)=>(n,a)=>u(Wc,{isActive:n===e,onClick:t,type:l,item:n},String(a)),Gc=x((({className:e,tabsType:t="default",items:l=[],value:n,onChange:a})=>u("div",{className:w("flex gap-x-2xs overflow-x-auto no-scrollbar",e),role:"tablist",children:l.map(Yc(n,a,t))}))),qc={categories:[],extraOptions:[],propertyType:[],stage:[]},Jc=x((({className:e,hotFilters:t,filtrationSchema:l={},resetButton:n,...a})=>{const[s,{field:o,reset:c,update:d}]=B(qc),m=fr(a.block?.blocks,s)(),h=i(((e=qc)=>d(e)),[]),x=(({hotFilters:e=Lc,filtrationState:t=$c,blocks:l=Lc,onFiltrationStateChange:n})=>{const a=r((()=>Math.max(0,e.findIndex((e=>_c(e.filter,t))))),[e,t]),s=r((()=>e.map((t=>({text:t.text,appendRight:u(zc,{version:t===e[a]?"primary":"secondary",count:Ac(l,t.filter)})})))),[e,l,a]),o=i((t=>{n(e[s.indexOf(t)].filter)}),[e,s]);return{value:s[a],items:s,onChange:o}})({hotFilters:t,filtrationState:s,blocks:a.block?.blocks,onFiltrationStateChange:h});return p(C,{className:w("space-y-2xs",e),defaultPadding:"p-0",version:"transparent",...a,children:[u(Gc,{...x}),yr({field:o,reset:c,filtrationSchema:l,resetButton:n}),u(ur,{blocksToRender:m,...a})]})}));Jc.childrenTypes=["ProductTile"],Jc.childSchema=e=>e?.filtrationSchema||{};const Zc=!Boolean("object"==typeof globalThis.process&&globalThis.process&&globalThis.process.version),Qc=x((({children:e})=>Zc?e:null));function ed(e,t,l){t.geoObjects.removeAll();const n=e.templateLayoutFactory.createClass('<div style="margin-top: -3px;">{{properties.geoObjects.length}}</div>'),a=new e.Clusterer({clusterIcons:[{href:"/icons/MapMarkerClusterIcon.svg",size:[78,84],offset:[-35,-50]}],clusterIconContentLayout:n,clusterHideIconOnBalloonOpen:!1,geoObjectHideIconOnBalloonOpen:!1}),i=l.map((t=>new e.Placemark(t,{},{iconLayout:"default#image",iconImageHref:"/icons/MapMarkerSingleIcon.svg",iconImageSize:[78,84],iconImageOffset:[-35,-50]})));a.add(i),t.geoObjects.add(a),t.setBounds(e.util.bounds.fromPoints(l)).then((()=>{t.getZoom()>10&&t.setZoom(10)}))}const td={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"flex items-center justify-center",font:"text-center font-sans"},ld=e=>u("a",{className:`select-none cursor-pointer px-4xl h-12 bg-primary-main text-white ${Object.values(td).join(" ")}`,href:`https://yandex.ru/maps/?ll=${[e[1],e[0]]}&z=10&l=map`,target:"_blank",children:"Открыть на карте"}),nd={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"absolute flex items-center justify-center",font:"text-center font-sans"},ad=(e,t,l)=>u("div",{className:`select-none cursor-pointer py-m w-12 bg-white ${Object.values(nd).join(" ")} ${l}`,onClick:()=>{t.geolocation.get({provider:"yandex",autoReverseGeocode:!0,mapStateAutoApply:!0}).then((function(t){e.geoObjects.add(t.geoObjects)}))},children:u(Ae,{name:"UserGeoLocationIcon",width:"20",height:"16"})}),id={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border-b border-b-2 border-gray last:border-0",position:"relative flex items-center justify-center",font:"text-center font-sans text-l"},rd=x((({yandexMaps:e,direction:t="in"})=>{const l="in"===t?"PlusIcon":"MinusIcon";return u("div",{onClick:()=>{const l=e.current.getZoom(),n="in"===t?l+1:l-1;e.current.setZoom(n,{checkZoomRange:!0})},className:`${Object.values(id).join(" ")} bg-white select-none cursor-pointer w-12 h-12`,children:u(Ae,{name:l,width:"20",height:"16"})})})),sd={border:"border border-transparent rounded-md ",position:"absolute flex items-center justify-center",size:"w-12 h-12",focus:"focus:border-primary-text focus:border",font:"text-center font-sans",active:"active:bg-primary-active",hover:"hover:bg-primary-hover",other:"select-none cursor-pointer"},od=[55.753995,37.614069],cd=x((({points:e,className:t="",zoom:l=5})=>{const i=s(null),r=Uo("ymaps",`https://api-maps.yandex.ru/2.1/?apikey=${d.YANDEX_MAP_API_KEY||""}&lang=ru_RU`),[o,c]=n(),m=e?dd(e):od;if(a((()=>{i?.current||r?.ready((()=>{i.current||(i.current=new r.Map("map",{center:m,zoom:l,controls:[],suppressMapOpenBlock:!0}),ed(r,i.current,e))})),i.current&&r&&(ed(r,i.current,e),e?.length||i.current.setCenter(od))}),[r,i,e,m,l]),!r)return null;const h=o?"z-[100000]":"z-10";return p("div",{id:"map",className:w(!o&&"relative","w-full",t),children:[u("div",{className:w("absolute flex left-2 top-4 w-1/2",h),children:ld(m)}),u("div",{className:w(Object.values(sd),h,"right-2 top-4 bg-white"),onClick:()=>{const e=i.current.container;o?e.exitFullscreen():e.enterFullscreen(),c(e.isFullscreen())},children:u(Ae,{name:"FullScreenIcon",width:"16",height:"16"})}),p("div",{className:w("absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md",h),children:[u(rd,{yandexMaps:i}),u(rd,{yandexMaps:i,direction:"out"})]}),ad(i.current,r,w("right-2 top-80",h))]})})),dd=e=>[hd(md(e,0)),hd(md(e,1))],md=(e,t)=>e.map((e=>e[t])),hd=e=>e.length&&e.reduce(((e,t)=>e+t))/e.length,ud={safeBoxCaseVolumes:"Аренда индивидуальных сейфовых ячеек",workingSaturday:"Открыты по субботам",terminalTypeAtms:"Банкоматы",terminalTypeTerm:"Терминалы",workAllTime:"Круглосуточно",billAcceptorEnable:"Прием наличных"},pd=(e,{field:t,reset:l})=>p("div",{className:"pb-2xl",children:[e?.length?u("div",{className:"flex flex-wrap gap-3xl pb-2xl",children:e.map((e=>u(en,{text:ud[e],...t(e)},e)))}):null,u(se,{version:"transparent",className:"text-secondary-text [&>*]:p-0",onClick:l,text:"Очистить фильтр",appendRight:u(Ae,{name:"CloseIcon",width:"16",height:"16"})})]}),xd=()=>null,gd=()=>[],fd=x((({className:e,data:t=[],renderCard:l=xd,filterItems:n=gd,initFilterState:a={},descriptionData:i,title:r})=>{const[s,{field:o,reset:c}]=B(a),d=n(t,s),m=d.map((e=>[e.gpsLatitude,e.gpsLongitude].filter(Boolean))).filter((e=>e&&2===e.length)),h=d.length;return p("div",{className:w("space-y-1",e),children:[p("div",{className:"bg-white",children:[p("div",{className:"pt-6xl px-6xl",children:[p("div",{className:"flex gap-xs pb-2xl",children:[u(I,{headingType:"h2",children:r}),h?u(me,{size:"text-h2",color:"text-secondary-text",children:`(${h})`}):null]}),i?bd(i):null,pd(Object.keys(a),{field:o,reset:c})]}),u("div",{className:"h-[600px]",children:u(Qc,{children:u(cd,{points:m,className:"h-full"})})})]}),d.map(l)]})})),bd=({description:e,list:t})=>e||t?.length?p("div",{className:"p-xl mb-2xl border border-gray rounded-md",children:[e?u(de,{size:"text-l",font:"font-light",children:e}):null,t?.length?u("div",{className:"flex gap-2xl flex-wrap pt-xs",children:t.map(((e,t)=>p("div",{className:"flex gap-xs items-center",children:[e?.image?u($t,{image:e.image}):null,e?.text?u(me,{size:"text-m",font:"font-light",children:e.text}):null]},String(t))))}):null]}):null,yd={yellow:{border:"border-yellow-light",text:"text-yellow"},green:{border:"border-green-light",text:"text-green-dark"},gray:{border:"border-gray",text:"text-secondary-text"},red:{border:"border-error",text:"text-error"}},vd=x((({className:e,children:t,color:l="gray"})=>u("div",{className:w("p-s border border-gray rounded-md flex items-center",yd[l].border,e),children:u(me,{size:"text-m",color:yd[l].text,children:t})}))),Nd=x((({className:e,label:t,value:l,subText:n,subColor:a})=>{const i=l?.split(",")??[];return i.length||n?p("div",{className:w("flex gap-2xs flex-col h-full max-w-[300px]",e),children:[t?u(me,{color:"text-secondary-text",font:"font-light",size:"text-m",children:t}):null,i.filter(Boolean).map(((e,t)=>u(me,{size:"text-l",children:e.trim()},String(t)))),n?u(me,{color:a,size:"text-m",children:n}):null]}):null})),wd=x((({className:e,children:t})=>u("div",{className:w("flex border-t border-solid border-main-divider py-xl gap-x-6xl gap-y-xl",e),children:t}))),kd=({location:e,address:t,billAcceptorType:l,terminalType:n,billAcceptorEnable:a,atmCode:i="",atmAccess:r="",workTime:s},o)=>{const c=[{label:"Устройство",value:Sd(n)},{label:"Модуль приема наличных",value:a?"Да":"Нет"},{label:"Прием наличных пачкой",value:"банкомат принимает пачками"===l?"Да":"Нет"},{label:"Доступность",value:["внешняя установка","территория банка"].includes(r)?"Общедоступный":""},{label:"Регистрационный номер",value:i}];return p("div",{className:"bg-white col-span-12 p-3xl border-green border",children:[p("div",{className:"flex justify-between",children:[u(me,{size:"text-h4",children:Sd(e)}),u(vd,{color:"green",children:Sd(s)})]}),t?p("div",{className:"flex pb-xl pt-xs gap-2xs",children:[u(Ae,{name:"GeolocationIcon",width:"24",height:"24"}),u(me,{size:"text-l",children:t})]}):null,u(wd,{className:"flex-wrap",children:c?.map(Cd)})]},String(o))},Cd=(e,t)=>u(Nd,{...e},String(t)),Sd=e=>e?`${e?.charAt(0)?.toUpperCase()}${e?.slice(1)}`:"",Id=[];const Td=async e=>await _(e,{method:"GET"})||Id,Bd={terminalTypeAtms:!0,terminalTypeTerm:!1,workAllTime:!1,billAcceptorEnable:!1},Md={terminalTypeAtms:e=>"банкомат"===e.terminalType?.toLowerCase(),terminalTypeTerm:e=>"терминал"===e.terminalType?.toLowerCase(),workAllTime:e=>"круглосуточно"===e.workTime?.toLowerCase(),billAcceptorEnable:e=>Boolean(e.billAcceptorEnable)},Pd=x((({data:e,className:t})=>{const[l]=To(),n=function(e){const{data:t=Id}=A(`/api/v1/atms?regionCode=${e}`,Td);return t}(l?.code??"000");return u(fd,{className:t,filterItems:Rd,data:n,initFilterState:Bd,renderCard:kd,title:`Банкоматы филиала ${l?.name}`,descriptionData:e})})),Rd=(e,t)=>{const l=Object.keys(t).filter((e=>t[e])),n=l.filter((e=>e.startsWith("terminalType"))),a=l.filter((e=>!n.includes(e)));return e.filter((e=>{const t=a.every((t=>Md[t](e))),l=!n.length||n.some((t=>Md[t](e)));return t&&l}))},Vd=[["Понедельник","workingMonday"],["Вторник","workingTuesday"],["Среда","workingWednesday"],["Четверг","workingThursday"],["Пятница","workingFriday"],["Суббота","workingSaturday"],["Воскресенье","workingSunday"]],zd=(new Date).getDay(),Ad=({name:e,address:t,phone:l,fax:n,phoneBusiness:a,phoneNatural:i,phoneCallCentre:r,phoneCurrencyControl:s,workSchedule:o,exchangeRate:c},d)=>{const m=o?Dd(o):null,[h]=m?.slice(zd-1)??[];return p("div",{className:"bg-white col-span-12 p-3xl border-green border",children:[p("div",{className:"flex justify-between",children:[u(me,{size:"text-h4",children:e}),jd(h)]}),t?p("div",{className:"flex pb-xl pt-xs gap-2xs",children:[u(Ae,{name:"GeolocationIcon",width:"24",height:"24"}),u(me,{size:"text-l",children:t})]}):null,p(wd,{className:"flex-wrap",children:[u(Nd,{label:"Факс",value:n}),u(Nd,{label:"Телефон филиала",value:l}),u(Nd,{label:"Для обращений юридических лиц",value:a}),u(Nd,{label:"Обслуживание физических лиц",value:i}),u(Nd,{label:"Для консультаций по валютному контролю",value:s}),u(Nd,{label:"Контакт-центр",value:r})]}),m?.length?u(wd,{children:m?.map(Ld)}):null,c?.currencies?.length?u(wd,{className:"flex-wrap",children:c?.currencies?.map(_d)}):null]},String(d))},Dd=e=>Vd.map((([t,l])=>{const n=["workingSaturday","workingSunday"].includes(l);return{title:t,status:Boolean(e?.[l]),workTime:n?e?.workTimeSaturday:e?.workTime,lunchHour:n?e?.lunchHourSaturday:e?.lunchHour,get hasLunch(){return/\d+/.test(this.lunchHour??"")}}})),_d=({currency:e,buyExchangeRate:t,saleExchangeRate:l},n)=>p("div",{className:"flex gap-lg h-full",children:[e?.currency?u(Nd,{label:"Валюта",value:e.currency}):null,t?u(Nd,{label:"Купить",value:String(t)}):null,l?u(Nd,{label:"Продать",value:String(l)}):null]},String(n)),jd=e=>{if(!e)return null;const{lunchHour:t,status:l,workTime:n,hasLunch:a}=e;return l?p("div",{className:"flex gap-s",children:[n?u(vd,{color:"green",children:n}):null,t&&a?u(vd,{color:"yellow",children:t}):null]}):u(vd,{color:"red",children:"Выходной"})},Ld=({title:e,status:t,workTime:l,lunchHour:n,hasLunch:a},i)=>u(Nd,{label:e,value:t&&l?l:"",subText:t?n:"Выходной",subColor:!t||a?"text-error":"text-green-dark"},String(i)),$d=[];const Od=async e=>await _(e,{method:"GET"})||$d,Ed={workingSaturday:!1},Fd={workingSaturday:e=>Boolean(e.workSchedule?.workingSaturday)},Ud=x((({className:e})=>{const[t]=To(),l=function(e){const{data:t=$d}=A(`/api/v1/branches?regionCode=${e}`,Od);return t}(t?.code??"000");return u(fd,{className:e,filterItems:Hd,data:l,initFilterState:Ed,renderCard:Ad,title:`Офисы филиала ${t?.name}`})})),Hd=(e,t)=>{const l=Object.keys(t).filter((e=>t[e]));return e.filter((e=>l.every((t=>Fd[t](e)))))},Wd=x((({data:e,className:t,...l})=>{const n=e?.dataType??"offices";return u(C,{version:"transparent",className:w(t),defaultPadding:"p-0",...l,children:"offices"===n?u(Ud,{}):u(Pd,{data:e})})})),Xd=x((({text:e,size:t,align:l,font:n,children:a,...i})=>u(C,{defaultPadding:"p-0",...i,children:u(de,{size:t,align:l,font:n,children:e||a})}))),Kd=(e,t)=>e||t?p("div",{className:"flex flex-wrap xl:flex-nowrap xl:bg-main-divider xl:rounded-md p-xs gap-xl",children:[Number(e)>0?Yd("Страховая сумма",e):null,Number(t)>0?Yd("Ежемесячный лимит",t):null]}):null,Yd=(e,t=0)=>p("div",{className:"basis-full flex flex-col-reverse sm:flex-row sm:justify-between sm:bg-main-divider sm:py-m sm:px-lg sm:rounded-md items-baseline whitespace-pre",children:[u(me,{font:"font-light",size:"text-l",color:"text-secondary-text",children:e}),p("span",{className:"font-sans text-h6 sm:text-primary-main text-primary-text",children:[pt(2)(t)," ₽"]})]}),Gd=x((({className:e,padding:t,headlineVersion:l="M",align:n="text-center",sum:a,monthLimit:i,imageOptions:r,...s})=>u(C,{className:e,padding:"p-0",...s,children:u(Ii,{className:"h-full",defaultPadding:"p-6xl",padding:t,headlineVersion:l,align:n,isFullWidthTitle:!0,imageOptions:{directionRight:!1,imageAlign:"center",...r},...s,children:Kd(Number(a),Number(i))})}))),qd=x((({className:e,title:t,description:l="Блок в разработке...",...n})=>p(C,{className:w("box-border",e),...n,children:[u(gl,{className:"max-w-[600px]",title:t,description:l,headlineVersion:"L",align:"text-left",isEmbedded:!0}),u("figure",{className:"m-0 mt-xl min-w-[80%]",children:Jd()})]}))),Jd=(e=3)=>Qd(100,e).map((e=>Math.floor(e))).map(Zd),Zd=(e,t)=>u("div",{style:{width:`${e||100}%`},className:"h-4 mt-xs bg-secondary-light"},String(t)),Qd=(e,t)=>[e].concat(t>0?Qd(e/1.618,t-1):[]);function em(e,t){const l="primary"===e?"white":"black",n="Вернуться назад";return p("div",{className:"hidden sm:flex items-center gap-s",children:[u("div",{className:re({className:"w-12 h-12 min-h-12 min-w-12 flex items-center justify-center",version:e,rounded:!0}),onClick:t,children:u($t,{className:"w-4 h-4",image:{icon:"ArrowLeftIcon",iconVersion:l}})}),u(se,{version:"link",className:"group-data-secondary:text-white/80",text:n,ariaLabel:n,onClick:t})]})}const tm=x((({className:e,padding:t,backwardButton:l,showBorder:n,...a})=>{const r=G(),s=i((e=>{e?.preventDefault(),r.back()}),[]);return p(C,{className:w("overflow-hidden flex flex-col gap-3xl box-border",n?"border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider":"",e),defaultPadding:"p-6xl",padding:t,...a,children:[l?em(a.version&&"primary"!==a.version?"white":"primary",s):null,u(Ii,{className:"grow h-full",...a})]})})),lm=x((({className:e="",padding:t,slides:l=[],...a})=>{const[i,r]=n(0);return p(C,{className:w("box-border overflow-hidden",e),defaultPadding:"py-6xl",padding:t,...a,children:[u("div",{className:"flex duration-1000",style:{transform:`translateX(-${100*i}%)`},role:"list",children:l.map((({productBlock:e},t)=>u("div",{className:"box-border grow-0 shrink-0 basis-full",role:"listitem",children:u(Ii,{className:"pl-6xl h-full",headlineVersion:"XXL",isFullWidthTitle:!1,...e,...a})},String(t))))}),u("div",{className:"h-28 px-xs mt-m -mb-m flex gap-xs box-border",children:l.map(nm({activeSlideIndex:i,onClick:r}))})]})})),nm=({activeSlideIndex:e,onClick:t})=>({nav:l},n)=>{const a=n===e,i=a?"min-w-[350px] bg-white shadow-dark-blue border-none p-6":"min-w-72 ease-in duration-300 bg-white/10 px-xl py-lg hover:py-xl backdrop-blur",r=a?"text-primary-text text-h6 py-xs":"text-l pb-2xs text-secondary-text group-data-secondary:text-white",s=a?"text-secondary-text text-l font-light":"text-secondary-text text-m font-light group-data-secondary:text-white/80";return p("button",{type:"button",onClick:()=>t(n),"aria-label":l?.title,className:w("relative px-xl box-border overflow-hidden text-left grow basis-0 border border-gray group-data-secondary:border-white/50",i),children:[u("div",{className:r,children:l?.title}),u("div",{className:s,children:l?.description})]},String(n))},am=x((({className:e,padding:t,headlineVersion:l="S",isTabularBenefits:n=!0,additionalDescription:a,imageOptions:i,isFullWidthTitle:r=!0,...s})=>u(C,{className:e,padding:"p-0",...s,children:u(Ii,{className:"h-full",defaultPadding:"p-4xl sm:p-xl",padding:t,headlineVersion:l,isTabularBenefits:n,imageOptions:{isImageSecondary:!0,...i},isFullWidthTitle:r,...s,children:a?u(de,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:a}):null})}))),im=x((({className:e,title:t="Акции и спецпредложения",description:l,headlineVersion:n="S",date:a,buttons:i=[],...r})=>u(C,{className:w("box-border",e),...r,children:p(Da,{className:"h-full",title:t?u(gl,{title:t,headlineVersion:n,align:"text-left",isEmbedded:!0}):null,buttons:dl(i),children:[a?u("div",{className:"text-s mb-xs",children:rm(a)}):null,u("div",{className:"text-l",children:l})]})})));function rm(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const sm=x((({address:e,email:t,telephone:l,button:n,className:a="",__html:i,icon:r,title:s,version:o="primary",...c})=>p(C,{className:w("box-border text-left space-y-s",a),version:o,...c,children:[p("div",{className:"w-full flex justify-between flex-row-reverse",children:[cl(r)?u("div",{className:"w-10 h-7 sm:w-24 sm:h-16",children:u($t,{image:r})}):null,s?u(I,{headingType:"h3",as:"h3",title:s}):null]}),p("div",{className:"w-full space-y-m",children:[i?om(i):null,cm({label:"Адрес",data:e,iconName:"GeolocationIcon"}),cm({label:"Телефон(факс)",data:l,iconName:"PhoneIcon"}),cm({label:"E-mail",data:t,iconName:"MailIcon",dataColor:"text-primary-main"}),n?.text?dl([n]):null]})]}))),om=e=>u("div",{className:"border-b border-main-divider pb-lg",children:u(hi,{__html:e})}),cm=({label:e,data:t,iconName:l,dataColor:n=""})=>t?p("div",{className:"flex gap-s",children:[u(Ae,{iconVersion:"black",name:l,width:"24",height:"24"}),p("div",{className:"flex flex-col gap-2xs",children:[u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e}),u(me,{size:"text-xl",color:n,children:t})]})]}):null,dm=x((e=>{const{__html:t,richVersion:l,...n}=e;return u(C,{defaultPadding:"p-0",...n,children:u(hi,{__html:t,richVersion:l})})})),mm=x((({label:e,labelIconBgVersion:t,icon:l,onToggle:n,labelIcon:a})=>u(sr,{tag:"button",className:w("border-none bg-transparent items-center group/button",a?.icon?"py-xs":"py-lg"),onClick:n,textNode:p("div",{className:"flex items-center text-start group-hover/button:text-primary-main gap-s",children:[null,e?u(me,{size:"text-h6",font:"font-normal",children:e}):null]}),iconNode:l?u(Ae,{name:l,iconVersion:"color",width:"24",height:"24"}):null}))),hm=x((({className:e="",isExpanded:t,isFoldButtonOnTop:l=!0,label:n="Развернуть",labelIcon:a,labelIconBgVersion:i,version:r="primary",...s})=>u(C,{className:w("w-full","border-0 border-b border-solid border-main-divider last:border-b-0",e),defaultPadding:"p-0",tag:"div",version:"transparent",...s,children:u(Ai,{isFoldButtonOnTop:l,unfoldedByDefault:t,renderFoldableSection:({isUnfolded:e})=>u(Di,{className:w("gap-lg","grid grid-cols-12 [&>*]:pb-m"),isUnfolded:e,children:ya({...s,extraProps:{className:"w-full",padding:"p-0"}})}),renderFoldButton:({isUnfolded:e,onToggle:t})=>um({version:r,label:n,labelIcon:a,labelIconBgVersion:i,isUnfolded:e,onToggle:t})})})));hm.childrenTypes={exclude:["RollupItem"]};const um=({version:e,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:a,onToggle:i})=>{const r=t||(a?"Скрыть":"Развернуть"),s=(e=>e?"MinusIcon":"PlusIcon")(a);return"primary"===e?u(mm,{label:r,labelIcon:l,labelIconBgVersion:n,icon:s,onToggle:i}):u(or,{label:r,icon:a?"ArrowUpIcon":"ArrowDownIcon",onClick:i})},pm=x((({className:e=""})=>{const[t,l]=n("option2"),a=i((e=>l(e)),[]);return p("div",{className:w("order-4",e),children:[u(Ot,{className:"mb-xs",name:"contractType",text:"Простое хранение",value:"option1",checked:"option1"===t,onChange:a}),u(Ot,{name:"contractType",text:"Сделка с недвижимостью",value:"option2",checked:"option2"===t,onChange:a})]})})),xm=x((({data:e,fieldLabel:t,fieldValue:l,selected:n,placeholder:a="",setSelected:i,label:r})=>{const s=e.filter(Boolean).map((e=>({key:e?.[l||t],text:e?.[t]}))),o=s.find((e=>e.key===n));return u(He,{options:s,label:r,placeholder:a||n,onChange:e=>i(e.key),value:o})})),gm=x((({regions:e=[],selectedRegion:t,onSelectedRegion:l,branches:n=[],selectedBranch:a,onSelectedBranch:i})=>p("div",{className:"flex flex-col @xl:flex-row gap-m order-1",children:[u("div",{className:"flex-1 min-w-0",children:u(xm,{data:e,fieldValue:"code",fieldLabel:"name",selected:t,setSelected:l,label:"Регион"})}),u("div",{className:"flex-1 min-w-0",children:u(xm,{data:n,fieldValue:"branchCode",fieldLabel:"address",selected:a,setSelected:i,label:"Отделение",placeholder:"Выберите отделение"})})]}))),fm=["От 1 дня","До 365 дней"],bm=x((({days:e,setDays:t})=>p("div",{className:"order-1",children:[u(me,{size:"text-m",font:"font-light",children:"Срок аренды"}),u(yt,{min:1,max:365,value:e,items:fm,onChange:t})]}))),ym=x((({caseVolumes:e=[],selectedCaseVolume:t,onSelectedCaseVolume:l,safeBoxCases:n=[],selectedBoxSize:a,onSelectedBoxSize:i})=>p("div",{className:"flex flex-col @xl:flex-row gap-m order-1",children:[u("div",{className:"flex-1 min-w-0",children:u(xm,{data:e,fieldLabel:"volume",selected:t,setSelected:l,label:"Размер",placeholder:"Выберите размер"})}),u("div",{className:"flex-1 min-w-0",children:u(xm,{data:n,fieldLabel:"safeBoxCasesSize",selected:a,setSelected:i,label:"Параметры ячейки, мм (ВхШхД)",placeholder:"Выберите параметр ячейки"})})]}))),vm=x((({regions:e,selectedRegion:t,branches:l,selectedBranch:n,days:a,selectedCaseVolume:i,selectedBoxSize:r,safeBoxCases:s,caseVolumes:o,onChange:c,onClick:d})=>p("div",{className:"contents @xl:block flex-1 space-y-xl",children:[u(gm,{regions:e,selectedRegion:t,onSelectedRegion:e=>c({selectedRegion:e}),branches:l,selectedBranch:n,onSelectedBranch:Nm(c)}),u(bm,{days:a,setDays:e=>c({days:e})}),u(ym,{caseVolumes:o,selectedCaseVolume:i,onSelectedCaseVolume:wm(c),safeBoxCases:s,selectedBoxSize:r,onSelectedBoxSize:e=>c({selectedBoxSize:e})}),u("div",{className:"order-4",children:u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:"Тип договора"})}),p("div",{className:"contents @md:flex justify-between items-center gap-m",children:[u(pm,{}),u(se,{text:"Офисы на карте",version:"primary",onClick:d,className:"order-6"})]})]}))),Nm=e=>t=>{e({selectedBranch:t,selectedCaseVolume:"",selectedBoxSize:""})},wm=e=>t=>{e({selectedCaseVolume:t,selectedBoxSize:""})},km=x((({days:e,tariffs:t=[]})=>{const l=Sm(e,t),n="На рисунке изображена пачка листов\nформата А4";return p("div",{className:"contents @xl:flex flex-col justify-between gap-xl order-2",children:[p("div",{className:"flex flex-col @xl:flex-row gap-x-6xl gap-y-2xl order-5 @xl:order-none py-2xl @xl:py-0 border-t border-main-divider @xl:border-none",children:[Cm("Аренда за",e),Cm("Цена",l+" ₽")]}),u("span",{className:"@xl:hidden order-3 mb-xs text-s font-light text-secondary-text",children:n}),p("div",{className:"flex flex-col items-center gap-s order-3 @xl:order-none mb-xl @xl:mb-0 bg-primary-main py-s @xl:p-3xl text-center",children:[u($t,{image:{icon:"PackA4Icon"},className:"@xl:h-60"}),u("span",{className:"hidden @xl:inline text-s font-light text-white opacity-80 whitespace-pre-line",children:n})]})]})})),Cm=(e,t)=>p("div",{className:"flex justify-between items-center gap-y-xs @xl:flex-col @xl:items-start",children:[u("div",{className:"text-l font-light text-secondary-text",children:e}),u("span",{className:"text-l @xl:text-h3 text-primary-text",children:t})]}),Sm=(e,t)=>{const l=Im(e);return e*(t?.find((e=>e.tariffType===String(l)))?.tariffValue||0)},Im=e=>{let t=1;switch(!0){case e>30&&e<=90:t=2;break;case e>90&&e<=180:t=3;break;case e>180&&e<=365:t=4}return t},Tm=(e,t)=>e.find((e=>e.branchCode===t)),Bm=x((e=>{const{regions:t,data:l,branches:n,onChange:i,onClick:r}=e;a((()=>{i({selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:""})}),[l.selectedRegion,i]);const s=Tm(n,l.selectedBranch),o=Mm(s?.safeBoxCaseVolumes),c=Pm(s?.safeBoxCaseVolumes,l.selectedCaseVolume)?.safeBoxCases,d=Rm(c,l.selectedBoxSize);return p("div",{className:"flex flex-col @4xl:flex-row gap-4xl align-top",children:[u(vm,{...l,regions:t,onClick:r,branches:n,caseVolumes:o,safeBoxCases:c,onChange:i}),u(km,{days:l.days,tariffs:d})]})})),Mm=e=>e?.length?e?.filter((e=>e?.safeBoxCases?.length)):[],Pm=(e,t)=>e?.find((e=>e.volume===t)),Rm=(e,t)=>e?.find((e=>e.safeBoxCasesSize===t))?.tariffs,Vm=[];const zm=async e=>await _(e,{method:"GET"})||Vm,Am=x((({title:e,footnote:t,className:l="",...a})=>{const[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),[c,d]=n({selectedRegion:"",selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:"",days:26}),m=$(),h=Dm(c.selectedRegion,m),x=function(e){const{data:t}=A(e?`/api/v1/safeboxes?regionCode=${e}`:null,zm);return t||Vm}(h),g=i((e=>d((t=>({...t,...e})))),[d]),f=(b=Tm(x,c.selectedBranch)||x,Array.isArray(b)?b.map((e=>e.gpsLatitude&&e.gpsLongitude?[e.gpsLatitude,e.gpsLongitude]:[])):b?.gpsLatitude&&b?.gpsLongitude?[[b.gpsLatitude,b.gpsLongitude]]:[]);var b;return p(C,{className:l,defaultPadding:"",...a,children:[p("div",{className:"p-4xl space-y-xl",children:[e?u(I,{title:e,headingType:"h3",as:"h2",className:"text-primary-text mb-s text-center"}):null,u(Bm,{regions:m,branches:x,data:{...c,selectedRegion:h},onClick:o,onChange:g}),t?u(de,{size:"text-s",font:"font-light",children:t}):null]}),f.length&&r?u(cd,{points:f,className:"h-[640px]"}):null]})})),Dm=(e,t)=>!e&&t?.length&&t[0]?.code?t[0].code:e,_m=({styleMap:e,isMainButton:t,version:l})=>(n,a,i)=>{const{label:r,description:s,button:o,items:c,isDotted:d}=n;return p("div",{className:w("relative flex flex-col items-center text-center justify-between whitespace-pre-line overflow-hidden space-y-3xl",jm(i.length)),children:[p("div",{className:"text-center space-y-xs",children:[r?u("div",{children:u(me,{size:"text-h6",children:r})}):null,p("div",{className:"flex flex-col items-center gap-3xs",children:[s?u("div",{className:e.description,children:s}):null,u(li,{className:e.description,items:c,listItemSize:"M",isDotted:d})]})]}),o?.text&&!t?u(se,{className:"box-border py-s w-full max-w-60 mt-auto",version:l,...o,children:o?.text}):null]},String(a))},jm=e=>e<5?"w-72":"w-52",Lm={description:"text-white/80 text-l font-light group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconText:"text-white group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconBackground:"bg-white/30 group-data-primary:bg-main-divider",iconConnector:"bg-white group-data-primary:bg-secondary-light",dot:"bg-white/80 group-data-primary:bg-secondary-text"},$m=x((({className:e="",showLines:t=!0,steps:l=[],buttons:n,size:a="normal",version:i="primary",stepVersion:r="gray",title:s,description:o,...c})=>{const d=l.length>3,m=Lm,h=(e=>e?"":"opacity-0")(t),x=(e=>e<5?"px-24":"px-16")(l.length),g=Boolean(n?.every((e=>e?.text)));return p(C,{className:w("box-border flex flex-col items-center overflow-hidden gap-y-3xl",e),defaultPadding:"p-6xl",version:i,...c,children:[u(gl,{headlineVersion:"S",title:s,description:o,isEmbedded:!0,className:"w-full"}),l?.length?p("div",{className:"box-border space-y-lg",children:[u("div",{className:w("flex items-center",x),children:pc(u("div",{className:w("h-0.5 w-full bg-secondary-light flex-1",h)}))(l.map(Om(m,a,r)))}),u("div",{className:w("flex justify-between",d?"gap-x-s":"gap-x-20"),children:l.map((f={styleMap:m,isMainButton:g,version:i},(e,t,l)=>{const{type:n}=e;if("default"!==n&&"rte"!==n)return null;switch(n){case"default":return _m(f)(e,t,l);case"rte":return u("div",{className:w("text-center",jm(l.length)),children:u(hi,{__html:e.__html})},String(t));default:return null}}))})]}):null,dl(n)]});var f})),Om=(e,t,l)=>({icon:n},a)=>{const i="secondary"===l?"white":"color";return u(C,{defaultPadding:"",className:`${Em(t)} flex justify-center items-center text-center rounded-full box-border z-10`,version:l,children:cl(n)?u($t,{image:{...n,iconVersion:n?.iconVersion||i},width:"48",height:"48"}):u("span",{className:w("text-h4","transparent"===l?e.iconText:Fm(l)),children:a+1})},String(a))},Em=e=>"normal"===e?"h-24 w-24":"h-16 w-16",Fm=e=>"secondary"===e?"group-data-primary:text-white":"text-secondary-text",Um=x((()=>u("div",{}))),Hm=x((({className:e,version:t,gap:l=14,padding:n=16,showDots:a=false,minHeight:i,children:r,onVisibleIndicesChange:s,listType:o="horizontal-list"})=>{const c=Array.isArray(r)?r.length:0,[d,m]=ca({itemCount:c,onVisibleIndicesChange:s}),[h]=m.visibleIndicesRange;return p("div",{className:w(e,"vertical-list"===o?"relative h-full":""),children:[u(ta,{containerRef:d,activeIndex:h,visibleItemCount:1,gap:l,padding:n,onVisibleIndicesChange:m.handleVisibleIndicesChange,listType:o,minHeight:i,children:r}),a?u(ra,{containerRef:d,activeIndex:h,dotCount:c,listType:o,version:t}):null]})})),Wm=x((({listType:e,showDots:t,options:l,version:n,...a})=>u(C,{version:n,defaultPadding:"p-0",...a,children:u(Hm,{listType:e,showDots:t,version:n,children:ya({...a,options:l})})})));Wm.childrenTypes={exclude:["SwipeListControlBlock"]};const Xm="hidden sm:flex absolute z-40 top-0",Km=x((({className:e,items:t=[],value:l,onChange:n,tabsType:a})=>{const[i,r]=ca({itemCount:t?.length||0});return p("div",{className:w("relative overflow-x-auto no-scrollbar",e),role:"tablist",children:[u(ta,{containerRef:i,snapAlign:"snap-start",onVisibleIndicesChange:r.handleVisibleIndicesChange,children:t.map(Yc(l,n,a))}),r.canScrollLeft?u(Vl,{className:w("left-6",Xm),onClick:r.scrollLeft}):null,r.canScrollRight?u(zl,{className:w("right-6",Xm),onClick:r.scrollRight}):null]})})),Ym=({tabsMode:e,...t})=>{switch(e){case"wideScreen":return u(Gc,{...t});case"centered":return u("div",{className:"flex",children:u(Gc,{className:"m-auto p-xs rounded-md bg-main-gray",tabsType:"rounded",...t})});case"scrollable":return u("div",{className:"flex",children:u(Km,{className:"m-auto",tabsType:"underlined",...t})});default:return null}},Gm="tab",qm=x((({className:e="",isSticky:t,tabs:l=[],tabsMode:s,...o})=>{const c=G(),{isReady:d}=c,m=r((()=>l.map(Zm)),[l]),[h,p]=n(0);a((()=>{if(!l||!l[0])return;const e=c.query.tab&&l.findIndex((e=>"group"===e.type&&e.ref===c.query.tab))||0,t=l[e]||l[0];p(e),Jm(t)}),[d]),a((()=>{const e=l[h];"group"===e?.type&&b.subject("tab",{type:e.type,label:e.ref})}),[l,h]);const x=i((e=>{const t=m.indexOf(e),n=l[t];p(t),Jm(n),"group"===n.type&&(e=>{const t=new URLSearchParams(c.query);e.name?t.set(Gm,e.name):t.delete(Gm),c.replace(`${c.pathname}?${t}`,"",{scroll:!1})})(e)}),[l,m]);return u(C,{className:w(t?"sticky top-1 z-20":"",e),defaultPadding:"p-0",...o,children:Ym({items:m,value:m[h],tabsMode:s,onChange:x})})})),Jm=e=>{"group"===e.type&&b.fire("tab",{type:e.type,label:e.ref}),"link"===e.type&&b.fire("tab",{type:e.type,label:e.href})},Zm=e=>"group"===e?.type?{text:e.title,name:e.ref}:e,Qm=x((({className:e="",isOpen:t,onClick:l})=>u(se,{className:e,appendRight:u($t,{image:{icon:t?"ArrowUpIcon":"ArrowDownIcon"},width:"20",height:"20"}),text:t?"Скрыть":"Показать",version:"gray",onClick:l}))),eh={Buttons:({buttons:e})=>dl(e,{buttonClassName:"basis-0"}),Img:({image:e})=>e?.src?u($t,{image:e}):null,List:({isDotted:e,...t})=>u(li,{className:"flex flex-col justify-between items-start text-h6",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>p("div",{className:"space-y-2xs",children:[e?u("div",{children:e}):null,t?u("div",{children:u(me,{size:"text-s",color:"text-secondary-text",children:t})}):null]}),Table:({isVisible:e,displayTable:t,dataUrl:l,pdfUrl:n,isOpen:a})=>e?u(Qm,{isOpen:a,onClick:()=>{t({dataUrl:l,pdfUrl:n})}}):null},th=({rowIdx:e,cellIdx:t,setTableInner:l,tableInner:i,openTableInnerIdx:r,setOpenTableInnerIdx:s})=>(o,c)=>{const[d,m]=n(!0);a((()=>{t===r&&i||m(!0)}),[i,r]);return u("div",{children:lh({cell:o,cellProps:{rowIdx:e,cellIdx:t,fieldIdx:c,displayTable:e=>{m(!1),s(t),l(e)},isVisible:d}})},String(c))},lh=({cell:e,cellProps:t})=>{if(!e)return null;const{tableCellType:l,...n}=e;if(!l||!(l in eh))return null;return u(eh[l],{...t,...n})},nh=x((({cells:e,rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})=>u("div",{className:"w-80 flex-grow flex flex-col gap-m @4xl:gap-lg",role:"cell",children:e?.length?e.map(th({rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})):null}))),ah=(e,t)=>140*ci(e.slice(0,t).map((e=>e?.cols?.length??1))),ih=(e,t)=>e?.length>0?u("div",{className:w("flex",0===t?"text-secondary-text":""),children:e.map(((e,t)=>u("div",{className:"w-20 text-h6 mx-lg",children:e},String(t))))}):null,rh=x((({rows:e})=>{const t=e?.[0]?.length??0,[l,n]=Pl({itemCount:t,visibleItemCount:5});return p("div",{children:[e?.map((a=l,(e,t)=>{if(!e?.length)return null;const[l,...n]=e,i=w("flex duration-1000 text-center",0!==t?"font-normal":"font-light");return p("div",{className:"flex border-main-divider border-b border-solid h-full",children:[l?.data?u("div",{className:"text-xl font-light w-56 min-w-56 py-lg",children:l.data}):null,u("div",{className:"flex flex-grow overflow-hidden",children:u("div",{className:i,style:{transform:`translateX(-${ah(n,a)}px)`},children:n?.map(((e,t)=>p("div",{className:"flex flex-col flex-grow gap-s justify-center py-xl odd:bg-main-divider",children:[e?.data?u("div",{className:"text-xl font-light",children:e.data}):null,e?.cols?ih(e.cols,a):null]},`row${t}`)))})})]},String(t))})),Al({...n,btnClass:["left-3 top-20","right-3 top-20"],className:""})]});var a})),sh=x((({activeTabIndex:e,items:t})=>u("div",{children:t.map(((t,l)=>{const n=`activeTabIdx:${e}-tableIdx:${l}`;return p("div",{className:"w-full @container",children:[u("div",{className:"flex p-m bg-white @4xl:bg-gray text-center justify-center relative",children:u(me,{size:"text-xl",font:"font-light",children:t.title})}),u("div",{className:"w-full pl-xs overflow-hidden transition-height duration-500 ease-in-out",children:u("div",{className:"relative",children:u(rh,{rows:t.rowsData})})})]},n)}))}))),oh=x((({currencies:e,linkToPDF:t,activeTabIndex:l,setActiveTabIndex:n})=>p("div",{className:"flex justify-between items-center w-full py-lg",children:[e&&e.length>1?u("div",{className:"flex bg-secondary-light p-2xs rounded-md",children:e.map(((e,t)=>u("div",{className:"rounded-md text-xl font-light px-4 py-3 cursor-pointer "+(t===l?"bg-primary-main text-white":"text-secondary-text"),onClick:()=>n(t),children:e||t+1},e)))}):null,t?u(se,{className:"text-primary-main",href:t,version:"secondary",target:"_blank",appendLeft:u(Ae,{name:"DocDownloadIcon",iconVersion:"color",className:"mr-3xs",width:"20",height:"20"}),text:"Скачать в PDF"}):null]})));async function ch(e){const t=await fetch(e);return await t.json()}const dh=x((({dataUrl:e,pdfUrl:t,onClick:l})=>{const{tableData:a}=function(e){const{data:t}=A(function(e){return`/wcms-resources/${e||"tariffs-inner-table-data"}.json`}(e),ch);return t||{}}(e),[r,s]=n(0),o=i((e=>s(e)),[]),c=a?.[r]?.items??[],d=a?.map((e=>e.currency??""));return p("div",a?{className:"bg-white z-10",children:[u(oh,{currencies:d,activeTabIndex:r,setActiveTabIndex:o,linkToPDF:t}),u(sh,{activeTabIndex:r,items:c}),u(Qm,{className:"mt-xl",onClick:l,isOpen:!0})]}:{className:"my-lg space-y-m text-h6 text-center",children:[u("p",{children:"Данных нет"}),u(Qm,{onClick:l,isOpen:!0})]})})),mh=x((({children:e,tableInner:t,onHideContentClick:l})=>p("div",{className:"self-start flex flex-col",role:"row",children:[u("div",{className:w("@4xl:border-main-divider @4xl:border-b","flex flex-col @4xl:flex-row gap-y-xs gap-x-5xl pb-lg @4xl:pt-lg"),children:e}),t?u("div",{className:"origin-top animate-expansion",children:u(dh,{...t,onClick:l})}):null]}))),hh=x((({row:{header:e,data:t},activeIndex:l,rowIdx:a,...r})=>{const[s,o]=n(void 0),c=i((e=>o(e)),[]),[d,m]=n(void 0),h=i((e=>m(e)),[]);return p(mh,{onHideContentClick:()=>o(void 0),tableInner:s,...r,children:[u("div",{className:w("text-s","w-80 flex-shrink-0"),children:p("div",{className:"flex gap-m items-center text-primary-text",role:"cell",children:[e?.icon?u($t,{className:"hidden @4xl:block max-w-6",image:e.icon,width:"24",height:"24"}):null,e?.title?u("div",{className:"text-m font-light",children:e?.title}):null]})}),t?.length?u(Wi,{activeIndex:l,columnWidth:360,version:"tariff",children:t.map(((e,t)=>u(nh,{cells:e,rowIdx:a,cellIdx:t,setTableInner:c,tableInner:s,openTableInnerIdx:d,setOpenTableInnerIdx:h,...r},String(t))))}):null]})})),uh=x((({children:e,controls:t})=>{const{isScrollAvailable:l}=t;return p("div",{role:"table",children:[p("div",{className:"relative space-y-xs",children:[e,Al({...t,btnClass:["top-28","top-11"],className:"right-7"})]}),l?u("div",{className:"absolute top-0 right-0 bottom-0 w-20 bg-opacity-to-white"}):null]})})),ph=x((({className:e="",title:t,description:l,rowHeaders:n,tariffsColumns:a,hiddenRowsNum:i=0,...r})=>{const s=a?.map((({data:e})=>e))||[],o=n?.map(((e,t)=>({header:e,data:s.map((e=>e?.[t]||[]))}))),c=s.length,[d,m]=Pl({itemCount:c,visibleItemCount:2}),h=(o||[]).map(((e,t)=>u(hh,{row:e,activeIndex:d,rowIdx:t,...r},String(t)))),[x,g]=i>0?[h.slice(0,-i),h.slice(-i)]:[h,[]];return p(C,{className:w("overflow-hidden relative space-y-0 @4xl:space-y-xl",e),defaultPadding:"p-6xl",...r,children:[u(gl,{title:t,description:l,headlineVersion:"M",isEmbedded:!0,align:"text-center"}),u("div",{className:"space-y-m",children:i>0?u(Ai,{renderFoldableSection:({isUnfolded:e})=>p(uh,{controls:m,children:[x,u(Di,{isUnfolded:e,children:g})]}),renderFoldButton:cr}):u(uh,{controls:m,children:h})})]})})),xh=x((({className:e="",title:t,description:l,iconVersion:n,image:a,__html:i,items:r=[],...s})=>p(C,{className:w("flex gap-s sm:gap-m bg-white group-data-secondary:bg-primary-main/10",e),...s,children:["small"===n?gh():null,"big"===n?fh(a):null,p("div",{className:"flex flex-col w-fit gap-2xs sm:gap-xs",children:[t?u(me,{size:"text-l",font:"font-normal",color:"text-primary-text group-data-secondary:text-white",children:t}):null,l?bh(l):null,r?.length?yh(r,!0):null,i?u(hi,{__html:i}):null]})]}))),gh=()=>u("div",{className:"rounded-full h-4 w-4 text-center text-xs font-light bg-primary-main text-white group-data-secondary:bg-white group-data-secondary:text-primary-main",children:"i"}),fh=e=>e?.src?u($t,{className:"h-fit flex-shrink-0",image:e}):null,bh=e=>u(de,{size:"text-s",font:"font-light",color:"text-secondary-text group-data-secondary:text-white",children:e}),yh=(e,t)=>u("ul",{className:w("text-secondary-text group-data-secondary:text-white/80",t?"list-disc pl-xl":""),children:e.map(((e,t)=>u("li",{children:u(me,{size:"text-s",font:"font-light",children:e})},`listItem-${t}`)))}),vh=x((({className:e,padding:t,headlineVersion:l="S",listItemSize:n="M",...a})=>u(C,{className:e,padding:"p-0",...a,children:u(Ii,{className:"h-full",defaultPadding:"p-xl",padding:t,headlineVersion:l,listItemSize:n,isFullWidthTitle:!1,...a})}))),Nh=x((({className:e="",gap:t="",isPadding:l=!1,isInnerPadding:n=!0,version:a="transparent",isTheme:i=!1,...r})=>u(C,{className:w("relative flex flex-col",ic[t],e),defaultPadding:l?"p-6xl":"",version:a,isTheme:i,...r,children:ya({...r,extraProps:{className:"w-full",padding:n?"":"p-0"}})})));Nh.childrenTypes=[];const wh=e=>(e=>{const t="col-span-",l=e?.split(/\s+/).find((e=>e.startsWith(t)));return l?parseInt(l.substring(t.length),10):12})(e)<10?"py-xl px-6xl":"py-6xl px-32",kh=x((({className:e,title:t,url:l,previewImg:n,...a})=>{const i=G();return p(C,{className:e,defaultPadding:wh(e),...a,children:[u(gl,{title:t,headlineVersion:"M"}),l?u("video",{className:"m-auto w-full object-fill",preload:"metadata",poster:X(i)(n?.src),style:{maxHeight:524},controls:!0,children:u("source",{src:X(i)(l)})}):null]})})),Ch={ApplicationForm:Qt,BenefitsBlock:al,Bonus:fl,BonusBenefitsBlock:Cl,BusinessBlock:Tl,ButtonsBlock:Ml,Calculator:Hn,CardTransfer:Jn,Carousel:Ta,CarouselBankHistoryCard:Ba,CarouselCard:za,CarouselCatalogCard:Fa,CarouselInvestmentCard:Wa,CarouselLinks:Ga,CarouselProductCard:ni,CarouselRecommendationCard:Vi,CarouselRichTextCard:zi,CarouselTariffsCard:ji,ComparisonTable:lr,ContactsBlock:ar,Depository:as,DepositFiltration:Mr,ErrorBlock:rs,ExchangeRateTile:Ms,Footer:go,GracePeriod:fo,Header:ac,Headline:gl,HorizontalLayout:rc,ImgBlock:sc,InsuranceAmountBlock:hc,InvestmentInfo:fc,LinkDocs:Tc,MobileAppTile:Pc,MortgageFiltration:Jc,OfficesAtmsMap:Wd,ParagraphBlock:Xd,PictureText:Gd,Placeholder:qd,ProductBlock:tm,ProductGallery:lm,ProductTile:am,PromoTile:im,RepresentativeOfficeInfo:sm,RichTextBlock:dm,RollupItem:hm,SafeDepositRental:Am,StepsBlock:$m,SwipeListControlBlock:Wm,StickyBottomMenu:Um,Tabs:qm,TariffsTable:ph,TextBlock:xh,Tile:vh,VerticalLayout:Nh,Video:kh};const Sh=["Header","Footer"],Ih=([,{target:e}])=>Math.abs(e.getBoundingClientRect().top);function Th(e=globalThis){const t=s(new Map);a((()=>N.subscribe("intersection",(({block:e,intersection:l})=>{t.current&&t.current.set(e,l)}))),[]),a((()=>{const l=((e,t=600)=>{let l;const n=(...a)=>{n.dispose(),l=setTimeout((()=>{e(...a)}),t)};return n.dispose=()=>{l&&clearTimeout(l)},n})((()=>{!function(e){const t=`#${l=e?.anchor,l?.replace("#","")||""}`;var l;globalThis.location?.hash!==t&&globalThis.history?.replaceState(globalThis.history?.state,"",t)}(globalThis.scrollY>3*globalThis.innerHeight/4?function(e){const t=e.filter((([e])=>!Sh.includes(e.type||""))).filter((([,{intersectionRatio:e}])=>e>.01)),[l]=t.length>0?hn(Ih)(t):[];return l}([...t.current||[]]):void 0)}),100);return e.addEventListener("scroll",l),()=>{l.dispose(),e.removeEventListener("scroll",l)}}),[e])}const Bh="cookie",Mh=x((({termLink:e,personalDataPolicyLink:t})=>{const[l,{setTrue:n,setFalse:a}]=Ve();$s((()=>{globalThis.localStorage?.getItem(Bh)||n()}),[],3e3);const r=i((()=>{globalThis.localStorage?.setItem(Bh,"true"),a()}),[]);return l?u("div",{className:"container fixed left-0 right-0 bottom-0 z-50",children:p("div",{className:"bg-white m-xl p-xl rounded-md flex sm:items-center shadow-main-black",children:[u("div",{className:"sm:flex-1",children:p(de,{size:"text-s",font:"font-light",color:"text-primary-text",children:["АО «Россельхозбанк» использует",u(Ja,{isRemote:!0,className:Ph(e?.href),...e,children:"cookie"}),"(файлы с данными о прошлых посещениях сайта) для персонализации сервисов и удобства пользователей. Вы можете запретить сохранение cookie в настройках своего браузера.",u(Ja,{isRemote:!0,className:Ph(t?.href),...t,children:"Обработка Ваших персональных данных"}),"производится в соответствии с требованиями Федерального закона от 27.07.2006 № 152-Ф3 «О персональных данных»."]})}),u("div",{className:"ml-s sm:ml-0 w-24 flex justify-end",children:u(Ls,{className:"bg-main-gray rounded-md",onClose:r})})]})}):null})),Ph=e=>w("inline mx-2xs",e?"text-green-dark":"");function Rh(e){throw new Error(e)}const Vh=({onCloseAll:e,onClose:t}={})=>{const[l,{push:r,pop:s,clear:o}]=function(e=[]){const[t,l]=n(e),a=i((e=>l((t=>[...t,e]))),[]),r=i((()=>l((e=>e.slice(0,-1)))),[]),s=i((e=>l((t=>t.filter((t=>t!==e))))),[]),o=i((()=>l([])),[]);return[t,{setList:l,push:a,pop:r,remove:s,clear:o}]}(),c=i((()=>{e&&e(l),o()}),[l,e]),d=i((()=>{t&&t(l[l.length-1]),s()}),[l,t]);return a((()=>b.subscribe("dialog",(e=>{switch(e.type){case"open":r(e);break;case"close":e.all?c():d();break;default:Rh(e)}}))),[c,d]),l},zh=x((()=>{const e=i((e=>{for(const t of e)t?.onClose&&t.onClose()}),[]),t=i((e=>{e?.onClose&&e.onClose()}),[]),l=Vh({onCloseAll:e,onClose:t}),{close:n}=O(),r=i((({key:e})=>{"Escape"===e&&n()}),[]);return $e(globalThis.document,"keydown",r),a((()=>{l.length?(globalThis.document?.body.classList.add("no-scrollbar"),globalThis.document?.body.classList.add("overflow-hidden")):(globalThis.document?.body.classList.remove("no-scrollbar"),globalThis.document?.body.classList.remove("overflow-hidden"))}),[l]),l.length?u("div",{className:"fixed inset-0 z-50",role:"dialog",children:l.map((({dialog:e,id:t},n)=>u("div",{className:w("absolute inset-0 overflow-x-hidden overflow-y-scroll no-scrollbar",n===l.length-1?"":"hidden"),children:e},String(t||n))))}):null})),Ah=x((()=>{const[e,t]=n(null),l=i((()=>{t(null)}),[]);a((()=>b.subscribe("popup",(e=>{switch(e.type){case"open":case"update":t(e);break;case"close":l();break;default:Rh(e)}}))),[]);const r=i((({key:e})=>{"Escape"===e&&l()}),[l]);return $e(globalThis.document,"keydown",r),e?u("div",{className:"absolute z-50",style:{left:`${e.left}px`,top:`${e.top}px`,...e.width?{width:`${e.width}px`}:{}},role:"dialog",children:e.popup}):null})),Dh=h();const _h=x((({className:e,onClick:t,ariaLabel:l})=>u("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":l,children:jh()}))),jh=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return p("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[u("path",{...e,strokeMiterlimit:"10",d:"M21.48 11.95c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1M7.48 18.35l3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l1.24-3.77"}),u("path",{...e,d:"M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z"})]})},Lh=x((({className:e=""})=>{const t=function(e){const[t,l]=n(0);return a((()=>{(async()=>{const[t]=await Dh.getLikeCount(e);l(t?.value||0)})()}),[e]),{likeCount:t,like:i((async()=>{l(await Dh.like(e))}),[e]),dislike:i((async()=>{l(await Dh.dislike(e))}),[e])}}(G().pathname);return p("div",{className:`border-main border-2 border-solid bg-white flex w-32 items-center justify-center gap-s p-xs font-sans ${e}`,children:[u(_h,{onClick:Y(t.like),ariaLabel:"Поставить отметку «лайк»"}),u(_h,{onClick:Y(t.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),u("span",{className:"select-none",children:t.likeCount})]})})),$h=x((({className:e,blocksRegistry:t,blockDecorator:l,data:n={}})=>{const{style:a,slots:i,likeControl:r,colorPalette:s="pc"}=n,o={key:"",page:n,blocksRegistry:t,blockDecorator:l,parent:n};return Th(),p("div",{"data-theme":s,children:[p("section",{className:w("@container relative",a,e),children:[i?.header?u("div",{className:"relative z-10 mb-lg shadow-[0_8px_32px_0px_#00000014]",children:ba(i?.header,{...o,slotName:"header"})}):null,p("div",{className:"container space-y-px @5xl:space-y-0 @5xl:grid @5xl:grid-cols-12 @5xl:gap-2xs",children:[ya({block:n,options:o,extraProps:{className:"scroll-mt-12"}}),ba(i?.footer,{...o,slotName:"footer"})]}),r?u("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:u(Lh,{className:"rounded-tl-3xl sticky bottom-0 pointer-events-auto"})}):null]}),u(Um,{}),u(zh,{}),u(Ah,{}),u(Mh,{termLink:{href:"/pd-policy#cookie",target:"_blank"},personalDataPolicyLink:{href:"/pd-policy",target:"_blank"}})]})}));$h.childrenTypes=[],$h.slots=()=>["header","footer","StickyBottomMenu"];e.Blocks=Ch,e.ContentPage=$h,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),l=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await l.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}},e.LikeAPI=h,e.handlerDecorator=Y,e.joinList=pc,e.packageVersion="0.14.26",e.projectSettings=d,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=W,e.useRouter=G,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";let t;const l=e=>(...l)=>t[e](...l),n=l("useState"),a=l("useEffect"),i=l("useCallback"),r=l("useMemo"),s=l("useRef");const o=e=>e&&!e.endsWith("/")?`${e}/`:e,c={PROD_BRANCH:"master"},d=new class{_=c;setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH||c.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get STICKY_MOBILE_MENU(){return this._.STICKY_MOBILE_MENU}get FOOTER(){return this._.FOOTER}get PORTAL_DATA(){return this._.PORTAL_DATA}get CHAT_BOT(){return this._.CHAT_BOT}get CDN(){return o(this._.CDN)}get BASE_PATH(){return o(this._.BASE_PATH)}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},m="likesToken";function h(){async function e(){try{const e=JSON.parse(globalThis.localStorage?.getItem(m)||"");if(e?.token)return e}catch(e){}try{const e=await fetch("/assist/v1/public/auth",{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:t,name:l}=await e.json();return globalThis.localStorage?.setItem(m,JSON.stringify({token:t,name:l})),{token:t,name:l}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:l}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l},body:JSON.stringify({node_ids:t})}),{likes:n}=await e.json();return n||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:l,name:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${d.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:l,UserID:n},body:JSON.stringify({node_id:t,user_name:n})}),{likes:a}=await e.json();return a||0}catch(e){return console.error(e),0}}}}const u=(...e)=>globalThis._uni._jsx(...e),p=(...e)=>globalThis._uni._jsxs(...e),x=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:g(e)),t._tmpl},g=e=>{function t(t,l){const{children:n,...a}=t||{},i=l?.slots?.default,r=n||i&&i();return e(Object.assign(a,r&&{children:r}),l)}return t.inheritAttrs=!1,t};class f{subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]=(this.subscribers[e]||[]).concat(t);const l=this.subjectsStateMap[e];return l&&t(l),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){e in this.subjectsStateMap&&(this.subjectsStateMap[e]=t),this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=new f;function y(e,{sensitivity:t,rootRef:l}={}){const n=s(null),i=r((()=>({threshold:v(t),root:l?.current})),[t,l?.current]);return a((()=>{if(!n.current)return;const t=new IntersectionObserver(e,i);return t.observe(n.current),()=>{t.disconnect()}}),[e,i]),n}function v(e=0){const t=Math.round(10*e);return new Array(t).fill(0).map(((e,l)=>Math.min(l/t)),1).concat(1)}const N=new f;const w=(...e)=>e.flatMap((e=>e)).filter(Boolean).join(" "),k={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white",gray:"bg-main-divider text-primary-text",transparent:"bg-transparent text-primary-text","":""},C=x((({className:e,version:t="primary",isTheme:l=!0,defaultPadding:r="p-xl",padding:s,block:o,tag:c="section",role:d,children:m})=>{const h=c,p=function(e){return y(i((t=>{if(!e||!t?.length)return;const l=t[t.length-1];N.fire("intersection",{block:e,intersection:l})}),[e]),{sensitivity:1})}(o),[x,g]=n(!1);a((()=>b.subscribe("tab",(e=>{g(Boolean(e.label&&o?.labels?.length&&!o.labels.includes(e.label)))}))),[o]);const f=t&&l;return u(h,{className:w("@container font-sans",f?"group":"",k[t],x?"hidden":"",s||r,e),...f?{"data-ver":t}:{},...o?.anchor?{id:o.anchor,ref:p}:{},role:d,children:m})})),S={h0:"text-h0",h1:"text-h1",h2:"text-h2",h3:"text-h3",h4:"text-h4",h5:"text-h5",h6:"text-h6"},I=x((({className:e="",headingType:t="h3",as:l="h3",title:n,children:a})=>u(l,{className:w("font-sans m-0",S[t],e),children:n||a}))),T=e=>e,B=(e,t)=>{const[l,a]=n(e),[r,o]=n(!1),[c,d]=n({}),m=s({}),h=i(((e,t)=>{const{parse:n=T,format:i=T}=t||{};return m.current||(m.current={}),m.current[e]||=t=>{a((l=>({...l,[e]:n(t)}))),d((t=>({...t,[e]:!0})))},{value:i(l[e]),isDirty:r||c[e],onChange:m.current[e]}}),[l,r,c]),u=i((e=>{a(e),d(e)}),[]),p=i((()=>{a(e),o(!1),d({})}),[e]),x=i((e=>{e.preventDefault(),o(!0),t&&t(l)}),[t,l]);return[l,{isDirty:r||Object.values(c).some(Boolean),field:h,update:u,reset:p,onSubmit:x}]},M=e=>t=>t&&Object.entries(e).flatMap((([e,l])=>l(t[e])))||[],P=e=>!e?.length,R=e=>t=>l=>e(l)?[]:[t],V=e=>null!=e,z=new Map;function A(e,t,{fallback:l,cache:i}={}){const s=r((()=>D(e)),[e]),[o]=(e=>Boolean(e&&Array.isArray(e)&&1===e.length&&"string"==typeof e[0]))(s)?s:[],[c,d]=n(void 0),[m,h]=n(void 0);a((()=>{if(!s.some(V))return;let e=!1;const l=(t,l)=>{e||(d(t),h(l))};return(async()=>{try{l(await(o?((e,t=z)=>l=>{const n=t.get(l);if(V(n))return n;const a=e(l);return V(a)?t.set(l,Promise.resolve(a)):t.delete(l),a})(t,i)(o):t(...s)))}catch(e){l(void 0,e)}})(),()=>{e=!0}}),[t,i,s]);const u=l&&o&&l[o];return{data:!c&&u?u:c,error:m,mutate:()=>Promise.resolve(void 0)}}function D(e){return Array.isArray(e)?e:e instanceof Function?D(e()):[e]}async function _(e,t){try{return e?await j(e,t):null}catch(e){console.error(e)}return null}async function j(e,t){return(await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}})).json()}const L=[];function $(){const{data:e}=A("/api/v1/regions",j);return e||L}const O=()=>({open:(e,t={})=>b.fire("dialog",{type:"open",dialog:e,...t}),close:()=>b.fire("dialog",{type:"close"}),closeAll:()=>b.fire("dialog",{type:"close",all:!0})}),E=e=>Boolean(e?.includes(":")),F=(e,t)=>Boolean(e&&!E(e)&&(!t||"_self"===t)),U=e=>(e||"").replace(/\?.*/,"").replace(/\/$/,""),H=(...e)=>e.filter(Boolean).join("/").replace(/\/+/g,"/");var W=Object.freeze({__proto__:null,isURL:E,isLocalURL:F,isHash:e=>Boolean(e?.startsWith("#")),withoutQuery:U,joinPath:H});const X=e=>(t,l=d.BASE_PATH)=>{if(!t||E(t)||K(t,d.CDN))return t;const n=t.startsWith("/");return H(K(t,l)?"":l,n?"/":e.pathname?.split("/").slice(0,-1).join("/"),t)},K=(e,t)=>t&&e&&e.startsWith(t),Y=(e,t)=>Y._impl(e,t);function G(){return G._impl()}function q(e={}){const{isRemote:t,basePath:l}=e,n=G(),{closeAll:a}=O();return e=>({...e,href:t&&!l?e.href:X(n)(e.href,l),"aria-label":e.text,onClick:Y(i(e),e)});function i({href:e,target:l,onClick:i}){return r=>{i&&i(r),e&&!t&&F(e,l)&&(a(),r?.preventDefault(),n.push(e))}}}Y._impl=e=>e,Y.setup=e=>{Y._impl=e},G._impl=()=>({isReady:!1,href:globalThis.location?.href||"/",pathname:globalThis.location?.pathname||"/",query:{},push:()=>{},replace:()=>{},back:()=>{}}),G.setup=e=>{G._impl=e};const J={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active",white:"text-primary-main bg-white hover:text-white hover:bg-primary-hover active:bg-white active:text-primary-main",link:"text-primary-main",transparent:"",gray:"text-primary-main bg-main-divider hover:text-white hover:bg-primary-hover active:bg-primary-active","":""},Z="bg-main-divider text-main-disabled",Q={primary:Z,secondary:Z,white:Z,link:"",transparent:"",gray:Z,"":""},ee="text-center font-sans select-none",te={primary:"group-hover/btn:brightness-0 group-hover/btn:invert",secondary:"group-hover/btn:brightness-0 group-hover/btn:invert",white:"group-hover/btn:brightness-0 group-hover/btn:invert",link:"text-primary-main",transparent:"",gray:"group-hover/btn:brightness-0 group-hover/btn:invert","":""},le=x((e=>{const{text:t,aboveText:l,appendLeft:n,appendRight:a,version:i="primary"}=e,r=ae(e)?"hidden lg:block":"";return p("div",{className:w(ne(e),"flex gap-xs"),children:[n?u("div",{className:w(r,te[i]),children:n}):null,ae(e)?p("div",{className:"whitespace-pre",children:[l?u("div",{className:"text-xs font-light text-left",children:l}):null,u("div",{className:"text-left "+(l?"text-s -mt-3xs":"text-l"),children:t})]}):null,a?u("div",{className:w(r,te[i]),children:a}):null]})})),ne=e=>{const{version:t,aboveText:l,rounded:n}=e;if("link"===t)return"";const a=""+(l?"py-2.5 px-9":"py-4 px-9");return w("group/btn items-center justify-center",ae(e)?a:"h-12 w-12 m-auto",n?"rounded-full":"")},ae=({text:e,aboveText:t,appendLeft:l})=>Boolean(e||t||!l),ie=({className:e,rounded:t,version:l})=>["inline-block",ee,l?Q[l]:"",t?"rounded-full":"rounded-md",e].join(" "),re=({className:e,rounded:t,version:l})=>[ee,"border border-transparent inline-block cursor-pointer no-underline focus:border-primary-text focus:border h-fit",l?J[l]:"",t?"rounded-full":"rounded-md",e].join(" "),se=x((({disabled:e,children:t,...l})=>{const n=q()(l),a=t??u(le,{...n});return u(e?ce:oe,{...n,children:a})})),oe=x((({className:e="",href:t,rel:l,target:n,ariaLabel:a,version:i,rounded:r,onClick:s,children:o})=>u("a",{className:re({className:e,version:i,rounded:r}),href:t,rel:l,target:n,"aria-label":a,role:t?"link":"button",onClick:s,children:o}))),ce=x((({className:e,ariaLabel:t,version:l,rounded:n,children:a})=>u("div",{role:"button","aria-disabled":"true","aria-label":t,tabIndex:-1,className:ie({className:e,rounded:n,version:l}),children:a}))),de=x((({children:e,...t})=>u("p",{className:w("font-sans",Object.values(t)),children:e}))),me=x((({children:e,...t})=>u("span",{className:w("font-sans",Object.values(t)),children:e}))),he=x((({text:e,link:t})=>p(de,{size:"text-s",font:"font-light",color:"text-secondary-text",children:[u(me,{children:e||"Нажимая кнопку, вы подтверждаете согласие с "}),t?u(se,{href:t.href,ariaLabel:"условия передачи данных",target:t.target,className:"text-primary-main",children:u(me,{children:t.text})}):null]}))),ue=(e,t)=>{const{value:l,isDirty:n}=e,a=n?t(l):[];return{...e,errors:a,error:a[0]}},pe=x((({key:e,className:t="",inputClassName:l="",id:n,name:r,type:o="text",label:c,placeholder:d,value:m="",valid:h=!0,children:x,onChange:g,onFocus:f,onBlur:b,pattern:y,autoFocus:v=!1})=>{const N=s(null),k=i((e=>{g&&g(e.target?.value||"")}),[g]);a((()=>{v&&N.current?.focus()}),[v,N]);const C=x?"pr-3xl":"",S=h?"border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text":"border-error";return p("div",{className:w("relative",t),children:[p("label",{children:[c?u("div",{className:"mb-xs",children:u(me,{size:"text-m",font:"font-light",children:c})}):null,u("input",{ref:N,className:w("w-full h-14 border rounded-md text-primary-text outline-none p-m",C,S,l),id:n,name:r||n,placeholder:d,type:o,value:m,onInput:k,onFocus:f,onBlur:b,pattern:y},e)]}),x]})})),xe=x((({className:e,label:t,value:l="",error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(pe,{type:"text","aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:n}):null})]}))),ge=e=>"_"===e,fe=e=>/\d/.test(e),be=e=>ge(e)||fe(e),ye=[..."+7 (___) ___-__-__"],ve=ye.findIndex(ge),Ne=ye.map(((e,t)=>be(e)?ye.slice(0,t).filter(be).length:-1));const we=x((({children:e,onChange:t,...l})=>{const n=i((e=>t&&t(function(e){const t=e.replace(/\D/g,""),l=ye.map(((e,l)=>fe(e)?e:t.charAt(Ne[l])||e)),n=Ne.indexOf(t.length-1)+1;return(n?l.slice(0,Math.max(ve,n)):l).join("")}(e))),[t]);return u(pe,{onChange:n,onFocus:e=>n(e?.target?.value||""),...l,children:e})})),ke=x((({className:e,label:t,value:l,error:n,onChange:a,onBlur:i})=>p("div",{className:e,children:[u(we,{"aria-label":t,label:t,valid:Boolean(!n),value:l,onChange:a,onBlur:i,placeholder:"+7 (___) ___-__-__"}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:n}):null})]}))),Ce="Некорректно заполненное поле",Se=R((e=>null!=e&&""!==e))(Ce),Ie=R((e=>"string"==typeof e&&e.length>1))(Ce),Te=R((e=>"string"==typeof e&&(10===e.length||12===e.length)))(Ce),Be=(Me=/^(\+7)?[\s-]?\(?[0-9]{3}\)?[\s-]?[0-9]{3}[\s-]?[0-9]{2}[\s-]?[0-9]{2}$/,R((e=>"string"==typeof e&&Me.test(e))))(Ce);var Me;const Pe=e=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)})]})]}),Re=[{name:"Торговый эквайринг"},{name:"Мобильный эквайринг"},{name:"Интернет-эквайринг"},{name:"QR-эквайринг (СБП)"},{name:"Все виды эквайринга"}];function Ve(e=!1){const[t,l]=n(e),a=i((()=>l(!0)),[]),r=i((()=>l(!1)),[]),s=i((()=>l((e=>!e))),[]);return[t,{setValue:l,setTrue:a,setFalse:r,toggle:s}]}const ze={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},Ae=x((({className:e="",imageClassName:t="",name:l="",alt:n=`Иконка ${l}`,title:a=n,iconVersion:i="color",width:r,height:s})=>{const o=G(),c=X(o)(H(d.CDN,"/icons",`${l}.svg`));return"normal"!==i?u(je,{className:e,children:p("svg",{className:w(_e(r),ze[i],"white"===i?"invert":"",t),width:r,height:s,"aria-hidden":"true",children:[a?u("title",{children:a}):null,n?u("desc",{children:n}):null,u("use",{href:`${c}#icon`,xlinkHref:`${c}#icon`})]})}):u("img",{className:e,src:c,alt:n,title:a,"aria-hidden":"true",width:r,height:s,style:De(e,s)})})),De=(e,t)=>{return e?.includes("h-")?{}:{height:(l=t,l&&!/\D/.test(l)?`${t}px`:t),width:"auto"};var l},_e=e=>e?"":"w-full h-full",je=x((({className:e,children:t})=>e?u("div",{className:e,children:t}):t)),Le=e=>e?.text||e?.key||"";function $e(e,t,l,n){a((()=>{if(e&&l)return e.addEventListener(t,l,n),()=>{e.removeEventListener(t,l,n)}}),[e,t,l])}function Oe(e){const t=s(null),l=i((l=>{t&&t.current&&l.target instanceof Node&&!t.current.contains(l.target)&&e()}),[e]);return $e(globalThis.document,"click",l),t}const Ee=(e,t)=>e?.length&&t?.trim()?e.filter((e=>e.text?.toLocaleLowerCase().includes(t?.trim().toLocaleLowerCase()))):e,Fe=x((({popupRef:e,options:t,value:l,query:n,onChange:a})=>t?.length?u("div",{className:"bg-white text-l max-h-64 overflow-y-auto overflow-x-hidden rounded-md",role:"listbox",ref:e,children:Ee(t,n).map((e=>p("div",{className:"flex px-m py-s cursor-pointer hover:bg-main-divider pr-5xl relative",role:"option","aria-selected":e.key===l?.key,onClick:t=>{t.stopPropagation(),a&&a(e)},children:[u("span",{className:"min-h-6",children:Le(e)}),u(Ae,{name:"DoneSimpleIcon",width:"16",height:"16",className:w("absolute right-4 pt-3xs",e.key===l?.key?"":"hidden")})]},e.key)))}):null));function Ue({isOpen:e,options:t,value:l,query:n,onChange:r,onClose:o}){const c={open:(e,t)=>b.fire("popup",{type:"open",popup:e,...t}),update:(e,t)=>b.fire("popup",{type:"update",popup:e,...t}),close:()=>b.fire("popup",{type:"close"})},d=i((()=>{c.close(),o&&o()}),[o]),m=i((e=>{d(),r&&r(e)}),[d,r]),h=s(null),p=Oe(d);return a((()=>{if(!e||!h.current)return;const a=h.current,{top:i,left:r,width:s,height:o}=a.getBoundingClientRect();c.update(u(Fe,{popupRef:p,options:t,value:l,query:n,onChange:m}),{top:i+window.scrollY+o,left:r,width:s})}),[e,t,l,n,m]),h}const He=x((({className:e,label:t,options:l=[],value:a,valid:r=!0,isBorder:s=!0,placeholder:o="",isSearch:c=!1,iconVersion:d,onChange:m})=>{const[h,{setFalse:x,setTrue:g}]=Ve(),[f,b]=n(""),y=i((()=>{b(""),x()}),[]),v=Ue({isOpen:h,options:l,value:a,query:f,onChange:m,onClose:y});return p("div",{className:e,children:[We(t),p("div",{className:w("relative",h?"z-20":"z-10"),ref:v,children:[p("div",{className:w("h-14 text-l flex justify-between items-center text-primary-text cursor-pointer relative z-10",Ke(s,r)),onClick:h?y:g,children:[u("p",{className:"p-m pr-3xl flex items-center overflow-hidden text-ellipsis whitespace-nowrap",children:Le(a)||o}),Xe(h,d)]}),c&&h?u("div",{className:w("absolute top-0 w-full z-20"),children:u(pe,{type:"text",autoFocus:!0,value:f,onChange:b})}):null]})]})})),We=e=>e?u("div",{className:"mb-xs",children:u(me,{size:"text-m",color:"text-primary-text",font:"font-light",children:e})}):null,Xe=(e,t)=>u(Ae,{className:w("absolute right-3",e?"":"rotate-180"),iconVersion:t,name:"ArrowUpIcon",width:"16",height:"16"}),Ke=(e,t)=>w(e?"border rounded-md hover:border-primary-hover":"",t?" border-gray":"border-error"),Ye=x((({className:e="",error:t,...l})=>p("div",{className:e,children:[u(He,{...l,valid:!t}),u("div",{className:"h-2",children:t?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:t}):null})]}))),Ge=({regions:e,field:t})=>p("div",{className:"border-b border-b-main-divider @xl:border-none @xl:flex @xl:justify-between gap-lg ",children:[u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Вид эквайринга",placeholder:"Выберите эквайринг",options:Re.map((({name:e=""})=>({key:e,text:e}))),...ue(t("acquiringType"),Se)})}),u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Адрес",placeholder:"Выберите адрес",options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)})})]}),qe=x((({value:e=!1,text:t,type:l="checkbox",onChange:n})=>p("div",{role:l,"aria-checked":e,className:"flex justify-start items-center w-full cursor-pointer mb-s",onClick:()=>n&&n(!e),children:[u("div",{className:w("relative flex-shrink-0 duration-300 w-9 h-5 mr-s rounded-2xl",e?"bg-primary-main":"bg-main-divider"),children:u("div",{className:w("absolute opacity-80 duration-500 top-0.5 w-4 h-4 bg-white rounded-full",e?"left-1/2":"left-[5%]")})}),u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:t})]}))),Je=e=>p("div",{children:[u(qe,{text:"Хочу купить онлайн-кассу",...e("onlineCheckout")}),u(qe,{text:"Хочу купить POS-терминал",...e("posTerminal")})]}),Ze=(e,t)=>{const l=re({className:"text-white",version:e?.version});return u("button",{type:"submit",className:w("p-m w-full @xl:w-auto",l,t),children:e?.text?e.text:"Отправить заявку"})},Qe={acquiringType:{key:"Торговый эквайринг"},fullName:"",inn:"",name:"",phone:"",onlineCheckout:!1,posTerminal:!1},et=M({acquiringType:Se,region:Se,fullName:Se,inn:Te,name:Ie,phone:Be}),tt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{acquiringType:t,region:l,fullName:a,inn:i,name:r,phone:s,onlineCheckout:o,posTerminal:c}=e;P(et(e))&&n({typeForm:"acqr",region:l?.text||"",partnerComments:`Вид эквайринга=${t?.key||""}/Онлайн касса=${o}/POS-терминал=${c}`,fullName:a,inn:i,name:r,phone:s.replace(/[^+\d]/g,"")})}),[n]),[,{field:r,...s}]=B(Qe,a),o=$();return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Вид эквайринга и регион",className:"@xl:text-center"}),Ge({regions:o,field:r}),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),Pe(r),Je(r),Ze(t),u(he,{link:l})]})})),lt=e=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)}),u(xe,{className:"shrink-0 w-full",label:"Электронная почта",...ue(e("mail"),Se)})]})]}),nt=({regions:e,field:t})=>u(Ye,{className:"w-full",label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(t("region"),Se)}),at={name:"",phone:"",inn:"",mail:""},it=M({region:Se,name:Ie,phone:Be,inn:Te,mail:Se}),rt=x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{region:t,name:l,phone:a,inn:i,mail:r}=e;P(it(e))&&n({typeForm:"bcrd",region:t?.text||"",name:l,inn:i,mail:r,phone:a.replace(/[^+\d]/g,"")})}),[n]),[,{field:r,...s}]=B(at,a),o=$();return p("form",{className:"container space-y-s",onSubmit:s.onSubmit,children:[nt({regions:o,field:r}),lt(r),Ze(t),u(he,{link:l})]})})),st=[];const ot=async e=>await _(e,{method:"GET"})||st,ct=["От 1 000 ₽","До 1 000 000 000 ₽"],dt=["От 1 мес","До 15 лет"],mt=e=>p("div",{className:"pb-2xs border-b border-b-main-divider @xl:flex @xl:justify-between @xl:gap-lg @xl:border-none @xl:pb-0",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"shrink-0 w-full",label:"ИНН",...ue(e("inn"),Te)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Годовая выручка, ₽",...ue(e("annualRevenue"),Se)}),u(xe,{className:"shrink-0 w-full",label:"Контактное лицо",...ue(e("name"),Ie)}),u(xe,{className:"shrink-0 w-full",label:"Электронная почта",...e("mail")})]})]}),ht=(e,{normalize:t,format:l})=>{const{value:a,onFocus:r,onBlur:s,onChange:o}=e,[c,d]=n(!1),m=i((e=>{d(!0),r&&r(e)}),[]),h=i((()=>{d(!1),o&&o(t(a)),s&&s()}),[o,a]);return{value:c||!l?a:l(a),onFocus:m,onBlur:h}},ut=(e,t,l)=>Math.max(t,Math.min(e,l)),pt=(e=0)=>(t=0)=>new Intl.NumberFormat("ru-RU",{minimumFractionDigits:0,maximumFractionDigits:e}).format(Number(t)||0);function xt(e){const t=(e||"").replace(/\D/g,""),l=parseInt(t,10);return Number.isNaN(l)?0:l}function gt({list:e=[],min:t,max:l,step:n,value:a=e[0]||t,disabled:i,onChange:r}){const s=e.length?e.indexOf(a):a,o={backgroundSize:`${(100*(s>t?s-t:0)/(l-t)).toFixed(2)}% 100%`};return p("div",{children:[e.length?u("div",{className:"absolute w-full flex justify-between -bottom-[3px] px-m",children:e.map(((e,t)=>u("div",{className:w("w-2 h-2 rounded-full",s<=t||i?"bg-gray":"bg-primary-main")},String(t))))}):null,u("div",{className:"absolute inset-x-0 -bottom-1 px-m leading-[18px]",children:u("input",{className:"box-border w-full m-0 cursor-pointer slider relative z-10",style:o,type:"range",min:t,max:l,step:n,value:s,disabled:i,onInput:t=>{const l=xt(t.target?.value),n=e.length?e[l]:l;r&&r(n||0)}})})]})}const ft=1,bt=100,yt=x((e=>{const{className:t,title:l,items:n=[],list:a=[],min:r=(a.length?0:ft),max:s=(a.length?a.length-1:bt),step:o=1,value:c=a[0]||r,disabled:d=!1,onChange:m}=e,h=ht(e,{normalize:(e=0)=>a.length?vt(a)(e):ut(e,r,s),format:pt()}),x=i((e=>{m&&m(xt(e.target?.value))}),[m]);return p("div",{className:t,children:[p("label",{className:"block relative",children:[l?u(me,{size:"text-m",font:"font-light",color:"text-primary-text",children:l}):null,u("input",{className:w("mt-xs font-sans text-h3 w-full h-14","border border-solid border-gray rounded-md outline-none","pl-m box-border","text-primary-text hover:border-primary-hover focus:border-primary-text","disabled:border-gray disabled:bg-main-divider"),disabled:d,onInput:x,...h}),gt({list:a,min:r,max:s,step:o,disabled:d,value:c,onChange:m})]}),Nt(n)]})})),vt=e=>t=>e.reduce(((e,l)=>Math.abs(l-t)<Math.abs(e-t)?l:e)),Nt=e=>u("div",{className:"flex justify-between my-xs",children:e.map(((e,t)=>u(me,{size:"text-s",font:"font-light",color:"text-secondary-text",children:e},String(t))))}),wt=e=>p("div",{className:"border-b border-b-main-divider @xl:border-none @xl:flex @xl:justify-between gap-lg",children:[p("div",{className:"@xl:w-1/2",children:[u("label",{children:u(me,{size:"text-m",font:"font-light",children:"Сумма, ₽"})}),u(yt,{items:ct,min:1e3,max:1e9,...e("amount")})]}),p("div",{className:"@xl:w-1/2",children:[u("label",{children:u(me,{size:"text-m",font:"font-light",children:"Срок, месяцев"})}),u(yt,{items:dt,min:1,max:180,...e("term")})]})]}),kt=({regions:e,branches:t,field:l})=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg @xl:mb-2xl @xl:border-none @xl:pb-0",children:[u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:e.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(l("region"),Se)})}),u("div",{className:"@xl:w-1/2",children:u(Ye,{label:"Адрес",placeholder:"Выберите адрес",options:t.map((({branchCode:e="",address:t=""})=>({key:e,text:t}))),...ue(l("department"),Se)})})]}),Ct={amount:1e3,term:12,fullName:"",inn:"",name:"",phone:"",mail:"",annualRevenue:""},St=M({fullName:Se,annualRevenue:Se,inn:Te,name:Ie,phone:Be,region:Se,department:Se}),It=x((({button:e,link:t,onSubmit:l})=>{const n=i((e=>{const{amount:t,term:n,fullName:a,inn:i,name:r,phone:s,mail:o,region:c,department:d,annualRevenue:m}=e;P(St(e))&&l({typeForm:"cred",fullName:a,inn:i,name:r,phone:s.replace(/[^+\d]/g,""),mail:o,region:c?.text||"",department:d?.text||"",partnerComments:`Сумма=${t}/Срок=${n}/Выручка=${m}`})}),[l]),[a,{field:r,...s}]=B(Ct,n),o=$(),c=function(e){const{data:t}=A(e?`/api/v1/branches?regionCode=${e}`:null,ot);return t||st}(a.region?.key).filter((e=>e?.address));return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[u(I,{headingType:"h6",title:"Параметры",className:"@xl:text-center"}),wt(r),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),mt(r),u(I,{headingType:"h6",title:"Офис банка",className:"@xl:text-center"}),kt({regions:o,branches:c,field:r}),Ze(e),u(he,{link:t})]})})),Tt={name:"",phone:""},Bt=M({name:Ie,phone:Be}),Mt=x((({button:e,link:t,onSubmit:l})=>{const n=i((e=>{const{name:t,phone:n}=e;P(Bt(e))&&l({typeForm:"dpst",name:t,phone:n.replace(/[^+\d]/g,"")})}),[l]),[,{field:a,...r}]=B(Tt,n);return p("form",{className:"container",onSubmit:r.onSubmit,children:[u(I,{headingType:"h6",title:"Оставьте заявку и мы ответим на любые вопросы по депозитам",className:"@xl:text-center mb-m"}),p("div",{className:"max-w-[560px] m-auto space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Имя",...ue(a("name"),Ie)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(a("phone"),Be)})]}),p("div",{className:"flex justify-between flex-col-reverse @xl:items-center @xl:flex-row max-w-[560px] m-auto",children:[u("div",{className:"flex-1",children:u(he,{link:t})}),Ze(e)]})]})})),Pt={},Rt="wcms-resources";function Vt(e,t={}){const{fallback:l=Pt,folderName:n=Rt,setBasePath:a=!1}=t,i=H("/",a?d.BASE_PATH:"",n,`${e}.json`),{data:r}=A(e?i:null,j,{fallback:l});return r||Pt}const zt=x((e=>{const{button:t,sourceBookDir:l}=e,{regions:a}=Vt(l||"regions-grant-support"),[i,r]=n({key:""}),s=re({className:"text-white",version:t?.version}),o=a?.find((e=>e.name===i.key))?.href;return p("div",{className:"container space-y-s @xl:space-y-lg",children:[a?u(Ye,{label:"Ваш регион",placeholder:"Выберите регион",isSearch:!0,options:a.map((({name:e=""})=>({key:e,text:e}))),value:i,onChange:r}):null,o?u("div",{className:"text-center",children:u(se,{href:o,target:"_blank",className:w("p-m w-full @xl:w-auto",s),children:t?.text?t.text:"Перейти"})}):null]})})),At=x((({className:e,viewBox:t,fill:l="none",width:n,height:a,paths:i,...r})=>u("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:l,width:n,height:a,children:i.map((({d:e,fill:t,...l},n)=>u("path",{d:e,fill:t||"currentColor",...r,...l},n)))}))),Dt=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],_t=x((({className:e,value:t,text:l,disabled:n,isRadio:a,onChange:r})=>{const s=i((e=>{n||(e.preventDefault(),r&&r(!t))}),[r,n,t]),o=a?u("div",{className:"absolute left-1 w-3 h-3 rounded-full bg-primary-main"}):u(At,{paths:Dt,className:"absolute left-1 ml-px block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"});return u("div",{className:e,children:p("label",{className:"flex items-center relative cursor-pointer group/box",onClick:s,children:[u("div",{className:w("appearance-none w-5 h-5 border-solid cursor-pointer m-0",a?"rounded-full border-2":jt(t),t?"border-primary-main":"border-gray",n?"bg-main-disabled":"group-hover/box:border-primary-hover"),role:"checkbox","aria-checked":Boolean(t),"aria-disabled":Boolean(n)}),t?o:null,l?u("div",{className:"ml-s",children:u(me,{size:"text-l",font:"font-light",children:l})}):null]})})})),jt=e=>w("rounded border",e?"bg-primary-main":""),Lt=(e,t=!1)=>{if("string"==typeof e)return e.split("-").reverse().join(".");{const l=String(e.getDate()).padStart(2,"0"),n=String(e.getMonth()+1).padStart(2,"0"),a=t?String(e.getFullYear()):String(e.getFullYear()).slice(-2);return t?`${a}-${n}-${l}`:`${l}.${n}.${a}`}},$t=()=>{},Ot=({today:e,firstDayOfWeek:t,totalDays:l,currentMonth:n,currentYear:a,min:i,max:r,onDateClick:s})=>{const o=[];let c=1;for(let d=0;d<6;d++){const m=[];for(let o=0;o<7;o++)if(0===d&&o<t)m.push(u("td",{},`empty-${o}`));else if(c>l)m.push(u("td",{},`empty-${o}`));else{const t=new Date(a,n,c),l=Et(t,e),o=Ft(t,i,r);m.push(u("td",{children:u("div",{className:Ut(l,o),onClick:()=>!o&&s(t),children:c})},`day-${c}`)),c++}o.push(u("tr",{children:m},`row-${d}`))}return o},Et=(e,t)=>t&&e.toDateString()===t.toDateString(),Ft=(e,t,l)=>t&&e.getTime()<t.getTime()||l&&e.getTime()>l.getTime(),Ut=(e,t)=>w("p-s text-center rounded-md border",e?"":"border-transparent hover:bg-gray",t?"text-gray hover:bg-transparent":"cursor-pointer"),Ht=["Пн","Вт","Ср","Чт","Пт","Сб","Вс"],Wt=x((({today:e,currentMonth:t,currentYear:l,min:n,max:a,onDateSelect:s=$t})=>{const o=i((e=>s(e)),[]),{firstDayOfWeek:c,totalDays:d}=r((()=>({firstDayOfWeek:new Date(l,t,1).getDay()-1,totalDays:new Date(l,t+1,0).getDate()})),[l,t]);return p("table",{className:"mx-auto",children:[u("thead",{className:"text-gray font-light",children:u("tr",{children:Ht.map(((e,t)=>u("th",{className:"p-s",children:e},String(t))))})}),u("tbody",{children:Ot({firstDayOfWeek:c,today:e,totalDays:d,currentYear:l,currentMonth:t,min:n,max:a,onDateClick:o})})]})})),Xt=["Январь","Февраль","Март","Апрель","Май","Июнь","Июль","Август","Сентябрь","Октябрь","Ноябрь","Декабрь"],Kt=Xt.map((e=>({key:e}))),Yt=Array.from({length:(new Date).getFullYear()-1940+1},((e,t)=>1940+t)).reverse().map((e=>({key:String(e)}))),Gt={name:"ArrowUpIcon",iconVersion:"black",width:"24",height:"24"},qt={className:"min-w-32",iconVersion:"black",isBorder:!1},Jt=x((({className:e="",label:t="",value:l,valid:a=!0,minDate:r,maxDate:s,onChange:o})=>{const[c,{setValue:d}]=Ve(!1),[m,h]=n(l?.getMonth()||(new Date).getMonth()),[x,g]=n(l?.getFullYear()||(new Date).getFullYear()),{handlePrevMonth:f,handleNextMonth:b,handleSelectMonth:y,handleSelectYear:v,monthsOptions:N,yearsOptions:k,handleChangeVisibleCalendar:C,ref:S}=(({onShowCalendar:e,showCalendar:t,selectedMonth:l,onMonthSelect:n,onYearSelect:a,selectedYear:r})=>{const s=Oe(i((()=>t&&e(!1)),[t]));return{handleChangeVisibleCalendar:i((()=>e(!t)),[t]),handleNextMonth:i((()=>{l+1<=11?n(l+1):(n(0),a(r+1))}),[l]),handlePrevMonth:i((()=>{l-1>=0?n(l-1):(n(11),a(r-1))}),[l]),handleSelectMonth:i((({key:e})=>n(Xt.indexOf(e))),[]),handleSelectYear:i((({key:e})=>a(Number(e))),[]),monthsOptions:Kt,yearsOptions:Yt,ref:s}})({onYearSelect:g,onMonthSelect:h,onShowCalendar:d,selectedYear:x,selectedMonth:m,showCalendar:c});return p("div",{className:w(e,"relative"),ref:S,children:[u(me,{size:"text-m",children:t}),Zt(C,l,a),c?p("div",{className:"absolute bg-white z-10 select-none",children:[p("div",{className:"flex gap-s",children:[u("div",{className:"my-auto",onClick:f,children:u(Ae,{...Gt,className:"-rotate-90 cursor-pointer"})}),u(He,{onChange:y,value:{key:Xt[m]},options:N,...qt}),u(He,{onChange:v,value:{key:String(x)},options:k,...qt}),u("div",{className:"my-auto",onClick:b,children:u(Ae,{...Gt,className:"rotate-90 cursor-pointer"})})]}),u(Wt,{today:l,currentMonth:m,currentYear:x,onDateSelect:o,min:r,max:s})]}):null]})})),Zt=(e,t,l)=>p("div",{onClick:e,className:w("flex justify-between items-center h-14 px-m py-s border rounded-md cursor-pointer hover:border-black active:border-black focus:border-black",l?"border-gray":"border-error"),children:[u(de,{children:t&&Lt(t)}),u(Ae,{...Gt,name:"CalendarIcon"})]}),Qt=x((({className:e,label:t,value:l,error:n,onChange:a})=>p("div",{className:e,children:[t?u("div",{className:"mb-xs",children:u(me,{size:"text-m",font:"font-light",children:t})}):null,u(Jt,{value:l,onChange:a,valid:Boolean(!n)}),u("div",{className:"h-2",children:n?u(me,{size:"text-xs",font:"font-light",color:"text-error",children:n}):null})]}))),el=e=>p("div",{className:"@xl:flex @xl:justify-between @xl:gap-lg",children:[p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Фамилия",...ue(e("surname"),Ie)}),u(xe,{className:"shrink-0 w-full",label:"Отчество",...ue(e("middleName"),Ie)}),u(ke,{className:"shrink-0 w-full",label:"Телефон",...ue(e("phone"),Be)})]}),p("div",{className:"@xl:w-1/2 space-y-s",children:[u(xe,{className:"shrink-0 w-full",label:"Имя",...ue(e("name"),Ie)}),u(Qt,{className:"shrink-0 w-full",label:"Дата рождения",...ue(e("date"),Se)}),u(xe,{className:"shrink-0 w-full",label:"Электронная почта",...ue(e("mail"),Se)})]})]}),tl={surname:"",name:"",middleName:"",phone:"",mail:"",date:void 0,consentDataProcessing:!0},ll=M({surname:Ie,name:Ie,middleName:Ie,phone:Be,mail:Se,date:Se}),nl=x((e=>{const{button:t,link:l,product:n,onSubmit:a}=e,r=i((e=>{const{surname:t,name:l,middleName:i,phone:r,mail:s,date:o,consentDataProcessing:c}=e;P(ll(e))&&a({typeForm:"dpst",surname:t,name:l,middleName:i,mail:s,consentDataProcessing:c,phone:r.replace(/[^+\d]/g,""),date:o?.toISOString().slice(0,10)||"",product:n||""},!0)}),[a]),[,{field:s,...o}]=B(tl,r);return p("form",{className:"container space-y-s",onSubmit:o.onSubmit,children:[el(s),p("div",{className:"@xl:flex justify-between items-center",children:[p("div",{className:"@xl:mb-0 mb-2 flex items-center gap-3",children:[u(_t,{...ue(s("consentDataProcessing"),Se)}),u(he,{text:"Согласен с ",link:l})]}),Ze(t)]})]})})),al=(e,t)=>e?.media&&t?.media?e.media-t.media:0,il=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n})=>{const a=G();return p("picture",{className:e,children:[t?.sources?.length?t.sources.filter((e=>e?.src)).sort(al).map((({src:e,format:l,media:i},r)=>u("source",{srcSet:sl(a,n)(e),type:ol(l),media:i?`(max-width: ${i}px)`:"",...t.size},`${r}_${e}`))):null,t?.src?rl({...t,src:sl(a,n)(t.src)},l):null]})})),rl=(e,t="")=>u("img",{src:e.src,className:w("object-contain",t),alt:e.alt||e.title,title:e.title||"",style:{width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"auto"},...e.size}),sl=(e,t)=>l=>l&&!E(l)?X(e)(H(t,l)):l,ol=e=>e?`image/${String(e)}`:void 0,cl=x((({className:e="",image:t,imageClassName:l="",pathPrefix:n,...a})=>t?.src||t?.icon?t.icon?u(Ae,{className:e,imageClassName:l,iconVersion:t?.iconVersion,name:t.icon,...a}):u(il,{className:e,imageClassName:l,image:t,pathPrefix:n}):null)),dl=x((({name:e,text:t,value:l,checked:n,onChange:a,className:i})=>u("div",{className:i,children:p("label",{className:"font-sans flex gap-s items-center relative cursor-pointer",children:[u("input",{className:"appearance-none flex justify-center items-center shrink-0 w-5 h-5 border border-gray hover:border-primary-hover\n checked:border-2 checked:!border-primary-main focus:checked:border-primary-main focus:border-primary-text active:border-primary-text\n after:block after:w-2.5 after:h-2.5 after:rounded-full checked:after:bg-primary-main outline-none rounded-full cursor-pointer",type:"radio",value:l,name:e,checked:n,onChange:e=>a(e.target.value)}),t?u(me,{color:"text-primary-text",children:t}):null]})}))),ml=e=>{const{value:t,onChange:l}=e("vedTypes");return u("div",{className:"space-y-m",children:p("div",{className:"@xl:flex @xl:items-center @xl:gap-xl",children:[u(dl,{className:"mb-xs",name:"vedTypes",text:"Валютный котроль",value:"currencyControl",checked:"currencyControl"===t,onChange:e=>l&&l(e)}),u(dl,{className:"mb-xs",name:"vedTypes",text:"Документарные операции",value:"documentOperations",checked:"documentOperations"===t,onChange:e=>l&&l(e)}),u(dl,{className:"mb-xs",name:"vedTypes",text:"Конверсионные операции",value:"conversionTransactions",checked:"conversionTransactions"===t,onChange:e=>l&&l(e)}),u(dl,{className:"mb-xs",name:"vedTypes",text:"Иные вопросы ВЭД",value:"otherIssues",checked:"otherIssues"===t,onChange:e=>l&&l(e)})]})})},hl=(e,t)=>{const l="currencyControl"===e("vedTypes").value;return p("div",{children:[l?u(Ye,{className:"mb-s",label:"Филиал",placeholder:"Выберите филиал",isSearch:!0,options:t.map((({code:e="",name:t=""})=>({key:e,text:t}))),...ue(e("region"),Se)}):null,p("div",{className:"@xl:grid @xl:grid-cols-2 @xl:gap-x-lg",children:[l?u(xe,{className:"w-full mb-s",label:"ИНН",...ue(e("inn"),Te)}):null,u(xe,{className:"w-full mb-s",label:"Наименование организации",...ue(e("fullName"),Se)}),u(xe,{className:"w-full mb-s",label:"ФИО",...ue(e("name"),Ie)}),u(ke,{className:"w-full mb-s",label:"Телефон",...ue(e("phone"),Be)}),l?null:u(xe,{className:"w-full mb-s",label:"Электронная почта",...ue(e("mail"),Se)})]})]})},ul=e=>{const t=e("text");return p("label",{children:[u("div",{className:"mb-xs",children:u(me,{size:"text-m",font:"font-light",children:"Обращение"})}),u("textarea",{placeholder:"Укажите интересующий вас вопрос, место ведения бизнеса и удобное время для телефонного звонка",className:w("block w-full resize-y min-h-24 p-m outline-none border rounded-md border-gray","hover:border-primary-hover active:focus:border-primary-text focus:border-primary-text"),value:t.value,onInput:e=>t.onChange&&t.onChange(e.target?.value||"")})]})},pl={fullName:"",name:"",phone:"",inn:"",vedTypes:"currencyControl",text:""},xl={fullName:Se,name:Ie,phone:Be},gl=M({...xl,mail:Se}),fl=M({...xl,inn:Te,region:Se}),bl=e=>"currencyControl"===e,yl=e=>({currencyControl:"currencyControl"===e,documentOperations:"documentOperations"===e,conversionTransactions:"conversionTransactions"===e,otherIssues:"otherIssues"===e}),vl={ApplicationFormBusinessCard:rt,ApplicationFormWed:x((e=>{const{button:t,link:l,onSubmit:n}=e,a=i((e=>{const{fullName:t,name:l,phone:a,mail:i,inn:r,region:s,vedTypes:o,text:c}=e,d={typeForm:"KVED",fullName:t,name:l,phone:a.replace(/[^+\d]/g,""),text:c,vedTypes:yl(o),PartnerComments:c,...bl(o)?{inn:r,region:s?.text||""}:{mail:i}};P((e=>bl(e)?fl:gl)(o)(e))&&n(d)}),[n]),[,{field:r,...s}]=B(pl,a),o=$();return p("form",{className:"container space-y-m",onSubmit:s.onSubmit,children:[ml(r),u(I,{headingType:"h6",title:"Данные организации",className:"@xl:text-center"}),hl(r,o),ul(r),p("div",{className:"flex flex-col gap-m border-b border-main-divider pb-lg @xl:items-center @xl:flex-row @xl:pb-4xl",children:[Ze(t),u(he,{link:l})]}),u(I,{headingType:"h6",title:"Или свяжитесь с нами удобным способом",className:"@xl:text-center"}),p("div",{className:"flex gap-xl",children:[p("a",{className:"flex gap-s items-center text-primary-text no-underline",href:"tel:8 (800) 200-78-70","aria-label":"8 (800) 200-78-70",children:[u(cl,{image:{icon:"PhoneIcon"},width:"24",height:"24"}),u("span",{children:"8 (800) 200-78-70"})]}),p("a",{className:"flex gap-s items-center text-primary-text no-underline","aria-label":"ved@rshb.ru",href:"mailto:ved@rshb.ru",children:[u(cl,{image:{icon:"MailIcon"},width:"24",height:"24"}),u("span",{children:"ved@rshb.ru"})]})]})]})})),ApplicationFormDeposit:Mt,ApplicationFormCredit:It,ApplicationFormAcquiring:tt,ApplicationFormGrantSupport:zt,ApplicationFormIndividuals:nl},Nl=x((({responseType:e})=>{const t="OK"===e;return p("div",{className:`flex items-center p-lg rounded-md space-x-m ${t?"bg-ok":"bg-fail"}`,children:[u(cl,t?{image:{icon:"ResponseOKIcon"},width:"42",height:"42"}:{image:{icon:"ResponseFailIcon"},width:"37",height:"34"}),p("div",{children:[u(I,{headingType:"h6",title:t?"Ваша заявка отправлена":"Не удалось отправить заявку",className:"mb-2xs"}),u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:t?"Совсем скоро мы с вами свяжемся":"Пожалуйста, повторите позднее"})]})]})})),wl={send:async function(e,t){const l=t?"/api/v1/lead":"/api/v1/sendcorporatelead";try{const t=await fetch(l,{method:"POST",headers:{"Content-Type":"application/json"},mode:"cors",body:JSON.stringify(e)});return t?.ok?await t.json():null}catch(e){return null}}},kl=x((e=>{const{className:t,formBlock:l,...a}=e,[r,s]=n(""),o=i((async(e,t)=>{const l=await wl.send(e,t)?"OK":"Fail";return s(l),l}),[]);return u(C,{className:t,defaultPadding:"p-6xl",...a,children:p("div",{className:"container max-w-[978px] space-y-lg",children:[l?.title?u(I,{headingType:"h3",title:l.title,className:"@xl:text-center"}):null,l?Cl(l,o):null,r?u(Nl,{responseType:r}):null]})})})),Cl=(e,t)=>{const l=e?.formType;if(!l||!(l in vl))return null;return u(vl[l],{...e,onSubmit:t})},Sl="text-center",Il={"":"bg-main-divider group-data-secondary:bg-white/30",primary:"bg-main-divider",secondary:"bg-secondary-light",opacity:"bg-white/30"},Tl=x((({className:e,defaultIconSize:t=44,iconBgVersion:l="primary",size:n,icon:a,...i})=>{const r=String(n?.width||t);return a?u("div",{style:{width:`${r}px`,height:`${r}px`},className:w("rounded-icon object-fit flex justify-center items-center",Il[l],e),children:u(Ae,{...i,width:"54%",height:"54%",name:a})}):null})),Bl=x((({className:e="",title:t,benefitList:l,...n})=>p(C,{className:e,defaultPadding:"p-6xl",...n,children:[t?u(I,{headingType:"h3",as:"h2",className:Sl,title:t}):null,l?.length?u("div",{className:"flex flex-col @md:flex-row flex-wrap w-full @md:justify-center mt-xl gap-5xl",role:"list",children:l.map(Ml)}):null]}))),Ml=(e,t)=>p("div",{className:"flex gap-m items-center @md:basis-1/2 @md:max-w-[500px]",role:"listitem",children:[e?.icon?.icon?u(Tl,{className:"shrink-0",defaultIconSize:44,iconBgVersion:e?.iconBgVersion||"",...e?.icon}):null,e?.icon?.src?u(cl,{className:"shrink-0",image:e.icon}):null,e?.label?p("div",{className:"@sm:h-full",children:[u(I,{headingType:"h6",children:e.label}),Pl(e.description)]}):null]},String(t)),Pl=e=>{const t=e?.benefitType||null;return e&&t?u("div",{className:"mt-xs text-l font-light text-secondary-text group-data-secondary:text-white/80",children:"list"===t?Vl(e):Rl(e)}):null},Rl=e=>e?.name?u(me,{size:"text-l",color:"text-secondary-text group-data-secondary:text-white/80",font:"font-light",children:e.name}):null,Vl=e=>{const t=e?.bullets?"list-disc pl-3xl":"";return e?.items&&e.items.length>0?u("ul",{className:t,children:e.items.map(((e,t)=>u("li",{children:u(me,{size:"text-l",color:"text-secondary-text group-data-secondary:text-white/80",font:"font-light",children:e})},`benefitListItem-${t}`)))}):null},zl=e=>Boolean(e?.src||e?.icon),Al=(e,{className:t,buttonClassName:l,isVertical:n}={})=>e?.length&&e.some((e=>e?.text||e?.icon?.icon))?u("div",{className:w("flex",n?"flex-col gap-xs justify-items-stretch":"flex-wrap @xl:flex-nowrap gap-lg sm:gap-m",t),children:e.map(Dl(l))}):null,Dl=(e="")=>(t,l)=>{const{text:n,icon:a,iconRight:i,version:r,...s}=t||{},o=_l(a,r),c=_l(i,r);return n||a?.icon?u(se,{className:w("basis-full sm:basis-auto",e),appendLeft:jl({...a,iconVersion:o}),appendRight:jl({...i,iconVersion:c}),version:r,text:n,...s},l?String(l):""):null},_l=(e,t="secondary")=>{const l="secondary"===t?"color":"white";return e?.iconVersion?e?.iconVersion:l},jl=e=>zl(e)?u(cl,{image:e,width:String(e?.size?.width||24),height:String(24)}):null,Ll={XXL:{title:{headingType:"h0",as:"h1"},descriptionSize:"text-h5",descriptionWeight:"font-normal",descriptionStyle:"mt-xl"},XL:{title:{headingType:"h1",as:"h1"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-m"},L:{title:{headingType:"h2",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-m"},M:{title:{headingType:"h3",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-s"},S:{title:{headingType:"h4",as:"h2"},descriptionSize:"text-xl",descriptionWeight:"font-light",descriptionStyle:"mt-xs"},XS:{title:{headingType:"h5",as:"h2"},descriptionSize:"text-m",descriptionWeight:"font-light",descriptionStyle:"mt-xs"}},$l={H6:"text-h6",XL_L:"text-xl-light",XL_R:"text-xl",L_L:"text-l-light",L_R:"text-l",M:"text-m-light",S:"text-s-light",XS:"text-xs-light"},Ol=x((({className:e,version:t="",headlineVersion:l="XL",title:n,description:a,align:i="text-center",as:r,isEmbedded:s=!1,isTheme:o=!1,...c})=>{const d=Ll[l],m={marginTop:d.descriptionStyle};return p(C,{className:w(s?"@container-normal":"",e),defaultPadding:s?"":"p-6xl",version:t,isTheme:o,...c,children:[n?u(I,{className:w("whitespace-pre-wrap",i),...d?.title,as:r||d?.title.as,title:n}):null,a?u(de,{size:d.descriptionSize,font:d.descriptionWeight,align:i,...m,children:a}):null]})})),El=x((({className:e="",title:t,description:l,bonusItems:n=[],align:a=Sl,...i})=>u(C,{className:e,defaultPadding:"p-6xl",...i,children:p("div",{className:"container",children:[u(Ol,{className:"mb-xl",isEmbedded:!0,title:t,description:l,headlineVersion:"M",align:a}),u("div",{className:"flex flex-wrap gap-3xl gap-x-m w-full",children:n.length>0?n.map(((e,t)=>p("div",{className:"w-full @xl:w-[48%] sm:space-y-xs flex flex-col grow w-full p-xl sm:p-m border border-gray",children:[u("div",{className:"grow",children:u(Ol,{title:e?.title,description:e?.description,headlineVersion:"S",isEmbedded:!0,align:"text-left"})}),p("div",{className:"flex justify-center sm:justify-between sm:items-end",children:[u("div",{className:"hidden sm:block",children:Al(e?.buttons)}),e.bonusItemContent?.bonusType?Fl(e.bonusItemContent):null]})]},String(t)))):null})]})}))),Fl=e=>"count"===e.bonusType?Ul(e):Hl(e),Ul=e=>p("div",{className:"w-full pt-default @xl:mt-s @xl:mb-4 flex justify-center sm:justify-end items-end",children:[e.bonusCount?u("div",{className:"shrink-0 -mb-6 @xl:-mb-4",children:u("span",{className:"font-mohave text-title-large sm:text-title-extra gradient-color-text",children:e.bonusCount})}):null,e.bonusName?u("div",{className:"shrink-0 gradient-color-text",children:u(me,{size:"text-h2",children:e.bonusName})}):null]}),Hl=e=>e.image?u(cl,{className:"min-w-12 p-xs rounded-icon shrink-0",image:e.image}):null,Wl=e=>({icon:t,title:l,description:n},a)=>p("div",{className:w("flex flex-col gap-1","items-center",n||l?"":"justify-center"),children:[l?u(me,{size:"text-h6",font:"font-normal",align:e,children:l}):null,t?u(cl,{image:t,height:"180",className:"w-auto"}):null,n?u(me,{size:"text-h6",font:"font-normal",align:e,children:n}):null]},String(a)),Xl=(e,t,l)=>u("div",{className:`grid gap-2xs ${Kl(t)}`,children:e.map(Wl(l))}),Kl=e=>{switch(e){case"3":return"grid-cols-3";case"4":return"grid-cols-4";default:return"grid-cols-5"}},Yl=x((({bonusBenefits:e,cardTextAlign:t="text-center",className:l="",columnsCount:n="4",subtitle:a,title:i,...r})=>p(C,{className:l,defaultPadding:"p-6xl",...r,children:[u(Ol,{title:i,description:a,headlineVersion:"M"}),e?.length?Xl(e,n,t):null]}))),Gl=x((e=>{const{title:t,image:l,cardItems:n,button:a}=e;return p("div",{className:"border-gray border p-4xl w-1/2 space-y-lg",children:[l?p("div",{className:"flex justify-center",children:[l?.src?u(cl,{image:l}):null,l?.icon?u(cl,{image:l}):null]}):null,t?u(I,{headingType:"h4",title:t}):null,n?.length?u("ul",{className:"space-y-s",children:n.map(((e,t)=>ql(e,String(t))))}):null,Al([a])]})})),ql=(e,t)=>{const{icon:l,text:n}=e;return p("li",{className:"flex items-center gap-s",children:[l?.icon?u(cl,{image:l,className:"w-12 h-12 min-w-12 p-s rounded-icon bg-main-divider"}):null,l?.src?u(cl,{image:l}):null,u(me,{size:"text-xl",font:"font-light",children:n})]},t)},Jl=x((({className:e,title:t,cards:l,...n})=>p(C,{className:e,defaultPadding:"p-6xl space-y-3xl",...n,children:[u(I,{headingType:"h3",title:t,className:"text-center"}),u("div",{className:"flex gap-lg",children:l?.length?l.map(((e,t)=>u(Gl,{...e},String(t)))):null})]}))),Zl={start:"justify-start",center:"justify-center",end:"justify-end"},Ql=x((({buttons:e,className:t="",align:l,...n})=>{const a=l?w("flex",Zl[l]):"";return u(C,{className:w("!bg-transparent",a,t),defaultPadding:"p-0",...n,children:Al(e)})})),en=(e,t=0)=>{const{itemCount:l,visibleItemCount:a}=e,[r,s]=n(t),o=i((()=>s((e=>Math.min(e+1,l-1)))),[l]),c=i((()=>s((e=>Math.max(e-1,0)))),[l]),d=a?l>a&&r<l-a:r<l-1,m=r>0;return[r,{inc:o,dec:c,canInc:d,canDec:m,isScrollAvailable:m||d}]},tn=x((({className:e,disabled:t,...l})=>u(se,{rounded:!0,className:w("group/btn w-12 h-12 min-h-12 max-h-12 flex items-center justify-center shadow-main-black",t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main",e||""),disabled:t,...l,children:u(cl,{className:"w-4 h-4 min-w-4 min-h-4 rounded-full box-border",image:{icon:"ArrowLeftIcon",iconVersion:"black"},imageClassName:"group-hover/btn:text-primary-main",width:"16",height:"16"})}))),ln=x((e=>u(tn,{...e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left"}))),nn=x((e=>u(tn,{...e,className:`${e.className||""} rotate-180`,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right"})));function an({dec:e,inc:t,canDec:l,canInc:n,btnClass:a,className:i=""}){return l||n?p("div",{children:[l?u(tn,{className:`absolute z-40 ${a[0]} ${i}`,onClick:e,ariaLabel:"Пролистать влево","data-block-control":"scroll-left",disabled:!l}):null,n?u(tn,{className:`absolute z-40 rotate-180 ${a[1]} ${i}`,onClick:t,ariaLabel:"Пролистать вправо","data-block-control":"scroll-right",disabled:!n}):null]}):null}const rn=x((({title:e,value:t,postfix:l="",prefix:n,className:a=""})=>p("div",{className:w("flex justify-between @xl:flex-col",a),children:[e?u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:e}):null,u("div",t?{children:p(me,{size:"text-h3",children:[n," ",pt(2)(Math.round(t))," ",l]})}:{children:u(me,{size:"text-h3",children:"-"})})]}))),sn=Math.round(23.5),on={minSum:1e4,maxSum:5e6,minMonths:13,maxMonths:60,rate:0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,isInsurance:!0},cn={minSum:1e4,maxSum:3e6,minSumOld:0,maxSumOld:25e5,minSumExtra:0,maxSumExtra:5e5,minMonths:13,maxMonths:60,rate:0,isExtraMoney:!1,isSalaryClient:!1,isInsurance:!0},dn={minSumTravel:6e3,maxSumTravel:2e5,minSumOther:6e3,maxSumOther:2e5,maxBonus:5e3,prefMonthsNum:2,prefTravelBonusRate:.015,prefRestBonusRate:.01,travelBonusRate:.015,restBonusRate:.01},mn={minSum:5e4,maxSum:5e6,minMonths:2,maxMonths:10,rate:0,isMonthlyInterestPayment:!0,isRemoteRegistration:!0},hn={minSum:1e3,maxSum:5e5,minDays:1,maxDays:1095,rate:0,isMonthlyInterestPayment:!0,isReplenished:!1,isPartialWithdrawal:!1,depositeName:"Депозит 'Стабильный'"},un=e=>e?u(de,{size:"text-s",font:"font-light",color:"text-secondary-text",children:e}):null,pn=x((({rate:e,title:t="Ставка",unit:l,depositeName:n,isShowDepositeName:a,fractionDigits:i=2})=>p("div",{children:[u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:t}),p("div",{className:"relative",children:[p("div",{className:"flex justify-start gradient-color-text",children:[u("span",{className:"font-mohave text-title-huge pr-xl -mt-m tracking-[-15px]",children:String(e.toFixed(i)).replace(".",",")}),l?u("span",{className:"text-7xl",children:l}):null]}),n&&a?u("div",{className:"absolute bottom-2 w-full text-left whitespace-nowrap",children:n}):null]})]}))),xn=x((({title:e="Ставка",isUnavailableByTerm:t=!1})=>p("div",{className:"space-y-s",children:[u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:e}),u(Ae,{className:"w-10 h-10 @5xl:h-auto @5xl:w-40",name:"PercentIcon"}),u("div",{className:"w-64",children:t?p(de,{size:"text-xl",font:"font-light",color:"text-primary-text",children:["Процентная ставка для срока ",u("strong",{children:"1-30 дней"})," устанавливается при обращении в Банк"]}):u(de,{size:"text-xl",font:"font-light",color:"text-primary-text",children:"Выберите другую сумму или срок"})})]}))),gn=({rate:e,depositeName:t,fractionDigits:l,isShowDepositeName:n,title:a,unit:i})=>u(pn,{rate:e,depositeName:t,fractionDigits:l,isShowDepositeName:n,unit:i,title:a}),fn=({rate:e,title:t,unit:l})=>u(rn,{title:t,value:e,postfix:l}),bn=({isUnknownRateShown:e=!0,isUnavailableByTerm:t=!1,title:l="Ставка",unit:n="%",rate:a=0,...i})=>e&&0===a?u(xn,{isUnavailableByTerm:t,title:l}):p("div",{children:[u("div",{className:"hidden @xl:block",children:gn({title:l,unit:n,rate:a,...i})}),u("div",{className:"@xl:hidden",children:fn({title:l,unit:n,rate:a,...i})})]});function yn({isShowItems:e=!0,step:t=1e3,...l}){const n=[`От ${pt(2)(l.min||0)} ₽`,`До ${pt(2)(l.max||0)} ₽`];return u(yt,{items:e?n:[],step:t,...l})}function vn(e){const{data:t}=A(`/wcms-resources/${e}.json`,j);return t}const Nn=(e,t)=>{const{travelExpenseValue:l,restExpenseValue:n}=e,a=vn(t||"bonus-calculator-data")||dn,[i,r]=((e,t,l)=>{const{minSumTravel:n,minSumOther:a,maxBonus:i,prefMonthsNum:r,prefTravelBonusRate:s,prefRestBonusRate:o,travelBonusRate:c,restBonusRate:d}=e;if(t===n&&l===a)return[0,0];const m=Math.min(Math.round(s*t)+Math.round(o*l),i);return[m,m*r+Math.min(Math.round(c*t)+Math.round(d*l),i)*(12-r)]})(a,l,n);return{...a,...e,monthBonus:i,yearBonus:r}},wn=x((({className:e="",sourceBookDir:t,buttons:l,footnote:n})=>{const[a,{field:i}]=B({travelExpenseValue:6e3,restExpenseValue:6e3}),{minSumTravel:r,maxSumTravel:s,minSumOther:o,maxSumOther:c,monthBonus:d,yearBonus:m}=Nn(a,t);return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-y-4xl",e),children:[p("div",{className:"flex flex-col @xl:max-w-md gap-2xl border-b border-b-main-divider @xl:border-none pb-3xl @xl:pb-0",children:[yn({title:"Сумма покупок в категории путешествия, ₽",min:r,max:s,step:500,isShowItems:!1,...i("travelExpenseValue")}),yn({title:"Сумма покупок в остальных категориях, ₽",min:o,max:c,step:500,isShowItems:!1,...i("restExpenseValue")})]}),d>=0?bn({title:"Баллов за месяц",rate:d,fractionDigits:0,isUnknownRateShown:!1,unit:""}):null,p("div",{className:"flex flex-col gap-y-4xl @xl:w-96",children:[m>=0?u(rn,{title:"Баллов за год",value:m}):null,Al(l,{isVertical:!0}),un(n)]})]})})),kn=e=>`${e} ${Number(e)%10==1?"дня":"дней"}`,Cn={horizontal:"gap-5xl",vertical:"flex-col gap-s"},Sn=x((({items:e,checkedItem:t,className:l,onChange:n,orientation:a="horizontal"})=>u("div",{className:w(`flex ${Cn[a]}`,l),children:e?.map((({id:e,text:l})=>u(_t,{isRadio:!0,text:l,value:t===e,onChange:()=>n&&n(e)},String(e))))}))),In=({items:e,title:t,orientation:l="horizontal",value:n,radioGroupClassName:a,onChange:i})=>p("div",{className:"space-y-s",children:[t?u("div",{children:u(me,{color:"text-secondary-text",font:"font-light",children:t})}):null,u(Sn,{orientation:l,items:e,checkedItem:e[n?0:1].id,className:w("flex-col sm:flex-row",a),onChange:t=>i&&i(t===e[0].id)})]}),Tn=e=>In({...e,items:[{id:"everyMonth",text:"Ежемесячно"},{id:"atEndTerm",text:"В конце срока"}]}),Bn=e=>e,Mn=(e=Bn)=>t=>t.reduceRight(((t,l)=>e(t)>e(l)?t:l)),Pn=Mn(),Rn=e=>{const t=[...e];t.sort((([e],[t])=>e-t));let l=1;for(;l<t.length;){const[e,n]=t[l-1],[a,i]=t[l];n>=a?t.splice(l-1,2,[e,Math.max(n,i)]):l++}return t},Vn=(e=Bn)=>Mn((t=>-e(t))),zn=Vn(),An=([e,t],l,n=[])=>l&&l[e]&&l[t]?{[e]:l[e],[t]:l[t]}:Dn([e,t],n),Dn=([e,t],l=[])=>({[e]:l.length?zn(l.filter((t=>"number"==typeof t[e])).map((t=>t[e]))):0,[t]:l.length?Pn(l.filter((t=>"number"==typeof t[e])).map((e=>e[t]))):0}),_n=(e,[t,l],n)=>e>=n[t]&&e<=n[l],jn=(e,t)=>e?t.isReplenished&&t.isPartialWithdrawal:!t.isReplenished&&!t.isPartialWithdrawal,Ln=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,daysValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a/30)-n):Math.round(n*e*a/365/100)},$n=x((({className:e="",rateParams:t,buttons:l,footnote:n,bottomFootnote:a,isShowDepositeName:i})=>{const[r,{field:s}]=B({moneyValue:1e5,daysValue:90,isReplenished:!1,isPartialWithdrawal:!1,isMonthlyInterestPayment:!1}),o=((e,t)=>{const{daysValue:l,moneyValue:n,isPartialWithdrawal:a,isReplenished:i,isMonthlyInterestPayment:r}=e,s=vn(t||"business-calculator-data"),o=i||a,c=l<90||l>730;if(l<=30)return{...hn,...e,isDisabledOperatingDeposit:c,isUnavailableByTerm:!0};const d=s?.rateRows?.find((e=>r===e.isMonthlyInterestPayment&&jn(o,e)&&_n(n,["minSum","maxSum"],e)&&_n(l,["minDays","maxDays"],e)))||hn,{rate:m}=d,h=Ln(m,e),u=n+h,p=s?.rateRows||[hn];return{...d,...Dn(["minSum","maxSum"],p),...Dn(["minDays","maxDays"],p),...e,isDisabledOperatingDeposit:c,income:h,finalSum:u}})(r,t?.sourceBookDir),{income:c,finalSum:d,rate:m,isUnavailableByTerm:h,depositeName:x}=o;return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[yn({title:"Сумма, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),(g={title:"Срок, дней",min:o.minDays,max:o.maxDays,...s("daysValue"),value:o.daysValue},u(yt,{items:[`От ${kn(g.min||0)}`,`До ${kn(g.max||0)}`],step:1,...g})),p("div",{className:"flex flex-col sm:flex-row gap-y-4 gap-x-14",children:[On(o,s),Tn({title:"Выплата процентов",orientation:"vertical",...s("isMonthlyInterestPayment"),radioGroupClassName:"sm:flex-col"})]})]}),u("div",{className:"border-b border-main-divider md:hidden"}),bn({rate:m,depositeName:x,isShowDepositeName:i,isUnavailableByTerm:h}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[En(d,c),Al(l,{isVertical:!0}),un(n),un(a)]})]});var g})),On=(e,t)=>p("div",{className:"space-y-s",children:[u(me,{color:"text-secondary-text",font:"font-light",children:"Параметры"}),p("div",{className:"flex flex-col gap-y-xl sm:gap-y-s",children:[u(_t,{text:"Пополнение",disabled:e.isDisabledOperatingDeposit,...t("isReplenished"),value:e.isReplenished}),u(_t,{disabled:e.isDisabledOperatingDeposit,text:"Частичное снятие",...t("isPartialWithdrawal"),value:e.isPartialWithdrawal})]})]}),En=(e,t)=>p("div",{className:"flex flex-col gap-2xl sm:gap-0",children:[u(rn,{title:"Доход в конце срока",value:t,postfix:"₽",prefix:"+"}),u(rn,{title:"Сумма в конце срока",value:e,postfix:"₽"})]}),Fn=({min:e=0,max:t=0,availableMonths:l,...n})=>u(yt,{items:[`От ${Un(e)}`,`До ${Un(t)}`],step:1,...l?.length?{list:l}:{min:e,max:t},...n}),Un=e=>`${e} ${Number(e)%10==1?"месяца":"месяцев"}`,Hn=e=>In({...e,radioGroupClassName:"sm:flex-col",items:[{id:"annuity",text:"Аннуитетный"},{id:"differential",text:"Дифференцированный"}]}),Wn=e=>Xn({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&Xn({...e,fieldKey:"isStateEmployee",viewSettingFieldKey:"isShowStateEmployee"})&&Xn({...e,fieldKey:"isPensionClient",viewSettingFieldKey:"isShowPensionClient"})&&Xn({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),Xn=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],Kn=(e,t)=>{const{isAnnuity:l,moneyValue:n,monthsValue:a,moneyExtra:i}=t;if(0===e)return 0;if(l){const t=e/1200;return i?(n+i)*(t+t/(Math.pow(1+t,a)-1)):n*(t+t/(Math.pow(1+t,a)-1))}return Math.round(n/a)+n*(e/1200)},Yn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=vn(t||"credit-calculator-data"),s=i?.rateRows||[on],o=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>Wn({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:i?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:c,maxSum:d}=An(["minSum","maxSum"],o,s),{minMonths:m,maxMonths:h}=An(["minMonths","maxMonths"],o,s),u=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a})=>e?.find((e=>Wn({row:e,userInputParams:t,paramsViewSettings:l})&&_n(n,["minSum","maxSum"],e)&&_n(a,["minMonths","maxMonths"],e)))||on)({rateRows:s,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a}),{rate:p}=u,x=Kn(p,e);return r((()=>({...u,...e,minSum:c,maxSum:d,minMonths:m,maxMonths:h,moneyValue:n,monthsValue:a,monthlyPayment:x})),[e,i])},Gn=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a,isMobile:i})=>{const[r,{field:s}]=B({isAnnuity:!0,isInsurance:!0,isSalaryClient:!1,isPensionClient:!1,isStateEmployee:!1,moneyValue:2e5,monthsValue:sn}),o=Yn(r,t,a),c=Hn({title:i?"Тип платежа":"",orientation:"vertical",...s("isAnnuity")});return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[yn({title:"Сумма кредита, ₽",step:500,min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),Fn({title:"Срок кредита, месяцев",min:o.minMonths,max:o.maxMonths,...s("monthsValue"),value:o.monthsValue}),qn({...o,...a},s),u("div",{className:"sm:hidden",children:c})]}),u("div",{className:"border-b border-main-divider md:hidden"}),bn({rate:o.rate}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(rn,{title:"Ежемесячный платеж",value:o.monthlyPayment,postfix:"₽"}),u("div",{className:"hidden sm:block",children:c}),Al(l,{isVertical:!0}),un(n)]})]})})),qn=(e,t)=>p("div",{className:"flex flex-col gap-y-2xl",children:[e.isShowSalaryClient?u(_t,{text:"Получаю зарплату на счёт\nв Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient,className:"whitespace-pre-line sm:whitespace-normal"}):null,e.isShowStateEmployee?u(_t,{text:"Работаю в бюджетной организации",...t("isStateEmployee"),value:e.isStateEmployee}):null,e.isShowPensionClient?u(_t,{text:"Получаю пенсию на карту Россельхозбанка",...t("isPensionClient"),value:e.isPensionClient}):null,e.isShowInsurance?u(_t,{text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null]}),Jn=(e,t,l)=>{const{moneyValue:n,monthsValue:a}=e,i=vn(t||"deposit-calculator-data"),r=i?.rateRows?.[0]?ea(i.rateRows[0].minMonths,i.rateRows[0].maxMonths):1,s=!l?.isShowMonthlyInterestPayment,o=!l?.isShowRemoteRegistration,c=i?.rateRows?.find((t=>Qn({row:t,userInputParams:e,paramKey:"isMonthlyInterestPayment",isExclude:s})&&Qn({row:t,userInputParams:e,paramKey:"isRemoteRegistration",isExclude:o})&&_n(n,["minSum","maxSum"],t)&&_n(a||r,["minMonths","maxMonths"],t)))||mn,{rate:d}=c,m=Zn(d,e),h=n+m,u=i?.rateRows||[mn];return{...c,...Dn(["minSum","maxSum"],u),...Dn(["minMonths","maxMonths"],u),availableMonths:Rn(u.map((e=>[e.minMonths,e.maxMonths]))).flatMap((([e,t])=>((e,t,l=1)=>Array.from({length:Math.abs(t-e)/l+1},((n,a)=>t>=e?e+a*l:e-a*l)))(e,t))),...e,defaultMonth:r,income:m,finalSum:h}},Zn=(e,t)=>{const{isMonthlyInterestPayment:l,moneyValue:n,monthsValue:a}=t;return l?Math.round(n*Math.pow((1200+e)/1200,a)-n):Math.round(n*e*30*a/365/100)},Qn=({row:e,userInputParams:t,paramKey:l,isExclude:n})=>n||t[l]===e[l],ea=(e,t)=>e+Math.round((t-e)/2),ta=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:i})=>{const[r,{field:s}]=B({moneyValue:2e4,monthsValue:0,isMonthlyInterestPayment:!1,isRemoteRegistration:!1}),o=Jn(r,t,i),{defaultMonth:c,rate:d,income:m,finalSum:h}=o,{onChange:x}=s("monthsValue");return a((()=>{x&&x(c)}),[c]),p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[yn({title:"Сумма, ₽",min:o.minSum,max:o.maxSum,...s("moneyValue"),value:o.moneyValue}),Fn({title:"Срок, месяцев",min:o.minMonths,max:o.maxMonths,availableMonths:o.availableMonths,...s("monthsValue"),value:o.monthsValue}),la({...o,...i},s)]}),u("div",{className:"border-b border-main-divider md:hidden"}),bn({rate:d}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(rn,{title:"Доход в конце срока",value:m,postfix:"₽",prefix:"+"}),u(rn,{title:"Сумма в конце срока",value:h,postfix:"₽"}),Al(l,{isVertical:!0}),un(n)]})]})})),la=(e,t)=>{return p("div",{className:"flex flex-col gap-y-2xl",children:[e.isShowMonthlyInterestPayment?Tn({title:"Выплата процентов",...t("isMonthlyInterestPayment"),value:e.isMonthlyInterestPayment}):null,e.isShowRemoteRegistration?(l={title:"Оформление",...t("isRemoteRegistration"),value:e.isRemoteRegistration},In({...l,items:[{id:"remote",text:"Дистанционно"},{id:"office",text:"Офис Банка"}]})):null]});var l},na=e=>aa({...e,fieldKey:"isSalaryClient",viewSettingFieldKey:"isShowSalaryClient"})&&aa({...e,fieldKey:"isInsurance",viewSettingFieldKey:"isShowInsurance"}),aa=({row:e,userInputParams:t,paramsViewSettings:l,fieldKey:n,viewSettingFieldKey:a})=>!!l&&!l[a]||t[n]===e[n],ia=(e,t,l)=>{const{moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s}=e,o=vn(t||"refinancing-calculator-data"),c=o?.rateRows||[cn],d=(({limitRows:e,userInputParams:t,paramsViewSettings:l})=>e?.find((e=>na({row:e,userInputParams:t,paramsViewSettings:l}))))({limitRows:o?.limitRows||[],userInputParams:e,paramsViewSettings:l}),{minSum:m,maxSum:h}=An(["minSum","maxSum"],d,c),{minMonths:u,maxMonths:p}=An(["minMonths","maxMonths"],d,c),x=(({rateRows:e=[],userInputParams:t,paramsViewSettings:l,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:r})=>e?.find((e=>na({row:e,userInputParams:t,paramsViewSettings:l})&&_n(n+r,["minSum","maxSum"],e)&&_n(i,["minSumOld","maxSumOld"],e)&&_n(r,["minSumExtra","maxSumExtra"],e)&&_n(a,["minMonths","maxMonths"],e)))||cn)({rateRows:c,userInputParams:e,paramsViewSettings:l,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s}),{rate:g}=x,f=Kn(g,e),b=e.oldMonthlyPayment-f;return r((()=>({...x,...e,minSum:m,maxSum:h,minMonths:u,maxMonths:p,moneyValue:n,monthsValue:a,oldMonthlyPayment:i,moneyExtra:s,monthlyPayment:f,benefit:b})),[e,o])},ra=x((({className:e,sourceBookDir:t,buttons:l,footnote:n,paramsViewSettings:a})=>{const[i,{field:r}]=B({isAnnuity:!0,isInsurance:!0,isSalaryClient:!1,isExtraMoney:!1,moneyValue:7e5,oldMonthlyPayment:0,monthsValue:48,moneyExtra:0}),s=ia(i,t,a);return p("section",{className:w("flex flex-col justify-between @5xl:flex-row gap-m",e),children:[p("div",{className:"flex flex-col gap-y-m sm:max-w-md gap-2xl",children:[yn({title:"Остаток долга в других банках, ₽ ",step:500,min:s.minSum,max:s.maxSum-s.maxSumExtra,...r("moneyValue"),value:s.moneyValue}),yn({title:"Ежемесячный платеж в других банках, ₽",step:500,min:s.minSumOld,max:s.maxSumOld,...r("oldMonthlyPayment"),value:s.oldMonthlyPayment}),Fn({title:"Новый срок кредита, месяцев",min:s.minMonths,max:s.maxMonths,...r("monthsValue"),value:s.monthsValue}),sa({...s,...a},r),s.isExtraMoney?yn({title:"Дополнительная сумма, ₽ ",step:500,min:s.minSumExtra,max:s.maxSumExtra,...r("moneyExtra"),value:s.moneyExtra}):null]}),bn({rate:s.rate,fractionDigits:1}),p("div",{className:"flex flex-col gap-2xl sm:w-96",children:[u(rn,{title:"Ежемесячный платеж",value:s.monthlyPayment,postfix:"₽"}),s.benefit>0?u(rn,{title:"Выгода в месяц",value:s.benefit,postfix:"₽"}):null,Hn({orientation:"vertical",...r("isAnnuity")}),Al(l,{isVertical:!0}),un(n)]})]})})),sa=(e,t)=>p("div",{className:"space-y-s",children:[e.isShowSalaryClient?u(_t,{text:"Получаю зарплату на счёт в Россельхозбанке",...t("isSalaryClient"),value:e.isSalaryClient}):null,e.isShowInsurance?u(_t,{text:"Комплексная страховая защита",...t("isInsurance"),value:e.isInsurance}):null,u(_t,{text:"Получить дополнительную сумму",...t("isExtraMoney"),value:e.isExtraMoney})]}),oa={CreditCalculatorForm:Gn,DepositCalculatorForm:ta,BusinessDepositCalculatorForm:$n,BonusCalculatorForm:wn,RefinancingCalculatorForm:ra},ca=(e,t)=>{const l=e?.calcType;if(!l||!(l in oa))return null;const n=oa[l];return u("section",{className:"box-border relative bg-white flex shrink-0 self-start basis-full",role:"listitem",children:p("div",{className:"box-border p-4xl w-full space-y-xl",children:[e?.title?u(I,{className:"text-center",title:e.title}):null,u(n,{...e})]})},String(t))},da=x((({className:e="",tabAlign:t,calculatorTabs:l=[],...a})=>{const r=l.map((e=>e.nav||{})),s=l.map((({calculatorBlock:e})=>e||{})),[o,c]=n(0),d=i((e=>c(e)),[]),[m,h]=en({itemCount:l?.length,visibleItemCount:3});return p(C,{className:w("box-border overflow-hidden relative",e),defaultPadding:"p-0",...a,children:[p("div",{className:"bg-white",children:[r.length>1?ma({activeIndex:m,tabsNav:r,tabAlign:t,slideIndexShift:o,onClick:d}):null,an({...h,btnClass:["left-3","right-3"],className:"top-10"})]}),u("div",{className:"flex",style:{transform:`translateX(-${o}00%)`},role:"list",children:s?.length?s.map(ca):null})]})}));function ma({activeIndex:e,tabsNav:t,tabAlign:l,slideIndexShift:n,onClick:a}){return p("div",{children:[u("div",{style:{transform:`translateX(-${388*e}px)`},className:"flex flex-col justify-end items-center h-32 pt-4xl box-border duration-1000",children:u("div",{className:w("w-full flex flex-nowrap items-end gap-xs",l?Zl[l]:""),children:t.map(((e,t)=>function({tab:e,i:t,isActive:l,onClick:n}){const a=l?"w-96 p-m border-none bg-primary-main text-white":"w-96 p-s ease-in duration-300 bg-white text-primary-text",i=l?"text-xl mb-xs":"text-l mb-2xs",r=l?"text-l font-light text-white":"text-m font-light text-secondary-text",s=l?"":"text-primary-main",o=e?.icon?.iconVersion,c=l?"white":"normal";return p("button",{type:"button",onClick:n,"aria-label":e?.title,className:w("box-border relative border border-gray cursor-pointer text-left border-b-0 flex space-x-m min-h-20",a),children:[u(cl,{className:w("h-6 w-6 min-w-6 min-h-6",s),image:{...e?.icon,iconVersion:o??c},width:"24",height:"24"}),p("div",{className:"border-0",children:[u("div",{className:i,children:e?.title}),u("div",{className:r,children:e.description})]})]},String(t))}({tab:e,i:t,isActive:Boolean(t===n),onClick:()=>a(t)})))})}),u("div",{className:"w-full h-2 bg-primary-main"})]})}const ha=x((e=>{const{onChange:t,min:l,max:n,defaultValue:a="0",fractionDigits:r=0,...s}=e,o=ht(e,{normalize:(e=a)=>l&&n?String(ut(Number(ua(e)),l,n)):ua(e),format:pt(r)}),c=i((e=>t&&t(ua(e))),[t]);return u(pe,{onChange:c,...s,...o})})),ua=(e="")=>e.replaceAll(",",".").replace(/[^\d.]/g,"").replace(/([^.]*\.[^.]*)\./,"$1"),pa=x((e=>u(ha,{...e,fractionDigits:2,children:u("div",{className:"absolute right-4 bottom-4",children:u(me,{size:"text-xl",font:"font-light",children:"₽"})})}))),xa={private:"https://old.rshb.ru/p2p/",business:"https://old.rshb.ru/smallbusiness/p2p/"},ga={amount:1500,_amount:1500},fa=x((({className:e="",title:t="Укажите сумму перевода",label:l="Сумма перевода",placeholder:n="1500",button:a,formType:i="private",...r})=>{const[{amount:s,_amount:o},{field:c}]=B(ga),d=s<=0,m=d?ie({version:a?.version}):re({className:"text-white",version:a?.version}),h=q();return p(C,{className:w("flex flex-col items-center",e),defaultPadding:"p-6xl",...r,children:[t?u(I,{className:"pb-lg xl:pb-4xl self-start xl:self-center",headingType:"h3",title:t}):null,p("form",{className:"w-full xl:max-w-[468px]",method:"POST",action:xa[i],children:[u(pa,{name:"_amount",valid:!d,placeholder:n,label:l,...c("_amount",{parse:Number,format:String})}),u("input",{type:"hidden",name:"amount",value:o}),a?.text?u("button",{type:"submit",className:w("w-full p-m mt-lg",m),disabled:d,...h(a),children:a.text}):null]})]})})),ba=e=>({height:"calc(100vh - 242px)",minHeight:`${e||866}px`}),ya=x((({className:e="",style:t,idx:l,activeIndex:n,observerOptions:a,children:r,onIntersection:s})=>{const o=y(i((e=>{e.length&&s&&s(l||0,e[e.length-1])}),[s,l]),a);return u("div",{className:`inline-block snap-always box-border ${e}`,style:t,"aria-current":Boolean(l===n),ref:o,children:r})})),va=["min-w-full","@lg:min-w-[50%]","@lg:min-w-[33.3%]","@lg:min-w-[25%]"],Na=x((({className:e="",containerRef:t,activeIndex:l,visibleItemCount:n=0,gap:a=0,padding:r=0,listType:o="horizontal-list",snapAlign:c="snap-center",minHeight:d,children:m,onVisibleItemsChange:h,onVisibleIndicesChange:p})=>{const x={sensitivity:1,rootRef:t},g=s([]),f=i(((e,t)=>{const l=[...g.current||[]];l[e]=t,g.current=l,h&&h(l),p&&p(ka(l))}),[h,p]),b=n>0?a*Number(n)-1:0,y="vertical-list"===o,v="horizontal-list"===o,N={...v?wa(r,b):{},...y?ba(d):{},gap:`${a}px`};return u("div",{className:w("box-border overflow-auto no-scrollbar",o,e),style:N,ref:t,children:(k=(e,t)=>u(ya,{className:w(c,n?va[n-1]:"",y?"h-full":""),style:v?wa(r/4):{},activeIndex:l,idx:t,observerOptions:x,onIntersection:f,children:e},String(t)),e=>null==e?e:Array.isArray(e)?e.map(k):k(e,0))(m)});var k})),wa=(e,t=0)=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e+t}px`}),ka=e=>e.map(((e,t)=>[e,t])).filter((([e])=>e&&e.intersectionRatio>=.9)).map((([,e])=>e)),Ca={"horizontal-list":"mx-auto mt-lg w-fit","vertical-list":"absolute flex-col justify-center h-full top-0 left-4"},Sa={"horizontal-list":"w-6","vertical-list":"h-6"},Ia=x((({className:e="",containerRef:t,activeIndex:l,dotCount:n=0,listType:a="horizontal-list",version:i})=>n?u("div",{className:w("flex gap-xs",Ca[a],i?"group":"",e),...i?{"data-ver":i}:{},children:new Array(n).fill(null).map(((e,n)=>u("div",{className:`cursor-pointer rounded-full transition-width duration-300 bg-primary-main group-data-secondary:bg-white group-data-transparent:bg-white ${n===l?Sa[a]:"w-2 h-2 opacity-30"}`,role:"button","aria-hidden":!0,onClick:()=>(e=>{e!==l&&t?.current&&t.current.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest"})})(n)},String(n))))}):null)),Ta=e=>t=>e.scrollWidth/t,Ba=e=>(t,l)=>{e.scrollBy({left:l*Ta(e)(t),behavior:"smooth"})},Ma=({itemCount:e,onVisibleIndicesChange:t})=>{const l=s(null),[a,r]=n([]),o=i((e=>{r((t=>{return(l=t)===(n=e)||Boolean(l&&n&&l?.length===n?.length&&l.every(((e,t)=>e===n[t])))?t:e;var l,n})),t&&t(e)}),[e]),[c,d]=a.length?[Vn()(a),Mn()(a)]:[-1,-1],m=c>0,h=d<e-1,u=i((()=>{var t;l.current&&(m?Ba(l.current)(e,-1):(t=l.current).scrollTo({left:t.scrollWidth,behavior:"smooth"}))}),[e,m]),p=i((()=>{l.current&&(h?Ba(l.current)(e,1):l.current.scrollTo({left:0,behavior:"smooth"}))}),[e,h]),x=i((e=>{l?.current&&l.current.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})}),[l]);return[l,{scrollLeft:u,scrollRight:p,scrollTo:x,canScrollLeft:m,canScrollRight:h,visibleIndicesRange:[c,d],handleVisibleIndicesChange:o}]},Pa="absolute top-[calc(50%-24px)] z-40",Ra="absolute top-0 bottom-0 z-40 hidden @lg:block w-20 pointer-events-none",Va=x((({scroll:e,activeIndex:t,itemCount:l,arrowsPadded:n,hasEdgeBlocks:a,onScrollLeft:r,onScrollRight:s})=>{const{canScrollLeft:o,canScrollRight:c,scrollLeft:d,scrollRight:m}=e,h=a?t>0:o,x=a?t<l-1:c,g=i((()=>{a?(o&&t!==l-1&&d(),r()):d()}),[d,r,a,o,t,l]),f=i((()=>{a?(c&&0!==t&&m(),s()):m()}),[m,s,a,o,t,l]);return p("div",{className:"hidden @lg:block",children:[za(e),h?u(ln,{className:w(Pa,n?"left-1 @lg:left-8":"left-0"),onClick:g}):null,x?u(nn,{className:w(Pa,n?"right-1 @lg:right-8":"right-0"),onClick:f}):null]})})),za=e=>p("div",{children:[e.canScrollLeft?u("div",{className:w(Ra,"left-0 bg-opacity-from-white group-data-secondary:bg-none")}):null,e.canScrollRight?u("div",{className:w(Ra,"right-0 bg-opacity-to-white group-data-secondary:bg-none")}):null]}),Aa=({blockClassName:e,block:t,render:l})=>l({blockClassName:e,block:t}),Da=[];function _a(e,t,{className:l,...n}={}){const{key:a,blockDecorator:i=Aa,blocksRegistry:r={},ancestors:s=Da}=t,{type:o}=e;o&&o in r||console.warn(`No block with "${o}" is registered`);const c=o&&r[o];return i({blockClassName:w(e.style?.length?e.style:"col-span-12",l),block:e,ancestors:s,render:({block:l,blockClassName:i})=>{const{content:r}=l;return c?u(c,{className:i,block:e,options:t,...r,...n},a):null}},a)}const ja=[],La=(e,{key:t,ancestors:l=ja,slotName:n=null,extraProps:a,renderProps:i=_a,...r})=>{const s=a?(e,t)=>_a(e,t,a):i;return(e||[]).map(((e,a)=>s(e,{...r,key:`${t||e.type}-${a}`,ancestors:r.parent?[...l||ja,[r.parent,n]]:l},a)))};function $a({block:e,options:t,children:l,extraProps:n,renderProps:a}){return l||(e&&t?La(e.blocks,{...t,parent:e,extraProps:n,renderProps:a}):null)}const Oa=e=>e?"border border-solid border-gray group-data-secondary:border-white/50 group-data-gray:border-main-divider":"",Ea=({className:e,text:t="ХИТ"}={})=>p("div",{className:w("w-14 h-14 bg-white flex flex-col items-center justify-center rounded-md shadow-main-black",e),children:[u(Ae,{iconVersion:"black",name:"HeartIcon",width:"24",height:"24"}),u(de,{size:"text-s",font:"font-normal",align:"text-center",color:"text-primary-text",children:t})]}),Fa="relative h-full",Ua={small:"sm:min-w-64",normal:"sm:min-w-96",big:"sm:min-w-[515px]"},Ha=({noCardBorder:e,activeIndex:t,cardSize:l="normal",...n})=>{const{blocks:a}=n.block||{},i=a?.some(Ka);return $a({...n,renderProps:(n,a,r)=>p("div",{className:Wa(n,{someCardsHighlighted:i}),children:[_a(n,a,{className:Xa(n,{someCardsHighlighted:i,showBorder:!e,cardSize:l}),blockIndex:r,isActive:r===t}),Ka(n)?Ea({className:"absolute top-0 -right-4 z-40"}):null]},String(r))})},Wa=(e,{someCardsHighlighted:t})=>w(Fa,t&&(Ka(e)?"pt-3xl":"pt-3xl sm:pt-16")),Xa=(e,{someCardsHighlighted:t,showBorder:l,cardSize:n="normal"})=>w(Fa,"min-w-80",Ua[n],t&&(Ka(e)?"pt-3xl sm:pt-16":"pt-3xl"),Oa(l),l&&"h-full"),Ka=e=>e?.content&&"isHighlighting"in e.content&&e.content.isHighlighting,Ya=x((({className:e,itemCount:t,visibleItemCount:l=1,noCardBorder:n,isAlignCenter:a,arrowsPadded:i=!0,isGap:r=!0,cardSize:s="normal",...o})=>{const{blocks:c=[]}=o.block||{},d=t||c?.length,[m,{inc:h,dec:x}]=en({itemCount:d,visibleItemCount:l},Math.floor(l/2)),[g,f]=Ma({itemCount:d}),[b]=f.visibleIndicesRange,y=c&&"CarouselBankHistoryCard"===c[0]?.type;return p(C,{className:e,defaultPadding:"p-6xl",...o,children:[p("div",{className:w(a?"flex justify-center":"","relative max-w-full"),children:[u(Na,{containerRef:g,visibleItemCount:l,snapAlign:"snap-start",gap:r?16:void 0,onVisibleIndicesChange:f.handleVisibleIndicesChange,children:Ha({noCardBorder:n,activeIndex:m,cardSize:s,...o})}),u(Va,{scroll:f,arrowsPadded:i,onScrollLeft:x,onScrollRight:h,hasEdgeBlocks:y,activeIndex:m,itemCount:d})]}),u(Ia,{className:"@5xl:hidden",containerRef:g,activeIndex:b,dotCount:d,listType:"horizontal-list"})]})}));Ya.childrenTypes=["CarouselCard","CarouselBankHistoryCard","CarouselCatalogCard","CarouselInvestmentCard","CarouselProductCard","CarouselProgramsCard","CarouselRecommendationCard","CarouselTariffsCard","CarouselRichTextCard","CarouselInvestmentCard","ProductBlock"],Ya.childSchema=()=>({isHighlighting:{title:"Выделить карточку",type:"boolean"}});const Ga=x((({className:e,title:t,description:l,blockIndex:n=0,isActive:a,...i})=>u(C,{className:w("relative flex h-[485px]",a?"w-[440px] z-10":"w-[340px]",e),defaultPadding:"p-0",...i,children:u("div",{className:w("basis-full self-center",qa(n)),children:a?u(Ol,{headlineVersion:"M",title:t,description:l,padding:"p-3xl",align:"text-left",className:"h-96 text-white shadow-dark-blue"}):u("div",{className:"h-[300px] flex justify-center items-center font-mohave text-title-large",children:u("span",{className:Ja(n),children:t})})})}))),qa=e=>["bg-primary-main","bg-green-light","bg-yellow-light"][e%3],Ja=e=>["gradient-color-text-on-green","gradient-color-text-on-yellow","gradient-color-text-on-yellow"][e%3],Za="z-10 border border-solid w-full h-full",Qa=w(Za,"absolute hidden @xl:block border-transparent"),ei=x((({className:e,title:t,description:l,button:n,...a})=>u(C,{className:w("sm:pl-6xl sm:pb-4xl @container-normal",e),defaultPadding:"p-0",...a,children:p("div",{className:"relative h-full",children:[u("div",{className:w(Qa,"top-9 right-12 bg-green-dark")}),u("div",{className:w(Qa,"top-6 right-8 bg-green")}),u("div",{className:w(Qa,"top-3 right-4 bg-green-light")}),p("div",{className:w(Za,"relative p-xl sm:p-5xl bg-white border-transparent sm:border-green-light"),children:[u(Ol,{title:t,description:l,headlineVersion:"XS",align:"text-left",isEmbedded:!0}),Al([n],{className:"mt-m sm:mt-6xl sm:justify-center",isVertical:!0})]})]})}))),ti={start:"@xl:self-start",center:"@xl:self-center",end:"@xl:self-end"},li=x((({className:e,defaultPadding:t,padding:l,title:n="",insetTitle:a="",buttons:i,leftImage:r,rightImage:s,imageAlign:o,isImageAlwaysOnRight:c=!1,isImageSecondary:d=!1,children:m})=>p("div",{className:w("relative flex flex-col gap-3xl overflow-hidden",l||t,e),children:[n?u("div",{className:"relative",children:n}):null,p("div",{className:w("grow relative flex flex-col @md:flex-row gap-3xl",r?"self-start":""),children:[ri(r,{imageAlign:o,className:"m-auto"}),p("div",{className:w("grid gap-3xl",s?"@xl:grid-cols-2":"",r?"":"grow"),children:[p("div",{className:"grow space-y-lg min-w-fit",children:[a,m]}),ri(s,{className:w("@xl:justify-self-end @xl:col-start-2",i?ni(c):"",ai(c),si(d)),imageAlign:o}),ii(i)]})]})]}))),ni=e=>e?"row-span-2":"@xl:row-span-2",ai=e=>e?"justify-self-end col-start-2 self-center":"",ii=e=>e?u("div",{className:"self-end",children:e}):null,ri=(e,{className:t,imageAlign:l})=>e?u("div",{className:w("shrink-1/2 justify-self-center",l&&ti[l],t),children:e}):null,si=e=>e?"hidden @md:block":"",oi={black:"bg-black",white:"bg-white"},ci=x((({className:e="",title:t,description:l,image:n,price:a,button:i,colors:r=[],align:s="text-left",padding:o,...c})=>u(C,{className:w("flex flex-col justify-left",e),defaultPadding:"p-2xl",...c,children:p(li,{className:"h-full",padding:o,title:t||l?u(Ol,{title:t,description:l,headlineVersion:"XS",isEmbedded:!0,align:s}):null,rightImage:n?.src?u(cl,{className:"flex justify-center align-center mb-xl",image:n}):null,buttons:Al([i],{buttonClassName:"w-full self-end"}),children:[r?.length?p("div",{className:"flex text-secondary-text mb-m",children:[u("div",{className:"mr-xs",children:u(me,{size:"text-s",align:"text-left",font:"font-light",children:"Цвета:"})}),r.map(di)]}):null,a?p(me,{size:"text-h3",align:"text-left",children:[a," ₽"]}):null]})}))),di=(e,t)=>u("div",{role:"figure",className:`w-6 h-6 ml-s border border-solid border-main-divider rounded-full ${oi[e]}`},String(t)),mi={1:"grid-cols-1",2:"grid-cols-2"},hi=x((({className:e,padding:t,additionalDescription:l,cardsList:n=[],columnsMode:a=1,description:i,image:r,title:s,...o})=>u(C,{className:w("text-left",e),padding:"p-0",...o,children:p(li,{className:"h-full",defaultPadding:"p-xl",padding:t,title:s?u(I,{headingType:"h4",as:"h3",className:"mb-m z-10",title:s}):null,rightImage:r?.src?u(cl,{image:r}):null,children:[p("div",{className:"flex justify-between mb-m",children:[i?u("div",{className:"w-1/3",children:u(me,{size:"text-h6",children:i})}):null,l?u(me,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:l}):null]}),n.length?u("ul",{className:w("list-none m-0 p-0 grid gap-xs",mi[a]),children:ui(n)}):null]})}))),ui=e=>e.map(((e,t)=>p("li",{children:[e?.parameter?u("div",{className:"inline pr-xs",children:u(me,{size:"text-h6",children:e.parameter})}):null,e?.parameterDescription?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e.parameterDescription}):null]},String(t)))),pi="hidden xl:block absolute w-full h-full border border-white",xi=x((({text:e,href:t="",target:l="",className:n=""})=>{const a=q()({href:t,target:l});return e?u("div",{className:w("flex relative group/link pl-s pb-s min-w-[16rem] xl:min-w-[20rem]",n),children:p("div",{className:"relative min-h-16 w-full",children:[p("a",{className:w("absolute border\n bg-white flex justify-between group-hover/link:text-primary-main","sm:rounded-md rounded-none w-full px-xl py-lg whitespace-nowrap z-10"),role:"link",...a,children:[u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:e}),u(cl,{className:"group-hover/link:brightness-100 hidden xl:block ml-2xs",image:{icon:"ArrowRightIcon",iconVersion:"black"},imageClassName:"group-hover/link:text-primary-main hidden xl:block",width:"24",height:"24"})]}),u("div",{className:w(pi,"-bottom-1.5 -left-1.5")}),u("div",{className:w(pi,"-bottom-3 -left-3")})]})}):null})),gi=x((({className:e,additionalDescription:t,description:l,links:n,title:a,...i})=>u(C,{className:w("overflow-hidden",e),...i,children:p("div",{className:"flex flex-col @6xl:flex-row gap-m",children:[p("div",{children:[u(Ol,{isEmbedded:!0,title:a,description:l,as:"h1",align:"text-left"}),t?u(Ol,{className:"pt-m",description:t,align:"text-left",isEmbedded:!0}):null]}),n?.length?fi(n,"@6xl:min-w-[672px] p-0 justify-self-end"):null]})}))),fi=(e,t="")=>{const l=Math.ceil(e.length/10);return u(Ya,{className:t,version:"secondary",itemCount:l,arrowsPadded:!1,padding:"p-0",children:new Array(l).fill(null).map(((t,l)=>u("div",{className:w("flex flex-wrap gap-2xs self-start xl:justify-center @5xl:grid @5xl:grid-cols-2"),children:e.slice(10*l,10*(l+1)).map(((e,t)=>u(xi,{...e},String(t))))},String(l))))})},bi=x((({className:e="",href:t,target:l,isRemote:n=!1,children:a})=>{const i=q({isRemote:n})({href:t,target:l});return u(t?"a":"div",{className:w("block",e),...t?i:{},children:a})})),yi={L:"w-1.5 h-1.5 mr-m",M:"w-1.5 h-1.5 mr-s",S:"w-1 h-1 mr-xs",XS:"w-1 h-1 mr-xs"},vi=x((({className:e,isDotted:t=!0,children:l,size:n="M"})=>p("div",{className:w("font-sans flex",e),role:"listitem",children:[t?u("div",{className:"shrink-0",children:u("div",{className:w("align-middle inline-block rounded-full bg-primary-text group-data-secondary:bg-white",yi[n])})}):null,u("span",{children:l})]}))),Ni={XS:"text-m font-light",S:"text-l font-light",M:"text-h6",L:"text-h5"},wi={XS:"ml-2xs",S:"ml-xs",M:"ml-s",L:"ml-m"},ki=x((({className:e,hasIndent:t,isDotted:l,items:n,listItemSize:a="M"})=>n?.length?u("section",{className:w("flex flex-col gap-xs text-left text-primary-text group-data-secondary:text-white group-data-gray:text-secondary-text",Ni[a],t?wi[a]:"",e),role:"list",children:n.map(((e,t)=>u(vi,{isDotted:l,size:a,children:e},String(t))))}):null)),Ci=x((({additionalDescription:e,align:t=Sl,button:l={},className:n="",description:a,headlineSmallVersion:i="H6",href:r,icon:s,isDotted:o=!0,isButtonFullWidth:c=!0,isImageFullWidth:d=!1,isTopPosition:m=!1,items:h=[],target:u,title:x,version:g="primary",...f})=>p(C,{className:w("flex flex-col justify-between",n),defaultPadding:"p-0",version:g,...f,children:[p(bi,{className:"p-m flex flex-col gap-xs",href:r,target:u,children:[Ii(i,x,t),Ti(a,t),Mi(h,o,g),Bi(e,t),Si(s,d,m)]}),Al([l],{className:w("p-m pt-0",c?"":"self-center"),isVertical:c})]}))),Si=(e,t,l)=>p("div",{className:w("flex gap-y-lg justify-center",t?"min-w-full h-full":"",l?"order-first":"order-last"),children:[e?.src?u(cl,{image:e}):null,e?.icon?u(cl,{className:w(t?"w-full h-full":"w-8 h-8 min-w-8"),image:e}):null]}),Ii=(e,t,l)=>t?u(me,{align:l,size:$l[e],children:t}):null,Ti=(e,t)=>e?u(de,{align:t,size:"text-l",children:e}):null,Bi=(e,t)=>e?u(me,{size:"text-m",font:"font-light",color:"text-secondary-text group-data-secondary:text-white/80",align:t,children:e}):null,Mi=(e,t,l="primary")=>e?.length?u(ki,{className:w("text-s","primary"===l?"!text-secondary-text":""),items:e.filter((e=>e?.text)).map((e=>e.text)),isDotted:t,listItemSize:"S"}):null,Pi=(e=[])=>e.reduce(((e,t)=>e+t),0),Ri=(e=[])=>e?.length?Pi(e)/e.length:0,Vi=(e,t="normal")=>e?u("div",{className:w("sm:w-12 sm:h-12 sm:min-w-12 w-11 h-11 min-w-11 box-border flex items-center justify-center rounded-icon","normal"===t?"bg-secondary-light text-primary-main":"bg-primary-main text-black group-data-secondary:bg-white/30 group-data-secondary:text-black"),children:u(cl,{className:"w-6 h-6",image:{...e,iconVersion:e.iconVersion||t}})}):null,zi=x((e=>{const{__html:t="",richVersion:l=""}=e;return t.replace(/<\/?[^>]+\/?>/g,"").trim()?u("div",{className:w(l,"md-container"),dangerouslySetInnerHTML:{__html:t}}):null})),Ai=(e,t)=>e?u(de,{font:"font-light",size:"text-m",color:"text-secondary-text group-data-secondary:text-white",children:e},`description-${t}`):null,Di=(e,t)=>e?u(me,{color:"text-primary-text group-data-secondary:text-white",size:"text-h6",children:e},`label-${t}`):null,_i=(e,t)=>"rte"===e.type&&"__html"in e&&e.__html?u(zi,{...e},`rte-${t}`):["label"in e?Di(e.label,t):null,"description"in e?u("span",{className:e.descriptionClassName,children:Ai(e.description,t)},String(t)):null],ji=x((({className:e,benefitsVersion:t,...l})=>p("div",{className:w("flex gap-m min-w-56 items-center",e),children:["icon"in l?Vi(l.icon,t):null,u("div",{children:_i(l)})]}))),Li=e=>"rte"===e.type?e?.__html?.length||0:Math.max(e?.label?.length||0,e?.description?.length||0),$i=e=>{return((t=e.map(Li))?.length?Math.sqrt(Math.abs(Ri(t.map((e=>e**2)))-Ri(t)**2)):0)>16;var t},Oi=e=>e&&"icon"in e&&e.icon&&(e.icon.icon||e.icon.src),Ei=e=>!e.some(Oi),Fi=x((({className:e,benefitsVersion:t="normal",benefits:l})=>l?.length?u("div",{className:w("flex gap-x-m gap-y-s",$i(l)||Ei(l)?"flex-col":"flex-wrap",e),children:l.map(((e,l)=>u(ji,{benefitsVersion:t,...e},String(l))))}):null)),Ui=x((({className:e,benefits:t})=>t?.length?u("div",{className:w("grid grid-cols-[max-content_1fr] auto-rows-auto items-baseline gap-x-m gap-y-xs",e),children:t.flatMap(_i)}):null)),Hi=x((({isTabularBenefits:e,...t})=>u(e?Ui:Fi,{...t}))),Wi=x((({className:e,tags:t})=>t?.length?u("div",{className:w("flex flex-wrap gap-xs",e),role:"list",children:t.map(Xi)}):null)),Xi=(e,t)=>u("div",{className:"p-xs border-solid border rounded-md border-gray",role:"listitem",children:u(me,{size:"text-m",font:"font-light",children:e})},String(t)),Ki=x((({className:e,padding:t,defaultPadding:l,title:n,description:a,headlineVersion:i="L",align:r="text-left",benefitsVersion:s,isTabularBenefits:o,benefits:c,__html:d,isFullWidthTitle:m,items:h,isDotted:x=!0,listItemSize:g,tags:f=[],buttons:b,image:y,imageOptions:{imageAlign:v="center",directionRight:N=!0,isImageAlwaysOnRight:w,isImageSecondary:k=!1}={},children:C})=>{const S=y?.src?u(cl,{image:y}):null,I=qi({title:n,description:a,headlineVersion:i,align:r}),T=c?.filter((e=>"rte"===e?.type||"label"in e||"description"in e));return u(li,{className:e,padding:t,defaultPadding:l,...m?{title:I}:{insetTitle:I},...Yi(S,N),isImageSecondary:k,imageAlign:v,isImageAlwaysOnRight:w,buttons:Al(b),children:p("div",{className:"flex flex-col sm:gap-xl gap-4xl",children:[T?.length?u(Hi,{benefitsVersion:s,isTabularBenefits:o,benefits:T}):null,d?u(zi,{__html:d}):null,h?.length?u(ki,{items:h,isDotted:x,listItemSize:g}):null,C,Gi(f)]})})})),Yi=(e,t)=>t?{rightImage:e}:{leftImage:e},Gi=e=>e?.length?u(Wi,{tags:e}):null,qi=({title:e,description:t,headlineVersion:l,align:n})=>e||t?u(Ol,{title:e,description:t,headlineVersion:l,align:n,isEmbedded:!0}):null,Ji=[{origins:["t.me","telegram.org"],iconMapped:{icon:"TelegramIcon"}},{origins:["vk.com"],iconMapped:{icon:"VKIcon"}},{origins:["ok.ru"],iconMapped:{icon:"OkIcon"}},{origins:["apps.apple.com"],iconMapped:{icon:"AppleIcon"}},{origins:["play.google.com"],iconMapped:{icon:"PlayMarketIcon"}},{origins:["youtube.com"],iconMapped:{icon:"YoutubeIcon"}},{origins:["rutube.ru"],iconMapped:{icon:"RutubeIcon"}},{origins:["dzen.ru"],iconMapped:{icon:"DzenIcon"}}],Zi=x((({className:e="",media:t,showButtonText:l,stretched:a,version:i="white",children:r})=>{const[s,o]=n(),c=t?.map((e=>{const{href:t,icon:n,text:a}=e,{iconMapped:r}=(e=>Ji.find((({origins:t})=>t?.some((t=>e?.includes(t)))))||{})(t),c=zl(n)?n:r,d=l?{text:a}:{text:""};return!s&&a&&o(!0),{...e,...d,icon:{...c,iconVersion:"color"},version:i}})),d=w("border border-solid hover:border-transparent group-data-primary:border-main-divider border-main-divider group-data-gray:border-green group/media",l&&s?"":"basis-auto",a?"flex-1 justify-center":"");return p("div",{className:w("flex flex-col gap-xs",e),children:[u("div",{className:"flex gap-xs",children:Al(c,{className:a?"w-full":"",buttonClassName:d})}),r?u(me,{size:"text-s",font:"font-light",color:"text-secondary-text",children:r}):null]})})),Qi=x((({className:e,padding:t,description:l,href:n,icon:a,items:i=[],listItemSize:r="S",socialMedia:s=[],target:o,title:c,align:d="text-left",benefits:m,imageOptions:{directionRight:h=!0,isImageAlwaysOnRight:x=true,isImageSecondary:g=!1}={},...f})=>u(C,{className:w("relative min-h-28 group-data-gray:bg-main-divider/50",e),defaultPadding:"p-0",...f,children:u(bi,{href:n,target:o,className:"h-full",children:p(li,{className:"h-full",defaultPadding:"p-2xl",padding:t,insetTitle:c?u(Ol,{title:c,description:l,headlineVersion:"S",isEmbedded:!0,align:d}):null,...Yi(zl(a)?u(cl,{image:a}):null,h),buttons:s.length?u(Zi,{media:s,showButtonText:!0,version:f?.version}):null,isImageAlwaysOnRight:x,isImageSecondary:g,children:[u(Hi,{benefits:m}),u(ki,{items:i,listItemSize:r})]})})}))),er=x((({className:e="",__html:t,richVersion:l="striped",...n})=>u(C,{className:e,...n,children:u(zi,{__html:t,richVersion:l})}))),tr=x((({className:e="",isFoldButtonOnTop:t=!1,unfoldedByDefault:l=!1,renderFoldableSection:a,renderFoldButton:r})=>{const[s,o]=n(l),c=i((()=>{o((e=>!e))}),[]),d=a({isUnfolded:s,onToggle:c}),m=r?r({isUnfolded:s,onToggle:c}):null;return p("div",t?{className:e,children:[m,d]}:{className:e,children:[d,m]})})),lr=x((({className:e="",isUnfolded:t,children:l})=>{const n=s(null);return a((()=>{n.current&&(n.current.style.maxHeight=t?`${n.current.scrollHeight}px`:"")}),[t,l?.length]),u("div",{ref:n,className:`transition-max-h duration-300 overflow-hidden ${n.current||!t?"max-h-0":""} ${e}`,children:l})})),nr=(e,t)=>{const{title:l,description:n,buttons:a}=e;return p("div",{className:"py-lg border-b border-main-divider",children:[l?u("div",{className:"opacity-80",children:u(me,{size:"text-m",color:"text-secondary-text",children:l})}):null,n?u("div",{className:"mt-2xs",children:u(me,{size:"text-xl",color:"text-primary-text",children:n})}):null,a?.length?u("div",{className:"text-primary-main",children:Al(a)}):null]},String(t))},ar=x((({className:e="",title:t,align:l="text-center",icon:n,button:a,cardCells:i=[],...r})=>{const s=i.map(nr),o=s.slice(0,1),c=s.slice(1);return p(C,{className:w("flex flex-col",e),defaultPadding:"p-2xl",...r,children:[zl(n)?u("div",{className:"self-center",children:u(cl,{image:n})}):null,t?u(I,{className:w("pt-xs",l),headingType:"h5",title:t}):null,a?u(se,{className:"w-full mt-m mb-lg",...a}):null,i.length?u(tr,{renderFoldableSection:({isUnfolded:e})=>p("div",{children:[o,u(lr,{isUnfolded:e,children:c})]}),renderFoldButton:i.length>1?ir:null}):null]})})),ir=({isUnfolded:e,onToggle:t})=>p("button",{className:"w-full cursor-pointer text-primary-main pt-lg flex justify-between items-center",onClick:t,children:[u("div",{children:e?"Скрыть":"Подробнее о тарифе"}),u(Ae,{className:"text-primary-text",name:e?"ArrowUpIcon":"ArrowDownIcon",width:"16",height:"16"})]}),rr="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",sr="border-gray border-solid border",or="border-main-divider border-b",cr="w-52",dr=x((({icon:e,image:t,title:l,link:n})=>p("div",{className:w("w-80 box-border flex flex-col gap-m items-center rounded-t-md border-b-0 p-2xl",sr,rr),role:"columnheader",children:[e&&!t?.src&&u(cl,{className:"h-16 w-16 min-w-16 min-h-16",image:e,width:"64",height:"64"}),t?.src&&u(cl,{image:t}),l?u(I,{headingType:"h4",as:"h3",className:"text-center text-white",title:l}):null,n?.text&&u("div",{className:"mt-auto w-full",children:u(se,{href:n.href,target:n.target,className:"w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:u("div",{className:"text-xs font-light font-medium py-s",children:n.text})})})]}))),mr={comparison:"flex gap-m duration-1000",tariff:"flex gap-5xl flex-grow duration-1000"},hr=x((({children:e,activeIndex:t,columnWidth:l,version:n="comparison"})=>u("div",{className:"flex flex-1 overflow-hidden",children:u("div",{className:mr[n],style:{transform:`translateX(-${t*l}px)`},children:e})}))),ur=x((({children:e})=>u("div",{className:"self-start flex flex-col",role:"row",children:u("div",{className:"flex gap-xl",children:e})}))),pr=x((({colHeaders:e,activeIndex:t})=>p(ur,{children:[u("div",{className:cr,role:"columnheader"}),u(hr,{activeIndex:t,columnWidth:336,children:e.map(((e,t)=>u(dr,{...e},String(t))))})]}))),xr=x((({cell:e,isFirstRow:t,isLastRow:l,isFillGradient:n})=>{const a=w("w-80 box-border flex flex-col",sr,l?"border-t-0 rounded-b-md":"border-y-0",n?rr:""),i=w("mx-2xl h-full",or,n&&t?"border-t":"",l?"border-b-0":"border-solid");return u("div",{className:a,role:"cell",children:u("div",{className:i,children:e.map(((e,t)=>br(e,t,n)))})})})),gr=(e=!1)=>"text-xl m-0 "+(e?"text-white":""),fr=(e=!1)=>"text-s opacity-80 "+(e?"text-white":"text-secondary-text"),br=({label:e,description:t},l,n)=>p("div",{className:"first:pt-2xl pt-xl last:pb-2xl",children:[e?u("h4",{className:gr(n),children:e}):null,t?u("div",{className:fr(n),children:t}):null]},String(l)),yr=(e=!1)=>w("text-s py-2xl",or,cr,e?"border-b-0":"border-solid"),vr=x((({row:{header:e,data:t},activeIndex:l,isColoredFirstColumn:n,isFirstRow:a,isLastRow:i})=>p(ur,{children:[e?.title?u("div",{className:yr(i),children:e.title}):null,t?.length?u(hr,{activeIndex:l,columnWidth:336,children:t.map(((e,t)=>u(xr,{cell:e,isFirstRow:a,isLastRow:i,isFillGradient:n&&0===t},String(t))))}):null]}))),Nr=x((({rowData:e,isColoredFirstColumn:t,activeIndex:l,controls:n})=>{const{isScrollAvailable:a}=n;return p("div",{className:"relative",children:[e.map(((e,n,{length:a})=>u(vr,{row:e,isFirstRow:0===n,isLastRow:n+1===a,activeIndex:l,isColoredFirstColumn:t},String(n)))),a?an({...n,btnClass:["top-28","top-12"],className:"right-7",isDisabled:!0}):null]})})),wr=x((({columns:e=[],rowHeaders:t,isShowAllRow:l,visibleRowLength:n,isColoredFirstColumn:a})=>{const i=e?.map((({header:e})=>e||{})),r=e?.map((({data:e})=>e))||[],s=t?.map(((e,t)=>({header:e,data:r.map((e=>e?.[t]||[{}]))}))).slice(0,l?t.length:n),[o,c]=en({itemCount:e.length,visibleItemCount:3}),{isScrollAvailable:d}=c;return p("div",{children:[p("div",{role:"table",children:[i?.length?u(pr,{colHeaders:i,activeIndex:o}):null,s?.length?u(Nr,{rowData:s,isColoredFirstColumn:a,activeIndex:o,controls:c}):null]}),d?u("div",{className:"absolute top-0 right-0 bottom-0 w-20 bg-opacity-to-white"}):null]})})),kr=x((({className:e="",title:t,rowHeaders:l,columns:a,visibleRowLength:r=0,isColoredFirstColumn:s=!1,...o})=>{const[c,d]=n(!r),m=i((()=>d((e=>!e))),[]);return p(C,{className:w("overflow-hidden relative",e),defaultPadding:"p-6xl",...o,children:[u(I,{headingType:"h2",className:"text-center mb-4xl mx-auto",title:t}),u(wr,{columns:a,rowHeaders:l,isShowAllRow:c,isColoredFirstColumn:s,visibleRowLength:r}),r?Cr({isShowAllRow:c,onClick:m}):null]})})),Cr=({isShowAllRow:e,onClick:t})=>u("div",{className:"pr-6xl",children:p("div",{className:"flex gap-m w-full",children:[u("div",{className:cr}),u("button",{onClick:t,className:"py-xs flex-1 border-gray border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:u(me,{size:"text-xs",font:"font-medium",children:e?"Скрыть":"Показать все параметры"})})]})}),Sr=x((({className:e,contacts:t,info:l,version:n="secondary",...a})=>p(C,{className:w("flex",e),defaultPadding:"p-6xl",version:n,...a,children:[l?.length?Ir(l):null,t?.length?Ir(t):null]}))),Ir=e=>u("div",{className:"flex gap-5xl grow basis-0",children:e.map(((e,t)=>Tr({column:e,index:t})))}),Tr=({column:e,index:t})=>e?u("div",{className:"flex flex-col gap-xl grow basis-0",children:e.map((({title:e="",description:t,additionalDescription:l,button:n},a)=>p("div",{children:[u(Ol,{title:e,description:t,headlineVersion:"XS",align:"text-left",isEmbedded:!0}),l?u("div",{className:"mt-xs opacity-80",children:u(de,{size:"text-m",font:"font-light",children:l})}):null,n?.href?u(se,{className:"mt-xl",...n}):null]},String(a))))},`col-${String(t)}`):null,Br=x((({textNode:e,iconNode:t,tag:l,onClick:n,justifyContent:a="between",className:i,...r})=>p(l,{tag:l,className:w("flex items-center w-full gap-1","between"===a?"justify-between":"justify-center",i),onClick:n,...r,children:[e?u("div",{children:e}):null,t?u("div",{children:t}):null]}))),Mr=x((({className:e="",label:t,icon:l,dataTheme:n="",disabled:a=!1,onClick:i})=>u(Br,{tag:"button",onClick:i,disabled:a,"data-theme":n,justifyContent:"center",className:w("py-4 border border-transparent outline-none focus:border-primary-text",a?"bg-main-divider text-main-disabled hover:bg-main-divider":"bg-primary-main text-white hover:bg-primary-hove",e),textNode:u("span",{className:"text-h4 pr-s",children:t}),iconNode:l?u(cl,{image:{icon:l,iconVersion:"white"},className:"my-auto",width:"20",height:"20"}):null}))),Pr=({isUnfolded:e,onToggle:t})=>u(Mr,{icon:["ArrowDownIcon","ArrowUpIcon"][Number(e)],label:["Развернуть","Скрыть"][Number(e)],onClick:t}),Rr=x((({title:e,description:t})=>p("div",{className:"bg-white p-6xl py-20 flex gap-s flex-col @xl:items-center",children:[u(cl,{image:{icon:"MagnifierIcon",iconVersion:"normal"},width:"120",height:"120"}),u(Ol,{title:e,description:t,headlineVersion:"S",isEmbedded:!0,align:Sl})]}))),Vr=["ArrowDownIcon","ArrowUpIcon"],zr="space-y-px lg:space-y-0 lg:grid lg:grid-cols-12 gap-2xs border-box",Ar=x((({label:e="",blocksToRender:t=[],topItemsCount:l=0,block:n,notFound:a,...i})=>{const[r,s]=l>0?[t.slice(0,l),t.slice(l)]:[t,[]];return p("div",{children:[u("div",{className:w(t.length?"hidden":"block"),children:a?u(Rr,{...a}):null}),p("div",{className:w("space-y-2xs",t.length?"":"hidden"),children:[u("div",{className:w(zr),children:La(r,{...i.options,parent:n})}),u(tr,{renderFoldableSection:({isUnfolded:e})=>u(lr,{className:w(zr),isUnfolded:e,children:La(s,{...i.options,parent:n})}),renderFoldButton:({isUnfolded:t,onToggle:n})=>u(Mr,{className:w(l<1?"hidden":""),disabled:!s?.length,label:e,icon:Vr[Number(t)],dataTheme:i.options?.page?.colorPalette,onClick:n})})]})]})})),Dr=e=>null==e||""===e||Array.isArray(e)&&0===e.length||"object"==typeof e&&0===Object.keys(e).length,_r=(e,t)=>Object.entries(e).map((([l,n])=>"number"==typeof n?Array.isArray(t[l])?((e,t)=>l=>Dr(t[e])||Dr(l[e])||l[e]?.includes(t[e]))(l,e):((e,t)=>l=>Dr(t[e])||Dr(l[e])||jr(t[e])<=jr(l[e]))(l,e):"object"==typeof n&&"min"in n&&"max"in n?((e,t)=>l=>Dr(t[e])||Dr(l[e])||jr(t[e]?.min)>=jr(l[e]?.min)&&jr(t[e]?.min)<=jr(l[e]?.max))(l,e):Array.isArray(n)?((e,t)=>l=>Dr(t[e])||Dr(l[e])||t[e]?.some((t=>l[e]?.includes(t))))(l,e):((e,t)=>l=>Dr(t[e])||Dr(l[e])||t[e]===l[e])(l,e))).every((e=>e(t))),jr=e=>Number(e||0),Lr=(e,t)=>(l=T)=>e&&e.filter((e=>_r(t,l(e.content||{})))),$r=x((({value:e,onChange:t,items:l=[],multiple:n})=>l.map((l=>u(qe,{text:l.title,value:[e].flatMap((e=>e)).includes(l.value),onChange:()=>(l=>{if(t)if(n){const n=e?.includes(l);t(n?(e||[]).filter((e=>e!==l)):[...e||[],l])}else t(e===l?"":l)})(l.value),type:n?"checkbox":"radio"},l.value))))),Or=({field:e,reset:t,filtrationSchema:l,resetButton:n,children:a})=>p("form",{className:"flex flex-col @4xl:flex-row justify-between bg-white p-4xl gap-s @4xl:gap-0",children:[p("div",{className:"flex flex-col @4xl:flex-row gap-5xl",children:[a,Object.entries(l).map(Er(e))]}),n?u("div",{children:u(se,{className:"w-full @4xl:w-72 @4xl:ml-s",onClick:t,...n})}):null]}),Er=e=>([t,l])=>{const n=l?.type;return"array"===n?Fr(t,e)(l):null},Fr=(e,t)=>l=>{const n=l?.items?.enum?.map(((e,t)=>({value:e,title:l?.items?.enumNames?.[t]||""})))||[];return p("div",{children:[l?.title?u("div",{className:"mb-m",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:l.title})}):null,u($r,{items:n,multiple:!0,...t(e)})]},e)},Ur=(e,t)=>e[t?.sourceBook]?.rateRows.map((e=>e.minMonths)).filter((e=>void 0!==e));async function Hr(...e){const t=e.map((e=>_(e)));return Promise.all(t)}function Wr(e,...t){return e.map(((e,l)=>[e,...t.map((e=>e[l]))]))}const Xr=e=>Boolean(e&&e.content&&"string"==typeof e.content.sourceBook);function Kr(e){const{dirs:t=[],source:l=[]}=r((()=>{const t=(e=>e?.filter(Xr).map((({content:{sourceBook:e}})=>e)))(e);return{dirs:t?.map((e=>`/wcms-resources/${e}.json`)),source:t}}),[e]),{data:n=[]}=A(t,Hr);return{source:Object.fromEntries(Wr(l,n).filter((([,e])=>Boolean(e)))),months:(a=n.flatMap((e=>e?.rateRows||[])).filter((e=>"number"==typeof e.minMonths&&e.minMonths===e.maxMonths)).map((e=>e.minMonths)),[...new Set(a)]).sort(((e,t)=>e-t))||[]};var a}const Yr=1e9,Gr={sum:{min:1e4,max:Yr},period:3},qr=x((({className:e,filtrationSchema:t={},resetButton:l,sumInput:n,periodInput:a,...i})=>{const{source:r,months:s}=Kr(i.block?.blocks),[o,{field:c,reset:d}]=B(Gr),m=Lr(i.block?.blocks,o)((e=>({...e,period:Ur(r,e||{})||[]}))),h=p("div",{children:[u(pa,{label:n?.title,min:500,max:Yr,...c("sum",{parse:e=>({min:Number(e),max:Yr}),format:({min:e})=>String(e)})}),u(yt,{title:a?.title,items:["От 3 мес","До 5 лет"],list:s,...c("period")})]});return p(C,{className:w("space-y-2xs",e),defaultPadding:"p-0",version:"transparent",...i,children:[Or({field:c,reset:d,filtrationSchema:t,resetButton:l,children:h}),u(Ar,{blocksToRender:m,...i})]})})),Jr={type:"string",title:"Адрес справочника"};qr.childrenTypes=["ProductTile"],qr.childSchema=e=>({...e?.filtrationSchema||{},sourceBook:Jr});const Zr=[{key:"10"},{key:"50"},{key:"100"}],Qr=({itemCount:e,onItemCountChange:t})=>{const l=i((({key:e})=>t(Number(e))),[]);return p("div",{className:"flex items-center gap-s",children:[u("span",{children:"Показать по"}),u(He,{className:"min-w-20",onChange:l,value:{key:String(e)},options:Zr,iconVersion:"black"})]})},es="py-m px-lg rounded-md cursor-pointer hover:bg-green-more-dark hover:text-white",ts=(e,t)=>{const{currentPage:l,onPageChange:n,totalPages:a}=e,i=t+1;return i===l?u("div",{"aria-current":"true",className:"py-m px-lg bg-green-light text-white rounded-md",children:i},String(t)):1!==i&&i!==a&&((e,t,l)=>e<t&&e>=t-2||e<=t+2&&e>t||((e,t,l)=>t<=3&&e<=t+3||t>=l-1&&e>=l-4)(e,t,l))(i,l,a)?u("div",{onClick:()=>n(i),className:es,"aria-label":`Страница ${i}`,children:i},String(t)):null},ls={width:"24",height:"24"},ns=({currentPage:e,onPageChange:t,totalPages:l})=>{const n=r((()=>new Array(l).fill({currentPage:e,onPageChange:t,totalPages:l})),[l,e]),a=i((()=>{e>1&&t(e-1)}),[e]),s=i((()=>{e<l-1&&t(e+1)}),[e,l]),o=i((()=>t(1)),[]),c=i((()=>t(l)),[l]);return p("div",{className:"flex gap-m items-center",children:[u("div",{onClick:a,children:u(Ae,{name:"ArrowLeftIcon",iconVersion:"black",imageClassName:as(1===e),...ls})}),p("div",{className:"flex gap-xs",children:[e>1?u("div",{onClick:o,className:es,"aria-label":"Страница 1",children:"1"}):null,e>4?u("div",{className:"py-m px-s",children:"..."}):null,n.map(ts),e<l-3?u("div",{className:"py-m px-s",children:"..."}):null,e<l?u("div",{onClick:c,className:es,"aria-label":`Страница ${l}}`,children:l}):null]}),u("div",{onClick:s,children:u(Ae,{className:"rotate-180",name:"ArrowLeftIcon",iconVersion:"black",imageClassName:as(e===l),...ls})})]})},as=e=>e?"opacity-20":"cursor-pointer hover:opacity-60",is=({currentPage:e,onPageChange:t,totalPages:l,itemCount:n,onItemCountChange:a})=>p("div",{className:"mt-3xl flex justify-between items-center select-none",role:"navigation","aria-label":"Пагинация",children:[u(ns,{currentPage:e,onPageChange:t,totalPages:l}),n&&a?u(Qr,{itemCount:n,onItemCountChange:a}):null]}),rs=x((({className:e,value:t,autoFocus:l,onChange:n,onFocus:a,placeholder:r="Поиск по сайту"})=>{const s=i((e=>{n&&n(e.target?.value||"")}),[n]);return p("div",{className:w("font-sans relative",e),role:"form",children:[u("div",{className:"absolute h-full flex items-center pl-m pointer-events-none",children:u(cl,{image:{icon:"LoupeIcon",iconVersion:"black"},width:"24",height:"24"})}),u("input",{className:w("h-14 w-full px-10 text-l text-black outline-none box-border border border-solid rounded-md","border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text"),value:t,type:"text",name:"search-bar-input",placeholder:r,autoFocus:l,onChange:s,onFocus:a})]})})),ss=x((({field:e,onClearFilter:t,filtrationState:l})=>p("div",{className:"grid grid-cols-12 mb-3xl space-x-xl",children:[u(rs,{className:"col-span-4 mt-auto",placeholder:"Поиск",...e("query")}),u(Jt,{className:"col-span-3",label:"Период от",maxDate:l.endDate,...e("startDate")}),u(Jt,{className:"col-span-3",label:"Период до",minDate:l.startDate,...e("endDate")}),u("div",{className:"col-span-2 mt-auto",children:u("button",{className:"px-m py-s rounded-md bg-main-gray text-green cursor-pointer w-full",onClick:t,children:"Очистить фильтр"})})]}))),os=({title:e,timestamp:t,publicId:l})=>{const n=q({basePath:"/"}),{href:a}=n({href:`/api/v1/depository/${l}/file`});return p("div",{className:"grid grid-cols-12 py-lg border-gray border-opacity-50 border-b",children:[u("div",{className:"col-span-2 text-m",children:t?u(me,{children:Lt(t)}):null}),u("div",{className:"col-span-10 text-h6 hover:text-primary-active",children:u("a",{href:a,download:!0,"aria-label":"Скачать",children:e})})]},l)},cs={startDate:void 0,endDate:void 0,query:""},ds=x((({className:e,...t})=>{const[l,a]=n(0),[r,s]=n(10),[o,{field:c,reset:d}]=B(cs),{totalPages:m=0,items:h}=(({size:e,page:t,query:l,startDate:n,endDate:a})=>{const{data:i}=A(`/api/v1/depository?page=${t}&size=${e}&query=${l}×tampStart=${n?Lt(n,!0):""}×tampEnd=${a?Lt(a,!0):""}`,j);return{items:i?.content,totalPages:i?.totalPages}})({size:r,page:l,...o}),x=i((e=>a(e-1)),[]),g=i((e=>s(e)),[]);return p(C,{className:w(e,"container p-4xl"),...t,children:[u(ss,{filtrationState:o,field:c,onClearFilter:d}),p("div",{className:"flex flex-col",children:[p("div",{className:"grid grid-cols-12 pb-lg border-gray border-opacity-50 border-b",children:[u("span",{className:"col-span-2 text-gray text-m",children:"Дата"}),u("span",{className:"col-span-10 text-gray text-m",children:"Тема"})]}),h?.length?h?.map((e=>u(os,{...e},String(e.publicId)))):u(Rr,{title:"Ничего не найдено",description:"Попробуйте очистить фильтры"}),u(is,{currentPage:l+1,onPageChange:x,totalPages:m+1,itemCount:r,onItemCountChange:g})]})]})})),ms=e=>"Image"===e?.contentType&&e?.image?u(cl,{image:e.image}):"Code"===e?.contentType&&e.code?u("div",{className:"font-mohave text-title-large sm:text-title-extra gradient-color-text",children:e.code}):null,hs=x((({className:e="",title:t,description:l,error:n,button:a,...i})=>p(C,{className:w("flex flex-col justify-center items-center",e),defaultPadding:w("p-6xl"),version:"transparent",...i,children:[u("div",{className:"flex justify-center",children:ms(n)}),u(Ol,{title:t,description:l,headlineVersion:"XL",isEmbedded:!0,className:"mb-2xl last:mb-0"}),a?.text?u(se,{version:a?.version,text:a?.text,...a}):null]})));var us;!function(e){e.RUB="RUB",e.EUR="EUR",e.USD="USD"}(us||(us={}));const ps=new Intl.NumberFormat("ru",{style:"currency",currency:us.RUB}),xs=e=>e?ps.format(e):"",gs="text-left text-m font-light text-secondary-text",fs=`${gs} pl-5xl`,bs={USD:"DollarIcon",EUR:"EuroIcon"},ys=x((({className:e,exchangeCurrencyItems:t})=>p("table",{className:`h-fit w-fit ${e}`,children:[u("thead",{children:p("tr",{children:[u("th",{className:gs,children:u(me,{size:"text-m",children:"Валюта"})}),u("th",{className:fs,children:u(me,{size:"text-m",children:"Купить"})}),u("th",{className:fs,children:u(me,{size:"text-m",children:"Продать"})})]})}),u("tbody",{children:t.map(vs)})]}))),vs=e=>{const t=e?.currency?.currency;return p("tr",{className:"pb-2xs text-h6",children:[u("td",{className:"pt-m",children:p("div",{className:"flex items-center gap-xs",children:[t?u(cl,{image:{icon:bs[t]},width:"24",height:"24"}):null,u(me,{size:"text-h6",children:t})]})}),u("td",{className:"pt-m pl-5xl",children:u(me,{size:"text-h6",children:xs(e?.saleExchangeRate)})}),u("td",{className:"pt-m pl-5xl",children:u(me,{size:"text-h6",children:xs(e?.buyExchangeRate)})})]},t)},Ns={icon:"GpsIcon"},ws=x((({className:e="",address:t})=>p("div",{className:`flex gap-s ${e}`,children:[u(Tl,{...Ns,iconBgVersion:"primary"}),p("div",{className:"space-y-2xs",children:[t?u("p",{className:"text-primary-main text-l",children:t}):null,u("p",{className:"text-secondary-text text-m",children:"Курс указан для заданного офиса"})]})]}))),ks=(e,t,l)=>{const n=Number(Cs(e))*Math.pow(t,l?-1:1);return Number.isInteger(n)?n:((e,t=2)=>{const l=10**t;return Math.round(parseFloat(String(e))*l)/l})(n)},Cs=e=>e.replace(/[^\d.,]/g,"").replace(",","."),Ss=e=>{return(t=[[e=>e.value!==us.RUB&&e.oppositeValue!==us.RUB,()=>e.handleConvert(e.value,us.RUB)],[e=>e.value===us.RUB&&e.oppositeValue===us.RUB,()=>e.handleConvert(e.value,us.USD)],[()=>!0,()=>e.handleConvert(e.value)]],e=>{const[,l]=t.find((([t])=>t(e)))||[];return l})(e)?.();var t};function Is(e){const{placeholder:t,rates:l,selected:n,value:a,setValue:i,setSelected:r}=e,s=l.map((e=>({key:e?.currency?.currency??"",text:e?.currency?.currency??""}))),o={key:n,text:n};return p("div",{className:"relative flex",children:[u(pe,{className:"shrink-0 text-l w-full appearance-none -mr-24",placeholder:t,type:"text",value:a,onChange:i}),s.length?u(He,{isBorder:!1,onChange:e=>r(e.key),options:s,value:o}):null]})}const Ts=x((({className:e="",currencyRatesBuy:t,currencyRatesSell:l,button:a})=>{const[r,s]=n({inputSell:"",inputBuy:"",selectSell:t?.[0]?.currency?.currency||us.RUB,selectBuy:l?.[0]?.currency?.currency||us.USD}),o=i((e=>s((t=>({...t,...e})))),[]);return p("div",{className:`grid gap-m pt-2xl ${e}`,children:[Is({placeholder:"Хочу продать",rates:l,selected:r.selectSell,setSelected:Bs(r,o,l),value:r.inputSell,setValue:e=>Ps(o,l)(e,r.selectSell,r.selectBuy)}),Is({placeholder:"Получу",rates:t,selected:r.selectBuy,setSelected:Ms(r,o,t),value:r.inputBuy,setValue:e=>Rs(o,t)(e,r.selectBuy,r.selectSell)}),a?.text?u(se,{text:a.text,version:a?.version,...a}):null]})})),Bs=(e,t,l)=>n=>{t({selectSell:n}),Ss({value:n,oppositeValue:e.selectBuy,handleConvert:(n=e.selectSell,a=e.selectBuy)=>{Ps(t,l)(e.inputSell,n,a)}})},Ms=(e,t,l)=>n=>{t({selectBuy:n}),Ss({value:n,oppositeValue:e.selectSell,handleConvert:(n=e.selectBuy,a=e.selectSell)=>Rs(t,l)(e.inputBuy,n,a)})},Ps=(e,t)=>(l,n,a)=>{e({inputSell:Cs(l),selectBuy:a});const i=t.find((e=>e.currency?.currency===a))?.buyExchangeRate||t.find((e=>e.currency?.currency===n))?.saleExchangeRate;i&&e({inputBuy:String(ks(l,i,n===us.RUB)||"")})},Rs=(e,t)=>(l,n,a)=>{e({inputBuy:Cs(l),selectSell:a});const i=t.find((e=>e.currency?.currency===a))?.saleExchangeRate||t.find((e=>e.currency?.currency===n))?.buyExchangeRate;i&&e({inputSell:String(ks(l,i,n===us.RUB)||"")})};const Vs=async e=>{const t=await zs(),l=t?.code||"000";return{region:t,exchangeRates:await As(e,l)}},zs=async()=>{try{return await j("/api/v1/region",{method:"GET"})}catch(e){return console.log(e),{}}},As=async(e,t)=>{try{return await j(e+`?regionCode=${t}`,{method:"GET"})}catch(e){return console.log(e),{}}},Ds=x((({className:e="",title:t="Курсы обмена валют",button:l,...n})=>{const{exchangeRates:a}=function(){const{data:e}=A("/api/v1/exchangerates",Vs);return e||{}}(),i=_s(a?.exchangeRate?.currencies),r=i.filter((e=>e.buyExchangeRate));r.unshift({currency:{currency:us.RUB}});const s=i.filter((e=>e.saleExchangeRate));return s.push({currency:{currency:us.RUB}}),u(C,{className:w("box-border min-h-80",e),...n,children:u(li,{className:"h-full",title:u(I,{headingType:"h4",title:t,className:"whitespace-pre-wrap"}),children:p("div",{className:"flex gap-6xl flex-wrap",children:[p("div",{children:[i?u(ys,{className:"mb-xl",exchangeCurrencyItems:i}):null,u(ws,{address:a?.address})]}),i.length&&r.length&&s.length?u(Ts,{className:"grow",currencyRatesBuy:r,currencyRatesSell:s,button:l}):null]})})})})),_s=e=>e?.filter((e=>1===e?.currency?.id||2===e?.currency?.id))||[],js=e=>Vt(d.SITEMAP||"sitemap",{fallback:e}),Ls={width:"40",height:"45"},$s={"bg-white":"color",transparent:"white"},Os={"bg-white":"text-primary-main",transparent:"text-white"},Es=(e,t,l)=>u(cl,t?.src?{image:t,className:Os[e],width:l?.width,height:l?.height,pathPrefix:"/wcms-resources/"}:{image:{icon:t?.icon||"LogoIcon",iconVersion:$s[e]},className:Os[e],width:l?.width,height:l?.height}),Fs={"bg-white":"text-primary-text",transparent:"text-white"},Us=x((({className:e,href:t="/",logo:l,children:n,targetBlank:a,bgColor:i="bg-white",showTitle:r=!0})=>p("a",{className:w("inline-flex items-center font-sans no-underline",e),href:t,target:a?"_blank":"_self","aria-label":l?.title||"Россельхозбанк",children:[Es(i,l?.image,Ls),r?n??u("div",{className:"ml-s",children:u(me,{font:"font-medium",color:Fs[i],size:"",children:l?.title||"Россельхозбанк"})}):null]}))),Hs=x((({className:e,onClose:t})=>u("button",{className:w("flex justify-center items-center w-12 h-12 p-2xs bg-transparent border-none",e),onClick:t,title:"Закрыть",children:u(cl,{image:{icon:"CloseIcon"},width:"24",height:"24"})})));function Ws(e,t,l=300){a((()=>{const t=globalThis.setTimeout(e,l);return()=>{globalThis.clearTimeout(t)}}),t)}const Xs=e=>t=>{if(e===t)return 1;if(!e||!t)return 0;const{m:l,s1Matches:n,s2Matches:a}=function(e,t){const l=Math.max(0,Math.floor(Math.max(e.length,t.length)/2)-1),n=new Array(e.length),a=new Array(t.length);let i=0;for(let r=0;r<e.length;r++){const s=Math.max(0,r-l),o=Math.min(r+l,t.length-1);for(let l=s;l<=o;l++)n[r]||a[l]||e[r]!==t[l]||(i++,n[r]=!0,a[l]=!0)}return{m:i,s1Matches:n,s2Matches:a}}(e,t);if(0===l)return 0;const i=function(e,t,{s1Matches:l,s2Matches:n}){let a=0;for(let i=0,r=0;i<e.length;i++){if(!l[i])continue;let s=r;for(;s<t.length;s++)if(n[s]){r=s+1;break}e[i]!==t[s]&&a++}return a}(e,t,{s1Matches:n,s2Matches:a}),r=(l/e.length+l/t.length+(l-i/2)/l)/3,s=r>.7?.1*function(e,t){let l=0;for(;e[l]===t[l]&&l<4;)l++;return l}(e,t):0;return r+s*(1-r)};const Ks=(e,t)=>(l,n)=>{for(const[a,i]of n)l.set(a,e(l.get(a)||t,i));return l},Ys=e=>e.toLowerCase().split(/[^0-9a-zа-я-]+/).filter((e=>e.length>=3&&!/[0-9a-z]/.test(e))),Gs=e=>t=>e.map((([e,l])=>[Xs(t)(e),l])).filter((([e])=>e>=.8)).map((([e,t])=>Js(t,e))).reduce(Ks(Math.max,0),new Map),qs=e=>t=>{return Wr(t,t.map((({title:e})=>e)).map((e=>t=>{const l=Ys(t||"");return l.length?Pi(e.map((e=>Pn(l.map(Xs(e)))))):0})(e))).sort((n=([,e])=>e,l=(e,t)=>n(e)-n(t),(e,t)=>-l(e,t))).map((([e])=>e));var l,n},Js=(e,t)=>new Map(e.map((e=>[e,t]))),Zs=({basePathList:e,initialQuery:t=""})=>{const[l,i]=n(t||"");a((()=>{null!=t&&i(t)}),[t]);const{data:r}=A(e?.length?e:null,Qs),[s,o]=n(null);return Ws((()=>{r&&o(r.map((e=>t=>{const{corpus:l,dictionary:n}=t||{};if(!(e&&l?.length&&n&&Object.keys(n).length))return[];const a=Ys(e);if(!a.length)return[];const i=Object.entries(n),r=[...a.map(Gs(i)).reduce(Ks(((e,t)=>e+t),0),new Map).entries()].filter((([,e])=>e>=.799*a.length)).map((([e])=>l[e]));return qs(a)(r)})(l)))}),[r,l]),[s,{value:l,onChange:i}]},Qs=async(...e)=>(await Promise.allSettled(e.map((e=>_(H(e,"/","search.index.json")))))).map((e=>"fulfilled"===e.status?e.value:{})),eo=x((({className:e,head:t,children:l,onClose:n})=>{const{close:a}=O(),r=i((()=>{a(),n&&n()}),[n]);return p("div",{className:w("relative min-h-full bg-white pt-0 p-5",e),children:[p("div",{className:"sticky py-xl top-0 bg-white z-10",children:[u(Hs,{className:"absolute top-0 right-0",onClose:r}),u("div",{className:"container",children:t})]}),u("div",{className:"container pb-6xl",children:l})]})})),to=x((({className:e,topItems:t})=>{const l=q({isRemote:!0});return u("div",{className:w("flex items-start justify-between",e),children:t?.map(l).map(no)})})),lo=["all","footer"],no=(e,t)=>{const{text:l,items:n=[],href:a,target:i,onClick:r}=e,s=n.filter((e=>!e.displayArea||lo.includes(e.displayArea.toLowerCase())));return p("div",{className:"flex flex-col gap-s w-1/4",children:[u("a",{className:"leading-5 text-l text-primary-text hover:text-primary-main no-underline",href:a,target:i||"_self",onClick:r,children:l||`Раздел ${t}`}),s.map(((e,t)=>u(ao,{...e,basePath:o(a),index:t},String(t))))]},String(t))},ao=x((({text:e,index:t,basePath:l,...n})=>{const a=q({isRemote:!(!d.BASE_PATH||!l)&&!d.BASE_PATH.startsWith(l),basePath:l}),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-l font-light text-secondary-text hover:text-primary-main no-underline","overflow-x-hidden overflow-ellipsis whitespace-nowrap"),href:i,target:r||"_self",onClick:s,children:e||`Раздел ${t}`})})),io=x((({initialQuery:e})=>{const{topItems:t}=js(),l=r((()=>t?.map((e=>e.href||"/"))),[t]),[n,i]=Zs({basePathList:l,initialQuery:e}),s=r((()=>ro(t)(n)),[t,n]);return a((()=>function(e){for(const t of e.filter((({items:e})=>e?.length)))console.group(t.text),console.table(t.items,["text","href"]),console.groupEnd()}(s)),[s]),u(eo,{head:u(rs,{autoFocus:!0,...i}),children:u(to,{topItems:s})})})),ro=e=>t=>e?.length&&t?.length?Wr(e,t).map((([e,t])=>({...e,items:t?.map((({title:e,uri:t})=>({text:e,href:H("/",t)})))}))):[];const so=()=>{const{open:e,close:t}=O();return{open:(t={},l={})=>e(u(io,{...t}),l),close:t}},oo=x((({className:e})=>{const[t,l]=n(""),a=i((()=>l("")),[]),{open:r}=so(),s=i((e=>{l(e),co(e)&&r({initialQuery:e},{onClose:a})}),[a]);return p("div",{className:w("relative",e),children:[u(rs,{value:t,onChange:s}),u(Hs,{className:"absolute top-0 right-0 sm:hidden",onClose:a})]})})),co=e=>e&&e.length>=3,mo=()=>{const e=globalThis.document?.cookie.split(";")??[];for(const t of e){const[e]=t.split("=");globalThis.document.cookie=`${e}=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/`}},ho=x((({className:e="",items:t})=>p("div",{className:e,children:[t?.length?t.map(uo):null,u(se,{version:"primary",className:"w-full",href:"https://old.rshb.ru/feedback/question/",target:"_blank",ariaLabel:"Обратная связь",text:"Обратная связь"})]}))),uo=(e,t)=>p("div",{className:"mb-m",children:[u("div",{className:"mb-m",children:u(me,{size:"text-l",font:"font-medium",children:e?.title})}),u("div",{children:e.items?.map(po)})]},String(t)),po=(e,t)=>p("div",{className:"mb-m",children:[u("div",{children:xo(e.type,e.text)}),u("div",{className:"mt-2xs text-s font-light text-secondary-text",children:e.description})]},String(t)),xo=(e,t="")=>{switch(e){case"tel":return u("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${go(t)}`,children:t});case"email":return u("a",{className:"text-xl font-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return u("span",{children:t})}},go=e=>e.replaceAll(/\D/g,""),fo=x((({className:e="",index:t,text:l,...n})=>{const a=q(),{href:i,target:r,onClick:s}=a(n);return u("a",{className:w("text-secondary-text",e),href:i,target:r,onClick:s,children:l||`Документ ${t}`})})),bo=x((({className:e="",links:t})=>u("div",{className:e,children:t?.length?u("div",{className:"flex justify-between items-center gap-lg py-lg border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>u(fo,{index:t,className:"text-l font-light max-w-[292px]",...e},String(t))))}):null}))),yo=x((({className:e="",index:t,...l})=>{const n=q({isRemote:!0}),{href:a,target:i,text:r,onClick:s}=n(l);return u("a",{className:`text-xs font-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:a,target:i,onClick:s,children:r||`Документ ${t}`})})),vo=x((({className:e="",links:t})=>p("div",{className:w("@container",e),children:[u("div",{className:"pt-lg",children:u(me,{size:"text-xs",font:"font-light",color:"text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?u("div",{className:"flex flex-col @5xl:flex-row justify-start items-start gap-x-lg gap-y-xs pt-lg",children:t.map(((e,t)=>u(yo,{index:t,...e},String(t))))}):null]}))),No="w-52",wo=x((({className:e,...t})=>{const{topItems:l,logo:n}=js(t.options?.page?.fallback),{documents:a,relatedEnterprises:i,contacts:r,socialMedia:s,mobileApps:o}=Vt(d.FOOTER||"footer",{fallback:t.options?.page?.fallback});return p(C,{tag:"footer",className:e,...t,children:[p("div",{className:"flex items-stretch gap-3xl pb-3xl ",children:[u(Us,{className:No,logo:n}),u(oo,{className:"grow"})]}),p("div",{className:"flex items-stretch gap-6xl",children:[p("div",{className:w(No,"flex flex-col shrink-0 overflow-hidden space-y-xl"),children:[u(ho,{items:r}),u(Zi,{media:s,children:"Соцсети"}),u(Zi,{media:o,showButtonText:!1,children:"Мобильное приложение"}),u(se,{version:"link",href:"https://old.rshb.ru",className:"!text-left text-s font-light",onClick:mo,children:"Вернуться на прежнюю версию сайта"})]}),u(to,{className:"flex-grow",topItems:l})]}),u(bo,{className:"mt-xl",links:i}),u(vo,{links:a})]})})),ko=x((({className:e="",title:t,description:l,calendar:n,...a})=>p(C,{className:w("space-y-m",e),defaultPadding:"p-6xl",...a,children:[u(Ol,{title:t,description:l,headlineVersion:"M",isEmbedded:!0}),n?Co(n):null]}))),Co=e=>{const t=100/(e.reduce(((e,t)=>t?.month?.length?e+t.month.length:e),0)||1),l=e.filter((e=>e?.month?.length)).map((e=>({...e,flexBasis:`${e?.month?.length?e.month.length*t:""}%`})));return p("div",{className:"w-full flex flex-col justify-center gap-s",children:[u("div",{className:"flex w-full text-h6 text-center",children:l.map((e=>So(e,t)))}),u("div",{className:"flex gap-s w-full",children:l.map(((e,t)=>p("div",{className:"border-r border-main-divider last:border-r-0 space-y-s",style:{flexBasis:e.flexBasis},children:[u("div",{className:"flex gap-s",children:Io(e)}),p("div",{className:"text-s font-light text-primary-text",children:[u("span",{children:e.text})," ",u("span",{className:"text-primary-main",children:e.greenText})]})]},`monthItem-${t}`)))})]})},So=(e,t)=>e.month?.map(((e,l)=>u("div",{style:{flexBasis:`${t}%`},children:e.text},`monthName-${l}`))),Io=e=>e.month?.map((e=>e.image?.src?u("div",{className:"h-52 border-r pr-s border-main-divider last:border-r-0",children:u(cl,{image:e.image,className:"flex"})},`monthImage-${e.image.src}`):null)),To=e=>({href:t})=>!!t&&U(E(t)?e.href:e.pathname).startsWith(U(t));function Bo(e=[]){const t=G(),l=e.findIndex((e=>To(d.BASE_PATH?{pathname:d.BASE_PATH}:e))(t));return[l,e[l]]}const Mo=x((({className:e="",active:t,flat:l,children:n,...a})=>{const i=q({isRemote:!0}),{href:r,target:s,text:o,onClick:c}=i(a);return u("a",{className:w(Po(t,l),e),href:r,target:s,onClick:c,rel:"noopener noreferrer","aria-label":o,children:u("span",{className:Ro(t,l),children:o||n})})})),Po=(e=!1,t=!1)=>w("inline-block border border-solid bg-transparent text-center no-underline",e?"rounded-md border-primary-main group-data-transparent:border-white":"border-transparent",t?"":"px-m py-xs"),Ro=(e=!1,t=!1)=>w("font-sans text-s font-light",e?"text-primary-main":w(t?"text-primary-text":"text-secondary-text","hover:text-primary-main"),"group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),Vo="location";function zo(e="Москва"){const[t,l]=((e,t,l)=>{const[r,s]=n(l||null);return a((()=>e.subscribe(t,(e=>s(e)))),[e,t]),[r,i((l=>e.fire(t,l)),[e,t])]})(b,"location",Do()??{name:e}),r=i((e=>{_o(e),l(e)}),[]),{data:s}=A("/api/v1/region",j);return a((()=>{s&&!Ao()&&l(s)}),[s]),[t??{name:e},r]}const Ao=()=>Boolean(globalThis.localStorage?.getItem(Vo)),Do=()=>{try{const e=globalThis.localStorage?.getItem(Vo);return e&&JSON.parse(e)}catch(e){return null}},_o=e=>{try{globalThis.localStorage?.setItem(Vo,JSON.stringify(e))}catch(e){}};const jo=e=>e?.length?p("div",{className:"sm:border-t sm:border-main-divider mt-2xs pt-2xs",children:[u("div",{className:"mb-m",children:u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:"Представительства за рубежом:"})}),u("div",{className:"flex flex-col sm:flex-row gap-5xl",children:e.map(((e,t)=>u(Lo,{...e},String(t))))})]}):null,Lo=x((({icon:e,...t})=>{const l=q(),{text:n,target:a,href:i,onClick:r}=l(t);return p("div",{className:"flex gap-s items-center",children:[e?u(cl,{pathPrefix:"/wcms-resources/",image:e}):null,n?u("a",{className:"hover:text-primary-hover",href:i,target:a,onClick:r,children:u(me,{size:"text-l",font:"font-light",color:"text-primary-text",children:n})}):null]})})),$o=e=>t=>u("div",{className:"mb-xs sm:mb-2xs",children:u("button",{className:"cursor-pointer hover:text-primary-hover",onClick:()=>{e&&e(t)},children:u(me,{size:"text-l",font:"font-light",children:t.name||""})})},t.id),Oo=x((({className:e,searchTerm:t,onSearch:l})=>p("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-m max-w-44 gap-s pointer-events-none",children:t?null:u("label",{htmlFor:"search-bar-input",className:"text-secondary-text ",children:"Поиск по филиалам"})}),u("input",{id:"search-bar-input",className:"h-12 pl-m w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none border-gray hover:border-primary-hover active:border-primary-text focus:border-primary-text",value:t,onChange:e=>l(e.target.value.toLowerCase()),type:"text",name:"location-search-bar-input"})]}))),Eo=x((()=>{const{defaultLocation:e,foreignOffices:t}=js(),[l,a]=zo(e),[r,s]=n(""),o=Uo(function(){const{data:e}=A("/api/v1/regions",j);return e||[]}()).sort(((e,t)=>e.name.localeCompare(t.name))),c=((e,t)=>{const l=new Map;for(const n of e){const e=t(n),a=l.get(e)||[];l.set(e,[...a,n])}return l})(o,Fo),{close:d}=O(),m=i((e=>{a(e),d()}),[]);return p(eo,{className:"pb-20",head:p("div",{children:[u(me,{size:"text-h4",color:"text-primary-text",children:"Выберите филиал"}),l?p("div",{className:"mb-s",children:[u(me,{size:"text-l",font:"font-light",children:"Сейчас выбран: "}),u("button",{onClick:()=>a(l),children:u(me,{color:"text-primary-main",children:l.name})})]}):null,u(Oo,{onSearch:s,searchTerm:r})]}),children:[r&&r.length>=3?u("div",{children:o.filter((({name:e})=>e&&Xs(e.toLowerCase())(r.toLowerCase())>=.8)).map($o(m))}):u("div",{className:"columns-1 sm:columns-5",children:Array.from(c.entries()).map((h=m,([e,t])=>p("div",{className:"break-inside-avoid mb-2xl w-56",children:[u("div",{className:"mb-s",children:u(me,{size:"text-h6",children:e})}),t.map($o(h))]},e)))}),jo(t)]});var h})),Fo=e=>e.name?.charAt(0)||"",Uo=e=>e.map((e=>({...e,name:e.name?.replace(/республика|область|край'/gi,"").trim()||""}))),Ho={default:"w-6 h-6",large:"w-12 h-12"},Wo=x((({className:e,isRounded:t,buttonSize:l="default",isGrayBg:n=!1,disabled:a,ariaLabel:i,image:r,onClick:s})=>u("button",{className:w("group/btn border-0 flex shrink-0 items-center",n?"p-s rounded-full":"p-0 bg-inherit",n&&!t?"bg-main-divider":"",t?"w-8 h-8 text-secondary-light hover:text-secondary-hove":`${Ho[l]} text-primary-text hover:text-primary-main`,"group-data-transparent:text-white",e),type:"button",disabled:a,"aria-label":i,onClick:s,children:u(cl,{image:r,className:w("h-full",t?"bg-main-divider/20 rounded-full":""),imageClassName:"group-hover/btn:text-primary-hover group-hover/btn:invert-0"})}))),Xo=x((({className:e,version:t,officesLink:l,defaultLocation:n})=>{const a="transparent"===t?"white":"black",[r]=zo(n),s=so(),o=i((()=>s.open()),[]),c=(()=>{const{open:e,close:t}=O();return{open:(t={})=>e(u(Eo,{}),t),close:t}})(),d=i((()=>c.open()),[]);return p("div",{className:w("flex items-center gap-lg",e),children:[u(Mo,{flat:!0,href:"#",text:r?.name,onClick:d}),l?u(Mo,{flat:!0,href:l,text:"Офисы и банкоматы"}):null,u(Wo,{image:{icon:"LoupeIcon",iconVersion:a},ariaLabel:"Поиск",onClick:o})]})})),Ko=x((({className:e="",items:t,activeItem:l})=>{const a=q(),[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),c=Oe(i((()=>s(!1)),[]));return p("div",{className:w(r?"bg-white rounded-md shadow-blue-gray":"",e),ref:c,children:[u("button",{className:"group/btn flex justify-between items-center h-6","aria-label":""+(r?"Скрыть другие разделы":"Показать другие разделы"),onClick:o,children:Array(3).fill(null).map(((e,t)=>u("div",{className:"w-[3px] h-[3px] rounded mr-2xs bg-primary-text group-hover/btn:bg-primary-hover group-data-transparent:bg-white"},String(t))))}),u("div",{className:w("absolute flex flex-col rounded-md bg-white p-xl pb-xs",r?"":"hidden"),"aria-hidden":!r,children:t?.map(((e,t)=>{const{text:n,...i}=e;return u("a",{className:w("text-l font-light pb-m hover:text-primary-main",e===l?"text-primary-main":""),...a(i),children:n},e.href||String(t))}))})]})})),Yo=e=>globalThis[e];function Go(e,t){const[l,r]=n(),s=i((()=>r(Yo(e))),[e]);return a((()=>{const l=document.getElementById(t);if(!l){const e=document.createElement("script");return e.src=t,e.async=!0,e.id=t,e.addEventListener("load",s),document.head.appendChild(e),()=>{document.head.removeChild(e),r(void 0)}}if(!Yo(e))return l.addEventListener("load",s),()=>{l.removeEventListener("load",s)};s()}),[e,t]),l}const qo={personal:"//chat.mes.rshb.ru/assets/js/webchat_rshb",business:""},Jo=x((e=>{const[t,{setTrue:l}]=Ve();return t?u(Zo,{...e}):Qo({...e,onClick:l})})),Zo=x((({chat:e="personal",...t})=>((e=>{a((()=>globalThis.localStorage?.setItem("webchat-keep-open",String(Date.now()))),[]),Go("chatbot",qo[e])})(e),Qo(t)))),Qo=({className:e,iconVersion:t,onClick:l})=>u(Wo,{className:w("text-page__btn-chat",e),image:{icon:"HeadphonesIcon",iconVersion:t},ariaLabel:"Чат",onClick:l,buttonSize:"large",isGrayBg:!0}),ec=x((({className:e="",active:t,dataItemName:l,children:n,...a})=>{const i=q(),{href:r,target:s,text:o,onClick:c}=i(a);return p("a",{className:w("relative inline-block bg-transparent text-center no-underline",e),href:r,target:s,"data-item-name":l,onClick:c,children:[u("span",{className:tc(t),children:o||n}),t?u("div",{className:"absolute left-0 right-0 -bottom-3 h-0.5 bg-primary-main group-data-transparent:bg-transparent"}):null]})})),tc=(e=!1)=>w("font-sans text-l font-light",e?"text-primary-main":"text-primary-text hover:text-primary-main","group-data-transparent:text-white group-data-transparent:hover:text-primary-hover"),lc=x((({observerOptions:e,onVisibilityChange:t,children:l,className:n,...a})=>{const r=y(i((e=>{if(!e.length||!t)return;const l=e[e.length-1];t(l.isIntersecting)}),[t]),e);return u("span",{ref:r,className:n,children:u(ec,{...a,children:l})})})),nc={default:"px-lg bg-main-divider rounded hover:text-primary-main",transparent:"text-white hover:text-primary-hover"},ac=x((({version:e,internetBankUrl:t})=>t?u(se,{href:t,ariaLabel:"Интернет-банк",target:"_blank",className:w("py-s ml-s text-l font-light whitespace-nowrap hover:text-primary-main",nc["transparent"===e?"transparent":"default"]),children:"Интернет-банк"}):null)),ic=["all","header"],rc=x((({subItems:e=[],version:t,internetBankUrl:l})=>{const a="transparent"===t?"white":"black",i=G(),o=r((()=>e.filter((e=>!e.displayArea||ic.includes(e.displayArea.toLowerCase())))),[e]),c=(e=>(t=[])=>{const l=t?.filter(To(e));return l?.length?Mn((e=>e.href?.length||0))(l):void 0})(i)(e),[m,h]=n(o.length),x=o.slice(m),g=s(null),f={rootRef:g},b=r((()=>o.map(((e,t)=>e=>{h(e?sc(t):oc(t))}))),[o]);return p("nav",{className:"relative mt-s flex items-center justify-between",children:[u("div",{ref:g,className:"overflow-hidden whitespace-nowrap pb-s mt-xs space-x-3xl",children:o.map(((e,t)=>u(lc,{className:m-1<t?"invisible":"",active:e===c,observerOptions:f,onVisibilityChange:b[t],...e},String(t))))}),x.length?u(Ko,{className:"relative w-auto z-40",items:x,activeItem:c}):null,p("div",{className:"flex",children:[d.CHAT_BOT?u(Jo,{className:"ml-4xl",iconVersion:a,chat:d.CHAT_BOT}):null,u(ac,{version:t,internetBankUrl:l})]})]})})),sc=e=>t=>Math.max(t,e+1),oc=e=>t=>Math.min(t,e),cc={"bg-white":"primary",transparent:"transparent"},dc=x((({className:e,bgColor:t="bg-white",version:l=cc[t],...n})=>{const{topItems:a,logo:i,officesLink:r,defaultLocation:s}=js(n.options?.page?.fallback),[,o]=Bo(a),{internetBankUrl:c}=Vt(d.PORTAL_DATA||"portal-data",{folderName:"portal-resources",setBasePath:!0});return u(C,{tag:"header",className:w("pt-3xl px-20",o?.items?.length?"pb-m":"pb-lg",e),defaultPadding:"",version:l,...n,children:p("div",{className:"container",children:[p("div",{className:"flex items-center",children:[u(Us,{className:"mr-3xl",bgColor:t,logo:i}),a?.map(((e,t)=>u(Mo,{active:e===o,...e},String(t)))),u(Xo,{version:l,className:"ml-auto",officesLink:r,defaultLocation:s})]}),u("div",{className:w("mt-xl h-px bg-main-divider","transparent"===l?"opacity-30":"")}),o?.items?.length?u(rc,{subItems:o.items,version:l,internetBankUrl:c}):null]})})})),mc={XXL:"gap-6xl",XL:"gap-5xl",L:"gap-3xl",M:"gap-m",S:"gap-xs",XS:"gap-2xs","":""},hc=x((({className:e="",gap:t="XS",isPadding:l=!1,version:n="transparent",isTheme:a=!1,isCardBorder:i,...r})=>u(C,{className:w("relative","grid grid-cols-12",mc[t],e),defaultPadding:l?"p-6xl":"",version:n,isTheme:a,...r,children:$a({...r,extraProps:{className:Oa(i)}})})));hc.childrenTypes={exclude:["HorizontalLayout"]};const uc=x((e=>{const{className:t,image:l,...n}=e;return u(C,{className:t,defaultPadding:"p-0",...n,children:u(cl,{image:l})})})),pc=x((({className:e="",cards:t=[],button:l})=>{const[a,r]=n(0),s=i((e=>r(e)),[]),o=t.length,[c,d]=en({itemCount:o,visibleItemCount:2}),{canDec:m,canInc:h}=d,x=t[c]?.href;return p("section",{role:"listitem",className:`min-w-full text-center ${e}`,children:[p("div",{className:"relative overflow-hidden",children:[o?xc({activeIndex:c,cards:t,selectedCardIndex:a,onClick:s}):null,an({...d,btnClass:["left-12","right-12"],className:"top-16"}),m?u("div",{className:"absolute top-0 left-0 h-full w-32 bg-opacity-from-white"}):null,h?u("div",{className:"absolute top-0 right-0 h-full w-32 bg-opacity-to-white"}):null]}),u(se,{className:"w-60 text-center",version:"primary",...l,href:x})]})}));function xc({activeIndex:e,cards:t,selectedCardIndex:l,onClick:n}){const a=460*e,i=t.length>2?"justify-start":"justify-center";return u("div",{style:{transform:`translateX(-${a}px)`},className:"duration-1000 px-6xl",children:u("div",{className:`w-full flex flex-nowrap gap-s pb-6xl ${i}`,children:t.map(((e,t)=>function({slide:e,i:t,isActive:l,onClick:n}){return p("button",{type:"button",onClick:n,className:"p-3xl min-w-fit flex items-center gap-2xl bg-white border-solid border relative "+(l?"shadow-dark-blue border-primary-main":"ease-in duration-300 border-gray"),children:[e?.icon?u(cl,{className:"p-lg rounded-full bg-secondary-light",image:e.icon,width:"108",height:"108"}):null,p("div",{className:"flex gap-s",children:[e?.sum?gc("страховая сумма",e.sum):null,e?.fee?gc("страховой взнос",e.fee):null]}),fc(l)]},String(t))}({slide:e,i:t,isActive:Boolean(t===l),onClick:()=>n(t)})))})})}function gc(e,t){return p("div",{className:"flex flex-col text-left whitespace-pre",children:[p("span",{className:"text-h6",children:[pt(2)(t)," ₽"]}),u("span",{className:"text-secondary-text text-l mt-2xs",children:e})]})}function fc(e){return e?u(cl,{className:"h-6 w-6 min-w-6 min-h-6 absolute right-4 top-4",image:{icon:"DoneIcon"},width:"24",height:"24"}):null}const bc=x((({className:e="",title:t,insuranceTabs:l=[],button:a,...r})=>{const[s,o]=n(0),c=i((e=>o(e)),[]);return p(C,{className:w("box-border overflow-hidden relative px-0 space-y-2xl",e),defaultPadding:"p-6xl",...r,children:[t?u(I,{className:"text-center",title:t,headingType:"h3"}):null,l?.length>1?u("div",{className:"p-xs bg-secondary-light w-fit mx-auto rounded-md",children:l.map(((e,t)=>function({title:e,i:t,isActive:l,onClick:n}){return u("button",{type:"button",onClick:n,"aria-label":e,className:"box-border px-m py-s text-m font-light "+(l?"bg-primary-main text-white rounded-md":"text-secondary-text"),children:e},String(t))}({title:e?.title,i:t,isActive:Boolean(t===s),onClick:()=>c(t)})))}):null,u("div",{className:"flex",style:{transform:`translateX(-${s}00%)`},role:"list",children:yc({insuranceTabs:l,button:a})})]})})),yc=({insuranceTabs:e,button:t})=>{const l=e?.map((e=>e.cards));return l?.length?l.map(((e,l)=>u(pc,{button:t,cards:e},String(l)))):null};const vc=e=>t=>t.reduce(((t,l,n)=>t.length?t.concat({...e,key:`sep-${n}`},l):[l]),[]),Nc={yellow:"bg-yellow",green:"bg-green","green-light":"bg-green-light","green-dark":"bg-green-dark"},wc={XS:"h-10",S:"h-16",M:"h-24",L:"h-32",XL:"h-52"},kc=x((e=>{const{className:t="",items:l,isDotted:n,investmentZeroColumn:a,investmentColumns:i,...r}=e,s=i?[...i]:[];return a&&s.unshift(a),u(C,{className:t,defaultPadding:"p-4xl",...r,children:p("div",{className:"container text-m font-light space-y-4xl",children:[s?.length?p("div",{children:[p("div",{className:"flex items-end relative pl-3xl pr-lg text-white",children:[vc(u("div",{className:"w-px h-4 bg-gray"}))(s.map(Cc)),u("div",{className:"absolute right-3xl w-px h-4 bg-gray"})]}),u("div",{className:"border-t border-gray -mt-xs mx-3xl"}),u("div",{className:"flex justify-between text-primary-text mt-s -mx-5xl",children:s.map(Tc)})]}):null,l?.length?u(ki,{className:"max-w-[657px]",items:l,isDotted:n,listItemSize:"M"}):null]})})})),Cc=(e,t,l)=>{const n=1===t,a=t===l.length-1;return u("div",{className:`${Sc(n,a,e.cells)}`,children:e.cells?.length?u("div",{className:"w-full "+(a?"border-4 border-green-more-dark p-2xs min-w-72":""),children:e.cells.reverse().map(Ic)}):null},`column_${t}`)},Sc=(e,t,l=[])=>[l.length?"flex-1":"flex-0",!l.length||e||t?"":"pl-s",l.length&&!t?"pr-s pb-3xl":"pb-xl"].join(" "),Ic=(e,t)=>{const l=e.cellSize||"XS",n=e.cellColor||"green";return e.text?u("div",{className:`flex-1 flex items-center justify-center relative py-xs ${wc[l]} ${Nc[n]} ${"XS"===l?"px-s":"px-5xl"}`,children:u("div",{className:"text-center",children:e.text})},`cell_${t}`):null},Tc=(e,t)=>u("div",{className:"flex-1 max-w-[180px] text-center px-xs last:pr-3xl",children:e.title},`title_${t}`),Bc=["байт","Кб","Мб","Гб","Тб","Пб"],Mc=x((({icon:e,text:t,fileFormat:l,fileSize:n,...a})=>{const i=l||n?",":"",r=n??"",s=l?String(l):"";return p("a",{className:"flex box-border gap-s group/item h-fit w-fit text-primary-text no-underline hover:text-primary-main",role:"link",...a,children:[e,t?p(me,{size:"text-l",font:"font-light",children:[t,u(me,{color:"text-secondary-text",children:a?.href&&`${r} ${i} ${s}`})]}):null]})})),Pc={double:"sm:flex-wrap sm:flex-row",single:"sm:flex-col"},Rc=x((({className:e="",title:t,description:l,align:n="text-center",documents:a,icon:i={icon:"DocIcon"},columnsMode:r="double",...s})=>{const o=G();return p(C,{className:w("space-y-lg",e),defaultPadding:"p-6xl",...s,children:[u(Ol,{title:t,description:l,align:n,headlineVersion:"M",as:"h2",isEmbedded:!0}),a?.length?u("div",{className:w("grid gap-xl","double"===r?"@md:grid-cols-2":"grid-cols-1",Pc[r]),role:"list",children:a.map(Vc(o,i))}):null]})})),Vc=(e,t)=>(l,n)=>{const a="Attachment"===l?.docType?X(e)(l?.attachment?.src):l?.href,i="Attachment"===l?.docType?((e,t=2)=>{if(0===e)return"";const l=Math.floor(Math.log(e)/Math.log(1024));return`${parseFloat((e/Math.pow(1024,l)).toFixed(t))} ${Bc[l]}`})(l?.attachment?.fileSize||0):l?.fileSize,r="Attachment"!==l?.docType?l?.fileFormat:"";return u("div",{role:"listitem",children:u(Mc,{text:l?.text,target:l?.target,href:a,fileFormat:r,fileSize:i,icon:t?u(cl,{className:"min-w-6 min-h-6",image:t,width:"24",height:"24"}):null})},String(n))},zc=(e,t,l)=>e?.length?u(ki,{items:e,listItemSize:t,className:"text-l font-light"}):u(me,{size:"text-m","font-weight":"font-light",color:"text-secondary-text",children:l}),Ac=x((({className:e,padding:t,align:l="text-left",buttons:n=[],description:a,headingType:i="h4",image:r,items:s,listItemSize:o,qr:c,additionalDescription:d="",title:m="Мобильное приложение",version:h="primary",...x})=>{const g="secondary"===h?"p-m min-w-32":"min-w-24",f=r?.src?u(cl,{className:"hidden lg:block",image:r}):null;return u(C,{className:w("min-h-80",e),padding:"p-0",version:h,...x,children:p(li,{className:"h-full",padding:t,defaultPadding:"p-6xl",title:m?u(I,{headingType:i,title:m,className:w("whitespace-pre-wrap",l)}):null,rightImage:f,buttons:Al(n,{className:"flex-wrap"}),children:[a?u(me,{size:"text-xl","font-weight":"font-light",children:a}):null,p("div",{className:w("gap-m","flex flex-1 flex-col","flex-col items-start @xl:flex-row @xl:items-center"),children:[zc(s,o,d),c?.src?u("div",{className:w("flex justify-center bg-white rounded-md @xl:-order-1",g),children:u(cl,{className:"w-fit",image:c})}):null,r?.src?u(cl,{className:"lg:hidden",image:r}):null]})]})})})),Dc={primary:"bg-white/30",secondary:"bg-main-divider"},_c={primary:"text-white",secondary:"text-secondary-text"},jc=x((({count:e,version:t="secondary"})=>u("div",{className:w("w-6 h-6 rounded-full flex items-center justify-center",Dc[t]),children:u(me,{size:"text-xs",color:_c[t],children:e})}))),Lc=(e=[],t={})=>e.filter((({content:e={}})=>_r(t,e))).length,$c=(e,t)=>e===t;const Oc=(Ec=function(...e){return(t,l)=>e.some((e=>e(t,l)))}($c,((e=$c)=>(t,l)=>t===l||Boolean(t&&l&&t.length===l.length&&t.every(((t,n)=>e(t,l[n])))))()),(e,t)=>e===t||Boolean(e&&t&&Object.keys(e).length===Object.keys(t).length&&Object.entries(e).every((([e,l])=>Ec(l,t[e])))));var Ec;const Fc=[],Uc={},Hc={default:"px-xs",underlined:"px-m",rounded:"px-lg rounded-md"},Wc={default:"text-black sm:text-white",underlined:"text-primary-main border-b-2",rounded:"text-white"},Xc={default:"bg-white",underlined:"bg-white",rounded:"bg-transparent"},Kc={default:"sm:bg-primary-main",underlined:"bg-white",rounded:"bg-primary-main"},Yc=x((({tag:e="div",item:t={},isActive:l,type:n="default",onClick:a})=>{const i=e,{text:r,appendRight:s,...o}=t;return u(i,{className:w("h-12","block flex-1","cursor-pointer",Hc[n],l?Kc[n]:Xc[n]),role:"tab","aria-selected":l,onClick:a,...o,children:p("div",{className:w("h-full","flex justify-center items-center","text-center whitespace-nowrap",l?Wc[n]:"text-secondary-text hover:text-primary-main"),children:[u(me,{size:"text-m",children:r}),s?u("div",{className:"ml-xs",children:s}):null]})})})),Gc=x((e=>u(e?.item?.href?qc:Jc,{...e}))),qc=x((e=>{const t=q(),l=i((()=>{e.onClick&&e.onClick(e.item||{})}),[e.onClick,e.item]),{onClick:n,...a}=t({...e.item,onClick:l});return u(Yc,{...e,tag:"a",item:a,onClick:n})})),Jc=x((({item:e={},onClick:t,...l})=>{const n=i((()=>{t&&t(e)}),[t,e]);return u(Yc,{item:e,onClick:n,...l})})),Zc=(e,t,l)=>(n,a)=>u(Gc,{isActive:n===e,onClick:t,type:l,item:n},String(a)),Qc=x((({className:e,tabsType:t="default",items:l=[],value:n,onChange:a})=>u("div",{className:w("flex gap-x-2xs overflow-x-auto no-scrollbar",e),role:"tablist",children:l.map(Zc(n,a,t))}))),ed={categories:[],extraOptions:[],propertyType:[],stage:[]},td=x((({className:e,hotFilters:t,filtrationSchema:l={},resetButton:n,...a})=>{const[s,{field:o,reset:c,update:d}]=B(ed),m=Lr(a.block?.blocks,s)(),h=i(((e=ed)=>d(e)),[]),x=(({hotFilters:e=Fc,filtrationState:t=Uc,blocks:l=Fc,onFiltrationStateChange:n})=>{const a=r((()=>Math.max(0,e.findIndex((e=>Oc(e.filter,t))))),[e,t]),s=r((()=>e.map((t=>({text:t.text,appendRight:u(jc,{version:t===e[a]?"primary":"secondary",count:Lc(l,t.filter)})})))),[e,l,a]),o=i((t=>{n(e[s.indexOf(t)].filter)}),[e,s]);return{value:s[a],items:s,onChange:o}})({hotFilters:t,filtrationState:s,blocks:a.block?.blocks,onFiltrationStateChange:h});return p(C,{className:w("space-y-2xs",e),defaultPadding:"p-0",version:"transparent",...a,children:[u(Qc,{...x}),Or({field:o,reset:c,filtrationSchema:l,resetButton:n}),u(Ar,{blocksToRender:m,...a})]})}));td.childrenTypes=["ProductTile"],td.childSchema=e=>e?.filtrationSchema||{};const ld=!Boolean("object"==typeof globalThis.process&&globalThis.process&&globalThis.process.version),nd=x((({children:e})=>ld?e:null));function ad(e,t,l){t.geoObjects.removeAll();const n=e.templateLayoutFactory.createClass('<div style="margin-top: -3px;">{{properties.geoObjects.length}}</div>'),a=new e.Clusterer({clusterIcons:[{href:"/icons/MapMarkerClusterIcon.svg",size:[78,84],offset:[-35,-50]}],clusterIconContentLayout:n,clusterHideIconOnBalloonOpen:!1,geoObjectHideIconOnBalloonOpen:!1}),i=l.map((t=>new e.Placemark(t,{},{iconLayout:"default#image",iconImageHref:"/icons/MapMarkerSingleIcon.svg",iconImageSize:[78,84],iconImageOffset:[-35,-50]})));a.add(i),t.geoObjects.add(a),t.setBounds(e.util.bounds.fromPoints(l)).then((()=>{t.getZoom()>10&&t.setZoom(10)}))}const id={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"flex items-center justify-center",font:"text-center font-sans"},rd=e=>u("a",{className:`select-none cursor-pointer px-4xl h-12 bg-primary-main text-white ${Object.values(id).join(" ")}`,href:`https://yandex.ru/maps/?ll=${[e[1],e[0]]}&z=10&l=map`,target:"_blank",children:"Открыть на карте"}),sd={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border border-transparent rounded-md",position:"absolute flex items-center justify-center",font:"text-center font-sans"},od=(e,t,l)=>u("div",{className:`select-none cursor-pointer py-m w-12 bg-white ${Object.values(sd).join(" ")} ${l}`,onClick:()=>{t.geolocation.get({provider:"yandex",autoReverseGeocode:!0,mapStateAutoApply:!0}).then((function(t){e.geoObjects.add(t.geoObjects)}))},children:u(Ae,{name:"UserGeoLocationIcon",width:"20",height:"16"})}),cd={focus:"focus:border-primary-text focus:border",hover:"hover:bg-primary-hover",active:"active:bg-primary-active",border:"border-b border-b-2 border-gray last:border-0",position:"relative flex items-center justify-center",font:"text-center font-sans text-l"},dd=x((({yandexMaps:e,direction:t="in"})=>{const l="in"===t?"PlusIcon":"MinusIcon";return u("div",{onClick:()=>{const l=e.current.getZoom(),n="in"===t?l+1:l-1;e.current.setZoom(n,{checkZoomRange:!0})},className:`${Object.values(cd).join(" ")} bg-white select-none cursor-pointer w-12 h-12`,children:u(Ae,{name:l,width:"20",height:"16"})})})),md={border:"border border-transparent rounded-md ",position:"absolute flex items-center justify-center",size:"w-12 h-12",focus:"focus:border-primary-text focus:border",font:"text-center font-sans",active:"active:bg-primary-active",hover:"hover:bg-primary-hover",other:"select-none cursor-pointer"},hd=[55.753995,37.614069],ud=x((({points:e,className:t="",zoom:l=5})=>{const i=s(null),r=Go("ymaps",`https://api-maps.yandex.ru/2.1/?apikey=${d.YANDEX_MAP_API_KEY||""}&lang=ru_RU`),[o,c]=n(),m=e?pd(e):hd;if(a((()=>{i?.current||r?.ready((()=>{i.current||(i.current=new r.Map("map",{center:m,zoom:l,controls:[],suppressMapOpenBlock:!0}),ad(r,i.current,e))})),i.current&&r&&(ad(r,i.current,e),e?.length||i.current.setCenter(hd))}),[r,i,e,m,l]),!r)return null;const h=o?"z-[100000]":"z-10";return p("div",{id:"map",className:w(!o&&"relative","w-full",t),children:[u("div",{className:w("absolute flex left-2 top-4 w-1/2",h),children:rd(m)}),u("div",{className:w(Object.values(md),h,"right-2 top-4 bg-white"),onClick:()=>{const e=i.current.container;o?e.exitFullscreen():e.enterFullscreen(),c(e.isFullscreen())},children:u(Ae,{name:"FullScreenIcon",width:"16",height:"16"})}),p("div",{className:w("absolute right-2 top-52 z-10 w-12 overflow-hidden border border-transparent rounded-md",h),children:[u(dd,{yandexMaps:i}),u(dd,{yandexMaps:i,direction:"out"})]}),od(i.current,r,w("right-2 top-80",h))]})})),pd=e=>[gd(xd(e,0)),gd(xd(e,1))],xd=(e,t)=>e.map((e=>e[t])),gd=e=>e.length&&e.reduce(((e,t)=>e+t))/e.length,fd={safeBoxCaseVolumes:"Аренда индивидуальных сейфовых ячеек",workingSaturday:"Открыты по субботам",terminalTypeAtms:"Банкоматы",terminalTypeTerm:"Терминалы",workAllTime:"Круглосуточно",billAcceptorEnable:"Прием наличных"},bd=(e,{field:t,reset:l})=>p("div",{className:"pb-2xl",children:[e?.length?u("div",{className:"flex flex-wrap gap-3xl pb-2xl",children:e.map((e=>u(_t,{text:fd[e],...t(e)},e)))}):null,u(se,{version:"transparent",className:"text-secondary-text [&>*]:p-0",onClick:l,text:"Очистить фильтр",appendRight:u(Ae,{name:"CloseIcon",width:"16",height:"16"})})]}),yd=()=>null,vd=()=>[],Nd=x((({className:e,data:t=[],renderCard:l=yd,filterItems:n=vd,initFilterState:a={},descriptionData:i,title:r})=>{const[s,{field:o,reset:c}]=B(a),d=n(t,s),m=d.map((e=>[e.gpsLatitude,e.gpsLongitude].filter(Boolean))).filter((e=>e&&2===e.length)),h=d.length;return p("div",{className:w("space-y-1",e),children:[p("div",{className:"bg-white",children:[p("div",{className:"pt-6xl px-6xl",children:[p("div",{className:"flex gap-xs pb-2xl",children:[u(I,{headingType:"h2",children:r}),h?u(me,{size:"text-h2",color:"text-secondary-text",children:`(${h})`}):null]}),i?wd(i):null,bd(Object.keys(a),{field:o,reset:c})]}),u("div",{className:"h-[600px]",children:u(nd,{children:u(ud,{points:m,className:"h-full"})})})]}),d.map(l)]})})),wd=({description:e,list:t})=>e||t?.length?p("div",{className:"p-xl mb-2xl border border-gray rounded-md",children:[e?u(de,{size:"text-l",font:"font-light",children:e}):null,t?.length?u("div",{className:"flex gap-2xl flex-wrap pt-xs",children:t.map(((e,t)=>p("div",{className:"flex gap-xs items-center",children:[e?.image?u(cl,{image:e.image}):null,e?.text?u(me,{size:"text-m",font:"font-light",children:e.text}):null]},String(t))))}):null]}):null,kd={yellow:{border:"border-yellow-light",text:"text-yellow"},green:{border:"border-green-light",text:"text-green-dark"},gray:{border:"border-gray",text:"text-secondary-text"},red:{border:"border-error",text:"text-error"}},Cd=x((({className:e,children:t,color:l="gray"})=>u("div",{className:w("p-s border border-gray rounded-md flex items-center",kd[l].border,e),children:u(me,{size:"text-m",color:kd[l].text,children:t})}))),Sd=x((({className:e,label:t,value:l,subText:n,subColor:a})=>{const i=l?.split(",")??[];return i.length||n?p("div",{className:w("flex gap-2xs flex-col h-full max-w-[300px]",e),children:[t?u(me,{color:"text-secondary-text",font:"font-light",size:"text-m",children:t}):null,i.filter(Boolean).map(((e,t)=>u(me,{size:"text-l",children:e.trim()},String(t)))),n?u(me,{color:a,size:"text-m",children:n}):null]}):null})),Id=x((({className:e,children:t})=>u("div",{className:w("flex border-t border-solid border-main-divider py-xl gap-x-6xl gap-y-xl",e),children:t}))),Td=({location:e,address:t,billAcceptorType:l,terminalType:n,billAcceptorEnable:a,atmCode:i="",atmAccess:r="",workTime:s},o)=>{const c=[{label:"Устройство",value:Md(n)},{label:"Модуль приема наличных",value:a?"Да":"Нет"},{label:"Прием наличных пачкой",value:"банкомат принимает пачками"===l?"Да":"Нет"},{label:"Доступность",value:["внешняя установка","территория банка"].includes(r)?"Общедоступный":""},{label:"Регистрационный номер",value:i}];return p("div",{className:"bg-white col-span-12 p-3xl border-green border",children:[p("div",{className:"flex justify-between",children:[u(me,{size:"text-h4",children:Md(e)}),u(Cd,{color:"green",children:Md(s)})]}),t?p("div",{className:"flex pb-xl pt-xs gap-2xs",children:[u(Ae,{name:"GeolocationIcon",width:"24",height:"24"}),u(me,{size:"text-l",children:t})]}):null,u(Id,{className:"flex-wrap",children:c?.map(Bd)})]},String(o))},Bd=(e,t)=>u(Sd,{...e},String(t)),Md=e=>e?`${e?.charAt(0)?.toUpperCase()}${e?.slice(1)}`:"",Pd=[];const Rd=async e=>await _(e,{method:"GET"})||Pd,Vd={terminalTypeAtms:!0,terminalTypeTerm:!1,workAllTime:!1,billAcceptorEnable:!1},zd={terminalTypeAtms:e=>"банкомат"===e.terminalType?.toLowerCase(),terminalTypeTerm:e=>"терминал"===e.terminalType?.toLowerCase(),workAllTime:e=>"круглосуточно"===e.workTime?.toLowerCase(),billAcceptorEnable:e=>Boolean(e.billAcceptorEnable)},Ad=x((({data:e,className:t})=>{const[l]=zo(),n=function(e){const{data:t=Pd}=A(`/api/v1/atms?regionCode=${e}`,Rd);return t}(l?.code??"000");return u(Nd,{className:t,filterItems:Dd,data:n,initFilterState:Vd,renderCard:Td,title:`Банкоматы филиала ${l?.name}`,descriptionData:e})})),Dd=(e,t)=>{const l=Object.keys(t).filter((e=>t[e])),n=l.filter((e=>e.startsWith("terminalType"))),a=l.filter((e=>!n.includes(e)));return e.filter((e=>{const t=a.every((t=>zd[t](e))),l=!n.length||n.some((t=>zd[t](e)));return t&&l}))},_d=[["Понедельник","workingMonday"],["Вторник","workingTuesday"],["Среда","workingWednesday"],["Четверг","workingThursday"],["Пятница","workingFriday"],["Суббота","workingSaturday"],["Воскресенье","workingSunday"]],jd=(new Date).getDay(),Ld=({name:e,address:t,phone:l,fax:n,phoneBusiness:a,phoneNatural:i,phoneCallCentre:r,phoneCurrencyControl:s,workSchedule:o,exchangeRate:c},d)=>{const m=o?$d(o):null,[h]=m?.slice(jd-1)??[];return p("div",{className:"bg-white col-span-12 p-3xl border-green border",children:[p("div",{className:"flex justify-between",children:[u(me,{size:"text-h4",children:e}),Ed(h)]}),t?p("div",{className:"flex pb-xl pt-xs gap-2xs",children:[u(Ae,{name:"GeolocationIcon",width:"24",height:"24"}),u(me,{size:"text-l",children:t})]}):null,p(Id,{className:"flex-wrap",children:[u(Sd,{label:"Факс",value:n}),u(Sd,{label:"Телефон филиала",value:l}),u(Sd,{label:"Для обращений юридических лиц",value:a}),u(Sd,{label:"Обслуживание физических лиц",value:i}),u(Sd,{label:"Для консультаций по валютному контролю",value:s}),u(Sd,{label:"Контакт-центр",value:r})]}),m?.length?u(Id,{children:m?.map(Fd)}):null,c?.currencies?.length?u(Id,{className:"flex-wrap",children:c?.currencies?.map(Od)}):null]},String(d))},$d=e=>_d.map((([t,l])=>{const n=["workingSaturday","workingSunday"].includes(l);return{title:t,status:Boolean(e?.[l]),workTime:n?e?.workTimeSaturday:e?.workTime,lunchHour:n?e?.lunchHourSaturday:e?.lunchHour,get hasLunch(){return/\d+/.test(this.lunchHour??"")}}})),Od=({currency:e,buyExchangeRate:t,saleExchangeRate:l},n)=>p("div",{className:"flex gap-lg h-full",children:[e?.currency?u(Sd,{label:"Валюта",value:e.currency}):null,t?u(Sd,{label:"Купить",value:String(t)}):null,l?u(Sd,{label:"Продать",value:String(l)}):null]},String(n)),Ed=e=>{if(!e)return null;const{lunchHour:t,status:l,workTime:n,hasLunch:a}=e;return l?p("div",{className:"flex gap-s",children:[n?u(Cd,{color:"green",children:n}):null,t&&a?u(Cd,{color:"yellow",children:t}):null]}):u(Cd,{color:"red",children:"Выходной"})},Fd=({title:e,status:t,workTime:l,lunchHour:n,hasLunch:a},i)=>u(Sd,{label:e,value:t&&l?l:"",subText:t?n:"Выходной",subColor:!t||a?"text-error":"text-green-dark"},String(i)),Ud=[];const Hd=async e=>await _(e,{method:"GET"})||Ud,Wd={workingSaturday:!1},Xd={workingSaturday:e=>Boolean(e.workSchedule?.workingSaturday)},Kd=x((({className:e})=>{const[t]=zo(),l=function(e){const{data:t=Ud}=A(`/api/v1/branches?regionCode=${e}`,Hd);return t}(t?.code??"000");return u(Nd,{className:e,filterItems:Yd,data:l,initFilterState:Wd,renderCard:Ld,title:`Офисы филиала ${t?.name}`})})),Yd=(e,t)=>{const l=Object.keys(t).filter((e=>t[e]));return e.filter((e=>l.every((t=>Xd[t](e)))))},Gd=x((({data:e,className:t,...l})=>{const n=e?.dataType??"offices";return u(C,{version:"transparent",className:w(t),defaultPadding:"p-0",...l,children:"offices"===n?u(Kd,{}):u(Ad,{data:e})})})),qd=x((({text:e,size:t,align:l,font:n,children:a,...i})=>u(C,{defaultPadding:"p-0",...i,children:u(de,{size:t,align:l,font:n,children:e||a})}))),Jd=(e,t)=>e||t?p("div",{className:"flex flex-wrap xl:flex-nowrap xl:bg-main-divider xl:rounded-md p-xs gap-xl",children:[Number(e)>0?Zd("Страховая сумма",e):null,Number(t)>0?Zd("Ежемесячный лимит",t):null]}):null,Zd=(e,t=0)=>p("div",{className:"basis-full flex flex-col-reverse sm:flex-row sm:justify-between sm:bg-main-divider sm:py-m sm:px-lg sm:rounded-md items-baseline whitespace-pre",children:[u(me,{font:"font-light",size:"text-l",color:"text-secondary-text",children:e}),p("span",{className:"font-sans text-h6 sm:text-primary-main text-primary-text",children:[pt(2)(t)," ₽"]})]}),Qd=x((({className:e,padding:t,headlineVersion:l="M",align:n="text-center",sum:a,monthLimit:i,imageOptions:r,...s})=>u(C,{className:e,padding:"p-0",...s,children:u(Ki,{className:"h-full",defaultPadding:"p-6xl",padding:t,headlineVersion:l,align:n,isFullWidthTitle:!0,imageOptions:{directionRight:!1,imageAlign:"center",...r},...s,children:Jd(Number(a),Number(i))})}))),em=x((({className:e,title:t,description:l="Блок в разработке...",...n})=>p(C,{className:w("box-border",e),...n,children:[u(Ol,{className:"max-w-[600px]",title:t,description:l,headlineVersion:"L",align:"text-left",isEmbedded:!0}),u("figure",{className:"m-0 mt-xl min-w-[80%]",children:tm()})]}))),tm=(e=3)=>nm(100,e).map((e=>Math.floor(e))).map(lm),lm=(e,t)=>u("div",{style:{width:`${e||100}%`},className:"h-4 mt-xs bg-secondary-light"},String(t)),nm=(e,t)=>[e].concat(t>0?nm(e/1.618,t-1):[]);function am(e,t){const l="primary"===e?"white":"black",n="Вернуться назад";return p("div",{className:"hidden sm:flex items-center gap-s",children:[u("div",{className:re({className:"w-12 h-12 min-h-12 min-w-12 flex items-center justify-center",version:e,rounded:!0}),onClick:t,children:u(cl,{className:"w-4 h-4",image:{icon:"ArrowLeftIcon",iconVersion:l}})}),u(se,{version:"link",className:"group-data-secondary:text-white/80",text:n,ariaLabel:n,onClick:t})]})}const im=x((({className:e,padding:t,backwardButton:l,showBorder:n,...a})=>{const r=G(),s=i((e=>{e?.preventDefault(),r.back()}),[]);return p(C,{className:w("overflow-hidden flex flex-col gap-3xl box-border",Oa(n),e),defaultPadding:"p-6xl",padding:t,...a,children:[l?am(a.version&&"primary"!==a.version?"white":"primary",s):null,u(Ki,{className:"grow h-full",...a})]})})),rm=x((({className:e="",padding:t,slides:l=[],...a})=>{const[i,r]=n(0);return p(C,{className:w("box-border overflow-hidden",e),defaultPadding:"py-6xl",padding:t,...a,children:[u("div",{className:"flex duration-1000",style:{transform:`translateX(-${100*i}%)`},role:"list",children:l.map((({productBlock:e},t)=>u("div",{className:"box-border grow-0 shrink-0 basis-full",role:"listitem",children:u(Ki,{className:"pl-6xl h-full",headlineVersion:"M",isFullWidthTitle:!1,...e,...a})},String(t))))}),u("div",{className:"h-28 px-xs mt-m -mb-m flex gap-xs box-border",children:l.map(sm({activeSlideIndex:i,onClick:r}))})]})})),sm=({activeSlideIndex:e,onClick:t})=>({nav:l},n)=>{const a=n===e,i=a?"min-w-[350px] bg-white shadow-dark-blue border-none p-6":"min-w-72 ease-in duration-300 bg-white/10 px-xl py-lg hover:py-xl backdrop-blur",r=a?"text-primary-text text-h6 py-xs":"text-l pb-2xs text-secondary-text group-data-secondary:text-white",s=a?"text-secondary-text text-l font-light":"text-secondary-text text-m font-light group-data-secondary:text-white/80";return p("button",{type:"button",onClick:()=>t(n),"aria-label":l?.title,className:w("relative px-xl box-border overflow-hidden text-left grow basis-0 border border-gray group-data-secondary:border-white/50",i),children:[u("div",{className:r,children:l?.title}),u("div",{className:s,children:l?.description})]},String(n))},om=x((({className:e,padding:t,headlineVersion:l="S",isTabularBenefits:n=!0,additionalDescription:a,imageOptions:i,isFullWidthTitle:r=!0,...s})=>u(C,{className:e,padding:"p-0",...s,children:u(Ki,{className:"h-full",defaultPadding:"p-4xl sm:p-xl",padding:t,headlineVersion:l,isTabularBenefits:n,imageOptions:{isImageSecondary:!0,...i},isFullWidthTitle:r,...s,children:a?u(de,{size:"text-m",font:"font-light",color:"group-data-primary:text-secondary-text",children:a}):null})}))),cm=x((({address:e,email:t,telephone:l,button:n,className:a="",__html:i,icon:r,title:s,version:o="primary",...c})=>p(C,{className:w("box-border text-left space-y-s",a),version:o,...c,children:[p("div",{className:"w-full flex justify-between flex-row-reverse",children:[zl(r)?u("div",{className:"w-10 h-7 sm:w-24 sm:h-16",children:u(cl,{image:r})}):null,s?u(I,{headingType:"h3",as:"h3",title:s}):null]}),p("div",{className:"w-full space-y-m",children:[i?dm(i):null,mm({label:"Адрес",data:e,iconName:"GeolocationIcon"}),mm({label:"Телефон(факс)",data:l,iconName:"PhoneIcon"}),mm({label:"E-mail",data:t,iconName:"MailIcon",dataColor:"text-primary-main"}),n?.text?Al([n]):null]})]}))),dm=e=>u("div",{className:"border-b border-main-divider pb-lg",children:u(zi,{__html:e})}),mm=({label:e,data:t,iconName:l,dataColor:n=""})=>t?p("div",{className:"flex gap-s",children:[u(Ae,{iconVersion:"black",name:l,width:"24",height:"24"}),p("div",{className:"flex flex-col gap-2xs",children:[u(me,{size:"text-m",font:"font-light",color:"text-secondary-text",children:e}),u(me,{size:"text-xl",color:n,children:t})]})]}):null,hm=x((e=>{const{__html:t,richVersion:l,...n}=e;return u(C,{defaultPadding:"p-0",...n,children:u(zi,{__html:t,richVersion:l})})})),um=x((({label:e,labelIconBgVersion:t,icon:l,onToggle:n,labelIcon:a})=>u(Br,{tag:"button",className:w("border-none bg-transparent items-center group/button",a?.icon?"py-xs":"py-lg"),onClick:n,textNode:p("div",{className:"flex items-center text-start group-hover/button:text-primary-main gap-s",children:[null,e?u(me,{size:"text-h6",font:"font-normal",children:e}):null]}),iconNode:l?u(Ae,{name:l,iconVersion:"color",width:"24",height:"24"}):null}))),pm=x((({className:e="",isExpanded:t,isFoldButtonOnTop:l=!0,label:n="Развернуть",labelIcon:a,labelIconBgVersion:i,version:r="primary",...s})=>u(C,{className:w("w-full","border-0 border-b border-solid border-main-divider last:border-b-0",e),defaultPadding:"p-0",tag:"div",version:"transparent",...s,children:u(tr,{isFoldButtonOnTop:l,unfoldedByDefault:t,renderFoldableSection:({isUnfolded:e})=>u(lr,{className:w("gap-lg","grid grid-cols-12 [&>*]:pb-m"),isUnfolded:e,children:$a({...s,extraProps:{className:"w-full",padding:"p-0"}})}),renderFoldButton:({isUnfolded:e,onToggle:t})=>xm({version:r,label:n,labelIcon:a,labelIconBgVersion:i,isUnfolded:e,onToggle:t})})})));pm.childrenTypes={exclude:["RollupItem"]};const xm=({version:e,label:t,labelIcon:l,labelIconBgVersion:n,isUnfolded:a,onToggle:i})=>{const r=t||(a?"Скрыть":"Развернуть"),s=(e=>e?"MinusIcon":"PlusIcon")(a);return"primary"===e?u(um,{label:r,labelIcon:l,labelIconBgVersion:n,icon:s,onToggle:i}):u(Mr,{label:r,icon:a?"ArrowUpIcon":"ArrowDownIcon",onClick:i})},gm=x((({className:e=""})=>{const[t,l]=n("option2"),a=i((e=>l(e)),[]);return p("div",{className:w("order-4",e),children:[u(dl,{className:"mb-xs",name:"contractType",text:"Простое хранение",value:"option1",checked:"option1"===t,onChange:a}),u(dl,{name:"contractType",text:"Сделка с недвижимостью",value:"option2",checked:"option2"===t,onChange:a})]})})),fm=x((({data:e,fieldLabel:t,fieldValue:l,selected:n,placeholder:a="",setSelected:i,label:r})=>{const s=e.filter(Boolean).map((e=>({key:e?.[l||t],text:e?.[t]}))),o=s.find((e=>e.key===n));return u(He,{options:s,label:r,placeholder:a||n,onChange:e=>i(e.key),value:o})})),bm=x((({regions:e=[],selectedRegion:t,onSelectedRegion:l,branches:n=[],selectedBranch:a,onSelectedBranch:i})=>p("div",{className:"flex flex-col @xl:flex-row gap-m order-1",children:[u("div",{className:"flex-1 min-w-0",children:u(fm,{data:e,fieldValue:"code",fieldLabel:"name",selected:t,setSelected:l,label:"Регион"})}),u("div",{className:"flex-1 min-w-0",children:u(fm,{data:n,fieldValue:"branchCode",fieldLabel:"address",selected:a,setSelected:i,label:"Отделение",placeholder:"Выберите отделение"})})]}))),ym=["От 1 дня","До 365 дней"],vm=x((({days:e,setDays:t})=>p("div",{className:"order-1",children:[u(me,{size:"text-m",font:"font-light",children:"Срок аренды"}),u(yt,{min:1,max:365,value:e,items:ym,onChange:t})]}))),Nm=x((({caseVolumes:e=[],selectedCaseVolume:t,onSelectedCaseVolume:l,safeBoxCases:n=[],selectedBoxSize:a,onSelectedBoxSize:i})=>p("div",{className:"flex flex-col @xl:flex-row gap-m order-1",children:[u("div",{className:"flex-1 min-w-0",children:u(fm,{data:e,fieldLabel:"volume",selected:t,setSelected:l,label:"Размер",placeholder:"Выберите размер"})}),u("div",{className:"flex-1 min-w-0",children:u(fm,{data:n,fieldLabel:"safeBoxCasesSize",selected:a,setSelected:i,label:"Параметры ячейки, мм (ВхШхД)",placeholder:"Выберите параметр ячейки"})})]}))),wm=x((({regions:e,selectedRegion:t,branches:l,selectedBranch:n,days:a,selectedCaseVolume:i,selectedBoxSize:r,safeBoxCases:s,caseVolumes:o,onChange:c,onClick:d})=>p("div",{className:"contents @xl:block flex-1 space-y-xl",children:[u(bm,{regions:e,selectedRegion:t,onSelectedRegion:e=>c({selectedRegion:e}),branches:l,selectedBranch:n,onSelectedBranch:km(c)}),u(vm,{days:a,setDays:e=>c({days:e})}),u(Nm,{caseVolumes:o,selectedCaseVolume:i,onSelectedCaseVolume:Cm(c),safeBoxCases:s,selectedBoxSize:r,onSelectedBoxSize:e=>c({selectedBoxSize:e})}),u("div",{className:"order-4",children:u(me,{size:"text-l",font:"font-light",color:"text-secondary-text",children:"Тип договора"})}),p("div",{className:"contents @md:flex justify-between items-center gap-m",children:[u(gm,{}),u(se,{text:"Офисы на карте",version:"primary",onClick:d,className:"order-6"})]})]}))),km=e=>t=>{e({selectedBranch:t,selectedCaseVolume:"",selectedBoxSize:""})},Cm=e=>t=>{e({selectedCaseVolume:t,selectedBoxSize:""})},Sm=x((({days:e,tariffs:t=[]})=>{const l=Tm(e,t),n="На рисунке изображена пачка листов\nформата А4";return p("div",{className:"contents @xl:flex flex-col justify-between gap-xl order-2",children:[p("div",{className:"flex flex-col @xl:flex-row gap-x-6xl gap-y-2xl order-5 @xl:order-none py-2xl @xl:py-0 border-t border-main-divider @xl:border-none",children:[Im("Аренда за",e),Im("Цена",l+" ₽")]}),u("span",{className:"@xl:hidden order-3 mb-xs text-s font-light text-secondary-text",children:n}),p("div",{className:"flex flex-col items-center gap-s order-3 @xl:order-none mb-xl @xl:mb-0 bg-primary-main py-s @xl:p-3xl text-center",children:[u(cl,{image:{icon:"PackA4Icon"},className:"@xl:h-60"}),u("span",{className:"hidden @xl:inline text-s font-light text-white opacity-80 whitespace-pre-line",children:n})]})]})})),Im=(e,t)=>p("div",{className:"flex justify-between items-center gap-y-xs @xl:flex-col @xl:items-start",children:[u("div",{className:"text-l font-light text-secondary-text",children:e}),u("span",{className:"text-l @xl:text-h3 text-primary-text",children:t})]}),Tm=(e,t)=>{const l=Bm(e);return e*(t?.find((e=>e.tariffType===String(l)))?.tariffValue||0)},Bm=e=>{let t=1;switch(!0){case e>30&&e<=90:t=2;break;case e>90&&e<=180:t=3;break;case e>180&&e<=365:t=4}return t},Mm=(e,t)=>e.find((e=>e.branchCode===t)),Pm=x((e=>{const{regions:t,data:l,branches:n,onChange:i,onClick:r}=e;a((()=>{i({selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:""})}),[l.selectedRegion,i]);const s=Mm(n,l.selectedBranch),o=Rm(s?.safeBoxCaseVolumes),c=Vm(s?.safeBoxCaseVolumes,l.selectedCaseVolume)?.safeBoxCases,d=zm(c,l.selectedBoxSize);return p("div",{className:"flex flex-col @4xl:flex-row gap-4xl align-top",children:[u(wm,{...l,regions:t,onClick:r,branches:n,caseVolumes:o,safeBoxCases:c,onChange:i}),u(Sm,{days:l.days,tariffs:d})]})})),Rm=e=>e?.length?e?.filter((e=>e?.safeBoxCases?.length)):[],Vm=(e,t)=>e?.find((e=>e.volume===t)),zm=(e,t)=>e?.find((e=>e.safeBoxCasesSize===t))?.tariffs,Am=[];const Dm=async e=>await _(e,{method:"GET"})||Am,_m=x((({title:e,footnote:t,className:l="",...a})=>{const[r,s]=n(!1),o=i((()=>s((e=>!e))),[]),[c,d]=n({selectedRegion:"",selectedBranch:"",selectedCaseVolume:"",selectedBoxSize:"",days:26}),m=$(),h=jm(c.selectedRegion,m),x=function(e){const{data:t}=A(e?`/api/v1/safeboxes?regionCode=${e}`:null,Dm);return t||Am}(h),g=i((e=>d((t=>({...t,...e})))),[d]),f=(b=Mm(x,c.selectedBranch)||x,Array.isArray(b)?b.map((e=>e.gpsLatitude&&e.gpsLongitude?[e.gpsLatitude,e.gpsLongitude]:[])):b?.gpsLatitude&&b?.gpsLongitude?[[b.gpsLatitude,b.gpsLongitude]]:[]);var b;return p(C,{className:l,defaultPadding:"",...a,children:[p("div",{className:"p-4xl space-y-xl",children:[e?u(I,{title:e,headingType:"h3",as:"h2",className:"text-primary-text mb-s text-center"}):null,u(Pm,{regions:m,branches:x,data:{...c,selectedRegion:h},onClick:o,onChange:g}),t?u(de,{size:"text-s",font:"font-light",children:t}):null]}),f.length&&r?u(ud,{points:f,className:"h-[640px]"}):null]})})),jm=(e,t)=>!e&&t?.length&&t[0]?.code?t[0].code:e,Lm=({styleMap:e,isMainButton:t,version:l})=>(n,a,i)=>{const{label:r,description:s,button:o,items:c,isDotted:d}=n;return p("div",{className:w("relative flex flex-col items-center text-center justify-between whitespace-pre-line overflow-hidden space-y-3xl",$m(i.length)),children:[p("div",{className:"text-center space-y-xs",children:[r?u("div",{children:u(me,{size:"text-h6",children:r})}):null,p("div",{className:"flex flex-col items-center gap-3xs",children:[s?u("div",{className:e.description,children:s}):null,u(ki,{className:e.description,items:c,listItemSize:"M",isDotted:d})]})]}),o?.text&&!t?u(se,{className:"box-border py-s w-full max-w-60 mt-auto",version:l,...o,children:o?.text}):null]},String(a))},$m=e=>e<5?"w-72":"w-52",Om={description:"text-white/80 text-l font-light group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconText:"text-white group-data-primary:text-secondary-text group-data-gray:text-secondary-text",iconBackground:"bg-white/30 group-data-primary:bg-main-divider",iconConnector:"bg-white group-data-primary:bg-secondary-light",dot:"bg-white/80 group-data-primary:bg-secondary-text"},Em=x((({className:e="",showLines:t=!0,steps:l=[],buttons:n,size:a="normal",version:i="primary",stepVersion:r="gray",title:s,description:o,...c})=>{const d=l.length>3,m=Om,h=(e=>e?"":"opacity-0")(t),x=(e=>e<5?"px-24":"px-16")(l.length),g=Boolean(n?.every((e=>e?.text)));return p(C,{className:w("box-border flex flex-col items-center overflow-hidden gap-y-3xl",e),defaultPadding:"p-6xl",version:i,...c,children:[u(Ol,{headlineVersion:"S",title:s,description:o,isEmbedded:!0,className:"w-full"}),l?.length?p("div",{className:"box-border space-y-lg",children:[u("div",{className:w("flex items-center",x),children:vc(u("div",{className:w("h-0.5 w-full bg-secondary-light flex-1",h)}))(l.map(Fm(m,a,r)))}),u("div",{className:w("flex justify-between",d?"gap-x-s":"gap-x-20"),children:l.map((f={styleMap:m,isMainButton:g,version:i},(e,t,l)=>{const{type:n}=e;if("default"!==n&&"rte"!==n)return null;switch(n){case"default":return Lm(f)(e,t,l);case"rte":return u("div",{className:w("text-center",$m(l.length)),children:u(zi,{__html:e.__html})},String(t));default:return null}}))})]}):null,Al(n)]});var f})),Fm=(e,t,l)=>({icon:n},a)=>{const i="secondary"===l?"white":"color";return u(C,{defaultPadding:"",className:`${Um(t)} flex justify-center items-center text-center rounded-full box-border z-10`,version:l,children:zl(n)?u(cl,{image:{...n,iconVersion:n?.iconVersion||i},width:"48",height:"48"}):u("span",{className:w("text-h4","transparent"===l?e.iconText:Hm(l)),children:a+1})},String(a))},Um=e=>"normal"===e?"h-24 w-24":"h-16 w-16",Hm=e=>"secondary"===e?"group-data-primary:text-white":"text-secondary-text",Wm=x((()=>u("div",{}))),Xm=x((({className:e,version:t,gap:l=14,padding:n=16,showDots:a=false,minHeight:i,children:r,onVisibleIndicesChange:s,listType:o="horizontal-list"})=>{const c=Array.isArray(r)?r.length:0,[d,m]=Ma({itemCount:c,onVisibleIndicesChange:s}),[h]=m.visibleIndicesRange;return p("div",{className:w(e,"vertical-list"===o?"relative h-full":""),children:[u(Na,{containerRef:d,activeIndex:h,visibleItemCount:1,gap:l,padding:n,onVisibleIndicesChange:m.handleVisibleIndicesChange,listType:o,minHeight:i,children:r}),a?u(Ia,{containerRef:d,activeIndex:h,dotCount:c,listType:o,version:t}):null]})})),Km=x((({listType:e,showDots:t,options:l,version:n,...a})=>u(C,{version:n,defaultPadding:"p-0",...a,children:u(Xm,{listType:e,showDots:t,version:n,children:$a({...a,options:l})})})));Km.childrenTypes={exclude:["SwipeListControlBlock"]};const Ym="hidden sm:flex absolute z-40 top-0",Gm=x((({className:e,items:t=[],value:l,onChange:n,tabsType:a})=>{const[i,r]=Ma({itemCount:t?.length||0});return p("div",{className:w("relative overflow-x-auto no-scrollbar",e),role:"tablist",children:[u(Na,{containerRef:i,snapAlign:"snap-start",onVisibleIndicesChange:r.handleVisibleIndicesChange,children:t.map(Zc(l,n,a))}),r.canScrollLeft?u(ln,{className:w("left-6",Ym),onClick:r.scrollLeft}):null,r.canScrollRight?u(nn,{className:w("right-6",Ym),onClick:r.scrollRight}):null]})})),qm=({tabsMode:e,...t})=>{switch(e){case"wideScreen":return u(Qc,{...t});case"centered":return u("div",{className:"flex",children:u(Qc,{className:"m-auto p-xs rounded-md bg-main-gray",tabsType:"rounded",...t})});case"scrollable":return u("div",{className:"flex",children:u(Gm,{className:"m-auto",tabsType:"underlined",...t})});default:return null}},Jm="tab",Zm=x((({className:e="",isSticky:t,tabs:l=[],tabsMode:s,...o})=>{const c=G(),{isReady:d}=c,m=r((()=>l.map(eh)),[l]),[h,p]=n(0);a((()=>{if(!l||!l[0])return;const e=c.query.tab&&l.findIndex((e=>"group"===e.type&&e.ref===c.query.tab))||0,t=l[e]||l[0];p(e),Qm(t)}),[d]),a((()=>{const e=l[h];"group"===e?.type&&b.subject("tab",{type:e.type,label:e.ref})}),[l,h]);const x=i((e=>{const t=m.indexOf(e),n=l[t];p(t),Qm(n),"group"===n.type&&(e=>{const t=new URLSearchParams(c.query);e.name?t.set(Jm,e.name):t.delete(Jm),c.replace(`${c.pathname}?${t}`,"",{scroll:!1})})(e)}),[l,m]);return u(C,{className:w(t?"sticky top-1 z-20":"",e),defaultPadding:"p-0",...o,children:qm({items:m,value:m[h],tabsMode:s,onChange:x})})})),Qm=e=>{"group"===e.type&&b.fire("tab",{type:e.type,label:e.ref}),"link"===e.type&&b.fire("tab",{type:e.type,label:e.href})},eh=e=>"group"===e?.type?{text:e.title,name:e.ref}:e,th=x((({className:e="",isOpen:t,onClick:l})=>u(se,{className:e,appendRight:u(cl,{image:{icon:t?"ArrowUpIcon":"ArrowDownIcon"},width:"20",height:"20"}),text:t?"Скрыть":"Показать",version:"gray",onClick:l}))),lh={Buttons:({buttons:e})=>Al(e,{buttonClassName:"basis-0"}),Img:({image:e})=>e?.src?u(cl,{image:e}):null,List:({isDotted:e,...t})=>u(ki,{className:"flex flex-col justify-between items-start text-h6",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>p("div",{className:"space-y-2xs",children:[e?u("div",{children:e}):null,t?u("div",{children:u(me,{size:"text-s",color:"text-secondary-text",children:t})}):null]}),Table:({isVisible:e,displayTable:t,dataUrl:l,pdfUrl:n,isOpen:a})=>e?u(th,{isOpen:a,onClick:()=>{t({dataUrl:l,pdfUrl:n})}}):null},nh=({rowIdx:e,cellIdx:t,setTableInner:l,tableInner:i,openTableInnerIdx:r,setOpenTableInnerIdx:s})=>(o,c)=>{const[d,m]=n(!0);a((()=>{t===r&&i||m(!0)}),[i,r]);return u("div",{children:ah({cell:o,cellProps:{rowIdx:e,cellIdx:t,fieldIdx:c,displayTable:e=>{m(!1),s(t),l(e)},isVisible:d}})},String(c))},ah=({cell:e,cellProps:t})=>{if(!e)return null;const{tableCellType:l,...n}=e;if(!l||!(l in lh))return null;return u(lh[l],{...t,...n})},ih=x((({cells:e,rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})=>u("div",{className:"w-80 flex-grow flex flex-col gap-m @4xl:gap-lg",role:"cell",children:e?.length?e.map(nh({rowIdx:t,cellIdx:l,setTableInner:n,tableInner:a,openTableInnerIdx:i,setOpenTableInnerIdx:r})):null}))),rh=(e,t)=>140*Pi(e.slice(0,t).map((e=>e?.cols?.length??1))),sh=(e,t)=>e?.length>0?u("div",{className:w("flex",0===t?"text-secondary-text":""),children:e.map(((e,t)=>u("div",{className:"w-20 text-h6 mx-lg",children:e},String(t))))}):null,oh=x((({rows:e})=>{const t=e?.[0]?.length??0,[l,n]=en({itemCount:t,visibleItemCount:5});return p("div",{children:[e?.map((a=l,(e,t)=>{if(!e?.length)return null;const[l,...n]=e,i=w("flex duration-1000 text-center",0!==t?"font-normal":"font-light");return p("div",{className:"flex border-main-divider border-b border-solid h-full",children:[l?.data?u("div",{className:"text-xl font-light w-56 min-w-56 py-lg",children:l.data}):null,u("div",{className:"flex flex-grow overflow-hidden",children:u("div",{className:i,style:{transform:`translateX(-${rh(n,a)}px)`},children:n?.map(((e,t)=>p("div",{className:"flex flex-col flex-grow gap-s justify-center py-xl odd:bg-main-divider",children:[e?.data?u("div",{className:"text-xl font-light",children:e.data}):null,e?.cols?sh(e.cols,a):null]},`row${t}`)))})})]},String(t))})),an({...n,btnClass:["left-3 top-20","right-3 top-20"],className:""})]});var a})),ch=x((({activeTabIndex:e,items:t})=>u("div",{children:t.map(((t,l)=>{const n=`activeTabIdx:${e}-tableIdx:${l}`;return p("div",{className:"w-full @container",children:[u("div",{className:"flex p-m bg-white @4xl:bg-gray text-center justify-center relative",children:u(me,{size:"text-xl",font:"font-light",children:t.title})}),u("div",{className:"w-full pl-xs overflow-hidden transition-height duration-500 ease-in-out",children:u("div",{className:"relative",children:u(oh,{rows:t.rowsData})})})]},n)}))}))),dh=x((({currencies:e,linkToPDF:t,activeTabIndex:l,setActiveTabIndex:n})=>p("div",{className:"flex justify-between items-center w-full py-lg",children:[e&&e.length>1?u("div",{className:"flex bg-secondary-light p-2xs rounded-md",children:e.map(((e,t)=>u("div",{className:"rounded-md text-xl font-light px-4 py-3 cursor-pointer "+(t===l?"bg-primary-main text-white":"text-secondary-text"),onClick:()=>n(t),children:e||t+1},e)))}):null,t?u(se,{className:"text-primary-main",href:t,version:"secondary",target:"_blank",appendLeft:u(Ae,{name:"DocDownloadIcon",iconVersion:"color",className:"mr-3xs",width:"20",height:"20"}),text:"Скачать в PDF"}):null]})));async function mh(e){const t=await fetch(e);return await t.json()}const hh=x((({dataUrl:e,pdfUrl:t,onClick:l})=>{const{tableData:a}=function(e){const{data:t}=A(function(e){return`/wcms-resources/${e||"tariffs-inner-table-data"}.json`}(e),mh);return t||{}}(e),[r,s]=n(0),o=i((e=>s(e)),[]),c=a?.[r]?.items??[],d=a?.map((e=>e.currency??""));return p("div",a?{className:"bg-white z-10",children:[u(dh,{currencies:d,activeTabIndex:r,setActiveTabIndex:o,linkToPDF:t}),u(ch,{activeTabIndex:r,items:c}),u(th,{className:"mt-xl",onClick:l,isOpen:!0})]}:{className:"my-lg space-y-m text-h6 text-center",children:[u("p",{children:"Данных нет"}),u(th,{onClick:l,isOpen:!0})]})})),uh=x((({children:e,tableInner:t,onHideContentClick:l})=>p("div",{className:"self-start flex flex-col",role:"row",children:[u("div",{className:w("@4xl:border-main-divider @4xl:border-b","flex flex-col @4xl:flex-row gap-y-xs gap-x-5xl pb-lg @4xl:pt-lg"),children:e}),t?u("div",{className:"origin-top animate-expansion",children:u(hh,{...t,onClick:l})}):null]}))),ph=x((({row:{header:e,data:t},activeIndex:l,rowIdx:a,...r})=>{const[s,o]=n(void 0),c=i((e=>o(e)),[]),[d,m]=n(void 0),h=i((e=>m(e)),[]);return p(uh,{onHideContentClick:()=>o(void 0),tableInner:s,...r,children:[u("div",{className:w("text-s","w-80 flex-shrink-0"),children:p("div",{className:"flex gap-m items-center text-primary-text",role:"cell",children:[e?.icon?u(cl,{className:"hidden @4xl:block max-w-6",image:e.icon,width:"24",height:"24"}):null,e?.title?u("div",{className:"text-m font-light",children:e?.title}):null]})}),t?.length?u(hr,{activeIndex:l,columnWidth:360,version:"tariff",children:t.map(((e,t)=>u(ih,{cells:e,rowIdx:a,cellIdx:t,setTableInner:c,tableInner:s,openTableInnerIdx:d,setOpenTableInnerIdx:h,...r},String(t))))}):null]})})),xh=x((({children:e,controls:t})=>{const{isScrollAvailable:l}=t;return p("div",{role:"table",children:[p("div",{className:"relative space-y-xs",children:[e,an({...t,btnClass:["top-28","top-11"],className:"right-7"})]}),l?u("div",{className:"absolute top-0 right-0 bottom-0 w-20 bg-opacity-to-white"}):null]})})),gh=x((({className:e="",title:t,description:l,rowHeaders:n,tariffsColumns:a,hiddenRowsNum:i=0,...r})=>{const s=a?.map((({data:e})=>e))||[],o=n?.map(((e,t)=>({header:e,data:s.map((e=>e?.[t]||[]))}))),c=s.length,[d,m]=en({itemCount:c,visibleItemCount:2}),h=(o||[]).map(((e,t)=>u(ph,{row:e,activeIndex:d,rowIdx:t,...r},String(t)))),[x,g]=i>0?[h.slice(0,-i),h.slice(-i)]:[h,[]];return p(C,{className:w("overflow-hidden relative space-y-6xl @4xl:space-y-xl",e),defaultPadding:"p-6xl",...r,children:[u(Ol,{title:t,description:l,headlineVersion:"M",isEmbedded:!0,align:"text-center"}),u("div",{className:"space-y-m",children:i>0?u(tr,{renderFoldableSection:({isUnfolded:e})=>p(xh,{controls:m,children:[x,u(lr,{isUnfolded:e,children:g})]}),renderFoldButton:Pr}):u(xh,{controls:m,children:h})})]})})),fh=x((({className:e="",title:t,description:l,iconVersion:n,image:a,__html:i,items:r=[],...s})=>p(C,{className:w("flex gap-s sm:gap-m bg-white group-data-secondary:bg-primary-main/10",e),...s,children:["small"===n?bh():null,"big"===n?yh(a):null,p("div",{className:"flex flex-col w-fit gap-2xs sm:gap-xs",children:[t?u(me,{size:"text-l",font:"font-normal",color:"text-primary-text group-data-secondary:text-white",children:t}):null,l?vh(l):null,r?.length?Nh(r,!0):null,i?u(zi,{__html:i}):null]})]}))),bh=()=>u("div",{className:"rounded-full h-4 w-4 text-center text-xs font-light bg-primary-main text-white group-data-secondary:bg-white group-data-secondary:text-primary-main",children:"i"}),yh=e=>e?.src?u(cl,{className:"h-fit flex-shrink-0",image:e}):null,vh=e=>u(de,{size:"text-s",font:"font-light",color:"text-secondary-text group-data-secondary:text-white",children:e}),Nh=(e,t)=>u("ul",{className:w("text-secondary-text group-data-secondary:text-white/80",t?"list-disc pl-xl":""),children:e.map(((e,t)=>u("li",{children:u(me,{size:"text-s",font:"font-light",children:e})},`listItem-${t}`)))}),wh=x((({className:e,padding:t,headlineVersion:l="S",listItemSize:n="M",...a})=>u(C,{className:e,padding:"p-0",...a,children:u(Ki,{className:"h-full",defaultPadding:"p-xl",padding:t,headlineVersion:l,listItemSize:n,isFullWidthTitle:!1,...a})}))),kh=x((({className:e="",gap:t="",isPadding:l=!1,isInnerPadding:n=!0,version:a="transparent",isTheme:i=!1,isInnerBorder:r=!1,...s})=>u(C,{className:w("relative flex flex-col",mc[t],e),defaultPadding:l?"p-6xl":"",version:a,isTheme:i,...s,children:$a({...s,extraProps:{className:w("w-full",Oa(r)),padding:n?"":"p-0"}})})));kh.childrenTypes=[];const Ch=e=>(e=>{const t="col-span-",l=e?.split(/\s+/).find((e=>e.startsWith(t)));return l?parseInt(l.substring(t.length),10):12})(e)<10?"py-xl px-6xl":"py-6xl px-32",Sh=x((({className:e,title:t,url:l,previewImg:n,...a})=>{const i=G();return p(C,{className:e,defaultPadding:Ch(e),...a,children:[u(Ol,{title:t,headlineVersion:"M"}),l?u("video",{className:"m-auto w-full object-fill",preload:"metadata",poster:X(i)(n?.src),style:{maxHeight:524},controls:!0,children:u("source",{src:X(i)(l)})}):null]})})),Ih={ApplicationForm:kl,BenefitsBlock:Bl,Bonus:El,BonusBenefitsBlock:Yl,BusinessBlock:Jl,ButtonsBlock:Ql,Calculator:da,CardTransfer:fa,Carousel:Ya,CarouselBankHistoryCard:Ga,CarouselCard:ei,CarouselCatalogCard:ci,CarouselInvestmentCard:hi,CarouselLinks:gi,CarouselProductCard:Ci,CarouselRecommendationCard:Qi,CarouselRichTextCard:er,CarouselTariffsCard:ar,ComparisonTable:kr,ContactsBlock:Sr,Depository:ds,DepositFiltration:qr,ErrorBlock:hs,ExchangeRateTile:Ds,Footer:wo,GracePeriod:ko,Header:dc,Headline:Ol,HorizontalLayout:hc,ImgBlock:uc,InsuranceAmountBlock:bc,InvestmentInfo:kc,LinkDocs:Rc,MobileAppTile:Ac,MortgageFiltration:td,OfficesAtmsMap:Gd,ParagraphBlock:qd,PictureText:Qd,Placeholder:em,ProductBlock:im,ProductGallery:rm,ProductTile:om,RepresentativeOfficeInfo:cm,RichTextBlock:hm,RollupItem:pm,SafeDepositRental:_m,StepsBlock:Em,SwipeListControlBlock:Km,StickyBottomMenu:Wm,Tabs:Zm,TariffsTable:gh,TextBlock:fh,Tile:wh,VerticalLayout:kh,Video:Sh};const Th=["Header","Footer"],Bh=([,{target:e}])=>Math.abs(e.getBoundingClientRect().top);function Mh(e=globalThis){const t=s(new Map);a((()=>N.subscribe("intersection",(({block:e,intersection:l})=>{t.current&&t.current.set(e,l)}))),[]),a((()=>{const l=((e,t=600)=>{let l;const n=(...a)=>{n.dispose(),l=setTimeout((()=>{e(...a)}),t)};return n.dispose=()=>{l&&clearTimeout(l)},n})((()=>{!function(e){const t=`#${l=e?.anchor,l?.replace("#","")||""}`;var l;globalThis.location?.hash!==t&&globalThis.history?.replaceState(globalThis.history?.state,"",t)}(globalThis.scrollY>3*globalThis.innerHeight/4?function(e){const t=e.filter((([e])=>!Th.includes(e.type||""))).filter((([,{intersectionRatio:e}])=>e>.01)),[l]=t.length>0?Vn(Bh)(t):[];return l}([...t.current||[]]):void 0)}),100);return e.addEventListener("scroll",l),()=>{l.dispose(),e.removeEventListener("scroll",l)}}),[e])}const Ph="cookie",Rh=x((({termLink:e,personalDataPolicyLink:t})=>{const[l,{setTrue:n,setFalse:a}]=Ve();Ws((()=>{globalThis.localStorage?.getItem(Ph)||n()}),[],3e3);const r=i((()=>{globalThis.localStorage?.setItem(Ph,"true"),a()}),[]);return l?u("div",{className:"container fixed left-0 right-0 bottom-0 z-50",children:p("div",{className:"bg-white m-xl p-xl rounded-md flex sm:items-center shadow-main-black",children:[u("div",{className:"sm:flex-1",children:p(de,{size:"text-s",font:"font-light",color:"text-primary-text",children:["АО «Россельхозбанк» использует",u(bi,{isRemote:!0,className:Vh(e?.href),...e,children:"cookie"}),"(файлы с данными о прошлых посещениях сайта) для персонализации сервисов и удобства пользователей. Вы можете запретить сохранение cookie в настройках своего браузера.",u(bi,{isRemote:!0,className:Vh(t?.href),...t,children:"Обработка Ваших персональных данных"}),"производится в соответствии с требованиями Федерального закона от 27.07.2006 № 152-Ф3 «О персональных данных»."]})}),u("div",{className:"ml-s sm:ml-0 w-24 flex justify-end",children:u(Hs,{className:"bg-main-gray rounded-md",onClose:r})})]})}):null})),Vh=e=>w("inline mx-2xs",e?"text-green-dark":"");function zh(e){throw new Error(e)}const Ah=({onCloseAll:e,onClose:t}={})=>{const[l,{push:r,pop:s,clear:o}]=function(e=[]){const[t,l]=n(e),a=i((e=>l((t=>[...t,e]))),[]),r=i((()=>l((e=>e.slice(0,-1)))),[]),s=i((e=>l((t=>t.filter((t=>t!==e))))),[]),o=i((()=>l([])),[]);return[t,{setList:l,push:a,pop:r,remove:s,clear:o}]}(),c=i((()=>{e&&e(l),o()}),[l,e]),d=i((()=>{t&&t(l[l.length-1]),s()}),[l,t]);return a((()=>b.subscribe("dialog",(e=>{switch(e.type){case"open":r(e);break;case"close":e.all?c():d();break;default:zh(e)}}))),[c,d]),l},Dh=x((()=>{const e=i((e=>{for(const t of e)t?.onClose&&t.onClose()}),[]),t=i((e=>{e?.onClose&&e.onClose()}),[]),l=Ah({onCloseAll:e,onClose:t}),{close:n}=O(),r=i((({key:e})=>{"Escape"===e&&n()}),[]);return $e(globalThis.document,"keydown",r),a((()=>{l.length?(globalThis.document?.body.classList.add("no-scrollbar"),globalThis.document?.body.classList.add("overflow-hidden")):(globalThis.document?.body.classList.remove("no-scrollbar"),globalThis.document?.body.classList.remove("overflow-hidden"))}),[l]),l.length?u("div",{className:"fixed inset-0 z-50",role:"dialog",children:l.map((({dialog:e,id:t},n)=>u("div",{className:w("absolute inset-0 overflow-x-hidden overflow-y-scroll no-scrollbar",n===l.length-1?"":"hidden"),children:e},String(t||n))))}):null})),_h=x((()=>{const[e,t]=n(null),l=i((()=>{t(null)}),[]);a((()=>b.subscribe("popup",(e=>{switch(e.type){case"open":case"update":t(e);break;case"close":l();break;default:zh(e)}}))),[]);const r=i((({key:e})=>{"Escape"===e&&l()}),[l]);return $e(globalThis.document,"keydown",r),e?u("div",{className:"absolute z-50",style:{left:`${e.left}px`,top:`${e.top}px`,...e.width?{width:`${e.width}px`}:{}},role:"dialog",children:e.popup}):null})),jh=h();const Lh=x((({className:e,onClick:t,ariaLabel:l})=>u("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":l,children:$h()}))),$h=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return p("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[u("path",{...e,strokeMiterlimit:"10",d:"M21.48 11.95c.5-1.4-.4-2.6-1.9-2.6h-4c-.6 0-1.1-.5-1-1.2l.5-3.2c.2-.9-.4-1.9-1.3-2.2-.8-.3-1.8.1-2.2.7l-4.1 6.1M7.48 18.35l3.1 2.4c.4.4 1.3.6 1.9.6h3.8c1.2 0 2.5-.9 2.8-2.1l1.24-3.77"}),u("path",{...e,d:"M2.38 18.35v-9.8c0-1.4.6-1.9 2-1.9h1c1.4 0 2 .5 2 1.9v9.8c0 1.4-.6 1.9-2 1.9h-1c-1.4 0-2-.5-2-1.9Z"})]})},Oh=x((({className:e=""})=>{const t=function(e){const[t,l]=n(0);return a((()=>{(async()=>{const[t]=await jh.getLikeCount(e);l(t?.value||0)})()}),[e]),{likeCount:t,like:i((async()=>{l(await jh.like(e))}),[e]),dislike:i((async()=>{l(await jh.dislike(e))}),[e])}}(G().pathname);return p("div",{className:`border-main border-2 border-solid bg-white flex w-32 items-center justify-center gap-s p-xs font-sans ${e}`,children:[u(Lh,{onClick:Y(t.like),ariaLabel:"Поставить отметку «лайк»"}),u(Lh,{onClick:Y(t.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),u("span",{className:"select-none",children:t.likeCount})]})})),Eh=x((({className:e,blocksRegistry:t,blockDecorator:l,data:n={}})=>{const{style:a,slots:i,likeControl:r,colorPalette:s="pc"}=n,o={key:"",page:n,blocksRegistry:t,blockDecorator:l,parent:n};return Mh(),p("div",{"data-theme":s,children:[p("section",{className:w("@container relative",a,e),children:[i?.header?u("div",{className:"relative z-10 mb-lg shadow-[0_8px_32px_0px_#00000014]",children:La(i?.header,{...o,slotName:"header"})}):null,p("div",{className:"container space-y-px @5xl:space-y-0 @5xl:grid @5xl:grid-cols-12 @5xl:gap-2xs",children:[$a({block:n,options:o,extraProps:{className:"scroll-mt-12"}}),La(i?.footer,{...o,slotName:"footer"})]}),r?u("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:u(Oh,{className:"rounded-tl-3xl sticky bottom-0 pointer-events-auto"})}):null]}),u(Wm,{}),u(Dh,{}),u(_h,{}),u(Rh,{termLink:{href:"/pd-policy#cookie",target:"_blank"},personalDataPolicyLink:{href:"/pd-policy",target:"_blank"}})]})}));Eh.childrenTypes=[],Eh.slots=()=>["header","footer","StickyBottomMenu"];e.Blocks=Ih,e.ContentPage=Eh,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),l=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await l.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}},e.LikeAPI=h,e.handlerDecorator=Y,e.joinList=vc,e.packageVersion="0.14.28",e.projectSettings=d,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=W,e.useRouter=G,Object.defineProperty(e,"__esModule",{value:!0})}));
|