@redneckz/wildless-cms-uni-blocks 0.2.83 → 0.2.86

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.
Files changed (284) hide show
  1. package/bundle/blocks.schema.json +1 -945
  2. package/bundle/bundle.umd.js +203 -198
  3. package/bundle/bundle.umd.min.js +1 -1
  4. package/dist/components/Accordion/Accordion.js +1 -1
  5. package/dist/components/Accordion/Accordion.js.map +1 -1
  6. package/dist/components/Accordion/AccordionContent.d.ts +29 -10
  7. package/dist/components/Accordion/AccordionItem.d.ts +2 -2
  8. package/dist/components/Accordion/AccordionItem.js +5 -6
  9. package/dist/components/Accordion/AccordionItem.js.map +1 -1
  10. package/dist/components/BaseTile/BaseTile.d.ts +2 -2
  11. package/dist/components/BaseTile/BaseTile.js +1 -1
  12. package/dist/components/BaseTile/BaseTile.js.map +1 -1
  13. package/dist/components/BaseTile/BaseTileProps.d.ts +31 -0
  14. package/dist/{model/SitemapContent.js → components/BaseTile/BaseTileProps.js} +1 -1
  15. package/dist/components/BaseTile/BaseTileProps.js.map +1 -0
  16. package/dist/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  17. package/dist/components/BenefitsBlock/BenefitsBlock.js +2 -1
  18. package/dist/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  19. package/dist/components/BenefitsBlock/BenefitsBlockContent.d.ts +14 -1
  20. package/dist/components/BlockContent.d.ts +4 -1
  21. package/dist/components/ComparisonTable/ComparisonTableContent.d.ts +45 -2
  22. package/dist/components/ComparisonTable/HeaderCell.d.ts +2 -2
  23. package/dist/components/ContentPage/ContentPage.d.ts +3 -2
  24. package/dist/components/ContentPage/ContentPage.js.map +1 -1
  25. package/dist/components/CreditCalculator/CreditCalculatorContent.d.ts +4 -0
  26. package/dist/components/ExchangeRateTile/ExchangeRateTile.d.ts +1 -1
  27. package/dist/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
  28. package/dist/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
  29. package/dist/components/ExchangeRateTile/ExchangeRateTileContent.d.ts +4 -0
  30. package/dist/components/Footer/Contacts.js +2 -2
  31. package/dist/components/Footer/Contacts.js.map +1 -1
  32. package/dist/components/Footer/FooterContent.d.ts +35 -9
  33. package/dist/components/Footer/FooterLink.d.ts +2 -2
  34. package/dist/components/Footer/HorizontalNavigation.js.map +1 -1
  35. package/dist/components/Footer/Sitemap.d.ts +1 -1
  36. package/dist/components/Footer/Sitemap.js +1 -1
  37. package/dist/components/Footer/Sitemap.js.map +1 -1
  38. package/dist/components/Footer/SocialMedia.d.ts +2 -2
  39. package/dist/components/Footer/SocialMedia.js +2 -2
  40. package/dist/components/Footer/SocialMedia.js.map +1 -1
  41. package/dist/components/Footer/TextInformation.js.map +1 -1
  42. package/dist/components/Gallery/GalleryContent.d.ts +13 -0
  43. package/dist/components/Header/HeaderContent.d.ts +10 -2
  44. package/dist/components/Header/HeaderSecondaryMenu.js +1 -1
  45. package/dist/components/Header/HeaderSecondaryMenu.js.map +1 -1
  46. package/dist/components/Header/HeaderSecondaryMenuButton.js +1 -1
  47. package/dist/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  48. package/dist/components/Header/isSubItemActive.d.ts +2 -2
  49. package/dist/components/Header/isSubItemActive.js.map +1 -1
  50. package/dist/components/Header/isTopItemActive.d.ts +2 -2
  51. package/dist/components/Header/isTopItemActive.js.map +1 -1
  52. package/dist/components/MiniGallery/MiniGallery.d.ts +3 -3
  53. package/dist/components/MiniGallery/MiniGalleryContent.d.ts +6 -0
  54. package/dist/components/MiniGallery/MiniGalleryContent.js +2 -0
  55. package/dist/components/MiniGallery/MiniGalleryContent.js.map +1 -0
  56. package/dist/components/MobileAppTile/MobileAppTileContent.d.ts +11 -2
  57. package/dist/components/Placeholder/PlaceholderContent.d.ts +3 -0
  58. package/dist/components/ProductBlock/ProductBlock.mobile.d.ts +2 -2
  59. package/dist/components/ProductBlock/ProductBlock.mobile.js.map +1 -1
  60. package/dist/components/ProductBlock/ProductBlockContent.d.ts +10 -5
  61. package/dist/components/ProductBlock/ProductBlockInner.d.ts +2 -2
  62. package/dist/components/ProductBlock/ProductBlockInner.js +1 -1
  63. package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
  64. package/dist/components/ProductGallery/ProductGallery.d.ts +1 -1
  65. package/dist/components/ProductGallery/ProductGallery.js.map +1 -1
  66. package/dist/components/ProductGallery/ProductGalleryContent.d.ts +17 -2
  67. package/dist/components/ProductTile/ProductTileContent.d.ts +6 -2
  68. package/dist/components/PromoTile/PromoTileContent.d.ts +6 -2
  69. package/dist/components/StepsBlock/StepsBlockContent.d.ts +13 -0
  70. package/dist/components/TextBlock/TextBlockContent.d.ts +13 -0
  71. package/dist/components/Tile/TileContent.d.ts +5 -2
  72. package/dist/hooks/useLink.d.ts +3 -3
  73. package/dist/hooks/useLink.js.map +1 -1
  74. package/dist/index.d.ts +12 -12
  75. package/dist/index.js +10 -10
  76. package/dist/index.js.map +1 -1
  77. package/dist/mergeTopItems.d.ts +2 -2
  78. package/dist/mergeTopItems.js.map +1 -1
  79. package/dist/model/BlockVersion.d.ts +4 -0
  80. package/dist/model/ButtonVersion.d.ts +4 -0
  81. package/dist/model/LinkProps.d.ts +21 -0
  82. package/dist/model/{LinkContent.js → LinkProps.js} +1 -1
  83. package/dist/model/LinkProps.js.map +1 -0
  84. package/dist/model/Picture.d.ts +11 -0
  85. package/dist/model/SitemapProps.d.ts +13 -0
  86. package/dist/{components/BaseTile/BaseTileContent.js → model/SitemapProps.js} +1 -1
  87. package/dist/model/SitemapProps.js.map +1 -0
  88. package/dist/types.d.ts +2 -2
  89. package/dist/ui-kit/Breadcrumb.d.ts +2 -2
  90. package/dist/ui-kit/Button/Button.d.ts +6 -3
  91. package/dist/ui-kit/Button/Button.js.map +1 -1
  92. package/dist/ui-kit/Button/ButtonProps.d.ts +15 -12
  93. package/dist/ui-kit/Icon/Icon.js +7 -1
  94. package/dist/ui-kit/Icon/Icon.js.map +1 -1
  95. package/dist/ui-kit/Icon/IconProps.d.ts +50 -19
  96. package/dist/ui-kit/Icon/IconProps.js +21 -18
  97. package/dist/ui-kit/Icon/IconProps.js.map +1 -1
  98. package/dist/ui-kit/TopItem/TopItem.d.ts +2 -2
  99. package/lib/common.css +1 -1
  100. package/lib/components/Accordion/Accordion.js +1 -1
  101. package/lib/components/Accordion/Accordion.js.map +1 -1
  102. package/lib/components/Accordion/AccordionContent.d.ts +29 -10
  103. package/lib/components/Accordion/AccordionItem.d.ts +2 -2
  104. package/lib/components/Accordion/AccordionItem.js +5 -6
  105. package/lib/components/Accordion/AccordionItem.js.map +1 -1
  106. package/lib/components/BaseTile/BaseTile.d.ts +2 -2
  107. package/lib/components/BaseTile/BaseTile.js +1 -1
  108. package/lib/components/BaseTile/BaseTile.js.map +1 -1
  109. package/lib/components/BaseTile/BaseTileProps.d.ts +31 -0
  110. package/lib/components/BaseTile/BaseTileProps.js +2 -0
  111. package/lib/components/BaseTile/BaseTileProps.js.map +1 -0
  112. package/lib/components/BenefitsBlock/BenefitsBlock.d.ts +1 -1
  113. package/lib/components/BenefitsBlock/BenefitsBlock.js +2 -1
  114. package/lib/components/BenefitsBlock/BenefitsBlock.js.map +1 -1
  115. package/lib/components/BenefitsBlock/BenefitsBlockContent.d.ts +14 -1
  116. package/lib/components/BlockContent.d.ts +4 -1
  117. package/lib/components/ComparisonTable/ComparisonTableContent.d.ts +45 -2
  118. package/lib/components/ComparisonTable/HeaderCell.d.ts +2 -2
  119. package/lib/components/ContentPage/ContentPage.d.ts +3 -2
  120. package/lib/components/ContentPage/ContentPage.js.map +1 -1
  121. package/lib/components/CreditCalculator/CreditCalculatorContent.d.ts +4 -0
  122. package/lib/components/ExchangeRateTile/ExchangeRateTile.d.ts +1 -1
  123. package/lib/components/ExchangeRateTile/ExchangeRateTile.js +1 -1
  124. package/lib/components/ExchangeRateTile/ExchangeRateTile.js.map +1 -1
  125. package/lib/components/ExchangeRateTile/ExchangeRateTileContent.d.ts +4 -0
  126. package/lib/components/Footer/Contacts.js +2 -2
  127. package/lib/components/Footer/Contacts.js.map +1 -1
  128. package/lib/components/Footer/FooterContent.d.ts +35 -9
  129. package/lib/components/Footer/FooterLink.d.ts +2 -2
  130. package/lib/components/Footer/HorizontalNavigation.js.map +1 -1
  131. package/lib/components/Footer/Sitemap.d.ts +1 -1
  132. package/lib/components/Footer/Sitemap.js +1 -1
  133. package/lib/components/Footer/Sitemap.js.map +1 -1
  134. package/lib/components/Footer/SocialMedia.d.ts +2 -2
  135. package/lib/components/Footer/SocialMedia.js +2 -2
  136. package/lib/components/Footer/SocialMedia.js.map +1 -1
  137. package/lib/components/Footer/TextInformation.js.map +1 -1
  138. package/lib/components/Gallery/GalleryContent.d.ts +13 -0
  139. package/lib/components/Header/HeaderContent.d.ts +10 -2
  140. package/lib/components/Header/HeaderSecondaryMenu.js +1 -1
  141. package/lib/components/Header/HeaderSecondaryMenu.js.map +1 -1
  142. package/lib/components/Header/HeaderSecondaryMenuButton.js +1 -1
  143. package/lib/components/Header/HeaderSecondaryMenuButton.js.map +1 -1
  144. package/lib/components/Header/isSubItemActive.d.ts +2 -2
  145. package/lib/components/Header/isSubItemActive.js.map +1 -1
  146. package/lib/components/Header/isTopItemActive.d.ts +2 -2
  147. package/lib/components/Header/isTopItemActive.js.map +1 -1
  148. package/lib/components/MiniGallery/MiniGallery.d.ts +3 -3
  149. package/lib/components/MiniGallery/MiniGalleryContent.d.ts +6 -0
  150. package/lib/components/MiniGallery/MiniGalleryContent.js +2 -0
  151. package/lib/components/MiniGallery/MiniGalleryContent.js.map +1 -0
  152. package/lib/components/MobileAppTile/MobileAppTileContent.d.ts +11 -2
  153. package/lib/components/Placeholder/PlaceholderContent.d.ts +3 -0
  154. package/lib/components/ProductBlock/ProductBlock.mobile.d.ts +2 -2
  155. package/lib/components/ProductBlock/ProductBlock.mobile.js.map +1 -1
  156. package/lib/components/ProductBlock/ProductBlockContent.d.ts +10 -5
  157. package/lib/components/ProductBlock/ProductBlockInner.d.ts +2 -2
  158. package/lib/components/ProductBlock/ProductBlockInner.js +1 -1
  159. package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
  160. package/lib/components/ProductGallery/ProductGallery.d.ts +1 -1
  161. package/lib/components/ProductGallery/ProductGallery.js.map +1 -1
  162. package/lib/components/ProductGallery/ProductGalleryContent.d.ts +17 -2
  163. package/lib/components/ProductTile/ProductTileContent.d.ts +6 -2
  164. package/lib/components/PromoTile/PromoTileContent.d.ts +6 -2
  165. package/lib/components/StepsBlock/StepsBlockContent.d.ts +13 -0
  166. package/lib/components/TextBlock/TextBlockContent.d.ts +13 -0
  167. package/lib/components/Tile/TileContent.d.ts +5 -2
  168. package/lib/hooks/useLink.d.ts +3 -3
  169. package/lib/hooks/useLink.js.map +1 -1
  170. package/lib/index.d.ts +12 -12
  171. package/lib/index.js +5 -5
  172. package/lib/index.js.map +1 -1
  173. package/lib/mergeTopItems.d.ts +2 -2
  174. package/lib/mergeTopItems.js.map +1 -1
  175. package/lib/model/BlockVersion.d.ts +4 -0
  176. package/lib/model/ButtonVersion.d.ts +4 -0
  177. package/lib/model/LinkProps.d.ts +21 -0
  178. package/lib/model/LinkProps.js +2 -0
  179. package/lib/model/LinkProps.js.map +1 -0
  180. package/lib/model/Picture.d.ts +11 -0
  181. package/lib/model/SitemapProps.d.ts +13 -0
  182. package/lib/model/SitemapProps.js +2 -0
  183. package/lib/model/SitemapProps.js.map +1 -0
  184. package/lib/types.d.ts +2 -2
  185. package/lib/ui-kit/Breadcrumb.d.ts +2 -2
  186. package/lib/ui-kit/Button/Button.d.ts +6 -3
  187. package/lib/ui-kit/Button/Button.js.map +1 -1
  188. package/lib/ui-kit/Button/ButtonProps.d.ts +15 -12
  189. package/lib/ui-kit/Icon/Icon.js +7 -1
  190. package/lib/ui-kit/Icon/Icon.js.map +1 -1
  191. package/lib/ui-kit/Icon/IconProps.d.ts +50 -19
  192. package/lib/ui-kit/Icon/IconProps.js +21 -18
  193. package/lib/ui-kit/Icon/IconProps.js.map +1 -1
  194. package/lib/ui-kit/TopItem/TopItem.d.ts +2 -2
  195. package/package.json +17 -36
  196. package/src/components/Accordion/Accordion.example.json +74 -0
  197. package/src/components/Accordion/Accordion.fixture.tsx +1 -16
  198. package/src/components/Accordion/Accordion.tsx +1 -1
  199. package/src/components/Accordion/AccordionContent.ts +31 -11
  200. package/src/components/Accordion/AccordionItem.tsx +10 -10
  201. package/src/components/BaseTile/BaseTile.tsx +4 -5
  202. package/src/components/BaseTile/BaseTileProps.ts +33 -0
  203. package/src/components/BenefitsBlock/BenefitsBlock.example.json +13 -0
  204. package/src/components/BenefitsBlock/BenefitsBlock.tsx +3 -2
  205. package/src/components/BenefitsBlock/BenefitsBlockContent.ts +14 -1
  206. package/src/components/BlockContent.ts +4 -1
  207. package/src/components/ComparisonTable/ComparisonTable.example.json +84 -0
  208. package/src/components/ComparisonTable/ComparisonTableContent.ts +46 -3
  209. package/src/components/ComparisonTable/HeaderCell.tsx +2 -2
  210. package/src/components/ContentPage/ContentPage.tsx +7 -5
  211. package/src/components/CreditCalculator/CreditCalculatorContent.ts +4 -0
  212. package/src/components/ExchangeRateTile/ExchangeRateTile.tsx +2 -2
  213. package/src/components/ExchangeRateTile/ExchangeRateTileContent.ts +4 -0
  214. package/src/components/Footer/Contacts.tsx +2 -2
  215. package/src/components/Footer/FooterContent.ts +36 -9
  216. package/src/components/Footer/FooterLink.ts +2 -2
  217. package/src/components/Footer/HorizontalNavigation.tsx +2 -2
  218. package/src/components/Footer/Sitemap.tsx +5 -5
  219. package/src/components/Footer/SocialMedia.tsx +5 -12
  220. package/src/components/Footer/TextInformation.tsx +2 -2
  221. package/src/components/Gallery/Gallery.example.json +71 -0
  222. package/src/components/Gallery/GalleryContent.ts +13 -0
  223. package/src/components/Header/HeaderContent.ts +10 -2
  224. package/src/components/Header/HeaderSecondaryMenu.tsx +4 -8
  225. package/src/components/Header/HeaderSecondaryMenuButton.tsx +1 -1
  226. package/src/components/Header/isSubItemActive.ts +3 -3
  227. package/src/components/Header/isTopItemActive.ts +3 -3
  228. package/src/components/MiniGallery/MiniGallery.example.json +61 -0
  229. package/src/components/MiniGallery/MiniGallery.tsx +3 -3
  230. package/src/components/MiniGallery/MiniGalleryContent.ts +6 -0
  231. package/src/components/MobileAppTile/MobileAppTile.example.json +20 -0
  232. package/src/components/MobileAppTile/MobileAppTileContent.ts +11 -2
  233. package/src/components/Placeholder/PlaceholderContent.ts +3 -0
  234. package/src/components/ProductBlock/ProductBlock.example.json +17 -0
  235. package/src/components/ProductBlock/ProductBlock.mobile.tsx +3 -3
  236. package/src/components/ProductBlock/ProductBlockContent.ts +10 -5
  237. package/src/components/ProductBlock/ProductBlockInner.tsx +4 -4
  238. package/src/components/ProductGallery/ProductGallery.example.json +21 -0
  239. package/src/components/ProductGallery/ProductGallery.tsx +3 -3
  240. package/src/components/ProductGallery/ProductGalleryContent.ts +17 -2
  241. package/src/components/ProductTile/ProductTile.example.json +30 -0
  242. package/src/components/ProductTile/ProductTileContent.ts +6 -2
  243. package/src/components/PromoTile/PromoTile.example.json +13 -0
  244. package/src/components/PromoTile/PromoTileContent.ts +6 -2
  245. package/src/components/StepsBlock/StepsBlock.example.json +17 -0
  246. package/src/components/StepsBlock/StepsBlockContent.ts +13 -0
  247. package/src/components/TextBlock/TextBlock.example.json +6 -0
  248. package/src/components/TextBlock/TextBlockContent.ts +14 -0
  249. package/src/components/Tile/Tile.example.json +18 -0
  250. package/src/components/Tile/TileContent.ts +5 -2
  251. package/src/hooks/useLink.ts +2 -2
  252. package/src/icons/GridIcon.svg +4 -7
  253. package/src/index.ts +14 -21
  254. package/src/mergeTopItems.ts +5 -5
  255. package/src/model/BlockVersion.ts +4 -0
  256. package/src/model/ButtonVersion.ts +4 -0
  257. package/src/model/LinkProps.ts +22 -0
  258. package/src/model/Picture.ts +11 -0
  259. package/src/model/SitemapProps.ts +15 -0
  260. package/src/types.ts +2 -2
  261. package/src/ui-kit/Breadcrumb.tsx +2 -2
  262. package/src/ui-kit/Button/Button.tsx +7 -3
  263. package/src/ui-kit/Button/ButtonProps.ts +16 -13
  264. package/src/ui-kit/Icon/Icon.tsx +23 -9
  265. package/src/ui-kit/Icon/IconProps.ts +36 -5
  266. package/src/ui-kit/TopItem/TopItem.tsx +2 -2
  267. package/dist/components/BaseTile/BaseTileContent.d.ts +0 -13
  268. package/dist/components/BaseTile/BaseTileContent.js.map +0 -1
  269. package/dist/model/LinkContent.d.ts +0 -5
  270. package/dist/model/LinkContent.js.map +0 -1
  271. package/dist/model/SitemapContent.d.ts +0 -7
  272. package/dist/model/SitemapContent.js.map +0 -1
  273. package/lib/components/BaseTile/BaseTileContent.d.ts +0 -13
  274. package/lib/components/BaseTile/BaseTileContent.js +0 -2
  275. package/lib/components/BaseTile/BaseTileContent.js.map +0 -1
  276. package/lib/model/LinkContent.d.ts +0 -5
  277. package/lib/model/LinkContent.js +0 -2
  278. package/lib/model/LinkContent.js.map +0 -1
  279. package/lib/model/SitemapContent.d.ts +0 -7
  280. package/lib/model/SitemapContent.js +0 -2
  281. package/lib/model/SitemapContent.js.map +0 -1
  282. package/src/components/BaseTile/BaseTileContent.ts +0 -14
  283. package/src/model/LinkContent.ts +0 -5
  284. package/src/model/SitemapContent.ts +0 -9
@@ -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,...s})=>n("svg",{className:e,...s,"aria-hidden":"true",children:[l?r("title",{children:l}):null,a?r("desc",{children:a}):null,r("use",{href:`${i.CDN||""}icons/${t}.svg#icon`,xlinkHref:`${i.CDN||""}icons/${t}.svg#icon`})]}))),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?H(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 H(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 Z={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},F=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||""} ${Z[a]} ${V(n)} `,children:r(B,{...e,children:t})})}));function V(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(F,{className:e,context:t,title:n,description:"Блок в разработке...",children:r("figure",{className:"m-0 min-w-[600px]",children:E()})}))),E=(e=3)=>W(100,e).map((e=>Math.floor(e))).map(U),U=(e=100,t)=>r("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),W=(e,t)=>[e].concat(t>0?W(e/1.618,t-1):[]),G=({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=G})=>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(F,{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,className:"[&>*]:fill-primary-text [&>*]:hover:fill-primary-main"})}):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(He)}):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 He(e,t){return r(x,{children:r("span",{className:"text-sm text-secondary-text",children:e})},String(t))}const Ze=a((e=>r(Oe,{...e,version:"normal"}))),Fe=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]}))),Ve=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] 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(Ve,{className:"mr-5",flat:!0,href:"#",text:i,ariaLabel:"Местоположение",onClick:l}),r(Ve,{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"})}),r(ze,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Профиль",children:r(N,{name:"ProfileIcon","aria-hidden":"true"})}),r(ze,{className:"mr-5 text-secondary-light hover:text-primary-main min-w-[32px] min-h-[32px]",ariaLabel:"Дополнительные ссылки",children:r(N,{name:"GridIcon","aria-hidden":"true",className:"[&>*]:fill-secondary-light [&>*]:hover:fill-primary-main"})})]})}));const Ue=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(Ve,{active:e===m,...A({router:l,handlerDecorator:c},e),ariaLabel:e.text},String(t)))),u=d?.map((e=>r(Fe,{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})]})})),We=a((e=>r(Oe,{...e,version:"mini"}))),Ge=a((({className:e,context:t,title:a="Мобильное приложение",qr:i,buttons:l=[]})=>r(F,{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(F,{...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(F,{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:Ue,Footer:Te,Placeholder:z,Tile:F,PromoTile:rt,TextBlock:ct,ProductTile:et,ProductBlock:Ke,StepsBlock:at,BenefitsBlock:q,ProductGallery:Ye,ExchangeRateTile:ne,MobileAppTile:Ge,Gallery:Ze,MiniGallery:We,ComparisonTable:yt,Accordion:Ct,CreditCalculator:Bt},Ht=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})}))),Zt=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(Ft)})]})));function Ft(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?Vt(e.items):null]}),e.href?r(b,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},t)}function Vt(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:Ue,Footer:Ht,Placeholder:z,Tile:F,ProductTile:et,ProductBlock:zt,TextBlock:ct,ExchangeRateTile:ne,MobileAppTile:Ge,Gallery:Zt};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";const l=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}},s=a((({className:e,name:t,alt:a=`Icon ${t}`,title:i=a,asSVG:s,...c})=>{const o=`${l.CDN||""}icons/${t}.svg`;return s?r("svg",{className:e,...c,"aria-hidden":"true",children:[i?n("title",{children:i}):null,a?n("desc",{children:a}):null,n("use",{href:`${o}#icon`,xlinkHref:`${o}#icon`})]}):n("img",{className:e,src:o,alt:a,title:i,...c,"aria-hidden":"true"})}));var c;!function(e){e.XL="text-title-lg",e.L="text-title",e.M="text-title-sm",e.S="text-title-xs"}(c||(c={}));const o=a((({size:e="L",className:t,children:r,...a})=>n("XL"===e?"h1":"h2",{className:m(c[e],t),...a,children:r}))),m=(...e)=>e.filter(Boolean).join(" "),d=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(o,{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(h)}):null]}))),h=(e,t)=>r("div",{className:"flex items-center p-10 gap-5 max-w-[580px]",children:[e.icon&&n(s,{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)),x="/mobile",u=e=>e?.includes("//"),p=(e,t,n=((e,t)=>e===t))=>n(f(e),b(f(u(e)?t.href:t.pathname))),f=e=>(e||"").replace(/\/?\?.*/,""),b=e=>(e||"").replace(x,""),g=e=>{if(!u(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t},N=(e,t)=>{if(!e)return e;const n=v(e,t),r=t?.pathname.startsWith(x);return r&&!u(n)?`/mobile${n}`:n},v=(e,t)=>{if(!e)return e;const n=g(t?.href);return n?e.replace(n,"")||"/":e};var y=Object.freeze({__proto__:null,MOBILE_URL_PATH:x,isURL:u,isHrefActive:p,withoutQuery:f,withoutMobilePath:b,getOrigin:g,adjustHref:N,toRelativeHref:v});const w=(e,t)=>e;function k({router:e,handlerDecorator:t=w},n){const r=N(n.href,e);return{...n,href:r,ariaLabel:n.text,onClick:t((t=>{const a=r&&!u(r),i=!n.target||"_self"===n.target;a&&i&&(t.preventDefault(),e.push(r))}),n)}}const $={primary:"bg-primary-main",secondary:"bg-white"},S={primary:"text-primary-text",secondary:"text-white"},C=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 ${$[i]}`}),n("span",{className:`text-base font-normal font-sans mx-3 ${S[i]}`,children:t||a})]}))),_={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"},j={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text"},L="inline-block text-center font-sans select-none",D=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(R,{text:t,aboveText:r,appendLeft:a,rounded:m});return o?n("div",{role:"button","aria-disabled":"true","aria-label":h,tabIndex:"-1",className:`${L} ${j[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,children:u}):n("a",{className:`${L} cursor-pointer no-underline ${_[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:s,"aria-label":h,role:i?"link":"button",...x,children:u})})),R=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})]})]})})),T=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:I(t)},`${r}_${e}`))):null,n("img",{src:t.src,alt:t.alt||t.title,title:t.title,...t?.size})]})));function I(e){return e?`image/${String(e)}`:void 0}const M=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12},A=a((({className:e,context:t,title:a,titleSize:i,description:l,children:c,buttons:m,image:d,items:h,version:x="primary"})=>{const u=t.useRouter(),{handlerDecorator:p}=t;return r("div",{className:"font-sans flex flex-col grow h-full",children:[a&&n(o,{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 items-start",children:[r("div",{children:[l?n("div",{className:"font-normal text-base max-w-[600px] mb-5",children:l}):null,c,h?.length?B(h,x):null]}),m?.length?n("div",{className:"flex mt-9 gap-3",children:m.map(((e,t)=>function({icon:e,...t},r){if(!t?.text)return;return n(D,e?{appendLeft:n(s,{name:e,width:"24",height:"24"}),...t}:{...t},String(r))}(k({router:u,handlerDecorator:p},e),t)))}):null]}),d?.src&&n(T,{className:"mt-auto ml-7",image:d})]})]})}));function P(e=""){const t=M(e);return t<=4?"S":t<=8?"M":"L"}function B(e=[],t){return n("section",{className:"max-w-[600px]",role:"list",children:e.map(((e,r)=>n(C,{className:r?"mt-2.5":"",text:e,version:t},String(r))))})}const O={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},V=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||""} ${O[a]} ${H(r)} `,children:n(A,{...e,children:t})})}));function H(e=""){const t=M(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const Z="https://www.cbr-xml-daily.ru/daily_json.js",F=["USD","EUR"],z={USD:"DollarIcon",EUR:"EuroIcon"},E=[{text:"Все показатели",href:"https://cbr.ru/currency_base/daily/",version:"secondary"}],G=a((({className:e,context:t,title:a})=>{const{data:i}=t.useAsyncData(Z,J);return n(V,{className:e,context:t,title:a||"Курсы обмена валют",buttons:E,children:r("table",{children:[n("thead",{children:r("tr",{children:[n(U,{children:"Валюта"}),n(U,{className:"pl-11",children:"Курс"})]})}),n("tbody",{children:F.map((e=>{const t=(i?.Valute||{})[e]?.Value;return r("tr",{children:[n(W,{className:"pt-4",children:r("div",{className:"flex items-center",children:[n(s,{name:z[e],width:"24",height:"24"}),n("span",{className:"ml-2",children:e})]})}),n(W,{className:"pt-4 pl-11",children:Q(t)})]},e)}))})]})})})),U=a((({className:e="",children:t})=>n("th",{className:`text-left font-normal text-sm text-secondary-text ${e}`,children:t}))),W=a((({className:e="",children:t})=>n("td",{className:`text-left font-normal text-base text-primary-text ${e}`,children:t})));async function J(){const e=await fetch(Z);return await e.json()}const X=new Intl.NumberFormat("ru",{style:"currency",currency:"RUB"}),Q=e=>e?X.format(e):"",q=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)))}))),K=["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"],Y=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(q,{className:"text-primary-main w-10",viewBox:"0 0 40 45",paths:K.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(s,{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:"Найти"})]})})),te=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(ne):null,a?n(D,{version:"primary",className:"my-4",...k({router:l,handlerDecorator:s},{text:"Обратная связь",href:"/",target:"_blank"})}):null]})})),ne=(e,t)=>{const{type:a,text:i,description:l}=e;return r("div",{className:"mb-4",children:[n("div",{children:re(a,i)}),n("div",{className:"font-sans text-sm text-secondary-text",children:l})]},String(t))},re=(e,t="")=>{switch(e){case"tel":return n("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`tel:${ae(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})}},ae=e=>e.replaceAll(/(\-|\s|\(|\)|\D+)/g,""),ie=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(le,{index:t,...k({router:a,handlerDecorator:i},e)},String(t))))}):null})})),le=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 se(e){const{data:t}=e(oe(),ce);return t||{}}async function ce(){const e=await fetch(oe());return await e.json()}function oe(){return`/wcms-resources/${l.SITEMAP||"sitemap"}.json`}const me=e=>t=>e?.href===t?.href;function de(e,t){return(r=e,a=t,(r||[]).map((e=>a?.find(me(e))||e))).concat((n=e,(t||[]).filter((e=>!n?.find(me(e))))));var n,r,a}const he=a((({className:e,items:t,context:r})=>{const a=de(se(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)=>xe(e,t,i)))})})),xe=(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(ue,{...k({router:a,handlerDecorator:i},e)},String(t))))]},String(t))},ue=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}`}))),pe=[{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"}],fe=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(be,{...k({router:a,handlerDecorator:i},e)},String(t))))})})),be=a((({href:e})=>{const{icon:t,label:r,width:a,height:i}=pe.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};return t?n(D,{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(s,{name:t,width:a,height:i,asSVG:!0})}):null})),ge=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(Ne,{index:t,...k({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),Ne=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}`}))),ve=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(Y,{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(te,{className:"w-[280px] shrink-0 overflow-hidden xl:w-[220px]",items:i,context:c,hasButton:!0}),n(he,{className:"pt-[3px]",context:c,items:s})]}),n(fe,{media:l,context:c}),n(ie,{links:a,context:c}),n(ge,{links:t,context:c})]}))),ye=[{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"}],we=a((({className:e,disabled:t,...r})=>n(D,{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(q,{paths:ye,viewBox:"0 0 16 16",fill:"none",width:"16",height:"16"})}))),ke={normal:"min-w-[364px] w-[364px]",mini:"min-w-[260px] w-[260px]"},$e={normal:380,mini:276},Se={normal:3,mini:4},Ce=a((({title:e,description:t,context:a,cards:i=[],className:l,version:s="normal"})=>{const[c,m]=a.useState(0);const d=i?.length>Se[s],h=d&&i?.length-c>Se[s],x=d&&c>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(o,{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<=Se[s]?"justify-center":""} duration-1000`,style:{transform:`translateX(-${c*$e[s]}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 ${ke[a]} w-full`,role:"listitem",children:[r("div",{children:[e.image?.src?n("div",{className:"flex justify-center",children:n(T,{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(_e)}):null]}),e.href?n(D,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},String(t))}(e,t,s)))}),x&&n(we,{className:"absolute top-1/2 left-8 rotate-180",onClick:function(){m(c-1)},ariaLabel:"Пролистать влево"}),h&&n(we,{className:"absolute top-1/2 right-1 z-10",onClick:function(){m(c+1)},ariaLabel:"Пролистать вправо"}),n("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"})]})}));function _e(e,t){return n(C,{children:n("span",{className:"text-sm text-secondary-text",children:e})},String(t))}const je=a((e=>n(Ce,{...e,version:"normal"}))),Le=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]}))),De=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})}))),Re=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}))),Te=a((({context:e,className:t,defaultLocation:a=""})=>{const[i,l]=e.useGeolocation(a);return r("div",{className:`flex items-center ${t||""}`,children:[n(De,{className:"mr-5",flat:!0,href:"#",text:i,ariaLabel:"Местоположение",onClick:l}),n(De,{className:"mr-7",flat:!0,href:"#",text:"Офисы и банкоматы",ariaLabel:"Список всех доступных офисов и банкоматов"}),n(Re,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Поиск по сайту",children:n(s,{name:"LoupeIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),n(Re,{className:"mr-5 text-primary-text hover:text-primary-main",ariaLabel:"Профиль",children:n(s,{name:"ProfileIcon","aria-hidden":"true",className:"h-full",asSVG:!0})}),n(Re,{className:"min-w-[32px] min-h-[32px] fill-secondary-light hover:fill-secondary-hover",ariaLabel:"Дополнительные ссылки",children:n(s,{name:"GridIcon","aria-hidden":"true",className:"h-full",asSVG:!0})})]})}));const Ie=a((({className:e,defaultLocation:t,context:a,topItems:i})=>{const l=a.useRouter(),s=se(a.useAsyncData),{handlerDecorator:c}=a,o=de(s.topItems,i),m=o.find(function(e){return t=>p(t.href,e,((e,t)=>t.startsWith(e)))}(l)),d=m?.items,h=d?.find(function(e){return t=>p(t.href,e)}(l)),x=o.map(((e,t)=>n(De,{active:e===m,...k({router:l,handlerDecorator:c},e),ariaLabel:e.text},String(t)))),u=d?.map((e=>n(Le,{className:"mr-8",active:e===h,...k({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(Y,{className:"mr-8"}),x,n(Te,{context:a,className:"ml-auto",defaultLocation:t})]}),n("div",{className:"mt-5 h-[1px] bg-main-divider"}),n("nav",{className:"mt-5",children:u})]})})),Me=a((e=>n(Ce,{...e,version:"mini"}))),Ae=a((({className:e,context:t,title:a="Мобильное приложение",qr:i,buttons:l=[]})=>n(V,{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-код и скачайте приложение"})]})}))),Pe=a((({className:e,context:t,title:r})=>n(V,{className:e,context:t,title:r,description:"Блок в разработке...",children:n("figure",{className:"m-0 min-w-[600px]",children:Be()})}))),Be=(e=3)=>Ve(100,e).map((e=>Math.floor(e))).map(Oe),Oe=(e=100,t)=>n("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),Ve=(e,t)=>[e].concat(t>0?Ve(e/1.618,t-1):[]),He=a((({className:e,context:t,title:a,titleSize:i,description:l,benefits:s,buttons:c,image:m,items:d})=>r("div",{className:`flex grow justify-between items-stretch ${e||""}`,children:[r("div",{className:"flex flex-col",children:[a&&n(o,{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:c,children:s?.length?n("div",{className:"flex gap-6 mt-6 mb-3.5",children:s.map(Ze)}):null})]}),m?.src&&n(T,{className:"mt-auto",image:m})]})));function Ze(e,t){return r("div",{className:"flex gap-4 items-center",children:[e.icon&&n(s,{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 Fe=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 ze(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])}const Ee=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:ze(n("span",{className:"text-secondary-text mx-2",children:"/"}))(i.map(((e,t)=>n(Fe,{...k({router:l,handlerDecorator:s},{className:"text-secondary-text",...e})},String(t)))))}):null,n(He,{...e})]})})),Ge=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(He,{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 Ue=a((e=>{const{benefits:t,version:a}=e;return n(V,{...e,children:r("div",{className:"flex mt-5 mb-1",children:[t?.length?n("div",{className:"mr-8",children:t.map(We)}):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 We(e,t){return n("div",{className:"text-xl font-medium "+(t?"mt-2.5":""),children:e.description},String(t))}const Je=a((({className:e,context:t,title:a="Акции и спецпредложения",date:i,description:l,buttons:s=[],version:c})=>n(V,{className:e,context:t,title:a,buttons:s,version:c,children:r("div",{children:[i&&n("div",{className:"text-sm mb-2",children:Xe(i)}),n("div",{className:"text-base",children:l})]})})));function Xe(e){return new Date(e).toLocaleString("ru-RU",{day:"numeric",month:"long",year:"numeric"}).replace("г.","")}const Qe=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(o,{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:ze(n("div",{className:"h-0.5 w-full bg-secondary-light"}))(a.map(((e,t)=>qe(e,t))))}),n("div",{className:"flex mt-9 justify-between gap-x-24",children:a.map(Ke)})]}):null]}))),qe=(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(s,{name:e.icon,width:"48",height:"48"})||n("span",{className:"font-medium text-title-sm text-secondary-text",children:t+1})})},String(t)),Ke=(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)),Ye={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"}},et=a((({title:e,description:t,blockVersion:a="primary",iconVersion:i,image:l,className:s})=>{const c=Ye[a];return r("section",{className:`font-sans px-9 py-4 flex ${c.background} ${s||""}`,children:[i&&"small"===i?tt(c.icon):null,i&&"big"===i?nt(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 tt(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 nt(e){return e?.src?n(T,{className:"pt-0.5 pr-3",image:e}):null}const rt=a((({children:e})=>n("div",{className:"self-start flex flex-col",role:"row",children:n("div",{className:"flex",children:e})}))),at="bg-gradient-to-r from-main-gradient-start to-main-gradient-end",it="border-main-stroke border-solid border",lt="border-main-divider border border-t-0 border-x-0",st="w-[200px] mr-6",ct=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})}))),ot=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 ${it} ${at}`,role:"columnheader",scope:"col",children:[e&&!t?.src&&n(s,{className:"h-[63px] w-[63px] min-w-[63px] min-h-[63px] mb-4",name:e,width:"63",height:"63"}),t?.src&&n(T,{className:"mb-4",image:t}),a&&n(o,{size:"S",className:"font-medium m-0 text-center text-white",children:a}),i?.text&&n("div",{className:"mt-auto w-full",children:n(D,{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})})})]}))),mt=a((({cell:e,isFirstRow:t,isLastRow:r,isFillGradient:a})=>n("div",{className:`w-80 box-border flex flex-col ${it} ${r?"border-t-0 rounded-b-md":"border-y-0"} ${a?at:""}`,role:"cell",children:n("div",{className:`mx-7 h-full ${lt} ${a&&t?"border-t":""} ${r?"":"border-solid"}`,children:e.map(((e,t)=>dt(e,t,a)))})}))),dt=({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)),ht=a((({row:{header:e,data:t},activeCardIndex:a,isColoredFirstColumn:i,isFirstRow:l,isLastRow:s})=>r(rt,{children:[e?.title?n("div",{className:`text-sm py-7 ${lt} w-[200px] mr-6 ${s?"":"border-solid"}`,children:e.title}):null,t?.length?n(ct,{activeCardIndex:a,children:t.map(((e,t)=>n(mt,{cell:e,isFirstRow:l,isLastRow:s,isFillGradient:i&&0===t},String(t))))}):null]}))),xt=a((({className:e,context:t,title:a,rowHeaders:i,columns:l,visibleRowLength:s=0,isColoredFirstColumn:c=!1})=>{const m=t.useRouter(),{handlerDecorator:d}=t,[h,x]=t.useState(0),[u,p]=t.useState(!s),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:s),N=b?.length&&b.length>2,v=N&&b?.length-h>2,y=N&&h>0;return r("section",{className:`bg-white font-sans py-[50px] pl-[50px] overflow-hidden text-primary-text relative ${e||""}`,children:[n(o,{className:"font-medium m-0 max-w-[47rem] text-center mb-9 mx-auto",children:a}),r("div",{role:"table",children:[f?.length?r(rt,{children:[n("div",{className:st,role:"columnheader",scope:"col"}),n(ct,{activeCardIndex:h,children:f.map(((e,t)=>n(ot,{...e,link:e.link&&k({router:m,handlerDecorator:d},e.link)},String(t))))})]}):null,g?.length?r("div",{className:"relative",children:[g.map(((e,t,{length:r})=>n(ht,{row:e,isFirstRow:0===t,isLastRow:t+1===r,activeCardIndex:h,isColoredFirstColumn:c},String(t)))),N?n("div",{children:r("div",{className:"absolute top-7 right-7 z-10",children:[n(we,{onClick:()=>x(h+1),disabled:!v,ariaLabel:"Пролистать вправо"}),n(we,{className:"mt-4 rotate-180",onClick:()=>x(h-1),disabled:!y,ariaLabel:"Пролистать влево"})]})}):null]}):null]}),N?n("div",{className:"absolute top-0 right-0 bottom-0 w-[84px] bg-opacity-to-white"}):null,s?n("div",{className:"pr-[50px]",children:r("div",{className:"flex w-full",children:[n("div",{className:st}),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]})})),ut={TextBlock:et},pt=a((({label:e,blocks:t,context:a})=>{const[i,l]=a.useState(!1),c=t?.length,o=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 "+(c?"group cursor-pointer":""),onClick:e=>{if(!c)return null;l(!i);const t=bt(e);t.style.maxHeight=t.style.maxHeight?null:`${t.scrollHeight}px`},children:[n("span",{className:"m-0 text-xl pr-2.5 font-medium "+(c?"group-hover:text-primary-main":""),children:e}),c?n(s,{name:o,width:"24",height:"24"}):null]}),c?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)=>ft(e,t,a))):null}):null]})})),ft=(e,t,r)=>{if(!e.type||!e.data||!ut.hasOwnProperty(e.type))return null;const a=ut[e.type];return n("div",{className:"mb-5 last:mb-0",children:n(a,{context:r,...e.data})},`block_${t}`)},bt=e=>"BUTTON"===e.target.tagName?e.target.nextSibling:e.target.parentNode.nextSibling,gt=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(o,{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(pt,{...e,context:a},`AccordionItem${t}`)))}):null]})));function Nt(e,t){const{data:n}=e(vt(t),(()=>async function(e){const t=await fetch(vt(e));return await t.json()}(t)));return n||{}}function vt(e){return`/wcms-resources/${e||"credit-calculator-data"}.json`}const yt=[{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"}],wt=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(q,{paths:yt,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]})}))),kt=e=>new Intl.NumberFormat("ru-RU",{maximumSignificantDigits:3}).format(e),$t=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:kt(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))))})]})})),St=(e,t,n)=>Math.max(t,Math.min(e,n)),Ct=3e4,_t=3e6,jt=Math.round(41.5),Lt=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:Nt(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):jt,f=x?.minSum||Ct,b=x?.maxSum||_t,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=St(a,t.minSum||Ct,t.maxSum||_t);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(St(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($t,{title:"Желаемая сумма кредита, ₽",items:[`От ${kt(f)} рублей`,`До ${kt(b)} рублей`],min:f,max:b,step:1e3,value:i||u,onChange:l}),n($t,{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(wt,{text:"Получаю пенсию на карту Россельхозбанка",checked:o,onChange:m}),n(wt,{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:[kt(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(D,{className:"mr-3",text:"Отправить заявку",version:"primary",href:"#"}),n("div",{className:"w-80 text-xxs leading-4 text-secondary-text","aria-label":"Соглашение на обработку персональных данных",children:"Отправляя заявку, вы соглашаетесь на обработку персональных данных соответственно требованиям ФЗ «О персональных данных»"})]})]})})}));const Dt={Header:Ie,Footer:ve,Placeholder:Pe,Tile:V,PromoTile:Je,TextBlock:et,ProductTile:Ue,ProductBlock:Ee,StepsBlock:Qe,BenefitsBlock:d,ProductGallery:Ge,ExchangeRateTile:G,MobileAppTile:Ae,Gallery:je,MiniGallery:Me,ComparisonTable:xt,Accordion:gt,CreditCalculator:Lt},Rt=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:Tt()}))),Tt=()=>{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"})]})},It=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(Rt,{onClick:a.like,ariaLabel:"Поставить отметку «лайк»"}),n(Rt,{onClick:a.dislike,className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),n("span",{className:"select-none",children:a.likeCount})]})})),Mt=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),At=a((({className:e,context:t,blocksRegistry:a,data:{style:i,blocks:l,likeControl:s,colorPalette:c="pc"},blockDecorator:o=Mt})=>r("section",{className:"relative","data-theme":c,children:[n("div",{className:`grid grid-cols-12 gap-1 ${Pt(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]||Pe;return o({blockClassName:Pt(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(It,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:t})})]})));function Pt(e){return e?e.join(" "):""}const Bt=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 Ot(e){const{mobile:t}=e;return t?{...e,style:t.style?.length?t.style:e.style}:e}const Vt=a((({className:e,context:t})=>n("footer",{className:`${e} px-9 py-2 bg-white rounded-bl-3xl rounded-br-3xl`,children:n(ge,{context:t})}))),Ht=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(o,{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(Zt)})]})));function Zt(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(T,{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?Ft(e.items):null]}),e.href?n(D,{className:"mt-6",text:"Подробнее",version:"secondary",href:e.href}):null]},t)}function Ft(e=[]){return n("section",{className:"max-w-[308px] mt-2",role:"list",children:e.map(((e,t)=>n(C,{children:n("span",{className:"text-sm text-secondary-text",children:e})},String(t))))})}const zt=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(He,{...a,titleSize:"L"})})})),Et={Header:Ie,Footer:Vt,Placeholder:Pe,Tile:V,ProductTile:Ue,ProductBlock:zt,TextBlock:et,ExchangeRateTile:G,MobileAppTile:Ae,Gallery:Ht};e.Blocks=Dt,e.ContentPage=At,e.ContentPageHead=Bt,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=Et,e.joinList=ze,e.projectSettings=l,e.setup=t,e.toMobilePage=function(e){const t=e.blocks?.filter((({mobile:e})=>!e?.hidden)).map(Ot);return{...e,blocks:t}},e.url=y,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;AAGxC,mDAAgD;AAChD,oDAAiD;AAIpC,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
+ {"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,14 +1,33 @@
1
1
  import type { TextBlockContent } from '../TextBlock/TextBlockContent';
2
- export interface AccordionContent {
3
- title?: string;
4
- accordionItems?: AccordionItemContent[];
2
+ /** @title Содержимое блока */
3
+ export declare type AccordionDataContent = TextBlockContent;
4
+ /**
5
+ * @title Тип блока
6
+ * @enumNames ["Текстовый блок"]
7
+ */
8
+ export declare type AccordionDataBlocks = 'TextBlock';
9
+ /**
10
+ * Блок
11
+ */
12
+ export interface AccordionBlock {
13
+ type?: AccordionDataBlocks;
14
+ data?: AccordionDataContent;
5
15
  }
6
- export interface AccordionItemContent {
16
+ /**
17
+ * @title Элемент списка
18
+ */
19
+ export interface AccordionItemCommonProps {
20
+ /** @title Название */
7
21
  label?: string;
8
- blocks?: AccordionBlockContent[];
22
+ /** @title Блоки */
23
+ blocks?: AccordionBlock[];
24
+ }
25
+ /**
26
+ * @title Аккордеон
27
+ */
28
+ export interface AccordionContent {
29
+ /** @title Заголовок */
30
+ title?: string;
31
+ /** @title Список */
32
+ accordionItems?: AccordionItemCommonProps[];
9
33
  }
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 { AccordionItemContent } from './AccordionContent';
3
- export interface AccordionItemProps extends AccordionItemContent, UniBlockProps {
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(renderComponent) : null })) : null] }));
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
- // TODO: draft, for dynamic rendering of components
27
- const renderComponent = (block, i) => {
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 = block.type && AccordionBlocks_1.default[block.type];
32
- return ((0, jsx_runtime_1.jsx)("div", { className: "mb-5 last:mb-0", children: (0, jsx_runtime_1.jsx)(AccordionBlock, { ...block.data }) }, `component${i}`));
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;AAGxC,iDAA8C;AAC9C,wEAAgD;AAInC,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,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AAC,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
- export interface BaseTileProps extends BaseTileContent, UniBlockProps {
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,12 +2,12 @@ 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
12
  const TITLE_CLASSES = 'font-medium m-0 mb-4 whitespace-pre-wrap max-w-[600px]';
13
13
  exports.BaseTile = (0, uni_jsx_1.JSX)(({ className, context, title, titleSize, description, children, buttons, image, items, version = 'primary', }) => {
@@ -1 +1 @@
1
- {"version":3,"file":"BaseTile.js","sourceRoot":"","sources":["../../../src/components/BaseTile/BaseTile.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAIxC,gEAA6D;AAC7D,uDAAoD;AAEpD,iDAA8C;AAC9C,0CAAuC;AACvC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eAAM,OAAqB,MAAM,IAArB,MAAM,CAAC,CAAC,CAAC,CAAgB,CAAC;AAChD,CAAC"}
@@ -0,0 +1,31 @@
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
+ export interface BaseTileIconButton extends ButtonWithIconProps {
7
+ icon?: IconName;
8
+ }
9
+ /**
10
+ * @title Плитка
11
+ */
12
+ export interface BaseTileCommonProps {
13
+ /** @title Заголовок */
14
+ title?: string;
15
+ /**
16
+ * @title Размер заголовка
17
+ * @default M
18
+ */
19
+ titleSize?: TitleSize;
20
+ /** @title Описание */
21
+ description?: string;
22
+ image?: Picture;
23
+ /** @title Список */
24
+ items?: string[];
25
+ /**
26
+ * @title Кнопки
27
+ * @maxItems 4
28
+ */
29
+ buttons?: BaseTileIconButton[];
30
+ version?: BlockVersion;
31
+ }
@@ -1,2 +1,2 @@
1
1
  Object.defineProperty(exports, "__esModule", { value: true });
2
- //# sourceMappingURL=SitemapContent.js.map
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)("h2", { className: "font-medium text-title m-0 max-w-[47rem] text-center", children: title }), benefits?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "grid grid-cols-2 gap-5 mt-9", children: benefits.map(renderStep) })) : null] }));
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;AAGxC,iDAA8C;AAIjC,QAAA,aAAa,GAAG,IAAA,aAAG,EAAqB,CAAC,EAAE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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"}
@@ -1,10 +1,23 @@
1
1
  import type { IconName } from '../../ui-kit/Icon/IconProps';
2
+ /**
3
+ * @title Преимущество
4
+ */
2
5
  export interface Benefit {
3
- label: string;
6
+ /** @title Название */
7
+ label?: string;
8
+ /** @title Описание */
4
9
  description?: string;
5
10
  icon?: IconName;
6
11
  }
12
+ /**
13
+ * @title Блок преимущества
14
+ */
7
15
  export interface BenefitsBlockContent {
16
+ /** @title Заголовок */
8
17
  title?: string;
18
+ /**
19
+ * @title Список преимущества
20
+ * @maxItems 6
21
+ */
9
22
  benefits?: Benefit[];
10
23
  }
@@ -1,4 +1,5 @@
1
1
  import type { BenefitsBlockContent } from './BenefitsBlock/BenefitsBlockContent';
2
+ import type { ComparisonTableContent } from './ComparisonTable/ComparisonTableContent';
2
3
  import type { ExchangeRateTileContent } from './ExchangeRateTile/ExchangeRateTileContent';
3
4
  import type { FooterContent } from './Footer/FooterContent';
4
5
  import type { GalleryContent } from './Gallery/GalleryContent';
@@ -12,5 +13,7 @@ import type { PromoTileContent } from './PromoTile/PromoTileContent';
12
13
  import type { StepsBlockContent } from './StepsBlock/StepsBlockContent';
13
14
  import type { TextBlockContent } from './TextBlock/TextBlockContent';
14
15
  import type { TileContent } from './Tile/TileContent';
15
- import type { ComparisonTableContent } from './ComparisonTable/ComparisonTableContent';
16
+ /**
17
+ * @hidden
18
+ */
16
19
  export declare type BlockContent = HeaderContent | FooterContent | PlaceholderContent | TileContent | PromoTileContent | TextBlockContent | ProductTileContent | ProductBlockContent | StepsBlockContent | BenefitsBlockContent | ProductGalleryContent | ExchangeRateTileContent | MobileAppTileContent | GalleryContent | ComparisonTableContent;