(function(a){function b(c,d,e,f,h,k,m){b.v.Init.call(this,c.j(),"none"==d?q:d,a.e.Ze,e,f,h,k,q,l,m);this.Di=c}function c(a){this.Init(a)}function d(a,b){this.Init(a,b)}function e(a,b,c,d,f,h,k,m,G,w){e.v.Init.call(this,a.j(),b,c,d,f,q,h,k,m,G,w);this.Di=a}function f(){this.Init({alta:f.fi})}function h(a){this.Init(a.j(),a.dispatchEvent,a);this.Di=a}function k(a){this.Di=a}a.sh=function(a,b,c){this.Init(a,b,c)};a.k.A(a.sh,a.Ae);a.sh.newInstance=function(b,c,d){return new a.sh(b,c,d)};a.sh.prototype.Init=
function(b,d,e){a.sh.v.Init.call(this,b,d,e);this.L=new h(this);this.L.hg(this);a.u.Va()||this.L.ps(new c(this.L));this.eh=new f;this.Wb=[]};a.sh.prototype.FI=function(b,c){if(!b||!c){var d=m.uo(this,b,c);this.Uka=d;b||(b=d.hq?d.xLa*d.y$:0);c||(c=d.hq?d.cQa*d.Oba:0)}return new a.Zj(b,c)};a.sh.prototype.wa=function(b,c,d){this.hj=this.za;var e=this.Ju,f=this.Cb?this.Cb:0,h=this.Ob?this.Ob:0;this.L.je();this.Wb=[];this.Ju=[];this.Uka=q;this.Op&&(this.za.removeChild(this.Op),this.Op=q);this.Sb&&(this.Nx=
l,this.Sb.stop());this.Gf(b);var k=this.j();if(!c&&!d){if(k.Gb.style.display="block",c=this.FI(),a.H.j2(k,c.a,c.b),d=a.H.Fqa(k),c.a==d.a&&c.b!=d.b?(this.Ob=d.b,c=this.FI(q,this.Ob),a.H.j2(k,c.a,this.Ob),this.Cb=a.H.Fqa(k).a):c.a!=d.a&&c.b==d.b?(this.Cb=d.a,c=this.FI(this.Cb,q),a.H.j2(k,this.Cb,c.b),this.Ob=a.H.Fqa(k).b):(this.Cb=d.a,this.Ob=d.b),this.Cb!=c.a||this.Ob!=c.b)this.Uka=q}else this.Cb=c,this.Ob=d;this.za=new a.ea(k);this.q(this.za);m.wa(this,this.za,new a.W(0,0,this.Cb,this.Ob),this.Uka);
this.hj?"none"!=this.U.animationOnDataChange&&b&&(b=new a.zp(k,q),b.Xp(e,this.Ju),this.Sb=b.cv()):this.Sb=this.T3a();this.Sb?(a.H.j2(k,Math.max(f,this.Cb),Math.max(h,this.Ob)),this.L.Xj(this),this.Op&&this.za.removeChild(this.Op),this.Sb.Of(this.E8,this),this.Sb.play()):this.E8()};a.sh.prototype.Gf=function(b){b?this.U=this.eh.Pm(b):this.U||(this.U=this.YD());a.u.Xi()||(this.U.animationOnDisplay="none",this.U.animationOnDataChange="none");b=this.U.selectionMode;this.$c="single"==b?new a.Tc(a.Tc.Az):
"multiple"==b?new a.Tc(a.Tc.zz):q;this.L.kB(this.$c)};a.sh.prototype.E8=function(){this.hj&&(this.removeChild(this.hj),this.hj.oa(),this.hj=q);this.Sb&&(this.Sb=q,this.L.hg(this),this.Op&&this.za.q(this.Op));a.H.j2(this.j(),this.Cb,this.Ob);for(var b,c=0;c<this.Wb.length&&!(b=this.Wb[c],"none"!=b.Cc());c++);this.L.os(b);this.$c&&this.$c.Gt(this.U.selection,this.Wb);a.Rg.Me(this.U.highlightedCategories,this.Wb,"any"==this.U.highlightMatch);this.wr();this.Nx||this.CB();this.Nx=q};a.sh.prototype.Ua=
N("L");a.sh.prototype.Fsa=I("Wb");a.sh.prototype.uk=N("Wb");a.sh.prototype.uib=function(a){this.Ju.push(a)};a.sh.prototype.tib=I("Op");a.sh.prototype.Gfb=function(){for(var a=0,b=0;b<this.Wb.length;b++)a+=this.Wb[b].getCount();return a};a.sh.prototype.pb=function(){return a.Ra.cs(this.U.animationDuration)/1E3};a.sh.prototype.T3a=function(){var b=this.U.animationOnDisplay,c=this.pb(),d=this.j(),e=new a.W(0,0,this.Cb,this.Ob);if(a.jc.isSupported(b))return a.jc.mD(d,b,this.za,e,c);var f=[];if("popIn"==
b)for(b=0;b<this.Ju.length;b++){var h=this.Ju[b];f.push(new a.ws(d,h,l,c))}else if("none"!=b){for(b=0;b<this.Ju.length;b++){var h=this.Ju[b],k=new a.Pd(d,h,c),B,G;m.Qb(this)?(B=m.Jra(this)?this.Cb:0,G=h.Bj(),h.ms(B),k.ga.M(a.F.T,h,h.Bj,h.ms,G)):(B=m.Ira(this)?this.Ob:0,G=h.Cj(),h.ns(B),k.ga.M(a.F.T,h,h.Cj,h.ns,G));f.push(k)}f.push(a.jc.mD(d,a.jc.nB,this.za,e,c))}return 0<f.length?new a.Eh(d,f):q};a.sh.prototype.oa=function(){this.L&&(this.L.Xj(this),this.L.oa(),this.L=q);a.sh.v.oa.call(this)};a.sh.prototype.Me=
function(b){var c=this.B();c.highlightedCategories=a.Ec.Ga(b);a.Rg.Me(b,this.uk(),"any"==c.highlightMatch)};a.sh.prototype.select=function(b){this.B().selection=a.Ec.Ga(b);this.$c&&this.$c.Gt(b,this.uk())};a.sh.prototype.xm=function(){return a.G.Ng(this.B(),"componentName",a.G.La,"PICTOCHART")};a.sh.prototype.mi=function(){this.BBa||(this.BBa=new k(this));return this.BBa};a.k.A(k,a.Wd);k.prototype.Ho=function(a){return(a=this.Di.Ua().jb(a))&&a instanceof d?"item["+this.Di.uk().indexOf(a)+"]":q};k.prototype.oi=
function(b){if(b==a.Wd.JB)return this.bE(this.Di);var c=b.indexOf("[");return 0<c&&"item"===b.substring(0,c)&&(b=parseInt(b.substring(c+1,b.length-1)),b=this.Di.uk()[b])?b.nb():q};k.prototype.getItem=function(a){if(a=this.Di.uk()[a]){var b={};b.color=a.ll();b.tooltip=a.de();b.id=a.getId();b.name=a.getName();b.count=a.getCount();b.selected=a.wb();return b}return q};k.prototype.gU=function(){return this.Di.uk().length};a.k.A(h,a.L);h.prototype.Cp=function(b,c,d){b=this.Di.B();"none"!=b.hoverBehavior&&
(c=c.we?c.we():[],b.highlightedCategories=d?c.slice():q,d=a.Ya.LG(b.highlightedCategories,d),c=a.Ra.cs(b.hoverBehaviorDelay),this.GH.Df(d,this.Di.uk(),c,"any"==b.highlightMatch))};h.prototype.tQ=function(a){(a=this.jb(a.target))&&(!a.qb||!a.qb())&&this.Zw(a)};h.prototype.lE=function(a){(a=this.jb(a.target))&&a.qb&&a.qb()&&this.Zw(a)};h.prototype.zW=function(a){(a=this.jb(a.target))&&(!a.qb||!a.qb())&&this.Zw(a)};h.prototype.Hv=function(a){(a=this.jb(a.target))&&(!a.qb||!a.qb())&&this.Zw(a)};h.prototype.sH=
function(a){var b=this.jb(a.target);b&&(b.qb&&b.qb())&&(a.preventDefault(),a.stopPropagation(),this.Zw(b))};h.prototype.Zw=function(b){b instanceof d&&b.Ej()&&this.Ak(a.Ya.wba(b.getId()))};a.k.A(f,a.ab);f.fi={animationOnDisplay:"none",animationOnDataChange:"none",animationDuration:750,drilling:"off",hiddenCategories:[],highlightedCategories:[],highlightMatch:"all",hoverBehavior:"none",hoverBehaviorDelay:200,layout:"horizontal",layoutOrigin:"topStart",selection:[],selectionMode:"none",_defaultColor:"#a6acb1",
_noneShapeColor:"rgba(255,255,255,0)",_defaultSize:32,_defaultShape:"rectangle",_gapRatio:0.25,_textStyle:new a.e(a.ab.h3+"color: #252525;"),_statusMessageStyle:new a.e(a.ab.h3+"color: #252525;"),_tooltipStyle:new a.e("border-collapse: separate; border-spacing: 1px"),_tooltipLabelStyle:new a.e("color: #737373; padding: 0px 2px"),_tooltipValueStyle:new a.e("color: #333333; padding: 0px 2px")};a.k.A(e,a.wf);e.prototype.nh=function(b,c){var d=new a.Pd(this.j(),this,0.75*this.Di.pb()),e=d.ga,f=this.ao();
this.Vp(c.ao());e.M(a.F.dg,this,this.ao,this.Vp,f);c.Q(0);b.add(d,1)};e.prototype.Vj=function(b){b.add(new a.Gj(this.j(),this,0.5*this.Di.pb()),0)};e.prototype.Ri=function(b){this.Q(0);b.add(new a.Ah(this.j(),this,0.5*this.Di.pb()),2)};e.prototype.ao=function(){return[this.Bj(),this.Cj(),this.getWidth(),this.getHeight()]};e.prototype.Vp=function(a){this.ms(a[0]);this.ns(a[1]);this.$a(a[2]);this.vb(a[3])};a.k.A(d,a.ea);d.Tz=0;d.prototype.Init=function(b,c){d.v.Init.call(this,b.j(),q,c.id);this.Di=
b;this.ho=c;this.qc=c.id!=q?c.id:c.name!=q?c.name:"_defaultId"+d.Tz;d.Tz++;this.QM="none"==c.shape;this.fd=this.dl=s;this.bGa=new a.O(0,0);(this.qb()||this.Ej())&&this.setCursor("pointer");b.Ua().mb(this,this)};d.prototype.HMa=function(){var a=this.ho.columnSpan;return a!=q&&0<=a?a:1};d.prototype.eOa=function(){var a=this.ho.rowSpan;return a!=q&&0<=a?a:1};d.prototype.getCount=function(){var a=this.ho.count;return a!=q?Math.max(a,0):1};d.prototype.Cc=function(){return this.ho.shape||this.Di.B()._defaultShape};
d.prototype.zc=function(){return this.QM?this.Di.B()._noneShapeColor:this.ho.color||this.Di.B()._defaultColor};d.prototype.Zp=function(){return this.ho.borderColor};d.prototype.zj=function(){return this.ho.borderWidth};d.prototype.c1=function(){return this.ho.source};d.prototype.Xqa=function(){return this.ho.sourceSelected};d.prototype.Vqa=function(){return this.ho.sourceHover};d.prototype.Wqa=function(){return this.ho.sourceHoverSelected};d.prototype.getName=function(){return this.ho.name};d.prototype.getId=
N("qc");d.prototype.de=function(){return this.ho.shortDesc};d.prototype.Ej=function(){if(this.QM)return s;var a=this.ho.drilling;return a&&"inherit"!=a?"on"==a:"on"==this.Di.B().drilling};d.prototype.xk=function(){return this.qb()&&this.Ej()&&!this.QM};d.prototype.Pkb=function(){this.Nf("img");this.Wu()};d.prototype.ug=function(){if(this.QM)return"";var b=this.Di.B(),c=this.Di.B().tooltip;if(c){var b=this.Di.j().Zf(),d={id:this.getId(),name:this.getName(),count:this.getCount(),color:this.zc()};return b.Mw(c,
d)}if(this.de()!=q)return this.de();c="";(d=this.getName())&&(c=a.Pe.WT("td",b._tooltipLabelStyle)+d+"\x3c/td\x3e");d=a.u.aa(this.Di.j());b._tooltipLabelStyle.qa(a.e.tE,d?"left":"right");b._tooltipValueStyle.qa(a.e.tE,d?"right":"left");return a.Pe.WT("table",b._tooltipStyle)+"\x3ctr\x3e"+c+a.Pe.WT("td",b._tooltipValueStyle)+this.Zja()+"\x3c/td\x3e\x3c/tr\x3e\x3c/table\x3e"};d.prototype.ll=function(){return this.zc()};d.prototype.Zja=function(){return a.G.Ng(this.Di.B(),"labelCountWithTotal",a.G.La,
"COUNT_WITH_TOTAL",[this.getCount(),this.Di.Gfb()])};d.prototype.qb=function(){return"none"!=this.Di.B().selectionMode&&!this.QM};d.prototype.wb=N("dl");d.prototype.uc=function(a){this.dl=a;this.Wu();for(var c=0;c<this.Hb();c++){var d=this.bb(c);(d instanceof b||d instanceof e)&&d.uc(a)}};d.prototype.Ad=function(){for(var a=0;a<this.Hb();a++){var c=this.bb(a);(c instanceof b||c instanceof e)&&c.Ad()}};d.prototype.ad=function(){for(var a=0;a<this.Hb();a++){var c=this.bb(a);(c instanceof b||c instanceof
e)&&c.ad()}};d.prototype.We=function(){return[this]};d.prototype.Fd=function(){var b=[],c=this.Di.B();this.qb()&&b.push(a.G.Ng(c,this.wb()?"stateSelected":"stateUnselected",a.G.La,this.wb()?"STATE_SELECTED":"STATE_UNSELECTED"));this.Ej()&&b.push(a.G.Ng(c,"stateDrillable",a.G.La,"STATE_DRILLABLE"));c=this.getName();c=this.de()!=q?this.de():c==q?this.Zja():a.G.pa(a.G.La,"COLON_SEP_LIST",[c,this.Zja()]);return a.ja.sk(c,b)};d.prototype.Wu=function(){a.u.Fi()||this.zd("label",this.Fd())};d.prototype.we=
function(){return this.ho.categories||[this.getId()]};d.prototype.Zd=function(b){var d=this.Di.Ua().Db;return b.type==a.ra.Ee||d.pv(b)?this:d.Yi(b)?c.Zd(this.Di,this,b):q};d.prototype.uf=function(a){return this.X(a)};d.prototype.rm=function(){return this.nb()};d.prototype.Pf=function(){this.QM||(this.fd=l,this.Ad())};d.prototype.Nd=function(){this.QM||(this.fd=s,this.ad())};d.prototype.Qd=N("fd");d.prototype.Ijb=I("bGa");d.prototype.pqa=N("bGa");a.k.A(c,a.Db);c.prototype.AD=function(a){return this.Yi(a)&&
!a.ctrlKey};c.prototype.pv=function(b){return b.keyCode==a.I.xi&&b.ctrlKey};c.Zd=function(b,d,e,f){var h=b.uk();f||(f=d);if("none"==d.Cc()&&d!=f){var k=a.ha.rb(h,d);if(0==k||k==h.length-1)return f}var y=m.Jra(b),B=m.Ira(b),G=m.Qb(b),k=d,y=e.keyCode==a.I.ag&&y||e.keyCode==a.I.bg&&!y||e.keyCode==a.I.Rh&&B||e.keyCode==a.I.lg&&!B,G=e.keyCode==a.I.ag&&G||e.keyCode==a.I.bg&&G||e.keyCode==a.I.Rh&&!G||e.keyCode==a.I.lg&&!G,y=a.ha.rb(h,d)+(y?1:-1);G?k=a.Db.Zd(d,e,h):y<h.length&&0<=y&&(k=h[y]);"none"==k.Cc()&&
(k=k!=d?c.Zd(b,k,e,f):f);return k};c.prototype.yk=function(b){var d=this.Pa.bf();return d&&b.keyCode==a.I.wi?(this.Pa.Zw(d),a.L.rc(b),d):c.v.yk.call(this,b)};a.k.A(b,a.ta);b.prototype.nh=function(b,c){var d=new a.Pd(this.j(),this,0.75*this.Di.pb()),e=d.ga,f=this.Id();this.la(c.Id().Ga());e.M(a.F.uq,this,this.Id,this.la,f);f=this.ao();this.Vp(c.ao());e.M(a.F.dg,this,this.ao,this.Vp,f);c.Q(0);b.add(d,1)};b.prototype.Vj=function(b){b.add(new a.Gj(this.j(),this,0.5*this.Di.pb()),0)};b.prototype.Ri=function(b){this.Q(0);
b.add(new a.Ah(this.j(),this,0.5*this.Di.pb()),2)};b.prototype.ao=function(){return[this.Bj(),this.Cj(),this.getWidth(),this.getHeight()]};b.prototype.Vp=function(a){this.ms(a[0]);this.ns(a[1]);this.$a(a[2]);this.vb(a[3])};var m={};a.k.A(m,a.k);m.wa=function(c,d,f,h){var k=c.j(),z=new a.na(k,f.x,f.y,f.a,f.b);z.dc();d.q(z);h||(h=m.uo(c,f.a,f.b));if(h.hq){c.Fsa(h.hq);for(var z=c.B()._gapRatio,y=m.Qb(c),B=m.Ira(c),G=m.Jra(c),w=new a.wH,D=0,C=0,E=0,H=0;H<h.hq.length;H++){for(var L=h.hq[H],A=L.HMa(),O=
L.eOa(),W=A*h.y$,Y=O*h.Oba,ma=L.getCount(),ja=0,la=l,ua;0<ma;){if(A!=D||O!=C)E=0;0==E&&(ua=m.VDa(w,A,O,h.xLa,h.cQa,y));if(ua==q)break;var qa=ua.Zoa*h.y$+W/2,oa=ua.Nsa*h.Oba+Y/2,qa=f.x+(G?f.a-qa:qa),oa=f.y+(B?f.b-oa:oa),sa=Math.min(1-E,ma),ca,ha,S,aa;y?(ca=qa-W/2,ha=B?oa+Y*(0.5-sa-E):oa+Y*(E-0.5),S=W,aa=Y*sa):(ca=G?qa+W*(0.5-sa-E):qa+W*(E-0.5),ha=oa-Y/2,S=W*sa,aa=Y);var V;1==sa?(V=L.getId()+"_"+ja,ja++):V=Math.random();if(L.c1())V=new e(c,qa,oa,W,Y,L.c1(),L.Xqa(),L.Vqa(),L.Wqa(),V+"_I");else{var Q=
new a.na(k,ca,ha,S,aa);Q.dc();L.q(Q);V=new b(c,L.Cc(),qa,oa,W-h.y$*z,Y-h.Oba*z,V+"_S");V.lb(L.zc());V.Mb(L.Zp(),q,L.zj());V.hV(L.zc())}1>sa&&(Q=new a.Kd,Q.Le(ca,ha,S,aa),V.De(Q));la&&(L.Ijb(new a.O(qa,oa)),la=s);L.q(V);c.uib(V);ma-=sa;E=(E+sa)%1}d.q(L);L.Pkb();D=A;C=O}}else m.lq(c,d,f)};m.uo=function(b,c,e){var f=b.B(),h=f.items;if(!h)return{};for(var k=a.ha.mO(f.hiddenCategories),y=[],B=0,G=1,w=1,D=0;D<h.length;D++)if(h[D]!=q){var C=new d(b,h[D]);if(!k||!a.ha.HU(k,C.we())){var E=C.HMa(),H=C.eOa();
E>G&&(G=E);H>w&&(w=H);B+=E*H*C.getCount();y.push(C)}}if(0==B)return{};h=f.columnWidth;k=f.rowHeight;if(!c||!e)h||(h=k?k:f._defaultSize),k||(k=h);b=m.Qb(b);D=f.columnCount;f=f.rowCount;!D&&!f&&(c&&e?b?f=m.vR(Math.sqrt(B*e/c),w):D=m.vR(Math.sqrt(B*c/e),G):c?D=Math.max(Math.floor(c/h),1):e?f=Math.max(Math.floor(e/k),1):b?f=m.vR(Math.sqrt(B),w):D=m.vR(Math.sqrt(B),G));D?f||(f=m.vR(B/D,w)):D=m.vR(B/f,G);c&&e&&(h||(h=k?k:Math.min(c/D,e/f)),k||(k=h));return 0>=D||0>=f||0>=h||0>=k?{}:{hq:y,xLa:D,cQa:f,y$:h,
Oba:k}};m.vR=function(a,b){return Math.ceil(a/b)*b};m.VDa=function(a,b,c,d,e,f){if(f)return(a=m.VDa(a,c,b,e,d,s))?{Zoa:a.Nsa,Nsa:a.Zoa}:q;for(f=0;f<e-c+1;f++)for(var h=0;h<d-b+1;h++)if(m.W0a(a,h,f,b,c))return m.g7a(a,h,f,b,c),{Zoa:h,Nsa:f};return q};m.W0a=function(a,b,c,d,e){for(var f=0;f<e;f++)for(var h=0;h<d;h++)if(a.get(b+h,c+f))return s;return l};m.g7a=function(a,b,c,d,e){for(var f=0;f<e;f++)for(var h=0;h<d;h++)a.put(b+h,c+f,l)};m.lq=function(b,c,d){var e=b.B(),f=a.G.Ng(e,"labelNoData",a.G.La,
"NO_DATA");c=a.Ba.lq(c,f,d.Ga(),b.Ua(),e._statusMessageStyle);b.tib(c)};m.Qb=function(a){return"vertical"==a.B().layout};m.Ira=function(a){a=a.B().layoutOrigin;return"bottomStart"==a||"bottomEnd"==a};m.Jra=function(b){var c=b.B().layoutOrigin,c="topEnd"==c||"bottomEnd"==c;return a.u.aa(b.j())?!c:c};a.Ta(a,"PictoChart",a.sh);a.Ta(a.sh,"newInstance",a.sh.newInstance);a.Ta(a.sh.prototype,"destroy",a.sh.prototype.oa);a.Ta(a.sh.prototype,"getAutomation",a.sh.prototype.mi);a.Ta(a.sh.prototype,"highlight",
a.sh.prototype.Me);a.Ta(a.sh.prototype,"render",a.sh.prototype.wa);a.Ta(a.sh.prototype,"select",a.sh.prototype.select);a.Ta(k.prototype,"getDomElementForSubId",k.prototype.oi);a.Ta(k.prototype,"getItem",k.prototype.getItem);a.Ta(k.prototype,"getItemCount",k.prototype.gU)})(dvt);