-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path6-es5.a52101246a5c0f70976d.js
1 lines (1 loc) · 62.7 KB
/
6-es5.a52101246a5c0f70976d.js
1
function _classCallCheck(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _defineProperties(e,t){for(var a=0;a<t.length;a++){var n=t[a];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function _createClass(e,t,a){return t&&_defineProperties(e.prototype,t),a&&_defineProperties(e,a),e}(window.webpackJsonp=window.webpackJsonp||[]).push([[6],{"2l0t":function(e,t,a){"use strict";a.r(t);var n=a("ofXK"),i=a("tyNb"),r=a("fXoL"),o=a("XiUz"),c=a("wZkO");function l(e,t){if(1&e&&(r.Sb(0,"a",6,7),r.Bc(2),r.Rb()),2&e){var a=t.$implicit,n=r.oc(1);r.jc("routerLink",a.link)("active",n.isActive),r.Bb(2),r.Dc(" ",a.label," ")}}var s,d=((s=function(){function e(){_classCallCheck(this,e),this.navLinks=[{label:"Graphique",link:"graphique",index:0},{label:"Carte",link:"carte",index:1}]}return _createClass(e,[{key:"ngOnInit",value:function(){}}]),e}()).\u0275fac=function(e){return new(e||s)},s.\u0275cmp=r.Hb({type:s,selectors:[["app-france"]],decls:7,vars:1,consts:[["fxFill","",1,"noScroll"],["fxFlex","","fxLayout","column"],["fxFlex","50px"],["mat-tab-nav-bar",""],["mat-tab-link","","routerLinkActive","",3,"routerLink","active",4,"ngFor","ngForOf"],["fxFlex","",1,"noScroll"],["mat-tab-link","","routerLinkActive","",3,"routerLink","active"],["rla","routerLinkActive"]],template:function(e,t){1&e&&(r.Sb(0,"div",0),r.Sb(1,"div",1),r.Sb(2,"div",2),r.Sb(3,"nav",3),r.Ac(4,l,3,3,"a",4),r.Rb(),r.Rb(),r.Sb(5,"div",5),r.Ob(6,"router-outlet"),r.Rb(),r.Rb(),r.Rb()),2&e&&(r.Bb(4),r.jc("ngForOf",t.navLinks))},directives:[o.f,o.b,o.d,c.b,n.j,i.f,i.d,c.a,i.c],styles:[".mat-tab-label[_ngcontent-%COMP%], .mat-tab-link[_ngcontent-%COMP%], .mat-tab-links[_ngcontent-%COMP%]{height:50px}.mat-tab-label-active[_ngcontent-%COMP%]{font-weight:700}.scrollable[_ngcontent-%COMP%]{overflow:auto}.noScroll[_ngcontent-%COMP%]{overflow:hidden;flex-wrap:nowrap}"]}),s),u=a("4R65"),p=function(e){return e.REGION="REGION",e.DEPARTEMENT="DEPARTEMENT",e.PAYS="PAYS",e.MONDE="MONDE",e.DOMTOM="DOMTOM",e}({}),b=a("9KmE"),f=a("PPqH"),y=a("WYmB"),g=a("tk/3"),h=a("/qmH"),C=a("bTqV"),T=a("OwhE"),m=a("f0Cb"),v=a("QibW"),D=a("3Pt+"),R=a("kmnG"),S=a("d3UM"),E=a("qFsG"),L=a("iadO"),x=a("FKr1"),M=a("NFeN"),B=a("znSr");function A(e,t){if(1&e&&(r.Sb(0,"mat-radio-button",44),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a," ")}}function I(e,t){if(1&e&&(r.Sb(0,"mat-option",44),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a," ")}}function P(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",33),r.Sb(1,"div",34),r.Sb(2,"h1"),r.Bc(3," Param\xe8tres "),r.Rb(),r.Rb(),r.Sb(4,"div",27),r.Sb(5,"div",34),r.Sb(6,"h3"),r.Bc(7," Granularit\xe9 Carte "),r.Rb(),r.Rb(),r.Sb(8,"div",35),r.Sb(9,"mat-radio-group",36),r.ac("ngModelChange",(function(e){return r.rc(a),r.ec().selectedGranularityMap=e}))("change",(function(){return r.rc(a),r.ec().changeGranularity()})),r.Sb(10,"div",37),r.Ac(11,A,2,2,"mat-radio-button",38),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Ob(12,"mat-divider"),r.Sb(13,"div",27),r.Sb(14,"div",34),r.Sb(15,"h3"),r.Bc(16," Type de donn\xe9es "),r.Rb(),r.Rb(),r.Sb(17,"div",35),r.Sb(18,"mat-form-field"),r.Sb(19,"mat-select",39),r.ac("selectionChange",(function(){return r.rc(a),r.ec().updateStyleMap()}))("valueChange",(function(e){return r.rc(a),r.ec().selectedTypeGraph=e})),r.Ac(20,I,2,2,"mat-option",38),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Sb(21,"div",27),r.Sb(22,"div",34),r.Sb(23,"h3"),r.Bc(24," Choix Date "),r.Rb(),r.Rb(),r.Sb(25,"div",35),r.Sb(26,"mat-form-field",40),r.Sb(27,"input",41),r.ac("dateChange",(function(e){return r.rc(a),r.ec().dateChanged(e.value)})),r.Rb(),r.Ob(28,"mat-datepicker-toggle",42),r.Ob(29,"mat-datepicker",null,43),r.Rb(),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.oc(30),i=r.ec();r.Bb(9),r.jc("ngModel",i.selectedGranularityMap),r.Bb(2),r.jc("ngForOf",i.listAllGranularityMap),r.Bb(8),r.jc("value",i.selectedTypeGraph),r.Bb(1),r.jc("ngForOf",i.listTypeGraph),r.Bb(7),r.jc("value",i.selectedDate)("min",i.minDate)("max",i.maxDate)("matDatepicker",n),r.Bb(1),r.jc("for",n)}}function G(e,t){1&e&&(r.Sb(0,"mat-icon"),r.Bc(1," keyboard_arrow_left "),r.Rb())}function w(e,t){1&e&&(r.Sb(0,"mat-icon"),r.Bc(1," keyboard_arrow_right "),r.Rb())}function O(e,t){if(1&e&&r.Ob(0,"div",45),2&e){var a=r.ec();r.jc("leafletLayer",a.franceLayer)}}function k(e,t){if(1&e&&r.Ob(0,"div",45),2&e){var a=r.ec();r.jc("leafletLayer",a.regionLayer)}}function j(e,t){if(1&e&&r.Ob(0,"div",45),2&e){var a=r.ec();r.jc("leafletLayer",a.departementLayer)}}function F(e,t){if(1&e&&(r.Sb(0,"h1",46),r.Bc(1),r.Rb()),2&e){var a=r.ec();r.Bb(1),r.Dc(" ",a.onHoverLegendInfos," ")}}function H(e,t){if(1&e&&(r.Sb(0,"h2",21),r.Bc(1),r.Rb()),2&e){var a=r.ec(2);r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValue," Cas ")}}function V(e,t){if(1&e&&(r.Sb(0,"div",49),r.Sb(1,"h2",50),r.Bc(2),r.Rb(),r.Rb()),2&e){var a=r.ec(2);r.Bb(2),r.Dc(" Taux ",a.onHoverLegendInfosValue," ")}}function q(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}var N=function(e,t){return{red:e,green:t}};function _(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,q,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec(2);r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueDayBefore>0,a.onHoverLegendInfosValueDayBefore<0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueDayBefore,") ")}}function z(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function Y(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,z,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec(2);r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueDayBefore<0,a.onHoverLegendInfosValueDayBefore>0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueDayBefore,") ")}}function U(e,t){if(1&e&&(r.Sb(0,"div",28),r.Ac(1,H,2,1,"h2",47),r.Ac(2,V,3,1,"div",48),r.Bc(3," \xa0 "),r.Sb(4,"h2",28),r.Ac(5,_,4,6,"span",25),r.Ac(6,Y,4,6,"span",25),r.Rb(),r.Rb()),2&e){var a=r.ec();r.Bb(1),r.jc("ngIf",!a.miseEnFormeLegendBottomTitle()),r.Bb(1),r.jc("ngIf",a.miseEnFormeLegendBottomTitle()),r.Bb(3),r.jc("ngIf",a.isColorInversed),r.Bb(1),r.jc("ngIf",!a.isColorInversed)}}function $(e,t){1&e&&(r.Sb(0,"div",28),r.Sb(1,"h2"),r.Bc(2," Donn\xe9es non disponible "),r.Rb(),r.Rb())}function Z(e,t){1&e&&(r.Sb(0,"div",28),r.Sb(1,"h2"),r.Bc(2," Selectionnez un pays... "),r.Rb(),r.Rb())}function X(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function J(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,X,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueMinDayBefore>0,a.onHoverLegendInfosValueMinDayBefore<0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueMinDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueMinDayBefore,") ")}}function K(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function Q(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,K,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueMinDayBefore<0,a.onHoverLegendInfosValueMinDayBefore>0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueMinDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueMinDayBefore,") ")}}function W(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function ee(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,W,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValuemaxDayBefore>0,a.onHoverLegendInfosValuemaxDayBefore<0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValuemaxDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValuemaxDayBefore,") ")}}function te(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function ae(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,te,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValuemaxDayBefore<0,a.onHoverLegendInfosValuemaxDayBefore>0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValuemaxDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValuemaxDayBefore,") ")}}function ne(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function ie(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,ne,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueMeanDayBefore>0,a.onHoverLegendInfosValueMeanDayBefore<0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueMeanDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueMeanDayBefore,") ")}}function re(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"+"),r.Rb())}function oe(e,t){if(1&e&&(r.Sb(0,"span",51),r.Bc(1," ( "),r.Ac(2,re,2,0,"span",7),r.Bc(3),r.Rb()),2&e){var a=r.ec();r.jc("ngClass",r.mc(3,N,a.onHoverLegendInfosValueMeanDayBefore<0,a.onHoverLegendInfosValueMeanDayBefore>0)),r.Bb(2),r.jc("ngIf",a.onHoverLegendInfosValueMeanDayBefore>0),r.Bb(1),r.Dc(" ",a.onHoverLegendInfosValueMeanDayBefore,") ")}}function ce(e,t){if(1&e&&(r.Sb(0,"span"),r.Bc(1),r.Rb()),2&e){var a=r.ec();r.Bb(1),r.Dc("Cas ",a.selectedTypeGraph,"")}}function le(e,t){if(1&e&&(r.Sb(0,"span"),r.Bc(1),r.Rb()),2&e){var a=r.ec();r.Bb(1),r.Cc(a.selectedTypeGraph)}}function se(e,t){1&e&&(r.Sb(0,"span"),r.Bc(1,"pour 100 personnes"),r.Rb())}function de(e,t){1&e&&r.Ob(0,"div",52),2&e&&r.yc("background: ",t.$implicit,"")}function ue(e,t){if(1&e&&(r.Sb(0,"div"),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.Bb(1),r.Cc(a)}}var pe,be=function(e){return{bottom:!1,right:e,top:!1,left:!1}},fe=300,ye=((pe=function(){function e(t,a){_classCallCheck(this,e),this.http=t,this.ref=a,this.aliasGranularityMap=p,this.leafletOptions={layers:[Object(u.tileLayer)("http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",{maxZoom:18,attribution:"Bastien MAURICE"})],zoom:6,center:Object(u.latLng)(46.303558,6.0164252)},this.widthSidebar=fe,this.isOpenSidebar=!0,this.selectedGranularityMap=p.PAYS,this.listAllGranularityMap=[p.PAYS,p.REGION,p.DEPARTEMENT],this.selectedTypeGraph=f.a.CONFIRMED,this.selectedLegendColorGradient=y.c,this.listTypeGraph=[f.a.CONFIRMED,f.a.DEATH,f.a.ACTIVE,f.a.HOSPITALIZED,f.a.REANIMATED,f.a.RECOVERED,f.a.RECOVERY_RATE,f.a.MORTALITY_RATE],this.selectedLegendInfos=[],this.onHoverLegendInfos="",this.isHoveringItem=!1,this.isColorInversed=!0}return _createClass(e,[{key:"toggleSidebar",value:function(){this.isOpenSidebar=!this.isOpenSidebar,this.widthSidebar=this.isOpenSidebar?fe:30}},{key:"onResizeEnd",value:function(e){fe=e.rectangle.width,this.widthSidebar=e.rectangle.width}},{key:"validate",value:function(e){return!(e.rectangle.width&&e.rectangle.width<300)}},{key:"ngOnInit",value:function(){var e=this;this.http.get(b.e).subscribe((function(t){e.franceLayer=u.geoJSON(t,{style:{color:"#4974ff",fillOpacity:.7,weight:2},onEachFeature:function(t,a){a.on("mouseover",(function(t){return e.highlightFeature(t)})),a.on("mouseout",(function(t){return e.resetHighlight(t)}))}}),e.updateDateMinMaxSelected(),e.updateStyleMap()})),this.http.get(b.d).subscribe((function(t){e.departementLayer=u.geoJSON(t,{style:{color:"#4974ff",fillOpacity:.7,weight:2},onEachFeature:function(t,a){a.on("mouseover",(function(t){return e.highlightFeature(t)})),a.on("mouseout",(function(t){return e.resetHighlight(t)}))}})})),this.http.get(b.g).subscribe((function(t){e.regionLayer=u.geoJSON(t,{style:{color:"#4974ff",fillOpacity:.7,weight:2},onEachFeature:function(t,a){a.on("mouseover",(function(t){return e.highlightFeature(t)})),a.on("mouseout",(function(t){return e.resetHighlight(t)}))}})}))}},{key:"zoomToFeature",value:function(e){}},{key:"updateStyleMap",value:function(){var e,t=this;switch(this.updateMinMaxMeanTopLegendInfosFIRST(),this.updateLengendColor(),this.updateLegendValues(),this.selectedTypeGraph){case f.a.CONFIRMED:e="confirmed",this.isColorInversed=!0;break;case f.a.DEATH:e="death",this.isColorInversed=!0;break;case f.a.ACTIVE:e="active",this.isColorInversed=!0;break;case f.a.HOSPITALIZED:e="hospitalized",this.isColorInversed=!0;break;case f.a.REANIMATED:e="reanimated",this.isColorInversed=!1;break;case f.a.RECOVERED:e="recovered",this.isColorInversed=!1;break;case f.a.RECOVERY_RATE:e="recoveredRate",this.isColorInversed=!1;break;case f.a.MORTALITY_RATE:e="mortalityRate",this.isColorInversed=!0}switch(this.selectedGranularityMap){case p.PAYS:this.franceLayer.eachLayer((function(a){a.feature.properties.value.forEach((function(n){Object(b.j)(new Date(n.date),t.selectedDate)&&a.setStyle({fillColor:t.getColor(n[e]),fillOpacity:.7,weight:2})}))}));break;case p.REGION:this.regionLayer.eachLayer((function(a){a.feature.properties.value.forEach((function(n){Object(b.j)(new Date(n.date),t.selectedDate)&&a.setStyle({fillColor:t.getColor(n[e]),fillOpacity:.7,weight:2})}))}));break;case p.DEPARTEMENT:this.departementLayer.eachLayer((function(a){a.feature.properties.value.forEach((function(n){Object(b.j)(new Date(n.date),t.selectedDate)&&a.setStyle({fillColor:t.getColor(n[e]),fillOpacity:.7,weight:2})}))}))}}},{key:"updateLengendColor",value:function(){switch(this.selectedTypeGraph){case f.a.CONFIRMED:case f.a.DEATH:this.selectedLegendColorGradient=y.c;break;case f.a.ACTIVE:case f.a.HOSPITALIZED:case f.a.REANIMATED:this.selectedLegendColorGradient=y.b;break;case f.a.RECOVERED:case f.a.RECOVERY_RATE:this.selectedLegendColorGradient=y.a;break;case f.a.MORTALITY_RATE:this.selectedLegendColorGradient=y.c}}},{key:"resetHighlight",value:function(e){switch(this.isHoveringItem=!1,this.selectedGranularityMap){case p.PAYS:this.franceLayer.eachLayer((function(e){e.setStyle({weight:2,color:"#4974ff"})}));break;case p.REGION:this.regionLayer.eachLayer((function(e){e.setStyle({weight:2,color:"#4974ff"})}));break;case p.DEPARTEMENT:this.departementLayer.eachLayer((function(e){e.setStyle({weight:2,color:"#4974ff"})}))}this.onHoverLegendInfos=null,this.onHoverLegendInfosValue=null,this.ref.detectChanges()}},{key:"getArgsId",value:function(){var e;switch(this.selectedTypeGraph){case f.a.CONFIRMED:e="confirmed";break;case f.a.DEATH:e="death";break;case f.a.ACTIVE:e="active";break;case f.a.HOSPITALIZED:e="hospitalized";break;case f.a.REANIMATED:e="reanimated";break;case f.a.RECOVERED:e="recovered";break;case f.a.RECOVERY_RATE:e="recoveredRate";break;case f.a.MORTALITY_RATE:e="mortalityRate"}return e}},{key:"highlightFeature",value:function(e){var t=this;this.isHoveringItem=!0;var a,n,i=e.target;i.setStyle({weight:5,color:"white"});var r=this.getArgsId(),o=new Date(this.selectedDate);o.setDate(o.getDate()-1),i.feature.properties.value.forEach((function(e){Object(b.j)(new Date(e.date),t.selectedDate)&&(a=e[r]),Object(b.j)(new Date(e.date),o)&&(n=e[r])})),a?(this.onHoverLegendInfos=i.feature.properties.nom,this.onHoverLegendInfosValue=Number(a.toFixed(2)),this.onHoverLegendInfosValueDayBefore=Number((a-n).toFixed(2))):(this.onHoverLegendInfos=i.feature.properties.nom,this.onHoverLegendInfosValue=null,this.onHoverLegendInfosValueDayBefore=null),this.ref.detectChanges()}},{key:"updateMinMaxMeanTopLegendInfosFIRST",value:function(){switch(this.selectedGranularityMap){case p.PAYS:this.updateMinMaxMeanTopLegendInfos(this.franceLayer);break;case p.REGION:this.updateMinMaxMeanTopLegendInfos(this.regionLayer);break;case p.DEPARTEMENT:this.updateMinMaxMeanTopLegendInfos(this.departementLayer)}}},{key:"updateMinMaxMeanTopLegendInfos",value:function(e){var t,a,n,i,r=this,o=this.getArgsId(),c=0,l=0,s=0,d=0;e.eachLayer((function(e){e.feature.properties.value.forEach((function(e){Object(b.j)(new Date(e.date),r.selectedDate)&&(c+=e[o],l++,void 0===t?t=e[o]:e[o]<t&&(t=e[o]),void 0===a?a=e[o]:e[o]>a&&(a=e[o]));var u=new Date(r.selectedDate);u.setDate(u.getDate()-1),Object(b.j)(u,new Date(e.date))&&(s+=e[o],d++,void 0===n?n=e[o]:e[o]<n&&(n=e[o]),void 0===i?i=e[o]:e[o]>i&&(i=e[o]))}))})),this.onHoverLegendInfosValueMean=Number(Math.round(c/l).toFixed(2)),this.onHoverLegendInfosValueMin=Number(t.toFixed(2)),this.onHoverLegendInfosValuemax=Number(a.toFixed(2)),this.onHoverLegendInfosValueMeanDayBefore=Number((Math.round(s/d)-this.onHoverLegendInfosValueMean).toFixed(2)),this.onHoverLegendInfosValueMinDayBefore=Number((t-n).toFixed(2)),this.onHoverLegendInfosValuemaxDayBefore=Number((i-a).toFixed(2))}},{key:"changeGranularity",value:function(){this.updateDateMinMaxSelected(),this.updateStyleMap()}},{key:"updateLegendValues",value:function(){switch(this.selectedGranularityMap){case p.PAYS:this.legendValuesMax(this.franceLayer);break;case p.REGION:this.legendValuesMax(this.regionLayer);break;case p.DEPARTEMENT:this.legendValuesMax(this.departementLayer)}}},{key:"legendValuesMax",value:function(e){var t=this,a=0;e.eachLayer((function(e){e.feature.properties.value.forEach((function(e){if(Object(b.j)(new Date(e.date),t.selectedDate))switch(t.selectedTypeGraph){case f.a.CONFIRMED:e.confirmed>a&&(a=e.confirmed);break;case f.a.DEATH:e.death>a&&(a=e.death);break;case f.a.ACTIVE:e.active>a&&(a=e.active);break;case f.a.HOSPITALIZED:e.hospitalized>a&&(a=e.hospitalized);break;case f.a.REANIMATED:e.reanimated>a&&(a=e.reanimated);break;case f.a.RECOVERED:e.recovered>a&&(a=e.recovered);break;case f.a.RECOVERY_RATE:e.recoveredRate>a&&(a=e.recoveredRate);break;case f.a.MORTALITY_RATE:e.mortalityRate>a&&(a=e.mortalityRate)}}))}));var n=Math.round(a/7);this.selectedLegendInfos=[6*n,5*n,4*n,3*n,2*n,n]}},{key:"dateChanged",value:function(e){this.selectedDate=e,this.updateStyleMap()}},{key:"updateDateMinMaxSelected",value:function(){switch(this.selectedGranularityMap){case p.PAYS:this.iteratorDates(this.franceLayer);break;case p.REGION:this.iteratorDates(this.regionLayer);break;case p.DEPARTEMENT:this.iteratorDates(this.departementLayer)}}},{key:"iteratorDates",value:function(e){var t=this;e.eachLayer((function(e){e.feature.properties.value.forEach((function(e){void 0===t.minDate&&(t.minDate=new Date(e.date)),void 0===t.maxDate&&(t.maxDate=new Date(e.date)),void 0===t.selectedDate&&(t.selectedDate=new Date(e.date)),new Date(e.date)>t.maxDate&&(t.maxDate=new Date(e.date),t.selectedDate=new Date(e.date)),new Date(e.date)<t.minDate&&(t.minDate=new Date(e.date))}))}))}},{key:"onMapReady",value:function(e){this.leafletMap=e}},{key:"miseEnFormeLegendBottomTitle",value:function(){return this.selectedTypeGraph===f.a.MORTALITY_RATE||this.selectedTypeGraph===f.a.RECOVERY_RATE}},{key:"getColor",value:function(e){return e>this.selectedLegendInfos[0]?this.selectedLegendColorGradient[0]:e>this.selectedLegendInfos[1]?this.selectedLegendColorGradient[1]:e>this.selectedLegendInfos[2]?this.selectedLegendColorGradient[2]:e>this.selectedLegendInfos[3]?this.selectedLegendColorGradient[3]:e>this.selectedLegendInfos[4]?this.selectedLegendColorGradient[4]:this.selectedLegendColorGradient[5]}}]),e}()).\u0275fac=function(e){return new(e||pe)(r.Nb(g.a),r.Nb(r.h))},pe.\u0275cmp=r.Hb({type:pe,selectors:[["app-map"]],decls:65,vars:33,consts:[["fxFlexFill","","fxLayout","row","fxLayoutAlign","center",1,"mainContener"],["mwlResizable","","resizeCursorPrecision","5",3,"enableGhostResize","resizeEdges","validateResize","resizeEnd"],["fxFlex","","fxLayout","row","fxLayoutAlign","space-between"],["fxFlex","","fxLayout","column","fxLayoutGap","20px","class","scrollable",4,"ngIf"],["fxLayout","row","fxFlex","30px"],["fxFlex","","fxLayoutAlign","center"],["fxFlex","","mat-button","",1,"buttonSidebarClose","icon",3,"click"],[4,"ngIf"],["fxFlex","2px",1,"dividerSidebar"],["fxFlex",""],["leaflet","",1,"lastPlan",2,"height","100%",3,"leafletOptions","leafletMapReady"],[3,"leafletLayer",4,"ngIf"],[1,"legendTop"],["fxFlex","","fxLayout","row","fxLayoutAlign","center"],["fxFlex","","fxLayout","column","fxLayoutAlign","center"],["fxLayoutAlign","center","style","margin: 0px;font-weight: bold;",4,"ngIf"],["fxLayoutAlign","center",4,"ngIf"],["fxLayout","row","fxLayoutAlign","center",2,"margin","10px"],["fxFlex","60%"],["fxFill",""],["fxLayout","column","fxLayoutAlign","center center","fxLa","",2,"margin","0px","margin-bottom","10px"],[2,"margin","0px"],["fxLayout","row","fxLayoutAlign","space-around center"],[2,"margin-left","20px"],["fxFlex","","fxLayout","row","fxLayoutAlign","end",2,"margin","0px","margin-right","20px"],[3,"ngClass",4,"ngIf"],[1,"firstPlan","legend"],["fxLayout","column"],["fxLayoutAlign","center"],["fxFlex","","fxLayout","row","fxLayoutGap","10px","fxLayoutAlign","space-evenly"],["fxLayoutGap","5px","fxLayout","column","fxLayoutAlign","center"],["class","squareLegend",3,"style",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],["fxFlex","","fxLayout","column","fxLayoutGap","20px",1,"scrollable"],["fxLayout","row","fxLayoutAlign","center"],[1,"contentTemplate"],[3,"ngModel","ngModelChange","change"],["fxLayout","column","fxLayoutGap","5px"],[3,"value",4,"ngFor","ngForOf"],[3,"value","selectionChange","valueChange"],[1,"dateInput"],["matInput","",3,"value","min","max","matDatepicker","dateChange"],["matSuffix","",3,"for"],["picker",""],[3,"value"],[3,"leafletLayer"],["fxLayoutAlign","center",2,"margin","0px","font-weight","bold"],["style","margin: 0px;",4,"ngIf"],["style","margin: 0px;","fxLayout","column",4,"ngIf"],["fxLayout","column",2,"margin","0px"],["fxLayoutAlign","center",2,"margin","0px"],[3,"ngClass"],[1,"squareLegend"]],template:function(e,t){1&e&&(r.Sb(0,"div",0),r.Sb(1,"div",1),r.ac("resizeEnd",(function(e){return t.onResizeEnd(e)})),r.Sb(2,"div",2),r.Ac(3,P,31,9,"div",3),r.Sb(4,"div",4),r.Sb(5,"div",5),r.Sb(6,"button",6),r.ac("click",(function(){return t.toggleSidebar()})),r.Ac(7,G,2,0,"mat-icon",7),r.Ac(8,w,2,0,"mat-icon",7),r.Rb(),r.Rb(),r.Ob(9,"div",8),r.Rb(),r.Rb(),r.Rb(),r.Sb(10,"div",9),r.Sb(11,"div",10),r.ac("leafletMapReady",(function(e){return t.onMapReady(e)})),r.Ac(12,O,1,1,"div",11),r.Ac(13,k,1,1,"div",11),r.Ac(14,j,1,1,"div",11),r.Rb(),r.Rb(),r.Rb(),r.Sb(15,"div",12),r.Sb(16,"div",13),r.Sb(17,"div",14),r.Ac(18,F,2,1,"h1",15),r.Ac(19,U,7,4,"div",16),r.Ac(20,$,3,0,"div",16),r.Ac(21,Z,3,0,"div",16),r.Sb(22,"div",17),r.Sb(23,"div",18),r.Ob(24,"mat-divider",19),r.Rb(),r.Rb(),r.Sb(25,"div",20),r.Sb(26,"h2",21),r.Bc(27),r.Rb(),r.Sb(28,"h3",21),r.Bc(29," Tout confondu "),r.Rb(),r.Rb(),r.Sb(30,"div",22),r.Sb(31,"div",23),r.Bc(32," Min "),r.Rb(),r.Sb(33,"h3",24),r.Sb(34,"div"),r.Bc(35),r.Ac(36,J,4,6,"span",25),r.Ac(37,Q,4,6,"span",25),r.Rb(),r.Rb(),r.Rb(),r.Sb(38,"div",22),r.Sb(39,"div",23),r.Bc(40," Max "),r.Rb(),r.Sb(41,"h3",24),r.Bc(42),r.Ac(43,ee,4,6,"span",25),r.Ac(44,ae,4,6,"span",25),r.Rb(),r.Rb(),r.Sb(45,"div",22),r.Sb(46,"div",23),r.Bc(47," Moyenne "),r.Rb(),r.Sb(48,"h3",24),r.Bc(49),r.Ac(50,ie,4,6,"span",25),r.Ac(51,oe,4,6,"span",25),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Sb(52,"div",26),r.Sb(53,"div",27),r.Sb(54,"div",28),r.Sb(55,"div"),r.Sb(56,"h3",21),r.Ac(57,ce,2,1,"span",7),r.Ac(58,le,2,1,"span",7),r.Rb(),r.Ac(59,se,2,0,"span",7),r.Rb(),r.Rb(),r.Sb(60,"div",29),r.Sb(61,"div",30),r.Ac(62,de,1,3,"div",31),r.Rb(),r.Sb(63,"div",30),r.Ac(64,ue,2,1,"div",32),r.Rb(),r.Rb(),r.Rb(),r.Rb()),2&e&&(r.Bb(1),r.zc("width",t.widthSidebar+"px"),r.jc("enableGhostResize",!0)("resizeEdges",r.lc(31,be,t.isOpenSidebar))("validateResize",t.validate),r.Bb(2),r.jc("ngIf",t.isOpenSidebar),r.Bb(4),r.jc("ngIf",t.isOpenSidebar),r.Bb(1),r.jc("ngIf",!t.isOpenSidebar),r.Bb(3),r.jc("leafletOptions",t.leafletOptions),r.Bb(1),r.jc("ngIf",t.selectedGranularityMap===t.aliasGranularityMap.PAYS),r.Bb(1),r.jc("ngIf",t.selectedGranularityMap===t.aliasGranularityMap.REGION),r.Bb(1),r.jc("ngIf",t.selectedGranularityMap===t.aliasGranularityMap.DEPARTEMENT),r.Bb(4),r.jc("ngIf",t.isHoveringItem),r.Bb(1),r.jc("ngIf",t.isHoveringItem),r.Bb(1),r.jc("ngIf",t.isHoveringItem&&null===t.onHoverLegendInfosValue),r.Bb(1),r.jc("ngIf",!t.isHoveringItem),r.Bb(6),r.Dc(" ",t.selectedGranularityMap," "),r.Bb(8),r.Dc(" ",t.onHoverLegendInfosValueMin," \xa0 "),r.Bb(1),r.jc("ngIf",t.isColorInversed),r.Bb(1),r.jc("ngIf",!t.isColorInversed),r.Bb(5),r.Dc(" ",t.onHoverLegendInfosValuemax," \xa0 "),r.Bb(1),r.jc("ngIf",t.isColorInversed),r.Bb(1),r.jc("ngIf",!t.isColorInversed),r.Bb(5),r.Dc(" ",t.onHoverLegendInfosValueMean," \xa0 "),r.Bb(1),r.jc("ngIf",t.isColorInversed),r.Bb(1),r.jc("ngIf",!t.isColorInversed),r.Bb(6),r.jc("ngIf",!t.miseEnFormeLegendBottomTitle()),r.Bb(1),r.jc("ngIf",t.miseEnFormeLegendBottomTitle()),r.Bb(1),r.jc("ngIf",t.miseEnFormeLegendBottomTitle()),r.Bb(3),r.jc("ngForOf",t.selectedLegendColorGradient),r.Bb(2),r.jc("ngForOf",t.selectedLegendInfos))},directives:[o.f,o.d,o.c,h.a,o.b,n.k,C.a,T.a,m.a,o.e,n.j,v.b,D.g,D.i,R.b,S.a,E.b,L.b,L.d,R.f,L.a,v.a,x.k,M.a,T.b,n.i,B.a],styles:[".dividerSidebar[_ngcontent-%COMP%]{background-color:#323233}.icon[_ngcontent-%COMP%]:hover{color:#ec407a}.icon[_ngcontent-%COMP%]{color:#f48fb1}mwlResizable[_ngcontent-%COMP%]{box-sizing:border-box}.floatingButtonContener[_ngcontent-%COMP%]{position:fixed;bottom:40px;right:20px}.buttonSidebarClose[_ngcontent-%COMP%]{padding:0;width:20px;min-width:0}.contentTemplate[_ngcontent-%COMP%]{padding-left:10px}.titleTemplate[_ngcontent-%COMP%]{padding-left:5px}.dateInput[_ngcontent-%COMP%]{width:150px}.loader[_ngcontent-%COMP%]{background-color:transparent;width:100%;height:100%;position:absolute;top:0;left:0;background-color:red;opacity:.5}.legend[_ngcontent-%COMP%]{width:150px;height:200px;bottom:60px}.legend[_ngcontent-%COMP%], .legendTop[_ngcontent-%COMP%]{position:fixed;right:40px;background-color:#fff}.legendTop[_ngcontent-%COMP%]{width:250px;height:280px;top:120px;z-index:3}.lastPlan[_ngcontent-%COMP%]{z-index:1}.firstPlan[_ngcontent-%COMP%]{z-index:2}.squareLegend[_ngcontent-%COMP%]{width:20px;height:20px}.green[_ngcontent-%COMP%]{color:green}.red[_ngcontent-%COMP%]{color:red}.scrollable[_ngcontent-%COMP%]{overflow:auto}"]}),pe),ge=function(){function e(t,a,n,i,r,o,c,l,s,d,u,p){_classCallCheck(this,e),this.date=t,this.typeCarte=a,this.codeTypeCarte=n,this.libeleTypeCarte=i,this.casConfirme=r,this.deces=o,this.reanimation=c,this.hospitalise=l,this.gueris=s,this.actif=d,this.tauxGuerison=p,this.tauxMortalite=u}return _createClass(e,[{key:"getMortalityRate",value:function(){return this.tauxMortalite}},{key:"getRecoveryRate",value:function(){return this.tauxGuerison}},{key:"getDate",value:function(){return this.date}},{key:"getActif",value:function(){return this.actif}},{key:"getTypeCarte",value:function(){return this.typeCarte}},{key:"getCodeTypeCarte",value:function(){return this.codeTypeCarte}},{key:"getLibeleTypeCarte",value:function(){return this.libeleTypeCarte}},{key:"getCasConfirme",value:function(){return this.casConfirme}},{key:"getDeces",value:function(){return this.deces}},{key:"getReanimation",value:function(){return this.reanimation}},{key:"getHospitalise",value:function(){return this.hospitalise}},{key:"getGueris",value:function(){return this.gueris}},{key:"setMortalityRate",value:function(e){this.tauxMortalite=e}},{key:"setRecoveryRate",value:function(e){this.tauxGuerison=e}},{key:"setDate",value:function(e){this.date=e}},{key:"setTypeCarte",value:function(e){this.typeCarte=e}},{key:"setCodeTypeCarte",value:function(e){this.codeTypeCarte=e}},{key:"setLibeleTypeCarte",value:function(e){this.libeleTypeCarte=e}},{key:"setCasConfirme",value:function(e){this.casConfirme=e}},{key:"setDeces",value:function(e){this.deces=e}},{key:"setReanimation",value:function(e){this.reanimation=e}},{key:"setHospitalise",value:function(e){this.hospitalise=e}},{key:"setGueris",value:function(e){this.gueris=e}},{key:"setActif",value:function(e){this.actif=e}}]),e}(),he=a("zT9C"),Ce=a("kRbQ"),Te=a("GvUb"),me=a("v5SH"),ve=a("kDNy"),De=[{codeTypeCarte:"FRA",libeleTypeCarte:"France"}],Re=[{codeTypeCarte:"REG-75",libeleTypeCarte:"Nouvelle-Aquitaine"},{codeTypeCarte:"REG-11",libeleTypeCarte:"\xcele-de-France"},{codeTypeCarte:"REG-84",libeleTypeCarte:"Auvergne-Rh\xf4ne-Alpes"},{codeTypeCarte:"REG-27",libeleTypeCarte:"Bourgogne-Franche-Comt\xe9"},{codeTypeCarte:"REG-32",libeleTypeCarte:"Hauts-de-France"},{codeTypeCarte:"REG-44",libeleTypeCarte:"Grand Est"},{codeTypeCarte:"REG-01",libeleTypeCarte:"Guadeloupe"},{codeTypeCarte:"REG-02",libeleTypeCarte:"Martinique"},{codeTypeCarte:"REG-03",libeleTypeCarte:"Guyane"},{codeTypeCarte:"REG-04",libeleTypeCarte:"La R\xe9union"},{codeTypeCarte:"REG-06",libeleTypeCarte:"Mayotte"},{codeTypeCarte:"REG-24",libeleTypeCarte:"Centre-Val de Loire"},{codeTypeCarte:"REG-28",libeleTypeCarte:"Normandie"},{codeTypeCarte:"REG-52",libeleTypeCarte:"Pays de la Loire"},{codeTypeCarte:"REG-53",libeleTypeCarte:"Bretagne"},{codeTypeCarte:"REG-76",libeleTypeCarte:"Occitanie"},{codeTypeCarte:"REG-93",libeleTypeCarte:"Provence-Alpes-C\xf4te d'Azur"},{codeTypeCarte:"REG-94",libeleTypeCarte:"Corse"}],Se=[{libeleTypeCarte:"Charente",codeTypeCarte:"DEP-16"},{libeleTypeCarte:"Charente-Maritime",codeTypeCarte:"DEP-17"},{libeleTypeCarte:"Corr\xe8ze",codeTypeCarte:"DEP-19"},{libeleTypeCarte:"Creuse",codeTypeCarte:"DEP-23"},{libeleTypeCarte:"Dordogne",codeTypeCarte:"DEP-24"},{libeleTypeCarte:"Gironde",codeTypeCarte:"DEP-33"},{libeleTypeCarte:"Landes",codeTypeCarte:"DEP-40"},{libeleTypeCarte:"Lot-et-Garonne",codeTypeCarte:"DEP-47"},{libeleTypeCarte:"Pyr\xe9n\xe9es-Atlantiques",codeTypeCarte:"DEP-64"},{libeleTypeCarte:"Deux-S\xe8vres",codeTypeCarte:"DEP-79"},{libeleTypeCarte:"Vienne",codeTypeCarte:"DEP-86"},{libeleTypeCarte:"Haute-Vienne",codeTypeCarte:"DEP-87"},{libeleTypeCarte:"H\xe9rault",codeTypeCarte:"DEP-34"},{libeleTypeCarte:"Haute-Savoie",codeTypeCarte:"DEP-74"},{libeleTypeCarte:"Aisne",codeTypeCarte:"DEP-02"},{libeleTypeCarte:"Doubs",codeTypeCarte:"DEP-25"},{libeleTypeCarte:"Nord",codeTypeCarte:"DEP-59"},{libeleTypeCarte:"Oise",codeTypeCarte:"DEP-60"},{libeleTypeCarte:"Pas-de-Calais",codeTypeCarte:"DEP-62"},{libeleTypeCarte:"Somme",codeTypeCarte:"DEP-80"},{libeleTypeCarte:"Territoire de Belfort",codeTypeCarte:"DEP-90"},{libeleTypeCarte:"C\xf4te-d'Or",codeTypeCarte:"DEP-21"},{libeleTypeCarte:"Finist\xe8re",codeTypeCarte:"DEP-29"},{libeleTypeCarte:"Loire-Atlantique",codeTypeCarte:"DEP-44"},{libeleTypeCarte:"Bas-Rhin",codeTypeCarte:"DEP-67"},{libeleTypeCarte:"Alpes-Maritimes",codeTypeCarte:"DEP-06"},{libeleTypeCarte:"Maine-et-Loire",codeTypeCarte:"DEP-49"},{libeleTypeCarte:"Mayenne",codeTypeCarte:"DEP-53"},{libeleTypeCarte:"Seine-Maritime",codeTypeCarte:"DEP-76"},{libeleTypeCarte:"Ille-et-Vilaine",codeTypeCarte:"DEP-35"},{libeleTypeCarte:"Morbihan",codeTypeCarte:"DEP-56"},{libeleTypeCarte:"Sarthe",codeTypeCarte:"DEP-72"},{libeleTypeCarte:"Ain",codeTypeCarte:"DEP-01"},{libeleTypeCarte:"Ardennes",codeTypeCarte:"DEP-08"},{libeleTypeCarte:"Aube",codeTypeCarte:"DEP-10"},{libeleTypeCarte:"Eure",codeTypeCarte:"DEP-27"},{libeleTypeCarte:"Marne",codeTypeCarte:"DEP-51"},{libeleTypeCarte:"Haute-Marne",codeTypeCarte:"DEP-52"},{libeleTypeCarte:"Meurthe-et-Moselle",codeTypeCarte:"DEP-54"},{libeleTypeCarte:"Meuse",codeTypeCarte:"DEP-55"},{libeleTypeCarte:"Moselle",codeTypeCarte:"DEP-57"},{libeleTypeCarte:"Haut-Rhin",codeTypeCarte:"DEP-68"},{libeleTypeCarte:"Rh\xf4ne",codeTypeCarte:"DEP-69"},{libeleTypeCarte:"Vosges",codeTypeCarte:"DEP-88"},{libeleTypeCarte:"Allier",codeTypeCarte:"DEP-03"},{libeleTypeCarte:"Ard\xe8che",codeTypeCarte:"DEP-07"},{libeleTypeCarte:"Cantal",codeTypeCarte:"DEP-15"},{libeleTypeCarte:"Dr\xf4me",codeTypeCarte:"DEP-26"},{libeleTypeCarte:"Gard",codeTypeCarte:"DEP-30"},{libeleTypeCarte:"Is\xe8re",codeTypeCarte:"DEP-38"},{libeleTypeCarte:"Loire",codeTypeCarte:"DEP-42"},{libeleTypeCarte:"Haute-Loire",codeTypeCarte:"DEP-43"},{libeleTypeCarte:"Puy-de-D\xf4me",codeTypeCarte:"DEP-63"},{libeleTypeCarte:"Sa\xf4ne-et-Loire",codeTypeCarte:"DEP-71"},{libeleTypeCarte:"Savoie",codeTypeCarte:"DEP-73"},{libeleTypeCarte:"Aveyron",codeTypeCarte:"DEP-12"},{libeleTypeCarte:"Bouches-du-Rh\xf4ne",codeTypeCarte:"DEP-13"},{libeleTypeCarte:"C\xf4tes-d'Armor",codeTypeCarte:"DEP-22"},{libeleTypeCarte:"Eure-et-Loir",codeTypeCarte:"DEP-28"},{libeleTypeCarte:"Indre-et-Loire",codeTypeCarte:"DEP-37"},{libeleTypeCarte:"Haute-Sa\xf4ne",codeTypeCarte:"DEP-70"},{libeleTypeCarte:"Vaucluse",codeTypeCarte:"DEP-84"},{libeleTypeCarte:"Guyane",codeTypeCarte:"DEP-973"},{libeleTypeCarte:"Hautes-Alpes",codeTypeCarte:"DEP-05"},{libeleTypeCarte:"Calvados",codeTypeCarte:"DEP-14"},{libeleTypeCarte:"Cher",codeTypeCarte:"DEP-18"},{libeleTypeCarte:"Corse-du-Sud",codeTypeCarte:"DEP-2A"},{libeleTypeCarte:"Haute-Corse",codeTypeCarte:"DEP-2B"},{libeleTypeCarte:"Haute-Garonne",codeTypeCarte:"DEP-31"},{libeleTypeCarte:"Indre",codeTypeCarte:"DEP-36"},{libeleTypeCarte:"Loir-et-Cher",codeTypeCarte:"DEP-41"},{libeleTypeCarte:"Loiret",codeTypeCarte:"DEP-45"},{libeleTypeCarte:"Manche",codeTypeCarte:"DEP-50"},{libeleTypeCarte:"Paris",codeTypeCarte:"DEP-75"},{libeleTypeCarte:"Seine-et-Marne",codeTypeCarte:"DEP-77"},{libeleTypeCarte:"Yvelines",codeTypeCarte:"DEP-78"},{libeleTypeCarte:"Var",codeTypeCarte:"DEP-83"},{libeleTypeCarte:"Essonne",codeTypeCarte:"DEP-91"},{libeleTypeCarte:"Hauts-de-Seine",codeTypeCarte:"DEP-82"},{libeleTypeCarte:"Seine-Saint-Denis",codeTypeCarte:"DEP-93"},{libeleTypeCarte:"Val-de-Marne",codeTypeCarte:"DEP-94"},{libeleTypeCarte:"Val-d'Oise",codeTypeCarte:"DEP-95"},{libeleTypeCarte:"Martinique",codeTypeCarte:"DEP-972"},{libeleTypeCarte:"Jura",codeTypeCarte:"DEP-39"},{libeleTypeCarte:"Lot",codeTypeCarte:"DEP-46"},{libeleTypeCarte:"Tarn",codeTypeCarte:"DEP-81"},{libeleTypeCarte:"Tarn-et-Garonne",codeTypeCarte:"DEP-82"},{libeleTypeCarte:"Vend\xe9e",codeTypeCarte:"DEP-85"},{libeleTypeCarte:"Yonne",codeTypeCarte:"DEP-89"},{libeleTypeCarte:"Aude",codeTypeCarte:"DEP-11"},{libeleTypeCarte:"Ni\xe8vre",codeTypeCarte:"DEP-58"},{libeleTypeCarte:"Orne",codeTypeCarte:"DEP-61"},{libeleTypeCarte:"Alpes-de-Haute-Provence",codeTypeCarte:"DEP-04"},{libeleTypeCarte:"Gers",codeTypeCarte:"DEP-32"},{libeleTypeCarte:"Hautes-Pyr\xe9n\xe9es",codeTypeCarte:"DEP-64"},{libeleTypeCarte:"Guadeloupe",codeTypeCarte:"DEP-971"},{libeleTypeCarte:"La R\xe9union",codeTypeCarte:"DEP-974"},{libeleTypeCarte:"Pyr\xe9n\xe9es-Orientales",codeTypeCarte:"DEP-66"},{libeleTypeCarte:"Loz\xe8re",codeTypeCarte:"DEP-48"},{libeleTypeCarte:"Mayotte",codeTypeCarte:"DEP-976"},{libeleTypeCarte:"Ari\xe8ge",codeTypeCarte:"DEP-09"}],Ee=a("nXzS"),Le=a("JJv3"),xe=a("Qu3c"),Me=a("8pX3"),Be=a("1jcm"),Ae=a("5RNC"),Ie=a("u3+B");function Pe(e,t){if(1&e&&(r.Sb(0,"mat-radio-button",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a," ")}}function Ge(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a.libeleTypeCarte," ")}}function we(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div"),r.Sb(1,"div"),r.Sb(2,"mat-form-field"),r.Sb(3,"mat-select",31),r.ac("valueChange",(function(e){return r.rc(a),r.ec(2).selectedUniqueCountry=e})),r.Ac(4,Ge,2,2,"mat-option",23),r.Rb(),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(2);r.Bb(3),r.jc("value",n.selectedUniqueCountry),r.Bb(1),r.jc("ngForOf",n.allCountry)}}function Oe(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Ec(" ",a.codeTypeCarte," ",a.libeleTypeCarte," ")}}function ke(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div"),r.Sb(1,"mat-form-field"),r.Sb(2,"mat-select",32),r.ac("selectionChange",(function(){return r.rc(a),r.ec(3).updateFiltredData()}))("valueChange",(function(e){return r.rc(a),r.ec(3).selectedMultipleRegion=e})),r.Ac(3,Oe,2,3,"mat-option",23),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(3);r.Bb(2),r.jc("value",n.selectedMultipleRegion),r.Bb(1),r.jc("ngForOf",n.allRegion)}}function je(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Ec(" ",a.codeTypeCarte," ",a.libeleTypeCarte," ")}}function Fe(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div"),r.Sb(1,"mat-form-field"),r.Sb(2,"mat-select",33),r.ac("selectionChange",(function(){return r.rc(a),r.ec(3).updateFiltredData()}))("valueChange",(function(e){return r.rc(a),r.ec(3).selectedUniqueRegion=e})),r.Ac(3,je,2,3,"mat-option",23),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(3);r.Bb(2),r.jc("value",n.selectedUniqueRegion),r.Bb(1),r.jc("ngForOf",n.allRegion)}}function He(e,t){if(1&e&&(r.Sb(0,"div"),r.Ac(1,ke,4,2,"div",7),r.Ac(2,Fe,4,2,"div",7),r.Rb()),2&e){var a=r.ec(2);r.Bb(1),r.jc("ngIf",!a.uniqueGraphique),r.Bb(1),r.jc("ngIf",a.uniqueGraphique)}}function Ve(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Ec(" ",a.codeTypeCarte," ",a.libeleTypeCarte," ")}}function qe(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div"),r.Sb(1,"mat-form-field"),r.Sb(2,"mat-select",32),r.ac("selectionChange",(function(){return r.rc(a),r.ec(3).updateFiltredData()}))("valueChange",(function(e){return r.rc(a),r.ec(3).selectedMultipleDepartemental=e})),r.Ac(3,Ve,2,3,"mat-option",23),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(3);r.Bb(2),r.jc("value",n.selectedMultipleDepartemental),r.Bb(1),r.jc("ngForOf",n.allDepartemental)}}function Ne(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Ec(" ",a.codeTypeCarte," ",a.libeleTypeCarte," ")}}function _e(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div"),r.Sb(1,"mat-form-field"),r.Sb(2,"mat-select",33),r.ac("selectionChange",(function(){return r.rc(a),r.ec(3).updateFiltredData()}))("valueChange",(function(e){return r.rc(a),r.ec(3).selectedUniqueDepartemental=e})),r.Ac(3,Ne,2,3,"mat-option",23),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(3);r.Bb(2),r.jc("value",n.selectedUniqueDepartemental),r.Bb(1),r.jc("ngForOf",n.allDepartemental)}}function ze(e,t){if(1&e&&(r.Sb(0,"div"),r.Ac(1,qe,4,2,"div",7),r.Ac(2,_e,4,2,"div",7),r.Rb()),2&e){var a=r.ec(2);r.Bb(1),r.jc("ngIf",!a.uniqueGraphique),r.Bb(1),r.jc("ngIf",a.uniqueGraphique)}}function Ye(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",20),r.Sb(1,"mat-form-field",27),r.Sb(2,"input",34),r.ac("dateChange",(function(e){return r.rc(a),r.ec(2).updateDate(e.value)})),r.Rb(),r.Ob(3,"mat-datepicker-toggle",35),r.Ob(4,"mat-datepicker",null,36),r.Rb(),r.Rb()}if(2&e){var n=r.oc(5),i=r.ec(2);r.Bb(2),r.jc("value",i.currentDate)("min",i.minDate)("max",i.maxDate)("matDatepicker",n),r.Bb(1),r.jc("for",n)}}function Ue(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",20),r.Sb(1,"div"),r.Bc(2,"Date Minimal"),r.Rb(),r.Sb(3,"mat-form-field",27),r.Sb(4,"input",34),r.ac("dateChange",(function(e){return r.rc(a),r.ec(2).updateDateCurrentMin(e.value)})),r.Rb(),r.Ob(5,"mat-datepicker-toggle",35),r.Ob(6,"mat-datepicker",null,37),r.Rb(),r.Sb(8,"div"),r.Bc(9,"Date Maximal"),r.Rb(),r.Sb(10,"mat-form-field",27),r.Sb(11,"input",34),r.ac("dateChange",(function(e){return r.rc(a),r.ec(2).updateDateCurrentMax(e.value)})),r.Rb(),r.Ob(12,"mat-datepicker-toggle",35),r.Ob(13,"mat-datepicker",null,38),r.Rb(),r.Rb()}if(2&e){var n=r.oc(7),i=r.oc(14),o=r.ec(2);r.Bb(4),r.jc("value",o.selectedDateMin)("min",o.minDate)("max",o.maxDate)("matDatepicker",n),r.Bb(1),r.jc("for",n),r.Bb(6),r.jc("value",o.selectedDateMax)("min",o.minDate)("max",o.maxDate)("matDatepicker",i),r.Bb(1),r.jc("for",i)}}function $e(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Cc(a)}}function Ze(e,t){if(1&e&&(r.Sb(0,"mat-radio-button",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a," ")}}function Xe(e,t){if(1&e&&(r.Sb(0,"mat-option",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Cc(a)}}function Je(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",20),r.Sb(1,"mat-form-field"),r.Sb(2,"mat-label"),r.Bc(3,"Liste submode"),r.Rb(),r.Sb(4,"mat-select",39),r.ac("selectionChange",(function(e){return r.rc(a),r.ec(2).updateScatterSubmod(e.value)})),r.Ac(5,Xe,2,2,"mat-option",23),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(2);r.Bb(4),r.jc("ngModel",n.allScatterSubmod),r.Bb(1),r.jc("ngForOf",n.allScatterSubmod)}}function Ke(e,t){if(1&e&&(r.Sb(0,"mat-radio-button",30),r.Bc(1),r.Rb()),2&e){var a=t.$implicit;r.jc("value",a),r.Bb(1),r.Dc(" ",a," ")}}function Qe(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",40),r.Sb(1,"div"),r.Sb(2,"mat-radio-group",21),r.ac("change",(function(e){return r.rc(a),r.ec(2).updateBarSubmod(e.value)}))("ngModelChange",(function(e){return r.rc(a),r.ec(2).selectedBarSubmod=e})),r.Sb(3,"div",22),r.Ac(4,Ke,2,2,"mat-radio-button",23),r.Rb(),r.Rb(),r.Rb(),r.Sb(5,"div",19),r.Sb(6,"div",41),r.Sb(7,"span"),r.Bc(8,"Gap bar"),r.Rb(),r.Sb(9,"mat-slider",42),r.ac("change",(function(e){return r.rc(a),r.ec(2).updateBarGap(e.value,"gap")}))("ngModelChange",(function(e){return r.rc(a),r.ec(2).selectedGap=e})),r.Rb(),r.Rb(),r.Sb(10,"div",41),r.Sb(11,"span"),r.Bc(12,"Gap bar groupe"),r.Rb(),r.Sb(13,"mat-slider",42),r.ac("change",(function(e){return r.rc(a),r.ec(2).updateBarGap(e.value,"gapGroup")}))("ngModelChange",(function(e){return r.rc(a),r.ec(2).selectedGapGroup=e})),r.Rb(),r.Rb(),r.Rb(),r.Rb()}if(2&e){var n=r.ec(2);r.Bb(2),r.jc("ngModel",n.selectedBarSubmod),r.Bb(2),r.jc("ngForOf",n.allBarSubmob),r.Bb(5),r.jc("ngModel",n.selectedGap),r.Bb(4),r.jc("ngModel",n.selectedGapGroup)}}function We(e,t){if(1&e){var a=r.Tb();r.Sb(0,"div",17),r.Sb(1,"div",18),r.Sb(2,"h1"),r.Bc(3," Param\xe8tres "),r.Rb(),r.Rb(),r.Sb(4,"div",19),r.Sb(5,"div",18),r.Sb(6,"h3"),r.Bc(7," Granularit\xe9 Carte "),r.Rb(),r.Rb(),r.Sb(8,"div",20),r.Sb(9,"mat-radio-group",21),r.ac("change",(function(){return r.rc(a),r.ec().updateFiltredData()}))("ngModelChange",(function(e){return r.rc(a),r.ec().currentGranulariteCarte=e})),r.Sb(10,"div",22),r.Ac(11,Pe,2,2,"mat-radio-button",23),r.Rb(),r.Rb(),r.Ac(12,we,5,2,"div",7),r.Ac(13,He,3,2,"div",7),r.Ac(14,ze,3,2,"div",7),r.Rb(),r.Rb(),r.Ob(15,"mat-divider"),r.Sb(16,"div",19),r.Sb(17,"div",18),r.Sb(18,"h3"),r.Bc(19," Choix Date "),r.Rb(),r.Rb(),r.Sb(20,"div",20),r.Sb(21,"mat-slide-toggle",24),r.ac("change",(function(e){return r.rc(a),r.ec().updateDateContener(e.checked)})),r.Bc(22," Date Unique "),r.Rb(),r.Rb(),r.Ac(23,Ye,6,5,"div",25),r.Ac(24,Ue,15,10,"div",25),r.Rb(),r.Ob(25,"mat-divider"),r.Sb(26,"div",19),r.Sb(27,"div",18),r.Sb(28,"h3"),r.Bc(29," Granularit\xe9 Graphique "),r.Rb(),r.Rb(),r.Sb(30,"div",26),r.Sb(31,"mat-slide-toggle",24),r.ac("change",(function(e){return r.rc(a),r.ec().updateGraphiqueContener(e.checked)})),r.Bc(32," Graphique global "),r.Rb(),r.Sb(33,"mat-form-field",27),r.Sb(34,"mat-label"),r.Bc(35,"Liste graphique"),r.Rb(),r.Sb(36,"mat-select",28),r.ac("selectionChange",(function(e){return r.rc(a),r.ec().updateNumberOfGraphique(e.value)})),r.Ac(37,$e,2,2,"mat-option",23),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Ob(38,"mat-divider"),r.Sb(39,"div",19),r.Sb(40,"div",18),r.Sb(41,"h3"),r.Bc(42," Graphique Type "),r.Rb(),r.Rb(),r.Sb(43,"div",20),r.Sb(44,"mat-radio-group",21),r.ac("change",(function(e){return r.rc(a),r.ec().updateGraphicType(e.value)}))("ngModelChange",(function(e){return r.rc(a),r.ec().selectedPlotType=e})),r.Sb(45,"div",22),r.Ac(46,Ze,2,2,"mat-radio-button",23),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Ob(47,"mat-divider"),r.Sb(48,"div",19),r.Sb(49,"div",18),r.Sb(50,"h3"),r.Bc(51," Customization "),r.Rb(),r.Rb(),r.Ac(52,Je,6,2,"div",25),r.Ac(53,Qe,14,4,"div",29),r.Rb(),r.Rb()}if(2&e){var n=r.ec();r.Bb(9),r.jc("ngModel",n.currentGranulariteCarte),r.Bb(2),r.jc("ngForOf",n.allMapviewType),r.Bb(1),r.jc("ngIf",n.currentGranulariteCarte===n.aliasGranuCarte.PAYS),r.Bb(1),r.jc("ngIf",n.currentGranulariteCarte===n.aliasGranuCarte.REGION),r.Bb(1),r.jc("ngIf",n.currentGranulariteCarte===n.aliasGranuCarte.DEPARTEMENT),r.Bb(7),r.jc("checked",n.uniqueDate),r.Bb(2),r.jc("ngIf",n.uniqueDate),r.Bb(1),r.jc("ngIf",!n.uniqueDate),r.Bb(7),r.jc("checked",n.uniqueGraphique),r.Bb(5),r.jc("disabled",n.uniqueGraphique),r.Bb(1),r.jc("ngForOf",n.listTypeGraph),r.Bb(7),r.jc("ngModel",n.selectedPlotType),r.Bb(2),r.jc("ngForOf",n.listPlotType),r.Bb(6),r.jc("ngIf",n.selectedPlotType===n.aliasPlotType.SCATTER),r.Bb(1),r.jc("ngIf",n.selectedPlotType===n.aliasPlotType.BAR)}}function et(e,t){1&e&&(r.Sb(0,"mat-icon"),r.Bc(1," keyboard_arrow_left "),r.Rb())}function tt(e,t){1&e&&(r.Sb(0,"mat-icon"),r.Bc(1," keyboard_arrow_right "),r.Rb())}var at=function(){return{width:"100%",height:"100%"}};function nt(e,t){if(1&e&&(r.Sb(0,"div",43),r.Ob(1,"plotly-plot",44),r.Rb()),2&e){var a=t.$implicit;r.Bb(1),r.xc(r.kc(6,at)),r.jc("useResizeHandler",!0)("data",a.data)("config",a.config)("layout",a.layout)}}var it,rt,ot=function(e){return{bottom:!1,right:e,top:!1,left:!1}},ct=300,lt=[{path:"",component:d,children:[{path:"",redirectTo:"graphique",pathMatch:"full"},{path:"carte",component:ye},{path:"graphique",component:(it=function(){function e(t){_classCallCheck(this,e),this.http=t,this.aliasGranuCarte=p,this.aliasPlotType=Ce.a,this.allCountry=De,this.allRegion=Re,this.allDepartemental=Se,this.currentGranulariteCarte=p.PAYS,this.allMapviewType=[p.PAYS,p.REGION,p.DEPARTEMENT],this.isOpenSidebar=!0,this.widthSidebar=ct,this.uniqueDate=!0,this.listTypeGraph=[f.a.ACTIVE,f.a.CONFIRMED,f.a.DEATH,f.a.HOSPITALIZED,f.a.REANIMATED,f.a.RECOVERED,f.a.RECOVERY_RATE,f.a.MORTALITY_RATE],this.selectedPlotType=Ce.a.BAR,this.listPlotType=[Ce.a.BAR,Ce.a.SCATTER],this.allGraphics=[],this.nbEntree=0,this.allData=[],this.uniqueGraphique=!0,this.selectedSpecificGraphicsList=[],this.allBarSubmob=[Te.a.GROUP,Te.a.STACK],this.selectedBarSubmod=Te.a.GROUP,this.allScatterSubmod=[me.a.LINES,me.a.MARKERS],this.selectedScatterSubmod="",this.selectedGap=.1,this.selectedGapGroup=.1,this.selectedUniqueCountry=De[0],this.selectedUniqueRegion=Re[0],this.selectedUniqueDepartemental=Se[0],this.selectedMultipleRegion=[Re[0]],this.selectedMultipleDepartemental=[Se[0]],this.allDepartemental.sort((function(e,t){return e.codeTypeCarte.localeCompare(t.codeTypeCarte)})),this.allRegion.sort((function(e,t){return e.codeTypeCarte.localeCompare(t.codeTypeCarte)})),this.initializeGlobalGraphics(),this.loadData()}return _createClass(e,[{key:"updateBarGap",value:function(e,t){var a=this;switch(t){case"gap":this.selectedGap=e,this.allGraphics.forEach((function(e){e.layout.bargap=a.selectedGap}));break;case"gapGroup":this.selectedGapGroup=e,this.allGraphics.forEach((function(e){e.layout.bargroupgap=a.selectedGapGroup}))}}},{key:"updateGraphAfterGranularityChange",value:function(){this.updateFiltredData()}},{key:"updateGraphicType",value:function(e){var t=this;this.selectedPlotType=e,this.allGraphics.forEach((function(e){e.data.forEach((function(e){e.type=t.selectedPlotType.toLowerCase()}))}))}},{key:"updateBarSubmod",value:function(e){var t=this;this.selectedBarSubmod=e,this.allGraphics.forEach((function(e){e.layout.barmode=t.selectedBarSubmod.toLowerCase()}))}},{key:"updateScatterSubmod",value:function(e){var t=this;this.selectedScatterSubmod="";var a=1;e.forEach((function(n){t.selectedScatterSubmod+=n.toLowerCase(),a<e.length&&(t.selectedScatterSubmod+="+"),a++})),this.allGraphics.forEach((function(e){e.data.forEach((function(e){e.mode=t.selectedScatterSubmod}))}))}},{key:"updateNumberOfGraphique",value:function(e){this.selectedSpecificGraphicsList=e,this.redrawSpecificGraphicsList()}},{key:"redrawSpecificGraphicsList",value:function(){var e=this;this.deleteAllGraphics(),this.selectedSpecificGraphicsList.forEach((function(t){e.addGraphics("Graphique "+t,[],[],t)})),Object(b.h)(),this.updateFiltredData()}},{key:"initializeGlobalGraphics",value:function(){this.deleteAllGraphics(),this.addGraphics("Graphique Global",[],[],f.a.GLOBAL),Object(b.h)()}},{key:"addGraphics",value:function(e,t,a,n){var i=[];i.push({x:t,y:a,type:this.selectedPlotType,mode:this.selectedScatterSubmod});var r={data:i,config:{responsive:!0},layout:{title:e,autosize:!0,bargap:this.selectedGap,bargroupgap:this.selectedGapGroup,barmode:this.selectedBarSubmod.toLowerCase()},typeGraphic:n};this.allGraphics.push(r)}},{key:"onResizeEnd",value:function(e){ct=e.rectangle.width,this.widthSidebar=e.rectangle.width,Object(b.h)()}},{key:"validate",value:function(e){return!(e.rectangle.width&&e.rectangle.width<300)}},{key:"updateDateContener",value:function(e){this.uniqueDate=e,this.updateFiltredData()}},{key:"updateGraphiqueContener",value:function(e){this.uniqueGraphique=e,this.uniqueGraphique?(this.initializeGlobalGraphics(),this.updateFiltredData()):this.selectedSpecificGraphicsList.length?this.redrawSpecificGraphicsList():this.deleteAllGraphics(),this.updateFiltredData()}},{key:"updateDateCurrentMin",value:function(e){this.selectedDateMin=e,this.updateFiltredData()}},{key:"updateDateCurrentMax",value:function(e){this.selectedDateMax=e,this.updateFiltredData()}},{key:"updateDate",value:function(e){this.currentDate=e,this.updateFiltredData()}},{key:"updateFiltredData",value:function(){var e=this;switch(this.cleanAllDataGraph(),this.currentGranulariteCarte){case p.PAYS:this.filtredData.forEach(this.uniqueDate?function(t){t.getCodeTypeCarte()===e.selectedUniqueCountry.codeTypeCarte&&Object(b.j)(t.getDate(),e.currentDate)&&e.addRow(t)}:function(t){t.getCodeTypeCarte()===e.selectedUniqueCountry.codeTypeCarte&&Object(b.i)(t.getDate(),e.selectedDateMin,e.selectedDateMax)&&e.addRow(t)});break;case p.REGION:this.filtredData.forEach(this.uniqueDate?this.uniqueGraphique?function(t){e.selectedUniqueRegion.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.j)(t.getDate(),e.currentDate)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}:function(t){e.selectedMultipleRegion.forEach((function(a){a.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.j)(t.getDate(),e.currentDate)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}))}:this.uniqueGraphique?function(t){e.selectedUniqueRegion.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.i)(t.getDate(),e.selectedDateMin,e.selectedDateMax)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}:function(t){e.selectedMultipleRegion.forEach((function(a){a.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.i)(t.getDate(),e.selectedDateMin,e.selectedDateMax)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}))});break;case p.DEPARTEMENT:this.filtredData.forEach(this.uniqueDate?this.uniqueGraphique?function(t){e.selectedUniqueDepartemental.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.j)(t.getDate(),e.currentDate)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}:function(t){e.selectedMultipleDepartemental.forEach((function(a){a.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.j)(t.getDate(),e.currentDate)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}))}:this.uniqueGraphique?function(t){e.selectedUniqueDepartemental.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.i)(t.getDate(),e.selectedDateMin,e.selectedDateMax)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}:function(t){e.selectedMultipleDepartemental.forEach((function(a){a.codeTypeCarte===t.getCodeTypeCarte()&&Object(b.i)(t.getDate(),e.selectedDateMin,e.selectedDateMax)&&(e.uniqueGraphique?e.addRow(t):e.addRowMultipleDate(t))}))})}}},{key:"addRowMultipleDate",value:function(e){var t=this,a=e.getDate().getDate()+"-"+e.getDate().getMonth()+"-"+e.getDate().getFullYear();this.allGraphics.forEach((function(n){switch(n.data.length,n.typeGraphic){case f.a.ACTIVE:if(0===n.data.length)n.data.push({x:[a],y:[e.getActif()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var i=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||i||(i=!0,t.x.push(a),t.y.push(e.getActif()))})),i||n.data.push({x:[a],y:[e.getActif()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.CONFIRMED:if(0===n.data.length)n.data.push({x:[a],y:[e.getCasConfirme()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var r=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||r||(r=!0,t.x.push(a),t.y.push(e.getCasConfirme()))})),r||n.data.push({x:[a],y:[e.getCasConfirme()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.DEATH:if(0===n.data.length)n.data.push({x:[a],y:[e.getDeces()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var o=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||o||(o=!0,t.x.push(a),t.y.push(e.getDeces()))})),o||n.data.push({x:[a],y:[e.getDeces()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.HOSPITALIZED:if(0===n.data.length)n.data.push({x:[a],y:[e.getHospitalise()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var c=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||c||(c=!0,t.x.push(a),t.y.push(e.getHospitalise()))})),c||n.data.push({x:[a],y:[e.getHospitalise()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.REANIMATED:if(0===n.data.length)n.data.push({x:[a],y:[e.getReanimation()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var l=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||l||(l=!0,t.x.push(a),t.y.push(e.getReanimation()))})),l||n.data.push({x:[a],y:[e.getReanimation()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.RECOVERED:if(0===n.data.length)n.data.push({x:[a],y:[e.getGueris()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var s=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||s||(s=!0,t.x.push(a),t.y.push(e.getGueris()))})),s||n.data.push({x:[a],y:[e.getGueris()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.MORTALITY_RATE:if(0===n.data.length)n.data.push({x:[a],y:[e.getMortalityRate()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var d=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||d||(d=!0,t.x.push(a),t.y.push(e.getMortalityRate()))})),d||n.data.push({x:[a],y:[e.getMortalityRate()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}break;case f.a.RECOVERY_RATE:if(0===n.data.length)n.data.push({x:[a],y:[e.getRecoveryRate()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod});else{var u=!1;n.data.forEach((function(t){t.name!==e.getLibeleTypeCarte()||u||(u=!0,t.x.push(a),t.y.push(e.getRecoveryRate()))})),u||n.data.push({x:[a],y:[e.getRecoveryRate()],name:e.getLibeleTypeCarte(),type:t.selectedPlotType.toLowerCase(),legendgroup:e.getLibeleTypeCarte(),showlegend:!0,mode:t.selectedScatterSubmod})}}}))}},{key:"loadData",value:function(){var e=this;this.http.get(b.a,{responseType:"text"}).subscribe((function(t){e.parseXmlFile(t)}))}},{key:"parseXmlFile",value:function(e){var t=this;e.split("\n").forEach((function(e){if(e.length&&""!==e){var a=e.split(",");0===t.nbEntree||(t.allData.push(new ge(new Date(a[0]),p[a[1].toUpperCase()],a[2],a[3],Number(a[4]),Number(a[5]),Number(a[6]),Number(a[7]),Number(a[8]),Number(a[9]),Number(a[10]),Number(a[11]))),void 0===t.maxDate&&(t.maxDate=new Date(a[0])),void 0===t.minDate&&(t.minDate=new Date(a[0])),new Date(a[0]).getTime()>t.maxDate.getTime()&&(t.maxDate=new Date(a[0])),new Date(a[0]).getTime()<t.minDate.getTime()&&(t.minDate=new Date(a[0]))),t.nbEntree++}})),this.selectedDateMax=new Date(this.maxDate);var a=new Date(this.selectedDateMax);a.setDate(a.getDate()-1),this.selectedDateMin=a,this.currentDate=new Date(this.maxDate),this.filtredData=he(this.allData),this.updateFiltredData()}},{key:"addRow",value:function(e){var t=this,a=e.getDate().getDate()+"-"+e.getDate().getMonth()+"-"+e.getDate().getFullYear();this.allGraphics.forEach((function(n){var i;switch(i=!(n.data.length>0),n.typeGraphic){case f.a.GLOBAL:0===n.data.length?(n.data.push({x:[a],y:[e.getDeces()],type:t.selectedPlotType.toLowerCase(),name:ve.a.DEATH,marker:{color:"red"},legendgroup:"D\xe9c\xe9s",showlegend:i,mode:t.selectedScatterSubmod}),n.data.push({x:[a],y:[e.getCasConfirme()],type:t.selectedPlotType.toLowerCase(),name:ve.a.CONFIRMED,marker:{color:"grey"},legendgroup:"Confirm\xe9s",showlegend:i,mode:t.selectedScatterSubmod}),n.data.push({x:[a],y:[e.getReanimation()],type:t.selectedPlotType.toLowerCase(),name:ve.a.REANIMATED,marker:{color:"orange"},legendgroup:"R\xe9anim\xe9s",showlegend:i,mode:t.selectedScatterSubmod}),n.data.push({x:[a],y:[e.getHospitalise()],type:t.selectedPlotType.toLowerCase(),name:ve.a.HOSPITALIZED,marker:{color:"yellow"},legendgroup:"Hospitalis\xe9s",showlegend:i,mode:t.selectedScatterSubmod}),n.data.push({x:[a],y:[e.getGueris()],type:t.selectedPlotType.toLowerCase(),name:ve.a.RECOVERED,marker:{color:"green"},legendgroup:"Gu\xe9rris",showlegend:i,mode:t.selectedScatterSubmod}),n.data.push({x:[a],y:[e.getActif()],type:t.selectedPlotType.toLowerCase(),name:ve.a.ACTIVE,marker:{color:"blue"},legendgroup:"Actifs",showlegend:i,mode:t.selectedScatterSubmod})):n.data.forEach((function(t){switch(t.name){case ve.a.ACTIVE:t.x.push(a),t.y.push(e.getActif());break;case ve.a.DEATH:t.x.push(a),t.y.push(e.getDeces());break;case ve.a.REANIMATED:t.x.push(a),t.y.push(e.getReanimation());break;case ve.a.RECOVERED:t.x.push(a),t.y.push(e.getGueris());break;case ve.a.HOSPITALIZED:t.x.push(a),t.y.push(e.getHospitalise());break;case ve.a.CONFIRMED:t.x.push(a),t.y.push(e.getCasConfirme())}}));break;case f.a.ACTIVE:n.data.push({x:[a],y:[e.getActif()],name:ve.a.ACTIVE,type:t.selectedPlotType.toLowerCase(),marker:{color:"blue"},legendgroup:"Actifs",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.CONFIRMED:n.data.push({x:[a],y:[e.getCasConfirme()],name:ve.a.CONFIRMED,type:t.selectedPlotType.toLowerCase(),marker:{color:"grey"},legendgroup:"Confirm\xe9s",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.DEATH:n.data.push({x:[a],y:[e.getDeces()],type:t.selectedPlotType.toLowerCase(),name:ve.a.DEATH,marker:{color:"red"},legendgroup:"D\xe9c\xe9s",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.HOSPITALIZED:n.data.push({x:[a],y:[e.getHospitalise()],name:ve.a.HOSPITALIZED,type:t.selectedPlotType.toLowerCase(),marker:{color:"yellow"},legendgroup:"Hospitalis\xe9s",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.REANIMATED:n.data.push({x:[a],y:[e.getReanimation()],name:ve.a.REANIMATED,type:t.selectedPlotType.toLowerCase(),marker:{color:"orange"},legendgroup:"R\xe9anim\xe9s",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.RECOVERED:n.data.push({x:[a],y:[e.getGueris()],name:ve.a.RECOVERED,type:t.selectedPlotType.toLowerCase(),marker:{color:"green"},legendgroup:"Gu\xe9rris",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.MORTALITY_RATE:n.data.push({x:[a],y:[e.getMortalityRate()],name:ve.a.RECOVERED,type:t.selectedPlotType.toLowerCase(),marker:{color:"purple"},legendgroup:"Taux de mortalit\xe9",showlegend:i,mode:t.selectedScatterSubmod});break;case f.a.RECOVERY_RATE:n.data.push({x:[a],y:[e.getRecoveryRate()],name:ve.a.RECOVERED,type:t.selectedPlotType.toLowerCase(),marker:{color:"pink"},legendgroup:"Taux de soign\xe9s",showlegend:i,mode:t.selectedScatterSubmod})}}))}},{key:"toggleSidebar",value:function(){this.isOpenSidebar=!this.isOpenSidebar,this.widthSidebar=this.isOpenSidebar?ct:30,Object(b.h)()}},{key:"cleanAllDataGraph",value:function(){this.allGraphics.forEach((function(e){e.data=[]}))}},{key:"deleteAllGraphics",value:function(){this.allGraphics=[]}},{key:"ngOnInit",value:function(){}}]),e}(),it.\u0275fac=function(e){return new(e||it)(r.Nb(g.a))},it.\u0275cmp=r.Hb({type:it,selectors:[["app-graphique"]],decls:22,vars:11,consts:[["fxFlexFill","","fxLayout","row","fxLayoutAlign","center",1,"mainContener"],["mwlResizable","","resizeCursorPrecision","5",3,"enableGhostResize","resizeEdges","validateResize","resizeEnd"],["fxFlex","","fxLayout","row","fxLayoutAlign","space-between"],["fxFlex","","fxLayout","column","fxLayoutGap","20px","class","scrollable",4,"ngIf"],["fxLayout","row","fxFlex","30px"],["fxFlex","","fxLayoutAlign","center"],["fxFlex","","mat-button","",1,"buttonSidebarClose","icon",3,"click"],[4,"ngIf"],["fxFlex","2px",1,"dividerSidebar"],["fxFlex",""],["fxLayout","column","fxFlex","",4,"ngFor","ngForOf"],[1,"floatingButtonContener"],["direction","up","animationMode","fling"],["spin","true"],["matTooltipPosition","left","mat-fab","","matTooltip","Param\xe8tres"],[1,"spin360"],["matTooltipPosition","left","matTooltip","Ouvrir menu param\xe8tres","mat-mini-fab","",3,"click"],["fxFlex","","fxLayout","column","fxLayoutGap","20px",1,"scrollable"],["fxLayout","row","fxLayoutAlign","center"],["fxLayout","column"],[1,"contentTemplate"],[3,"ngModel","change","ngModelChange"],["fxLayout","column","fxLayoutGap","5px"],[3,"value",4,"ngFor","ngForOf"],[3,"checked","change"],["class","contentTemplate",4,"ngIf"],["fxLayout","column","fxLayoutGap","5px",1,"contentTemplate"],[1,"dateInput"],["multiple","",3,"disabled","selectionChange"],["class","contentTemplate","fxLayout","column","fxLayoutGap","10px",4,"ngIf"],[3,"value"],[3,"value","valueChange"],["multiple","",3,"value","selectionChange","valueChange"],[3,"value","selectionChange","valueChange"],["matInput","",3,"value","min","max","matDatepicker","dateChange"],["matSuffix","",3,"for"],["picker",""],["pickerCurrentMin",""],["pickerCurrentMax",""],["multiple","",3,"ngModel","selectionChange"],["fxLayout","column","fxLayoutGap","10px",1,"contentTemplate"],["fxLayout","row","fxLayoutAlign","space-between center"],["max","1","min","0","step","0.1","thumbLabel","true",3,"ngModel","change","ngModelChange"],["fxLayout","column","fxFlex",""],["fxFlex","",3,"useResizeHandler","data","config","layout"]],template:function(e,t){1&e&&(r.Sb(0,"div",0),r.Sb(1,"div",1),r.ac("resizeEnd",(function(e){return t.onResizeEnd(e)})),r.Sb(2,"div",2),r.Ac(3,We,54,15,"div",3),r.Sb(4,"div",4),r.Sb(5,"div",5),r.Sb(6,"button",6),r.ac("click",(function(){return t.toggleSidebar()})),r.Ac(7,et,2,0,"mat-icon",7),r.Ac(8,tt,2,0,"mat-icon",7),r.Rb(),r.Rb(),r.Ob(9,"div",8),r.Rb(),r.Rb(),r.Rb(),r.Sb(10,"div",9),r.Ac(11,nt,2,7,"div",10),r.Rb(),r.Rb(),r.Sb(12,"div",11),r.Sb(13,"floating-button",12),r.Sb(14,"floating-button-trigger",13),r.Sb(15,"button",14),r.Sb(16,"mat-icon",15),r.Bc(17,"menu"),r.Rb(),r.Rb(),r.Rb(),r.Sb(18,"floating-button-action"),r.Sb(19,"button",16),r.ac("click",(function(){return t.toggleSidebar()})),r.Sb(20,"mat-icon"),r.Bc(21,"build"),r.Rb(),r.Rb(),r.Rb(),r.Rb(),r.Rb()),2&e&&(r.Bb(1),r.zc("width",t.widthSidebar+"px"),r.jc("enableGhostResize",!0)("resizeEdges",r.lc(9,ot,t.isOpenSidebar))("validateResize",t.validate),r.Bb(2),r.jc("ngIf",t.isOpenSidebar),r.Bb(4),r.jc("ngIf",t.isOpenSidebar),r.Bb(1),r.jc("ngIf",!t.isOpenSidebar),r.Bb(3),r.jc("ngForOf",t.allGraphics))},directives:[o.f,o.d,o.c,h.a,o.b,n.k,C.a,n.j,Ee.a,Le.a,xe.a,M.a,Me.a,o.e,v.b,D.g,D.i,m.a,Be.a,R.b,R.e,S.a,v.a,x.k,E.b,L.b,L.d,R.f,L.a,Ae.a,Ie.a],styles:[".dividerSidebar[_ngcontent-%COMP%]{background-color:#323233}.icon[_ngcontent-%COMP%]:hover{color:#ec407a}.icon[_ngcontent-%COMP%]{color:#f48fb1}mwlResizable[_ngcontent-%COMP%]{box-sizing:border-box}.floatingButtonContener[_ngcontent-%COMP%]{position:fixed;bottom:40px;right:20px}.buttonSidebarClose[_ngcontent-%COMP%]{padding:0;width:20px;min-width:0}.contentTemplate[_ngcontent-%COMP%]{padding-left:10px}.titleTemplate[_ngcontent-%COMP%]{padding-left:5px}.dateInput[_ngcontent-%COMP%]{width:150px}.scrollable[_ngcontent-%COMP%]{overflow:auto}"]}),it)}]}],st=((rt=function e(){_classCallCheck(this,e)}).\u0275mod=r.Lb({type:rt}),rt.\u0275inj=r.Kb({factory:function(e){return new(e||rt)},imports:[[i.e.forChild(lt)],i.e]}),rt),dt=a("95T3"),ut=a("YUcS"),pt=a("j+7c"),bt=a("XhcP"),ft=a("bSwM"),yt=a("Xa2L");a.d(t,"FranceModule",(function(){return ht})),Ie.b.plotlyjs=dt;var gt,ht=((gt=function e(){_classCallCheck(this,e)}).\u0275mod=r.Lb({type:gt}),gt.\u0275inj=r.Kb({factory:function(e){return new(e||gt)},providers:[L.c],imports:[[n.c,st,Ie.b,c.c,C.b,M.b,ut.a,pt.a,v.c,D.c,m.b,bt.a,h.b,xe.b,ft.a,L.c,E.c,R.d,x.i,Be.b,S.b,D.j,Ae.b,yt.a,T.c]]}),gt)}}]);