(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6041],{82619:function(e,t,n){"use strict";n.d(t,{y:function(){return x}});var a=n(57437),i=n(75461),l=n(5426),o=n(54365),s=n(33145),r=n(2265),c=n(76670),u=n(81486),_=n(92449),d=n(75873),p=n(72151),m=n(31219),h=n(48034),f=n(29184),v=n(73927),g=n.n(v);let x=(0,r.memo)(e=>{let{title:t,content:n,pageUrl:v,infoLink:x,chips:D,isMobile:C,isShowChips:b,isExpandSettings:y,onToggleSettings:k,isSavingAccount:A,titleClassName:N,calculatorClassName:j,chevronSrc:T=c.Z,withNewMarkup:w,eventCategory:P,productId:S}=e,I=(0,i.s4)(),L=e=>{(0,d.D)({eventCategory:v,eventAction:d.i.popup,eventActionText:e}),null==k||k()},O=(0,h.Z)(10),M=(0,r.useCallback)(()=>{x&&(w&&(0,p.lQ)({eventCategory:P,eventLabel:S,eventAction:"click_".concat((0,m.b)(x.text))}),(0,l.ld)(x.idScrollBlock,{offset:O,position:"top"}))},[P,x,S,O,w]);return(0,a.jsxs)(l.W2,{className:(0,o.Z)(g().container,j),children:[(0,a.jsxs)("button",{className:(0,o.Z)(g().title,A&&g().marginNone,N),"data-testid":"calculator-settings-button",onClick:()=>L(t),children:[t,(0,a.jsx)(s.default,{className:(0,o.Z)(g().collapseArrow,y&&g().collapseArrowOpened),src:T,alt:""})]}),(0,a.jsxs)(_.u,{className:(0,o.Z)(g().fieldsContainer,!I&&g().initialCollapsed),isOpen:y||!C,children:[(0,a.jsx)("div",{className:g().fieldsWrapper,children:n}),(0,a.jsx)(f.Y,{className:g().disclaimer,text:"Все ".concat(A?"счета":"вклады"," застрахованы в АСВ")})]}),x&&x.isShow&&(0,a.jsx)(u.j,{offPadding:x.offPadding,widthMaxContent:x.widthMaxContent,text:x.text,iconColor:"light",mainPageUrl:v,className:g().link,onClick:M,isCustomMarkup:w}),b&&!A&&(0,a.jsx)(l.ev,{className:(0,o.Z)(g().chips,!I&&g().initialChips),options:D,selected:D,multiple:!0,theme:"secondary",size:"medium"})]})});x.displayName="Calculator"},29184:function(e,t,n){"use strict";n.d(t,{Y:function(){return u}});var a=n(57437),i=n(54365),l=n(33145),o=n(2265),s={src:"/deposits/_next/static/media/ASV-square.dfc8f22f.svg",height:24,width:24,blurWidth:0,blurHeight:0},r=n(82042),c=n.n(r);let u=(0,o.memo)(e=>{let{text:t,className:n,hideIcon:o=!1}=e;return(0,a.jsxs)("p",{className:(0,i.Z)(c().disclaimer,n),children:[!o&&(0,a.jsx)(l.default,{className:c().iconASV,src:s,alt:"Иконка АСВ"}),t]})});u.displayName="DepositDisclaimer"},23468:function(e,t,n){"use strict";n.d(t,{M:function(){return _}});var a=n(57437),i=n(5426),l=n(54365),o=n(50666),s=n(2265),r=n(75873),c=n(33176),u=n.n(c);let _=(0,s.memo)(e=>{let{className:t,url:n,text:s,title:c}=e;return(0,a.jsxs)(i.W2,{className:(0,l.Z)(u().container,t),children:[(0,a.jsx)("h3",{className:u().title,dangerouslySetInnerHTML:{__html:c}}),(0,a.jsx)("h4",{className:u().text,dangerouslySetInnerHTML:{__html:s}}),(0,a.jsx)(i.zx,{as:"a",variant:"purple",href:"/".concat(n),onClick:()=>{(0,r.D)({eventCategory:n,eventAction:r.i.button,eventActionText:"Подобрать предложение",url:"".concat((0,o.env)("NEXT_PUBLIC_BASE_URL"),"/").concat(n)})},className:u().button,children:"Подобрать предложения"})]})});_.displayName="ArchivePromo"},21301:function(e,t,n){"use strict";n.d(t,{V:function(){return c}});var a=n(57437),i=n(54365),l=n(44587),o=n(11359),s=n(281),r=n.n(s);let c=e=>{let{className:t,text:n,tooltipText:s,theme:c="primary",tipIcon:u,onTooltipOpen:_}=e;return(0,a.jsx)("div",{className:(0,i.Z)(r().tag,{[r().tagPrimary]:"primary"===c,[r().tagSecondary]:"secondary"===c,[r().tagPink]:"pink"===c,[r().tagYellow]:"yellow"===c},t),children:s&&(0,a.jsx)(o.C,{className:r().detail,iconSrc:l.Z,text:s,iconClassName:r().detailIcon,icon:u,onOpen:()=>null==_?void 0:_(n),children:(0,a.jsx)("span",{className:r().text,children:n})})})}},91627:function(e,t,n){"use strict";n.d(t,{F:function(){return a}});let a=30.416},72096:function(e,t,n){"use strict";n.d(t,{$k:function(){return i},k5:function(){return l},kJ:function(){return a}});let a=[{label:"Добавлять ко вкладу (капитализация)",value:"add"},{label:"Выплачивать",value:"dont_add"}],i=[{label:"В конце срока",value:"end"},{label:"Ежедневно",value:"daily"},{label:"Раз в месяц",value:"1"},{label:"Раз в квартал",value:"3"},{label:"Раз в полгода",value:"6"},{label:"Раз в год",value:"12"}],l=[{label:"Не предусмотрено",value:"0"},{label:"Раз в месяц",value:"1"},{label:"Раз в 2 месяца",value:"2"},{label:"Раз в квартал",value:"3"},{label:"Раз в 4 месяца",value:"4"},{label:"Раз в полгода",value:"6"},{label:"Раз в год",value:"12"}]},32523:function(e,t,n){"use strict";n.d(t,{n:function(){return z}});var a=n(57437);n(38068);var i=n(53685),l=n(5426),o=n(54365),s=n(2265),r=n(21301),c=n(69589),u=n(14862),_=n(44579),d=n(35563),p=n(32817),m=n.n(p);function h(e){let{loading:t}=e;return(0,a.jsxs)("div",{className:(0,o.Z)(m().skeletonContainer,t&&m().visible),children:[(0,a.jsx)(d.Od,{className:m().skeletonDate}),(0,a.jsx)(d.Od,{className:m().skeletonProfit})]})}var f=n(27648),v=n(11359),g=n(87566),x=n(23e3),D=n.n(x);function C(e){let{rowCount:t,loading:n}=e;return(0,a.jsx)("div",{className:(0,o.Z)(D().skeletonContainer,n&&D().visible),children:Array.from(Array(t).keys()).map(e=>(0,a.jsx)(d.Od,{className:D().skeleton},e))})}var b=n(70104),y=n(72151),k=n(31219),A=n(90297),N=n.n(A);function j(e){var t;let{withNewMarkup:n,rate:i,effectiveRate:o,hideExternalLinks:r,profit:c,unit:u,extraInfo:_,isSavingAccount:d,salaryToggle:p,setSalaryToggle:m,discount:h,bonus:x,firstDepositBonusTitle:D,tipIcon:A,switchRate:j,onSwitchRate:T,isRateSwitched:w,eventCategory:P,productId:S,isCombo:I=!1,isLoading:L}=e,O=(0,s.useCallback)(()=>{T&&(T(!w),(0,y.lQ)({event:"data-event",eventAction:"click_button_perekluchit_stavku",eventCategory:P,eventLabel:S}))},[T,w,P,S]),M=(0,s.useCallback)(e=>()=>{(0,y.lQ)({event:"data-event",eventAction:"click_link_".concat((0,k.b)(e)),eventCategory:P,eventLabel:S})},[P,S]),E=(0,s.useMemo)(()=>{var e;let t=[{label:"Доход от банка",value:"".concat((0,b.Y4)(c,2)," ").concat(u)}];if((null===(e=_.algo)||void 0===e?void 0:e.id)==="mkb-nakop"&&t.push({label:"Открытие дебетовой карты",value:"Да",description:d&&null!=_.karta?_.karta.label:"Открывая счет, Вы соглашаетесь на оформление дебетовой карты банка"},{label:"Действие счета",value:"Бессрочно"},{label:"Зарплата или пенсия на карту МКБ",value:(0,a.jsx)(l.jw,{checked:p,className:N().singleToggle,onChange:()=>null==m?void 0:m(!p)}),description:(0,a.jsx)(a.Fragment,{children:"Процентная ставка применяется при условии зачисления заработной платы от юридических лиц и индивидуальных предпринимателей на картсчет Клиента, открытый в Банке или суммы пенсий от Фонда пенсионного и социального страхования Российской Федерации или иных органов (учреждений) на любой счет Клиента, открытый в Банке, поступивших в течение 60 календарных дней до каждой даты начисления процентов по счету."})}),i&&t.unshift({label:"Ставка",value:"".concat((0,b.Y4)(i,2),"%")}),o&&t.unshift({label:"Эффективная ставка",value:"".concat((0,b.Y4)(o,2),"%"),description:(0,a.jsxs)(a.Fragment,{children:["Иногда у вклада есть особенности — капитализация процентов, возможность пополнения или акция от банка. Дополнительные параметры меняют доход в большую или меньшую сторону, поэтому процент по эффективной ставке отличается от банковской. Он отражает доход корректнее."," ",!r&&(0,a.jsx)(f.default,{className:N().tooltipLink,target:"_self",onClick:M("Подробнее о том, как считать сложный процент"),href:"".concat(g._n,"/navigator/nakopit-i-sohranit/stat_chto_takoe_slozhnyj_procent_po_vkladu_i_kak_ego_poschitat?ysclid=lfmam3zaig67098551%22"),children:"Подробнее о том, как считать сложный процент"})]})}),h&&x){let e=I?"%":" ".concat(u);t.push({label:D?"Бонус за первый вклад":"Бонус от Финуслуг",value:"".concat((0,b.Y4)(x,2)).concat(e),description:null==h?void 0:h.description})}return t},[x,h,o,null===(t=_.algo)||void 0===t?void 0:t.id,_.karta,D,M,r,d,c,i,p,m,u,I]),B=!!j&&(null==j?void 0:j.difference)>0,R=B?"+".concat((0,b.Y4)(j.difference,1),"% к ставке"):null,Z=(0,s.useCallback)(e=>{(0,y.lQ)({eventAction:"click_question_".concat((0,k.b)(e)),eventCategory:P,eventLabel:S})},[P,S]);return(0,a.jsxs)("ul",{className:N().values,children:[(0,a.jsx)(C,{loading:L,rowCount:E.length}),E.map(e=>(0,a.jsxs)("li",{className:N().value,children:[(0,a.jsx)("div",{children:e.label}),e.description&&(0,a.jsx)(v.C,{text:e.description,className:N().detail,onOpen:()=>n&&Z(e.label),icon:A}),(0,a.jsx)("div",{className:N().valueDash}),(0,a.jsx)("div",{children:e.value})]},e.label)),B&&R&&(0,a.jsxs)("li",{className:N().value,children:[(0,a.jsx)("div",{children:R}),(0,a.jsx)(v.C,{text:"При сумме вклада от ".concat((0,b.Y4)(j.minAmount)," ₽"),className:N().detail,icon:A,onOpen:()=>n&&Z(R)}),(0,a.jsx)(l.jw,{onChange:O,checked:w,className:N().toggle,size:"small"})]})]})}var T=n(37162);let w=e=>{let{depositType:t,isHideButtons:n,isShowDepositTip:a,isSavingAccount:i}=e,l=t===c.P.isPlatformDeposit?"Как открыть вклад":"Где открыть вклад",o=t===c.P.isPlatformDeposit?"Как открыть накопительный счет":"Где открыть накопительный счет";return{helpButtonLabel:i?o:l,blockId:t===c.P.isPlatformDeposit?T.a6:T.VT,isShowMainButton:!n&&t===c.P.isPlatformDeposit||t===c.P.isLidgenDeposit,isShowHelpButton:t!==c.P.isArchiveDeposit&&a&&!n,isOfferText:t===c.P.isPlatformDeposit||t===c.P.isLidgenDeposit}};var P=n(2674),S=n(53931),I=n(84948),L=n(32443),O=n(50017),M=n(33145),E={src:"/deposits/_next/static/media/edit.c0611721.svg",height:16,width:16,blurWidth:0,blurHeight:0},B=n(45198),R=n(97291),Z=n(35041),V=n(56924),F=n(28734),H=n.n(F);function K(e){let{term:t,totalProfit:n,withChart:i,isChartOpen:l,isEditable:o=!0,endingDate:r,onEditButtonClick:c,onToggleChart:u}=e,_=(0,b.Y4)(n,2).split(","),d=(0,s.useMemo)(()=>r?(0,R.f)(r):function(e){let t=new Date;return(0,R.f)(B.Z.day(t,e))}(t),[r,t]);return(0,a.jsxs)("div",{className:H().head,children:[(0,a.jsxs)("h4",{className:H().title,children:["Накопите к ",d]}),(0,a.jsxs)("h5",{className:H().result,children:[(0,a.jsxs)("span",{className:H().resultText,children:[_[0],_[1]?(0,a.jsxs)(a.Fragment,{children:[",",(0,a.jsxs)("span",{className:H().resultTextFloat,children:[_[1]," ₽"]})]}):" ₽"]}),o&&(0,a.jsx)("button",{className:H().resultButton,onClick:c,children:(0,a.jsx)(M.default,{className:H().resultIcon,src:E,alt:"edit"})})]}),i&&(0,a.jsx)(Z.W,{onClick:u,className:H().chartButton,icon:l?V.d.arrowBack:V.d.chart,alt:"chart"})]})}var Y=n(56257),U=n.n(Y);let Q=(0,s.memo)(e=>{let{href:t,id:n,pageType:i,eventCategory:o,withNewMarkup:s,eventLabel:r}=e;return(0,a.jsx)(l.zx,{as:"a",className:U().button,target:"_blank",href:t,size:"s",disabled:!t,onClick:()=>{(0,y.lQ)({event:"data-event",eventLabel:r,eventCategory:o,eventAction:s?"click_button_open_online":"open_in_bank_product",eventValue:null!=n?n:""})},children:i===c.P.isPlatformDeposit?"Открыть онлайн":"Перейти на сайт банка"})});Q.displayName="MainButton";let W={highlights:null,title:null,description:null,variant:"secondary",primaryAuthProviders:["ALFA","SBER","TINKOFF","VTB","MTS","SOVCOM","PHONE"],additionalAuthProviders:[],extraAuthProviders:[],primaryTextOverride:"Открыть вклад"},z=(0,s.memo)(e=>{var t,n;let{onEdit:d,isMobile:p,rate:m,sum:f,term:v,tag:g,appUrl:x,discount:D,isRateSwitched:C,onSwitchRate:b,switchRate:A,isCapitalization:N,depositType:T,productId:M,unit:E,tags:B,isSavingAccount:R,extraInfo:Z,salaryToggle:V,setSalaryToggle:F,isShowDepositTip:H,isHideButtons:Y=!1,paymentFrequency:z,customActions:G,shortChipsList:q=!1,firstDepositBonusTitle:J=!1,scrollOffset:X,computeClassName:$,withChart:ee,tipIcon:et,tagIcon:en,customTagTitle:ea,hideExternalLinks:ei=!1,computeHeader:el,computeTag:eo,eventCategory:es,withNewMarkup:er,totalValues:ec,isEditable:eu=!0,isCombo:e_=!1,calculatedProfit:ed,calculatedTotalProfit:ep,calculatedEffectiveRate:em,calculatedBonus:eh,integrationType:ef,calculatedEndingDate:ev,isLoading:eg=!1}=e,[ex,eD]=(0,s.useState)(!1),eC=new Date;eC.setDate(eC.getDate()+v);let{total:eb,bonus:ey,effectiveRate:ek,profit:eA}=(0,I.Z)({depositSum:f,term:v,rate:m,isCapitalization:N,discount:T===c.P.isPlatformDeposit?D:null,period:_.Z.Day,paymentFrequency:z}),eN=ed||eA,ej=ep||eb,eT=eh||ey,ew=function(e){let{integrationType:t}=e,{toggles:{FEATURE_TOGGLE_INTERNAL_REFERAL_LOGIN_ENABLED:n}}=(0,P.ND)(),a=(0,s.useMemo)(()=>(0,S.$1)(),[]),i=(null==a?void 0:a["auth.gtm_customer_id"])||null;return n&&"INTERNAL_REFERAL"===t&&!i}({integrationType:ef}),{helpButtonLabel:eP,blockId:eS,isShowMainButton:eI,isShowHelpButton:eL,isOfferText:eO}=w({depositType:T,isHideButtons:Y,isShowDepositTip:H,isSavingAccount:R}),eM=(0,s.useCallback)(()=>{(0,y.lQ)({event:"data-event",eventAction:er?"click_button_how_to_open":"click_button_".concat((0,k.b)(eP)),eventCategory:es,eventLabel:M}),(0,l.ld)(eS,{offset:X,position:"top"})},[eS,es,eP,M,X,er]),eE=(0,s.useCallback)(()=>{eD(e=>!e),(0,y.lQ)({event:"data-event",eventAction:"click_icon_diagramma",eventCategory:es,eventLabel:M})},[es,M]),eB=(0,s.useCallback)(()=>{d&&(d(),(0,y.lQ)({event:"data-event",eventAction:er?"click_pencil":"click_icon_redactirovanie",eventCategory:es,eventLabel:M}))},[es,d,M,er]),eR=(0,s.useCallback)(e=>{(0,y.lQ)({eventCategory:es,eventLabel:M,eventAction:"click_chips_".concat((0,k.b)(e))})},[es,M]),eZ=(0,s.useCallback)(()=>{var e;return g&&g.title?null!==(e=null==eo?void 0:eo(g))&&void 0!==e?e:(0,a.jsx)(r.V,{className:U().tag,text:null!=ea?ea:g.title,tooltipText:g.description,tipIcon:en,onTooltipOpen:e=>er&&eR(e)}):null},[eo,ea,eR,g,en,er]),{widgetConfig:eV,isWidgetDataLoading:eF}=(0,L.B)({disabled:!ew}),eH=(0,s.useCallback)(()=>{if(eI)return ew&&(eV||eF)?(0,a.jsx)(i.U,{baseUrl:u.m.LK_URL,s3AssetsUrl:u.m.ASSETS_URL,skeleton:(0,a.jsx)(l.zx,{pending:!0,className:U().button,size:"s",label:"Открыть вклад",disabled:!0}),className:(0,o.Z)(U().button,U().loginWidget),serverConfig:eV?{...eV,consents:[],legalInfo:null}:void 0,config:W,query:{targetUri:x},isSilent:!0}):(0,a.jsx)(Q,{href:x,id:M,pageType:T,eventCategory:es,withNewMarkup:er,eventLabel:ec})},[eI,ew,eV,eF,x,M,T,es,er,ec]);return(0,a.jsxs)(l.W2,{className:(0,o.Z)(U().container,ex&&U().containerChart,$),children:[null!==(n=null==el?void 0:el(ej,eB))&&void 0!==n?n:(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(h,{loading:eg}),(0,a.jsx)(K,{term:v,totalProfit:ej,withChart:ee&&!e_,isChartOpen:ex,isEditable:eu,endingDate:ev,onEditButtonClick:eB,onToggleChart:eE})]}),(0,a.jsxs)("div",{className:U().info,children:[(0,a.jsx)(O.H,{isMobile:p,className:(0,o.Z)(U().chart,ex&&U().chartVisible),sum:f,bonus:ey,profit:eN}),(0,a.jsxs)("div",{className:U().tags,children:[!q&&(null==B?void 0:B.map(e=>{let{title:t,description:n}=e;return(0,a.jsx)(r.V,{className:U().tag,text:t,tooltipText:n,theme:"pink",onTooltipOpen:eR},t)})),eZ(),!q&&(null===(t=Z.algo)||void 0===t?void 0:t.id)==="mkb-nakop"&&Z.algo.extraTag&&(0,a.jsx)(r.V,{className:U().tag,...Z.algo.extraTag,onTooltipOpen:eR})]}),(0,a.jsx)(j,{withNewMarkup:er,rate:m,effectiveRate:em||ek,hideExternalLinks:ei,profit:eN,unit:E,extraInfo:Z,isSavingAccount:R,salaryToggle:V,setSalaryToggle:F,discount:D,bonus:eT,firstDepositBonusTitle:J,tipIcon:et,switchRate:A,onSwitchRate:b,isRateSwitched:C,eventCategory:es,productId:M,isCombo:e_,isLoading:eg}),null==G?void 0:G(v),eH(),eL&&(0,a.jsx)(l.zx,{onClick:eM,className:U().button,size:"s",variant:"secondary",children:eP}),eO&&(0,a.jsx)("h3",{className:U().disclaimer,children:"Предварительный расчет. Не является офертой"})]})]})});z.displayName="DepositDetailCompute"},75217:function(e,t,n){"use strict";var a=n(2265);t.default=(0,a.createContext)(void 0)},60341:function(e,t,n){"use strict";n.d(t,{default:function(){return o}});var a=n(57437),i=n(2265),l=n(75217);function o(e){let{children:t,siteConfig:n}=e,[o]=(0,i.useState)(n);return(0,a.jsx)(l.default.Provider,{value:o,children:t})}},2674:function(e,t,n){"use strict";n.d(t,{ZP:function(){return r.default},ND:function(){return s}}),(a=i||(i={})).Beeline="beeline",a.T2="t2",a.Megafon="megafon",i.Beeline,i.T2,i.Megafon,i.T2,i.Beeline,i.Megafon,i.T2,i.Beeline,i.Megafon;var a,i,l=n(2265),o=n(75217);function s(){let e=(0,l.useContext)(o.default);if(!e)throw Error("Site config was used out of context");return e}var r=n(60341)},45198:function(e,t,n){"use strict";var a=n(92668),i=n(44579);let l={[i.Z.Day]:(e,t)=>(0,a.I)(e,{days:t}),[i.Z.Month]:(e,t)=>(0,a.I)(e,{months:t}),[i.Z.Year]:(e,t)=>(0,a.I)(e,{years:t})};t.Z=l},84948:function(e,t,n){"use strict";n.d(t,{Z:function(){return m}});var a=n(69775),i=n(89981),l=n(92668),o=n(85873),s=n(53970),r=n(52603),c=n(91627),u=n(40309),_=n(44579),d=n(45198);function p(e){let{capitalization:t,paymentFrequency:n,dateStart:a,termByYears:i,amount:l,averageRate:o,termInDays:s}=e;if(t){let e=o/100;if(n===u.Z.OnceAMonth){let t=s/c.F,n=l*Math.pow(1+e/12,t)-l,a=n/l/t*1200;return{profit:n,effectiveRate:a}}if(n===u.Z.EveryDay){let t=i.reduce((t,n)=>t*Math.pow(1+e/n.daysInYear,n.daysInInterval),l)-l,n=t/l/s*(0,r.y)(a)*100;return{profit:t,effectiveRate:n}}}return{profit:i.reduce((e,t)=>e+o/100*l/t.daysInYear*t.daysInInterval,0),effectiveRate:o}}function m(e){let{depositSum:t,term:n,rate:c,isCapitalization:u=!1,discount:m,period:h,paymentFrequency:f,dateStart:v=new Date}=e,g=d.Z[h](v,n),x=h===_.Z.Day?n:(0,s.w)(g,v),D=function(e,t,n){let c=(0,a.k)({start:e,end:t});return c.reduce((a,u,_)=>{let d=0===_?e:u,p=_===c.length-1?t:(0,i.u)((0,l.I)(d,{days:n}),{start:d,end:(0,l.I)((0,o.w)(u),{days:1})}),m=(0,s.w)(p,d);return 0===m?a:[...a,{daysInYear:(0,r.y)(u),daysInInterval:m}]},[])}(v,g,x),C={amount:t,paymentFrequency:f,dateEnd:g,dateStart:v,capitalization:u,termByYears:D,termInDays:x,averageRate:c},{profit:b,effectiveRate:y}=p(C),{bonus:k,bonusRate:A}=function(e,t){if(!t)return{bonus:0,bonusRate:0};let n=t.rate;if("fixedBonusAmount"in t&&t.fixedBonusAmount)return{bonus:t.fixedBonusAmount,bonusRate:n};let{profit:a}=p({...e,averageRate:n,capitalization:!1});if(a<t.sum)return{bonus:a,bonusRate:n};let i=t.sum/a;return{bonus:t.sum,bonusRate:n*i}}(C,m);return{total:t+b+k,bonus:k,profit:b,effectiveRate:y,bonusRate:A}}},19612:function(e,t,n){"use strict";n.d(t,{p:function(){return i}});class a{get hasKeysExistsSome(){return[...this.amountKeys,...this.termsKeys].some(e=>Object.prototype.hasOwnProperty.call(this.promotion,e))}get hasKeysExistsEvery(){return[...this.amountKeys,...this.termsKeys].every(e=>Object.prototype.hasOwnProperty.call(this.promotion,e))}get hasAmountKeys(){return this.amountKeys.some(e=>Object.prototype.hasOwnProperty.call(this.promotion,e))}get hasTermsKeys(){return this.termsKeys.some(e=>Object.prototype.hasOwnProperty.call(this.promotion,e))}checkMinMax(e,t,n){return(!!n||!!t)&&(n&&!t?e<=n:!n&&t?e>=t:e>=t&&e<=n)}getDiscountByAmount(){return this.checkMinMax(this.currentAmount,this.minAmount,this.maxAmount)}getDiscountByTerms(){return this.checkMinMax(this.terms,this.minTermInDays,this.maxTermInDays)}constructor(e,t){var n,a,i,l;this.promotion=e,this.minAmount=null!==(n=e.minAmount)&&void 0!==n?n:0,this.maxAmount=null!==(a=e.maxAmount)&&void 0!==a?a:0,this.minTermInDays=null!==(i=e.minTermInDays)&&void 0!==i?i:0,this.maxTermInDays=null!==(l=e.maxTermInDays)&&void 0!==l?l:0,this.terms=t.terms,this.currentAmount=t.currentAmount,this.amountKeys=["minAmount","maxAmount"],this.termsKeys=["minTermInDays","maxTermInDays"]}}let i=e=>{let{currentAmount:t,finuslugiBonusAllowed:n,isPlusFiveBonus:i,isOldUser:l,terms:o,finuslugiBonusPromotion:s}=e;if(!n)return!1;if(i)return!0;if(!s||!l)return!1;let r=new a(s,{terms:o,currentAmount:+t});return!r.hasAmountKeys&&!r.hasTermsKeys||(r.terms&&r.currentAmount||!r.hasKeysExistsEvery?!!(r.terms&&r.hasKeysExistsSome&&r.getDiscountByTerms())&&!!(r.currentAmount&&r.hasKeysExistsSome&&r.getDiscountByAmount()):r.getDiscountByTerms()&&r.getDiscountByAmount())}},39402:function(e,t,n){"use strict";n.d(t,{_:function(){return i}});var a=n(91220);function i(e){let{asPath:t,firstBaseUrl:n,productId:i,optionId:o,amount:s,durationValue:r,secondBaseUrl:c,passAggregatorId:u=!1,passCombo:_=!1}=e,{utm_campaign:d,utm_medium:p,utm_source:m,utm_term:h,aggregator_id:f}=(0,a.p)(t,"#"),{partner_id:v}=(0,a.p)(t,"?"),g=u?f:v;return{urlFirst:l(new URL("/add-product",n),{aggregatorId:null!=g?g:"moex-mp-new-sc",productId:i,optionId:o,amount:s,durationValue:r,utm_campaign:d,utm_medium:p,utm_source:m,utm_term:h,..._?{from:"combo"}:null}).toString(),urlSecond:c&&l(new URL(c),{amount:s,durationValue:r,utm_campaign:d,utm_medium:p,utm_source:m,utm_term:h,..._?{from:"combo"}:null}).toString()}}function l(e,t){let n=new URL(e);return Object.entries(t).forEach(e=>{let[t,a]=e;if(null!=a){if(Array.isArray(a))return a.forEach(e=>n.searchParams.append(t,String(e)));n.searchParams.set(t,String(a))}}),n}},39666:function(e,t,n){"use strict";n.d(t,{Y:function(){return a}});let a=e=>e.length?e[0].toUpperCase()+e.slice(1):""},23769:function(e,t,n){"use strict";n.d(t,{E:function(){return o}});var a=n(91627),i=n(36578);let l=e=>{let t=Math.floor(e/12),n=e%12,a=[];return t&&a.push((0,i.PY)(t,["год","года","лет"])),n&&a.push("".concat(n," мес")),a.join(" ")||"0 мес"},o=e=>l(Math.round(e/a.F))},2493:function(e,t,n){"use strict";n.d(t,{_:function(){return a}});let a=e=>{"Enter"===e.key&&e.currentTarget.blur()}},89911:function(e,t,n){"use strict";n.d(t,{d:function(){return l}});var a=n(2265),i=n(2938);function l(e,t,n){let{disabled:l=!1,separateLoaders:o=!1,...s}=null!=n?n:{},r=(0,i.ZP)(l?null:e,t,{revalidateOnFocus:!1,...s}),{isLoading:c,isValidating:u}=r,_=c||u;return(0,a.useMemo)(()=>({...r,isLoading:o?c:_,isValidating:o?u:_}),[_,c,u,o,r])}},32443:function(e,t,n){"use strict";n.d(t,{B:function(){return o}});var a=n(90856),i=n(14862),l=n(89911);function o(e){let{disabled:t}=null!=e?e:{},{data:n,isLoading:o}=(0,l.d)("login-widget",()=>(0,a.g)(i.m.LK_API,"deposit"),{disabled:t});return{widgetConfig:n,isWidgetDataLoading:o}}},50487:function(e,t,n){"use strict";n.d(t,{G:function(){return o}});var a=n(2265),i=n(70104),l=n(36578);let o=function(){let{type:e="text",unit:t,format:n,defaultValue:o="",maxLength:s=-1,maxFractionalLength:r=-1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},[c,u]=(0,a.useState)(o),_=(0,a.useRef)(c),[d,p]=(0,a.useState)(!1),m=(0,a.useCallback)((t,n)=>{"function"==typeof t&&(t=t(_.current));let a=String(t);if(!(s>-1)||!(a.length>s)){if(["int","float"].includes(e)){var i;if(isNaN(+t)||"int"===e&&a.includes(".")||"0"===a||a.includes(" ")||r>-1&&(null===(i=a.split(".")[1])||void 0===i?void 0:i.length)>r)return}_.current=a,u(a),null==n||n(a)}},[r,s,e]),h=(0,a.useMemo)(()=>({onChange:e=>m(e.currentTarget.value),onFocus:()=>p(!0),onBlur:()=>p(!1)}),[m]),f=(0,a.useMemo)(()=>{let a=c;"currency"===n&&["int","float"].includes(e)&&""!==c&&(a=(0,i.Y4)(+c));let o=(()=>{if(""===a)return"";switch(t){case"year":return(0,l._6)(+c,"год","года","лет");case"day":return(0,l._6)(+c,"день","дня","дней");default:return t||""}})();return o&&["int","float"].includes(e)?"".concat(a," ").concat(o):a},[n,e,t,c]);return(0,a.useMemo)(()=>({events:h,value:c,formattedValue:f,isFocused:d,handleChange:m}),[h,f,m,d,c])}},73927:function(e){e.exports={title:"Calculator_title__aC5Ud",container:"Calculator_container__vQuJ0",marginNone:"Calculator_marginNone__Hjy2l",collapseArrow:"Calculator_collapseArrow__Fm8Vk",collapseArrowOpened:"Calculator_collapseArrowOpened__Fbqar",fieldsContainer:"Calculator_fieldsContainer__5Rp05",initialCollapsed:"Calculator_initialCollapsed__GdleE",typeDescription:"Calculator_typeDescription__WHZqi",link:"Calculator_link__vCq4i",chips:"Calculator_chips__iGG5T",initialChips:"Calculator_initialChips__oiuSI",disclaimer:"Calculator_disclaimer__gr2ty"}},82042:function(e){e.exports={disclaimer:"DepositDisclaimer_disclaimer__pgXpL",iconASV:"DepositDisclaimer_iconASV__Ai2QW"}},33176:function(e){e.exports={title:"ArchivePromo_title__TJIJ7",container:"ArchivePromo_container__5L_r6",text:"ArchivePromo_text__nMo9K",button:"ArchivePromo_button__f_l5V"}},281:function(e){e.exports={tag:"Tag_tag__F7OOH",tagPrimary:"Tag_tagPrimary__avetL",tagSecondary:"Tag_tagSecondary__RMaKP",tagPink:"Tag_tagPink__YGm7U",tagYellow:"Tag_tagYellow__wh7Mz",text:"Tag_text__nOOMV",detail:"Tag_detail__xPW1b",detailIcon:"Tag_detailIcon__LNOTP"}},96024:function(e){e.exports={calculator:"DepositDetailCalculator_calculator__uCc_u",fieldsContainer:"DepositDetailCalculator_fieldsContainer__3ISJQ",input:"DepositDetailCalculator_input__lPHyT",inputError:"DepositDetailCalculator_inputError__9cOsR",inputRange:"DepositDetailCalculator_inputRange__eJR5n",chips:"DepositDetailCalculator_chips__mCKtS",legend:"DepositDetailCalculator_legend__GHEvN",chipsForm:"DepositDetailCalculator_chipsForm__UbRs_",collapseArrow:"DepositDetailCalculator_collapseArrow__zmlRp",collapseArrowOpened:"DepositDetailCalculator_collapseArrowOpened__DhduM",collapseArrowTitle:"DepositDetailCalculator_collapseArrowTitle__0v1_i",disclaimer:"DepositDetailCalculator_disclaimer___flSu",additionalButton:"DepositDetailCalculator_additionalButton__ViyCi",additionalContainer:"DepositDetailCalculator_additionalContainer__8sYDD",container:"DepositDetailCalculator_container__AXiy6",containerFull:"DepositDetailCalculator_containerFull__QUh5a",promo:"DepositDetailCalculator_promo__KDFX3",left:"DepositDetailCalculator_left__V9V0j",right:"DepositDetailCalculator_right__U4ABf",qrDesc:"DepositDetailCalculator_qrDesc__Fixg5",wide:"DepositDetailCalculator_wide__ItjPd",fivePercent:"DepositDetailCalculator_fivePercent__OgP8O",typeDescription:"DepositDetailCalculator_typeDescription__Nynxc",infoIcon:"DepositDetailCalculator_infoIcon__17O3e",expenseHead:"DepositDetailCalculator_expenseHead___7xlC",expenseSub:"DepositDetailCalculator_expenseSub__pnhPg"}},56257:function(e){e.exports={container:"DepositDetailCompute_container__wgV0n",containerChart:"DepositDetailCompute_containerChart__QUao0",info:"DepositDetailCompute_info___pqT7",tags:"DepositDetailCompute_tags__Le8d7",tag:"DepositDetailCompute_tag__DV451",button:"DepositDetailCompute_button__qK6jL",loginWidget:"DepositDetailCompute_loginWidget__3hRgV",detailIcon:"DepositDetailCompute_detailIcon__8lmnN",chart:"DepositDetailCompute_chart__S_HP1",chartVisible:"DepositDetailCompute_chartVisible__STX_r",tooltipLink:"DepositDetailCompute_tooltipLink__4gESn",buttonIcon:"DepositDetailCompute_buttonIcon__Zi3GE",disclaimer:"DepositDetailCompute_disclaimer__ZofBY",singleToggle:"DepositDetailCompute_singleToggle__tFiQ1"}},28734:function(e){e.exports={head:"Header_head__lMUs0",title:"Header_title__r4Wa_",result:"Header_result__SKeZv",resultText:"Header_resultText__UbYRQ",resultTextFloat:"Header_resultTextFloat__D5t0r",resultButton:"Header_resultButton__jXHD7",resultIcon:"Header_resultIcon__dJ1wD",chartButton:"Header_chartButton__AmKiY"}},32817:function(e){e.exports={skeletonContainer:"HeaderSkeleton_skeletonContainer___dhhJ",visible:"HeaderSkeleton_visible__arkXP",skeletonProfit:"HeaderSkeleton_skeletonProfit__PGN7g",skeletonDate:"HeaderSkeleton_skeletonDate__QrnJO"}},23e3:function(e){e.exports={skeletonContainer:"ProfitSkeleton_skeletonContainer__33exZ",visible:"ProfitSkeleton_visible__StSgI",skeleton:"ProfitSkeleton_skeleton___lU6r"}},90297:function(e){e.exports={values:"ValueList_values__mGunQ",value:"ValueList_value__RRvlg",valueDash:"ValueList_valueDash__mwitD",detail:"ValueList_detail__6tgWx",toggle:"ValueList_toggle__tin7w"}},44587:function(e,t){"use strict";t.Z={src:"/deposits/_next/static/media/detailed.37f1b990.svg",height:16,width:16,blurWidth:0,blurHeight:0}}}]);