@redneckz/wildless-cms-uni-blocks 0.3.10 → 0.3.11

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 (35) hide show
  1. package/bundle/bundle.umd.js +1 -1
  2. package/bundle/bundle.umd.min.js +1 -1
  3. package/dist/components/Header/Header.mobile.js +1 -1
  4. package/dist/components/Header/Header.mobile.js.map +1 -1
  5. package/dist/components/ProductBlock/ProductBlockInner.js +1 -1
  6. package/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
  7. package/dist/components/ProductBlock/ProductBlockInner.mobile.js +1 -1
  8. package/dist/components/ProductBlock/ProductBlockInner.mobile.js.map +1 -1
  9. package/lib/components/Header/Header.mobile.js +1 -1
  10. package/lib/components/Header/Header.mobile.js.map +1 -1
  11. package/lib/components/ProductBlock/ProductBlock.fixture.mobile.d.ts +2 -1
  12. package/lib/components/ProductBlock/ProductBlockInner.js +1 -1
  13. package/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
  14. package/lib/components/ProductBlock/ProductBlockInner.mobile.js +1 -1
  15. package/lib/components/ProductBlock/ProductBlockInner.mobile.js.map +1 -1
  16. package/mobile/bundle/bundle.umd.js +2 -2
  17. package/mobile/bundle/bundle.umd.min.js +1 -1
  18. package/mobile/dist/components/Header/Header.js +1 -1
  19. package/mobile/dist/components/Header/Header.js.map +1 -1
  20. package/mobile/dist/components/ProductBlock/ProductBlockInner.js +1 -1
  21. package/mobile/dist/components/ProductBlock/ProductBlockInner.js.map +1 -1
  22. package/mobile/lib/components/Header/Header.js +1 -1
  23. package/mobile/lib/components/Header/Header.js.map +1 -1
  24. package/mobile/lib/components/ProductBlock/ProductBlockInner.js +1 -1
  25. package/mobile/lib/components/ProductBlock/ProductBlockInner.js.map +1 -1
  26. package/mobile/src/components/Header/Header.tsx +1 -1
  27. package/mobile/src/components/ProductBlock/ProductBlock.example.json +11 -1
  28. package/mobile/src/components/ProductBlock/ProductBlockInner.tsx +5 -5
  29. package/package.json +1 -1
  30. package/src/components/Header/Header.mobile.tsx +1 -1
  31. package/src/components/ProductBlock/ProductBlock.example.json +11 -1
  32. package/src/components/ProductBlock/ProductBlock.fixture.mobile.tsx +57 -32
  33. package/src/components/ProductBlock/ProductBlock.fixture.tsx +57 -104
  34. package/src/components/ProductBlock/ProductBlockInner.mobile.tsx +5 -5
  35. package/src/components/ProductBlock/ProductBlockInner.tsx +4 -4
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniMobileBlocks={})}(this,(function(e){"use strict";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={h1:"text-m-title",h2:"text-m-title",h3:"text-m-title-md",h4:"text-m-title-xs",h5:"text-m-title-xs",h6:"text-m-title-xs"},s=a((e=>{const{className:t,headingType:r,title:a}=e;if(!r)return;return n(r,{className:`font-sans font-medium m-0 ${l[r]} ${t||""}`,children:a})})),c=new class{_={PROD_BRANCH:"master",FORCED_DRAFT_FLOW:!1};setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ENABLE_ASSIST(){return this._.ENABLE_ASSIST}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}},o={none:"",primary:"text-primary-main"},m=a((({className:e="",name:t,alt:a=`Icon ${t}`,title:i=a,asSVG:l,color:s="primary",...m})=>{const d=`${c.CDN||""}icons/${t}.svg`;return l?r("svg",{className:`${o[s]} ${e}`,...m,"aria-hidden":"true",children:[i?n("title",{children:i}):null,a?n("desc",{children:a}):null,n("use",{href:`${d}#icon`,xlinkHref:`${d}#icon`})]}):n("img",{className:e,src:d,alt:a,title:i,...m,"aria-hidden":"true"})})),d=a((({className:e="",image:t})=>{if(!t)return null;const a={width:t.size?.width?`${t.size?.width}px`:"100%",height:t.size?.height?`${t.size?.height}px`:"100%"};return r("picture",{className:e,children:[t.sources?.length?t.sources.map((({src:e,format:t},r)=>n("source",{srcSet:e,type:h(t)},`${r}_${e}`))):null,n("img",{src:t.src,className:`m-auto ${t.className||""}`,alt:t.alt||t.title,title:t.title,style:a,...t.size})]})}));function h(e){return e?`image/${String(e)}`:void 0}const x=a((({bgColor:e="transparent",className:t="",title:a,description:i,image:l})=>r("section",{className:`px-4 py-6 ${e} ${t}`,children:[a&&n(s,{headingType:"h2",className:"text-primary-text",title:a}),i&&n("p",{className:"font-normal text-m-md "+(a?"mt-2.5":""),children:i}),l?.src&&n("div",{className:"mt-5 mx-auto flex justify-center",children:n(d,{image:l})})]}))),p=a((({children:e,activeIndex:t,indexFraction:r,showDots:a})=>a&&e?.length?n("div",{className:"flex gap-2 mx-auto mt-5 w-fit",children:e?.map(((e,a)=>n("div",{className:"bg-primary-main opacity-30 w-1.5 h-1.5 min-w-1.5 min-h-1.5 rounded-full",style:u(a,t,r),"aria-hidden":!0},String(a))))}):null)),u=(e,t,n)=>{if(e<t||e>t+1)return null;const r=1-n;return e===t?{opacity:""+(.3+.7*r),width:6+16*r+"px"}:{opacity:""+(.3+.7*n),width:6+16*n+"px"}},f=a((({className:e="",children:t,...r})=>n("div",{className:`snap-center snap-always min-w-full box-border ${e}`,role:"listitem",...r,children:t}))),b=e=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e}px`}),g=a((({className:e="",children:t,activeIndex:r,onScroll:a,gap:i=14,padding:l=16})=>n("div",{className:`overflow-auto flex horizontal-list no-scrollbar ${e}`,style:{...b(l),gap:`${i}px`},role:"list",onScroll:a,children:t?.length?t?.map(((e,t)=>n(f,{style:b(l/4),"aria-current":Boolean(r===t),children:e},String(t)))):n(f,{children:t})}))),N=a((({className:e,context:t,children:n,gap:a=14,padding:i=16,showDots:l=!0,onSlideChange:s})=>{const[c,o]=t.useState(0),[m,d]=t.useState(0);return r("div",{className:e,children:[y({gap:a,padding:i,activeIndex:c,handleScroll:e=>{const{scrollLeft:t,clientWidth:n,childElementCount:r,scrollWidth:l,children:m}=e.currentTarget,h=m[0].offsetWidth-i/2,x=(({gap:e,padding:t,clientWidth:n,scrollWidth:r,childElementCount:a,itemWidth:i})=>{const l=i+e,s=r-n,c=n-e-t,o=a-2,m=new Array(a).fill(0).map(((e,t)=>0===t||t===o?[t>0?s-c:0,t>0?s:c]:[(t-1)*l+c,t*l+c]));return m[a-1]=[s,r],m})({gap:a,padding:i,clientWidth:n,scrollWidth:l,childElementCount:r,itemWidth:h}),{index:p,fraction:u}=((e,t)=>{const n=t.findIndex((([t,n])=>t<=e&&e<n));if(n<0)return{index:n,fraction:0};const[r,a]=t[n];return{index:n,fraction:(e-r)/(a-r)}})(t,x);p!==c&&s&&s(),o(p),d(u)},children:n}),v({activeIndex:c,indexFraction:m,showDots:l,children:n})]})})),y=({gap:e,padding:t,activeIndex:r,handleScroll:a,children:i})=>n(g,{gap:e,padding:t,activeIndex:r,onScroll:a,children:i}),v=({activeIndex:e,indexFraction:t,showDots:r,children:a})=>n(p,{activeIndex:e,indexFraction:t,showDots:r,children:a}),w=a((({className:e,iconClassName:t,textClassName:a,suffixClassName:i,doc:l,icon:s})=>{const{text:c,fileSize:o,...d}=l;return r("a",{className:e,role:"link",...d,children:[s?n(m,{className:t,name:s,width:"24px",height:"24px",asSVG:!0}):null,c?r("span",{className:a,children:[c,n("span",{className:i,children:d?.href&&k($(d.href),o)})]}):null]})})),k=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),$=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},S=a((({className:e="",doc:t,icon:r})=>n(w,{className:`flex h-full box-border ${e}`,iconClassName:"mr-3 min-w-6 min-h-6",doc:t,icon:r}))),C=a((({context:e,hasBorder:t=!0,documents:r,icon:a})=>n(N,{context:e,className:"text-m-sm text-primary-main",children:r?.length?r.map(((e,r)=>n(S,{className:t?"rounded-md border-main-stroke border p-4":"",doc:e,icon:a},String(r)))):null}))),T=a((({hasBorder:e=!0,documents:t,icon:r})=>n("div",{className:"text-m-sm text-primary-main flex flex-col "+(e?"gap-3.5":"gap-2"),role:"list",children:t?.length?t.map(((t,a)=>n("div",{role:"listitem",children:n(S,{className:e?"rounded-md border-main-stroke border p-4":"",doc:t,icon:r})},String(a)))):null}))),_=a((({className:e="",context:t,title:a,subtitle:i,icon:l="DocIconMonoColor",documents:c,listMode:o="vertical",hasBorder:m=!0})=>r("section",{className:`font-sans text-primary-text py-6 px-4 bg-white ${e}`,children:[a?n(s,{headingType:"h2",className:"text-center "+(i?"mb-2":"mb-5"),title:a}):null,i?n("h3",{className:"mt-0 font-normal mb-5 text-center text-m-md",children:i}):null,"vertical"===o?n(T,{hasBorder:m,documents:c,icon:l}):n(C,{context:t,hasBorder:m,documents:c,icon:l})]}))),j=a((({className:e="",title:t,image:a,benefits:i})=>r("section",{className:`relative font-sans text-primary-text bg-white p-14 ${e}`,children:[n(s,{headingType:"h2",className:"text-center",title:t}),r("div",{className:"flex justify-center mt-9",children:[a?.src&&n(d,{className:"mr-6",image:a}),i?.length?n("div",{className:"flex flex-col",children:i.map(D)}):null]})]})));function D(e,t){return r("div",{className:"flex flex-row mb-8",children:[e.icon&&n(m,{className:"w-[48px] h-[48px] bg-main rounded-full box-border p-[12px]",name:e.icon,width:"48",height:"48",asSVG:!0}),r("div",{className:"flex gap-1 flex-col h-full ml-5 max-w-[490px]",children:[e.label&&n("div",{className:"font-medium text-primary-text text-xl m-0",children:e.label}),e.description&&n("div",{className:"font-normal text-sm text-secondary-text",children:e.description})]})]},String(t))}const I={primary:"text-primary-text",secondary:"text-white",gray:"text-secondary-text"},L={primary:"bg-primary-main",secondary:"bg-white",gray:"bg-secondary-text"},B=a((({className:e="",isDotted:t=!0,children:a,version:i="primary"})=>r("div",{className:`font-sans flex items-start ${e}`,role:"listitem",children:[t&&n("div",{className:R(i)}),n("span",{className:`text-m-md ${I[i]}`,children:a})]}))),R=e=>`rounded-full inline-block mr-3 mt-2 ${L[e]} ${"gray"===e?"w-[6px] h-[6px] min-w-[6px] min-h-[6px]":"w-2 h-2 min-w-2 min-h-2"}`,V=a((e=>{const{className:t="",itemClassName:r,isDotted:a,items:i,version:l}=e;return n("section",{className:`${t}`,role:"list",children:i?.length?i.map(((e,t)=>n(B,{className:r,isDotted:a,version:l,children:e},String(t)))):null})})),A={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"}},O=a((({title:e,description:t,blockVersion:a="primary",iconVersion:i,image:l,className:s="",items:c,isDotted:o=!0})=>{const m=A[a];return r("section",{className:`font-sans px-4 py-[18px] flex flex-col ${m.background} ${s}`,children:["small"===i?M(m.icon):null,"big"===i?P(l):null,r("div",{className:"py-0.5",children:[e?n("div",{className:`font-medium text-base mb-1 ${m.title}`,children:e}):null,t?n("div",{className:`text-sm ${m.description}`,children:t}):null,c?.length?n(V,{items:c,isDotted:o,version:"gray",className:"mt-1 text-m-sm text-secondary-text"}):null]})]})}));function M(e){return n("div",{className:"mb-3",children:n("div",{className:`rounded-full h-4 w-4 text-center text-xs ${e}`,children:"i"})})}function P(e){return e?.src?n(d,{className:"pb-3 mr-auto",image:e}):null}const Z=e=>e?.includes("//"),H=e=>(e||"").replace(/\/?\?.*/,""),z=e=>{if(!e||!Z(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t};var E=Object.freeze({__proto__:null,isURL:Z,withoutQuery:H,getOrigin:z});const G="/mobile",F=(e,t)=>{if(!e)return e;const n=z(t?.href);return n?e.replace(n,"")||"/":e},W=e=>e;function U({router:e,handlerDecorator:t=W},n){const r=((e,t)=>{if(!e)return e;const n=F(e,t)||"",r=t?.pathname.startsWith(G);return r&&!Z(n)?`/mobile${n}`:n})(n.href,e);return{...n,href:r,ariaLabel:n.text,onClick:t((t=>{const a=r&&!Z(r),i=!n.target||"_self"===n.target;a&&i&&(t.preventDefault(),e.push(r))}),n)}}const J=a((({text:e,aboveText:t,appendLeft:a,rounded:i,version:l})=>{const s=!e&&!t&&Boolean(a);return function({buttonInnerClasses:e,appendLeft:t,withoutText:a,aboveText:i,text:l}){return r("div",{className:e,children:[t||null,a?null:r("div",{children:[n("div",{className:"text-m-2xs text-left",children:i}),n("div",{className:"text-m-button font-medium text-left",children:l})]})]})}({buttonInnerClasses:"link"!==l?`flex items-center justify-center\n ${s?"h-12 w-12":"px-8 gap-2 "+(t?"py-2":"py-3.5")} ${i?"rounded-full":""}`:null,appendLeft:a,withoutText:s,aboveText:t,text:e})}));const K={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",link:"text-primary-main"},Q={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text",link:""},X="w-full text-center font-sans select-none",Y=a((({className:e,text:t,aboveText:r,appendLeft:a,href:i,target:l,onClick:s,children:c,disabled:o,rounded:m,version:d="primary",ariaLabel:h,...x})=>{const p=c??n(J,{text:t,aboveText:r,appendLeft:a,rounded:m,version:d});return o?n("div",{role:"button","aria-disabled":"true","aria-label":h,tabIndex:"-1",className:`inline-block ${X} ${Q[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,children:p}):n("a",{className:`${X} inline-block cursor-pointer no-underline ${K[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:s,"aria-label":h,role:i?"link":"button",...x,children:p})})),q=a((({context:e,className:t="",buttons:r})=>{const{handlerDecorator:a}=e,i=e.useRouter();return r?.length?n("div",{className:`${t}`,children:r.map(((e,t)=>function({icon:e,...t},r){if(!t?.text)return;return n(Y,e?{appendLeft:n(m,{name:e,width:"24",height:"24",asSVG:!0}),...t}:{...t},String(r))}(U({router:i,handlerDecorator:a},e),t)))}):null}));const ee=a((e=>{const{className:t="",description:r}=e;return n("div",{className:`font-normal text-m-md ${t}`,children:r})})),te=a((({className:e="",title:t,children:a,buttons:i,image:l})=>r("div",{className:`font-sans flex flex-col grow h-full items-start ${e}`,children:[t,r("div",{className:"flex grow w-full justify-between",children:[r("div",{className:"flex flex-col justify-between w-full",children:[n("div",{children:a}),n("div",{children:i})]}),l]})]}))),ne=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12};function re(e=""){const t=ne(e);return t<=4?"h4":t<=8?"h3":"h2"}function ae(e=""){const t=ne(e);return t<=6?"min-h-[300px]":t<=8?"min-h-[320px]":"min-h-[360px]"}function ie(e=""){const t=ne(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const le={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},se=a((e=>{const{context:t,title:a,description:i,items:l,children:c,buttons:o,image:m,className:h="",version:x="primary",role:p}=e;return n("section",{className:`overflow-hidden font-sans p-9 box-border ${h} ${le[x]} ${ie(h)} ${ae(h)} `,role:p,children:r(te,{context:t,title:a&&n(s,{headingType:re(h),title:a,className:`whitespace-pre-wrap max-w-[600px] ${a?"mb-3":""}\n ${"primary"===x?"text-primary-text":""}`}),buttons:o?.length?n(q,{context:t,buttons:o,className:"flex mt-9 gap-3"}):null,image:m?.src&&n(d,{className:"mt-auto ml-7",image:m}),children:[i&&n(ee,{className:"mt-4 max-w-[600px]",description:i}),c,ce(l,x)]})})}));function ce(e,t){return e?.length?n(V,{items:e,version:t}):null}const oe={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},me=a((({context:e,className:t="",title:a,description:i,benefits:l,buttons:c,image:o,version:m="primary"})=>n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${t} ${oe[m]} ${ie(t)} ${ae(t)} `,children:r(te,{context:e,title:a&&n(s,{headingType:re(t),title:a,className:"whitespace-pre-wrap max-w-[600px]"}),buttons:c?.length?n(q,{context:e,buttons:c,className:"flex mt-9 gap-3"}):null,image:o?.src&&n(d,{className:"mt-auto ml-7",image:o}),children:[i&&n(ee,{className:"mt-4 max-w-[600px]",description:i}),r("div",{className:"flex mt-5 mb-1",children:[l?.length?n("div",{className:"mr-8",children:l.map(de)}):null,l?.length?n("div",{className:"pt-1",children:l.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.description},String(t))}(e,t,m)))}):null]})]})})));function de(e,t){return n("div",{className:"text-xl font-medium "+(t?"mt-2.5":""),children:e.label},String(t))}const he={primary:"bg-white",secondary:"bg-primary-main text-white"},xe=a((({context:e,title:t,description:a,cards:i=[],className:l,isScroll:c=!0})=>r("section",{className:`relative font-sans text-primary-text bg-white px-4 py-6 overflow-hidden ${l}`,children:[r("div",{className:"flex flex-col items-center mb-5",children:[n(s,{headingType:"h2",className:"text-center",title:t}),a?n("div",{className:"font-normal text-m-md max-w-[600px] mt-2",children:a}):null]}),pe(c,i,e)]})));function pe(e,t,r){return e?n(N,{context:r,children:t?.map(ue)}):n("div",{className:"grid gap-[14px]",children:t?.map(ue)})}function ue(e,t){return r("div",{className:`box-border horizontal-list-item border-solid border rounded-md border-main-stroke p-4 flex flex-col\n ${he[e.version??"primary"]}`,children:[r("div",{children:[e.image?.src?n("div",{className:"flex justify-center",children:n(d,{className:"mb-6",image:e.image})}):null,e.title?n("h4",{className:"font-medium text-m-title-xs m-0",children:e.title}):null,e.description?fe(e):null,e.items?.length?(i=e.items,n("section",{className:"mt-3",children:i.map(((e,t)=>r("div",{children:[n("span",{className:"text-m-md font-medium",children:e.title}),n("span",{className:"text-m-sm text-secondary-text pl-2",children:e.text})]},String(t))))})):null]}),e?.button?.text?(a=e.button,n(Y,{className:"mt-3",appendLeft:a?.icon&&n(m,{name:a?.icon,width:"24px",height:"24px",asSVG:!0}),...a})):null]},t);var a,i}function fe(e){return n("div",{className:"text-secondary-text mt-2 "+("secondary"===e.version?"text-white opacity-80":""),children:e.description})}const be=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)))}))),ge=[{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"}],Ne=a((({className:e,disabled:t,...r})=>n(Y,{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(be,{paths:ge,viewBox:"0 0 16 16",fill:"none",width:"16",height:"16"})}))),ye={primary:"bg-white text-secondary-text",secondary:"bg-primary-main text-white"},ve={normal:3,mini:4},we={normal:"min-w-[364px] w-[364px]",mini:"min-w-[260px] w-[260px]"},ke={normal:380,mini:276},$e={primary:"text-secondary-text",secondary:"text-white",gray:"text-secondary-text"},Se={primary:"bg-primary-main",secondary:"bg-white",gray:"bg-secondary-text"},Ce=a((({className:e="",isDotted:t=!0,text:a,children:i,version:l="primary"})=>r("div",{className:`font-sans flex items-start ${e}`,role:"listitem",children:[t&&n("div",{className:Te(l)}),n("span",{className:$e[l],children:a||i})]}))),Te=e=>`rounded-full inline-block mr-3 mt-2 ${Se[e]} ${"gray"===e?"w-[6px] h-[6px] min-w-[6px] min-h-[6px]":"w-2 h-2 min-w-2 min-h-2"}`,_e=a((({title:e,description:t,image:a,items:i,button:l,version:s})=>{const c=function(e,t,n){return`font-medium text-xl m-0\n ${"secondary"!==e?"text-primary-text":""}\n ${t||n?.length?"":"text-center"}\n `}(s,t,i);return r("div",{children:[r("div",{children:[a?.src?n("div",{className:"flex justify-center",children:n(d,{className:"mb-6",image:a})}):null,e?De(e,c):null,t?n("div",{className:"font-normal text-sm "+(e?"mt-2":""),children:t}):null,i?.length?Ie(i,s):null]}),l?.text?je(l):null]})}));function je(e){return n(Y,{className:"mt-6 w-full",appendLeft:e.icon&&n(m,{name:e.icon,width:"24px",height:"24px",asSVG:!0}),...e})}function De(e,t){return n("div",{className:`font-medium text-xl m-0 ${t}`,children:e})}function Ie(e,t){return n("section",{className:"max-w-[308px] mt-2",role:"list",children:e.filter((e=>e?.text)).map(((e,r)=>function(e,t,r){return n(Ce,{version:r??"primary",children:n("span",{className:"text-sm",children:e})},String(t))}(e.text,r,t)))})}const Le=a((({context:e,title:t,description:a,cards:i=[],version:l="normal",activeCardIndex:c})=>r("div",{children:[n("div",{className:"absolute top-0 left-0 bottom-0 w-[84px] bg-gradient-to-r from-white to-transparent"}),r("div",{className:"flex flex-col items-center mb-8",children:[t?n(s,{headingType:"h2",className:"text-center",title:t}):null,a?n("div",{className:"font-normal text-base max-w-[600px] mt-2.5",children:a}):null]}),n("div",{className:`flex ${i?.length<=ve[l]?"justify-center":""} duration-1000`,style:{transform:`translateX(-${c*ke[l]}px)`},role:"list",children:i?.map(((t,r)=>function({card:e,version:t},r){return n("section",{className:`box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between\n items-stretch ${we[t]} ${ye[e.version??"primary"]} w-full col-span-4`,role:"listitem",children:n(_e,{...e})},String(r))}({card:t,version:l,context:e},r)))})]})));const Be=a((({context:e,cards:t=[],className:a="",version:i="normal",...l})=>{const[s,c]=e.useState(0),o=t?.length>ve[i],m=o&&t?.length-s>ve[i],d=o&&s>0;return r("section",{className:`relative font-sans text-primary-text bg-white p-[50px] overflow-hidden ${a}`,children:[n(Le,{context:e,cards:t,version:i,activeCardIndex:s,...l}),d&&n(Ne,{className:"absolute top-1/2 left-8 rotate-180 z-10 mt-[25px]",onClick:()=>c(s-1),ariaLabel:"Пролистать влево"}),m&&n(Ne,{className:"absolute top-1/2 right-8 z-10 mt-[25px]",onClick:()=>c(s+1),ariaLabel:"Пролистать вправо"}),n("div",{className:"absolute top-0 left-0 bottom-0 w-[84px] bg-opacity-from-white"}),n("div",{className:"absolute top-0 right-0 bottom-0 w-[100px] bg-opacity-to-white"})]})})),Re=a((e=>n(Be,{...e,version:"mini"}))),Ve=a((({className:e="",documents:t})=>n("section",{className:`font-sans bg-white mt-[10px] ${e}`,children:n("ul",{className:"flex flex-col text-sm text-secondary-text p-0",children:t?.length?Ae(t):null})}))),Ae=e=>e.map(((e,t)=>{const{text:r,...a}=e;return n("li",{className:"mb-4 list-none",children:n("a",{className:"hover:text-primary-main",role:"link",...a,children:r||null})},`list_item_${String(t)}`)})),Oe={Headline:x,LinkDocs:_,TextBlock:O,PictureText:j,Tile:se,ProductTile:me,Gallery:xe,MiniGallery:Re,LinkList:Ve},Me=a((({blocks:e,context:t})=>n("div",{className:"transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0",children:e?.length?e.map(Pe(t)):null}))),Pe=e=>(t,r)=>{const a=t?.accordionBlockType;if(!a||!(a in Oe))return null;return n("div",{className:"mb-5 last:mb-0",children:n(Oe[a],{context:e,...t,className:"!p-0"})},`block_${r}`)},Ze=a((({label:e,blocks:t,bordered:a,context:i})=>{const{hasContent:l,icon:s,handleToggle:c}=(({context:e,blocks:t})=>{const[n,r]=e.useState(!1),a=t?.length;return{isActive:n,hasContent:a,icon:n?"MinusIcon":"PlusIcon",handleToggle:e=>{if(!a)return;r(!n);const t=(({currentTarget:e})=>e.nextSibling)(e);t.style.maxHeight=t.style.maxHeight?null:`${t.scrollHeight}px`}}})({context:i,blocks:t});return r("li",{className:(a?"border p-4 rounded mb-4":"border-0 border-b last:border-b-0")+" border-solid border-main-divider",children:[r("button",{className:`border-none bg-transparent flex justify-between text-left w-full font-sans text-primary-text\n ${a?"":"py-[14px] px-0"}\n ${l?"group cursor-pointer":""}`,onClick:c,children:[n("span",{className:"text-sm pr-2.5 font-medium "+(l?"group-hover:text-primary-main":""),children:e}),l?n(m,{name:s,width:"20",height:"20",asSVG:!0}):null]}),l?n(Me,{blocks:t,context:i}):null]})})),He=a((({title:e,description:t,accordionItems:a,context:i,className:l="",bordered:c})=>r("section",{className:`py-6 px-4 font-sans bg-white text-primary-text ${l}`,children:[e?n(s,{headingType:"h3",className:"mb-2 text-center",title:e}):null,t?n("div",{className:"mb-5 text-m-md text-center",children:t}):null,a?.length?n("ul",{className:"list-none m-0 p-0",children:a.map(((e,t)=>n(Ze,{...e,context:i,bordered:c},`AccordionItem${t}`)))}):null]}))),ze="https://www.cbr-xml-daily.ru/daily_json.js",Ee=["USD","EUR"],Ge={USD:"DollarIcon",EUR:"EuroIcon"},Fe=[{text:"Все показатели",href:"https://cbr.ru/currency_base/daily/",version:"secondary"}],We=a((({className:e="",context:t,title:a="Курсы обмена валют"})=>{const{data:i}=t.useAsyncData(ze,Ke);return n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${ie(e)} ${ae(e)} `,children:n(te,{context:t,title:a&&n(s,{headingType:re(e),title:a,className:"whitespace-pre-wrap max-w-[600px] "+(a?"mb-3":"")}),buttons:Fe?.length?n(q,{context:t,buttons:Fe,className:"flex mt-9 gap-3"}):null,children:r("table",{children:[n("thead",{children:r("tr",{children:[n(Ue,{children:"Валюта"}),n(Ue,{className:"pl-11",children:"Курс"})]})}),n("tbody",{children:Ee.map(Ye(i))})]})})})})),Ue=a((({className:e="",children:t})=>n("th",{className:`text-left font-normal text-sm text-secondary-text ${e}`,children:t}))),Je=a((({className:e="",children:t})=>n("td",{className:`text-left font-normal text-base text-primary-text ${e}`,children:t})));async function Ke(){const e=await fetch(ze);return await e.json()}const Qe=new Intl.NumberFormat("ru",{style:"currency",currency:"RUB"}),Xe=e=>e?Qe.format(e):"",Ye=e=>t=>{const a=(e?.Valute||{})[t]?.Value;return r("tr",{children:[n(Je,{className:"pt-4",children:r("div",{className:"flex items-center",children:[n(m,{name:Ge[t],width:"24",height:"24"}),n("span",{className:"ml-2",children:t})]})}),n(Je,{className:"pt-4 pl-11",children:Xe(a)})]},t)},qe=["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"],et={"bg-white":"text-primary-main",transparent:"text-white"},tt={"bg-white":"text-black",transparent:"text-white"},nt=a((({className:e="",href:t,children:a,targetBlank:i,bgColor:l="bg-white",hideTitle:s})=>r("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"https://rshb.ru/",target:i?"_blank":"_self","aria-label":"Россельхозбанк",children:[n(be,{className:`${et[l]} w-10 h-[38px]`,viewBox:"0 0 40 45",paths:qe.map((e=>({d:e})))}),!s&&n("span",{className:`${tt[l]} text-sm font-medium ml-2.5`,children:a||"Россельхозбанк"})]}))),rt=a((({className:e,title:t="Мобильное приложение",description:a,href:i="#"})=>n("div",{className:`col-span-12 rounded-md cursor-pointer p-4 mt-6 mb-6 bg-secondary-light ${e||""}`,children:i?r("div",{className:"flex",children:[n("div",{className:"flex justify-center align-middle rounded-md bg-primary-main w-[50px] h-[50px]",children:n(nt,{className:"w-[33px]",bgColor:"transparent",hideTitle:!0})}),r("a",{href:i,target:"_blank",className:"flex flex-col justify-center pl-3",children:[n("div",{className:"text-m-button font-medium mb-[3px]",children:t}),n("div",{className:"text-m-button text-secondary-text",children:a})]})]}):null}))),at=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(it):null,a?n(Y,{version:"primary",className:"mt-0.5 mb-5",...U({router:l,handlerDecorator:s},{text:"Обратная связь",href:"/",target:"_blank"})}):null]})})),it=(e,t)=>{const{type:a,text:i,description:l}=e;return r("div",{className:"mb-3.5",children:[n("div",{children:lt(a,i)}),n("div",{className:"font-sans text-sm text-secondary-text",children:l})]},String(t))},lt=(e,t="")=>{switch(e){case"tel":return n("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`tel:${st(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})}},st=e=>e.replaceAll(/\D/g,""),ct=a((({title:e,links:t,className:a="",context:i})=>{const l=i.useRouter(),{handlerDecorator:s}=i;return r("div",{className:a,children:[n("span",{className:"text-primary-text font-sans font-medium text-sm",children:e}),t?.length?n("div",{className:"flex flex-col gap-2 pt-3",children:t.map(((e,t)=>n(ot,{index:t,...U({router:l,handlerDecorator:s},e)},String(t))))}):null]})})),ot=a((({className:e="",index:t,text:r,href:a,target:i,onClick:l})=>n("a",{className:`font-sans font-normal text-sm text-secondary-text hover:text-primary-main inline-block no-underline ${e}`,href:a,target:i,onClick:l,children:r||`Документ ${t}`}))),mt=[{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"}],dt=a((({href:e})=>{const{icon:t,width:r,height:a,label:i}=mt.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};return t?n("a",{className:"flex items-center justify-center border border-solid border-main-divider rounded-full no-underline outline-none w-[38px] h-[38px] hover:text-primary-main",href:e,"aria-label":i,target:"_blank",rel:"noopener noreferrer",children:m&&n(m,{name:t,width:r,height:a,asSVG:!0,className:"block",color:"none"})}):null})),ht=a((({className:e,media:t,context:r})=>{const a=r.useRouter(),{handlerDecorator:i}=r;return n("div",{className:`flex gap-2 items-start justify-start pt-6 pb-6 ${e||""}`,children:t?.map(((e,t)=>n(dt,{...U({router:a,handlerDecorator:i},e)},String(t))))})})),xt=a((({className:e,links:t,context:a})=>{const i=a.useRouter(),{handlerDecorator:l}=a;return r("div",{className:`${e||""}`,children:[n("div",{className:"py-6",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 flex-col justify-start items-start gap-2",children:t.map(((e,t)=>n(pt,{index:t,...U({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),pt=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}`}))),ut=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-[20px] h-[20px]",children:n(m,{name:"LoupeIcon",width:"24",height:"24"})}),!a&&n("label",{htmlFor:"search-bar-input",className:"font-sans font-normal text-sm text-secondary-text",children:"Поиск по сайту"})]}),n("input",{id:"search-bar-input",className:"h-12 pl-12 w-full peer placeholder-transparent font-sans font-normal text-base text-black border border-solid rounded box-border outline-none pr-[6%] border-main-divider focus:border-primary-text",value:a,onChange:e=>i(e.target.value),type:"text",name:"search-bar-input",placeholder:"some search"}),n("button",{className:"visible peer-placeholder-shown:invisible absolute top-2 right-3 w-6 h-6 p-1 bg-transparent cursor-pointer",onClick:e=>{e.preventDefault(),i("")},children:n(m,{name:"CloseIcon",width:"24",height:"24"})})]})})),ft=e=>e?.map((e=>({label:e.text||"",blocks:[{accordionBlockType:"LinkList",documents:e.items||[]}]}))),bt=a((({className:e="",documents:t,relatedEnterprises:a,contacts:i,socialMedia:l,topItems:s,context:c,horizontalNavigationTitle:o,subMenu:m})=>{const d={context:c,accordionItems:ft(s)};return r("footer",{className:`px-4 py-[26px] bg-white ${e}`,children:[n(at,{className:"overflow-hidden",items:i,context:c,hasButton:!0}),n(He,{className:"!p-0 mb-4",...d}),n("div",{children:m?.map(gt)}),n(rt,{context:c,title:"Мобильное приложение",description:"Загрузить для IOS и Android"}),n(ut,{context:c,className:"grow"}),n(ht,{className:"pb-4",media:l,context:c}),n(ct,{title:o,links:a,context:c}),n(xt,{links:t,context:c})]})})),gt=(e,t)=>{const{icon:a,href:i,text:l}=e;return r(Y,{version:"link",href:i,className:"flex text-sm mb-4",children:[a?n(m,{className:"pr-1",name:a,width:"24",height:"24",asSVG:!0}):null,n("span",{className:"pl-2.5 font-medium text-primary-text",children:l})]},`footer-${t}`)},Nt=(e,t,n=((e,t)=>t.startsWith(e)))=>n(H(e),(e=>(e||"").replace(G,""))(H(Z(e)?t.href:t.pathname))),yt=e=>t=>Nt(t.href,e),vt=e=>t=>t.items?.some(yt(e))||Nt(t.href,e)||((e,t)=>z(e)===z(t.href))(t.href,e),wt=e=>t=>e?.href===t?.href,kt=(e,t)=>{return(r=e,a=t,(r||[]).map((e=>a?.find(wt(e))||e))).concat((n=e,(t||[]).filter((e=>!n?.find(wt(e))))));var n,r,a};async function $t(){const e=await fetch(St());return await e.json()}function St(){return`/wcms-resources/${c.SITEMAP||"sitemap"}.json`}const Ct="absolute left-0 -bottom-3 w-full h-[2px]",Tt=a((({className:e,text:t,href:a,target:i,active:l,onClick:s,children:c,bgColor:o="bg-white"})=>r("a",{className:`relative inline-block bg-transparent text-center no-underline ${e||""}`,href:a,target:i,onClick:s,children:[n("span",{className:_t(o,l),children:t||c}),l?n("div",{className:jt(o,l)}):null]}))),_t=(e,t)=>{let n="text-white";return"bg-white"===e&&(n=t?"text-primary-main":"text-secondary-text hover:text-primary-main"),`${n} font-sans font-normal text-sm`},jt=(e,t)=>t?`${"bg-white"===e?"bg-primary-main":e} ${Ct}`:Ct,Dt=a((({context:e,burgerSubMenu:t,onClick:a,defaultLocation:i="",children:l})=>{const[s,c]=e.useGeolocation(i);return r("div",{className:"absolute top-0 left-0 w-full h-full bg-white p-4 box-border z-20",children:[n("button",{className:"absolute top-4 right-4 border-none bg-transparent cursor-pointer",onClick:a,children:n(m,{name:"CloseIcon",width:"24",height:"24",asSVG:!0})}),r("button",{onClick:c,className:"flex items-center text-sm text-secondary-text mb-4 bg-transparent cursor-pointer",children:[n(m,{name:"GeolocationIcon",width:"20",height:"20",className:"text-primary-main box-border mr-2",asSVG:!0}),s]}),l,n("div",{className:"mb-7",children:t?.map(It)}),n(ut,{context:e,className:"grow"})]})})),It=(e,t)=>{const{icon:a,href:i,text:l}=e;return r("a",{href:i,className:"flex text-sm mb-4 hover:text-primary-main",children:[a?n(m,{className:"text-primary-main pr-1",name:a,width:"24",height:"24",asSVG:!0}):null,n("span",{className:"pl-0.5 font-medium",children:l})]},`headerSubMenu-${t}`)},Lt=a((({onClick:e,bgColor:t})=>r("div",{className:"flex items-center justify-between border-0 border-b border-main-divider h-[50px]",children:[r("div",{className:"flex items-center",children:[n("button",{className:"pr-4 border-0 bg-transparent cursor-pointer",onClick:e,"aria-label":"Открыть меню",children:n(m,{name:"bg-white"===t?"BurgerIcon":"BurgerIconWhite",width:"24",height:"24",asSVG:!0})}),n(nt,{bgColor:t})]}),n("button",{className:("bg-white"===t?"text-primary-main":"text-white")+" text-sm border-0 bg-transparent cursor-pointer",children:"Войти"})]}))),Bt=a((({className:e="",defaultLocation:t,bgColor:a="bg-white",context:i,topItems:l,burgerSubMenu:s})=>{const c=i.useRouter(),o=function(e){const{data:t}=e(St(),$t);return t||{}}(i.useAsyncData),{handlerDecorator:m}=i,d=kt(o.topItems,l).find(vt(c))?.items,h=(e=>(t=[])=>{const n=t?.filter(yt(e));var r;return n?.length?(r=e=>e.href?.length||0,e=>e.reduceRight(((e,t)=>r(e)>r(t)?e:t)))(n):null})(c)(d),[x,p]=i.useState(!1),u=()=>p(!x);return r("header",{className:`${a} ${e}`,children:[r("div",{className:"container px-4 py-0 box-border",children:[n(Lt,{onClick:u,bgColor:a}),n("nav",{className:"flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]",children:n("div",{className:"flex",children:d?.map(((e,t)=>Rt({...U({router:c,handlerDecorator:m},e),active:e===h,bgColor:a},t)))})})]}),x?n(Dt,{context:i,onClick:u,burgerSubMenu:s,defaultLocation:t,children:n(He,{context:i,accordionItems:ft(l),className:"p-0 pt-0 pb-0 mb-4"})}):null]})})),Rt=(e,t)=>n(Tt,{className:"mr-8 whitespace-nowrap text-sm",...e},String(t)),Vt={primary:"text-primary-text",secondary:"text-white"},At={primary:"text-secondary-text",secondary:"text-white"};const Ot=a((({className:e="",context:t,title:a,headingType:i="h2",description:l,benefits:c,buttons:o,image:d,items:h,version:x="primary"})=>r("div",{className:`w-full text-primary-text ${e}`,children:[n("div",{children:r(te,{context:t,title:a&&n(s,{headingType:i,title:a,className:"whitespace-pre-wrap max-w-[600px] "+(a?"mb-3":"")}),buttons:o?.length?n(q,{context:t,buttons:o,className:"flex flex-col mt-5 gap-2.5"}):null,children:[l?n(ee,{className:"mb-5",description:l}):null,c?.length?n("div",{className:"mt-5",children:c.map(((e,t)=>function(e,t,a){return r("div",{className:"flex gap-3 items-center mb-2.5 last:mb-0",children:[e.icon&&n(m,{className:"w-6 h-6 rounded-full box-border",name:e.icon,width:"24",height:"24",asSVG:!0}),n("div",{className:`font-medium text-m-title-xs m-0 ${Vt[a]}`,children:e.label}),e.description&&n("div",{className:`font-normal text-m-sm ${At[a]}`,children:e.description})]},String(t))}(e,t,x)))}):null,h?.length?n(V,{items:h}):null]})}),Mt(d)]})));function Mt(e){return e?.src?n("div",{className:"mt-5",children:n(d,{image:{className:"block",...e}})}):null}const Pt=a((e=>{const{className:t}=e;return n("section",{className:`font-sans bg-white px-4 py-6 ${t||""}`,children:n(Ot,{...e})})})),Zt=a((({block:e,headingType:t,context:r})=>n("section",{className:"flex grow-0 shrink-0 basis-full px-4 pt-6",children:n("div",{className:"flex grow",children:n(Ot,{context:r,headingType:t||"h2",...e})})}))),Ht=a((({className:e,context:t,slides:r=[]})=>{const a=r.map((e=>e.productBlock));return n("section",{className:`font-sans bg-white overflow-hidden w-100 pb-6 ${e||""}`,children:n(N,{context:t,children:a.map(((e,r)=>n(Zt,{block:e,context:t},String(r))))})})})),zt=a((({className:e,title:t,description:a,steps:i,size:l="normal"})=>r("section",{className:`box-border font-sans text-primary-text bg-white px-4 py-6 flex flex-col ${e||""}`,children:[t&&n(s,{headingType:"h3",className:"text-center",title:t}),a&&n("p",{className:`text-m-md text-center ${t&&"mt-2"}`,children:a}),i?.length?n("div",{className:"box-border py-0.5 mb-0.5 mt-5",children:n("div",{className:"flex flex-col justify-between gap-x-[101px]",children:i.map(((e,t)=>Et({step:e,size:l,i:t,length:i.length})))})}):null]}))),Et=e=>{const{step:t,size:a,i:i,length:l}=e,s=l-1===i,c="normal"===a?"ml-[34px]":"ml-[24px]";return n("div",{children:r("div",{className:"flex flex-row text-center relative",children:[r("div",{children:[Gt(t,a,i),!s&&n("div",{className:`min-h-8 h-full w-[2px] bg-secondary-light ${c}`})]}),r("div",{className:"flex flex-col justify-start relative",children:[t.label&&n("div",{className:"font-medium text-m-title-xs m-0 text-left",children:t.label}),t.description&&n("div",{className:"font-normal text-sm text-secondary-text text-left "+(t.label?"mt-1":""),children:t.description})]})]},String(i))},String(i))},Gt=(e,t,r)=>{const a="normal"===t?"38":"27";return n("div",{className:`${"normal"===t?"h-[70px] w-[70px] min-w-[70px] min-h-[70px]":"h-[50px] w-[50px] min-w-[50px] min-h-[50px]"} bg-secondary-light rounded-full z-10 mr-3 flex justify-center content-center`,children:n("span",{className:`font-medium text-secondary-text self-center ${"normal"===t?"text-m-title":"text-m-title-xs"}`,children:e.icon&&n(m,{name:e.icon,width:a,height:a})||r+1})})},Ft={Accordion:He,ExchangeRateTile:We,Footer:bt,Gallery:xe,Header:Bt,Headline:x,LinkDocs:_,MobileAppTile:rt,ProductBlock:Pt,ProductGallery:Ht,StepsBlock:zt,TextBlock:O,LinkList:Ve},Wt=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:Ut()}))),Ut=()=>{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"})]})},Jt=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(Wt,{onClick:a.like,ariaLabel:"Поставить отметку «лайк»"}),n(Wt,{onClick:a.dislike,className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),n("span",{className:"select-none",children:a.likeCount})]})})),Kt=a((({className:e,context:t,title:a,description:i="Блок в разработке..."})=>n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${ie(e)} ${ae(e)} `,children:r(te,{context:t,title:a?n(s,{headingType:re(e),title:a,className:"whitespace-pre-wrap max-w-[600px]"}):null,children:[i?n(ee,{className:"mt-4 max-w-[600px]",description:i}):null,n("figure",{className:"m-0 min-w-[600px]",children:Qt()})]})}))),Qt=(e=3)=>Yt(100,e).map((e=>Math.floor(e))).map(Xt),Xt=(e=100,t)=>n("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),Yt=(e,t)=>[e].concat(t>0?Yt(e/1.618,t-1):[]),qt=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),en=a((({className:e,context:t,blocksRegistry:a,data:{style:i,blocks:l,slots:s={},likeControl:c,colorPalette:o="pc"},blockDecorator:m=qt})=>{const{header:d}=s;return r("section",{className:`relative ${nn(i)} ${e||""}`,"data-theme":o,children:[d?.blocks?.length?n("div",{className:`${nn(d?.style)}`,children:d.blocks.map(((e,n)=>tn({block:e,blockDecorator:m,blocksRegistry:a,context:t},n)))}):null,l?.length?n("div",{className:"container grid grid-cols-12 gap-1",children:l.map(((e,n)=>tn({block:e,blockDecorator:m,blocksRegistry:a,context:t},n)))}):null,c&&n("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:n(Jt,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:t})})]})}));function tn({block:e,blockDecorator:t,blocksRegistry:r,context:a},i){const{type:l}=e;l&&l in r||console.warn(`No block with "${l}" is registered`);const s=r[l||"Placeholder"]||Kt;return t({blockClassName:nn(e.style),block:e,render:e=>{const{version:t,content:r}=e.block;return n(s,{className:e.blockClassName,version:t,context:a,...r},`${l}-${i}`)}},`block-${i}`)}function nn(e){return e?e.join(" "):""}const rn=a((({HeadComponent:e,data:t,children:a})=>{const{title:i,main:l,og:s,twitter:c,jsonLd:o}=t,{description:m,keywords:d,canonical:h,robots:x}=l||{};return r(e,{children:[n("title",{children:i}),n("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),m&&n("meta",{name:"description",content:m}),d&&n("meta",{name:"keywords",content:d.join(",")}),x&&n("meta",{name:"robots",content:x.join(",")}),an(s),ln(c),h&&n("link",{rel:"canonical",href:h}),o&&n("script",{type:"application/ld+json",children:o}),a]})}));function an(e){return e?Object.entries(e).map((([e,t])=>n("meta",{name:`og:${e}`,content:t},e))):null}function ln(e){return e?Object.entries(e).map((([e,t])=>n("meta",{name:`twitter:${e}`,content:t},e))):null}function sn(e){const{mobile:t,...n}=e;return t?{...n,...t,content:{...n.content,...t.content}}:e}function cn(e){return e?.filter((e=>(e?.type||e?.mobile?.type||"")in Ft&&!e.mobile?.hidden)).map(sn)}e.Blocks=Ft,e.ContentPage=en,e.ContentPageHead=rn,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.Header=Bt,e.Icon=m,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.joinList=function(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])},e.normalizePage=function(e){if(!e)return;const{blocks:t,slots:n}=e;return{...e,blocks:cn(t),slots:n&&Object.keys(n).reduce(((e,t)=>({...e,[t]:{...n[t],blocks:cn(n[t].blocks)}})),{})}},e.projectSettings=c,e.setup=t,e.url=E,Object.defineProperty(e,"__esModule",{value:!0})}));
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).UniMobileBlocks={})}(this,(function(e){"use strict";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={h1:"text-m-title",h2:"text-m-title",h3:"text-m-title-md",h4:"text-m-title-xs",h5:"text-m-title-xs",h6:"text-m-title-xs"},s=a((e=>{const{className:t,headingType:r,title:a}=e;if(!r)return;return n(r,{className:`font-sans font-medium m-0 ${l[r]} ${t||""}`,children:a})})),c=new class{_={PROD_BRANCH:"master",FORCED_DRAFT_FLOW:!1};setup(e){this._=e}get TEST_BRANCH(){return this._.TEST_BRANCH}get RC_BRANCH(){return this._.RC_BRANCH}get PROD_BRANCH(){return this._.PROD_BRANCH}get FORCED_DRAFT_FLOW(){return this._.FORCED_DRAFT_FLOW}get ENABLE_ASSIST(){return this._.ENABLE_ASSIST}get SITEMAP(){return this._.SITEMAP}get CDN(){return this._.CDN}},o={none:"",primary:"text-primary-main"},m=a((({className:e="",name:t,alt:a=`Icon ${t}`,title:i=a,asSVG:l,color:s="primary",...m})=>{const d=`${c.CDN||""}icons/${t}.svg`;return l?r("svg",{className:`${o[s]} ${e}`,...m,"aria-hidden":"true",children:[i?n("title",{children:i}):null,a?n("desc",{children:a}):null,n("use",{href:`${d}#icon`,xlinkHref:`${d}#icon`})]}):n("img",{className:e,src:d,alt:a,title:i,...m,"aria-hidden":"true"})})),d=a((({className:e="",image:t})=>{if(!t)return null;const a={width:t.size?.width?`${t.size?.width}px`:"100%",height:t.size?.height?`${t.size?.height}px`:"100%"};return r("picture",{className:e,children:[t.sources?.length?t.sources.map((({src:e,format:t},r)=>n("source",{srcSet:e,type:h(t)},`${r}_${e}`))):null,n("img",{src:t.src,className:`m-auto ${t.className||""}`,alt:t.alt||t.title,title:t.title,style:a,...t.size})]})}));function h(e){return e?`image/${String(e)}`:void 0}const x=a((({bgColor:e="transparent",className:t="",title:a,description:i,image:l})=>r("section",{className:`px-4 py-6 ${e} ${t}`,children:[a&&n(s,{headingType:"h2",className:"text-primary-text",title:a}),i&&n("p",{className:"font-normal text-m-md "+(a?"mt-2.5":""),children:i}),l?.src&&n("div",{className:"mt-5 mx-auto flex justify-center",children:n(d,{image:l})})]}))),p=a((({children:e,activeIndex:t,indexFraction:r,showDots:a})=>a&&e?.length?n("div",{className:"flex gap-2 mx-auto mt-5 w-fit",children:e?.map(((e,a)=>n("div",{className:"bg-primary-main opacity-30 w-1.5 h-1.5 min-w-1.5 min-h-1.5 rounded-full",style:u(a,t,r),"aria-hidden":!0},String(a))))}):null)),u=(e,t,n)=>{if(e<t||e>t+1)return null;const r=1-n;return e===t?{opacity:""+(.3+.7*r),width:6+16*r+"px"}:{opacity:""+(.3+.7*n),width:6+16*n+"px"}},f=a((({className:e="",children:t,...r})=>n("div",{className:`snap-center snap-always min-w-full box-border ${e}`,role:"listitem",...r,children:t}))),b=e=>({marginLeft:-e+"px",marginRight:-e+"px",paddingLeft:`${e}px`,paddingRight:`${e}px`}),g=a((({className:e="",children:t,activeIndex:r,onScroll:a,gap:i=14,padding:l=16})=>n("div",{className:`overflow-auto flex horizontal-list no-scrollbar ${e}`,style:{...b(l),gap:`${i}px`},role:"list",onScroll:a,children:t?.length?t?.map(((e,t)=>n(f,{style:b(l/4),"aria-current":Boolean(r===t),children:e},String(t)))):n(f,{children:t})}))),N=a((({className:e,context:t,children:n,gap:a=14,padding:i=16,showDots:l=!0,onSlideChange:s})=>{const[c,o]=t.useState(0),[m,d]=t.useState(0);return r("div",{className:e,children:[y({gap:a,padding:i,activeIndex:c,handleScroll:e=>{const{scrollLeft:t,clientWidth:n,childElementCount:r,scrollWidth:l,children:m}=e.currentTarget,h=m[0].offsetWidth-i/2,x=(({gap:e,padding:t,clientWidth:n,scrollWidth:r,childElementCount:a,itemWidth:i})=>{const l=i+e,s=r-n,c=n-e-t,o=a-2,m=new Array(a).fill(0).map(((e,t)=>0===t||t===o?[t>0?s-c:0,t>0?s:c]:[(t-1)*l+c,t*l+c]));return m[a-1]=[s,r],m})({gap:a,padding:i,clientWidth:n,scrollWidth:l,childElementCount:r,itemWidth:h}),{index:p,fraction:u}=((e,t)=>{const n=t.findIndex((([t,n])=>t<=e&&e<n));if(n<0)return{index:n,fraction:0};const[r,a]=t[n];return{index:n,fraction:(e-r)/(a-r)}})(t,x);p!==c&&s&&s(),o(p),d(u)},children:n}),v({activeIndex:c,indexFraction:m,showDots:l,children:n})]})})),y=({gap:e,padding:t,activeIndex:r,handleScroll:a,children:i})=>n(g,{gap:e,padding:t,activeIndex:r,onScroll:a,children:i}),v=({activeIndex:e,indexFraction:t,showDots:r,children:a})=>n(p,{activeIndex:e,indexFraction:t,showDots:r,children:a}),w=a((({className:e,iconClassName:t,textClassName:a,suffixClassName:i,doc:l,icon:s})=>{const{text:c,fileSize:o,...d}=l;return r("a",{className:e,role:"link",...d,children:[s?n(m,{className:t,name:s,width:"24px",height:"24px",asSVG:!0}):null,c?r("span",{className:a,children:[c,n("span",{className:i,children:d?.href&&k($(d.href),o)})]}):null]})})),k=(e,t)=>(e||t?",":"")+(e?` ${e}`:"")+(t?` (${t})`:""),$=e=>{if(!e)return"";const t=e.lastIndexOf(".");return-1!==t?e.substring(t+1):""},S=a((({className:e="",doc:t,icon:r})=>n(w,{className:`flex h-full box-border ${e}`,iconClassName:"mr-3 min-w-6 min-h-6",doc:t,icon:r}))),C=a((({context:e,hasBorder:t=!0,documents:r,icon:a})=>n(N,{context:e,className:"text-m-sm text-primary-main",children:r?.length?r.map(((e,r)=>n(S,{className:t?"rounded-md border-main-stroke border p-4":"",doc:e,icon:a},String(r)))):null}))),T=a((({hasBorder:e=!0,documents:t,icon:r})=>n("div",{className:"text-m-sm text-primary-main flex flex-col "+(e?"gap-3.5":"gap-2"),role:"list",children:t?.length?t.map(((t,a)=>n("div",{role:"listitem",children:n(S,{className:e?"rounded-md border-main-stroke border p-4":"",doc:t,icon:r})},String(a)))):null}))),_=a((({className:e="",context:t,title:a,subtitle:i,icon:l="DocIconMonoColor",documents:c,listMode:o="vertical",hasBorder:m=!0})=>r("section",{className:`font-sans text-primary-text py-6 px-4 bg-white ${e}`,children:[a?n(s,{headingType:"h2",className:"text-center "+(i?"mb-2":"mb-5"),title:a}):null,i?n("h3",{className:"mt-0 font-normal mb-5 text-center text-m-md",children:i}):null,"vertical"===o?n(T,{hasBorder:m,documents:c,icon:l}):n(C,{context:t,hasBorder:m,documents:c,icon:l})]}))),j=a((({className:e="",title:t,image:a,benefits:i})=>r("section",{className:`relative font-sans text-primary-text bg-white p-14 ${e}`,children:[n(s,{headingType:"h2",className:"text-center",title:t}),r("div",{className:"flex justify-center mt-9",children:[a?.src&&n(d,{className:"mr-6",image:a}),i?.length?n("div",{className:"flex flex-col",children:i.map(D)}):null]})]})));function D(e,t){return r("div",{className:"flex flex-row mb-8",children:[e.icon&&n(m,{className:"w-[48px] h-[48px] bg-main rounded-full box-border p-[12px]",name:e.icon,width:"48",height:"48",asSVG:!0}),r("div",{className:"flex gap-1 flex-col h-full ml-5 max-w-[490px]",children:[e.label&&n("div",{className:"font-medium text-primary-text text-xl m-0",children:e.label}),e.description&&n("div",{className:"font-normal text-sm text-secondary-text",children:e.description})]})]},String(t))}const I={primary:"text-primary-text",secondary:"text-white",gray:"text-secondary-text"},L={primary:"bg-primary-main",secondary:"bg-white",gray:"bg-secondary-text"},B=a((({className:e="",isDotted:t=!0,children:a,version:i="primary"})=>r("div",{className:`font-sans flex items-start ${e}`,role:"listitem",children:[t&&n("div",{className:R(i)}),n("span",{className:`text-m-md ${I[i]}`,children:a})]}))),R=e=>`rounded-full inline-block mr-3 mt-2 ${L[e]} ${"gray"===e?"w-[6px] h-[6px] min-w-[6px] min-h-[6px]":"w-2 h-2 min-w-2 min-h-2"}`,V=a((e=>{const{className:t="",itemClassName:r,isDotted:a,items:i,version:l}=e;return n("section",{className:`${t}`,role:"list",children:i?.length?i.map(((e,t)=>n(B,{className:r,isDotted:a,version:l,children:e},String(t)))):null})})),A={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"}},O=a((({title:e,description:t,blockVersion:a="primary",iconVersion:i,image:l,className:s="",items:c,isDotted:o=!0})=>{const m=A[a];return r("section",{className:`font-sans px-4 py-[18px] flex flex-col ${m.background} ${s}`,children:["small"===i?M(m.icon):null,"big"===i?P(l):null,r("div",{className:"py-0.5",children:[e?n("div",{className:`font-medium text-base mb-1 ${m.title}`,children:e}):null,t?n("div",{className:`text-sm ${m.description}`,children:t}):null,c?.length?n(V,{items:c,isDotted:o,version:"gray",className:"mt-1 text-m-sm text-secondary-text"}):null]})]})}));function M(e){return n("div",{className:"mb-3",children:n("div",{className:`rounded-full h-4 w-4 text-center text-xs ${e}`,children:"i"})})}function P(e){return e?.src?n(d,{className:"pb-3 mr-auto",image:e}):null}const Z=e=>e?.includes("//"),H=e=>(e||"").replace(/\/?\?.*/,""),z=e=>{if(!e||!Z(e))return;const t=e,n=t.indexOf("//"),r=t.indexOf("/",n+"//".length);return-1!==r?t.substring(0,r):t};var E=Object.freeze({__proto__:null,isURL:Z,withoutQuery:H,getOrigin:z});const G="/mobile",F=(e,t)=>{if(!e)return e;const n=z(t?.href);return n?e.replace(n,"")||"/":e},W=e=>e;function U({router:e,handlerDecorator:t=W},n){const r=((e,t)=>{if(!e)return e;const n=F(e,t)||"",r=t?.pathname.startsWith(G);return r&&!Z(n)?`/mobile${n}`:n})(n.href,e);return{...n,href:r,ariaLabel:n.text,onClick:t((t=>{const a=r&&!Z(r),i=!n.target||"_self"===n.target;a&&i&&(t.preventDefault(),e.push(r))}),n)}}const J=a((({text:e,aboveText:t,appendLeft:a,rounded:i,version:l})=>{const s=!e&&!t&&Boolean(a);return function({buttonInnerClasses:e,appendLeft:t,withoutText:a,aboveText:i,text:l}){return r("div",{className:e,children:[t||null,a?null:r("div",{children:[n("div",{className:"text-m-2xs text-left",children:i}),n("div",{className:"text-m-button font-medium text-left",children:l})]})]})}({buttonInnerClasses:"link"!==l?`flex items-center justify-center\n ${s?"h-12 w-12":"px-8 gap-2 "+(t?"py-2":"py-3.5")} ${i?"rounded-full":""}`:null,appendLeft:a,withoutText:s,aboveText:t,text:e})}));const K={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",link:"text-primary-main"},Q={primary:"bg-secondary-dark text-secondary-text",secondary:"bg-secondary-light text-secondary-text",link:""},X="w-full text-center font-sans select-none",Y=a((({className:e,text:t,aboveText:r,appendLeft:a,href:i,target:l,onClick:s,children:c,disabled:o,rounded:m,version:d="primary",ariaLabel:h,...x})=>{const p=c??n(J,{text:t,aboveText:r,appendLeft:a,rounded:m,version:d});return o?n("div",{role:"button","aria-disabled":"true","aria-label":h,tabIndex:"-1",className:`inline-block ${X} ${Q[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,children:p}):n("a",{className:`${X} inline-block cursor-pointer no-underline ${K[d]||""} ${m?"rounded-full":"rounded-md"} ${e||""}`,href:i,target:l,onClick:s,"aria-label":h,role:i?"link":"button",...x,children:p})})),q=a((({context:e,className:t="",buttons:r})=>{const{handlerDecorator:a}=e,i=e.useRouter();return r?.length?n("div",{className:`${t}`,children:r.map(((e,t)=>function({icon:e,...t},r){if(!t?.text)return;return n(Y,e?{appendLeft:n(m,{name:e,width:"24",height:"24",asSVG:!0}),...t}:{...t},String(r))}(U({router:i,handlerDecorator:a},e),t)))}):null}));const ee=a((e=>{const{className:t="",description:r}=e;return n("div",{className:`font-normal text-m-md ${t}`,children:r})})),te=a((({className:e="",title:t,children:a,buttons:i,image:l})=>r("div",{className:`font-sans flex flex-col grow h-full items-start ${e}`,children:[t,r("div",{className:"flex grow w-full justify-between",children:[r("div",{className:"flex flex-col justify-between w-full",children:[n("div",{children:a}),n("div",{children:i})]}),l]})]}))),ne=e=>{const t="col-span-",n=e.split(/\s+/).find((e=>e.startsWith(t)));return n?parseInt(n.substring(t.length),10):12};function re(e=""){const t=ne(e);return t<=4?"h4":t<=8?"h3":"h2"}function ae(e=""){const t=ne(e);return t<=6?"min-h-[300px]":t<=8?"min-h-[320px]":"min-h-[360px]"}function ie(e=""){const t=ne(e);return t<=6?"pr-9":t<=8?"pr-[4.75rem]":"pr-[9.4rem]"}const le={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},se=a((e=>{const{context:t,title:a,description:i,items:l,children:c,buttons:o,image:m,className:h="",version:x="primary",role:p}=e;return n("section",{className:`overflow-hidden font-sans p-9 box-border ${h} ${le[x]} ${ie(h)} ${ae(h)} `,role:p,children:r(te,{context:t,title:a&&n(s,{headingType:re(h),title:a,className:`whitespace-pre-wrap max-w-[600px] ${a?"mb-3":""}\n ${"primary"===x?"text-primary-text":""}`}),buttons:o?.length?n(q,{context:t,buttons:o,className:"flex mt-9 gap-3"}):null,image:m?.src&&n(d,{className:"mt-auto ml-7",image:m}),children:[i&&n(ee,{className:"mt-4 max-w-[600px]",description:i}),c,ce(l,x)]})})}));function ce(e,t){return e?.length?n(V,{items:e,version:t}):null}const oe={primary:"bg-white text-primary-text",secondary:"bg-primary-main text-white"},me=a((({context:e,className:t="",title:a,description:i,benefits:l,buttons:c,image:o,version:m="primary"})=>n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${t} ${oe[m]} ${ie(t)} ${ae(t)} `,children:r(te,{context:e,title:a&&n(s,{headingType:re(t),title:a,className:"whitespace-pre-wrap max-w-[600px]"}),buttons:c?.length?n(q,{context:e,buttons:c,className:"flex mt-9 gap-3"}):null,image:o?.src&&n(d,{className:"mt-auto ml-7",image:o}),children:[i&&n(ee,{className:"mt-4 max-w-[600px]",description:i}),r("div",{className:"flex mt-5 mb-1",children:[l?.length?n("div",{className:"mr-8",children:l.map(de)}):null,l?.length?n("div",{className:"pt-1",children:l.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.description},String(t))}(e,t,m)))}):null]})]})})));function de(e,t){return n("div",{className:"text-xl font-medium "+(t?"mt-2.5":""),children:e.label},String(t))}const he={primary:"bg-white",secondary:"bg-primary-main text-white"},xe=a((({context:e,title:t,description:a,cards:i=[],className:l,isScroll:c=!0})=>r("section",{className:`relative font-sans text-primary-text bg-white px-4 py-6 overflow-hidden ${l}`,children:[r("div",{className:"flex flex-col items-center mb-5",children:[n(s,{headingType:"h2",className:"text-center",title:t}),a?n("div",{className:"font-normal text-m-md max-w-[600px] mt-2",children:a}):null]}),pe(c,i,e)]})));function pe(e,t,r){return e?n(N,{context:r,children:t?.map(ue)}):n("div",{className:"grid gap-[14px]",children:t?.map(ue)})}function ue(e,t){return r("div",{className:`box-border horizontal-list-item border-solid border rounded-md border-main-stroke p-4 flex flex-col\n ${he[e.version??"primary"]}`,children:[r("div",{children:[e.image?.src?n("div",{className:"flex justify-center",children:n(d,{className:"mb-6",image:e.image})}):null,e.title?n("h4",{className:"font-medium text-m-title-xs m-0",children:e.title}):null,e.description?fe(e):null,e.items?.length?(i=e.items,n("section",{className:"mt-3",children:i.map(((e,t)=>r("div",{children:[n("span",{className:"text-m-md font-medium",children:e.title}),n("span",{className:"text-m-sm text-secondary-text pl-2",children:e.text})]},String(t))))})):null]}),e?.button?.text?(a=e.button,n(Y,{className:"mt-3",appendLeft:a?.icon&&n(m,{name:a?.icon,width:"24px",height:"24px",asSVG:!0}),...a})):null]},t);var a,i}function fe(e){return n("div",{className:"text-secondary-text mt-2 "+("secondary"===e.version?"text-white opacity-80":""),children:e.description})}const be=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)))}))),ge=[{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"}],Ne=a((({className:e,disabled:t,...r})=>n(Y,{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(be,{paths:ge,viewBox:"0 0 16 16",fill:"none",width:"16",height:"16"})}))),ye={primary:"bg-white text-secondary-text",secondary:"bg-primary-main text-white"},ve={normal:3,mini:4},we={normal:"min-w-[364px] w-[364px]",mini:"min-w-[260px] w-[260px]"},ke={normal:380,mini:276},$e={primary:"text-secondary-text",secondary:"text-white",gray:"text-secondary-text"},Se={primary:"bg-primary-main",secondary:"bg-white",gray:"bg-secondary-text"},Ce=a((({className:e="",isDotted:t=!0,text:a,children:i,version:l="primary"})=>r("div",{className:`font-sans flex items-start ${e}`,role:"listitem",children:[t&&n("div",{className:Te(l)}),n("span",{className:$e[l],children:a||i})]}))),Te=e=>`rounded-full inline-block mr-3 mt-2 ${Se[e]} ${"gray"===e?"w-[6px] h-[6px] min-w-[6px] min-h-[6px]":"w-2 h-2 min-w-2 min-h-2"}`,_e=a((({title:e,description:t,image:a,items:i,button:l,version:s})=>{const c=function(e,t,n){return`font-medium text-xl m-0\n ${"secondary"!==e?"text-primary-text":""}\n ${t||n?.length?"":"text-center"}\n `}(s,t,i);return r("div",{children:[r("div",{children:[a?.src?n("div",{className:"flex justify-center",children:n(d,{className:"mb-6",image:a})}):null,e?De(e,c):null,t?n("div",{className:"font-normal text-sm "+(e?"mt-2":""),children:t}):null,i?.length?Ie(i,s):null]}),l?.text?je(l):null]})}));function je(e){return n(Y,{className:"mt-6 w-full",appendLeft:e.icon&&n(m,{name:e.icon,width:"24px",height:"24px",asSVG:!0}),...e})}function De(e,t){return n("div",{className:`font-medium text-xl m-0 ${t}`,children:e})}function Ie(e,t){return n("section",{className:"max-w-[308px] mt-2",role:"list",children:e.filter((e=>e?.text)).map(((e,r)=>function(e,t,r){return n(Ce,{version:r??"primary",children:n("span",{className:"text-sm",children:e})},String(t))}(e.text,r,t)))})}const Le=a((({context:e,title:t,description:a,cards:i=[],version:l="normal",activeCardIndex:c})=>r("div",{children:[n("div",{className:"absolute top-0 left-0 bottom-0 w-[84px] bg-gradient-to-r from-white to-transparent"}),r("div",{className:"flex flex-col items-center mb-8",children:[t?n(s,{headingType:"h2",className:"text-center",title:t}):null,a?n("div",{className:"font-normal text-base max-w-[600px] mt-2.5",children:a}):null]}),n("div",{className:`flex ${i?.length<=ve[l]?"justify-center":""} duration-1000`,style:{transform:`translateX(-${c*ke[l]}px)`},role:"list",children:i?.map(((t,r)=>function({card:e,version:t},r){return n("section",{className:`box-border border-solid border rounded-md border-main-divider p-7 mx-2 flex flex-col justify-between\n items-stretch ${we[t]} ${ye[e.version??"primary"]} w-full col-span-4`,role:"listitem",children:n(_e,{...e})},String(r))}({card:t,version:l,context:e},r)))})]})));const Be=a((({context:e,cards:t=[],className:a="",version:i="normal",...l})=>{const[s,c]=e.useState(0),o=t?.length>ve[i],m=o&&t?.length-s>ve[i],d=o&&s>0;return r("section",{className:`relative font-sans text-primary-text bg-white p-[50px] overflow-hidden ${a}`,children:[n(Le,{context:e,cards:t,version:i,activeCardIndex:s,...l}),d&&n(Ne,{className:"absolute top-1/2 left-8 rotate-180 z-10 mt-[25px]",onClick:()=>c(s-1),ariaLabel:"Пролистать влево"}),m&&n(Ne,{className:"absolute top-1/2 right-8 z-10 mt-[25px]",onClick:()=>c(s+1),ariaLabel:"Пролистать вправо"}),n("div",{className:"absolute top-0 left-0 bottom-0 w-[84px] bg-opacity-from-white"}),n("div",{className:"absolute top-0 right-0 bottom-0 w-[100px] bg-opacity-to-white"})]})})),Re=a((e=>n(Be,{...e,version:"mini"}))),Ve=a((({className:e="",documents:t})=>n("section",{className:`font-sans bg-white mt-[10px] ${e}`,children:n("ul",{className:"flex flex-col text-sm text-secondary-text p-0",children:t?.length?Ae(t):null})}))),Ae=e=>e.map(((e,t)=>{const{text:r,...a}=e;return n("li",{className:"mb-4 list-none",children:n("a",{className:"hover:text-primary-main",role:"link",...a,children:r||null})},`list_item_${String(t)}`)})),Oe={Headline:x,LinkDocs:_,TextBlock:O,PictureText:j,Tile:se,ProductTile:me,Gallery:xe,MiniGallery:Re,LinkList:Ve},Me=a((({blocks:e,context:t})=>n("div",{className:"transition-all duration-300 max-h-0 overflow-hidden group-last:last:pb-0",children:e?.length?e.map(Pe(t)):null}))),Pe=e=>(t,r)=>{const a=t?.accordionBlockType;if(!a||!(a in Oe))return null;return n("div",{className:"mb-5 last:mb-0",children:n(Oe[a],{context:e,...t,className:"!p-0"})},`block_${r}`)},Ze=a((({label:e,blocks:t,bordered:a,context:i})=>{const{hasContent:l,icon:s,handleToggle:c}=(({context:e,blocks:t})=>{const[n,r]=e.useState(!1),a=t?.length;return{isActive:n,hasContent:a,icon:n?"MinusIcon":"PlusIcon",handleToggle:e=>{if(!a)return;r(!n);const t=(({currentTarget:e})=>e.nextSibling)(e);t.style.maxHeight=t.style.maxHeight?null:`${t.scrollHeight}px`}}})({context:i,blocks:t});return r("li",{className:(a?"border p-4 rounded mb-4":"border-0 border-b last:border-b-0")+" border-solid border-main-divider",children:[r("button",{className:`border-none bg-transparent flex justify-between text-left w-full font-sans text-primary-text\n ${a?"":"py-[14px] px-0"}\n ${l?"group cursor-pointer":""}`,onClick:c,children:[n("span",{className:"text-sm pr-2.5 font-medium "+(l?"group-hover:text-primary-main":""),children:e}),l?n(m,{name:s,width:"20",height:"20",asSVG:!0}):null]}),l?n(Me,{blocks:t,context:i}):null]})})),He=a((({title:e,description:t,accordionItems:a,context:i,className:l="",bordered:c})=>r("section",{className:`py-6 px-4 font-sans bg-white text-primary-text ${l}`,children:[e?n(s,{headingType:"h3",className:"mb-2 text-center",title:e}):null,t?n("div",{className:"mb-5 text-m-md text-center",children:t}):null,a?.length?n("ul",{className:"list-none m-0 p-0",children:a.map(((e,t)=>n(Ze,{...e,context:i,bordered:c},`AccordionItem${t}`)))}):null]}))),ze="https://www.cbr-xml-daily.ru/daily_json.js",Ee=["USD","EUR"],Ge={USD:"DollarIcon",EUR:"EuroIcon"},Fe=[{text:"Все показатели",href:"https://cbr.ru/currency_base/daily/",version:"secondary"}],We=a((({className:e="",context:t,title:a="Курсы обмена валют"})=>{const{data:i}=t.useAsyncData(ze,Ke);return n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${ie(e)} ${ae(e)} `,children:n(te,{context:t,title:a&&n(s,{headingType:re(e),title:a,className:"whitespace-pre-wrap max-w-[600px] "+(a?"mb-3":"")}),buttons:Fe?.length?n(q,{context:t,buttons:Fe,className:"flex mt-9 gap-3"}):null,children:r("table",{children:[n("thead",{children:r("tr",{children:[n(Ue,{children:"Валюта"}),n(Ue,{className:"pl-11",children:"Курс"})]})}),n("tbody",{children:Ee.map(Ye(i))})]})})})})),Ue=a((({className:e="",children:t})=>n("th",{className:`text-left font-normal text-sm text-secondary-text ${e}`,children:t}))),Je=a((({className:e="",children:t})=>n("td",{className:`text-left font-normal text-base text-primary-text ${e}`,children:t})));async function Ke(){const e=await fetch(ze);return await e.json()}const Qe=new Intl.NumberFormat("ru",{style:"currency",currency:"RUB"}),Xe=e=>e?Qe.format(e):"",Ye=e=>t=>{const a=(e?.Valute||{})[t]?.Value;return r("tr",{children:[n(Je,{className:"pt-4",children:r("div",{className:"flex items-center",children:[n(m,{name:Ge[t],width:"24",height:"24"}),n("span",{className:"ml-2",children:t})]})}),n(Je,{className:"pt-4 pl-11",children:Xe(a)})]},t)},qe=["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"],et={"bg-white":"text-primary-main",transparent:"text-white"},tt={"bg-white":"text-black",transparent:"text-white"},nt=a((({className:e="",href:t,children:a,targetBlank:i,bgColor:l="bg-white",hideTitle:s})=>r("a",{className:`inline-flex items-center font-sans no-underline ${e}`,href:t||"https://rshb.ru/",target:i?"_blank":"_self","aria-label":"Россельхозбанк",children:[n(be,{className:`${et[l]} w-10 h-[38px]`,viewBox:"0 0 40 45",paths:qe.map((e=>({d:e})))}),!s&&n("span",{className:`${tt[l]} text-sm font-medium ml-2.5`,children:a||"Россельхозбанк"})]}))),rt=a((({className:e,title:t="Мобильное приложение",description:a,href:i="#"})=>n("div",{className:`col-span-12 rounded-md cursor-pointer p-4 mt-6 mb-6 bg-secondary-light ${e||""}`,children:i?r("div",{className:"flex",children:[n("div",{className:"flex justify-center align-middle rounded-md bg-primary-main w-[50px] h-[50px]",children:n(nt,{className:"w-[33px]",bgColor:"transparent",hideTitle:!0})}),r("a",{href:i,target:"_blank",className:"flex flex-col justify-center pl-3",children:[n("div",{className:"text-m-button font-medium mb-[3px]",children:t}),n("div",{className:"text-m-button text-secondary-text",children:a})]})]}):null}))),at=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(it):null,a?n(Y,{version:"primary",className:"mt-0.5 mb-5",...U({router:l,handlerDecorator:s},{text:"Обратная связь",href:"/",target:"_blank"})}):null]})})),it=(e,t)=>{const{type:a,text:i,description:l}=e;return r("div",{className:"mb-3.5",children:[n("div",{children:lt(a,i)}),n("div",{className:"font-sans text-sm text-secondary-text",children:l})]},String(t))},lt=(e,t="")=>{switch(e){case"tel":return n("a",{className:"font-sans font-medium text-xl text-primary-text no-underline",href:`tel:${st(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})}},st=e=>e.replaceAll(/\D/g,""),ct=a((({title:e,links:t,className:a="",context:i})=>{const l=i.useRouter(),{handlerDecorator:s}=i;return r("div",{className:a,children:[n("span",{className:"text-primary-text font-sans font-medium text-sm",children:e}),t?.length?n("div",{className:"flex flex-col gap-2 pt-3",children:t.map(((e,t)=>n(ot,{index:t,...U({router:l,handlerDecorator:s},e)},String(t))))}):null]})})),ot=a((({className:e="",index:t,text:r,href:a,target:i,onClick:l})=>n("a",{className:`font-sans font-normal text-sm text-secondary-text hover:text-primary-main inline-block no-underline ${e}`,href:a,target:i,onClick:l,children:r||`Документ ${t}`}))),mt=[{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"}],dt=a((({href:e})=>{const{icon:t,width:r,height:a,label:i}=mt.find((({origins:t})=>t.some((t=>e?.includes(t)))))||{};return t?n("a",{className:"flex items-center justify-center border border-solid border-main-divider rounded-full no-underline outline-none w-[38px] h-[38px] hover:text-primary-main",href:e,"aria-label":i,target:"_blank",rel:"noopener noreferrer",children:m&&n(m,{name:t,width:r,height:a,asSVG:!0,className:"block",color:"none"})}):null})),ht=a((({className:e,media:t,context:r})=>{const a=r.useRouter(),{handlerDecorator:i}=r;return n("div",{className:`flex gap-2 items-start justify-start pt-6 pb-6 ${e||""}`,children:t?.map(((e,t)=>n(dt,{...U({router:a,handlerDecorator:i},e)},String(t))))})})),xt=a((({className:e,links:t,context:a})=>{const i=a.useRouter(),{handlerDecorator:l}=a;return r("div",{className:`${e||""}`,children:[n("div",{className:"py-6",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 flex-col justify-start items-start gap-2",children:t.map(((e,t)=>n(pt,{index:t,...U({router:i,handlerDecorator:l},e)},String(t))))}):null]})})),pt=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}`}))),ut=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-[20px] h-[20px]",children:n(m,{name:"LoupeIcon",width:"24",height:"24"})}),!a&&n("label",{htmlFor:"search-bar-input",className:"font-sans font-normal text-sm text-secondary-text",children:"Поиск по сайту"})]}),n("input",{id:"search-bar-input",className:"h-12 pl-12 w-full peer placeholder-transparent font-sans font-normal text-base text-black border border-solid rounded box-border outline-none pr-[6%] border-main-divider focus:border-primary-text",value:a,onChange:e=>i(e.target.value),type:"text",name:"search-bar-input",placeholder:"some search"}),n("button",{className:"visible peer-placeholder-shown:invisible absolute top-2 right-3 w-6 h-6 p-1 bg-transparent cursor-pointer",onClick:e=>{e.preventDefault(),i("")},children:n(m,{name:"CloseIcon",width:"24",height:"24"})})]})})),ft=e=>e?.map((e=>({label:e.text||"",blocks:[{accordionBlockType:"LinkList",documents:e.items||[]}]}))),bt=a((({className:e="",documents:t,relatedEnterprises:a,contacts:i,socialMedia:l,topItems:s,context:c,horizontalNavigationTitle:o,subMenu:m})=>{const d={context:c,accordionItems:ft(s)};return r("footer",{className:`px-4 py-[26px] bg-white ${e}`,children:[n(at,{className:"overflow-hidden",items:i,context:c,hasButton:!0}),n(He,{className:"!p-0 mb-4",...d}),n("div",{children:m?.map(gt)}),n(rt,{context:c,title:"Мобильное приложение",description:"Загрузить для IOS и Android"}),n(ut,{context:c,className:"grow"}),n(ht,{className:"pb-4",media:l,context:c}),n(ct,{title:o,links:a,context:c}),n(xt,{links:t,context:c})]})})),gt=(e,t)=>{const{icon:a,href:i,text:l}=e;return r(Y,{version:"link",href:i,className:"flex text-sm mb-4",children:[a?n(m,{className:"pr-1",name:a,width:"24",height:"24",asSVG:!0}):null,n("span",{className:"pl-2.5 font-medium text-primary-text",children:l})]},`footer-${t}`)},Nt=(e,t,n=((e,t)=>t.startsWith(e)))=>n(H(e),(e=>(e||"").replace(G,""))(H(Z(e)?t.href:t.pathname))),yt=e=>t=>Nt(t.href,e),vt=e=>t=>t.items?.some(yt(e))||Nt(t.href,e)||((e,t)=>z(e)===z(t.href))(t.href,e),wt=e=>t=>e?.href===t?.href,kt=(e,t)=>{return(r=e,a=t,(r||[]).map((e=>a?.find(wt(e))||e))).concat((n=e,(t||[]).filter((e=>!n?.find(wt(e))))));var n,r,a};async function $t(){const e=await fetch(St());return await e.json()}function St(){return`/wcms-resources/${c.SITEMAP||"sitemap"}.json`}const Ct="absolute left-0 -bottom-3 w-full h-[2px]",Tt=a((({className:e,text:t,href:a,target:i,active:l,onClick:s,children:c,bgColor:o="bg-white"})=>r("a",{className:`relative inline-block bg-transparent text-center no-underline ${e||""}`,href:a,target:i,onClick:s,children:[n("span",{className:_t(o,l),children:t||c}),l?n("div",{className:jt(o,l)}):null]}))),_t=(e,t)=>{let n="text-white";return"bg-white"===e&&(n=t?"text-primary-main":"text-secondary-text hover:text-primary-main"),`${n} font-sans font-normal text-sm`},jt=(e,t)=>t?`${"bg-white"===e?"bg-primary-main":e} ${Ct}`:Ct,Dt=a((({context:e,burgerSubMenu:t,onClick:a,defaultLocation:i="",children:l})=>{const[s,c]=e.useGeolocation(i);return r("div",{className:"absolute top-0 left-0 w-full h-full bg-white p-4 box-border z-20",children:[n("button",{className:"absolute top-4 right-4 border-none bg-transparent cursor-pointer",onClick:a,children:n(m,{name:"CloseIcon",width:"24",height:"24",asSVG:!0})}),r("button",{onClick:c,className:"flex items-center text-sm text-secondary-text mb-4 bg-transparent cursor-pointer",children:[n(m,{name:"GeolocationIcon",width:"20",height:"20",className:"text-primary-main box-border mr-2",asSVG:!0}),s]}),l,n("div",{className:"mb-7",children:t?.map(It)}),n(ut,{context:e,className:"grow"})]})})),It=(e,t)=>{const{icon:a,href:i,text:l}=e;return r("a",{href:i,className:"flex text-sm mb-4 hover:text-primary-main",children:[a?n(m,{className:"text-primary-main pr-1",name:a,width:"24",height:"24",asSVG:!0}):null,n("span",{className:"pl-0.5 font-medium",children:l})]},`headerSubMenu-${t}`)},Lt=a((({onClick:e,bgColor:t})=>r("div",{className:"flex items-center justify-between border-0 border-b border-main-divider h-[50px]",children:[r("div",{className:"flex items-center",children:[n("button",{className:"pr-4 border-0 bg-transparent cursor-pointer",onClick:e,"aria-label":"Открыть меню",children:n(m,{name:"bg-white"===t?"BurgerIcon":"BurgerIconWhite",width:"24",height:"24",asSVG:!0})}),n(nt,{bgColor:t})]}),n("button",{className:("bg-white"===t?"text-primary-main":"text-white")+" text-sm border-0 bg-transparent cursor-pointer",children:"Войти"})]}))),Bt=a((({className:e="",defaultLocation:t,bgColor:a="bg-white",context:i,topItems:l,burgerSubMenu:s})=>{const c=i.useRouter(),o=function(e){const{data:t}=e(St(),$t);return t||{}}(i.useAsyncData),{handlerDecorator:m}=i,d=kt(o.topItems,l).find(vt(c))?.items,h=(e=>(t=[])=>{const n=t?.filter(yt(e));var r;return n?.length?(r=e=>e.href?.length||0,e=>e.reduceRight(((e,t)=>r(e)>r(t)?e:t)))(n):null})(c)(d),[x,p]=i.useState(!1),u=()=>p(!x);return r("header",{className:`${a} ${e}`,children:[r("div",{className:"container px-4 py-0 box-border",children:[n(Lt,{onClick:u,bgColor:a}),n("nav",{className:"flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]",children:n("div",{className:"flex no-scrollbar horizontal-list h-full items-center",children:d?.map(((e,t)=>Rt({...U({router:c,handlerDecorator:m},e),active:e===h,bgColor:a},t)))})})]}),x?n(Dt,{context:i,onClick:u,burgerSubMenu:s,defaultLocation:t,children:n(He,{context:i,accordionItems:ft(l),className:"p-0 pt-0 pb-0 mb-4"})}):null]})})),Rt=(e,t)=>n(Tt,{className:"mr-8 whitespace-nowrap text-sm",...e},String(t)),Vt={primary:"text-primary-text",secondary:"text-white"},At={primary:"text-secondary-text",secondary:"text-white"};const Ot=a((({className:e="",context:t,title:a,headingType:i="h2",description:l,benefits:c,buttons:o,image:d,items:h,version:x="primary"})=>r("div",{className:`w-full text-primary-text ${e}`,children:[n("div",{children:r(te,{context:t,title:a&&n(s,{headingType:i,title:a,className:"whitespace-pre-wrap max-w-[600px]"}),buttons:o?.length?n(q,{context:t,buttons:o,className:"flex flex-col mt-5 gap-2.5"}):null,children:[l?n(ee,{className:"mt-3",description:l}):null,c?.filter((e=>e.label))?.length?n("div",{className:"mt-3",children:c.map(((e,t)=>function(e,t,a){return r("div",{className:"flex gap-3 items-center mb-2.5 last:mb-0",children:[e.icon&&n(m,{className:"w-6 h-6 rounded-full box-border",name:e.icon,width:"24",height:"24",asSVG:!0}),n("div",{className:`font-medium text-m-title-xs m-0 ${Vt[a]}`,children:e.label}),e.description&&n("div",{className:`font-normal text-m-sm ${At[a]}`,children:e.description})]},String(t))}(e,t,x)))}):null,h?.length?n(V,{className:"mt-3",items:h}):null]})}),Mt(d)]})));function Mt(e){return e?.src?n("div",{className:"mt-5",children:n(d,{image:{className:"block",...e}})}):null}const Pt=a((e=>{const{className:t}=e;return n("section",{className:`font-sans bg-white px-4 py-6 ${t||""}`,children:n(Ot,{...e})})})),Zt=a((({block:e,headingType:t,context:r})=>n("section",{className:"flex grow-0 shrink-0 basis-full px-4 pt-6",children:n("div",{className:"flex grow",children:n(Ot,{context:r,headingType:t||"h2",...e})})}))),Ht=a((({className:e,context:t,slides:r=[]})=>{const a=r.map((e=>e.productBlock));return n("section",{className:`font-sans bg-white overflow-hidden w-100 pb-6 ${e||""}`,children:n(N,{context:t,children:a.map(((e,r)=>n(Zt,{block:e,context:t},String(r))))})})})),zt=a((({className:e,title:t,description:a,steps:i,size:l="normal"})=>r("section",{className:`box-border font-sans text-primary-text bg-white px-4 py-6 flex flex-col ${e||""}`,children:[t&&n(s,{headingType:"h3",className:"text-center",title:t}),a&&n("p",{className:`text-m-md text-center ${t&&"mt-2"}`,children:a}),i?.length?n("div",{className:"box-border py-0.5 mb-0.5 mt-5",children:n("div",{className:"flex flex-col justify-between gap-x-[101px]",children:i.map(((e,t)=>Et({step:e,size:l,i:t,length:i.length})))})}):null]}))),Et=e=>{const{step:t,size:a,i:i,length:l}=e,s=l-1===i,c="normal"===a?"ml-[34px]":"ml-[24px]";return n("div",{children:r("div",{className:"flex flex-row text-center relative",children:[r("div",{children:[Gt(t,a,i),!s&&n("div",{className:`min-h-8 h-full w-[2px] bg-secondary-light ${c}`})]}),r("div",{className:"flex flex-col justify-start relative",children:[t.label&&n("div",{className:"font-medium text-m-title-xs m-0 text-left",children:t.label}),t.description&&n("div",{className:"font-normal text-sm text-secondary-text text-left "+(t.label?"mt-1":""),children:t.description})]})]},String(i))},String(i))},Gt=(e,t,r)=>{const a="normal"===t?"38":"27";return n("div",{className:`${"normal"===t?"h-[70px] w-[70px] min-w-[70px] min-h-[70px]":"h-[50px] w-[50px] min-w-[50px] min-h-[50px]"} bg-secondary-light rounded-full z-10 mr-3 flex justify-center content-center`,children:n("span",{className:`font-medium text-secondary-text self-center ${"normal"===t?"text-m-title":"text-m-title-xs"}`,children:e.icon&&n(m,{name:e.icon,width:a,height:a})||r+1})})},Ft={Accordion:He,ExchangeRateTile:We,Footer:bt,Gallery:xe,Header:Bt,Headline:x,LinkDocs:_,MobileAppTile:rt,ProductBlock:Pt,ProductGallery:Ht,StepsBlock:zt,TextBlock:O,LinkList:Ve},Wt=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:Ut()}))),Ut=()=>{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"})]})},Jt=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(Wt,{onClick:a.like,ariaLabel:"Поставить отметку «лайк»"}),n(Wt,{onClick:a.dislike,className:"rotate-180",ariaLabel:"Поставить отметку «дизлайк»"}),n("span",{className:"select-none",children:a.likeCount})]})})),Kt=a((({className:e,context:t,title:a,description:i="Блок в разработке..."})=>n("section",{className:`bg-white text-primary-text font-sans p-9 box-border ${e} ${ie(e)} ${ae(e)} `,children:r(te,{context:t,title:a?n(s,{headingType:re(e),title:a,className:"whitespace-pre-wrap max-w-[600px]"}):null,children:[i?n(ee,{className:"mt-4 max-w-[600px]",description:i}):null,n("figure",{className:"m-0 min-w-[600px]",children:Qt()})]})}))),Qt=(e=3)=>Yt(100,e).map((e=>Math.floor(e))).map(Xt),Xt=(e=100,t)=>n("div",{style:{width:`${e}%`},className:"h-4 mt-2 bg-secondary-light"},String(t)),Yt=(e,t)=>[e].concat(t>0?Yt(e/1.618,t-1):[]),qt=({blockClassName:e,block:t,render:n})=>n({blockClassName:e,block:t}),en=a((({className:e,context:t,blocksRegistry:a,data:{style:i,blocks:l,slots:s={},likeControl:c,colorPalette:o="pc"},blockDecorator:m=qt})=>{const{header:d}=s;return r("section",{className:`relative ${nn(i)} ${e||""}`,"data-theme":o,children:[d?.blocks?.length?n("div",{className:`${nn(d?.style)}`,children:d.blocks.map(((e,n)=>tn({block:e,blockDecorator:m,blocksRegistry:a,context:t},n)))}):null,l?.length?n("div",{className:"container grid grid-cols-12 gap-1",children:l.map(((e,n)=>tn({block:e,blockDecorator:m,blocksRegistry:a,context:t},n)))}):null,c&&n("div",{className:"flex items-end absolute bottom-0 right-0 h-full pointer-events-none",children:n(Jt,{className:"rounded-tl-lg sticky bottom-0 pointer-events-auto",context:t})})]})}));function tn({block:e,blockDecorator:t,blocksRegistry:r,context:a},i){const{type:l}=e;l&&l in r||console.warn(`No block with "${l}" is registered`);const s=r[l||"Placeholder"]||Kt;return t({blockClassName:nn(e.style),block:e,render:e=>{const{version:t,content:r}=e.block;return n(s,{className:e.blockClassName,version:t,context:a,...r},`${l}-${i}`)}},`block-${i}`)}function nn(e){return e?e.join(" "):""}const rn=a((({HeadComponent:e,data:t,children:a})=>{const{title:i,main:l,og:s,twitter:c,jsonLd:o}=t,{description:m,keywords:d,canonical:h,robots:x}=l||{};return r(e,{children:[n("title",{children:i}),n("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),m&&n("meta",{name:"description",content:m}),d&&n("meta",{name:"keywords",content:d.join(",")}),x&&n("meta",{name:"robots",content:x.join(",")}),an(s),ln(c),h&&n("link",{rel:"canonical",href:h}),o&&n("script",{type:"application/ld+json",children:o}),a]})}));function an(e){return e?Object.entries(e).map((([e,t])=>n("meta",{name:`og:${e}`,content:t},e))):null}function ln(e){return e?Object.entries(e).map((([e,t])=>n("meta",{name:`twitter:${e}`,content:t},e))):null}function sn(e){const{mobile:t,...n}=e;return t?{...n,...t,content:{...n.content,...t.content}}:e}function cn(e){return e?.filter((e=>(e?.type||e?.mobile?.type||"")in Ft&&!e.mobile?.hidden)).map(sn)}e.Blocks=Ft,e.ContentPage=en,e.ContentPageHead=rn,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.Header=Bt,e.Icon=m,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.joinList=function(e){return t=>t.reduce(((t,n,r)=>t.length?t.concat({...e,key:r},n):[n]),[])},e.normalizePage=function(e){if(!e)return;const{blocks:t,slots:n}=e;return{...e,blocks:cn(t),slots:n&&Object.keys(n).reduce(((e,t)=>({...e,[t]:{...n[t],blocks:cn(n[t].blocks)}})),{})}},e.projectSettings=c,e.setup=t,e.url=E,Object.defineProperty(e,"__esModule",{value:!0})}));
@@ -22,7 +22,7 @@ exports.Header = (0, uni_jsx_1.JSX)(({ className = '', defaultLocation, bgColor
22
22
  const activeSubItem = (0, findActiveSubItem_1.findActiveSubItem)(router)(subItems);
23
23
  const [burgerMenuShow, setBurgerMenuShow] = context.useState(false);
24
24
  const toggleBurgerMenu = () => setBurgerMenuShow(!burgerMenuShow);
25
- return ((0, jsx_runtime_1.jsxs)("header", { className: `${bgColor} ${className}`, children: [(0, jsx_runtime_1.jsxs)("div", { className: "container px-4 py-0 box-border", children: [(0, jsx_runtime_1.jsx)(HeaderTop_1.HeaderTop, { onClick: toggleBurgerMenu, bgColor: bgColor }), (0, jsx_runtime_1.jsx)("nav", { className: "flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]", children: (0, jsx_runtime_1.jsx)("div", { className: "flex", children: subItems?.map((_, i) => renderSubItem({
25
+ return ((0, jsx_runtime_1.jsxs)("header", { className: `${bgColor} ${className}`, children: [(0, jsx_runtime_1.jsxs)("div", { className: "container px-4 py-0 box-border", children: [(0, jsx_runtime_1.jsx)(HeaderTop_1.HeaderTop, { onClick: toggleBurgerMenu, bgColor: bgColor }), (0, jsx_runtime_1.jsx)("nav", { className: "flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]", children: (0, jsx_runtime_1.jsx)("div", { className: "flex no-scrollbar horizontal-list h-full items-center", children: subItems?.map((_, i) => renderSubItem({
26
26
  ...(0, useLink_1.useLink)({ router, handlerDecorator }, _),
27
27
  active: _ === activeSubItem,
28
28
  bgColor,
@@ -1 +1 @@
1
- {"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../src/components/Header/Header.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AACxC,iDAA8C;AAC9C,gFAA6E;AAC7E,4EAAyE;AACzE,wEAAqE;AACrE,kEAA+D;AAE/D,mEAAgE;AAEhE,qEAAkE;AAClE,sDAAmD;AACnD,iDAA8C;AAE9C,2CAAwC;AAI3B,QAAA,MAAM,GAAG,IAAA,aAAG,EACvB,CAAC,EAAE,SAAS,GAAG,EAAE,EAAE,eAAe,EAAE,OAAO,GAAG,UAAU,EAAE,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,EAAE,EAAE;IAC9F,MAAM,MAAM,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC;IACnC,MAAM,OAAO,GAAG,IAAA,uBAAU,EAAC,OAAO,CAAC,YAAY,CAAC,CAAC;IACjD,MAAM,EAAE,gBAAgB,EAAE,GAAG,OAAO,CAAC;IAErC,MAAM,WAAW,GAAG,IAAA,6BAAa,EAAC,OAA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enefit_1 = require("./renderBenefit");
12
12
  exports.ProductBlockInner = (0, uni_jsx_1.JSX)(({ className = '', context, title, headingType = 'h2', description, benefits, buttons, image, items, version = 'primary', }) => {
13
- return ((0, jsx_runtime_1.jsxs)("div", { className: `w-full text-primary-text ${className}`, children: [(0, jsx_runtime_1.jsx)("div", { children: (0, jsx_runtime_1.jsxs)(BaseTile_1.BaseTile, { context: context, title: title && ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: headingType, title: title, className: `whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}` })), buttons: buttons?.length ? ((0, jsx_runtime_1.jsx)(ButtonSection_1.ButtonSection, { context: context, buttons: buttons, className: "flex flex-col mt-5 gap-2.5" })) : null, children: [description ? (0, jsx_runtime_1.jsx)(Description_1.Description, { className: "mb-5", description: description }) : null, benefits?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "mt-5", children: benefits.map((_, i) => (0, renderBenefit_1.renderBenefit)(_, i, version)) })) : null, items?.length ? (0, jsx_runtime_1.jsx)(List_1.List, { items: items }) : null] }) }), renderImage(image)] }));
13
+ return ((0, jsx_runtime_1.jsxs)("div", { className: `w-full text-primary-text ${className}`, children: [(0, jsx_runtime_1.jsx)("div", { children: (0, jsx_runtime_1.jsxs)(BaseTile_1.BaseTile, { context: context, title: title && ((0, jsx_runtime_1.jsx)(Heading_1.Heading, { headingType: headingType, title: title, className: "whitespace-pre-wrap max-w-[600px]" })), buttons: buttons?.length ? ((0, jsx_runtime_1.jsx)(ButtonSection_1.ButtonSection, { context: context, buttons: buttons, className: "flex flex-col mt-5 gap-2.5" })) : null, children: [description ? (0, jsx_runtime_1.jsx)(Description_1.Description, { className: "mt-3", description: description }) : null, benefits?.filter((items) => items.label)?.length ? ((0, jsx_runtime_1.jsx)("div", { className: "mt-3", children: benefits.map((_, i) => (0, renderBenefit_1.renderBenefit)(_, i, version)) })) : null, items?.length ? (0, jsx_runtime_1.jsx)(List_1.List, { className: "mt-3", items: items }) : null] }) }), renderImage(image)] }));
14
14
  });
15
15
  function renderImage(image) {
16
16
  return image?.src ? ((0, jsx_runtime_1.jsx)("div", { className: "mt-5", children: (0, jsx_runtime_1.jsx)(Img_1.Img, { image: { className: 'block', ...image } }) })) : null;
@@ -1 +1 @@
1
- {"version":3,"file":"ProductBlockInner.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/ProductBlockInner.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,qEAAkE;AAClE,sEAAmE;AACnE,0DAAuD;AACvD,8CAA2C;AAC3C,iDAA8C;AAC9C,mDAAgD;AAEhD,mDAAgD;AAInC,QAAA,iBAAiB,GAAG,IAAA,aAAG,EAClC,CAAC,EACC,SAAS,GAAG,EAAE,EACd,OAAO,EACP,KAAK,EACL,WAAW,GAAG,IAAI,EAClB,WAAW,EACX,QAAQ,EACR,OAAO,EACP,KAAK,EACL,KAAK,EACL,OAAO,GAAG,SAAS,GACpB,EAAE,EAAE;IACH,OAAO,CACL,iCAAK,SAAS,EAAE,4BAA4B,SAAS,EAAE,aACrD,0CACE,wBAAC,mBAAQ,IACP,OAAO,EAAE,OAAO,EAChB,KAAK,EACH,KAAK,IAAI,CACP,uBAAC,iBAAO,IACN,WAAW,EAAE,WAAW,EACxB,KAAK,EAAE,KAAK,EACZ,SAAS,EAAE,qCAAqC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,GACrE,CACH,EAEH,OAAO,EACL,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,CAChB,uBAAC,6BAAa,IACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,SAAS,EAAC,4BAA4B,GACtC,CACH,CAAC,CAAC,CAAC,IAAI,aAGT,WAAW,CAAC,CAAC,CAAC,uBAAC,yBAAW,IAAC,SAAS,EAAC,MAAM,EAAC,WAAW,EAAE,WAAW,GAAI,CAAC,CAAC,CAAC,IAAI,EAC/E,QAAQ,EAAE,MAAM,CAAC,CAAC,CAAC,CAClB,gCAAK,SAAS,EAAC,MAAM,YAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,IAAA,6BAAa,EAAC,CAAC,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC,GAAO,CACnF,CAAC,CAAC,CAAC,IAAI,EACP,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,uBAAC,WAAI,IAAC,KAAK,EAAE,KAAK,GAAI,CAAC,CAAC,CAAC,IAAI,IACrC,GACP,EACL,WAAW,CAAC,KAAK,CAAC,IACf,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,SAAS,WAAW,CAAC,KAAK;IACxB,OAAO,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,CAClB,gCAAK,SAAS,EAAC,MAAM,YACnB,uBAAC,SAAG,IAAC,KAAK,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,GAAI,GAC5C,CACP,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC"}
1
+ {"version":3,"file":"ProductBlockInner.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/ProductBlockInner.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAExC,qEAAkE;AAClE,sEAAmE;AACnE,0DAAuD;AACvD,8CAA2C;AAC3C,iDAA8C;AAC9C,mDAAgD;AAEhD,mDAAgD;AAInC,QAAA,iBAAiB,GAAG,IAAA,aAAG,EAClC,CAAC,EACC,SAAS,GAAG,EAAE,EACd,OAAO,EACP,KAAK,EACL,WAAW,GAAG,IAAI,EAClB,WAAW,EACX,QAAQ,EACR,OAAO,EACP,KAAK,EACL,KAAK,EACL,OAAO,GAAG,SAAS,GACpB,EAAE,EAAE;IACH,OAAO,CACL,iCAAK,SAAS,EAAE,4BAA4B,SAAS,EAAE,aACrD,0CACE,wBAAC,mBAAQ,IACP,OAAO,EAAE,OAAO,EAChB,KAAK,EACH,KAAK,IAAI,CACP,uBAA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bgColor = 'bg-whit
20
20
  const activeSubItem = findActiveSubItem(router)(subItems);
21
21
  const [burgerMenuShow, setBurgerMenuShow] = context.useState(false);
22
22
  const toggleBurgerMenu = () => setBurgerMenuShow(!burgerMenuShow);
23
- return (_jsxs("header", { className: `${bgColor} ${className}`, children: [_jsxs("div", { className: "container px-4 py-0 box-border", children: [_jsx(HeaderTop, { onClick: toggleBurgerMenu, bgColor: bgColor }), _jsx("nav", { className: "flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]", children: _jsx("div", { className: "flex", children: subItems?.map((_, i) => renderSubItem({
23
+ return (_jsxs("header", { className: `${bgColor} ${className}`, children: [_jsxs("div", { className: "container px-4 py-0 box-border", children: [_jsx(HeaderTop, { onClick: toggleBurgerMenu, bgColor: bgColor }), _jsx("nav", { className: "flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]", children: _jsx("div", { className: "flex no-scrollbar horizontal-list h-full items-center", children: subItems?.map((_, i) => renderSubItem({
24
24
  ...useLink({ router, handlerDecorator }, _),
25
25
  active: _ === activeSubItem,
26
26
  bgColor,
@@ -1 +1 @@
1
- {"version":3,"file":"Header.js","sourceRoot":"","sources":["../../../src/components/Header/Header.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,iBAAiB,EAAE,MAAM,0CAA0C,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,wCAAwC,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAC;AAE/D,OAAO,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAC;AAEhE,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO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gCACE,GAAG,OAAO,CAAC,EAAE,MAAM,EAAE,gBAAgB,EAAE,EAAE,CAAC,CAAC;gCAC3C,MAAM,EAAE,CAAC,KAAK,aAAa;gCAC3B,OAAO;6BACR,EACD,CAAC,CACF,CACF,GACG,GACF,IACF,EACL,cAAc,CAAC,CAAC,CAAC,CAChB,KAAC,YAAY,IACX,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,gBAAgB,EACzB,aAAa,EAAE,aAAa,EAC5B,eAAe,EAAE,eAAe,YAEhC,KAAC,SAAS,IACR,OAAO,EAAE,OAAO,EAChB,cAAc,EAAE,iBAAiB,CAAC,QAAQ,CAAC,EAC3C,SAAS,EAAC,oBAAoB,GAC9B,GACW,CAChB,CAAC,CAAC,CAAC,IAAI,IACD,CACV,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,MAAM,aAAa,GAAG,CAAC,IAAkB,EAAE,CAAS,EAAE,EAAE,CAAC,CACvD,KAAC,UAAU,IAAiB,SAAS,EAAC,gCAAgC,KAAK,IAAI,IAA9D,MAAM,CAAC,CAAC,CAAC,CAAyD,CACpF,CAAC"}
@@ -8,7 +8,7 @@ import { List } from '../../ui-kit/List/List.js';
8
8
  import { BaseTile } from '../BaseTile/BaseTile.js';
9
9
  import { renderBenefit } from './renderBenefit.js';
10
10
  export const ProductBlockInner = JSX(({ className = '', context, title, headingType = 'h2', description, benefits, buttons, image, items, version = 'primary', }) => {
11
- return (_jsxs("div", { className: `w-full text-primary-text ${className}`, children: [_jsx("div", { children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType: headingType, title: title, className: `whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}` })), buttons: buttons?.length ? (_jsx(ButtonSection, { context: context, buttons: buttons, className: "flex flex-col mt-5 gap-2.5" })) : null, children: [description ? _jsx(Description, { className: "mb-5", description: description }) : null, benefits?.length ? (_jsx("div", { className: "mt-5", children: benefits.map((_, i) => renderBenefit(_, i, version)) })) : null, items?.length ? _jsx(List, { items: items }) : null] }) }), renderImage(image)] }));
11
+ return (_jsxs("div", { className: `w-full text-primary-text ${className}`, children: [_jsx("div", { children: _jsxs(BaseTile, { context: context, title: title && (_jsx(Heading, { headingType: headingType, title: title, className: "whitespace-pre-wrap max-w-[600px]" })), buttons: buttons?.length ? (_jsx(ButtonSection, { context: context, buttons: buttons, className: "flex flex-col mt-5 gap-2.5" })) : null, children: [description ? _jsx(Description, { className: "mt-3", description: description }) : null, benefits?.filter((items) => items.label)?.length ? (_jsx("div", { className: "mt-3", children: benefits.map((_, i) => renderBenefit(_, i, version)) })) : null, items?.length ? _jsx(List, { className: "mt-3", items: items }) : null] }) }), renderImage(image)] }));
12
12
  });
13
13
  function renderImage(image) {
14
14
  return image?.src ? (_jsx("div", { className: "mt-5", children: _jsx(Img, { image: { className: 'block', ...image } }) })) : null;
@@ -1 +1 @@
1
- {"version":3,"file":"ProductBlockInner.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/ProductBlockInner.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAIhD,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,CAClC,CAAC,EACC,SAAS,GAAG,EAAE,EACd,OAAO,EACP,KAAK,EACL,WAAW,GAAG,IAAI,EAClB,WAAW,EACX,QAAQ,EACR,OAAO,EACP,KAAK,EACL,KAAK,EACL,OAAO,GAA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AE,GAAI,GAC5C,CACP,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC"}
1
+ {"version":3,"file":"ProductBlockInner.js","sourceRoot":"","sources":["../../../src/components/ProductBlock/ProductBlockInner.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAExC,OAAO,EAAE,aAAa,EAAE,MAAM,mCAAmC,CAAC;AAClE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACvD,OAAO,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAIhD,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,CAClC,CAAC,EACC,SAAS,GAAG,EAAE,EACd,OAAO,EACP,KAAK,EACL,WAAW,GAAG,IAAI,EAClB,WAAW,EACX,QAAQ,EACR,OAAO,EACP,KAAK,EACL,KAAK,EACL,OAAO,GAAG,SAAS,GACpB,EAAE,EAAE;IACH,OAAO,CACL,eAAK,SAAS,EAAE,4BAA4B,SAAS,EAAE,aACrD,wBACE,MAAC,QAAQ,IACP,OAAO,EAAE,OAAO,EAChB,KAAK,EACH,KAAK,IAAI,CACP,KAAC,OAAO,IACN,WAAW,EAAE,WAAW,EACxB,KAAK,EAAE,KAAK,EACZ,SAAS,EAAC,mCAAmC,GAC7C,CACH,EAEH,OAAO,EACL,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,CAChB,KAAC,aAAa,IACZ,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,SAAS,EAAC,4BAA4B,GACtC,CACH,CAAC,CAAC,CAAC,IAAI,aAGT,WAAW,CAAC,CAAC,CAAC,KAAC,WAAW,IAAC,SAAS,EAAC,MAAM,EAAC,WAAW,EAAE,WAAW,GAAI,CAAC,CAAC,CAAC,IAAI,EAC/E,QAAQ,EAAE,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,CAAC,CAAC,CAClD,cAAK,SAAS,EAAC,MAAM,YAAE,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,aAAa,CAAC,CAAC,EAAE,CAAC,EAAE,OAAO,CAAC,CAAC,GAAO,CACnF,CAAC,CAAC,CAAC,IAAI,EACP,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC,KAAC,IAAI,IAAC,SAAS,EAAC,MAAM,EAAC,KAAK,EAAE,KAAK,GAAI,CAAC,CAAC,CAAC,IAAI,IACtD,GACP,EACL,WAAW,CAAC,KAAK,CAAC,IACf,CACP,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,SAAS,WAAW,CAAC,KAAK;IACxB,OAAO,KAAK,EAAE,GAAG,CAAC,CAAC,CAAC,CAClB,cAAK,SAAS,EAAC,MAAM,YACnB,KAAC,GAAG,IAAC,KAAK,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,GAAG,KAAK,EAAE,GAAI,GAC5C,CACP,CAAC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC"}
@@ -35,7 +35,7 @@ export const Header = JSX<HeaderProps>(
35
35
  <div className="container px-4 py-0 box-border">
36
36
  <HeaderTop onClick={toggleBurgerMenu} bgColor={bgColor} />
37
37
  <nav className="flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]">
38
- <div className="flex">
38
+ <div className="flex no-scrollbar horizontal-list h-full items-center">
39
39
  {subItems?.map((_, i) =>
40
40
  renderSubItem(
41
41
  {
@@ -14,5 +14,15 @@
14
14
  "version": "secondary"
15
15
  }
16
16
  ],
17
- "version": "primary"
17
+ "version": "primary",
18
+ "benefits": [
19
+ {
20
+ "label": "Преимущество №1",
21
+ "icon": "ClockIcon"
22
+ },
23
+ {
24
+ "label": "Преимущество №2",
25
+ "icon": "SignDocsIcon"
26
+ }
27
+ ]
18
28
  }
@@ -34,7 +34,7 @@ export const ProductBlockInner = JSX<ProductBlockInnerProps>(
34
34
  <Heading
35
35
  headingType={headingType}
36
36
  title={title}
37
- className={`whitespace-pre-wrap max-w-[600px] ${title ? 'mb-3' : ''}`}
37
+ className="whitespace-pre-wrap max-w-[600px]"
38
38
  />
39
39
  )
40
40
  }
@@ -48,11 +48,11 @@ export const ProductBlockInner = JSX<ProductBlockInnerProps>(
48
48
  ) : null
49
49
  }
50
50
  >
51
- {description ? <Description className="mb-5" description={description} /> : null}
52
- {benefits?.length ? (
53
- <div className="mt-5">{benefits.map((_, i) => renderBenefit(_, i, version))}</div>
51
+ {description ? <Description className="mt-3" description={description} /> : null}
52
+ {benefits?.filter((items) => items.label)?.length ? (
53
+ <div className="mt-3">{benefits.map((_, i) => renderBenefit(_, i, version))}</div>
54
54
  ) : null}
55
- {items?.length ? <List items={items} /> : null}
55
+ {items?.length ? <List className="mt-3" items={items} /> : null}
56
56
  </BaseTile>
57
57
  </div>
58
58
  {renderImage(image)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redneckz/wildless-cms-uni-blocks",
3
- "version": "0.3.10",
3
+ "version": "0.3.11",
4
4
  "private": false,
5
5
  "license": "MIT",
6
6
  "author": "ЦК",
@@ -35,7 +35,7 @@ export const Header = JSX<HeaderProps>(
35
35
  <div className="container px-4 py-0 box-border">
36
36
  <HeaderTop onClick={toggleBurgerMenu} bgColor={bgColor} />
37
37
  <nav className="flex items-center m-0 p-0 overflow-y-hidden w-full h-[50px]">
38
- <div className="flex">
38
+ <div className="flex no-scrollbar horizontal-list h-full items-center">
39
39
  {subItems?.map((_, i) =>
40
40
  renderSubItem(
41
41
  {
@@ -14,5 +14,15 @@
14
14
  "version": "secondary"
15
15
  }
16
16
  ],
17
- "version": "primary"
17
+ "version": "primary",
18
+ "benefits": [
19
+ {
20
+ "label": "Преимущество №1",
21
+ "icon": "ClockIcon"
22
+ },
23
+ {
24
+ "label": "Преимущество №2",
25
+ "icon": "SignDocsIcon"
26
+ }
27
+ ]
18
28
  }
@@ -1,6 +1,8 @@
1
1
  import type { Picture } from '../../model/Picture';
2
2
  import { context } from '../../setup-fixture';
3
3
  import { ProductBlock } from './ProductBlock';
4
+ import { ButtonWithIconProps } from '../../ui-kit/Button/ButtonProps';
5
+ import { Benefit } from '../BenefitsBlock/BenefitsBlockContent';
4
6
 
5
7
  const image: Picture = {
6
8
  src: 'money-1.png',
@@ -18,45 +20,68 @@ const image: Picture = {
18
20
  ],
19
21
  };
20
22
 
23
+ const benefits = [
24
+ {
25
+ label: 'До 5 млн ₽',
26
+ description: 'Кредитный лимит',
27
+ icon: 'EmptyWalletIcon',
28
+ },
29
+ {
30
+ label: 'От 16,9%',
31
+ description: 'Ставка по кредиту',
32
+ icon: 'PercentageSquareIcon',
33
+ },
34
+ {
35
+ label: 'До 5 лет',
36
+ description: 'Срок кредитования',
37
+ icon: 'CalendarIcon',
38
+ },
39
+ ];
40
+
41
+ const buttons = [
42
+ {
43
+ href: 'https://rshb.ru',
44
+ text: 'Оформить карту',
45
+ target: '_blank',
46
+ version: 'primary',
47
+ },
48
+ {
49
+ href: 'https://rshb.ru',
50
+ text: 'Подробнее',
51
+ target: '_blank',
52
+ version: 'secondary',
53
+ },
54
+ ] as ButtonWithIconProps;
55
+
56
+ const items = [
57
+ 'Совершайте любые личные покупки',
58
+ 'Используйте корпоративную карту как обычную дебетовую, если вы ИП',
59
+ 'Расходы для бизнеса на УСН 15% позволят снизить налоговую базу',
60
+ ];
61
+
21
62
  export default {
22
- primary: (
63
+ default: (
64
+ <div className="container grid grid-cols-12">
65
+ <ProductBlock
66
+ className="col-span-12"
67
+ context={context}
68
+ title={'Кредит до 5 000 000 Р\nбез залога и поручителей'}
69
+ description="Кредит наличными без залога и поручительства. Потребительский кредит на любые цели. Нужен только паспорт."
70
+ benefits={benefits as Benefit[]}
71
+ buttons={buttons as ButtonWithIconProps[]}
72
+ image={image}
73
+ />
74
+ </div>
75
+ ),
76
+ items: (
23
77
  <div className="container grid grid-cols-12">
24
78
  <ProductBlock
25
79
  className="col-span-12"
26
80
  context={context}
27
81
  title={'Кредит до 5 000 000 Р\nбез залога и поручителей'}
28
82
  description="Кредит наличными без залога и поручительства. Потребительский кредит на любые цели. Нужен только паспорт."
29
- benefits={[
30
- {
31
- label: 'До 5 млн ₽',
32
- description: 'Кредитный лимит',
33
- icon: 'EmptyWalletIcon',
34
- },
35
- {
36
- label: 'От 16,9%',
37
- description: 'Ставка по кредиту',
38
- icon: 'PercentageSquareIcon',
39
- },
40
- {
41
- label: 'До 5 лет',
42
- description: 'Срок кредитования',
43
- icon: 'CalendarIcon',
44
- },
45
- ]}
46
- buttons={[
47
- {
48
- href: 'https://rshb.ru',
49
- text: 'Оформить карту',
50
- target: '_blank',
51
- version: 'primary',
52
- },
53
- {
54
- href: 'https://rshb.ru',
55
- text: 'Подробнее',
56
- target: '_blank',
57
- version: 'secondary',
58
- },
59
- ]}
83
+ items={items}
84
+ buttons={buttons as ButtonWithIconProps[]}
60
85
  image={image}
61
86
  />
62
87
  </div>