@redneckz/wildless-cms-uni-blocks 0.2.84 → 0.2.87
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 -945
- package/bundle/bundle.umd.js +551 -487
- package/bundle/bundle.umd.min.js +1 -1
- package/dist/components/Accordion/Accordion.js +1 -1
- package/dist/components/Accordion/Accordion.js.map +1 -1
- package/dist/components/Accordion/AccordionBlocks.d.ts +3 -0
- package/dist/components/Accordion/AccordionBlocks.js +6 -0
- package/dist/components/Accordion/AccordionBlocks.js.map +1 -1
- package/dist/components/Accordion/AccordionContent.d.ts +37 -10
- package/dist/components/Accordion/AccordionItem.d.ts +2 -2
- package/dist/components/Accordion/AccordionItem.js +5 -6
- package/dist/components/Accordion/AccordionItem.js.map +1 -1
- package/dist/components/BaseTile/BaseTile.d.ts +2 -2
- package/dist/components/BaseTile/BaseTile.js +14 -4
- package/dist/components/BaseTile/BaseTile.js.map +1 -1
- package/dist/components/BaseTile/BaseTileProps.d.ts +41 -0
- package/dist/{model/SitemapContent.js → components/BaseTile/BaseTileProps.js} +1 -1
- package/dist/components/BaseTile/BaseTileProps.js.map +1 -0
- package/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/dist/components/BenefitsBlock/BenefitsBlock.js +2 -1
- package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/dist/components/BenefitsBlock/BenefitsBlockContent.d.ts +14 -1
- package/dist/components/BlockContent.d.ts +7 -2
- package/dist/components/Blocks.d.ts +17 -14
- package/dist/components/Blocks.js +23 -17
- package/dist/components/Blocks.js.map +1 -1
- package/dist/components/ComparisonTable/ComparisonTableContent.d.ts +45 -2
- package/dist/components/ComparisonTable/HeaderCell.d.ts +2 -2
- package/dist/components/ContentPage/ContentPage.d.ts +3 -2
- package/dist/components/ContentPage/ContentPage.js.map +1 -1
- package/dist/components/CreditCalculator/CreditCalculatorContent.d.ts +4 -0
- package/dist/components/ExchangeRateTile/ExchangeRateTile.d.ts +1 -1
- package/dist/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/dist/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/dist/components/ExchangeRateTile/ExchangeRateTileContent.d.ts +4 -0
- package/dist/components/Footer/Contacts.js +2 -2
- package/dist/components/Footer/Contacts.js.map +1 -1
- package/dist/components/Footer/FooterContent.d.ts +35 -9
- package/dist/components/Footer/FooterLink.d.ts +2 -2
- package/dist/components/Footer/HorizontalNavigation.js.map +1 -1
- package/dist/components/Footer/Sitemap.d.ts +1 -1
- package/dist/components/Footer/Sitemap.js +1 -1
- package/dist/components/Footer/Sitemap.js.map +1 -1
- package/dist/components/Footer/SocialMedia.d.ts +2 -2
- package/dist/components/Footer/TextInformation.js.map +1 -1
- package/dist/components/Gallery/GalleryContent.d.ts +13 -0
- package/dist/components/Header/HeaderContent.d.ts +10 -2
- package/dist/components/Header/isSubItemActive.d.ts +2 -2
- package/dist/components/Header/isSubItemActive.js.map +1 -1
- package/dist/components/Header/isTopItemActive.d.ts +2 -2
- package/dist/components/Header/isTopItemActive.js.map +1 -1
- package/dist/components/Headline/Headline.d.ts +5 -0
- package/dist/components/Headline/Headline.js +9 -0
- package/dist/components/Headline/Headline.js.map +1 -0
- package/dist/components/Headline/HeadlineContent.d.ts +15 -0
- package/dist/components/{BaseTile/BaseTileContent.js → Headline/HeadlineContent.js} +1 -1
- package/dist/components/Headline/HeadlineContent.js.map +1 -0
- package/dist/components/LinkDocs/LinkDocs.d.ts +5 -0
- package/dist/components/LinkDocs/LinkDocs.js +42 -0
- package/dist/components/LinkDocs/LinkDocs.js.map +1 -0
- package/dist/components/LinkDocs/LinkDocsContent.d.ts +23 -0
- package/dist/components/LinkDocs/LinkDocsContent.js +2 -0
- package/dist/components/LinkDocs/LinkDocsContent.js.map +1 -0
- package/dist/components/MiniGallery/MiniGallery.d.ts +3 -3
- package/dist/components/MiniGallery/MiniGalleryContent.d.ts +6 -0
- package/dist/components/MiniGallery/MiniGalleryContent.js +2 -0
- package/dist/components/MiniGallery/MiniGalleryContent.js.map +1 -0
- package/dist/components/MobileAppTile/MobileAppTileContent.d.ts +11 -2
- package/dist/components/MobileBlocks.d.ts +8 -6
- package/dist/components/MobileBlocks.js +10 -6
- package/dist/components/MobileBlocks.js.map +1 -1
- package/dist/components/PictureText/PictureText.d.ts +5 -0
- package/dist/components/PictureText/PictureText.js +14 -0
- package/dist/components/PictureText/PictureText.js.map +1 -0
- package/dist/components/PictureText/PictureTextContent.d.ts +11 -0
- package/dist/components/PictureText/PictureTextContent.js +2 -0
- package/dist/components/PictureText/PictureTextContent.js.map +1 -0
- package/dist/components/Placeholder/PlaceholderContent.d.ts +3 -0
- package/dist/components/ProductBlock/ProductBlock.mobile.d.ts +2 -2
- package/dist/components/ProductBlock/ProductBlock.mobile.js.map +1 -1
- package/dist/components/ProductBlock/ProductBlockContent.d.ts +10 -5
- package/dist/components/ProductBlock/ProductBlockInner.d.ts +2 -2
- package/dist/components/ProductBlock/ProductBlockInner.js +1 -1
- package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/dist/components/ProductGallery/ProductGallery.d.ts +1 -1
- package/dist/components/ProductGallery/ProductGallery.js.map +1 -1
- package/dist/components/ProductGallery/ProductGalleryContent.d.ts +19 -4
- package/dist/components/ProductTile/ProductTileContent.d.ts +6 -2
- package/dist/components/PromoTile/PromoTileContent.d.ts +6 -2
- package/dist/components/StepsBlock/StepsBlockContent.d.ts +13 -0
- package/dist/components/TextBlock/TextBlockContent.d.ts +13 -0
- package/dist/components/Tile/TileContent.d.ts +5 -2
- package/dist/hooks/useLink.d.ts +3 -3
- package/dist/hooks/useLink.js.map +1 -1
- package/dist/index.d.ts +12 -12
- package/dist/index.js +10 -10
- package/dist/index.js.map +1 -1
- package/dist/mergeTopItems.d.ts +2 -2
- package/dist/mergeTopItems.js.map +1 -1
- package/dist/model/BlockVersion.d.ts +4 -0
- package/dist/model/ButtonVersion.d.ts +4 -0
- package/dist/model/LinkProps.d.ts +21 -0
- package/dist/model/{LinkContent.js → LinkProps.js} +1 -1
- package/dist/model/LinkProps.js.map +1 -0
- package/dist/model/Picture.d.ts +11 -0
- package/dist/model/SitemapProps.d.ts +13 -0
- package/dist/model/SitemapProps.js +2 -0
- package/dist/model/SitemapProps.js.map +1 -0
- package/dist/types.d.ts +2 -2
- package/dist/ui-kit/Breadcrumb.d.ts +2 -2
- package/dist/ui-kit/Button/Button.d.ts +6 -3
- package/dist/ui-kit/Button/Button.js.map +1 -1
- package/dist/ui-kit/Button/ButtonProps.d.ts +15 -12
- package/dist/ui-kit/Icon/IconProps.d.ts +53 -18
- package/dist/ui-kit/Icon/IconProps.js +23 -18
- package/dist/ui-kit/Icon/IconProps.js.map +1 -1
- package/dist/ui-kit/TopItem/TopItem.d.ts +2 -2
- package/lib/common.css +1 -1
- package/lib/components/Accordion/Accordion.fixture.d.ts +1 -0
- package/lib/components/Accordion/Accordion.js +1 -1
- package/lib/components/Accordion/Accordion.js.map +1 -1
- package/lib/components/Accordion/AccordionBlocks.d.ts +3 -0
- package/lib/components/Accordion/AccordionBlocks.js +6 -0
- package/lib/components/Accordion/AccordionBlocks.js.map +1 -1
- package/lib/components/Accordion/AccordionContent.d.ts +37 -10
- package/lib/components/Accordion/AccordionItem.d.ts +2 -2
- package/lib/components/Accordion/AccordionItem.js +5 -6
- package/lib/components/Accordion/AccordionItem.js.map +1 -1
- package/lib/components/BaseTile/BaseTile.d.ts +2 -2
- package/lib/components/BaseTile/BaseTile.js +14 -4
- package/lib/components/BaseTile/BaseTile.js.map +1 -1
- package/lib/components/BaseTile/BaseTileProps.d.ts +41 -0
- package/lib/components/BaseTile/BaseTileProps.js +2 -0
- package/lib/components/BaseTile/BaseTileProps.js.map +1 -0
- package/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.js +2 -1
- package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
- package/lib/components/BenefitsBlock/BenefitsBlockContent.d.ts +14 -1
- package/lib/components/BlockContent.d.ts +7 -2
- package/lib/components/Blocks.d.ts +17 -14
- package/lib/components/Blocks.js +23 -17
- package/lib/components/Blocks.js.map +1 -1
- package/lib/components/ComparisonTable/ComparisonTableContent.d.ts +45 -2
- package/lib/components/ComparisonTable/HeaderCell.d.ts +2 -2
- package/lib/components/ContentPage/ContentPage.d.ts +3 -2
- package/lib/components/ContentPage/ContentPage.js.map +1 -1
- package/lib/components/CreditCalculator/CreditCalculatorContent.d.ts +4 -0
- package/lib/components/ExchangeRateTile/ExchangeRateTile.d.ts +1 -1
- package/lib/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
- package/lib/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
- package/lib/components/ExchangeRateTile/ExchangeRateTileContent.d.ts +4 -0
- package/lib/components/Footer/Contacts.js +2 -2
- package/lib/components/Footer/Contacts.js.map +1 -1
- package/lib/components/Footer/FooterContent.d.ts +35 -9
- package/lib/components/Footer/FooterLink.d.ts +2 -2
- package/lib/components/Footer/HorizontalNavigation.js.map +1 -1
- package/lib/components/Footer/Sitemap.d.ts +1 -1
- package/lib/components/Footer/Sitemap.js +1 -1
- package/lib/components/Footer/Sitemap.js.map +1 -1
- package/lib/components/Footer/SocialMedia.d.ts +2 -2
- package/lib/components/Footer/TextInformation.js.map +1 -1
- package/lib/components/Gallery/GalleryContent.d.ts +13 -0
- package/lib/components/Header/HeaderContent.d.ts +10 -2
- package/lib/components/Header/isSubItemActive.d.ts +2 -2
- package/lib/components/Header/isSubItemActive.js.map +1 -1
- package/lib/components/Header/isTopItemActive.d.ts +2 -2
- package/lib/components/Header/isTopItemActive.js.map +1 -1
- package/lib/components/Headline/Headline.d.ts +5 -0
- package/lib/components/Headline/Headline.fixture.d.ts +7 -0
- package/lib/components/Headline/Headline.js +7 -0
- package/lib/components/Headline/Headline.js.map +1 -0
- package/lib/components/Headline/HeadlineContent.d.ts +15 -0
- package/lib/components/Headline/HeadlineContent.js +2 -0
- package/lib/components/Headline/HeadlineContent.js.map +1 -0
- package/lib/components/LinkDocs/LinkDocs.d.ts +5 -0
- package/lib/components/LinkDocs/LinkDocs.fixture.d.ts +12 -0
- package/lib/components/LinkDocs/LinkDocs.js +40 -0
- package/lib/components/LinkDocs/LinkDocs.js.map +1 -0
- package/lib/components/LinkDocs/LinkDocsContent.d.ts +23 -0
- package/lib/components/LinkDocs/LinkDocsContent.js +2 -0
- package/lib/components/LinkDocs/LinkDocsContent.js.map +1 -0
- package/lib/components/MiniGallery/MiniGallery.d.ts +3 -3
- package/lib/components/MiniGallery/MiniGalleryContent.d.ts +6 -0
- package/lib/components/MiniGallery/MiniGalleryContent.js +2 -0
- package/lib/components/MiniGallery/MiniGalleryContent.js.map +1 -0
- package/lib/components/MobileAppTile/MobileAppTileContent.d.ts +11 -2
- package/lib/components/MobileBlocks.d.ts +8 -6
- package/lib/components/MobileBlocks.js +10 -6
- package/lib/components/MobileBlocks.js.map +1 -1
- package/lib/components/PictureText/PictureText.d.ts +5 -0
- package/lib/components/PictureText/PictureText.fixture.d.ts +4 -0
- package/lib/components/PictureText/PictureText.js +12 -0
- package/lib/components/PictureText/PictureText.js.map +1 -0
- package/lib/components/PictureText/PictureTextContent.d.ts +11 -0
- package/lib/components/PictureText/PictureTextContent.js +2 -0
- package/lib/components/PictureText/PictureTextContent.js.map +1 -0
- package/lib/components/Placeholder/PlaceholderContent.d.ts +3 -0
- package/lib/components/ProductBlock/ProductBlock.mobile.d.ts +2 -2
- package/lib/components/ProductBlock/ProductBlock.mobile.js.map +1 -1
- package/lib/components/ProductBlock/ProductBlockContent.d.ts +10 -5
- package/lib/components/ProductBlock/ProductBlockInner.d.ts +2 -2
- package/lib/components/ProductBlock/ProductBlockInner.js +1 -1
- package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
- package/lib/components/ProductGallery/ProductGallery.d.ts +1 -1
- package/lib/components/ProductGallery/ProductGallery.js.map +1 -1
- package/lib/components/ProductGallery/ProductGalleryContent.d.ts +19 -4
- package/lib/components/ProductTile/ProductTileContent.d.ts +6 -2
- package/lib/components/PromoTile/PromoTileContent.d.ts +6 -2
- package/lib/components/StepsBlock/StepsBlockContent.d.ts +13 -0
- package/lib/components/TextBlock/TextBlockContent.d.ts +13 -0
- package/lib/components/Tile/TileContent.d.ts +5 -2
- package/lib/hooks/useLink.d.ts +3 -3
- package/lib/hooks/useLink.js.map +1 -1
- package/lib/index.d.ts +12 -12
- package/lib/index.js +5 -5
- package/lib/index.js.map +1 -1
- package/lib/mergeTopItems.d.ts +2 -2
- package/lib/mergeTopItems.js.map +1 -1
- package/lib/model/BlockVersion.d.ts +4 -0
- package/lib/model/ButtonVersion.d.ts +4 -0
- package/lib/model/LinkProps.d.ts +21 -0
- package/lib/model/LinkProps.js +2 -0
- package/lib/model/LinkProps.js.map +1 -0
- package/lib/model/Picture.d.ts +11 -0
- package/lib/model/SitemapProps.d.ts +13 -0
- package/lib/model/SitemapProps.js +2 -0
- package/lib/model/SitemapProps.js.map +1 -0
- package/lib/types.d.ts +2 -2
- package/lib/ui-kit/Breadcrumb.d.ts +2 -2
- package/lib/ui-kit/Button/Button.d.ts +6 -3
- package/lib/ui-kit/Button/Button.js.map +1 -1
- package/lib/ui-kit/Button/ButtonProps.d.ts +15 -12
- package/lib/ui-kit/Icon/IconProps.d.ts +53 -18
- package/lib/ui-kit/Icon/IconProps.js +23 -18
- package/lib/ui-kit/Icon/IconProps.js.map +1 -1
- package/lib/ui-kit/TopItem/TopItem.d.ts +2 -2
- package/package.json +2 -22
- package/src/components/Accordion/Accordion.example.json +74 -0
- package/src/components/Accordion/Accordion.fixture.tsx +93 -7
- package/src/components/Accordion/Accordion.tsx +1 -1
- package/src/components/Accordion/AccordionBlocks.tsx +6 -0
- package/src/components/Accordion/AccordionContent.ts +43 -11
- package/src/components/Accordion/AccordionItem.tsx +10 -10
- package/src/components/BaseTile/BaseTile.tsx +22 -9
- package/src/components/BaseTile/BaseTileProps.ts +44 -0
- package/src/components/BenefitsBlock/BenefitsBlock.example.json +13 -0
- package/src/components/BenefitsBlock/BenefitsBlock.tsx +3 -2
- package/src/components/BenefitsBlock/BenefitsBlockContent.ts +14 -1
- package/src/components/BlockContent.ts +19 -12
- package/src/components/Blocks.ts +23 -17
- package/src/components/ComparisonTable/ComparisonTable.example.json +84 -0
- package/src/components/ComparisonTable/ComparisonTableContent.ts +46 -3
- package/src/components/ComparisonTable/HeaderCell.tsx +2 -2
- package/src/components/ContentPage/ContentPage.page.json +88 -2
- package/src/components/ContentPage/ContentPage.tsx +7 -5
- package/src/components/CreditCalculator/CreditCalculatorContent.ts +4 -0
- package/src/components/ExchangeRateTile/ExchangeRateTile.tsx +2 -2
- package/src/components/ExchangeRateTile/ExchangeRateTileContent.ts +4 -0
- package/src/components/Footer/Contacts.tsx +2 -2
- package/src/components/Footer/FooterContent.ts +36 -9
- package/src/components/Footer/FooterLink.ts +2 -2
- package/src/components/Footer/HorizontalNavigation.tsx +2 -2
- package/src/components/Footer/Sitemap.tsx +5 -5
- package/src/components/Footer/SocialMedia.tsx +2 -2
- package/src/components/Footer/TextInformation.tsx +2 -2
- package/src/components/Gallery/Gallery.example.json +71 -0
- package/src/components/Gallery/GalleryContent.ts +13 -0
- package/src/components/Header/HeaderContent.ts +10 -2
- package/src/components/Header/isSubItemActive.ts +3 -3
- package/src/components/Header/isTopItemActive.ts +3 -3
- package/src/components/Headline/Headline.example.json +6 -0
- package/src/components/Headline/Headline.fixture.tsx +42 -0
- package/src/components/Headline/Headline.tsx +15 -0
- package/src/components/Headline/HeadlineContent.ts +18 -0
- package/src/components/LinkDocs/LinkDocs.fixture.tsx +51 -0
- package/src/components/LinkDocs/LinkDocs.tsx +81 -0
- package/src/components/LinkDocs/LinkDocsContent.ts +26 -0
- package/src/components/MiniGallery/MiniGallery.example.json +61 -0
- package/src/components/MiniGallery/MiniGallery.tsx +3 -3
- package/src/components/MiniGallery/MiniGalleryContent.ts +6 -0
- package/src/components/MobileAppTile/MobileAppTile.example.json +20 -0
- package/src/components/MobileAppTile/MobileAppTileContent.ts +11 -2
- package/src/components/MobileBlocks.ts +10 -6
- package/src/components/PictureText/PictureText.example.json +20 -0
- package/src/components/PictureText/PictureText.fixture.tsx +36 -0
- package/src/components/PictureText/PictureText.tsx +45 -0
- package/src/components/PictureText/PictureTextContent.ts +13 -0
- package/src/components/Placeholder/PlaceholderContent.ts +3 -0
- package/src/components/ProductBlock/ProductBlock.example.json +17 -0
- package/src/components/ProductBlock/ProductBlock.mobile.tsx +3 -3
- package/src/components/ProductBlock/ProductBlockContent.ts +10 -5
- package/src/components/ProductBlock/ProductBlockInner.tsx +4 -4
- package/src/components/ProductGallery/ProductGallery.example.json +21 -0
- package/src/components/ProductGallery/ProductGallery.tsx +3 -3
- package/src/components/ProductGallery/ProductGalleryContent.ts +19 -4
- package/src/components/ProductTile/ProductTile.example.json +30 -0
- package/src/components/ProductTile/ProductTileContent.ts +6 -2
- package/src/components/PromoTile/PromoTile.example.json +13 -0
- package/src/components/PromoTile/PromoTileContent.ts +6 -2
- package/src/components/StepsBlock/StepsBlock.example.json +17 -0
- package/src/components/StepsBlock/StepsBlockContent.ts +13 -0
- package/src/components/TextBlock/TextBlock.example.json +6 -0
- package/src/components/TextBlock/TextBlockContent.ts +14 -0
- package/src/components/Tile/Tile.example.json +18 -0
- package/src/components/Tile/TileContent.ts +5 -2
- package/src/hooks/useLink.ts +2 -2
- package/src/icons/DiscountShape.svg +7 -0
- package/src/icons/DocIcon.svg +1 -1
- package/src/icons/DocumentText.svg +6 -0
- package/src/icons/GridIcon.svg +4 -7
- package/src/index.ts +14 -21
- package/src/mergeTopItems.ts +5 -5
- package/src/model/BlockVersion.ts +4 -0
- package/src/model/ButtonVersion.ts +4 -0
- package/src/model/LinkProps.ts +22 -0
- package/src/model/Picture.ts +11 -0
- package/src/model/SitemapProps.ts +15 -0
- package/src/types.ts +2 -2
- package/src/ui-kit/Breadcrumb.tsx +2 -2
- package/src/ui-kit/Button/Button.tsx +7 -3
- package/src/ui-kit/Button/ButtonProps.ts +16 -13
- package/src/ui-kit/Icon/IconProps.ts +39 -4
- package/src/ui-kit/TopItem/TopItem.tsx +2 -2
- package/dist/components/BaseTile/BaseTileContent.d.ts +0 -13
- package/dist/components/BaseTile/BaseTileContent.js.map +0 -1
- package/dist/model/LinkContent.d.ts +0 -5
- package/dist/model/LinkContent.js.map +0 -1
- package/dist/model/SitemapContent.d.ts +0 -7
- package/dist/model/SitemapContent.js.map +0 -1
- package/lib/components/BaseTile/BaseTileContent.d.ts +0 -13
- package/lib/components/BaseTile/BaseTileContent.js +0 -2
- package/lib/components/BaseTile/BaseTileContent.js.map +0 -1
- package/lib/model/LinkContent.d.ts +0 -5
- package/lib/model/LinkContent.js +0 -2
- package/lib/model/LinkContent.js.map +0 -1
- package/lib/model/SitemapContent.d.ts +0 -7
- package/lib/model/SitemapContent.js +0 -2
- package/lib/model/SitemapContent.js.map +0 -1
- package/src/components/BaseTile/BaseTileContent.ts +0 -14
- package/src/icons/MinusIcon.svg +0 -1
- package/src/icons/PlusIcon.svg +0 -1
- package/src/model/LinkContent.ts +0 -5
- package/src/model/SitemapContent.ts +0 -9
package/bundle/bundle.umd.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";const t=(e,r)=>{t._jsx=e,t._jsxs=r||e};t.vue=e=>{t(((t,{children:r,dangerouslySetInnerHTML:n,...a}={})=>{const i=Object.assign({},a,n?{innerHTML:n.__html}:{});return e(t,i,"string"!=typeof t?()=>r:r)}))};const r=(...e)=>t._jsx(...e),n=(...e)=>t._jsxs(...e),a=e=>(e._tmpl||(e._tmpl=function(t,r){const{children:n,...a}=t||{},i=r?.slots?.default,l=n||i&&i();return e(Object.assign(a,l&&{children:l}),r)},e._tmpl.inheritAttrs=!1),e._tmpl),i=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 ENABLE_ASSIST(){return this._.ENABLE_ASSIST}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}},l="likesToken";const s=a((({HeadComponent:e,data:t,children:a})=>{const{title:i,description:l,keywords:s,robots:c,og:o}=t;return n(e,{children:[r("title",{children:i}),r("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),l&&r("meta",{name:"description",content:l}),s&&r("meta",{name:"keywords",content:s.join(",")}),c&&r("meta",{name:"robots",content:c.join(",")}),o?Object.entries(o).map((([e,t])=>r("meta",{name:`og:${e}`,content:t},e))):null,a]})})),c=a((({className:e,onClick:t,ariaLabel:n})=>r("button",{type:"button",className:`border-0 w-[36px] bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":n,children:o()}))),o=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return n("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[r("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"}),r("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"})]})},m=a((({className:e,context:t})=>{const a=t.useLikeService();return n("div",{className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e||""}`,children:[r(c,{onClick:a.like,ariaLabel:"Поставить отметку «лайк»"}),r(c,{onClick:a.dislike,className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),r("span",{className:"select-none",children:a.likeCount})]})})),d={primary:"bg-primary-main",secondary:"bg-white"},h={primary:"text-primary-text",secondary:"text-white"},x=a((({className:e,text:t,children:a,version:i="primary"})=>n("div",{className:`inline-block flex ${e||""}`,role:"listitem",children:[r("div",{className:`inline-block w-[8px] h-[8px] min-w-[8px] min-h-[8px] rounded-full mt-2 ${d[i]}`}),r("span",{className:`text-base font-normal font-sans mx-3 ${h[i]}`,children:t||a})]}))),u={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-secondary-light hover:bg-secondary-hover active:bg-secondary-active"},p={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text"},f="inline-block text-center font-sans select-none",b=a((({className:e,text:t,aboveText:n,appendLeft:a,href:i,target:l,onClick:s,children:c,disabled:o,rounded:m,version:d="none",ariaLabel:h,...x})=>{const b=c??r(g,{text:t,aboveText:n,appendLeft:a,rounded:m});return o?r("div",{role:"button","aria-disabled":"true","aria-label":h,tabIndex:"-1",className:`${f} ${p[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,children:b}):r("a",{className:`${f} cursor-pointer no-underline ${u[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:s,"aria-label":h,role:i?"link":"button",...x,children:b})})),g=a((({text:e,aboveText:t,appendLeft:a,rounded:i})=>{const l=!e&&!t&&Boolean(a);return n("div",{className:`flex items-center justify-center ${l?"h-12 w-12 min-h-12 min-w-12":"px-8 gap-2 "+(t?"py-2":"py-[13px]")} ${i?"rounded-full":""}`,children:[a||null,l?null:n("div",{children:[r("div",{className:"text-xxs text-left",children:t}),r("div",{className:"text-sm font-medium text-left",children:e})]})]})})),N=a((({className:e,name:t,alt:a=`Icon ${t}`,title:l=a,asSVG:s,...c})=>{const o=`${i.CDN||""}icons/${t}.svg`;return s?n("svg",{className:e,...c,"aria-hidden":"true",children:[l?r("title",{children:l}):null,a?r("desc",{children:a}):null,r("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]}):r("img",{className:e,src:o,alt:a,title:l,...c,"aria-hidden":"true"})})),v=a((({className:e,image:t})=>n("picture",{className:`${e||""}`,children:[t.sources?.length?t.sources.map((({src:e,format:t},n)=>r("source",{srcSet:e,type:y(t)},`${n}_${e}`))):null,r("img",{src:t.src,alt:t.alt||t.title,title:t.title,...t?.size})]})));function y(e){return e?`image/${String(e)}`:void 0}var w;!function(e){e.XL="text-title-lg",e.L="text-title",e.M="text-title-sm",e.S="text-title-xs"}(w||(w={}));const k=a((({size:e="L",className:t,children:n,...a})=>r("XL"===e?"h1":"h2",{className:$(w[e],t),...a,children:n}))),$=(...e)=>e.filter(Boolean).join(" "),S="/mobile",C=e=>e?.includes("//"),_=(e,t,r=((e,t)=>e===t))=>r(j(e),L(j(C(e)?t.href:t.pathname))),j=e=>(e||"").replace(/\/?\?.*/,""),L=e=>(e||"").replace(S,""),D=e=>{if(!C(e))return;const t=e,r=t.indexOf("//"),n=t.indexOf("/",r+"//".length);return-1!==n?t.substring(0,n):t},R=(e,t)=>{if(!e)return e;const r=T(e,t),n=t?.pathname.startsWith(S);return n&&!C(r)?`/mobile${r}`:r},T=(e,t)=>{if(!e)return e;const r=D(t?.href);return r?e.replace(r,"")||"/":e};var I=Object.freeze({__proto__:null,MOBILE_URL_PATH:S,isURL:C,isHrefActive:_,withoutQuery:j,withoutMobilePath:L,getOrigin:D,adjustHref:R,toRelativeHref:T});const M=(e,t)=>e;function A({router:e,handlerDecorator:t=M},r){const n=R(r.href,e);return{...r,href:n,ariaLabel:r.text,onClick:t((t=>{const a=n&&!C(n),i=!r.target||"_self"===r.target;a&&i&&(t.preventDefault(),e.push(n))}),r)}}const P=e=>{const t="col-span-",r=e.split(/\s+/).find((e=>e.startsWith(t)));return r?parseInt(r.substring(t.length),10):12},B=a((({className:e,context:t,title:a,titleSize:i,description:l,children:s,buttons:c,image:o,items:m,version:d="primary"})=>{const h=t.useRouter(),{handlerDecorator:x}=t;return n("div",{className:"font-sans flex flex-col grow h-full",children:[a&&r(k,{size:i||O(e),className:"font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px]",children:a}),n("div",{className:"flex grow justify-between",children:[n("div",{className:"flex flex-col justify-between items-start",children:[n("div",{children:[l?r("div",{className:"font-normal text-base max-w-[600px] mb-5",children:l}):null,s,m?.length?V(m,d):null]}),c?.length?r("div",{className:"flex mt-9 gap-3",children:c.map(((e,t)=>function({icon:e,...t},n){if(!t?.text)return;return r(b,e?{appendLeft:r(N,{name:e,width:"24",height:"24"}),...t}:{...t},String(n))}(A({router:h,handlerDecorator:x},e),t)))}):null]}),o?.src&&r(v,{className:"mt-auto ml-7",image:o})]})]})}));function O(e=""){const t=P(e);return t<=4?"S":t<=8?"M":"L"}function V(e=[],t){return r("section",{className:"max-w-[600px]",role:"list",children:e.map(((e,n)=>r(x,{className:n?"mt-2.5":"",text:e,version:t},String(n))))})}const H={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},Z=a((e=>{const{children:t,className:n,version:a="primary"}=e;return r("section",{className:`font-sans p-9 min-h-[320px] box-border ${n||""} ${H[a]} ${F(n)} `,children:r(B,{...e,children:t})})}));function F(e=""){const t=P(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const z=a((({className:e,context:t,title:n})=>r(Z,{className:e,context:t,title:n,description:"Блок в разработке...",children:r("figure",{className:"m-0 min-w-[600px]",children:E()})}))),E=(e=3)=>U(100,e).map((e=>Math.floor(e))).map(G),G=(e=100,t)=>r("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),U=(e,t)=>[e].concat(t>0?U(e/1.618,t-1):[]),W=({blockClassName:e,block:t,render:r})=>r({blockClassName:e,block:t}),J=a((({className:e,context:t,blocksRegistry:a,data:{style:i,blocks:l,likeControl:s,colorPalette:c="pc"},blockDecorator:o=W})=>n("section",{className:"relative","data-theme":c,children:[r("div",{className:`grid grid-cols-12 gap-1 ${X(i)} ${e||""}`,children:l?.length?l.map((function e(n,i){const{type:l}=n;l in a||console.warn(`No block with "${l}" is registered`);const s=a[l]||z;return o({blockClassName:X(n.style),block:n,render:n=>{const{version:a,content:c,blocks:o}=n.block;return r(s,{className:n.blockClassName,version:a,context:t,...c,children:o?.length?o.map(e):null},`${l}-${i}`)}},`block-${i}`)})):null}),s&&r("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:r(m,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:t})})]})));function X(e){return e?e.join(" "):""}function Q(e){const{mobile:t}=e;return t?{...e,style:t.style?.length?t.style:e.style}:e}const q=a((({className:e,title:t,benefits:a})=>n("section",{className:`font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${e||""}`,children:[r("h2",{className:"font-medium text-title m-0 max-w-[47rem] text-center",children:t}),a?.length?r("div",{className:"grid grid-cols-2 gap-5 mt-9",children:a.map(K)}):null]}))),K=(e,t)=>n("div",{className:"flex items-center p-10 gap-5 max-w-[580px]",children:[e.icon&&r(N,{className:"h-[70px] w-[70px] min-w-[70px] min-h-[70px]",name:e.icon,width:"70",height:"70"}),n("div",{children:[r("h3",{className:"font-medium text-xl m-0",children:e.label}),e.description&&r("div",{className:"font-normal text-sm mt-2",children:e.description})]})]},String(t)),Y="https://www.cbr-xml-daily.ru/daily_json.js",ee=["USD","EUR"],te={USD:"DollarIcon",EUR:"EuroIcon"},re=[{text:"Все показатели",href:"https://cbr.ru/currency_base/daily/",version:"secondary"}],ne=a((({className:e,context:t,title:a})=>{const{data:i}=t.useAsyncData(Y,le);return r(Z,{className:e,context:t,title:a||"Курсы обмена валют",buttons:re,children:n("table",{children:[r("thead",{children:n("tr",{children:[r(ae,{children:"Валюта"}),r(ae,{className:"pl-11",children:"Курс"})]})}),r("tbody",{children:ee.map((e=>{const t=(i?.Valute||{})[e]?.Value;return n("tr",{children:[r(ie,{className:"pt-4",children:n("div",{className:"flex items-center",children:[r(N,{name:te[e],width:"24",height:"24"}),r("span",{className:"ml-2",children:e})]})}),r(ie,{className:"pt-4 pl-11",children:ce(t)})]},e)}))})]})})})),ae=a((({className:e="",children:t})=>r("th",{className:`text-left font-normal text-sm text-secondary-text ${e}`,children:t}))),ie=a((({className:e="",children:t})=>r("td",{className:`text-left font-normal text-base text-primary-text ${e}`,children:t})));async function le(){const e=await fetch(Y);return await e.json()}const se=new Intl.NumberFormat("ru",{style:"currency",currency:"RUB"}),ce=e=>e?se.format(e):"",oe=a((({className:e,viewBox:t,fill:n="none",width:a,height:i,paths:l,...s})=>r("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:n,width:a,height:i,children:l.map((({d:e,fill:t,...n},a)=>r("path",{d:e,fill:t||"currentColor",...s,...n},a)))}))),me=["m13.72 25.51 4.42-4.33v-2.95l-4.42 4.32v2.96Zm0-10.98 4.42-4.35V7.41l-4.42 4.31v2.8Zm0 3.63 4.42-4.33v-2.78l-4.42 4.32v2.8ZM12.46 7.44l-.6-.56V0h-.66v6.22l-.58-.57V0h-.67v5l-.59-.58V0H8.7v6.56l4.44 4.33V0h-.67v7.44Zm1.26 14.35 4.42-4.33v-2.78L13.72 19v2.8Zm-5.03-.61 4.44 4.33v-2.96l-4.44-4.32v2.95Zm8.79-16.76-.59.58V0h-.66v5.66l-.6.56V0h-.66v6.87l-.58.57V0h-.67v10.9l4.42-4.34V0h-.66v4.42Zm-8.79 5.76 4.44 4.35v-2.8L8.69 7.4v2.77Zm0 3.65 4.44 4.33v-2.8l-4.44-4.3v2.77Zm0 3.63 4.44 4.33V19l-4.44-4.31v2.78Zm26.37 2.29H24.3a2.25 2.25 0 0 0 .36-1.22 2.32 2.32 0 0 0-2.33-2.31 2.32 2.32 0 0 0-2.31 2.31c0 .5.16.96.43 1.34a.74.74 0 0 0-.33.61c0 .26.14.49.33.62a2.32 2.32 0 0 0-.43 1.34 2.31 2.31 0 0 0 2.31 2.31 2.32 2.32 0 0 0 2.33-2.31c0-.45-.13-.87-.36-1.22h8.01v.49h-.8v.68h.8v.7h-.8v1.3h.8v-.58h1.17v.58h.79v-1.3h-.79v-.7h.79v-.68h-.79v-.5h1.58a.56.56 0 0 0 .56-.56v-.34a.57.57 0 0 0-.56-.56Zm-11.53 2.7a1.2 1.2 0 0 1-2.4 0c0-.24.08-.47.2-.66l.34-.56a.97.97 0 0 1-.34-.75c0-.3.13-.56.33-.74l-.32-.56a1.13 1.13 0 0 1-.2-.66 1.2 1.2 0 0 1 2.4 0c0 .49-.56 1.65-.56 1.65v.62c-.01.01.55 1.17.55 1.66ZM4.67 18.34v2.89c0 2.75 1.2 4.53 1.9 5.21l4.58 4.5c1.28 1.25 1.5 1.66 1.79 2.37v-3.2c0-2.84-1.44-3.94-2.19-4.67-1.73-1.68-2.89-2.8-3.82-3.73a8.98 8.98 0 0 1-2.26-3.37Zm6.08 14.24c-1.73-1.7-2.89-2.8-3.82-3.73a10 10 0 0 1-2.25-2.98v2.49a7.87 7.87 0 0 0 1.89 5.24l4.58 4.47c1.28 1.25 1.5 1.85 1.79 2.55v-3.37c0-2.85-1.45-3.95-2.19-4.67Z","M19.88 5.34c-.32 0-.64 0-.96.02V6.7a18.5 18.5 0 1 1 .95 36.94A18.5 18.5 0 0 1 1.35 25.17c0-5.67 2.55-10.73 6.58-14.13V9.32A19.78 19.78 0 0 0 0 25.17C0 36.12 8.9 45 19.88 45a19.85 19.85 0 0 0 19.86-19.83c0-10.95-8.9-19.83-19.87-19.83Z","M33.93 35.53c.3-.41.6-.85.87-1.3v-2.66h-.87v3.96Zm2.54-4.92c.12-.4.24-.78.34-1.16h-2.88v.7h.43c.77-.02 1.63-.03 2.11.46Zm-19.19-1.27h-.78v7.91h.78v-7.9Z","M14.7 27.83h2.58c.67 0 1.14.14 1.4.4.27.25.4.72.4 1.38v7.4c0 .66-.12 1.12-.4 1.38-.4.41-1.16.41-1.78.41l-.4-.01v3.5l.78.14v-2.88c1.2 0 1.97-.4 2.34-1.22v4.29h.26l.5-.01V29.74c0-.68.13-1.16.4-1.43.25-.27.72-.4 1.37-.4.67 0 1.65-.1 2.16.4.26.27.38.76.38 1.43v3.8h-1.77v-4.06h-.77v12.99c.26-.03.5-.07.77-.12V34.3h1.77v7.64c.36-.1.72-.21 1.08-.34v-7c0-.8.19-1.4 1-1.67l-.9-4.87h1.8l.3 5.31h.22l.3-5.31h1.88l-1.01 4.87c.84.3 1.01.81 1.01 1.66v4.53a16.63 16.63 0 0 0 1.5-1.27v-9.83h5.25l.1-.72H24.93l.17.89c-.38-.72-1.12-1.08-2.2-1.08h-.77c-1.3 0-2.1.52-2.4 1.55-.27-1.08-1.1-1.62-2.46-1.62h-3.36v14.52c.26.09.52.18.78.25V27.84Zm16.29 5.58-.85-.8.85-4.37v5.17Z","M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z"],de=a((({className:e,href:t,children:a,targetBlank:i})=>n("a",{className:`inline-flex items-center font-sans no-underline ${e||""}`,href:t||"https://rshb.ru/",target:i?"_blank":"_self",children:[r(oe,{className:"text-primary-main w-10",viewBox:"0 0 40 45",paths:me.map((e=>({d:e})))}),r("span",{className:"text-black text-base font-medium ml-2.5",children:a||"Россельхозбанк"})]}))),he=a((({className:e,context:t})=>{const{term:a,setTerm:i}=t.useSearch();return n("form",{className:`relative ${e||""}`,children:[n("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:[r("div",{className:"w-[24px] h-[24px]",children:r(N,{name:"LoupeIcon",width:"24",height:"24"})}),!a&&r("span",{className:"font-sans font-normal text-base text-secondary-text",children:"Поиск по сайту"})]}),r("input",{className:"pl-12 w-full font-sans font-normal text-base text-black border border-solid border-main-divider rounded h-full box-border outline-none pr-[6%]",value:a,onChange:e=>i(e.target.value),type:"text",name:"s"}),a&&r("button",{type:"submit",className:"absolute font-sans font-normal text-sm cursor-pointer bg-transparent hover:bg-primary-hover active:bg-primary-active text-primary-main hover:text-white border-none px-5 py-2 rounded top-1 right-1 outline-none",onClick:e=>{e.preventDefault(),console.log("click")},children:"Найти"})]})})),xe=a((({className:e,items:t,hasButton:a,context:i})=>{const l=i.useRouter(),{handlerDecorator:s}=i;return n("div",{className:`flex flex-col ${e||""}`,children:[t?.length?t.map(ue):null,a?r(b,{version:"primary",className:"my-4",...A({router:l,handlerDecorator:s},{text:"Обратная связь",href:"/",target:"_blank"})}):null]})})),ue=(e,t)=>{const{type:a,text:i,description:l}=e;return n("div",{className:"mb-4",children:[r("div",{children:pe(a,i)}),r("div",{className:"font-sans text-sm text-secondary-text",children:l})]},String(t))},pe=(e,t)=>{switch(e){case"tel":return r("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`tel:${fe(t)}`,children:t});case"email":return r("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return r("span",{children:t})}},fe=e=>e.replaceAll(/(\-|\s|\(|\)|\D+)/g,""),be=a((({className:e,links:t,context:n})=>{const a=n.useRouter(),{handlerDecorator:i}=n;return r("div",{className:`${e||""}`,children:t?.length?r("div",{className:"flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>r(ge,{index:t,...A({router:a,handlerDecorator:i},e)},String(t))))}):null})})),ge=a((({className:e,index:t,text:n,href:a,target:i,onClick:l})=>r("a",{className:`font-sans font-normal text-sm text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${e||""}`,href:a,target:i,onClick:l,children:n||`Документ ${t}`}))),Ne=e=>t=>e?.href===t?.href;function ve(e,t){return(n=e,a=t,(n||[]).map((e=>a?.find(Ne(e))||e))).concat((r=e,(t||[]).filter((e=>!r?.find(Ne(e))))));var r,n,a}function ye(e){const{data:t}=e(ke(),we);return t||{}}async function we(){const e=await fetch(ke());return await e.json()}function ke(){return`/wcms-resources/${i.SITEMAP||"sitemap"}.json`}const $e=a((({className:e,items:t,context:n})=>{const a=ve(ye(n.useAsyncData).topItems,t),i={router:n.useRouter(),handlerDecorator:n.handlerDecorator};return r("div",{className:`flex items-start justify-start gap-11 xl:gap-5 ${e||""}`,children:a?.map(((e,t)=>Se(e,t,i)))})})),Se=(e,t,{router:a,handlerDecorator:i})=>{const{text:l,href:s,items:c,target:o}=e;return n("div",{className:"flex flex-col w-[235px] gap-[14px]",children:[r("a",{className:"block font-sans font-medium text-base text-primary-text no-underline",href:s,target:o||"_self",children:l||`Раздел ${t}`}),c?.map(((e,t)=>r(Ce,{...A({router:a,handlerDecorator:i},e)},String(t))))]},String(t))},Ce=a((({text:e,href:t,target:n,index:a})=>r("a",{className:"block font-sans font-normal text-base text-secondary-text hover:text-primary-main no-underline",href:t,target:n||"_self",children:e||`Раздел ${a}`}))),_e=[{origins:["t.me","telegram.org"],icon:"TelegramIcon",label:"Телеграм",width:"20px",height:"16px"},{origins:["vk.com"],icon:"VKIcon",label:"ВКонтакте",width:"24px",height:"12px"},{origins:["ok.ru"],icon:"OkIcon",label:"Одноклассники",width:"12px",height:"20px"}],je=a((({className:e,media:t,context:n})=>{const a=n.useRouter(),{handlerDecorator:i}=n;return r("div",{className:`flex items-end justify-end gap-2 pt-[30px] pb-7 ${e||""}`,children:t?.map(((e,t)=>r(Le,{...A({router:a,handlerDecorator:i},e)},String(t))))})})),Le=a((({href:e})=>{const{icon:t,label:n,width:a,height:i}=_e.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};return t?r(b,{rounded:!0,href:e,target:"_blank",rel:"noopener noreferrer","aria-label":n,className:"border-solid border border-main-divider w-9 h-9 flex items-center justify-center hover:fill-primary-main",appendLeft:r(N,{name:t,width:a,height:i,asSVG:!0})}):null})),De=a((({className:e,links:t,context:a})=>{const i=a.useRouter(),{handlerDecorator:l}=a;return n("div",{className:`${e||""}`,children:[r("div",{className:"pt-5 pb-[5px]",children:r("span",{className:"font-sans font-normal text-xs text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?r("div",{className:"flex justify-start items-start gap-5 pt-[5px]",children:t.map(((e,t)=>r(Re,{index:t,...A({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),Re=a((({className:e,index:t,text:n,href:a,target:i,onClick:l})=>r("a",{className:`font-sans font-normal text-xs text-secondary-text visited:text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${e||""}`,href:a,target:i,onClick:l,children:n||`Документ ${t}`}))),Te=a((({className:e,documents:t,relatedEnterprises:a,contacts:i,socialMedia:l,topItems:s,context:c})=>n("footer",{className:`${e} px-9 py-10 bg-white`,children:[n("div",{className:"flex items-stretch gap-32 pb-8 xl:gap-8",children:[r(de,{className:"w-[280px] xl:w-[220px]"}),r(he,{context:c,className:"grow"})]}),n("div",{className:"flex items-stretch gap-32 xl:gap-8",children:[r(xe,{className:"w-[280px] shrink-0 overflow-hidden xl:w-[220px]",items:i,context:c,hasButton:!0}),r($e,{className:"pt-[3px]",context:c,items:s})]}),r(je,{media:l,context:c}),r(be,{links:a,context:c}),r(De,{links:t,context:c})]}))),Ie=[{d:"m9 12 4-4-4-4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",fill:"none"},{d:"M2 9a1 1 0 0 1 0-2v2Zm6-2a1 1 0 0 1 0 2V7ZM2 7h6v2H2V7Z"}],Me=a((({className:e,disabled:t,...n})=>r(b,{rounded:!0,className:`shadow-[0_4px_25px_rgba(0,0,0,0.07)] w-12 h-12 min-h-12 max-h-12 flex items-center justify-center ${t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main"} ${e||""}`,disabled:t,...n,children:r(oe,{paths:Ie,viewBox:"0 0 16 16",fill:"none",width:"16",height:"16"})}))),Ae={normal:"min-w-[364px] w-[364px]",mini:"min-w-[260px] w-[260px]"},Pe={normal:380,mini:276},Be={normal:3,mini:4},Oe=a((({title:e,description:t,context:a,cards:i=[],className:l,version:s="normal"})=>{const[c,o]=a.useState(0);const m=i?.length>Be[s],d=m&&i?.length-c>Be[s],h=m&&c>0;return n("section",{className:`relative font-sans text-primary-text bg-white p-12 overflow-hidden ${l}`,children:[n("div",{className:"flex flex-col items-center mb-8",children:[e?r(k,{className:"font-medium m-0 text-center",children:e}):null,t?r("div",{className:"font-normal text-base max-w-[600px] mt-3",children:t}):null]}),r("div",{className:`flex ${i?.length<=Be[s]?"justify-center":""} duration-1000`,style:{transform:`translateX(-${c*Pe[s]}px)`},role:"list",children:i?.map(((e,t)=>function(e,t,a){return n("div",{className:`box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between items-stretch ${Ae[a]} w-full`,role:"listitem",children:[n("div",{children:[e.image?.src?r("div",{className:"flex justify-center",children:r(v,{className:"mb-6",image:e.image})}):null,e.title?r("h4",{className:"font-medium text-xl m-0 "+(e.description||e.items?.length?"":"text-center"),children:e.title}):null,e.description?r("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description}):null,e.items?.length?r("section",{className:"max-w-[308px] mt-2",role:"list",children:e.items.map(Ve)}):null]}),e.href?r(b,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},String(t))}(e,t,s)))}),h&&r(Me,{className:"absolute top-1/2 left-8 rotate-180",onClick:function(){o(c-1)},ariaLabel:"Пролистать влево"}),d&&r(Me,{className:"absolute top-1/2 right-1 z-10",onClick:function(){o(c+1)},ariaLabel:"Пролистать вправо"}),r("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"})]})}));function Ve(e,t){return r(x,{children:r("span",{className:"text-sm text-secondary-text",children:e})},String(t))}const He=a((e=>r(Oe,{...e,version:"normal"}))),Ze=a((({className:e,text:t,href:a,target:i,active:l,onClick:s,children:c})=>n("a",{className:`relative inline-block bg-transparent text-center no-underline ${e||""}`,href:a,target:i,onClick:s,children:[r("span",{className:`font-sans font-normal text-base ${l?"text-primary-main":"text-primary-text hover:text-primary-main"}`,children:t||c}),l?r("div",{className:"absolute left-0 -bottom-2 w-full h-[2px] bg-primary-main"}):null]}))),Fe=a((({className:e,text:t,href:n,target:a,active:i,flat:l,onClick:s,children:c,ariaLabel:o})=>r("a",{className:`inline-block border border-solid bg-transparent text-center no-underline ${l?"":"px-4 py-2"} ${i?"border-primary-main rounded-md":"border-transparent"} ${e||""}`,href:n,target:a,onClick:s,rel:"noopener noreferrer","aria-label":o,children:r("span",{className:`font-sans font-normal text-sm ${i?"text-primary-main":(l?"text-primary-text":"text-secondary-text")+" hover:text-primary-main"}`,children:t||c})}))),ze=a((({className:e,children:t,ariaLabel:n})=>r("button",{type:"button",className:`border-0 p-0 w-[24px] h-[24px] flex items-center bg-inherit cursor-pointer ${e||""}`,disabled:!0,"aria-label":n,children:t}))),Ee=a((({context:e,className:t,defaultLocation:a=""})=>{const[i,l]=e.useGeolocation(a);return n("div",{className:`flex items-center ${t||""}`,children:[r(Fe,{className:"mr-5",flat:!0,href:"#",text:i,ariaLabel:"Местоположение",onClick:l}),r(Fe,{className:"mr-7",flat:!0,href:"#",text:"Офисы и банкоматы",ariaLabel:"Список всех доступных офисов и банкоматов"}),r(ze,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Поиск по сайту",children:r(N,{name:"LoupeIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),r(ze,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Профиль",children:r(N,{name:"ProfileIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),r(ze,{className:"min-w-[32px] min-h-[32px] fill-secondary-light hover:fill-secondary-hover",ariaLabel:"Дополнительные ссылки",children:r(N,{name:"GridIcon","aria-hidden":"true",className:"h-full",asSVG:!0})})]})}));const Ge=a((({className:e,defaultLocation:t,context:a,topItems:i})=>{const l=a.useRouter(),s=ye(a.useAsyncData),{handlerDecorator:c}=a,o=ve(s.topItems,i),m=o.find(function(e){return t=>_(t.href,e,((e,t)=>t.startsWith(e)))}(l)),d=m?.items,h=d?.find(function(e){return t=>_(t.href,e)}(l)),x=o.map(((e,t)=>r(Fe,{active:e===m,...A({router:l,handlerDecorator:c},e),ariaLabel:e.text},String(t)))),u=d?.map((e=>r(Ze,{className:"mr-8",active:e===h,...A({router:l,handlerDecorator:c},e)},e.href)));return n("header",{className:`pt-5 pb-8 px-20 bg-white ${e||""}`,children:[n("div",{className:"flex items-center",children:[r(de,{className:"mr-8"}),x,r(Ee,{context:a,className:"ml-auto",defaultLocation:t})]}),r("div",{className:"mt-5 h-[1px] bg-main-divider"}),r("nav",{className:"mt-5",children:u})]})})),Ue=a((e=>r(Oe,{...e,version:"mini"}))),We=a((({className:e,context:t,title:a="Мобильное приложение",qr:i,buttons:l=[]})=>r(Z,{className:e,context:t,title:a,buttons:l,children:n("div",{className:"flex items-center",children:[i?.src&&i?.href&&r("a",{href:i.href,target:"_blank",children:r("img",{src:i.src,alt:a,title:a,width:"164",height:"164",className:"w-[90px] h-[90px] min-w-[90px] min-h-[90px] bg-secondary-light"})}),r("span",{className:"font-normal text-sm text-secondary-text ml-4",children:"Наведите камеру телефона на QR-код и скачайте приложение"})]})}))),Je=a((({className:e,context:t,title:a,titleSize:i,description:l,benefits:s,buttons:c,image:o,items:m})=>n("div",{className:`flex grow justify-between items-stretch ${e||""}`,children:[n("div",{className:"flex flex-col",children:[a&&r(k,{size:i||"XL",className:"font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px] text-primary-text",children:a}),r(B,{context:t,description:l,items:m,buttons:c,children:s?.length?r("div",{className:"flex gap-6 mt-6 mb-3.5",children:s.map(Xe)}):null})]}),o?.src&&r(v,{className:"mt-auto",image:o})]})));function Xe(e,t){return n("div",{className:"flex gap-4 items-center",children:[e.icon&&r(N,{className:"w-[50px] h-[50px] min-w-[50px] min-h-[50px] bg-main rounded-full p-[10px] box-border",name:e.icon,width:"24",height:"24"}),n("div",{className:"flex gap-1 flex-col h-full",children:[r("h4",{className:"font-medium text-primary-text text-xl m-0",children:e.label}),e.description&&r("div",{className:"font-normal text-sm text-secondary-text",children:e.description})]})]},String(t))}const Qe=a((({text:e,href:t,target:n,onClick:a,className:i,children:l})=>t?r("a",{className:`no-underline ${i||""}`,href:t,target:n,onClick:a,children:r("span",{className:`${i||""}`,children:e||l})}):r("span",{className:`${i||""}`,children:e||l})));function qe(e){return t=>t.reduce(((t,r,n)=>t.length?t.concat({...e,key:n},r):[r]),[])}const Ke=a((e=>{const{context:t,className:a,breadcrumbs:i}=e,l=t.useRouter(),{handlerDecorator:s}=t;return n("section",{className:`font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${a||""}`,children:[i?.length?r("div",{className:"text-xs mb-6",children:qe(r("span",{className:"text-secondary-text mx-2",children:"/"}))(i.map(((e,t)=>r(Qe,{...A({router:l,handlerDecorator:s},{className:"text-secondary-text",...e})},String(t)))))}):null,r(Je,{...e})]})})),Ye=a((({className:e,context:t,duration:a=0,slides:i=[]})=>{const l=i.map((e=>e.nav)),s=i.map((e=>e.productBlock)),[c,o]=t.useState(0);return n("section",{className:`font-sans bg-white overflow-hidden w-100 ${e||""}`,children:[r("div",{className:"flex duration-1000",style:{transform:`translateX(-${c}00%)`},role:"list",children:s.map(((e,n)=>function(e,t,n){return r("section",{className:"flex grow-0 shrink-0 basis-full",role:"listitem",children:r("div",{className:"p-10 flex grow",children:r(Je,{className:"pl-2.5 pt-2.5 pb-1.5 pr-[6.25rem]",context:n,...e})})},String(t))}(e,n,t)))}),r("div",{className:"border-t border-solid border-main-divider flex",children:l.map(((e,t)=>function({slide:e,i:t,activeSlideIndex:a,onClick:i,duration:l}){const s=t===a,c=s?"animate-slide":"";return n("button",{type:"button",onClick:i,className:"group relative overflow-hidden border-0 bg-inherit cursor-pointer text-left px-0 py-4 grow basis-0",children:[n("div",{className:"border-0 border-r border-solid border-main-divider px-6",children:[r("div",{className:"text-sm font-medium group-hover:text-primary-text "+(s?"text-primary-text":"text-secondary-text"),children:e?.title}),r("div",{className:"text-xs text-secondary-text",children:e.desc})]}),r("div",{className:`absolute bottom-0 left-0 w-full h-[3px] bg-primary-main -translate-x-full ${c}`,style:{animationDuration:`${l}s`}})]},String(t))}({slide:e,i:t,activeSlideIndex:c,onClick:()=>o(t),duration:a})))})]})}));const et=a((e=>{const{benefits:t,version:a}=e;return r(Z,{...e,children:n("div",{className:"flex mt-5 mb-1",children:[t?.length?r("div",{className:"mr-8",children:t.map(tt)}):null,t?.length?r("div",{className:"pt-1",children:t.map(((e,t)=>function(e,t,n="primary"){return r("div",{className:`text-sm ${t?"mt-4":""} ${{primary:"text-secondary-text",secondary:"text-white"}[n]}`,children:e.label},String(t))}(e,t,a)))}):null]})})}));function tt(e,t){return r("div",{className:"text-xl font-medium "+(t?"mt-2.5":""),children:e.description},String(t))}const rt=a((({className:e,context:t,title:a="Акции и спецпредложения",date:i,description:l,buttons:s=[],version:c})=>r(Z,{className:e,context:t,title:a,buttons:s,version:c,children:n("div",{children:[i&&r("div",{className:"text-sm mb-2",children:nt(i)}),r("div",{className:"text-base",children:l})]})})));function nt(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const at=a((({className:e,title:t,steps:a})=>n("section",{className:`font-sans text-primary-text bg-white px-12 py-12 flex flex-col items-center ${e||""}`,children:[r(k,{className:"font-medium m-0 max-w-[47rem] text-center",children:t}),a?.length?n("div",{children:[r("div",{className:"flex mt-9 items-center px-[88px]",children:qe(r("div",{className:"h-0.5 w-full bg-secondary-light"}))(a.map(((e,t)=>it(e,t))))}),r("div",{className:"flex mt-9 justify-between gap-x-24",children:a.map(lt)})]}):null]}))),it=(e,t)=>r("div",{className:"flex flex-col items-center text-center relative",children:r("div",{className:"h-[100px] w-[100px] min-w-[100px] min-h-[100px] bg-secondary-light rounded-full p-[26px] box-border z-10",children:e.icon&&r(N,{name:e.icon,width:"48",height:"48"})||r("span",{className:"font-medium text-title-sm text-secondary-text",children:t+1})})},String(t)),lt=(e,t)=>r("div",{className:"flex flex-col items-center text-center relative w-[276px]",children:n("div",{className:"max-w-min",children:[r("h5",{className:"font-medium text-xl m-0 mt-4 whitespace-nowrap px-3",children:e.label}),e.description&&r("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description})]})},String(t)),st={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"}},ct=a((({title:e,description:t,blockVersion:a="primary",iconVersion:i,image:l,className:s})=>{const c=st[a];return n("section",{className:`font-sans px-9 py-4 flex ${c.background} ${s||""}`,children:[i&&"small"===i?ot(c.icon):null,i&&"big"===i?mt(l):null,n("div",{className:"py-0.5",children:[e&&r("div",{className:`font-medium text-base mb-1 ${c.title}`,children:e}),t&&r("div",{className:`text-sm ${c.description}`,children:t})]})]})}));function ot(e){return r("div",{className:"pt-1.5 pr-4",children:r("div",{className:`rounded-full h-4 w-4 text-center text-xs ${e}`,children:"i"})})}function mt(e){return e?.src?r(v,{className:"pt-0.5 pr-3",image:e}):null}const dt=a((({children:e})=>r("div",{className:"self-start flex flex-col",role:"row",children:r("div",{className:"flex",children:e})}))),ht="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",xt="border-main-stroke border-solid border",ut="border-main-divider border border-t-0 border-x-0",pt="w-[200px] mr-6",ft=a((({children:e,activeCardIndex:t})=>r("div",{className:"flex flex-1 overflow-hidden",children:r("div",{className:"flex gap-4 duration-1000",style:{transform:`translateX(-${336*t}px)`},children:e})}))),bt=a((({icon:e,image:t,title:a,link:i})=>n("div",{className:`w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-12 ${xt} ${ht}`,role:"columnheader",scope:"col",children:[e&&!t?.src&&r(N,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",name:e,width:"63",height:"63"}),t?.src&&r(v,{className:"mb-4",image:t}),a&&r(k,{size:"S",className:"font-medium m-0 text-center text-white",children:a}),i?.text&&r("div",{className:"mt-auto w-full",children:r(b,{href:i.href,target:i.target,className:"mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:r("div",{className:"text-xs py-[11px]",children:i.text})})})]}))),gt=a((({cell:e,isFirstRow:t,isLastRow:n,isFillGradient:a})=>r("div",{className:`w-80 box-border flex flex-col ${xt} ${n?"border-t-0 rounded-b-md":"border-y-0"} ${a?ht:""}`,role:"cell",children:r("div",{className:`mx-7 h-full ${ut} ${a&&t?"border-t":""} ${n?"":"border-solid"}`,children:e.map(((e,t)=>Nt(e,t,a)))})}))),Nt=({label:e,description:t},a,i)=>n("div",{className:"first:pt-7 pt-6 last:pb-7",children:[e&&r("h5",{className:"text-xl font-medium m-0 "+(i?"text-white":""),children:e}),t&&r("div",{className:"text-sm opacity-80 "+(i?"text-white":"text-secondary-text"),children:t})]},String(a)),vt=a((({row:{header:e,data:t},activeCardIndex:a,isColoredFirstColumn:i,isFirstRow:l,isLastRow:s})=>n(dt,{children:[e?.title?r("div",{className:`text-sm py-7 ${ut} w-[200px] mr-6 ${s?"":"border-solid"}`,children:e.title}):null,t?.length?r(ft,{activeCardIndex:a,children:t.map(((e,t)=>r(gt,{cell:e,isFirstRow:l,isLastRow:s,isFillGradient:i&&0===t},String(t))))}):null]}))),yt=a((({className:e,context:t,title:a,rowHeaders:i,columns:l,visibleRowLength:s=0,isColoredFirstColumn:c=!1})=>{const o=t.useRouter(),{handlerDecorator:m}=t,[d,h]=t.useState(0),[x,u]=t.useState(!s),p=l?.map((({header:e})=>e||{})),f=l?.map((({data:e})=>e))||[],b=i?.map(((e,t)=>({header:e,data:f.map((e=>e?.[t]||[{}]))}))).slice(0,x?i.length:s),g=f?.length&&f.length>2,N=g&&f?.length-d>2,v=g&&d>0;return n("section",{className:`bg-white font-sans py-[50px] pl-[50px] overflow-hidden text-primary-text relative ${e||""}`,children:[r(k,{className:"font-medium m-0 max-w-[47rem] text-center mb-9 mx-auto",children:a}),n("div",{role:"table",children:[p?.length?n(dt,{children:[r("div",{className:pt,role:"columnheader",scope:"col"}),r(ft,{activeCardIndex:d,children:p.map(((e,t)=>r(bt,{...e,link:e.link&&A({router:o,handlerDecorator:m},e.link)},String(t))))})]}):null,b?.length?n("div",{className:"relative",children:[b.map(((e,t,{length:n})=>r(vt,{row:e,isFirstRow:0===t,isLastRow:t+1===n,activeCardIndex:d,isColoredFirstColumn:c},String(t)))),g?r("div",{children:n("div",{className:"absolute top-7 right-7 z-10",children:[r(Me,{onClick:()=>h(d+1),disabled:!N,ariaLabel:"Пролистать вправо"}),r(Me,{className:"mt-4 rotate-180",onClick:()=>h(d-1),disabled:!v,ariaLabel:"Пролистать влево"})]})}):null]}):null]}),g?r("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null,s?r("div",{className:"pr-[50px]",children:n("div",{className:"flex w-full",children:[r("div",{className:pt}),r("button",{onClick:()=>u(!x),className:"mt-5 flex-1 border-main-stroke border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:r("div",{className:"font-sans font-medium text-xs py-[11px]",children:x?"Скрыть":"Показать все параметры"})})]})}):null]})})),wt={TextBlock:ct},kt=a((({label:e,blocks:t,context:a})=>{const[i,l]=a.useState(!1),s=t?.length,c=i?"MinusIcon":"PlusIcon";return n("li",{className:"border-0 border-b border-solid border-main-divider last:border-b-0",children:[n("button",{className:"border-none bg-transparent px-0 py-5 flex justify-between text-left w-full font-sans text-primary-text\n "+(s?"group cursor-pointer":""),onClick:e=>{if(!s)return null;l(!i);const t=St(e);t.style.maxHeight=t.style.maxHeight?null:`${t.scrollHeight}px`},children:[r("span",{className:"m-0 text-xl pr-2.5 font-medium "+(s?"group-hover:text-primary-main":""),children:e}),s?r(N,{name:c,width:"24",height:"24"}):null]}),s?r("div",{className:(i?"pb-5":"")+" text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 ",children:t?.length?t.map($t):null}):null]})})),$t=(e,t)=>{if(e.type&&e.data&&!wt.hasOwnProperty(e.type))return null;const n=e.type&&wt[e.type];return r("div",{className:"mb-5 last:mb-0",children:r(n,{...e.data})},`component${t}`)},St=e=>"BUTTON"===e.target.tagName?e.target.nextSibling:e.target.parentNode.nextSibling,Ct=a((({title:e,accordionItems:t,context:a,className:i})=>n("section",{className:`p-[50px] font-sans bg-white text-primary-text ${i||""}`,children:[e?r(k,{className:"m-0 mb-2.5",children:e}):null,t?.length?r("ul",{className:"list-none m-0 p-0",children:t.map(((e,t)=>r(kt,{...e,context:a},`AccordionItem${t}`)))}):null]})));function _t(e,t){const{data:r}=e(jt(t),(()=>async function(e){const t=await fetch(jt(e));return await t.json()}(t)));return r||{}}function jt(e){return`/wcms-resources/${e||"credit-calculator-data"}.json`}const Lt=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],Dt=a((({text:e,checked:t,onChange:a,className:i})=>r("div",{className:i,children:n("label",{className:"flex items-center cursor-pointer relative",children:[r("input",{className:"peer appearance-none w-5 h-5 border-solid border rounded border-black checked:bg-primary-main checked:border-primary-main",type:"checkbox",onChange:e=>{a(e.target.checked)},checked:t}),r(oe,{paths:Lt,className:"hidden absolute left-2 ml-px peer-checked:block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"}),e?r("span",{className:"font-sans ml-2 text-sm cursor-pointer",children:e}):null]})}))),Rt=e=>new Intl.NumberFormat("ru-RU",{maximumSignificantDigits:3}).format(e),Tt=a((({className:e,title:t,items:a=[],min:i=1,max:l=100,step:s=1,value:c=i,onChange:o})=>{const m=e=>{if(!o)return;const t=Number(e.replace(/\D/g,""));o(t)},d={backgroundSize:`${(100*(c-i)/(l-i)).toFixed(2)}% 100%`};return n("div",{className:e,children:[n("div",{className:"relative",children:[t?r("span",{className:"absolute text-xs text-secondary-text top-1 mt-0.5 pl-4 ml-0.5",children:t}):null,r("input",{className:"m-0 font-sans text-sm w-full h-12 border-2 border-solid border-main-divider rounded-md outline-none p-0 pl-4 m-0 box-border text-primary-text "+(t?"pt-4":""),value:Rt(c),onChange:e=>m(e.target.value),onBlur:()=>{o&&(c<i&&o(i),c>l&&o(l))}}),r("div",{className:"absolute inset-x-0 mt-0.5 top-8 px-4",children:r("input",{className:"box-border w-full m-0 cursor-pointer slider",type:"range",min:i,max:l,step:s,value:c,onChange:e=>m(e.target.value),style:d})})]}),r("div",{className:"flex justify-between mt-3 mb-4",children:a.map(((e,t)=>r("span",{className:"text-xs text-secondary-text pl-4",children:e},String(t))))})]})})),It=(e,t,r)=>Math.max(t,Math.min(e,r)),Mt=3e4,At=3e6,Pt=Math.round(41.5),Bt=a((({context:e,className:t,directoryName:a})=>{const[i,l]=e.useState(void 0),[s,c]=e.useState(void 0),[o,m]=e.useState(!0),[d,h]=e.useState(!0),x=(e=>{const{tableRows:t,isAnnuity:r=!1}=e;return t&&t.find((e=>e.isAnnuity===r))||{}})({tableRows:_t(e.useAsyncData,a).rows,isAnnuity:o}),u=x.maxSum&&x.minSum?(x.maxSum-x.minSum)/2:1485e3,p=x.maxMonths&&x.minMonths?Math.round((x.maxMonths-x.minMonths)/2):Pt,f=x?.minSum||Mt,g=x?.maxSum||At,N=x?.minMonths||1,v=x?.maxMonths||84,y=(e=>{const{calculatorParams:t,isInsurance:r}=e;return t?r?t?.rateWithInsurance||5:t?.rateWithoutInsurance||5:5})({calculatorParams:x,isInsurance:d}),w=(e=>{const{calculatorParams:t,paymentType:r,rate:n,sum:a,months:i}=e;if(!t)return 0;const l=It(a,t.minSum||Mt,t.maxSum||At);if("annuity"===r){const e=Number(n)/1200;return l*(e+e/(Math.pow(1+e,i)-1))}return l/i+l*(Number(n)/12)})({calculatorParams:x,paymentType:"annuity",rate:y,sum:i||u,months:s||p}),k=((e,t)=>{const r=Math.ceil((t-e)/12),n=Math.floor(e/12)+1,a=new Array(Math.min(r-1,5)).fill(0).map(((e,t)=>n+t)),i=r+n-1;return a.concat(i)})(N,v);function $(e){c(It(12*e,N,v))}return r("section",{className:`font-sans text-primary-text bg-white p-4 ${t}`,children:n("div",{className:"box-border p-12 flex flex-col justify-between border-solid border-3 border-primary-main rounded-md",children:[n("div",{className:"flex justify-between",children:[n("div",{className:"grow mr-11",children:[r(Tt,{title:"Желаемая сумма кредита, ₽",items:[`От ${Rt(f)} рублей`,`До ${Rt(g)} рублей`],min:f,max:g,step:1e3,value:i||u,onChange:l}),r(Tt,{title:"Срок кредита, месяцев",items:["Или выберите из предложенных вариантов ниже"],min:N,max:v,step:1,value:s||p,onChange:c}),r("div",{className:"flex mb-7",children:k.map(((e,t)=>function(e,t,a){return r("button",{className:"bg-secondary-light rounded-3xl h-10 w-[75px] box-border mr-2 flex items-center justify-center cursor-pointer border-none",onClick:()=>a(e),children:n("span",{className:"font-semibold text-sm",children:[e," ",1===e?"год":e>4?"лет":"года"]})},String(t))}(e,t,$)))}),r(Dt,{text:"Получаю пенсию на карту Россельхозбанка",checked:o,onChange:m}),r(Dt,{className:"mb-4",text:"Комплексная страховая защита",checked:d,onChange:h})]}),n("div",{className:"p-9 bg-primary-main rounded-md text-white",children:[r("div",{className:"text-base mb-5",children:"Наше предложение"}),r("div",{className:"text-sm opacity-60",children:"Ежемесячный платёж"}),n("div",{className:"text-lg mb-3",children:[Rt(Math.round(w))," ₽"]}),r("div",{className:"text-sm opacity-60",children:"Ставка"}),n("div",{className:"text-lg",children:[y," %"]})]})]}),n("div",{className:"flex items-center",children:[r(b,{className:"mr-3",text:"Отправить заявку",version:"primary",href:"#"}),r("div",{className:"w-80 text-xxs leading-4 text-secondary-text","aria-label":"Соглашение на обработку персональных данных",children:"Отправляя заявку, вы соглашаетесь на обработку персональных данных соответственно требованиям ФЗ «О персональных данных»"})]})]})})}));const Ot={Header:Ge,Footer:Te,Placeholder:z,Tile:Z,PromoTile:rt,TextBlock:ct,ProductTile:et,ProductBlock:Ke,StepsBlock:at,BenefitsBlock:q,ProductGallery:Ye,ExchangeRateTile:ne,MobileAppTile:We,Gallery:He,MiniGallery:Ue,ComparisonTable:yt,Accordion:Ct,CreditCalculator:Bt},Vt=a((({className:e,context:t})=>r("footer",{className:`${e} px-9 py-2 bg-white rounded-bl-3xl rounded-br-3xl`,children:r(De,{context:t})}))),Ht=a((({title:e,description:t,cards:a=[],className:i})=>n("section",{className:`relative font-sans text-primary-text bg-white p-4 overflow-hidden ${i}`,children:[n("div",{className:"flex flex-col items-center mb-8",children:[r(k,{className:"font-medium m-0 text-centers",children:e}),t?r("div",{className:"font-normal text-base max-w-[600px] mt-3",children:t}):null]}),r("div",{className:"horizontal-list no-scrollbar",role:"list",children:a?.map(Zt)})]})));function Zt(e,t){return n("div",{className:"box-border horizontal-list-item border-solid border rounded-md border-main-divider p-4 mx-1 flex flex-col justify-between items-stretch",role:"listitem",children:[n("div",{children:[e.image?.src?r("div",{className:"flex justify-center",children:r(v,{className:"mb-6",image:e.image})}):null,e.title?r("h4",{className:"font-medium text-xl m-0 "+(e.description||e.items?.length?"":"text-center"),children:e.title}):null,e.description?r("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description}):null,e.items?.length?Ft(e.items):null]}),e.href?r(b,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},t)}function Ft(e=[]){return r("section",{className:"max-w-[308px] mt-2",role:"list",children:e.map(((e,t)=>r(x,{children:r("span",{className:"text-sm text-secondary-text",children:e})},String(t))))})}const zt=a((({titleSize:e,image:t,benefits:n,...a})=>{const{className:i}=a;return r("section",{className:`font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${i||""}`,children:r(Je,{...a,titleSize:"L"})})})),Et={Header:Ge,Footer:Vt,Placeholder:z,Tile:Z,ProductTile:et,ProductBlock:zt,TextBlock:ct,ExchangeRateTile:ne,MobileAppTile:We,Gallery:Ht};e.Blocks=Ot,e.ContentPage=J,e.ContentPageHead=s,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),r=await fetch(`${e}/geolocate`,{method:"POST",mode:"cors",body:JSON.stringify({lat:t.latitude,lon:t.longitude,count:1})});return(await r.json())?.suggestions?.[0]?.data?.city}catch(e){return console.error(e),null}}}},e.LikeAPI=function(e,t=""){async function r(){try{const e=JSON.parse(globalThis.localStorage.getItem(l)||"");if(e?.token)return e}catch(e){}try{const e=await fetch(`${t}/assist/v1/public/auth`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:r,name:n}=await e.json();return globalThis.localStorage.setItem(l,JSON.stringify({token:r,name:n})),{token:r,name:n}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...n){if(!n.length)return[];const{token:a}=await r();try{const r=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a},body:JSON.stringify({node_ids:n})}),{likes:i}=await r.json();return i||[]}catch(e){return console.error(e),[]}},like:async function(n){if(!n)return 0;const{token:a,name:i}=await r();try{const r=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a,UserID:i},body:JSON.stringify({node_id:n,user_name:i})}),{likes:l}=await r.json();return l||0}catch(e){return console.error(e),0}},dislike:async function(n){if(!n)return 0;const{token:a,name:i}=await r();try{const r=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a,UserID:i},body:JSON.stringify({node_id:n,user_name:i})}),{likes:l}=await r.json();return l||0}catch(e){return console.error(e),0}}}},e.MobileBlocks=Et,e.joinList=qe,e.projectSettings=i,e.setup=t,e.toMobilePage=function(e){const t=e.blocks?.filter((({mobile:e})=>!e?.hidden)).map(Q);return{...e,blocks:t}},e.url=I,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
1
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniBlocks={})}(this,(function(e){"use strict";const t=(e,n)=>{t._jsx=e,t._jsxs=n||e};t.vue=e=>{t(((t,{children:n,dangerouslySetInnerHTML:r,...a}={})=>{const i=Object.assign({},a,r?{innerHTML:r.__html}:{});return e(t,i,"string"!=typeof t?()=>n:n)}))};const n=(...e)=>t._jsx(...e),r=(...e)=>t._jsxs(...e),a=e=>(e._tmpl||(e._tmpl=function(t,n){const{children:r,...a}=t||{},i=n?.slots?.default,l=r||i&&i();return e(Object.assign(a,l&&{children:l}),n)},e._tmpl.inheritAttrs=!1),e._tmpl);const i="likesToken";var l;!function(e){e.XL="text-title-lg",e.L="text-title",e.M="text-title-sm",e.S="text-title-xs"}(l||(l={}));const s=a((({size:e="L",className:t,children:r,...a})=>n("XL"===e?"h1":"h2",{className:c(l[e],t),...a,children:r}))),c=(...e)=>e.filter(Boolean).join(" "),o=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 ENABLE_ASSIST(){return this._.ENABLE_ASSIST}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}},m=a((({className:e,name:t,alt:a=`Icon ${t}`,title:i=a,asSVG:l,...s})=>{const c=`${o.CDN||""}icons/${t}.svg`;return l?r("svg",{className:e,...s,"aria-hidden":"true",children:[i?n("title",{children:i}):null,a?n("desc",{children:a}):null,n("use",{href:`${c}#icon`,xlinkHref:`${c}#icon`})]}):n("img",{className:e,src:c,alt:a,title:i,...s,"aria-hidden":"true"})})),d="/mobile",h=e=>e?.includes("//"),x=(e,t,n=((e,t)=>e===t))=>n(u(e),p(u(h(e)?t.href:t.pathname))),u=e=>(e||"").replace(/\/?\?.*/,""),p=e=>(e||"").replace(d,""),f=e=>{if(!h(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t},b=(e,t)=>{if(!e)return e;const n=g(e,t),r=t?.pathname.startsWith(d);return r&&!h(n)?`/mobile${n}`:n},g=(e,t)=>{if(!e)return e;const n=f(t?.href);return n?e.replace(n,"")||"/":e};var N=Object.freeze({__proto__:null,MOBILE_URL_PATH:d,isURL:h,isHrefActive:x,withoutQuery:u,withoutMobilePath:p,getOrigin:f,adjustHref:b,toRelativeHref:g});const v=(e,t)=>e;function y({router:e,handlerDecorator:t=v},n){const r=b(n.href,e);return{...n,href:r,ariaLabel:n.text,onClick:t((t=>{const a=r&&!h(r),i=!n.target||"_self"===n.target;a&&i&&(t.preventDefault(),e.push(r))}),n)}}const w={primary:"bg-primary-main",secondary:"bg-white"},k={primary:"text-primary-text",secondary:"text-white"},$=a((({className:e,text:t,children:a,version:i="primary"})=>r("div",{className:`inline-block flex ${e||""}`,role:"listitem",children:[n("div",{className:`inline-block w-[8px] h-[8px] min-w-[8px] min-h-[8px] rounded-full mt-2 ${w[i]}`}),n("span",{className:`text-base font-normal font-sans mx-3 ${k[i]}`,children:t||a})]}))),S={primary:"text-white bg-primary-main hover:bg-primary-hover active:bg-primary-active",secondary:"text-primary-main bg-secondary-light hover:bg-secondary-hover active:bg-secondary-active"},C={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text"},L="inline-block text-center font-sans select-none",_=a((({className:e,text:t,aboveText:r,appendLeft:a,href:i,target:l,onClick:s,children:c,disabled:o,rounded:m,version:d="none",ariaLabel:h,...x})=>{const u=c??n(j,{text:t,aboveText:r,appendLeft:a,rounded:m});return o?n("div",{role:"button","aria-disabled":"true","aria-label":h,tabIndex:"-1",className:`${L} ${C[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,children:u}):n("a",{className:`${L} cursor-pointer no-underline ${S[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:s,"aria-label":h,role:i?"link":"button",...x,children:u})})),j=a((({text:e,aboveText:t,appendLeft:a,rounded:i})=>{const l=!e&&!t&&Boolean(a);return r("div",{className:`flex items-center justify-center ${l?"h-12 w-12 min-h-12 min-w-12":"px-8 gap-2 "+(t?"py-2":"py-[13px]")} ${i?"rounded-full":""}`,children:[a||null,l?null:r("div",{children:[n("div",{className:"text-xxs text-left",children:t}),n("div",{className:"text-sm font-medium text-left",children:e})]})]})})),D=a((({className:e,image:t})=>r("picture",{className:`${e||""}`,children:[t.sources?.length?t.sources.map((({src:e,format:t},r)=>n("source",{srcSet:e,type:T(t)},`${r}_${e}`))):null,n("img",{src:t.src,alt:t.alt||t.title,title:t.title,...t?.size})]})));function T(e){return e?`image/${String(e)}`:void 0}const R=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12},M={left:"items-start",center:"items-center",right:"items-end"},I={left:"text-left",center:"text-center",right:"text-right"},A=a((({className:e,context:t,title:a,titleSize:i,description:l,children:c,buttons:o,image:d,items:h,version:x="primary",align:u="left"})=>{const p=t.useRouter(),{handlerDecorator:f}=t;return r("div",{className:`font-sans flex flex-col grow h-full ${M[u]}`,children:[a&&n(s,{size:i||P(e),className:"font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px]",children:a}),r("div",{className:"flex grow justify-between",children:[r("div",{className:`flex flex-col justify-between ${M[u]}`,children:[r("div",{children:[l?n("div",{className:`font-normal text-base max-w-[600px] ${I[u]}`,children:l}):null,c,h?.length?B(h,x):null]}),o?.length?n("div",{className:"flex mt-9 gap-3",children:o.map(((e,t)=>function({icon:e,...t},r){if(!t?.text)return;return n(_,e?{appendLeft:n(m,{name:e,width:"24",height:"24"}),...t}:{...t},String(r))}(y({router:p,handlerDecorator:f},e),t)))}):null]}),d?.src&&n(D,{className:"mt-auto ml-7",image:d})]})]})}));function P(e=""){const t=R(e);return t<=4?"S":t<=8?"M":"L"}function B(e=[],t){return n("section",{className:"max-w-[600px] mt-5",role:"list",children:e.map(((e,r)=>n($,{className:r?"mt-2.5":"",text:e,version:t},String(r))))})}const O=a((({bgColor:e="bg-white",className:t,...r})=>n("section",{className:`p-10 ${e} ${t||""} `,children:n(A,{...r})}))),H={left:"text-left",center:"text-center",right:"text-right"},V={double:"mb-8",single:""},Z={double:"gap-x-5 gap-y-[26px] flex-wrap",single:"gap-3.5 flex-col"},F=a((({className:e,title:t,align:a,documents:i,icon:l,columnsMode:c="double"})=>{const o=Z[c];return r("section",{className:`font-sans p-[50px] bg-white ${e}`,children:[t&&n(s,{className:`font-medium m-0 ${V[c]} ${H[a??"center"]}`,children:t}),n("div",{className:`flex ${o}`,role:"list",children:i?.length?i.map((({text:e,fileSize:t,...a})=>r("a",{className:"group flex items-center text-sm\n text-sm font-sans align-middle items-center text-primary-text no-underline group hover:text-primary-main\n "+("double"===c?"basis-[calc(50%-20px)]":""),role:"listitem",...a,children:[l&&n(m,{className:"mr-3.5",name:l,width:"24px",height:"24px"}),r("span",{children:[e,n("span",{className:"text-secondary-text group-hover:text-primary-main",children:a?.href&&E(z(a.href),t)})]})]}))):null})]})})),z=e=>{if(!e)return"";const t=e.split(".").pop();return!t||t.includes("/")?"":t},E=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),G=a((({className:e,title:t,image:a,benefits:i})=>r("section",{className:`relative font-sans text-primary-text bg-white p-14 ${e}`,children:[n(s,{className:"font-medium m-0 text-center",children:t}),r("div",{className:"flex justify-center mt-9",children:[a?.src&&n(D,{className:"mr-6",image:a}),i?.length?n("div",{className:"flex flex-col",children:i.map(U)}):null]})]})));function U(e,t){return r("div",{className:"flex flex-row mb-8",children:[e.icon&&n(m,{className:"w-[48px] h-[48px] bg-main rounded-full box-border p-[12px]",name:e.icon,width:"48",height:"48"}),r("div",{className:"flex gap-1 flex-col h-full ml-5 max-w-[490px]",children:[n("div",{className:"font-medium text-primary-text text-xl m-0",children:e.label}),e.description&&n("div",{className:"font-normal text-sm text-secondary-text",children:e.description})]})]},String(t))}const W={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"}},J=a((({title:e,description:t,blockVersion:a="primary",iconVersion:i,image:l,className:s})=>{const c=W[a];return r("section",{className:`font-sans px-9 py-4 flex ${c.background} ${s||""}`,children:[i&&"small"===i?X(c.icon):null,i&&"big"===i?Q(l):null,r("div",{className:"py-0.5",children:[e&&n("div",{className:`font-medium text-base mb-1 ${c.title}`,children:e}),t&&n("div",{className:`text-sm ${c.description}`,children:t})]})]})}));function X(e){return n("div",{className:"pt-1.5 pr-4",children:n("div",{className:`rounded-full h-4 w-4 text-center text-xs ${e}`,children:"i"})})}function Q(e){return e?.src?n(D,{className:"pt-0.5 pr-3",image:e}):null}const q={Headline:O,LinkDocs:F,TextBlock:J,PictureText:G},K=a((({label:e,blocks:t,context:a})=>{const[i,l]=a.useState(!1),s=t?.length,c=i?"MinusIcon":"PlusIcon";return r("li",{className:"border-0 border-b border-solid border-main-divider last:border-b-0",children:[r("button",{className:"border-none bg-transparent px-0 py-5 flex justify-between text-left w-full font-sans text-primary-text\n "+(s?"group cursor-pointer":""),onClick:e=>{if(!s)return null;l(!i);const t=ee(e);t.style.maxHeight=t.style.maxHeight?null:`${t.scrollHeight}px`},children:[n("span",{className:"m-0 text-xl pr-2.5 font-medium "+(s?"group-hover:text-primary-main":""),children:e}),s?n(m,{name:c,width:"24",height:"24"}):null]}),s?n("div",{className:(i?"pb-5":"")+" text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 ",children:t?.length?t.map(((e,t)=>Y(e,t,a))):null}):null]})})),Y=(e,t,r)=>{if(!e.type||!e.data||!q.hasOwnProperty(e.type))return null;const a=q[e.type];return n("div",{className:"mb-5 last:mb-0",children:n(a,{context:r,...e.data})},`block_${t}`)},ee=e=>"BUTTON"===e.target.tagName?e.target.nextSibling:e.target.parentNode.nextSibling,te=a((({title:e,accordionItems:t,context:a,className:i})=>r("section",{className:`p-[50px] font-sans bg-white text-primary-text ${i||""}`,children:[e?n(s,{className:"m-0 mb-2.5",children:e}):null,t?.length?n("ul",{className:"list-none m-0 p-0",children:t.map(((e,t)=>n(K,{...e,context:a},`AccordionItem${t}`)))}):null]}))),ne=a((({className:e,title:t,benefits:a})=>r("section",{className:`font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${e||""}`,children:[t?n(s,{className:"font-medium m-0 max-w-[47rem] text-center",children:t}):null,a?.length?n("div",{className:"grid grid-cols-2 gap-5 mt-9",children:a.map(re)}):null]}))),re=(e,t)=>r("div",{className:"flex items-center p-10 gap-5 max-w-[580px]",children:[e.icon&&n(m,{className:"h-[70px] w-[70px] min-w-[70px] min-h-[70px]",name:e.icon,width:"70",height:"70"}),r("div",{children:[n("h3",{className:"font-medium text-xl m-0",children:e.label}),e.description&&n("div",{className:"font-normal text-sm mt-2",children:e.description})]})]},String(t)),ae=a((({className:e,viewBox:t,fill:r="none",width:a,height:i,paths:l,...s})=>n("svg",{xmlns:"http://www.w3.org/2000/svg",className:e,viewBox:t,fill:r,width:a,height:i,children:l.map((({d:e,fill:t,...r},a)=>n("path",{d:e,fill:t||"currentColor",...s,...r},a)))}))),ie=[{d:"m9 12 4-4-4-4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",fill:"none"},{d:"M2 9a1 1 0 0 1 0-2v2Zm6-2a1 1 0 0 1 0 2V7ZM2 7h6v2H2V7Z"}],le=a((({className:e,disabled:t,...r})=>n(_,{rounded:!0,className:`shadow-[0_4px_25px_rgba(0,0,0,0.07)] w-12 h-12 min-h-12 max-h-12 flex items-center justify-center ${t?"bg-secondary-light text-secondary-text":"bg-white text-primary-text hover:text-primary-main"} ${e||""}`,disabled:t,...r,children:n(ae,{paths:ie,viewBox:"0 0 16 16",fill:"none",width:"16",height:"16"})}))),se=a((({children:e})=>n("div",{className:"self-start flex flex-col",role:"row",children:n("div",{className:"flex",children:e})}))),ce="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",oe="border-main-stroke border-solid border",me="border-main-divider border border-t-0 border-x-0",de="w-[200px] mr-6",he=a((({children:e,activeCardIndex:t})=>n("div",{className:"flex flex-1 overflow-hidden",children:n("div",{className:"flex gap-4 duration-1000",style:{transform:`translateX(-${336*t}px)`},children:e})}))),xe=a((({icon:e,image:t,title:a,link:i})=>r("div",{className:`w-80 box-border flex flex-col items-center rounded-t-md border-b-0 px-7 pt-7 pb-12 ${oe} ${ce}`,role:"columnheader",scope:"col",children:[e&&!t?.src&&n(m,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",name:e,width:"63",height:"63"}),t?.src&&n(D,{className:"mb-4",image:t}),a&&n(s,{size:"S",className:"font-medium m-0 text-center text-white",children:a}),i?.text&&n("div",{className:"mt-auto w-full",children:n(_,{href:i.href,target:i.target,className:"mt-4 w-full text-primary-main bg-white hover:bg-secondary-hover active:bg-secondary-active",children:n("div",{className:"text-xs py-[11px]",children:i.text})})})]}))),ue=a((({cell:e,isFirstRow:t,isLastRow:r,isFillGradient:a})=>n("div",{className:`w-80 box-border flex flex-col ${oe} ${r?"border-t-0 rounded-b-md":"border-y-0"} ${a?ce:""}`,role:"cell",children:n("div",{className:`mx-7 h-full ${me} ${a&&t?"border-t":""} ${r?"":"border-solid"}`,children:e.map(((e,t)=>pe(e,t,a)))})}))),pe=({label:e,description:t},a,i)=>r("div",{className:"first:pt-7 pt-6 last:pb-7",children:[e&&n("h5",{className:"text-xl font-medium m-0 "+(i?"text-white":""),children:e}),t&&n("div",{className:"text-sm opacity-80 "+(i?"text-white":"text-secondary-text"),children:t})]},String(a)),fe=a((({row:{header:e,data:t},activeCardIndex:a,isColoredFirstColumn:i,isFirstRow:l,isLastRow:s})=>r(se,{children:[e?.title?n("div",{className:`text-sm py-7 ${me} w-[200px] mr-6 ${s?"":"border-solid"}`,children:e.title}):null,t?.length?n(he,{activeCardIndex:a,children:t.map(((e,t)=>n(ue,{cell:e,isFirstRow:l,isLastRow:s,isFillGradient:i&&0===t},String(t))))}):null]}))),be=a((({className:e,context:t,title:a,rowHeaders:i,columns:l,visibleRowLength:c=0,isColoredFirstColumn:o=!1})=>{const m=t.useRouter(),{handlerDecorator:d}=t,[h,x]=t.useState(0),[u,p]=t.useState(!c),f=l?.map((({header:e})=>e||{})),b=l?.map((({data:e})=>e))||[],g=i?.map(((e,t)=>({header:e,data:b.map((e=>e?.[t]||[{}]))}))).slice(0,u?i.length:c),N=b?.length&&b.length>2,v=N&&b?.length-h>2,w=N&&h>0;return r("section",{className:`bg-white font-sans py-[50px] pl-[50px] overflow-hidden text-primary-text relative ${e||""}`,children:[n(s,{className:"font-medium m-0 max-w-[47rem] text-center mb-9 mx-auto",children:a}),r("div",{role:"table",children:[f?.length?r(se,{children:[n("div",{className:de,role:"columnheader",scope:"col"}),n(he,{activeCardIndex:h,children:f.map(((e,t)=>n(xe,{...e,link:e.link&&y({router:m,handlerDecorator:d},e.link)},String(t))))})]}):null,g?.length?r("div",{className:"relative",children:[g.map(((e,t,{length:r})=>n(fe,{row:e,isFirstRow:0===t,isLastRow:t+1===r,activeCardIndex:h,isColoredFirstColumn:o},String(t)))),N?n("div",{children:r("div",{className:"absolute top-7 right-7 z-10",children:[n(le,{onClick:()=>x(h+1),disabled:!v,ariaLabel:"Пролистать вправо"}),n(le,{className:"mt-4 rotate-180",onClick:()=>x(h-1),disabled:!w,ariaLabel:"Пролистать влево"})]})}):null]}):null]}),N?n("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null,c?n("div",{className:"pr-[50px]",children:r("div",{className:"flex w-full",children:[n("div",{className:de}),n("button",{onClick:()=>p(!u),className:"mt-5 flex-1 border-main-stroke border-solid border text-primary-text bg-white hover:border-primary-main hover:text-primary-main",children:n("div",{className:"font-sans font-medium text-xs py-[11px]",children:u?"Скрыть":"Показать все параметры"})})]})}):null]})}));function ge(e,t){const{data:n}=e(Ne(t),(()=>async function(e){const t=await fetch(Ne(e));return await t.json()}(t)));return n||{}}function Ne(e){return`/wcms-resources/${e||"credit-calculator-data"}.json`}const ve=[{d:"M10.207.793a1 1 0 0 1 0 1.414l-6 6a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L3.5 6.086 8.793.793a1 1 0 0 1 1.414 0Z",fillRule:"evenodd",clipRule:"evenodd",fill:"white"}],ye=a((({text:e,checked:t,onChange:a,className:i})=>n("div",{className:i,children:r("label",{className:"flex items-center cursor-pointer relative",children:[n("input",{className:"peer appearance-none w-5 h-5 border-solid border rounded border-black checked:bg-primary-main checked:border-primary-main",type:"checkbox",onChange:e=>{a(e.target.checked)},checked:t}),n(ae,{paths:ve,className:"hidden absolute left-2 ml-px peer-checked:block",width:"11",height:"9",fill:"white",viewBox:"0 0 11 9"}),e?n("span",{className:"font-sans ml-2 text-sm cursor-pointer",children:e}):null]})}))),we=e=>new Intl.NumberFormat("ru-RU",{maximumSignificantDigits:3}).format(e),ke=a((({className:e,title:t,items:a=[],min:i=1,max:l=100,step:s=1,value:c=i,onChange:o})=>{const m=e=>{if(!o)return;const t=Number(e.replace(/\D/g,""));o(t)},d={backgroundSize:`${(100*(c-i)/(l-i)).toFixed(2)}% 100%`};return r("div",{className:e,children:[r("div",{className:"relative",children:[t?n("span",{className:"absolute text-xs text-secondary-text top-1 mt-0.5 pl-4 ml-0.5",children:t}):null,n("input",{className:"m-0 font-sans text-sm w-full h-12 border-2 border-solid border-main-divider rounded-md outline-none p-0 pl-4 m-0 box-border text-primary-text "+(t?"pt-4":""),value:we(c),onChange:e=>m(e.target.value),onBlur:()=>{o&&(c<i&&o(i),c>l&&o(l))}}),n("div",{className:"absolute inset-x-0 mt-0.5 top-8 px-4",children:n("input",{className:"box-border w-full m-0 cursor-pointer slider",type:"range",min:i,max:l,step:s,value:c,onChange:e=>m(e.target.value),style:d})})]}),n("div",{className:"flex justify-between mt-3 mb-4",children:a.map(((e,t)=>n("span",{className:"text-xs text-secondary-text pl-4",children:e},String(t))))})]})})),$e=(e,t,n)=>Math.max(t,Math.min(e,n)),Se=3e4,Ce=3e6,Le=Math.round(41.5),_e=a((({context:e,className:t,directoryName:a})=>{const[i,l]=e.useState(void 0),[s,c]=e.useState(void 0),[o,m]=e.useState(!0),[d,h]=e.useState(!0),x=(e=>{const{tableRows:t,isAnnuity:n=!1}=e;return t&&t.find((e=>e.isAnnuity===n))||{}})({tableRows:ge(e.useAsyncData,a).rows,isAnnuity:o}),u=x.maxSum&&x.minSum?(x.maxSum-x.minSum)/2:1485e3,p=x.maxMonths&&x.minMonths?Math.round((x.maxMonths-x.minMonths)/2):Le,f=x?.minSum||Se,b=x?.maxSum||Ce,g=x?.minMonths||1,N=x?.maxMonths||84,v=(e=>{const{calculatorParams:t,isInsurance:n}=e;return t?n?t?.rateWithInsurance||5:t?.rateWithoutInsurance||5:5})({calculatorParams:x,isInsurance:d}),y=(e=>{const{calculatorParams:t,paymentType:n,rate:r,sum:a,months:i}=e;if(!t)return 0;const l=$e(a,t.minSum||Se,t.maxSum||Ce);if("annuity"===n){const e=Number(r)/1200;return l*(e+e/(Math.pow(1+e,i)-1))}return l/i+l*(Number(r)/12)})({calculatorParams:x,paymentType:"annuity",rate:v,sum:i||u,months:s||p}),w=((e,t)=>{const n=Math.ceil((t-e)/12),r=Math.floor(e/12)+1,a=new Array(Math.min(n-1,5)).fill(0).map(((e,t)=>r+t)),i=n+r-1;return a.concat(i)})(g,N);function k(e){c($e(12*e,g,N))}return n("section",{className:`font-sans text-primary-text bg-white p-4 ${t}`,children:r("div",{className:"box-border p-12 flex flex-col justify-between border-solid border-3 border-primary-main rounded-md",children:[r("div",{className:"flex justify-between",children:[r("div",{className:"grow mr-11",children:[n(ke,{title:"Желаемая сумма кредита, ₽",items:[`От ${we(f)} рублей`,`До ${we(b)} рублей`],min:f,max:b,step:1e3,value:i||u,onChange:l}),n(ke,{title:"Срок кредита, месяцев",items:["Или выберите из предложенных вариантов ниже"],min:g,max:N,step:1,value:s||p,onChange:c}),n("div",{className:"flex mb-7",children:w.map(((e,t)=>function(e,t,a){return n("button",{className:"bg-secondary-light rounded-3xl h-10 w-[75px] box-border mr-2 flex items-center justify-center cursor-pointer border-none",onClick:()=>a(e),children:r("span",{className:"font-semibold text-sm",children:[e," ",1===e?"год":e>4?"лет":"года"]})},String(t))}(e,t,k)))}),n(ye,{text:"Получаю пенсию на карту Россельхозбанка",checked:o,onChange:m}),n(ye,{className:"mb-4",text:"Комплексная страховая защита",checked:d,onChange:h})]}),r("div",{className:"p-9 bg-primary-main rounded-md text-white",children:[n("div",{className:"text-base mb-5",children:"Наше предложение"}),n("div",{className:"text-sm opacity-60",children:"Ежемесячный платёж"}),r("div",{className:"text-lg mb-3",children:[we(Math.round(y))," ₽"]}),n("div",{className:"text-sm opacity-60",children:"Ставка"}),r("div",{className:"text-lg",children:[v," %"]})]})]}),r("div",{className:"flex items-center",children:[n(_,{className:"mr-3",text:"Отправить заявку",version:"primary",href:"#"}),n("div",{className:"w-80 text-xxs leading-4 text-secondary-text","aria-label":"Соглашение на обработку персональных данных",children:"Отправляя заявку, вы соглашаетесь на обработку персональных данных соответственно требованиям ФЗ «О персональных данных»"})]})]})})}));const je={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},De=a((e=>{const{children:t,className:r,version:a="primary"}=e;return n("section",{className:`font-sans p-9 min-h-[320px] box-border ${r||""} ${je[a]} ${Te(r)} `,children:n(A,{...e,children:t})})}));function Te(e=""){const t=R(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const Re="https://www.cbr-xml-daily.ru/daily_json.js",Me=["USD","EUR"],Ie={USD:"DollarIcon",EUR:"EuroIcon"},Ae=[{text:"Все показатели",href:"https://cbr.ru/currency_base/daily/",version:"secondary"}],Pe=a((({className:e,context:t,title:a})=>{const{data:i}=t.useAsyncData(Re,He);return n(De,{className:e,context:t,title:a||"Курсы обмена валют",buttons:Ae,children:r("table",{children:[n("thead",{children:r("tr",{children:[n(Be,{children:"Валюта"}),n(Be,{className:"pl-11",children:"Курс"})]})}),n("tbody",{children:Me.map((e=>{const t=(i?.Valute||{})[e]?.Value;return r("tr",{children:[n(Oe,{className:"pt-4",children:r("div",{className:"flex items-center",children:[n(m,{name:Ie[e],width:"24",height:"24"}),n("span",{className:"ml-2",children:e})]})}),n(Oe,{className:"pt-4 pl-11",children:Ze(t)})]},e)}))})]})})})),Be=a((({className:e="",children:t})=>n("th",{className:`text-left font-normal text-sm text-secondary-text ${e}`,children:t}))),Oe=a((({className:e="",children:t})=>n("td",{className:`text-left font-normal text-base text-primary-text ${e}`,children:t})));async function He(){const e=await fetch(Re);return await e.json()}const Ve=new Intl.NumberFormat("ru",{style:"currency",currency:"RUB"}),Ze=e=>e?Ve.format(e):"",Fe=["m13.72 25.51 4.42-4.33v-2.95l-4.42 4.32v2.96Zm0-10.98 4.42-4.35V7.41l-4.42 4.31v2.8Zm0 3.63 4.42-4.33v-2.78l-4.42 4.32v2.8ZM12.46 7.44l-.6-.56V0h-.66v6.22l-.58-.57V0h-.67v5l-.59-.58V0H8.7v6.56l4.44 4.33V0h-.67v7.44Zm1.26 14.35 4.42-4.33v-2.78L13.72 19v2.8Zm-5.03-.61 4.44 4.33v-2.96l-4.44-4.32v2.95Zm8.79-16.76-.59.58V0h-.66v5.66l-.6.56V0h-.66v6.87l-.58.57V0h-.67v10.9l4.42-4.34V0h-.66v4.42Zm-8.79 5.76 4.44 4.35v-2.8L8.69 7.4v2.77Zm0 3.65 4.44 4.33v-2.8l-4.44-4.3v2.77Zm0 3.63 4.44 4.33V19l-4.44-4.31v2.78Zm26.37 2.29H24.3a2.25 2.25 0 0 0 .36-1.22 2.32 2.32 0 0 0-2.33-2.31 2.32 2.32 0 0 0-2.31 2.31c0 .5.16.96.43 1.34a.74.74 0 0 0-.33.61c0 .26.14.49.33.62a2.32 2.32 0 0 0-.43 1.34 2.31 2.31 0 0 0 2.31 2.31 2.32 2.32 0 0 0 2.33-2.31c0-.45-.13-.87-.36-1.22h8.01v.49h-.8v.68h.8v.7h-.8v1.3h.8v-.58h1.17v.58h.79v-1.3h-.79v-.7h.79v-.68h-.79v-.5h1.58a.56.56 0 0 0 .56-.56v-.34a.57.57 0 0 0-.56-.56Zm-11.53 2.7a1.2 1.2 0 0 1-2.4 0c0-.24.08-.47.2-.66l.34-.56a.97.97 0 0 1-.34-.75c0-.3.13-.56.33-.74l-.32-.56a1.13 1.13 0 0 1-.2-.66 1.2 1.2 0 0 1 2.4 0c0 .49-.56 1.65-.56 1.65v.62c-.01.01.55 1.17.55 1.66ZM4.67 18.34v2.89c0 2.75 1.2 4.53 1.9 5.21l4.58 4.5c1.28 1.25 1.5 1.66 1.79 2.37v-3.2c0-2.84-1.44-3.94-2.19-4.67-1.73-1.68-2.89-2.8-3.82-3.73a8.98 8.98 0 0 1-2.26-3.37Zm6.08 14.24c-1.73-1.7-2.89-2.8-3.82-3.73a10 10 0 0 1-2.25-2.98v2.49a7.87 7.87 0 0 0 1.89 5.24l4.58 4.47c1.28 1.25 1.5 1.85 1.79 2.55v-3.37c0-2.85-1.45-3.95-2.19-4.67Z","M19.88 5.34c-.32 0-.64 0-.96.02V6.7a18.5 18.5 0 1 1 .95 36.94A18.5 18.5 0 0 1 1.35 25.17c0-5.67 2.55-10.73 6.58-14.13V9.32A19.78 19.78 0 0 0 0 25.17C0 36.12 8.9 45 19.88 45a19.85 19.85 0 0 0 19.86-19.83c0-10.95-8.9-19.83-19.87-19.83Z","M33.93 35.53c.3-.41.6-.85.87-1.3v-2.66h-.87v3.96Zm2.54-4.92c.12-.4.24-.78.34-1.16h-2.88v.7h.43c.77-.02 1.63-.03 2.11.46Zm-19.19-1.27h-.78v7.91h.78v-7.9Z","M14.7 27.83h2.58c.67 0 1.14.14 1.4.4.27.25.4.72.4 1.38v7.4c0 .66-.12 1.12-.4 1.38-.4.41-1.16.41-1.78.41l-.4-.01v3.5l.78.14v-2.88c1.2 0 1.97-.4 2.34-1.22v4.29h.26l.5-.01V29.74c0-.68.13-1.16.4-1.43.25-.27.72-.4 1.37-.4.67 0 1.65-.1 2.16.4.26.27.38.76.38 1.43v3.8h-1.77v-4.06h-.77v12.99c.26-.03.5-.07.77-.12V34.3h1.77v7.64c.36-.1.72-.21 1.08-.34v-7c0-.8.19-1.4 1-1.67l-.9-4.87h1.8l.3 5.31h.22l.3-5.31h1.88l-1.01 4.87c.84.3 1.01.81 1.01 1.66v4.53a16.63 16.63 0 0 0 1.5-1.27v-9.83h5.25l.1-.72H24.93l.17.89c-.38-.72-1.12-1.08-2.2-1.08h-.77c-1.3 0-2.1.52-2.4 1.55-.27-1.08-1.1-1.62-2.46-1.62h-3.36v14.52c.26.09.52.18.78.25V27.84Zm16.29 5.58-.85-.8.85-4.37v5.17Z","M27.66 40.79c.27-.14.55-.28.8-.43v-5.98h-.8v6.4Z"],ze=a((({className:e,href:t,children:a,targetBlank:i})=>r("a",{className:`inline-flex items-center font-sans no-underline ${e||""}`,href:t||"https://rshb.ru/",target:i?"_blank":"_self",children:[n(ae,{className:"text-primary-main w-10",viewBox:"0 0 40 45",paths:Fe.map((e=>({d:e})))}),n("span",{className:"text-black text-base font-medium ml-2.5",children:a||"Россельхозбанк"})]}))),Ee=a((({className:e,context:t})=>{const{term:a,setTerm:i}=t.useSearch();return r("form",{className:`relative ${e||""}`,children:[r("div",{className:"absolute rounded h-full flex items-center justify-center pl-4 max-w-[170px] gap-3.5 pointer-events-none",children:[n("div",{className:"w-[24px] h-[24px]",children:n(m,{name:"LoupeIcon",width:"24",height:"24"})}),!a&&n("span",{className:"font-sans font-normal text-base text-secondary-text",children:"Поиск по сайту"})]}),n("input",{className:"pl-12 w-full font-sans font-normal text-base text-black border border-solid border-main-divider rounded h-full box-border outline-none pr-[6%]",value:a,onChange:e=>i(e.target.value),type:"text",name:"s"}),a&&n("button",{type:"submit",className:"absolute font-sans font-normal text-sm cursor-pointer bg-transparent hover:bg-primary-hover active:bg-primary-active text-primary-main hover:text-white border-none px-5 py-2 rounded top-1 right-1 outline-none",onClick:e=>{e.preventDefault(),console.log("click")},children:"Найти"})]})})),Ge=a((({className:e,items:t,hasButton:a,context:i})=>{const l=i.useRouter(),{handlerDecorator:s}=i;return r("div",{className:`flex flex-col ${e||""}`,children:[t?.length?t.map(Ue):null,a?n(_,{version:"primary",className:"my-4",...y({router:l,handlerDecorator:s},{text:"Обратная связь",href:"/",target:"_blank"})}):null]})})),Ue=(e,t)=>{const{type:a,text:i,description:l}=e;return r("div",{className:"mb-4",children:[n("div",{children:We(a,i)}),n("div",{className:"font-sans text-sm text-secondary-text",children:l})]},String(t))},We=(e,t="")=>{switch(e){case"tel":return n("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`tel:${Je(t)}`,children:t});case"email":return n("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`mailto:${t}`,children:t});default:return n("span",{children:t})}},Je=e=>e.replaceAll(/(\-|\s|\(|\)|\D+)/g,""),Xe=a((({className:e,links:t,context:r})=>{const a=r.useRouter(),{handlerDecorator:i}=r;return n("div",{className:`${e||""}`,children:t?.length?n("div",{className:"flex justify-between items-center gap-5 py-5 border-solid border-x-0 border-y border-y-main-divider",children:t.map(((e,t)=>n(Qe,{index:t,...y({router:a,handlerDecorator:i},e)},String(t))))}):null})})),Qe=a((({className:e,index:t,text:r,href:a,target:i,onClick:l})=>n("a",{className:`font-sans font-normal text-sm text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${e||""}`,href:a,target:i,onClick:l,children:r||`Документ ${t}`})));function qe(e){const{data:t}=e(Ye(),Ke);return t||{}}async function Ke(){const e=await fetch(Ye());return await e.json()}function Ye(){return`/wcms-resources/${o.SITEMAP||"sitemap"}.json`}const et=e=>t=>e?.href===t?.href;function tt(e,t){return(r=e,a=t,(r||[]).map((e=>a?.find(et(e))||e))).concat((n=e,(t||[]).filter((e=>!n?.find(et(e))))));var n,r,a}const nt=a((({className:e,items:t,context:r})=>{const a=tt(qe(r.useAsyncData).topItems,t),i={router:r.useRouter(),handlerDecorator:r.handlerDecorator};return n("div",{className:`flex items-start justify-start gap-11 xl:gap-5 ${e||""}`,children:a?.map(((e,t)=>rt(e,t,i)))})})),rt=(e,t,{router:a,handlerDecorator:i})=>{const{text:l,href:s,items:c,target:o}=e;return r("div",{className:"flex flex-col w-[235px] gap-[14px]",children:[n("a",{className:"block font-sans font-medium text-base text-primary-text no-underline",href:s,target:o||"_self",children:l||`Раздел ${t}`}),c?.map(((e,t)=>n(at,{...y({router:a,handlerDecorator:i},e)},String(t))))]},String(t))},at=a((({text:e,href:t,target:r,index:a})=>n("a",{className:"block font-sans font-normal text-base text-secondary-text hover:text-primary-main no-underline",href:t,target:r||"_self",children:e||`Раздел ${a}`}))),it=[{origins:["t.me","telegram.org"],icon:"TelegramIcon",label:"Телеграм",width:"20px",height:"16px"},{origins:["vk.com"],icon:"VKIcon",label:"ВКонтакте",width:"24px",height:"12px"},{origins:["ok.ru"],icon:"OkIcon",label:"Одноклассники",width:"12px",height:"20px"}],lt=a((({className:e,media:t,context:r})=>{const a=r.useRouter(),{handlerDecorator:i}=r;return n("div",{className:`flex items-end justify-end gap-2 pt-[30px] pb-7 ${e||""}`,children:t?.map(((e,t)=>n(st,{...y({router:a,handlerDecorator:i},e)},String(t))))})})),st=a((({href:e})=>{const{icon:t,label:r,width:a,height:i}=it.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};return t?n(_,{rounded:!0,href:e,target:"_blank",rel:"noopener noreferrer","aria-label":r,className:"border-solid border border-main-divider w-9 h-9 flex items-center justify-center hover:fill-primary-main",appendLeft:n(m,{name:t,width:a,height:i,asSVG:!0})}):null})),ct=a((({className:e,links:t,context:a})=>{const i=a.useRouter(),{handlerDecorator:l}=a;return r("div",{className:`${e||""}`,children:[n("div",{className:"pt-5 pb-[5px]",children:n("span",{className:"font-sans font-normal text-xs text-secondary-text",children:`© 2000-${(new Date).getFullYear()} АО «Россельхозбанк» Генеральная лицензия Банка России № 3349 от 12.08.2015 г.`})}),t?.length?n("div",{className:"flex justify-start items-start gap-5 pt-[5px]",children:t.map(((e,t)=>n(ot,{index:t,...y({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),ot=a((({className:e,index:t,text:r,href:a,target:i,onClick:l})=>n("a",{className:`font-sans font-normal text-xs text-secondary-text visited:text-secondary-text hover:text-primary-text inline-block no-underline max-w-[292px] ${e||""}`,href:a,target:i,onClick:l,children:r||`Документ ${t}`}))),mt=a((({className:e,documents:t,relatedEnterprises:a,contacts:i,socialMedia:l,topItems:s,context:c})=>r("footer",{className:`${e} px-9 py-10 bg-white`,children:[r("div",{className:"flex items-stretch gap-32 pb-8 xl:gap-8",children:[n(ze,{className:"w-[280px] xl:w-[220px]"}),n(Ee,{context:c,className:"grow"})]}),r("div",{className:"flex items-stretch gap-32 xl:gap-8",children:[n(Ge,{className:"w-[280px] shrink-0 overflow-hidden xl:w-[220px]",items:i,context:c,hasButton:!0}),n(nt,{className:"pt-[3px]",context:c,items:s})]}),n(lt,{media:l,context:c}),n(Xe,{links:a,context:c}),n(ct,{links:t,context:c})]}))),dt={normal:"min-w-[364px] w-[364px]",mini:"min-w-[260px] w-[260px]"},ht={normal:380,mini:276},xt={normal:3,mini:4},ut=a((({title:e,description:t,context:a,cards:i=[],className:l,version:c="normal"})=>{const[o,m]=a.useState(0);const d=i?.length>xt[c],h=d&&i?.length-o>xt[c],x=d&&o>0;return r("section",{className:`relative font-sans text-primary-text bg-white p-12 overflow-hidden ${l}`,children:[r("div",{className:"flex flex-col items-center mb-8",children:[e?n(s,{className:"font-medium m-0 text-center",children:e}):null,t?n("div",{className:"font-normal text-base max-w-[600px] mt-3",children:t}):null]}),n("div",{className:`flex ${i?.length<=xt[c]?"justify-center":""} duration-1000`,style:{transform:`translateX(-${o*ht[c]}px)`},role:"list",children:i?.map(((e,t)=>function(e,t,a){return r("div",{className:`box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between items-stretch ${dt[a]} w-full`,role:"listitem",children:[r("div",{children:[e.image?.src?n("div",{className:"flex justify-center",children:n(D,{className:"mb-6",image:e.image})}):null,e.title?n("h4",{className:"font-medium text-xl m-0 "+(e.description||e.items?.length?"":"text-center"),children:e.title}):null,e.description?n("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description}):null,e.items?.length?n("section",{className:"max-w-[308px] mt-2",role:"list",children:e.items.map(pt)}):null]}),e.href?n(_,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},String(t))}(e,t,c)))}),x&&n(le,{className:"absolute top-1/2 left-8 rotate-180",onClick:function(){m(o-1)},ariaLabel:"Пролистать влево"}),h&&n(le,{className:"absolute top-1/2 right-1 z-10",onClick:function(){m(o+1)},ariaLabel:"Пролистать вправо"}),n("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"})]})}));function pt(e,t){return n($,{children:n("span",{className:"text-sm text-secondary-text",children:e})},String(t))}const ft=a((e=>n(ut,{...e,version:"normal"}))),bt=a((({className:e,text:t,href:a,target:i,active:l,onClick:s,children:c})=>r("a",{className:`relative inline-block bg-transparent text-center no-underline ${e||""}`,href:a,target:i,onClick:s,children:[n("span",{className:`font-sans font-normal text-base ${l?"text-primary-main":"text-primary-text hover:text-primary-main"}`,children:t||c}),l?n("div",{className:"absolute left-0 -bottom-2 w-full h-[2px] bg-primary-main"}):null]}))),gt=a((({className:e,text:t,href:r,target:a,active:i,flat:l,onClick:s,children:c,ariaLabel:o})=>n("a",{className:`inline-block border border-solid bg-transparent text-center no-underline ${l?"":"px-4 py-2"} ${i?"border-primary-main rounded-md":"border-transparent"} ${e||""}`,href:r,target:a,onClick:s,rel:"noopener noreferrer","aria-label":o,children:n("span",{className:`font-sans font-normal text-sm ${i?"text-primary-main":(l?"text-primary-text":"text-secondary-text")+" hover:text-primary-main"}`,children:t||c})}))),Nt=a((({className:e,children:t,ariaLabel:r})=>n("button",{type:"button",className:`border-0 p-0 w-[24px] h-[24px] flex items-center bg-inherit cursor-pointer ${e||""}`,disabled:!0,"aria-label":r,children:t}))),vt=a((({context:e,className:t,defaultLocation:a=""})=>{const[i,l]=e.useGeolocation(a);return r("div",{className:`flex items-center ${t||""}`,children:[n(gt,{className:"mr-5",flat:!0,href:"#",text:i,ariaLabel:"Местоположение",onClick:l}),n(gt,{className:"mr-7",flat:!0,href:"#",text:"Офисы и банкоматы",ariaLabel:"Список всех доступных офисов и банкоматов"}),n(Nt,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Поиск по сайту",children:n(m,{name:"LoupeIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),n(Nt,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Профиль",children:n(m,{name:"ProfileIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),n(Nt,{className:"min-w-[32px] min-h-[32px] fill-secondary-light hover:fill-secondary-hover",ariaLabel:"Дополнительные ссылки",children:n(m,{name:"GridIcon","aria-hidden":"true",className:"h-full",asSVG:!0})})]})}));const yt=a((({className:e,defaultLocation:t,context:a,topItems:i})=>{const l=a.useRouter(),s=qe(a.useAsyncData),{handlerDecorator:c}=a,o=tt(s.topItems,i),m=o.find(function(e){return t=>x(t.href,e,((e,t)=>t.startsWith(e)))}(l)),d=m?.items,h=d?.find(function(e){return t=>x(t.href,e)}(l)),u=o.map(((e,t)=>n(gt,{active:e===m,...y({router:l,handlerDecorator:c},e),ariaLabel:e.text},String(t)))),p=d?.map((e=>n(bt,{className:"mr-8",active:e===h,...y({router:l,handlerDecorator:c},e)},e.href)));return r("header",{className:`pt-5 pb-8 px-20 bg-white ${e||""}`,children:[r("div",{className:"flex items-center",children:[n(ze,{className:"mr-8"}),u,n(vt,{context:a,className:"ml-auto",defaultLocation:t})]}),n("div",{className:"mt-5 h-[1px] bg-main-divider"}),n("nav",{className:"mt-5",children:p})]})})),wt=a((e=>n(ut,{...e,version:"mini"}))),kt=a((({className:e,context:t,title:a="Мобильное приложение",qr:i,buttons:l=[]})=>n(De,{className:e,context:t,title:a,buttons:l,children:r("div",{className:"flex items-center",children:[i?.src&&i?.href&&n("a",{href:i.href,target:"_blank",children:n("img",{src:i.src,alt:a,title:a,width:"164",height:"164",className:"w-[90px] h-[90px] min-w-[90px] min-h-[90px] bg-secondary-light"})}),n("span",{className:"font-normal text-sm text-secondary-text ml-4",children:"Наведите камеру телефона на QR-код и скачайте приложение"})]})}))),$t=a((({className:e,context:t,title:r})=>n(De,{className:e,context:t,title:r,description:"Блок в разработке...",children:n("figure",{className:"m-0 min-w-[600px]",children:St()})}))),St=(e=3)=>Lt(100,e).map((e=>Math.floor(e))).map(Ct),Ct=(e=100,t)=>n("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),Lt=(e,t)=>[e].concat(t>0?Lt(e/1.618,t-1):[]),_t=a((({className:e,context:t,title:a,titleSize:i,description:l,benefits:c,buttons:o,image:m,items:d})=>r("div",{className:`flex grow justify-between items-stretch ${e||""}`,children:[r("div",{className:"flex flex-col",children:[a&&n(s,{size:i||"XL",className:"font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px] text-primary-text",children:a}),n(A,{context:t,description:l,items:d,buttons:o,children:c?.length?n("div",{className:"flex gap-6 mt-6 mb-3.5",children:c.map(jt)}):null})]}),m?.src&&n(D,{className:"mt-auto",image:m})]})));function jt(e,t){return r("div",{className:"flex gap-4 items-center",children:[e.icon&&n(m,{className:"w-[50px] h-[50px] min-w-[50px] min-h-[50px] bg-main rounded-full p-[10px] box-border",name:e.icon,width:"24",height:"24"}),r("div",{className:"flex gap-1 flex-col h-full",children:[n("h4",{className:"font-medium text-primary-text text-xl m-0",children:e.label}),e.description&&n("div",{className:"font-normal text-sm text-secondary-text",children:e.description})]})]},String(t))}const Dt=a((({text:e,href:t,target:r,onClick:a,className:i,children:l})=>t?n("a",{className:`no-underline ${i||""}`,href:t,target:r,onClick:a,children:n("span",{className:`${i||""}`,children:e||l})}):n("span",{className:`${i||""}`,children:e||l})));function Tt(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])}const Rt=a((e=>{const{context:t,className:a,breadcrumbs:i}=e,l=t.useRouter(),{handlerDecorator:s}=t;return r("section",{className:`font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${a||""}`,children:[i?.length?n("div",{className:"text-xs mb-6",children:Tt(n("span",{className:"text-secondary-text mx-2",children:"/"}))(i.map(((e,t)=>n(Dt,{...y({router:l,handlerDecorator:s},{className:"text-secondary-text",...e})},String(t)))))}):null,n(_t,{...e})]})})),Mt=a((({className:e,context:t,duration:a=0,slides:i=[]})=>{const l=i.map((e=>e.nav)),s=i.map((e=>e.productBlock)),[c,o]=t.useState(0);return r("section",{className:`font-sans bg-white overflow-hidden w-100 ${e||""}`,children:[n("div",{className:"flex duration-1000",style:{transform:`translateX(-${c}00%)`},role:"list",children:s.map(((e,r)=>function(e,t,r){return n("section",{className:"flex grow-0 shrink-0 basis-full",role:"listitem",children:n("div",{className:"p-10 flex grow",children:n(_t,{className:"pl-2.5 pt-2.5 pb-1.5 pr-[6.25rem]",context:r,...e})})},String(t))}(e,r,t)))}),n("div",{className:"border-t border-solid border-main-divider flex",children:l.map(((e,t)=>function({slide:e,i:t,activeSlideIndex:a,onClick:i,duration:l}){const s=t===a,c=s?"animate-slide":"";return r("button",{type:"button",onClick:i,className:"group relative overflow-hidden border-0 bg-inherit cursor-pointer text-left px-0 py-4 grow basis-0",children:[r("div",{className:"border-0 border-r border-solid border-main-divider px-6",children:[n("div",{className:"text-sm font-medium group-hover:text-primary-text "+(s?"text-primary-text":"text-secondary-text"),children:e?.title}),n("div",{className:"text-xs text-secondary-text",children:e.desc})]}),n("div",{className:`absolute bottom-0 left-0 w-full h-[3px] bg-primary-main -translate-x-full ${c}`,style:{animationDuration:`${l}s`}})]},String(t))}({slide:e,i:t,activeSlideIndex:c,onClick:()=>o(t),duration:a})))})]})}));const It=a((e=>{const{benefits:t,version:a}=e;return n(De,{...e,children:r("div",{className:"flex mt-5 mb-1",children:[t?.length?n("div",{className:"mr-8",children:t.map(At)}):null,t?.length?n("div",{className:"pt-1",children:t.map(((e,t)=>function(e,t,r="primary"){return n("div",{className:`text-sm ${t?"mt-4":""} ${{primary:"text-secondary-text",secondary:"text-white"}[r]}`,children:e.label},String(t))}(e,t,a)))}):null]})})}));function At(e,t){return n("div",{className:"text-xl font-medium "+(t?"mt-2.5":""),children:e.description},String(t))}const Pt=a((({className:e,context:t,title:a="Акции и спецпредложения",date:i,description:l,buttons:s=[],version:c})=>n(De,{className:e,context:t,title:a,buttons:s,version:c,children:r("div",{children:[i&&n("div",{className:"text-sm mb-2",children:Bt(i)}),n("div",{className:"text-base",children:l})]})})));function Bt(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const Ot=a((({className:e,title:t,steps:a})=>r("section",{className:`font-sans text-primary-text bg-white px-12 py-12 flex flex-col items-center ${e||""}`,children:[n(s,{className:"font-medium m-0 max-w-[47rem] text-center",children:t}),a?.length?r("div",{children:[n("div",{className:"flex mt-9 items-center px-[88px]",children:Tt(n("div",{className:"h-0.5 w-full bg-secondary-light"}))(a.map(((e,t)=>Ht(e,t))))}),n("div",{className:"flex mt-9 justify-between gap-x-24",children:a.map(Vt)})]}):null]}))),Ht=(e,t)=>n("div",{className:"flex flex-col items-center text-center relative",children:n("div",{className:"h-[100px] w-[100px] min-w-[100px] min-h-[100px] bg-secondary-light rounded-full p-[26px] box-border z-10",children:e.icon&&n(m,{name:e.icon,width:"48",height:"48"})||n("span",{className:"font-medium text-title-sm text-secondary-text",children:t+1})})},String(t)),Vt=(e,t)=>n("div",{className:"flex flex-col items-center text-center relative w-[276px]",children:r("div",{className:"max-w-min",children:[n("h5",{className:"font-medium text-xl m-0 mt-4 whitespace-nowrap px-3",children:e.label}),e.description&&n("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description})]})},String(t)),Zt={Accordion:te,BenefitsBlock:ne,ComparisonTable:be,CreditCalculator:_e,ExchangeRateTile:Pe,Footer:mt,Gallery:ft,Header:yt,Headline:O,LinkDocs:F,MiniGallery:wt,MobileAppTile:kt,PictureText:G,Placeholder:$t,ProductBlock:Rt,ProductGallery:Mt,ProductTile:It,PromoTile:Pt,StepsBlock:Ot,TextBlock:J,Tile:De},Ft=a((({className:e,onClick:t,ariaLabel:r})=>n("button",{type:"button",className:`border-0 w-[36px] bg-inherit cursor-pointer ${e||""}`,onClick:t,"aria-label":r,children:zt()}))),zt=()=>{const e={stroke:"#292D32",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5"};return r("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[n("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"}),n("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"})]})},Et=a((({className:e,context:t})=>{const a=t.useLikeService();return r("div",{className:`border-main border-2 border-solid bg-white flex w-[125px] items-center justify-center gap-3 p-2 font-sans ${e||""}`,children:[n(Ft,{onClick:a.like,ariaLabel:"Поставить отметку «лайк»"}),n(Ft,{onClick:a.dislike,className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),n("span",{className:"select-none",children:a.likeCount})]})})),Gt=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),Ut=a((({className:e,context:t,blocksRegistry:a,data:{style:i,blocks:l,likeControl:s,colorPalette:c="pc"},blockDecorator:o=Gt})=>r("section",{className:"relative","data-theme":c,children:[n("div",{className:`grid grid-cols-12 gap-1 ${Wt(i)} ${e||""}`,children:l?.length?l.map((function e(r,i){const{type:l}=r;l in a||console.warn(`No block with "${l}" is registered`);const s=a[l]||$t;return o({blockClassName:Wt(r.style),block:r,render:r=>{const{version:a,content:c,blocks:o}=r.block;return n(s,{className:r.blockClassName,version:a,context:t,...c,children:o?.length?o.map(e):null},`${l}-${i}`)}},`block-${i}`)})):null}),s&&n("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:n(Et,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:t})})]})));function Wt(e){return e?e.join(" "):""}const Jt=a((({HeadComponent:e,data:t,children:a})=>{const{title:i,description:l,keywords:s,robots:c,og:o}=t;return r(e,{children:[n("title",{children:i}),n("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),l&&n("meta",{name:"description",content:l}),s&&n("meta",{name:"keywords",content:s.join(",")}),c&&n("meta",{name:"robots",content:c.join(",")}),o?Object.entries(o).map((([e,t])=>n("meta",{name:`og:${e}`,content:t},e))):null,a]})}));function Xt(e){const{mobile:t}=e;return t?{...e,style:t.style?.length?t.style:e.style}:e}const Qt=a((({className:e,context:t})=>n("footer",{className:`${e} px-9 py-2 bg-white rounded-bl-3xl rounded-br-3xl`,children:n(ct,{context:t})}))),qt=a((({title:e,description:t,cards:a=[],className:i})=>r("section",{className:`relative font-sans text-primary-text bg-white p-4 overflow-hidden ${i}`,children:[r("div",{className:"flex flex-col items-center mb-8",children:[n(s,{className:"font-medium m-0 text-centers",children:e}),t?n("div",{className:"font-normal text-base max-w-[600px] mt-3",children:t}):null]}),n("div",{className:"horizontal-list no-scrollbar",role:"list",children:a?.map(Kt)})]})));function Kt(e,t){return r("div",{className:"box-border horizontal-list-item border-solid border rounded-md border-main-divider p-4 mx-1 flex flex-col justify-between items-stretch",role:"listitem",children:[r("div",{children:[e.image?.src?n("div",{className:"flex justify-center",children:n(D,{className:"mb-6",image:e.image})}):null,e.title?n("h4",{className:"font-medium text-xl m-0 "+(e.description||e.items?.length?"":"text-center"),children:e.title}):null,e.description?n("div",{className:"font-normal text-sm text-secondary-text mt-2",children:e.description}):null,e.items?.length?Yt(e.items):null]}),e.href?n(_,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},t)}function Yt(e=[]){return n("section",{className:"max-w-[308px] mt-2",role:"list",children:e.map(((e,t)=>n($,{children:n("span",{className:"text-sm text-secondary-text",children:e})},String(t))))})}const en=a((({titleSize:e,image:t,benefits:r,...a})=>{const{className:i}=a;return n("section",{className:`font-sans bg-white pt-10 pl-[50px] pb-[50px] pr-[7.5rem] ${i||""}`,children:n(_t,{...a,titleSize:"L"})})})),tn={ExchangeRateTile:Pe,Footer:Qt,Gallery:qt,Header:yt,Headline:O,MobileAppTile:kt,PictureText:G,Placeholder:$t,ProductBlock:en,ProductTile:It,TextBlock:J,Tile:De};e.Blocks=Zt,e.ContentPage=Ut,e.ContentPageHead=Jt,e.DaDataAPI=function(e=""){return{getFetcherAddress:async function(){if(!("geolocation"in navigator))return null;try{const t=await(async()=>new Promise((e=>navigator.geolocation.getCurrentPosition((({coords:t})=>e(t))))))(),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}}}},e.LikeAPI=function(e,t=""){async function n(){try{const e=JSON.parse(globalThis.localStorage.getItem(i)||"");if(e?.token)return e}catch(e){}try{const e=await fetch(`${t}/assist/v1/public/auth`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json"},body:JSON.stringify({prefix:"guest"})}),{token:n,name:r}=await e.json();return globalThis.localStorage.setItem(i,JSON.stringify({token:n,name:r})),{token:n,name:r}}catch(e){return console.error(e),{}}}return{getLikeCount:async function(...r){if(!r.length)return[];const{token:a}=await n();try{const n=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/likes`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a},body:JSON.stringify({node_ids:r})}),{likes:i}=await n.json();return i||[]}catch(e){return console.error(e),[]}},like:async function(r){if(!r)return 0;const{token:a,name:i}=await n();try{const n=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/like`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a,UserID:i},body:JSON.stringify({node_id:r,user_name:i})}),{likes:l}=await n.json();return l||0}catch(e){return console.error(e),0}},dislike:async function(r){if(!r)return 0;const{token:a,name:i}=await n();try{const n=await fetch(`${t}/assist/v1/public/projects/${e}/nodes/unlike`,{method:"POST",mode:"cors",headers:{"Content-Type":"application/json",Authorization:a,UserID:i},body:JSON.stringify({node_id:r,user_name:i})}),{likes:l}=await n.json();return l||0}catch(e){return console.error(e),0}}}},e.MobileBlocks=tn,e.joinList=Tt,e.projectSettings=o,e.setup=t,e.toMobilePage=function(e){const t=e.blocks?.filter((({mobile:e})=>!e?.hidden)).map(Xt);return{...e,blocks:t}},e.url=N,Object.defineProperty(e,"__esModule",{value:!0})}));
|
|
@@ -2,8 +2,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
2
2
|
exports.Accordion = 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 AccordionItem_1 = require("./AccordionItem");
|
|
6
5
|
const Title_1 = require("../../ui-kit/Title/Title");
|
|
6
|
+
const AccordionItem_1 = require("./AccordionItem");
|
|
7
7
|
exports.Accordion = (0, uni_jsx_1.JSX)(({ title, accordionItems, context, className }) => {
|
|
8
8
|
return ((0, jsx_runtime_1.jsxs)("section", { className: `p-[50px] font-sans bg-white text-primary-text ${className || ''}`, children: [title ? (0, jsx_runtime_1.jsx)(Title_1.Title, { className: "m-0 mb-2.5", children: title }) : null, accordionItems?.length ? ((0, jsx_runtime_1.jsx)("ul", { className: "list-none m-0 p-0", children: accordionItems.map((item, i) => ((0, jsx_runtime_1.jsx)(AccordionItem_1.AccordionItem, { ...item, context: context }, `AccordionItem${i}`))) })) : null] }));
|
|
9
9
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Accordion.js","sourceRoot":"","sources":["../../../src/components/Accordion/Accordion.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;
|
|
1
|
+
{"version":3,"file":"Accordion.js","sourceRoot":"","sources":["../../../src/components/Accordion/Accordion.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,oDAAiD;AAEjD,mDAAgD;AAInC,QAAA,SAAS,GAAG,IAAA,aAAG,EAAiB,CAAC,EAAE,KAAK,EAAE,cAAc,EAAE,OAAO,EAAE,SAAS,EAAE,EAAE,EAAE;IAC7F,OAAO,CACL,qCAAS,SAAS,EAAE,iDAAiD,SAAS,IAAI,EAAE,EAAE,aACnF,KAAK,CAAC,CAAC,CAAC,uBAAC,aAAK,IAAC,SAAS,EAAC,YAAY,YAAE,KAAK,GAAS,CAAC,CAAC,CAAC,IAAI,EAC5D,cAAc,EAAE,MAAM,CAAC,CAAC,CAAC,CACxB,+BAAI,SAAS,EAAC,mBAAmB,YAC9B,cAAc,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC,CAC/B,uBAAC,6BAAa,OAA+B,IAAI,EAAE,OAAO,EAAE,OAAO,IAA/C,gBAAgB,CAAC,EAAE,CAAgC,CACxE,CAAC,GACC,CACN,CAAC,CAAC,CAAC,IAAI,IACA,CACX,CAAC;AACJ,CAAC,CAAC,CAAC"}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
declare const AccordionBlocks: {
|
|
2
|
+
Headline: (props: import("@redneckz/uni-jsx").PropsWithChildren<import("../Headline/Headline").HeadlineProps, any>, context?: any) => any;
|
|
3
|
+
LinkDocs: (props: import("@redneckz/uni-jsx").PropsWithChildren<import("../LinkDocs/LinkDocs").LinkDocsProps, any>, context?: any) => any;
|
|
2
4
|
TextBlock: (props: import("@redneckz/uni-jsx").PropsWithChildren<import("../TextBlock/TextBlock").TextBlockProps, any>, context?: any) => any;
|
|
5
|
+
PictureText: (props: import("@redneckz/uni-jsx").PropsWithChildren<import("../PictureText/PictureText").PictureTextProps, any>, context?: any) => any;
|
|
3
6
|
};
|
|
4
7
|
export default AccordionBlocks;
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2
|
+
const Headline_1 = require("../Headline/Headline");
|
|
3
|
+
const LinkDocs_1 = require("../LinkDocs/LinkDocs");
|
|
4
|
+
const PictureText_1 = require("../PictureText/PictureText");
|
|
2
5
|
const TextBlock_1 = require("../TextBlock/TextBlock");
|
|
3
6
|
const AccordionBlocks = {
|
|
7
|
+
Headline: Headline_1.Headline,
|
|
8
|
+
LinkDocs: LinkDocs_1.LinkDocs,
|
|
4
9
|
TextBlock: TextBlock_1.TextBlock,
|
|
10
|
+
PictureText: PictureText_1.PictureText,
|
|
5
11
|
};
|
|
6
12
|
exports.default = AccordionBlocks;
|
|
7
13
|
//# sourceMappingURL=AccordionBlocks.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionBlocks.js","sourceRoot":"","sources":["../../../src/components/Accordion/AccordionBlocks.tsx"],"names":[],"mappings":";AAAA,sDAAmD;AAEnD,MAAM,eAAe,GAAG;IACtB,SAAS,EAAT,qBAAS;
|
|
1
|
+
{"version":3,"file":"AccordionBlocks.js","sourceRoot":"","sources":["../../../src/components/Accordion/AccordionBlocks.tsx"],"names":[],"mappings":";AAAA,mDAAgD;AAChD,mDAAgD;AAChD,4DAAyD;AACzD,sDAAmD;AAEnD,MAAM,eAAe,GAAG;IACtB,QAAQ,EAAR,mBAAQ;IACR,QAAQ,EAAR,mBAAQ;IACR,SAAS,EAAT,qBAAS;IACT,WAAW,EAAX,yBAAW;CACZ,CAAC;AAEF,kBAAe,eAAe,CAAC"}
|
|
@@ -1,14 +1,41 @@
|
|
|
1
|
+
import type { HeadlineContent } from '../Headline/HeadlineContent';
|
|
2
|
+
import type { LinkDocsContent } from '../LinkDocs/LinkDocsContent';
|
|
3
|
+
import type { PictureTextContent } from '../PictureText/PictureTextContent';
|
|
1
4
|
import type { TextBlockContent } from '../TextBlock/TextBlockContent';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
+
import AccordionBlocks from './AccordionBlocks';
|
|
6
|
+
/**
|
|
7
|
+
* @hidden
|
|
8
|
+
* @title Содержимое блока
|
|
9
|
+
*/
|
|
10
|
+
export declare type AccordionData = HeadlineContent | LinkDocsContent | TextBlockContent | PictureTextContent;
|
|
11
|
+
/**
|
|
12
|
+
* @hidden
|
|
13
|
+
* @title Тип блока
|
|
14
|
+
* @enumNames ["Заголовок", "Блок документов", Текстовый блок", "Картинка с текстом"]
|
|
15
|
+
*/
|
|
16
|
+
export declare type AccordionTypeBlock = keyof typeof AccordionBlocks;
|
|
17
|
+
/**
|
|
18
|
+
* Блок
|
|
19
|
+
*/
|
|
20
|
+
export interface AccordionBlock {
|
|
21
|
+
type?: AccordionTypeBlock;
|
|
22
|
+
data?: AccordionData;
|
|
5
23
|
}
|
|
6
|
-
|
|
24
|
+
/**
|
|
25
|
+
* @title Элемент списка
|
|
26
|
+
*/
|
|
27
|
+
export interface AccordionItemCommonProps {
|
|
28
|
+
/** @title Название */
|
|
7
29
|
label?: string;
|
|
8
|
-
|
|
30
|
+
/** @title Блоки */
|
|
31
|
+
blocks?: AccordionBlock[];
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* @title Аккордеон
|
|
35
|
+
*/
|
|
36
|
+
export interface AccordionContent {
|
|
37
|
+
/** @title Заголовок */
|
|
38
|
+
title?: string;
|
|
39
|
+
/** @title Список */
|
|
40
|
+
accordionItems?: AccordionItemCommonProps[];
|
|
9
41
|
}
|
|
10
|
-
export declare type AccordionBlockContent = {
|
|
11
|
-
type?: string;
|
|
12
|
-
data?: AccordionDataContent;
|
|
13
|
-
};
|
|
14
|
-
export declare type AccordionDataContent = TextBlockContent;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { UniBlockProps } from '../../types';
|
|
2
|
-
import type {
|
|
3
|
-
export interface AccordionItemProps extends
|
|
2
|
+
import type { AccordionItemCommonProps } from './AccordionContent';
|
|
3
|
+
export interface AccordionItemProps extends AccordionItemCommonProps, UniBlockProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const AccordionItem: (props: import("@redneckz/uni-jsx").PropsWithChildren<AccordionItemProps, any>, context?: any) => any;
|
|
@@ -21,15 +21,14 @@ exports.AccordionItem = (0, uni_jsx_1.JSX)(({ label, blocks, context }) => {
|
|
|
21
21
|
: `${contentBlock.scrollHeight}px`;
|
|
22
22
|
};
|
|
23
23
|
return ((0, jsx_runtime_1.jsxs)("li", { className: "border-0 border-b border-solid border-main-divider last:border-b-0", children: [(0, jsx_runtime_1.jsxs)("button", { className: `border-none bg-transparent px-0 py-5 flex justify-between text-left w-full font-sans text-primary-text
|
|
24
|
-
${hasContent ? 'group cursor-pointer' : ''}`, onClick: handleToggle, children: [(0, jsx_runtime_1.jsx)("span", { className: `m-0 text-xl pr-2.5 font-medium ${hasContent ? 'group-hover:text-primary-main' : ''}`, children: label }), hasContent ? (0, jsx_runtime_1.jsx)(Icon_1.Icon, { name: icon, width: "24", height: "24" }) : null] }), hasContent ? ((0, jsx_runtime_1.jsx)("div", { className: `${isActive ? 'pb-5' : ''} text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 `, children: blocks?.length ? blocks.map(
|
|
24
|
+
${hasContent ? 'group cursor-pointer' : ''}`, onClick: handleToggle, children: [(0, jsx_runtime_1.jsx)("span", { className: `m-0 text-xl pr-2.5 font-medium ${hasContent ? 'group-hover:text-primary-main' : ''}`, children: label }), hasContent ? (0, jsx_runtime_1.jsx)(Icon_1.Icon, { name: icon, width: "24", height: "24" }) : null] }), hasContent ? ((0, jsx_runtime_1.jsx)("div", { className: `${isActive ? 'pb-5' : ''} text-sm transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0 `, children: blocks?.length ? blocks.map((block, i) => renderBlock(block, i, context)) : null })) : null] }));
|
|
25
25
|
});
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
if (block.type && block.data && !AccordionBlocks_1.default.hasOwnProperty(block.type)) {
|
|
26
|
+
const renderBlock = (block, i, context) => {
|
|
27
|
+
if (!block.type || !block.data || !AccordionBlocks_1.default.hasOwnProperty(block.type)) {
|
|
29
28
|
return null;
|
|
30
29
|
}
|
|
31
|
-
const AccordionBlock =
|
|
32
|
-
return ((0, jsx_runtime_1.jsx)("div", { className: "mb-5 last:mb-0", children: (0, jsx_runtime_1.jsx)(AccordionBlock, { ...block.data }) }, `
|
|
30
|
+
const AccordionBlock = AccordionBlocks_1.default[block.type];
|
|
31
|
+
return ((0, jsx_runtime_1.jsx)("div", { className: "mb-5 last:mb-0", children: (0, jsx_runtime_1.jsx)(AccordionBlock, { context: context, ...block.data }) }, `block_${i}`));
|
|
33
32
|
};
|
|
34
33
|
const getContentBlock = (e) => e.target.tagName === 'BUTTON' ? e.target.nextSibling : e.target.parentNode.nextSibling;
|
|
35
34
|
//# sourceMappingURL=AccordionItem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionItem.js","sourceRoot":"","sources":["../../../src/components/Accordion/AccordionItem.tsx"],"names":[],"mappings":";;;;;;AAAA,+CAAwC;
|
|
1
|
+
{"version":3,"file":"AccordionItem.js","sourceRoot":"","sources":["../../../src/components/Accordion/AccordionItem.tsx"],"names":[],"mappings":";;;;;;AAAA,+CAAwC;AAExC,iDAA8C;AAG9C,wEAAgD;AAKnC,QAAA,aAAa,GAAG,IAAA,aAAG,EAAqB,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE,EAAE;IAClF,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IACxD,MAAM,UAAU,GAAG,MAAM,EAAE,MAAM,CAAC;IAClC,MAAM,IAAI,GAAG,QAAQ,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,UAAU,CAAC;IAEjD,MAAM,YAAY,GAAG,CAAC,CAAC,EAAE,EAAE;QACzB,IAAI,CAAC,UAAU;YAAE,OAAO,IAAI,CAAC;QAC7B,WAAW,CAAC,CAAC,QAAQ,CAAC,CAAC;QACvB,MAAM,YAAY,GAAG,eAAe,CAAC,CAAC,CAAC,CAAC;QACxC,YAAY,CAAC,KAAK,CAAC,SAAS,GAAG,YAAY,CAAC,KAAK,CAAC,SAAS;YACzD,CAAC,CAAC,IAAI;YACN,CAAC,CAAC,GAAG,YAAY,CAAC,YAAY,IAAI,CAAC;IACvC,CAAC,CAAC;IAEF,OAAO,CACL,gCAAI,SAAS,EAAC,oEAAoE,aAChF,oCACE,SAAS,EAAE;UACT,UAAU,CAAC,CAAC,CAAC,sBAAsB,CAAC,CAAC,CAAC,EAAE,EAAE,EAC5C,OAAO,EAAE,YAAY,aAErB,iCACE,SAAS,EAAE,kCACT,UAAU,CAAC,CAAC,CAAC,+BAA+B,CAAC,CAAC,CAAC,EACjD,EAAE,YAED,KAAK,GACD,EACN,UAAU,CAAC,CAAC,CAAC,uBAAC,WAAI,IAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,GAAG,CAAC,CAAC,CAAC,IAAI,IACzD,EACR,UAAU,CAAC,CAAC,CAAC,CACZ,gCACE,SAAS,EAAE,GACT,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EACtB,oFAAoF,YAEnF,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,CAAC,EAAE,EAAE,CAAC,WAAW,CAAC,KAAK,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,GAC7E,CACP,CAAC,CAAC,CAAC,IAAI,IACL,CACN,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,WAAW,GAAG,CAAC,KAAqB,EAAE,CAAS,EAAE,OAA2B,EAAE,EAAE;IACpF,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,CAAC,yBAAe,CAAC,cAAc,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE;QAC7E,OAAO,IAAI,CAAC;KACb;IAED,MAAM,cAAc,GAAa,yBAAe,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IAC7D,OAAO,CACL,gCAAK,SAAS,EAAC,gBAAgB,YAC7B,uBAAC,cAAc,IAAC,OAAO,EAAE,OAAO,KAAM,KAAK,CAAC,IAAI,GAAI,IADjB,SAAS,CAAC,EAAE,CAE3C,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,eAAe,GAAG,CAAC,CAAC,EAAE,EAAE,CAC5B,CAAC,CAAC,MAAM,CAAC,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,WAAW,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { BaseTileContent } from './BaseTileContent';
|
|
2
1
|
import type { UniBlockProps } from '../../types';
|
|
3
|
-
|
|
2
|
+
import type { BaseTileCommonProps } from './BaseTileProps';
|
|
3
|
+
export interface BaseTileProps extends BaseTileCommonProps, UniBlockProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const BaseTile: (props: import("@redneckz/uni-jsx").PropsWithChildren<BaseTileProps, any>, context?: any) => any;
|
|
@@ -2,18 +2,28 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
2
2
|
exports.BaseTile = 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 useLink_1 = require("../../hooks/useLink");
|
|
5
6
|
const BlockItem_1 = require("../../ui-kit/BlockItem/BlockItem");
|
|
6
7
|
const Button_1 = require("../../ui-kit/Button/Button");
|
|
7
8
|
const Icon_1 = require("../../ui-kit/Icon/Icon");
|
|
8
9
|
const Img_1 = require("../../ui-kit/Img");
|
|
9
10
|
const Title_1 = require("../../ui-kit/Title/Title");
|
|
10
|
-
const useLink_1 = require("../../hooks/useLink");
|
|
11
11
|
const getColSpan_1 = require("../../utils/getColSpan");
|
|
12
|
+
const alignBlock = {
|
|
13
|
+
left: 'items-start',
|
|
14
|
+
center: 'items-center',
|
|
15
|
+
right: 'items-end',
|
|
16
|
+
};
|
|
17
|
+
const alignText = {
|
|
18
|
+
left: 'text-left',
|
|
19
|
+
center: 'text-center',
|
|
20
|
+
right: 'text-right',
|
|
21
|
+
};
|
|
12
22
|
const TITLE_CLASSES = 'font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px]';
|
|
13
|
-
exports.BaseTile = (0, uni_jsx_1.JSX)(({ className, context, title, titleSize, description, children, buttons, image, items, version = 'primary', }) => {
|
|
23
|
+
exports.BaseTile = (0, uni_jsx_1.JSX)(({ className, context, title, titleSize, description, children, buttons, image, items, version = 'primary', align = 'left', }) => {
|
|
14
24
|
const router = context.useRouter();
|
|
15
25
|
const { handlerDecorator } = context;
|
|
16
|
-
return ((0, jsx_runtime_1.jsxs)("div", { className: `font-sans flex flex-col grow h-full`, children: [title && ((0, jsx_runtime_1.jsx)(Title_1.Title, { size: titleSize || getTitleSizeByClassName(className), className: TITLE_CLASSES, children: title })), (0, jsx_runtime_1.jsxs)("div", { className: "flex grow justify-between", children: [(0, jsx_runtime_1.jsxs)("div", { className:
|
|
26
|
+
return ((0, jsx_runtime_1.jsxs)("div", { className: `font-sans flex flex-col grow h-full ${alignBlock[align]}`, children: [title && ((0, jsx_runtime_1.jsx)(Title_1.Title, { size: titleSize || getTitleSizeByClassName(className), className: TITLE_CLASSES, children: title })), (0, jsx_runtime_1.jsxs)("div", { className: "flex grow justify-between", children: [(0, jsx_runtime_1.jsxs)("div", { className: `flex flex-col justify-between ${alignBlock[align]}`, children: [(0, jsx_runtime_1.jsxs)("div", { children: [description ? ((0, jsx_runtime_1.jsx)("div", { className: `font-normal text-base max-w-[600px] ${alignText[align]}`, children: description })) : null, children, items?.length ? renderItems(items, version) : null] }), buttons?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "flex mt-9 gap-3", children: buttons.map((button, index) => renderButton((0, useLink_1.useLink)({ router, handlerDecorator }, button), index)) })) : null] }), image?.src && (0, jsx_runtime_1.jsx)(Img_1.Img, { className: "mt-auto ml-7", image: image })] })] }));
|
|
17
27
|
});
|
|
18
28
|
function getTitleSizeByClassName(className = '') {
|
|
19
29
|
const colSpan = (0, getColSpan_1.getColSpan)(className);
|
|
@@ -28,7 +38,7 @@ function getTitleSizeByClassName(className = '') {
|
|
|
28
38
|
}
|
|
29
39
|
}
|
|
30
40
|
function renderItems(items = [], version) {
|
|
31
|
-
return ((0, jsx_runtime_1.jsx)("section", { className: "max-w-[600px]", role: "list", children: items.map((_, i) => ((0, jsx_runtime_1.jsx)(BlockItem_1.BlockItem, { className: i ? 'mt-2.5' : '', text: _, version: version }, String(i)))) }));
|
|
41
|
+
return ((0, jsx_runtime_1.jsx)("section", { className: "max-w-[600px] mt-5", role: "list", children: items.map((_, i) => ((0, jsx_runtime_1.jsx)(BlockItem_1.BlockItem, { className: i ? 'mt-2.5' : '', text: _, version: version }, String(i)))) }));
|
|
32
42
|
}
|
|
33
43
|
function renderButton({ icon, ...button }, i) {
|
|
34
44
|
if (!button?.text)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseTile.js","sourceRoot":"","sources":["../../../src/components/BaseTile/BaseTile.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;
|
|
1
|
+
{"version":3,"file":"BaseTile.js","sourceRoot":"","sources":["../../../src/components/BaseTile/BaseTile.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,iDAA8C;AAG9C,gEAA6D;AAC7D,uDAAoD;AACpD,iDAA8C;AAC9C,0CAAuC;AACvC,oDAAiD;AACjD,uDAAoD;AAGpD,MAAM,UAAU,GAA8B;IAC5C,IAAI,EAAE,aAAa;IACnB,MAAM,EAAE,cAAc;IACtB,KAAK,EAAE,WAAW;CACnB,CAAC;AACF,MAAM,SAAS,GAA8B;IAC3C,IAAI,EAAE,WAAW;IACjB,MAAM,EAAE,aAAa;IACrB,KAAK,EAAE,YAAY;CACpB,CAAC;AAIF,MAAM,aAAa,GAAG,wDAAwD,CAAC;AAElE,QAAA,QAAQ,GAAG,IAAA,aAAG,EACzB,CAAC,EACC,SAAS,EACT,OAAO,EACP,KAAK,EACL,SAAS,EACT,WAAW,EACX,QAAQ,EACR,OAAO,EACP,KAAK,EACL,KAAK,EACL,OAAO,GAAG,SAAS,EACnB,KAAK,GAAG,MAAM,GACf,EAAE,EAAE;IACH,MAAM,MAAM,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC;IACnC,MAAM,EAAE,gBAAgB,EAAE,GAAG,OAAO,CAAC;IACrC,OAAO,CACL,iCAAK,SAAS,EAAE,uCAAuC,UAAU,CAAC,KAAK,CAAC,EAAE,aACvE,KAAK,IAAI,CACR,uBAAC,aAAK,IAAC,IAAI,EAAE,SAAS,IAAI,uBAAuB,CAAC,SAAS,CAAC,EAAE,SAAS,EAAE,aAAa,YACnF,KAAK,GACA,CACT,EACD,iCAAK,SAAS,EAAC,2BAA2B,aACxC,iCAAK,SAAS,EAAE,iCAAiC,UAAU,CAAC,KAAK,CAAC,EAAE,aAClE,4CACG,WAAW,CAAC,CAAC,CAAC,CACb,gCAAK,SAAS,EAAE,uCAAuC,SAAS,CAAC,KAAK,CAAC,EAAE,YACtE,WAAW,GACR,CACP,CAAC,CAAC,CAAC,IAAI,EACP,QAAQ,EACR,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,WAAW,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,IAAI,IAC/C,EACL,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,CACjB,gCAAK,SAAS,EAAC,iBAAiB,YAC7B,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAC7B,YAAY,CAAC,IAAA,iBAAO,EAAC,EAAE,MAAM,EAAE,gBAAgB,EAAE,EAAE,MAAM,CAAC,EAAE,KAAK,CAAC,CACnE,GACG,CACP,CAAC,CAAC,CAAC,IAAI,IACJ,EACL,KAAK,EAAE,GAAG,IAAI,uBAAC,SAAG,IAAC,SAAS,EAAC,cAAc,EAAC,KAAK,EAAE,KAAK,GAAI,IACzD,IACF,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,SAAS,uBAAuB,CAAC,YAAoB,EAAE;IACrD,MAAM,OAAO,GAAG,IAAA,uBAAU,EAAC,SAAS,CAAC,CAAC;IACtC,IAAI,OAAO,IAAI,CAAC,EAAE;QAChB,OAAO,GAAG,CAAC;KACZ;SAAM,IAAI,OAAO,IAAI,CAAC,EAAE;QACvB,OAAO,GAAG,CAAC;KACZ;SAAM;QACL,OAAO,GAAG,CAAC;KACZ;AACH,CAAC;AAED,SAAS,WAAW,CAAC,QAAkB,EAAE,EAAE,OAAsB;IAC/D,OAAO,CACL,oCAAS,SAAS,EAAC,oBAAoB,EAAC,IAAI,EAAC,MAAM,YAChD,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CACnB,uBAAC,qBAAS,IAAiB,SAAS,EAAE,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,OAAO,IAAlE,MAAM,CAAC,CAAC,CAAC,CAA6D,CACvF,CAAC,GACM,CACX,CAAC;AACJ,CAAC;AAED,SAAS,YAAY,CAAC,EAAE,IAAI,EAAE,GAAG,MAAM,EAAsB,EAAE,CAAS;IACtE,IAAI,CAAC,MAAM,EAAE,IAAI;QAAE,OAAO;IAE1B,IAAI,IAAI;QACN,OAAO,CACL,uBAAC,eAAM,IAEL,UAAU,EAAE,uBAAC,WAAI,IAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAC,IAAI,EAAC,MAAM,EAAC,IAAI,GAAG,KACnD,MAAM,IAFL,MAAM,CAAC,CAAC,CAAC,CAGd,CACH,CAAC;IAEJ,OAAO,uBAAC,eAAM,OAAqB,MAAM,IAArB,MAAM,CAAC,CAAC,CAAC,CAAgB,CAAC;AAChD,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { BlockVersion } from '../../model/BlockVersion';
|
|
2
|
+
import type { Picture } from '../../model/Picture';
|
|
3
|
+
import type { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
|
|
4
|
+
import type { IconName } from '../../ui-kit/Icon/IconProps';
|
|
5
|
+
import type { TitleSize } from '../../ui-kit/Title/TitleProps';
|
|
6
|
+
/**
|
|
7
|
+
* @title Выравнивание
|
|
8
|
+
* @enumNames [
|
|
9
|
+
* "По левому краю",
|
|
10
|
+
* "По центру",
|
|
11
|
+
* "По правому краю"
|
|
12
|
+
* ]
|
|
13
|
+
*/
|
|
14
|
+
export declare type AlignType = 'left' | 'center' | 'right';
|
|
15
|
+
export interface BaseTileIconButton extends ButtonWithIconProps {
|
|
16
|
+
icon?: IconName;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* @title Плитка
|
|
20
|
+
*/
|
|
21
|
+
export interface BaseTileCommonProps {
|
|
22
|
+
/** @title Заголовок */
|
|
23
|
+
title?: string;
|
|
24
|
+
/**
|
|
25
|
+
* @title Размер заголовка
|
|
26
|
+
* @default M
|
|
27
|
+
*/
|
|
28
|
+
titleSize?: TitleSize;
|
|
29
|
+
/** @title Описание */
|
|
30
|
+
description?: string;
|
|
31
|
+
image?: Picture;
|
|
32
|
+
/** @title Список */
|
|
33
|
+
items?: string[];
|
|
34
|
+
/**
|
|
35
|
+
* @title Кнопки
|
|
36
|
+
* @maxItems 4
|
|
37
|
+
*/
|
|
38
|
+
buttons?: BaseTileIconButton[];
|
|
39
|
+
version?: BlockVersion;
|
|
40
|
+
align?: AlignType;
|
|
41
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
2
|
-
//# sourceMappingURL=
|
|
2
|
+
//# sourceMappingURL=BaseTileProps.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseTileProps.js","sourceRoot":"","sources":["../../../src/components/BaseTile/BaseTileProps.ts"],"names":[],"mappings":""}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { BenefitsBlockContent } from './BenefitsBlockContent';
|
|
2
1
|
import type { UniBlockProps } from '../../types';
|
|
2
|
+
import type { BenefitsBlockContent } from './BenefitsBlockContent';
|
|
3
3
|
export interface BenefitsBlockProps extends BenefitsBlockContent, UniBlockProps {
|
|
4
4
|
}
|
|
5
5
|
export declare const BenefitsBlock: (props: import("@redneckz/uni-jsx").PropsWithChildren<BenefitsBlockProps, any>, context?: any) => any;
|
|
@@ -3,8 +3,9 @@ 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
5
|
const Icon_1 = require("../../ui-kit/Icon/Icon");
|
|
6
|
+
const Title_1 = require("../../ui-kit/Title/Title");
|
|
6
7
|
exports.BenefitsBlock = (0, uni_jsx_1.JSX)(({ className, title, benefits }) => {
|
|
7
|
-
return ((0, jsx_runtime_1.jsxs)("section", { className: `font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${className || ''}`, children: [(0, jsx_runtime_1.jsx)(
|
|
8
|
+
return ((0, jsx_runtime_1.jsxs)("section", { className: `font-sans text-primary-text bg-white p-12 pb-2 flex flex-col items-center ${className || ''}`, children: [title ? (0, jsx_runtime_1.jsx)(Title_1.Title, { className: "font-medium m-0 max-w-[47rem] text-center", children: title }) : null, benefits?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "grid grid-cols-2 gap-5 mt-9", children: benefits.map(renderStep) })) : null] }));
|
|
8
9
|
});
|
|
9
10
|
const renderStep = (benefit, i) => {
|
|
10
11
|
return ((0, jsx_runtime_1.jsxs)("div", { className: "flex items-center p-10 gap-5 max-w-[580px]", children: [benefit.icon && ((0, jsx_runtime_1.jsx)(Icon_1.Icon, { className: "h-[70px] w-[70px] min-w-[70px] min-h-[70px]", name: benefit.icon, width: "70", height: "70" })), (0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)("h3", { className: "font-medium text-xl m-0", children: benefit.label }), benefit.description && ((0, jsx_runtime_1.jsx)("div", { className: "font-normal text-sm mt-2", children: benefit.description }))] })] }, String(i)));
|
|
@@ -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;AAExC,iDAA8C;AAC9C,oDAAiD;AAKpC,QAAA,aAAa,GAAG,IAAA,aAAG,EAAqB,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,EAAE;IACtF,OAAO,CACL,qCACE,SAAS,EAAE,6EACT,SAAS,IAAI,EACf,EAAE,aAED,KAAK,CAAC,CAAC,CAAC,uBAAC,aAAK,IAAC,SAAS,EAAC,2CAA2C,YAAE,KAAK,GAAS,CAAC,CAAC,CAAC,IAAI,EAC3F,QAAQ,EAAE,MAAM,CAAC,CAAC,CAAC,CAClB,gCAAK,SAAS,EAAC,6BAA6B,YAAE,QAAQ,CAAC,GAAG,CAAC,UAAU,CAAC,GAAO,CAC9E,CAAC,CAAC,CAAC,IAAI,IACA,CACX,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,UAAU,GAAG,CAAC,OAAgB,EAAE,CAAS,EAAE,EAAE;IACjD,OAAO,CACL,iCAAqB,SAAS,EAAC,4CAA4C,aACxE,OAAO,CAAC,IAAI,IAAI,CACf,uBAAC,WAAI,IACH,SAAS,EAAC,6CAA6C,EACvD,IAAI,EAAE,OAAO,CAAC,IAAI,EAClB,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,GACX,CACH,EACD,4CACE,+BAAI,SAAS,EAAC,yBAAyB,YAAE,OAAO,CAAC,KAAK,GAAM,EAC3D,OAAO,CAAC,WAAW,IAAI,CACtB,gCAAK,SAAS,EAAC,0BAA0B,YAAE,OAAO,CAAC,WAAW,GAAO,CACtE,IACG,KAdE,MAAM,CAAC,CAAC,CAAC,CAeb,CACP,CAAC;AACJ,CAAC,CAAC"}
|