1"use strict";(self.webpackChunkwealth_front=self.webpackChunkwealth_front||[]).push([[50],{9050:(te,W,u)=>{u.r(W),u.d(W,{CarterasModule:()=>Wt});var H=u(1389),lt=u(2575),Y=u(8810),Z=u(8152),tt=u(591),K=u(567),b=u(4850),_=u(7221),p=u(9595),et=u(8929),C=u(1086),q=u(520),t=u(5e3),k=u(4793),it=u(9783);let B=(()=>{class a{constructor(e,i,s,r){this.httpClient=e,this.dataStorage=i,this.i18=s,this.messageService=r,this.datos$=new et.xQ,this.rentabilidades$=new et.xQ}recuperarDatos(e,i,s,r){(0,K.D)([this.getInformacionObservable(e,s),this.getChartRentabilidadesObservable(e,i,s),this.getRentabilidadesMensualObservable(e,s),this.getRentabilidadesAcumuladasObservable(e,s),this.getRentabilidadesAnualesObservable(e,s),this.getTiposObservable(e,s),this.getZonasGeograficasObservable(e,s),this.getChartCategoriasObservable(e,s),this.getChartGestorasObservable(e,s),this.getCostesChartSectores(e,s),this.getChartRatingsObservable(e,s),this.getChartDivisasObservable(e,s),this.getChartTopObservable(e,s),this.getAnalisisObservable(e,s)]).subscribe(o=>{this.datos$.next(o)})}getInformacionObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_INFORMACION,{idioma:i,codigo:e,rentabilidad:"NONE"}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.cartera:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio informaci\xf3n"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}requestChartRentabilidades(e,i,s){return{idioma:s,idCartera:e,periodo:i}}getChartRentabilidadesObservable(e,i,s){const r=this.requestChartRentabilidades(e,i,s);return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_RENTABILIDADES,r).pipe((0,b.U)(o=>{const l=Object.assign({},o);return l.status===p.r.HTTP_STATUS_OK?o.rentabilidades:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:l.msg_descripcion}),null)}),(0,_.K)(o=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio rentabilidad"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartRentabilidad(e,i,s){const r=this.requestChartRentabilidades(e,i,s),o=new q.aW(p.r.HTTP_POST,this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_RENTABILIDADES,r,{reportProgress:!0});this.httpClient.request(o).subscribe(l=>{switch(l.type){case q.dt.Sent:break;case q.dt.Response:{const c=Object.assign({},l.body);c.status===p.r.HTTP_STATUS_OK?this.rentabilidades$.next(l.body.rentabilidades):this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:c.msg_descripcion})}}},l=>{this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio rentabilidades"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")})})}getTiposObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_TIPOS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.assets:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio tipos"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getZonasGeograficasObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_ZONAS_GEOGRAFICAS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.zonasGeograficas:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio zonas geogr\xe1ficas"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartGestorasObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_GESTORAS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.gestoras:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio gestoras"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartCategoriasObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_CATEGORIAS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.categorias:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio categorias"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getRentabilidadesMensualObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_RENTABILIDADES_MENSUAL,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio rentabilidades mensual"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getRentabilidadesAnualesObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_RENTABILIDADES_ANUALES,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.rentabilidadesAnuales:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio rentabilidades acumuladas"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getRentabilidadesAcumuladasObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_RENTABILIDADES_ACUMULADAS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.rentabilidadesAcumuladas:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio rentabilidades acumuladas"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getCostesChartSectores(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_SECTORES,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);if(o.status===p.r.HTTP_STATUS_OK)return r.sectores;this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion})}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio /ser-wealth/carteras/chart/sectores"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartRatingsObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_RATING,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.ratings:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio ratings"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartDivisasObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_DIVISAS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.divisas:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio divisas"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getChartTopObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CHART_TOP_POSICIONES,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);return o.status===p.r.HTTP_STATUS_OK?r.topten:(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion}),null)}
1),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio top posiciones"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}getAnalisisObservable(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_ANALISIS,{idioma:i,idCartera:e}).pipe((0,b.U)(r=>{const o=Object.assign({},r);if(o.status===p.r.HTTP_STATUS_OK)return r.analisis;this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion})}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio analisis"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}addCartera(e,i,s,r,o){const c=new q.aW(p.r.HTTP_POST,this.dataStorage.url_Server_Rest+a.SERVICIO_ADD_CESTA,{idioma:o,identificador:e,tipo:i,mercado:s,codigo:r},{reportProgress:!0});this.httpClient.request(c).subscribe(d=>{switch(d.type){case q.dt.Sent:break;case q.dt.Response:{const h=Object.assign({},d.body);h.status!=p.r.HTTP_STATUS_OK&&this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:h.msg_descripcion})}}},d=>{this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio a\xf1adir a mi cartera"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")})})}generarPdf(e,i,s){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CESTA_GENERAR_PDF,{codigo:e,idioma:i}).pipe((0,b.U)(o=>{const l=Object.assign({},o);if(l.status===p.r.HTTP_STATUS_OK)return o.id;this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:l.msg_descripcion})}),(0,_.K)(o=>(this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}updateEmailPdf(e,i){return this.httpClient.post(this.dataStorage.url_Server_Rest+a.SERVICIO_CESTA_UPDATE_EMAIL_PDF,{id:e,email:i}).pipe((0,b.U)(r=>{const o=Object.assign({},r);if(o.status===p.r.HTTP_STATUS_OK)return r;this.messageService.add({severity:"error",summary:this.i18.getValue("common.informacion"),detail:o.msg_descripcion})}),(0,_.K)(r=>(this.messageService.add({severity:"error",summary:this.i18.getValue("confirm-error-servicio.titulo",{servicio:"Servicio costes cargos"}),detail:this.i18.getValue("confirm-error-servicio.mensaje")}),(0,C.of)(null))))}}return a.SERVICIO_INFORMACION="/ser-wealth/carteras/info",a.SERVICIO_CHART_RENTABILIDADES="/ser-wealth/carteras/chart/rentabilidades",a.SERVICIO_RENTABILIDADES_MENSUAL="/ser-wealth/carteras/chart/updown",a.SERVICIO_TIPOS="/ser-wealth/carteras/chart/assets",a.SERVICIO_ZONAS_GEOGRAFICAS="/ser-wealth/carteras/chart/zonasgeograficas",a.SERVICIO_CHART_CATEGORIAS="/ser-wealth/carteras/chart/categorias",a.SERVICIO_CHART_GESTORAS="/ser-wealth/carteras/chart/gestoras",a.SERVICIO_CHART_RATING="/ser-wealth/carteras/chart/ratings",a.SERVICIO_CHART_DIVISAS="/ser-wealth/carteras/chart/divisas",a.SERVICIO_CHART_TOP_POSICIONES="/ser-wealth/carteras/chart/top",a.SERVICIO_ANALISIS="/ser-wealth/carteras/analisis_portfolio",a.SERVICIO_VER_PDF_INTRANET="/ser-wealth/carteras/informe/intranet",a.SERVICIO_RENTABILIDADES_ACUMULADAS="/ser-wealth/carteras/chart/acumuladas",a.SERVICIO_RENTABILIDADES_ANUALES="/ser-wealth/carteras/chart/anuales",a.SERVICIO_CHART_SECTORES="/ser-wealth/carteras/chart/sectores",a.SERVICIO_ADD_CESTA="/ser-wealth/cesta/add",a.SERVICIO_CESTA_GENERAR_PDF="/ser-wealth/carteras/informe",a.SERVICIO_CESTA_UPDATE_EMAIL_PDF="/ser-wealth/carteras/informe/update",a.\u0275fac=function(e){return new(e||a)(t.LFG(q.eN),t.LFG(Z.J),t.LFG(k.o),t.LFG(it.ez))},a.\u0275prov=t.Yz7({token:a,factory:a.\u0275fac,providedIn:"root"}),a})();var E=u(3075),at=u(2967),y=u(9808),N=u(2466);function ct(a,n){if(1&a&&(t.TgZ(0,"div",19),t._UZ(1,"img",20),t.TgZ(2,"p"),t._uU(3),t.qZA()()),2&a){const e=t.oxw();
1t.xp6(3),t.Oqu(e.errorMessageDescripcion)}}let dt=(()=>{class a{constructor(e,i,s){this.i18=e,this.bsModalService=i,this.utilsButtonService=s,this.captchaVerified=new tt.X(!1),this.errorMessageDescripcion=""}ngOnInit(){this.sumaForm=new E.cw({resultado:new E.NI(null,[E.kI.required])}),this.actualizarNumeros(),this.mensaje=this.bsModalService.config.mensaje,this.captchaVerified=this.bsModalService.config.isValid,this.utilsButtonService.submitedButtonChanged.next(!0)}actualizarNumeros(){this.numero1=Math.ceil(9*Math.random()),this.numero2=Math.ceil(9*Math.random())}validar(){let e=!0;return this.errorMessageDescripcion="",this.sumaForm.value.resultado!==this.numero1+this.numero2&&(this.actualizarNumeros(),this.errorMessageDescripcion=this.i18.getValue("captcha.resultado-incorrecto"),e=!1,this.sumaForm.get("resultado").reset()),e}onSubmit(){this.validar()&&(this.captchaVerified.next(!0),this.closeModal())}closeModal(){this.bsModalRef.hide()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(k.o),t.Y36(H.tT),t.Y36(at.N))},a.\u0275cmp=t.Xpm({type:a,selectors:[["lib-captcha"]],decls:26,vars:14,consts:[[1,"gvcmodal"],[1,"gvcmodalheader"],[1,"gvcmodalheader_cerrarmodal"],["src","assets/images/icons/24px/closeButtonNegro.svg",1,"icon",3,"click"],[1,"row","mb-2"],[1,"col-12"],[1,"row"],[3,"formGroup","ngSubmit"],[1,"input_container","col-md-12","col-sm-12"],[1,"input-group","gvc-input-group",2,"flex-wrap","nowrap"],[1,"input-group-addon","cutom-mat-icono-label"],[1,"ui-float-label","custom-ui-float-label"],["type","number","id","float-resultado","pInputText","","formControlName","resultado","aria-label","resultado","aria-describedby","basic-addon1","required","","pattern","[0-9]{1,3}",1,"cutom-mat","resultado-captcha"],["for","float-resultado"],[1,"row",2,"margin-top","20px"],[1,"col-10","alertas-section"],["class","alertas-error",4,"ngIf"],[1,"col-2"],["type","submit",1,"gvc-button","primary","mb-3","float-end","btn-enviar",3,"disabled"],[1,"alertas-error"],["src","assets/images/icons/24px/ico_alerta_s.svg"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"span",2)(3,"img",3),t.NdJ("click",function(){return i.closeModal()}),t.qZA()()(),t.TgZ(4,"div",4)(5,"div",5),t._uU(6),t.qZA()(),t.TgZ(7,"div",6)(8,"form",7),t.NdJ("ngSubmit",function(){return i.onSubmit()}),t.TgZ(9,"div",8)(10,"div",9)(11,"span",10),t._uU(12),t.qZA(),t.TgZ(13,"span",11),t._UZ(14,"input",12),t.TgZ(15,"label",13),t._uU(16),t.ALo(17,"translate"),t.qZA()()(),t.TgZ(18,"div",14)(19,"div",15),t.YNc(20,ct,4,1,"div",16),t.qZA(),t.TgZ(21,"div",17)(22,"button",18),t.ALo(23,"async"),t._uU(24),t.ALo(25,"translate"),t.qZA()()()()()()()),2&e&&(t.xp6(6),t.Oqu(i.mensaje),t.xp6(2),t.Q6J("formGroup",i.sumaForm),t.xp6(4),t.AsE(" ",i.numero1," + ",i.numero2," = "),t.xp6(4),t.Oqu(t.lcZ(17,8,"captcha.resultado-operacion")),t.xp6(4),t.Q6J("ngIf",""!==i.errorMessageDescripcion),t.xp6(2),t.Q6J("disabled",!i.sumaForm.valid||t.lcZ(23,10,i.submited$)),t.xp6(2),t.hij(" ",t.lcZ(25,12,"common.enviar")," "))},directives:[E._Y,E.JL,E.sg,E.wV,E.Fj,E.JJ,E.u,E.Q7,E.c5,y.O5],pipes:[N.X$,y.Ov],encapsulation:2}),a})();var ut=u(351),$=u(8441);let ht=(()=>{class a{constructor(e,i,s,r,o){this.dataStorage=e,this.carterasService=i,this.ngxService=s,this.i18=r,this.bsModalService=o}ngOnInit(){this.urlPoliticaPrivacidad=ut.V.URL_POLITICA_DE_PRIVACIDAD,this.urlPdf=this.bsModalService.config.idPdf,this.nombreInforme=this.bsModalService.config.nombreInforme,this.idFormularioHubspot=this.bsModalService.config.idFormularioHubspot,this.initForm_MailPdf(this.urlPdf),this.ngxService.stop()}initForm_MailPdf(e){let i=this;hbspt.forms.create({region:"na1",portalId:"9037667",formId:this.idFormularioHubspot,css:"",target:"#Form_SendMailPdf",translations:{es:{required:this.i18.getValue("hubspot.form-pdf.errores.requerido")}},onFormReady(s){},onFormSubmit:function(s){let r=document.querySelector('input[name="email"]');i.carterasService.updateEmailPdf(e,r.value).subscribe(),document.querySelector('input[name="url_pdf"]').value=`${i.dataStorage.url_Server_Rest}/ser-wealth/carteras/informe/${e}`,document.querySelector('input[name="nombre_informe"]').value=i.nombreInforme}})}closeModal(){this.bsModalRefAyudaFormulario.hide()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(Z.J),t.Y36(B),t.Y36($.LA),t.Y36(k.o),t.Y36(H.tT))},a.\u0275cmp=t.Xpm({type:a,selectors:[["lib-hubspot-formulario"]],decls:8,vars:0,consts:[[1,"gvcmodal"],[1,"gvcmodalheader_hubspot"],[1,"gvcmodalheader_hubspot_cerrarmodal",3,"click"],["src","assets/images/icons/24px/closeButtonNegro.svg",1,"icon"],[1,"help_modal_content"],["id","embedded_helpform",1,"help_container"],[1,"help_subcontainer"],["id","Form_SendMailPdf"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"span",2),t.NdJ("click",function(){return i.closeModal()}),t._UZ(3,"img",3),t.qZA()(),t.TgZ(4,"div",4)(5,"div",5)(6,"div",6),t._UZ(7,"div",7),t.qZA()()()())},encapsulation:2}),a})();var mt=u(8270),pt=u(359),st=u(5743),ft=u(7773),rt=u(9772),gt=u(845),vt=u(7307),ot=(u(8717),u(870));const bt=["chartContainer"];let _t=(()=>{class a{constructor(e,i,s){this.deviceService=e,this.datePipe=i,this.carterasService=s,this.datos=[],this.chart=null,this.zoom="5Y",this.chart_locale="es-es",this.chart_formatDate="d' 'MMMM' 'yyyy"}ngOnInit(){switch(this.isMobile=this.deviceService.isMobile(),this.isTablet=this.deviceService.isTablet(),this.isDesktop=this.deviceService.isDesktop(),this.fe
1cha=this.datePipe.transform(new Date,"dd/MM/yyyy"),this.idioma){case"ES":this.chart_locale="es-es";break;case"CA":this.chart_locale="ca-es"}this.chart=anychart.stock();const e=this.chart.plot(0);e.legend(!1),this.chart.crosshair(!1),this.chart.margin(0,70,0,0);const i=e.yAxis();i.orientation("right"),i.labels().fontWeight(400),i.labels().fontSize(12),i.labels().fontFamily("Poppins"),i.labels().format("{%Value}");const s=this.chart.plot(0).priceIndicator();s.stroke("#009CA3",2,"5 5"),s.value("last-visible"),s.label().background().fill("#009CA3"),s.label().fontColor("White").fontSize(12),s.label().format("{%value}{decimalsCount:2}"),this.chart.scroller(!1),this.chart.scroller().enabled(!1),this.chart.plot(0).xAxis().showHelperLabel(!1),this.chart.padding(10,0,0,0);const r=e.xAxis();r.height(40),r.background("#FFFFFF"),r.background().topStroke("#CECECE"),r.background().top(-1),e.xAxis({fontFamily:"Poppins"});const o=e.xAxis().labels();o.hAlign("center"),o.width(60),o.fontWeight(400),o.fontSize(11),o.fontFamily("Poppins"),o.format("{%tickValue}{dateTimeFormat:LLL \nyyyy}"),e.xAxis().minorLabels().format("{%tickValue}{dateTimeFormat:LLL \nyyyy}"),(new Date).getTimezoneOffset(),this.chart.tooltip().titleFormat("{%x}{dateTimeFormat:dd LLLL yyyy}"),e.xAxis({fontFamily:"Poppins"}),this.chart.selectRange("MAX"),this.chart.interactivity().zoomOnMouseWheel(!1),this.chart.contextMenu(!1),this.chart.credits().enabled(!1),this.rentabilidadesSuscription=this.carterasService.rentabilidades$.subscribe(h=>{this.dataTable.removeFirst(this.datos.length-1),this.rentabilidades=h,this.processData(),this.dataTable.addData(this.datos)})}aplicarZoom(e){this.zoom=e,this.carterasService.getChartRentabilidad(this.informacion.codigo,e,this.idioma)}ngOnChanges(e){if(e.rentabilidades&&void 0!==this.rentabilidades){this.processData(),this.dataTable=anychart.data.table(),this.dataTable.addData(this.datos);const r=this.dataTable.mapAs({value:1}),o=this.chart.plot(0);anychart.format.outputLocale(this.chart_locale),anychart.format.outputDateTimeFormat(this.chart_formatDate);const l=o.spline(r);l.normal().stroke("#009CA3"),this.chart.tooltip().background().fill("#000826");var s=l.tooltip().title();s.fontFamily("Poppins"),s.background().fill("#000826"),s.fontWeight(400),s.fontSize(12);const c=l.tooltip();c.fontFamily("Poppins"),c.background().fill("#000826"),c.fontWeight(400),c.fontSize(12),c.title({fontColor:"#FFFFFF"})}}processData(){var e;if((null===(e=this.rentabilidades)||void 0===e?void 0:e.length)>0){this.datos=[];for(let s=0;s<this.rentabilidades.length;s++){const r=this.rentabilidades[s],o=r.fecha.split("-");var i=new Date(o[0],+o[1]-1,+o[2]);const c=r.rentabilidad.toFixed(2),d=[i.getTime(),c];this.datos.push(d)}}}classZoom(e){let i="";return this.zoom==e&&(i="zoom-item-selected"),i}classContainerZoom(){let e="";return this.isMobile?e+=" justify-content-start":this.isDesktop&&(e+=" justify-content-end"),e}ngAfterViewInit(){this.chart.container(this.chartContainer.nativeElement),this.chart.draw()}ngOnDestroy(){void 0!==this.rentabilidadesSuscription&&this.rentabilidadesSuscription.unsubscribe()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(ot.x0),t.Y36(y.uU),t.Y36(B))},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-chart"]],viewQuery:function(e,i){if(1&e&&t.Gf(bt,7),2&e){let s;t.iGM(s=t.CRH())&&(i.chartContainer=s.first)}},inputs:{rentabilidades:"rentabilidades",informacion:"informacion",idioma:"idioma"},features:[t.TTD],decls:33,vars:29,consts:[[1,"chart-fichas-overview"],[1,"container-resumen"],[1,"texto"],[1,"material-icons"],[1,"container-zoom"],[1,"zoom-row"],[1,"zoom-item",3,"ngClass","click"],[1,"chart-ficha-evolution"],["chartContainer",""],[1,"texto-pie"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"span",3),t._uU(4,"horizontal_rule"),t.qZA(),t._uU(5),t.qZA(),t.TgZ(6,"div",4)(7,"div",5)(8,"div",6),t.NdJ("click",function(){return i.aplicarZoom("3M")}),t._uU(9),t.ALo(10,"translate"),t.qZA(),t.TgZ(11,"div",6),t.NdJ("click",function(){return i.aplicarZoom("6M")}),t._uU(12),t.ALo(13,"translate"),t.qZA(),t.TgZ(14,"div",6),t.NdJ("click",function(){return i.aplicarZoom("YTD")}),t._uU(15),t.ALo(16,"translate"),t.qZA()(),t.TgZ(17,"div",5)(18,"div",6),t.NdJ("click",function(){return i.aplicarZoom("1Y")}),t._uU(19),t.ALo(20,"translate"),t.qZA(),t.TgZ(21,"div",6),t.NdJ("click",function(){return i.aplicarZoom("3Y")}),t._uU(22),t.ALo(23,"translate"),t.qZA(),t.TgZ(24,"div",6),t.NdJ("click",function(){return i.aplicarZoom("5Y")}),t._uU(25),t.ALo(26,"translate"),t.qZA()()()()(),t._UZ(27,"div",7,8),t.TgZ(29,"div",9)(30,"p"),t._uU(31),t.ALo(32,"translate"),t.qZA()()),2&e&&(t.xp6(5),t.hij(" ",null==i.informacion?null:i.informacion.titulo," "),t.xp6(3),t.Q6J("ngClass",i.class
1Zoom("3M")),t.xp6(1),t.Oqu(t.lcZ(10,15,"carteras.details.evolution.chart.zoom-3M")),t.xp6(2),t.Q6J("ngClass",i.classZoom("6M")),t.xp6(1),t.Oqu(t.lcZ(13,17,"carteras.details.evolution.chart.zoom-6M")),t.xp6(2),t.Q6J("ngClass",i.classZoom("YTD")),t.xp6(1),t.Oqu(t.lcZ(16,19,"carteras.details.evolution.chart.zoom-YTD")),t.xp6(3),t.Q6J("ngClass",i.classZoom("1Y")),t.xp6(1),t.Oqu(t.lcZ(20,21,"carteras.details.evolution.chart.zoom-1Y")),t.xp6(2),t.Q6J("ngClass",i.classZoom("3Y")),t.xp6(1),t.Oqu(t.lcZ(23,23,"carteras.details.evolution.chart.zoom-3Y")),t.xp6(2),t.Q6J("ngClass",i.classZoom("5Y")),t.xp6(1),t.Oqu(t.lcZ(26,25,"carteras.details.evolution.chart.zoom-5Y")),t.xp6(6),t.AsE(" ",t.lcZ(32,27,"carteras.details.evolution.chart.description")," ",i.fecha," "))},directives:[y.mk],pipes:[N.X$],encapsulation:2}),a})(),Ct=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-evolution"]],inputs:{informacion:"informacion",rentabilidades:"rentabilidades",idioma:"idioma"},decls:1,vars:3,consts:[[3,"rentabilidades","informacion","idioma"]],template:function(e,i){1&e&&t._UZ(0,"app-chart",0),2&e&&t.Q6J("rentabilidades",i.rentabilidades)("informacion",i.informacion)("idioma",i.idioma)},directives:[_t],encapsulation:2}),a})();var G=u(7767);const At=["containerMonthlyPerformance"];let St=(()=>{class a{constructor(){this.chart=null,this.multiplyES5=function(e,i){return e*i}}ngOnInit(){let e;switch(this.chart=anychart.column(),this.chart.animation(!0),this.chart.interactivity().hoverMode("single"),this.chart.yAxis().stroke("transparent"),this.chart.yAxis().ticks(!1),this.chart.yAxis().labels().format("{%Value}%"),this.chart.yAxis().labels().fontWeight(400),this.chart.yAxis().labels().fontColor("#666"),this.chart.yAxis().labels().fontSize(12),this.chart.yAxis().labels().fontFamily("Poppins"),this.chart.xAxis().value(0).labels(!1),this.chart.xAxis().value(0).ticks(!1),this.chart.xAxis(2).stroke(null).orientation("bottom"),this.chart.xAxis(2).ticks(!1),anychart.format.outputLocale("hi-in"),this.idioma){case"ES":e="es-es";break;case"CA":e="ca-es"}const i=this.chart.xAxis(2).labels();i.hAlign("center"),i.width(60),i.fontWeight(400),i.fontColor("#666"),i.fontSize(12),i.fontFamily("Poppins"),i.format(function(){const l=new Date(this.tickValue).toLocaleDateString(e,{month:"short",year:"2-digit"}).split(" "),c=l[0];return c.charAt(0).toUpperCase()+c.slice(1)+"\n"+l[1]}),this.chart.labels(!1),this.chart.legend().enabled(!1),this.chart.interactivity().selectionMode("none"),this.chart.background({fill:"transparent"}),this.chart.contextMenu(!1),this.chart.credits().enabled(!1)}ngOnChanges(e){if(e.rentabilidadesMensual&&void 0!==this.rentabilidadesMensual){const s=[];if(this.dataSet)for(;this.dataSet.getRowsCount()>0;)this.dataSet.remove(this.dataSet.getRowsCount()-1);for(let l=0;l<this.rentabilidadesMensual.rentabilidades.length;l++){const c=this.rentabilidadesMensual.rentabilidades[l].fecha.split("-");var i=new Date(c[0],+c[1]-1,+c[2]);s.push({idioma:this.idioma,value:this.rentabilidadesMensual.rentabilidades[l].rentabilidad,x:i})}this.dataSet=anychart.data.set(s);const r=this.chart.column(this.dataSet);this.maximo=r.getStat("seriesMax"),this.minimo=r.getStat("seriesMin"),r.stroke(this.coloringFunction),r.fill(this.coloringFunction);const o=r.tooltip();o.fontFamily("Poppins"),o.background().fill("#000826"),o.fontWeight(400),o.fontSize(12),o.title({fontColor:"#FFFFFF"}),o.titleFormat(function(){let c;switch(this.getData("idioma")){case"es":c="es-es";break;case"ca":c="ca-es"}const h=new Date(this.x).toLocaleDateString(c,{month:"short",year:"2-digit"});return h.charAt(0).toUpperCase()+h.slice(1)}),o.format(function(){return function l(d,h){if(""===d&&void 0===d||"--"===d)return"";{let m,f;const v=Number(d);void 0!==h&&(d=v.toFixed(h));const g=(d=""+Number(d)).indexOf(".");-1===g?(f="",m=d):(m=d.substr(0,g),f=d.substr(g));let S=!1;Number(m)<0&&(S=!0,m=m.replace("-",""));const T=m.length%3,A=m.substr(T).match(/\d{3}/g);let V=m.substr(0,T);return A&&(V+=(T?".":"")+A.join(".")),S&&(V="-"+V),V+""+f.replace(".",",")+"%"}}(this.value,2)}),this.chart.barGroupsPadding(1)}}coloringFunction(){return this.value==this.series.getStat("seriesMax")?"#00871A":this.value==this.series.getStat("seriesMin")?"#D00F00":"#C1C1C1"}ngAfterViewInit(){this.chart.container(this.container.nativeElement),this.chart.draw()}}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-monthly-performance"]],viewQuery:function(e,i){if(1&e&&t.Gf(At,5),2&e){let s;t.iGM(s=t.CRH())&&(i.container=s.first)}},inputs:{rentabilidadesMensual:"rentabilidadesMensual",idioma:"idioma"},features:[t.TTD],decls:13,vars:18,consts:[[1,"container-monthly-performance"],["containerMonthlyPerformance",""],[1,"pie-chart"],[1,"gvc-chart-pie"],[1,"minimo"],[1,"maximo"]],template:function(e,i){1&e&&(t._UZ(0,"div",0,1),t.TgZ(2,"div",2)(3,"div",3),t._UZ(4,"div",4),t._uU(5),t.ALo(6,"translate"),t.ALo(7,"pu
1ntoDecimal"),t.qZA(),t.TgZ(8,"div",3),t._UZ(9,"div",5),t._uU(10),t.ALo(11,"translate"),t.ALo(12,"puntoDecimal"),t.qZA()()),2&e&&(t.xp6(5),t.AsE(" ",t.lcZ(6,4,"carteras.details.performance.monthly-performance.minimo")," ",t.gM2(7,6,i.minimo,!0,2,"%")," "),t.xp6(5),t.AsE(" ",t.lcZ(11,11,"carteras.details.performance.monthly-performance.maximo")," ",t.gM2(12,13,i.maximo,!0,2,"%")," "))},pipes:[N.X$,G.d],encapsulation:2}),a})();const Tt=["containerColumnsChart"];let Zt=(()=>{class a{constructor(e){this.i18=e,this.chart=null}ngOnInit(){this.chart=anychart.column(),this.chart.animation(!0),this.chart.interactivity().hoverMode("single"),this.chart.yAxis().stroke("transparent"),this.chart.yAxis().ticks(!1),this.chart.yAxis().labels().format("{%Value}%"),this.chart.yAxis().labels().fontWeight(400),this.chart.yAxis().labels().fontColor("#666"),this.chart.yAxis().labels().fontSize(12),this.chart.yAxis().labels().fontFamily("Poppins"),this.chart.xAxis().value(0).labels(!1),this.chart.xAxis().value(0).ticks(!1),this.chart.xAxis(2).stroke(null).orientation("bottom"),this.chart.xAxis(2).ticks(!1);const e=this.chart.xAxis(2).labels();e.hAlign("center"),e.width(60),e.fontWeight(400),e.fontColor("#666"),e.fontSize(12),e.fontFamily("Poppins"),this.chart.barGroupsPadding(8),this.chart.labels(!1),this.chart.legend().enabled(!1),this.chart.interactivity().selectionMode("none"),this.chart.contextMenu(!1),this.chart.background({fill:"transparent"}),this.chart.credits().enabled(!1)}ngOnChanges(e){if(e.rentabilidades&&void 0!==this.rentabilidades){const i=[];if(this.dataSet)for(;this.dataSet.getRowsCount()>0;)this.dataSet.remove(this.dataSet.getRowsCount()-1);switch(this.idContainer){case"rentabilidadesAcumuladas":i.push({value:this.rentabilidades.m3,x:this.i18.getValue("carteras.details.performance.cumulative-performance.m3")}),i.push({value:this.rentabilidades.m6,x:this.i18.getValue("carteras.details.performance.cumulative-performance.m6")}),i.push({value:this.rentabilidades.ytd,x:this.i18.getValue("carteras.details.performance.cumulative-performance.ytd")}),i.push({value:this.rentabilidades.y1,x:this.i18.getValue("carteras.details.performance.cumulative-performance.y1")}),i.push({value:this.rentabilidades.y3,x:this.i18.getValue("carteras.details.performance.cumulative-performance.y3")}),i.push({value:this.rentabilidades.y5,x:this.i18.getValue("carteras.details.performance.cumulative-performance.y5")});break;case"rentabilidadesAnuales":i.push({value:this.rentabilidades.ren_y1,x:this.rentabilidades.txt_y1}),i.push({value:this.rentabilidades.ren_y2,x:this.rentabilidades.txt_y2}),i.push({value:this.rentabilidades.ren_y3,x:this.rentabilidades.txt_y3}),i.push({value:this.rentabilidades.ren_y4,x:this.rentabilidades.txt_y4}),i.push({value:this.rentabilidades.ren_y5,x:this.rentabilidades.txt_y5}),i.push({value:this.rentabilidades.ren_y6,x:this.rentabilidades.txt_y6})}this.dataSet=anychart.data.set(i);const s=this.chart.column(this.dataSet);s.stroke("#009CA3"),s.fill("#009CA3");const r=s.tooltip();r.fontFamily("Poppins"),r.background().fill("#000826"),r.fontWeight(400),r.fontSize(12),"rentabilidadesAnuales"==this.idContainer&&r.titleFormat("{%x}"),r.title({fontColor:"#FFFFFF"}),r.format(function(){return function o(c,d){if(""===c&&void 0===c||"--"===c)return"";{let h,m;const f=Number(c);void 0!==d&&(c=f.toFixed(d));const v=(c=""+Number(c)).indexOf(".");-1===v?(m="",h=c):(h=c.substr(0,v),m=c.substr(v));let g=!1;Number(h)<0&&(g=!0,h=h.replace("-",""));const S=h.length%3,T=h.substr(S).match(/\d{3}/g);let A=h.substr(0,S);return T&&(A+=(S?".":"")+T.join(".")),g&&(A="-"+A),A+""+m.replace(".",",")+"%"}}(this.value,2)})}}ngAfterViewInit(){this.chart.container(this.container.nativeElement),this.chart.draw()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(k.o))},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-column-chart"]],viewQuery:function(e,i){if(1&e&&t.Gf(Tt,5),2&e){let s;t.iGM(s=t.CRH())&&(i.container=s.first)}},inputs:{rentabilidades:"rentabilidades",idContainer:"idContainer"},features:[t.TTD],decls:2,vars:0,consts:[[1,"w-full","container-columns-chart"],["containerColumnsChart",""]],template:function(e,i){1&e&&t._UZ(0,"div",0,1)},encapsulation:2}),a})(),yt=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-rentabilidades"]],inputs:{informacion:"informacion",rentabilidadesMensual:"rentabilidadesMensual",rentabilidadesAnuales:"rentabilidadesAnuales",rentabilidadesAcumuladas:"rentabilidadesAcumuladas",idioma:"idioma"},decls:25,vars:12,consts:[[1,"chart-fichas-rentabilidades"],[1,"titulo"],[1,"gvc-separator"],[3,"rentabilidadesMensual"],[1,"container-rentabilidades"],[1,"header-group-items"],[1,"container-items"],[1,"group-items"],["idContainer","rentabilidadesAcumuladas",3,"rentabilidades"],[1,"group-separador"],["idContainer","rentabilidadesAnuales",3,"rentabilidades"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"h4"),t._uU(3),t.ALo(4,"translate"),t.qZA(),t._UZ(5,"hr",2),t.qZA(),t._UZ(6,"app-monthly-performance",3),t.qZA(),t.TgZ(7,"div",4)(8,"div",5)(9,"h4"),t._uU(10),t.ALo(11,"translate"),t.qZA(),t._UZ(12,"hr",2),t.TgZ(13,"div",6)(14,"div",7),t._UZ(15,"app-column-chart",8),t.qZA()()(),t._UZ(16,"div",9),t.TgZ(17,"div",5)(18,"h4"),t._uU(19),t.ALo(20,"translate"),t.qZA(),t._UZ(21,"hr",2),t.TgZ(22,"div",6)(23,"div",7),t._UZ(24,"app-column-chart",10),t.qZA()()()()),2&e&&(t.xp6(3),t.hij(" ",t.lcZ(4,6,"carteras.details.performance.monthly-performance.title")," "),t.xp6(3),t.Q6J("rentabilidadesMensual",i.rentabilidadesMensual),t.xp6(4),t.hij(" ",t.lcZ(11,8,"carteras.details.performance.cumulative-performance.title")," "),t.xp6(5),t.Q6J("rentabilidades",i.rentabilidadesAcumuladas),t.xp6(4),t.hij(" ",t.lcZ(20,10,"carteras.details.performance.discrete-performance.title")," "),t.xp6(5),t.Q6J("rentabilidades",i.rentabilidadesAnuales))},directives:[St,Zt],pipes:[N.X$],encapsulation:2}),a})(),xt=(()=>{class a{constructor(){}}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-analisis"]],inputs:{analisis:"analisis"},decls:52,vars:46,consts:[[1,"container-analisis"],[1,"gvc-separator"],[1,"container-items"],[1,"group-items"],[1,"item"],[1,"item-descripcion-larga"],["matTooltipPosition","right","matTooltipClass","gvc-tooltip",1,"gvc-icon-info",3,"matTooltip","click"],["fundSize","matTooltip"],[1,"item-value"],["anualized_return","matTooltip"],[1,"group-separador"],["volatilidad","matTooltip"],["current_expenses","matTooltip"]],template:function(e,i){if(1&e){const s=t.EpF();t.TgZ(0,"div",0)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",1),t.TgZ(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5),t._uU(9),t.ALo(10,"translate"),t.TgZ(11,"span",6,7),t.NdJ("click",function(){return t.CHM(s),t.MAs(12).toggle()}),t.ALo(13,"translate"),t._uU(14," info "),t.qZA()(),t.TgZ(15,"div",8),t._uU(16),t.qZA()(),t.TgZ(17,"div",4)(18,"div",5),t._uU(19),t.ALo(20,"translate"),t.TgZ(21,"span",6,9),t.
1NdJ("click",function(){return t.CHM(s),t.MAs(22).toggle()}),t.ALo(23,"translate"),t._uU(24," info "),t.qZA()(),t.TgZ(25,"div",8),t._uU(26),t.ALo(27,"puntoDecimal"),t.qZA()()(),t._UZ(28,"div",10),t.TgZ(29,"div",3)(30,"div",4)(31,"div",5),t._uU(32),t.ALo(33,"translate"),t.TgZ(34,"span",6,11),t.NdJ("click",function(){return t.CHM(s),t.MAs(35).toggle()}),t.ALo(36,"translate"),t._uU(37," info "),t.qZA()(),t.TgZ(38,"div",8),t._uU(39),t.ALo(40,"puntoDecimal"),t.qZA()(),t.TgZ(41,"div",4)(42,"div",5),t._uU(43),t.ALo(44,"translate"),t.TgZ(45,"span",6,12),t.NdJ("click",function(){return t.CHM(s),t.MAs(46).toggle()}),t.ALo(47,"translate"),t._uU(48," info "),t.qZA()(),t.TgZ(49,"div",8),t._uU(50),t.ALo(51,"puntoDecimal"),t.qZA()()()()()}2&e&&(t.xp6(2),t.hij(" ",t.lcZ(3,13,"carteras.details.analisis.subtitle")," "),t.xp6(7),t.hij(" ",t.lcZ(10,15,"carteras.details.analisis.risk")," "),t.xp6(2),t.s9C("matTooltip",t.lcZ(13,17,"carteras.details.analisis.tooltips.risk")),t.xp6(5),t.hij(" ",null==i.analisis?null:i.analisis.riesgo," "),t.xp6(3),t.hij(" ",t.lcZ(20,19,"carteras.details.analisis.anualized-return")," "),t.xp6(2),t.s9C("matTooltip",t.lcZ(23,21,"carteras.details.analisis.tooltips.anualized-return")),t.xp6(5),t.hij(" ",t.gM2(27,23,null==i.analisis?null:i.analisis.rentabilididad,!0,2,"%")," "),t.xp6(6),t.hij(" ",t.lcZ(33,28,"carteras.details.analisis.volatility")," "),t.xp6(2),t.s9C("matTooltip",t.lcZ(36,30,"carteras.details.analisis.tooltips.volatility")),t.xp6(5),t.hij(" ",t.gM2(40,32,null==i.analisis?null:i.analisis.volatilidad,!0,2,"%")," "),t.xp6(4),t.hij(" ",t.lcZ(44,37,"carteras.details.analisis.current-expenses")," "),t.xp6(2),t.s9C("matTooltip",t.lcZ(47,39,"carteras.details.analisis.tooltips.current-expenses")),t.xp6(5),t.hij(" ",t.gM2(51,41,null==i.analisis?null:i.analisis.gastos_corrientes,!0,2,"%")," "))},directives:[rt.gM],pipes:[N.X$,G.d],encapsulation:2}),a})();var It=u(8185);function Rt(a,n){if(1&a&&(t.TgZ(0,"div",2)(1,"div",3),t._UZ(2,"p-progressBar",4),t.TgZ(3,"div",5),t._uU(4),t.ALo(5,"puntoDecimal"),t.qZA()()()),2&a){const e=n.$implicit,i=n.index;t.xp6(1),t.MGl("id","item-",i,""),t.xp6(1),t.MGl("styleClass","progressbar-",i,""),t.Q6J("value",e.valor)("showValue",!1),t.xp6(2),t.AsE("",e.descripcion," (",t.gM2(5,6,e.valor,!0,2,"%"),")")}}let Et=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-asset-class"]],inputs:{tipos:"tipos"},decls:2,vars:1,consts:[[1,"container-asset-class"],["class","row-asset-class",4,"ngFor","ngForOf"],[1,"row-asset-class"],[1,"item-asset-class",3,"id"],[3,"value","showValue","styleClass"],[1,"text-asset-class"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0),t.YNc(1,Rt,6,11,"div",1),t.qZA()),2&e&&(t.xp6(1),t.Q6J("ngForOf",i.tipos))},directives:[y.sg,It.k],pipes:[G.d],encapsulation:2}),a})();var nt=u(3766);const Ot=["containerZonasGeograficas"];function Mt(a,n){if(1&a){const e=t.EpF();t.TgZ(0,"div",5),t.NdJ("mouseover",function(){const s=t.CHM(e),r=s.$implicit,o=s.index;return t.oxw().mouseover(r,o)})("mouseout",function(){return t.CHM(e),t.oxw().mouseout()}),t.TgZ(1,"div",6),t._uU(2),t.qZA(),t.TgZ(3,"div",7),t._uU(4),t.ALo(5,"puntoDecimal"),t.qZA()()}if(2&a){const e=n.$implicit,i=n.index,s=t.oxw();t.Q6J("ngClass",s.indexSeleccionado==i?"item-seleccionado":null),t.xp6(2),t.hij(" ",e.descripcion," "),t.xp6(2),t.hij(" ",t.gM2(5,3,e.valor,!0,2,"%")," ")}}let Ut=(()=>{class a{constructor(e){this.utilNumbers=e,this.map=null,this.datos=[],this.indexSeleccionado=-1}ngOnInit(){this.map=anychart.map(),this.map.geoData("anychart.maps.world").padding(0),this.map.title(!1).enabled(!0).padding([0,0,10,0]),this.map.minBubbleSize("0.5%").maxBubbleSize("5%"),this.map.unboundRegions().fill("#d6dadc"),this.map.background({fill:"transparent"}),this.map.legend().enabled(!0).position("center-top").align("center").itemsLayout("horizontal").padding(0,0,30,0).paginator(!1),this.map.interactivity().selectionMode("none"),anychart.column().contextMenu(!1),this.map.tooltip().useHtml(!0).padding([8,13,10,13]).titleFormat(function(){return this.getData("descripcion")}).format(function(){return'<span style="color: #FFFFFF; font-size: 12px; font-weight: 400;font-family:Poppins">'+function r(l,c){if(""===l&&void 0===l||"--"===l)return"";{let d,h;const m=Number(l);void 0!==c&&(l=m.toFixed(c));
1const f=(l=""+Number(l)).indexOf(".");-1===f?(h="",d=l):(d=l.substr(0,f),h=l.substr(f));let v=!1;Number(d)<0&&(v=!0,d=d.replace("-",""));const g=d.length%3,S=d.substr(g).match(/\d{3}/g);let T=d.substr(0,g);return S&&(T+=(g?".":"")+S.join(".")),v&&(T="-"+T),T+""+h.replace(".",",")}}(this.getData("amount"),2)+"%</span>"}),this.map.tooltip().background().enabled(!0).fill("#000826").stroke("#000826").corners(3).cornerType("round"),this.map.interactivity().zoomOnMouseWheel(!1),this.map.interactivity().keyboardZoomAndMove(!1),this.map.interactivity().zoomOnDoubleClick(!1),this.map.listen("pointsHover",this.pointsHover,!0,this),this.map.listen("pointMouseOut",this.pointMouseOut,!0,this),this.map.contextMenu(!1),this.map.credits().enabled(!1)}pointsHover(e){const i=e.point,s=i.getIndex();if(!i.hovered())return;const r=this.datos[s],o=this.zonasGeograficas.findIndex(l=>l.region_un===r.id);this.indexSeleccionado=o}pointMouseOut(e){this.indexSeleccionado=-1}mouseover(e,i){if(e.valor>0){const s=this.datos.findIndex(r=>r.id===e.region_un);-1!=s&&this.series1.hover([s]),this.indexSeleccionado=i}}mouseout(){this.series1.unhover(),this.indexSeleccionado=-1}ngOnChanges(e){if(e.zonasGeograficas&&void 0!==this.zonasGeograficas){if(this.datos=[],this.dataSet)for(;this.dataSet.getRowsCount()>0;)this.dataSet.remove(this.dataSet.getRowsCount()-1);for(let s=0;s<this.zonasGeograficas.length;s++)this.zonasGeograficas[s].valor>0&&this.datos.push({id:this.zonasGeograficas[s].region_un,descripcion:this.zonasGeograficas[s].descripcion,percent:this.zonasGeograficas[s].valor,amount:this.zonasGeograficas[s].valor});this.dataSet=anychart.data.set(this.datos);const i=this.dataSet.mapAs({id:"id",size:"amount",value:"percent"});this.series1=this.map.bubble(i),this.series1.geoIdField("iso_a2").fill("#009CA3 0.3").stroke("1 #009CA3 0.9"),this.series1.legendItem(!1),this.series1.hovered().stroke("1 #009CA3").fill("#009CA3 0.99")}}ngAfterViewInit(){this.map.container(this.container.nativeElement),this.map.draw()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(nt.q))},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-zonas-geograficas"]],viewQuery:function(e,i){if(1&e&&t.Gf(Ot,5),2&e){let s;t.iGM(s=t.CRH())&&(i.container=s.first)}},inputs:{zonasGeograficas:"zonasGeograficas"},features:[t.TTD],decls:5,vars:1,consts:[[1,"container-zonas-geograficas"],[1,"container-zonas-geograficas-mapa"],["containerZonasGeograficas",""],[1,"container-textos-zonas-geograficas"],["class","item",3,"ngClass","mouseover","mouseout",4,"ngFor","ngForOf"],[1,"item",3,"ngClass","mouseover","mouseout"],[1,"paises"],[1,"paises-porcentaje"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0),t._UZ(1,"div",1,2),t.TgZ(3,"div",3),t.YNc(4,Mt,6,8,"div",4),t.qZA()()),2&e&&(t.xp6(4),t.Q6J("ngForOf",i.zonasGeograficas))},directives:[y.sg,y.mk],pipes:[G.d],encapsulation:2}),a})();var Dt=u(4393);const Lt=function(a){return{backgroundColor:a}};function Ft(a,n){if(1&a){const e=t.EpF();t.TgZ(0,"tr",11),t.NdJ("mouseover",function(){const r=t.CHM(e).index;return t.oxw().mouseover(r)})("mouseout",function(){return t.CHM(e),t.oxw().out()}),t.TgZ(1,"td")(2,"div",12),t._UZ(3,"div",13),t.TgZ(4,"div",14),t._uU(5),t.qZA()()(),t.TgZ(6,"td",15),t._uU(7),t.ALo(8,"puntoDecimal"),t.qZA()()}if(2&a){const e=n.$implicit,i=n.index,s=t.oxw();t.Q6J("id","table-"+s.id+"-"+i),t.xp6(3),t.Akn(t.VKq(11,Lt,e.color)),t.Q6J("id","table-{{id}}-cuadrado-"+i),t.xp6(2),t.Oqu(e.descripcion),t.xp6(2),t.hij(" ",t.gM2(8,6,e.peso,!0,2,"%")," ")}}let Pt=(()=>{class a{constructor(e,i,s){this.deviceService=e,this.paletaColoresService=i,this.utilNumbers=s,this.colorSeleccionado=0,this.data=[],this.doughnutChartLabels=[],this.total=0}ngOnInit(){this.isMobile=this.deviceService.isMobile(),this.isTablet=this.deviceService.isTablet(),this.isDesktop=this.deviceService.isDesktop()}crearGrafico(){this.data=[],this.total=0,this.paletaColores=this.paletaColoresService.crearPaletaColores();for(let r=0;r<this.datos.length;r++){this.paletaColores.colores[0].color.length-1===this.colorSeleccionado&&(this.colorSeleccionado=0);const o=this.paletaColores.colores[0].color[this.colorSeleccionado];this.colorSeleccionado++,this.datos[r].color=o,this.total+=this.datos[r].peso,this.doughnutChartL
1abels.push(this.datos[r].descripcion),this.data.push({id:this.datos[r].descripcion,nested:{value:this.datos[r].peso}})}let e={events:["mousemove","mouseout"],enabled:!1,external:this.tooltipEvents};this.isDesktop||(e={events:["touchstart","touchmove"],enabled:!1,external:this.tooltipEventsMobil});const s=document.getElementById("chart-"+this.id);this.doughnutChart=new Dt.kL(s,{type:"doughnut",data:{labels:this.doughnutChartLabels,datasets:[{data:this.data,backgroundColor:this.paletaColores.colores[0].color,hoverBackgroundColor:this.paletaColores.colores[0].color,hoverBorderColor:this.paletaColores.colores[0].color,hoverBorderWidth:3}]},options:{responsive:!0,maintainAspectRatio:!1,cutout:"85%",parsing:{key:"nested.value"},plugins:{legend:{display:!1},tooltip:e}}}),this.doughnutChart.update()}ngOnChanges(e){e.datos&&void 0!==this.datos&&setTimeout(()=>{this.crearGrafico()},0)}triggerHover(e,i){e.setActiveElements([{datasetIndex:0,index:i}]),e.update()}mouseover(e){this.out(),this.isDesktop?this.over(e):setTimeout(()=>{this.over(e)},0)}over(e){const i=this.data[e];let s=document.getElementById("chartjs-tooltip-"+this.id),r="";r+=this.utilNumbers.formatNumberDecimals0(""+i.nested.value,2,"%"),r+="",s.textContent=r,this.triggerHover(this.doughnutChart,e);let o=document.getElementById("table-"+this.id+"-cuadrado-"+e);o&&o.setAttribute("class","cuadrado-seleccionado"),document.getElementById("table-"+this.id+"-"+e).setAttribute("class","pie-seleccionad
1a")}out(){document.getElementById("chartjs-tooltip-"+this.id).textContent="",this.doughnutChart.setActiveElements([]),this.doughnutChart.update(),this.clearTabla()}clearTabla(){let e=document.getElementById("table-"+this.id);for(var s,i=0;s=e.rows[i];i++){s.setAttribute("class","");let r=document.getElementById("table-"+this.id+"-cuadrado-"+i);r&&r.setAttribute("class","cuadrado")}}tooltipEventsMobil(e){let s=document.getElementById("chartjs-tooltip-"+e.chart.canvas.id);const r=e.tooltip;let o=document.getElementById("table-"+this.id);for(var c,l=0;c=o.rows[l];l++){c.setAttribute("class","");let d=document.getElementById("table-"+this.id+"-cuadrado-"+l);d&&d.setAttribute("class","cuadrado")}s.style.color="#000826",s.textContent="",s.style.opacity="0",setTimeout(()=>{if(s.classList.remove("above","below","no-transform"),s.classList.add(r.yAlign?r.yAlign:"no-transform"),r.body){const m=r.body.map(function d(h){return h.lines});let f="";m.forEach((v,g)=>{if(v[g]){let S=v[g].split(":");const T=S[0],A=e.chart.data.datasets[0].data.findIndex(U=>U.id===T);document.getElementById("table-"+this.id+"-"+A).setAttribute("class","pie-seleccionad
1a");let J=document.getElementById("table-"+this.id+"-cuadrado-"+A);J&&J.setAttribute("class","cuadrado-seleccionado");let O=S[1].trim();O=O.replace(/,|_/g,".");const F=2,x="%";let D,M,I;const L=Number(O);void 0!==F&&(O=L.toFixed(F)),O=""+Number(O);const R=O.indexOf(".");if(-1===R)I=",00",M=O;else if(M=O.substr(0,R),I=O.substr(R),void 0!==F&&I.length<F+1)for(let U=I.length;U<F+1;U++)I+="0";let Q=!1;Number(M)<0&&(Q=!0,M=M.replace("-",""));const w=M.length%3,z=M.substr(w).match(/\d{3}/g);let P=M.substr(0,w);z&&(P+=(w?".":"")+z.join(".")),Q&&(P="-"+P),D=void 0!==x?P+""+I.replace(".",",")+x:P+""+I.replace(".",","),f+=D}}),f+="",s.textContent=f}s.style.opacity="1",s.style.color="#000826"},500)}tooltipEvents(e){const i=e.chart.canvas.id.substring(6);let s=document.getElementById("chartjs-tooltip-"+i);const r=e.tooltip;if(e.chart._lastEvent="mousemove",s.classList.remove("above","below","no-transform"),s.classList.add(r.yAlign?r.yAlign:"no-transform"),r.body){const d=r.body.map(function o(c){return c.lines});let h="";d.forEach((m,f)=>{if(m[f]){let S=m[f].split(":");const T=S[0],A=e.chart.data.datasets[0].data.findIndex(j=>j.id===T),V=""+A;let J=document.getElementById("table-"+i);for(var g,v=0;g=J.rows[v];v++){g.setAttribute("class","");let j=document.getElementById("table-"+i+"-cuadrado-"+v);j&&j.setAttribute("class","cuadrado")}if(s.style.opacity===V)return s.style.color="#000826",s.textContent="",void(s.style.opacity="");s.style.opacity=""+A,document.getElementById("table-"+i+"-"+A).setAttribute("class","pie-seleccionad
1a");let F=document.getElementById("table-"+i+"-cuadrado-"+A);F&&F.setAttribute("class","cuadrado-seleccionado");let x=S[1].trim();x=x.replace(/,|_/g,".");const D=2,M="%";let I,L,R;const Q=Number(x);void 0!==D&&(x=Q.toFixed(D)),x=""+Number(x);const w=x.indexOf(".");if(-1===w)R=",00",L=x;else if(L=x.substr(0,w),R=x.substr(w),void 0!==D&&R.length<D+1)for(let j=R.length;j<D+1;j++)R+="0";let z=!1;Number(L)<0&&(z=!0,L=L.replace("-",""));const P=L.length%3,X=L.substr(P).match(/\d{3}/g);let U=L.substr(0,P);X&&(U+=(P?".":"")+X.join(".")),z&&(U="-"+U),I=void 0!==M?U+""+R.replace(".",",")+M:U+""+R.replace(".",","),h+=I}}),h+="",s.textContent=h}e.chart.canvas.getBoundingClientRect(),s.style.color="#000826",s.style.pointerEvents="none"}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(ot.x0),t.Y36(st.g),t.Y36(nt.q))},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-pie"]],inputs:{datos:"datos",id:"id"},features:[t.TTD],decls:19,vars:15,consts:[[1,"container-pie"],[1,"container-chart-pie"],["baseChart","",1,"chart-pie",3,"id"],[1,"chartjs-tooltip","chartjs-tooltip-text",3,"id"],[1,"chart-pie-separator"],[1,"chart-pie-data"],[1,"chart-pie-data-table",3,"id"],[3,"id","mouseover","mouseout",4,"ngFor","ngForOf"],[1,"chart-pie-data-footer"],[1,"column-total"],[1,"d-flex","justify-content-end","tfoot-pie-porcentaje"],[3,"id","mouseover","mouseout"],[1,"column-descripcion"],[1,"cuadrado",3,"id"],[1,"column-descripcion-texto"],[1,"column-value"]],template:function(e,i){1&e&&(t.TgZ(0,"div",0)(1,"div",1),t._UZ(2,"canvas",2)(3,"div",3),t.qZA(),t._UZ(4,"div",4),t.TgZ(5,"div",5)(6,"table",6),t.YNc(7,Ft,9,13,"tr",7),t.qZA(),t.TgZ(8,"table")(9,"tfoot"),t._UZ(10,"tr",8),t.TgZ(11,"tr")(12,"td",9),t._uU(13),t.ALo(14,"uppercase"),t.ALo(15,"translate"),t.qZA(),t.TgZ(16,"td",10),t._uU(17),t.ALo(18,"puntoDecimal"),t.qZA()()()()()()),2&e&&(t.xp6(2),t.MGl("id","chart-",i.id,""),t.xp6(1),t.MGl("id","chartjs-tooltip-",i.id,""),t.xp6(3),t.MGl("id","table-",i.id,""),t.xp6(1),t.Q6J("ngForOf",i.datos),t.xp6(6),t.Oqu(t.lcZ(14,6,t.lcZ(15,8,"carteras.details.distribucion.total"))),t.xp6(4),t.hij(" ",t.gM2(18,10,i.total,!0,2,"%"),""))},directives:[y.sg],pipes:[G.d,y.gd,N.X$],encapsulation:2}),a})();function Nt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",2)(5,"app-asset-class",3),t.qZA()),2&a){const e=t.oxw();
1t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.distribucion.asset-class.title")," "),t.xp6(3),t.Q6J("tipos",e.tipos)}}function Vt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",2)(5,"app-zonas-geograficas",4),t.qZA()),2&a){const e=t.oxw();t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.distribucion.zonas-geograficas.title")," "),t.xp6(3),t.Q6J("zonasGeograficas",e.zonasGeograficas)}}function jt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",2)(5,"app-pie",5),t.qZA()),2&a){const e=t.oxw();t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.distribucion.sectores-renta-variable.title")," "),t.xp6(3),t.Q6J("datos",e.chartSectores)}}function qt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",2)(5,"app-pie",6),t.qZA()),2&a){const e=t.oxw();t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.distribucion.calidad-crediticia-renta-fija.title")," "),t.xp6(3),t.Q6J("datos",e.chartRating)}}function wt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"hr",2)(5,"app-pie",7),t.qZA()),2&a){const e=t.oxw();
1t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.distribucion.divisas.title")," "),t.xp6(3),t.Q6J("datos",e.chartDivisas)}}function Gt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"div",1)(2,"h4"),t._uU(3),t.ALo(4,"translate"),t.qZA(),t._UZ(5,"hr",2)(6,"app-pie",8),t.qZA()()),2&a){const e=t.oxw();t.xp6(3),t.hij(" ",t.lcZ(4,2,"carteras.details.distribucion.categorias.title")," "),t.xp6(3),t.Q6J("datos",e.chartCategorias)}}function kt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"div",1)(2,"h4"),t._uU(3),t.ALo(4,"translate"),t.qZA(),t._UZ(5,"hr",2)(6,"app-pie",9),t.qZA()()),2&a){const e=t.oxw();t.xp6(3),t.hij(" ",t.lcZ(4,2,"carteras.details.distribucion.gestoras.title")," "),t.xp6(3),t.Q6J("datos",e.chartGestoras)}}function Jt(a,n){if(1&a&&(t.TgZ(0,"div",1)(1,"div",1)(2,"h4"),t._uU(3),t.ALo(4,"translate"),t.qZA(),t._UZ(5,"hr",2)(6,"app-pie",10),t.qZA()()),2&a){const e=t.oxw();t.xp6(3),t.hij(" ",t.lcZ(4,2,"carteras.details.distribucion.top-posiciones.title")," "),t.xp6(3),t.Q6J("datos",e.chartTopPosiciones)}}let zt=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275cmp=t.Xpm({type:a,selectors:[["app-distribucion"]],inputs:{tipos:"tipos",zonasGeograficas:"zonasGeograficas",chartSectores:"chartSectores",chartRating:"chartRating",chartDivisas:"chartDivisas",chartGestoras:"chartGestoras",chartCategorias:"chartCategorias",chartTopPosiciones:"chartTopPosiciones",isClaseActivo:"isClaseActivo",isZonasGeograficas:"isZonasGeograficas"},decls:8,vars:8,consts:[["class","container-composition",4,"ngIf"],[1,"container-composition"],[1,"gvc-separator"],[3,"tipos"],[3,"zonasGeograficas"],["id","sectores-renta-variable",3,"datos"],["id","calidad-crediticia-renta-fija",3,"datos"],["id","divisas",3,"datos"],["id","categorias",3,"datos"],["id","gestoras",3,"datos"],["id","top-posiciones",3,"datos"]],template:function(e,i){1&e&&(t.YNc(0,Nt,6,4,"div",0),t.YNc(1,Vt,6,4,"div",0),t.YNc(2,jt,6,4,"div",0),t.YNc(3,qt,6,4,"div",0),t.YNc(4,wt,6,4,"div",0),t.YNc(5,Gt,7,4,"div",0),t.YNc(6,kt,7,4,"div",0),t.YNc(7,Jt,7,4,"div",0)),2&e&&(t.Q6J("ngIf",i.isClaseActivo),t.xp6(1),t.Q6J("ngIf",i.isZonasGeograficas),t.xp6(1),t.Q6J("ngIf",(null==i.chartSectores?null:i.chartSectores.length)>0),t.xp6(1),t.Q6J("ngIf",(null==i.chartRating?null:i.chartRating.length)>0),t.xp6(1),t.Q6J("ngIf",(null==i.chartDivisas?null:i.chartDivisas.length)>0),t.xp6(1),t.Q6J("ngIf",(null==i.chartCategorias?null:i.chartCategorias.length)>0),t.xp6(1),t.Q6J("ngIf",(null==i.chartGestoras?null:i.chartGestoras.length)>0),t.xp6(1),t.Q6J("ngIf",(null==i.chartTopPosiciones?null:i.chartTopPosiciones.length)>0))},directives:[y.O5,Et,Ut,Pt],pipes:[N.X$],encapsulation:2}),a})();function Ht(a,n){if(1&a&&(t.TgZ(0,"div",40)(1,"span",41),t._uU(2,"add"),t.qZA(),t._uU(3),t.ALo(4,"puntoDecimal"),t.TgZ(5,"span",42),t._uU(6,"north"),t.qZA()()),2&a){const e=t.oxw();t.Tol(e.paletaColoresService.cssPosNeg_number(null==e.informacion?null:e.informacion.anualRetorno)),t.xp6(3),t.hij(" ",t.Dn7(4,3,null==e.informacion?null:e.informacion.anualRetorno,!0,2)," ")}}function Yt(a,n){if(1&a&&(t.TgZ(0,"div",40)(1,"span",41),t._uU(2,"remove"),t.qZA(),t._uU(3),t.ALo(4,"puntoDecimal"),t.TgZ(5,"span",42),t._uU(6,"south"),t.qZA()()),2&a){const e=t.oxw();t.Tol(e.paletaColoresService.cssPosNeg_number(null==e.informacion?null:e.informacion.anualRetorno)),t.xp6(3),t.hij(" ",t.Dn7(4,3,-(null==e.informacion?null:e.informacion.anualRetorno),!0,2)," ")}}function Bt(a,n){if(1&a){const e=t.EpF();t.TgZ(0,"div",43)(1,"div",44)(2,"button",45),t.NdJ("click",function(){return t.CHM(e),t.oxw().volver()}),t._UZ(3,"span",46),t._uU(4),t.ALo(5,"translate"),t.qZA()(),t.TgZ(6,"div",47)(7,"button",48),t.NdJ("click",function(){return t.CHM(e),t.oxw().abrirCaptcha()}),t._uU(8),t.ALo(9,"uppercase"),t.ALo(10,"translate"),t.qZA(),t.TgZ(11,"a",49),t._uU(12),t.ALo(13,"uppercase"),t.ALo(14,"translate"),t.qZA()()()}2&a&&(t.xp6(4),t.hij(" ",t.lcZ(5,3,"common.back")," "),t.xp6(4),t.hij(" ",t.lcZ(9,5,t.lcZ(10,7,"carteras.details.newclient"))," "),t.xp6(4),t.hij(" ",t.lcZ(13,9,t.lcZ(14,11,"carteras.details.likeit"))," "))}function Qt(a,n){if(1&a){const e=t.EpF();t.TgZ(0,"div",23)(1,"div",50)(2,"button",51),t.NdJ("click",function(s){return t.CHM(e),t.oxw().verInformeIntranet(s)}),t.ALo(3,"uppercase"),t.ALo(4,"translate"),t.qZA(),t._UZ(5,"p-confirmPopup"),t.qZA()()}2&a&&(t.xp6(2),t.s9C("label",t.lcZ(3,1,t.lcZ(4,3,"carteras.details.informe"))))}function Kt(a,n){if(1&a&&(t.TgZ(0,"div",52)(1,"h4"),t._uU(2),t.ALo(3,"translate"),t.qZA(),t._UZ(4,"app-analisis",53),t.qZA()),2&a){const e=t.oxw();
1t.xp6(2),t.hij(" ",t.lcZ(3,2,"carteras.details.analisis.title")," "),t.xp6(2),t.Q6J("analisis",e.analisisCarteras)}}const $t=[{path:"",children:[{path:"details/:isin",component:(()=>{class a{constructor(e,i,s,r,o,l,c,d,h,m,f,v,g){this._location=e,this.dataStorage=i,this.carterasService=s,this.utilsButtonService=r,this.bsModalService=o,this.utilsService=l,this.i18=c,this.confirmationService=d,this.ngxService=h,this.router=m,this.route=f,this.localeService=v,this.paletaColoresService=g,this.isDistribucion=!0,this.isClaseActivo=!0,this.isZonasGeograficas=!0,this.mensajeGenerandoInforme="",this.mensajeCaptcha=""}ngOnInit(){this.id=this.router.routerState.snapshot.root.queryParams.id,this.idioma=this.router.routerState.snapshot.root.queryParams.idioma,this.urlIdFormHubspot="CA"===this.idioma?Z.J.URL_HUBSPOT_CARTERA_FORM_CA_ID:Z.J.URL_HUBSPOT_CARTERA_FORM_ES_ID,this.localeService.switchLang(this.localeService.getLanguageType(this.idioma.toUpperCase())),this.route.paramMap.subscribe(e=>{this.isin=""+e.get("isin")}),this.subscriptionUrlRestServer=this.dataStorage.getUrlRestServers().subscribe(e=>{e&&this.carterasService.recuperarDatos(this.isin,"5Y",this.idioma,10)}),this.datosSuscription=this.carterasService.datos$.subscribe(e=>{this.informacion=e[0],this.rentabilidades=e[1],this.rentabilidadesMensual=e[2],this.rentabilidadesAcumuladas=e[3],this.rentabilidadesAnuales=e[4],this.tipos=this.ordenarTipos(e[5]),this.zonasGeograficas=e[6],this.chartCategorias=e[7],this.chartGestoras=e[8],this.chartSectores=e[9],this.chartRating=e[10],this.chartDivisas=e[11],this.chartTopPosiciones=e[12],this.analisisCarteras=e[13],this.isZonasGeograficas=this.existZonasGeograficas(),this.isClaseActivo=this.existClaseActivo(),!this.isZonasGeograficas&&!this.isClaseActivo&&0===this.chartCategorias.length&&0===this.chartGestoras.length&&(this.isDistribucion=!1)}),this.getInfoEnvironments(),this.submited$=this.utilsButtonService.submitedButtonChanged}scrollToElement(e){let i=document.getElementById(e);i&&window.scroll({top:i.offsetTop-200,behavior:"smooth"})}existClaseActivo(){let e=!1;for(let i=0;i<this.tipos.length;i++)if(this.tipos[i].valor>0){e=!0;break}return e}existZonasGeograficas(){let e=!1;for(let i=0;i<this.zonasGeograficas.length;i++)if(this.zonasGeograficas[i].valor>0){e=!0;break}return e}ordenarTipos(e){let s=new Array;return e&&e.length>0&&["equity","fixed_income","cash","other"].forEach(r=>{let o=e.find(l=>l.id===r);o&&s.push(o)}),s}onAddCartera(){this.carterasService.addCartera(this.id,"FONDO","NOMERC",this.isin,this.idioma)}abrirCaptcha(){this.checkCaptcha=new tt.X(!1);const i=this.bsModalService.show(dt,{class:"",mensaje:this.mensajeCaptcha,isValid:this.checkCaptcha});i.content.bsModalRef=i,this.subscriptionCaptcha=this.checkCaptcha.subscribe(s=>{s&&this.abrirModalInforme()})}abrirModalInforme(){let e;this.ngxService.start(),(0,K.D)([this.dataStorage.getHubspotFormId(this.urlIdFormHubspot),this.carterasService.generarPdf(this.isin,this.idioma,null)]).subscribe(i=>{if(this.idFormHubspot=i[0],e=i[1],null==e||null==e)return void this.ngxService.stop();const r=this.bsModalService.show(ht,{class:"modal_help",idioma:this.idioma,id:this.id,idPdf:e,nombreInforme:this.informacion.titulo,idFormularioHubspot:this.idFormHubspot});r.content.bsModalRefAyudaFormulario=r})}getInfoEnvironments(){let e=Z.J.URL_MENSAJE_CAPTCHA_ES;"CA"===this.idioma.toUpperCase()?e=Z.J.URL_MENSAJE_CAPTCHA_CA:"EN"===this.idioma.toUpperCase()&&(e=Z.J.URL_MENSAJE_CAPTCHA_EN);let i=Z.J.URL_HUBSPOT_INFORME_CARGANDO_ES;"CA"===this.idioma.toUpperCase()?i=Z.J.URL_HUBSPOT_INFORME_CARGANDO_CA:"EN"===this.idioma.toUpperCase()&&(i=Z.J.URL_HUBSPOT_INFORME_CARGANDO_EN),(0,K.D)([this.dataStorage.getInfoEnvironment(e),this.dataStorage.getInfoEnvironment(i),this.dataStorage.getInfoEnvironment(Z.J.URL_DESPLIEGUES_PERMITIDOS_WEALTH),this.dataStorage.getInfoEnvironment(Z.J.URL_DESPLIEGUES_PERMITIDOS_CANAL),this.dataStorage.getInfoEnvironment(Z.J.URL_DESPLIEGUES_PERMITIDOS_INTRANET)]).subscribe(s=>{this.mensajeCaptcha=s[0],this.mensajeGenerandoInforme=s[1],this.dataStorage.urls_permitidas_wealth=s[2],this.dataStorage.urls_permitidas_canal=s[3],this.dataStorage.urls_permitidas_intranet=s[4]})}get isIntranet(){return this.utilsService.isIntranet()}get isCanalOnline(){return this.utilsService.isCanalOnline()}get isWealth(){return this.utilsService.isWealth()}verInformeIntranet(e){e.stopPropagation(),this.confirmationService.confirm({target:e.target,message:this.i18.getValue("common.mensaje-descarga"),icon:"pi pi-info-circle",rejectButtonStyleClass:"p-button-outlined p-button-secondary",acceptButtonStyleClass:"gvc-gaesco-button-accept",acceptLabel:this.i18.getValue("common.continuar"),rejectLabel:this.i18.getValue("common.cancelar"),accept:()=>{window.open(`${this.dataStorage.url_Server_Rest}${B.SERVICIO_VER_PDF_INTRANET}?token=${this.router.routerState.snapshot.root.queryParams.token}`,"_blank")}})}volver(){this._location.back()}ngOnDestroy(){void 0!==this.subscriptionUrlRestServer&&this.subscriptionUrlRestServer.unsubscribe(),void 0!==this.datosSuscription&&this.datosSuscription.unsubscribe(),void 0!==this.subscriptionCaptcha&&this.subscriptionCaptcha.unsubscribe()}}return a.\u0275fac=function(e){return new(e||a)(t.Y36(y.Ye),t.Y36(Z.J),t.Y36(B),t.Y36(at.N),t.Y36(H.tT),t.Y36(mt.F),t.Y36(k.o),t.Y36(it.YP),t.Y36($.LA),t.Y36(Y.F0),t.Y36(Y.gz),t.Y36(pt.O),t.Y36(st.g))}
1,a.\u0275cmp=t.Xpm({type:a,selectors:[["app-carteras-details"]],decls:89,vars:78,consts:[["position","top-center"],[1,"fichas-wealth"],[1,"container-ficha-head"],[1,"container-ficha-header-body","row-flex-column"],[1,"row-flex-column"],[1,"container-ficha-item-top"],[1,"title"],[1,"container-ficha-item-bottom"],[1,"container-ficha-item-info"],[1,"descripcion"],[1,"container-ficha-item-data"],[1,"item-data"],[1,"item"],[1,"rentabilidad-year-title"],["matTooltipPosition","above","matTooltipClass","gvc-tooltip",1,"gvc-icon-info",3,"matTooltip","click"],["rentabilidad_year","matTooltip"],["class","rentabilidad-year-value",3,"class",4,"ngIf"],[1,"volatilidad-year-title"],["volatilidad","matTooltip"],[1,"volatilidad-year-value"],[1,"riesgo-title"],[1,"riesgo-value"],[1,"container-ficha-flotante"],[1,"fondo-blanco"],[1,"container-ficha-flotante-body"],["class","container-ficha-acciones fondo-blanco row-flex-row",4,"ngIf"],["class","fondo-blanco",4,"ngIf"],[1,"gvc-tab-group"],[1,"gvc-tab-button","gvc-button","anchor",3,"click"],[1,"container-ficha-body"],["id","evolution",1,"container-ficha-overview"],[3,"idioma","informacion","rentabilidades"],["id","performance",1,"container-ficha-rentabilidades"],[3,"idioma","informacion","rentabilidadesMensual","rentabilidadesAnuales","rentabilidadesAcumuladas"],["class","container-ficha-analisis","id","analisis",4,"ngIf"],["id","distribucion",1,"container-ficha-composicion"],[3,"tipos","zonasGeograficas","chartSectores","chartRating","chartDivisas","chartCategorias","chartGestoras","chartTopPosiciones","isClaseActivo","isZonasGeograficas"],[1,"container-ficha-pie"],[1,"container-pie"],["overlayColor","rgba(255, 255, 255, 0.9)","blur","0",3,"text"],[1,"rentabilidad-year-value"],[1,"material-icons","gvc-fz-16"],[1,"material-icons-outlined","gvc-fz-16"],[1,"container-ficha-acciones","fondo-blanco","row-flex-row"],[1,"grupo-volver"],[1,"gvc-button","link",3,"click"],[1,"fas","fa-chevron-left"],[1,"grupo-acciones"],[1,"gvc-button","gvc-button-fichas","outline-1",3,"click"],["href","https://onboarding.gvcgaesco.es/",1,"gvc-button","gvc-button-fichas","add-cartera","primary"],[1,"grupo-informe"],["pButton","","pRipple","","type","button",1,"gvc-button","outline-1",3,"label","click"],["id","analisis",1,"container-ficha-analisis"],[3,"analisis"]],template:function(e,i){if(1&e){const s=t.EpF();t._UZ(0,"p-toast",0)(1,"p-toast",0),t.TgZ(2,"div",1)(3,"div",2)(4,"div",3)(5,"div",4)(6,"div",5)(7,"h1",6),t._uU(8),t.qZA()(),t.TgZ(9,"div",7)(10,"div",8)(11,"p",9),t._uU(12),t.qZA()(),t.TgZ(13,"div",10)(14,"div",11)(15,"div",12)(16,"div",13),t._uU(17),t.ALo(18,"translate"),t.TgZ(19,"span",14,15),t.NdJ("click",function(){return t.CHM(s),t.MAs(20).toggle()}),t.ALo(21,"translate"),t._uU(22," info "),t.qZA()(),t.YNc(23,Ht,7,7,"div",16),t.YNc(24,Yt,7,7,"div",16),t.qZA(),t.TgZ(25,"div",12)(26,"div",17),t._uU(27),t.ALo(28,"translate"),t.TgZ(29,"span",14,18),t.NdJ("click",function(){return t.CHM(s),t.MAs(30).toggle()}),t.ALo(31,"translate"),t._uU(32," info "),t.qZA()(),t.TgZ(33,"div",19),t._uU(34),t.ALo(35,"puntoDecimal"),t.qZA()(),t.TgZ(36,"div",12)(37,"div",20),t._uU(38),t.ALo(39,"translate"),t.qZA(),t.TgZ(40,"div",21),t._uU(41),t.qZA()()()()()()()(),t.TgZ(42,"div",22)(43,"div",23)(44,"div",24),t.YNc(45,Bt,15,13,"div",25),t.YNc(46,Qt,6,5,"div",26),t.TgZ(47,"div",27)(48,"span",28),t.NdJ("click",function(){return i.scrollToElement("evolution")}),t._uU(49),t.ALo(50,"translate"),t.qZA(),t.TgZ(51,"span",28),t.NdJ("click",function(){return i.scrollToElement("performance")}),t._uU(52),t.ALo(53,"translate"),t.qZA(),t.TgZ(54,"span",28),t.NdJ("click",function(){return i.scrollToElement("analisis")}),t._uU(55),t.ALo(56,"translate"),t.qZA(),t.TgZ(57,"span",28),t.NdJ("click",function(){return i.scrollToElement("distribucion")}),t._uU(58),t.ALo(59,"translate"),t.qZA()()()()(),t.TgZ(60,"div",29)(61,"div",30)(62,"h4"),t._uU(63),t.ALo(64,"translate"),t.qZA(),t._UZ(65,"app-evolution",31),t.qZA(),t.TgZ(66,"div",32)(67,"h4"),t._uU(68),t.ALo(69,"translate"),t.qZA(),t._UZ(70,"app-rentabilidades",33),t.qZA(),t.YNc(71,Kt,5,4,"div",34),t.TgZ(72,"div",35)(73,"h4"),t._uU(74),t.ALo(75,"translate"),t.qZA(),t._UZ(76,"app-distribucion",36),t.qZA()(),t.TgZ(77,"div",37)(78,"div",38)(79,"p")(80,"strong"),t._uU(81),t.ALo(82,"translate"),t.qZA(),t._uU(83),t.ALo(84,"translate"),t.qZA(),t.TgZ(85,"p"),t._uU(86),t.ALo(87,"translate"),t.qZA()()()(),t._UZ(88,"ngx-ui-loader",39)}2&e&&(t.xp6(8),t.hij(" ",null==i.informacion?null:i.informacion.titulo," "),t.xp6(4),t.hij(" ",null==i.informacion?null:i.informacion.descripcion," "),t.xp6(5),t.hij(" ",t.lcZ(18,43,"ficha-carteras.anualized-return")," "),t.xp6(2),t.MGl("matTooltip"," ",t.lcZ(21,45,"ficha-carteras.tooltips.anualized-return"),""),t.xp6(4),t.Q6J("ngIf",(null==i.informacion?null:i.informacion.anualRetorno)>0),t.xp6(1),t.Q6J("ngIf",(null==i.informacion?null:i.informacion.anualRetorno)<0),t.xp6(3),t.hij(" ",t.lcZ(28,47,"ficha-carteras.anualized-votality")," "),t.xp6(2),t.MGl("matTooltip"," ",t.lcZ(31,49,"ficha-carteras.tooltips.anualized-votality"),""),t.xp6(5),t.hij(" ",t.gM2(35,51,null==i.informacion?null:i.informacion.anualVolatilidad,!0,2,"%")," "),t.xp6(4),t.hij(" ",t.lcZ(39,56,"ficha-carteras.risk-level")," "),t.xp6(3),t.hij(" ",null==i.informacion?null:i.informacion.riesgo," "),t.xp6(4),t.Q6J("ngIf",i.isWealth),t.xp6(1),t.Q6J("ngIf",i.isIntranet),t.xp6(3),t.hij(" ",t.lcZ(50,58,"carteras.details.evolution.title")," "),t.xp6(3),t.hij(" ",t.lcZ(53,60,"carteras.details.performance.title")," "),t.xp6(3),t.hij(" ",t.lcZ(56,62,"carteras.details.analisis.title-ancla")," "),t.xp6(3),t.hij(" ",t.lcZ(59,64,"carteras.details.distribucion.title")," "),t.xp6(5),t.hij(" ",t.lcZ(64,66,"carteras.details.evolution.title")," "),t.xp6(2),t.Q6J("idioma",i.idioma)("informacion",i.informacion)("rentabilidades",i.rentabilidades),t.xp6(3),t.hij(" ",t.lcZ(69,68,"carteras.details.performance.title")," "),t.xp6(2),t.Q6J("idioma",i.idioma)("informacion",i.informacion)("rentabilidadesMensual",i.rentabilidadesMensual)("rentabilidadesAnuales",i.rentabilidadesAnuales)("rentabilidadesAcumuladas",i.rentabilidadesAcumuladas),t.xp6(1),t.Q6J("ngIf",null!=i.analisisCarteras),t.xp6(3),t.hij(" ",t.lcZ(75,70,"carteras.details.distribucion.title")," "),t.xp6(2),t.Q6J("tipos",i.tipos)("zonasGeograficas",i.zonasGeograficas)("chartSectores",i.chartSectores)("chartRating",i.chartRating)("chartDivisas",i.chartDivisas)("chartCategorias",i.chartCategorias)("chartGestoras",i.chartGestoras)("chartTopPosiciones",i.chartTopPosiciones)("isClaseActivo",i.isClaseActivo)("isZonasGeograficas",i.isZonasGeograficas),t.xp6(5),t.Oqu(t.lcZ(82,72,"disclaimer.disclaimer-entrada")),t.xp6(2),t.hij(" ",t.lcZ(84,74,"disclaimer.disclaimer-parrafo-01"),""),t.xp6(3),t.Oqu(t.lcZ(87,76,"disclaimer.disclaimer-parrafo-02")),t.xp6(2),t.s9C("text",i.mensajeGenerandoInforme))},directives:[ft.FN,rt.gM,y.O5,gt.Hq,vt.P,Ct,yt,xt,zt,$.Eo],pipes:[N.X$,G.d,y.gd],encapsulation:2}),a})()}]}];let Xt=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275mod=t.oAB({type:a}),a.\u0275inj=t.cJS({imports:[[Y.Bz.forChild($t)],Y.Bz]}),a})(),Wt=(()=>{class a{}return a.\u0275fac=function(e){return new(e||a)},a.\u0275mod=t.oAB({type:a}),a.\u0275inj=t.cJS({imports:[[lt.m,Xt,H.zk]]}),a})()}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.