@redneckz/wildless-cms-uni-blocks 0.6.24 → 0.6.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle/blocks.schema.json +1 -1
- package/bundle/bundle.umd.js +97 -58
- package/bundle/bundle.umd.min.js +1 -1
- package/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/bundle/components/Catalog/CatalogContent.d.ts +2 -0
- package/bundle/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/bundle/components/ContentPage/normalizePage.d.ts +1 -1
- package/bundle/components/Header/HeaderContent.d.ts +1 -2
- package/bundle/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/bundle/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/bundle/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/bundle/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/bundle/model/BorderVersion.d.ts +6 -0
- package/bundle/services/sitemap/useSitemap.d.ts +2 -2
- package/bundle/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/dist/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/dist/components/BenefitsBlock/BenefitsBlock.js +5 -9
- package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/dist/components/Blocks.js +2 -0
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/Catalog/CatalogContent.d.ts +2 -0
- package/dist/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/dist/components/ContentPage/computeAPIFallback.js +1 -1
- package/dist/components/ContentPage/computeAPIFallback.js.map +1 -1
- package/dist/components/ContentPage/normalizeBlock.js +4 -8
- package/dist/components/ContentPage/normalizeBlock.js.map +1 -1
- package/dist/components/ContentPage/normalizeBlock.mobile.js +4 -8
- package/dist/components/ContentPage/normalizeBlock.mobile.js.map +1 -1
- package/dist/components/ContentPage/normalizePage.d.ts +1 -1
- package/dist/components/ContentPage/normalizePage.js +1 -6
- package/dist/components/ContentPage/normalizePage.js.map +1 -1
- package/dist/components/Header/Header.js +9 -9
- package/dist/components/Header/Header.js.map +1 -1
- package/dist/components/Header/Header.mobile.js +6 -6
- package/dist/components/Header/Header.mobile.js.map +1 -1
- package/dist/components/Header/HeaderContent.d.ts +1 -2
- package/dist/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/dist/components/InvestmentGallery/InvestmentGallery.js +40 -0
- package/dist/components/InvestmentGallery/InvestmentGallery.js.map +1 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryCard.js +24 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryCard.js.map +1 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryContent.js +2 -0
- package/dist/components/InvestmentGallery/InvestmentGalleryContent.js.map +1 -0
- package/dist/components/PictureText/PictureText.js +2 -2
- package/dist/components/PictureText/PictureText.js.map +1 -1
- package/dist/components/ProductGallery/ProductGallery.js +2 -2
- package/dist/components/ProductGallery/ProductGallery.js.map +1 -1
- package/dist/components/Recommendation/Recommendation.js +7 -5
- package/dist/components/Recommendation/Recommendation.js.map +1 -1
- package/dist/components/StepsBlock/StepsBlock.mobile.js +1 -5
- package/dist/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/dist/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/dist/content-page-repository/ContentPageRepository.js +24 -35
- package/dist/content-page-repository/ContentPageRepository.js.map +1 -1
- package/dist/model/BorderVersion.d.ts +6 -0
- package/dist/model/BorderVersion.js +7 -0
- package/dist/model/BorderVersion.js.map +1 -0
- package/dist/services/sitemap/useSitemap.d.ts +2 -2
- package/dist/services/sitemap/useSitemap.js.map +1 -1
- package/dist/ui-kit/BenefitItem/BenefitItem.js +3 -3
- package/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/dist/ui-kit/Breadcrumb.js +1 -8
- package/dist/ui-kit/Breadcrumb.js.map +1 -1
- package/dist/ui-kit/CurrencyInput/CurrencyInput.js +1 -1
- package/dist/ui-kit/CurrencyInput/CurrencyInput.js.map +1 -1
- package/dist/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/{mobile/dist/ui-kit/CurrencyInput/adjustValue .js → dist/ui-kit/CurrencyInput/adjustValue.js} +1 -1
- package/dist/ui-kit/CurrencyInput/adjustValue.js.map +1 -0
- package/dist/ui-kit/Tags/Tags.js +2 -2
- package/dist/ui-kit/Tags/Tags.js.map +1 -1
- package/lib/common.css +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.js +5 -9
- package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/lib/components/Blocks.js +2 -0
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/Catalog/CatalogContent.d.ts +2 -0
- package/lib/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/lib/components/ContentPage/computeAPIFallback.js +1 -1
- package/lib/components/ContentPage/computeAPIFallback.js.map +1 -1
- package/lib/components/ContentPage/normalizeBlock.js +4 -8
- package/lib/components/ContentPage/normalizeBlock.js.map +1 -1
- package/lib/components/ContentPage/normalizeBlock.mobile.js +4 -8
- package/lib/components/ContentPage/normalizeBlock.mobile.js.map +1 -1
- package/lib/components/ContentPage/normalizePage.d.ts +1 -1
- package/lib/components/ContentPage/normalizePage.js +1 -6
- package/lib/components/ContentPage/normalizePage.js.map +1 -1
- package/lib/components/Header/Header.js +9 -9
- package/lib/components/Header/Header.js.map +1 -1
- package/lib/components/Header/Header.mobile.js +6 -6
- package/lib/components/Header/Header.mobile.js.map +1 -1
- package/lib/components/Header/HeaderContent.d.ts +1 -2
- package/lib/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/lib/components/InvestmentGallery/InvestmentGallery.fixture.d.ts +7 -0
- package/lib/components/InvestmentGallery/InvestmentGallery.js +38 -0
- package/lib/components/InvestmentGallery/InvestmentGallery.js.map +1 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryCard.js +22 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryCard.js.map +1 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryContent.js +2 -0
- package/lib/components/InvestmentGallery/InvestmentGalleryContent.js.map +1 -0
- package/lib/components/PictureText/PictureText.js +2 -2
- package/lib/components/PictureText/PictureText.js.map +1 -1
- package/lib/components/ProductGallery/ProductGallery.js +2 -2
- package/lib/components/ProductGallery/ProductGallery.js.map +1 -1
- package/lib/components/Recommendation/Recommendation.js +7 -5
- package/lib/components/Recommendation/Recommendation.js.map +1 -1
- package/lib/components/StepsBlock/StepsBlock.mobile.js +1 -5
- package/lib/components/StepsBlock/StepsBlock.mobile.js.map +1 -1
- package/lib/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/lib/content-page-repository/ContentPageRepository.js +24 -35
- package/lib/content-page-repository/ContentPageRepository.js.map +1 -1
- package/lib/model/BorderVersion.d.ts +6 -0
- package/lib/model/BorderVersion.js +5 -0
- package/lib/model/BorderVersion.js.map +1 -0
- package/lib/services/sitemap/useSitemap.d.ts +2 -2
- package/lib/services/sitemap/useSitemap.js.map +1 -1
- package/lib/ui-kit/BenefitItem/BenefitItem.js +3 -3
- package/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/lib/ui-kit/Breadcrumb.js +1 -8
- package/lib/ui-kit/Breadcrumb.js.map +1 -1
- package/lib/ui-kit/CurrencyInput/CurrencyInput.js +1 -1
- package/lib/ui-kit/CurrencyInput/CurrencyInput.js.map +1 -1
- package/lib/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/lib/ui-kit/CurrencyInput/{adjustValue .js → adjustValue.js} +1 -1
- package/lib/ui-kit/CurrencyInput/adjustValue.js.map +1 -0
- package/lib/ui-kit/Tags/Tags.js +2 -2
- package/lib/ui-kit/Tags/Tags.js.map +1 -1
- package/mobile/bundle/bundle.umd.js +9 -13
- package/mobile/bundle/bundle.umd.min.js +1 -1
- package/mobile/bundle/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/mobile/bundle/components/Catalog/CatalogContent.d.ts +2 -0
- package/mobile/bundle/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/mobile/bundle/components/ContentPage/normalizePage.d.ts +1 -1
- package/mobile/bundle/components/Header/HeaderContent.d.ts +1 -2
- package/mobile/bundle/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/mobile/bundle/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/mobile/bundle/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/mobile/bundle/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/mobile/bundle/model/BorderVersion.d.ts +6 -0
- package/mobile/bundle/services/sitemap/useSitemap.d.ts +2 -2
- package/mobile/bundle/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js +5 -9
- package/mobile/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/dist/components/Catalog/CatalogContent.d.ts +2 -0
- package/mobile/dist/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/mobile/dist/components/ContentPage/computeAPIFallback.js +1 -1
- package/mobile/dist/components/ContentPage/computeAPIFallback.js.map +1 -1
- package/mobile/dist/components/ContentPage/normalizeBlock.js +4 -8
- package/mobile/dist/components/ContentPage/normalizeBlock.js.map +1 -1
- package/mobile/dist/components/ContentPage/normalizePage.d.ts +1 -1
- package/mobile/dist/components/ContentPage/normalizePage.js +1 -6
- package/mobile/dist/components/ContentPage/normalizePage.js.map +1 -1
- package/mobile/dist/components/Header/Header.js +6 -6
- package/mobile/dist/components/Header/Header.js.map +1 -1
- package/mobile/dist/components/Header/HeaderContent.d.ts +1 -2
- package/mobile/dist/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGallery.js +40 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGallery.js.map +1 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryCard.js +24 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryCard.js.map +1 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryContent.js +2 -0
- package/mobile/dist/components/InvestmentGallery/InvestmentGalleryContent.js.map +1 -0
- package/mobile/dist/components/PictureText/PictureText.js +2 -2
- package/mobile/dist/components/PictureText/PictureText.js.map +1 -1
- package/mobile/dist/components/Recommendation/Recommendation.js +7 -5
- package/mobile/dist/components/Recommendation/Recommendation.js.map +1 -1
- package/mobile/dist/components/StepsBlock/StepsBlock.js +1 -5
- package/mobile/dist/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/dist/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/mobile/dist/content-page-repository/ContentPageRepository.js +24 -35
- package/mobile/dist/content-page-repository/ContentPageRepository.js.map +1 -1
- package/mobile/dist/model/BorderVersion.d.ts +6 -0
- package/mobile/dist/model/BorderVersion.js +7 -0
- package/mobile/dist/model/BorderVersion.js.map +1 -0
- package/mobile/dist/services/sitemap/useSitemap.d.ts +2 -2
- package/mobile/dist/services/sitemap/useSitemap.js.map +1 -1
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js +3 -3
- package/mobile/dist/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/dist/ui-kit/Breadcrumb.js +1 -8
- package/mobile/dist/ui-kit/Breadcrumb.js.map +1 -1
- package/mobile/dist/ui-kit/CurrencyInput/CurrencyInput.js +1 -1
- package/mobile/dist/ui-kit/CurrencyInput/CurrencyInput.js.map +1 -1
- package/mobile/dist/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/{dist/ui-kit/CurrencyInput/adjustValue .js → mobile/dist/ui-kit/CurrencyInput/adjustValue.js} +1 -1
- package/mobile/dist/ui-kit/CurrencyInput/adjustValue.js.map +1 -0
- package/mobile/dist/ui-kit/Tags/Tags.js +2 -2
- package/mobile/dist/ui-kit/Tags/Tags.js.map +1 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.d.ts +2 -1
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js +5 -9
- package/mobile/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/mobile/lib/components/Catalog/CatalogContent.d.ts +2 -0
- package/mobile/lib/components/ContentPage/computeAPIFallback.d.ts +1 -1
- package/mobile/lib/components/ContentPage/computeAPIFallback.js +1 -1
- package/mobile/lib/components/ContentPage/computeAPIFallback.js.map +1 -1
- package/mobile/lib/components/ContentPage/normalizeBlock.js +4 -8
- package/mobile/lib/components/ContentPage/normalizeBlock.js.map +1 -1
- package/mobile/lib/components/ContentPage/normalizePage.d.ts +1 -1
- package/mobile/lib/components/ContentPage/normalizePage.js +1 -6
- package/mobile/lib/components/ContentPage/normalizePage.js.map +1 -1
- package/mobile/lib/components/Header/Header.js +6 -6
- package/mobile/lib/components/Header/Header.js.map +1 -1
- package/mobile/lib/components/Header/HeaderContent.d.ts +1 -2
- package/mobile/lib/components/InvestmentGallery/InvestmentGallery.d.ts +5 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGallery.js +38 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGallery.js.map +1 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryCard.d.ts +7 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryCard.js +22 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryCard.js.map +1 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryContent.d.ts +50 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryContent.js +2 -0
- package/mobile/lib/components/InvestmentGallery/InvestmentGalleryContent.js.map +1 -0
- package/mobile/lib/components/PictureText/PictureText.js +2 -2
- package/mobile/lib/components/PictureText/PictureText.js.map +1 -1
- package/mobile/lib/components/Recommendation/Recommendation.js +7 -5
- package/mobile/lib/components/Recommendation/Recommendation.js.map +1 -1
- package/mobile/lib/components/StepsBlock/StepsBlock.js +1 -5
- package/mobile/lib/components/StepsBlock/StepsBlock.js.map +1 -1
- package/mobile/lib/content-page-repository/ContentPageRepository.d.ts +12 -9
- package/mobile/lib/content-page-repository/ContentPageRepository.js +24 -35
- package/mobile/lib/content-page-repository/ContentPageRepository.js.map +1 -1
- package/mobile/lib/model/BorderVersion.d.ts +6 -0
- package/mobile/lib/model/BorderVersion.js +5 -0
- package/mobile/lib/model/BorderVersion.js.map +1 -0
- package/mobile/lib/services/sitemap/useSitemap.d.ts +2 -2
- package/mobile/lib/services/sitemap/useSitemap.js.map +1 -1
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js +3 -3
- package/mobile/lib/ui-kit/BenefitItem/BenefitItem.js.map +1 -1
- package/mobile/lib/ui-kit/Breadcrumb.js +1 -8
- package/mobile/lib/ui-kit/Breadcrumb.js.map +1 -1
- package/mobile/lib/ui-kit/CurrencyInput/CurrencyInput.js +1 -1
- package/mobile/lib/ui-kit/CurrencyInput/CurrencyInput.js.map +1 -1
- package/mobile/lib/ui-kit/CurrencyInput/{adjustValue .d.ts → adjustValue.d.ts} +0 -0
- package/mobile/lib/ui-kit/CurrencyInput/{adjustValue .js → adjustValue.js} +1 -1
- package/mobile/lib/ui-kit/CurrencyInput/adjustValue.js.map +1 -0
- package/mobile/lib/ui-kit/Tags/Tags.js +2 -2
- package/mobile/lib/ui-kit/Tags/Tags.js.map +1 -1
- package/mobile/src/components/BenefitsBlock/BenefitsBlock.tsx +14 -21
- package/mobile/src/components/Catalog/CatalogContent.ts +2 -0
- package/mobile/src/components/ContentPage/computeAPIFallback.ts +20 -21
- package/mobile/src/components/ContentPage/normalizeBlock.ts +15 -18
- package/mobile/src/components/ContentPage/normalizePage.ts +2 -7
- package/mobile/src/components/Header/Header.tsx +11 -11
- package/mobile/src/components/Header/HeaderContent.ts +1 -2
- package/mobile/src/components/InvestmentGallery/InvestmentGallery.example.json +64 -0
- package/mobile/src/components/InvestmentGallery/InvestmentGallery.tsx +103 -0
- package/mobile/src/components/InvestmentGallery/InvestmentGallery.ui.json +11 -0
- package/mobile/src/components/InvestmentGallery/InvestmentGalleryCard.tsx +91 -0
- package/mobile/src/components/InvestmentGallery/InvestmentGalleryContent.ts +54 -0
- package/mobile/src/components/PictureText/PictureText.tsx +3 -3
- package/mobile/src/components/Recommendation/Recommendation.tsx +9 -7
- package/mobile/src/components/StepsBlock/StepsBlock.tsx +1 -7
- package/mobile/src/content-page-repository/ContentPageRepository.ts +27 -45
- package/mobile/src/model/BorderVersion.ts +10 -0
- package/mobile/src/services/sitemap/useSitemap.ts +4 -4
- package/mobile/src/ui-kit/BenefitItem/BenefitItem.tsx +6 -5
- package/mobile/src/ui-kit/Breadcrumb.tsx +8 -11
- package/mobile/src/ui-kit/CurrencyInput/CurrencyInput.tsx +1 -1
- package/mobile/src/ui-kit/CurrencyInput/{adjustValue .ts → adjustValue.ts} +0 -0
- package/mobile/src/ui-kit/Tags/Tags.tsx +3 -5
- package/package.json +1 -1
- package/src/components/BenefitsBlock/BenefitsBlock.tsx +14 -21
- package/src/components/Blocks.ts +2 -0
- package/src/components/Catalog/CatalogContent.ts +2 -0
- package/src/components/ContentPage/computeAPIFallback.ts +20 -21
- package/src/components/ContentPage/normalizeBlock.mobile.ts +15 -18
- package/src/components/ContentPage/normalizeBlock.ts +10 -12
- package/src/components/ContentPage/normalizePage.ts +2 -7
- package/src/components/Header/Header.mobile.tsx +11 -11
- package/src/components/Header/Header.tsx +17 -12
- package/src/components/Header/HeaderContent.ts +1 -2
- package/src/components/InvestmentGallery/InvestmentGallery.example.json +64 -0
- package/src/components/InvestmentGallery/InvestmentGallery.fixture.tsx +79 -0
- package/src/components/InvestmentGallery/InvestmentGallery.tsx +103 -0
- package/src/components/InvestmentGallery/InvestmentGallery.ui.json +11 -0
- package/src/components/InvestmentGallery/InvestmentGalleryCard.tsx +91 -0
- package/src/components/InvestmentGallery/InvestmentGalleryContent.ts +54 -0
- package/src/components/PictureText/PictureText.tsx +3 -3
- package/src/components/ProductGallery/ProductGallery.tsx +3 -4
- package/src/components/Recommendation/Recommendation.tsx +9 -7
- package/src/components/StepsBlock/StepsBlock.mobile.tsx +1 -7
- package/src/content-page-repository/ContentPageRepository.ts +27 -45
- package/src/model/BorderVersion.ts +10 -0
- package/src/services/sitemap/useSitemap.ts +4 -4
- package/src/ui-kit/BenefitItem/BenefitItem.tsx +6 -5
- package/src/ui-kit/Breadcrumb.tsx +8 -11
- package/src/ui-kit/CurrencyInput/CurrencyInput.tsx +1 -1
- package/src/ui-kit/CurrencyInput/{adjustValue .ts → adjustValue.ts} +0 -0
- package/src/ui-kit/Tags/Tags.tsx +3 -5
- package/dist/ui-kit/CurrencyInput/adjustValue .js.map +0 -1
- package/lib/ui-kit/CurrencyInput/adjustValue .js.map +0 -1
- package/mobile/dist/ui-kit/CurrencyInput/adjustValue .js.map +0 -1
- package/mobile/lib/ui-kit/CurrencyInput/adjustValue .js.map +0 -1
|
@@ -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).UniMobileBlocks={})}(this,(function(e){"use strict";let t;const n=e=>(...n)=>t[e](...n),r=n("useState"),i=n("useEffect"),l=n("useCallback"),a=n("useMemo"),s=n("useRef");function o(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))))))(),n=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await n.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}}const c=new class{_={PROD_BRANCH:"master",FORCED_DRAFT_FLOW:!1};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}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},d="likesToken";function m(){async function e(){try{const e=JSON.parse(globalThis.localStorage.getItem(d)||"");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:n}=await e.json();return globalThis.localStorage.setItem(d,JSON.stringify({token:t,name:n})),{token:t,name:n}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n},body:JSON.stringify({node_ids:t})}),{likes:r}=await e.json();return r||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:n,name:r}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n,UserID:r},body:JSON.stringify({node_id:t,user_name:r})}),{likes:i}=await e.json();return i||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:n,name:r}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n,UserID:r},body:JSON.stringify({node_id:t,user_name:r})}),{likes:i}=await e.json();return i||0}catch(e){return console.error(e),0}}}}const h=(...e)=>globalThis._uni._jsx(...e),u=(...e)=>globalThis._uni._jsxs(...e),p=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:x(e)),t._tmpl},x=e=>{function t(t,n){const{children:r,...i}=t||{},l=n?.slots?.default,a=r||l&&l();return e(Object.assign(i,a&&{children:a}),n)}return t.inheritAttrs=!1,t};class g{static inst=new g;subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]||=[],this.subscribers[e]?.push(t);const n=this.subjectsStateMap[e];return n&&t(n),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){this.subjectsStateMap[e]=t,this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=100,f={threshold:new Array(18).fill(0).map((function(e,t){const n=(t+1)/b+.82;return Math.round(n*b)/b}))},N=p((({anchor:e,className:t,children:n,tag:l="section",labels:o,role:c})=>{const d=l,[m,u]=r(!0),p=s({}),x=a((()=>(({anchor:e,anchorClickRef:t})=>n=>{if(!n?.length)return;const[r]=n;!r.isIntersecting||r.boundingClientRect.top>150||(t?.current?.isScrolling&&t.current.label===`#${e}`?(g.inst.fire("anchorClick",{isScrolling:!1,label:void 0}),g.inst.fire("tab",{type:"link",label:e})):t?.current?.isScrolling||g.inst.fire("tab",{type:"link",label:e}))})({anchor:e,anchorClickRef:p})),[e]),b=function(e,t){const n=s(null);return i((()=>{if(!n.current)return;const r=new IntersectionObserver(e,t);return r.observe(n.current),()=>{r.disconnect()}}),[e,t]),n}(x,f);return i((()=>g.inst.subscribe("anchorClick",(e=>{u(!0),p.current=e}))),[]),i((()=>g.inst.subscribe("tab",(t=>{if("group"===t.type){const n=o?.length||e;u(!t.label||(!n||Boolean(o?.includes(t.label))))}else(n=t.label)&&(globalThis.document.location.hash=n),u(!0);var n}))),[]),m?h(d,{className:t,role:c,...e?{id:e,ref:b}:{},children:n}):null}));const y={h0:"text-m-title",h1:"text-m-title",h2:"text-m-title",h3:"text-h6",h4:"text-m-title-xs",h5:"text-m-title-xs",h6:"text-m-title-xs"},v=p((e=>{const{className:t,headingType:n="h3",title:r,as:i="h3"}=e;return h(i,{className:`font-sans font-medium m-0 ${y[n]} ${t||""}`,children:r})})),w=p((({children:e})=>h("ul",{className:"list-none m-0 p-0",children:e}))),k=p((({title:e,description:t,context:n,className:r="",children:i,...l})=>u(N,{context:n,className:`py-6 px-4 font-sans bg-white text-primary-text ${r}`,...l,children:[e?h(v,{headingType:"h3",className:"mb-2 text-center",title:e}):null,t?h("div",{className:"mb-5 text-m-light text-center",children:t}):null,h(w,{children:i})]})));k.childrenTypes=["AccordionItem"];const $=p((({isFoldButtonOnTop:e=!1,unfoldedByDefault:t=!1,renderFoldableSection:n,renderFoldButton:i})=>{const[a,s]=r(t),o=l((()=>{s((e=>!e))}),[]),c=n({isUnfolded:a,onToggle:o}),d=i?i({isUnfolded:a,onToggle:o}):null;return u("div",e?{children:[d,c]}:{children:[c,d]})})),C=p((({className:e="",isUnfolded:t,children:n})=>{const r=s(null);return i((()=>{r.current&&(r.current.style.maxHeight=t?`${r.current.scrollHeight}px`:"")}),[t,n?.length]),h("div",{ref:r,className:`transition-max-h duration-300 overflow-hidden max-h-0 ${e}`,children:n})})),S={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},T=p((({className:e="",imageClassName:t="",name:n="",alt:r=`Иконка ${n}`,title:i=r,iconVersion:l="color",asSVG:a,...s})=>{const o=`${c.CDN||""}icons/${n}.svg`;return a&&"normal"!==l?h(I,{className:e,children:u("svg",{className:[D(e,s.width),S[l],t,_(l)].join(" "),...s,"aria-hidden":"true",children:[i?h("title",{children:i}):null,r?h("desc",{children:r}):null,h("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]})}):h("img",{className:e,src:o,alt:r,title:i,...s,"aria-hidden":"true"})})),_=e=>"white"===e?"invert":"",D=(e,t)=>t?`width: ${t}px `:"w-full h-full",I=p((({className:e,children:t})=>e?h("div",{className:e,children:t}):t));function j(e){return"string"==typeof e?"normal":e?.iconVersion||"normal"}const R=(e,t)=>e.media&&t.media?e.media-t.media:0,A=p((({className:e="",image:t,imageClassName:n="",isMobile:r=!1})=>{if(!t||!t?.sources&&!t?.src)return null;return u("picture",{className:`${r?"flex":"flex-none"} ${e}`,children:[t?.sources?.length?t.sources.sort(R).map((({src:e,format:n,media:r},i)=>h("source",{srcSet:e,type:M(n),media:r?`(max-width: ${r}px)`:"",...t.size},`${i}_${e}`))):null,L(t,n,r)]})})),L=(e,t="",n=!1)=>{const r={width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"100%"},i=e.title||"",l=e.alt||e.title,a=n?"m-auto":"m-0";return h("img",{src:e.src,className:`${a} ${t}`,alt:l,title:i,style:r,...e.size})};function M(e){return e?`image/${String(e)}`:void 0}const O=p((({className:e="",image:t,imageClassName:n="",isMobile:r,...i})=>{if(!t)return null;const l="string"==typeof t?t:t.icon;return l||""===l?l.length?h(T,{className:e,imageClassName:n,iconVersion:j(t),name:l,...i}):null:h(A,{className:e,imageClassName:n,image:t,isMobile:r})})),B=p((e=>h(O,{...e,isMobile:!0}))),V=(e,t="primary")=>({...e,iconVersion:e?.iconVersion??("secondary"===t?"white":"color")}),P=["PlusIcon","MinusIcon"],F=p((({className:e="",ancestors:t,label:n="",labelIcon:r,isExpanded:i,children:l})=>{const{bordered:a}=function(e,t){const{content:n}=function(e,t){const[n]=(e||[]).map((e=>e)).reverse().find((([e])=>e&&"type"in e&&(!t||t===e.type)))||[];return n||{}}(e);return n||t}(t,{});return h("li",{className:`${a?"border p-4 rounded mb-4":"border-0 border-b last:border-b-0"} border-solid border-main-divider ${e}`,children:h($,{isFoldButtonOnTop:!0,unfoldedByDefault:i,renderFoldableSection:({isUnfolded:e})=>h(C,{className:"flex flex-wrap group-last:last:pb-0 gap-5 [&>*]:p-0",isUnfolded:e,children:l}),renderFoldButton:({isUnfolded:e,onToggle:t})=>h(E,{className:a?"":"py-[14px] px-0",label:n,icon:P[Number(e)],primaryIcon:r,onClick:t})})})}));F.childrenTypes=[];const E=p((({className:e,icon:t,label:n,primaryIcon:r,onClick:i})=>u("button",{className:`border-none bg-transparent flex justify-between text-left w-full font-sans text-primary-text group cursor-pointer ${e}`,onClick:i,children:[u("span",{className:"text-m-title-xs font-medium pr-2.5 flex group-hover:text-primary-main",children:[r?h(B,{image:V(r),className:"mr-3 flex-shrink-0",width:"24",height:"24",asSVG:!0}):null,n]}),h(B,{className:"flex-shrink-0",image:V({icon:t}),width:"24",height:"24",asSVG:!0})]}))),z=p((({children:e,activeIndex:t,indexFraction:n,showDots:r})=>{const i=e=>n=>{if(e===t)return;const r=n.currentTarget.parentElement?.previousElementSibling;r?.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest"})};return r&&e?.length?h("div",{className:"flex gap-2 mx-auto mt-5 w-fit",children:e?.map(((e,r)=>h("div",{onClick:i(r),className:"bg-primary-main opacity-30 w-1.5 h-1.5 min-w-1.5 min-h-1.5 rounded-full",style:G(r,t,n),"aria-hidden":!0},String(r))))}):null})),G=(e,t,n)=>{if(e<t||e>t+1)return;const r=1-n;return e===t?{opacity:""+(.3+.7*r),width:6+16*r+"px"}:{opacity:""+(.3+.7*n),width:6+16*n+"px"}},H=p((({className:e="",children:t,...n})=>h("div",{className:`snap-center snap-always min-w-full box-border ${e}`,role:"listitem",...n,children:t}))),W=e=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e}px`}),J=p((({className:e="",children:t,activeIndex:n,onScroll:r,gap:i=14,padding:l=16})=>h("div",{className:`overflow-auto flex horizontal-list no-scrollbar ${e}`,style:{...W(l),gap:`${i}px`},role:"list",onScroll:r,children:t?.length?t?.map(((e,t)=>h(H,{style:W(l/4),"aria-current":Boolean(n===t),children:e},String(t)))):h(H,{children:t})}))),U=p((({className:e,children:t,gap:n=14,padding:i=16,showDots:l=!0,onSlideChange:a})=>{const[s,o]=r(0),[c,d]=r(0),m={activeIndex:s,indexFraction:c,showDots:l,children:t};return u("div",{className:e,children:[h(J,{gap:n,padding:i,activeIndex:s,onScroll:e=>{const{scrollLeft:t,clientWidth:r,childElementCount:l,scrollWidth:c,children:m}=e?.currentTarget,h=m[0].offsetWidth-i/2,u=(({gap:e,padding:t,clientWidth:n,scrollWidth:r,childElementCount:i,itemWidth:l})=>{const a=r-n;if(2===i)return[[0,a],[a,r]];const s=l+e,o=n-e-t,c=i-2,d=new Array(i).fill(0).map(((e,t)=>0===t||t===c?[t>0?a-o:0,t>0?a:o]:[(t-1)*s+o,t*s+o]));return d[i-1]=[a,r],d})({gap:n,padding:i,clientWidth:r,scrollWidth:c,childElementCount:l,itemWidth:h}),{index:p,fraction:x}=((e,t)=>{const n=t.findIndex((([t,n])=>t<=e&&e<n));if(n<0)return{index:n,fraction:0};const[r,i]=t[n];return{index:n,fraction:(e-r)/(i-r)}})(t,u);p!==s&&a&&a(),o(p),d(x)},children:t}),h(z,{...m})]})})),Y={primary:"group-hover:brightness-0 group-hover:invert",secondary:"group-hover:brightness-0 group-hover:invert",white:"group-hover:brightness-0 group-hover:invert",link:""},K=p((e=>{const{text:t,aboveText:n,appendLeft:r,appendRight:i,version:l="primary"}=e;return u("div",{className:X(e),children:[r?h("div",{className:Y[l],children:r}):null,Q(e)?u("div",{children:[h("div",{className:"text-xs-light text-left",children:n}),h("div",{className:"text-left "+(n?"text-s -mt-0.5":"text-l"),children:t})]}):null,i?h("div",{className:Y[l],children:i}):null]})})),X=e=>{const{className:t="",version:n,aboveText:r,rounded:i}=e;if("link"===n)return"";const l="gap-2 "+(r?"py-2.5 px-7":"py-4 px-9");return["group flex items-center justify-center",Q(e)?l:"h-12 w-12",i?"rounded-full":"",t].join(" ")},Q=({text:e,aboveText:t,appendLeft:n})=>Boolean(e||t||!n),Z={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",link:"text-primary-main"},q={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text",white:"bg-white text-primary-text",link:""},ee="w-full text-center font-sans select-none",te=p((({className:e,text:t,aboveText:n,appendLeft:r,href:i,target:l,onClick:a,children:s,disabled:o,rounded:c,version:d="primary",ariaLabel:m,...u})=>{const{appendRight:p,...x}=u,g=s??h(K,{text:t,aboveText:n,appendLeft:r,rounded:c,version:d});return o?h("div",{role:"button","aria-disabled":"true","aria-label":m,tabIndex:-1,className:`inline-block ${ee} ${q[d]||""} ${c?"rounded-full":"rounded-md"} ${e||""}`,children:g}):h("a",{className:`${ee} inline-block cursor-pointer no-underline focus:border focus:border-primary-focus ${Z[d]||""} ${c?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:a,"aria-label":m,role:i?"link":"button",...x,children:g})})),ne=(e=!1)=>e?"text-white":"",re=(e=!1)=>"text-s mb-3.5 "+(e?"text-white":"text-secondary-text/80"),ie=p((({icon:e,image:t,title:n,subtitle:r,isFillGradient:i})=>u("div",{role:"columnheader",children:[e?h(B,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",image:e,width:"63",height:"63"}):null,t?.src&&h("div",{className:"mb-3.5",children:h(B,{image:t})}),n?h(v,{headingType:"h4",className:ne(i),title:n}):null,r?h("div",{className:re(i),children:r}):null]}))),le=p((({cell:e,rowHeader:t,isFillGradient:n=!1})=>h("div",{className:"box-border flex flex-col",role:"cell",children:h("div",{className:"h-full border-main-divider border border-t-0 border-x-0",children:e.map(ae(n,t))})}))),ae=(e,t)=>({label:n,description:r},i)=>u("div",{className:"flex justify-between text-s py-3.5",children:[h("div",{className:""+(e?"text-white/80":"text-secondary-text"),children:t}),u("div",{className:"basis-1/2",children:[n?h("div",{className:"text-right "+(e?"text-white":""),children:n}):null,r?h("div",{className:"text-right "+(e?"text-white/80":"text-secondary-text"),children:r}):null]})]},String(i)),se=p((({header:e,columnData:t,visibleRowLength:n=0,isFillGradient:r,showRow:i,onToggleColumn:l})=>{const a=t?.slice(0,i?t.length:n),s=r?"secondary":"primary";return u("div",{className:`border border-main-stroke rounded-md p-4 mb-3.5 ${r?"bg-gradient-to-r from-main-gradient-start to-main-gradient-end":""}`,role:"row",children:[h(ie,{...e,isFillGradient:r}),a?.length?a.map((({rowHeader:e,cell:t},n)=>h(le,{cell:t,rowHeader:e,isFillGradient:r},String(n)))):null,i&&e?.link?h(te,{href:e.link.href,target:e.link.target,version:s,className:"text-s font-medium mt-4 py-[11px]",children:e.link.text}):null,oe({onToggleColumn:l,isFillGradient:r,showRow:i})]})})),oe=({onToggleColumn:e,isFillGradient:t,showRow:n})=>h("div",{className:"mt-5",role:"cell",children:h("a",{role:"link",onClick:e,className:"text-s font-medium cursor-pointer "+(t?"text-white/80":"text-primary-main"),children:n?"Скрыть":"Показать описание"})}),ce=p((e=>{const{className:t,title:n}=e;return u("section",{className:`bg-white font-sans px-4 py-6 overflow-hidden text-primary-text relative ${t||""}`,children:[n?h(v,{headingType:"h3",className:"font-medium text-center m-0 mb-5",title:n}):null,h("div",{role:"table",children:h(de,{...e})})]})})),de=p((({columns:e,rowHeaders:t,isColoredFirstColumn:n,visibleRowLength:i,orientation:a,context:s})=>{const[o,c]=r(new Array(e?.length||0).fill(!i)),d=l((e=>{const t=(t,n)=>n===e?!t:t;c((e=>e.map(t)))}),[]),m=l((()=>c((e=>new Array(e.length).fill(!1)))),[]),u=e?.map((({data:e,header:r},l)=>{return h(se,{context:s,visibleRowLength:i,showRow:o[l],header:r,columnData:(a=e,a?.map(((e,n)=>({cell:e,rowHeader:t?.[n]?.title})))),isFillGradient:0===l&&n,onToggleColumn:()=>d(l)},String(l));var a}));return"horizontal"===a?h(U,{context:s,onSlideChange:m,children:u}):u})),me=new Map;function he(e,t,{fallback:n}={}){const l=a((()=>ue(e)),[e]),[s,o]=r(),[c,d]=r(),m=e=>{o(e),d(void 0)},h=e=>{o(void 0),d(e)};i((()=>{if(!l.every((e=>null===e)))try{const e=t(...l);"then"in e?(e=>{e.then((e=>me.get(l)||e)).then(m).catch(h)})(e):m(e)}catch(e){h(e)}}),[t,...l]);const u=l[0],p=n&&"string"==typeof u&&n[u];return{data:s||c||!p?s:p,error:c,mutate:()=>Promise.resolve(void 0),isValidating:!1}}function ue(e){return e?Array.isArray(e)?e:e instanceof Function?ue(e()):[e]:[e]}async function pe(e,t){const n=await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}});return await n.json()}function xe(e={}){const{data:t}=he(`/wcms-resources/${c.SITEMAP||"sitemap"}.json`,pe,{fallback:e});return t||{}}const ge=p((({className:e,isMobile:t=!1})=>{const{term:n,setTerm:i}=(()=>{const[e,t]=r("");return{term:e,setTerm:e=>t(e)}})(),l=t?"text-s":"text-l-light",a=t?" placeholder-transparent":"h-full",s=t?"some search":void 0;return u("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:[h("div",{className:t?"w-5 h-5":"w-6 h-6",children:h(B,{image:"LoupeIcon",width:"24",height:"24"})}),n?null:h("label",{htmlFor:"search-bar-input",className:`text-secondary-text ${l}`,children:"Поиск по сайту"})]}),h("input",{id:"search-bar-input",className:`h-12 pl-12 w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none pr-[6%] border-main-stroke hover:border-primary-hover active:border-primary-text focus:border-primary-text ${a}`,value:n,onChange:e=>i(e.target.value),type:"text",name:"search-bar-input",placeholder:s}),t?h("button",{className:"visible peer-placeholder-shown:invisible absolute top-2 right-3 w-6 h-6 p-1 bg-transparent cursor-pointer border-none",onClick:e=>{e.preventDefault(),i("")},children:h(B,{image:"CloseIcon",width:"24",height:"24"})}):h(te,{version:"primary",text:"Найти",className:"invisible peer-focus:visible absolute top-[3px] right-1",onClick:e=>{e?.preventDefault(),console.log("click")},children:h("div",{className:"text-s px-9 py-2.5",children:"Найти"})})]})})),be=p((({className:e=""})=>h(ge,{className:e,isMobile:!0}))),fe=p((({className:e="",documents:t,...n})=>h(N,{className:`font-sans bg-white mt-[10px] ${e}`,...n,children:h("ul",{className:"flex flex-col text-s text-secondary-text p-0",children:t?.length?Ne(t):null})}))),Ne=e=>e.map(((e,t)=>{const{text:n,...r}=e;return h("li",{className:"mb-4 list-none",children:h("a",{className:"hover:text-primary-main",role:"link",...r,children:n||null})},`list_item_${String(t)}`)})),ye={"bg-white":"color",transparent:"white"},ve={"bg-white":"text-primary-main",transparent:"text-white"},we={"bg-white":"text-black",transparent:"text-white"},ke=p((({className:e="",href:t,children:n,targetBlank:r,bgColor:i="bg-white",showTitle:l=!0})=>u("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"https://rshb.ru/",target:r?"_blank":"_self","aria-label":"Россельхозбанк",children:[h(B,{image:{icon:"LogoIcon",iconVersion:ye[i]},className:`${ve[i]}`,width:"34",height:"34",asSVG:!0}),l?h("span",{className:`${we[i]} text-s font-medium ml-2.5`,children:n||"Россельхозбанк"}):null]}))),$e=p((({className:e="",title:t="Мобильное приложение",description:n,href:r="#"})=>h("div",{className:`col-span-12 rounded-md cursor-pointer p-4 mt-6 mb-6 bg-secondary-light font-sans ${e}`,children:r?u("div",{className:"flex",children:[h("div",{className:"flex justify-center align-middle rounded-md bg-primary-main w-[50px] h-[50px]",children:h(ke,{className:"w-8",bgColor:"transparent",showTitle:!0})}),u("a",{href:r,target:"_blank",className:"flex flex-col justify-center pl-3",children:[h("div",{className:"text-s font-medium mb-[3px]",children:t}),h("div",{className:"text-s text-secondary-text",children:n})]})]}):null}))),Ce=e=>e?.includes("//"),Se=e=>(e||"").replace(/\/?\?.*/,""),Te=e=>{if(!e||!Ce(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t};var _e=Object.freeze({__proto__:null,isURL:Ce,withoutQuery:Se,getOrigin:Te,getHash:e=>{if(!e||!Ce(e))return;const t=e.indexOf("#");return-1!==t?e.substring(t,e.length):void 0},isHash:e=>e?.startsWith("#")});const De="/mobile",Ie=(e,t)=>{if(!e)return e;const n=Te(t?.href);return n?e.replace(n,"")||"/":e},je=e=>e;function Re({router:e,handlerDecorator:t=je},n){const r=((e,t)=>{if(!e)return e;const n=Ie(e,t)||"",r=t?.pathname.startsWith(De);return r&&!Ce(n)?`/mobile${n}`:n})(n.href,e);return{...n,href:r,"aria-label":n.text,onClick:t((t=>{const i=r&&!Ce(r),l=!n.target||"_self"===n.target;i&&l&&(t?.preventDefault(),e.push(r))}),n)}}const Ae=p((({className:e="",items:t,hasButton:n,context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return u("div",{className:e,children:[t?.length?t.map(Le):null,n?h(te,{version:"primary",className:"mb-6 w-full",...Re({router:i,handlerDecorator:l},{text:"Обратная связь",href:"/",target:"_blank"}),ariaLabel:"Обратная связь"}):null]})})),Le=(e,t)=>{const{type:n,text:r,description:i}=e;return u("div",{className:"mb-4",children:[h("div",{children:Me(n,r)}),h("div",{className:"mt-1 text-s-light text-secondary-text",children:i})]},String(t))},Me=(e,t="")=>{switch(e){case"tel":return h("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${Oe(t)}`,children:t});case"email":return h("a",{className:"text-xl-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return h("span",{children:t})}},Oe=e=>e.replaceAll(/\D/g,""),Be=p((({className:e="",index:t,text:n,href:r,target:i,onClick:l})=>h("a",{className:`text-secondary-text hover:text-primary-main inline-block no-underline ${e}`,href:r,target:i,onClick:l,children:n||`Документ ${t}`}))),Ve=p((({title:e,links:t,className:n="",context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return u("div",{className:n,children:[h("span",{className:"text-primary-text text-s font-medium",children:e}),t?.length?h("div",{className:"flex flex-col gap-2 pt-3",children:t.map(((e,t)=>h(Be,{index:t,className:"text-s",...Re({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),Pe=[{origins:["t.me","telegram.org"],icon:{icon:"TelegramIcon"},label:"Телеграм"},{origins:["vk.com"],icon:{icon:"VKIcon"},label:"ВКонтакте"},{origins:["ok.ru"],icon:{icon:"OkIcon"},label:"Одноклассники"},{origins:["apps.apple.com"],icon:{icon:"AppleIcon"},label:"App Store"},{origins:["play.google.com"],icon:{icon:"PlayMarketIcon"},label:"Google Play"}],Fe=p((({href:e,version:t="primary"})=>{const{icon:n,label:r}=Pe.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};if(!n)return null;return h("a",{className:`flex items-center justify-center rounded-md w-14 h-14 group box-border ${"secondary"===t?"bg-white hover:bg-secondary-hover":"border-solid border-[1px] border-main-divider hover:border-transparent hover:bg-primary-main"} ${"primary"===t?"hover:text-black":""}`,href:e,"aria-label":r,target:"_blank",rel:"noopener noreferrer",children:n?h(B,{image:V(n),imageClassName:"group-hover:text-white",width:"24",height:"24",asSVG:!0}):null})})),Ee=p((({className:e,media:t,version:n,context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return h("div",{className:`flex gap-2 items-start justify-start pt-6 pb-6 ${e||""}`,children:t?.map(((e,t)=>h(Fe,{version:n,...Re({router:i,handlerDecorator:l},e)},String(t))))})})),ze=p((({className:e="",index:t,text:n,href:r,target:i,onClick:l})=>h("a",{className:`text-xs-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:r,target:i,onClick:l,children:n||`Документ ${t}`}))),Ge=p((({className:e,links:t,context:n})=>{const r=n.useRouter(),{handlerDecorator:i}=n;return u("div",{className:`${e||""}`,children:[h("div",{className:"py-6",children:h("span",{className:"text-xs-light text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?h("div",{className:"flex flex-col justify-start items-start gap-2",children:t.map(((e,t)=>h(ze,{index:t,className:"",...Re({router:r,handlerDecorator:i},e)},String(t))))}):null]})})),He=p((({className:e="",documents:t,relatedEnterprises:n,contacts:r,socialMedia:i,context:l,horizontalNavigationTitle:a,page:s})=>{const o=s?.fallback,c=xe(o),d=c?.dispositions;return u("footer",{className:`font-sans px-4 py-[26px] bg-white ${e}`,children:[h(Ae,{className:"overflow-hidden",items:r,context:l,hasButton:!0}),h(w,{children:c.topItems?.map(((e,t)=>h(F,{context:l,label:e.text,children:h(fe,{context:l,documents:e.items})},String(t))))}),h("div",{children:d?.map(We)}),h($e,{context:l,title:"Мобильное приложение",description:"Загрузить для IOS и Android"}),h(be,{context:l,className:"grow"}),h(Ee,{className:"pb-4",media:i,context:l}),h(Ve,{title:a,links:n,context:l}),h(Ge,{links:t,context:l})]})})),We=(e,t)=>{const{icon:n,href:r,text:i}=e;return u(te,{version:"link",href:r,className:"flex text-s mb-4 w-6",children:[n?h(B,{className:"pr-1",image:V({icon:n}),width:"24",height:"24",asSVG:!0}):null,h("span",{className:"pl-2.5 font-medium text-primary-text",children:i})]},`footer-${t}`)},Je={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},Ue=p((({context:e,title:t,description:n,cards:r=[],className:i,orientation:l="horizontal"})=>u("section",{className:`relative font-sans text-primary-text bg-white px-4 py-6 overflow-hidden ${i}`,children:[u("div",{className:"flex flex-col items-center mb-5",children:[t?h(v,{headingType:"h3",className:`text-center ${n?"mb-2":"mb-5"}`,title:t}):null,n?h("div",{className:"text-m max-w-[600px] text-center mb-5",children:n}):null]}),Ye(l,r,e)]})));function Ye(e,t,n){return"horizontal"===e?h(U,{context:n,children:t?.map(Ke)}):h("div",{className:"grid gap-[14px]",children:t?.map(Ke)})}function Ke(e,t){return u("div",{className:`h-full justify-between box-border horizontal-list-item border-solid border rounded-md border-main-stroke p-4 flex flex-col\n ${Je[e.version??"primary"]}`,children:[u("div",{children:[Xe(e.icon),e.title?h("h3",{className:"text-m-title-xs font-medium m-0",children:e.title}):null,e.description?Qe(e):null,e.items?.length?qe(e.items,e.isDotted,e.version):null]}),e?.button?.text?(n=e.button,h(te,{className:"mt-3",...n})):null]},t);var n}const Xe=e=>e?.src||e?.icon?h("div",{className:"flex justify-center",children:h(B,{className:"mb-3.5",image:e})}):null;function Qe(e){return h("div",{className:"text-secondary-text mt-1 text-s "+("secondary"===e.version?"text-white opacity-80":""),children:e.description})}const Ze={primary:"bg-primary-text",secondary:"bg-white",gray:"bg-secondary-text"};function qe(e,t,n="primary"){return h("section",{className:"mt-3",children:e.map(((e,r)=>u("div",{children:[t?h("div",{className:`rounded-full inline-block mr-3 mt-2 w-2 h-2 min-w-2 min-h-2 ${Ze[n]}`}):null,h("span",{className:"text-m font-medium",children:e.title}),h("span",{className:"text-s pl-2 "+("primary"===n?"text-secondary-text":""),children:e.text})]},String(r))))})}const et=(e,t,n=((e,t)=>t.startsWith(e)))=>n(Se(e),(e=>(e||"").replace(De,""))(Se(Ce(e)?t.href:t.pathname))),tt=e=>t=>et(t.href,e),nt=e=>t=>t.items?.some(tt(e))||et(t.href,e)||((e,t)=>Te(e)===Te(t.href))(t.href,e),rt=e=>t=>e?.href===t?.href,it=(e,t)=>{return(r=e,i=t,(r||[]).map((e=>i?.find(rt(e))||e))).concat((n=e,(t||[]).filter((e=>!n?.find(rt(e))))));var n,r,i},lt="absolute left-0 -bottom-3 w-full h-[2px]",at=p((({className:e="",text:t,href:n,target:r,active:i,onClick:l,children:a,bgColor:s="bg-white"})=>u("a",{className:`relative inline-block bg-transparent text-center no-underline ${e}`,href:n,target:r,onClick:l,children:[h("span",{className:st(s,i),children:t||a}),i?h("div",{className:ot(s,i)}):null]}))),st=(e,t=!1)=>{let n="text-white";return"bg-white"===e&&(n=t?"text-primary-main":"text-secondary-text hover:text-primary-main"),`${n} font-sans text-s`},ot=(e,t=!1)=>t?`${"bg-white"===e?"bg-primary-main":e} ${lt}`:lt,ct=o("https://10.80.4.9");const dt=p((({context:e,burgerSubMenu:t,onClick:n,defaultLocation:a="",children:s})=>{const[o,c]=function(e){const[t,n]=r(e);return i((()=>{n(globalThis?.localStorage.getItem("location")||e)}),[e]),[t,l((()=>{ct.getFetcherAddress().then((t=>{const r=t||e;globalThis?.localStorage.setItem("location",r),n(r)}))}),[e])]}(a);return u("div",{className:"absolute top-0 left-0 w-full h-full bg-white p-4 box-border z-20",children:[h("button",{className:"absolute top-4 right-4 border-none bg-transparent cursor-pointer",onClick:n,children:h(B,{image:"CloseIcon",width:"24",height:"24",asSVG:!0})}),u("button",{onClick:c,className:"flex items-center text-s text-secondary-text p-0 mb-4 bg-transparent cursor-pointer",children:[h(B,{image:"GeolocationIcon",width:"20",height:"20",className:"text-primary-main box-border mr-2",asSVG:!0}),o]}),s,h("div",{className:"mb-7",children:t?.map(mt)}),h(be,{context:e,className:"grow"})]})})),mt=(e,t)=>{const{icon:n,href:r,text:i}=e;return u("a",{href:r,className:"flex text-s mb-4 hover:text-primary-main",children:[n?h(B,{className:"text-primary-main pr-1",image:n,width:"24",height:"24",asSVG:!0}):null,h("span",{className:"font-medium pl-0.5",children:i})]},`headerSubMenu-${t}`)},ht=p((({onClick:e,bgColor:t})=>u("div",{className:"flex items-center justify-between border-0 border-b border-main-divider h-[50px]",children:[u("div",{className:"flex items-center",children:[h("button",{className:"pl-0 pr-4 border-0 bg-transparent cursor-pointer",onClick:e,"aria-label":"Открыть меню",children:h(B,{image:{icon:"BurgerIcon",iconVersion:"bg-white"===t?"black":"white"},className:"text-primary-text w-6 h-6",width:"24",height:"24",asSVG:!0})}),h(ke,{className:"mr-8",bgColor:t})]}),h("button",{className:("bg-white"===t?"text-primary-main":"text-white")+" text-s border-0 bg-transparent cursor-pointer",children:"Войти"})]}))),ut=p((({className:e="",defaultLocation:t,bgColor:n="bg-white",context:i,topItems:l,page:a})=>{const{handlerDecorator:s}=i,o=i.useRouter(),c=a?.fallback,d=xe(c),m=it(d.topItems,l).find(nt(o))?.items,p=(e=>(t=[])=>{const n=t?.filter(tt(e));return n?.length?(r=e=>e.href?.length||0,e=>e.reduceRight(((e,t)=>r(e)>r(t)?e:t)))(n):void 0;var r})(o)(m),[x,g]=r(!1),b=()=>g(!x);return u("header",{className:`${n} ${e}`,children:[u("div",{className:"container px-4 py-0 box-border",children:[h(ht,{onClick:b,bgColor:n}),h("nav",{className:"flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]",children:h("div",{className:"flex no-scrollbar horizontal-list h-full items-center",children:m?.map(((e,t)=>pt({...Re({router:o,handlerDecorator:s},e),active:e===p,bgColor:n},t)))})})]}),x?h(dt,{context:i,onClick:b,burgerSubMenu:d?.dispositions,defaultLocation:t,children:h(w,{children:d.topItems?.map(((e,t)=>h(F,{context:i,label:e.text,children:h(fe,{context:i,documents:e.items})},String(t))))})}):null]})})),pt=(e,t)=>h(at,{className:"mr-8 whitespace-nowrap text-s",...e},String(t)),xt={left:"text-left",center:"text-center",right:"text-right"},gt={transparent:{background:"bg-transparent",text:"text-primary-text",description:"text-primary-text"},primary:{background:"bg-white",text:"text-primary-text",description:"text-primary-text"},secondary:{background:"bg-primary-main",text:"text-white",description:"text-white/80"}},bt=p((({bgColorHeadline:e="transparent",className:t="",title:n,description:r,image:i,align:l="left"})=>{const a=gt[e];return u("section",{className:`px-4 py-6 flex flex-col gap-2.5 ${a.background} ${t}`,children:[n?h(v,{headingType:"h2",className:`${a.text} ${xt[l]}`,title:n}):null,r?h("p",{className:`text-m ${a.description} ${xt[l]}`,children:r}):null,i?.src&&h("div",{className:"mt-2.5 mx-auto flex justify-center",children:h(B,{image:i})})]})})),ft=p((({className:e,iconClassName:t,textClassName:n,suffixClassName:r,doc:i,icon:l})=>{const{text:a,fileSize:s,...o}=i;return u("a",{className:e,role:"link",...o,children:[l?h(B,{className:t,image:V(l),width:"24px",height:"24px",asSVG:!0}):null,a?u("span",{className:n,children:[a,h("span",{className:r,children:o?.href&&Nt(yt(o.href),s)})]}):null]})})),Nt=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),yt=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},vt=p((({className:e="",doc:t,icon:n})=>h(ft,{className:`flex h-full box-border ${e}`,iconClassName:"mr-3 min-w-6 min-h-6",doc:t,icon:n}))),wt=p((({context:e,hasBorder:t=!0,documents:n,icon:r})=>h(U,{context:e,className:"text-s text-primary-main mt-5",children:n?.length?n.map(((e,n)=>h(vt,{className:t?"rounded-md border-main-stroke border border-solid p-4":"",doc:e,icon:r},String(n)))):null}))),kt=p((({hasBorder:e=!0,documents:t,icon:n})=>h("div",{className:"text-s text-primary-main flex flex-col mt-5 "+(e?"gap-3.5":"gap-2"),role:"list",children:t?.length?t.map(((t,r)=>h("div",{role:"listitem",children:h(vt,{className:e?"rounded-md border-main-stroke border border-solid p-4":"",doc:t,icon:n})},String(r)))):null}))),$t=p((({className:e="",context:t,title:n,description:r,icon:i={icon:"DocIconMonoColor"},documents:l,orientation:a="vertical",hasBorder:s=!0})=>u("section",{className:`font-sans text-primary-text py-6 px-4 bg-white overflow-x-hidden ${e}`,children:[h(bt,{className:"!p-0 "+(r?"gap-2":"gap-5"),title:n,description:r,context:t,align:"center"}),"vertical"===a?h(kt,{hasBorder:s,documents:l,icon:i}):h(wt,{context:t,hasBorder:s,documents:l,icon:i})]}))),Ct=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12};function St(e=""){const t=Ct(e);return t<=4?"S":t<=8?"M":"L"}function Tt(e=""){const t=Ct(e);return t<=6?"min-h-[300px]":t<=8?"min-h-[320px]":"min-h-[360px]"}function _t(e=""){const t=Ct(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const Dt=p((({className:e,context:t,title:n,description:r="Блок в разработке...",...i})=>u(N,{context:t,className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${_t(e)} ${Tt(e)} `,...i,children:[h(bt,{context:t,className:"!p-0 max-w-[600px]",title:n,description:r,headlineVersion:St(e)}),h("figure",{className:"m-0 min-w-[80%]",children:It()})]}))),It=(e=3)=>Rt(100,e).map((e=>Math.floor(e))).map(jt),jt=(e,t)=>h("div",{style:{width:`${e||100}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),Rt=(e,t)=>[e].concat(t>0?Rt(e/1.618,t-1):[]),At=p((({context:e,className:t="",buttons:n})=>{const{handlerDecorator:r}=e,i=e.useRouter();return n&&n?.length?h("div",{className:t,children:n.map(((e,t)=>Lt({button:Re({router:i,handlerDecorator:r},e),index:t})))}):null}));function Lt({button:e,buttonClassName:t,index:n}){const{icon:r,iconRight:i,version:l,...a}=e,s="secondary"===l?"color":"white",o=Mt({...r,iconVersion:s}),c=Mt({...i,iconVersion:s});return h(te,{className:t,appendLeft:o,appendRight:c,version:l,...a},n?String(n):"")}const Mt=e=>{if(!e?.icon&&!e?.src)return null;const t=e?.size?.width?`${e.size.width}`:"24";return h(B,{image:{...e},width:t,height:"24",asSVG:!0})},Ot={primary:"bg-primary-text",secondary:"bg-white",gray:"bg-secondary-text"},Bt={L:"w-1.5 h-1.5 min-w-1.5 min-h-1.5 mr-4",M:"w-1.5 h-1.5 min-w-1.5 min-h-1.5 mr-3",S:"w-1 h-1 min-w-1 min-h-1 mr-2"},Vt=p((({className:e="",isDotted:t=!0,children:n,version:r="primary",size:i="M"})=>u("div",{className:`font-sans flex items-baseline ${e}`,role:"listitem",children:[t?h("div",{children:h("div",{className:`rounded-full align-middle inline-block ${Ot[r]} ${Bt[i]}`})}):null,h("span",{children:n})]}))),Pt={primary:"text-primary-text",secondary:"text-white",gray:"text-secondary-text"},Ft={S:"text-l-light",M:"text-h6",L:"text-h5"},Et={S:"ml-2",M:"ml-3",L:"ml-4"},zt=p((e=>{const{className:t="",hasIndent:n,isDotted:r,itemClassName:i="",items:l,listItemSize:a="M",version:s="primary"}=e;return l?.length?h("section",{className:`${Pt[s]} ${Ft[a]} ${t} ${n?Et[a]:""}`,role:"list",children:l.map(((e,t)=>h(Vt,{className:`${i} mb-1.5`,isDotted:r,version:s,size:a,children:e},String(t))))}):null})),Gt=p((({className:e="",title:t="",children:n,buttons:r,image:i})=>u("div",{className:`font-sans flex flex-col grow h-full items-start ${e}`,children:[t,u("div",{className:"flex grow w-full justify-between",children:[u("div",{className:"flex flex-col justify-between w-full",children:[h("div",{className:"h-full",children:n}),r?h("div",{className:"mt-auto pt-8",children:r}):null]}),i]})]}))),Ht={primary:"text-primary-text",secondary:"text-white"},Wt={primary:"text-secondary-text",secondary:"text-white"},Jt=p((e=>{const{className:t="",icon:n,label:r,description:i,version:l="primary",benefitsVersion:a="normal"}=e,s="white"===a?"secondary":"primary";return u("div",{className:`flex gap-5 ${i?"items-start":"items-center"} ${t}`,children:[n?h("div",{className:Ut(l,a),children:h(B,{className:"w-6 h-6",image:V(n,s),asSVG:!0})}):null,u("div",{className:"gap-0.5",children:[r?h("div",{className:`text-h6 ${Ht[l]}`,children:r}):null,i?h("div",{className:`text-m-light ${Wt[l]}`,children:i}):null]})]})}));function Ut(e,t){let n="bg-primary-main text-black";return"secondary"===e?n="bg-white/30 text-black":"normal"===t&&(n="bg-secondary-light text-primary-main"),`w-[50px] h-[50px] min-w-[50px] rounded-full p-2.5 box-border flex items-center justify-center ${n}`}const Yt=(e="primary",t="normal")=>({icon:n,label:r,description:i},l)=>h(Jt,{icon:n,label:r,description:i,version:e,benefitsVersion:t},String(l)),Kt=p((({className:e="",context:t,title:n,headlineVersion:r="L",description:i,benefits:l,benefitsVersion:a="normal",buttons:s,image:o,items:c,version:d="primary",isDotted:m=!0,label:p})=>u("div",{className:`w-full ${e}`,children:[u("div",{children:[p?Zt(p,d):null,h(bt,{context:t,className:"!p-0 max-w-[600px]",title:n,description:i,bgColorHeadline:d,headlineVersion:r}),u(Gt,{context:t,buttons:s?.length?h(At,{context:t,buttons:s,className:"flex flex-col mt-5 gap-2.5"}):null,children:[l?.filter((e=>e.label))?.length?h("div",{className:"mt-3",children:l.map(Yt(d,a))}):null,c?.length?h(zt,{className:"mt-3 text-m",items:c,version:d,isDotted:m}):null]})]}),Xt(o)]})));function Xt(e){return e?.src?h(B,{imageClassName:"mt-5 mx-auto block",image:{className:"block",...e}}):null}const Qt={primary:"text-primary-main border-secondary-hover",secondary:"text-white/80"},Zt=(e,t)=>h("div",{className:`px-2.5 py-1.5 mb-5 rounded-md border-2 border-solid w-fit ${Qt[t]}`,children:e}),qt=p((e=>{const{className:t="",version:n="primary"}=e;return h("section",{className:`font-sans bg-white px-4 py-6 ${Je[n]} ${t}`,children:h(Kt,{...e})})})),en=p((({block:e,context:t,className:n=""})=>h("section",{className:`flex grow-0 shrink-0 basis-full px-4 pt-6 ${Je[e?.version??"primary"]} ${n}`,role:"listitem",children:h("div",{className:"flex grow",children:h(Kt,{context:t,...e})})}))),tn=p((({className:e,context:t,slides:n=[]})=>{const r=n.map((e=>e.productBlock));return h("section",{className:`font-sans bg-white overflow-hidden w-100 pb-6 ${e||""}`,children:h(U,{context:t,children:r.map(((e,n)=>h(en,{block:e,context:t},String(n))))})})})),nn={primary:{background:"bg-white",title:"text-primary-text",description:"!text-secondary-text text-l-light",iconText:"text-secondary-text",iconBackground:"bg-main-divider",iconConnector:"bg-secondary-light",dot:"bg-secondary-text"},secondary:{background:"bg-primary-main",title:"text-white",description:"!text-white/80 text-l-light",iconText:"text-white",iconBackground:"bg-white/30",iconConnector:"bg-white",dot:"bg-white/80"}},rn={normal:"h-[70px] w-[70px] min-w-[70px] min-h-[70px]",small:"h-[50px] w-[50px] min-w-[50px] min-h-[50px]"},ln={normal:"min-h-[70px]",small:"min-h-[50px]"},an=p((({className:e,title:t,description:n,showLines:r=!0,steps:i,size:l="normal",version:a="primary"})=>{const s=nn[a];return u("section",{className:`box-border font-sans bg-white px-4 py-6 flex flex-col\n ${s.background} ${s.title} ${e||""}`,children:[t?h(v,{headingType:"h3",className:`text-center ${s.title}`,title:t}):null,n?h("p",{className:`text-m-light text-center ${s.description} ${t?"mt-2":""}`,children:n}):null,i?.length?h("div",{className:"box-border py-0.5 mb-0.5 mt-5",children:h("div",{className:"flex flex-col justify-between gap-x-[101px]",children:i.map(sn(l,a,r))})}):null]})})),sn=(e,t,n)=>(r,i,l)=>{const a=l.length-1===i,s="normal"===e?"ml-[34px]":"ml-6",o=nn[t];return h("div",{children:u("div",{className:"flex flex-row text-center relative",children:[u("div",{className:"overflow-hidden flex-shrink-0",children:[on(e,t)(r,i),a?null:h("div",{className:`min-h-8 h-full w-[2px] ${n?o.iconConnector:""} ${s}`})]}),u("div",{className:`flex flex-col justify-center h-fit ${ln[e]}`,children:[r.label?h("div",{className:"text-m-title-xs font-medium m-0 text-left mb-1",children:r.label}):null,r.description?h("div",{className:`text-s ${o.description} text-left`,children:r.description}):null]})]})},String(i))},on=(e,t)=>(n,r)=>{const i=nn[t],l="normal"===e?"38":"27",a="normal"===e?"text-m-title":"text-m-title-xs";return h("div",{className:`${rn[e]} ${i.iconBackground} rounded-full z-10 mr-3 flex justify-center content-center`,children:h("span",{className:`font-medium flex self-center ${i.title} ${a}`,children:(s=n?.icon,Boolean(s?.icon||s?.src)?h(B,{image:V({...n.icon},t),width:l,height:l,asSVG:!0}):h("span",{children:r+1}))})});var s},cn={Buttons:({buttons:e})=>e&&e?.length?h("div",{children:e.map((({rounded:e,icon:t,...n},r)=>Lt({button:{rounded:e,icon:t,...n},buttonClassName:`mt-3 ${r>0&&e?"ml-2.5":""} ${t?"w-12 h-12":""}`,index:r})))}):null,Img:({image:e})=>e?.src?h(B,{image:{...e,className:"m-0"}}):null,List:({isDotted:e,...t})=>h(zt,{className:"flex flex-col justify-between items-start text-m",version:"gray",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>u("div",{children:[e?h("div",{className:"text-xl font-medium m-0 "+(t?"mb-1":""),children:e}):null,t?h("div",{className:"text-s text-secondary-text",children:t}):null]})},dn=p((({title:e,icon:t})=>u("div",{className:"flex gap-2.5 mb-2",children:[e?h(v,{headingType:"h3",className:"font-medium",title:e}):null,t?h(B,{className:"ml-auto max-w-6 max-h-6",image:t,width:"24px",height:"24px"}):null]}))),mn=p((({context:e,tile:t})=>u("div",{className:"rounded-md border-main-stroke h-full box-border border p-4",children:[h(dn,{...t.header}),t.data?.length?t.data.map(hn(e)):null]}))),hn=e=>(t,n)=>u("div",{children:[n>0?h("div",{className:"h-5"}):null,un(t,e)]},String(n)),un=(e,t)=>{if(!e)return null;const{tableCellType:n,...r}=e;if(!n||!(n in cn))return null;return h(cn[n],{context:t,displayTable:()=>null,...r,isVisible:!0})},pn=p((({tiles:e,context:t})=>h(U,{context:t,children:e.map(((e,n)=>h(mn,{tile:e,context:t},String(n))))}))),xn=p((({tiles:e,context:t})=>h("div",{className:"flex flex-col gap-3.5",children:e.map(((e,n)=>h(mn,{tile:e,context:t},String(n))))}))),gn=p((({className:e,context:t,title:n,description:r,tariffsColumns:i,rowHeaders:l,orientation:a="vertical"})=>{const s=fn(i),o=Nn(l,s);return u("section",{className:`px-4 py-6 bg-white font-sans text-primary-text overflow-x-hidden ${e}`,children:[n?h(v,{headingType:"h2",className:`text-center ${r?"mb-2":"mb-5"}`,title:n}):null,r?h("div",{className:"mb-5 text-center text-m",children:r}):null,o?.length?bn(a,o,t):null]})}));function bn(e,t,n){return h("vertical"===e?xn:pn,{context:n,tiles:t})}const fn=e=>e?.[0].data?e[0].data:[],Nn=(e,t)=>e?.map(((e,n)=>({header:e,data:t?.[n]||[{}]}))),yn={primary:{background:"bg-white",icon:"bg-primary-main text-white",title:"text-primary-text",description:"text-secondary-text"},secondary:{background:"bg-primary-main",icon:"bg-white text-primary-main",title:"text-white",description:"text-white"},"secondary-light":{background:"bg-primary-main/10",icon:"bg-primary-main text-white",title:"text-primary-text",description:"text-secondary-text"}},vn=p((({title:e,description:t,blockVersion:n="primary",iconVersion:r,image:i,className:l="",items:a,isDotted:s=!0})=>{const o=yn[n],c="secondary"===n?"secondary":"gray";return u("section",{className:`font-sans px-4 py-[18px] flex flex-col ${o.background} ${l}`,children:["small"===r?wn(o.icon):null,"big"===r?kn(i):null,u("div",{className:"py-0.5",children:[e?h("div",{className:`text-l font-medium mb-1 ${o.title}`,children:e}):null,t?h("div",{className:`text-s ${o.description}`,children:t}):null,a?.length?h(zt,{className:"mt-1 text-m",items:a,isDotted:s,version:c}):null]})]})}));function wn(e){return h("div",{className:"mb-3",children:h("div",{className:`rounded-full h-4 w-4 text-center text-xs-light ${e}`,children:"i"})})}function kn(e){return e?.src?h(B,{className:"pb-3 mr-auto",image:e}):null}const $n={Accordion:k,AccordionItem:F,ComparisonTable:ce,Footer:He,Gallery:Ue,Header:ut,Headline:bt,LinkDocs:$t,LinkList:fe,MobileAppTile:$e,ProductBlock:qt,ProductGallery:tn,StepsBlock:an,TariffsTable:gn,TextBlock:vn,Placeholder:Dt};function Cn(e){return e?e.filter(Boolean).join(" "):""}const Sn=m();const Tn=p((({className:e,onClick:t,ariaLabel:n})=>h("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":n,children:_n()}))),_n=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return u("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[h("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"}),h("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"})]})},Dn=p((({className:e,context:t,...n})=>{const{useRouter:a,handlerDecorator:s=je}=t,o=function(e){const[t,n]=r(0);return i((()=>{(async()=>{const[t]=await Sn.getLikeCount(e);n(t?.value||0)})()}),[e]),{likeCount:t,like:l((async()=>{n(await Sn.like(e))}),[e]),dislike:l((async()=>{n(await Sn.dislike(e))}),[e])}}(a().pathname);return u(N,{tag:"div",context:t,className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e||""}`,...n,children:[h(Tn,{onClick:s(o.like),ariaLabel:"Поставить отметку «лайк»"}),h(Tn,{onClick:s(o.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),h("span",{className:"select-none",children:o.likeCount})]})}));function In({slots:e={},parent:t,options:n,ancestors:r=[]}){return Object.entries(e).reduce(((e,[i,l])=>({...e,[i]:Rn({blocks:l,parent:t,slotName:i,options:n,ancestors:r})})),{})}const jn=e=>e;function Rn({blocks:e=[],parent:t,slotName:n=null,options:r,ancestors:i=[]}){const{blocksRegistry:l={}}=r,{type:a}=t,s=a&&l[a],{renderChild:o=jn}=s||{};return e.map(((e,l)=>o(function({block:e={},options:t,ancestors:n=[]}){const{key:r,page:i,blockDecorator:l,blocksRegistry:a={},context:s}=t,{type:o,slots:c,blocks:d}=e;o&&o in a||console.warn(`No block with "${o}" is registered`);const m=o&&a[o],u={parent:e,options:t,ancestors:n},p=Rn({...u,blocks:d}),x=c?In({...u,slots:c}):{};return l({blockClassName:`scroll-mt-12 ${Cn(e.style)}`,block:e,ancestors:n,render:({block:e,blockClassName:t})=>{const{version:l,anchor:a,labels:o,content:c}=e;return m?h(m,{className:t,context:s,page:i,ancestors:n,version:l,anchor:a,labels:o,slots:x,...c,children:p},r):null}},r)}({block:e,options:{...r,key:`${r.key?r.key:e.type}-${l}`},ancestors:[...i,[t,n]]}),l)))}const An=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),Ln=p((e=>{const{className:t="",blocksRegistry:n,blockDecorator:r,context:i,data:l={}}=e,{style:a,blocks:s,slots:o,likeControl:c,colorPalette:d="pc"}=l,m={key:"",blocksRegistry:n,page:l,blockDecorator:r||An,context:i},p=In({slots:o,parent:l,options:m});return u("section",{className:`relative ${Cn(a)} ${t}`,"data-theme":d,children:[p?.header?h("div",{className:"mb-5 shadow-[0_8px_32px_0px_#00000014]",children:p.header}):null,s?.length?u("div",{className:"container grid grid-cols-12 gap-1",children:[Rn({blocks:s,parent:l,options:m}),p?.footer?p.footer:null]}):null,c?Mn(i):null]})}));function Mn(e){return h("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:h(Dn,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:e},"LikeControl")})}Ln.childrenTypes=[],Ln.slots=()=>["header","footer"];e.Blocks=$n,e.ContentPage=Ln,e.DaDataAPI=o,e.LikeAPI=m,e.joinList=function(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])},e.packageVersion="0.6.24",e.projectSettings=c,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=_e,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).UniMobileBlocks={})}(this,(function(e){"use strict";let t;const n=e=>(...n)=>t[e](...n),r=n("useState"),i=n("useEffect"),l=n("useCallback"),a=n("useMemo"),s=n("useRef");function o(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))))))(),n=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await n.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}}const c=new class{_={PROD_BRANCH:"master",FORCED_DRAFT_FLOW:!1};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}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ASSIST_PROJECT_ID(){return this._.ASSIST_PROJECT_ID}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}get YANDEX_MAP_API_KEY(){return this._.YANDEX_MAP_API_KEY}get YANDEX_METRIKA_ID(){return this._.YANDEX_METRIKA_ID}},d="likesToken";function m(){async function e(){try{const e=JSON.parse(globalThis.localStorage.getItem(d)||"");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:n}=await e.json();return globalThis.localStorage.setItem(d,JSON.stringify({token:t,name:n})),{token:t,name:n}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...t){if(!t.length)return[];const{token:n}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n},body:JSON.stringify({node_ids:t})}),{likes:r}=await e.json();return r||[]}catch(e){return console.error(e),[]}},like:async function(t){if(!t)return 0;const{token:n,name:r}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n,UserID:r},body:JSON.stringify({node_id:t,user_name:r})}),{likes:i}=await e.json();return i||0}catch(e){return console.error(e),0}},dislike:async function(t){if(!t)return 0;const{token:n,name:r}=await e();try{const e=await fetch(`/assist/v1/public/projects/${c.ASSIST_PROJECT_ID}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:n,UserID:r},body:JSON.stringify({node_id:t,user_name:r})}),{likes:i}=await e.json();return i||0}catch(e){return console.error(e),0}}}}const h=(...e)=>globalThis._uni._jsx(...e),u=(...e)=>globalThis._uni._jsxs(...e),p=e=>{const t=e;return t._tmpl||(t._tmpl=globalThis.__UNI_REACT__?e:x(e)),t._tmpl},x=e=>{function t(t,n){const{children:r,...i}=t||{},l=n?.slots?.default,a=r||l&&l();return e(Object.assign(i,a&&{children:a}),n)}return t.inheritAttrs=!1,t};class g{static inst=new g;subscribers={};subjectsStateMap={};subscribe(e,t){this.subscribers[e]||=[],this.subscribers[e]?.push(t);const n=this.subjectsStateMap[e];return n&&t(n),()=>{this.unsubscribe(e,t)}}unsubscribe(e,t){this.subscribers[e]=this.subscribers[e]?.filter((e=>e!==t))}fire(e,t){this.subjectsStateMap[e]=t,this.subscribers[e]?.forEach((e=>e(t)))}subject(e,t){this.subjectsStateMap[e]=t}}const b=100,f={threshold:new Array(18).fill(0).map((function(e,t){const n=(t+1)/b+.82;return Math.round(n*b)/b}))},N=p((({anchor:e,className:t,children:n,tag:l="section",labels:o,role:c})=>{const d=l,[m,u]=r(!0),p=s({}),x=a((()=>(({anchor:e,anchorClickRef:t})=>n=>{if(!n?.length)return;const[r]=n;!r.isIntersecting||r.boundingClientRect.top>150||(t?.current?.isScrolling&&t.current.label===`#${e}`?(g.inst.fire("anchorClick",{isScrolling:!1,label:void 0}),g.inst.fire("tab",{type:"link",label:e})):t?.current?.isScrolling||g.inst.fire("tab",{type:"link",label:e}))})({anchor:e,anchorClickRef:p})),[e]),b=function(e,t){const n=s(null);return i((()=>{if(!n.current)return;const r=new IntersectionObserver(e,t);return r.observe(n.current),()=>{r.disconnect()}}),[e,t]),n}(x,f);return i((()=>g.inst.subscribe("anchorClick",(e=>{u(!0),p.current=e}))),[]),i((()=>g.inst.subscribe("tab",(t=>{if("group"===t.type){const n=o?.length||e;u(!t.label||(!n||Boolean(o?.includes(t.label))))}else(n=t.label)&&(globalThis.document.location.hash=n),u(!0);var n}))),[]),m?h(d,{className:t,role:c,...e?{id:e,ref:b}:{},children:n}):null}));const y={h0:"text-m-title",h1:"text-m-title",h2:"text-m-title",h3:"text-h6",h4:"text-m-title-xs",h5:"text-m-title-xs",h6:"text-m-title-xs"},v=p((e=>{const{className:t,headingType:n="h3",title:r,as:i="h3"}=e;return h(i,{className:`font-sans font-medium m-0 ${y[n]} ${t||""}`,children:r})})),w=p((({children:e})=>h("ul",{className:"list-none m-0 p-0",children:e}))),k=p((({title:e,description:t,context:n,className:r="",children:i,...l})=>u(N,{context:n,className:`py-6 px-4 font-sans bg-white text-primary-text ${r}`,...l,children:[e?h(v,{headingType:"h3",className:"mb-2 text-center",title:e}):null,t?h("div",{className:"mb-5 text-m-light text-center",children:t}):null,h(w,{children:i})]})));k.childrenTypes=["AccordionItem"];const $=p((({isFoldButtonOnTop:e=!1,unfoldedByDefault:t=!1,renderFoldableSection:n,renderFoldButton:i})=>{const[a,s]=r(t),o=l((()=>{s((e=>!e))}),[]),c=n({isUnfolded:a,onToggle:o}),d=i?i({isUnfolded:a,onToggle:o}):null;return u("div",e?{children:[d,c]}:{children:[c,d]})})),C=p((({className:e="",isUnfolded:t,children:n})=>{const r=s(null);return i((()=>{r.current&&(r.current.style.maxHeight=t?`${r.current.scrollHeight}px`:"")}),[t,n?.length]),h("div",{ref:r,className:`transition-max-h duration-300 overflow-hidden max-h-0 ${e}`,children:n})})),S={normal:"",color:"text-primary-main",black:"text-black",white:"text-black"},T=p((({className:e="",imageClassName:t="",name:n="",alt:r=`Иконка ${n}`,title:i=r,iconVersion:l="color",asSVG:a,...s})=>{const o=`${c.CDN||""}icons/${n}.svg`;return a&&"normal"!==l?h(I,{className:e,children:u("svg",{className:[D(e,s.width),S[l],t,_(l)].join(" "),...s,"aria-hidden":"true",children:[i?h("title",{children:i}):null,r?h("desc",{children:r}):null,h("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]})}):h("img",{className:e,src:o,alt:r,title:i,...s,"aria-hidden":"true"})})),_=e=>"white"===e?"invert":"",D=(e,t)=>t?`width: ${t}px `:"w-full h-full",I=p((({className:e,children:t})=>e?h("div",{className:e,children:t}):t));function j(e){return"string"==typeof e?"normal":e?.iconVersion||"normal"}const R=(e,t)=>e.media&&t.media?e.media-t.media:0,A=p((({className:e="",image:t,imageClassName:n="",isMobile:r=!1})=>{if(!t||!t?.sources&&!t?.src)return null;return u("picture",{className:`${r?"flex":"flex-none"} ${e}`,children:[t?.sources?.length?t.sources.sort(R).map((({src:e,format:n,media:r},i)=>h("source",{srcSet:e,type:M(n),media:r?`(max-width: ${r}px)`:"",...t.size},`${i}_${e}`))):null,L(t,n,r)]})})),L=(e,t="",n=!1)=>{const r={width:e.size?.width?`${e.size?.width}px`:"100%",height:e.size?.height?`${e.size?.height}px`:"100%"},i=e.title||"",l=e.alt||e.title,a=n?"m-auto":"m-0";return h("img",{src:e.src,className:`${a} ${t}`,alt:l,title:i,style:r,...e.size})};function M(e){return e?`image/${String(e)}`:void 0}const O=p((({className:e="",image:t,imageClassName:n="",isMobile:r,...i})=>{if(!t)return null;const l="string"==typeof t?t:t.icon;return l||""===l?l.length?h(T,{className:e,imageClassName:n,iconVersion:j(t),name:l,...i}):null:h(A,{className:e,imageClassName:n,image:t,isMobile:r})})),B=p((e=>h(O,{...e,isMobile:!0}))),V=(e,t="primary")=>({...e,iconVersion:e?.iconVersion??("secondary"===t?"white":"color")}),P=["PlusIcon","MinusIcon"],F=p((({className:e="",ancestors:t,label:n="",labelIcon:r,isExpanded:i,children:l})=>{const{bordered:a}=function(e,t){const{content:n}=function(e,t){const[n]=(e||[]).map((e=>e)).reverse().find((([e])=>e&&"type"in e&&(!t||t===e.type)))||[];return n||{}}(e);return n||t}(t,{});return h("li",{className:`${a?"border p-4 rounded mb-4":"border-0 border-b last:border-b-0"} border-solid border-main-divider ${e}`,children:h($,{isFoldButtonOnTop:!0,unfoldedByDefault:i,renderFoldableSection:({isUnfolded:e})=>h(C,{className:"flex flex-wrap group-last:last:pb-0 gap-5 [&>*]:p-0",isUnfolded:e,children:l}),renderFoldButton:({isUnfolded:e,onToggle:t})=>h(E,{className:a?"":"py-[14px] px-0",label:n,icon:P[Number(e)],primaryIcon:r,onClick:t})})})}));F.childrenTypes=[];const E=p((({className:e,icon:t,label:n,primaryIcon:r,onClick:i})=>u("button",{className:`border-none bg-transparent flex justify-between text-left w-full font-sans text-primary-text group cursor-pointer ${e}`,onClick:i,children:[u("span",{className:"text-m-title-xs font-medium pr-2.5 flex group-hover:text-primary-main",children:[r?h(B,{image:V(r),className:"mr-3 flex-shrink-0",width:"24",height:"24",asSVG:!0}):null,n]}),h(B,{className:"flex-shrink-0",image:V({icon:t}),width:"24",height:"24",asSVG:!0})]}))),z=p((({children:e,activeIndex:t,indexFraction:n,showDots:r})=>{const i=e=>n=>{if(e===t)return;const r=n.currentTarget.parentElement?.previousElementSibling;r?.children[e]?.scrollIntoView({behavior:"smooth",block:"nearest"})};return r&&e?.length?h("div",{className:"flex gap-2 mx-auto mt-5 w-fit",children:e?.map(((e,r)=>h("div",{onClick:i(r),className:"bg-primary-main opacity-30 w-1.5 h-1.5 min-w-1.5 min-h-1.5 rounded-full",style:G(r,t,n),"aria-hidden":!0},String(r))))}):null})),G=(e,t,n)=>{if(e<t||e>t+1)return;const r=1-n;return e===t?{opacity:""+(.3+.7*r),width:6+16*r+"px"}:{opacity:""+(.3+.7*n),width:6+16*n+"px"}},H=p((({className:e="",children:t,...n})=>h("div",{className:`snap-center snap-always min-w-full box-border ${e}`,role:"listitem",...n,children:t}))),W=e=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e}px`}),J=p((({className:e="",children:t,activeIndex:n,onScroll:r,gap:i=14,padding:l=16})=>h("div",{className:`overflow-auto flex horizontal-list no-scrollbar ${e}`,style:{...W(l),gap:`${i}px`},role:"list",onScroll:r,children:t?.length?t?.map(((e,t)=>h(H,{style:W(l/4),"aria-current":Boolean(n===t),children:e},String(t)))):h(H,{children:t})}))),U=p((({className:e,children:t,gap:n=14,padding:i=16,showDots:l=!0,onSlideChange:a})=>{const[s,o]=r(0),[c,d]=r(0),m={activeIndex:s,indexFraction:c,showDots:l,children:t};return u("div",{className:e,children:[h(J,{gap:n,padding:i,activeIndex:s,onScroll:e=>{const{scrollLeft:t,clientWidth:r,childElementCount:l,scrollWidth:c,children:m}=e?.currentTarget,h=m[0].offsetWidth-i/2,u=(({gap:e,padding:t,clientWidth:n,scrollWidth:r,childElementCount:i,itemWidth:l})=>{const a=r-n;if(2===i)return[[0,a],[a,r]];const s=l+e,o=n-e-t,c=i-2,d=new Array(i).fill(0).map(((e,t)=>0===t||t===c?[t>0?a-o:0,t>0?a:o]:[(t-1)*s+o,t*s+o]));return d[i-1]=[a,r],d})({gap:n,padding:i,clientWidth:r,scrollWidth:c,childElementCount:l,itemWidth:h}),{index:p,fraction:x}=((e,t)=>{const n=t.findIndex((([t,n])=>t<=e&&e<n));if(n<0)return{index:n,fraction:0};const[r,i]=t[n];return{index:n,fraction:(e-r)/(i-r)}})(t,u);p!==s&&a&&a(),o(p),d(x)},children:t}),h(z,{...m})]})})),Y={primary:"group-hover:brightness-0 group-hover:invert",secondary:"group-hover:brightness-0 group-hover:invert",white:"group-hover:brightness-0 group-hover:invert",link:""},K=p((e=>{const{text:t,aboveText:n,appendLeft:r,appendRight:i,version:l="primary"}=e;return u("div",{className:X(e),children:[r?h("div",{className:Y[l],children:r}):null,Q(e)?u("div",{children:[h("div",{className:"text-xs-light text-left",children:n}),h("div",{className:"text-left "+(n?"text-s -mt-0.5":"text-l"),children:t})]}):null,i?h("div",{className:Y[l],children:i}):null]})})),X=e=>{const{className:t="",version:n,aboveText:r,rounded:i}=e;if("link"===n)return"";const l="gap-2 "+(r?"py-2.5 px-7":"py-4 px-9");return["group flex items-center justify-center",Q(e)?l:"h-12 w-12",i?"rounded-full":"",t].join(" ")},Q=({text:e,aboveText:t,appendLeft:n})=>Boolean(e||t||!n),Z={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",link:"text-primary-main"},q={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text",white:"bg-white text-primary-text",link:""},ee="w-full text-center font-sans select-none",te=p((({className:e,text:t,aboveText:n,appendLeft:r,href:i,target:l,onClick:a,children:s,disabled:o,rounded:c,version:d="primary",ariaLabel:m,...u})=>{const{appendRight:p,...x}=u,g=s??h(K,{text:t,aboveText:n,appendLeft:r,rounded:c,version:d});return o?h("div",{role:"button","aria-disabled":"true","aria-label":m,tabIndex:-1,className:`inline-block ${ee} ${q[d]||""} ${c?"rounded-full":"rounded-md"} ${e||""}`,children:g}):h("a",{className:`${ee} inline-block cursor-pointer no-underline focus:border focus:border-primary-focus ${Z[d]||""} ${c?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:a,"aria-label":m,role:i?"link":"button",...x,children:g})})),ne=(e=!1)=>e?"text-white":"",re=(e=!1)=>"text-s mb-3.5 "+(e?"text-white":"text-secondary-text/80"),ie=p((({icon:e,image:t,title:n,subtitle:r,isFillGradient:i})=>u("div",{role:"columnheader",children:[e?h(B,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",image:e,width:"63",height:"63"}):null,t?.src&&h("div",{className:"mb-3.5",children:h(B,{image:t})}),n?h(v,{headingType:"h4",className:ne(i),title:n}):null,r?h("div",{className:re(i),children:r}):null]}))),le=p((({cell:e,rowHeader:t,isFillGradient:n=!1})=>h("div",{className:"box-border flex flex-col",role:"cell",children:h("div",{className:"h-full border-main-divider border border-t-0 border-x-0",children:e.map(ae(n,t))})}))),ae=(e,t)=>({label:n,description:r},i)=>u("div",{className:"flex justify-between text-s py-3.5",children:[h("div",{className:""+(e?"text-white/80":"text-secondary-text"),children:t}),u("div",{className:"basis-1/2",children:[n?h("div",{className:"text-right "+(e?"text-white":""),children:n}):null,r?h("div",{className:"text-right "+(e?"text-white/80":"text-secondary-text"),children:r}):null]})]},String(i)),se=p((({header:e,columnData:t,visibleRowLength:n=0,isFillGradient:r,showRow:i,onToggleColumn:l})=>{const a=t?.slice(0,i?t.length:n),s=r?"secondary":"primary";return u("div",{className:`border border-main-stroke rounded-md p-4 mb-3.5 ${r?"bg-gradient-to-r from-main-gradient-start to-main-gradient-end":""}`,role:"row",children:[h(ie,{...e,isFillGradient:r}),a?.length?a.map((({rowHeader:e,cell:t},n)=>h(le,{cell:t,rowHeader:e,isFillGradient:r},String(n)))):null,i&&e?.link?h(te,{href:e.link.href,target:e.link.target,version:s,className:"text-s font-medium mt-4 py-[11px]",children:e.link.text}):null,oe({onToggleColumn:l,isFillGradient:r,showRow:i})]})})),oe=({onToggleColumn:e,isFillGradient:t,showRow:n})=>h("div",{className:"mt-5",role:"cell",children:h("a",{role:"link",onClick:e,className:"text-s font-medium cursor-pointer "+(t?"text-white/80":"text-primary-main"),children:n?"Скрыть":"Показать описание"})}),ce=p((e=>{const{className:t,title:n}=e;return u("section",{className:`bg-white font-sans px-4 py-6 overflow-hidden text-primary-text relative ${t||""}`,children:[n?h(v,{headingType:"h3",className:"font-medium text-center m-0 mb-5",title:n}):null,h("div",{role:"table",children:h(de,{...e})})]})})),de=p((({columns:e,rowHeaders:t,isColoredFirstColumn:n,visibleRowLength:i,orientation:a,context:s})=>{const[o,c]=r(new Array(e?.length||0).fill(!i)),d=l((e=>{const t=(t,n)=>n===e?!t:t;c((e=>e.map(t)))}),[]),m=l((()=>c((e=>new Array(e.length).fill(!1)))),[]),u=e?.map((({data:e,header:r},l)=>{return h(se,{context:s,visibleRowLength:i,showRow:o[l],header:r,columnData:(a=e,a?.map(((e,n)=>({cell:e,rowHeader:t?.[n]?.title})))),isFillGradient:0===l&&n,onToggleColumn:()=>d(l)},String(l));var a}));return"horizontal"===a?h(U,{context:s,onSlideChange:m,children:u}):u})),me=new Map;function he(e,t,{fallback:n}={}){const l=a((()=>ue(e)),[e]),[s,o]=r(),[c,d]=r(),m=e=>{o(e),d(void 0)},h=e=>{o(void 0),d(e)};i((()=>{if(!l.every((e=>null===e)))try{const e=t(...l);"then"in e?(e=>{e.then((e=>me.get(l)||e)).then(m).catch(h)})(e):m(e)}catch(e){h(e)}}),[t,...l]);const u=l[0],p=n&&"string"==typeof u&&n[u];return{data:s||c||!p?s:p,error:c,mutate:()=>Promise.resolve(void 0),isValidating:!1}}function ue(e){return e?Array.isArray(e)?e:e instanceof Function?ue(e()):[e]:[e]}async function pe(e,t){const n=await fetch(e,{...t,headers:{...t?.headers,"Content-Type":"application/json"}});return await n.json()}function xe(e={}){const{data:t}=he(`/wcms-resources/${c.SITEMAP||"sitemap"}.json`,pe,{fallback:e});return t||{}}const ge=p((({className:e,isMobile:t=!1})=>{const{term:n,setTerm:i}=(()=>{const[e,t]=r("");return{term:e,setTerm:e=>t(e)}})(),l=t?"text-s":"text-l-light",a=t?" placeholder-transparent":"h-full",s=t?"some search":void 0;return u("form",{className:`font-sans relative ${e}`,children:[u("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:[h("div",{className:t?"w-5 h-5":"w-6 h-6",children:h(B,{image:"LoupeIcon",width:"24",height:"24"})}),n?null:h("label",{htmlFor:"search-bar-input",className:`text-secondary-text ${l}`,children:"Поиск по сайту"})]}),h("input",{id:"search-bar-input",className:`h-12 pl-12 w-full peer text-l text-black border border-solid rounded-md box-border\n outline-none pr-[6%] border-main-stroke hover:border-primary-hover active:border-primary-text focus:border-primary-text ${a}`,value:n,onChange:e=>i(e.target.value),type:"text",name:"search-bar-input",placeholder:s}),t?h("button",{className:"visible peer-placeholder-shown:invisible absolute top-2 right-3 w-6 h-6 p-1 bg-transparent cursor-pointer border-none",onClick:e=>{e.preventDefault(),i("")},children:h(B,{image:"CloseIcon",width:"24",height:"24"})}):h(te,{version:"primary",text:"Найти",className:"invisible peer-focus:visible absolute top-[3px] right-1",onClick:e=>{e?.preventDefault(),console.log("click")},children:h("div",{className:"text-s px-9 py-2.5",children:"Найти"})})]})})),be=p((({className:e=""})=>h(ge,{className:e,isMobile:!0}))),fe=p((({className:e="",documents:t,...n})=>h(N,{className:`font-sans bg-white mt-[10px] ${e}`,...n,children:h("ul",{className:"flex flex-col text-s text-secondary-text p-0",children:t?.length?Ne(t):null})}))),Ne=e=>e.map(((e,t)=>{const{text:n,...r}=e;return h("li",{className:"mb-4 list-none",children:h("a",{className:"hover:text-primary-main",role:"link",...r,children:n||null})},`list_item_${String(t)}`)})),ye={"bg-white":"color",transparent:"white"},ve={"bg-white":"text-primary-main",transparent:"text-white"},we={"bg-white":"text-black",transparent:"text-white"},ke=p((({className:e="",href:t,children:n,targetBlank:r,bgColor:i="bg-white",showTitle:l=!0})=>u("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"https://rshb.ru/",target:r?"_blank":"_self","aria-label":"Россельхозбанк",children:[h(B,{image:{icon:"LogoIcon",iconVersion:ye[i]},className:`${ve[i]}`,width:"34",height:"34",asSVG:!0}),l?h("span",{className:`${we[i]} text-s font-medium ml-2.5`,children:n||"Россельхозбанк"}):null]}))),$e=p((({className:e="",title:t="Мобильное приложение",description:n,href:r="#"})=>h("div",{className:`col-span-12 rounded-md cursor-pointer p-4 mt-6 mb-6 bg-secondary-light font-sans ${e}`,children:r?u("div",{className:"flex",children:[h("div",{className:"flex justify-center align-middle rounded-md bg-primary-main w-[50px] h-[50px]",children:h(ke,{className:"w-8",bgColor:"transparent",showTitle:!0})}),u("a",{href:r,target:"_blank",className:"flex flex-col justify-center pl-3",children:[h("div",{className:"text-s font-medium mb-[3px]",children:t}),h("div",{className:"text-s text-secondary-text",children:n})]})]}):null}))),Ce=e=>e?.includes("//"),Se=e=>(e||"").replace(/\/?\?.*/,""),Te=e=>{if(!e||!Ce(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t};var _e=Object.freeze({__proto__:null,isURL:Ce,withoutQuery:Se,getOrigin:Te,getHash:e=>{if(!e||!Ce(e))return;const t=e.indexOf("#");return-1!==t?e.substring(t,e.length):void 0},isHash:e=>e?.startsWith("#")});const De="/mobile",Ie=(e,t)=>{if(!e)return e;const n=Te(t?.href);return n?e.replace(n,"")||"/":e},je=e=>e;function Re({router:e,handlerDecorator:t=je},n){const r=((e,t)=>{if(!e)return e;const n=Ie(e,t)||"",r=t?.pathname.startsWith(De);return r&&!Ce(n)?`/mobile${n}`:n})(n.href,e);return{...n,href:r,"aria-label":n.text,onClick:t((t=>{const i=r&&!Ce(r),l=!n.target||"_self"===n.target;i&&l&&(t?.preventDefault(),e.push(r))}),n)}}const Ae=p((({className:e="",items:t,hasButton:n,context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return u("div",{className:e,children:[t?.length?t.map(Le):null,n?h(te,{version:"primary",className:"mb-6 w-full",...Re({router:i,handlerDecorator:l},{text:"Обратная связь",href:"/",target:"_blank"}),ariaLabel:"Обратная связь"}):null]})})),Le=(e,t)=>{const{type:n,text:r,description:i}=e;return u("div",{className:"mb-4",children:[h("div",{children:Me(n,r)}),h("div",{className:"mt-1 text-s-light text-secondary-text",children:i})]},String(t))},Me=(e,t="")=>{switch(e){case"tel":return h("a",{className:"text-h6 text-primary-text hover:text-primary-main no-underline",href:`tel:${Oe(t)}`,children:t});case"email":return h("a",{className:"text-xl-light text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return h("span",{children:t})}},Oe=e=>e.replaceAll(/\D/g,""),Be=p((({className:e="",index:t,text:n,href:r,target:i,onClick:l})=>h("a",{className:`text-secondary-text hover:text-primary-main inline-block no-underline ${e}`,href:r,target:i,onClick:l,children:n||`Документ ${t}`}))),Ve=p((({title:e,links:t,className:n="",context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return u("div",{className:n,children:[h("span",{className:"text-primary-text text-s font-medium",children:e}),t?.length?h("div",{className:"flex flex-col gap-2 pt-3",children:t.map(((e,t)=>h(Be,{index:t,className:"text-s",...Re({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),Pe=[{origins:["t.me","telegram.org"],icon:{icon:"TelegramIcon"},label:"Телеграм"},{origins:["vk.com"],icon:{icon:"VKIcon"},label:"ВКонтакте"},{origins:["ok.ru"],icon:{icon:"OkIcon"},label:"Одноклассники"},{origins:["apps.apple.com"],icon:{icon:"AppleIcon"},label:"App Store"},{origins:["play.google.com"],icon:{icon:"PlayMarketIcon"},label:"Google Play"}],Fe=p((({href:e,version:t="primary"})=>{const{icon:n,label:r}=Pe.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};if(!n)return null;return h("a",{className:`flex items-center justify-center rounded-md w-14 h-14 group box-border ${"secondary"===t?"bg-white hover:bg-secondary-hover":"border-solid border-[1px] border-main-divider hover:border-transparent hover:bg-primary-main"} ${"primary"===t?"hover:text-black":""}`,href:e,"aria-label":r,target:"_blank",rel:"noopener noreferrer",children:n?h(B,{image:V(n),imageClassName:"group-hover:text-white",width:"24",height:"24",asSVG:!0}):null})})),Ee=p((({className:e,media:t,version:n,context:r})=>{const i=r.useRouter(),{handlerDecorator:l}=r;return h("div",{className:`flex gap-2 items-start justify-start pt-6 pb-6 ${e||""}`,children:t?.map(((e,t)=>h(Fe,{version:n,...Re({router:i,handlerDecorator:l},e)},String(t))))})})),ze=p((({className:e="",index:t,text:n,href:r,target:i,onClick:l})=>h("a",{className:`text-xs-light text-secondary-text visited:text-secondary-text hover:text-primary-main inline-block no-underline max-w-[292px] ${e}`,href:r,target:i,onClick:l,children:n||`Документ ${t}`}))),Ge=p((({className:e,links:t,context:n})=>{const r=n.useRouter(),{handlerDecorator:i}=n;return u("div",{className:`${e||""}`,children:[h("div",{className:"py-6",children:h("span",{className:"text-xs-light text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?h("div",{className:"flex flex-col justify-start items-start gap-2",children:t.map(((e,t)=>h(ze,{index:t,className:"",...Re({router:r,handlerDecorator:i},e)},String(t))))}):null]})})),He=p((({className:e="",documents:t,relatedEnterprises:n,contacts:r,socialMedia:i,context:l,horizontalNavigationTitle:a,page:s})=>{const o=s?.fallback,c=xe(o),d=c?.dispositions;return u("footer",{className:`font-sans px-4 py-[26px] bg-white ${e}`,children:[h(Ae,{className:"overflow-hidden",items:r,context:l,hasButton:!0}),h(w,{children:c.topItems?.map(((e,t)=>h(F,{context:l,label:e.text,children:h(fe,{context:l,documents:e.items})},String(t))))}),h("div",{children:d?.map(We)}),h($e,{context:l,title:"Мобильное приложение",description:"Загрузить для IOS и Android"}),h(be,{context:l,className:"grow"}),h(Ee,{className:"pb-4",media:i,context:l}),h(Ve,{title:a,links:n,context:l}),h(Ge,{links:t,context:l})]})})),We=(e,t)=>{const{icon:n,href:r,text:i}=e;return u(te,{version:"link",href:r,className:"flex text-s mb-4 w-6",children:[n?h(B,{className:"pr-1",image:V({icon:n}),width:"24",height:"24",asSVG:!0}):null,h("span",{className:"pl-2.5 font-medium text-primary-text",children:i})]},`footer-${t}`)},Je={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},Ue=p((({context:e,title:t,description:n,cards:r=[],className:i,orientation:l="horizontal"})=>u("section",{className:`relative font-sans text-primary-text bg-white px-4 py-6 overflow-hidden ${i}`,children:[u("div",{className:"flex flex-col items-center mb-5",children:[t?h(v,{headingType:"h3",className:`text-center ${n?"mb-2":"mb-5"}`,title:t}):null,n?h("div",{className:"text-m max-w-[600px] text-center mb-5",children:n}):null]}),Ye(l,r,e)]})));function Ye(e,t,n){return"horizontal"===e?h(U,{context:n,children:t?.map(Ke)}):h("div",{className:"grid gap-[14px]",children:t?.map(Ke)})}function Ke(e,t){return u("div",{className:`h-full justify-between box-border horizontal-list-item border-solid border rounded-md border-main-stroke p-4 flex flex-col\n ${Je[e.version??"primary"]}`,children:[u("div",{children:[Xe(e.icon),e.title?h("h3",{className:"text-m-title-xs font-medium m-0",children:e.title}):null,e.description?Qe(e):null,e.items?.length?qe(e.items,e.isDotted,e.version):null]}),e?.button?.text?(n=e.button,h(te,{className:"mt-3",...n})):null]},t);var n}const Xe=e=>e?.src||e?.icon?h("div",{className:"flex justify-center",children:h(B,{className:"mb-3.5",image:e})}):null;function Qe(e){return h("div",{className:"text-secondary-text mt-1 text-s "+("secondary"===e.version?"text-white opacity-80":""),children:e.description})}const Ze={primary:"bg-primary-text",secondary:"bg-white",gray:"bg-secondary-text"};function qe(e,t,n="primary"){return h("section",{className:"mt-3",children:e.map(((e,r)=>u("div",{children:[t?h("div",{className:`rounded-full inline-block mr-3 mt-2 w-2 h-2 min-w-2 min-h-2 ${Ze[n]}`}):null,h("span",{className:"text-m font-medium",children:e.title}),h("span",{className:"text-s pl-2 "+("primary"===n?"text-secondary-text":""),children:e.text})]},String(r))))})}const et=(e,t,n=((e,t)=>t.startsWith(e)))=>n(Se(e),(e=>(e||"").replace(De,""))(Se(Ce(e)?t.href:t.pathname))),tt=e=>t=>et(t.href,e),nt=e=>t=>t.items?.some(tt(e))||et(t.href,e)||((e,t)=>Te(e)===Te(t.href))(t.href,e),rt="absolute left-0 -bottom-3 w-full h-[2px]",it=p((({className:e="",text:t,href:n,target:r,active:i,onClick:l,children:a,bgColor:s="bg-white"})=>u("a",{className:`relative inline-block bg-transparent text-center no-underline ${e}`,href:n,target:r,onClick:l,children:[h("span",{className:lt(s,i),children:t||a}),i?h("div",{className:at(s,i)}):null]}))),lt=(e,t=!1)=>{let n="text-white";return"bg-white"===e&&(n=t?"text-primary-main":"text-secondary-text hover:text-primary-main"),`${n} font-sans text-s`},at=(e,t=!1)=>t?`${"bg-white"===e?"bg-primary-main":e} ${rt}`:rt,st=o("https://10.80.4.9");const ot=p((({context:e,burgerSubMenu:t,onClick:n,defaultLocation:a="",children:s})=>{const[o,c]=function(e){const[t,n]=r(e);return i((()=>{n(globalThis?.localStorage.getItem("location")||e)}),[e]),[t,l((()=>{st.getFetcherAddress().then((t=>{const r=t||e;globalThis?.localStorage.setItem("location",r),n(r)}))}),[e])]}(a);return u("div",{className:"absolute top-0 left-0 w-full h-full bg-white p-4 box-border z-20",children:[h("button",{className:"absolute top-4 right-4 border-none bg-transparent cursor-pointer",onClick:n,children:h(B,{image:"CloseIcon",width:"24",height:"24",asSVG:!0})}),u("button",{onClick:c,className:"flex items-center text-s text-secondary-text p-0 mb-4 bg-transparent cursor-pointer",children:[h(B,{image:"GeolocationIcon",width:"20",height:"20",className:"text-primary-main box-border mr-2",asSVG:!0}),o]}),s,h("div",{className:"mb-7",children:t?.map(ct)}),h(be,{context:e,className:"grow"})]})})),ct=(e,t)=>{const{icon:n,href:r,text:i}=e;return u("a",{href:r,className:"flex text-s mb-4 hover:text-primary-main",children:[n?h(B,{className:"text-primary-main pr-1",image:n,width:"24",height:"24",asSVG:!0}):null,h("span",{className:"font-medium pl-0.5",children:i})]},`headerSubMenu-${t}`)},dt=p((({onClick:e,bgColor:t})=>u("div",{className:"flex items-center justify-between border-0 border-b border-main-divider h-[50px]",children:[u("div",{className:"flex items-center",children:[h("button",{className:"pl-0 pr-4 border-0 bg-transparent cursor-pointer",onClick:e,"aria-label":"Открыть меню",children:h(B,{image:{icon:"BurgerIcon",iconVersion:"bg-white"===t?"black":"white"},className:"text-primary-text w-6 h-6",width:"24",height:"24",asSVG:!0})}),h(ke,{className:"mr-8",bgColor:t})]}),h("button",{className:("bg-white"===t?"text-primary-main":"text-white")+" text-s border-0 bg-transparent cursor-pointer",children:"Войти"})]}))),mt=p((({className:e="",defaultLocation:t,bgColor:n="bg-white",context:i,page:l})=>{const{handlerDecorator:a}=i,s=i.useRouter(),o=l?.fallback,{topItems:c,dispositions:d}=xe(o),m=c?.find(nt(s)),p=m?.items,x=(e=>(t=[])=>{const n=t?.filter(tt(e));return n?.length?(r=e=>e.href?.length||0,e=>e.reduceRight(((e,t)=>r(e)>r(t)?e:t)))(n):void 0;var r})(s)(p),[g,b]=r(!1),f=()=>b(!g);return u("header",{className:`${n} ${e}`,children:[u("div",{className:"container px-4 py-0 box-border",children:[h(dt,{onClick:f,bgColor:n}),h("nav",{className:"flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]",children:h("div",{className:"flex no-scrollbar horizontal-list h-full items-center",children:p?.map(((e,t)=>ht({...Re({router:s,handlerDecorator:a},e),active:e===x,bgColor:n},t)))})})]}),g?h(ot,{context:i,onClick:f,burgerSubMenu:d,defaultLocation:t,children:h(w,{children:c?.map(((e,t)=>{e?.text&&h(F,{context:i,label:e.text,children:h(fe,{context:i,documents:e.items})},String(t))}))})}):null]})})),ht=(e,t)=>h(it,{className:"mr-8 whitespace-nowrap text-s",...e},String(t)),ut={left:"text-left",center:"text-center",right:"text-right"},pt={transparent:{background:"bg-transparent",text:"text-primary-text",description:"text-primary-text"},primary:{background:"bg-white",text:"text-primary-text",description:"text-primary-text"},secondary:{background:"bg-primary-main",text:"text-white",description:"text-white/80"}},xt=p((({bgColorHeadline:e="transparent",className:t="",title:n,description:r,image:i,align:l="left"})=>{const a=pt[e];return u("section",{className:`px-4 py-6 flex flex-col gap-2.5 ${a.background} ${t}`,children:[n?h(v,{headingType:"h2",className:`${a.text} ${ut[l]}`,title:n}):null,r?h("p",{className:`text-m ${a.description} ${ut[l]}`,children:r}):null,i?.src&&h("div",{className:"mt-2.5 mx-auto flex justify-center",children:h(B,{image:i})})]})})),gt=p((({className:e,iconClassName:t,textClassName:n,suffixClassName:r,doc:i,icon:l})=>{const{text:a,fileSize:s,...o}=i;return u("a",{className:e,role:"link",...o,children:[l?h(B,{className:t,image:V(l),width:"24px",height:"24px",asSVG:!0}):null,a?u("span",{className:n,children:[a,h("span",{className:r,children:o?.href&&bt(ft(o.href),s)})]}):null]})})),bt=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),ft=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},Nt=p((({className:e="",doc:t,icon:n})=>h(gt,{className:`flex h-full box-border ${e}`,iconClassName:"mr-3 min-w-6 min-h-6",doc:t,icon:n}))),yt=p((({context:e,hasBorder:t=!0,documents:n,icon:r})=>h(U,{context:e,className:"text-s text-primary-main mt-5",children:n?.length?n.map(((e,n)=>h(Nt,{className:t?"rounded-md border-main-stroke border border-solid p-4":"",doc:e,icon:r},String(n)))):null}))),vt=p((({hasBorder:e=!0,documents:t,icon:n})=>h("div",{className:"text-s text-primary-main flex flex-col mt-5 "+(e?"gap-3.5":"gap-2"),role:"list",children:t?.length?t.map(((t,r)=>h("div",{role:"listitem",children:h(Nt,{className:e?"rounded-md border-main-stroke border border-solid p-4":"",doc:t,icon:n})},String(r)))):null}))),wt=p((({className:e="",context:t,title:n,description:r,icon:i={icon:"DocIconMonoColor"},documents:l,orientation:a="vertical",hasBorder:s=!0})=>u("section",{className:`font-sans text-primary-text py-6 px-4 bg-white overflow-x-hidden ${e}`,children:[h(xt,{className:"!p-0 "+(r?"gap-2":"gap-5"),title:n,description:r,context:t,align:"center"}),"vertical"===a?h(vt,{hasBorder:s,documents:l,icon:i}):h(yt,{context:t,hasBorder:s,documents:l,icon:i})]}))),kt=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12};function $t(e=""){const t=kt(e);return t<=4?"S":t<=8?"M":"L"}function Ct(e=""){const t=kt(e);return t<=6?"min-h-[300px]":t<=8?"min-h-[320px]":"min-h-[360px]"}function St(e=""){const t=kt(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const Tt=p((({className:e,context:t,title:n,description:r="Блок в разработке...",...i})=>u(N,{context:t,className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${St(e)} ${Ct(e)} `,...i,children:[h(xt,{context:t,className:"!p-0 max-w-[600px]",title:n,description:r,headlineVersion:$t(e)}),h("figure",{className:"m-0 min-w-[80%]",children:_t()})]}))),_t=(e=3)=>It(100,e).map((e=>Math.floor(e))).map(Dt),Dt=(e,t)=>h("div",{style:{width:`${e||100}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),It=(e,t)=>[e].concat(t>0?It(e/1.618,t-1):[]),jt=p((({context:e,className:t="",buttons:n})=>{const{handlerDecorator:r}=e,i=e.useRouter();return n&&n?.length?h("div",{className:t,children:n.map(((e,t)=>Rt({button:Re({router:i,handlerDecorator:r},e),index:t})))}):null}));function Rt({button:e,buttonClassName:t,index:n}){const{icon:r,iconRight:i,version:l,...a}=e,s="secondary"===l?"color":"white",o=At({...r,iconVersion:s}),c=At({...i,iconVersion:s});return h(te,{className:t,appendLeft:o,appendRight:c,version:l,...a},n?String(n):"")}const At=e=>{if(!e?.icon&&!e?.src)return null;const t=e?.size?.width?`${e.size.width}`:"24";return h(B,{image:{...e},width:t,height:"24",asSVG:!0})},Lt={primary:"bg-primary-text",secondary:"bg-white",gray:"bg-secondary-text"},Mt={L:"w-1.5 h-1.5 min-w-1.5 min-h-1.5 mr-4",M:"w-1.5 h-1.5 min-w-1.5 min-h-1.5 mr-3",S:"w-1 h-1 min-w-1 min-h-1 mr-2"},Ot=p((({className:e="",isDotted:t=!0,children:n,version:r="primary",size:i="M"})=>u("div",{className:`font-sans flex items-baseline ${e}`,role:"listitem",children:[t?h("div",{children:h("div",{className:`rounded-full align-middle inline-block ${Lt[r]} ${Mt[i]}`})}):null,h("span",{children:n})]}))),Bt={primary:"text-primary-text",secondary:"text-white",gray:"text-secondary-text"},Vt={S:"text-l-light",M:"text-h6",L:"text-h5"},Pt={S:"ml-2",M:"ml-3",L:"ml-4"},Ft=p((e=>{const{className:t="",hasIndent:n,isDotted:r,itemClassName:i="",items:l,listItemSize:a="M",version:s="primary"}=e;return l?.length?h("section",{className:`${Bt[s]} ${Vt[a]} ${t} ${n?Pt[a]:""}`,role:"list",children:l.map(((e,t)=>h(Ot,{className:`${i} mb-1.5`,isDotted:r,version:s,size:a,children:e},String(t))))}):null})),Et=p((({className:e="",title:t="",children:n,buttons:r,image:i})=>u("div",{className:`font-sans flex flex-col grow h-full items-start ${e}`,children:[t,u("div",{className:"flex grow w-full justify-between",children:[u("div",{className:"flex flex-col justify-between w-full",children:[h("div",{className:"h-full",children:n}),r?h("div",{className:"mt-auto pt-8",children:r}):null]}),i]})]}))),zt={primary:"text-primary-text",secondary:"text-white"},Gt={primary:"text-secondary-text",secondary:"text-white"},Ht=p((e=>{const{className:t="",icon:n,label:r,description:i,version:l="primary",benefitsVersion:a="normal"}=e,s="white"===a?"secondary":"primary";return u("div",{className:`flex gap-5 ${i?"items-start":"items-center"} ${t}`,children:[n?h("div",{className:Wt(l,a),children:h(B,{className:"w-6 h-6",image:V(n,s),asSVG:!0})}):null,u("div",{className:"gap-0.5",children:[r?h("div",{className:`text-h6 ${zt[l]}`,children:r}):null,i?h("div",{className:`text-m-light ${Gt[l]}`,children:i}):null]})]})}));function Wt(e,t){let n="bg-primary-main text-black";return"secondary"===e?n="bg-white/30 text-black":"normal"===t&&(n="bg-secondary-light text-primary-main"),`w-[50px] h-[50px] min-w-[50px] rounded-full p-2.5 box-border flex items-center justify-center ${n}`}const Jt=(e="primary",t="normal")=>({icon:n,label:r,description:i},l)=>h(Ht,{icon:n,label:r,description:i,version:e,benefitsVersion:t},String(l)),Ut=p((({className:e="",context:t,title:n,headlineVersion:r="L",description:i,benefits:l,benefitsVersion:a="normal",buttons:s,image:o,items:c,version:d="primary",isDotted:m=!0,label:p})=>u("div",{className:`w-full ${e}`,children:[u("div",{children:[p?Xt(p,d):null,h(xt,{context:t,className:"!p-0 max-w-[600px]",title:n,description:i,bgColorHeadline:d,headlineVersion:r}),u(Et,{context:t,buttons:s?.length?h(jt,{context:t,buttons:s,className:"flex flex-col mt-5 gap-2.5"}):null,children:[l?.filter((e=>e.label))?.length?h("div",{className:"mt-3",children:l.map(Jt(d,a))}):null,c?.length?h(Ft,{className:"mt-3 text-m",items:c,version:d,isDotted:m}):null]})]}),Yt(o)]})));function Yt(e){return e?.src?h(B,{imageClassName:"mt-5 mx-auto block",image:{className:"block",...e}}):null}const Kt={primary:"text-primary-main border-secondary-hover",secondary:"text-white/80"},Xt=(e,t)=>h("div",{className:`px-2.5 py-1.5 mb-5 rounded-md border-2 border-solid w-fit ${Kt[t]}`,children:e}),Qt=p((e=>{const{className:t="",version:n="primary"}=e;return h("section",{className:`font-sans bg-white px-4 py-6 ${Je[n]} ${t}`,children:h(Ut,{...e})})})),Zt=p((({block:e,context:t,className:n=""})=>h("section",{className:`flex grow-0 shrink-0 basis-full px-4 pt-6 ${Je[e?.version??"primary"]} ${n}`,role:"listitem",children:h("div",{className:"flex grow",children:h(Ut,{context:t,...e})})}))),qt=p((({className:e,context:t,slides:n=[]})=>{const r=n.map((e=>e.productBlock));return h("section",{className:`font-sans bg-white overflow-hidden w-100 pb-6 ${e||""}`,children:h(U,{context:t,children:r.map(((e,n)=>h(Zt,{block:e,context:t},String(n))))})})})),en={primary:{background:"bg-white",title:"text-primary-text",description:"!text-secondary-text text-l-light",iconText:"text-secondary-text",iconBackground:"bg-main-divider",iconConnector:"bg-secondary-light",dot:"bg-secondary-text"},secondary:{background:"bg-primary-main",title:"text-white",description:"!text-white/80 text-l-light",iconText:"text-white",iconBackground:"bg-white/30",iconConnector:"bg-white",dot:"bg-white/80"}},tn={normal:"h-[70px] w-[70px] min-w-[70px] min-h-[70px]",small:"h-[50px] w-[50px] min-w-[50px] min-h-[50px]"},nn={normal:"min-h-[70px]",small:"min-h-[50px]"},rn=p((({className:e,title:t,description:n,showLines:r=!0,steps:i,size:l="normal",version:a="primary"})=>{const s=en[a];return u("section",{className:`box-border font-sans bg-white px-4 py-6 flex flex-col\n ${s.background} ${s.title} ${e||""}`,children:[t?h(v,{headingType:"h3",className:`text-center ${s.title}`,title:t}):null,n?h("p",{className:`text-m-light text-center ${s.description} ${t?"mt-2":""}`,children:n}):null,i?.length?h("div",{className:"box-border py-0.5 mb-0.5 mt-5",children:h("div",{className:"flex flex-col justify-between gap-x-[101px]",children:i.map(ln(l,a,r))})}):null]})})),ln=(e,t,n)=>(r,i,l)=>{const a=l.length-1===i,s="normal"===e?"ml-[34px]":"ml-6",o=en[t];return h("div",{children:u("div",{className:"flex flex-row text-center relative",children:[u("div",{className:"overflow-hidden flex-shrink-0",children:[an(e,t)(r,i),a?null:h("div",{className:`min-h-8 h-full w-[2px] ${n?o.iconConnector:""} ${s}`})]}),u("div",{className:`flex flex-col justify-center h-fit ${nn[e]}`,children:[r.label?h("div",{className:"text-m-title-xs font-medium m-0 text-left mb-1",children:r.label}):null,r.description?h("div",{className:`text-s ${o.description} text-left`,children:r.description}):null]})]})},String(i))},an=(e,t)=>(n,r)=>{const i=en[t],l="normal"===e?"38":"27",a="normal"===e?"text-m-title":"text-m-title-xs";return h("div",{className:`${tn[e]} ${i.iconBackground} rounded-full z-10 mr-3 flex justify-center content-center`,children:h("span",{className:`font-medium flex self-center ${i.title} ${a}`,children:(s=n?.icon,Boolean(s?.icon||s?.src)?h(B,{image:V({...n.icon},t),width:l,height:l,asSVG:!0}):h("span",{children:r+1}))})});var s},sn={Buttons:({buttons:e})=>e&&e?.length?h("div",{children:e.map((({rounded:e,icon:t,...n},r)=>Rt({button:{rounded:e,icon:t,...n},buttonClassName:`mt-3 ${r>0&&e?"ml-2.5":""} ${t?"w-12 h-12":""}`,index:r})))}):null,Img:({image:e})=>e?.src?h(B,{image:{...e,className:"m-0"}}):null,List:({isDotted:e,...t})=>h(Ft,{className:"flex flex-col justify-between items-start text-m",version:"gray",isDotted:e??!0,...t}),LabelDescription:({label:e,description:t})=>u("div",{children:[e?h("div",{className:"text-xl font-medium m-0 "+(t?"mb-1":""),children:e}):null,t?h("div",{className:"text-s text-secondary-text",children:t}):null]})},on=p((({title:e,icon:t})=>u("div",{className:"flex gap-2.5 mb-2",children:[e?h(v,{headingType:"h3",className:"font-medium",title:e}):null,t?h(B,{className:"ml-auto max-w-6 max-h-6",image:t,width:"24px",height:"24px"}):null]}))),cn=p((({context:e,tile:t})=>u("div",{className:"rounded-md border-main-stroke h-full box-border border p-4",children:[h(on,{...t.header}),t.data?.length?t.data.map(dn(e)):null]}))),dn=e=>(t,n)=>u("div",{children:[n>0?h("div",{className:"h-5"}):null,mn(t,e)]},String(n)),mn=(e,t)=>{if(!e)return null;const{tableCellType:n,...r}=e;if(!n||!(n in sn))return null;return h(sn[n],{context:t,displayTable:()=>null,...r,isVisible:!0})},hn=p((({tiles:e,context:t})=>h(U,{context:t,children:e.map(((e,n)=>h(cn,{tile:e,context:t},String(n))))}))),un=p((({tiles:e,context:t})=>h("div",{className:"flex flex-col gap-3.5",children:e.map(((e,n)=>h(cn,{tile:e,context:t},String(n))))}))),pn=p((({className:e,context:t,title:n,description:r,tariffsColumns:i,rowHeaders:l,orientation:a="vertical"})=>{const s=gn(i),o=bn(l,s);return u("section",{className:`px-4 py-6 bg-white font-sans text-primary-text overflow-x-hidden ${e}`,children:[n?h(v,{headingType:"h2",className:`text-center ${r?"mb-2":"mb-5"}`,title:n}):null,r?h("div",{className:"mb-5 text-center text-m",children:r}):null,o?.length?xn(a,o,t):null]})}));function xn(e,t,n){return h("vertical"===e?un:hn,{context:n,tiles:t})}const gn=e=>e?.[0].data?e[0].data:[],bn=(e,t)=>e?.map(((e,n)=>({header:e,data:t?.[n]||[{}]}))),fn={primary:{background:"bg-white",icon:"bg-primary-main text-white",title:"text-primary-text",description:"text-secondary-text"},secondary:{background:"bg-primary-main",icon:"bg-white text-primary-main",title:"text-white",description:"text-white"},"secondary-light":{background:"bg-primary-main/10",icon:"bg-primary-main text-white",title:"text-primary-text",description:"text-secondary-text"}},Nn=p((({title:e,description:t,blockVersion:n="primary",iconVersion:r,image:i,className:l="",items:a,isDotted:s=!0})=>{const o=fn[n],c="secondary"===n?"secondary":"gray";return u("section",{className:`font-sans px-4 py-[18px] flex flex-col ${o.background} ${l}`,children:["small"===r?yn(o.icon):null,"big"===r?vn(i):null,u("div",{className:"py-0.5",children:[e?h("div",{className:`text-l font-medium mb-1 ${o.title}`,children:e}):null,t?h("div",{className:`text-s ${o.description}`,children:t}):null,a?.length?h(Ft,{className:"mt-1 text-m",items:a,isDotted:s,version:c}):null]})]})}));function yn(e){return h("div",{className:"mb-3",children:h("div",{className:`rounded-full h-4 w-4 text-center text-xs-light ${e}`,children:"i"})})}function vn(e){return e?.src?h(B,{className:"pb-3 mr-auto",image:e}):null}const wn={Accordion:k,AccordionItem:F,ComparisonTable:ce,Footer:He,Gallery:Ue,Header:mt,Headline:xt,LinkDocs:wt,LinkList:fe,MobileAppTile:$e,ProductBlock:Qt,ProductGallery:qt,StepsBlock:rn,TariffsTable:pn,TextBlock:Nn,Placeholder:Tt};function kn(e){return e?e.filter(Boolean).join(" "):""}const $n=m();const Cn=p((({className:e,onClick:t,ariaLabel:n})=>h("button",{type:"button",className:`border-0 w-9 bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":n,children:Sn()}))),Sn=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return u("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[h("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"}),h("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"})]})},Tn=p((({className:e,context:t,...n})=>{const{useRouter:a,handlerDecorator:s=je}=t,o=function(e){const[t,n]=r(0);return i((()=>{(async()=>{const[t]=await $n.getLikeCount(e);n(t?.value||0)})()}),[e]),{likeCount:t,like:l((async()=>{n(await $n.like(e))}),[e]),dislike:l((async()=>{n(await $n.dislike(e))}),[e])}}(a().pathname);return u(N,{tag:"div",context:t,className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e||""}`,...n,children:[h(Cn,{onClick:s(o.like),ariaLabel:"Поставить отметку «лайк»"}),h(Cn,{onClick:s(o.dislike),className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),h("span",{className:"select-none",children:o.likeCount})]})}));function _n({slots:e={},parent:t,options:n,ancestors:r=[]}){return Object.entries(e).reduce(((e,[i,l])=>({...e,[i]:In({blocks:l,parent:t,slotName:i,options:n,ancestors:r})})),{})}const Dn=e=>e;function In({blocks:e=[],parent:t,slotName:n=null,options:r,ancestors:i=[]}){const{blocksRegistry:l={}}=r,{type:a}=t,s=a&&l[a],{renderChild:o=Dn}=s||{};return e.map(((e,l)=>o(function({block:e={},options:t,ancestors:n=[]}){const{key:r,page:i,blockDecorator:l,blocksRegistry:a={},context:s}=t,{type:o,slots:c,blocks:d}=e;o&&o in a||console.warn(`No block with "${o}" is registered`);const m=o&&a[o],u={parent:e,options:t,ancestors:n},p=In({...u,blocks:d}),x=c?_n({...u,slots:c}):{};return l({blockClassName:`scroll-mt-12 ${kn(e.style)}`,block:e,ancestors:n,render:({block:e,blockClassName:t})=>{const{version:l,anchor:a,labels:o,content:c}=e;return m?h(m,{className:t,context:s,page:i,ancestors:n,version:l,anchor:a,labels:o,slots:x,...c,children:p},r):null}},r)}({block:e,options:{...r,key:`${r.key?r.key:e.type}-${l}`},ancestors:[...i,[t,n]]}),l)))}const jn=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),Rn=p((e=>{const{className:t="",blocksRegistry:n,blockDecorator:r,context:i,data:l={}}=e,{style:a,blocks:s,slots:o,likeControl:c,colorPalette:d="pc"}=l,m={key:"",blocksRegistry:n,page:l,blockDecorator:r||jn,context:i},p=_n({slots:o,parent:l,options:m});return u("section",{className:`relative ${kn(a)} ${t}`,"data-theme":d,children:[p?.header?h("div",{className:"mb-5 shadow-[0_8px_32px_0px_#00000014]",children:p.header}):null,s?.length?u("div",{className:"container grid grid-cols-12 gap-1",children:[In({blocks:s,parent:l,options:m}),p?.footer?p.footer:null]}):null,c?An(i):null]})}));function An(e){return h("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:h(Tn,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:e},"LikeControl")})}Rn.childrenTypes=[],Rn.slots=()=>["header","footer"];e.Blocks=wn,e.ContentPage=Rn,e.DaDataAPI=o,e.LikeAPI=m,e.joinList=function(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])},e.packageVersion="0.6.26",e.projectSettings=c,e.setup=(e,t)=>{globalThis._uni={_jsx:e,_jsxs:t||e}},e.setupHooks=e=>{t=e},e.url=_e,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
2
2
|
import type { BenefitsBlockContent } from './BenefitsBlockContent';
|
|
3
|
-
|
|
3
|
+
interface BenefitsBlockProps extends BenefitsBlockContent, UniBlockProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const BenefitsBlock: import("@redneckz/uni-jsx").UNIComponent<BenefitsBlockProps, any, any>;
|
|
6
|
+
export {};
|
|
@@ -2,6 +2,7 @@ import type { HeadlineCommonProps } from '../../model/HeadlineType';
|
|
|
2
2
|
import type { ProductColorVersion } from '../../model/ProductColorVersion';
|
|
3
3
|
import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
|
|
4
4
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
5
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
5
6
|
export interface CatalogCardType extends HeadlineCommonProps, ImageContent {
|
|
6
7
|
/** @title Цена в рублях */
|
|
7
8
|
price?: number;
|
|
@@ -22,4 +23,5 @@ export interface CatalogCardType extends HeadlineCommonProps, ImageContent {
|
|
|
22
23
|
export declare type CatalogContent = HeadlineCommonProps & {
|
|
23
24
|
/** @title Список карточек */
|
|
24
25
|
cards?: CatalogCardType[];
|
|
26
|
+
version?: BlockVersion;
|
|
25
27
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BlocksRegistry } from '../../model/BlocksRegistry';
|
|
2
2
|
import type { Fallback, FallbackMap } from '../../model/Fallback';
|
|
3
|
-
export declare const computeAPIFallback: (blocksRegistry: BlocksRegistry) =>
|
|
3
|
+
export declare const computeAPIFallback: (blocksRegistry: BlocksRegistry) => Promise<Fallback>;
|
|
4
4
|
export declare function loadBlockFallback(blockName: string): Promise<FallbackMap | undefined>;
|
|
5
5
|
export declare function getPageFallbackMap(blocksFallbackMap: Array<FallbackMap | undefined>): FallbackMap;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { BlocksRegistry } from '../../model/BlocksRegistry';
|
|
2
2
|
import type { ContentPageDef } from '../../model/ContentPageDef';
|
|
3
|
-
export declare const normalizePage: (blocksRegistry: BlocksRegistry) => (contentPage: ContentPageDef | undefined | null) => ContentPageDef
|
|
3
|
+
export declare const normalizePage: (blocksRegistry: BlocksRegistry) => (contentPage: ContentPageDef | undefined | null) => ContentPageDef;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type { BgColorVersion } from '../../model/BgColorVersion';
|
|
2
2
|
import type { LinkProps } from '../../model/LinkProps';
|
|
3
3
|
import type { IconProps, Picture } from '../../model/Picture';
|
|
4
|
-
import type { SitemapProps } from '../../services/sitemap/SitemapProps';
|
|
5
4
|
/**
|
|
6
5
|
* @title Пункт подменю
|
|
7
6
|
*/
|
|
@@ -27,7 +26,7 @@ export interface Logo {
|
|
|
27
26
|
* @title Шапка (для мобильных горизонтальная прокрутка shift+mouseScroll)
|
|
28
27
|
* @required ["defaultLocation", "topItems"]
|
|
29
28
|
*/
|
|
30
|
-
export interface HeaderContent
|
|
29
|
+
export interface HeaderContent {
|
|
31
30
|
logo?: Logo;
|
|
32
31
|
/**
|
|
33
32
|
* @title Город по-умолчанию
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
2
|
+
import type { InvestmentGalleryContent } from './InvestmentGalleryContent';
|
|
3
|
+
export interface InvestmentGalleryProps extends InvestmentGalleryContent, UniBlockProps {
|
|
4
|
+
}
|
|
5
|
+
export declare const InvestmentGallery: import("@redneckz/uni-jsx").UNIComponent<InvestmentGalleryProps, any, any>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
|
+
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
3
|
+
import type { InvestmentGalleryCardTypes } from './InvestmentGalleryContent';
|
|
4
|
+
export interface RecommendationCardProps extends InvestmentGalleryCardTypes, UniBlockProps {
|
|
5
|
+
version?: BlockVersion;
|
|
6
|
+
}
|
|
7
|
+
export declare const InvestmentGalleryCard: import("@redneckz/uni-jsx").UNIComponent<RecommendationCardProps, any, any>;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
|
+
import type { Picture } from '../../model/Picture';
|
|
3
|
+
import type { HeadlineCommonProps, TitleProps } from '../../model/HeadlineType';
|
|
4
|
+
/**
|
|
5
|
+
* @title Количество колонок в списке
|
|
6
|
+
* @enumNames [
|
|
7
|
+
* "1 колонка",
|
|
8
|
+
* "2 колонки",
|
|
9
|
+
* ]
|
|
10
|
+
*/
|
|
11
|
+
export declare type CardColumnsMode = 'single' | 'double';
|
|
12
|
+
/**
|
|
13
|
+
* @title Карточка
|
|
14
|
+
*/
|
|
15
|
+
export interface InvestmentGalleryCardTypes extends HeadlineCommonProps {
|
|
16
|
+
/** @title Доп. описание карточки */
|
|
17
|
+
additionalDescription?: string;
|
|
18
|
+
/**
|
|
19
|
+
* @default {
|
|
20
|
+
* "format": "webp",
|
|
21
|
+
* "size": {
|
|
22
|
+
* "width": 290
|
|
23
|
+
* },
|
|
24
|
+
* "sources": [{
|
|
25
|
+
* "media": 1279,
|
|
26
|
+
* "width": 174,
|
|
27
|
+
* "format": "webp",
|
|
28
|
+
* "alignment": "southeast"
|
|
29
|
+
* }]
|
|
30
|
+
* }
|
|
31
|
+
*/
|
|
32
|
+
image?: Picture;
|
|
33
|
+
columnsMode?: CardColumnsMode;
|
|
34
|
+
/** @title Описание пункта */
|
|
35
|
+
cardList?: CardListItem[];
|
|
36
|
+
}
|
|
37
|
+
export interface CardListItem {
|
|
38
|
+
/** @title Параметр */
|
|
39
|
+
parameter?: string;
|
|
40
|
+
/** @title Описание */
|
|
41
|
+
parameterDesccription?: string;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* @title Карточка
|
|
45
|
+
*/
|
|
46
|
+
export interface InvestmentGalleryContent extends TitleProps {
|
|
47
|
+
/** @title Карточки */
|
|
48
|
+
cards?: InvestmentGalleryCardTypes[];
|
|
49
|
+
version?: BlockVersion;
|
|
50
|
+
}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import type { ContentPageDef } from '../model/ContentPageDef';
|
|
2
2
|
import type { TransformationOptions } from './TransformationOptions';
|
|
3
|
-
export declare
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
3
|
+
export declare class ContentPageRepository {
|
|
4
|
+
private readonly options;
|
|
5
|
+
static readonly inst: ContentPageRepository;
|
|
6
|
+
private cache;
|
|
7
|
+
constructor(options?: TransformationOptions);
|
|
8
|
+
listAllContentPages(): Promise<string[]>;
|
|
9
|
+
getAllContentPages(): Promise<ContentPageDef[]>;
|
|
10
|
+
getSecondaryContentPages(customPageType?: string): Promise<ContentPageDef[]>;
|
|
11
|
+
getContentPageBySlug(slug: string): Promise<ContentPageDef | undefined>;
|
|
12
|
+
getIndexPage(): Promise<ContentPageDef | undefined>;
|
|
13
|
+
readPage(filePath: string): Promise<ContentPageDef>;
|
|
14
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { HeaderContent } from '../../components/Header/HeaderContent';
|
|
2
1
|
import type { Fallback } from '../../model/Fallback';
|
|
3
|
-
|
|
2
|
+
import type { SitemapProps } from './SitemapProps';
|
|
3
|
+
export declare function useSitemap(fallback?: Fallback): SitemapProps;
|
|
File without changes
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { UniBlockProps } from '../../model/JSXBlock';
|
|
2
2
|
import type { BenefitsBlockContent } from './BenefitsBlockContent';
|
|
3
|
-
|
|
3
|
+
interface BenefitsBlockProps extends BenefitsBlockContent, UniBlockProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const BenefitsBlock: import("@redneckz/uni-jsx").UNIComponent<BenefitsBlockProps, any, any>;
|
|
6
|
+
export {};
|
|
@@ -2,14 +2,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
2
2
|
exports.BenefitsBlock = void 0;
|
|
3
3
|
const jsx_runtime_1 = require("@redneckz/uni-jsx/jsx-runtime");
|
|
4
4
|
const uni_jsx_1 = require("@redneckz/uni-jsx");
|
|
5
|
+
const BlockVersion_1 = require("../../model/BlockVersion");
|
|
5
6
|
const BlockWrapper_1 = require("../../ui-kit/BlockWrapper");
|
|
6
7
|
const Heading_1 = require("../../ui-kit/Heading/Heading");
|
|
7
8
|
const Img_1 = require("../../ui-kit/Img/Img");
|
|
8
9
|
const getIconWithVersion_1 = require("../../utils/getIconWithVersion");
|
|
9
|
-
const benefitsBlockStyleMap = {
|
|
10
|
-
primary: 'bg-white',
|
|
11
|
-
secondary: 'bg-primary-main',
|
|
12
|
-
};
|
|
13
10
|
const benefitsTextStyleMap = {
|
|
14
11
|
primary: '',
|
|
15
12
|
secondary: 'text-white',
|
|
@@ -22,19 +19,18 @@ const benefitsIconStyleMap = {
|
|
|
22
19
|
primary: 'bg-main-divider text-primary-main',
|
|
23
20
|
secondary: 'bg-white/30 text-black',
|
|
24
21
|
};
|
|
25
|
-
exports.BenefitsBlock = (0, uni_jsx_1.JSX)(({ className = '', title, benefitList, version = 'primary', ...rest }) => ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: `font-sans text-primary-text p-12 flex flex-col items-center ${className} ${
|
|
26
|
-
const renderBenefits = (benefitList, version) => ((0, jsx_runtime_1.jsx)("div", { className: "flex flex-wrap w-full justify-center gap-x-20 mt-8", children: benefitList.map(renderStep(version)) }));
|
|
22
|
+
exports.BenefitsBlock = (0, uni_jsx_1.JSX)(({ className = '', title, benefitList, version = 'primary', ...rest }) => ((0, jsx_runtime_1.jsxs)(BlockWrapper_1.BlockWrapper, { className: `font-sans text-primary-text p-12 flex flex-col items-center ${className} ${BlockVersion_1.VersionStyleMap[version]}`, ...rest, children: [title ? ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: "h3", as: "h2", className: `max-w-[47rem] text-center ${benefitsTextStyleMap[version]}`, title: title })) : null, benefitList?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "flex flex-wrap w-full justify-center gap-x-20 mt-8", children: benefitList.map(renderStep(version)) })) : null] })));
|
|
27
23
|
const renderStep = (version) => (benefit, i) => {
|
|
28
|
-
const description =
|
|
24
|
+
const description = benefit.description;
|
|
29
25
|
return ((0, jsx_runtime_1.jsxs)("div", { className: "flex items-center basis-1/2 max-w-[500px] mb-14", children: [benefit?.icon?.icon ? ((0, jsx_runtime_1.jsx)(Img_1.Img, { className: `w-[50px] h-[50px] min-w-[50px] p-3 rounded-full ${benefitsIconStyleMap[version]}`, image: (0, getIconWithVersion_1.getIconWithVersion)(benefit.icon, version), asSVG: true })) : null, benefit?.icon?.src ? (0, jsx_runtime_1.jsx)(Img_1.Img, { image: benefit.icon }) : null, (0, jsx_runtime_1.jsxs)("div", { className: "ml-5", children: [benefit?.label ? ((0, jsx_runtime_1.jsx)("h3", { className: `text-h6 m-0 ${benefitsTextStyleMap[version]}`, children: benefit.label })) : null, renderDescription(description, version)] })] }, String(i)));
|
|
30
26
|
};
|
|
31
27
|
const renderDescription = (description, version) => {
|
|
32
|
-
const benefitType = description
|
|
28
|
+
const benefitType = description?.benefitType || null;
|
|
33
29
|
return description && benefitType ? ((0, jsx_runtime_1.jsx)("div", { className: `text-l-light mt-2 ${benefitsDescriptionStyleMap[version]}`, children: benefitType === 'list'
|
|
34
30
|
? renderListBenefit(description)
|
|
35
31
|
: renderTextBenefit(description) })) : null;
|
|
36
32
|
};
|
|
37
|
-
const renderTextBenefit = (description) =>
|
|
33
|
+
const renderTextBenefit = (description) => description?.name || null;
|
|
38
34
|
const renderListBenefit = (description) => {
|
|
39
35
|
const listStyleType = description?.bullets ? 'list-disc pl-6' : '';
|
|
40
36
|
return description?.items && description.items.length > 0 ? ((0, jsx_runtime_1.jsx)("ul", { className: listStyleType, children: description.items.map((_, i) => ((0, jsx_runtime_1.jsx)("li", { children: _ }, `benefitListItem-${i}`))) })) : null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BenefitsBlock.js","sourceRoot":"","sources":["../../../src/components/BenefitsBlock/BenefitsBlock.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;
|
|
1
|
+
{"version":3,"file":"BenefitsBlock.js","sourceRoot":"","sources":["../../../src/components/BenefitsBlock/BenefitsBlock.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,2DAAyE;AAEzE,4DAAyD;AACzD,0DAAuD;AACvD,8CAA2C;AAC3C,uEAAoE;AAIpE,MAAM,oBAAoB,GAAG;IAC3B,OAAO,EAAE,EAAE;IACX,SAAS,EAAE,YAAY;CACxB,CAAC;AAEF,MAAM,2BAA2B,GAAG;IAClC,OAAO,EAAE,qBAAqB;IAC9B,SAAS,EAAE,uBAAuB;CACnC,CAAC;AAEF,MAAM,oBAAoB,GAAG;IAC3B,OAAO,EAAE,mCAAmC;IAC5C,SAAS,EAAE,wBAAwB;CACpC,CAAC;AAIW,QAAA,aAAa,GAAG,IAAA,aAAG,EAC9B,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,OAAO,GAAG,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CACxE,wBAAC,2BAAY,IACX,SAAS,EAAE,+DAA+D,SAAS,IAAI,8BAAe,CAAC,OAAO,CAAC,EAAE,KAC7G,IAAI,aAEP,KAAK,CAAC,CAAC,CAAC,CACP,uBAAC,iBAAO,IACN,WAAW,EAAC,IAAI,EAChB,EAAE,EAAC,IAAI,EACP,SAAS,EAAE,6BAA6B,oBAAoB,CAAC,OAAO,CAAC,EAAE,EACvE,KAAK,EAAE,KAAK,GACZ,CACH,CAAC,CAAC,CAAC,IAAI,EACP,WAAW,EAAE,MAAM,CAAC,CAAC,CAAC,CACrB,gCAAK,SAAS,EAAC,oDAAoD,YAChE,WAAW,CAAC,GAAG,CAAC,UAAU,CAAC,OAAO,CAAC,CAAC,GACjC,CACP,CAAC,CAAC,CAAC,IAAI,IACK,CAChB,CACF,CAAC;AAEF,MAAM,UAAU,GAAG,CAAC,OAAqB,EAAE,EAAE,CAAC,CAAC,OAA8B,EAAE,CAAS,EAAE,EAAE;IAC1F,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,CAAC;IAExC,OAAO,CACL,iCAAqB,SAAS,EAAC,iDAAiD,aAC7E,OAAO,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,CACrB,uBAAC,SAAG,IACF,SAAS,EAAE,mDAAmD,oBAAoB,CAAC,OAAO,CAAC,EAAE,EAC7F,KAAK,EAAE,IAAA,uCAAkB,EAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,EAChD,KAAK,SACL,CACH,CAAC,CAAC,CAAC,IAAI,EACP,OAAO,EAAE,IAAI,EAAE,GAAG,CAAC,CAAC,CAAC,uBAAC,SAAG,IAAC,KAAK,EAAE,OAAO,CAAC,IAAI,GAAI,CAAC,CAAC,CAAC,IAAI,EACzD,iCAAK,SAAS,EAAC,MAAM,aAClB,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC,CAChB,+BAAI,SAAS,EAAE,eAAe,oBAAoB,CAAC,OAAO,CAAC,EAAE,YAAG,OAAO,CAAC,KAAK,GAAM,CACpF,CAAC,CAAC,CAAC,IAAI,EACP,iBAAiB,CAAC,WAAW,EAAE,OAAO,CAAC,IACpC,KAdE,MAAM,CAAC,CAAC,CAAC,CAeb,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,iBAAiB,GAAG,CAAC,WAAuC,EAAE,OAAqB,EAAE,EAAE;IAC3F,MAAM,WAAW,GAAG,WAAW,EAAE,WAAW,IAAI,IAAI,CAAC;IAErD,OAAO,WAAW,IAAI,WAAW,CAAC,CAAC,CAAC,CAClC,gCAAK,SAAS,EAAE,qBAAqB,2BAA2B,CAAC,OAAO,CAAC,EAAE,YACxE,WAAW,KAAK,MAAM;YACrB,CAAC,CAAC,iBAAiB,CAAC,WAA6B,CAAC;YAClD,CAAC,CAAC,iBAAiB,CAAC,WAA6B,CAAC,GAChD,CACP,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC,CAAC;AAEF,MAAM,iBAAiB,GAAG,CAAC,WAA4B,EAAE,EAAE,CAAC,WAAW,EAAE,IAAI,IAAI,IAAI,CAAC;AAEtF,MAAM,iBAAiB,GAAG,CAAC,WAA4B,EAAE,EAAE;IACzD,MAAM,aAAa,GAAG,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC,gBAAgB,CAAC,CAAC,CAAC,EAAE,CAAC;IAEnE,OAAO,WAAW,EAAE,KAAK,IAAI,WAAW,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAC1D,+BAAI,SAAS,EAAE,aAAa,YACzB,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAC/B,yCAAkC,CAAC,IAA1B,mBAAmB,CAAC,EAAE,CAAU,CAC1C,CAAC,GACC,CACN,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC,CAAC"}
|
|
@@ -2,6 +2,7 @@ import type { HeadlineCommonProps } from '../../model/HeadlineType';
|
|
|
2
2
|
import type { ProductColorVersion } from '../../model/ProductColorVersion';
|
|
3
3
|
import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
|
|
4
4
|
import type { ImageContent } from '../../ui-kit/Img/ImgProps';
|
|
5
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
5
6
|
export interface CatalogCardType extends HeadlineCommonProps, ImageContent {
|
|
6
7
|
/** @title Цена в рублях */
|
|
7
8
|
price?: number;
|
|
@@ -22,4 +23,5 @@ export interface CatalogCardType extends HeadlineCommonProps, ImageContent {
|
|
|
22
23
|
export declare type CatalogContent = HeadlineCommonProps & {
|
|
23
24
|
/** @title Список карточек */
|
|
24
25
|
cards?: CatalogCardType[];
|
|
26
|
+
version?: BlockVersion;
|
|
25
27
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BlocksRegistry } from '../../model/BlocksRegistry';
|
|
2
2
|
import type { Fallback, FallbackMap } from '../../model/Fallback';
|
|
3
|
-
export declare const computeAPIFallback: (blocksRegistry: BlocksRegistry) =>
|
|
3
|
+
export declare const computeAPIFallback: (blocksRegistry: BlocksRegistry) => Promise<Fallback>;
|
|
4
4
|
export declare function loadBlockFallback(blockName: string): Promise<FallbackMap | undefined>;
|
|
5
5
|
export declare function getPageFallbackMap(blocksFallbackMap: Array<FallbackMap | undefined>): FallbackMap;
|
|
@@ -23,7 +23,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
};
|
|
24
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
25
|
exports.getPageFallbackMap = exports.loadBlockFallback = exports.computeAPIFallback = void 0;
|
|
26
|
-
const computeAPIFallback =
|
|
26
|
+
const computeAPIFallback = async (blocksRegistry) => {
|
|
27
27
|
const blocksFallbackMap = await Promise.all(Object.keys(blocksRegistry).map(loadBlockFallback));
|
|
28
28
|
const pageFallbackMap = getPageFallbackMap(blocksFallbackMap);
|
|
29
29
|
const fallbackData = await Promise.allSettled(Object.entries(pageFallbackMap).map(async ([key, fetcher]) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"computeAPIFallback.js","sourceRoot":"","sources":["../../../src/components/ContentPage/computeAPIFallback.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAQO,MAAM,kBAAkB,
|
|
1
|
+
{"version":3,"file":"computeAPIFallback.js","sourceRoot":"","sources":["../../../src/components/ContentPage/computeAPIFallback.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAQO,MAAM,kBAAkB,GAAG,KAAK,EAAE,cAA8B,EAAqB,EAAE;IAC5F,MAAM,iBAAiB,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC,CAAC;IAChG,MAAM,eAAe,GAAG,kBAAkB,CAAC,iBAAiB,CAAC,CAAC;IAC9D,MAAM,YAAY,GAAG,MAAM,OAAO,CAAC,UAAU,CAC3C,MAAM,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC,GAAG,CAAC,KAAK,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,EAAE,EAAE;QAC3D,MAAM,IAAI,GAAG,MAAM,OAAO,EAAE,CAAC;QAE7B,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC;IACvB,CAAC,CAAC,CACH,CAAC;IAEF,OAAO,YAAY;SAChB,MAAM,CAAC,CAAC,CAAC,EAA6C,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,WAAW,CAAC;SAClF,MAAM,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE;QACpB,OAAO;YACL,GAAG,GAAG;YACN,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI;SAClC,CAAC;IACJ,CAAC,EAAE,EAAE,CAAC,CAAC;AACX,CAAC,CAAC;AAnBW,QAAA,kBAAkB,sBAmB7B;AAEK,KAAK,UAAU,iBAAiB,CAAC,SAAiB;IACvD,IAAI;QACF,MAAM,aAAa,GAAG,wDAAa,MAAM,SAAS,IAAI,SAAS,WAAW,GAAC,CAAC;QAE5E,OAAO,aAAa,IAAI,aAAa,CAAC,UAAU,CAAC;YAC/C,CAAC,CAAC,MAAM,aAAa,CAAC,UAAU,CAAC,EAAE;YACnC,CAAC,CAAC,SAAS,CAAC;KACf;IAAC,OAAO,KAAK,EAAE;QACd,OAAO,SAAS,CAAC;KAClB;AACH,CAAC;AAVD,8CAUC;AAED,SAAgB,kBAAkB,CAAC,iBAAiD;IAClF,OAAO,iBAAiB;SACrB,MAAM,CAAC,CAAC,CAAC,EAAoB,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;SAC3C,MAAM,CAAC,CAAC,MAAM,EAAE,WAAW,EAAE,EAAE;QAC9B,KAAK,MAAM,CAAC,GAAG,EAAE,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,CAAC,EAAE;YACxD,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE;gBAChB,MAAM,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC;aACvB;SACF;QAED,OAAO,MAAM,CAAC;IAChB,CAAC,EAAE,EAAE,CAAC,CAAC;AACX,CAAC;AAZD,gDAYC"}
|
|
@@ -3,21 +3,17 @@ exports.normalizeBlock = void 0;
|
|
|
3
3
|
const mapSlot_1 = require("./mapSlot");
|
|
4
4
|
function normalizeBlock(block, blocksRegistry) {
|
|
5
5
|
const { mobile, ...rest } = (block || {});
|
|
6
|
-
const
|
|
6
|
+
const result = mobile
|
|
7
7
|
? { ...rest, ...mobile, content: { ...rest.content, ...mobile.content } }
|
|
8
8
|
: block;
|
|
9
|
-
return {
|
|
10
|
-
...(0, mapSlot_1.mapSlot)((blocks) => filterBlocks(blocks, blocksRegistry))(normalizedBlock || {}),
|
|
11
|
-
};
|
|
9
|
+
return (0, mapSlot_1.mapSlot)(filterBlocks(blocksRegistry))(result || {});
|
|
12
10
|
}
|
|
13
11
|
exports.normalizeBlock = normalizeBlock;
|
|
14
|
-
const filterBlocks = (
|
|
12
|
+
const filterBlocks = (blocksRegistry) => (blocks) => blocks
|
|
15
13
|
? blocks
|
|
16
14
|
?.filter((block) => blocksRegistry &&
|
|
17
15
|
(block?.type || block?.mobile?.type || '') in blocksRegistry &&
|
|
18
16
|
!block.mobile?.hidden)
|
|
19
|
-
.map((block) => (
|
|
20
|
-
...normalizeBlock(block, blocksRegistry),
|
|
21
|
-
}))
|
|
17
|
+
.map((block) => normalizeBlock(block, blocksRegistry))
|
|
22
18
|
: [];
|
|
23
19
|
//# sourceMappingURL=normalizeBlock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"normalizeBlock.js","sourceRoot":"","sources":["../../../src/components/ContentPage/normalizeBlock.ts"],"names":[],"mappings":";;AAEA,uCAAoC;AAEpC,SAAgB,cAAc,CAAiB,KAAS,EAAE,cAA+B;IACvF,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC,KAAK,IAAI,EAAE,CAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"normalizeBlock.js","sourceRoot":"","sources":["../../../src/components/ContentPage/normalizeBlock.ts"],"names":[],"mappings":";;AAEA,uCAAoC;AAEpC,SAAgB,cAAc,CAAiB,KAAS,EAAE,cAA+B;IACvF,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,CAAC,KAAK,IAAI,EAAE,CAAa,CAAC;IACtD,MAAM,MAAM,GAAG,MAAM;QACnB,CAAC,CAAC,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,EAAE,OAAO,EAAE,EAAE,GAAG,IAAI,CAAC,OAAO,EAAE,GAAG,MAAM,CAAC,OAAO,EAAE,EAAE;QACzE,CAAC,CAAC,KAAK,CAAC;IAEV,OAAO,IAAA,iBAAO,EAAC,YAAY,CAAC,cAAc,CAAC,CAAC,CAAC,MAAM,IAAI,EAAE,CAAM,CAAC;AAClE,CAAC;AAPD,wCAOC;AAED,MAAM,YAAY,GAChB,CAAC,cAA+B,EAAE,EAAE,CACpC,CAAC,MAAmB,EAAc,EAAE,CAClC,MAAM;IACJ,CAAC,CAAC,MAAM;QACJ,EAAE,MAAM,CACN,CAAC,KAAK,EAAE,EAAE,CACR,cAAc;QACd,CAAC,KAAK,EAAE,IAAI,IAAI,KAAK,EAAE,MAAM,EAAE,IAAI,IAAI,EAAE,CAAC,IAAI,cAAc;QAC5D,CAAC,KAAK,CAAC,MAAM,EAAE,MAAM,CACxB;SACA,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,cAAc,CAAC,KAAK,EAAE,cAAc,CAAC,CAAC;IAC1D,CAAC,CAAC,EAAE,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { BlocksRegistry } from '../../model/BlocksRegistry';
|
|
2
2
|
import type { ContentPageDef } from '../../model/ContentPageDef';
|
|
3
|
-
export declare const normalizePage: (blocksRegistry: BlocksRegistry) => (contentPage: ContentPageDef | undefined | null) => ContentPageDef
|
|
3
|
+
export declare const normalizePage: (blocksRegistry: BlocksRegistry) => (contentPage: ContentPageDef | undefined | null) => ContentPageDef;
|