!function(){function t(t,e){return e>t?-1:t>e?1:t>=e?0:NaN}function e(t){return null===t?NaN:+t}function n(t){return!isNaN(t)}function i(t){return{left:function(e,n,i,r){for(arguments.length<3&&(i=0),arguments.length<4&&(r=e.length);r>i;){var o=i+r>>>1;t(e[o],n)<0?i=o+1:r=o}return i},right:function(e,n,i,r){for(arguments.length<3&&(i=0),arguments.length<4&&(r=e.length);r>i;){var o=i+r>>>1;t(e[o],n)>0?r=o:i=o+1}return i}}}function r(t){return t.length}function o(t,e){for(var n in e)Object.defineProperty(t.prototype,n,{value:e[n],enumerable:!1})}function a(){this._=Object.create(null)}function s(t){return(t+="")===io||t[0]===ro?ro+t:t}function l(t){return(t+="")[0]===ro?t.slice(1):t}function c(t){return s(t)in this._}function u(t){return(t=s(t))in this._&&delete this._[t]}function h(){var t=[];for(var e in this._)t.push(l(e));return t}function p(){var t=0;for(var e in this._)++t;return t}function d(){for(var t in this._)return!1;return!0}function f(){this._=Object.create(null)}function g(t,e,n){return function(){var i=n.apply(e,arguments);return i===e?t:i}}function m(t,e){if(e in t)return e;e=e.charAt(0).toUpperCase()+e.slice(1);for(var n=0,i=oo.length;i>n;++n){var r=oo[n]+e;if(r in t)return r}}function y(){}function v(){}function C(t){function e(){for(var e,i=n,r=-1,o=i.length;++r<o;)(e=i[r].on)&&e.apply(this,arguments);return t}var n=[],i=new a;return e.on=function(e,r){var o,a=i.get(e);return arguments.length<2?a&&a.on:(a&&(a.on=null,n=n.slice(0,o=n.indexOf(a)).concat(n.slice(o+1)),i.remove(e)),r&&n.push(i.set(e,{on:r})),t)},e}function b(){Hr.event.preventDefault()}function x(){for(var t,e=Hr.event;t=e.sourceEvent;)e=t;return e}function L(t){for(var e=new v,n=0,i=arguments.length;++n<i;)e[arguments[n]]=C(e);return e.of=function(n,i){return function(r){try{var o=r.sourceEvent=Hr.event;r.target=t,Hr.event=r,e[r.type].apply(n,i)}finally{Hr.event=o}}},e}function k(t){return so(t,po),t}function w(t){return"function"==typeof t?t:function(){return lo(t,this)}}function _(t){return"function"==typeof t?t:function(){return co(t,this)}}function S(t,e){return t=Hr.ns.qualify(t),null==e?t.local?function(){this.removeAttributeNS(t.space,t.local)}:function(){this.removeAttribute(t)}:"function"==typeof e?t.local?function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}:function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}:t.local?function(){this.setAttributeNS(t.space,t.local,e)}:function(){this.setAttribute(t,e)}}function M(t){return t.trim().replace(/\s+/g," ")}function F(t){return new RegExp("(?:^|\\s+)"+Hr.requote(t)+"(?:\\s+|$)","g")}function E(t){return(t+"").trim().split(/^|\s+/)}function P(t,e){var n=(t=E(t).map(T)).length;return"function"==typeof e?function(){for(var i=-1,r=e.apply(this,arguments);++i<n;)t[i](this,r)}:function(){for(var i=-1;++i<n;)t[i](this,e)}}function T(t){var e=F(t);return function(n,i){if(r=n.classList)return i?r.add(t):r.remove(t);var r=n.getAttribute("class")||"";i?(e.lastIndex=0,e.test(r)||n.setAttribute("class",M(r+" "+t))):n.setAttribute("class",M(r.replace(e," ")))}}function A(t,e,n){return null==e?function(){this.style.removeProperty(t)}:"function"==typeof e?function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,n)}:function(){this.style.setProperty(t,e,n)}}function z(t,e){return null==e?function(){delete this[t]}:"function"==typeof e?function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}:function(){this[t]=e}}function B(t){return"function"==typeof t?t:(t=Hr.ns.qualify(t)).local?function(){return this.ownerDocument.createElementNS(t.space,t.local)}:function(){return this.ownerDocument.createElementNS(this.namespaceURI,t)}}function N(){var t=this.parentNode;t&&t.removeChild(this)}function D(t){return{__data__:t}}function $(t){return function(){return ho(this,t)}}function O(e){return arguments.length||(e=t),function(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}}function U(t,e){for(var n=0,i=t.length;i>n;n++)for(var r,o=t[n],a=0,s=o.length;s>a;a++)(r=o[a])&&e(r,a,n);return t}function I(t){return so(t,go),t}function R(t,e,n){function i(){var e=this[r];e&&(this.removeEventListener(t,e,e.$),delete this[r])}var r="__on"+t,o=t.indexOf("."),a=Y;o>0&&(t=t.slice(0,o));var s=yo.get(t);return s&&(t=s,a=Z),o?e?function(){var o=a(e,jr(arguments));i.call(this),this.addEventListener(t,this[r]=o,o.$=n),o._=e}:i:e?y:function(){var e,n=new RegExp("^__on([^.]+)"+Hr.requote(t)+"$");for(var i in this)if(e=i.match(n)){var r=this[i];this.removeEventListener(e[1],r,r.$),delete this[i]}}}function Y(t,e){return function(n){var i=Hr.event;Hr.event=n,e[0]=this.__data__;try{t.apply(this,e)}finally{Hr.event=i}}}function Z(t,e){var n=Y(t,e);return function(t){var e=this,i=t.relatedTarget;i&&(i===e||8&i.compareDocumentPosition(e))||n.call(e,t)}}function H(){var t=".dragsuppress-"+ ++Co,e="click"+t,n=Hr.select(Wr).on("touchmove"+t,b).on("dragstart"+t,b).on("selectstart"+t,b);if(vo){var i=Vr.style,r=i[vo];i[vo]="none"}return function(o){if(n.on(t,null),vo&&(i[vo]=r),o){var a=function(){n.on(e,null)};n.on(e,function(){b(),a()},!0),setTimeout(a,0)}}}function q(t,e){e.changedTouches&&(e=e.changedTouches[0]);var n=t.ownerSVGElement||t;if(n.createSVGPoint){var i=n.createSVGPoint();if(0>bo&&(Wr.scrollX||Wr.scrollY)){var r=(n=Hr.select("body").append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important"))[0][0].getScreenCTM();bo=!(r.f||r.e),n.remove()}return bo?(i.x=e.pageX,i.y=e.pageY):(i.x=e.clientX,i.y=e.clientY),[(i=i.matrixTransform(t.getScreenCTM().inverse())).x,i.y]}var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}function j(){return Hr.event.changedTouches[0].identifier}function K(){return Hr.event.target}function V(){return Wr}function W(t){return t>0?1:0>t?-1:0}function X(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function G(t){return t>1?0:-1>t?ko:Math.acos(t)}function Q(t){return t>1?So:-1>t?-So:Math.asin(t)}function J(t){return((t=Math.exp(t))+1/t)/2}function tt(t){return(t=Math.sin(t/2))*t}function et(){}function nt(t,e,n){return this instanceof nt?(this.h=+t,this.s=+e,void(this.l=+n)):arguments.length<2?t instanceof nt?new nt(t.h,t.s,t.l):mt(""+t,yt,nt):new nt(t,e,n)}function it(t,e,n){function i(t){return Math.round(255*function(t){return t>360?t-=360:0>t&&(t+=360),60>t?r+(o-r)*t/60:180>t?o:240>t?r+(o-r)*(240-t)/60:r}(t))}var r,o;return t=isNaN(t)?0:(t%=360)<0?t+360:t,e=isNaN(e)?0:0>e?0:e>1?1:e,r=2*(n=0>n?0:n>1?1:n)-(o=.5>=n?n*(1+e):n+e-n*e),new pt(i(t+120),i(t),i(t-120))}function rt(t,e,n){return this instanceof rt?(this.h=+t,this.c=+e,void(this.l=+n)):arguments.length<2?t instanceof rt?new rt(t.h,t.c,t.l):lt(t instanceof at?t.l:(t=vt((t=Hr.rgb(t)).r,t.g,t.b)).l,t.a,t.b):new rt(t,e,n)}function ot(t,e,n){return isNaN(t)&&(t=0),isNaN(e)&&(e=0),new at(n,Math.cos(t*=Mo)*e,Math.sin(t)*e)}function at(t,e,n){return this instanceof at?(this.l=+t,this.a=+e,void(this.b=+n)):arguments.length<2?t instanceof at?new at(t.l,t.a,t.b):t instanceof rt?ot(t.h,t.c,t.l):vt((t=pt(t)).r,t.g,t.b):new at(t,e,n)}function st(t,e,n){var i=(t+16)/116,r=i+e/500,o=i-n/200;return new pt(ht(3.2404542*(r=ct(r)*$o)-1.5371385*(i=ct(i)*Oo)-.4985314*(o=ct(o)*Uo)),ht(-.969266*r+1.8760108*i+.041556*o),ht(.0556434*r-.2040259*i+1.0572252*o))}function lt(t,e,n){return t>0?new rt(Math.atan2(n,e)*Fo,Math.sqrt(e*e+n*n),t):new rt(NaN,NaN,t)}function ct(t){return t>.206893034?t*t*t:(t-4/29)/7.787037}function ut(t){return t>.008856?Math.pow(t,1/3):7.787037*t+4/29}function ht(t){return Math.round(255*(.00304>=t?12.92*t:1.055*Math.pow(t,1/2.4)-.055))}function pt(t,e,n){return this instanceof pt?(this.r=~~t,this.g=~~e,void(this.b=~~n)):arguments.length<2?t instanceof pt?new pt(t.r,t.g,t.b):mt(""+t,pt,it):new pt(t,e,n)}function dt(t){return new pt(t>>16,255&t>>8,255&t)}function ft(t){return dt(t)+""}function gt(t){return 16>t?"0"+Math.max(0,t).toString(16):Math.min(255,t).toString(16)}function mt(t,e,n){var i,r,o,a=0,s=0,l=0;if(i=/([a-z]+)\((.*)\)/i.exec(t))switch(r=i[2].split(","),i[1]){case"hsl":return n(parseFloat(r[0]),parseFloat(r[1])/100,parseFloat(r[2])/100);case"rgb":return e(bt(r[0]),bt(r[1]),bt(r[2]))}return(o=Yo.get(t))?e(o.r,o.g,o.b):(null==t||"#"!==t.charAt(0)||isNaN(o=parseInt(t.slice(1),16))||(4===t.length?(a=(3840&o)>>4,a|=a>>4,s=240&o,s|=s>>4,l=15&o,l|=l<<4):7===t.length&&(a=(16711680&o)>>16,s=(65280&o)>>8,l=255&o)),e(a,s,l))}function yt(t,e,n){var i,r,o=Math.min(t/=255,e/=255,n/=255),a=Math.max(t,e,n),s=a-o,l=(a+o)/2;return s?(r=.5>l?s/(a+o):s/(2-a-o),i=t==a?(e-n)/s+(n>e?6:0):e==a?(n-t)/s+2:(t-e)/s+4,i*=60):(i=NaN,r=l>0&&1>l?0:i),new nt(i,r,l)}function vt(t,e,n){var i=ut((.4124564*(t=Ct(t))+.3575761*(e=Ct(e))+.1804375*(n=Ct(n)))/$o),r=ut((.2126729*t+.7151522*e+.072175*n)/Oo);return at(116*r-16,500*(i-r),200*(r-ut((.0193339*t+.119192*e+.9503041*n)/Uo)))}function Ct(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function bt(t){var e=parseFloat(t);return"%"===t.charAt(t.length-1)?Math.round(2.55*e):e}function xt(t){return"function"==typeof t?t:function(){return t}}function Lt(t){return t}function kt(t){return function(e,n,i){return 2===arguments.length&&"function"==typeof n&&(i=n,n=null),wt(e,n,t,i)}}function wt(t,e,n,i){function r(){var t,e=l.status;if(!e&&function(t){var e=t.responseType;return e&&"text"!==e?t.response:t.responseText}(l)||e>=200&&300>e||304===e){try{t=n.call(o,l)}catch(t){return void a.error.call(o,t)}a.load.call(o,t)}else a.error.call(o,l)}var o={},a=Hr.dispatch("beforesend","progress","load","error"),s={},l=new XMLHttpRequest,c=null;return!Wr.XDomainRequest||"withCredentials"in l||!/^(http(s)?:)?\/\//.test(t)||(l=new XDomainRequest),"onload"in l?l.onload=l.onerror=r:l.onreadystatechange=function(){l.readyState>3&&r()},l.onprogress=function(t){var e=Hr.event;Hr.event=t;try{a.progress.call(o,l)}finally{Hr.event=e}},o.header=function(t,e){return t=(t+"").toLowerCase(),arguments.length<2?s[t]:(null==e?delete s[t]:s[t]=e+"",o)},o.mimeType=function(t){return arguments.length?(e=null==t?null:t+"",o):e},o.responseType=function(t){return arguments.length?(c=t,o):c},o.response=function(t){return n=t,o},["get","post"].forEach(function(t){o[t]=function(){return o.send.apply(o,[t].concat(jr(arguments)))}}),o.send=function(n,i,r){if(2===arguments.length&&"function"==typeof i&&(r=i,i=null),l.open(n,t,!0),null==e||"accept"in s||(s.accept=e+",*/*"),l.setRequestHeader)for(var u in s)l.setRequestHeader(u,s[u]);return null!=e&&l.overrideMimeType&&l.overrideMimeType(e),null!=c&&(l.responseType=c),null!=r&&o.on("error",r).on("load",function(t){r(null,t)}),a.beforesend.call(o,l),l.send(null==i?null:i),o},o.abort=function(){return l.abort(),o},Hr.rebind(o,a,"on"),null==i?o:o.get(function(t){return 1===t.length?function(e,n){t(null==e?n:null)}:t}(i))}function _t(){var t=St(),e=Mt()-t;e>24?(isFinite(e)&&(clearTimeout(jo),jo=setTimeout(_t,e)),qo=0):(qo=1,Vo(_t))}function St(){var t=Date.now();for(Ko=Zo;Ko;)t>=Ko.t&&(Ko.f=Ko.c(t-Ko.t)),Ko=Ko.n;return t}function Mt(){for(var t,e=Zo,n=1/0;e;)e.f?e=t?t.n=e.n:Zo=e.n:(e.t<n&&(n=e.t),e=(t=e).n);return Ho=t,n}function Ft(t,e){return e-(t?Math.ceil(Math.log(t)/Math.LN10):1)}function Et(t){return t+""}function Pt(){this._=new Date(arguments.length>1?Date.UTC.apply(this,arguments):arguments[0])}function Tt(t,e,n){function i(e){var n=t(e),i=o(n,1);return i-e>e-n?n:i}function r(n){return e(n=t(new Jo(n-1)),1),n}function o(t,n){return e(t=new Jo(+t),n),t}function a(t,i,o){var a=r(t),s=[];if(o>1)for(;i>a;)n(a)%o||s.push(new Date(+a)),e(a,1);else for(;i>a;)s.push(new Date(+a)),e(a,1);return s}t.floor=t,t.round=i,t.ceil=r,t.offset=o,t.range=a;var s=t.utc=At(t);return s.floor=s,s.round=At(i),s.ceil=At(r),s.offset=At(o),s.range=function(t,e,n){try{Jo=Pt;var i=new Pt;return i._=t,a(i,e,n)}finally{Jo=Date}},t}function At(t){return function(e,n){try{Jo=Pt;var i=new Pt;return i._=e,t(i,n)._}finally{Jo=Date}}}function zt(t,e,n){var i=0>t?"-":"",r=(i?-t:t)+"",o=r.length;return i+(n>o?new Array(n-o+1).join(e)+r:r)}function Bt(t){return new RegExp("^(?:"+t.map(Hr.requote).join("|")+")","i")}function Nt(t){for(var e=new a,n=-1,i=t.length;++n<i;)e.set(t[n].toLowerCase(),n);return e}function Dt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+1));return i?(t.w=+i[0],n+i[0].length):-1}function $t(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n));return i?(t.U=+i[0],n+i[0].length):-1}function Ot(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n));return i?(t.W=+i[0],n+i[0].length):-1}function Ut(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+4));return i?(t.y=+i[0],n+i[0].length):-1}function It(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.y=function(t){return t+(t>68?1900:2e3)}(+i[0]),n+i[0].length):-1}function Rt(t,e,n){return/^[+-]\d{4}$/.test(e=e.slice(n,n+5))?(t.Z=-e,n+5):-1}function Yt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.m=i[0]-1,n+i[0].length):-1}function Zt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.d=+i[0],n+i[0].length):-1}function Ht(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+3));return i?(t.j=+i[0],n+i[0].length):-1}function qt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.H=+i[0],n+i[0].length):-1}function jt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.M=+i[0],n+i[0].length):-1}function Kt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+2));return i?(t.S=+i[0],n+i[0].length):-1}function Vt(t,e,n){na.lastIndex=0;var i=na.exec(e.slice(n,n+3));return i?(t.L=+i[0],n+i[0].length):-1}function Wt(t){var e=t.getTimezoneOffset(),n=e>0?"-":"+",i=0|no(e)/60,r=no(e)%60;return n+zt(i,"0",2)+zt(r,"0",2)}function Xt(t,e,n){ia.lastIndex=0;var i=ia.exec(e.slice(n,n+1));return i?n+i[0].length:-1}function Gt(t){for(var e=t.length,n=-1;++n<e;)t[n][0]=this(t[n][0]);return function(e){for(var n=0,i=t[n];!i[1](e);)i=t[++n];return i[0](e)}}function Qt(){}function Jt(t,e,n){var i=n.s=t+e,r=i-t,o=i-r;n.t=t-o+(e-r)}function te(t,e){t&&sa.hasOwnProperty(t.type)&&sa[t.type](t,e)}function ee(t,e,n){var i,r=-1,o=t.length-n;for(e.lineStart();++r<o;)i=t[r],e.point(i[0],i[1],i[2]);e.lineEnd()}function ne(t,e){var n=-1,i=t.length;for(e.polygonStart();++n<i;)ee(t[n],e,1);e.polygonEnd()}function ie(){function t(t,e){e=e*Mo/2+ko/4;var n=(t*=Mo)-i,a=n>=0?1:-1,s=a*n,l=Math.cos(e),c=Math.sin(e),u=o*c,h=r*l+u*Math.cos(s),p=u*a*Math.sin(s);ca.add(Math.atan2(p,h)),i=t,r=l,o=c}var e,n,i,r,o;ua.point=function(a,s){ua.point=t,i=(e=a)*Mo,r=Math.cos(s=(n=s)*Mo/2+ko/4),o=Math.sin(s)},ua.lineEnd=function(){t(e,n)}}function re(t){var e=t[0],n=t[1],i=Math.cos(n);return[i*Math.cos(e),i*Math.sin(e),Math.sin(n)]}function oe(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function ae(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function se(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function le(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function ce(t){var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}function ue(t){return[Math.atan2(t[1],t[0]),Q(t[2])]}function he(t,e){return no(t[0]-e[0])<xo&&no(t[1]-e[1])<xo}function pe(t,e){t*=Mo;var n=Math.cos(e*=Mo);de(n*Math.cos(t),n*Math.sin(t),Math.sin(e))}function de(t,e,n){da+=(t-da)/++ha,fa+=(e-fa)/ha,ga+=(n-ga)/ha}function fe(){function t(t,r){t*=Mo;var o=Math.cos(r*=Mo),a=o*Math.cos(t),s=o*Math.sin(t),l=Math.sin(r),c=Math.atan2(Math.sqrt((c=n*l-i*s)*c+(c=i*a-e*l)*c+(c=e*s-n*a)*c),e*a+n*s+i*l);pa+=c,ma+=c*(e+(e=a)),ya+=c*(n+(n=s)),va+=c*(i+(i=l)),de(e,n,i)}var e,n,i;La.point=function(r,o){r*=Mo;var a=Math.cos(o*=Mo);e=a*Math.cos(r),n=a*Math.sin(r),i=Math.sin(o),La.point=t,de(e,n,i)}}function ge(){La.point=pe}function me(){function t(t,e){t*=Mo;var n=Math.cos(e*=Mo),a=n*Math.cos(t),s=n*Math.sin(t),l=Math.sin(e),c=r*l-o*s,u=o*a-i*l,h=i*s-r*a,p=Math.sqrt(c*c+u*u+h*h),d=i*a+r*s+o*l,f=p&&-G(d)/p,g=Math.atan2(p,d);Ca+=f*c,ba+=f*u,xa+=f*h,pa+=g,ma+=g*(i+(i=a)),ya+=g*(r+(r=s)),va+=g*(o+(o=l)),de(i,r,o)}var e,n,i,r,o;La.point=function(a,s){e=a,n=s,La.point=t,a*=Mo;var l=Math.cos(s*=Mo);i=l*Math.cos(a),r=l*Math.sin(a),o=Math.sin(s),de(i,r,o)},La.lineEnd=function(){t(e,n),La.lineEnd=ge,La.point=pe}}function ye(t,e){function n(n,i){return n=t(n,i),e(n[0],n[1])}return t.invert&&e.invert&&(n.invert=function(n,i){return(n=e.invert(n,i))&&t.invert(n[0],n[1])}),n}function ve(){return!0}function Ce(t,e,n,i,r){var o=[],a=[];if(t.forEach(function(t){if(!((e=t.length-1)<=0)){var e,n=t[0],i=t[e];if(he(n,i)){r.lineStart();for(var s=0;e>s;++s)r.point((n=t[s])[0],n[1]);return void r.lineEnd()}var l=new xe(n,t,null,!0),c=new xe(n,null,l,!1);l.o=c,o.push(l),a.push(c),c=new xe(i,null,l=new xe(i,t,null,!1),!0),l.o=c,o.push(l),a.push(c)}}),a.sort(e),be(o),be(a),o.length){for(var s=0,l=n,c=a.length;c>s;++s)a[s].e=l=!l;for(var u,h,p=o[0];;){for(var d=p,f=!0;d.v;)if((d=d.n)===p)return;u=d.z,r.lineStart();do{if(d.v=d.o.v=!0,d.e){if(f)for(s=0,c=u.length;c>s;++s)r.point((h=u[s])[0],h[1]);else i(d.x,d.n.x,1,r);d=d.n}else{if(f)for(s=(u=d.p.z).length-1;s>=0;--s)r.point((h=u[s])[0],h[1]);else i(d.x,d.p.x,-1,r);d=d.p}u=(d=d.o).z,f=!f}while(!d.v);r.lineEnd()}}}function be(t){if(e=t.length){for(var e,n,i=0,r=t[0];++i<e;)r.n=n=t[i],n.p=r,r=n;r.n=n=t[0],n.p=r}}function xe(t,e,n,i){this.x=t,this.z=e,this.o=n,this.e=i,this.v=!1,this.n=this.p=null}function Le(t,e,n,i){return function(r,o){function a(e,n){var i=r(e,n);t(e=i[0],n=i[1])&&o.point(e,n)}function s(t,e){var n=r(t,e);m.point(n[0],n[1])}function l(){v.point=s,m.lineStart()}function c(){v.point=a,m.lineEnd()}function u(t,e){g.push([t,e]);var n=r(t,e);b.point(n[0],n[1])}function h(){b.lineStart(),g=[]}function p(){u(g[0][0],g[0][1]),b.lineEnd();var t,e=b.clean(),n=C.buffer(),i=n.length;if(g.pop(),f.push(g),g=null,i)if(1&e){var r,a=-1;if((i=(t=n[0]).length-1)>0){for(x||(o.polygonStart(),x=!0),o.lineStart();++a<i;)o.point((r=t[a])[0],r[1]);o.lineEnd()}}else i>1&&2&e&&n.push(n.pop().concat(n.shift())),d.push(n.filter(ke))}var d,f,g,m=e(o),y=r.invert(i[0],i[1]),v={point:a,lineStart:l,lineEnd:c,polygonStart:function(){v.point=u,v.lineStart=h,v.lineEnd=p,d=[],f=[]},polygonEnd:function(){v.point=a,v.lineStart=l,v.lineEnd=c,d=Hr.merge(d);var t=function(t,e){var n=t[0],i=t[1],r=[Math.sin(n),-Math.cos(n),0],o=0,a=0;ca.reset();for(var s=0,l=e.length;l>s;++s){var c=e[s],u=c.length;if(u)for(var h=c[0],p=h[0],d=h[1]/2+ko/4,f=Math.sin(d),g=Math.cos(d),m=1;;){m===u&&(m=0);var y=(t=c[m])[0],v=t[1]/2+ko/4,C=Math.sin(v),b=Math.cos(v),x=y-p,L=x>=0?1:-1,k=L*x,w=k>ko,_=f*C;if(ca.add(Math.atan2(_*L*Math.sin(k),g*b+_*Math.cos(k))),o+=w?x+L*wo:x,w^p>=n^y>=n){var S=ae(re(h),re(t));ce(S);var M=ae(r,S);ce(M);var F=(w^x>=0?-1:1)*Q(M[2]);(i>F||i===F&&(S[0]||S[1]))&&(a+=w^x>=0?1:-1)}if(!m++)break;p=y,f=C,g=b,h=t}}return(-xo>o||xo>o&&0>ca)^1&a}(y,f);d.length?(x||(o.polygonStart(),x=!0),Ce(d,_e,t,n,o)):t&&(x||(o.polygonStart(),x=!0),o.lineStart(),n(null,null,1,o),o.lineEnd()),x&&(o.polygonEnd(),x=!1),d=f=null},sphere:function(){o.polygonStart(),o.lineStart(),n(null,null,1,o),o.lineEnd(),o.polygonEnd()}},C=we(),b=e(C),x=!1;return v}}function ke(t){return t.length>1}function we(){var t,e=[];return{lineStart:function(){e.push(t=[])},point:function(e,n){t.push([e,n])},lineEnd:y,buffer:function(){var n=e;return e=[],t=null,n},rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))}}}function _e(t,e){return((t=t.x)[0]<0?t[1]-So-xo:So-t[1])-((e=e.x)[0]<0?e[1]-So-xo:So-e[1])}function Se(t,e,n,i){return function(r){var o,a=r.a,s=r.b,l=a.x,c=a.y,u=0,h=1,p=s.x-l,d=s.y-c;if(o=t-l,p||!(o>0)){if(o/=p,0>p){if(u>o)return;h>o&&(h=o)}else if(p>0){if(o>h)return;o>u&&(u=o)}if(o=n-l,p||!(0>o)){if(o/=p,0>p){if(o>h)return;o>u&&(u=o)}else if(p>0){if(u>o)return;h>o&&(h=o)}if(o=e-c,d||!(o>0)){if(o/=d,0>d){if(u>o)return;h>o&&(h=o)}else if(d>0){if(o>h)return;o>u&&(u=o)}if(o=i-c,d||!(0>o)){if(o/=d,0>d){if(o>h)return;o>u&&(u=o)}else if(d>0){if(u>o)return;h>o&&(h=o)}return u>0&&(r.a={x:l+u*p,y:c+u*d}),1>h&&(r.b={x:l+h*p,y:c+h*d}),r}}}}}}function Me(t,e,n,i){function r(i,r){return no(i[0]-t)<xo?r>0?0:3:no(i[0]-n)<xo?r>0?2:1:no(i[1]-e)<xo?r>0?1:0:r>0?3:2}function o(t,e){return a(t.x,e.x)}function a(t,e){var n=r(t,1),i=r(e,1);return n!==i?n-i:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(s){function l(o,s,l,c){var u=0,h=0;if(null==o||(u=r(o,l))!==(h=r(s,l))||a(o,s)<0^l>0)do{c.point(0===u||3===u?t:n,u>1?i:e)}while((u=(u+l+4)%4)!==h);else c.point(s[0],s[1])}function c(r,o){return r>=t&&n>=r&&o>=e&&i>=o}function u(t,e){c(t,e)&&s.point(t,e)}function h(t,e){var n=c(t=Math.max(-wa,Math.min(wa,t)),e=Math.max(-wa,Math.min(wa,e)));if(d&&f.push([t,e]),x)g=t,m=e,y=n,x=!1,n&&(s.lineStart(),s.point(t,e));else if(n&&b)s.point(t,e);else{var i={a:{x:v,y:C},b:{x:t,y:e}};_(i)?(b||(s.lineStart(),s.point(i.a.x,i.a.y)),s.point(i.b.x,i.b.y),n||s.lineEnd(),L=!1):n&&(s.lineStart(),s.point(t,e),L=!1)}v=t,C=e,b=n}var p,d,f,g,m,y,v,C,b,x,L,k=s,w=we(),_=Se(t,e,n,i),S={point:u,lineStart:function(){S.point=h,d&&d.push(f=[]),x=!0,b=!1,v=C=NaN},lineEnd:function(){p&&(h(g,m),y&&b&&w.rejoin(),p.push(w.buffer())),S.point=u,b&&s.lineEnd()},polygonStart:function(){s=w,p=[],d=[],L=!0},polygonEnd:function(){s=k,p=Hr.merge(p);var e=function(t){for(var e=0,n=d.length,i=t[1],r=0;n>r;++r)for(var o,a=1,s=d[r],l=s.length,c=s[0];l>a;++a)o=s[a],c[1]<=i?o[1]>i&&X(c,o,t)>0&&++e:o[1]<=i&&X(c,o,t)<0&&--e,c=o;return 0!==e}([t,i]),n=L&&e,r=p.length;(n||r)&&(s.polygonStart(),n&&(s.lineStart(),l(null,null,1,s),s.lineEnd()),r&&Ce(p,o,e,l,s),s.polygonEnd()),p=d=f=null}};return S}}function Fe(t){var e=0,n=ko/3,i=Ie(t),r=i(e,n);return r.parallels=function(t){return arguments.length?i(e=t[0]*ko/180,n=t[1]*ko/180):[e/ko*180,n/ko*180]},r}function Ee(t,e){function n(t,e){var n=Math.sqrt(o-2*r*Math.sin(e))/r;return[n*Math.sin(t*=r),a-n*Math.cos(t)]}var i=Math.sin(t),r=(i+Math.sin(e))/2,o=1+i*(2*r-i),a=Math.sqrt(o)/r;return n.invert=function(t,e){var n=a-e;return[Math.atan2(t,n)/r,Q((o-(t*t+n*n)*r*r)/(2*r))]},n}function Pe(){function t(t,e){Sa+=r*t-i*e,i=t,r=e}var e,n,i,r;Ta.point=function(o,a){Ta.point=t,e=i=o,n=r=a},Ta.lineEnd=function(){t(e,n)}}function Te(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Ae(t,e){da+=t,fa+=e,++ga}function ze(){function t(t,i){var r=t-e,o=i-n,a=Math.sqrt(r*r+o*o);ma+=a*(e+t)/2,ya+=a*(n+i)/2,va+=a,Ae(e=t,n=i)}var e,n;za.point=function(i,r){za.point=t,Ae(e=i,n=r)}}function Be(){za.point=Ae}function Ne(){function t(t,e){var n=t-i,o=e-r,a=Math.sqrt(n*n+o*o);ma+=a*(i+t)/2,ya+=a*(r+e)/2,va+=a,Ca+=(a=r*t-i*e)*(i+t),ba+=a*(r+e),xa+=3*a,Ae(i=t,r=e)}var e,n,i,r;za.point=function(o,a){za.point=t,Ae(e=i=o,n=r=a)},za.lineEnd=function(){t(e,n)}}function De(t){function e(t){return(s?i:n)(t)}function n(e){return Oe(e,function(n,i){n=t(n,i),e.point(n[0],n[1])})}function i(e){function n(n,i){n=t(n,i),e.point(n[0],n[1])}function i(){v=NaN,k.point=o,e.lineStart()}function o(n,i){var o=re([n,i]),a=t(n,i);r(v,C,y,b,x,L,v=a[0],C=a[1],y=n,b=o[0],x=o[1],L=o[2],s,e),e.point(v,C)}function a(){k.point=n,e.lineEnd()}function l(){i(),k.point=c,k.lineEnd=u}function c(t,e){o(h=t,e),p=v,d=C,f=b,g=x,m=L,k.point=o}function u(){r(v,C,y,b,x,L,p,d,h,f,g,m,s,e),k.lineEnd=a,a()}var h,p,d,f,g,m,y,v,C,b,x,L,k={point:n,lineStart:i,lineEnd:a,polygonStart:function(){e.polygonStart(),k.lineStart=l},polygonEnd:function(){e.polygonEnd(),k.lineStart=i}};return k}function r(e,n,i,s,l,c,u,h,p,d,f,g,m,y){var v=u-e,C=h-n,b=v*v+C*C;if(b>4*o&&m--){var x=s+d,L=l+f,k=c+g,w=Math.sqrt(x*x+L*L+k*k),_=Math.asin(k/=w),S=no(no(k)-1)<xo||no(i-p)<xo?(i+p)/2:Math.atan2(L,x),M=t(S,_),F=M[0],E=M[1],P=F-e,T=E-n,A=C*P-v*T;(A*A/b>o||no((v*P+C*T)/b-.5)>.3||a>s*d+l*f+c*g)&&(r(e,n,i,s,l,c,F,E,S,x/=w,L/=w,k,m,y),y.point(F,E),r(F,E,S,x,L,k,u,h,p,d,f,g,m,y))}}var o=.5,a=Math.cos(30*Mo),s=16;return e.precision=function(t){return arguments.length?(s=(o=t*t)>0&&16,e):Math.sqrt(o)},e}function $e(t){this.stream=t}function Oe(t,e){return{point:e,sphere:function(){t.sphere()},lineStart:function(){t.lineStart()},lineEnd:function(){t.lineEnd()},polygonStart:function(){t.polygonStart()},polygonEnd:function(){t.polygonEnd()}}}function Ue(t){return Ie(function(){return t})()}function Ie(t){function e(t){return[(t=s(t[0]*Mo,t[1]*Mo))[0]*p+l,c-t[1]*p]}function n(t){return(t=s.invert((t[0]-l)/p,(c-t[1])/p))&&[t[0]*Fo,t[1]*Fo]}function i(){s=ye(a=He(y,v,C),o);var t=o(g,m);return l=d-t[0]*p,c=f+t[1]*p,r()}function r(){return u&&(u.valid=!1,u=null),e}var o,a,s,l,c,u,h=De(function(t,e){return[(t=o(t,e))[0]*p+l,c-t[1]*p]}),p=150,d=480,f=250,g=0,m=0,y=0,v=0,C=0,b=ka,x=Lt,L=null,k=null;return e.stream=function(t){return u&&(u.valid=!1),(u=Re(b(a,h(x(t))))).valid=!0,u},e.clipAngle=function(t){return arguments.length?(b=null==t?(L=t,ka):function(t){function e(t,e){return Math.cos(t)*Math.cos(e)>r}function n(t,e,n){var i=[1,0,0],o=ae(re(t),re(e)),a=oe(o,o),s=o[0],l=a-s*s;if(!l)return!n&&t;var c=r*a/l,u=-r*s/l,h=ae(i,o),p=le(i,c);se(p,le(o,u));var d=h,f=oe(p,d),g=oe(d,d),m=f*f-g*(oe(p,p)-1);if(!(0>m)){var y=Math.sqrt(m),v=le(d,(-f-y)/g);if(se(v,p),v=ue(v),!n)return v;var C,b=t[0],x=e[0],L=t[1],k=e[1];b>x&&(C=b,b=x,x=C);var w=x-b,_=no(w-ko)<xo;if(!_&&L>k&&(C=L,L=k,k=C),_||xo>w?_?L+k>0^v[1]<(no(v[0]-b)<xo?L:k):L<=v[1]&&v[1]<=k:w>ko^(b<=v[0]&&v[0]<=x)){var S=le(d,(-f+y)/g);return se(S,p),[v,ue(S)]}}}function i(e,n){var i=o?t:ko-t,r=0;return-i>e?r|=1:e>i&&(r|=2),-i>n?r|=4:n>i&&(r|=8),r}var r=Math.cos(t),o=r>0,a=no(r)>xo;return Le(e,function(t){var r,s,l,c,u;return{lineStart:function(){c=l=!1,u=1},point:function(h,p){var d,f=[h,p],g=e(h,p),m=o?g?0:i(h,p):g?i(h+(0>h?ko:-ko),p):0;if(!r&&(c=l=g)&&t.lineStart(),g!==l&&(d=n(r,f),(he(r,d)||he(f,d))&&(f[0]+=xo,f[1]+=xo,g=e(f[0],f[1]))),g!==l)u=0,g?(t.lineStart(),d=n(f,r),t.point(d[0],d[1])):(d=n(r,f),t.point(d[0],d[1]),t.lineEnd()),r=d;else if(a&&r&&o^g){var y;m&s||!(y=n(f,r,!0))||(u=0,o?(t.lineStart(),t.point(y[0][0],y[0][1]),t.point(y[1][0],y[1][1]),t.lineEnd()):(t.point(y[1][0],y[1][1]),t.lineEnd(),t.lineStart(),t.point(y[0][0],y[0][1])))}!g||r&&he(r,f)||t.point(f[0],f[1]),r=f,l=g,s=m},lineEnd:function(){l&&t.lineEnd(),r=null},clean:function(){return u|(c&&l)<<1}}},Ve(t,6*Mo),o?[0,-t]:[-ko,t-ko])}((L=+t)*Mo),r()):L},e.clipExtent=function(t){return arguments.length?(k=t,x=t?Me(t[0][0],t[0][1],t[1][0],t[1][1]):Lt,r()):k},e.scale=function(t){return arguments.length?(p=+t,i()):p},e.translate=function(t){return arguments.length?(d=+t[0],f=+t[1],i()):[d,f]},e.center=function(t){return arguments.length?(g=t[0]%360*Mo,m=t[1]%360*Mo,i()):[g*Fo,m*Fo]},e.rotate=function(t){return arguments.length?(y=t[0]%360*Mo,v=t[1]%360*Mo,C=t.length>2?t[2]%360*Mo:0,i()):[y*Fo,v*Fo,C*Fo]},Hr.rebind(e,h,"precision"),function(){return o=t.apply(this,arguments),e.invert=o.invert&&n,i()}}function Re(t){return Oe(t,function(e,n){t.point(e*Mo,n*Mo)})}function Ye(t,e){return[t,e]}function Ze(t,e){return[t>ko?t-wo:-ko>t?t+wo:t,e]}function He(t,e,n){return t?e||n?ye(je(t),Ke(e,n)):je(t):e||n?Ke(e,n):Ze}function qe(t){return function(e,n){return[(e+=t)>ko?e-wo:-ko>e?e+wo:e,n]}}function je(t){var e=qe(t);return e.invert=qe(-t),e}function Ke(t,e){function n(t,e){var n=Math.cos(e),s=Math.cos(t)*n,l=Math.sin(t)*n,c=Math.sin(e),u=c*i+s*r;return[Math.atan2(l*o-u*a,s*i-c*r),Q(u*o+l*a)]}var i=Math.cos(t),r=Math.sin(t),o=Math.cos(e),a=Math.sin(e);return n.invert=function(t,e){var n=Math.cos(e),s=Math.cos(t)*n,l=Math.sin(t)*n,c=Math.sin(e),u=c*o-l*a;return[Math.atan2(l*o+c*a,s*i+u*r),Q(u*i-s*r)]},n}function Ve(t,e){var n=Math.cos(t),i=Math.sin(t);return function(r,o,a,s){var l=a*e;null!=r?(r=We(n,r),o=We(n,o),(a>0?o>r:r>o)&&(r+=a*wo)):(r=t+a*wo,o=t-.5*l);for(var c,u=r;a>0?u>o:o>u;u-=l)s.point((c=ue([n,-i*Math.cos(u),-i*Math.sin(u)]))[0],c[1])}}function We(t,e){var n=re(e);n[0]-=t,ce(n);var i=G(-n[1]);return((-n[2]<0?-i:i)+2*Math.PI-xo)%(2*Math.PI)}function Xe(t,e,n){var i=Hr.range(t,e-xo,n).concat(e);return function(t){return i.map(function(e){return[t,e]})}}function Ge(t,e,n){var i=Hr.range(t,e-xo,n).concat(e);return function(t){return i.map(function(e){return[e,t]})}}function Qe(t){return t.source}function Je(t){return t.target}function tn(t,e){function n(e,n){var i=Math.cos(e),r=Math.cos(n),o=t(i*r);return[o*r*Math.sin(e),o*Math.sin(n)]}return n.invert=function(t,n){var i=Math.sqrt(t*t+n*n),r=e(i),o=Math.sin(r),a=Math.cos(r);return[Math.atan2(t*o,i*a),Math.asin(i&&n*o/i)]},n}function en(t,e){function n(t,e){a>0?-So+xo>e&&(e=-So+xo):e>So-xo&&(e=So-xo);var n=a/Math.pow(r(e),o);return[n*Math.sin(o*t),a-n*Math.cos(o*t)]}var i=Math.cos(t),r=function(t){return Math.tan(ko/4+t/2)},o=t===e?Math.sin(t):Math.log(i/Math.cos(e))/Math.log(r(e)/r(t)),a=i*Math.pow(r(t),o)/o;return o?(n.invert=function(t,e){var n=a-e,i=W(o)*Math.sqrt(t*t+n*n);return[Math.atan2(t,n)/o,2*Math.atan(Math.pow(a/i,1/o))-So]},n):rn}function nn(t,e){function n(t,e){var n=o-e;return[n*Math.sin(r*t),o-n*Math.cos(r*t)]}var i=Math.cos(t),r=t===e?Math.sin(t):(i-Math.cos(e))/(e-t),o=i/r+t;return no(r)<xo?Ye:(n.invert=function(t,e){var n=o-e;return[Math.atan2(t,n)/r,o-W(r)*Math.sqrt(t*t+n*n)]},n)}function rn(t,e){return[t,Math.log(Math.tan(ko/4+e/2))]}function on(t){var e,n=Ue(t),i=n.scale,r=n.translate,o=n.clipExtent;return n.scale=function(){var t=i.apply(n,arguments);return t===n?e?n.clipExtent(null):n:t},n.translate=function(){var t=r.apply(n,arguments);return t===n?e?n.clipExtent(null):n:t},n.clipExtent=function(t){var a=o.apply(n,arguments);if(a===n){if(e=null==t){var s=ko*i(),l=r();o([[l[0]-s,l[1]-s],[l[0]+s,l[1]+s]])}}else e&&(a=null);return a},n.clipExtent(null)}function an(t,e){return[Math.log(Math.tan(ko/4+e/2)),-t]}function sn(t){return t[0]}function ln(t){return t[1]}function cn(t){for(var e=t.length,n=[0,1],i=2,r=2;e>r;r++){for(;i>1&&X(t[n[i-2]],t[n[i-1]],t[r])<=0;)--i;n[i++]=r}return n.slice(0,i)}function un(t,e){return t[0]-e[0]||t[1]-e[1]}function hn(t,e,n){return(n[0]-e[0])*(t[1]-e[1])<(n[1]-e[1])*(t[0]-e[0])}function pn(t,e,n,i){var r=t[0],o=n[0],a=e[0]-r,s=i[0]-o,l=t[1],c=n[1],u=e[1]-l,h=i[1]-c,p=(s*(l-c)-h*(r-o))/(h*a-s*u);return[r+p*a,l+p*u]}function dn(t){var e=t[0],n=t[t.length-1];return!(e[0]-n[0]||e[1]-n[1])}function fn(t){var e=Ka.pop()||new function(){Tn(this),this.edge=this.site=this.circle=null};return e.site=t,e}function gn(t){kn(t),Ha.remove(t),Ka.push(t),Tn(t)}function mn(t){var e=t.circle,n=e.x,i=e.cy,r={x:n,y:i},o=t.P,a=t.N,s=[t];gn(t);for(var l=o;l.circle&&no(n-l.circle.x)<xo&&no(i-l.circle.cy)<xo;)o=l.P,s.unshift(l),gn(l),l=o;s.unshift(l),kn(l);for(var c=a;c.circle&&no(n-c.circle.x)<xo&&no(i-c.circle.cy)<xo;)a=c.N,s.push(c),gn(c),c=a;s.push(c),kn(c);var u,h=s.length;for(u=1;h>u;++u)c=s[u],l=s[u-1],Fn(c.edge,l.site,c.site,r);l=s[0],(c=s[h-1]).edge=Sn(l.site,c.site,null,r),Ln(l),Ln(c)}function yn(t){for(var e,n,i,r,o=t.x,a=t.y,s=Ha._;s;)if((i=vn(s,a)-o)>xo)s=s.L;else{if(!((r=o-Cn(s,a))>xo)){i>-xo?(e=s.P,n=s):r>-xo?(e=s,n=s.N):e=n=s;break}if(!s.R){e=s;break}s=s.R}var l=fn(t);if(Ha.insert(e,l),e||n){if(e===n)return kn(e),n=fn(e.site),Ha.insert(l,n),l.edge=n.edge=Sn(e.site,l.site),Ln(e),void Ln(n);if(!n)return void(l.edge=Sn(e.site,l.site));kn(e),kn(n);var c=e.site,u=c.x,h=c.y,p=t.x-u,d=t.y-h,f=n.site,g=f.x-u,m=f.y-h,y=2*(p*m-d*g),v=p*p+d*d,C=g*g+m*m,b={x:(m*v-d*C)/y+u,y:(p*C-g*v)/y+h};Fn(n.edge,c,f,b),l.edge=Sn(c,t,null,b),n.edge=Sn(t,f,null,b),Ln(e),Ln(n)}}function vn(t,e){var n=t.site,i=n.x,r=n.y,o=r-e;if(!o)return i;var a=t.P;if(!a)return-1/0;var s=(n=a.site).x,l=n.y,c=l-e;if(!c)return s;var u=s-i,h=1/o-1/c,p=u/c;return h?(-p+Math.sqrt(p*p-2*h*(u*u/(-2*c)-l+c/2+r-o/2)))/h+i:(i+s)/2}function Cn(t,e){var n=t.N;if(n)return vn(n,e);var i=t.site;return i.y===e?i.x:1/0}function bn(t){this.site=t,this.edges=[]}function xn(t,e){return e.angle-t.angle}function Ln(t){var e=t.P,n=t.N;if(e&&n){var i=e.site,r=t.site,o=n.site;if(i!==o){var a=r.x,s=r.y,l=i.x-a,c=i.y-s,u=o.x-a,h=2*(l*(m=o.y-s)-c*u);if(!(h>=-Lo)){var p=l*l+c*c,d=u*u+m*m,f=(m*p-c*d)/h,g=(l*d-u*p)/h,m=g+s,y=Va.pop()||new function(){Tn(this),this.x=this.y=this.arc=this.site=this.cy=null};y.arc=t,y.site=r,y.x=f+a,y.y=m+Math.sqrt(f*f+g*g),y.cy=m,t.circle=y;for(var v=null,C=ja._;C;)if(y.y<C.y||y.y===C.y&&y.x<=C.x){if(!C.L){v=C.P;break}C=C.L}else{if(!C.R){v=C;break}C=C.R}ja.insert(v,y),v||(qa=y)}}}}function kn(t){var e=t.circle;e&&(e.P||(qa=e.N),ja.remove(e),Va.push(e),Tn(e),t.circle=null)}function wn(t,e){var n=t.b;if(n)return!0;var i,r,o=t.a,a=e[0][0],s=e[1][0],l=e[0][1],c=e[1][1],u=t.l,h=t.r,p=u.x,d=u.y,f=h.x,g=h.y,m=(p+f)/2,y=(d+g)/2;if(g===d){if(a>m||m>=s)return;if(p>f){if(o){if(o.y>=c)return}else o={x:m,y:l};n={x:m,y:c}}else{if(o){if(o.y<l)return}else o={x:m,y:c};n={x:m,y:l}}}else if(r=y-(i=(p-f)/(g-d))*m,-1>i||i>1)if(p>f){if(o){if(o.y>=c)return}else o={x:(l-r)/i,y:l};n={x:(c-r)/i,y:c}}else{if(o){if(o.y<l)return}else o={x:(c-r)/i,y:c};n={x:(l-r)/i,y:l}}else if(g>d){if(o){if(o.x>=s)return}else o={x:a,y:i*a+r};n={x:s,y:i*s+r}}else{if(o){if(o.x<a)return}else o={x:s,y:i*s+r};n={x:a,y:i*a+r}}return t.a=o,t.b=n,!0}function _n(t,e){this.l=t,this.r=e,this.a=this.b=null}function Sn(t,e,n,i){var r=new _n(t,e);return Ya.push(r),n&&Fn(r,t,e,n),i&&Fn(r,e,t,i),Za[t.i].edges.push(new En(r,t,e)),Za[e.i].edges.push(new En(r,e,t)),r}function Mn(t,e,n){var i=new _n(t,null);return i.a=e,i.b=n,Ya.push(i),i}function Fn(t,e,n,i){t.a||t.b?t.l===n?t.b=i:t.a=i:(t.a=i,t.l=e,t.r=n)}function En(t,e,n){var i=t.a,r=t.b;this.edge=t,this.site=e,this.angle=n?Math.atan2(n.y-e.y,n.x-e.x):t.l===e?Math.atan2(r.x-i.x,i.y-r.y):Math.atan2(i.x-r.x,r.y-i.y)}function Pn(){this._=null}function Tn(t){t.U=t.C=t.L=t.R=t.P=t.N=null}function An(t,e){var n=e,i=e.R,r=n.U;r?r.L===n?r.L=i:r.R=i:t._=i,i.U=r,n.U=i,n.R=i.L,n.R&&(n.R.U=n),i.L=n}function zn(t,e){var n=e,i=e.L,r=n.U;r?r.L===n?r.L=i:r.R=i:t._=i,i.U=r,n.U=i,n.L=i.R,n.L&&(n.L.U=n),i.R=n}function Bn(t){for(;t.L;)t=t.L;return t}function Nn(t,e){var n,i,r,o=t.sort(Dn).pop();for(Ya=[],Za=new Array(t.length),Ha=new Pn,ja=new Pn;;)if(r=qa,o&&(!r||o.y<r.y||o.y===r.y&&o.x<r.x))(o.x!==n||o.y!==i)&&(Za[o.i]=new bn(o),yn(o),n=o.x,i=o.y),o=t.pop();else{if(!r)break;mn(r.arc)}e&&(function(t){for(var e,n=Ya,i=Se(t[0][0],t[0][1],t[1][0],t[1][1]),r=n.length;r--;)(!wn(e=n[r],t)||!i(e)||no(e.a.x-e.b.x)<xo&&no(e.a.y-e.b.y)<xo)&&(e.a=e.b=null,n.splice(r,1))}(e),function(t){for(var e,n,i,r,o,a,s,l,c,u,h=t[0][0],p=t[1][0],d=t[0][1],f=t[1][1],g=Za,m=g.length;m--;)if((o=g[m])&&o.prepare())for(l=(s=o.edges).length,a=0;l>a;)i=(u=s[a].end()).x,r=u.y,e=(c=s[++a%l].start()).x,n=c.y,(no(i-e)>xo||no(r-n)>xo)&&(s.splice(a,0,new En(Mn(o.site,u,no(i-h)<xo&&f-r>xo?{x:h,y:no(e-h)<xo?n:f}:no(r-f)<xo&&p-i>xo?{x:no(n-f)<xo?e:p,y:f}:no(i-p)<xo&&r-d>xo?{x:p,y:no(e-p)<xo?n:d}:no(r-d)<xo&&i-h>xo?{x:no(n-d)<xo?e:h,y:d}:null),o.site,null)),++l)}(e));var a={cells:Za,edges:Ya};return Ha=ja=Ya=Za=null,a}function Dn(t,e){return e.y-t.y||e.x-t.x}function $n(t,e,n){return(t.x-n.x)*(e.y-t.y)-(t.x-e.x)*(n.y-t.y)}function On(t){return t.x}function Un(t){return t.y}function In(t,e){t=Hr.rgb(t),e=Hr.rgb(e);var n=t.r,i=t.g,r=t.b,o=e.r-n,a=e.g-i,s=e.b-r;return function(t){return"#"+gt(Math.round(n+o*t))+gt(Math.round(i+a*t))+gt(Math.round(r+s*t))}}function Rn(t,e){var n,i={},r={};for(n in t)n in e?i[n]=Hn(t[n],e[n]):r[n]=t[n];for(n in e)n in t||(r[n]=e[n]);return function(t){for(n in i)r[n]=i[n](t);return r}}function Yn(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function Zn(t,e){var n,i,r,o=Xa.lastIndex=Ga.lastIndex=0,a=-1,s=[],l=[];for(t+="",e+="";(n=Xa.exec(t))&&(i=Ga.exec(e));)(r=i.index)>o&&(r=e.slice(o,r),s[a]?s[a]+=r:s[++a]=r),(n=n[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,l.push({i:a,x:Yn(n,i)})),o=Ga.lastIndex;return o<e.length&&(r=e.slice(o),s[a]?s[a]+=r:s[++a]=r),s.length<2?l[0]?(e=l[0].x,function(t){return e(t)+""}):function(){return e}:(e=l.length,function(t){for(var n,i=0;e>i;++i)s[(n=l[i]).i]=n.x(t);return s.join("")})}function Hn(t,e){for(var n,i=Hr.interpolators.length;--i>=0&&!(n=Hr.interpolators[i](t,e)););return n}function qn(t,e){var n,i=[],r=[],o=t.length,a=e.length,s=Math.min(t.length,e.length);for(n=0;s>n;++n)i.push(Hn(t[n],e[n]));for(;o>n;++n)r[n]=t[n];for(;a>n;++n)r[n]=e[n];return function(t){for(n=0;s>n;++n)r[n]=i[n](t);return r}}function jn(t){return function(e){return 1-t(1-e)}}function Kn(t){return function(e){return.5*(.5>e?t(2*e):2-t(2-2*e))}}function Vn(t){return t*t}function Wn(t){return t*t*t}function Xn(t){if(0>=t)return 0;if(t>=1)return 1;var e=t*t,n=e*t;return 4*(.5>t?n:3*(t-e)+n-.75)}function Gn(t){return 1-Math.cos(t*So)}function Qn(t){return Math.pow(2,10*(t-1))}function Jn(t){return 1-Math.sqrt(1-t*t)}function ti(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375}function ei(t,e){return e-=t,function(n){return Math.round(t+e*n)}}function ni(t){var e=[t.a,t.b],n=[t.c,t.d],i=ri(e),r=ii(e,n),o=ri(function(t,e,n){return t[0]+=n*e[0],t[1]+=n*e[1],t}(n,e,-r))||0;e[0]*n[1]<n[0]*e[1]&&(e[0]*=-1,e[1]*=-1,i*=-1,r*=-1),this.rotate=(i?Math.atan2(e[1],e[0]):Math.atan2(-n[0],n[1]))*Fo,this.translate=[t.e,t.f],this.scale=[i,o],this.skew=o?Math.atan2(r,o)*Fo:0}function ii(t,e){return t[0]*e[0]+t[1]*e[1]}function ri(t){var e=Math.sqrt(ii(t,t));return e&&(t[0]/=e,t[1]/=e),e}function oi(t,e){var n,i=[],r=[],o=Hr.transform(t),a=Hr.transform(e),s=o.translate,l=a.translate,c=o.rotate,u=a.rotate,h=o.skew,p=a.skew,d=o.scale,f=a.scale;return s[0]!=l[0]||s[1]!=l[1]?(i.push("translate(",null,",",null,")"),r.push({i:1,x:Yn(s[0],l[0])},{i:3,x:Yn(s[1],l[1])})):l[0]||l[1]?i.push("translate("+l+")"):i.push(""),c!=u?(c-u>180?u+=360:u-c>180&&(c+=360),r.push({i:i.push(i.pop()+"rotate(",null,")")-2,x:Yn(c,u)})):u&&i.push(i.pop()+"rotate("+u+")"),h!=p?r.push({i:i.push(i.pop()+"skewX(",null,")")-2,x:Yn(h,p)}):p&&i.push(i.pop()+"skewX("+p+")"),d[0]!=f[0]||d[1]!=f[1]?(n=i.push(i.pop()+"scale(",null,",",null,")"),r.push({i:n-4,x:Yn(d[0],f[0])},{i:n-2,x:Yn(d[1],f[1])})):(1!=f[0]||1!=f[1])&&i.push(i.pop()+"scale("+f+")"),n=r.length,function(t){for(var e,o=-1;++o<n;)i[(e=r[o]).i]=e.x(t);return i.join("")}}function ai(t,e){return e=(e-=t=+t)||1/e,function(n){return(n-t)/e}}function si(t,e){return e=(e-=t=+t)||1/e,function(n){return Math.max(0,Math.min(1,(n-t)/e))}}function li(t){for(var e=t.source,n=t.target,i=function(t,e){if(t===e)return t;for(var n=ci(t),i=ci(e),r=n.pop(),o=i.pop(),a=null;r===o;)a=r,r=n.pop(),o=i.pop();return a}(e,n),r=[e];e!==i;)e=e.parent,r.push(e);for(var o=r.length;n!==i;)r.splice(o,0,n),n=n.parent;return r}function ci(t){for(var e=[],n=t.parent;null!=n;)e.push(t),t=n,n=n.parent;return e.push(t),e}function ui(t){t.fixed|=2}function hi(t){t.fixed&=-7}function pi(t){t.fixed|=4,t.px=t.x,t.py=t.y}function di(t){t.fixed&=-5}function fi(t,e){return Hr.rebind(t,e,"sort","children","value"),t.nodes=t,t.links=bi,t}function gi(t,e){for(var n=[t];null!=(t=n.pop());)if(e(t),(r=t.children)&&(i=r.length))for(var i,r;--i>=0;)n.push(r[i])}function mi(t,e){for(var n=[t],i=[];null!=(t=n.pop());)if(i.push(t),(o=t.children)&&(r=o.length))for(var r,o,a=-1;++a<r;)n.push(o[a]);for(;null!=(t=i.pop());)e(t)}function yi(t){return t.children}function vi(t){return t.value}function Ci(t,e){return e.value-t.value}function bi(t){return Hr.merge(t.map(function(t){return(t.children||[]).map(function(e){return{source:t,target:e}})}))}function xi(t){return t.x}function Li(t){return t.y}function ki(t,e,n){t.y0=e,t.y=n}function wi(t){return Hr.range(t.length)}function _i(t){for(var e=-1,n=t[0].length,i=[];++e<n;)i[e]=0;return i}function Si(t){for(var e,n=1,i=0,r=t[0][1],o=t.length;o>n;++n)(e=t[n][1])>r&&(i=n,r=e);return i}function Mi(t){return t.reduce(Fi,0)}function Fi(t,e){return t+e[1]}function Ei(t,e){return Pi(t,Math.ceil(Math.log(e.length)/Math.LN2+1))}function Pi(t,e){for(var n=-1,i=+t[0],r=(t[1]-i)/e,o=[];++n<=e;)o[n]=r*n+i;return o}function Ti(t){return[Hr.min(t),Hr.max(t)]}function Ai(t,e){return t.value-e.value}function zi(t,e){var n=t._pack_next;t._pack_next=e,e._pack_prev=t,e._pack_next=n,n._pack_prev=e}function Bi(t,e){t._pack_next=e,e._pack_prev=t}function Ni(t,e){var n=e.x-t.x,i=e.y-t.y,r=t.r+e.r;return.999*r*r>n*n+i*i}function Di(t){function e(t){u=Math.min(t.x-t.r,u),h=Math.max(t.x+t.r,h),p=Math.min(t.y-t.r,p),d=Math.max(t.y+t.r,d)}if((n=t.children)&&(c=n.length)){var n,i,r,o,a,s,l,c,u=1/0,h=-1/0,p=1/0,d=-1/0;if(n.forEach($i),(i=n[0]).x=-i.r,i.y=0,e(i),c>1&&((r=n[1]).x=r.r,r.y=0,e(r),c>2))for(Ui(i,r,o=n[2]),e(o),zi(i,o),i._pack_prev=o,zi(o,r),r=i._pack_next,a=3;c>a;a++){Ui(i,r,o=n[a]);var f=0,g=1,m=1;for(s=r._pack_next;s!==r;s=s._pack_next,g++)if(Ni(s,o)){f=1;break}if(1==f)for(l=i._pack_prev;l!==s._pack_prev&&!Ni(l,o);l=l._pack_prev,m++);f?(m>g||g==m&&r.r<i.r?Bi(i,r=s):Bi(i=l,r),a--):(zi(i,o),r=o,e(o))}var y=(u+h)/2,v=(p+d)/2,C=0;for(a=0;c>a;a++)(o=n[a]).x-=y,o.y-=v,C=Math.max(C,o.r+Math.sqrt(o.x*o.x+o.y*o.y));t.r=C,n.forEach(Oi)}}function $i(t){t._pack_next=t._pack_prev=t}function Oi(t){delete t._pack_next,delete t._pack_prev}function Ui(t,e,n){var i=t.r+n.r,r=e.x-t.x,o=e.y-t.y;if(i&&(r||o)){var a=e.r+n.r,s=r*r+o*o,l=.5+((i*=i)-(a*=a))/(2*s),c=Math.sqrt(Math.max(0,2*a*(i+s)-(i-=s)*i-a*a))/(2*s);n.x=t.x+l*r+c*o,n.y=t.y+l*o-c*r}else n.x=t.x+i,n.y=t.y}function Ii(t,e){return t.parent==e.parent?1:2}function Ri(t){var e=t.children;return e.length?e[0]:t.t}function Yi(t){var e,n=t.children;return(e=n.length)?n[e-1]:t.t}function Zi(t,e,n){var i=n/(e.i-t.i);e.c-=i,e.s+=n,t.c+=i,e.z+=n,e.m+=n}function Hi(t,e,n){return t.a.parent===e.parent?t.a:n}function qi(t){return{x:t.x,y:t.y,dx:t.dx,dy:t.dy}}function ji(t,e){var n=t.x+e[3],i=t.y+e[0],r=t.dx-e[1]-e[3],o=t.dy-e[0]-e[2];return 0>r&&(n+=r/2,r=0),0>o&&(i+=o/2,o=0),{x:n,y:i,dx:r,dy:o}}function Ki(t){var e=t[0],n=t[t.length-1];return n>e?[e,n]:[n,e]}function Vi(t){return t.rangeExtent?t.rangeExtent():Ki(t.range())}function Wi(t,e,n,i){var r=n(t[0],t[1]),o=i(e[0],e[1]);return function(t){return o(r(t))}}function Xi(t,e){var n,i=0,r=t.length-1,o=t[i],a=t[r];return o>a&&(n=i,i=r,r=n,n=o,o=a,a=n),t[i]=e.floor(o),t[r]=e.ceil(a),t}function Gi(t,e,n,i){var r=[],o=[],a=0,s=Math.min(t.length,e.length)-1;for(t[s]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++a<=s;)r.push(n(t[a-1],t[a])),o.push(i(e[a-1],e[a]));return function(e){var n=Hr.bisect(t,e,1,s)-1;return o[n](r[n](e))}}function Qi(t,e){return Hr.rebind(t,e,"range","rangeRound","interpolate","clamp")}function Ji(t,e){return Xi(t,function(t){return t?{floor:function(e){return Math.floor(e/t)*t},ceil:function(e){return Math.ceil(e/t)*t}}:ls}(tr(t,e)[2]))}function tr(t,e){null==e&&(e=10);var n=Ki(t),i=n[1]-n[0],r=Math.pow(10,Math.floor(Math.log(i/e)/Math.LN10)),o=e/i*r;return.15>=o?r*=10:.35>=o?r*=5:.75>=o&&(r*=2),n[0]=Math.ceil(n[0]/r)*r,n[1]=Math.floor(n[1]/r)*r+.5*r,n[2]=r,n}function er(t,e){return Hr.range.apply(Hr,tr(t,e))}function nr(t,e,n){var i=tr(t,e);if(n){var r=Xo.exec(n);if(r.shift(),"s"===r[8]){var o=Hr.formatPrefix(Math.max(no(i[0]),no(i[1])));return r[7]||(r[7]="."+ir(o.scale(i[2]))),r[8]="f",n=Hr.format(r.join("")),function(t){return n(o.scale(t))+o.symbol}}r[7]||(r[7]="."+function(t,e){var n=ir(e[2]);return t in cs?Math.abs(n-ir(Math.max(no(e[0]),no(e[1]))))+ +("e"!==t):n-2*("%"===t)}(r[8],i)),n=r.join("")}else n=",."+ir(i[2])+"f";return Hr.format(n)}function ir(t){return-Math.floor(Math.log(t)/Math.LN10+.01)}function rr(t){return function(e){return 0>e?-Math.pow(-e,t):Math.pow(e,t)}}function or(){return 0}function ar(t){return t.innerRadius}function sr(t){return t.outerRadius}function lr(t){return t.startAngle}function cr(t){return t.endAngle}function ur(t){return t&&t.padAngle}function hr(t,e,n,i){return(t-n)*e-(e-i)*t>0?0:1}function pr(t,e,n,i,r){var o=t[0]-e[0],a=t[1]-e[1],s=(r?i:-i)/Math.sqrt(o*o+a*a),l=s*a,c=-s*o,u=t[0]+l,h=t[1]+c,p=e[0]+l,d=e[1]+c,f=(u+p)/2,g=(h+d)/2,m=p-u,y=d-h,v=m*m+y*y,C=n-i,b=u*d-p*h,x=(0>y?-1:1)*Math.sqrt(C*C*v-b*b),L=(b*y-m*x)/v,k=(-b*m-y*x)/v,w=(b*y+m*x)/v,_=(-b*m+y*x)/v,S=L-f,M=k-g,F=w-f,E=_-g;return S*S+M*M>F*F+E*E&&(L=w,k=_),[[L-l,k-c],[L*n/C,k*n/C]]}function dr(t){function e(e){function a(){c.push("M",o(t(u),s))}for(var l,c=[],u=[],h=-1,p=e.length,d=xt(n),f=xt(i);++h<p;)r.call(this,l=e[h],h)?u.push([+d.call(this,l,h),+f.call(this,l,h)]):u.length&&(a(),u=[]);return u.length&&a(),c.length?c.join(""):null}var n=sn,i=ln,r=ve,o=fr,a=o.key,s=.7;return e.x=function(t){return arguments.length?(n=t,e):n},e.y=function(t){return arguments.length?(i=t,e):i},e.defined=function(t){return arguments.length?(r=t,e):r},e.interpolate=function(t){return arguments.length?(a="function"==typeof t?o=t:(o=ys.get(t)||fr).key,e):a},e.tension=function(t){return arguments.length?(s=t,e):s},e}function fr(t){return t.join("L")}function gr(t){for(var e=0,n=t.length,i=t[0],r=[i[0],",",i[1]];++e<n;)r.push("V",(i=t[e])[1],"H",i[0]);return r.join("")}function mr(t){for(var e=0,n=t.length,i=t[0],r=[i[0],",",i[1]];++e<n;)r.push("H",(i=t[e])[0],"V",i[1]);return r.join("")}function yr(t,e){if(e.length<1||t.length!=e.length&&t.length!=e.length+2)return fr(t);var n=t.length!=e.length,i="",r=t[0],o=t[1],a=e[0],s=a,l=1;if(n&&(i+="Q"+(o[0]-2*a[0]/3)+","+(o[1]-2*a[1]/3)+","+o[0]+","+o[1],r=t[1],l=2),e.length>1){s=e[1],o=t[l],l++,i+="C"+(r[0]+a[0])+","+(r[1]+a[1])+","+(o[0]-s[0])+","+(o[1]-s[1])+","+o[0]+","+o[1];for(var c=2;c<e.length;c++,l++)o=t[l],s=e[c],i+="S"+(o[0]-s[0])+","+(o[1]-s[1])+","+o[0]+","+o[1]}if(n){var u=t[l];i+="Q"+(o[0]+2*s[0]/3)+","+(o[1]+2*s[1]/3)+","+u[0]+","+u[1]}return i}function vr(t,e){for(var n,i=[],r=(1-e)/2,o=t[0],a=t[1],s=1,l=t.length;++s<l;)n=o,o=a,a=t[s],i.push([r*(a[0]-n[0]),r*(a[1]-n[1])]);return i}function Cr(t){if(t.length<3)return fr(t);var e=1,n=t.length,i=t[0],r=i[0],o=i[1],a=[r,r,r,(i=t[1])[0]],s=[o,o,o,i[1]],l=[r,",",o,"L",br(bs,a),",",br(bs,s)];for(t.push(t[n-1]);++e<=n;)i=t[e],a.shift(),a.push(i[0]),s.shift(),s.push(i[1]),xr(l,a,s);return t.pop(),l.push("L",i),l.join("")}function br(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]+t[3]*e[3]}function xr(t,e,n){t.push("C",br(vs,e),",",br(vs,n),",",br(Cs,e),",",br(Cs,n),",",br(bs,e),",",br(bs,n))}function Lr(t,e){return(e[1]-t[1])/(e[0]-t[0])}function kr(t){for(var e,n,i,r,o=[],a=function(t){for(var e=0,n=t.length-1,i=[],r=t[0],o=t[1],a=i[0]=Lr(r,o);++e<n;)i[e]=(a+(a=Lr(r=o,o=t[e+1])))/2;return i[e]=a,i}(t),s=-1,l=t.length-1;++s<l;)e=Lr(t[s],t[s+1]),no(e)<xo?a[s]=a[s+1]=0:(r=(n=a[s]/e)*n+(i=a[s+1]/e)*i)>9&&(r=3*e/Math.sqrt(r),a[s]=r*n,a[s+1]=r*i);for(s=-1;++s<=l;)r=(t[Math.min(l,s+1)][0]-t[Math.max(0,s-1)][0])/(6*(1+a[s]*a[s])),o.push([r||0,a[s]*r||0]);return o}function wr(t){for(var e,n,i,r=-1,o=t.length;++r<o;)n=(e=t[r])[0],i=e[1]-So,e[0]=n*Math.cos(i),e[1]=n*Math.sin(i);return t}function _r(t){function e(e){function l(){g.push("M",s(t(y),h),u,c(t(m.reverse()),h),"Z")}for(var p,d,f,g=[],m=[],y=[],v=-1,C=e.length,b=xt(n),x=xt(r),L=n===i?function(){return d}:xt(i),k=r===o?function(){return f}:xt(o);++v<C;)a.call(this,p=e[v],v)?(m.push([d=+b.call(this,p,v),f=+x.call(this,p,v)]),y.push([+L.call(this,p,v),+k.call(this,p,v)])):m.length&&(l(),m=[],y=[]);return m.length&&l(),g.length?g.join(""):null}var n=sn,i=sn,r=0,o=ln,a=ve,s=fr,l=s.key,c=s,u="L",h=.7;return e.x=function(t){return arguments.length?(n=i=t,e):i},e.x0=function(t){return arguments.length?(n=t,e):n},e.x1=function(t){return arguments.length?(i=t,e):i},e.y=function(t){return arguments.length?(r=o=t,e):o},e.y0=function(t){return arguments.length?(r=t,e):r},e.y1=function(t){return arguments.length?(o=t,e):o},e.defined=function(t){return arguments.length?(a=t,e):a},e.interpolate=function(t){return arguments.length?(l="function"==typeof t?s=t:(s=ys.get(t)||fr).key,c=s.reverse||s,u=s.closed?"M":"L",e):l},e.tension=function(t){return arguments.length?(h=t,e):h},e}function Sr(t){return t.radius}function Mr(t){return[t.x,t.y]}function Fr(){return 64}function Er(){return"circle"}function Pr(t){var e=Math.sqrt(t/ko);return"M0,"+e+"A"+e+","+e+" 0 1,1 0,"+-e+"A"+e+","+e+" 0 1,1 0,"+e+"Z"}function Tr(t){return function(){var e,n;(e=this[t])&&(n=e[e.active])&&(--e.count?(delete e[e.active],e.active+=.5):delete this[t],n.event&&n.event.interrupt.call(this,this.__data__,n.index))}}function Ar(t,e,n){return so(t,Ms),t.namespace=e,t.id=n,t}function zr(t,e,n,i){var r=t.id,o=t.namespace;return U(t,"function"==typeof n?function(t,a,s){t[o][r].tween.set(e,i(n.call(t,t.__data__,a,s)))}:(n=i(n),function(t){t[o][r].tween.set(e,n)}))}function Br(t){return null==t&&(t=""),function(){this.textContent=t}}function Nr(t){return null==t?"__transition__":"__transition_"+t+"__"}function Dr(t,e,n,i,r){var o=t[n]||(t[n]={active:0,count:0}),s=o[i];if(!s){var l=r.time;s=o[i]={tween:new a,time:l,delay:r.delay,duration:r.duration,ease:r.ease,index:e},r=null,++o.count,Hr.timer(function(r){function a(n){if(o.active>i)return u();var r=o[o.active];r&&(--o.count,delete o[o.active],r.event&&r.event.interrupt.call(t,t.__data__,r.index)),o.active=i,s.event&&s.event.start.call(t,t.__data__,e),s.tween.forEach(function(n,i){(i=i.call(t,t.__data__,e))&&g.push(i)}),p=s.ease,h=s.duration,Hr.timer(function(){return f.c=c(n||1)?ve:c,1},0,l)}function c(n){if(o.active!==i)return 1;for(var r=n/h,a=p(r),l=g.length;l>0;)g[--l].call(t,a);return r>=1?(s.event&&s.event.end.call(t,t.__data__,e),u()):void 0}function u(){return--o.count?delete o[i]:delete t[n],1}var h,p,d=s.delay,f=Ko,g=[];return f.t=d+l,r>=d?a(r-d):void(f.c=a)},0,l)}}function $r(t,e,n){t.attr("transform",function(t){var i=e(t);return"translate("+(isFinite(i)?i:n(t))+",0)"})}function Or(t,e,n){t.attr("transform",function(t){var i=e(t);return"translate(0,"+(isFinite(i)?i:n(t))+")"})}function Ur(t){return t.toISOString()}function Ir(t,e,n){function i(e){return t(e)}function r(t,n){var i=(t[1]-t[0])/n,r=Hr.bisect(Ds,i);return r==Ds.length?[e.year,tr(t.map(function(t){return t/31536e6}),n)[2]]:r?e[i/Ds[r-1]<Ds[r]/i?r-1:r]:[Us,tr(t,n)[2]]}return i.invert=function(e){return Rr(t.invert(e))},i.domain=function(e){return arguments.length?(t.domain(e),i):t.domain().map(Rr)},i.nice=function(t,e){function n(n){return!isNaN(n)&&!t.range(n,Rr(+n+1),e).length}var o=i.domain(),a=Ki(o),s=null==t?r(a,10):"number"==typeof t&&r(a,t);return s&&(t=s[0],e=s[1]),i.domain(Xi(o,e>1?{floor:function(e){for(;n(e=t.floor(e));)e=Rr(e-1);return e},ceil:function(e){for(;n(e=t.ceil(e));)e=Rr(+e+1);return e}}:t))},i.ticks=function(t,e){var n=Ki(i.domain()),o=null==t?r(n,10):"number"==typeof t?r(n,t):!t.range&&[{range:t},e];return o&&(t=o[0],e=o[1]),t.range(n[0],Rr(+n[1]+1),1>e?1:e)},i.tickFormat=function(){return n},i.copy=function(){return Ir(t.copy(),e,n)},Qi(i,t)}function Rr(t){return new Date(t)}function Yr(t){return JSON.parse(t.responseText)}function Zr(t){var e=Kr.createRange();return e.selectNode(Kr.body),e.createContextualFragment(t.responseText)}var Hr={version:"3.5.2"};Date.now||(Date.now=function(){return+new Date});var qr=[].slice,jr=function(t){return qr.call(t)},Kr=document,Vr=Kr.documentElement,Wr=window;try{jr(Vr.childNodes)[0].nodeType}catch(t){jr=function(t){for(var e=t.length,n=new Array(e);e--;)n[e]=t[e];return n}}try{Kr.createElement("div").style.setProperty("opacity",0,"")}catch(t){var Xr=Wr.Element.prototype,Gr=Xr.setAttribute,Qr=Xr.setAttributeNS,Jr=Wr.CSSStyleDeclaration.prototype,to=Jr.setProperty;Xr.setAttribute=function(t,e){Gr.call(this,t,e+"")},Xr.setAttributeNS=function(t,e,n){Qr.call(this,t,e,n+"")},Jr.setProperty=function(t,e,n){to.call(this,t,e+"",n)}}Hr.ascending=t,Hr.descending=function(t,e){return t>e?-1:e>t?1:e>=t?0:NaN},Hr.min=function(t,e){var n,i,r=-1,o=t.length;if(1===arguments.length){for(;++r<o;)if(null!=(i=t[r])&&i>=i){n=i;break}for(;++r<o;)null!=(i=t[r])&&n>i&&(n=i)}else{for(;++r<o;)if(null!=(i=e.call(t,t[r],r))&&i>=i){n=i;break}for(;++r<o;)null!=(i=e.call(t,t[r],r))&&n>i&&(n=i)}return n},Hr.max=function(t,e){var n,i,r=-1,o=t.length;if(1===arguments.length){for(;++r<o;)if(null!=(i=t[r])&&i>=i){n=i;break}for(;++r<o;)null!=(i=t[r])&&i>n&&(n=i)}else{for(;++r<o;)if(null!=(i=e.call(t,t[r],r))&&i>=i){n=i;break}for(;++r<o;)null!=(i=e.call(t,t[r],r))&&i>n&&(n=i)}return n},Hr.extent=function(t,e){var n,i,r,o=-1,a=t.length;if(1===arguments.length){for(;++o<a;)if(null!=(i=t[o])&&i>=i){n=r=i;break}for(;++o<a;)null!=(i=t[o])&&(n>i&&(n=i),i>r&&(r=i))}else{for(;++o<a;)if(null!=(i=e.call(t,t[o],o))&&i>=i){n=r=i;break}for(;++o<a;)null!=(i=e.call(t,t[o],o))&&(n>i&&(n=i),i>r&&(r=i))}return[n,r]},Hr.sum=function(t,e){var i,r=0,o=t.length,a=-1;if(1===arguments.length)for(;++a<o;)n(i=+t[a])&&(r+=i);else for(;++a<o;)n(i=+e.call(t,t[a],a))&&(r+=i);return r},Hr.mean=function(t,i){var r,o=0,a=t.length,s=-1,l=a;if(1===arguments.length)for(;++s<a;)n(r=e(t[s]))?o+=r:--l;else for(;++s<a;)n(r=e(i.call(t,t[s],s)))?o+=r:--l;return l?o/l:void 0},Hr.quantile=function(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],o=n-i;return o?r+o*(t[i]-r):r},Hr.median=function(i,r){var o,a=[],s=i.length,l=-1;if(1===arguments.length)for(;++l<s;)n(o=e(i[l]))&&a.push(o);else for(;++l<s;)n(o=e(r.call(i,i[l],l)))&&a.push(o);return a.length?Hr.quantile(a.sort(t),.5):void 0},Hr.variance=function(t,i){var r,o,a=t.length,s=0,l=0,c=-1,u=0;if(1===arguments.length)for(;++c<a;)n(r=e(t[c]))&&(l+=(o=r-s)*(r-(s+=o/++u)));else for(;++c<a;)n(r=e(i.call(t,t[c],c)))&&(l+=(o=r-s)*(r-(s+=o/++u)));return u>1?l/(u-1):void 0},Hr.deviation=function(){var t=Hr.variance.apply(this,arguments);return t?Math.sqrt(t):t};var eo=i(t);Hr.bisectLeft=eo.left,Hr.bisect=Hr.bisectRight=eo.right,Hr.bisector=function(e){return i(1===e.length?function(n,i){return t(e(n),i)}:e)},Hr.shuffle=function(t,e,n){(o=arguments.length)<3&&(n=t.length,2>o&&(e=0));for(var i,r,o=n-e;o;)r=0|Math.random()*o--,i=t[o+e],t[o+e]=t[r+e],t[r+e]=i;return t},Hr.permute=function(t,e){for(var n=e.length,i=new Array(n);n--;)i[n]=t[e[n]];return i},Hr.pairs=function(t){for(var e=0,n=t.length-1,i=t[0],r=new Array(0>n?0:n);n>e;)r[e]=[i,i=t[++e]];return r},Hr.zip=function(){if(!(i=arguments.length))return[];for(var t=-1,e=Hr.min(arguments,r),n=new Array(e);++t<e;)for(var i,o=-1,a=n[t]=new Array(i);++o<i;)a[o]=arguments[o][t];return n},Hr.transpose=function(t){return Hr.zip.apply(Hr,t)},Hr.keys=function(t){var e=[];for(var n in t)e.push(n);return e},Hr.values=function(t){var e=[];for(var n in t)e.push(t[n]);return e},Hr.entries=function(t){var e=[];for(var n in t)e.push({key:n,value:t[n]});return e},Hr.merge=function(t){for(var e,n,i,r=t.length,o=-1,a=0;++o<r;)a+=t[o].length;for(n=new Array(a);--r>=0;)for(e=(i=t[r]).length;--e>=0;)n[--a]=i[e];return n};var no=Math.abs;Hr.range=function(t,e,n){if(arguments.length<3&&(n=1,arguments.length<2&&(e=t,t=0)),1/0==(e-t)/n)throw new Error("infinite range");var i,r=[],o=function(t){for(var e=1;t*e%1;)e*=10;return e}(no(n)),a=-1;if(t*=o,e*=o,0>(n*=o))for(;(i=t+n*++a)>e;)r.push(i/o);else for(;(i=t+n*++a)<e;)r.push(i/o);return r},Hr.map=function(t,e){var n=new a;if(t instanceof a)t.forEach(function(t,e){n.set(t,e)});else if(Array.isArray(t)){var i,r=-1,o=t.length;if(1===arguments.length)for(;++r<o;)n.set(r,t[r]);else for(;++r<o;)n.set(e.call(t,i=t[r],r),i)}else for(var s in t)n.set(s,t[s]);return n};var io="__proto__",ro="\0";o(a,{has:c,get:function(t){return this._[s(t)]},set:function(t,e){return this._[s(t)]=e},remove:u,keys:h,values:function(){var t=[];for(var e in this._)t.push(this._[e]);return t},entries:function(){var t=[];for(var e in this._)t.push({key:l(e),value:this._[e]});return t},size:p,empty:d,forEach:function(t){for(var e in this._)t.call(this,l(e),this._[e])}}),Hr.nest=function(){function t(o,s,l){if(l>=r.length)return n?n.call(i,s):e?s.sort(e):s;for(var c,u,h,p,d=-1,f=s.length,g=r[l++],m=new a;++d<f;)(p=m.get(c=g(u=s[d])))?p.push(u):m.set(c,[u]);return o?(u=o(),h=function(e,n){u.set(e,t(o,n,l))}):(u={},h=function(e,n){u[e]=t(o,n,l)}),m.forEach(h),u}var e,n,i={},r=[],o=[];return i.map=function(e,n){return t(n,e,0)},i.entries=function(e){return function t(e,n){if(n>=r.length)return e;var i=[],a=o[n++];return e.forEach(function(e,r){i.push({key:e,values:t(r,n)})}),a?i.sort(function(t,e){return a(t.key,e.key)}):i}(t(Hr.map,e,0),0)},i.key=function(t){return r.push(t),i},i.sortKeys=function(t){return o[r.length-1]=t,i},i.sortValues=function(t){return e=t,i},i.rollup=function(t){return n=t,i},i},Hr.set=function(t){var e=new f;if(t)for(var n=0,i=t.length;i>n;++n)e.add(t[n]);return e},o(f,{has:c,add:function(t){return this._[s(t+="")]=!0,t},remove:u,values:h,size:p,empty:d,forEach:function(t){for(var e in this._)t.call(this,l(e))}}),Hr.behavior={},Hr.rebind=function(t,e){for(var n,i=1,r=arguments.length;++i<r;)t[n=arguments[i]]=g(t,e,e[n]);return t};var oo=["webkit","ms","moz","Moz","o","O"];Hr.dispatch=function(){for(var t=new v,e=-1,n=arguments.length;++e<n;)t[arguments[e]]=C(t);return t},v.prototype.on=function(t,e){var n=t.indexOf("."),i="";if(n>=0&&(i=t.slice(n+1),t=t.slice(0,n)),t)return arguments.length<2?this[t].on(i):this[t].on(i,e);if(2===arguments.length){if(null==e)for(t in this)this.hasOwnProperty(t)&&this[t].on(i,null);return this}},Hr.event=null,Hr.requote=function(t){return t.replace(ao,"\\$&")};var ao=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g,so={}.__proto__?function(t,e){t.__proto__=e}:function(t,e){for(var n in e)t[n]=e[n]},lo=function(t,e){return e.querySelector(t)},co=function(t,e){return e.querySelectorAll(t)},uo=Vr.matches||Vr[m(Vr,"matchesSelector")],ho=function(t,e){return uo.call(t,e)};"function"==typeof Sizzle&&(lo=function(t,e){return Sizzle(t,e)[0]||null},co=Sizzle,ho=Sizzle.matchesSelector),Hr.selection=function(){return mo};var po=Hr.selection.prototype=[];po.select=function(t){var e,n,i,r,o=[];t=w(t);for(var a=-1,s=this.length;++a<s;){o.push(e=[]),e.parentNode=(i=this[a]).parentNode;for(var l=-1,c=i.length;++l<c;)(r=i[l])?(e.push(n=t.call(r,r.__data__,l,a)),n&&"__data__"in r&&(n.__data__=r.__data__)):e.push(null)}return k(o)},po.selectAll=function(t){var e,n,i=[];t=_(t);for(var r=-1,o=this.length;++r<o;)for(var a=this[r],s=-1,l=a.length;++s<l;)(n=a[s])&&(i.push(e=jr(t.call(n,n.__data__,s,r))),e.parentNode=n);return k(i)};var fo={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};Hr.ns={prefix:fo,qualify:function(t){var e=t.indexOf(":"),n=t;return e>=0&&(n=t.slice(0,e),t=t.slice(e+1)),fo.hasOwnProperty(n)?{space:fo[n],local:t}:t}},po.attr=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node();return(t=Hr.ns.qualify(t)).local?n.getAttributeNS(t.space,t.local):n.getAttribute(t)}for(e in t)this.each(S(e,t[e]));return this}return this.each(S(t,e))},po.classed=function(t,e){if(arguments.length<2){if("string"==typeof t){var n=this.node(),i=(t=E(t)).length,r=-1;if(e=n.classList){for(;++r<i;)if(!e.contains(t[r]))return!1}else for(e=n.getAttribute("class");++r<i;)if(!F(t[r]).test(e))return!1;return!0}for(e in t)this.each(P(e,t[e]));return this}return this.each(P(t,e))},po.style=function(t,e,n){var i=arguments.length;if(3>i){if("string"!=typeof t){for(n in 2>i&&(e=""),t)this.each(A(n,t[n],e));return this}if(2>i)return Wr.getComputedStyle(this.node(),null).getPropertyValue(t);n=""}return this.each(A(t,e,n))},po.property=function(t,e){if(arguments.length<2){if("string"==typeof t)return this.node()[t];for(e in t)this.each(z(e,t[e]));return this}return this.each(z(t,e))},po.text=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}:null==t?function(){this.textContent=""}:function(){this.textContent=t}):this.node().textContent},po.html=function(t){return arguments.length?this.each("function"==typeof t?function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}:null==t?function(){this.innerHTML=""}:function(){this.innerHTML=t}):this.node().innerHTML},po.append=function(t){return t=B(t),this.select(function(){return this.appendChild(t.apply(this,arguments))})},po.insert=function(t,e){return t=B(t),e=w(e),this.select(function(){return this.insertBefore(t.apply(this,arguments),e.apply(this,arguments)||null)})},po.remove=function(){return this.each(N)},po.data=function(t,e){function n(t,n){var i,r,o,s=t.length,h=n.length,p=Math.min(s,h),d=new Array(h),f=new Array(h),g=new Array(s);if(e){var m,y=new a,v=new Array(s);for(i=-1;++i<s;)y.has(m=e.call(r=t[i],r.__data__,i))?g[i]=r:y.set(m,r),v[i]=m;for(i=-1;++i<h;)(r=y.get(m=e.call(n,o=n[i],i)))?!0!==r&&(d[i]=r,r.__data__=o):f[i]=D(o),y.set(m,!0);for(i=-1;++i<s;)!0!==y.get(v[i])&&(g[i]=t[i])}else{for(i=-1;++i<p;)r=t[i],o=n[i],r?(r.__data__=o,d[i]=r):f[i]=D(o);for(;h>i;++i)f[i]=D(n[i]);for(;s>i;++i)g[i]=t[i]}f.update=d,f.parentNode=d.parentNode=g.parentNode=t.parentNode,l.push(f),c.push(d),u.push(g)}var i,r,o=-1,s=this.length;if(!arguments.length){for(t=new Array(s=(i=this[0]).length);++o<s;)(r=i[o])&&(t[o]=r.__data__);return t}var l=I([]),c=k([]),u=k([]);if("function"==typeof t)for(;++o<s;)n(i=this[o],t.call(i,i.parentNode.__data__,o));else for(;++o<s;)n(i=this[o],t);return c.enter=function(){return l},c.exit=function(){return u},c},po.datum=function(t){return arguments.length?this.property("__data__",t):this.property("__data__")},po.filter=function(t){var e,n,i,r=[];"function"!=typeof t&&(t=$(t));for(var o=0,a=this.length;a>o;o++){r.push(e=[]),e.parentNode=(n=this[o]).parentNode;for(var s=0,l=n.length;l>s;s++)(i=n[s])&&t.call(i,i.__data__,s,o)&&e.push(i)}return k(r)},po.order=function(){for(var t=-1,e=this.length;++t<e;)for(var n,i=this[t],r=i.length-1,o=i[r];--r>=0;)(n=i[r])&&(o&&o!==n.nextSibling&&o.parentNode.insertBefore(n,o),o=n);return this},po.sort=function(t){t=O.apply(this,arguments);for(var e=-1,n=this.length;++e<n;)this[e].sort(t);return this.order()},po.each=function(t){return U(this,function(e,n,i){t.call(e,e.__data__,n,i)})},po.call=function(t){var e=jr(arguments);return t.apply(e[0]=this,e),this},po.empty=function(){return!this.node()},po.node=function(){for(var t=0,e=this.length;e>t;t++)for(var n=this[t],i=0,r=n.length;r>i;i++){var o=n[i];if(o)return o}return null},po.size=function(){var t=0;return U(this,function(){++t}),t};var go=[];Hr.selection.enter=I,Hr.selection.enter.prototype=go,go.append=po.append,go.empty=po.empty,go.node=po.node,go.call=po.call,go.size=po.size,go.select=function(t){for(var e,n,i,r,o,a=[],s=-1,l=this.length;++s<l;){i=(r=this[s]).update,a.push(e=[]),e.parentNode=r.parentNode;for(var c=-1,u=r.length;++c<u;)(o=r[c])?(e.push(i[c]=n=t.call(r.parentNode,o.__data__,c,s)),n.__data__=o.__data__):e.push(null)}return k(a)},go.insert=function(t,e){return arguments.length<2&&(e=function(t){var e,n;return function(i,r,o){var a,s=t[o].update,l=s.length;for(o!=n&&(n=o,e=0),r>=e&&(e=r+1);!(a=s[e])&&++e<l;);return a}}(this)),po.insert.call(this,t,e)},Hr.select=function(t){var e=["string"==typeof t?lo(t,Kr):t];return e.parentNode=Vr,k([e])},Hr.selectAll=function(t){var e=jr("string"==typeof t?co(t,Kr):t);return e.parentNode=Vr,k([e])};var mo=Hr.select(Vr);po.on=function(t,e,n){var i=arguments.length;if(3>i){if("string"!=typeof t){for(n in 2>i&&(e=!1),t)this.each(R(n,t[n],e));return this}if(2>i)return(i=this.node()["__on"+t])&&i._;n=!1}return this.each(R(t,e,n))};var yo=Hr.map({mouseenter:"mouseover",mouseleave:"mouseout"});yo.forEach(function(t){"on"+t in Kr&&yo.remove(t)});var vo="onselectstart"in Kr?null:m(Vr.style,"userSelect"),Co=0;Hr.mouse=function(t){return q(t,x())};var bo=/WebKit/.test(Wr.navigator.userAgent)?-1:0;Hr.touch=function(t,e,n){if(arguments.length<3&&(n=e,e=x().changedTouches),e)for(var i,r=0,o=e.length;o>r;++r)if((i=e[r]).identifier===n)return q(t,i)},Hr.behavior.drag=function(){function t(){this.on("mousedown.drag",r).on("touchstart.drag",o)}function e(t,e,r,o,a){return function(){var s,l=this,c=Hr.event.target,u=l.parentNode,h=n.of(l,arguments),p=0,d=t(),f=".drag"+(null==d?"":"-"+d),g=Hr.select(r()).on(o+f,function(){var t,n,i=e(u,d);i&&(t=i[0]-y[0],n=i[1]-y[1],p|=t|n,y=i,h({type:"drag",x:i[0]+s[0],y:i[1]+s[1],dx:t,dy:n}))}).on(a+f,function(){e(u,d)&&(g.on(o+f,null).on(a+f,null),m(p&&Hr.event.target===c),h({type:"dragend"}))}),m=H(),y=e(u,d);i?s=[(s=i.apply(l,arguments)).x-y[0],s.y-y[1]]:s=[0,0],h({type:"dragstart"})}}var n=L(t,"drag","dragstart","dragend"),i=null,r=e(y,Hr.mouse,V,"mousemove","mouseup"),o=e(j,Hr.touch,K,"touchmove","touchend");return t.origin=function(e){return arguments.length?(i=e,t):i},Hr.rebind(t,n,"on")},Hr.touches=function(t,e){return arguments.length<2&&(e=x().touches),e?jr(e).map(function(e){var n=q(t,e);return n.identifier=e.identifier,n}):[]};var xo=1e-6,Lo=xo*xo,ko=Math.PI,wo=2*ko,_o=wo-xo,So=ko/2,Mo=ko/180,Fo=180/ko,Eo=Math.SQRT2,Po=2;Hr.interpolateZoom=function(t,e){function n(t){var e=t*y;if(m){var n=J(g),a=o/(Po*p)*(n*function(t){return((t=Math.exp(2*t))-1)/(t+1)}(Eo*e+g)-function(t){return((t=Math.exp(t))-1/t)/2}(g));return[i+a*c,r+a*u,o*n/J(Eo*e+g)]}return[i+t*c,r+t*u,o*Math.exp(Eo*e)]}var i=t[0],r=t[1],o=t[2],a=e[0],s=e[1],l=e[2],c=a-i,u=s-r,h=c*c+u*u,p=Math.sqrt(h),d=(l*l-o*o+4*h)/(2*o*Po*p),f=(l*l-o*o-4*h)/(2*l*Po*p),g=Math.log(Math.sqrt(d*d+1)-d),m=Math.log(Math.sqrt(f*f+1)-f)-g,y=(m||Math.log(l/o))/Eo;return n.duration=1e3*y,n},Hr.behavior.zoom=function(){function t(t){t.on(E,c).on(zo+".zoom",h).on("dblclick.zoom",p).on(A,u)}function e(t){return[(t[0]-w.x)/w.k,(t[1]-w.y)/w.k]}function n(t){w.k=Math.max(S[0],Math.min(S[1],t))}function i(t,e){e=function(t){return[t[0]*w.k+w.x,t[1]*w.k+w.y]}(e),w.x+=t[0]-e[0],w.y+=t[1]-e[1]}function r(e,r,o,a){e.__chart__={x:w.x,y:w.y,k:w.k},n(Math.pow(2,a)),i(f=r,o),e=Hr.select(e),M>0&&(e=e.transition().duration(M)),e.call(t.event)}function o(){C&&C.domain(v.range().map(function(t){return(t-w.x)/w.k}).map(v.invert)),k&&k.domain(x.range().map(function(t){return(t-w.y)/w.k}).map(x.invert))}function a(t){F++||t({type:"zoomstart"})}function s(t){o(),t({type:"zoom",scale:w.k,translate:[w.x,w.y]})}function l(t){--F||t({type:"zoomend"}),f=null}function c(){var t=this,n=Hr.event.target,r=z.of(t,arguments),o=0,c=Hr.select(Wr).on(P,function(){o=1,i(Hr.mouse(t),u),s(r)}).on(T,function(){c.on(P,null).on(T,null),h(o&&Hr.event.target===n),l(r)}),u=e(Hr.mouse(t)),h=H();Ss.call(t),a(r)}function u(){function t(){var t=Hr.touches(f);return d=w.k,t.forEach(function(t){t.identifier in m&&(m[t.identifier]=e(t))}),t}function o(){var e=Hr.event.target;Hr.select(e).on(x,h).on(L,p),k.push(e);for(var n=Hr.event.changedTouches,i=0,o=n.length;o>i;++i)m[n[i].identifier]=null;var a=t(),s=Date.now();if(1===a.length){if(500>s-y){var l=a[0];r(f,l,m[l.identifier],Math.floor(Math.log(w.k)/Math.LN2)+1),b()}y=s}else if(a.length>1){l=a[0];var c=a[1],u=l[0]-c[0],d=l[1]-c[1];v=u*u+d*d}}function h(){var t,e,r,o,a=Hr.touches(f);Ss.call(f);for(var l=0,c=a.length;c>l;++l,o=null)if(r=a[l],o=m[r.identifier]){if(e)break;t=r,e=o}if(o){var u=(u=r[0]-t[0])*u+(u=r[1]-t[1])*u,h=v&&Math.sqrt(u/v);t=[(t[0]+r[0])/2,(t[1]+r[1])/2],e=[(e[0]+o[0])/2,(e[1]+o[1])/2],n(h*d)}y=null,i(t,e),s(g)}function p(){if(Hr.event.touches.length){for(var e=Hr.event.changedTouches,n=0,i=e.length;i>n;++n)delete m[e[n].identifier];for(var r in m)return void t()}Hr.selectAll(k).on(C,null),_.on(E,c).on(A,u),S(),l(g)}var d,f=this,g=z.of(f,arguments),m={},v=0,C=".zoom-"+Hr.event.changedTouches[0].identifier,x="touchmove"+C,L="touchend"+C,k=[],_=Hr.select(f),S=H();o(),a(g),_.on(E,null).on(A,o)}function h(){var t=z.of(this,arguments);m?clearTimeout(m):(d=e(f=g||Hr.mouse(this)),Ss.call(this),a(t)),m=setTimeout(function(){m=null,l(t)},50),b(),n(Math.pow(2,.002*To())*w.k),i(f,d),s(t)}function p(){var t=Hr.mouse(this),n=Math.log(w.k)/Math.LN2;r(this,t,e(t),Hr.event.shiftKey?Math.ceil(n)-1:Math.floor(n)+1)}var d,f,g,m,y,v,C,x,k,w={x:0,y:0,k:1},_=[960,500],S=Ao,M=250,F=0,E="mousedown.zoom",P="mousemove.zoom",T="mouseup.zoom",A="touchstart.zoom",z=L(t,"zoomstart","zoom","zoomend");return t.event=function(t){t.each(function(){var t=z.of(this,arguments),e=w;ws?Hr.select(this).transition().each("start.zoom",function(){w=this.__chart__||{x:0,y:0,k:1},a(t)}).tween("zoom:zoom",function(){var n=_[0],i=_[1],r=f?f[0]:n/2,o=f?f[1]:i/2,a=Hr.interpolateZoom([(r-w.x)/w.k,(o-w.y)/w.k,n/w.k],[(r-e.x)/e.k,(o-e.y)/e.k,n/e.k]);return function(e){var i=a(e),l=n/i[2];this.__chart__=w={x:r-i[0]*l,y:o-i[1]*l,k:l},s(t)}}).each("interrupt.zoom",function(){l(t)}).each("end.zoom",function(){l(t)}):(this.__chart__=w,a(t),s(t),l(t))})},t.translate=function(e){return arguments.length?(w={x:+e[0],y:+e[1],k:w.k},o(),t):[w.x,w.y]},t.scale=function(e){return arguments.length?(w={x:w.x,y:w.y,k:+e},o(),t):w.k},t.scaleExtent=function(e){return arguments.length?(S=null==e?Ao:[+e[0],+e[1]],t):S},t.center=function(e){return arguments.length?(g=e&&[+e[0],+e[1]],t):g},t.size=function(e){return arguments.length?(_=e&&[+e[0],+e[1]],t):_},t.duration=function(e){return arguments.length?(M=+e,t):M},t.x=function(e){return arguments.length?(C=e,v=e.copy(),w={x:0,y:0,k:1},t):C},t.y=function(e){return arguments.length?(k=e,x=e.copy(),w={x:0,y:0,k:1},t):k},Hr.rebind(t,z,"on")};var To,Ao=[0,1/0],zo="onwheel"in Kr?(To=function(){return-Hr.event.deltaY*(Hr.event.deltaMode?120:1)},"wheel"):"onmousewheel"in Kr?(To=function(){return Hr.event.wheelDelta},"mousewheel"):(To=function(){return-Hr.event.detail},"MozMousePixelScroll");Hr.color=et,et.prototype.toString=function(){return this.rgb()+""},Hr.hsl=nt;var Bo=nt.prototype=new et;Bo.brighter=function(t){return t=Math.pow(.7,arguments.length?t:1),new nt(this.h,this.s,this.l/t)},Bo.darker=function(t){return t=Math.pow(.7,arguments.length?t:1),new nt(this.h,this.s,t*this.l)},Bo.rgb=function(){return it(this.h,this.s,this.l)},Hr.hcl=rt;var No=rt.prototype=new et;No.brighter=function(t){return new rt(this.h,this.c,Math.min(100,this.l+Do*(arguments.length?t:1)))},No.darker=function(t){return new rt(this.h,this.c,Math.max(0,this.l-Do*(arguments.length?t:1)))},No.rgb=function(){return ot(this.h,this.c,this.l).rgb()},Hr.lab=at;var Do=18,$o=.95047,Oo=1,Uo=1.08883,Io=at.prototype=new et;Io.brighter=function(t){return new at(Math.min(100,this.l+Do*(arguments.length?t:1)),this.a,this.b)},Io.darker=function(t){return new at(Math.max(0,this.l-Do*(arguments.length?t:1)),this.a,this.b)},Io.rgb=function(){return st(this.l,this.a,this.b)},Hr.rgb=pt;var Ro=pt.prototype=new et;Ro.brighter=function(t){t=Math.pow(.7,arguments.length?t:1);var e=this.r,n=this.g,i=this.b,r=30;return e||n||i?(e&&r>e&&(e=r),n&&r>n&&(n=r),i&&r>i&&(i=r),new pt(Math.min(255,e/t),Math.min(255,n/t),Math.min(255,i/t))):new pt(r,r,r)},Ro.darker=function(t){return new pt((t=Math.pow(.7,arguments.length?t:1))*this.r,t*this.g,t*this.b)},Ro.hsl=function(){return yt(this.r,this.g,this.b)},Ro.toString=function(){return"#"+gt(this.r)+gt(this.g)+gt(this.b)};var Yo=Hr.map({aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074});Yo.forEach(function(t,e){Yo.set(t,dt(e))}),Hr.functor=xt,Hr.xhr=kt(Lt),Hr.dsv=function(t,e){function n(t,n,o){arguments.length<3&&(o=n,n=null);var a=wt(t,e,null==n?i:r(n),o);return a.row=function(t){return arguments.length?a.response(null==(n=t)?i:r(t)):n},a}function i(t){return n.parse(t.responseText)}function r(t){return function(e){return n.parse(e.responseText,t)}}function o(e){return e.map(a).join(t)}function a(t){return s.test(t)?'"'+t.replace(/\"/g,'""')+'"':t}var s=new RegExp('["'+t+"\n]"),l=t.charCodeAt(0);return n.parse=function(t,e){var i;return n.parseRows(t,function(t,n){if(i)return i(t,n-1);var r=new Function("d","return {"+t.map(function(t,e){return JSON.stringify(t)+": d["+e+"]"}).join(",")+"}");i=e?function(t,n){return e(r(t),n)}:r})},n.parseRows=function(t,e){function n(){if(u>=c)return a;if(r)return r=!1,o;var e=u;if(34===t.charCodeAt(e)){for(var n=e;n++<c;)if(34===t.charCodeAt(n)){if(34!==t.charCodeAt(n+1))break;++n}return u=n+2,13===(i=t.charCodeAt(n+1))?(r=!0,10===t.charCodeAt(n+2)&&++u):10===i&&(r=!0),t.slice(e+1,n).replace(/""/g,'"')}for(;c>u;){var i,s=1;if(10===(i=t.charCodeAt(u++)))r=!0;else if(13===i)r=!0,10===t.charCodeAt(u)&&(++u,++s);else if(i!==l)continue;return t.slice(e,u-s)}return t.slice(e)}for(var i,r,o={},a={},s=[],c=t.length,u=0,h=0;(i=n())!==a;){for(var p=[];i!==o&&i!==a;)p.push(i),i=n();e&&null==(p=e(p,h++))||s.push(p)}return s},n.format=function(e){if(Array.isArray(e[0]))return n.formatRows(e);var i=new f,r=[];return e.forEach(function(t){for(var e in t)i.has(e)||r.push(i.add(e))}),[r.map(a).join(t)].concat(e.map(function(e){return r.map(function(t){return a(e[t])}).join(t)})).join("\n")},n.formatRows=function(t){return t.map(o).join("\n")},n},Hr.csv=Hr.dsv(",","text/csv"),Hr.tsv=Hr.dsv("\t","text/tab-separated-values");var Zo,Ho,qo,jo,Ko,Vo=Wr[m(Wr,"requestAnimationFrame")]||function(t){setTimeout(t,17)};Hr.timer=function(t,e,n){var i=arguments.length;2>i&&(e=0),3>i&&(n=Date.now());var r={c:t,t:n+e,f:!1,n:null};Ho?Ho.n=r:Zo=r,Ho=r,qo||(jo=clearTimeout(jo),qo=1,Vo(_t))},Hr.timer.flush=function(){St(),Mt()},Hr.round=function(t,e){return e?Math.round(t*(e=Math.pow(10,e)))/e:Math.round(t)};var Wo=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"].map(function(t,e){var n=Math.pow(10,3*no(8-e));return{scale:e>8?function(t){return t/n}:function(t){return t*n},symbol:t}});Hr.formatPrefix=function(t,e){var n=0;return t&&(0>t&&(t*=-1),e&&(t=Hr.round(t,Ft(t,e))),n=1+Math.floor(1e-12+Math.log(t)/Math.LN10),n=Math.max(-24,Math.min(24,3*Math.floor((n-1)/3)))),Wo[8+n/3]};var Xo=/(?:([^{])?([<>=^]))?([+\- ])?([$#])?(0)?(\d+)?(,)?(\.-?\d+)?([a-z%])?/i,Go=Hr.map({b:function(t){return t.toString(2)},c:function(t){return String.fromCharCode(t)},o:function(t){return t.toString(8)},x:function(t){return t.toString(16)},X:function(t){return t.toString(16).toUpperCase()},g:function(t,e){return t.toPrecision(e)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},r:function(t,e){return(t=Hr.round(t,Ft(t,e))).toFixed(Math.max(0,Math.min(20,Ft(t*(1+1e-15),e))))}}),Qo=Hr.time={},Jo=Date;Pt.prototype={getDate:function(){return this._.getUTCDate()},getDay:function(){return this._.getUTCDay()},getFullYear:function(){return this._.getUTCFullYear()},getHours:function(){return this._.getUTCHours()},getMilliseconds:function(){return this._.getUTCMilliseconds()},getMinutes:function(){return this._.getUTCMinutes()},getMonth:function(){return this._.getUTCMonth()},getSeconds:function(){return this._.getUTCSeconds()},getTime:function(){return this._.getTime()},getTimezoneOffset:function(){return 0},valueOf:function(){return this._.valueOf()},setDate:function(){ta.setUTCDate.apply(this._,arguments)},setDay:function(){ta.setUTCDay.apply(this._,arguments)},setFullYear:function(){ta.setUTCFullYear.apply(this._,arguments)},setHours:function(){ta.setUTCHours.apply(this._,arguments)},setMilliseconds:function(){ta.setUTCMilliseconds.apply(this._,arguments)},setMinutes:function(){ta.setUTCMinutes.apply(this._,arguments)},setMonth:function(){ta.setUTCMonth.apply(this._,arguments)},setSeconds:function(){ta.setUTCSeconds.apply(this._,arguments)},setTime:function(){ta.setTime.apply(this._,arguments)}};var ta=Date.prototype;Qo.year=Tt(function(t){return(t=Qo.day(t)).setMonth(0,1),t},function(t,e){t.setFullYear(t.getFullYear()+e)},function(t){return t.getFullYear()}),Qo.years=Qo.year.range,Qo.years.utc=Qo.year.utc.range,Qo.day=Tt(function(t){var e=new Jo(2e3,0);return e.setFullYear(t.getFullYear(),t.getMonth(),t.getDate()),e},function(t,e){t.setDate(t.getDate()+e)},function(t){return t.getDate()-1}),Qo.days=Qo.day.range,Qo.days.utc=Qo.day.utc.range,Qo.dayOfYear=function(t){var e=Qo.year(t);return Math.floor((t-e-6e4*(t.getTimezoneOffset()-e.getTimezoneOffset()))/864e5)},["sunday","monday","tuesday","wednesday","thursday","friday","saturday"].forEach(function(t,e){e=7-e;var n=Qo[t]=Tt(function(t){return(t=Qo.day(t)).setDate(t.getDate()-(t.getDay()+e)%7),t},function(t,e){t.setDate(t.getDate()+7*Math.floor(e))},function(t){var n=Qo.year(t).getDay();return Math.floor((Qo.dayOfYear(t)+(n+e)%7)/7)-(n!==e)});Qo[t+"s"]=n.range,Qo[t+"s"].utc=n.utc.range,Qo[t+"OfYear"]=function(t){var n=Qo.year(t).getDay();return Math.floor((Qo.dayOfYear(t)+(n+e)%7)/7)}}),Qo.week=Qo.sunday,Qo.weeks=Qo.sunday.range,Qo.weeks.utc=Qo.sunday.utc.range,Qo.weekOfYear=Qo.sundayOfYear;var ea={"-":"",_:" ",0:"0"},na=/^\s*\d+/,ia=/^%/;Hr.locale=function(t){return{numberFormat:function(t){var e=t.decimal,n=t.thousands,i=t.grouping,r=t.currency,o=i&&n?function(t,e){for(var r=t.length,o=[],a=0,s=i[0],l=0;r>0&&s>0&&(l+s+1>e&&(s=Math.max(1,e-l)),o.push(t.substring(r-=s,r+s)),!((l+=s+1)>e));)s=i[a=(a+1)%i.length];return o.reverse().join(n)}:Lt;return function(t){var n=Xo.exec(t),i=n[1]||" ",a=n[2]||">",s=n[3]||"-",l=n[4]||"",c=n[5],u=+n[6],h=n[7],p=n[8],d=n[9],f=1,g="",m="",y=!1,v=!0;switch(p&&(p=+p.substring(1)),(c||"0"===i&&"="===a)&&(c=i="0",a="="),d){case"n":h=!0,d="g";break;case"%":f=100,m="%",d="f";break;case"p":f=100,m="%",d="r";break;case"b":case"o":case"x":case"X":"#"===l&&(g="0"+d.toLowerCase());case"c":v=!1;case"d":y=!0,p=0;break;case"s":f=-1,d="r"}"$"===l&&(g=r[0],m=r[1]),"r"!=d||p||(d="g"),null!=p&&("g"==d?p=Math.max(1,Math.min(21,p)):("e"==d||"f"==d)&&(p=Math.max(0,Math.min(20,p)))),d=Go.get(d)||Et;var C=c&&h;return function(t){var n=m;if(y&&t%1)return"";var r=0>t||0===t&&0>1/t?(t=-t,"-"):"-"===s?"":s;if(0>f){var l=Hr.formatPrefix(t,p);t=l.scale(t),n=l.symbol+m}else t*=f;var b,x,L=(t=d(t,p)).lastIndexOf(".");if(0>L){var k=v?t.lastIndexOf("e"):-1;0>k?(b=t,x=""):(b=t.substring(0,k),x=t.substring(k))}else b=t.substring(0,L),x=e+t.substring(L+1);!c&&h&&(b=o(b,1/0));var w=g.length+b.length+x.length+(C?0:r.length),_=u>w?new Array(w=u-w+1).join(i):"";return C&&(b=o(_+b,_.length?u-x.length:1/0)),r+=g,t=b+x,("<"===a?r+t+_:">"===a?_+r+t:"^"===a?_.substring(0,w>>=1)+r+t+_.substring(w):r+(C?t:_+t))+n}}}(t),timeFormat:function(t){function e(t){function e(e){for(var n,r,o,a=[],s=-1,l=0;++s<i;)37===t.charCodeAt(s)&&(a.push(t.slice(l,s)),null!=(r=ea[n=t.charAt(++s)])&&(n=t.charAt(++s)),(o=b[n])&&(n=o(e,null==r?"e"===n?" ":"0":r)),a.push(n),l=s+1);return a.push(t.slice(l,s)),a.join("")}var i=t.length;return e.parse=function(e){var i={y:1900,m:0,d:1,H:0,M:0,S:0,L:0,Z:null};if(n(i,t,e,0)!=e.length)return null;"p"in i&&(i.H=i.H%12+12*i.p);var r=null!=i.Z&&Jo!==Pt,o=new(r?Pt:Jo);return"j"in i?o.setFullYear(i.y,0,i.j):"w"in i&&("W"in i||"U"in i)?(o.setFullYear(i.y,0,1),o.setFullYear(i.y,0,"W"in i?(i.w+6)%7+7*i.W-(o.getDay()+5)%7:i.w+7*i.U-(o.getDay()+6)%7)):o.setFullYear(i.y,i.m,i.d),o.setHours(i.H+(0|i.Z/100),i.M+i.Z%100,i.S,i.L),r?o._:o},e.toString=function(){return t},e}function n(t,e,n,i){for(var r,o,a,s=0,l=e.length,c=n.length;l>s;){if(i>=c)return-1;if(37===(r=e.charCodeAt(s++))){if(a=e.charAt(s++),!(o=x[a in ea?e.charAt(s++):a])||(i=o(t,n,i))<0)return-1}else if(r!=n.charCodeAt(i++))return-1}return i}var i=t.dateTime,r=t.date,o=t.time,a=t.periods,s=t.days,l=t.shortDays,c=t.months,u=t.shortMonths;e.utc=function(t){function n(t){try{var e=new(Jo=Pt);return e._=t,i(e)}finally{Jo=Date}}var i=e(t);return n.parse=function(t){try{Jo=Pt;var e=i.parse(t);return e&&e._}finally{Jo=Date}},n.toString=i.toString,n},e.multi=e.utc.multi=Gt;var h=Hr.map(),p=Bt(s),d=Nt(s),f=Bt(l),g=Nt(l),m=Bt(c),y=Nt(c),v=Bt(u),C=Nt(u);a.forEach(function(t,e){h.set(t.toLowerCase(),e)});var b={a:function(t){return l[t.getDay()]},A:function(t){return s[t.getDay()]},b:function(t){return u[t.getMonth()]},B:function(t){return c[t.getMonth()]},c:e(i),d:function(t,e){return zt(t.getDate(),e,2)},e:function(t,e){return zt(t.getDate(),e,2)},H:function(t,e){return zt(t.getHours(),e,2)},I:function(t,e){return zt(t.getHours()%12||12,e,2)},j:function(t,e){return zt(1+Qo.dayOfYear(t),e,3)},L:function(t,e){return zt(t.getMilliseconds(),e,3)},m:function(t,e){return zt(t.getMonth()+1,e,2)},M:function(t,e){return zt(t.getMinutes(),e,2)},p:function(t){return a[+(t.getHours()>=12)]},S:function(t,e){return zt(t.getSeconds(),e,2)},U:function(t,e){return zt(Qo.sundayOfYear(t),e,2)},w:function(t){return t.getDay()},W:function(t,e){return zt(Qo.mondayOfYear(t),e,2)},x:e(r),X:e(o),y:function(t,e){return zt(t.getFullYear()%100,e,2)},Y:function(t,e){return zt(t.getFullYear()%1e4,e,4)},Z:Wt,"%":function(){return"%"}},x={a:function(t,e,n){f.lastIndex=0;var i=f.exec(e.slice(n));return i?(t.w=g.get(i[0].toLowerCase()),n+i[0].length):-1},A:function(t,e,n){p.lastIndex=0;var i=p.exec(e.slice(n));return i?(t.w=d.get(i[0].toLowerCase()),n+i[0].length):-1},b:function(t,e,n){v.lastIndex=0;var i=v.exec(e.slice(n));return i?(t.m=C.get(i[0].toLowerCase()),n+i[0].length):-1},B:function(t,e,n){m.lastIndex=0;var i=m.exec(e.slice(n));return i?(t.m=y.get(i[0].toLowerCase()),n+i[0].length):-1},c:function(t,e,i){return n(t,b.c.toString(),e,i)},d:Zt,e:Zt,H:qt,I:qt,j:Ht,L:Vt,m:Yt,M:jt,p:function(t,e,n){var i=h.get(e.slice(n,n+=2).toLowerCase());return null==i?-1:(t.p=i,n)},S:Kt,U:$t,w:Dt,W:Ot,x:function(t,e,i){return n(t,b.x.toString(),e,i)},X:function(t,e,i){return n(t,b.X.toString(),e,i)},y:It,Y:Ut,Z:Rt,"%":Xt};return e}(t)}};var ra=Hr.locale({decimal:".",thousands:",",grouping:[3],currency:["$",""],dateTime:"%a %b %e %X %Y",date:"%m/%d/%Y",time:"%H:%M:%S",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});Hr.format=ra.numberFormat,Hr.geo={},Qt.prototype={s:0,t:0,add:function(t){Jt(t,this.t,oa),Jt(oa.s,this.s,this),this.s?this.t+=oa.t:this.s=oa.t},reset:function(){this.s=this.t=0},valueOf:function(){return this.s}};var oa=new Qt;Hr.geo.stream=function(t,e){t&&aa.hasOwnProperty(t.type)?aa[t.type](t,e):te(t,e)};var aa={Feature:function(t,e){te(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,i=-1,r=n.length;++i<r;)te(n[i].geometry,e)}},sa={Sphere:function(t,e){e.sphere()},Point:function(t,e){t=t.coordinates,e.point(t[0],t[1],t[2])},MultiPoint:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)t=n[i],e.point(t[0],t[1],t[2])},LineString:function(t,e){ee(t.coordinates,e,0)},MultiLineString:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)ee(n[i],e,0)},Polygon:function(t,e){ne(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,i=-1,r=n.length;++i<r;)ne(n[i],e)},GeometryCollection:function(t,e){for(var n=t.geometries,i=-1,r=n.length;++i<r;)te(n[i],e)}};Hr.geo.area=function(t){return la=0,Hr.geo.stream(t,ua),la};var la,ca=new Qt,ua={sphere:function(){la+=4*ko},point:y,lineStart:y,lineEnd:y,polygonStart:function(){ca.reset(),ua.lineStart=ie},polygonEnd:function(){var t=2*ca;la+=0>t?4*ko+t:t,ua.lineStart=ua.lineEnd=ua.point=y}};Hr.geo.bounds=function(){function t(t,e){C.push(b=[u=t,p=t]),h>e&&(h=e),e>d&&(d=e)}function e(e,n){var i=re([e*Mo,n*Mo]);if(y){var r=ae(y,i),o=ae([r[1],-r[0],0],r);ce(o),o=ue(o);var a=e-f,l=a>0?1:-1,c=o[0]*Fo*l,g=no(a)>180;if(g^(c>l*f&&l*e>c))(m=o[1]*Fo)>d&&(d=m);else if(g^((c=(c+360)%360-180)>l*f&&l*e>c)){var m=-o[1]*Fo;h>m&&(h=m)}else h>n&&(h=n),n>d&&(d=n);g?f>e?s(u,e)>s(u,p)&&(p=e):s(e,p)>s(u,p)&&(u=e):p>=u?(u>e&&(u=e),e>p&&(p=e)):e>f?s(u,e)>s(u,p)&&(p=e):s(e,p)>s(u,p)&&(u=e)}else t(e,n);y=i,f=e}function n(){x.point=e}function i(){b[0]=u,b[1]=p,x.point=t,y=null}function r(t,n){if(y){var i=t-f;v+=no(i)>180?i+(i>0?360:-360):i}else g=t,m=n;ua.point(t,n),e(t,n)}function o(){ua.lineStart()}function a(){r(g,m),ua.lineEnd(),no(v)>xo&&(u=-(p=180)),b[0]=u,b[1]=p,y=null}function s(t,e){return(e-=t)<0?e+360:e}function l(t,e){return t[0]-e[0]}function c(t,e){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:t<e[0]||e[1]<t}var u,h,p,d,f,g,m,y,v,C,b,x={point:t,lineStart:n,lineEnd:i,polygonStart:function(){x.point=r,x.lineStart=o,x.lineEnd=a,v=0,ua.polygonStart()},polygonEnd:function(){ua.polygonEnd(),x.point=t,x.lineStart=n,x.lineEnd=i,0>ca?(u=-(p=180),h=-(d=90)):v>xo?d=90:-xo>v&&(h=-90),b[0]=u,b[1]=p}};return function(t){if(d=p=-(u=h=1/0),C=[],Hr.geo.stream(t,x),o=C.length){C.sort(l);for(var e=1,n=[f=C[0]];o>e;++e)c((r=C[e])[0],f)||c(r[1],f)?(s(f[0],r[1])>s(f[0],f[1])&&(f[1]=r[1]),s(r[0],f[1])>s(f[0],f[1])&&(f[0]=r[0])):n.push(f=r);for(var i,r,o,a=-1/0,f=(e=0,n[o=n.length-1]);o>=e;f=r,++e)r=n[e],(i=s(f[1],r[0]))>a&&(a=i,u=r[0],p=f[1])}return C=b=null,1/0===u||1/0===h?[[NaN,NaN],[NaN,NaN]]:[[u,h],[p,d]]}}(),Hr.geo.centroid=function(t){ha=pa=da=fa=ga=ma=ya=va=Ca=ba=xa=0,Hr.geo.stream(t,La);var e=Ca,n=ba,i=xa,r=e*e+n*n+i*i;return Lo>r&&(e=ma,n=ya,i=va,xo>pa&&(e=da,n=fa,i=ga),Lo>(r=e*e+n*n+i*i))?[NaN,NaN]:[Math.atan2(n,e)*Fo,Q(i/Math.sqrt(r))*Fo]};var ha,pa,da,fa,ga,ma,ya,va,Ca,ba,xa,La={sphere:y,point:pe,lineStart:fe,lineEnd:ge,polygonStart:function(){La.lineStart=me},polygonEnd:function(){La.lineStart=fe}},ka=Le(ve,function(t){var e,n=NaN,i=NaN,r=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(o,a){var s=o>0?ko:-ko,l=no(o-n);no(l-ko)<xo?(t.point(n,i=(i+a)/2>0?So:-So),t.point(r,i),t.lineEnd(),t.lineStart(),t.point(s,i),t.point(o,i),e=0):r!==s&&l>=ko&&(no(n-r)<xo&&(n-=r*xo),no(o-s)<xo&&(o-=s*xo),i=function(t,e,n,i){var r,o,a=Math.sin(t-n);return no(a)>xo?Math.atan((Math.sin(e)*(o=Math.cos(i))*Math.sin(n)-Math.sin(i)*(r=Math.cos(e))*Math.sin(t))/(r*o*a)):(e+i)/2}(n,i,o,a),t.point(r,i),t.lineEnd(),t.lineStart(),t.point(s,i),e=0),t.point(n=o,i=a),r=s},lineEnd:function(){t.lineEnd(),n=i=NaN},clean:function(){return 2-e}}},function(t,e,n,i){var r;if(null==t)r=n*So,i.point(-ko,r),i.point(0,r),i.point(ko,r),i.point(ko,0),i.point(ko,-r),i.point(0,-r),i.point(-ko,-r),i.point(-ko,0),i.point(-ko,r);else if(no(t[0]-e[0])>xo){var o=t[0]<e[0]?ko:-ko;r=n*o/2,i.point(-o,r),i.point(0,r),i.point(o,r)}else i.point(e[0],e[1])},[-ko,-ko/2]),wa=1e9;Hr.geo.clipExtent=function(){var t,e,n,i,r,o,a={stream:function(t){return r&&(r.valid=!1),(r=o(t)).valid=!0,r},extent:function(s){return arguments.length?(o=Me(t=+s[0][0],e=+s[0][1],n=+s[1][0],i=+s[1][1]),r&&(r.valid=!1,r=null),a):[[t,e],[n,i]]}};return a.extent([[0,0],[960,500]])},(Hr.geo.conicEqualArea=function(){return Fe(Ee)}).raw=Ee,Hr.geo.albers=function(){return Hr.geo.conicEqualArea().rotate([96,0]).center([-.6,38.7]).parallels([29.5,45.5]).scale(1070)},Hr.geo.albersUsa=function(){function t(t){var o=t[0],a=t[1];return e=null,n(o,a),e||(i(o,a),e)||r(o,a),e}var e,n,i,r,o=Hr.geo.albers(),a=Hr.geo.conicEqualArea().rotate([154,0]).center([-2,58.5]).parallels([55,65]),s=Hr.geo.conicEqualArea().rotate([157,0]).center([-3,19.9]).parallels([8,18]),l={point:function(t,n){e=[t,n]}};return t.invert=function(t){var e=o.scale(),n=o.translate(),i=(t[0]-n[0])/e,r=(t[1]-n[1])/e;return(r>=.12&&.234>r&&i>=-.425&&-.214>i?a:r>=.166&&.234>r&&i>=-.214&&-.115>i?s:o).invert(t)},t.stream=function(t){var e=o.stream(t),n=a.stream(t),i=s.stream(t);return{point:function(t,r){e.point(t,r),n.point(t,r),i.point(t,r)},sphere:function(){e.sphere(),n.sphere(),i.sphere()},lineStart:function(){e.lineStart(),n.lineStart(),i.lineStart()},lineEnd:function(){e.lineEnd(),n.lineEnd(),i.lineEnd()},polygonStart:function(){e.polygonStart(),n.polygonStart(),i.polygonStart()},polygonEnd:function(){e.polygonEnd(),n.polygonEnd(),i.polygonEnd()}}},t.precision=function(e){return arguments.length?(o.precision(e),a.precision(e),s.precision(e),t):o.precision()},t.scale=function(e){return arguments.length?(o.scale(e),a.scale(.35*e),s.scale(e),t.translate(o.translate())):o.scale()},t.translate=function(e){if(!arguments.length)return o.translate();var c=o.scale(),u=+e[0],h=+e[1];return n=o.translate(e).clipExtent([[u-.455*c,h-.238*c],[u+.455*c,h+.238*c]]).stream(l).point,i=a.translate([u-.307*c,h+.201*c]).clipExtent([[u-.425*c+xo,h+.12*c+xo],[u-.214*c-xo,h+.234*c-xo]]).stream(l).point,r=s.translate([u-.205*c,h+.212*c]).clipExtent([[u-.214*c+xo,h+.166*c+xo],[u-.115*c-xo,h+.234*c-xo]]).stream(l).point,t},t.scale(1070)};var _a,Sa,Ma,Fa,Ea,Pa,Ta={point:y,lineStart:y,lineEnd:y,polygonStart:function(){Sa=0,Ta.lineStart=Pe},polygonEnd:function(){Ta.lineStart=Ta.lineEnd=Ta.point=y,_a+=no(Sa/2)}},Aa={point:function(t,e){Ma>t&&(Ma=t),t>Ea&&(Ea=t),Fa>e&&(Fa=e),e>Pa&&(Pa=e)},lineStart:y,lineEnd:y,polygonStart:y,polygonEnd:y},za={point:Ae,lineStart:ze,lineEnd:Be,polygonStart:function(){za.lineStart=Ne},polygonEnd:function(){za.point=Ae,za.lineStart=ze,za.lineEnd=Be}};Hr.geo.path=function(){function t(t){return t&&("function"==typeof s&&o.pointRadius(+s.apply(this,arguments)),a&&a.valid||(a=r(o)),Hr.geo.stream(t,a)),o.result()}function e(){return a=null,t}var n,i,r,o,a,s=4.5;return t.area=function(t){return _a=0,Hr.geo.stream(t,r(Ta)),_a},t.centroid=function(t){return da=fa=ga=ma=ya=va=Ca=ba=xa=0,Hr.geo.stream(t,r(za)),xa?[Ca/xa,ba/xa]:va?[ma/va,ya/va]:ga?[da/ga,fa/ga]:[NaN,NaN]},t.bounds=function(t){return Ea=Pa=-(Ma=Fa=1/0),Hr.geo.stream(t,r(Aa)),[[Ma,Fa],[Ea,Pa]]},t.projection=function(t){return arguments.length?(r=(n=t)?t.stream||function(t){var e=De(function(e,n){return t([e*Fo,n*Fo])});return function(t){return Re(e(t))}}(t):Lt,e()):n},t.context=function(t){return arguments.length?(o=null==(i=t)?new function(){function t(t,e){a.push("M",t,",",e,o)}function e(t,e){a.push("M",t,",",e),s.point=n}function n(t,e){a.push("L",t,",",e)}function i(){s.point=t}function r(){a.push("Z")}var o=Te(4.5),a=[],s={point:t,lineStart:function(){s.point=e},lineEnd:i,polygonStart:function(){s.lineEnd=r},polygonEnd:function(){s.lineEnd=i,s.point=t},pointRadius:function(t){return o=Te(t),s},result:function(){if(a.length){var t=a.join("");return a=[],t}}};return s}:new function(t){function e(e,n){t.moveTo(e+a,n),t.arc(e,n,a,0,wo)}function n(e,n){t.moveTo(e,n),s.point=i}function i(e,n){t.lineTo(e,n)}function r(){s.point=e}function o(){t.closePath()}var a=4.5,s={point:e,lineStart:function(){s.point=n},lineEnd:r,polygonStart:function(){s.lineEnd=o},polygonEnd:function(){s.lineEnd=r,s.point=e},pointRadius:function(t){return a=t,s},result:y};return s}(t),"function"!=typeof s&&o.pointRadius(s),e()):i},t.pointRadius=function(e){return arguments.length?(s="function"==typeof e?e:(o.pointRadius(+e),+e),t):s},t.projection(Hr.geo.albersUsa()).context(null)},Hr.geo.transform=function(t){return{stream:function(e){var n=new $e(e);for(var i in t)n[i]=t[i];return n}}},$e.prototype={point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}},Hr.geo.projection=Ue,Hr.geo.projectionMutator=Ie,(Hr.geo.equirectangular=function(){return Ue(Ye)}).raw=Ye.invert=Ye,Hr.geo.rotation=function(t){function e(e){return(e=t(e[0]*Mo,e[1]*Mo))[0]*=Fo,e[1]*=Fo,e}return t=He(t[0]%360*Mo,t[1]*Mo,t.length>2?t[2]*Mo:0),e.invert=function(e){return(e=t.invert(e[0]*Mo,e[1]*Mo))[0]*=Fo,e[1]*=Fo,e},e},Ze.invert=Ye,Hr.geo.circle=function(){function t(){var t="function"==typeof i?i.apply(this,arguments):i,e=He(-t[0]*Mo,-t[1]*Mo,0).invert,r=[];return n(null,null,1,{point:function(t,n){r.push(t=e(t,n)),t[0]*=Fo,t[1]*=Fo}}),{type:"Polygon",coordinates:[r]}}var e,n,i=[0,0],r=6;return t.origin=function(e){return arguments.length?(i=e,t):i},t.angle=function(i){return arguments.length?(n=Ve((e=+i)*Mo,r*Mo),t):e},t.precision=function(i){return arguments.length?(n=Ve(e*Mo,(r=+i)*Mo),t):r},t.angle(90)},Hr.geo.distance=function(t,e){var n,i=(e[0]-t[0])*Mo,r=t[1]*Mo,o=e[1]*Mo,a=Math.sin(i),s=Math.cos(i),l=Math.sin(r),c=Math.cos(r),u=Math.sin(o),h=Math.cos(o);return Math.atan2(Math.sqrt((n=h*a)*n+(n=c*u-l*h*s)*n),l*u+c*h*s)},Hr.geo.graticule=function(){function t(){return{type:"MultiLineString",coordinates:e()}}function e(){return Hr.range(Math.ceil(o/m)*m,r,m).map(p).concat(Hr.range(Math.ceil(c/y)*y,l,y).map(d)).concat(Hr.range(Math.ceil(i/f)*f,n,f).filter(function(t){return no(t%m)>xo}).map(u)).concat(Hr.range(Math.ceil(s/g)*g,a,g).filter(function(t){return no(t%y)>xo}).map(h))}var n,i,r,o,a,s,l,c,u,h,p,d,f=10,g=f,m=90,y=360,v=2.5;return t.lines=function(){return e().map(function(t){return{type:"LineString",coordinates:t}})},t.outline=function(){return{type:"Polygon",coordinates:[p(o).concat(d(l).slice(1),p(r).reverse().slice(1),d(c).reverse().slice(1))]}},t.extent=function(e){return arguments.length?t.majorExtent(e).minorExtent(e):t.minorExtent()},t.majorExtent=function(e){return arguments.length?(o=+e[0][0],r=+e[1][0],c=+e[0][1],l=+e[1][1],o>r&&(e=o,o=r,r=e),c>l&&(e=c,c=l,l=e),t.precision(v)):[[o,c],[r,l]]},t.minorExtent=function(e){return arguments.length?(i=+e[0][0],n=+e[1][0],s=+e[0][1],a=+e[1][1],i>n&&(e=i,i=n,n=e),s>a&&(e=s,s=a,a=e),t.precision(v)):[[i,s],[n,a]]},t.step=function(e){return arguments.length?t.majorStep(e).minorStep(e):t.minorStep()},t.majorStep=function(e){return arguments.length?(m=+e[0],y=+e[1],t):[m,y]},t.minorStep=function(e){return arguments.length?(f=+e[0],g=+e[1],t):[f,g]},t.precision=function(e){return arguments.length?(v=+e,u=Xe(s,a,90),h=Ge(i,n,v),p=Xe(c,l,90),d=Ge(o,r,v),t):v},t.majorExtent([[-180,-90+xo],[180,90-xo]]).minorExtent([[-180,-80-xo],[180,80+xo]])},Hr.geo.greatArc=function(){function t(){return{type:"LineString",coordinates:[e||i.apply(this,arguments),n||r.apply(this,arguments)]}}var e,n,i=Qe,r=Je;return t.distance=function(){return Hr.geo.distance(e||i.apply(this,arguments),n||r.apply(this,arguments))},t.source=function(n){return arguments.length?(i=n,e="function"==typeof n?null:n,t):i},t.target=function(e){return arguments.length?(r=e,n="function"==typeof e?null:e,t):r},t.precision=function(){return arguments.length?t:0},t},Hr.geo.interpolate=function(t,e){return function(t,e,n,i){var r=Math.cos(e),o=Math.sin(e),a=Math.cos(i),s=Math.sin(i),l=r*Math.cos(t),c=r*Math.sin(t),u=a*Math.cos(n),h=a*Math.sin(n),p=2*Math.asin(Math.sqrt(tt(i-e)+r*a*tt(n-t))),d=1/Math.sin(p),f=p?function(t){var e=Math.sin(t*=p)*d,n=Math.sin(p-t)*d,i=n*l+e*u,r=n*c+e*h,a=n*o+e*s;return[Math.atan2(r,i)*Fo,Math.atan2(a,Math.sqrt(i*i+r*r))*Fo]}:function(){return[t*Fo,e*Fo]};return f.distance=p,f}(t[0]*Mo,t[1]*Mo,e[0]*Mo,e[1]*Mo)},Hr.geo.length=function(t){return Ba=0,Hr.geo.stream(t,Na),Ba};var Ba,Na={sphere:y,point:y,lineStart:function(){function t(t,r){var o=Math.sin(r*=Mo),a=Math.cos(r),s=no((t*=Mo)-e),l=Math.cos(s);Ba+=Math.atan2(Math.sqrt((s=a*Math.sin(s))*s+(s=i*o-n*a*l)*s),n*o+i*a*l),e=t,n=o,i=a}var e,n,i;Na.point=function(r,o){e=r*Mo,n=Math.sin(o*=Mo),i=Math.cos(o),Na.point=t},Na.lineEnd=function(){Na.point=Na.lineEnd=y}},lineEnd:y,polygonStart:y,polygonEnd:y},Da=tn(function(t){return Math.sqrt(2/(1+t))},function(t){return 2*Math.asin(t/2)});(Hr.geo.azimuthalEqualArea=function(){return Ue(Da)}).raw=Da;var $a=tn(function(t){var e=Math.acos(t);return e&&e/Math.sin(e)},Lt);(Hr.geo.azimuthalEquidistant=function(){return Ue($a)}).raw=$a,(Hr.geo.conicConformal=function(){return Fe(en)}).raw=en,(Hr.geo.conicEquidistant=function(){return Fe(nn)}).raw=nn;var Oa=tn(function(t){return 1/t},Math.atan);(Hr.geo.gnomonic=function(){return Ue(Oa)}).raw=Oa,rn.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-So]},(Hr.geo.mercator=function(){return on(rn)}).raw=rn;var Ua=tn(function(){return 1},Math.asin);(Hr.geo.orthographic=function(){return Ue(Ua)}).raw=Ua;var Ia=tn(function(t){return 1/(1+t)},function(t){return 2*Math.atan(t)});(Hr.geo.stereographic=function(){return Ue(Ia)}).raw=Ia,an.invert=function(t,e){return[-e,2*Math.atan(Math.exp(t))-So]},(Hr.geo.transverseMercator=function(){var t=on(an),e=t.center,n=t.rotate;return t.center=function(t){return t?e([-t[1],t[0]]):[(t=e())[1],-t[0]]},t.rotate=function(t){return t?n([t[0],t[1],t.length>2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90])}).raw=an,Hr.geom={},Hr.geom.hull=function(t){function e(t){if(t.length<3)return[];var e,r=xt(n),o=xt(i),a=t.length,s=[],l=[];for(e=0;a>e;e++)s.push([+r.call(this,t[e],e),+o.call(this,t[e],e),e]);for(s.sort(un),e=0;a>e;e++)l.push([s[e][0],-s[e][1]]);var c=cn(s),u=cn(l),h=u[0]===c[0],p=u[u.length-1]===c[c.length-1],d=[];for(e=c.length-1;e>=0;--e)d.push(t[s[c[e]][2]]);for(e=+h;e<u.length-p;++e)d.push(t[s[u[e]][2]]);return d}var n=sn,i=ln;return arguments.length?e(t):(e.x=function(t){return arguments.length?(n=t,e):n},e.y=function(t){return arguments.length?(i=t,e):i},e)},Hr.geom.polygon=function(t){return so(t,Ra),t};var Ra=Hr.geom.polygon.prototype=[];Ra.area=function(){for(var t,e=-1,n=this.length,i=this[n-1],r=0;++e<n;)t=i,i=this[e],r+=t[1]*i[0]-t[0]*i[1];return.5*r},Ra.centroid=function(t){var e,n,i=-1,r=this.length,o=0,a=0,s=this[r-1];for(arguments.length||(t=-1/(6*this.area()));++i<r;)e=s,s=this[i],n=e[0]*s[1]-s[0]*e[1],o+=(e[0]+s[0])*n,a+=(e[1]+s[1])*n;return[o*t,a*t]},Ra.clip=function(t){for(var e,n,i,r,o,a,s=dn(t),l=-1,c=this.length-dn(this),u=this[c-1];++l<c;){for(e=t.slice(),t.length=0,r=this[l],o=e[(i=e.length-s)-1],n=-1;++n<i;)hn(a=e[n],u,r)?(hn(o,u,r)||t.push(pn(o,a,u,r)),t.push(a)):hn(o,u,r)&&t.push(pn(o,a,u,r)),o=a;s&&t.push(t[0]),u=r}return t};var Ya,Za,Ha,qa,ja,Ka=[],Va=[];bn.prototype.prepare=function(){for(var t,e=this.edges,n=e.length;n--;)(t=e[n].edge).b&&t.a||e.splice(n,1);return e.sort(xn),e.length},En.prototype={start:function(){return this.edge.l===this.site?this.edge.a:this.edge.b},end:function(){return this.edge.l===this.site?this.edge.b:this.edge.a}},Pn.prototype={insert:function(t,e){var n,i,r;if(t){if(e.P=t,e.N=t.N,t.N&&(t.N.P=e),t.N=e,t.R){for(t=t.R;t.L;)t=t.L;t.L=e}else t.R=e;n=t}else this._?(t=Bn(this._),e.P=null,e.N=t,t.P=t.L=e,n=t):(e.P=e.N=null,this._=e,n=null);for(e.L=e.R=null,e.U=n,e.C=!0,t=e;n&&n.C;)n===(i=n.U).L?(r=i.R)&&r.C?(n.C=r.C=!1,i.C=!0,t=i):(t===n.R&&(An(this,n),n=(t=n).U),n.C=!1,i.C=!0,zn(this,i)):(r=i.L)&&r.C?(n.C=r.C=!1,i.C=!0,t=i):(t===n.L&&(zn(this,n),n=(t=n).U),n.C=!1,i.C=!0,An(this,i)),n=t.U;this._.C=!1},remove:function(t){t.N&&(t.N.P=t.P),t.P&&(t.P.N=t.N),t.N=t.P=null;var e,n,i,r=t.U,o=t.L,a=t.R;if(n=o?a?Bn(a):o:a,r?r.L===t?r.L=n:r.R=n:this._=n,o&&a?(i=n.C,n.C=t.C,n.L=o,o.U=n,n!==a?(r=n.U,n.U=t.U,t=n.R,r.L=t,n.R=a,a.U=n):(n.U=r,r=n,t=n.R)):(i=t.C,t=n),t&&(t.U=r),!i){if(t&&t.C)return void(t.C=!1);do{if(t===this._)break;if(t===r.L){if((e=r.R).C&&(e.C=!1,r.C=!0,An(this,r),e=r.R),e.L&&e.L.C||e.R&&e.R.C){e.R&&e.R.C||(e.L.C=!1,e.C=!0,zn(this,e),e=r.R),e.C=r.C,r.C=e.R.C=!1,An(this,r),t=this._;break}}else if((e=r.L).C&&(e.C=!1,r.C=!0,zn(this,r),e=r.L),e.L&&e.L.C||e.R&&e.R.C){e.L&&e.L.C||(e.R.C=!1,e.C=!0,An(this,e),e=r.L),e.C=r.C,r.C=e.L.C=!1,zn(this,r),t=this._;break}e.C=!0,t=r,r=r.U}while(!t.C);t&&(t.C=!1)}}},Hr.geom.voronoi=function(t){function e(t){var e=new Array(t.length),i=s[0][0],r=s[0][1],o=s[1][0],a=s[1][1];return Nn(n(t),s).cells.forEach(function(n,s){var l=n.edges,c=n.site;(e[s]=l.length?l.map(function(t){var e=t.start();return[e.x,e.y]}):c.x>=i&&c.x<=o&&c.y>=r&&c.y<=a?[[i,a],[o,a],[o,r],[i,r]]:[]).point=t[s]}),e}function n(t){return t.map(function(t,e){return{x:Math.round(o(t,e)/xo)*xo,y:Math.round(a(t,e)/xo)*xo,i:e}})}var i=sn,r=ln,o=i,a=r,s=Wa;return t?e(t):(e.links=function(t){return Nn(n(t)).edges.filter(function(t){return t.l&&t.r}).map(function(e){return{source:t[e.l.i],target:t[e.r.i]}})},e.triangles=function(t){var e=[];return Nn(n(t)).cells.forEach(function(n,i){for(var r,o=n.site,a=n.edges.sort(xn),s=-1,l=a.length,c=a[l-1].edge,u=c.l===o?c.r:c.l;++s<l;)c,r=u,u=(c=a[s].edge).l===o?c.r:c.l,i<r.i&&i<u.i&&$n(o,r,u)<0&&e.push([t[i],t[r.i],t[u.i]])}),e},e.x=function(t){return arguments.length?(o=xt(i=t),e):i},e.y=function(t){return arguments.length?(a=xt(r=t),e):r},e.clipExtent=function(t){return arguments.length?(s=null==t?Wa:t,e):s===Wa?null:s},e.size=function(t){return arguments.length?e.clipExtent(t&&[[0,0],t]):s===Wa?null:s&&s[1]},e)};var Wa=[[-1e6,-1e6],[1e6,1e6]];Hr.geom.delaunay=function(t){return Hr.geom.voronoi().triangles(t)},Hr.geom.quadtree=function(t,e,n,i,r){function o(t){function o(t,e,n,i,r,o,a,s){if(!isNaN(n)&&!isNaN(i))if(t.leaf){var l=t.x,u=t.y;if(null!=l)if(no(l-n)+no(u-i)<.01)c(t,e,n,i,r,o,a,s);else{var h=t.point;t.x=t.y=t.point=null,c(t,h,l,u,r,o,a,s),c(t,e,n,i,r,o,a,s)}else t.x=n,t.y=i,t.point=e}else c(t,e,n,i,r,o,a,s)}function c(t,e,n,i,r,a,s,l){var c=.5*(r+s),u=.5*(a+l),h=n>=c,p=i>=u,d=p<<1|h;t.leaf=!1,t=t.nodes[d]||(t.nodes[d]={leaf:!0,nodes:[],point:null,x:null,y:null,add:function(t){o(_,t,+C(t,++d),+b(t,d),g,m,y,v)}}),h?r=c:s=c,p?a=u:l=u,o(t,e,n,i,r,a,s,l)}var u,h,p,d,f,g,m,y,v,C=xt(s),b=xt(l);if(null!=e)g=e,m=n,y=i,v=r;else if(y=v=-(g=m=1/0),h=[],p=[],f=t.length,a)for(d=0;f>d;++d)(u=t[d]).x<g&&(g=u.x),u.y<m&&(m=u.y),u.x>y&&(y=u.x),u.y>v&&(v=u.y),h.push(u.x),p.push(u.y);else for(d=0;f>d;++d){var x=+C(u=t[d],d),L=+b(u,d);g>x&&(g=x),m>L&&(m=L),x>y&&(y=x),L>v&&(v=L),h.push(x),p.push(L)}var k=y-g,w=v-m;k>w?v=m+k:y=g+w;var _={leaf:!0,nodes:[],point:null,x:null,y:null,add:function(t){o(_,t,+C(t,++d),+b(t,d),g,m,y,v)}};if(_.visit=function(t){!function t(e,n,i,r,o,a){if(!e(n,i,r,o,a)){var s=.5*(i+o),l=.5*(r+a),c=n.nodes;c[0]&&t(e,c[0],i,r,s,l),c[1]&&t(e,c[1],s,r,o,l),c[2]&&t(e,c[2],i,l,s,a),c[3]&&t(e,c[3],s,l,o,a)}}(t,_,g,m,y,v)},_.find=function(t){return function(t,e,n,i,r,o,a){var s,l=1/0;return function t(c,u,h,p,d){if(!(u>o||h>a||i>p||r>d)){if(f=c.point){var f,g=e-f[0],m=n-f[1],y=g*g+m*m;if(l>y){var v=Math.sqrt(l=y);i=e-v,r=n-v,o=e+v,a=n+v,s=f}}for(var C=c.nodes,b=.5*(u+p),x=.5*(h+d),L=(n>=x)<<1|e>=b,k=L+4;k>L;++L)if(c=C[3&L])switch(3&L){case 0:t(c,u,h,b,x);break;case 1:t(c,b,h,p,x);break;case 2:t(c,u,x,b,d);break;case 3:t(c,b,x,p,d)}}}(t,i,r,o,a),s}(_,t[0],t[1],g,m,y,v)},d=-1,null==e){for(;++d<f;)o(_,t[d],h[d],p[d],g,m,y,v);--d}else t.forEach(_.add);return h=p=t=u=null,_}var a,s=sn,l=ln;return(a=arguments.length)?(s=On,l=Un,3===a&&(r=n,i=e,n=e=0),o(t)):(o.x=function(t){return arguments.length?(s=t,o):s},o.y=function(t){return arguments.length?(l=t,o):l},o.extent=function(t){return arguments.length?(null==t?e=n=i=r=null:(e=+t[0][0],n=+t[0][1],i=+t[1][0],r=+t[1][1]),o):null==e?null:[[e,n],[i,r]]},o.size=function(t){return arguments.length?(null==t?e=n=i=r=null:(e=n=0,i=+t[0],r=+t[1]),o):null==e?null:[i-e,r-n]},o)},Hr.interpolateRgb=In,Hr.interpolateObject=Rn,Hr.interpolateNumber=Yn,Hr.interpolateString=Zn;var Xa=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Ga=new RegExp(Xa.source,"g");Hr.interpolate=Hn,Hr.interpolators=[function(t,e){var n=typeof e;return("string"===n?Yo.has(e)||/^(#|rgb\(|hsl\()/.test(e)?In:Zn:e instanceof et?In:Array.isArray(e)?qn:"object"===n&&isNaN(e)?Rn:Yn)(t,e)}],Hr.interpolateArray=qn;var Qa=function(){return Lt},Ja=Hr.map({linear:Qa,poly:function(t){return function(e){return Math.pow(e,t)}},quad:function(){return Vn},cubic:function(){return Wn},sin:function(){return Gn},exp:function(){return Qn},circle:function(){return Jn},elastic:function(t,e){var n;return arguments.length<2&&(e=.45),arguments.length?n=e/wo*Math.asin(1/t):(t=1,n=e/4),function(i){return 1+t*Math.pow(2,-10*i)*Math.sin((i-n)*wo/e)}},back:function(t){return t||(t=1.70158),function(e){return e*e*((t+1)*e-t)}},bounce:function(){return ti}}),ts=Hr.map({in:Lt,out:jn,"in-out":Kn,"out-in":function(t){return Kn(jn(t))}});Hr.ease=function(t){var e=t.indexOf("-"),n=e>=0?t.slice(0,e):t,i=e>=0?t.slice(e+1):"in";return n=Ja.get(n)||Qa,function(t){return function(e){return 0>=e?0:e>=1?1:t(e)}}((i=ts.get(i)||Lt)(n.apply(null,qr.call(arguments,1))))},Hr.interpolateHcl=function(t,e){t=Hr.hcl(t),e=Hr.hcl(e);var n=t.h,i=t.c,r=t.l,o=e.h-n,a=e.c-i,s=e.l-r;return isNaN(a)&&(a=0,i=isNaN(i)?e.c:i),isNaN(o)?(o=0,n=isNaN(n)?e.h:n):o>180?o-=360:-180>o&&(o+=360),function(t){return ot(n+o*t,i+a*t,r+s*t)+""}},Hr.interpolateHsl=function(t,e){t=Hr.hsl(t),e=Hr.hsl(e);var n=t.h,i=t.s,r=t.l,o=e.h-n,a=e.s-i,s=e.l-r;return isNaN(a)&&(a=0,i=isNaN(i)?e.s:i),isNaN(o)?(o=0,n=isNaN(n)?e.h:n):o>180?o-=360:-180>o&&(o+=360),function(t){return it(n+o*t,i+a*t,r+s*t)+""}},Hr.interpolateLab=function(t,e){t=Hr.lab(t),e=Hr.lab(e);var n=t.l,i=t.a,r=t.b,o=e.l-n,a=e.a-i,s=e.b-r;return function(t){return st(n+o*t,i+a*t,r+s*t)+""}},Hr.interpolateRound=ei,Hr.transform=function(t){var e=Kr.createElementNS(Hr.ns.prefix.svg,"g");return(Hr.transform=function(t){if(null!=t){e.setAttribute("transform",t);var n=e.transform.baseVal.consolidate()}return new ni(n?n.matrix:es)})(t)},ni.prototype.toString=function(){return"translate("+this.translate+")rotate("+this.rotate+")skewX("+this.skew+")scale("+this.scale+")"};var es={a:1,b:0,c:0,d:1,e:0,f:0};Hr.interpolateTransform=oi,Hr.layout={},Hr.layout.bundle=function(){return function(t){for(var e=[],n=-1,i=t.length;++n<i;)e.push(li(t[n]));return e}},Hr.layout.chord=function(){function t(){var t,c,h,p,d,f={},g=[],m=Hr.range(o),y=[];for(n=[],i=[],t=0,p=-1;++p<o;){for(c=0,d=-1;++d<o;)c+=r[p][d];g.push(c),y.push(Hr.range(o)),t+=c}for(a&&m.sort(function(t,e){return a(g[t],g[e])}),s&&y.forEach(function(t,e){t.sort(function(t,n){return s(r[e][t],r[e][n])})}),t=(wo-u*o)/t,c=0,p=-1;++p<o;){for(h=c,d=-1;++d<o;){var v=m[p],C=y[v][d],b=r[v][C],x=c,L=c+=b*t;f[v+"-"+C]={index:v,subindex:C,startAngle:x,endAngle:L,value:b}}i[v]={index:v,startAngle:h,endAngle:c,value:(c-h)/t},c+=u}for(p=-1;++p<o;)for(d=p-1;++d<o;){var k=f[p+"-"+d],w=f[d+"-"+p];(k.value||w.value)&&n.push(k.value<w.value?{source:w,target:k}:{source:k,target:w})}l&&e()}function e(){n.sort(function(t,e){return l((t.source.value+t.target.value)/2,(e.source.value+e.target.value)/2)})}var n,i,r,o,a,s,l,c={},u=0;return c.matrix=function(t){return arguments.length?(o=(r=t)&&r.length,n=i=null,c):r},c.padding=function(t){return arguments.length?(u=t,n=i=null,c):u},c.sortGroups=function(t){return arguments.length?(a=t,n=i=null,c):a},c.sortSubgroups=function(t){return arguments.length?(s=t,n=null,c):s},c.sortChords=function(t){return arguments.length?(l=t,n&&e(),c):l},c.chords=function(){return n||t(),n},c.groups=function(){return i||t(),i},c},Hr.layout.force=function(){function t(t){return function(e,n,i,r){if(e.point!==t){var o=e.cx-t.x,a=e.cy-t.y,s=r-n,l=o*o+a*a;if(l>s*s/m){if(f>l){var c=e.charge/l;t.px-=o*c,t.py-=a*c}return!0}if(e.point&&l&&f>l){c=e.pointCharge/l;t.px-=o*c,t.py-=a*c}}return!e.charge}}function e(t){t.px=Hr.event.x,t.py=Hr.event.y,s.resume()}var n,i,r,o,a,s={},l=Hr.dispatch("start","tick","end"),c=[1,1],u=.9,h=ns,p=is,d=-30,f=rs,g=.1,m=.64,y=[],v=[];return s.tick=function(){if((i*=.99)<.005)return l.end({type:"end",alpha:i=0}),!0;var e,n,s,h,p,f,m,C,b,x=y.length,L=v.length;for(n=0;L>n;++n)h=(s=v[n]).source,(f=(C=(p=s.target).x-h.x)*C+(b=p.y-h.y)*b)&&(C*=f=i*o[n]*((f=Math.sqrt(f))-r[n])/f,b*=f,p.x-=C*(m=h.weight/(p.weight+h.weight)),p.y-=b*m,h.x+=C*(m=1-m),h.y+=b*m);if((m=i*g)&&(C=c[0]/2,b=c[1]/2,n=-1,m))for(;++n<x;)(s=y[n]).x+=(C-s.x)*m,s.y+=(b-s.y)*m;if(d)for(function t(e,n,i){var r=0,o=0;if(e.charge=0,!e.leaf)for(var a,s=e.nodes,l=s.length,c=-1;++c<l;)null!=(a=s[c])&&(t(a,n,i),e.charge+=a.charge,r+=a.charge*a.cx,o+=a.charge*a.cy);if(e.point){e.leaf||(e.point.x+=Math.random()-.5,e.point.y+=Math.random()-.5);var u=n*i[e.point.index];e.charge+=e.pointCharge=u,r+=u*e.point.x,o+=u*e.point.y}e.cx=r/e.charge,e.cy=o/e.charge}(e=Hr.geom.quadtree(y),i,a),n=-1;++n<x;)(s=y[n]).fixed||e.visit(t(s));for(n=-1;++n<x;)(s=y[n]).fixed?(s.x=s.px,s.y=s.py):(s.x-=(s.px-(s.px=s.x))*u,s.y-=(s.py-(s.py=s.y))*u);l.tick({type:"tick",alpha:i})},s.nodes=function(t){return arguments.length?(y=t,s):y},s.links=function(t){return arguments.length?(v=t,s):v},s.size=function(t){return arguments.length?(c=t,s):c},s.linkDistance=function(t){return arguments.length?(h="function"==typeof t?t:+t,s):h},s.distance=s.linkDistance,s.linkStrength=function(t){return arguments.length?(p="function"==typeof t?t:+t,s):p},s.friction=function(t){return arguments.length?(u=+t,s):u},s.charge=function(t){return arguments.length?(d="function"==typeof t?t:+t,s):d},s.chargeDistance=function(t){return arguments.length?(f=t*t,s):Math.sqrt(f)},s.gravity=function(t){return arguments.length?(g=+t,s):g},s.theta=function(t){return arguments.length?(m=t*t,s):Math.sqrt(m)},s.alpha=function(t){return arguments.length?(t=+t,i?i=t>0?t:0:t>0&&(l.start({type:"start",alpha:i=t}),Hr.timer(s.tick)),s):i},s.start=function(){function t(t,i){if(!n){for(n=new Array(l),s=0;l>s;++s)n[s]=[];for(s=0;c>s;++s){var r=v[s];n[r.source.index].push(r.target),n[r.target.index].push(r.source)}}for(var o,a=n[e],s=-1,c=a.length;++s<c;)if(!isNaN(o=a[s][t]))return o;return Math.random()*i}var e,n,i,l=y.length,u=v.length,f=c[0],g=c[1];for(e=0;l>e;++e)(i=y[e]).index=e,i.weight=0;for(e=0;u>e;++e)"number"==typeof(i=v[e]).source&&(i.source=y[i.source]),"number"==typeof i.target&&(i.target=y[i.target]),++i.source.weight,++i.target.weight;for(e=0;l>e;++e)i=y[e],isNaN(i.x)&&(i.x=t("x",f)),isNaN(i.y)&&(i.y=t("y",g)),isNaN(i.px)&&(i.px=i.x),isNaN(i.py)&&(i.py=i.y);if(r=[],"function"==typeof h)for(e=0;u>e;++e)r[e]=+h.call(this,v[e],e);else for(e=0;u>e;++e)r[e]=h;if(o=[],"function"==typeof p)for(e=0;u>e;++e)o[e]=+p.call(this,v[e],e);else for(e=0;u>e;++e)o[e]=p;if(a=[],"function"==typeof d)for(e=0;l>e;++e)a[e]=+d.call(this,y[e],e);else for(e=0;l>e;++e)a[e]=d;return s.resume()},s.resume=function(){return s.alpha(.1)},s.stop=function(){return s.alpha(0)},s.drag=function(){return n||(n=Hr.behavior.drag().origin(Lt).on("dragstart.force",ui).on("drag.force",e).on("dragend.force",hi)),arguments.length?void this.on("mouseover.force",pi).on("mouseout.force",di).call(n):n},Hr.rebind(s,l,"on")};var ns=20,is=1,rs=1/0;Hr.layout.hierarchy=function(){function t(r){var o,a=[r],s=[];for(r.depth=0;null!=(o=a.pop());)if(s.push(o),(c=n.call(t,o,o.depth))&&(l=c.length)){for(var l,c,u;--l>=0;)a.push(u=c[l]),u.parent=o,u.depth=o.depth+1;i&&(o.value=0),o.children=c}else i&&(o.value=+i.call(t,o,o.depth)||0),delete o.children;return mi(r,function(t){var n,r;e&&(n=t.children)&&n.sort(e),i&&(r=t.parent)&&(r.value+=t.value)}),s}var e=Ci,n=yi,i=vi;return t.sort=function(n){return arguments.length?(e=n,t):e},t.children=function(e){return arguments.length?(n=e,t):n},t.value=function(e){return arguments.length?(i=e,t):i},t.revalue=function(e){return i&&(gi(e,function(t){t.children&&(t.value=0)}),mi(e,function(e){var n;e.children||(e.value=+i.call(t,e,e.depth)||0),(n=e.parent)&&(n.value+=e.value)})),e},t},Hr.layout.partition=function(){function t(t,i){var r=e.call(this,t,i);return function t(e,n,i,r){var o=e.children;if(e.x=n,e.y=e.depth*r,e.dx=i,e.dy=r,o&&(a=o.length)){var a,s,l,c=-1;for(i=e.value?i/e.value:0;++c<a;)t(s=o[c],n,l=s.value*i,r),n+=l}}(r[0],0,n[0],n[1]/function t(e){var n=e.children,i=0;if(n&&(r=n.length))for(var r,o=-1;++o<r;)i=Math.max(i,t(n[o]));return 1+i}(r[0])),r}var e=Hr.layout.hierarchy(),n=[1,1];return t.size=function(e){return arguments.length?(n=e,t):n},fi(t,e)},Hr.layout.pie=function(){function t(a){var s,l=a.length,c=a.map(function(n,i){return+e.call(t,n,i)}),u=+("function"==typeof i?i.apply(this,arguments):i),h=("function"==typeof r?r.apply(this,arguments):r)-u,p=Math.min(Math.abs(h)/l,+("function"==typeof o?o.apply(this,arguments):o)),d=p*(0>h?-1:1),f=(h-l*d)/Hr.sum(c),g=Hr.range(l),m=[];return null!=n&&g.sort(n===os?function(t,e){return c[e]-c[t]}:function(t,e){return n(a[t],a[e])}),g.forEach(function(t){m[t]={data:a[t],value:s=c[t],startAngle:u,endAngle:u+=s*f+d,padAngle:p}}),m}var e=Number,n=os,i=0,r=wo,o=0;return t.value=function(n){return arguments.length?(e=n,t):e},t.sort=function(e){return arguments.length?(n=e,t):n},t.startAngle=function(e){return arguments.length?(i=e,t):i},t.endAngle=function(e){return arguments.length?(r=e,t):r},t.padAngle=function(e){return arguments.length?(o=e,t):o},t};var os={};Hr.layout.stack=function(){function t(s,l){if(!(p=s.length))return s;var c=s.map(function(n,i){return e.call(t,n,i)}),u=c.map(function(e){return e.map(function(e,n){return[o.call(t,e,n),a.call(t,e,n)]})}),h=n.call(t,u,l);c=Hr.permute(c,h),u=Hr.permute(u,h);var p,d,f,g,m=i.call(t,u,l),y=c[0].length;for(f=0;y>f;++f)for(r.call(t,c[0][f],g=m[f],u[0][f][1]),d=1;p>d;++d)r.call(t,c[d][f],g+=u[d-1][f][1],u[d][f][1]);return s}var e=Lt,n=wi,i=_i,r=ki,o=xi,a=Li;return t.values=function(n){return arguments.length?(e=n,t):e},t.order=function(e){return arguments.length?(n="function"==typeof e?e:as.get(e)||wi,t):n},t.offset=function(e){return arguments.length?(i="function"==typeof e?e:ss.get(e)||_i,t):i},t.x=function(e){return arguments.length?(o=e,t):o},t.y=function(e){return arguments.length?(a=e,t):a},t.out=function(e){return arguments.length?(r=e,t):r},t};var as=Hr.map({"inside-out":function(t){var e,n,i=t.length,r=t.map(Si),o=t.map(Mi),a=Hr.range(i).sort(function(t,e){return r[t]-r[e]}),s=0,l=0,c=[],u=[];for(e=0;i>e;++e)n=a[e],l>s?(s+=o[n],c.push(n)):(l+=o[n],u.push(n));return u.reverse().concat(c)},reverse:function(t){return Hr.range(t.length).reverse()},default:wi}),ss=Hr.map({silhouette:function(t){var e,n,i,r=t.length,o=t[0].length,a=[],s=0,l=[];for(n=0;o>n;++n){for(e=0,i=0;r>e;e++)i+=t[e][n][1];i>s&&(s=i),a.push(i)}for(n=0;o>n;++n)l[n]=(s-a[n])/2;return l},wiggle:function(t){var e,n,i,r,o,a,s,l,c,u=t.length,h=t[0],p=h.length,d=[];for(d[0]=l=c=0,n=1;p>n;++n){for(e=0,r=0;u>e;++e)r+=t[e][n][1];for(e=0,o=0,s=h[n][0]-h[n-1][0];u>e;++e){for(i=0,a=(t[e][n][1]-t[e][n-1][1])/(2*s);e>i;++i)a+=(t[i][n][1]-t[i][n-1][1])/s;o+=a*t[e][n][1]}d[n]=l-=r?o/r*s:0,c>l&&(c=l)}for(n=0;p>n;++n)d[n]-=c;return d},expand:function(t){var e,n,i,r=t.length,o=t[0].length,a=1/r,s=[];for(n=0;o>n;++n){for(e=0,i=0;r>e;e++)i+=t[e][n][1];if(i)for(e=0;r>e;e++)t[e][n][1]/=i;else for(e=0;r>e;e++)t[e][n][1]=a}for(n=0;o>n;++n)s[n]=0;return s},zero:_i});Hr.layout.histogram=function(){function t(t,o){for(var a,s,l=[],c=t.map(n,this),u=i.call(this,c,o),h=r.call(this,u,c,o),p=(o=-1,c.length),d=h.length-1,f=e?1:1/p;++o<d;)(a=l[o]=[]).dx=h[o+1]-(a.x=h[o]),a.y=0;if(d>0)for(o=-1;++o<p;)(s=c[o])>=u[0]&&s<=u[1]&&((a=l[Hr.bisect(h,s,1,d)-1]).y+=f,a.push(t[o]));return l}var e=!0,n=Number,i=Ti,r=Ei;return t.value=function(e){return arguments.length?(n=e,t):n},t.range=function(e){return arguments.length?(i=xt(e),t):i},t.bins=function(e){return arguments.length?(r="number"==typeof e?function(t){return Pi(t,e)}:xt(e),t):r},t.frequency=function(n){return arguments.length?(e=!!n,t):e},t},Hr.layout.pack=function(){function t(t,o){var a=n.call(this,t,o),s=a[0],l=r[0],c=r[1],u=null==e?Math.sqrt:"function"==typeof e?e:function(){return e};if(s.x=s.y=0,mi(s,function(t){t.r=+u(t.value)}),mi(s,Di),i){var h=i*(e?1:Math.max(2*s.r/l,2*s.r/c))/2;mi(s,function(t){t.r+=h}),mi(s,Di),mi(s,function(t){t.r-=h})}return function t(e,n,i,r){var o=e.children;if(e.x=n+=r*e.x,e.y=i+=r*e.y,e.r*=r,o)for(var a=-1,s=o.length;++a<s;)t(o[a],n,i,r)}(s,l/2,c/2,e?1:1/Math.max(2*s.r/l,2*s.r/c)),a}var e,n=Hr.layout.hierarchy().sort(Ai),i=0,r=[1,1];return t.size=function(e){return arguments.length?(r=e,t):r},t.radius=function(n){return arguments.length?(e=null==n||"function"==typeof n?n:+n,t):e},t.padding=function(e){return arguments.length?(i=+e,t):i},fi(t,n)},Hr.layout.tree=function(){function t(t,l){var c=r.call(this,t,l),u=c[0],h=function(t){for(var e,n={A:null,children:[t]},i=[n];null!=(e=i.pop());)for(var r,o=e.children,a=0,s=o.length;s>a;++a)i.push((o[a]=r={_:o[a],parent:e,children:(r=o[a].children)&&r.slice()||[],A:null,a:null,z:0,m:0,c:0,s:0,t:null,i:a}).a=r);return n.children[0]}(u);if(mi(h,e),h.parent.m=-h.z,gi(h,n),s)gi(u,i);else{var p=u,d=u,f=u;gi(u,function(t){t.x<p.x&&(p=t),t.x>d.x&&(d=t),t.depth>f.depth&&(f=t)});var g=o(p,d)/2-p.x,m=a[0]/(d.x+o(d,p)/2+g),y=a[1]/(f.depth||1);gi(u,function(t){t.x=(t.x+g)*m,t.y=t.depth*y})}return c}function e(t){var e=t.children,n=t.parent.children,i=t.i?n[t.i-1]:null;if(e.length){!function(t){for(var e,n=0,i=0,r=t.children,o=r.length;--o>=0;)(e=r[o]).z+=n,e.m+=n,n+=e.s+(i+=e.c)}(t);var r=(e[0].z+e[e.length-1].z)/2;i?(t.z=i.z+o(t._,i._),t.m=t.z-r):t.z=r}else i&&(t.z=i.z+o(t._,i._));t.parent.A=function(t,e,n){if(e){for(var i,r=t,a=t,s=e,l=r.parent.children[0],c=r.m,u=a.m,h=s.m,p=l.m;s=Yi(s),r=Ri(r),s&&r;)l=Ri(l),(a=Yi(a)).a=t,(i=s.z+h-r.z-c+o(s._,r._))>0&&(Zi(Hi(s,t,n),t,i),c+=i,u+=i),h+=s.m,c+=r.m,p+=l.m,u+=a.m;s&&!Yi(a)&&(a.t=s,a.m+=h-u),r&&!Ri(l)&&(l.t=r,l.m+=c-p,n=t)}return n}(t,i,t.parent.A||n[0])}function n(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function i(t){t.x*=a[0],t.y=t.depth*a[1]}var r=Hr.layout.hierarchy().sort(null).value(null),o=Ii,a=[1,1],s=null;return t.separation=function(e){return arguments.length?(o=e,t):o},t.size=function(e){return arguments.length?(s=null==(a=e)?i:null,t):s?null:a},t.nodeSize=function(e){return arguments.length?(s=null==(a=e)?null:i,t):s?a:null},fi(t,r)},Hr.layout.cluster=function(){function t(t,o){var a,s=e.call(this,t,o),l=s[0],c=0;mi(l,function(t){var e=t.children;e&&e.length?(t.x=function(t){return t.reduce(function(t,e){return t+e.x},0)/t.length}(e),t.y=function(t){return 1+Hr.max(t,function(t){return t.y})}(e)):(t.x=a?c+=n(t,a):0,t.y=0,a=t)});var u=function t(e){var n=e.children;return n&&n.length?t(n[0]):e}(l),h=function t(e){var n,i=e.children;return i&&(n=i.length)?t(i[n-1]):e}(l),p=u.x-n(u,h)/2,d=h.x+n(h,u)/2;return mi(l,r?function(t){t.x=(t.x-l.x)*i[0],t.y=(l.y-t.y)*i[1]}:function(t){t.x=(t.x-p)/(d-p)*i[0],t.y=(1-(l.y?t.y/l.y:1))*i[1]}),s}var e=Hr.layout.hierarchy().sort(null).value(null),n=Ii,i=[1,1],r=!1;return t.separation=function(e){return arguments.length?(n=e,t):n},t.size=function(e){return arguments.length?(r=null==(i=e),t):r?null:i},t.nodeSize=function(e){return arguments.length?(r=null!=(i=e),t):r?i:null},fi(t,e)},Hr.layout.treemap=function(){function t(t,e){for(var n,i,r=-1,o=t.length;++r<o;)i=(n=t[r]).value*(0>e?0:e),n.area=isNaN(i)||0>=i?0:i}function e(n){var o=n.children;if(o&&o.length){var a,s,l,c=h(n),u=[],p=o.slice(),f=1/0,g="slice"===d?c.dx:"dice"===d?c.dy:"slice-dice"===d?1&n.depth?c.dy:c.dx:Math.min(c.dx,c.dy);for(t(p,c.dx*c.dy/n.value),u.area=0;(l=p.length)>0;)u.push(a=p[l-1]),u.area+=a.area,"squarify"!==d||(s=i(u,g))<=f?(p.pop(),f=s):(u.area-=u.pop().area,r(u,g,c,!1),g=Math.min(c.dx,c.dy),u.length=u.area=0,f=1/0);u.length&&(r(u,g,c,!0),u.length=u.area=0),o.forEach(e)}}function n(e){var i=e.children;if(i&&i.length){var o,a=h(e),s=i.slice(),l=[];for(t(s,a.dx*a.dy/e.value),l.area=0;o=s.pop();)l.push(o),l.area+=o.area,null!=o.z&&(r(l,o.z?a.dx:a.dy,a,!s.length),l.length=l.area=0);i.forEach(n)}}function i(t,e){for(var n,i=t.area,r=0,o=1/0,a=-1,s=t.length;++a<s;)(n=t[a].area)&&(o>n&&(o=n),n>r&&(r=n));return e*=e,(i*=i)?Math.max(e*r*f/i,i/(e*o*f)):1/0}function r(t,e,n,i){var r,o=-1,a=t.length,s=n.x,c=n.y,u=e?l(t.area/e):0;if(e==n.dx){for((i||u>n.dy)&&(u=n.dy);++o<a;)(r=t[o]).x=s,r.y=c,r.dy=u,s+=r.dx=Math.min(n.x+n.dx-s,u?l(r.area/u):0);r.z=!0,r.dx+=n.x+n.dx-s,n.y+=u,n.dy-=u}else{for((i||u>n.dx)&&(u=n.dx);++o<a;)(r=t[o]).x=s,r.y=c,r.dx=u,c+=r.dy=Math.min(n.y+n.dy-c,u?l(r.area/u):0);r.z=!1,r.dy+=n.y+n.dy-c,n.x+=u,n.dx-=u}}function o(i){var r=a||s(i),o=r[0];return o.x=0,o.y=0,o.dx=c[0],o.dy=c[1],a&&s.revalue(o),t([o],o.dx*o.dy/o.value),(a?n:e)(o),p&&(a=r),r}var a,s=Hr.layout.hierarchy(),l=Math.round,c=[1,1],u=null,h=qi,p=!1,d="squarify",f=.5*(1+Math.sqrt(5));return o.size=function(t){return arguments.length?(c=t,o):c},o.padding=function(t){function e(e){return ji(e,t)}return arguments.length?(h=null==(u=t)?qi:"function"==(n=typeof t)?function(e){var n=t.call(o,e,e.depth);return null==n?qi(e):ji(e,"number"==typeof n?[n,n,n,n]:n)}:"number"===n?(t=[t,t,t,t],e):e,o):u;var n},o.round=function(t){return arguments.length?(l=t?Math.round:Number,o):l!=Number},o.sticky=function(t){return arguments.length?(p=t,a=null,o):p},o.ratio=function(t){return arguments.length?(f=t,o):f},o.mode=function(t){return arguments.length?(d=t+"",o):d},fi(o,s)},Hr.random={normal:function(t,e){var n=arguments.length;return 2>n&&(e=1),1>n&&(t=0),function(){var n,i,r;do{r=(n=2*Math.random()-1)*n+(i=2*Math.random()-1)*i}while(!r||r>1);return t+e*n*Math.sqrt(-2*Math.log(r)/r)}},logNormal:function(){var t=Hr.random.normal.apply(Hr,arguments);return function(){return Math.exp(t())}},bates:function(t){var e=Hr.random.irwinHall(t);return function(){return e()/t}},irwinHall:function(t){return function(){for(var e=0,n=0;t>n;n++)e+=Math.random();return e}}},Hr.scale={};var ls={floor:Lt,ceil:Lt};Hr.scale.linear=function(){return function t(e,n,i,r){function o(){var t=Math.min(e.length,n.length)>2?Gi:Wi,o=r?si:ai;return s=t(e,n,o,i),l=t(n,e,o,Hn),a}function a(t){return s(t)}var s,l;return a.invert=function(t){return l(t)},a.domain=function(t){return arguments.length?(e=t.map(Number),o()):e},a.range=function(t){return arguments.length?(n=t,o()):n},a.rangeRound=function(t){return a.range(t).interpolate(ei)},a.clamp=function(t){return arguments.length?(r=t,o()):r},a.interpolate=function(t){return arguments.length?(i=t,o()):i},a.ticks=function(t){return er(e,t)},a.tickFormat=function(t,n){return nr(e,t,n)},a.nice=function(t){return Ji(e,t),o()},a.copy=function(){return t(e,n,i,r)},o()}([0,1],[0,1],Hn,!1)};var cs={s:1,g:1,p:1,r:1,e:1};Hr.scale.log=function(){return function t(e,n,i,r){function o(t){return(i?Math.log(0>t?0:t):-Math.log(t>0?0:-t))/Math.log(n)}function a(t){return i?Math.pow(n,t):-Math.pow(n,-t)}function s(t){return e(o(t))}return s.invert=function(t){return a(e.invert(t))},s.domain=function(t){return arguments.length?(i=t[0]>=0,e.domain((r=t.map(Number)).map(o)),s):r},s.base=function(t){return arguments.length?(n=+t,e.domain(r.map(o)),s):n},s.nice=function(){var t=Xi(r.map(o),i?Math:hs);return e.domain(t),r=t.map(a),s},s.ticks=function(){var t=Ki(r),e=[],s=t[0],l=t[1],c=Math.floor(o(s)),u=Math.ceil(o(l)),h=n%1?2:n;if(isFinite(u-c)){if(i){for(;u>c;c++)for(var p=1;h>p;p++)e.push(a(c)*p);e.push(a(c))}else for(e.push(a(c));c++<u;)for(p=h-1;p>0;p--)e.push(a(c)*p);for(c=0;e[c]<s;c++);for(u=e.length;e[u-1]>l;u--);e=e.slice(c,u)}return e},s.tickFormat=function(t,e){if(!arguments.length)return us;arguments.length<2?e=us:"function"!=typeof e&&(e=Hr.format(e));var n,r=Math.max(.1,t/s.ticks().length),l=i?(n=1e-12,Math.ceil):(n=-1e-12,Math.floor);return function(t){return t/a(l(o(t)+n))<=r?e(t):""}},s.copy=function(){return t(e.copy(),n,i,r)},Qi(s,e)}(Hr.scale.linear().domain([0,1]),10,!0,[1,10])};var us=Hr.format(".0e"),hs={floor:function(t){return-Math.ceil(-t)},ceil:function(t){return-Math.floor(-t)}};Hr.scale.pow=function(){return function t(e,n,i){function r(t){return e(o(t))}var o=rr(n),a=rr(1/n);return r.invert=function(t){return a(e.invert(t))},r.domain=function(t){return arguments.length?(e.domain((i=t.map(Number)).map(o)),r):i},r.ticks=function(t){return er(i,t)},r.tickFormat=function(t,e){return nr(i,t,e)},r.nice=function(t){return r.domain(Ji(i,t))},r.exponent=function(t){return arguments.length?(o=rr(n=t),a=rr(1/n),e.domain(i.map(o)),r):n},r.copy=function(){return t(e.copy(),n,i)},Qi(r,e)}(Hr.scale.linear(),1,[0,1])},Hr.scale.sqrt=function(){return Hr.scale.pow().exponent(.5)},Hr.scale.ordinal=function(){return function t(e,n){function i(t){return s[((o.get(t)||("range"===n.t?o.set(t,e.push(t)):NaN))-1)%s.length]}function r(t,n){return Hr.range(e.length).map(function(e){return t+n*e})}var o,s,l;return i.domain=function(t){if(!arguments.length)return e;e=[],o=new a;for(var r,s=-1,l=t.length;++s<l;)o.has(r=t[s])||o.set(r,e.push(r));return i[n.t].apply(i,n.a)},i.range=function(t){return arguments.length?(s=t,l=0,n={t:"range",a:arguments},i):s},i.rangePoints=function(t,o){arguments.length<2&&(o=0);var a=t[0],c=t[1],u=e.length<2?(a=(a+c)/2,0):(c-a)/(e.length-1+o);return s=r(a+u*o/2,u),l=0,n={t:"rangePoints",a:arguments},i},i.rangeRoundPoints=function(t,o){arguments.length<2&&(o=0);var a=t[0],c=t[1],u=e.length<2?(a=c=Math.round((a+c)/2),0):0|(c-a)/(e.length-1+o);return s=r(a+Math.round(u*o/2+(c-a-(e.length-1+o)*u)/2),u),l=0,n={t:"rangeRoundPoints",a:arguments},i},i.rangeBands=function(t,o,a){arguments.length<2&&(o=0),arguments.length<3&&(a=o);var c=t[1]<t[0],u=t[c-0],h=(t[1-c]-u)/(e.length-o+2*a);return s=r(u+h*a,h),c&&s.reverse(),l=h*(1-o),n={t:"rangeBands",a:arguments},i},i.rangeRoundBands=function(t,o,a){arguments.length<2&&(o=0),arguments.length<3&&(a=o);var c=t[1]<t[0],u=t[c-0],h=t[1-c],p=Math.floor((h-u)/(e.length-o+2*a));return s=r(u+Math.round((h-u-(e.length-o)*p)/2),p),c&&s.reverse(),l=Math.round(p*(1-o)),n={t:"rangeRoundBands",a:arguments},i},i.rangeBand=function(){return l},i.rangeExtent=function(){return Ki(n.a[0])},i.copy=function(){return t(e,n)},i.domain(e)}([],{t:"range",a:[[]]})},Hr.scale.category10=function(){return Hr.scale.ordinal().range(ps)},Hr.scale.category20=function(){return Hr.scale.ordinal().range(ds)},Hr.scale.category20b=function(){return Hr.scale.ordinal().range(fs)},Hr.scale.category20c=function(){return Hr.scale.ordinal().range(gs)};var ps=[2062260,16744206,2924588,14034728,9725885,9197131,14907330,8355711,12369186,1556175].map(ft),ds=[2062260,11454440,16744206,16759672,2924588,10018698,14034728,16750742,9725885,12955861,9197131,12885140,14907330,16234194,8355711,13092807,12369186,14408589,1556175,10410725].map(ft),fs=[3750777,5395619,7040719,10264286,6519097,9216594,11915115,13556636,9202993,12426809,15186514,15190932,8666169,11356490,14049643,15177372,8077683,10834324,13528509,14589654].map(ft),gs=[3244733,7057110,10406625,13032431,15095053,16616764,16625259,16634018,3253076,7652470,10607003,13101504,7695281,10394312,12369372,14342891,6513507,9868950,12434877,14277081].map(ft);Hr.scale.quantile=function(){return function i(r,o){function a(){var t=0,e=o.length;for(l=[];++t<e;)l[t-1]=Hr.quantile(r,t/e);return s}function s(t){return isNaN(t=+t)?void 0:o[Hr.bisect(l,t)]}var l;return s.domain=function(i){return arguments.length?(r=i.map(e).filter(n).sort(t),a()):r},s.range=function(t){return arguments.length?(o=t,a()):o},s.quantiles=function(){return l},s.invertExtent=function(t){return 0>(t=o.indexOf(t))?[NaN,NaN]:[t>0?l[t-1]:r[0],t<l.length?l[t]:r[r.length-1]]},s.copy=function(){return i(r,o)},a()}([],[])},Hr.scale.quantize=function(){return function t(e,n,i){function r(t){return i[Math.max(0,Math.min(s,Math.floor(a*(t-e))))]}function o(){return a=i.length/(n-e),s=i.length-1,r}var a,s;return r.domain=function(t){return arguments.length?(e=+t[0],n=+t[t.length-1],o()):[e,n]},r.range=function(t){return arguments.length?(i=t,o()):i},r.invertExtent=function(t){return[t=0>(t=i.indexOf(t))?NaN:t/a+e,t+1/a]},r.copy=function(){return t(e,n,i)},o()}(0,1,[0,1])},Hr.scale.threshold=function(){return function t(e,n){function i(t){return t>=t?n[Hr.bisect(e,t)]:void 0}return i.domain=function(t){return arguments.length?(e=t,i):e},i.range=function(t){return arguments.length?(n=t,i):n},i.invertExtent=function(t){return t=n.indexOf(t),[e[t-1],e[t]]},i.copy=function(){return t(e,n)},i}([.5],[0,1])},Hr.scale.identity=function(){return function t(e){function n(t){return+t}return n.invert=n,n.domain=n.range=function(t){return arguments.length?(e=t.map(n),n):e},n.ticks=function(t){return er(e,t)},n.tickFormat=function(t,n){return nr(e,t,n)},n.copy=function(){return t(e)},n}([0,1])},Hr.svg={},Hr.svg.arc=function(){function t(){var t=Math.max(0,+n.apply(this,arguments)),c=Math.max(0,+i.apply(this,arguments)),u=a.apply(this,arguments)-So,h=s.apply(this,arguments)-So,p=Math.abs(h-u),d=u>h?0:1;if(t>c&&(f=c,c=t,t=f),p>=_o)return e(c,d)+(t?e(t,1-d):"")+"Z";var f,g,m,y,v,C,b,x,L,k,w,_,S=0,M=0,F=[];if((y=(+l.apply(this,arguments)||0)/2)&&(m=o===ms?Math.sqrt(t*t+c*c):+o.apply(this,arguments),d||(M*=-1),c&&(M=Q(m/c*Math.sin(y))),t&&(S=Q(m/t*Math.sin(y)))),c){v=c*Math.cos(u+M),C=c*Math.sin(u+M),b=c*Math.cos(h-M),x=c*Math.sin(h-M);var E=Math.abs(h-u-2*M)<=ko?0:1;if(M&&hr(v,C,b,x)===d^E){var P=(u+h)/2;v=c*Math.cos(P),C=c*Math.sin(P),b=x=null}}else v=C=0;if(t){L=t*Math.cos(h-S),k=t*Math.sin(h-S),w=t*Math.cos(u+S),_=t*Math.sin(u+S);var T=Math.abs(u-h+2*S)<=ko?0:1;if(S&&hr(L,k,w,_)===1-d^T){var A=(u+h)/2;L=t*Math.cos(A),k=t*Math.sin(A),w=_=null}}else L=k=0;if((f=Math.min(Math.abs(c-t)/2,+r.apply(this,arguments)))>.001){g=c>t^d?0:1;var z=null==w?[L,k]:null==b?[v,C]:pn([v,C],[w,_],[b,x],[L,k]),B=v-z[0],N=C-z[1],D=b-z[0],$=x-z[1],O=1/Math.sin(Math.acos((B*D+N*$)/(Math.sqrt(B*B+N*N)*Math.sqrt(D*D+$*$)))/2),U=Math.sqrt(z[0]*z[0]+z[1]*z[1]);if(null!=b){var I=Math.min(f,(c-U)/(O+1)),R=pr(null==w?[L,k]:[w,_],[v,C],c,I,d),Y=pr([b,x],[L,k],c,I,d);f===I?F.push("M",R[0],"A",I,",",I," 0 0,",g," ",R[1],"A",c,",",c," 0 ",1-d^hr(R[1][0],R[1][1],Y[1][0],Y[1][1]),",",d," ",Y[1],"A",I,",",I," 0 0,",g," ",Y[0]):F.push("M",R[0],"A",I,",",I," 0 1,",g," ",Y[0])}else F.push("M",v,",",C);if(null!=w){var Z=Math.min(f,(t-U)/(O-1)),H=pr([v,C],[w,_],t,-Z,d),q=pr([L,k],null==b?[v,C]:[b,x],t,-Z,d);f===Z?F.push("L",q[0],"A",Z,",",Z," 0 0,",g," ",q[1],"A",t,",",t," 0 ",d^hr(q[1][0],q[1][1],H[1][0],H[1][1]),",",1-d," ",H[1],"A",Z,",",Z," 0 0,",g," ",H[0]):F.push("L",q[0],"A",Z,",",Z," 0 0,",g," ",H[0])}else F.push("L",L,",",k)}else F.push("M",v,",",C),null!=b&&F.push("A",c,",",c," 0 ",E,",",d," ",b,",",x),F.push("L",L,",",k),null!=w&&F.push("A",t,",",t," 0 ",T,",",1-d," ",w,",",_);return F.push("Z"),F.join("")}function e(t,e){return"M0,"+t+"A"+t+","+t+" 0 1,"+e+" 0,"+-t+"A"+t+","+t+" 0 1,"+e+" 0,"+t}var n=ar,i=sr,r=or,o=ms,a=lr,s=cr,l=ur;return t.innerRadius=function(e){return arguments.length?(n=xt(e),t):n},t.outerRadius=function(e){return arguments.length?(i=xt(e),t):i},t.cornerRadius=function(e){return arguments.length?(r=xt(e),t):r},t.padRadius=function(e){return arguments.length?(o=e==ms?ms:xt(e),t):o},t.startAngle=function(e){return arguments.length?(a=xt(e),t):a},t.endAngle=function(e){return arguments.length?(s=xt(e),t):s},t.padAngle=function(e){return arguments.length?(l=xt(e),t):l},t.centroid=function(){var t=(+n.apply(this,arguments)+ +i.apply(this,arguments))/2,e=(+a.apply(this,arguments)+ +s.apply(this,arguments))/2-So;return[Math.cos(e)*t,Math.sin(e)*t]},t};var ms="auto";Hr.svg.line=function(){return dr(Lt)};var ys=Hr.map({linear:fr,"linear-closed":function(t){return fr(t)+"Z"},step:function(t){for(var e=0,n=t.length,i=t[0],r=[i[0],",",i[1]];++e<n;)r.push("H",(i[0]+(i=t[e])[0])/2,"V",i[1]);return n>1&&r.push("H",i[0]),r.join("")},"step-before":gr,"step-after":mr,basis:Cr,"basis-open":function(t){if(t.length<4)return fr(t);for(var e,n=[],i=-1,r=t.length,o=[0],a=[0];++i<3;)e=t[i],o.push(e[0]),a.push(e[1]);for(n.push(br(bs,o)+","+br(bs,a)),--i;++i<r;)e=t[i],o.shift(),o.push(e[0]),a.shift(),a.push(e[1]),xr(n,o,a);return n.join("")},"basis-closed":function(t){for(var e,n,i=-1,r=t.length,o=r+4,a=[],s=[];++i<4;)n=t[i%r],a.push(n[0]),s.push(n[1]);for(e=[br(bs,a),",",br(bs,s)],--i;++i<o;)n=t[i%r],a.shift(),a.push(n[0]),s.shift(),s.push(n[1]),xr(e,a,s);return e.join("")},bundle:function(t,e){var n=t.length-1;if(n)for(var i,r,o=t[0][0],a=t[0][1],s=t[n][0]-o,l=t[n][1]-a,c=-1;++c<=n;)r=c/n,(i=t[c])[0]=e*i[0]+(1-e)*(o+r*s),i[1]=e*i[1]+(1-e)*(a+r*l);return Cr(t)},cardinal:function(t,e){return t.length<3?fr(t):t[0]+yr(t,vr(t,e))},"cardinal-open":function(t,e){return t.length<4?fr(t):t[1]+yr(t.slice(1,-1),vr(t,e))},"cardinal-closed":function(t,e){return t.length<3?fr(t):t[0]+yr((t.push(t[0]),t),vr([t[t.length-2]].concat(t,[t[1]]),e))},monotone:function(t){return t.length<3?fr(t):t[0]+yr(t,kr(t))}});ys.forEach(function(t,e){e.key=t,e.closed=/-closed$/.test(t)});var vs=[0,2/3,1/3,0],Cs=[0,1/3,2/3,0],bs=[0,1/6,2/3,1/6];Hr.svg.line.radial=function(){var t=dr(wr);return t.radius=t.x,delete t.x,t.angle=t.y,delete t.y,t},gr.reverse=mr,mr.reverse=gr,Hr.svg.area=function(){return _r(Lt)},Hr.svg.area.radial=function(){var t=_r(wr);return t.radius=t.x,delete t.x,t.innerRadius=t.x0,delete t.x0,t.outerRadius=t.x1,delete t.x1,t.angle=t.y,delete t.y,t.startAngle=t.y0,delete t.y0,t.endAngle=t.y1,delete t.y1,t},Hr.svg.chord=function(){function t(t,a){var s=e(this,r,t,a),l=e(this,o,t,a);return"M"+s.p0+n(s.r,s.p1,s.a1-s.a0)+(function(t,e){return t.a0==e.a0&&t.a1==e.a1}(s,l)?i(s.r,s.p1,s.r,s.p0):i(s.r,s.p1,l.r,l.p0)+n(l.r,l.p1,l.a1-l.a0)+i(l.r,l.p1,s.r,s.p0))+"Z"}function e(t,e,n,i){var r=e.call(t,n,i),o=a.call(t,r,i),c=s.call(t,r,i)-So,u=l.call(t,r,i)-So;return{r:o,a0:c,a1:u,p0:[o*Math.cos(c),o*Math.sin(c)],p1:[o*Math.cos(u),o*Math.sin(u)]}}function n(t,e,n){return"A"+t+","+t+" 0 "+ +(n>ko)+",1 "+e}function i(t,e,n,i){return"Q 0,0 "+i}var r=Qe,o=Je,a=Sr,s=lr,l=cr;return t.radius=function(e){return arguments.length?(a=xt(e),t):a},t.source=function(e){return arguments.length?(r=xt(e),t):r},t.target=function(e){return arguments.length?(o=xt(e),t):o},t.startAngle=function(e){return arguments.length?(s=xt(e),t):s},t.endAngle=function(e){return arguments.length?(l=xt(e),t):l},t},Hr.svg.diagonal=function(){function t(t,r){var o=e.call(this,t,r),a=n.call(this,t,r),s=(o.y+a.y)/2,l=[o,{x:o.x,y:s},{x:a.x,y:s},a];return"M"+(l=l.map(i))[0]+"C"+l[1]+" "+l[2]+" "+l[3]}var e=Qe,n=Je,i=Mr;return t.source=function(n){return arguments.length?(e=xt(n),t):e},t.target=function(e){return arguments.length?(n=xt(e),t):n},t.projection=function(e){return arguments.length?(i=e,t):i},t},Hr.svg.diagonal.radial=function(){var t=Hr.svg.diagonal(),e=Mr,n=t.projection;return t.projection=function(t){return arguments.length?n(function(t){return function(){var e=t.apply(this,arguments),n=e[0],i=e[1]-So;return[n*Math.cos(i),n*Math.sin(i)]}}(e=t)):e},t},Hr.svg.symbol=function(){function t(t,i){return(xs.get(e.call(this,t,i))||Pr)(n.call(this,t,i))}var e=Er,n=Fr;return t.type=function(n){return arguments.length?(e=xt(n),t):e},t.size=function(e){return arguments.length?(n=xt(e),t):n},t};var xs=Hr.map({circle:Pr,cross:function(t){var e=Math.sqrt(t/5)/2;return"M"+-3*e+","+-e+"H"+-e+"V"+-3*e+"H"+e+"V"+-e+"H"+3*e+"V"+e+"H"+e+"V"+3*e+"H"+-e+"V"+e+"H"+-3*e+"Z"},diamond:function(t){var e=Math.sqrt(t/(2*ks)),n=e*ks;return"M0,"+-e+"L"+n+",0 0,"+e+" "+-n+",0Z"},square:function(t){var e=Math.sqrt(t)/2;return"M"+-e+","+-e+"L"+e+","+-e+" "+e+","+e+" "+-e+","+e+"Z"},"triangle-down":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+n+"L"+e+","+-n+" "+-e+","+-n+"Z"},"triangle-up":function(t){var e=Math.sqrt(t/Ls),n=e*Ls/2;return"M0,"+-n+"L"+e+","+n+" "+-e+","+n+"Z"}});Hr.svg.symbolTypes=xs.keys();var Ls=Math.sqrt(3),ks=Math.tan(30*Mo);po.transition=function(t){for(var e,n,i=ws||++Fs,r=Nr(t),o=[],a=_s||{time:Date.now(),ease:Xn,delay:0,duration:250},s=-1,l=this.length;++s<l;){o.push(e=[]);for(var c=this[s],u=-1,h=c.length;++u<h;)(n=c[u])&&Dr(n,u,r,i,a),e.push(n)}return Ar(o,r,i)},po.interrupt=function(t){return this.each(null==t?Ss:Tr(Nr(t)))};var ws,_s,Ss=Tr(Nr()),Ms=[],Fs=0;Ms.call=po.call,Ms.empty=po.empty,Ms.node=po.node,Ms.size=po.size,Hr.transition=function(t,e){return t&&t.transition?ws?t.transition(e):t:mo.transition(t)},Hr.transition.prototype=Ms,Ms.select=function(t){var e,n,i,r=this.id,o=this.namespace,a=[];t=w(t);for(var s=-1,l=this.length;++s<l;){a.push(e=[]);for(var c=this[s],u=-1,h=c.length;++u<h;)(i=c[u])&&(n=t.call(i,i.__data__,u,s))?("__data__"in i&&(n.__data__=i.__data__),Dr(n,u,o,r,i[o][r]),e.push(n)):e.push(null)}return Ar(a,o,r)},Ms.selectAll=function(t){var e,n,i,r,o,a=this.id,s=this.namespace,l=[];t=_(t);for(var c=-1,u=this.length;++c<u;)for(var h=this[c],p=-1,d=h.length;++p<d;)if(i=h[p]){o=i[s][a],n=t.call(i,i.__data__,p,c),l.push(e=[]);for(var f=-1,g=n.length;++f<g;)(r=n[f])&&Dr(r,f,s,a,o),e.push(r)}return Ar(l,s,a)},Ms.filter=function(t){var e,n,i=[];"function"!=typeof t&&(t=$(t));for(var r=0,o=this.length;o>r;r++){i.push(e=[]);for(var a,s=0,l=(a=this[r]).length;l>s;s++)(n=a[s])&&t.call(n,n.__data__,s,r)&&e.push(n)}return Ar(i,this.namespace,this.id)},Ms.tween=function(t,e){var n=this.id,i=this.namespace;return arguments.length<2?this.node()[i][n].tween.get(t):U(this,null==e?function(e){e[i][n].tween.remove(t)}:function(r){r[i][n].tween.set(t,e)})},Ms.attr=function(t,e){function n(){this.removeAttribute(o)}function i(){this.removeAttributeNS(o.space,o.local)}if(arguments.length<2){for(e in t)this.attr(e,t[e]);return this}var r="transform"==t?oi:Hn,o=Hr.ns.qualify(t);return zr(this,"attr."+t,e,o.local?function(t){return null==t?i:(t+="",function(){var e,n=this.getAttributeNS(o.space,o.local);return n!==t&&(e=r(n,t),function(t){this.setAttributeNS(o.space,o.local,e(t))})})}:function(t){return null==t?n:(t+="",function(){var e,n=this.getAttribute(o);return n!==t&&(e=r(n,t),function(t){this.setAttribute(o,e(t))})})})},Ms.attrTween=function(t,e){var n=Hr.ns.qualify(t);return this.tween("attr."+t,n.local?function(t,i){var r=e.call(this,t,i,this.getAttributeNS(n.space,n.local));return r&&function(t){this.setAttributeNS(n.space,n.local,r(t))}}:function(t,i){var r=e.call(this,t,i,this.getAttribute(n));return r&&function(t){this.setAttribute(n,r(t))}})},Ms.style=function(t,e,n){function i(){this.style.removeProperty(t)}var r=arguments.length;if(3>r){if("string"!=typeof t){for(n in 2>r&&(e=""),t)this.style(n,t[n],e);return this}n=""}return zr(this,"style."+t,e,function(e){return null==e?i:(e+="",function(){var i,r=Wr.getComputedStyle(this,null).getPropertyValue(t);return r!==e&&(i=Hn(r,e),function(e){this.style.setProperty(t,i(e),n)})})})},Ms.styleTween=function(t,e,n){return arguments.length<3&&(n=""),this.tween("style."+t,function(i,r){var o=e.call(this,i,r,Wr.getComputedStyle(this,null).getPropertyValue(t));return o&&function(e){this.style.setProperty(t,o(e),n)}})},Ms.text=function(t){return zr(this,"text",t,Br)},Ms.remove=function(){var t=this.namespace;return this.each("end.transition",function(){var e;this[t].count<2&&(e=this.parentNode)&&e.removeChild(this)})},Ms.ease=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].ease:("function"!=typeof t&&(t=Hr.ease.apply(Hr,arguments)),U(this,function(i){i[n][e].ease=t}))},Ms.delay=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].delay:U(this,"function"==typeof t?function(i,r,o){i[n][e].delay=+t.call(i,i.__data__,r,o)}:(t=+t,function(i){i[n][e].delay=t}))},Ms.duration=function(t){var e=this.id,n=this.namespace;return arguments.length<1?this.node()[n][e].duration:U(this,"function"==typeof t?function(i,r,o){i[n][e].duration=Math.max(1,t.call(i,i.__data__,r,o))}:(t=Math.max(1,t),function(i){i[n][e].duration=t}))},Ms.each=function(t,e){var n=this.id,i=this.namespace;if(arguments.length<2){var r=_s,o=ws;try{ws=n,U(this,function(e,r,o){_s=e[i][n],t.call(e,e.__data__,r,o)})}finally{_s=r,ws=o}}else U(this,function(r){var o=r[i][n];(o.event||(o.event=Hr.dispatch("start","end","interrupt"))).on(t,e)});return this},Ms.transition=function(){for(var t,e,n,i=this.id,r=++Fs,o=this.namespace,a=[],s=0,l=this.length;l>s;s++){a.push(t=[]);for(var c,u=0,h=(c=this[s]).length;h>u;u++)(e=c[u])&&Dr(e,u,o,r,{time:(n=e[o][i]).time,ease:n.ease,delay:n.delay+n.duration,duration:n.duration}),t.push(e)}return Ar(a,o,r)},Hr.svg.axis=function(){function t(t){t.each(function(){var t,c=Hr.select(this),u=this.__chart__||n,h=this.__chart__=n.copy(),p=null==l?h.ticks?h.ticks.apply(h,s):h.domain():l,d=null==e?h.tickFormat?h.tickFormat.apply(h,s):Lt:e,f=c.selectAll(".tick").data(p,h),g=f.enter().insert("g",".domain").attr("class","tick").style("opacity",xo),m=Hr.transition(f.exit()).style("opacity",xo).remove(),y=Hr.transition(f.order()).style("opacity",1),v=Math.max(r,0)+a,C=Vi(h),b=c.selectAll(".domain").data([0]),x=(b.enter().append("path").attr("class","domain"),Hr.transition(b));g.append("line"),g.append("text");var L,k,w,_,S=g.select("line"),M=y.select("line"),F=f.select("text").text(d),E=g.select("text"),P=y.select("text"),T="top"===i||"left"===i?-1:1;if("bottom"===i||"top"===i?(t=$r,L="x",w="y",k="x2",_="y2",F.attr("dy",0>T?"0em":".71em").style("text-anchor","middle"),x.attr("d","M"+C[0]+","+T*o+"V0H"+C[1]+"V"+T*o)):(t=Or,L="y",w="x",k="y2",_="x2",F.attr("dy",".32em").style("text-anchor",0>T?"end":"start"),x.attr("d","M"+T*o+","+C[0]+"H0V"+C[1]+"H"+T*o)),S.attr(_,T*r),E.attr(w,T*v),M.attr(k,0).attr(_,T*r),P.attr(L,0).attr(w,T*v),h.rangeBand){var A=h,z=A.rangeBand()/2;u=h=function(t){return A(t)+z}}else u.rangeBand?u=h:m.call(t,h,u);g.call(t,u,h),y.call(t,h,h)})}var e,n=Hr.scale.linear(),i=Es,r=6,o=6,a=3,s=[10],l=null;return t.scale=function(e){return arguments.length?(n=e,t):n},t.orient=function(e){return arguments.length?(i=e in Ps?e+"":Es,t):i},t.ticks=function(){return arguments.length?(s=arguments,t):s},t.tickValues=function(e){return arguments.length?(l=e,t):l},t.tickFormat=function(n){return arguments.length?(e=n,t):e},t.tickSize=function(e){var n=arguments.length;return n?(r=+e,o=+arguments[n-1],t):r},t.innerTickSize=function(e){return arguments.length?(r=+e,t):r},t.outerTickSize=function(e){return arguments.length?(o=+e,t):o},t.tickPadding=function(e){return arguments.length?(a=+e,t):a},t.tickSubdivide=function(){return arguments.length&&t},t};var Es="bottom",Ps={top:1,right:1,bottom:1,left:1};Hr.svg.brush=function(){function t(o){o.each(function(){var o=Hr.select(this).style("pointer-events","all").style("-webkit-tap-highlight-color","rgba(0,0,0,0)").on("mousedown.brush",r).on("touchstart.brush",r),a=o.selectAll(".background").data([0]);a.enter().append("rect").attr("class","background").style("visibility","hidden").style("cursor","crosshair"),o.selectAll(".extent").data([0]).enter().append("rect").attr("class","extent").style("cursor","move");var s=o.selectAll(".resize").data(f,Lt);s.exit().remove(),s.enter().append("g").attr("class",function(t){return"resize "+t}).style("cursor",function(t){return Ts[t]}).append("rect").attr("x",function(t){return/[ew]$/.test(t)?-3:null}).attr("y",function(t){return/^[ns]/.test(t)?-3:null}).attr("width",6).attr("height",6).style("visibility","hidden"),s.style("display",t.empty()?"none":null);var u,h=Hr.transition(o),p=Hr.transition(a);l&&(u=Vi(l),p.attr("x",u[0]).attr("width",u[1]-u[0]),n(h)),c&&(u=Vi(c),p.attr("y",u[0]).attr("height",u[1]-u[0]),i(h)),e(h)})}function e(t){t.selectAll(".resize").attr("transform",function(t){return"translate("+u[+/e$/.test(t)]+","+h[+/^s/.test(t)]+")"})}function n(t){t.select(".extent").attr("x",u[0]),t.selectAll(".extent,.n>rect,.s>rect").attr("width",u[1]-u[0])}function i(t){t.select(".extent").attr("y",h[0]),t.selectAll(".extent,.e>rect,.w>rect").attr("height",h[1]-h[0])}function r(){function r(){var t=Hr.mouse(v),r=!1;y&&(t[0]+=y[0],t[1]+=y[1]),S||(Hr.event.altKey?(m||(m=[(u[0]+u[1])/2,(h[0]+h[1])/2]),F[0]=u[+(t[0]<m[0])],F[1]=h[+(t[1]<m[1])]):m=null),w&&f(t,l,0)&&(n(L),r=!0),_&&f(t,c,1)&&(i(L),r=!0),r&&(e(L),x({type:"brush",mode:S?"move":"resize"}))}function f(t,e,n){var i,r,s=Vi(e),l=s[0],c=s[1],f=F[n],g=n?h:u,y=g[1]-g[0];return S&&(l-=f,c-=y+f),i=(n?d:p)?Math.max(l,Math.min(c,t[n])):t[n],S?r=(i+=f)+y:(m&&(f=Math.max(l,Math.min(c,2*m[n]-i))),i>f?(r=i,i=f):r=f),g[0]!=i||g[1]!=r?(n?a=null:o=null,g[0]=i,g[1]=r,!0):void 0}function g(){r(),L.style("pointer-events","all").selectAll(".resize").style("display",t.empty()?"none":null),Hr.select("body").style("cursor",null),E.on("mousemove.brush",null).on("mouseup.brush",null).on("touchmove.brush",null).on("touchend.brush",null).on("keydown.brush",null).on("keyup.brush",null),M(),x({type:"brushend"})}var m,y,v=this,C=Hr.select(Hr.event.target),x=s.of(v,arguments),L=Hr.select(v),k=C.datum(),w=!/^(n|s)$/.test(k)&&l,_=!/^(e|w)$/.test(k)&&c,S=C.classed("extent"),M=H(),F=Hr.mouse(v),E=Hr.select(Wr).on("keydown.brush",function(){32==Hr.event.keyCode&&(S||(m=null,F[0]-=u[1],F[1]-=h[1],S=2),b())}).on("keyup.brush",function(){32==Hr.event.keyCode&&2==S&&(F[0]+=u[1],F[1]+=h[1],S=0,b())});if(Hr.event.changedTouches?E.on("touchmove.brush",r).on("touchend.brush",g):E.on("mousemove.brush",r).on("mouseup.brush",g),L.interrupt().selectAll("*").interrupt(),S)F[0]=u[0]-F[0],F[1]=h[0]-F[1];else if(k){var P=+/w$/.test(k),T=+/^n/.test(k);y=[u[1-P]-F[0],h[1-T]-F[1]],F[0]=u[P],F[1]=h[T]}else Hr.event.altKey&&(m=F.slice());L.style("pointer-events","none").selectAll(".resize").style("display",null),Hr.select("body").style("cursor",C.style("cursor")),x({type:"brushstart"}),r()}var o,a,s=L(t,"brushstart","brush","brushend"),l=null,c=null,u=[0,0],h=[0,0],p=!0,d=!0,f=As[0];return t.event=function(t){t.each(function(){var t=s.of(this,arguments),e={x:u,y:h,i:o,j:a},n=this.__chart__||e;this.__chart__=e,ws?Hr.select(this).transition().each("start.brush",function(){o=n.i,a=n.j,u=n.x,h=n.y,t({type:"brushstart"})}).tween("brush:brush",function(){var n=qn(u,e.x),i=qn(h,e.y);return o=a=null,function(r){u=e.x=n(r),h=e.y=i(r),t({type:"brush",mode:"resize"})}}).each("end.brush",function(){o=e.i,a=e.j,t({type:"brush",mode:"resize"}),t({type:"brushend"})}):(t({type:"brushstart"}),t({type:"brush",mode:"resize"}),t({type:"brushend"}))})},t.x=function(e){return arguments.length?(f=As[!(l=e)<<1|!c],t):l},t.y=function(e){return arguments.length?(f=As[!l<<1|!(c=e)],t):c},t.clamp=function(e){return arguments.length?(l&&c?(p=!!e[0],d=!!e[1]):l?p=!!e:c&&(d=!!e),t):l&&c?[p,d]:l?p:c?d:null},t.extent=function(e){var n,i,r,s,p;return arguments.length?(l&&(n=e[0],i=e[1],c&&(n=n[0],i=i[0]),o=[n,i],l.invert&&(n=l(n),i=l(i)),n>i&&(p=n,n=i,i=p),(n!=u[0]||i!=u[1])&&(u=[n,i])),c&&(r=e[0],s=e[1],l&&(r=r[1],s=s[1]),a=[r,s],c.invert&&(r=c(r),s=c(s)),r>s&&(p=r,r=s,s=p),(r!=h[0]||s!=h[1])&&(h=[r,s])),t):(l&&(o?(n=o[0],i=o[1]):(n=u[0],i=u[1],l.invert&&(n=l.invert(n),i=l.invert(i)),n>i&&(p=n,n=i,i=p))),c&&(a?(r=a[0],s=a[1]):(r=h[0],s=h[1],c.invert&&(r=c.invert(r),s=c.invert(s)),r>s&&(p=r,r=s,s=p))),l&&c?[[n,r],[i,s]]:l?[n,i]:c&&[r,s])},t.clear=function(){return t.empty()||(u=[0,0],h=[0,0],o=a=null),t},t.empty=function(){return!!l&&u[0]==u[1]||!!c&&h[0]==h[1]},Hr.rebind(t,s,"on")};var Ts={n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},As=[["n","e","s","w","nw","ne","se","sw"],["e","w"],["n","s"],[]],zs=Qo.format=ra.timeFormat,Bs=zs.utc,Ns=Bs("%Y-%m-%dT%H:%M:%S.%LZ");zs.iso=Date.prototype.toISOString&&+new Date("2000-01-01T00:00:00.000Z")?Ur:Ns,Ur.parse=function(t){var e=new Date(t);return isNaN(e)?null:e},Ur.toString=Ns.toString,Qo.second=Tt(function(t){return new Jo(1e3*Math.floor(t/1e3))},function(t,e){t.setTime(t.getTime()+1e3*Math.floor(e))},function(t){return t.getSeconds()}),Qo.seconds=Qo.second.range,Qo.seconds.utc=Qo.second.utc.range,Qo.minute=Tt(function(t){return new Jo(6e4*Math.floor(t/6e4))},function(t,e){t.setTime(t.getTime()+6e4*Math.floor(e))},function(t){return t.getMinutes()}),Qo.minutes=Qo.minute.range,Qo.minutes.utc=Qo.minute.utc.range,Qo.hour=Tt(function(t){var e=t.getTimezoneOffset()/60;return new Jo(36e5*(Math.floor(t/36e5-e)+e))},function(t,e){t.setTime(t.getTime()+36e5*Math.floor(e))},function(t){return t.getHours()}),Qo.hours=Qo.hour.range,Qo.hours.utc=Qo.hour.utc.range,Qo.month=Tt(function(t){return(t=Qo.day(t)).setDate(1),t},function(t,e){t.setMonth(t.getMonth()+e)},function(t){return t.getMonth()}),Qo.months=Qo.month.range,Qo.months.utc=Qo.month.utc.range;var Ds=[1e3,5e3,15e3,3e4,6e4,3e5,9e5,18e5,36e5,108e5,216e5,432e5,864e5,1728e5,6048e5,2592e6,7776e6,31536e6],$s=[[Qo.second,1],[Qo.second,5],[Qo.second,15],[Qo.second,30],[Qo.minute,1],[Qo.minute,5],[Qo.minute,15],[Qo.minute,30],[Qo.hour,1],[Qo.hour,3],[Qo.hour,6],[Qo.hour,12],[Qo.day,1],[Qo.day,2],[Qo.week,1],[Qo.month,1],[Qo.month,3],[Qo.year,1]],Os=zs.multi([[".%L",function(t){return t.getMilliseconds()}],[":%S",function(t){return t.getSeconds()}],["%I:%M",function(t){return t.getMinutes()}],["%I %p",function(t){return t.getHours()}],["%a %d",function(t){return t.getDay()&&1!=t.getDate()}],["%b %d",function(t){return 1!=t.getDate()}],["%B",function(t){return t.getMonth()}],["%Y",ve]]),Us={range:function(t,e,n){return Hr.range(Math.ceil(t/n)*n,+e,n).map(Rr)},floor:Lt,ceil:Lt};$s.year=Qo.year,Qo.scale=function(){return Ir(Hr.scale.linear(),$s,Os)};var Is=$s.map(function(t){return[t[0].utc,t[1]]}),Rs=Bs.multi([[".%L",function(t){return t.getUTCMilliseconds()}],[":%S",function(t){return t.getUTCSeconds()}],["%I:%M",function(t){return t.getUTCMinutes()}],["%I %p",function(t){return t.getUTCHours()}],["%a %d",function(t){return t.getUTCDay()&&1!=t.getUTCDate()}],["%b %d",function(t){return 1!=t.getUTCDate()}],["%B",function(t){return t.getUTCMonth()}],["%Y",ve]]);Is.year=Qo.year.utc,Qo.scale.utc=function(){return Ir(Hr.scale.linear(),Is,Rs)},Hr.text=kt(function(t){return t.responseText}),Hr.json=function(t,e){return wt(t,"application/json",Yr,e)},Hr.html=function(t,e){return wt(t,"text/html",Zr,e)},Hr.xml=kt(function(t){return t.responseXML}),"function"==typeof define&&define.amd?define(Hr):"object"==typeof module&&module.exports&&(module.exports=Hr),this.d3=Hr}(),function(t,e,n,i){"use strict";var r=function(){return this.init.apply(this,arguments)};r.prototype={defaults:{onstatechange:function(){},ondragend:function(){},ondragstart:function(){},isRange:!1,showLabels:!0,showScale:!0,step:1,format:"%s",theme:"theme-green",width:300,disable:!1},template:'<div class="slider-container">\t\t\t<div class="back-bar"> <div class="selected-bar"></div> <div class="pointer low"></div><div class="pointer-label">123456</div> <div class="pointer high"></div><div class="pointer-label">456789</div> <div class="clickable-dummy"></div> <div class="numeric-value"></div> </div> <div class="scale"></div>\t\t</div>',init:function(e,n){this.options=t.extend({},this.defaults,n),this.inputNode=t(e),this.options.value=this.inputNode.val()||(this.options.isRange?this.options.from+","+this.options.from:this.options.from),this.domNode=t(this.template),this.domNode.addClass(this.options.theme),this.inputNode.after(this.domNode),this.domNode.on("change",this.onChange),this.pointers=t(".pointer",this.domNode),this.lowPointer=this.pointers.first(),this.highPointer=this.pointers.last(),this.labels=t(".pointer-label",this.domNode),this.lowLabel=this.labels.first(),this.highLabel=this.labels.last(),this.scale=t(".scale",this.domNode),this.bar=t(".selected-bar",this.domNode),this.clickableBar=this.domNode.find(".clickable-dummy"),this.interval=this.options.to-this.options.from,this.render()},render:function(){(0!==this.inputNode.width()||this.options.width)&&(this.domNode.width(this.options.width||this.inputNode.width()),this.inputNode.hide(),this.isSingle()&&(this.lowPointer.hide(),this.lowLabel.hide()),this.options.showLabels||this.labels.hide(),this.attachEvents(),this.options.showScale&&this.renderScale(),this.setValue(this.options.value))},isSingle:function(){return"number"==typeof this.options.value||-1===this.options.value.indexOf(",")&&!this.options.isRange},attachEvents:function(){this.clickableBar.click(t.proxy(this.barClicked,this)),this.pointers.on("mousedown touchstart",t.proxy(this.onDragStart,this)),this.pointers.bind("dragstart",function(t){t.preventDefault()})},onDragStart:function(e){if(!(this.options.disable||"mousedown"===e.type&&1!==e.which)){e.stopPropagation(),e.preventDefault();var i=t(e.target);this.pointers.removeClass("last-active"),i.addClass("focused last-active"),this[(i.hasClass("low")?"low":"high")+"Label"].addClass("focused"),t(n).on("mousemove.slider touchmove.slider",t.proxy(this.onDrag,this,i)),t(n).on("mouseup.slider touchend.slider touchcancel.slider",t.proxy(this.onDragEnd,this)),this.options.ondragstart.call(this)}},onDrag:function(t,e){e.stopPropagation(),e.preventDefault(),e.originalEvent.touches&&e.originalEvent.touches.length?e=e.originalEvent.touches[0]:e.originalEvent.changedTouches&&e.originalEvent.changedTouches.length&&(e=e.originalEvent.changedTouches[0]);var n=e.clientX-this.domNode.offset().left;this.domNode.trigger("change",[this,t,n])},onDragEnd:function(e){this.pointers.removeClass("focused"),this.labels.removeClass("focused"),t(n).off(".slider"),this.options.ondragend.call(this,this.options.value)},barClicked:function(t){if(!this.options.disable){var e=t.pageX-this.clickableBar.offset().left;if(this.isSingle())this.setPosition(this.pointers.last(),e,!0,!0);else{var n=Math.abs(parseInt(this.pointers.first().css("left"),10)-e+this.pointers.first().width()/2)<Math.abs(parseInt(this.pointers.last().css("left"),10)-e+this.pointers.first().width()/2)?this.pointers.first():this.pointers.last();this.setPosition(n,e,!0,!0)}}},onChange:function(t,e,n,i){var r,o;e.isSingle()?(r=0,o=e.domNode.width()):(r=n.hasClass("high")?e.lowPointer.position().left+e.lowPointer.width()/2:0,o=n.hasClass("low")?e.highPointer.position().left+e.highPointer.width()/2:e.domNode.width());var a=Math.min(Math.max(i,r),o);e.setPosition(n,a,!0)},setPosition:function(t,e,n,i){var r,o=this.lowPointer.position().left,a=this.highPointer.position().left,s=this.highPointer.width()/2;n||(e=this.prcToPx(e)),t[0]===this.highPointer[0]?a=Math.round(e-s):o=Math.round(e-s),t[i?"animate":"css"]({left:Math.round(e-s)}),r=this.isSingle()?0:o+s,this.bar[i?"animate":"css"]({width:Math.round(a+s-r),left:r}),this.showPointerValue(t,e,i),this.isReadonly()},setValue:function(e){var n=e.toString().split(",");if(this.options.value=e,this.isSingle()){var i="";i=t.isFunction(this.options.format)?this.options.format(e):this.options.format.replace("%s",e),t(".numeric-value",this.domNode).html(i)}var r=this.valuesToPrc(2===n.length?n:[0,n[0]]);this.isSingle()?this.setPosition(this.highPointer,r[1]):(this.setPosition(this.lowPointer,r[0]),this.setPosition(this.highPointer,r[1]))},renderScale:function(){for(var e=this.options.scale||[this.options.from,this.options.to],n=Math.round(100/(e.length-1)*10)/10,i="",r=0;r<e.length;r++)i+='<span style="left: '+r*n+'%">'+("|"!=e[r]?"<ins>"+e[r]+"</ins>":"")+"</span>";this.scale.html(i),t("ins",this.scale).each(function(){t(this).css({marginLeft:-t(this).outerWidth()/2})})},getBarWidth:function(){var t=this.options.value.split(",");return t.length>1?parseInt(t[1],10)-parseInt(t[0],10):parseInt(t[0],10)},showPointerValue:function(e,n,i){var r,o=t(".pointer-label",this.domNode)[e.hasClass("low")?"first":"last"](),a=this.positionToValue(n);if(t.isFunction(this.options.format)){var s=this.isSingle()?void 0:e.hasClass("low")?"low":"high";r=this.options.format(a,s)}else r=this.options.format.replace("%s",a);var l=o.html(r).width(),c=n-l/2;c=Math.min(Math.max(c,0),this.options.width-l),o[i?"animate":"css"]({left:c}),this.setInputValue(e,a)},valuesToPrc:function(t){return[100*(t[0]-this.options.from)/this.interval,100*(t[1]-this.options.from)/this.interval]},prcToPx:function(t){return this.domNode.width()*t/100},positionToValue:function(t){var e=t/this.domNode.width()*this.interval;return e+=this.options.from,Math.round(e/this.options.step)*this.options.step},setInputValue:function(e,n){if(this.isSingle()){this.options.value=n.toString();var i="";i=t.isFunction(this.options.format)?this.options.format(this.options.value):this.options.format.replace("%s",this.options.value),t(".numeric-value",this.domNode).html(i)}else{var r=this.options.value.split(",");e.hasClass("low")?this.options.value=n+","+r[1]:this.options.value=r[0]+","+n}this.inputNode.val()!==this.options.value&&(this.inputNode.val(this.options.value),this.options.onstatechange.call(this,this.options.value))},getValue:function(){return this.options.value},isReadonly:function(){this.domNode.toggleClass("slider-readonly",this.options.disable)},disable:function(){this.options.disable=!0,this.isReadonly()},enable:function(){this.options.disable=!1,this.isReadonly()},toggleDisable:function(){this.options.disable=!this.options.disable,this.isReadonly()}};t.fn.jRange=function(n){var i,o=arguments;return this.each(function(){var a=t(this),s=t.data(this,"plugin_jRange"),l="object"==typeof n&&n;s||(a.data("plugin_jRange",s=new r(this,l)),t(e).resize(function(){s.setValue(s.getValue())})),"string"==typeof n&&(i=s[n].apply(s,Array.prototype.slice.call(o,1)))}),i||this}}(jQuery,window,document),function(t,e){var n=!0;function i(){this._state=[],this._defaults={classHolder:"sbHolder",classHolderDisabled:"sbHolderDisabled",classSelector:"sbSelector",classOptions:"sbOptions",classGroup:"sbGroup",classSub:"sbSub",classDisabled:"sbDisabled",classToggleOpen:"sbToggleOpen",classToggle:"sbToggle",classFocus:"sbFocus",speed:200,effect:"slide",onChange:null,onOpen:null,onClose:null}}t.extend(i.prototype,{_isOpenSelectbox:function(t){return!!t&&this._getInst(t).isOpen},_isDisabledSelectbox:function(t){return!!t&&this._getInst(t).isDisabled},_attachSelectbox:function(e,i){if(this._getInst(e))return!1;var r,o,a,s,l=t(e),c=this,u=c._newInst(l),h=!1,p=(l.find("optgroup"),l.find("option")),d=p.length;function f(){var e,n,i=this.attr("id").split("_")[1];for(e in c._state)e!==i&&c._state.hasOwnProperty(e)&&(n=t("select[sb='"+e+"']")[0])&&c._closeSelectbox(n)}function g(){var i=!(!arguments[1]||!arguments[1].sub),r=!(!arguments[1]||!arguments[1].disabled);arguments[0].each(function(l){var p,f=t(this),g=t("<li>");f.is(":selected")&&(o.text(f.text()),h=n),l===d-1&&g.addClass("last"),f.is(":disabled")||r?(p=t("<span>",{text:f.text()}).addClass(u.settings.classDisabled),i&&p.addClass(u.settings.classSub),p.appendTo(g)):(p=t("<a>",{href:"#"+f.val(),rel:f.val()}).text(f.text()).bind("click.sb",function(n){n&&n.preventDefault&&n.preventDefault();var i=a,r=t(this);i.attr("id").split("_")[1];c._changeSelectbox(e,r.attr("rel"),r.text()),c._closeSelectbox(e)}).bind("mouseover.sb",function(){var e=t(this);e.parent().siblings().find("a").removeClass(u.settings.classFocus),e.addClass(u.settings.classFocus)}).bind("mouseout.sb",function(){t(this).removeClass(u.settings.classFocus)}),i&&p.addClass(u.settings.classSub),f.is(":selected")&&p.addClass(u.settings.classFocus),p.appendTo(g)),g.appendTo(s)})}l.attr("sb",u.uid),t.extend(u.settings,c._defaults,i),c._state[u.uid]=!1,l.hide(),r=t("<div>",{id:"sbHolder_"+u.uid,class:u.settings.classHolder,tabindex:l.attr("tabindex")}),o=t("<a>",{id:"sbSelector_"+u.uid,href:"#",class:u.settings.classSelector,click:function(n){n.preventDefault(),f.apply(t(this),[]);var i=t(this).attr("id").split("_")[1];c._state[i]?c._closeSelectbox(e):c._openSelectbox(e)}}),(a=t("<a>",{id:"sbToggle_"+u.uid,href:"#",class:u.settings.classToggle,click:function(n){n.preventDefault(),f.apply(t(this),[]);var i=t(this).attr("id").split("_")[1];c._state[i]?c._closeSelectbox(e):c._openSelectbox(e)}})).appendTo(r),s=t("<ul>",{id:"sbOptions_"+u.uid,class:u.settings.classOptions,css:{display:"none"}}),l.children().each(function(e){var n,i=t(this),r={};i.is("option")?g(i):i.is("optgroup")&&(n=t("<li>"),t("<span>",{text:i.attr("label")}).addClass(u.settings.classGroup).appendTo(n),n.appendTo(s),i.is(":disabled")&&(r.disabled=!0),r.sub=!0,g(i.find("option"),r))}),h||o.text(p.first().text()),t.data(e,"selectbox",u),r.data("uid",u.uid).bind("keydown.sb",function(e){var n=e.charCode?e.charCode:e.keyCode?e.keyCode:0,i=t(this),r=i.data("uid"),o=i.siblings("select[sb='"+r+"']").data("selectbox"),a=i.siblings(["select[sb='",r,"']"].join("")).get(0),s=i.find("ul").find("a."+o.settings.classFocus);switch(n){case 37:case 38:if(s.length>0)t("a",i).removeClass(o.settings.classFocus),(l=s.parent().prevAll("li:has(a)").eq(0).find("a")).length>0&&(l.addClass(o.settings.classFocus).focus(),t("#sbSelector_"+r).text(l.text()));break;case 39:case 40:var l;t("a",i).removeClass(o.settings.classFocus),(l=s.length>0?s.parent().nextAll("li:has(a)").eq(0).find("a"):i.find("ul").find("a").eq(0)).length>0&&(l.addClass(o.settings.classFocus).focus(),t("#sbSelector_"+r).text(l.text()));break;case 13:s.length>0&&c._changeSelectbox(a,s.attr("rel"),s.text()),c._closeSelectbox(a);break;case 9:if(a)(o=c._getInst(a))&&(s.length>0&&c._changeSelectbox(a,s.attr("rel"),s.text()),c._closeSelectbox(a));var u=parseInt(i.attr("tabindex"),10);e.shiftKey?u--:u++,t("*[tabindex='"+u+"']").focus();break;case 27:c._closeSelectbox(a)}return e.stopPropagation(),!1}).delegate("a","mouseover",function(e){t(this).addClass(u.settings.classFocus)}).delegate("a","mouseout",function(e){t(this).removeClass(u.settings.classFocus)}),o.appendTo(r),s.appendTo(r),r.insertAfter(l),t("html").on("mousedown",function(e){e.stopPropagation(),t("select").selectbox("close")}),t([".",u.settings.classHolder,", .",u.settings.classSelector].join("")).mousedown(function(t){t.stopPropagation()})},_detachSelectbox:function(e){var n=this._getInst(e);if(!n)return!1;t("#sbHolder_"+n.uid).remove(),t.data(e,"selectbox",null),t(e).show()},_changeSelectbox:function(e,i,r){var o,a=this._getInst(e);a&&(o=this._get(a,"onChange"),t("#sbSelector_"+a.uid).text(r)),i=i.replace(/\'/g,"\\'"),t(e).find("option[value='"+i+"']").attr("selected",n),a&&o?o.apply(a.input?a.input[0]:null,[i,a]):a&&a.input&&a.input.trigger("change")},_enableSelectbox:function(e){var n=this._getInst(e);if(!n||!n.isDisabled)return!1;t("#sbHolder_"+n.uid).removeClass(n.settings.classHolderDisabled),n.isDisabled=!1,t.data(e,"selectbox",n)},_disableSelectbox:function(e){var i=this._getInst(e);if(!i||i.isDisabled)return!1;t("#sbHolder_"+i.uid).addClass(i.settings.classHolderDisabled),i.isDisabled=n,t.data(e,"selectbox",i)},_optionSelectbox:function(e,n,i){var r=this._getInst(e);if(!r)return!1;r[n]=i,t.data(e,"selectbox",r)},_openSelectbox:function(e){var i=this._getInst(e);if(i&&!i.isOpen&&!i.isDisabled){var r=t("#sbOptions_"+i.uid),o=parseInt(t(window).height(),10),a=t("#sbHolder_"+i.uid).offset(),s=t(window).scrollTop(),l=r.prev().height(),c=o-(a.top-s)-l/2,u=this._get(i,"onOpen");r.css({top:l+"px",maxHeight:c-l+"px"}),"fade"===i.settings.effect?r.fadeIn(i.settings.speed):r.slideDown(i.settings.speed),t("#sbToggle_"+i.uid).addClass(i.settings.classToggleOpen),this._state[i.uid]=n,i.isOpen=n,u&&u.apply(i.input?i.input[0]:null,[i]),t.data(e,"selectbox",i)}},_closeSelectbox:function(e){var n=this._getInst(e);if(n&&n.isOpen){var i=this._get(n,"onClose");"fade"===n.settings.effect?t("#sbOptions_"+n.uid).fadeOut(n.settings.speed):t("#sbOptions_"+n.uid).slideUp(n.settings.speed),t("#sbToggle_"+n.uid).removeClass(n.settings.classToggleOpen),this._state[n.uid]=!1,n.isOpen=!1,i&&i.apply(n.input?n.input[0]:null,[n]),t.data(e,"selectbox",n)}},_newInst:function(t){return{id:t[0].id.replace(/([^A-Za-z0-9_-])/g,"\\\\$1"),input:t,uid:Math.floor(99999999*Math.random()),isOpen:!1,isDisabled:!1,settings:{}}},_getInst:function(e){try{return t.data(e,"selectbox")}catch(t){throw"Missing instance data for this selectbox"}},_get:function(t,e){return void 0!==t.settings[e]?t.settings[e]:this._defaults[e]}}),t.fn.selectbox=function(e){var n=Array.prototype.slice.call(arguments,1);return"string"==typeof e&&"isDisabled"==e?t.selectbox["_"+e+"Selectbox"].apply(t.selectbox,[this[0]].concat(n)):"option"==e&&2==arguments.length&&"string"==typeof arguments[1]?t.selectbox["_"+e+"Selectbox"].apply(t.selectbox,[this[0]].concat(n)):this.each(function(){"string"==typeof e?t.selectbox["_"+e+"Selectbox"].apply(t.selectbox,[this].concat(n)):t.selectbox._attachSelectbox(this,e)})},t.selectbox=new i,t.selectbox.version="0.2"}(jQuery),function(t,e,n){function i(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent("on"+e,n)}function r(t){if("keypress"==t.type){var e=String.fromCharCode(t.which);return t.shiftKey||(e=e.toLowerCase()),e}return c[t.which]?c[t.which]:u[t.which]?u[t.which]:String.fromCharCode(t.which).toLowerCase()}function o(t){return"shift"==t||"ctrl"==t||"alt"==t||"meta"==t}function a(t,e){var n,i,r,a=[];for("+"===(n=t)?n=["+"]:n=(n=n.replace(/\+{2}/g,"+plus")).split("+"),r=0;r<n.length;++r)i=n[r],p[i]&&(i=p[i]),e&&"keypress"!=e&&h[i]&&(i=h[i],a.push("shift")),o(i)&&a.push(i);if(n=i,!(r=e)){if(!l)for(var s in l={},c)95<s&&112>s||c.hasOwnProperty(s)&&(l[c[s]]=s);r=l[n]?"keydown":"keypress"}return"keypress"==r&&a.length&&(r="keydown"),{key:i,modifiers:a,action:r}}function s(t){function n(t){t=t||{};var e,n=!1;for(e in g)t[e]?n=!0:g[e]=0;n||(v=!1)}function l(t,e,n,i,r,a){var s,l,c=[],u=n.type;if(!d._callbacks[t])return[];for("keyup"==u&&o(t)&&(e=[t]),s=0;s<d._callbacks[t].length;++s)if(l=d._callbacks[t][s],(i||!l.seq||g[l.seq]==l.level)&&u==l.action){var h;(h="keypress"==u&&!n.metaKey&&!n.ctrlKey)||(h=l.modifiers,h=e.sort().join(",")===h.sort().join(",")),h&&(h=i&&l.seq==i&&l.level==a,(!i&&l.combo==r||h)&&d._callbacks[t].splice(s,1),c.push(l))}return c}function c(t,e,n,i){d.stopCallback(e,e.target||e.srcElement,n,i)||!1!==t(e,n)||(e.preventDefault?e.preventDefault():e.returnValue=!1,e.stopPropagation?e.stopPropagation():e.cancelBubble=!0)}function u(t){"number"!=typeof t.which&&(t.which=t.keyCode);var e=r(t);e&&("keyup"==t.type&&m===e?m=!1:d.handleKey(e,function(t){var e=[];return t.shiftKey&&e.push("shift"),t.altKey&&e.push("alt"),t.ctrlKey&&e.push("ctrl"),t.metaKey&&e.push("meta"),e}(t),t))}function h(t,e,i,o){function s(e){return function(){v=e,++g[t],clearTimeout(f),f=setTimeout(n,1e3)}}function l(e){c(i,e,t),"keyup"!==o&&(m=r(e)),setTimeout(n,10)}for(var u=g[t]=0;u<e.length;++u){var h=u+1===e.length?l:s(o||a(e[u+1]).action);p(e[u],h,o,t,u)}}function p(t,e,n,i,r){d._directMap[t+":"+n]=e;var o=(t=t.replace(/\s+/g," ")).split(" ");1<o.length?h(t,o,e,n):(n=a(t,n),d._callbacks[n.key]=d._callbacks[n.key]||[],l(n.key,n.modifiers,{type:n.action},i,t,r),d._callbacks[n.key][i?"unshift":"push"]({callback:e,modifiers:n.modifiers,action:n.action,seq:i,level:r,combo:t}))}var d=this;if(t=t||e,!(d instanceof s))return new s(t);d.target=t,d._callbacks={},d._directMap={};var f,g={},m=!1,y=!1,v=!1;d._handleKey=function(t,e,i){var r,a=l(t,e,i);e={};var s=0,u=!1;for(r=0;r<a.length;++r)a[r].seq&&(s=Math.max(s,a[r].level));for(r=0;r<a.length;++r)a[r].seq?a[r].level==s&&(u=!0,e[a[r].seq]=1,c(a[r].callback,i,a[r].combo,a[r].seq)):u||c(a[r].callback,i,a[r].combo);a="keypress"==i.type&&y,i.type!=v||o(t)||a||n(e),y=u&&"keydown"==i.type},d._bindMultiple=function(t,e,n){for(var i=0;i<t.length;++i)p(t[i],e,n)},i(t,"keypress",u),i(t,"keydown",u),i(t,"keyup",u)}var l,c={8:"backspace",9:"tab",13:"enter",16:"shift",17:"ctrl",18:"alt",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"ins",46:"del",91:"meta",93:"meta",224:"meta"},u={106:"*",107:"+",109:"-",110:".",111:"/",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},h={"~":"`","!":"1","@":"2","#":"3",$:"4","%":"5","^":"6","&":"7","*":"8","(":"9",")":"0",_:"-","+":"=",":":";",'"':"'","<":",",">":".","?":"/","|":"\\"},p={option:"alt",command:"meta",return:"enter",escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"};for(n=1;20>n;++n)c[111+n]="f"+n;for(n=0;9>=n;++n)c[n+96]=n;s.prototype.bind=function(t,e,n){return t=t instanceof Array?t:[t],this._bindMultiple.call(this,t,e,n),this},s.prototype.unbind=function(t,e){return this.bind.call(this,t,function(){},e)},s.prototype.trigger=function(t,e){return this._directMap[t+":"+e]&&this._directMap[t+":"+e]({},t),this},s.prototype.reset=function(){return this._callbacks={},this._directMap={},this},s.prototype.stopCallback=function(t,n){return!(-1<(" "+n.className+" ").indexOf(" mousetrap ")||function t(n,i){return null!==n&&n!==e&&(n===i||t(n.parentNode,i))}(n,this.target))&&("INPUT"==n.tagName||"SELECT"==n.tagName||"TEXTAREA"==n.tagName||n.isContentEditable)},s.prototype.handleKey=function(){return this._handleKey.apply(this,arguments)},s.init=function(){var t,n=s(e);for(t in n)"_"!==t.charAt(0)&&(s[t]=function(t){return function(){return n[t].apply(n,arguments)}}(t))},s.init(),t.Mousetrap=s,"undefined"!=typeof module&&module.exports&&(module.exports=s),"function"==typeof define&&define.amd&&define(function(){return s})}(window,document),function(t){t.fn.extend({Segment:function(){t(this).each(function(){var e=t(this),n=e.attr("onchange"),i=t("<div>",{class:"ui-segment"});t(this).find("option").each(function(){var e=t("<span>",{class:"option",onclick:n,text:t(this).text(),value:t(this).val()});t(this).is(":selected")&&e.addClass("active"),i.append(e)}),i.find("span.option").click(function(){i.find("span.option").removeClass("active"),t(this).addClass("active"),e.val(t(this).attr("value"))}),t(this).after(i),t(this).hide()})}})}(jQuery),function(){"use strict";function t(t,e,n){var i=e.x,r=e.y,o=n.x-i,a=n.y-r;if(0!==o||0!==a){var s=((t.x-i)*o+(t.y-r)*a)/(o*o+a*a);s>1?(i=n.x,r=n.y):s>0&&(i+=o*s,r+=a*s)}return(o=t.x-i)*o+(a=t.y-r)*a}function e(e,n){var i=e.length-1,r=[e[0]];return function e(n,i,r,o,a){for(var s,l=o,c=i+1;c<r;c++){var u=t(n[c],n[i],n[r]);u>l&&(s=c,l=u)}l>o&&(s-i>1&&e(n,i,s,o,a),a.push(n[s]),r-s>1&&e(n,s,r,o,a))}(e,0,i,n,r),r.push(e[i]),r}function n(t,n,i){if(t.length<=2)return t;var r=void 0!==n?n*n:1;return t=e(t=i?t:function(t,e){for(var n,i,r,o,a,s=t[0],l=[s],c=1,u=t.length;c<u;c++)n=t[c],r=s,o=(i=n).x-r.x,a=i.y-r.y,o*o+a*a>e&&(l.push(n),s=n);return s!==n&&l.push(n),l}(t,r),r)}"function"==typeof define&&define.amd?define(function(){return n}):"undefined"!=typeof module?module.exports=n:"undefined"!=typeof self?self.simplify=n:window.simplify=n}(),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof exports&&"object"==typeof module?module.exports=t:t(jQuery)}(function(t,e){"use strict";var n={beforeShow:u,move:u,change:u,show:u,hide:u,color:!1,flat:!1,showInput:!1,allowEmpty:!1,showButtons:!0,clickoutFiresChange:!0,showInitial:!1,showPalette:!1,showPaletteOnly:!1,hideAfterPaletteSelect:!1,togglePaletteOnly:!1,showSelectionPalette:!0,localStorageKey:!1,appendTo:"body",maxSelectionSize:7,cancelText:"cancel",chooseText:"choose",togglePaletteMoreText:"more",togglePaletteLessText:"less",clearText:"Clear Color Selection",noColorSelectedText:"No Color Selected",preferredFormat:!1,className:"",containerClassName:"",replacerClassName:"",showAlpha:!1,theme:"sp-light",palette:[["#ffffff","#000000","#ff0000","#ff8000","#ffff00","#008000","#0000ff","#4b0082","#9400d3"]],selectionPalette:[],disabled:!1,offset:null},i=[],r=!!/msie/i.exec(window.navigator.userAgent),o=function(){function t(t,e){return!!~(""+t).indexOf(e)}var e=document.createElement("div").style;return e.cssText="background-color:rgba(0,0,0,.5)",t(e.backgroundColor,"rgba")||t(e.backgroundColor,"hsla")}(),a=["<div class='sp-replacer'>","<div class='sp-preview'><div class='sp-preview-inner'></div></div>","<div class='sp-dd'>▼</div>","</div>"].join(""),s=function(){var t="";if(r)for(var e=1;e<=6;e++)t+="<div class='sp-"+e+"'></div>";return["<div class='sp-container sp-hidden'>","<div class='sp-palette-container'>","<div class='sp-palette sp-thumb sp-cf'></div>","<div class='sp-palette-button-container sp-cf'>","<button type='button' class='sp-palette-toggle'></button>","</div>","</div>","<div class='sp-picker-container'>","<div class='sp-top sp-cf'>","<div class='sp-fill'></div>","<div class='sp-top-inner'>","<div class='sp-color'>","<div class='sp-sat'>","<div class='sp-val'>","<div class='sp-dragger'></div>","</div>","</div>","</div>","<div class='sp-clear sp-clear-display'>","</div>","<div class='sp-hue'>","<div class='sp-slider'></div>",t,"</div>","</div>","<div class='sp-alpha'><div class='sp-alpha-inner'><div class='sp-alpha-handle'></div></div></div>","</div>","<div class='sp-input-container sp-cf'>","<input class='sp-input' type='text' spellcheck='false' />","</div>","<div class='sp-initial sp-thumb sp-cf'></div>","<div class='sp-button-container sp-cf'>","<a class='sp-cancel' href='#'></a>","<button type='button' class='sp-choose'></button>","</div>","</div>","</div>"].join("")}();function l(e,n,i,r){for(var a=[],s=0;s<e.length;s++){var l=e[s];if(l){var c=tinycolor(l),u=c.toHsl().l<.5?"sp-thumb-el sp-thumb-dark":"sp-thumb-el sp-thumb-light";u+=tinycolor.equals(n,l)?" sp-thumb-active":"";var h=c.toString(r.preferredFormat||"rgb"),p=o?"background-color:"+c.toRgbString():"filter:"+c.toFilter();a.push('<span title="'+h+'" data-color="'+c.toRgbString()+'" class="'+u+'"><span class="sp-thumb-inner" style="'+p+';" /></span>')}else{a.push(t("<div />").append(t('<span data-color="" style="background-color:transparent;" class="sp-clear-display"></span>').attr("title",r.noColorSelectedText)).html())}}return"<div class='sp-cf "+i+"'>"+a.join("")+"</div>"}function c(c,u){var g,m,y,v,C=function(e,i){var r=t.extend({},n,e);return r.callbacks={move:p(r.move,i),change:p(r.change,i),show:p(r.show,i),hide:p(r.hide,i),beforeShow:p(r.beforeShow,i)},r}(u,c),b=C.flat,x=C.showSelectionPalette,L=C.localStorageKey,k=C.theme,w=C.callbacks,_=(g=Ht,m=10,function(){var t=this,e=arguments;y&&clearTimeout(v),!y&&v||(v=setTimeout(function(){v=null,g.apply(t,e)},m))}),S=!1,M=!1,F=0,E=0,P=0,T=0,A=0,z=0,B=0,N=0,D=0,$=0,O=1,U=[],I=[],R={},Y=C.selectionPalette.slice(0),Z=C.maxSelectionSize,H="sp-dragging",q=null,j=c.ownerDocument,K=(j.body,t(c)),V=!1,W=t(s,j).addClass(k),X=W.find(".sp-picker-container"),G=W.find(".sp-color"),Q=W.find(".sp-dragger"),J=W.find(".sp-hue"),tt=W.find(".sp-slider"),et=W.find(".sp-alpha-inner"),nt=W.find(".sp-alpha"),it=W.find(".sp-alpha-handle"),rt=W.find(".sp-input"),ot=W.find(".sp-palette"),at=W.find(".sp-initial"),st=W.find(".sp-cancel"),lt=W.find(".sp-clear"),ct=W.find(".sp-choose"),ut=W.find(".sp-palette-toggle"),ht=K.is("input"),pt=ht&&"color"===K.attr("type")&&f(),dt=ht&&!b,ft=dt?t(a).addClass(k).addClass(C.className).addClass(C.replacerClassName):t([]),gt=dt?ft:K,mt=ft.find(".sp-preview-inner"),yt=C.color||ht&&K.val(),vt=!1,Ct=C.preferredFormat,bt=Ct,xt=!C.showButtons||C.clickoutFiresChange,Lt=!yt,kt=C.allowEmpty&&!pt;function wt(){if(C.showPaletteOnly&&(C.showPalette=!0),ut.text(C.showPaletteOnly?C.togglePaletteMoreText:C.togglePaletteLessText),C.palette){U=C.palette.slice(0),I=t.isArray(U[0])?U:[U],R={};for(var e=0;e<I.length;e++)for(var n=0;n<I[e].length;n++){var i=tinycolor(I[e][n]).toRgbString();R[i]=!0}}W.toggleClass("sp-flat",b),W.toggleClass("sp-input-disabled",!C.showInput),W.toggleClass("sp-alpha-enabled",C.showAlpha),W.toggleClass("sp-clear-enabled",kt),W.toggleClass("sp-buttons-disabled",!C.showButtons),W.toggleClass("sp-palette-buttons-disabled",!C.togglePaletteOnly),W.toggleClass("sp-palette-disabled",!C.showPalette),W.toggleClass("sp-palette-only",C.showPaletteOnly),W.toggleClass("sp-initial-disabled",!C.showInitial),W.addClass(C.className).addClass(C.containerClassName),Ht()}function _t(){if(L&&window.localStorage){try{var e=window.localStorage[L].split(",#");e.length>1&&(delete window.localStorage[L],t.each(e,function(t,e){St(e)}))}catch(t){}try{Y=window.localStorage[L].split(";")}catch(t){}}}function St(e){if(x){var n=tinycolor(e).toRgbString();if(!R[n]&&-1===t.inArray(n,Y))for(Y.push(n);Y.length>Z;)Y.shift();if(L&&window.localStorage)try{window.localStorage[L]=Y.join(";")}catch(t){}}}function Mt(){var e=Ut(),n=t.map(I,function(t,n){return l(t,e,"sp-palette-row sp-palette-row-"+n,C)});_t(),Y&&n.push(l(function(){var t=[];if(C.showPalette)for(var e=0;e<Y.length;e++){var n=tinycolor(Y[e]).toRgbString();R[n]||t.push(Y[e])}return t.reverse().slice(0,C.maxSelectionSize)}(),e,"sp-palette-row sp-palette-row-selection",C)),ot.html(n.join(""))}function Ft(){if(C.showInitial){var t=vt,e=Ut();at.html(l([t,e],e,"sp-palette-row-initial",C))}}function Et(){(E<=0||F<=0||T<=0)&&Ht(),M=!0,W.addClass(H),q=null,K.trigger("dragstart.spectrum",[Ut()])}function Pt(){M=!1,W.removeClass(H),K.trigger("dragstop.spectrum",[Ut()])}function Tt(){var t=rt.val();if(null!==t&&""!==t||!kt){var e=tinycolor(t);e.isValid()?(Ot(e),Zt(!0)):rt.addClass("sp-validation-error")}else Ot(null),Zt(!0)}function At(){S?Dt():zt()}function zt(){var e=t.Event("beforeShow.spectrum");S?Ht():(K.trigger(e,[Ut()]),!1===w.beforeShow(Ut())||e.isDefaultPrevented()||(!function(){for(var t=0;t<i.length;t++)i[t]&&i[t].hide()}(),S=!0,t(j).bind("keydown.spectrum",Bt),t(j).bind("click.spectrum",Nt),t(window).bind("resize.spectrum",_),ft.addClass("sp-active"),W.removeClass("sp-hidden"),Ht(),Rt(),vt=Ut(),Ft(),w.show(vt),K.trigger("show.spectrum",[vt])))}function Bt(t){27===t.keyCode&&Dt()}function Nt(t){2!=t.button&&(M||(xt?Zt(!0):$t(),Dt()))}function Dt(){S&&!b&&(S=!1,t(j).unbind("keydown.spectrum",Bt),t(j).unbind("click.spectrum",Nt),t(window).unbind("resize.spectrum",_),ft.removeClass("sp-active"),W.addClass("sp-hidden"),w.hide(Ut()),K.trigger("hide.spectrum",[Ut()]))}function $t(){Ot(vt,!0)}function Ot(t,e){var n,i;tinycolor.equals(t,Ut())?Rt():(!t&&kt?Lt=!0:(Lt=!1,i=(n=tinycolor(t)).toHsv(),N=i.h%360/360,D=i.s,$=i.v,O=i.a),Rt(),n&&n.isValid()&&!e&&(bt=Ct||n.getFormat()))}function Ut(t){return t=t||{},kt&&Lt?null:tinycolor.fromRatio({h:N,s:D,v:$,a:Math.round(100*O)/100},{format:t.format||bt})}function It(){Rt(),w.move(Ut()),K.trigger("move.spectrum",[Ut()])}function Rt(){rt.removeClass("sp-validation-error"),Yt();var t=tinycolor.fromRatio({h:N,s:1,v:1});G.css("background-color",t.toHexString());var e=bt;O<1&&(0!==O||"name"!==e)&&("hex"!==e&&"hex3"!==e&&"hex6"!==e&&"name"!==e||(e="rgb"));var n=Ut({format:e}),i="";if(mt.removeClass("sp-clear-display"),mt.css("background-color","transparent"),!n&&kt)mt.addClass("sp-clear-display");else{var a=n.toHexString(),s=n.toRgbString();if(o||1===n.alpha?mt.css("background-color",s):(mt.css("background-color","transparent"),mt.css("filter",n.toFilter())),C.showAlpha){var l=n.toRgb();l.a=0;var c=tinycolor(l).toRgbString(),u="linear-gradient(left, "+c+", "+a+")";r?et.css("filter",tinycolor(c).toFilter({gradientType:1},a)):(et.css("background","-webkit-"+u),et.css("background","-moz-"+u),et.css("background","-ms-"+u),et.css("background","linear-gradient(to right, "+c+", "+a+")"))}i=n.toString(e)}C.showInput&&rt.val(i),C.showPalette&&Mt(),Ft()}function Yt(){var t=D,e=$;if(kt&&Lt)it.hide(),tt.hide(),Q.hide();else{it.show(),tt.show(),Q.show();var n=t*F,i=E-e*E;n=Math.max(-P,Math.min(F-P,n-P)),i=Math.max(-P,Math.min(E-P,i-P)),Q.css({top:i+"px",left:n+"px"});var r=O*A;it.css({left:r-z/2+"px"});var o=N*T;tt.css({top:o-B+"px"})}}function Zt(t){var e=Ut(),n="",i=!tinycolor.equals(e,vt);e&&(n=e.toString(bt),St(e)),ht&&K.val(n),t&&i&&(w.change(e),K.trigger("change",[e]))}function Ht(){var e,n,i,r,o,a,s,l,c,u;F=G.width(),E=G.height(),P=Q.height(),J.width(),T=J.height(),B=tt.height(),A=nt.width(),z=it.width(),b||(W.css("position","absolute"),C.offset?W.offset(C.offset):W.offset((n=gt,i=(e=W).outerWidth(),r=e.outerHeight(),o=n.outerHeight(),a=e[0].ownerDocument,s=a.documentElement,l=s.clientWidth+t(a).scrollLeft(),c=s.clientHeight+t(a).scrollTop(),(u=n.offset()).top+=o,u.left-=Math.min(u.left,u.left+i>l&&l>i?Math.abs(u.left+i-l):0),u.top-=Math.min(u.top,u.top+r>c&&c>r?Math.abs(r+o-0):0),u))),Yt(),C.showPalette&&Mt(),K.trigger("reflow.spectrum")}function qt(){Dt(),V=!0,K.attr("disabled",!0),gt.addClass("sp-disabled")}!function(){if(r&&W.find("*:not(input)").attr("unselectable","on"),wt(),dt&&K.after(ft).hide(),kt||lt.hide(),b)K.after(W).hide();else{var e="parent"===C.appendTo?K.parent():t(C.appendTo);1!==e.length&&(e=t("body")),e.append(W)}function n(e){return e.data&&e.data.ignore?(Ot(t(e.target).closest(".sp-thumb-el").data("color")),It()):(Ot(t(e.target).closest(".sp-thumb-el").data("color")),It(),Zt(!0),C.hideAfterPaletteSelect&&Dt()),!1}_t(),gt.bind("click.spectrum touchstart.spectrum",function(e){V||At(),e.stopPropagation(),t(e.target).is("input")||e.preventDefault()}),(K.is(":disabled")||!0===C.disabled)&&qt(),W.click(h),rt.change(Tt),rt.bind("paste",function(){setTimeout(Tt,1)}),rt.keydown(function(t){13==t.keyCode&&Tt()}),st.text(C.cancelText),st.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),$t(),Dt()}),lt.attr("title",C.clearText),lt.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),Lt=!0,It(),b&&Zt(!0)}),ct.text(C.chooseText),ct.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),r&&rt.is(":focus")&&rt.trigger("change"),rt.hasClass("sp-validation-error")||(Zt(!0),Dt())}),ut.text(C.showPaletteOnly?C.togglePaletteMoreText:C.togglePaletteLessText),ut.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),C.showPaletteOnly=!C.showPaletteOnly,C.showPaletteOnly||b||W.css("left","-="+(X.outerWidth(!0)+5)),wt()}),d(nt,function(t,e,n){O=t/A,Lt=!1,n.shiftKey&&(O=Math.round(10*O)/10),It()},Et,Pt),d(J,function(t,e){N=parseFloat(e/T),Lt=!1,C.showAlpha||(O=1),It()},Et,Pt),d(G,function(t,e,n){if(n.shiftKey){if(!q){var i=D*F,r=E-$*E,o=Math.abs(t-i)>Math.abs(e-r);q=o?"x":"y"}}else q=null;var a=!q||"y"===q;(!q||"x"===q)&&(D=parseFloat(t/F)),a&&($=parseFloat((E-e)/E)),Lt=!1,C.showAlpha||(O=1),It()},Et,Pt),yt?(Ot(yt),Rt(),bt=Ct||tinycolor(yt).format,St(yt)):Rt(),b&&zt();var i=r?"mousedown.spectrum":"click.spectrum touchstart.spectrum";ot.delegate(".sp-thumb-el",i,n),at.delegate(".sp-thumb-el:nth-child(1)",i,{ignore:!0},n)}();var jt={show:zt,hide:Dt,toggle:At,reflow:Ht,option:function(n,i){return n===e?t.extend({},C):i===e?C[n]:(C[n]=i,void wt())},enable:function(){V=!1,K.attr("disabled",!1),gt.removeClass("sp-disabled")},disable:qt,offset:function(t){C.offset=t,Ht()},set:function(t){Ot(t),Zt()},get:Ut,destroy:function(){K.show(),gt.unbind("click.spectrum touchstart.spectrum"),W.remove(),ft.remove(),i[jt.id]=null},container:W};return jt.id=i.push(jt)-1,jt}function u(){}function h(t){t.stopPropagation()}function p(t,e){var n=Array.prototype.slice,i=n.call(arguments,2);return function(){return t.apply(e,i.concat(n.call(arguments)))}}function d(e,n,i,o){n=n||function(){},i=i||function(){},o=o||function(){};var a=document,s=!1,l={},c=0,u=0,h="ontouchstart"in window,p={};function d(t){t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),t.returnValue=!1}function f(t){if(s){if(r&&a.documentMode<9&&!t.button)return g();var i=t.originalEvent&&t.originalEvent.touches&&t.originalEvent.touches[0],o=i&&i.pageX||t.pageX,p=i&&i.pageY||t.pageY,f=Math.max(0,Math.min(o-l.left,u)),m=Math.max(0,Math.min(p-l.top,c));h&&d(t),n.apply(e,[f,m,t])}}function g(){s&&(t(a).unbind(p),t(a.body).removeClass("sp-dragging"),setTimeout(function(){o.apply(e,arguments)},0)),s=!1}p.selectstart=d,p.dragstart=d,p["touchmove mousemove"]=f,p["touchend mouseup"]=g,t(e).bind("touchstart mousedown",function(n){(n.which?3==n.which:2==n.button)||s||!1!==i.apply(e,arguments)&&(s=!0,c=t(e).height(),u=t(e).width(),l=t(e).offset(),t(a).bind(p),t(a.body).addClass("sp-dragging"),f(n),d(n))})}function f(){return t.fn.spectrum.inputTypeColorSupport()}t.fn.spectrum=function(e,n){if("string"==typeof e){var r=this,o=Array.prototype.slice.call(arguments,1);return this.each(function(){var n=i[t(this).data("spectrum.id")];if(n){var a=n[e];if(!a)throw new Error("Spectrum: no such method: '"+e+"'");"get"==e?r=n.get():"container"==e?r=n.container:"option"==e?r=n.option.apply(n,o):"destroy"==e?(n.destroy(),t(this).removeData("spectrum.id")):a.apply(n,o)}}),r}return this.spectrum("destroy").each(function(){var n=c(this,t.extend({},e,t(this).data()));t(this).data("spectrum.id",n.id)})},t.fn.spectrum.load=!0,t.fn.spectrum.loadOpts={},t.fn.spectrum.draggable=d,t.fn.spectrum.defaults=n,t.fn.spectrum.inputTypeColorSupport=function e(){if(void 0===e._cachedResult){var n=t("<input type='color'/>")[0];e._cachedResult="color"===n.type&&""!==n.value}return e._cachedResult},t.spectrum={},t.spectrum.localization={},t.spectrum.palettes={},t.fn.spectrum.processNativeColorInputs=function(){var e=t("input[type=color]");e.length&&!f()&&e.spectrum({preferredFormat:"hex6"})},function(){var t=/^[\s,#]+/,e=/\s+$/,n=0,i=Math,r=i.round,o=i.min,a=i.max,s=i.random,l=function(s,c){if(s=s||"",c=c||{},s instanceof l)return s;if(!(this instanceof l))return new l(s,c);var u=function(n){var r={r:0,g:0,b:0},s=1,l=!1,c=!1;"string"==typeof n&&(n=function(n){n=n.replace(t,"").replace(e,"").toLowerCase();var i,r=!1;if(S[n])n=S[n],r=!0;else if("transparent"==n)return{r:0,g:0,b:0,a:0,format:"name"};if(i=$.rgb.exec(n))return{r:i[1],g:i[2],b:i[3]};if(i=$.rgba.exec(n))return{r:i[1],g:i[2],b:i[3],a:i[4]};if(i=$.hsl.exec(n))return{h:i[1],s:i[2],l:i[3]};if(i=$.hsla.exec(n))return{h:i[1],s:i[2],l:i[3],a:i[4]};if(i=$.hsv.exec(n))return{h:i[1],s:i[2],v:i[3]};if(i=$.hsva.exec(n))return{h:i[1],s:i[2],v:i[3],a:i[4]};if(i=$.hex8.exec(n))return{a:(o=i[1],T(o)/255),r:T(i[2]),g:T(i[3]),b:T(i[4]),format:r?"name":"hex8"};var o;if(i=$.hex6.exec(n))return{r:T(i[1]),g:T(i[2]),b:T(i[3]),format:r?"name":"hex"};if(i=$.hex3.exec(n))return{r:T(i[1]+""+i[1]),g:T(i[2]+""+i[2]),b:T(i[3]+""+i[3]),format:r?"name":"hex"};return!1}(n));"object"==typeof n&&(n.hasOwnProperty("r")&&n.hasOwnProperty("g")&&n.hasOwnProperty("b")?(u=n.r,h=n.g,p=n.b,r={r:255*E(u,255),g:255*E(h,255),b:255*E(p,255)},l=!0,c="%"===String(n.r).substr(-1)?"prgb":"rgb"):n.hasOwnProperty("h")&&n.hasOwnProperty("s")&&n.hasOwnProperty("v")?(n.s=z(n.s),n.v=z(n.v),r=function(t,e,n){t=6*E(t,360),e=E(e,100),n=E(n,100);var r=i.floor(t),o=t-r,a=n*(1-e),s=n*(1-o*e),l=n*(1-(1-o)*e),c=r%6;return{r:255*[n,s,a,a,l,n][c],g:255*[l,n,n,s,a,a][c],b:255*[a,a,l,n,n,s][c]}}(n.h,n.s,n.v),l=!0,c="hsv"):n.hasOwnProperty("h")&&n.hasOwnProperty("s")&&n.hasOwnProperty("l")&&(n.s=z(n.s),n.l=z(n.l),r=function(t,e,n){var i,r,o;function a(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}if(t=E(t,360),e=E(e,100),n=E(n,100),0===e)i=r=o=n;else{var s=n<.5?n*(1+e):n+e-n*e,l=2*n-s;i=a(l,s,t+1/3),r=a(l,s,t),o=a(l,s,t-1/3)}return{r:255*i,g:255*r,b:255*o}}(n.h,n.s,n.l),l=!0,c="hsl"),n.hasOwnProperty("a")&&(s=n.a));var u,h,p;return s=F(s),{ok:l,format:n.format||c,r:o(255,a(r.r,0)),g:o(255,a(r.g,0)),b:o(255,a(r.b,0)),a:s}}(s);this._originalInput=s,this._r=u.r,this._g=u.g,this._b=u.b,this._a=u.a,this._roundA=r(100*this._a)/100,this._format=c.format||u.format,this._gradientType=c.gradientType,this._r<1&&(this._r=r(this._r)),this._g<1&&(this._g=r(this._g)),this._b<1&&(this._b=r(this._b)),this._ok=u.ok,this._tc_id=n++};function c(t,e,n){t=E(t,255),e=E(e,255),n=E(n,255);var i,r,s=a(t,e,n),l=o(t,e,n),c=(s+l)/2;if(s==l)i=r=0;else{var u=s-l;switch(r=c>.5?u/(2-s-l):u/(s+l),s){case t:i=(e-n)/u+(e<n?6:0);break;case e:i=(n-t)/u+2;break;case n:i=(t-e)/u+4}i/=6}return{h:i,s:r,l:c}}function u(t,e,n){t=E(t,255),e=E(e,255),n=E(n,255);var i,r,s=a(t,e,n),l=o(t,e,n),c=s,u=s-l;if(r=0===s?0:u/s,s==l)i=0;else{switch(s){case t:i=(e-n)/u+(e<n?6:0);break;case e:i=(n-t)/u+2;break;case n:i=(t-e)/u+4}i/=6}return{h:i,s:r,v:c}}function h(t,e,n,i){var o=[A(r(t).toString(16)),A(r(e).toString(16)),A(r(n).toString(16))];return i&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0):o.join("")}function p(t,e,n,i){var o;return[A((o=i,Math.round(255*parseFloat(o)).toString(16))),A(r(t).toString(16)),A(r(e).toString(16)),A(r(n).toString(16))].join("")}function d(t,e){e=0===e?0:e||10;var n=l(t).toHsl();return n.s-=e/100,n.s=P(n.s),l(n)}function f(t,e){e=0===e?0:e||10;var n=l(t).toHsl();return n.s+=e/100,n.s=P(n.s),l(n)}function g(t){return l(t).desaturate(100)}function m(t,e){e=0===e?0:e||10;var n=l(t).toHsl();return n.l+=e/100,n.l=P(n.l),l(n)}function y(t,e){e=0===e?0:e||10;var n=l(t).toRgb();return n.r=a(0,o(255,n.r-r(-e/100*255))),n.g=a(0,o(255,n.g-r(-e/100*255))),n.b=a(0,o(255,n.b-r(-e/100*255))),l(n)}function v(t,e){e=0===e?0:e||10;var n=l(t).toHsl();return n.l-=e/100,n.l=P(n.l),l(n)}function C(t,e){var n=l(t).toHsl(),i=(r(n.h)+e)%360;return n.h=i<0?360+i:i,l(n)}function b(t){var e=l(t).toHsl();return e.h=(e.h+180)%360,l(e)}function x(t){var e=l(t).toHsl(),n=e.h;return[l(t),l({h:(n+120)%360,s:e.s,l:e.l}),l({h:(n+240)%360,s:e.s,l:e.l})]}function L(t){var e=l(t).toHsl(),n=e.h;return[l(t),l({h:(n+90)%360,s:e.s,l:e.l}),l({h:(n+180)%360,s:e.s,l:e.l}),l({h:(n+270)%360,s:e.s,l:e.l})]}function k(t){var e=l(t).toHsl(),n=e.h;return[l(t),l({h:(n+72)%360,s:e.s,l:e.l}),l({h:(n+216)%360,s:e.s,l:e.l})]}function w(t,e,n){e=e||6,n=n||30;var i=l(t).toHsl(),r=360/n,o=[l(t)];for(i.h=(i.h-(r*e>>1)+720)%360;--e;)i.h=(i.h+r)%360,o.push(l(i));return o}function _(t,e){e=e||6;for(var n=l(t).toHsv(),i=n.h,r=n.s,o=n.v,a=[],s=1/e;e--;)a.push(l({h:i,s:r,v:o})),o=(o+s)%1;return a}l.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(299*t.r+587*t.g+114*t.b)/1e3},setAlpha:function(t){return this._a=F(t),this._roundA=r(100*this._a)/100,this},toHsv:function(){var t=u(this._r,this._g,this._b);return{h:360*t.h,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=u(this._r,this._g,this._b),e=r(360*t.h),n=r(100*t.s),i=r(100*t.v);return 1==this._a?"hsv("+e+", "+n+"%, "+i+"%)":"hsva("+e+", "+n+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=c(this._r,this._g,this._b);return{h:360*t.h,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=c(this._r,this._g,this._b),e=r(360*t.h),n=r(100*t.s),i=r(100*t.l);return 1==this._a?"hsl("+e+", "+n+"%, "+i+"%)":"hsla("+e+", "+n+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return h(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(){return p(this._r,this._g,this._b,this._a)},toHex8String:function(){return"#"+this.toHex8()},toRgb:function(){return{r:r(this._r),g:r(this._g),b:r(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+r(this._r)+", "+r(this._g)+", "+r(this._b)+")":"rgba("+r(this._r)+", "+r(this._g)+", "+r(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:r(100*E(this._r,255))+"%",g:r(100*E(this._g,255))+"%",b:r(100*E(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+r(100*E(this._r,255))+"%, "+r(100*E(this._g,255))+"%, "+r(100*E(this._b,255))+"%)":"rgba("+r(100*E(this._r,255))+"%, "+r(100*E(this._g,255))+"%, "+r(100*E(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(M[h(this._r,this._g,this._b,!0)]||!1)},toFilter:function(t){var e="#"+p(this._r,this._g,this._b,this._a),n=e,i=this._gradientType?"GradientType = 1, ":"";t&&(n=l(t).toHex8String());return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+e+",endColorstr="+n+")"},toString:function(t){var e=!!t;t=t||this._format;var n=!1,i=this._a<1&&this._a>=0;return e||!i||"hex"!==t&&"hex6"!==t&&"hex3"!==t&&"name"!==t?("rgb"===t&&(n=this.toRgbString()),"prgb"===t&&(n=this.toPercentageRgbString()),"hex"!==t&&"hex6"!==t||(n=this.toHexString()),"hex3"===t&&(n=this.toHexString(!0)),"hex8"===t&&(n=this.toHex8String()),"name"===t&&(n=this.toName()),"hsl"===t&&(n=this.toHslString()),"hsv"===t&&(n=this.toHsvString()),n||this.toHexString()):"name"===t&&0===this._a?this.toName():this.toRgbString()},_applyModification:function(t,e){var n=t.apply(null,[this].concat([].slice.call(e)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(m,arguments)},brighten:function(){return this._applyModification(y,arguments)},darken:function(){return this._applyModification(v,arguments)},desaturate:function(){return this._applyModification(d,arguments)},saturate:function(){return this._applyModification(f,arguments)},greyscale:function(){return this._applyModification(g,arguments)},spin:function(){return this._applyModification(C,arguments)},_applyCombination:function(t,e){return t.apply(null,[this].concat([].slice.call(e)))},analogous:function(){return this._applyCombination(w,arguments)},complement:function(){return this._applyCombination(b,arguments)},monochromatic:function(){return this._applyCombination(_,arguments)},splitcomplement:function(){return this._applyCombination(k,arguments)},triad:function(){return this._applyCombination(x,arguments)},tetrad:function(){return this._applyCombination(L,arguments)}},l.fromRatio=function(t,e){if("object"==typeof t){var n={};for(var i in t)t.hasOwnProperty(i)&&(n[i]="a"===i?t[i]:z(t[i]));t=n}return l(t,e)},l.equals=function(t,e){return!(!t||!e)&&l(t).toRgbString()==l(e).toRgbString()},l.random=function(){return l.fromRatio({r:s(),g:s(),b:s()})},l.mix=function(t,e,n){n=0===n?0:n||50;var i,r=l(t).toRgb(),o=l(e).toRgb(),a=n/100,s=2*a-1,c=o.a-r.a,u=1-(i=((i=s*c==-1?s:(s+c)/(1+s*c))+1)/2),h={r:o.r*i+r.r*u,g:o.g*i+r.g*u,b:o.b*i+r.b*u,a:o.a*a+r.a*(1-a)};return l(h)},l.readability=function(t,e){var n=l(t),i=l(e),r=n.toRgb(),o=i.toRgb(),a=n.getBrightness(),s=i.getBrightness(),c=Math.max(r.r,o.r)-Math.min(r.r,o.r)+Math.max(r.g,o.g)-Math.min(r.g,o.g)+Math.max(r.b,o.b)-Math.min(r.b,o.b);return{brightness:Math.abs(a-s),color:c}},l.isReadable=function(t,e){var n=l.readability(t,e);return n.brightness>125&&n.color>500},l.mostReadable=function(t,e){for(var n=null,i=0,r=!1,o=0;o<e.length;o++){var a=l.readability(t,e[o]),s=a.brightness>125&&a.color>500,c=a.brightness/125*3+a.color/500;(s&&!r||s&&r&&c>i||!s&&!r&&c>i)&&(r=s,i=c,n=l(e[o]))}return n};var S=l.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},M=l.hexNames=function(t){var e={};for(var n in t)t.hasOwnProperty(n)&&(e[t[n]]=n);return e}(S);function F(t){return t=parseFloat(t),(isNaN(t)||t<0||t>1)&&(t=1),t}function E(t,e){(function(t){return"string"==typeof t&&-1!=t.indexOf(".")&&1===parseFloat(t)})(t)&&(t="100%");var n=function(t){return"string"==typeof t&&-1!=t.indexOf("%")}(t);return t=o(e,a(0,parseFloat(t))),n&&(t=parseInt(t*e,10)/100),i.abs(t-e)<1e-6?1:t%e/parseFloat(e)}function P(t){return o(1,a(0,t))}function T(t){return parseInt(t,16)}function A(t){return 1==t.length?"0"+t:""+t}function z(t){return t<=1&&(t=100*t+"%"),t}var B,N,D,$=(N="[\\s|\\(]+("+(B="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+B+")[,|\\s]+("+B+")\\s*\\)?",D="[\\s|\\(]+("+B+")[,|\\s]+("+B+")[,|\\s]+("+B+")[,|\\s]+("+B+")\\s*\\)?",{rgb:new RegExp("rgb"+N),rgba:new RegExp("rgba"+D),hsl:new RegExp("hsl"+N),hsla:new RegExp("hsla"+D),hsv:new RegExp("hsv"+N),hsva:new RegExp("hsva"+D),hex3:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex8:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});window.tinycolor=l}(),t(function(){t.fn.spectrum.load&&t.fn.spectrum.processNativeColorInputs()})});var YCEllipse=function(t){"use strict";var e=0,n=function(t){this.x=0,this.y=0,this.rx=void 0!==t.rx?t.rx:100,this.ry=void 0!==t.ry?t.ry:100,this.translate=[t.x,t.y],this.rotate=0,this.scale=1,this.editor=null,this.figure=null,this.selectionShape=null,this.backSelectionShape=null,this.id="ellipse"+e++,this.handles=[],this.actions=["point_move"],this.line=d3.svg.line(),this.elementType="ellipse",this.prop_color="#000000",this.prop_color2="#000000",this.prop_lineStyle="solid",this.prop_stroke=2,this.prop_opacity=1,this.prop_bgOpacity=.25,void 0!==t.rotate&&(this.rotate=t.rotate),void 0!==t.scale&&(this.scale=t.scale),void 0!==t.translate&&(this.translate=t.translate),void 0!==t.rx&&(this.rx=t.rx),void 0!==t.ry&&(this.ry=t.ry),void 0!==t.color&&(this.prop_color=t.color),void 0!==t.color2&&(this.prop_color2=t.color2),void 0!==t.lineStyle&&(this.prop_lineStyle=t.lineStyle),void 0!==t.stroke&&(this.prop_stroke=t.stroke),void 0!==t.opacity&&(this.prop_opacity=t.opacity),void 0!==t.bgOpacity&&(this.prop_bgOpacity=t.bgOpacity),this.keyFrames={},void 0!==t.keyFrames?this.keyFrames=t.keyFrames:this.storeKeyFrame(0)};return n.prototype.elementProperties=function(){return["color","color2","opacity","bgOpacity","stroke","lineStyle"]},n.prototype.toModel=function(){var t=this.editor.toModelHelper(this);t.type=this.elementType;for(var e=["rx","ry","rotate","scale"],n=0;n<e.length;++n){var i=e[n];t[i]=this[i]}return t.x=this.translate[0],t.y=this.translate[1],t},n.prototype.elementProperty=function(t,e){if(void 0===e)return"color"===t?this.prop_color:"color2"===t?this.prop_color2:"lineStyle"===t?this.prop_lineStyle:"stroke"===t?this.prop_stroke:"opacity"===t?this.prop_opacity:"bgOpacity"===t?this.prop_bgOpacity:null;"color"===t?this.prop_color=e:"color2"===t?this.prop_color2=e:"opacity"===t?this.prop_opacity=parseFloat(e):"bgOpacity"===t?this.prop_bgOpacity=parseFloat(e):"stroke"===t?this.prop_stroke=parseFloat(e):"lineStyle"===t&&(this.prop_lineStyle=e),this.redraw(),this.updateSelectionShape()},n.prototype.create=function(e){var n=this;this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id).attr("transform",this.getTransformation()),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){var e="";void 0===t&&(t=!1);var n=this.translate[0],i=this.translate[1];return e+="translate("+n+","+i+") ",e+="rotate("+this.rotate+") "},n.prototype.redraw=function(t){var e=this,n=this.figure.selectAll("ellipse.ellipse_line").data([[this.x,this.y,this.rx,this.ry]]);n.enter().append("ellipse").attr("class","ellipse_line"),n.attr("stroke",this.prop_color).attr("stroke-width",this.prop_stroke).attr("stroke-opacity",this.prop_opacity).attr("fill",this.prop_color2).attr("fill-opacity",this.prop_bgOpacity),"solid"==this.prop_lineStyle?n.attr("stroke-dasharray",null):"dotted"==this.prop_lineStyle?n.attr("stroke-dasharray",this.prop_stroke+","+this.prop_stroke):"dashed"==this.prop_lineStyle?n.attr("stroke-dasharray",3*this.prop_stroke+","+3*this.prop_stroke):"doubled"==this.prop_lineStyle&&n.attr("stroke-dasharray",null),t?n.transition().attr("cx",function(t){return t[0]}).attr("cy",function(t){return t[1]}).attr("rx",function(t){return t[2]}).attr("ry",function(t){return t[3]}).each("end",function(){e.updateSelectionShape(!1)}):n.attr("cx",function(t){return t[0]}).attr("cy",function(t){return t[1]}).attr("rx",function(t){return t[2]}).attr("ry",function(t){return t[3]}),n.exit().remove()},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);var r=this.getTransformation();this.translate[0]+=t,this.translate[1]+=e,i&&this.storeKeyFrame();var o=this.getTransformation();function a(t,e,n){return d3.interpolateString(r,o)}if(n?this.figure.transition().duration(500).attrTween("transform",a):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();n?this.selectionShape.transition().duration(500).attrTween("transform",a):this.selectionShape.attr("transform",this.getTransformation(!1))}},n.prototype.rotateOf=function(t,e){},n.prototype.scaleOf=function(t,e){},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.translate[0],y:this.translate[1]};this.move(t-this.translate[0],e-this.translate[1])},n.prototype.movePoint=function(t,e,n,i,r,o){void 0===i&&(i=!1),void 0===r&&(r=!1),void 0===o&&(o=!0);for(var a=1/this.editor.zoom,s=1/this.editor.zoom,l=0;l<this.handles.length;++l)if(n===this.handles[l].id){0!=l&&3!=l||(a=-1),3==l&&(s=-1);break}2*(this.rx+a*t)<5*this.editor.zoom&&(t=0),2*(this.ry+s*e)<5*this.editor.zoom&&(e=0),this.rx+=a*t;var c=this.ry;return this.ry+=s*e,r&&(this.ry=this.rx,e=(this.rx-c)/s),o&&this.storeKeyFrame(),0==t&&0==e||(this.redraw(i),this.updateSelectionShape(i)),[t,e]},n.prototype.ellipseDeform=function(t,e,n,i){void 0===n&&(n=!0),this.rx=t,this.ry=e,void 0===i&&(i=!0),i&&this.storeKeyFrame(),this.redraw(n)},n.prototype.handleMove=function(t,e){if("move_point"===t.command){var n=this.movePoint(e.dx,e.dy,t.id,!1,e.mouseEvent.shiftKey);e.dx=n[0],e.dy=n[1]}else if("rotate"===t.command){var i=0;if(void 0===e.rotationAngle){var r=this.figure.node().getBBox(),o=r.x+r.width/2+this.translate[0],a=r.y+r.height/2+this.translate[1],s=e.x,l=e.y,c=e.x-e.dx,u=e.y-e.dy;s/=this.editor.zoom,l/=this.editor.zoom,c/=this.editor.zoom;u/=this.editor.zoom;i=Math.atan2(a-l,s-o)*(180/Math.PI)-Math.atan2(a-u,c-o)*(180/Math.PI),e.rotationAngle=i}else i=e.rotationAngle;this.rotate-=i,this.storeKeyFrame(),this.figure.attr("transform",this.getTransformation()),this.updateSelectionShape()}},n.prototype.select=function(){var e=this,n=this.figure.node().getBBox();if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation());for(var i=this.selectionShape.append("rect").attr("id",this.id+"_sel_rect").attr("x",n.x).attr("y",n.y).attr("width",n.width).attr("height",n.height).attr("stroke-width",1/this.editor.zoom/this.scale).attr("fill","rgba(0,0,0,0)").attr("stroke",e.editor.getSelectionShapeStrokeColor()),r=[[n.x,n.y+n.height],[n.x+n.width,n.y+n.height],[n.x+n.width,n.y],[n.x,n.y]],o=["move_point","move_point","rotate","move_point"],a=0;a<4;++a){var s=new YCHandle({id:this.id+"_sel_handle_"+a,group:this.selectionShape,x:r[a][0],y:r[a][1],parentElement:this,command:o[a],shape:2===a?"circle":"square"});s.create(this.editor),this.handles[a]=s}t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null)},n.prototype.updateSelectionShape=function(t){if(void 0===t&&(t=!1),void 0!==this.selectionShape&&null!==this.selectionShape){this.selectionShape.attr("transform",this.getTransformation(!1)),this.selectionShape.selectAll("rect").attr("stroke-width",1/this.editor.zoom/this.scale);var e=this.figure.node().getBBox();t?this.editor.selectionLayer.select("#"+this.id+"_sel_rect").transition().attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height):this.editor.selectionLayer.select("#"+this.id+"_sel_rect").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);for(var n=[[e.x,e.y+e.height],[e.x+e.width,e.y+e.height],[e.x+e.width,e.y],[e.x,e.y]],i=0;i<n.length;++i)this.handles[i].x=n[i][0],this.handles[i].y=n[i][1],this.handles[i].updateHandle(t)}},n.prototype.setCurrentFrame=function(t){var e=0;for(var n in this.keyFrames)n<=t&&parseInt(n)>e&&(e=n);var i=this.keyFrames[e],r=i.x-this.translate[0],o=i.y-this.translate[1];i.rotate,this.rotate;this.move(r,o,!1,0,!1),this.rotate=i.rotate,this.figure.attr("transform",this.getTransformation()),this.ellipseDeform(i.rx,i.ry,!1,!1),this.updateSelectionShape()},n.prototype.storeKeyFrame=function(t){void 0===t&&(t=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(t)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[t]={x:0,y:0,scale:1}),this.keyFrames[t].x=this.translate[0],this.keyFrames[t].y=this.translate[1],this.keyFrames[t].rx=this.rx,this.keyFrames[t].ry=this.ry,this.keyFrames[t].scale=this.scale,this.keyFrames[t].rotate=this.rotate},n.prototype.animate=function(t,e,n){var i=this.editor.calculateTransformation(e),r=this.editor.calculateTransformation(n),o=this.figure,a=this.figure.selectAll("ellipse.ellipse_line");this.editor.timeline.animatedDataFrames.push(o),this.editor.timeline.animatedDataFrames.push(a),o.attr("transform",i).transition().duration(t).ease("linear").attr("transform",r),a.attr("rx",e.rx).attr("rx",e.rx).attr("ry",e.ry).transition().duration(t).ease("linear").attr("rx",n.rx).attr("ry",n.ry)},n}(jQuery),YCFigure=function(t){"use strict";var e=0,n=function(n){this.x=0,this.y=0,this.width=n.width,this.height=n.height,this.fillImage=void 0===n.fillImage?null:n.fillImage,this.svg=n.svg,this.editor=null,this.figure=null,this.selectionShape=null,this.id="figure"+e++,this.translate=[n.x,n.y],this.rotate=0;var i="figure";void 0===n.elementType?("undefined"!==n.svg&&-1!=n.svg.indexOf("materials")&&(i="materials"),this.elementType=i):this.elementType=n.elementType,this.scale=1,this.originaleScale=1,this.handles=[],this.actions=["rotate","move","resize"],this.mainFigureContainer,this.mainFigureContainerTransformation,this.mainFigureContainerTransformationScale=1,void 0!==n.rotate&&(this.rotate=n.rotate),void 0!==n.scale&&(this.scale=n.scale,this.originaleScale=n.scale),void 0!==n.translate&&(this.translate=n.translate),this.prop_color=null,void 0!==n.color&&(this.prop_color=n.color),this.prop_color2=null,void 0!==n.color2&&(this.prop_color2=n.color2),this.prop_uniform={type:"f",c1:this.prop_color,c2:this.prop_color2,c3:this.prop_color2,c4:this.prop_color2},void 0!==n.uniform&&(this.prop_uniform=t.extend({},this.prop_uniform,n.uniform)),this.prop_opacity=1,void 0!==n.opacity&&(this.prop_opacity=n.opacity),this.prop_flip=0,void 0!==n.flip&&(this.prop_flip=parseFloat(n.flip)),this.prop_skin="#D3AB9B",void 0!==n.skin&&(this.prop_skin=n.skin),this.prop_hair="#000000",void 0!==n.hair&&(this.prop_hair=n.hair),this.keyFrames={},void 0!==n.keyFrames?this.keyFrames=n.keyFrames:this.storeKeyFrame(0)};return n.prototype.toModel=function(){for(var t=this.editor.toModelHelper(this),e=["width","height","svg","elementType"],n=0;n<e.length;++n){var i=e[n];t[i]=this[i]}return t.type="figure",t.scale=this.keyFrames[0].scale/this.mainFigureContainerTransformationScale,t},n.prototype.create=function(e){var n=this;this.editor=e;var i=parseFloat(this.width),r=parseFloat(this.height);if(this.figure=this.editor.elementsLayer.append("g").attr("id",this.id).attr("opacity",this.prop_opacity),null!=this.fillImage){this.figure.append("rect").attr("x",-i/2).attr("y",-r/2).attr("width",i).attr("height",r);this.editor.setBackgroundImage(this.figure,this.fillImage),n.creationCallback()}else{!1===n.editor.options.uselocal&&t.get(n.editor.options.baseUrl+this.svg,function(e,i,o){!function(e){n.mainFigureContainer=n.figure.append("g"),t(n.mainFigureContainer.node()).append(e);var i=n.mainFigureContainer.node().getBBox(),o=r/i.height;n.mainFigureContainerTransformationScale=o,n.scale=n.originaleScale*n.mainFigureContainerTransformationScale,n.keyFrames[0].scale=n.scale,n.mainFigureContainerTransformation="translate(-"+i.width/2+",-"+i.height/2+")",n.mainFigureContainer.attr("transform",(1===n.prop_flip?"scale(-1,1) ":" ")+n.mainFigureContainerTransformation),n.figure.attr("transform",n.getTransformation()),t(".yc-color-1",n.figure.node()).attr("fill",n.prop_color),t(".yc-color-2",n.figure.node()).attr("fill",n.prop_color2),t(".yc-skin",n.figure.node()).attr("fill",n.prop_skin),t(".yc-hair",n.figure.node()).attr("fill",n.prop_hair),n.updateUniform(),n.creationCallback()}(o.responseText)},"xml").fail(function(t,e,n){})}t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)}),this.editor.setLastUsedUniformForFigure(this.elementType,this.prop_uniform)},n.prototype.updateUniform=function(){switch(t(".base_tshirt",this.figure.node()).attr("fill",this.prop_uniform.c1),t(".shorts",this.figure.node()).attr("fill",this.prop_uniform.c2),t(".socks",this.figure.node()).attr("fill",this.prop_uniform.c4),this.prop_uniform.type){case"f":t(".v_stripe",this.figure.node()).attr("fill","none"),t(".h_stripe",this.figure.node()).attr("fill","none");break;case"v":t(".v_stripe",this.figure.node()).attr("fill",this.prop_uniform.c3),t(".h_stripe",this.figure.node()).attr("fill","none");break;case"h":t(".v_stripe",this.figure.node()).attr("fill","none"),t(".h_stripe",this.figure.node()).attr("fill",this.prop_uniform.c3);break;case"q":t(".v_stripe",this.figure.node()).attr("fill",this.prop_uniform.c3),t(".h_stripe",this.figure.node()).attr("fill",this.prop_uniform.c3)}},n.prototype.elementProperties=function(){var t=["uniform","color","opacity","flip","relativeScale","skin","hair"];return"materials"===this.elementType?(t.splice(t.indexOf("uniform"),1),t.splice(t.indexOf("skin"),1),t.splice(t.indexOf("hair"),1)):t.splice(t.indexOf("color"),1),t},n.prototype.elementProperty=function(e,n){if(void 0===n)return"color"==e?this.prop_color:"color2"==e?this.prop_color2:"uniform"==e?t.extend({},this.prop_uniform):"opacity"==e?this.prop_opacity:"skin"==e?this.prop_skin:"hair"==e?this.prop_hair:"flip"==e?this.prop_flip:"relativeScale"==e?this.scale/this.mainFigureContainerTransformationScale:null;if("color"==e&&(this.prop_color=n,t(".yc-color-1",this.figure.node()).attr("fill",this.prop_color)),"uniform"==e&&(this.prop_uniform=t.extend({},this.prop_uniform,n),this.updateUniform()),"flip"==e&&(this.prop_flip=parseFloat(n),this.mainFigureContainer.attr("transform",(1===this.prop_flip?"scale(-1,1) ":" ")+this.mainFigureContainerTransformation)),"relativeScale"==e){var i=parseFloat(n)*this.mainFigureContainerTransformationScale;this.scaleOf(i-this.scale)}"color2"==e?(this.prop_color2=n,t(".yc-color-2",this.figure.node()).attr("fill",this.prop_color2)):"opacity"==e?(this.prop_opacity=n,this.figure.attr("opacity",this.prop_opacity),this.storeKeyFrame()):"skin"==e?(this.prop_skin=n,t(".yc-skin",this.figure.node()).attr("fill",this.prop_skin)):"hair"==e&&(this.prop_hair=n,t(".yc-hair",this.figure.node()).attr("fill",this.prop_hair))},n.prototype.getTransformation=function(t){var e="";void 0===t&&(t=!1);var n=i=0,i=(n=this.translate[0],this.translate[1]);e+="translate("+n+","+i+") ";var r=this.scale;if(1!=r||t){var o=this.width;n=-this.x-o/2*(r-1)-this.translate[0],i=-this.y-o/2*(r-1)-this.translate[1],e+="scale("+r+") "}else e+="scale(1) ";return e+="rotate("+this.rotate+") "},n.prototype.move=function(t,e,n,i,r){void 0===n&&(n=!1,i=0),void 0===i&&(i=500),void 0===r&&(r=!0);var o=this.getTransformation();this.translate[0]+=t,this.translate[1]+=e,r&&this.storeKeyFrame();var a=this.getTransformation();function s(t,e,n){return d3.interpolateString(o,a)}if(n?this.figure.transition().duration(i).attrTween("transform",s):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();n?this.selectionShape.transition().duration(i).attrTween("transform",s):this.selectionShape.attr("transform",this.getTransformation(!1))}},n.prototype.rotateOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.rotate+=t,n&&this.storeKeyFrame();var r=this.getTransformation();function o(t,e,n){return d3.interpolateString(i,r)}if(e?this.figure.transition().duration(500).attrTween("transform",o):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();e?this.selectionShape.transition().duration(500).attrTween("transform",o):this.selectionShape.attr("transform",this.getTransformation())}},n.prototype.scaleOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.scale+=t,n&&this.storeKeyFrame();var r=this,o=this.getTransformation();function a(t,e,n){return d3.interpolateString(i,o)}if(e?this.figure.transition().duration(500).attrTween("transform",a):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();e?(this.selectionShape.attr("transform",this.getTransformation()),this.updateSelectionShape(),this.selectionShape.transition().duration(500).attrTween("transform",a).each("end",function(){r.updateSelectionShape()}).tween("side-effects",function(e,n,i){return function(e){var n=r.scale;r.scale-=t*(1-e),r.updateSelectionShape(),r.scale=n}})):(this.selectionShape.attr("transform",this.getTransformation()),this.updateSelectionShape())}},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.translate[0],y:this.translate[1]};this.move(t-this.translate[0],e-this.translate[1])},n.prototype.handleMove=function(t,e){var n=1/this.editor.zoom;this.editor.zoom;if("resize-se"===t.command||"resize-ne"===t.command||"resize-sw"===t.command||"resize-nw"===t.command){if("resize-sw"!==t.command&&"resize-nw"!==t.command||(n*=-1),(r=this.figure.node().getBBox()).width*this.scale+2*n*e.dx<10&&(e.dx=0),r.height*this.scale+2*n*e.dx<10&&(e.dx=0),0===e.dx)return;this.scale=(r.width*this.scale+2*n*e.dx)/r.width,this.figure.attr("transform",this.getTransformation())}else if("rotate"===t.command){var i=0;if(void 0===e.rotationAngle){var r,o=(r=this.figure.node().getBBox()).x+r.width/2+this.translate[0],a=r.y+r.height/2+this.translate[1],s=e.x,l=e.y,c=e.x-e.dx,u=e.y-e.dy;s/=this.editor.zoom,l/=this.editor.zoom,c/=this.editor.zoom;u/=this.editor.zoom;i=Math.atan2(a-l,s-o)*(180/Math.PI)-Math.atan2(a-u,c-o)*(180/Math.PI),e.rotationAngle=i}else i=e.rotationAngle;this.rotate-=i,this.figure.attr("transform",this.getTransformation())}this.storeKeyFrame(),this.updateSelectionShape()},n.prototype.select=function(){var e=this,n=this.figure.node().getBBox();if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation());for(var i=this.selectionShape.append("rect").attr("id",this.id+"_sel_rect").attr("x",n.x).attr("y",n.y).attr("width",n.width).attr("height",n.height).attr("stroke-width",1/this.editor.zoom/this.scale).attr("fill","rgba(0,0,0,0)").attr("stroke",e.editor.getSelectionShapeStrokeColor()),r=[[n.x,n.y+n.height],[n.x+n.width,n.y+n.height],[n.x+n.width,n.y],[n.x,n.y]],o=["resize-sw","resize-se","rotate","resize-nw"],a=0;a<4;++a){var s=new YCHandle({id:this.id+"_sel_handle_"+a,group:this.selectionShape,x:r[a][0],y:r[a][1],parentElement:this,command:o[a]});s.create(this.editor),this.handles[a]=s}t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null)},n.prototype.updateSelectionShape=function(){this.selectionShape.attr("transform",this.getTransformation(!1)),this.selectionShape.selectAll("rect").attr("stroke-width",1/this.editor.zoom/this.scale);var t=this.figure.node().getBBox();this.editor.selectionLayer.select("#"+this.id+"_sel_rect").attr("x",t.x).attr("y",t.y).attr("width",t.width).attr("height",t.height);for(var e=0;e<4;++e)this.handles[e].updateHandle()},n.prototype.creationCallback=function(){},n.prototype.storeKeyFrame=function(t){void 0===t&&(t=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(t)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[t]={x:0,y:0,scale:1}),this.keyFrames[t].x=this.translate[0],this.keyFrames[t].y=this.translate[1],this.keyFrames[t].scale=this.scale,this.keyFrames[t].rotate=this.rotate,this.keyFrames[t].prop_opacity=this.prop_opacity},n.prototype.setCurrentFrame=function(t){var e=0;for(var n in this.keyFrames)n<=t&&parseInt(n)>e&&(e=n);var i=this.keyFrames[e];this.scale=i.scale,this.rotate=i.rotate,this.translate[0]=i.x,this.translate[1]=i.y,this.prop_opacity=i.prop_opacity,this.figure.attr("opacity",this.prop_opacity).attr("transform",this.getTransformation(!0))},n.prototype.animate=function(t,e,n){var i=this.editor.calculateTransformation(e),r=this.editor.calculateTransformation(n),o=this.figure;this.editor.timeline.animatedDataFrames.push(o),o.attr("transform",i).attr("opacity",e.prop_opacity).transition().ease("linear").duration(t).attr("transform",r).attr("opacity",n.prop_opacity)},n}(jQuery),YCDisc=function(t,e){"use strict";var n=function(t){e.call(this,t),this.number=t.number,this.elementType="discs",this.prop_textlabel=void 0===t.textlabel?"":t.textlabel};return(n.prototype=Object.create(e.prototype,{})).create=function(t){e.prototype.create.apply(this,[t])},n.prototype.creationCallback=function(){t(".disc_text",this.figure.node()).text(this.prop_textlabel),t(".yc-color-1",this.figure.node()).attr("fill",this.prop_color),t(".yc-color-2",this.figure.node()).attr("fill",this.prop_color2)},n.prototype.toModel=function(t){var n=e.prototype.toModel.apply(this,[]);return n.type="disc",n},n.prototype.elementProperties=function(){return["color","color2","opacity","textlabel"]},n.prototype.elementProperty=function(n,i){if(void 0===i)return"textlabel"==n?this.prop_textlabel:e.prototype.elementProperty.apply(this,[n]);"textlabel"==n?(this.prop_textlabel=i,t(".disc_text",this.figure.node()).text(this.prop_textlabel)):e.prototype.elementProperty.apply(this,[n,i])},n.prototype.constructor=n,n}(jQuery,YCFigure),YCHandle=function(t){"use strict";var e=function(t){this.x=t.x,this.y=t.y,this.editor=null,this.group=t.group,this.command=t.command,this.figure=null,this.parentElement=t.parentElement,this.id=t.id,this.translate=[0,0],this.rotate=0,this.scale=1,this.parentFigureCenter=[0,0],this.shape=void 0!==t.shape?t.shape:"",this.undoOperation=[]};return e.prototype.create=function(e){var n=this;this.editor=e;var i=parseFloat(this.x),r=parseFloat(this.y);if("resize-se"===this.command||"resize-ne"===this.command||"resize-sw"===this.command||"resize-nw"===this.command||"move_point"===this.command&&"square"===this.shape){var o=10/this.editor.zoom/this.parentElement.scale;this.figure=this.group.append("rect").attr("id",this.id).attr("x",i-o/2).attr("y",r-o/2).attr("width",o).attr("height",o).attr("fill","#1388d8").attr("stroke-width",2/this.editor.zoom/this.parentElement.scale).attr("stroke","#ffffff").attr("class",this.getCursorClass()+" "+this.command+" editor-handler")}else this.figure=this.group.append("circle").attr("cx",i).attr("cy",r).attr("id",this.id).attr("r",5/this.editor.zoom/this.parentElement.scale).attr("fill","#1388d8").attr("stroke-width",2/this.editor.zoom/this.parentElement.scale).attr("stroke","#ffffff").attr("class",this.getCursorClass()+" "+this.command+" editor-handler");t(this.figure[0]).data("handle-elemet",n),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},e.prototype.getTransformation=function(){var t="";return 0==this.translate[0]&&0==this.translate[1]||(t+="translate("+this.translate[0]+","+this.translate[1]+") "),t},e.prototype.handleMove=function(e){var n=this;e.figureCenter=this.parentFigureCenter,t.each(this.editor.currentSelection,function(t){this.handleMove(n,e)}),this.updateHandle()},e.prototype.updateHandle=function(t){void 0===t&&(t=!1),this.r=5/this.editor.zoom/this.parentElement.scale,"resize-se"===this.command||"resize-ne"===this.command||"resize-sw"===this.command||"resize-nw"===this.command||"move_point"===this.command&&"square"===this.shape?this.figure.attr("width",2*this.r).attr("height",2*this.r).attr("x",this.x-this.r).attr("y",this.y-this.r):(this.r=5/this.editor.zoom/this.parentElement.scale,this.figure.attr("r",this.r),t?this.figure.transition().attr("cx",this.x).attr("cy",this.y):this.figure.attr("cx",this.x).attr("cy",this.y)),this.figure.attr("stroke-width",2/this.editor.zoom/this.parentElement.scale).attr("transform",this.getTransformation())},e.prototype.select=function(){return null},e.prototype.unselect=function(){},e.prototype.getCursorClass=function(){return"cursor-"+this.command},e.prototype.startMove=function(e,n){var i=this;this.undoOperation={command:this.command,elements:[],elementsNew:[]},t.each(this.editor.currentSelection,function(t){var e={id:this.id,rotate:this.rotate,scale:this.scale,fontSize:this.elementProperty("fontSize"),newRotate:this.rotate,newScale:this.scale,newFontSize:this.elementProperty("fontSize"),x:i.x,y:i.y,shift:n.originalEvent.shiftKey};if("ellipse"===this.elementType)e.rx=this.rx,e.ry=this.ry;else if("polygon"===this.elementType){e.points=[];for(t=0;t<this.points.length;++t)e.points.push([this.points[t][0],this.points[t][1]])}i.undoOperation.elements.push(e)});var r=this.parentElement.figure.node().getBBox();this.parentFigureCenter={x:r.x+r.width/2,y:r.y+r.height/2}},e.prototype.endMove=function(e){var n=this;t.each(this.undoOperation.elements,function(t){var e=n.editor.findElement(this.id);if(this.newRotate=e.rotate,this.newScale=e.scale,this.newFontSize=e.elementProperty("fontSize"),this.newX=n.x,this.newY=n.y,this.handlerId=n.id,"ellipse"===e.elementType)this.newRx=e.rx,this.newRy=e.ry;else if("polygon"===e.elementType){this.newPoints=[];for(t=0;t<e.points.length;++t)this.newPoints.push([e.points[t][0],e.points[t][1]])}});var i=n.undoOperation;n.editor.updatePropertiesPanel(),this.editor.appendUndo({undo:function(){t.each(i.elements,function(t){var e=n.editor.findElement(this.id);"rotate"==i.command?e.rotateOf(this.rotate-this.newRotate,!0):"move_point"==i.command?"ellipse"===e.elementType?e.ellipseDeform(this.rx,this.ry):"polygon"===e.elementType?e.polygonDeform(this.points):e.movePoint(this.x-this.newX,this.y-this.newY,n.id,!0,n.shift):"text"===e.elementType?(e.elementProperty("fontSize",this.fontSize,!0),n.editor.updatePropertiesPanel()):e.scaleOf(this.scale-this.newScale,!0)})},redo:function(){t.each(i.elements,function(t){var e=n.editor.findElement(this.id);"rotate"==i.command?e.rotateOf(this.newRotate-this.rotate,!0):"move_point"==i.command?"ellipse"===e.elementType?e.ellipseDeform(this.newRx,this.newRy):"polygon"===e.elementType?e.polygonDeform(this.newPoints):e.movePoint(this.newX-this.x,this.newY-this.y,n.id,!0,n.shift):"text"===e.elementType?(e.elementProperty("fontSize",this.newFontSize,!0),n.editor.updatePropertiesPanel()):e.scaleOf(this.newScale-this.scale,!0)})},name:function(){return"rotate"==i.command?"Rotate":"move_point"==i.command?"Move Point":"Scale"}})},e}(jQuery),YCLine=function(t){"use strict";var e=0,n=function(t){this.points=t.points,this.x=this.points[0][0],this.y=this.points[0][1],this.translate=[0,0],this.rotate=0,this.scale=1,this.editor=null,this.figure=null,this.selectionShape=null,this.backSelectionShape=null,this.id="line"+e++,this.handles=[],this.actions=["point_move"],this.controlLine=d3.svg.line(),this.arrowSize=10,this.elementType="line",this.prop_color="#000",this.prop_lineStyle="solid",this.prop_stroke=4,this.prop_opacity=1,this.prop_arrowStyle="arrow-right",this.prop_waveAmplitude=-1,this.prop_waveFrequency=40,this.prop_linesOffset=30,this.prop_lineType="normal",this.prop_lineInterpolation="basis",void 0!==t.color&&(this.prop_color=t.color),void 0!==t.lineStyle&&(this.prop_lineStyle=t.lineStyle),void 0!==t.stroke&&(this.prop_stroke=t.stroke),void 0!==t.opacity&&(this.prop_opacity=t.opacity),void 0!==t.arrowStyle&&(this.prop_arrowStyle=t.arrowStyle),void 0!==t.lineInterpolation&&(this.prop_lineInterpolation=t.lineInterpolation),void 0!==t.lineType&&(this.prop_lineType=t.lineType),void 0!==t.waveAmplitude&&(this.prop_waveAmplitude=t.waveAmplitude),void 0!==t.waveFrequency&&(this.prop_waveFrequency=t.waveFrequency),void 0!==t.linesOffset&&(this.prop_linesOffset=t.linesOffset),this.line=d3.svg.line().interpolate(this.prop_lineInterpolation),this.keyFrames={},void 0!==t.keyFrames?this.keyFrames=t.keyFrames:this.storeKeyFrame(0)};return n.prototype.toModel=function(){var e=this.editor.toModelHelper(this);return e.points=t.extend(!0,[],this.keyFrames[0].points),e.lineInterpolation=this.elementProperty("lineInterpolation"),e.lineType=this.elementProperty("lineType"),e},n.prototype.elementProperties=function(){var t=["color","opacity","stroke","lineStyle","arrowStyle"];return"waves"==this.prop_lineType?(t.push("waveFrequency"),t.push("waveAmplitude")):"double"==this.prop_lineType&&t.push("linesOffset"),t},n.prototype.elementProperty=function(t,e,n){if(void 0===n&&(n=!1),void 0===e)return"color"===t?this.prop_color:"lineStyle"===t?this.prop_lineStyle:"stroke"===t?this.prop_stroke:"opacity"===t?this.prop_opacity:"arrowStyle"===t?this.prop_arrowStyle:"waveFrequency"===t?this.prop_waveFrequency:"waveAmplitude"===t?this.prop_waveAmplitude:"linesOffset"===t?this.prop_linesOffset:"lineType"===t?this.prop_lineType:"lineInterpolation"===t?this.prop_lineInterpolation:null;if("color"===t)this.prop_color=e;else{if("opacity"===t)return this.prop_opacity=parseFloat(e),void(n?this.figure.transition().attr("opacity",this.prop_opacity):this.figure.attr("opacity",this.prop_opacity));"stroke"===t?this.prop_stroke=parseFloat(e):"lineStyle"===t?this.prop_lineStyle=e:"arrowStyle"===t?this.prop_arrowStyle=e:"waveFrequency"===t?this.prop_waveFrequency=parseFloat(e):"waveAmplitude"===t?this.prop_waveAmplitude=parseFloat(e):"linesOffset"===t?this.prop_linesOffset=parseFloat(e):"lineType"===t?this.prop_lineType=e:"lineInterpolation"===t&&(this.prop_lineInterpolation=e)}this.redraw(),this.updateSelectionShape()},n.prototype.create=function(e){var n=this;this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){return""},n.prototype.setCurrentFrame=function(e){var n=0;for(var i in this.keyFrames)i<=e&&parseInt(i)>n&&(n=i);var r=this.keyFrames[n];this.points=t.extend(!0,[],r.points),this.redraw(!1),this.updateSelectionShape(!1)},n.prototype.redraw=function(e){var n=this,i=this.figure.selectAll("path.arrow_line").data([this.points]);i.enter().append("path").attr("class","arrow_line"),i.attr("fill","none"),"normal"===this.prop_lineType?this.applyLineStyle(i):i.attr("stroke-opacity",0);var r=i.attr("d");i.attr("d",this.line),this.drawLine(i,e,r);var o=[];this.arrowSize=Math.max(10,"double"===this.prop_lineType?this.prop_linesOffset/2:10),"arrow-right"!=this.prop_arrowStyle&&"arrow-left-right"!=this.prop_arrowStyle||o.push(this.trianglePath(this.points[this.points.length-2],this.points[this.points.length-1],this.arrowSize)),"arrow-left"!=this.prop_arrowStyle&&"arrow-left-right"!=this.prop_arrowStyle||o.push(this.trianglePath(this.points[1],this.points[0],this.arrowSize));var a=this.figure.selectAll("path.arrow_triangle").data(o);a.enter().append("path").attr("class","arrow_triangle editor-handler"),a.attr("fill",this.prop_color).attr("stroke","none").call(function(e){t(e).each(function(){t(this).data("handle-elemet",n)})}),e?a.transition().attr("d",this.controlLine):a.attr("d",this.controlLine),a.exit().remove()},n.prototype.applyLineStyle=function(t){t.attr("stroke-width",this.prop_stroke).attr("stroke",this.prop_color).attr("fill","none"),"solid"==this.prop_lineStyle?t.attr("stroke-dasharray",null):"dotted"==this.prop_lineStyle?t.attr("stroke-dasharray",this.prop_stroke+","+this.prop_stroke):"dashed"==this.prop_lineStyle?t.attr("stroke-dasharray",3*this.prop_stroke+","+3*this.prop_stroke):"doubled"==this.prop_lineStyle&&t.attr("stroke-dasharray",null)},n.prototype.drawLine=function(t,e,n){"waves"===this.prop_lineType?this.drawWaves(t,this.prop_waveAmplitude,this.prop_waveFrequency):"double"===this.prop_lineType?this.drawOffset3(t,this.prop_linesOffset,e):e&&(t.attr("d",function(t){return n}),t.transition().attr("d",this.line))},n.prototype.drawWaves=function(t,e,n){e<10&&(e=null);for(var i=t.node(),r=i.getTotalLength(),o=i.getPointAtLength(r),a=parseInt(r/n,10),s=r/a,l=(d3.svg.line(),d3.svg.line().interpolate("basis"),[]),c=0;c<=a;++c){var u=i.getPointAtLength(c*s);l.push(u)}var h=[];for(c=0;c<l.length-1;++c)h.push(this.calcVector90(l[c],l[c+1],e));var p="";p="M"+h[0][0][0]+","+h[0][0][1],p+=" C","arrow-left"==this.prop_arrowStyle||"arrow-left-right"==this.prop_arrowStyle?p+=h[1][0][0]+","+h[1][0][1]:p+=h[0][1][0]+","+h[0][1][1],p+=" "+h[1][1][0]+","+h[1][1][1]+" "+h[1][0][0]+","+h[1][0][1];for(var d=1,f=1;f<h.length;++f){if(0===f?(p+="M"+h[f][0][0]+","+h[f][0][1],p+=" C"+h[f][1][0]+","+h[f][1][1]+" "):p+="S",f<h.length-1)p+=" "+h[f+1][1+d][0]+","+h[f+1][1+d][1]+" "+h[f+1][0][0]+","+h[f+1][0][1];else{var g={x:h[f][0][0],y:h[f][0][1]},m=o;p+=" "+(g.x+m.x)/2+","+(g.y+m.y)/2+" "+m.x+","+m.y}d=0===d?1:0}var y=this.figure.selectAll("path.sin_curve").data([p]);y.enter().append("path").attr("class","sin_curve"),this.applyLineStyle(y),y.attr("d",function(t){return t}),y.exit().remove()},n.prototype.drawOffset=function(t){var e=[],n=[],i=d3.svg.line(),r=d3.svg.line().interpolate("basis"),o=this.calcVector90({x:this.points[0][0],y:this.points[0][1]},{x:this.points[1][0],y:this.points[1][1]},t);e.push(o[2]),n.push(o[1]);var a=this.calcVector90({x:this.points[1][0],y:this.points[1][1]},{x:this.points[0][0],y:this.points[0][1]},t),s=this.calcVector90({x:this.points[1][0],y:this.points[1][1]},{x:this.points[2][0],y:this.points[2][1]},t),l=this.calcVector90({x:this.points[2][0],y:this.points[2][1]},{x:this.points[1][0],y:this.points[1][1]},t),c=this.calcVector90({x:this.points[2][0],y:this.points[2][1]},{x:this.points[3][0],y:this.points[3][1]},t),u=this.calcIntersection(this.mkp(o[2]),this.mkp(a[1]),this.mkp(s[2]),this.mkp(l[1]));e.push(u);var h=this.calcIntersection(this.mkp(o[1]),this.mkp(a[2]),this.mkp(s[1]),this.mkp(l[2]));n.push(h);var p=this.calcVector90({x:this.points[3][0],y:this.points[3][1]},{x:this.points[2][0],y:this.points[2][1]},t),d=this.calcIntersection(this.mkp(l[1]),this.mkp(s[2]),this.mkp(c[2]),this.mkp(p[1]));e.push(d);var f=this.calcIntersection(this.mkp(l[2]),this.mkp(s[1]),this.mkp(c[1]),this.mkp(p[2]));n.push(f),e.push(p[1]),n.push(p[2]);var g=e.concat(n),m=this.figure.selectAll("circle.shifted_control_points").data(g);m.enter().append("circle").attr("class","shifted_control_points"),m.attr("cx",function(t){return t[0]}).attr("cy",function(t){return t[1]}).attr("r",3).attr("fill",function(t,n){return n>=e.length?"#FF00FF":"#FF0000"}),m.exit().remove();var y=this.figure.selectAll("path.shifted_control_lines").data([e,n]);y.enter().append("path").attr("class","shifted_control_lines"),y.attr("d",i).attr("fill","none").attr("stroke",function(t,e){return e>0?"#FF00FF":"#FF0000"}),y.exit().remove();var v=this.figure.selectAll("path.shifted_control_splines").data([e,n]);v.enter().append("path").attr("class","shifted_control_splines"),v.attr("d",r).attr("fill","none").attr("stroke",function(t,e){return e>0?"#FF00FF":"#FF0000"}),v.exit().remove()},n.prototype.drawOffset2=function(t,e){for(var n=t.node(),i=n.getTotalLength(),r=(d3.svg.line(),d3.svg.line().interpolate("basis"),parseInt(i/.5,10)),o=i/r,a=[],s=0;s<=r;++s){var l=n.getPointAtLength(s*o);a.push(l)}var c=[];for(s=0;s<a.length;++s)if(s===a.length-1){var u=this.calcVector90(a[s],a[s-1],15),h=u[1];u[1]=u[2],u[2]=h,c.push(u)}else c.push(this.calcVector90(a[s],a[s+1],15));var p="M "+c[0][1][0]+","+c[0][1][1],d="M "+c[0][2][0]+","+c[0][2][1];for(s=1;s<c.length;++s)p+=" L"+c[s][1][0]+","+c[s][1][1],d+=" L"+c[s][2][0]+","+c[s][2][1];var f=this.figure.selectAll("path.parallel_line_path").data([p,d]);f.enter().append("path").attr("class","parallel_line_path"),f.attr("d",function(t){return t}).attr("fill","none").attr("stroke-width",this.prop_stroke).attr("stroke","#FF5555"),f.exit().remove()},n.prototype.drawOffset3=function(t,e,n){t.node().getTotalLength(),d3.svg.line(),d3.svg.line().interpolate("basis");var i=this.calculateDoubleLinePath(t,e/2,!0),r=this.calculateDoubleLinePath(t,e/2,!1),o=this.figure.selectAll("path.parallel_line_path").data([i,r]);o.enter().append("path").attr("class","parallel_line_path"),this.applyLineStyle(o),o.attr("d",function(t){return t}),o.exit().remove()},n.prototype.calculateDoubleLinePath=function(t,e,n){for(var i=t.node(),r=i.getTotalLength(),o=[],a=2,s=[],l=null,c=null,u="arrow-left"==this.prop_arrowStyle||"arrow-left-right"==this.prop_arrowStyle?2:0,h=u;h<r;h+=a)if(l=c,c=i.getPointAtLength(h),h!==u){var p=this.calcVector90(l,c,e/2);if(o.length>1){var d=p[n?2:1],f=o[o.length-1],g=o[o.length-2];this.vectorAngle(this.mkp(d),this.mkp(f),this.mkp(g))*(180/Math.PI)>179?(o.splice(s.length-1,1),a=2):a=.1}o.push(p[n?2:1])}var m="M "+o[0][0]+","+o[0][1];for(h=1;h<o.length;++h)m+=" L"+o[h][0]+","+o[h][1];return m},n.prototype.pointDistance=function(t,e){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))},n.prototype.vectorAngle=function(t,e,n){var i={x:t.x-e.x,y:t.y-e.y},r={x:n.x-e.x,y:n.y-e.y},o=Math.sqrt(Math.pow(i.x,2)+Math.pow(i.y,2));i.x=i.x/o,i.y=i.y/o;var a=Math.sqrt(Math.pow(r.x,2)+Math.pow(r.y,2));r.x=r.x/a,r.y=r.y/a;var s=i.x*r.x+i.y*r.y;return Math.acos(s)},n.prototype.lineSlope=function(t,e){var n=t.x,i=e.x;return n===i?0:(t.y-e.y)/(n-i)},n.prototype.mkp=function(t){return{x:t[0],y:t[1]}},n.prototype.calcIntersection=function(t,e,n,i){var r=parseFloat(t.x),o=parseFloat(e.x),a=parseFloat(n.x),s=parseFloat(i.x),l=parseFloat(t.y),c=parseFloat(e.y),u=parseFloat(n.y),h=parseFloat(i.y),p=(r*c-l*o)*(a-s)-(r-o)*(a*h-u*s),d=(r-o)*(u-h)-(l-c)*(a-s),f=e.x;0!=d&&(f=p/d);var g=(r*c-l*o)*(u-h)-(l-c)*(a*h-u*s),m=(r-o)*(u-h)-(l-c)*(a-s),y=e.y;return 0!==m&&(y=g/m),[f,y]},n.prototype.calcVector90=function(t,e,n){void 0!==n&&null!==n||(n=Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)));var i=Math.atan2(e.y-t.y,e.x-t.x),r=t.x,o=t.y,a=(180*i/Math.PI+90)/180*Math.PI,s=t.x+.6*Math.cos(a)*n,l=t.y+.6*Math.sin(a)*n,c=(180*i/Math.PI-90)/180*Math.PI;return[[r,o],[s,l],[t.x+.6*Math.cos(c)*n,t.y+.6*Math.sin(c)*n]]},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);for(var r=0;r<this.points.length;++r)this.points[r][0]+=t,this.points[r][1]+=e;i&&this.storeKeyFrame(),this.redraw(n),this.updateSelectionShape()},n.prototype.rotateOf=function(t,e){},n.prototype.scaleOf=function(t,e){},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.points[0][0],y:this.points[0][1]};this.move(t-this.points[0][0],e-this.points[0][1])},n.prototype.movePoint=function(t,e,n,i){void 0===i&&(i=!1);for(var r=1/this.editor.zoom,o=1/this.editor.zoom,a=0;a<this.handles.length;++a)if(n===this.handles[a].id){this.points[a][0]+=t*r,this.points[a][1]+=e*o,this.points.length>2&&(0==a&&(this.points[1][0]+=t*r,this.points[1][1]+=e*o),a==this.points.length-1&&(this.points[this.points.length-2][0]+=t*r,this.points[this.points.length-2][1]+=e*o)),this.redraw(i);break}this.storeKeyFrame(),this.updateSelectionShape(i)},n.prototype.handleMove=function(t,e){this.movePoint(e.dx,e.dy,t.id,!1)},n.prototype.select=function(){var e=this;if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation()),this.backSelectionShape=this.editor.backSelectionLayer.append("g").attr("id",this.id+"_sel_back").attr("transform",this.getTransformation());var n=5/this.editor.zoom/this.scale,i=this.backSelectionShape.append("path").datum(this.points).attr("id",this.id+"_sel_path").attr("stroke-width",this.prop_stroke+4/this.editor.zoom).attr("stroke",e.editor.getSelectionShapeStrokeColor()).attr("stroke-opacity","0.5").attr("fill","none").attr("d",this.line);this.points.length>2&&(this.selectionShape.append("path").attr("id",this.id+"_sel_control_line_1").attr("stroke-width",2/this.editor.zoom/this.scale).attr("stroke","#666").attr("stroke-dasharray",n+","+n).attr("d",this.controlLine([this.points[0],this.points[1]])),this.selectionShape.append("path").attr("id",this.id+"_sel_control_line_2").attr("stroke-width",2/this.editor.zoom/this.scale).attr("stroke","#666").attr("stroke-dasharray",n+","+n).attr("d",this.controlLine([this.points[this.points.length-2],this.points[this.points.length-1]])));for(var r=[],o=0;o<this.points.length;++o)r.push(this.points[o].slice(0));for(o=0;o<this.points.length;++o){var a=new YCHandle({id:this.id+"_sel_handle_"+o,group:this.selectionShape,x:r[o][0],y:r[o][1],parentElement:this,command:"move_point"});a.create(this.editor),this.handles[o]=a}t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null,this.backSelectionShape.remove(),this.backSelectionShape=null)},n.prototype.updateSelectionShape=function(t){if(void 0===t&&(t=!1),null!=this.selectionShape){this.backSelectionShape.selectAll("#"+this.id+"_sel_path").attr("stroke-width",this.prop_stroke+4/this.editor.zoom);var e=5/this.editor.zoom/this.scale;this.selectionShape.selectAll("#"+this.id+"_sel_control_line_1").attr("stroke-width",2/this.editor.zoom/this.scale).attr("stroke-dasharray",e+","+e),this.selectionShape.selectAll("#"+this.id+"_sel_control_line_2").attr("stroke-width",2/this.editor.zoom/this.scale).attr("stroke-dasharray",e+","+e),t?(this.backSelectionShape.selectAll("#"+this.id+"_sel_path").transition().attr("d",this.line(this.points)),this.points.length>2&&(this.selectionShape.selectAll("#"+this.id+"_sel_control_line_1").transition().attr("d",this.controlLine([this.points[0],this.points[1]])),this.selectionShape.selectAll("#"+this.id+"_sel_control_line_2").transition().attr("d",this.controlLine([this.points[this.points.length-2],this.points[this.points.length-1]])))):(this.backSelectionShape.selectAll("#"+this.id+"_sel_path").attr("d",this.line(this.points)),this.points.length>2&&(this.selectionShape.selectAll("#"+this.id+"_sel_control_line_1").attr("d",this.controlLine([this.points[0],this.points[1]])),this.selectionShape.selectAll("#"+this.id+"_sel_control_line_2").attr("d",this.controlLine([this.points[this.points.length-2],this.points[this.points.length-1]]))));this.figure.node().getBBox();for(var n=0;n<this.points.length;++n)this.handles[n].x=this.points[n][0],this.handles[n].y=this.points[n][1],this.handles[n].updateHandle(t)}},n.prototype.trianglePath=function(t,e,n,i){void 0===i&&(i=n),i<n&&(i=n);var r=Math.atan2(e[1]-t[1],e[0]-t[0]),o=e[0]+Math.cos(r)*n,a=e[1]+Math.sin(r)*n,s=(180*r/Math.PI-135)/180*Math.PI,l=e[0]+Math.cos(s)*i,c=e[1]+Math.sin(s)*i,u=(180*r/Math.PI+135)/180*Math.PI;return[[o,a],[l,c],[e[0]+Math.cos(u)*i,e[1]+Math.sin(u)*i]]},n.prototype.storeKeyFrame=function(e){void 0===e&&(e=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(e)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[e]={x:0,y:0,scale:1}),this.keyFrames[e].x=this.translate[0],this.keyFrames[e].y=this.translate[1],this.keyFrames[e].scale=this.scale,this.keyFrames[e].rotate=this.rotate,this.keyFrames[e].points=t.extend(!0,[],this.points)},n.prototype.animate=function(e,n,i){var r=this,o=d3.select(n);this.editor.timeline.animatedDataFrames.push(o);var a=t.extend(!0,[],n.points),s=t.extend(!0,[],i.points);o.transition().duration(e).ease("linear").tween("customTween",function(){var t=d3.interpolate(a,s);return function(e){r.points=t(e),r.redraw()}})},n}(jQuery),YCPath=function(t){"use strict";var e=0,n=function(t){this.x=0,this.y=0,this.d=t.d,this.editor=null,this.figure=null,this.selectionShape=null,this.id="path"+e++,this.path=null,this.elementType="path",this.translate=[t.x,t.y],this.rotate=0,this.scale=1,this.handles=[],this.actions=["rotate","move","resize"],this.prop_color="#000000",this.prop_opacity=1,this.prop_stroke=2,this.prop_lineStyle="solid",void 0!==t.rotate&&(this.rotate=t.rotate),void 0!==t.scale&&(this.scale=t.scale),void 0!==t.stroke&&(this.prop_stroke=t.stroke),void 0!==t.color&&(this.prop_color=t.color),void 0!==t.opacity&&(this.prop_opacity=t.opacity),void 0!==t.lineStyle&&(this.prop_lineStyle=t.lineStyle),this.keyFrames={},void 0!==t.keyFrames?this.keyFrames=t.keyFrames:this.storeKeyFrame(0)};return n.prototype.toModel=function(){var t={};return(t=this.editor.toModelHelper(this)).d=this.d,t},n.prototype.elementProperties=function(){return["color","opacity","stroke","lineStyle"]},n.prototype.elementProperty=function(t,e){if(void 0===e)return"color"==t?this.prop_color:"opacity"==t?this.prop_opacity:"lineStyle"===t?this.prop_lineStyle:"stroke"===t?this.prop_stroke:null;"color"==t?this.prop_color=e:"stroke"===t?this.prop_stroke=parseFloat(e):"lineStyle"===t?this.prop_lineStyle=e:"opacity"==t&&(this.prop_opacity=e,this.storeKeyFrame()),this.redraw()},n.prototype.redraw=function(){var t=this.figure.selectAll("path.free_path").data([this.d]);t.enter().append("path").attr("class","free_path"),t.attr("d",function(t){return t}).attr("stroke-width",parseFloat(this.stroke)).attr("stroke-opacity",this.prop_opacity).attr("fill-opacity",0).attr("stroke-width",this.prop_stroke/this.scale).attr("stroke",this.prop_color),"solid"==this.prop_lineStyle?t.attr("stroke-dasharray",null):"dotted"==this.prop_lineStyle?t.attr("stroke-dasharray",this.prop_stroke+","+this.prop_stroke):"dashed"==this.prop_lineStyle?t.attr("stroke-dasharray",3*this.prop_stroke+","+3*this.prop_stroke):"doubled"==this.prop_lineStyle&&t.attr("stroke-dasharray",null),this.figure.attr("opacity",this.prop_opacity)},n.prototype.create=function(e){var n=this;this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id).attr("opacity",this.prop_opacity).attr("transform",n.getTransformation()),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){var e="";void 0===t&&(t=!1);var n=this.translate[0],i=this.translate[1];return e+="translate("+n+","+i+") ",1!=this.scale||t?e+="scale("+this.scale+") ":e+="scale(1) ",e+="rotate("+this.rotate+") "},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);var r=this.getTransformation();this.translate[0]+=t,this.translate[1]+=e,i&&this.storeKeyFrame();var o=this.getTransformation();function a(t,e,n){return d3.interpolateString(r,o)}if(n?this.figure.transition().duration(500).attrTween("transform",a):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();n?this.selectionShape.transition().duration(500).attrTween("transform",a):this.selectionShape.attr("transform",this.getTransformation(!1))}},n.prototype.rotateOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.rotate+=t,n&&this.storeKeyFrame();var r=this.getTransformation();function o(t,e,n){return d3.interpolateString(i,r)}if(e?this.figure.transition().duration(500).attrTween("transform",o):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();e?this.selectionShape.transition().duration(500).attrTween("transform",o):this.selectionShape.attr("transform",this.getTransformation())}},n.prototype.scaleOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.scale;this.scale+=t,n&&this.storeKeyFrame();var r=this,o=this.getTransformation();function a(t,e,n){return d3.interpolateString(i,o)}if(e?(this.figure.transition().attrTween("transform",a),this.figure.selectAll("path.free_path").transition().attr("stroke-width",this.prop_stroke/this.scale)):(this.figure.attr("transform",this.getTransformation()),this.figure.selectAll("path.free_path").attr("stroke-width",this.prop_stroke/this.scale)),null!==this.selectionShape){this.figure.node().getBBox();e?(this.selectionShape.attr("transform",this.getTransformation()),this.updateSelectionShape(),this.selectionShape.transition().attrTween("transform",a).each("end",function(){r.updateSelectionShape()}).tween("side-effects",function(e,n,i){return function(e){var n=r.scale;r.scale-=t*(1-e),r.updateSelectionShape(),r.scale=n}})):(this.selectionShape.attr("transform",this.getTransformation()),this.updateSelectionShape())}},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.translate[0],y:this.translate[1]};this.move(t-this.translate[0],e-this.translate[1])},n.prototype.handleMove=function(t,e){if("resize-se"===t.command||"resize-ne"===t.command||"resize-sw"===t.command||"resize-nw"===t.command){var n=1/this.editor.zoom;if("resize-sw"!==t.command&&"resize-nw"!==t.command||(n*=-1),(i=this.figure.node().getBBox()).width*this.scale+2*e.dx*n<10&&(e.dx=0),i.height*this.scale+2*e.dx*n<10&&(e.dx=0),0===e.dx)return;this.scale=(i.width*this.scale+2*n*e.dx)/i.width,this.figure.attr("transform",this.getTransformation()),this.figure.selectAll("path.free_path").attr("stroke-width",this.prop_stroke/this.scale)}else if("rotate"===t.command){var i,r=(i=this.figure.node().getBBox()).x+i.width/2+this.translate[0],o=i.y+i.height/2+this.translate[1],a=e.x,s=e.y,l=e.x-e.dx,c=e.y-e.dy;a/=this.editor.zoom,s/=this.editor.zoom,l/=this.editor.zoom;c/=this.editor.zoom;var u=Math.atan2(o-s,a-r)*(180/Math.PI)-Math.atan2(o-c,l-r)*(180/Math.PI);this.rotate-=u,this.figure.attr("transform",this.getTransformation())}this.storeKeyFrame(),this.updateSelectionShape()},n.prototype.select=function(){var e=this,n=this.figure.node().getBBox();if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation());for(var i=this.selectionShape.append("rect").attr("id",this.id+"_sel_rect").attr("x",n.x).attr("y",n.y).attr("width",n.width).attr("height",n.height).attr("stroke-width",1/this.editor.zoom/this.scale).attr("fill","rgba(0,0,0,0)").attr("stroke",e.editor.getSelectionShapeStrokeColor()),r=[[n.x,n.y+n.height],[n.x+n.width,n.y+n.height],[n.x+n.width,n.y],[n.x,n.y]],o=["resize-sw","resize-se","rotate","resize-nw"],a=0;a<4;++a){var s=new YCHandle({id:this.id+"_sel_handle_"+a,group:this.selectionShape,x:r[a][0],y:r[a][1],parentElement:this,command:o[a]});s.create(this.editor),this.handles[a]=s}t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null)},n.prototype.updateSelectionShape=function(t){if(null!==this.selectionShape){void 0===t&&(t=!1),this.selectionShape.attr("transform",this.getTransformation(!1)),this.selectionShape.selectAll("rect").attr("stroke-width",1/this.editor.zoom/this.scale);var e=this.figure.node().getBBox();d3.select(this.id+"_sel_rect").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height);for(var n=0;n<4;++n)this.handles[n].updateHandle()}},n.prototype.setCurrentFrame=function(t){var e=0;for(var n in this.keyFrames)n<=t&&parseInt(n)>e&&(e=n);var i=this.keyFrames[e],r=i.x-this.translate[0],o=i.y-this.translate[1];this.move(r,o,!1,0,!1),this.rotate=i.rotate,this.scale=i.scale,this.figure.attr("transform",this.getTransformation()),this.prop_opacity=i.prop_opacity,this.redraw(),this.updateSelectionShape()},n.prototype.storeKeyFrame=function(t){void 0===t&&(t=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(t)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[t]={x:0,y:0,scale:1}),this.keyFrames[t].x=this.translate[0],this.keyFrames[t].y=this.translate[1],this.keyFrames[t].scale=this.scale,this.keyFrames[t].rotate=this.rotate,this.keyFrames[t].prop_opacity=this.prop_opacity},n.prototype.animate=function(t,e,n){var i=this,r=i.editor.calculateTransformation(e),o=i.editor.calculateTransformation(n),a=d3.select(e),s=this.figure;this.editor.timeline.animatedDataFrames.push(a),this.editor.timeline.animatedDataFrames.push(s),a.transition().duration(t).tween("attr:transform",function(){var t=d3.interpolateString(r,o);return function(e){i.figure.attr("transform",t(e))}}),s.attr("opacity",e.prop_opacity).transition().ease("linear").duration(t).attr("opacity",n.prop_opacity)},n}(jQuery),YCPolygon=function(t){"use strict";var e=0,n=function(t){this.points=t.points,this.x=t.x,this.y=t.y,this.translate=[0,0],this.rotate=0,this.scale=1,this.editor=null,this.figure=null,this.selectionShape=null,this.backSelectionShape=null,this.id="polygon"+e++,this.handles=[],this.actions=["point_move"],this.line=d3.svg.line(),this.elementType="polygon",this.prop_color="#000000",this.prop_color2="#000000",this.prop_lineStyle="solid",this.prop_stroke=2,this.prop_opacity=1,this.prop_bgOpacity=.25,void 0!==t.rotate&&(this.rotate=t.color),void 0!==t.scale&&(this.scale=t.scale),void 0!==t.translate&&(this.translate=t.translate),void 0!==t.color&&(this.prop_color=t.color),void 0!==t.color2&&(this.prop_color2=t.color2),void 0!==t.lineStyle&&(this.prop_lineStyle=t.lineStyle),void 0!==t.stroke&&(this.prop_stroke=t.stroke),void 0!==t.opacity&&(this.prop_opacity=t.opacity),void 0!==t.bgOpacity&&(this.prop_bgOpacity=t.bgOpacity),this.keyFrames={},void 0!==t.keyFrames?this.keyFrames=t.keyFrames:this.storeKeyFrame(0)};return n.prototype.toModel=function(){var e=this.editor.toModelHelper(this);return e.points=t.extend(!0,[],this.keyFrames[0].points),e.x=this.translate[0],e.y=this.translate[1],e},n.prototype.elementProperties=function(){return["color","color2","opacity","bgOpacity","stroke","lineStyle"]},n.prototype.elementProperty=function(t,e){if(void 0===e)return"color"===t?this.prop_color:"color2"===t?this.prop_color2:"lineStyle"===t?this.prop_lineStyle:"stroke"===t?this.prop_stroke:"opacity"===t?this.prop_opacity:"bgOpacity"===t?this.prop_bgOpacity:null;"color"===t?this.prop_color=e:"color2"===t?this.prop_color2=e:"opacity"===t?this.prop_opacity=parseFloat(e):"bgOpacity"===t?this.prop_bgOpacity=parseFloat(e):"stroke"===t?this.prop_stroke=parseFloat(e):"lineStyle"===t&&(this.prop_lineStyle=e),this.redraw(),this.updateSelectionShape()},n.prototype.create=function(e){var n=this;this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){return""},n.prototype.polygonDeform=function(t,e,n){void 0===e&&(e=!0),void 0===n&&(n=!0),this.points=t.slice(0),n&&this.storeKeyFrame(),this.redraw(e),this.updateSelectionShape(e)},n.prototype.redraw=function(t){var e=this,n=this.figure.selectAll("path.polygon_line").data([this.points]);n.enter().append("path").attr("class","polygon_line"),n.attr("stroke",this.prop_color).attr("stroke-width",this.prop_stroke).attr("stroke-opacity",this.prop_opacity).attr("fill",this.prop_color2).attr("fill-opacity",this.prop_bgOpacity),"solid"==this.prop_lineStyle?n.attr("stroke-dasharray",null):"dotted"==this.prop_lineStyle?n.attr("stroke-dasharray",this.prop_stroke+","+this.prop_stroke):"dashed"==this.prop_lineStyle?n.attr("stroke-dasharray",3*this.prop_stroke+","+3*this.prop_stroke):"doubled"==this.prop_lineStyle&&n.attr("stroke-dasharray",null),t?n.transition().attr("d",function(t){return e.line(t)+"Z"}):n.attr("d",function(t){return e.line(t)+"Z"}),n.exit().remove()},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);for(var r=0;r<this.points.length;++r)this.points[r][0]+=t,this.points[r][1]+=e;i&&this.storeKeyFrame(),this.redraw(n),this.updateSelectionShape(n)},n.prototype.rotateOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.rotate+=t,n&&this.storeKeyFrame();var r=this.getTransformation();function o(t,e,n){return d3.interpolateString(i,r)}if(e?this.figure.transition().duration(500).attrTween("transform",o):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();e?this.selectionShape.transition().duration(500).attrTween("transform",o):this.selectionShape.attr("transform",this.getTransformation())}},n.prototype.scaleOf=function(t,e,n){},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.points[0][0],y:this.points[0][1]};this.move(t-this.points[0][0],e-this.points[0][1])},n.prototype.movePoint=function(t,e,n,i,r,o){void 0===i&&(i=!1),void 0===r&&(r=!1),void 0===o&&(o=null);for(var a=[],s=1/this.editor.zoom,l=1/this.editor.zoom,c=0;c<this.handles.length;++c)if(n===this.handles[c].id){for(var u=0;u<this.points.length;++u)if(u!=c){var h=[this.points[u][0],this.points[u][1]];a.push(h)}if(o.mouseEvent.altKey){this.points[c][0]+=t*s,this.points[c][1]+=e*l;o.figureCenter;var p=[o.figureCenter.x,o.figureCenter.y],d=this.points[c],f=Math.atan2(d[1]-p[1],d[0]-p[0])*(180/Math.PI),g=Math.sqrt(Math.pow(d[0]-p[0],2)+Math.pow(d[1]-p[1],2)),m=this.points.length,y=90;if(4===m&&(y=-45),r){var v=Math.abs(f)%y;if(v>y-5||v<5){f=Math.round(f/y)*y;var C=[[[o.figureCenter.x,o.figureCenter.y+g],[o.figureCenter.x,o.figureCenter.y-g]],[[o.figureCenter.x-g,o.figureCenter.y],[o.figureCenter.x+g,o.figureCenter.y]]],b=this.editor.feedbackLayer.selectAll("path.SpecialEffectAlignment").data(C);b.enter().append("path").attr("class","SpecialEffectAlignment"),b.attr("stroke-width",1*s).attr("stroke-dasharray","5, 5, 1, 5").attr("stroke","#FF0000").attr("opacity",1).attr("d",this.line),b.transition().attr("opacity",0)}}var x=f;for(u=0;u<m;++u){x=f+u*(360/m),(h=[0,0])[0]=o.figureCenter.x+g*Math.cos(x*(Math.PI/180)),h[1]=o.figureCenter.y+g*Math.sin(x*(Math.PI/180)),this.points[(c+u)%m]=h}}else if(r){for(u=0;u<a.length;++u){var L=a[u];Math.abs(this.points[c][0]+t*s-L[0])<10&&(t=(L[0]-this.points[c][0])/s),Math.abs(this.points[c][1]+e*l-L[1])<10&&(e=(L[1]-this.points[c][1])/l)}this.points[c][0]+=t*s,this.points[c][1]+=e*l}else this.points[c][0]+=t*s,this.points[c][1]+=e*l;this.storeKeyFrame(),this.redraw(i);break}return this.updateSelectionShape(i),[t,e]},n.prototype.handleMove=function(t,e){var n=this.movePoint(e.dx,e.dy,t.id,!1,e.mouseEvent.shiftKey,e);e.dx=n[0],e.dy=n[1]},n.prototype.select=function(){var e=this;if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation()),this.backSelectionShape=this.editor.backSelectionLayer.append("g").attr("id",this.id+"_sel_back").attr("transform",this.getTransformation());this.editor.zoom,this.scale;for(var n=this.backSelectionShape.append("path").datum(this.points).attr("id",this.id+"_sel_path").attr("stroke-width",this.prop_stroke+4/this.editor.zoom).attr("stroke",e.editor.getSelectionShapeStrokeColor()).attr("fill","none").attr("d",function(t){return e.line(t)+"Z"}),i=[],r=[],o=0;o<this.points.length;++o)i.push(this.points[o].slice(0)),r.push("move_point");for(o=0;o<this.points.length;++o){var a=new YCHandle({id:this.id+"_sel_handle_"+o,group:this.selectionShape,x:i[o][0],y:i[o][1],parentElement:this,command:r[o]});a.create(this.editor),this.handles[o]=a}t(n[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null,this.backSelectionShape.remove(),this.backSelectionShape=null)},n.prototype.updateSelectionShape=function(t){if(void 0===t&&(t=!1),void 0!==this.selectionShape&&null!==this.selectionShape){this.backSelectionShape.selectAll("#"+this.id+"_sel_path").attr("stroke-width",this.prop_stroke+4/this.editor.zoom),t?this.backSelectionShape.selectAll("#"+this.id+"_sel_path").transition().attr("d",this.line(this.points)+"Z"):this.backSelectionShape.selectAll("#"+this.id+"_sel_path").attr("d",this.line(this.points)+"Z");for(var e=0;e<this.points.length;++e)this.handles[e].x=this.points[e][0],this.handles[e].y=this.points[e][1],this.handles[e].updateHandle(t)}},n.prototype.setCurrentFrame=function(e){var n=0;for(var i in this.keyFrames)i<=e&&parseInt(i)>n&&(n=i);var r=this.keyFrames[n],o=r.x-this.translate[0],a=r.y-this.translate[1],s=r.scale-this.scale,l=r.rotate-this.rotate;this.move(o,a,!1,0,!1),this.scaleOf(s,!1,!1),this.rotateOf(l,!1,!1),this.polygonDeform(t.extend(!0,[],r.points),!1,!1)},n.prototype.storeKeyFrame=function(e){void 0===e&&(e=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(e)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[e]={x:0,y:0,scale:1}),this.keyFrames[e].x=this.translate[0],this.keyFrames[e].y=this.translate[1],this.keyFrames[e].scale=this.scale,this.keyFrames[e].rotate=this.rotate,this.keyFrames[e].points=t.extend(!0,[],this.points)},n.prototype.animate=function(t,e,n){var i=this.figure.selectAll("path.polygon_line");this.editor.timeline.animatedDataFrames.push(i),i.attr("d",this.line(e.points)+"Z").transition().duration(t).ease("linear").attr("d",this.line(n.points)+"Z")},n}(jQuery),YCTeamPlayer=function(t){"use strict";var e=0,n=function(n){this.x=0,this.y=0,this.translate=[n.x,n.y],this.rotate=0,this.scale=1,this.editor=null,this.figure=null,this.selectionShape=null,this.backSelectionShape=null,this.id="teamPlayer"+e++,this.handles=[],this.actions=["point_move"],this.line=d3.svg.line(),this.elementType="team_player",this.prop_color="#000000",this.prop_color2="#FFFFFF",this.prop_opacity=1,this.playerName=n.playerName,this.playerDisplayName=t("<span/>").html(n.playerDisplayName).text(),this.playerImage=n.playerImage,this.playerUniform=n.playerUniform,this.playerNumber=n.playerNumber,this.patternId=null,this.svgContent=void 0!==n.svgContent&&""!=n.svgContent?n.svgContent:null,void 0!==n.rotate&&(this.rotate=n.rotate),void 0!==n.scale&&(this.scale=n.scale),void 0!==n.translate&&(this.translate=n.translate),void 0!==n.color&&(this.prop_color=n.color),void 0!==n.color2&&(this.prop_color2=n.color2),void 0!==n.opacity&&(this.prop_opacity=n.opacity),this.keyFrames={},void 0!==n.keyFrames?this.keyFrames=n.keyFrames:this.storeKeyFrame(0)};return n.prototype.elementProperties=function(){return["color","color2","opacity"]},n.prototype.toModel=function(){var t=this.editor.toModelHelper(this);t.type=this.elementType;for(var e=["scale"],n=0;n<e.length;++n){var i=e[n];t[i]=this[i]}return t.x=this.translate[0],t.y=this.translate[1],t.playerName=this.playerName,t.playerDisplayName=this.playerDisplayName,t.playerImage=this.playerImage,t.playerUniform=this.playerUniform,t.playerNumber=this.playerNumber,t.svgContent=this.svgContent,t},n.prototype.elementProperty=function(t,e){if(void 0===e)return"color"===t?this.prop_color:"color2"===t?this.prop_color2:"opacity"===t?this.prop_opacity:null;"color"===t?this.prop_color=e:"color2"===t?this.prop_color2=e:"opacity"===t&&(this.prop_opacity=parseFloat(e)),this.redraw(),this.updateSelectionShape()},n.prototype.create=function(e){var n=this;this.patternId=null,this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id).attr("transform",this.getTransformation()),null!==this.playerUniform||null!==this.playerImage&&(this.patternId=e.addPatternImage(this.playerImage)),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){var e="";void 0===t&&(t=!1);var n=this.translate[0],i=this.translate[1];return e+="translate("+n+","+i+") "},n.prototype.redraw=function(){var e=this,n=this.figure.selectAll("g.team_player").data([[this.x,this.y]]);if(0==n.size()){var i=n.enter().append("g");if(i.attr("class","team_player"),null!=this.playerUniform||null!=this.svgContent){e.mainFigureContainer=i.append("g").attr("transform","translate(-15, -20) scale(0.234)");var r=function(n){e.svgContent=n,t(e.mainFigureContainer.node()).append(e.svgContent)};null===this.svgContent?t.get(this.playerUniform,function(t,n,i){r(i.responseText),e.editor.fireModelChange()},"xml").fail(function(t,e,n){this.svgContent=""}):""!=this.svgContent&&r(this.svgContent)}else{if(i.append("circle").attr("cx",0).attr("cy",0).attr("r",20).attr("stroke",this.prop_color).attr("strole-width",2).attr("fill",null===e.patternId?this.prop_color2:"url(#"+e.patternId+")"),void 0===this.shortName){this.shortName="";for(var o=t("<span/>").html(this.playerName).text().toUpperCase().split(" "),a=0;a<o.length&&a<3;++a)this.shortName+=o[a].substring(0,1)}i.append("text").attr("x",0).attr("y",8).attr("text-anchor","middle").attr("stroke","none").attr("fill","#999").attr("font-family","sans-serif").attr("font-size","20px").attr("font-weight","normal").text(this.shortName)}var s=i.append("text").attr("x",0).attr("y",34).attr("class","team_player_name").attr("text-anchor","middle").attr("stroke","none").attr("fill","#fff").attr("font-family","sans-serif").attr("font-size","13px").attr("font-weight","normal").text(this.playerDisplayName);i.insert("rect","text").attr("x",function(){return-s.node().getComputedTextLength()/2-5}).attr("y",22).attr("width",s.node().getComputedTextLength()+10).attr("height",16).attr("fill","rgba(16, 20, 30, 0.5)").attr("rx","3").attr("ry","3")}n.select("circle").attr("stroke",this.prop_color),null===this.patternId&&n.select("circle").attr("fill",this.prop_color2),n.exit().remove()},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);var r=this.getTransformation();this.translate[0]+=t,this.translate[1]+=e,i&&this.storeKeyFrame();var o=this.getTransformation();function a(t,e,n){return d3.interpolateString(r,o)}if(n?this.figure.transition().duration(500).attrTween("transform",a):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();n?this.selectionShape.transition().duration(500).attrTween("transform",a):this.selectionShape.attr("transform",this.getTransformation(!1))}},n.prototype.rotateOf=function(t,e){},n.prototype.scaleOf=function(t,e){},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.translate[0],y:this.translate[1]};this.move(t-this.translate[0],e-this.translate[1])},n.prototype.movePoint=function(t,e,n,i,r,o){return[t,e]},n.prototype.handleMove=function(t,e){},n.prototype.select=function(){var e=this,n=this.figure.node().getBBox();if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation());var i=this.selectionShape.append("rect").attr("id",this.id+"_sel_rect").attr("x",n.x).attr("y",n.y).attr("width",n.width).attr("height",n.height).attr("stroke-width",1/this.editor.zoom/this.scale).attr("fill","rgba(0,0,0,0)").attr("stroke",e.editor.getSelectionShapeStrokeColor());t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null)},n.prototype.updateSelectionShape=function(t){if(void 0===t&&(t=!1),void 0!==this.selectionShape&&null!==this.selectionShape){this.selectionShape.attr("transform",this.getTransformation(!1)),this.selectionShape.selectAll("rect").attr("stroke-width",1/this.editor.zoom/this.scale);var e=this.figure.node().getBBox();t?this.editor.selectionLayer.select("#"+this.id+"_sel_rect").transition().attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height):this.editor.selectionLayer.select("#"+this.id+"_sel_rect").attr("x",e.x).attr("y",e.y).attr("width",e.width).attr("height",e.height)}},n.prototype.setCurrentFrame=function(t){var e=0;for(var n in this.keyFrames)n<=t&&parseInt(n)>e&&(e=n);var i=this.keyFrames[e],r=i.x-this.translate[0],o=i.y-this.translate[1];i.rotate,this.rotate;this.move(r,o,!1,0,!1),this.rotate=i.rotate,this.figure.attr("transform",this.getTransformation()),this.updateSelectionShape()},n.prototype.storeKeyFrame=function(t){void 0===t&&(t=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(t)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[t]={x:0,y:0,scale:1}),this.keyFrames[t].x=this.translate[0],this.keyFrames[t].y=this.translate[1],this.keyFrames[t].scale=this.scale,this.keyFrames[t].rotate=this.rotate},n.prototype.animate=function(t,e,n){var i=this.editor.calculateTransformation(e),r=this.editor.calculateTransformation(n),o=this.figure,a=this.figure.selectAll("ellipse.ellipse_line");this.editor.timeline.animatedDataFrames.push(o),this.editor.timeline.animatedDataFrames.push(a),o.attr("transform",i).transition().duration(t).ease("linear").attr("transform",r)},n}(jQuery),YCText=function(t){"use strict";var e=0,n=function(t){this.x=0,this.y=0,this.d=t.d,this.editor=null,this.figure=null,this.selectionShape=null,this.id="text"+e++,this.elementType="text",this.translate=[t.x,t.y],this.rotate=0,this.scale=1,this.handles=[],this.actions=["rotate","move","resize"],this.line_spacing=1.1,this.prop_color="#000000",this.prop_color2="#000000",this.prop_opacity=1,this.prop_bgOpacity=.25,this.prop_text="Text",this.prop_fontSize="24",void 0!==t.rotate&&(this.rotate=t.rotate),void 0!==t.scale&&(this.scale=t.scale),void 0!==t.color&&(this.prop_color=t.color),void 0!==t.color2&&(this.prop_color2=t.color2),void 0!==t.opacity&&(this.prop_opacity=t.opacity),void 0!==t.bgOpacity&&(this.prop_bgOpacity=t.bgOpacity),void 0!==t.text&&(this.prop_text=t.text),void 0!==t.fontSize&&(this.prop_fontSize=t.fontSize),this.keyFrames={},void 0!==t.keyFrames?this.keyFrames=t.keyFrames:this.storeKeyFrame(0)};return n.prototype.toModel=function(){return this.editor.toModelHelper(this)},n.prototype.elementProperties=function(){return["color","color2","opacity","bgOpacity","text","fontSize"]},n.prototype.elementProperty=function(e,n,i){if(void 0===i&&(i=!1),void 0===n)return"color"==e?this.prop_color:"color2"==e?this.prop_color2:"opacity"==e?this.prop_opacity:"bgOpacity"==e?this.prop_bgOpacity:"text"==e?this.prop_text:"fontSize"==e?this.prop_fontSize:null;"color"==e&&(this.prop_color=n),"color2"==e&&(this.prop_color2=n),"opacity"==e&&(this.prop_opacity=n),"bgOpacity"==e&&(this.prop_bgOpacity=n),"text"==e&&(this.prop_text=n),"fontSize"==e&&(this.prop_fontSize=n),t.inArray(e),this.storeKeyFrame(),this.redraw(i)},n.prototype.redraw=function(t){void 0===t&&(t=!1);var e=this,n=this.figure.selectAll("rect").data([this.prop_text]);n.enter().append("rect");var i=this.figure.selectAll("text").data([this.prop_text]);i.enter().append("text"),this.figure.attr("opacity",this.prop_opacity),i.attr("fill",this.prop_color).attr("class","yc-text-label").attr("font-family","'Helvetica Neue', Helvetica, Arial, sans-serif");var r=parseFloat(i.attr("font-size"));i.attr("font-size",this.prop_fontSize).attr("text-anchor","middle").attr("alignment-baseline","middle").attr("dominant-baseline","central");var o=this.prop_text.split("\n");0==o.length&&o.push("");var a=parseFloat(e.prop_fontSize)+parseFloat(e.prop_fontSize)*e.line_spacing*(o.length-1),s=parseFloat(e.prop_fontSize)/2-a/2,l=function(t,n){return 0===n?s:e.prop_fontSize*e.line_spacing},c=r+r*e.line_spacing*(o.length-1),u=r/2-c/2,h=function(t,n){return 0==n?u:r*e.line_spacing},p=i.selectAll("tspan").data(o);p.enter().append("tspan"),p.text(function(t){return t}).attr("x",0).attr("dy",l),p.exit().remove(),n.attr("fill",e.prop_color2).attr("opacity",e.prop_bgOpacity).attr("rx",5).attr("ry",5);var d=i.node().getBBox();i.exit(),t?(p.attr("dy",h),i.attr("font-size",r),p.transition().attrTween("dy",function(t,e){return d3.interpolate(h(0,e),l(0,e))}),i.transition().attrTween("font-size",function(t,n){return d3.interpolate(r,parseFloat(e.prop_fontSize))}),n.transition().attrTween("x",function(t,e){return d3.interpolate(n.attr("x"),d.x-4)}).attrTween("y",function(t,e){return d3.interpolate(n.attr("y"),d.y)}).attrTween("width",function(t,e){return d3.interpolate(n.attr("width"),d.width+8)}).attrTween("height",function(t,e){return d3.interpolate(n.attr("height"),d.height)}).each("end",function(){e.updateSelectionShape()})):(n.attr("x",d.x-4).attr("y",d.y).attr("width",d.width+8).attr("height",d.height),e.updateSelectionShape())},n.prototype.create=function(e){var n=this;this.editor=e,this.figure=this.editor.elementsLayer.append("g").attr("id",this.id).attr("transform",this.getTransformation()),this.redraw(),t(this.figure[0]).on("mousedown touchstart",function(t){n.editor.mouseDown(t,n)})},n.prototype.getTransformation=function(t){var e="";void 0===t&&(t=!1);var n=this.translate[0],i=this.translate[1];this.x,this.translate[0],this.y,this.translate[1];return e+="translate("+n+","+i+") ",e+="rotate("+this.rotate+") ",1!=this.scale||t?e+="scale("+this.scale+") ":e+="scale(1) ",e},n.prototype.move=function(t,e,n,i){void 0===n&&(n=!1),void 0===i&&(i=!0);var r=this.getTransformation();this.translate[0]+=t,this.translate[1]+=e,i&&this.storeKeyFrame();var o=this.getTransformation();function a(t,e,n){return d3.interpolateString(r,o)}if(n?this.figure.transition().duration(500).attrTween("transform",a):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();n?this.selectionShape.transition().duration(500).attrTween("transform",a):this.selectionShape.attr("transform",this.getTransformation(!1))}},n.prototype.rotateOf=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0);var i=this.getTransformation();this.rotate+=t,n&&this.storeKeyFrame();var r=this.getTransformation();function o(t,e,n){return d3.interpolateString(i,r)}if(e?this.figure.transition().duration(500).attrTween("transform",o):this.figure.attr("transform",this.getTransformation()),null!==this.selectionShape){this.figure.node().getBBox();e?this.selectionShape.transition().duration(500).attrTween("transform",o):this.selectionShape.attr("transform",this.getTransformation())}},n.prototype.scaleOf=function(t,e){},n.prototype.position=function(t,e){if(void 0===t&&void 0===e)return{x:this.translate[0],y:this.translate[1]};this.move(t-this.translate[0],e-this.translate[1])},n.prototype.handleMove=function(t,e){var n=1/this.editor.zoom;this.editor.zoom;if("resize-se"===t.command||"resize-ne"===t.command||"resize-sw"===t.command||"resize-nw"===t.command){"resize-sw"!==t.command&&"resize-nw"!==t.command||(n*=-1);var i=((r=this.figure.node().getBBox()).width/2*this.scale+e.dx*n)/(r.width/2);if(this.prop_fontSize*i>200&&(e.dx=0),this.prop_fontSize*i<5&&(e.dx=0),0===e.dx)return;this.prop_fontSize=this.prop_fontSize*i,this.redraw(!1)}else if("rotate"===t.command){var r,o=(r=this.figure.select("text").node().getBBox()).x+r.width/2+this.translate[0],a=r.y+r.height/2+this.translate[1],s=e.x,l=e.y,c=e.x-e.dx*this.editor.zoom,u=e.y-e.dy*this.editor.zoom;s/=this.editor.zoom,l/=this.editor.zoom,c/=this.editor.zoom;u/=this.editor.zoom;var h=Math.atan2(a-l,s-o)*(180/Math.PI)-Math.atan2(a-u,c-o)*(180/Math.PI);this.rotate-=h,this.figure.attr("transform",this.getTransformation())}this.storeKeyFrame(),this.updateSelectionShape()},n.prototype.select=function(){var e=this,n=this.figure.node().getBBox();if(null===this.selectionShape){this.selectionShape=this.editor.selectionLayer.append("g").attr("id",this.id+"_sel").attr("transform",this.getTransformation());for(var i=this.selectionShape.append("rect").attr("id",this.id+"_sel_rect").attr("x",n.x).attr("y",n.y).attr("width",n.width).attr("height",n.height).attr("stroke-width",1/this.editor.zoom/this.scale).attr("fill","rgba(0,0,0,0)").attr("stroke",e.editor.getSelectionShapeStrokeColor()),r=[[n.x,n.y+n.height],[n.x+n.width,n.y+n.height],[n.x+n.width,n.y],[n.x,n.y]],o=["resize-sw","resize-se","rotate","resize-nw"],a=0;a<4;++a){var s=new YCHandle({id:this.id+"_sel_handle_"+a,group:this.selectionShape,x:r[a][0],y:r[a][1],parentElement:this,command:o[a]});s.create(this.editor),this.handles[a]=s}t(i[0]).on("mousedown touchstart",function(t){e.editor.mouseDown(t,e)})}return this.selectionShape},n.prototype.unselect=function(){null!==this.selectionShape&&(this.selectionShape.remove(),this.selectionShape=null)},n.prototype.updateSelectionShape=function(){if(null!=this.selectionShape){this.selectionShape.attr("transform",this.getTransformation(!1)),this.selectionShape.selectAll("rect").attr("stroke-width",1/this.editor.zoom/this.scale);var t=this.figure.node().getBBox();this.selectionShape.selectAll("#"+this.id+"_sel_rect").attr("x",t.x).attr("y",t.y).attr("width",t.width).attr("height",t.height);for(var e=[[t.x,t.y+t.height],[t.x+t.width,t.y+t.height],[t.x+t.width,t.y],[t.x,t.y]],n=0;n<4;++n)this.handles[n].x=e[n][0],this.handles[n].y=e[n][1],this.handles[n].updateHandle()}},n.prototype.setCurrentFrame=function(t){var e=0;for(var n in this.keyFrames)n<=t&&parseInt(n)>e&&(e=n);var i=this.keyFrames[e],r=i.x-this.translate[0],o=i.y-this.translate[1];i.rotate,this.rotate;this.move(r,o,!1,0,!1),this.rotate=i.rotate,this.figure.attr("transform",this.getTransformation()),this.prop_fontSize=i.prop_fontSize,this.prop_bgOpacity=i.prop_bgOpacity,this.prop_opacity=i.prop_opacity,this.redraw(!1),this.updateSelectionShape()},n.prototype.storeKeyFrame=function(t){void 0===t&&(t=this.editor.timeline.currentKeyFrameTime),this.keyFrames.hasOwnProperty(t)||(void 0!==this.editor&&null!=this.editor&&this.editor.addKeyframe(),this.keyFrames[t]={x:0,y:0,scale:1}),this.keyFrames[t].x=this.translate[0],this.keyFrames[t].y=this.translate[1],this.keyFrames[t].scale=this.scale,this.keyFrames[t].rotate=this.rotate,this.keyFrames[t].prop_fontSize=this.prop_fontSize,this.keyFrames[t].prop_bgOpacity=this.prop_bgOpacity,this.keyFrames[t].prop_opacity=this.prop_opacity},n.prototype.animate=function(t,e,n){var i=this,r=i.editor.calculateTransformation(e),o=i.editor.calculateTransformation(n),a=d3.select(e);this.editor.timeline.animatedDataFrames.push(a),a.transition().duration(t).tween("customTween",function(){var t=d3.interpolateString(r,o),a=d3.interpolate(e.prop_fontSize,n.prop_fontSize),s=d3.interpolate(e.prop_opacity,n.prop_opacity),l=d3.interpolate(e.prop_bgOpacity,n.prop_bgOpacity);return function(e){i.figure.attr("transform",t(e)),i.prop_fontSize=a(e),i.prop_opacity=s(e),i.prop_bgOpacity=l(e),i.redraw()}})},n}(jQuery),YCEditorArrowAction=function(t){this.editor=t,this.currentOperation=null,this.startx=0,this.starty=0,this.lastx=0,this.lasty=0,this.figure=null,this.points=null,this.sidebar=null;var e=this;this.toolbar=this.editor.toolbar,this.toolbar.find(".arrow-tool").on("click touchstart touchend",function(t){e.toolbar.find(".designer-tool").removeClass("selected"),e.editor.selectedTool===e?e.editor.setSelectedTool(null,"",".selection-tool"):e.editor.setSelectedTool(e,"crosshair",".arrow-tool"),t.stopPropagation()}),this.line=d3.svg.line();var n=new YCLine({points:[[0,0],[0,0]],lineInterpolation:"basis",stroke:4});this.trianglePath=n.trianglePath};YCEditorArrowAction.prototype.startMove=function(t){this.startx=0,this.starty=0},YCEditorArrowAction.prototype.handleMove=function(t){var e=1/this.editor.zoom,n=1/this.editor.zoom;null==this.figure&&(this.figure=this.editor.feedbackLayer.append("g"),this.startx=t.x*e,this.starty=t.y*n,this.lastx=this.startx,this.lasty=this.starty),this.lastx+=t.dx*e,this.lasty+=t.dy*n;var i=[[this.startx,this.starty],[this.lastx,this.lasty]],r=this.figure.selectAll("path.arrow_line").data([i]);r.enter().append("path").attr("class","arrow_line");var o=this.editor.getLastUsedColorsForFigure("arrow")[0];r.attr("stroke",o).attr("fill","none").attr("stroke-width",4/this.editor.zoom).attr("d",this.line);var a=this.figure.selectAll("path.arrow_triangle").data([this.trianglePath(i[0],i[1],10)]);a.enter().append("path").attr("class","arrow_triangle"),a.attr("fill",o).attr("stroke","none").attr("d",this.line)},YCEditorArrowAction.prototype.endMove=function(t){if(null!==this.figure){this.editor.feedbackLayer.selectAll("*").remove(),this.figure=null;var e=[];e.push([this.startx,this.starty]);var n=0,i=0,r=0,o=0;this.startx<=this.lastx&&(n=this.startx+(this.lastx-this.startx)/3,i=this.startx+2*(this.lastx-this.startx)/3),this.startx>this.lastx&&(i=this.lastx+(this.startx-this.lastx)/3,n=this.lastx+2*(this.startx-this.lastx)/3),this.starty<=this.lasty&&(r=this.starty+(this.lasty-this.starty)/3,o=this.starty+2*(this.lasty-this.starty)/3),this.starty>this.lasty&&(o=this.lasty+(this.starty-this.lasty)/3,r=this.lasty+2*(this.starty-this.lasty)/3),e.push([n,r]),e.push([i,o]),e.push([this.lastx,this.lasty]);var a=new YCLine({points:e,lineInterpolation:"basis",lineType:"normal",color:this.editor.getLastUsedColorsForFigure("arrow")[0],stroke:4});a.create(this.editor),this.editor.addElement(a),this.editor.setSelectedTool(null);var s=this;this.editor.appendUndo({undo:function(){s.editor.removeElement(a)},redo:function(){s.editor.addElement(a)},name:function(){return"New Arrow"}})}else this.editor.setSelectedTool(null)};var YCEditorMoveAction=function(t){this.editor=t,this.currentOperation=null,this.alignToPivots=[],this.dx=0,this.dy=0,this.bbox=null,this.originalPositions=[]};YCEditorMoveAction.prototype.startMove=function(t){var e=this;this.currentOperation=null,this.pivot=null,this.alignToPivots=[],this.originalPositions=[],this.dx=0,this.dy=0,this.bbox=null,e.bbox=this.editor.transformedBoundingBox(t.figure.node());var n=[];$.each(this.editor.currentSelection,function(t){n.push(this.id);var i=this.position();e.originalPositions.push({id:this.id,x:i.x,y:i.y})}),$.each(this.editor.elements,function(t){if(this.editor.currentSelection.indexOf(this)<0){var n=e.editor.transformedBoundingBox(this.figure.node());e.alignToPivots.push([n.x+n.width/2,n.y+n.height/2])}}),this.currentOperation={op:"move",elements:n,dx:0,dy:0}},YCEditorMoveAction.prototype.handleMove=function(t){var e=this,n=1/this.editor.zoom,i=1/this.editor.zoom;this.dx+=t.dx*n,this.dy+=t.dy*i,this.editor.feedbackLayer.selectAll("*").remove();var r=e.bbox.x+this.dx,o=e.bbox.y+this.dy,a=null,s=null;t.mouseEvent.shiftKey&&$.each(this.alignToPivots,function(t){if(null===a||null===s){null===a&&Math.abs(r+e.bbox.width/2-this[0])<10/e.editor.zoom&&(r=this[0]-e.bbox.width/2,a={x:this[0],y:this[1]}),null===s&&Math.abs(o+e.bbox.height/2-this[1])<10/e.editor.zoom&&(o=this[1]-e.bbox.height/2,s={x:this[0],y:this[1]})}}),null!==a&&e.editor.feedbackLayer.append("path").attr("d","M"+a.x+","+(o+e.bbox.height/2)+"L"+a.x+","+a.y).attr("id","x-guide-line").attr("stroke",3).attr("opacity",.8).attr("stroke",e.editor.getSelectionShapeStrokeColor()),null!==s&&e.editor.feedbackLayer.append("path").attr("d","M"+(r+e.bbox.width/2)+","+s.y+"L"+s.x+","+s.y).attr("id","x-guide-line").attr("stroke",3).attr("opacity",.8).attr("stroke",e.editor.getSelectionShapeStrokeColor()),this.currentOperation.dx=r-this.bbox.x,this.currentOperation.dy=o-this.bbox.y,$.each(this.originalPositions,function(t){var n=e.editor.findElement(this.id);n.position(this.x+e.currentOperation.dx,this.y+e.currentOperation.dy);var i=n.elementProperty("opacity");null==i&&(i=1),n.figure.transition().duration(50).attr("opacity",Math.min(.6,i))})},YCEditorMoveAction.prototype.endMove=function(t){if($.each(this.editor.currentSelection,function(t){var e=this.elementProperty("opacity");null==e&&(e=1),this.figure.transition().duration(50).attr("opacity",e)}),null!==this.currentOperation&&(0!==this.currentOperation.dx||0!==this.currentOperation.dy)){var e=this.currentOperation,n=this;this.editor.appendUndo({undo:function(){$.each(e.elements,function(t){n.editor.findElement(this).move(-e.dx,-e.dy,!0)})},redo:function(){$.each(e.elements,function(t){n.editor.findElement(this).move(e.dx,e.dy,!0)})},name:function(){return"Move"}})}this.editor.feedbackLayer.selectAll("*").remove()};var YCEditorMoveBackgroundAction=function(t){this.editor=t,this.currentOperation=null,this.alignToPivots=[],this.dx=0,this.dy=0,this.bbox=null,this.originalPositions=[];var e=this;this.editor.$mainElement.find(".background-move-tool").on("click touchstart",function(){e.editor.$mainElement.find(".designer-tool").removeClass("selected"),e.editor.selectedTool===e?e.editor.setSelectedTool(null,"",".selection-tool"):e.editor.setSelectedTool(e,"move",".background-move-tool")})};YCEditorMoveBackgroundAction.prototype.startMove=function(t){this.currentOperation=null,this.pivot=null,this.alignToPivots=[],this.originalPositions=[],this.dx=0,this.dy=0,this.bbox=null,this.currentOperation={op:"move_background",original_x:this.editor.selectedBackgroundPosition[0],original_y:this.editor.selectedBackgroundPosition[1],dx:0,dy:0}},YCEditorMoveBackgroundAction.prototype.handleMove=function(t){var e=1/this.editor.zoom,n=1/this.editor.zoom;this.dx+=t.dx*e,this.dy+=t.dy*n,this.currentOperation.dx=this.dx,this.currentOperation.dy=this.dy,this.editor.selectedBackgroundPosition[0]=this.currentOperation.dx+this.currentOperation.original_x,this.editor.selectedBackgroundPosition[1]=this.currentOperation.dy+this.currentOperation.original_y,this.editor.updateBackground()},YCEditorMoveBackgroundAction.prototype.endMove=function(t){if(null!==this.currentOperation&&(0!==this.currentOperation.dx||0!==this.currentOperation.dy)){var e=this.currentOperation,n=this;this.editor.appendUndo({undo:function(){n.editor.selectedBackgroundPosition[0]=e.original_x,n.editor.selectedBackgroundPosition[1]=e.original_y,n.editor.updateBackground()},redo:function(){n.editor.selectedBackgroundPosition[0]=e.original_x+e.dx,n.editor.selectedBackgroundPosition[1]=e.original_y+e.dy,n.editor.updateBackground()},name:function(){return"Move Background"}})}this.editor.setSelectedTool(null)};var YCEditorPenAction=function(t){this.editor=t,this.currentOperation=null,this.startx=0,this.starty=0,this.lastx=0,this.lasty=0,this.figure=null,this.points=null,this.sidebar=null;var e=this;this.toolbar=this.editor.toolbar,this.toolbar.find(".pen-tool").on("click touchstart",function(){e.toolbar.find(".designer-tool").removeClass("selected"),e.editor.selectedTool===e?e.editor.setSelectedTool(null,"",".selection-tool"):e.editor.setSelectedTool(e,"crosshair",".pen-tool")})};YCEditorPenAction.prototype.startMove=function(t){this.startx=0,this.starty=0,this.points=null},YCEditorPenAction.prototype.handleMove=function(t){var e=1/this.editor.zoom,n=1/this.editor.zoom;null==this.points&&(this.points=[],this.startx=t.x*e,this.starty=t.y*n,this.lastx=this.startx,this.lasty=this.starty,this.figure=this.editor.feedbackLayer.append("path").attr("id","selection-action").attr("d",this.buildPath()).attr("stroke-width",2).attr("stroke-opacity",1).attr("fill-opacity",0).attr("stroke",this.editor.getLastUsedColorsForFigure("pen")[0])),this.lastx+=t.dx*e,this.lasty+=t.dy*n,this.points.push({x:this.lastx,y:this.lasty}),this.figure.attr("d",this.buildPath())},YCEditorPenAction.prototype.endMove=function(t){if(null!==this.figure){var e=this.figure.node().getBBox();this.editor.feedbackLayer.selectAll("*").remove(),this.figure=null;simplify(this.points,1,!0);for(var n=0;n<this.points.length;++n)this.points[n].x-=e.x+e.width/2,this.points[n].y-=e.y+e.height/2;var i=new YCPath({x:e.x+e.width/2,y:e.y+e.height/2,d:this.buildPath(),color:this.editor.getLastUsedColorsForFigure("pen")[0],stroke:2});i.create(this.editor),this.editor.addElement(i),this.editor.setSelectedTool(null);var r=this;this.editor.appendUndo({undo:function(){r.editor.removeElement(i)},redo:function(){r.editor.addElement(i)},name:function(){return"New Path"}}),this.editor.setSelection([i])}else this.editor.setSelectedTool(null)},YCEditorPenAction.prototype.buildPath=function(){if(this.points.length>1)for(var t=this.points,e="M"+t[0].x+" "+t[0].y,n=1;n<t.length;++n)e+=" L"+t[n].x+" "+t[n].y;return e};var YCEditorSelectionAction=function(t){this.editor=t,this.currentOperation=null,this.startx=0,this.starty=0,this.width=1,this.height=1,this.figure=null};YCEditorSelectionAction.prototype.startMove=function(t){this.editor.$element.css("cursor","crosshair"),this.startx=0,this.starty=0,this.width=1,this.height=1},YCEditorSelectionAction.prototype.handleMove=function(t){var e=1/this.editor.zoom,n=1/this.editor.zoom;if(null==this.figure)this.startx=t.x*e,this.starty=t.y*n,this.width=1,this.height=1,this.figure=this.editor.feedbackLayer.append("rect").attr("id","selection-action").attr("x",this.startx).attr("y",this.starty).attr("width",this.width).attr("height",this.height).attr("fill",this.editor.getSelectionShapeStrokeColor()).attr("stroke-width",1/this.editor.zoom).attr("stroke-opacity",1).attr("fill-opacity",.5).attr("stroke","#fff");else{this.width+=t.dx*e,this.height+=t.dy*n;var i=this.getSelectionRectangle();this.figure.attr("x",i.x),this.figure.attr("y",i.y),this.figure.attr("width",i.width),this.figure.attr("height",i.height)}},YCEditorSelectionAction.prototype.endMove=function(t){this.editor.feedbackLayer.selectAll("*").remove(),this.figure=null;var e=this,n=this.getSelectionRectangle();$.each(this.editor.elements,function(t){var i=e.editor.transformedBoundingBox(this.figure.node());n.x<=i.x&&n.y<=i.y&&n.x+n.width>=i.x+i.width&&n.y+n.height>=i.y+i.height&&e.editor.addSelection(this)}),this.editor.$element.css("cursor","")},YCEditorSelectionAction.prototype.getSelectionRectangle=function(){var t={x:0,y:0,w:0,h:0};return this.width>0?(t.x=this.startx,t.width=this.width):(t.x=this.startx+this.width,t.width=-this.width),this.height>0?(t.y=this.starty,t.height=this.height):(t.y=this.starty+this.height,t.height=-this.height),t},function(t){var e=function(t,e){this.skinValue="#f4e3d7",this.hairValue="#B17F48",this.init(t,e)};e.prototype.skins=[{hair:"#B17F48",skin:"#f4e3d7"},{hair:"#191315",skin:"#684d41"},{hair:"#574037",skin:"#b67d5e"},{hair:"#83452e",skin:"#E7B398"},{hair:"#dbd188",skin:"#edd2a8"},{hair:"#3d3537",skin:"#fde9cb"},{hair:"#000000",skin:"#d3ab9b"},{hair:"#673B15",skin:"#EDC9B9"}],e.prototype.skinColors=["#f4e3d7","#EDC9B9","#d3ab9b","#fde9cb","#edd2a8","#f0bc91","#d58f63","#b67d5e","#b36135","#684d41"],e.prototype.hairColors=["#000000","#191315","#3d3537","#B17F48","#83452e","#673B15","#FFE869","#dbd188","#bf0020","#008aff"],e.prototype.init=function(e,n){var i=this;this.settings=t.extend({},this.defaults,n),this.$el=t(e),this.el=e,this.$button=t(this.generateButton()),this.$el.after(this.$button).hide(),this.$el.hide(),this.panel=t('<div class="ycse-panel"></div>'),this.panel.append(this.generatePanelContent()),t(this.el.ownerDocument.body).append(this.panel),this.$button.off("click touchstart").on("click",function(){if(t(i.panel).hasClass("ycse-panel-open"))return i.hide(),!1;var e=i.getOffset(t(i.panel),t(i.$button));return i.panel.css(e),i.settings.beforeShow.call(this),t(i.panel).addClass("ycse-panel-open").show(),i.settings.afterShow.call(this),!1}),t(document).on("click touchstart",function(e){var n=t(e.target);t.contains(i.panel[0],n[0])||i.hide()}),this.settings.afterLoad.call(this)},e.prototype.getOffset=function(e,n){var i=e.outerWidth(),r=e.outerHeight(),o=n.outerHeight(),a=e[0].ownerDocument,s=a.documentElement,l=s.clientWidth+t(a).scrollLeft(),c=s.clientHeight+t(a).scrollTop(),u=n.offset();return u.top+=o,u.left-=Math.min(u.left,u.left+i>l&&l>i?Math.abs(u.left+i-l):0),u.top-=Math.min(u.top,u.top+r>c&&c>r?Math.abs(r+o-0):0),u},e.prototype.container=function(){return t(this.panel)},e.prototype.hide=function(){t(this.panel).hasClass("ycse-panel-open")&&(this.settings.beforeHide.call(this,{hair:this.hairValue,skin:this.skinValue}),t(".ycse-panel-open").removeClass("ycse-panel-open").hide(),this.settings.afterHide.call(this,{hair:this.hairValue,skin:this.skinValue}))},e.prototype.generateButton=function(){var t="";return t+='<div id="skin-chooser" class="ycse-replacer ycse-light">',t+=' <div class="ycse-preview">',t+=' <div class="ycse-preview-inner">',t+=this.generatePreview(40,40),t+=" </div>",t+=" </div>",t+=' <div class="ycse-dd">▼</div>',t+=" </div>"},e.prototype.generatePreview=function(t,e){var n="";return n+=' <svg height="'+t+'" width="'+e+'" viewBox="0 0 33.780486 44.190974" class="skin-preview">',n+=' <g id="layer1" transform="translate(-341.08 -398.85)">',n+=' <path id="path5200" d="m5.8343 25.397c-0.5497-0.444-1.1911-0.626-1.6878-0.481l-0.2777 0.082-0.1865-0.228c-0.7269-0.887-1.5297-2.604-1.9227-4.111-0.1492-0.572-0.1679-0.74-0.1928-1.737-0.030966-1.2388 0.018089-1.7528 0.26001-2.7242 0.16385-0.65798 0.26573-1.9279 0.15467-1.9279-0.028772 0-0.2021 0.08779-0.38518 0.19509s-0.34148 0.18648-0.352 0.17596c-0.010523-0.01052 0.052681-0.29041 0.14045-0.62197 0.51359-1.9401 1.437-3.8797 2.5998-5.4607l0.3724-0.5063-0.2674-0.2238-0.2673-0.2239 0.358-0.6743c1.1079-2.0866 2.5564-3.6731 4.0326-4.4169 1.1021-0.5552 3.9421-1.2514 4.2071-1.0314 0.05537 0.045954 0.14452 0.034574 0.35467-0.04528 0.15439-0.058664 0.53687-0.1627 0.84995-0.23119 0.5246-0.11477 0.70743-0.12458 2.3319-0.12518l1.7626-0.0006502 0.96393 0.18509c0.91406 0.17551 1.0509 0.1871 2.6439 0.22395 1.4697 0.033999 1.714 0.052164 1.952 0.14513 0.21604 0.084397 0.28128 0.14019 0.31697 0.27105 0.12483 0.45772 0.68748 0.9554 1.9732 1.7453 1.1604 0.71295 1.8277 1.3716 2.4826 2.4506 0.65908 1.0858 2.0698 4.4601 2.3562 5.6357 0.06273 0.25751 0.15336 0.8276 0.2014 1.2669 0.1168 1.0681 0.2207 1.3704 0.64372 1.873l0.33831 0.40191 0.11939-0.14973 0.11939-0.14973 0.065 0.39359c0.09715 0.58828 0.16129 1.6102 0.21086 3.3595 0.07298 2.5755 0.08105 2.5003-0.35049 3.2644-0.26827 0.47502-0.35387 0.75538-0.23158 0.75853 0.04165 0.0011 0.01377 0.03738-0.06197 0.08067-0.17152 0.09805-0.40984 0.10488-0.48077 0.01377-0.02948-0.03787-0.20871-0.44596-0.39828-0.90687-0.189-0.461-0.448-1.019-0.576-1.239-0.128-0.221-0.426-0.736-0.663-1.145-0.815-1.412-1.156-1.799-2.231-2.534-0.812-0.556-1.184-0.909-1.274-1.211l-0.06533-0.21804-0.33605 0.02879c-0.70187 0.06012-0.69408 0.05675-0.69408 0.30052 0 0.27013-0.16053 1.813-0.20036 1.9256-0.01733 0.04903-0.14211-0.15252-0.30691-0.49574-0.369-0.7685-0.80909-1.2144-1.6309-1.6525-1.328-0.70783-2.083-1.2638-2.3427-1.7251-0.07133-0.12669-0.21364-0.5092-0.31625-0.85002s-0.20065-0.61967-0.21788-0.61967c-0.08421 0-0.80346 1.6192-1.0699 2.4087-0.52677 1.5606-0.766 1.9006-1.666 2.3679-0.853 0.44284-2.0826 0.85931-2.8958 0.98081l-0.26388 0.03943 0.33588-0.5161c0.4604-0.70743 0.96266-1.7415 1.1251-2.3163 0.15383-0.54438 0.29277-1.6253 0.21763-1.693-0.0582-0.05249-0.74425-0.22538-0.88676-0.22348-0.06701 0.000893-0.18474 0.15858-0.36553 0.48958-0.14668 0.26854-0.48333 0.83185-0.74812 1.2518-0.26479 0.41994-0.82459 1.3088-1.244 1.9753-0.89466 1.4217-1.1158 1.7218-1.6756 2.2734-0.43235 0.42608-2.2442 1.9157-2.4053 1.9775-0.083617 0.03209-0.088038-0.02188-0.050719-0.61914 0.035643-0.57045 0.075779-0.80796 0.22291-1.3191 0.025553-0.08877-0.047023-0.17086-0.3643-0.41207l-0.397-0.301-0.3769 0.403c-0.23729 0.25331-0.44846 0.54888-0.5699 0.79764-0.36042 0.73834-0.37186 0.82886-0.40963 3.2436-0.020641 1.3194-0.055799 2.2085-0.088599 2.2405-0.03517 0.0343-0.14713-0.02177-0.31696-0.15874z" fill-rule="evenodd" transform="translate(341.08 398.85)" stroke="#b17f48" fill="#b17f48" class="yc-hair"/>',n+=' <g stroke="#000" fill="none">',n+=' <path id="path37" d="m351.9 436.57c0.1 0.21 0.21 0.42 0.32 0.62 0.3 0.55 0.64 1.08 1.04 1.58 1.69 2.09 4.88 3.28 7.41 3.67 1.07 0.16 3.14 0.21 4.05-0.4 0.021 0 0.03-0.01 0.04-0.02"/>',n+=' <path id="path39" d="m347.76 426.69c0.33 1.72 1.08 3.45 1.87 5.1 0.41 0.85 0.82 1.67 1.19 2.46 0.38 0.78 0.71 1.56 1.07 2.32"/>',n+=' <path id="path41" d="m347.67 426.13c0.03 0.18 0.06 0.37 0.09 0.55"/>',n+=' <path id="path43" d="m347.76 426.52c-0.04-0.13-0.07-0.26-0.08-0.39"/>',n+=' <path id="path45" d="m372.09 421.77c-0.04 0.18-0.07 0.36-0.11 0.54-0.02 0.12-0.04 0.24-0.069 0.36-0.4 2.25-0.59 4.6-0.891 6.93-0.1 0.77-0.21 1.53-0.34 2.29-0.28 1.59-0.66 3.15-1.24 4.63-0.109 0.28-0.22 0.58-0.35 0.87-0.42 1.02-0.94 2.06-1.74 2.73-0.81 0.68-1.899 1.2-2.63 1.92-0.07 0.07-0.14 0.15-0.21 0.23"/>',n+=' <path id="path47" d="m347.76 426.69v-0.01c0.01-0.05 0.01-0.1 0-0.16 0-0.12-0.03-0.25-0.08-0.39h-0.01c-0.07-0.2-0.18-0.41-0.31-0.61-0.36-0.54-0.87-1.02-1.27-1.17-0.64-0.23-1-0.07-1.19 0.28-0.41 0.75-0.03 2.37 0.19 2.95 0.54 1.41 1.13 3.44 2.33 4.42 0.67 0.54 1.81 0.74 2.21-0.21 0.01-0.03 0.03-0.06 0.04-0.1"/>',n+=' <path id="path49" d="m372.09 422.69c0.16-0.31 0.52-0.51 0.9-0.56 0.38-0.06 0.779 0.03 1.02 0.31 0.68 0.78 0.21 2.37-0.07 3.23-0.38 1.21-1.229 4.18-2.92 3.93h-0.01"/>',n+=' <path id="path51" d="m347.26 425.6c0.04-0.02 0.07-0.05 0.1-0.08 0.6-0.59 0.48-2.77 0.48-3.5 0-1.7-0.14-2.7 1.18-3.89-0.53 1.01-0.25 2.45-0.33 3.53 1.52-1.55 3.42-2.45 4.57-4.4 0.92-1.57 2-3.01 2.83-4.63 0 2.08-1.05 3.39-2.16 5 1.14 0.38 4.06-0.69 4.99-1.37 1.1-0.81 1.21-2.41 1.78-3.55 0.27 0.88 1.4 1.59 2.16 2 0.66 0.35 1.29 0.61 1.73 1.25 0.29 0.4 0.37 0.9 0.67 1.29 0.71 0.92 0.82 0.13 0.93-0.8 0.08-0.64 0.17-1.25 0.15-1.9 0.15 1.15 1.68 1.7 2.42 2.41 0.76 0.73 1.18 1.76 1.75 2.64 0.54 0.84 0.84 2.02 1.25 2.67"/>',n+=' <path id="path53" d="m358.76 432.02c1.43 0.53 4.3 1.18 4.91-0.83"/>',n+=' <path id="path55" d="m350.84 425.69c1-1.48 4.48-2.76 6.08-1.59"/>',n+=' <path id="path57" d="m363.01 422.77c1.7-0.43 4.3-1.27 5.83 0.08"/>',n+=' <path id="path59" d="m352.22 427.58c-0.02-1.15 3.2-2.29 3.93-1.37"/>',n+=' <path id="path61" d="m364.34 424.9c0.29-0.51 1.64-0.65 2.2-0.69 0.319-0.03 0.81-0.08 1.109 0 0.341 0.08 0.591 0.38 0.94 0.43"/>',n+=' <path id="path63" d="m353.9 399.96c-0.07-0.07-0.16-0.11-0.27-0.15-0.66-0.18-1.92 0.22-2.42 0.33-1.48 0.35-2.9 0.98-3.98 2.07-0.91 0.91-1.65 1.85-2.25 2.98-0.44 0.84-0.88 1.75-1.57 2.38 0.53-0.09 1.25-0.57 1.61-0.97-1.01 1.21-1.95 2.96-2.51 4.4-0.48 1.25-1.03 3.15-0.91 4.51 0.56-0.13 0.43-1.25 0.98-1.55 0 0.46-0.18 0.94-0.29 1.39-0.18 0.8-0.2 1.54-0.2 2.36 0 1.4 0.33 2.43 0.83 3.7 0.41 1.04 1.07 2.24 1.86 3.03 0-0.06-0.01-0.12 0-0.17"/>',n+=' <path id="path65" d="m365.15 400.52c0.021 0.09 0.07 0.19 0.141 0.29 0.46 0.65 1.859 1.33 2.359 1.7 1.07 0.77 1.931 1.97 2.471 3.17 0.62 1.36 1.25 2.78 1.72 4.2 0.23 0.7 0.32 1.3 0.39 2.04 0.04 0.45 0.07 0.98 0.38 1.34 0.131-0.22 0.25-0.57 0.37-0.86 0.86 1.8 0.65 4.26 0.75 6.23 0.03 0.74 0.13 1.36-0.189 2.03-0.16 0.34-0.42 0.67-0.521 1.04-0.04 0.01-0.08 0-0.109 0-0.03 0-0.051 0-0.07 0.01"/>',n+=' <path id="path67" d="m353.4 399.9c0.08-0.03 0.15-0.06 0.23-0.09 1.43-0.52 3.13-0.48 4.65-0.42 1.14 0.05 2.24 0.43 3.37 0.44 0.93 0.01 3.45-0.32 3.69 0.94"/>',n+=" </g>",n+=' <g fill-rule="evenodd" fill="#f4e3d7" class="yc-skin">',n+=' <path id="path5194" d="m20.332 43.132c-1.56-0.117-3.367-0.643-4.954-1.441-1.773-0.893-2.769-1.836-3.729-3.531-0.169-0.297-0.547-1.066-0.842-1.708-0.295-0.643-0.8716-1.863-1.2816-2.711-0.4099-0.848-0.8626-1.802-1.0058-2.12-0.6561-1.457-1.1853-3.029-1.2977-3.856-0.0575-0.423-0.1938-0.925-0.2753-1.014-0.025072-0.02728-0.00814-0.13882 0.037631-0.24787 0.15855-0.37774 0.25143-0.97331 0.28195-1.8079l0.030666-0.83847 0.6669-0.65169c0.36679-0.35843 1.1065-1.004 1.6438-1.4346 1.512-1.2117 1.9359-1.6137 2.6182-2.4825l0.10336-0.13162 0.29898 0.10332c0.38539 0.13318 1.2124 0.13317 1.8964-0.00004 0.74724-0.14554 2.0626-0.59941 2.8361-0.97865 0.60124-0.29476 0.74212-0.39128 1.1046-0.75673 0.33314-0.3359 0.46554-0.52245 0.66841-0.94177 0.13914-0.28759 0.32112-0.73358 0.40442-0.99109 0.08329-0.25751 0.16236-0.48742 0.17571-0.51091s0.15254 0.07338 0.30933 0.21527c0.37515 0.33952 1.0765 0.79705 1.8388 1.1996 0.91279 0.48198 1.1027 0.67059 1.504 1.4936 0.38902 0.79781 0.72274 1.1911 1.096 1.2916 0.64156 0.17276 1.0013-0.27164 1.136-1.4033 0.01803-0.15148 0.04507-0.34142 0.0601-0.4221l0.02732-0.14669 0.42356 0.29893c1.442 1.0177 1.4938 1.074 2.3853 2.592 0.73597 1.2533 0.80899 1.3942 1.1307 2.1822 0.29262 0.71678 0.55528 1.2633 0.62906 1.3089 0.03081 0.01904-0.003 0.38528-0.08402 0.90995-0.13658 0.88452-0.25294 1.8107-0.60852 4.844-0.47008 4.0099-0.91618 6.0594-1.8164 8.3449-0.33673 0.85488-0.82511 1.8398-1.1333 2.2857-0.38588 0.55819-0.71372 0.84636-1.7766 1.5616-0.49253 0.33143-1.065 0.74153-1.2722 0.91133-0.38648 0.3168-0.63645 0.42275-1.2351 0.52352-0.48462 0.08158-1.3557 0.10765-1.9957 0.05972zm0.93042-9.0059c0.89655-0.21136 1.5572-0.78158 1.7946-1.549 0.03765-0.1217 0.02567-0.12705-0.85964-0.38384-0.06754-0.01959-0.12679 0.03746-0.21162 0.20374-0.17112 0.33542-0.41851 0.53494-0.81579 0.65793-0.66516 0.20592-1.7821 0.11044-2.9145-0.24915-0.23167-0.07357-0.42443-0.12857-0.42836-0.12222-0.0039 0.0063-0.07094 0.18505-0.14892 0.39712-0.07797 0.21206-0.15834 0.42716-0.1786 0.47798-0.03057 0.07672 0.0504 0.12019 0.47705 0.25608 0.44012 0.14019 0.99714 0.27014 1.5329 0.35762 0.35667 0.05824 1.4298 0.02993 1.7529-0.04626zm-9.5331-5.5513c0.36407-0.61705 2.1384-1.2252 2.7857-0.95481 0.17683 0.07389 0.18562 0.0703 0.57392-0.2341 0.21689-0.17002 0.39554-0.32757 0.39701-0.3501 0.0015-0.02253-0.10053-0.11573-0.22667-0.2071-0.71946-0.52118-1.9771-0.42101-3.3166 0.26415-0.77925 0.3986-1.2967 0.98965-1.3001 1.4849l-0.0012 0.17902h0.4903 0.4903l0.10736-0.18196zm-0.78459-2.1614c0.44182-0.31527 1.2375-0.69186 1.8724-0.88618 0.44043-0.1348 0.58484-0.15208 1.2944-0.15488 0.76122-0.003 0.814 0.004 1.1251 0.1497 0.17951 0.08407 0.34063 0.13232 0.35803 0.10723s0.15324-0.21397 0.30185-0.41972c0.29849-0.41326 0.30609-0.37864-0.13342-0.60814-1.5131-0.79011-4.4774-0.07122-6.0168 1.4592-0.23479 0.23342-0.42632 0.44599-0.42564 0.47238 0.0006875 0.02639 0.19279 0.17432 0.42688 0.32872l0.42563 0.28073 0.21256-0.24092c0.11691-0.1325 0.36846-0.35216 0.559-0.48813zm13.743-0.43207c0.25751-0.04475 0.74188-0.09865 1.0764-0.11977l0.60819-0.0384 0.43415 0.23002c0.60693 0.32156 0.64569 0.30726 0.72726-0.26832 0.03629-0.2561 0.0575-0.47938 0.04713-0.49616-0.01037-0.01679-0.2116-0.12948-0.44718-0.25042l-0.42831-0.2199-0.77471 0.0067c-1.1568 0.01002-2.1286 0.20484-2.7041 0.54211-0.22777 0.13348-0.45026 0.39477-0.38863 0.45641 0.01745 0.01745 0.21153 0.13444 0.43128 0.25998l0.39955 0.22825 0.27541-0.12456c0.15148-0.06851 0.4861-0.16118 0.7436-0.20593zm-1.6972-1.7921c2.1261-0.53455 3.4049-0.51984 4.2156 0.04851l0.23252 0.163 0.31829-0.3603c0.17506-0.19817 0.3183-0.38926 0.3183-0.42464 0-0.10636-0.5797-0.46382-0.99147-0.61137-1.0792-0.38669-2.276-0.34303-4.2993 0.15683-0.53097 0.13118-0.97496 0.24807-0.98664 0.25975-0.01747 0.01748 0.13747 0.66203 0.22004 0.91537 0.03024 0.09279 0.000275 0.09732 0.97262-0.14715z" transform="translate(341.08 398.85)"/>',n+=' <path id="path5196" d="m30.55 30.015c0.01594-0.07118 0.11707-0.9102 0.22472-1.8645 0.10765-0.95429 0.2692-2.2487 0.35901-2.8766 0.08981-0.62781 0.16328-1.1646 0.16328-1.1929 0-0.02827 0.04957-0.03843 0.11016-0.02259s0.11016 0.004 0.11016-0.02642c0-0.09565 0.36456-0.23303 0.61839-0.23303 0.42485 0 0.59364 0.28714 0.59302 1.0088-0.000434 0.50671-0.11211 1.028-0.44999 2.1006-0.52905 1.6794-1.0745 2.7494-1.5878 3.1149l-0.16994 0.121 0.02899-0.12941z" transform="translate(341.08 398.85)"/>',n+=' <path id="path5198" d="m7.0228 32.945c-0.5342-0.242-1.1493-1.036-1.6172-2.087-0.41-0.92-0.9888-2.521-1.1088-3.066-0.1223-0.555-0.1436-1.469-0.0394-1.698 0.086286-0.18938 0.16717-0.21104 0.45952-0.12305 0.31504 0.09481 0.62874 0.34345 0.93212 0.73878 0.33603 0.43788 0.39653 0.57574 0.49922 1.1376 0.20839 1.1402 0.70886 2.6307 1.4148 4.2138 0.3489 0.78234 0.37288 0.85953 0.28672 0.92262-0.13837 0.10132-0.56277 0.08163-0.82706-0.03836z" transform="translate(341.08 398.85)"/>',n+=" </g>",n+=" </g>",n+=" </svg>"},e.prototype.generatePanelContent=function(e){var n=this;void 0===e&&(e=!1);var i=t("<div></div>");if(e){for(var r=t("<ul></ul>").addClass("ycse-hair-buttons"),o=0;o<this.hairColors.length;++o){var a=t("<li></li>").css({"background-color":this.hairColors[o]});this.hairColors[o].toUpperCase()===this.hairValue.toUpperCase()&&a.addClass("selected"),r.append(a)}i.append(r),(g=t("<div></div>").addClass("ycse-preview-face")).append(this.generatePreview(60,60)),i.append(g);var s=t("<ul></ul>").addClass("ycse-skin-buttons");for(o=0;o<this.skinColors.length;++o){var l=t("<li></li>").css({"background-color":this.skinColors[o]});this.skinColors[o].toUpperCase()===this.skinValue.toUpperCase()&&l.addClass("selected"),s.append(l)}g.find(".yc-hair").attr("fill",this.hairValue).attr("stroke",this.hairValue),g.find(".yc-skin").attr("fill",this.skinValue),i.append(s);var c=t("<div></div>").addClass("ycse-less-options");c.html('<span class="ycse-less-options-link">◀ Less options</span>'),i.append(c),t(".ycse-less-options-link",i).on("click touchstart",function(e){return e.preventDefault(),t(".ycse-panel").html(n.generatePanelContent(!1)),!1}),t(".ycse-hair-buttons li",i).on("click touchstart",function(e){e.preventDefault(),t(".ycse-hair-buttons li").removeClass("selected"),t(this).addClass("selected");var i=n.rgb2hex(t(this).css("background-color"));n.hairValue=i,n.updateButtonPreview(),n.updateAdvancedPreview(),n.fireChange()}),t(".ycse-skin-buttons li",i).on("click touchstart",function(e){e.preventDefault(),t(".ycse-skin-buttons li").removeClass("selected"),t(this).addClass("selected");var i=n.rgb2hex(t(this).css("background-color"));n.skinValue=i,n.updateButtonPreview(),n.updateAdvancedPreview(),n.fireChange()})}else{for(var u=Math.floor(this.skins.length/2),h=!1,p=0;p<2;++p){var d=t("<div></div>");for(o=p*u;o<this.skins.length&&o<(p+1)*u;++o){var f=this.skins[o],g=t("<div></div>").addClass("ycse-face").attr("face",o);7==o&&g.addClass("ycse-custom-face"),g.append(this.generatePreview(40,40)),g.find(".yc-hair").attr("fill",f.hair).attr("stroke",f.hair),g.find(".yc-skin").attr("fill",f.skin),h||this.hairValue.toUpperCase()!==f.hair.toUpperCase()||this.skinValue.toUpperCase()!==f.skin.toUpperCase()||(t(".ycse-panel .ycse-face").removeClass("selected"),h=!0,g.addClass("selected")),d.append(g),g.on("click touchstart",function(){n.skinValue=n.rgb2hex(t(this).find(".yc-skin").attr("fill")),n.hairValue=n.rgb2hex(t(this).find(".yc-hair").attr("fill")),t(".ycse-panel .ycse-face").removeClass("selected"),t(this).addClass("selected"),n.updateButtonPreview(),n.fireChange()})}i.append(d)}h||(t(".ycse-custom-face").find(".yc-skin").attr("fill",this.skinValue),t(".ycse-custom-face").find(".yc-hair").attr("fill",this.hairValue).attr("stroke",this.hairValue),t(".ycse-custom-face").addClass("selected")),(e=t("<div></div>").addClass("ycse-more-options")).html('<span class="ycse-more-options-link">More options ►</span>'),i.append(e),t(".ycse-more-options-link",i).on("click touchstart",function(e){return e.preventDefault(),t(".ycse-panel").html(n.generatePanelContent(!0)),!1})}return i},e.prototype.rgb2hex=function(t){if(void 0===t)return null;if("#"===t.substring(0,1))return t;var e=new Array("0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f");function n(t){return isNaN(t)?"00":e[(t-t%16)/16]+e[t%16]}return"#"+n((t=t.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/))[1])+n(t[2])+n(t[3])},e.prototype.updateButtonPreview=function(){t(".yc-hair",this.$button).attr("fill",this.hairValue).attr("stroke",this.hairValue),this.$button.find(".yc-skin").attr("fill",this.skinValue),this.skins[7].skin=this.skinValue,this.skins[7].hair=this.hairValue},e.prototype.updateAdvancedPreview=function(){t(".ycse-preview-face",this.$panel).find(".yc-hair").attr("fill",this.hairValue).attr("stroke",this.hairValue),t(".ycse-preview-face",this.$panel).find(".yc-skin").attr("fill",this.skinValue)},e.prototype.fireChange=function(){this.settings.change({hair:this.hairValue,skin:this.skinValue})},e.prototype.setValue=function(t){this.skinValue=t.skin,this.hairValue=t.hair,this.updateSelectedColors()},e.prototype.updateSelectedColors=function(){this.updateButtonPreview(),this.panel.html(this.generatePanelContent(0===t(this.panel).find(".ycse-more-options-link").length))},e.prototype.defaults={afterLoad:function(){},beforeShow:function(){},afterShow:function(){},beforeHide:function(){},afterHide:function(t){},change:function(t){}},e.prototype.settings={};var n=t.fn.YCSkinChooser;t.fn.YCSkinChooser=function(n,i){var r=null,o=this.each(function(){var o=t(this),a=o.data("YCSkinChooser"),s="object"==typeof n&&n;a||o.data("YCSkinChooser",a=new e(this,s)),"string"==typeof n&&(r=a[n].apply(a,i))});return null!=r?r:o},t.fn.YCSkinChooser.Constructor=e,t.fn.YCSkinChooser.noConflict=function(){return t.fn.YCSkinChooser=n,this}}(jQuery),function(t){var e=function(t,e){this.init(t,e)};e.prototype.uniformConfigLabels={full:{c1:"T-Shirt",c3:"Stripes",c2:"Shorts",c4:"Socks"},bicolor:{c1:"T-Shirt and socks",c2:"Shorts"}},e.prototype.tshirtsColors={c1:"#FFFFFF",c3:"#000000",c2:"#FFFFFF",c4:"#FFFFFF"},e.prototype.init=function(e,n){var i=this;this.settings=t.extend({},this.defaults,n),this.uniformConfigLabels.full.c1=this.settings.locale["T-Shirt"],this.uniformConfigLabels.full.c3=this.settings.locale.Stripes,this.uniformConfigLabels.full.c2=this.settings.locale.Shorts,this.uniformConfigLabels.full.c4=this.settings.locale.Socks,this.$el=t(e),this.el=e,this.$button=t(this.generateButton()),this.$el.after(this.$button).hide(),this.$el.hide(),this.presets=[],this.panel=t('<div class="ycue-panel"></div>'),this.panel.append(this.generatePanelContent()),t(this.el.ownerDocument.body).append(this.panel),this.$button.off("click touchstart").on("click",function(){if(t(i.panel).hasClass("ycue-panel-open"))return!(t(".ycuc-sp-container:not(.sp-hidden)").size()>0)&&(i.hide(),!1);var e=i.getOffset(t(i.panel),t(i.$button));return i.panel.css(e),i.settings.beforeShow.call(this),t(i.panel).addClass("ycue-panel-open").show(),i.settings.afterShow.call(this),!1}),t(document).on("click touchstart",function(e){var n=t(e.target);t.contains(i.panel[0],n[0])||i.hide()}),this.setPreview(this.settings.config),this.settings.afterLoad.call(this)},e.prototype.getOffset=function(e,n){var i=e.outerWidth(),r=e.outerHeight(),o=n.outerHeight(),a=e[0].ownerDocument,s=a.documentElement,l=s.clientWidth+t(a).scrollLeft(),c=s.clientHeight+t(a).scrollTop(),u=n.offset();return u.top+=o,u.left-=Math.min(u.left,u.left+i>l&&l>i?Math.abs(u.left+i-l):0),u.top-=Math.min(u.top,u.top+r>c&&c>r?Math.abs(r+o-0):0),u},e.prototype.container=function(){return t(this.panel)},e.prototype.hide=function(){t(this.panel).hasClass("ycue-panel-open")&&(t(".ycuc-color-button input",this.panel).each(function(){t(this).spectrum("container").hasClass("sp-hidden")||t(this).spectrum("hide")}),this.settings.beforeHide.call(this,t.extend({},this.settings.config)),t(".ycue-panel-open").removeClass("ycue-panel-open").hide(),this.settings.afterHide.call(this,t.extend({},this.settings.config)))},e.prototype.generateButton=function(){var t="";return t+='<div id="uniform-chooser" class="ycue-replacer ycue-light">',t+=' <div class="ycue-preview">',t+=' <div class="ycue-preview-inner ycuc-preview-svg">',t+=this.generatePreview(20,20,!0),t+=" </div>",t+=" </div>",t+=' <div class="ycue-dd">▼</div>',t+=" </div>"},e.prototype.generatePreviewTShirt=function(t,e){return'<?xml version="1.0" encoding="UTF-8"?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.7c-16.7-2.3-33.5 3.9-50.3 2.2-4.6-0.5-9.2-1.6-13.7-2.7-3.4-0.8-6.8-1.6-10.2-2.5 1.5-2.6 2-5.7 1.4-8.6-0.5-2.3-1.4-5.2 0.4-6.8v-0.1c0.9 0.1 1.6 0.4 2.1 0.8z"/>\n <path class="h_stripe" d="m-326.8 49.9c3.6-0.8 7.2-1.8 10.8-1.6-0.6 4.9 0.2 9.9 2.3 14.3-16.5 3.2-33.3 4.7-50 4.5-2 0-4.1-0.1-5.9-0.8-2.9-1.2-5.2-4.2-8.3-4.4-1.1-0.1-2.6 0.1-3.1-0.9-0.2-0.4-0.2-0.8-0.1-1.3 0.3-3.9 0.8-7.7 1.5-11.5l0.4-0.7c4.3-0.7 8.3 2.3 12.4 3.8 3.2 1.1 6.6 1.4 10 1.5 10 0.3 20.2-0.7 30-2.9z"/>\n <path class="h_stripe" d="m-294.9 5.8c-0.4 5-0.2 10.1 0.7 15.1-7.1-0.9-14.2 1.8-20.8 4.5-0.6 0.2-1.3 0.4-1.8 0-0.3-0.2-0.4-0.7-0.4-1-0.2-1.2-0.4-2.4-0.5-3.6v-0.1c6.3-6.6 14.1-11.7 22.8-14.9z"/>\n <path class="h_stripe" d="m-317.8 20.7v0c-0.1 1 0 2 0.1 2.9 0.3 3 1 6.1 0.6 9.1-9.5 0.3-19 0.7-28.5 1-4.3 0.1-8.6 0.3-12.9 0-6.5-0.5-13-2-19.1-4.5-0.5-0.2-1.1-0.5-1.4-0.9s-0.4-1-0.4-1.6c-0.2-2.5-0.3-5.1-0.5-7.7 0.2 0 0.4 0.1 0.5 0.1-0.2-0.4-0.4-0.9-0.6-1.3-0.1-2.2-0.3-4.4-0.4-6.7 7.3 4.5 16 6.2 24.5 7.3 13.5 1.8 27.9 2.2 40.2-3.6-1.3 1.7-1.9 3.8-2.1 5.9z"/>\n <path class="h_stripe" d="m-380 18c0 0.4 0.1 0.8 0.1 1.2-6.8-1.2-13.8-1.5-20.7-1-0.4 0-0.9 0-1.1-0.3-0.2-0.2-0.1-0.6-0.1-0.9 0.5-3.9 2.7-7.6 2.6-11.6 0-0.6-0.1-1.3 0.1-1.9 0.1-0.3 0.3-0.7 0.6-0.9 3.8-0.5 7.6 1.8 10.5 4.5 3.2 3 6 6.8 8 10.9z"/>\n <path class="h_stripe" d="m-306.3-18.4c4.6 1.5 8.2 5.8 8.8 10.7-8.7 6.2-19 9.9-29.5 11.8-5.3 1-10.6 1.5-16 1.1-5-0.3-9.9-1.4-14.8-2.5-7.8-1.7-15.8-3.5-22.6-7.8-2.2-1.4-4.2-2.9-6.5-4-3.1-1.5-6.6-2-10.1-2.5 0.6-3.8 4.2-6.8 8-6.8 1.1 0 2.2 0.3 3.4 0.2 1.1-0.1 2.3-0.7 2.7-1.7v-0.1c2.9 1.2 5.8 2.5 8.7 3.7 4.7 2 9.6 4.1 14.7 4.2 2.3 0.1 4.7-0.3 7 0.2s4.6 2 4.9 4.3c1.3-2.2 2.8-4.5 5.2-5.2 1-0.3 2.1-0.2 3.2-0.2 5.2 0.3 10.4 0.8 15.5 0.3s10.4-2 14.4-5.2c0.4-0.3 0.8-0.6 1.2-0.8 0.6 0 1.2 0.1 1.8 0.3z"/>\n <path class="v_stripe" d="m-317.3 21.6c0.2-0.5 0.8-0.8 1.4-1.1 4.1-1.8 8.2-3.7 11.8-6.3s6.8-6.1 8.5-10.2c0.5 6.6 1 13.1 1.5 19.7-5.9 0.8-11.8 1.6-17.7 2.4-1.8 0.2-3.7 0.5-5.5 0.2v-4.7z"/>\n <path class="v_stripe" d="m-297.2-10.1c0.4 3.9-1.6 7.6-3.7 10.8-4.4 6.6-10.1 12.4-16.6 17 3.7-6.6 7.4-13.1 11-19.7 2.6-4.7 5.2-9.6 5.2-14.9l0.2-0.1c2.1 1.6 3.6 4.2 3.9 6.9z"/>\n <path class="v_stripe" d="m-323.9-25.9c1.1 1.9 3.5 2.9 5.7 3.5 2.6 0.7 5.5 1.3 7.1 3.5 1.6 2.1 1.5 5 1.1 7.6-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.9-3.3 23.4-1 3.1-2.6 5.9-3.8 8.9-1.4 3.7-2.3 7.6-2.4 11.5-4.3-0.6-8.6-1.2-12.9-1.8 0.9-4.8 1.8-9.7 4.1-14.1 2.1-4.1 5.5-7.5 6.9-11.9 1.7-5.2 0.6-10.8 0.8-16.2 0.2-6.9 2.7-13.8 1.6-20.6-0.5-3.5-2-6.8-2.6-10.3-0.5-2.5-0.6-5.1-0.8-7.6-0.8-12.5-2.7-25-5.9-37.2 4.7-2 9.3-4.3 13.7-7-0.7 2.2-0.9 4.6-0.9 7-0.4 19.6 6.4 38.8 6.3 58.5-0.1 2.3-0.2 4.6 0.1 6.9z"/>\n <path class="v_stripe" d="m-388.4-13.3c3.8 8 6.5 16.6 7.8 25.5-1.6-2.9-3.5-5.7-5.3-8.5-0.6-0.9-1.2-1.7-1.9-2.4-0.6-0.5-1.4-0.9-2.2-1.3-2.4-1.2-4.7-2.4-7.1-3.7-0.3-0.2-0.6-0.3-0.8-0.7-0.1-0.3-0.1-0.6-0.1-0.9 0.7-4.8 2.9-9.3 6.2-12.8 1.6 1.3 2.5 3.1 3.4 4.8z"/>\n <path class="v_stripe" d="m-379.6 18.2c0 1.8 0.1 3.6 0.1 5.4-6.4-3.1-13.9-4-20.9-2.5-0.3 0.1-0.6 0.1-0.9 0.1-0.5-0.1-0.9-0.6-1.1-1.1-0.3-0.9-0.1-1.9 0-2.9 0.5-3 1.1-6.1 1.7-9.1 3.6-0.6 7.4 0.8 10.6 2.7 3.3 2 6.3 4.5 9.7 6.3 0.2 0.1 0.5 0.2 0.6 0.5 0.2 0.2 0.2 0.4 0.2 0.6z"/>\n </svg>\n '},e.prototype.generatePreview=function(t,e,n){void 0===n&&(n=!1);var i='<?xml version="1.0" encoding="UTF-8"?>\n <svg version="1.1" viewBox="-424 -84 150 368" xmlns="http://www.w3.org/2000/svg">\n <path class="skin" d="m-321.1 160.6c3.1 0 6.5 0.4 9.6-0.1 2.5-0.4 4.8-1.2 7-2.3 0.7-0.4 1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10 1.5 10 0.3 20.2-0.7 30-2.9z"/>\n <path class="h_stripe" d="m-294.9 5.8c-0.4 5-0.2 10.1 0.7 15.1-7.1-0.9-14.2 1.8-20.8 4.5-0.6 0.2-1.3 0.4-1.8 0-0.3-0.2-0.4-0.7-0.4-1-0.2-1.2-0.4-2.4-0.5-3.6v-0.1c6.3-6.6 14.1-11.7 22.8-14.9z"/>\n <path class="h_stripe" d="m-317.8 20.7v0c-0.1 1 0 2 0.1 2.9 0.3 3 1 6.1 0.6 9.1-9.5 0.3-19 0.7-28.5 1-4.3 0.1-8.6 0.3-12.9 0-6.5-0.5-13-2-19.1-4.5-0.5-0.2-1.1-0.5-1.4-0.9s-0.4-1-0.4-1.6c-0.2-2.5-0.3-5.1-0.5-7.7 0.2 0 0.4 0.1 0.5 0.1-0.2-0.4-0.4-0.9-0.6-1.3-0.1-2.2-0.3-4.4-0.4-6.7 7.3 4.5 16 6.2 24.5 7.3 13.5 1.8 27.9 2.2 40.2-3.6-1.3 1.7-1.9 3.8-2.1 5.9z"/>\n <path class="h_stripe" d="m-380 18c0 0.4 0.1 0.8 0.1 1.2-6.8-1.2-13.8-1.5-20.7-1-0.4 0-0.9 0-1.1-0.3-0.2-0.2-0.1-0.6-0.1-0.9 0.5-3.9 2.7-7.6 2.6-11.6 0-0.6-0.1-1.3 0.1-1.9 0.1-0.3 0.3-0.7 0.6-0.9 3.8-0.5 7.6 1.8 10.5 4.5 3.2 3 6 6.8 8 10.9z"/>\n <path class="h_stripe" d="m-306.3-18.4c4.6 1.5 8.2 5.8 8.8 10.7-8.7 6.2-19 9.9-29.5 11.8-5.3 1-10.6 1.5-16 1.1-5-0.3-9.9-1.4-14.8-2.5-7.8-1.7-15.8-3.5-22.6-7.8-2.2-1.4-4.2-2.9-6.5-4-3.1-1.5-6.6-2-10.1-2.5 0.6-3.8 4.2-6.8 8-6.8 1.1 0 2.2 0.3 3.4 0.2 1.1-0.1 2.3-0.7 2.7-1.7v-0.1c2.9 1.2 5.8 2.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3.3 2.9 5 9.4 4.8 13.8-1-0.1-3.5-5.2-4.3-6.3-1.3-2-2.4-4.5-3.4-6.7-1.1-2.5-2.6-4.9-3.7-7.5-0.9-2.1-1.9-6.5-1.2-8.7" opacity=".4" stroke="#000"/>\n <path d="m-331.7 26.3c2.6-0.2 5.2-1.2 7.5-2.9 1.6-1.1 2.6-3.3 4.1-4.2 0.4 3 1 6 1.2 9.1 0.2 3.9 0.2 7.9 0.5 11.7 0.2 2.6 0.8 5.2 1.3 7.7 0.4 1.8 1 4.4 0.7 6.3-1.4-0.2-3.4-8.5-3.6-10.3-0.4-2.6 0.5-5.6-1.1-7.8-1.2-1.7-3.6-3.6-5.3-4.9-1.4-1-5.3-3.2-5.5-5" opacity=".4" stroke="#000"/>\n <path d="m-310.1 4.5c-1.1 1.4-0.8 5.6 1.3 3.4-1.8 1.6-3.2 4.7-4.3 6.9s-2 4.6-3.5 6.6c0.7-2.9 1.1-5.6 2.6-8.3 1.4-2.5 2.2-5.9 4-8" opacity=".4" stroke="#000"/>\n <path d="m-309.4 18.7c-2.3 1.8-4.7 4.8-5.5 7.5-0.7 2.5-2 4.6-1.8 7.3 1.5-0.5 2.3-1.8 3.4-3 1.4-1.5 2.9-1.8 3.1-3.9 0.3-3.1-0.2-6.5 0.8-9.3" opacity=".4" stroke="#000"/>\n <path d="m-310.6 33.8c1.7-2.5 8-2 10.8-2-4.8 3.4-3.8 10.8-6.9 15.4 2.2-3.9 0.5-11.8-3.6-13.5" opacity=".4" stroke="#000"/>\n <path d="m-342.2 122.2c0 2.9 1.2 7.4 2.2 11 1.1 4 3.3 7.6 4.5 11.6 0.8 2.7 2 5.7 2.3 8.5 0.1 0.8 0.4 3.6-0.2 4.1-0.3 0.3-2.6 0.4-3.3 0.6-1.3 0.3-2.7 0.7-4 0.8 0-2.9 0.6-6 0.3-9-0.3-3.3-1.5-6.2-2.5-9.2-1-2.7-2.8-4.3-1.8-7.3 1-2.8 1.6-5.8 2.1-8.7 0.2-0.8 0.3-2.1 0.9-2.8" opacity=".4" stroke="#000"/>\n <path d="m-372.6 101c1.4 0.9-1.7 8.3-2.1 10-0.6 2.2-1.2 4.3-1.9 6.4 1.2-3.1 3.1-6.7 4.8-9.6 1.2-2 2.8-4 2.5-6.5-0.9 0-2.1-0.1-2.8-0.4" opacity=".4" stroke="#000"/>\n <path d="m-380.9 99.3c1.7 1.1 4.7 0.8 6.6 1.2-2.4 2.6-6.3 4.4-8.1 7.6 0.3-2.6-0.1-6.6 1.5-8.8" opacity=".4" stroke="#000"/>\n <path d="m-330.1 100.3c1.2 1.3 1.9 2.9 2.8 4.3 1 1.6 2.1 2.8 2.9 4.5 1.1 2.3 2.8 4.3 4.1 6.4-1-1.8-5.9-11.1-0.3-9.7-2 0.4-4.5-3.1-5.7-4.7-1.5-2.1-1.6-1.6-4.1-1.4 0 0 0.6 0.4 0.9 0.5" opacity=".4" stroke="#000"/>\n <path d="m-324.4 99.5c2.2 0.7 5.1 0.4 7.4 0.5 1.2 0.1 4.3 0.4 5.2-0.3-3.3 0.4-3.5 4.3-4.7 6.4-1.3-0.9-8.3-5.4-8.1-6.6" opacity=".4" stroke="#000"/>\n <path d="m-328.2 162c5 1 11 0.8 15.8-0.5-2.8 0.7-5.8 6-7 8.5-1.6 3.4-2.2 7.1-3.8 10.4-1.9-1.7-1.6-6.3-1.9-8.6-0.2-1.6-0.3-3.2-0.9-4.7-0.5-1.2-2.8-3.6-2.5-4.7" opacity=".4" stroke="#000"/>\n <path d="m-363.6 116.7c-2.3 5.5-5.2 10.3-9.1 14.8-2.1 2.4-4.1 4.6-6.6 6.6-0.8 0.6-2.8 1.7-3 2.9-0.2 1.4 1.6 2 1.2 3.3-0.3 0.9-1.8 1.9-2.4 2.7-1.2 1.6-2.2 3.3-3.3 5-2.3 3.8-0.3 6.8 3.8 8.2 3.1 1 6.2 1 9.5 1 2 0 4.7 0 6.3-1.4 2.3-1.9 2.9-5.7 3.7-8.5 1.3-4.4 4.4-8 6.5-12 2.5-5.1 4.2-10.4 6-15.7 1.8-5 3.7-10.3 3.4-15.6-1.4 0.1-3.7 3.9-4.7 5-1.6 1.8-2.3 3.6-4.8 3.9-1.5 0.2-6.4-0.6-6.9 0.7" fill="#fff" opacity=".5" stroke="#fff"/>\n <path d="m-397.4 48.3c-2.1 1.2-2.9 5.5-3 7.7-0.2 3.7-0.3 7.4-0.3 11.1 0 6.9-0.7 13.8-0.1 20.7 1.3-4.2 1.5-9.1 2.2-13.6 0.7-5 1.9-10.1 3-15 0.5-2.4 2.6-11.2-1.4-10.9" fill="#fff" opacity=".5" stroke="#fff"/>\n <path d="m-377.1-17.8c-2.1 0.2-4.1 0.7-6.2 0.9-1.8 0.2-3.4-0.1-5.1 0.3-3.8 0.8-6.8 3.3-6 7.8 1.1 6 7.8 4.3 12 3.7 4-0.6 6 0.9 8.7 3.9 2.1 2.4 3.4 5 4.9 7.9 1.6 3.2 3.8 4.5 7 5.6 3.5 1.3 7 2.4 10.7 1 1.6-0.6 2.9-1.7 4.5-2 1.7-0.4 3.6 0.2 5.3 0.7 3.1 0.9 6.2 2.4 9.5 1.9 6-0.8 9.3-6.7 12.3-11.2 2.6-3.9 6-4.5 10.5-5 3.8-0.4 6.3-2.7 6.8-6.5 0.4-3.2-1.3-7-4.5-8.1s-6.5-1.3-9.8-2c-1.3-0.3-3.1-1.1-4.4-0.9-1.8 0.3-3.5 2.1-4.9 3.1-2.8 1.9-5.9 3.4-8.6 5.4-2.1 1.5-4.1 3.2-6.3 4.4-1.6 0.9-3.7 2-5.7 1.4-1.3-0.4-2.6-2.2-3.8-3.2-4.1-3.3-7.6-6.7-13-7.8-3.1-0.6-6.1-1.2-9.2-1.6-1.8-0.3-3.6 0-5.3 0" fill="#fff" opacity=".5" stroke="#fff"/>\n '),i+="</svg>"},e.prototype.generatePanelContent=function(){var e=this,n=t('<div class="ycue-panel-container"></div>'),i=t('<div class="ycue-preview-big ycuc-preview-svg"/>');i.append(this.generatePreview(40,100,!0)),n.append(i);var r=t("<div></div>"),o=["f","v","h","q"];if("bicolor"!=this.settings.mode){for(var a=t('<div class="ycue-preview-tshirts"></div>'),s=0;s<o.length;++s){var l=o[s],c=t("<div></div>").addClass("ycue-shirt").attr("tshirt-type",l);c.append(this.generatePreviewTShirt(40,40));var u=t.extend({},this.tshirtsColors,{type:l});this.setPreview(u,c),u.type==this.settings.config.type&&(t(".ycue-panel .ycue-shirt").removeClass("selected"),c.addClass("selected")),a.append(c),c.on("click touchstart",function(){e.settings.config.type="bicolor"!=e.settings.mode?t(this).attr("tshirt-type"):"f",e.setPreview(e.settings.config),e.fireChange()})}r.append(a)}var h=t('<div class="ycuc-color-buttons"></div>'),p=0,d=t('<div class="ycuc-color-buttons-column"></div>');for(var f in h.append(d),this.uniformConfigLabels[this.settings.mode]){3==++p&&(d=t('<div class="ycuc-color-buttons-column"></div>'),h.append(d));var g=t('<div class="ycuc-color-button" id="ycuc-color-'+f+'-container"></div>'),m=t('<input id="ycuc-color-'+f+'" color-prop="'+f+'"/>');g.append(m);var y=t("<label/>");y.text(this.uniformConfigLabels[this.settings.mode][f]),g.append(y),d.append(g),m.val(this.settings.config[f]);m.spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showPalette:!0,showSelectionPalette:!0,localStorageKey:"youcoach.drilleditor",maxSelectionSize:3,showInitial:!0,showButtons:!1,preferredFormat:"hex",containerClassName:"ycuc-sp-container",show:function(){},move:function(n){e.settings.config[t(this).attr("color-prop")]=n.toHexString(),e.setPreview(e.settings.config),e.fireChange()},hide:function(n){e.settings.config[t(this).attr("color-prop")]=n.toHexString(),e.setPreview(e.settings.config),e.fireChange()}})}r.append(h),n.append(r);for(var v=t('<div class="ycue-presets-container"/>'),C=0;C<4;++C){var b=t('<div class="ycue-presets-figure" preset-index="'+C+'"/>');b.append(this.generatePreview(0,0,!0)),v.append(b),b.on("click",function(){var n=t(this).attr("preset-index");e.settings.config=t.extend({},e.getPreset(n)),e.setPreview(e.settings.config),e.fireChange()})}return n.append(v),n},e.prototype.setPreview=function(e,n){if(void 0===n&&(n=t(this.$button).add(t(".ycuc-preview-svg",this.$p)),"bicolor"==this.settings.mode?(t("#ycuc-color-c3-container",self.$panel).hide(),t("#ycuc-color-c4-container",self.$panel).hide()):(t("#ycuc-color-c4-container",self.$panel).show(),"f"==this.settings.config.type?t("#ycuc-color-c3-container",self.$panel).hide():t("#ycuc-color-c3-container",self.$panel).show()),t(".ycue-shirt",this.panel).removeClass("selected"),t(".ycue-shirt[tshirt-type="+e.type+"]",this.panel).addClass("selected"),t("#ycuc-color-c1",this.panel).spectrum("set",e.c1),t("#ycuc-color-c2",this.panel).spectrum("set",e.c2),t("#ycuc-color-c3",this.panel).spectrum("set",e.c3),t("#ycuc-color-c4",this.panel).spectrum("set",e.c4)),"bicolor"!=this.settings.mode)switch(n.find(".base_tshirt").css("fill",e.c1),n.find(".shorts").css("fill",e.c2),n.find(".socks").css("fill",e.c4),e.type){case"f":n.find(".v_stripe").css("fill","none"),n.find(".h_stripe").css("fill","none");break;case"v":n.find(".v_stripe").css("fill",e.c3),n.find(".h_stripe").css("fill","none");break;case"h":n.find(".v_stripe").css("fill","none"),n.find(".h_stripe").css("fill",e.c3);break;case"q":n.find(".v_stripe").css("fill",e.c3),n.find(".h_stripe").css("fill",e.c3)}else n.find(".base_tshirt").css("fill",e.c1),n.find(".shorts").css("fill",e.c2),n.find(".socks").css("fill",e.c1),n.find(".v_stripe").css("fill","none"),n.find(".h_stripe").css("fill","none")},e.prototype.rgb2hex=function(t){if(void 0===t)return null;if("#"===t.substring(0,1))return t;var e=new Array("0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f");function n(t){return isNaN(t)?"00":e[(t-t%16)/16]+e[t%16]}return"#"+n((t=t.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/))[1])+n(t[2])+n(t[3])},e.prototype.fireChange=function(){this.settings.change(t.extend({},this.settings.config))},e.prototype.setValue=function(e){this.settings.config=t.extend(this.settings.config,e),this.updateSelectedColors()},e.prototype.setPresets=function(e){this.presets=e;for(var n=0;n<4;++n)this.setPreview(this.getPreset(n),t(".ycue-presets-figure[preset-index="+n+"]",this.panel))},e.prototype.getPreset=function(t){return void 0===this.presets[t]?{type:"f",c1:"#000000",c2:"#000000",c3:"#000000",c4:"#000000"}:this.presets[t]},e.prototype.updateSelectedColors=function(){this.panel.html(this.generatePanelContent()),this.setPreview(this.settings.config)},e.prototype.setMode=function(t){this.settings.mode=t,this.updateSelectedColors(),this.setPresets(this.presets)},e.prototype.defaults={afterLoad:function(){},beforeShow:function(){},afterShow:function(){},beforeHide:function(){},afterHide:function(t){},change:function(t){},config:{type:"f",c1:"#FF0000",c3:"#FFFFFF",c2:"#000000",c4:"#FF0000"},mode:"full",locale:{"T-Shirt":"T-Shirt",Shorts:"Shorts",Socks:"Socks",Stripes:"Stripes"}},e.prototype.settings={};var n=t.fn.YCUniformChooser;t.fn.YCUniformChooser=function(n,i){var r=null,o=this.each(function(){var o=t(this),a=o.data("YCUniformChooser"),s="object"==typeof n&&n;a||o.data("YCUniformChooser",a=new e(this,s)),"string"==typeof n&&(r=a[n].apply(a,i))});return null!=r?r:o},t.fn.YCUniformChooser.Constructor=e,t.fn.YCUniformChooser.noConflict=function(){return t.fn.YCUniformChooser=n,this}}(jQuery),SVGElement.prototype.getTransformToElement=SVGElement.prototype.getTransformToElement||function(t){return t.getScreenCTM().inverse().multiply(this.getScreenCTM())};var YCEditor=function(t,e){this.id="main_Editor",this.options=null,this.elements=[],this.$element=null,this.$mainElement=null,this.zoom=null,this.undoRedoStack=[],this.undoRedoStackIndex=0,this.originalHeight=null,this.originalWidth=null,this.defs=null,this.background=null,this.elementsLayer=null,this.selectionLayer=null,this.backSelectionLayer=null,this.feedbackLayer=null,this.isMouseDown=!1,this.startX=0,this.startY=0,this.lastX=0,this.lastY=0,this.unique_id=0,this.moveAction=new YCEditorMoveAction(this),this.selectionAction=new YCEditorSelectionAction(this),this.currentAction=null,this.selectedTool=null,this.currentSelection=[],this.selectedBackground="",this.selectedBackgroundSvg="",this.selectedBackgroundColor="",this.selectedBackgroundFigureScale=1,this.selectedBackgroundScale=1,this.selectedBackgroundBaseScale=1,this.selectedBackgroundPosition=[0,0],this.selectedColorField="#3B9CCC",this.selectedColorFieldAreas="#277EA0",this.selectedColorFieldBorder="#FF9F48",this.toolbar=null,this.clipBoard=[],this.fullscreenPlaceHolder=null,this.init(t,e)};YCEditor.prototype.DEFAULTS={locale:"en",mode:"editor",resizable:!0,initialAnimation:!0,resourcesUrl:"",uselocal:!1,tld:"it",autoplay:!1,loop:!1,slowMotion:1,onModelChange:function(){}},YCEditor.prototype.plugins=[],YCEditor.prototype.viewerPlugins=[],YCEditor.prototype.init=function(t,e){this.$mainElement=$(t),this.options=$.extend({},this.DEFAULTS),void 0!==e&&"object"==typeof e&&(this.options=$.extend(this.options,this.$mainElement.data(),e)),void 0!==this.options.team_players&&null!==this.options.team_players&&this.options.team_players.length>0&&this.palette_categories.unshift({label:"Team Players",options:[{name:"team_players",label:"Team Players"}]}),this.initAnimator(),this.createMainUI(this.$mainElement,this.options);var n=this;this.zoom=1,this.recalculateDesignArea(!1),this.originalWidth=800,this.originalHeight=600;this.$element.width(),this.$element.height();if(this.adjustZoom(),this.shapeCounter=1,this.initSVG(),this.options.resizable&&this.$mainElement.resizable({handles:{se:$(".grips",n.$mainElement)},minHeight:300,minWidth:500}),this.$mainElement.on("resize",function(){n.$mainElement.is(":visible")&&n.recalculateDesignArea(!0)}),"viewer"!=this.options.mode){this.setupTools(),this.setupPalette(),this.setupPropertiesPanel(),this.undoRedo=[],this.$element.on("mouseup touchend",function(t){n.mouseUp(t)}),$(this.background[0]).on("mousedown touchstart",function(t){n.mouseDown(t,null)}),this.$element.attr("tabindex","1"),this.$element.focus(),this.setupKeyBinding(),this.$element.on("mousemove touchmove",function(t){n.mouseMove(t)}),this.updateUndoRedoButtons(),this.recalculateDesignArea(!1),this.pluginCallbacks=[];for(i=0;i<this.plugins.length;++i){"object"==typeof(r=this.plugins[i](this))&&(this.pluginCallbacks.push(r),"function"==typeof r.initEditor&&r.initEditor(this))}}else{this.recalculateDesignArea(!1),1==this.options.autoplay&&setTimeout(function(){n.playAnimation(n.options.loop)},1e3),this.pluginCallbacks=[];for(var i=0;i<this.viewerPlugins.length;++i){var r;"object"==typeof(r=this.viewerPlugins[i](this))&&(this.pluginCallbacks.push(r),"function"==typeof r.initViewer&&r.initViewer(this))}}},YCEditor.prototype.initSVG=function(){var t=this,e=d3.select(this.$element[0]).append("svg");e.attr("width","100%").attr("height","100%").attr("viewBox","0 0 "+this.originalWidth+" "+this.originalHeight).attr("preserveAspectRatio","xMidYMid meet").attr("class","drill-editor-svg"),this.defs=e.append("svg:defs"),this.background=e.append("rect").attr("id","de-background-back").attr("x",0).attr("y",0).attr("width",this.originalWidth).attr("height",this.originalHeight).attr("fill","#000000"),this.background=e.append("rect").attr("id","de-background").attr("x",0).attr("y",0).attr("width",this.originalWidth).attr("height",this.originalHeight).attr("opacity","0"),this.setBackgroundImage(this.background,"images/fields/field0.jpg",this.options.initialAnimation),this.backgroundLayer=e.append("g").attr("class","background-layer");var n=$('<?xml version="1.0" encoding="UTF-8" standalone="no"?><svg id="yceditor_yclogo" width="820" height="180" viewBox="0 0 820 180" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;"><path d="M651.154,78.042C653.984,74.938 657.414,72.421 661.431,70.504C665.546,68.679 669.837,67.766 674.317,67.766C677.147,67.766 679.893,68.176 682.54,68.998C683.817,69.454 685.096,69.957 686.381,70.504C687.659,71.052 688.891,71.691 690.084,72.421C691.27,73.152 692.367,73.928 693.371,74.749C694.467,75.571 695.516,76.484 696.52,77.488C696.977,77.945 697.434,78.447 697.889,78.994L699.26,80.364C699.99,81.277 700.949,81.916 702.141,82.281C703.42,82.555 704.562,82.463 705.566,82.007L715.712,77.892C716.806,77.436 717.538,76.751 717.902,75.838C718.267,74.834 718.13,73.83 717.493,72.826C715.849,70.361 713.886,67.935 711.597,65.562C710.045,64.009 708.357,62.549 706.523,61.173C704.789,59.712 702.912,58.389 700.902,57.195C697.068,54.913 692.862,53.126 688.291,51.848C683.628,50.57 678.973,49.931 674.31,49.931C667.183,49.931 660.466,51.3 654.16,54.046C647.947,56.784 642.416,60.488 637.578,65.144C632.915,69.989 629.219,75.512 626.473,81.727C623.735,88.032 622.358,94.749 622.358,101.876C622.358,109.003 623.729,115.72 626.473,122.025C629.212,128.331 632.915,133.815 637.578,138.471C642.332,143.225 647.855,146.968 654.16,149.713C660.466,152.452 667.183,153.828 674.31,153.828C678.973,153.828 683.628,153.189 688.291,151.91C690.573,151.271 692.77,150.495 694.871,149.582C696.971,148.67 698.986,147.62 700.902,146.433C705.017,144.059 708.578,141.268 711.591,138.073C712.685,136.978 713.697,135.836 714.609,134.65C715.613,133.372 716.572,132.093 717.484,130.809C718.124,129.805 718.261,128.801 717.896,127.796C717.531,126.792 716.8,126.062 715.706,125.605L705.558,121.491C704.553,121.034 703.412,120.989 702.135,121.354C700.949,121.719 699.99,122.358 699.252,123.271C698.797,123.727 698.34,124.229 697.883,124.777L696.514,126.147C695.51,127.151 694.461,128.109 693.365,129.022C692.36,129.844 691.264,130.62 690.078,131.35C688.891,132.081 687.659,132.72 686.374,133.267C685.096,133.815 683.817,134.317 682.534,134.774C679.887,135.595 677.141,136.006 674.31,136.006C669.648,136.006 665.357,135.048 661.425,133.13C657.402,131.396 653.978,128.925 651.148,125.729C648.228,122.534 645.891,118.921 644.158,114.905C642.424,110.881 641.555,106.545 641.555,101.882C641.555,97.22 642.424,92.975 644.158,88.86C645.891,84.837 648.228,81.231 651.148,78.036L651.154,78.042ZM515.417,106.306L507.226,109.593C506.802,109.762 506.326,109.514 506.222,109.071L501.378,88.895C501.337,88.745 501.351,88.589 501.408,88.445L507.865,72.372C507.956,72.137 507.931,71.876 507.788,71.667C503.999,66.105 499.16,61.312 493.551,57.582C493.39,57.472 493.187,57.432 492.998,57.472L474.374,60.849C474.217,60.876 474.061,60.849 473.917,60.784L452.568,50.488C452.41,50.41 452.228,50.39 452.052,50.436C447.435,51.583 443.066,53.357 439.037,55.646C438.81,55.776 438.666,56.024 438.658,56.291L438.398,71.759C438.398,71.935 438.332,72.098 438.221,72.228L424.743,88.067C424.508,88.348 424.104,88.413 423.79,88.224L416.487,83.848C416.083,83.607 415.548,83.796 415.393,84.246C413.612,89.489 412.653,95.103 412.653,100.953C412.653,109.032 414.493,116.681 417.778,123.502C418.092,124.147 419.038,124.03 419.188,123.332L421.743,111.288C421.836,110.845 422.299,110.584 422.729,110.74L441.201,117.391C441.437,117.476 441.613,117.665 441.672,117.907L446.654,137.124C446.75,137.495 446.55,137.88 446.191,138.01L434.91,142.203C434.342,142.412 434.25,143.168 434.746,143.521C443.224,149.5 453.566,153.015 464.729,153.015C467.364,153.015 469.958,152.819 472.489,152.434C473.051,152.35 473.311,151.685 472.958,151.235L464.038,139.817C463.802,139.51 463.835,139.08 464.116,138.812L480.889,122.993C481.045,122.843 481.254,122.771 481.469,122.791L496.513,124.167C496.89,124.199 497.185,124.519 497.191,124.903L497.386,139.914C497.392,140.553 498.142,140.879 498.625,140.469C508.296,132.174 514.888,120.391 516.446,107.076C516.511,106.515 515.944,106.091 515.423,106.3L515.417,106.306ZM180.516,64.048C175.853,59.295 170.376,55.552 164.07,52.813C157.764,50.074 151.002,48.698 143.784,48.698C136.565,48.698 129.94,50.068 123.634,52.813C117.328,55.552 111.799,59.301 107.051,64.048C102.389,68.711 98.692,74.234 95.946,80.631C93.208,86.936 91.832,93.653 91.832,100.78C91.832,107.908 93.201,114.761 95.946,121.066C98.685,127.372 102.389,132.902 107.051,137.649C111.805,142.311 117.328,146.009 123.634,148.754C129.94,151.493 136.656,152.869 143.784,152.869C150.911,152.869 157.764,151.499 164.07,148.754C170.376,146.015 175.86,142.311 180.516,137.649C185.27,132.895 189.013,127.372 191.758,121.066C194.497,114.761 195.873,107.999 195.873,100.78C195.873,93.562 194.503,86.936 191.758,80.631C189.013,74.234 185.27,68.704 180.516,64.048ZM338.275,77.059C341.105,73.955 344.535,71.438 348.552,69.521C352.667,67.695 356.958,66.782 361.438,66.782C364.268,66.782 367.014,67.193 369.659,68.015C370.938,68.471 372.217,68.973 373.502,69.521C374.778,70.069 376.012,70.708 377.205,71.438C378.391,72.169 379.488,72.945 380.492,73.766C381.586,74.588 382.637,75.501 383.641,76.505C384.098,76.961 384.553,77.463 385.01,78.011L386.379,79.381C387.111,80.294 388.068,80.933 389.263,81.298C390.539,81.572 391.681,81.48 392.693,81.024L402.833,76.909C403.927,76.453 404.659,75.768 405.023,74.855C405.388,73.851 405.251,72.847 404.611,71.843C402.97,69.378 401.007,66.952 398.718,64.578C397.164,63.026 395.47,61.566 393.644,60.19C391.91,58.729 390.031,57.406 388.023,56.219C384.182,53.936 379.983,52.15 375.412,50.872C370.749,49.594 366.094,48.954 361.432,48.954C354.304,48.954 347.587,50.324 341.281,53.069C335.068,55.808 329.537,59.512 324.699,64.167C320.036,69.013 316.34,74.536 313.6,80.75C310.862,87.056 309.485,93.772 309.485,100.899C309.485,108.027 310.856,114.743 313.6,121.049C316.346,127.354 320.043,132.838 324.699,137.494C329.453,142.248 334.976,145.991 341.281,148.736C347.587,151.475 354.304,152.851 361.432,152.851C366.094,152.851 370.749,152.212 375.412,150.934C377.694,150.295 379.891,149.519 381.992,148.606C384.09,147.693 386.107,146.643 388.023,145.456C392.138,143.083 395.699,140.292 398.718,137.097C399.812,136.001 400.816,134.86 401.73,133.673C402.734,132.395 403.693,131.117 404.605,129.832C405.245,128.828 405.382,127.824 405.017,126.82C404.65,125.816 403.921,125.085 402.827,124.629L392.685,120.514C391.681,120.058 390.539,120.012 389.256,120.377C388.068,120.742 387.111,121.381 386.373,122.294C385.916,122.751 385.461,123.253 385.004,123.801L383.635,125.17C382.631,126.174 381.58,127.133 380.486,128.046C379.481,128.867 378.385,129.643 377.199,130.374C376.012,131.104 374.778,131.743 373.496,132.291C372.217,132.838 370.938,133.341 369.653,133.797C367.005,134.619 364.262,135.029 361.432,135.029C356.769,135.029 352.478,134.071 348.546,132.154C344.523,130.419 341.099,127.948 338.269,124.753C335.346,121.557 333.012,117.945 331.279,113.928C329.543,109.905 328.676,105.568 328.676,100.906C328.676,96.244 329.543,91.998 331.279,87.884C333.012,83.86 335.346,80.254 338.269,77.059L338.275,77.059ZM290.744,50.732L280.049,50.732C278.863,50.732 277.859,51.142 277.037,51.964C276.215,52.786 275.805,53.79 275.805,54.977L275.805,110.351C275.805,115.379 274.983,119.533 273.34,122.826C271.696,126.112 269.637,128.721 267.172,130.638C264.799,132.646 262.19,133.97 259.36,134.616C256.438,135.346 253.966,135.711 251.958,135.711C250.862,135.711 249.675,135.62 248.398,135.437C247.21,135.255 245.888,134.981 244.421,134.616C241.773,133.977 239.164,132.653 236.607,130.638C234.234,128.629 232.22,126.021 230.576,122.826C228.932,119.539 228.111,115.379 228.111,110.351L228.111,54.977C228.111,53.79 227.701,52.786 226.879,51.964C226.057,51.142 225.053,50.732 223.867,50.732L213.034,50.732C211.94,50.732 210.981,51.142 210.159,51.964C209.337,52.786 208.928,53.79 208.928,54.977L208.928,110.489C208.928,116.977 209.932,122.78 211.94,127.893C213.948,133.103 216.875,137.53 220.711,141.189C224.27,144.755 228.795,147.585 234.279,149.685C239.398,151.694 245.294,152.698 251.958,152.698C258.622,152.698 264.569,151.694 269.772,149.685C275.166,147.585 279.684,144.749 283.342,141.189C287.086,137.439 289.968,133.011 291.976,127.893C292.98,125.245 293.712,122.5 294.169,119.67C294.716,116.748 294.99,113.684 294.99,110.489L294.99,54.977C294.99,53.79 294.578,52.786 293.757,51.964C292.935,51.142 291.931,50.732 290.744,50.732ZM578.395,53.223C577.846,52.128 576.934,51.58 575.655,51.58C574.378,51.58 573.464,52.128 572.917,53.223L525.36,148.206C524.903,149.21 524.858,150.077 525.223,150.808C525.68,151.538 526.501,151.903 527.688,151.903L540.162,151.903C541.348,151.903 542.49,151.538 543.592,150.808C544.779,150.077 545.646,149.164 546.195,148.069L550.172,139.983C550.627,138.888 551.449,137.975 552.638,137.244C553.824,136.514 555.011,136.149 556.197,136.149L595.121,136.149C596.307,136.149 597.449,136.514 598.543,137.244C599.73,137.975 600.599,138.842 601.152,139.846L605.267,148.069C605.724,149.164 606.546,150.077 607.732,150.808C608.919,151.538 610.105,151.903 611.292,151.903L623.768,151.903C624.954,151.903 625.729,151.538 626.096,150.808C626.55,150.077 626.505,149.21 625.958,148.206L578.395,53.223ZM816.453,52.813C815.632,51.991 814.627,51.58 813.439,51.58L802.746,51.58C801.559,51.58 800.555,51.991 799.733,52.813C798.912,53.634 798.5,54.638 798.5,55.825L798.5,90.777C798.5,91.964 798.09,92.968 797.268,93.789C796.446,94.611 795.442,95.022 794.256,95.022L753.279,95.022C752.092,95.022 751.086,94.611 750.266,93.789C749.445,92.968 749.033,91.964 749.033,90.777L749.033,55.825C749.033,54.638 748.623,53.634 747.801,52.813C746.979,51.991 745.975,51.58 744.789,51.58L734.1,51.58C732.913,51.58 731.909,51.991 731.087,52.813C730.266,53.634 729.856,54.638 729.856,55.825L729.856,147.651C729.856,148.838 730.266,149.843 731.087,150.664C731.909,151.486 732.913,151.897 734.1,151.897L744.789,151.897C745.975,151.897 746.979,151.486 747.801,150.664C748.623,149.843 749.033,148.838 749.033,147.651L749.033,116.267C749.033,115.08 749.445,114.076 750.266,113.254C751.086,112.432 752.092,112.022 753.279,112.022L794.256,112.022C795.442,112.022 796.446,112.432 797.268,113.254C798.09,114.076 798.5,115.08 798.5,116.267L798.5,147.651C798.5,148.838 798.912,149.843 799.733,150.664C800.555,151.486 801.559,151.897 802.746,151.897L813.439,151.897C814.627,151.897 815.632,151.486 816.453,150.664C817.275,149.843 817.685,148.838 817.685,147.651L817.685,55.832C817.685,54.645 817.275,53.641 816.453,52.819L816.453,52.813ZM94.342,51.834C93.976,51.103 93.2,50.738 92.014,50.738L78.033,50.738C76.846,50.738 75.613,51.103 74.335,51.834C73.149,52.473 72.281,53.294 71.734,54.298L69.816,57.585C69.177,58.68 68.493,59.776 67.762,60.871L64.476,66.355C63.472,68.181 62.422,70.014 61.326,71.84L54.747,82.938C54.016,84.125 53.286,85.266 52.556,86.361L50.638,89.648C50,90.652 49.223,91.154 48.311,91.154C47.489,91.154 46.804,90.652 46.256,89.648L41.046,80.877C39.312,77.956 37.577,74.982 35.836,71.97C34.01,68.957 32.23,65.984 30.489,63.063L25.279,54.292C24.731,53.288 23.818,52.466 22.54,51.827C21.353,51.097 20.166,50.732 18.98,50.732L4.979,50.732C3.792,50.732 2.971,51.097 2.514,51.827C2.149,52.466 2.286,53.288 2.925,54.292C5.573,58.954 8.318,63.565 11.148,68.136C13.978,72.616 16.906,77.18 19.919,81.843C22.84,86.414 25.676,90.978 28.415,95.549C31.245,100.029 33.991,104.594 36.638,109.256C37.277,110.26 37.779,111.538 38.144,113.097C38.601,114.649 38.829,116.018 38.829,117.212L38.829,146.679C38.829,147.866 39.194,148.87 39.925,149.692C40.746,150.513 41.75,150.924 42.937,150.924L53.762,150.924C54.949,150.924 55.953,150.513 56.775,149.692C57.596,148.87 58.007,147.866 58.007,146.679L58.007,117.212C58.007,116.025 58.19,114.655 58.555,113.097C58.92,111.538 59.422,110.267 60.061,109.256C61.065,107.521 62.115,105.741 63.211,103.909C64.398,102.083 65.63,100.159 66.908,98.151C68.551,95.504 70.195,92.804 71.844,90.065C73.579,87.235 75.366,84.399 77.192,81.569C78.926,78.739 80.615,75.948 82.265,73.209C83.999,70.47 85.688,67.77 87.338,65.123C88.616,63.115 89.803,61.237 90.905,59.502C92.001,57.676 93.05,55.942 94.055,54.292C94.602,53.288 94.694,52.466 94.328,51.827L94.342,51.834ZM174.073,113.796C172.339,117.91 169.958,121.562 166.946,124.757C164.024,127.861 160.549,130.378 156.532,132.295C152.6,134.121 148.355,135.034 143.784,135.034C139.212,135.034 134.922,134.121 130.898,132.295C126.966,130.378 123.497,127.861 120.484,124.757C117.563,121.562 115.229,117.904 113.494,113.796C111.759,109.688 110.892,105.345 110.892,100.774C110.892,96.203 111.759,92.003 113.494,87.888C115.229,83.683 117.563,80.031 120.484,76.927C123.497,73.823 126.973,71.352 130.898,69.526C134.922,67.609 139.212,66.65 143.784,66.65C148.355,66.65 152.6,67.609 156.532,69.526C160.555,71.352 164.024,73.823 166.946,76.927C169.958,80.031 172.339,83.689 174.073,87.888C175.808,92.003 176.675,96.294 176.675,100.774C176.675,105.254 175.808,109.681 174.073,113.796ZM588.131,118.327C587.764,119.058 586.989,119.423 585.803,119.423L565.515,119.423C564.329,119.423 563.507,119.058 563.05,118.327C562.595,117.597 562.595,116.684 563.05,115.589L573.882,92.974C574.337,91.879 574.932,91.331 575.661,91.331C576.393,91.331 576.985,91.879 577.442,92.974L588.131,115.589C588.586,116.593 588.586,117.506 588.131,118.327ZM525.516,116.812C527.225,113.695 528.614,110.487 529.762,106.998C538.186,81.463 529.559,53.821 508.294,38.21C493.967,27.692 476.577,23.89 459.329,27.503C442.322,31.07 427.586,41.731 418.874,56.808C418.528,57.407 418.684,58.131 419.251,58.529C419.819,58.927 420.563,58.836 421.012,58.307C439.623,36.391 471.229,30.946 496.172,45.363C520.534,59.442 531.77,89.014 522.895,115.665C522.653,116.388 522.987,117.132 523.684,117.438C523.878,117.523 524.075,117.562 524.27,117.562C524.772,117.562 525.249,117.288 525.51,116.812L525.516,116.812ZM489.553,90.715L478.313,110.088C478.155,110.362 477.836,110.506 477.524,110.434L454.923,105.276C454.622,105.204 454.4,104.956 454.361,104.656L451.785,83.692C451.747,83.372 451.923,83.066 452.216,82.935L473.141,73.63C473.422,73.506 473.747,73.572 473.963,73.793L489.443,89.848C489.672,90.082 489.717,90.434 489.553,90.715Z" style="fill:white;fill-rule:nonzero;"/></svg>'),i="translate(300,250) scale(0.25)",r="translate(200,250) scale(0.50)",o="translate(100,250) scale(0.75)";function a(t,e){return d3.interpolateString(i,o)}function s(t,e){return d3.interpolateString(o,r)}this.options.initialAnimation||(i=r),"viewer"!==this.options.mode&&(this.logoLayer=e.append("g").attr("class","logo-layer").attr("transform",i).attr("opacity",this.options.initialAnimation?0:.1),$(this.logoLayer.node()).append(n),$(this.logoLayer.node()).find("#url_value").text("www.youcoach."+this.options.tld),this.options.initialAnimation&&(t.logoLayer.transition().duration(2e3).ease("elastic").attr("opacity",1).attrTween("transform",a).transition().duration(2e3).ease("cubic-in-out").attrTween("transform",s).attr("opacity",.2),setTimeout(function(){t.updateLogoPosition()},4100))),this.backSelectionLayer=e.append("g").attr("class","back-selection-layer"),this.elementsLayer=e.append("g").attr("class","elements-layer"),this.selectionLayer=e.append("g").attr("class","selection-layer"),this.feedbackLayer=e.append("g").attr("class","feedback-layer"),this.options.initialAnimation&&(this.backSelectionLayer.attr("opacity",0),this.elementsLayer.attr("opacity",0),this.selectionLayer.attr("opacity",0),this.feedbackLayer.attr("opacity",0),setTimeout(function(){t.backSelectionLayer.transition().duration(500).attr("opacity",1),t.elementsLayer.transition().duration(500).attr("opacity",1),t.selectionLayer.transition().duration(500).attr("opacity",1),t.feedbackLayer.transition().duration(500).attr("opacity",1)},3500)),"viewer"===this.options.mode&&(this.logoLayer=e.append("g").attr("class","logo-layer").attr("transform",i).attr("opacity",this.options.initialAnimation?0:.25),$(this.logoLayer.node()).append(n),$(this.logoLayer.node()).find("#url_value").text("www.youcoach."+this.options.tld),this.options.initialAnimation?(t.logoLayer.transition().duration(2e3).ease("elastic").attr("opacity",1).attrTween("transform",a).transition().duration(2e3).ease("cubic-in-out").attrTween("transform",s).attr("opacity",.25),setTimeout(function(){t.updateLogoPosition()},2100)):t.updateLogoPosition(!1))},YCEditor.prototype.getUniqueId=function(){return this.unique_id++,this.unique_id},YCEditor.prototype.updateLogoPosition=function(t){void 0===t&&(t=!0);finalTransform=this.calculateLogoPosition(this.selectedLogoPosition);var e=this.logoLayer.attr("transform");t?this.logoLayer.transition().duration(500).ease("cubic-in-out").attrTween("transform",function(t,n){return d3.interpolateString(e,finalTransform)}):this.logoLayer.attr("transform",finalTransform)},YCEditor.prototype.calculateLogoPosition=function(t){switch(t){case"top_left":return"translate(20,20) scale(0.25)";case"top_right":return"translate(575,20) scale(0.25)";case"bottom_left":return"translate(20,540) scale(0.25)";case"bottom_right":return"translate(575,540) scale(0.25)";default:return"translate(200,250) scale(0.5)"}},YCEditor.prototype.recalculateDesignArea=function(t){void 0===t&&(t=!0);var e=parseFloat(this.$mainElement.width()),n=parseFloat(this.$mainElement.height()),i=n,r=0;"viewer"!==this.options.mode&&(n-=40,i-=40,this.timelineVisible&&(i-=72),e-=r=parseFloat($(".sidebar",this.$mainElement).width()));var o=e,a=i;e/4>i/3?e=i*(4/3):i=e/(4/3);var s=(a-i)/2;if(this.$element.css({top:s,width:e,height:i,"margin-left":(o-e)/2+r}),"viewer"!==this.options.mode){$(".sidebar .properties",this.$mainElement).outerHeight(),$(".sidebar .sbHolder",this.$mainElement).outerHeight(),$(".sidebar .direction-selector").is(":visible")&&$(".sidebar .direction-selector",this.$mainElement).outerHeight();$.each(this.currentSelection,function(t){this.unselect(),this.select()})}if(t){this.adjustZoom();for(var l=0;l<this.currentSelection.length;++l)this.currentSelection[l].updateSelectionShape()}},YCEditor.prototype.adjustZoom=function(){var t=parseFloat(this.$element.width())/parseFloat(this.originalWidth),e=parseFloat(this.$element.height())/parseFloat(this.originalHeight);this.zoom=Math.min(t,e)},YCEditor.prototype.getSelectionShapeStrokeColor=function(){return""!=this.selectedBackgroundColor?function(t){if(void 0===t||null===t||t.length<7)return"#1388d8";var e=t;return e=e.substring(1),e=parseInt(e,16),e="#"+(e=("000000"+(e=(e^=16777215).toString(16))).slice(-6))}(this.selectedBackgroundColor):"#1388d8"},YCEditor.prototype.loadShape=function(t){if("circle"===t.type){var e=new YCCircle(t);return e.create(this),e}if("path"===t.type){var n=new YCPath(t);return n.create(this),n}var i;return"figure"===t.type?((i=new YCFigure(t)).create(this),i):"disc"===t.type?((i=new YCDisc(t)).create(this),i):"text"===t.type?((i=new YCText(t)).create(this),i):"polygon"===t.type?((i=new YCPolygon(t)).create(this),i):"ellipse"===t.type?((i=new YCEllipse(t)).create(this),i):"line"===t.type?((i=new YCLine(t)).create(this),i):"team_player"===t.type?((i=new YCTeamPlayer(t)).create(this),i):null},YCEditor.prototype.deleteSelectedElements=function(){for(var t=this,e=[];this.currentSelection.length>0;){var n=this.currentSelection[0],i=this.removeElement(n);e.push({element:n,position:i})}return this.appendUndo({undo:function(){for(var n=0;n<e.length;++n)t.addElementAt(e[n].element,e[n].position)},redo:function(){for(var n=0;n<e.length;++n)t.removeElement(e[n].element)},name:function(){return"Delete element(s)"}}),null},YCEditor.prototype.moveUpElements=function(){var t=this,e=[],n=this.currentSelection.slice(0),i=this.currentSelection.slice(0);n.sort(function(e,n){return t.findElementIndex(e)<t.findElementIndex(e)?-1:t.findElementIndex(e)>t.findElementIndex(e)?1:0});for(var r=n.length-1;r>=0;--r)e.push({element:n[r],oldIndex:t.findElementIndex(n[r])}),t.removeElement(n[r]),t.addElement(n[r]);var o={undo:function(){for(var n=0;n<e.length;++n)t.removeElement(e[n].element),t.addElementAt(e[n].element,e[n].oldIndex)},redo:function(){for(var n=e.length-1;n>=0;--n)t.removeElement(e[n].element),t.addElement(e[n].element)},name:function(){return t.t("Move Up")}};this.appendUndo(o),this.setSelection(i)},YCEditor.prototype.moveDownElements=function(){var t=this,e=[],n=this.currentSelection.slice(0),i=this.currentSelection.slice(0);n.sort(function(e,n){return t.findElementIndex(e)<t.findElementIndex(e)?-1:t.findElementIndex(e)>t.findElementIndex(e)?1:0});for(var r=0;r<n.length;++r)e.push({element:n[r],oldIndex:t.findElementIndex(n[r])}),t.removeElement(n[r]),t.addElementAt(n[r],0);var o={undo:function(){for(var n=e.length-1;n>=0;--n)t.removeElement(e[n].element),t.addElementAt(e[n].element,e[n].oldIndex)},redo:function(){for(var n=0;n<e.length;++n)t.removeElement(e[n].element),t.addElementAt(e[n].element,0)},name:function(){return t.t("Move Down")}};this.appendUndo(o),this.setSelection(i)},YCEditor.prototype.addElement=function(t){return this.addElementAt(t,this.elements.length)},YCEditor.prototype.removeElement=function(t){"string"==typeof t&&(t=this.findElement(t)),this.removeSelection(t);var e=this.findElementIndex(t);return this.elements.splice(e,1),$(t.figure.node()).detach(),e},YCEditor.prototype.addElementAt=function(t,e){return this.findElementIndex(t.id)>=0?-1:(this.elements.splice(e,0,t),0==$(t.figure.node()).parent().length&&(0===e?$(this.elementsLayer.node()).prepend(t.figure.node()):$(this.elementsLayer.node()).children("g").eq(e-1).after(t.figure.node())),e)},YCEditor.prototype.getZoomFactor=function(){return parseFloat(this.originalWidth)/this.originalHeight*this.zoom},YCEditor.prototype.getSelection=function(){return this.currentSelection},YCEditor.prototype.setSelection=function(t){this.selectionChanging();for(var e=0;e<this.currentSelection.length;++e)this.currentSelection[e].unselect();this.currentSelection=t;for(e=0;e<this.currentSelection.length;++e)this.currentSelection[e].select();this.selectionChanged()},YCEditor.prototype.addSelection=function(t){this.selectionChanging(),this.currentSelection.unshift(t),t.select(),this.selectionChanged()},YCEditor.prototype.removeSelection=function(t){var e=this;this.selectionChanging(),$.each(this.currentSelection,function(n){if(e.currentSelection[n]===t)return e.currentSelection.splice(n,1),t.unselect(),!1}),this.selectionChanged()},YCEditor.prototype.selectionChanging=function(){$(".property-text textarea",this.$mainElement).is(":focus")&&$(".property-text textarea",this.$mainElement).blur(),$(".property-color input",this.$mainElement).spectrum("container").hasClass("sp-hidden")||$(".property-color input",this.$mainElement).spectrum("hide"),$(".property-color2 input",this.$mainElement).spectrum("container").hasClass("sp-hidden")||$(".property-color2 input",this.$mainElement).spectrum("hide"),$(".property-skin input",this.$mainElement).YCSkinChooser("container").hasClass("ycse-panel-open")&&$(".property-skin input",this.$mainElement).YCSkinChooser("hide"),$(".property-uniform input",this.$mainElement).YCUniformChooser("container").hasClass("ycue-panel-open")&&$(".property-uniform input",this.$mainElement).YCUniformChooser("hide")},YCEditor.prototype.selectionChanged=function(){var t=this.toolbar;this.currentSelection.length<=0?($(".trash-tool",t).addClass("disabled"),$(".move-up-tool",t).addClass("disabled"),$(".move-down-tool",t).addClass("disabled"),$(".editor-cut",t).addClass("disabled"),$(".editor-copy",t).addClass("disabled")):($(".trash-tool",t).removeClass("disabled"),$(".move-up-tool",t).removeClass("disabled"),$(".move-down-tool",t).removeClass("disabled"),$(".editor-cut",t).removeClass("disabled"),$(".editor-copy",t).removeClass("disabled"),this.$mainElement.find(".designer-area").focus()),this.updatePropertiesPanel(),this.recalculateDesignArea(!1),this.updateTimeline()},YCEditor.prototype.doCutElements=function(){this.doCopyElements(),this.deleteSelectedElements(),this.clipBoardOp="cut"},YCEditor.prototype.doCopyElements=function(){var t=this;this.currentSelection.length<=0||(this.clipBoard=[],$.each(this.currentSelection,function(e){t.clipBoard.push(t.currentSelection[e].toModel())}),this.clipBoardOp="copy",this.clipBoard.length>0?$(".editor-paste",this.toolbar).removeClass("disabled"):$(".editor-paste",this.toolbar).addClass("disabled"))},YCEditor.prototype.doPasteElements=function(){var t=this;this.setSelection([]),$.each(this.clipBoard,function(e){var n=t.loadShape($.extend(!0,{},t.clipBoard[e]));t.addElement(n);var i=0,r=function(){10!=i&&(i++,void 0!==n.figure&&void 0!==n.figure.node?("copy"===t.clipBoardOp&&n.move(10,10),t.addSelection(n)):r())};setTimeout(r,250)})},YCEditor.prototype.pauseEvent=function(t){return t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),t.cancelBubble=!0,t.returnValue=!1,!1},YCEditor.prototype.mouseUp=function(t){"viewer"!==this.options.mode&&(t=t||window.event,this.pauseEvent(t),t=this.touchHandlerEventTransform(t),this.isMouseDown&&(this.isMouseDown=!1,null!==this.currentAction&&this.currentAction.endMove(t),this.currentAction=null),this.$element.find("svg").attr("class",""))},YCEditor.prototype.mouseDown=function(t,e){if("viewer"!==this.options.mode){if(t=t||window.event,this.pauseEvent(t),t=this.touchHandlerEventTransform(t),this.currentAction=null,this.$element.focus(),this.isMouseDown=!0,this.lastX=this.startX=t.pageX,this.lastY=this.startY=t.pageY,null===e){$(".editor-handler",this.$element).each(function(){var n=$(this)[0].getBoundingClientRect();t.pageX<n.right+10&&t.pageX>n.left-10&&t.pageY>n.top-10&&t.pageY<n.bottom+10&&(e=$(this).data("handle-elemet"))})}null!==this.selectedTool?this.currentAction=this.selectedTool:null===e?(t.shiftKey||this.setSelection([]),this.currentAction=this.selectionAction):e instanceof YCHandle?(this.$element.find("svg").attr("class",e.getCursorClass()),this.movingHandle=e,this.currentAction=this.movingHandle):(this.currentAction=this.moveAction,null!==e.selectionShape?t.shiftKey&&this.removeSelection(e):t.shiftKey?this.addSelection(e):this.setSelection([e])),null!==this.currentAction&&this.currentAction.startMove(e,t)}},YCEditor.prototype.mouseMove=function(t){if(t=this.touchHandlerEventTransform(t),this.isMouseDown){var e=t.pageX-parseFloat(this.lastX),n=t.pageY-parseFloat(this.lastY),i=this.lastX,r=this.lastY;this.lastX=t.pageX,this.lastY=t.pageY;var o=(this.lastX-this.startX)/this.zoom,a=(this.lastY-this.startY)/this.zoom,s=t.pageX-this.$element.offset().left,l=t.pageY-this.$element.offset().top,c={dx:parseFloat(e),dy:parseFloat(n),totalx:o,totaly:a,x:s,y:l,mouseEvent:t};null!==this.currentAction&&(this.currentAction.handleMove(c),this.lastX=i+c.dx,this.lastY=r+c.dy)}},YCEditor.prototype.fireModelChange=function(){this.options.onModelChange(this)},YCEditor.prototype.appendUndo=function(t){t.atKeyFrameTime=this.timeline.currentKeyFrameTime,this.undoRedoStack=this.undoRedoStack.slice(0,this.undoRedoStackIndex),this.undoRedoStack.push(t),this.undoRedoStackIndex++,this.updateUndoRedoButtons(),this.fireModelChange()},YCEditor.prototype.doUndo=function(){if(this.undoRedoStackIndex>0){var t=this.undoRedoStack[this.undoRedoStackIndex-1];this.setCurrentKeyFrameTime(t.atKeyFrameTime),t.undo(),this.undoRedoStackIndex--}this.updateUndoRedoButtons(),this.fireModelChange()},YCEditor.prototype.doRedo=function(){if(this.undoRedoStackIndex>=0&&this.undoRedoStackIndex<this.undoRedoStack.length){var t=this.undoRedoStack[this.undoRedoStackIndex];this.setCurrentKeyFrameTime(t.atKeyFrameTime),t.redo(),this.undoRedoStackIndex++}this.updateUndoRedoButtons(),this.fireModelChange()},YCEditor.prototype.updateUndoRedoButtons=function(){this.undoRedoStackIndex>0?$(".editorUndo",this.$mainElement).removeClass("disabled").attr("title","Undo "+this.undoRedoStack[this.undoRedoStackIndex-1].name()):$(".editorUndo",this.$mainElement).addClass("disabled").attr("title",""),this.undoRedoStackIndex>=0&&this.undoRedoStackIndex<this.undoRedoStack.length?$(".editorRedo",this.$mainElement).removeClass("disabled").attr("title","Redo "+this.undoRedoStack[this.undoRedoStackIndex].name()):$(".editorRedo",this.$mainElement).addClass("disabled").attr("title","")},YCEditor.prototype.findElement=function(t){if((t=""+t)===this.id)return this;for(var e=0;e<this.elements.length;++e)if(this.elements[e].id===t)return this.elements[e];return null},YCEditor.prototype.findElementIndex=function(t){var e="";e="object"!=typeof t||void 0===t.id?""+t:t.id;for(var n=0;n<this.elements.length;++n)if(this.elements[n].id===e)return n;return-1},YCEditor.prototype.setSelectedTool=function(t,e,n){null!==t&&void 0!==e||(e=""),null!==t&&void 0!==n||(n=".selection-tool"),this.$mainElement.find(".designer-tool").removeClass("selected"),this.$element.css("cursor",e),this.selectedTool=t,this.$mainElement.find(n).addClass("selected")},YCEditor.prototype.transformedBoundingBox=function(t){var e=t.getBBox(),n=t.ownerSVGElement,i=t.getTransformToElement(t.parentNode),r=[n.createSVGPoint(),n.createSVGPoint(),n.createSVGPoint(),n.createSVGPoint()];r[0].x=e.x,r[0].y=e.y,r[1].x=e.x+e.width,r[1].y=e.y,r[2].x=e.x+e.width,r[2].y=e.y+e.height,r[3].x=e.x,r[3].y=e.y+e.height;var o=1/0,a=-1/0,s=1/0,l=-1/0;return r.forEach(function(t){t=t.matrixTransform(i),o=Math.min(o,t.x),a=Math.max(a,t.x),s=Math.min(s,t.y),l=Math.max(l,t.y)}),{x:o,y:s,width:a-o,height:l-s}},YCEditor.prototype.toggleFullscreen=function(){var t=this.$mainElement,e=t.hasClass("full-screen");if(t.css({width:"",height:""}),e?(t.css({"min-width":"300","min-height":"300"}),t.removeClass("full-screen"),t.detach(),t.insertBefore(this.fullscreenPlaceHolder),this.fullscreenPlaceHolder.remove()):(this.fullscreenPlaceHolder=$("<div></div>"),this.fullscreenPlaceHolder.uniqueId().insertAfter(t),t.detach(),$("body").append(t),t.addClass("full-screen"),window.scrollTo(0,0)),"viewer"!==this.options.mode){var n=this.toolbar.find(".editor-fullscreen");e?n.removeClass("full"):n.addClass("full")}this.recalculateDesignArea(!0)},YCEditor.prototype.setupKeyBinding=function(){var t=this;Mousetrap(t.$element[0]).bind(["backspace","del"],function(e){return e.preventDefault(),t.deleteSelectedElements(),!1}),Mousetrap(t.$element[0]).bind(["command+z","ctrl+z"],function(e){return e.preventDefault(),t.doUndo(),!1}),Mousetrap(t.$element[0]).bind(["shift+command+z","ctrl+y"],function(e){return e.preventDefault(),t.doRedo(),!1}),Mousetrap(t.$element[0]).bind(["command+c","ctrl+c"],function(e){return e.preventDefault(),t.doCopyElements(),!1}),Mousetrap(t.$element[0]).bind(["command+v","ctrl+v"],function(e){return e.preventDefault(),t.doPasteElements(),!1}),Mousetrap(t.$element[0]).bind(["command+x","ctrl+x"],function(e){return e.preventDefault(),t.doCutElements(),!1}),Mousetrap(t.$element[0]).bind(["command+a","ctrl+a"],function(e){return e.preventDefault(),t.setSelection(t.elements.slice(0)),!1});[{key:"left",move:[-1,0]},{key:"up",move:[0,-1]},{key:"down",move:[0,1]},{key:"right",move:[1,0]},{key:"shift+left",move:[-10,0]},{key:"shift+up",move:[0,-10]},{key:"shift+down",move:[0,10]},{key:"shift+right",move:[10,0]}].forEach(function(e){Mousetrap(t.$element[0]).bind([e.key],function(n){return n.preventDefault(),t.moveSelectedElements(e.move),!1})})},YCEditor.prototype.moveSelectedElements=function(t){var e=this,n=[];$.each(this.currentSelection,function(t){n.push(this.id)}),$.each(n,function(n){e.findElement(this).move(t[0],t[1],!1)});var i={code:"keyboardMode",op:{op:"move",elements:n,dx:t[0],dy:t[1]},undo:function(){var t=this.op;$.each(t.elements,function(n){e.findElement(this).move(-t.dx,-t.dy,!0)})},redo:function(){var t=this.op;$.each(t.elements,function(n){e.findElement(this).move(t.dx,t.dy,!0)})},name:function(){return"Move"}};if(this.undoRedoStackIndex>0&&this.undoRedoStack.length>0){var r=this.undoRedoStack[this.undoRedoStackIndex-1];if(void 0!==r.code&&r.code===i.code&&i.op.elements.join()==r.op.elements.join())return r.op.dx+=i.op.dx,void(r.op.dy+=i.op.dy)}this.appendUndo(i)},YCEditor.prototype.serializeModel=function(){var t={};t.background=this.selectedBackground,t.backgroundSvg=this.selectedBackgroundSvg,t.backgroundColor=this.selectedBackgroundColor,t.logoPosition=this.selectedLogoPosition,t.backgroundFigureScale=this.selectedBackgroundFigureScale,t.backgroundPosition=this.selectedBackgroundPosition,t.backgroundScale=this.selectedBackgroundScale,t.colorField=this.selectedColorField,t.colorFieldAreas=this.selectedColorFieldAreas,t.colorFieldBorder=this.selectedColorFieldBorder,t.version="2",t.elements=[];for(var e=!1,n=0;n<this.elements.length;++n){var i=this.elements[n].toModel();t.elements.push(i),void 0!==i.keyFrames&&Object.keys(i.keyFrames).length>1&&(e=!0)}t.animated=e,t.animationDuration=this.timeline.total_duration;for(n=0;n<this.pluginCallbacks.length;++n){var r=this.pluginCallbacks[n];void 0!==r&&"function"==typeof r.onSerializeModel&&r.onSerializeModel(this,t)}return JSON.stringify(t)},YCEditor.prototype.hasAnimation=function(){for(var t=0;t<this.elements.length;++t){var e=this.elements[t];if(e.keyFrames.length>1)return!0}return!1},YCEditor.prototype.loadModel=function(t){this.clearAll();var e=null;try{e=JSON.parse(t)}catch(t){return}if("object"==typeof e){var n=void 0!==e.version?e.version:"1";if(e.backgroundSvg=void 0!==e.backgroundSvg?e.backgroundSvg:"",e.backgroundColor=void 0!==e.backgroundColor?e.backgroundColor:"",e.logoPosition=void 0!==e.logoPosition?e.logoPosition:"center",e.backgroundFigureScale=void 0!==e.backgroundFigureScale?parseFloat(e.backgroundFigureScale):1,e.backgroundPosition=void 0!==e.backgroundPosition?e.backgroundPosition:[0,0],e.backgroundScale=void 0!==e.backgroundScale?e.backgroundScale:1,e.colorField=void 0!==e.colorField?e.colorField:"#3B9CCC",e.colorFieldAreas=void 0!==e.colorFieldAreas?e.colorFieldAreas:"#277EA0",e.colorFieldBorder=void 0!==e.colorFieldBorder?e.colorFieldBorder:"#FF9F48","1"===n&&(e.backgroundScale=1),e.version="2",this.setBackgroundSvg(e.backgroundSvg,e.backgroundColor,e.backgroundFigureScale,e.backgroundPosition,e.backgroundScale,e.colorField,e.colorFieldAreas,e.colorFieldBorder),this.selectedLogoPosition=e.logoPosition,this.updateBackground(),this.updateLogoPosition(!1),void 0!==e.animationDuration&&e.animationDuration>0?(this.setAnimationTotalDuration(e.animationDuration),this.timelineVisible||void 0===e.animated||!1===e.animated||this.toggleTimeline()):this.timelineVisible&&this.toggleTimeline(),void 0!==e.elements)for(var i=0;i<e.elements.length;++i){var r=e.elements[i],o=this.loadShape(r);this.addElement(o)}for(i=0;i<this.pluginCallbacks.length;++i){var a=this.pluginCallbacks[i];void 0!==a&&"function"==typeof a.onLoadModel&&a.onLoadModel(this,e)}}},YCEditor.prototype.clearAll=function(){for(this.stopAnimation();this.elements.length>0;)this.removeElement(this.elements[0]);this.selectedLogoPosition="center",this.updateLogoPosition(!1),this.setBackgroundSvg("","",1,[0,0],1,"#3B9CCC","#277EA0","#FF9F48"),this.undoRedoStack=[],this.undoRedoStackIndex=0,this.updateUndoRedoButtons(),this.setAnimationTotalDuration(10)},YCEditor.prototype.updateBackground=function(){try{void 0!==this.selectedBackgroundColor&&null!==this.selectedBackgroundColor&&""!==this.selectedBackgroundColor?this.backgroundLayer.selectAll("rect.backgroundSvgColor").attr("fill",this.selectedBackgroundColor):this.backgroundLayer.selectAll("rect.backgroundSvgColor").attr("fill","none"),this.backgroundLayer.selectAll(".yc-color-field").attr("fill",this.selectedColorField),this.backgroundLayer.selectAll(".yc-color-field-areas").attr("fill",this.selectedColorFieldAreas),this.backgroundLayer.selectAll(".yc-color-field-border").attr("fill",this.selectedColorFieldBorder);var t="translate("+this.selectedBackgroundPosition[0]+","+this.selectedBackgroundPosition[1]+") scale("+this.selectedBackgroundScale+")";this.backgroundLayer.selectAll("g.bglines").attr("transform",t)}catch(t){}},YCEditor.prototype.setBackgroundSvg=function(t,e,n,i,r,o,a,s){var l=this;void 0===e&&(e=null),void 0===n&&(n=1),void 0===i&&(i=null),void 0===r&&(r=null),void 0===o&&(o="#3B9CCC"),void 0===a&&(a="#277EA0"),void 0===s&&(s="#FF9F48"),n=parseFloat(n),this.selectedBackgroundSvg=t,this.selectedBackgroundColor=e,this.selectedColorField=o,this.selectedColorFieldAreas=a,this.selectedColorFieldBorder=s,this.selectedBackgroundFigureScale=n,this.selectedBackgroundPosition=i,this.selectedBackgroundScale=r,this.backgroundLayer.selectAll("g").remove();var c=l.backgroundLayer.selectAll("rect.backgroundSvgColor").data([null]);c.enter().append("rect"),c.attr("class","backgroundSvgColor").attr("x",0).attr("y",0).attr("width",l.originalWidth).attr("height",l.originalHeight),void 0!==e&&""!==e&&null!==e?c.attr("fill",e):c.attr("fill","none"),$(c[0]).on("mousedown touchstart",function(t){l.mouseDown(t,null)}),void 0!==t&&""!==t&&d3.xhr(this.options.baseUrl+t,function(t){var e=$(t.response);l.bgContainer=l.backgroundLayer.append("g").attr("class","bglines"),$(l.bgContainer.node()).append(e),$(l.bgContainer.node()).on("mousedown touchstart",function(t){l.mouseDown(t,null)});var n=l.bgContainer.node().getBBox();n.width>0&&(l.selectedBackgroundBaseScale=1,l.selectedBackgroundScale=null!=r?r:l.selectedBackgroundBaseScale,l.selectedBackgroundPosition=null!=i?i:[0,0],l.updatePropertiesPanel(),l.updateBackground())})},YCEditor.prototype.guidGenerator=function(){var t=function(){return(65536*(1+Math.random())|0).toString(16).substring(1)};return t()+t()+"-"+t()+"-"+t()+"-"+t()+"-"+t()+t()+t()},YCEditor.prototype.addPatternImage=function(t){var e=null;return $(this).find("svg pattern image").each(function(){null==e&&$(this).attr("href")==t&&(e=$(this).parent().attr("id"))}),null!=e?e:(e="pattern"+this.getUniqueId()+this.guidGenerator(),this.defs.append("svg:pattern").attr("id",e).attr("width","100%").attr("height","100%").attr("patternContentUnits","objectBoundingBox").attr("preserveAspectRatio","xMidYMid slice").append("svg:image").attr("xlink:href",t).attr("width",1).attr("height",1).attr("preserveAspectRatio","none"),e)},YCEditor.prototype.setBackgroundImage=function(t,e,n){void 0===n&&(n=!1),t===this.background&&(this.selectedBackground=e);var i=null,r=this;$(this).find("svg pattern image").each(function(){null==i&&$(this).attr("href")==this.options.baseUrl+e&&(i=$(this).parent().attr("id"))}),null==i&&(i="pattern"+this.getUniqueId()+this.guidGenerator());var o=function(){r.defs.append("svg:pattern").attr("id",i).attr("width","100%").attr("height","100%").attr("patternContentUnits","objectBoundingBox").attr("preserveAspectRatio","xMidYMid slice").append("svg:image").attr("xlink:href",r.options.baseUrl+e).attr("width",1).attr("height",1).attr("preserveAspectRatio","none"),t.attr({fill:"url(#"+i+")"}),n?t.transition().ease("cubic-out").duration(2e3).attr("opacity",1):t.attr("opacity",1)};if(n){var a=(new Date).getMilliseconds();$("<img />").on("load",function(){if(this.complete&&void 0!==this.naturalWidth&&0!=this.naturalWidth){var t=(new Date).getMilliseconds()-a;t<2e3?setTimeout(o,2e3-t):o()}}).attr("src",r.options.baseUrl+e)}else o()},YCEditor.prototype.touchHandlerEventTransform=function(t){switch(t.type){case"touchstart":n="mousedown";break;case"touchmove":n="mousemove";break;case"touchend":n="mouseup";break;default:return t}var e=t.originalEvent.changedTouches[0],n="",i=document.createEvent("MouseEvent");return i.initMouseEvent(n,!0,!0,window,1,e.screenX,e.screenY,e.clientX,e.clientY,!1,!1,!1,!1,0,null),t.preventDefault(),i},YCEditor.prototype.touchHandler=function(t){var e=t.changedTouches[0],n="";switch(t.type){case"touchstart":n="mousedown";break;case"touchmove":n="mousemove";break;case"touchend":n="mouseup";break;default:return}var i=document.createEvent("MouseEvent");i.initMouseEvent(n,!0,!0,window,1,e.screenX,e.screenY,e.clientX,e.clientY,!1,!1,!1,!1,0,null),e.target.dispatchEvent(i),t.preventDefault()},YCEditor.prototype.toModelHelper=function(t){var e={};e.type=t.elementType;for(var n=["x","y","rotate","scale"],i=0;i<n.length;++i){e[o=n[i]]=t.keyFrames[0][n[i]]}var r=t.elementProperties();for(i=0;i<r.length;++i){var o=r[i];void 0!==t.keyFrames[0]["prop_"+o]?e[o]=t.keyFrames[0]["prop_"+o]:e[o]=t.elementProperty(o)}return e.keyFrames=$.extend(!0,{},t.keyFrames),e};var old_yceditor_plugin=$.fn.yceditor;$.fn.yceditor=function(t){return this.each(function(){var e=$(this),n=e.data("yceditor"),i="object"==typeof t&&t;n||e.data("yceditor",n=new YCEditor(this,i)),"string"==typeof t&&n[t]()})},$.fn.yceditor.Constructor=YCEditor,$.fn.yceditor.noConflict=function(){return $.fn.yceditor=old_yceditor_plugin,this},function(t,e){"use strict";e.prototype.palette_categories=[{label:"Players",options:[{name:"players",label:"Players (Male)"},{name:"players_female",label:"Players (Female)"},{name:"goalkeepers",label:"Goalkeepers (Male)"},{name:"goalkeepers_female",label:"Goalkeepers (Female)"},{name:"futsal",label:"Futsal"},{name:"coaches",label:"Coaches"},{name:"referees",label:"Referees"},{name:"children",label:"Children"},{name:"preparation",label:"Preparation (Male)"},{name:"preparation_female",label:"Preparation (Female)"},{name:"players_top",label:"Players (from top)"}]},{label:"Materials",options:[{name:"materials",label:"Materials"},{name:"discs",label:"Text and Numbers"},{name:"shapes",label:"Arrows and Shapes"}]},{label:"Fields",options:[{name:"fields_11",label:"Fields 11"},{name:"fields_futsal",label:"Futsal"}]}],e.prototype.palette_fields={11:[{index:0,scale:1,color:""},{index:1,scale:.5,color:""},{index:2,scale:1.1,color:""},{index:3,scale:.8,color:""},{index:4,scale:.8,color:""},{index:5,scale:.8,color:""},{index:6,scale:1,color:""},{index:7,scale:.4,color:""},{index:8,scale:.7,color:""},{index:9,scale:.6,color:""},{index:10,scale:.6,color:""},{index:11,scale:.6,color:""},{index:12,scale:.6,color:""},{index:13,scale:.75,color:""},{index:14,scale:.75,color:""},{index:15,scale:.5,color:""},{index:16,scale:.8,color:""},{index:17,scale:.4,color:""},{index:18,scale:.5,color:""},{index:19,scale:.3,color:""},{index:21,scale:.4,color:""},{index:22,scale:.4,color:""},{index:23,scale:.5,color:""},{index:24,scale:.6,color:""},{index:25,scale:.7,color:""},{index:26,scale:.7,color:""},{index:27,scale:.45,color:""},{index:28,scale:.45,color:""},{index:29,scale:.6,color:""},{index:30,scale:.8,color:""},{index:31,scale:.8,color:""},{index:32,scale:.8,color:""},{index:33,scale:.5,color:""},{index:34,scale:.5,color:""},{index:35,scale:.4,color:""},{index:36,scale:.4,color:""},{index:37,scale:.4,color:""},{index:38,scale:.4,color:""},{index:39,scale:.3,color:""},{index:40,scale:.35,color:""},{index:41,scale:1,color:""},{index:42,scale:2,color:""},{index:43,scale:1,color:""},{index:44,scale:1,color:""},{index:45,scale:1,color:""},{index:46,scale:.6,color:""},{index:47,scale:1.9,color:""}],futsal:[{index:1,scale:.5,color:"#d1d1d1"},{index:2,scale:.6,color:"#d1d1d1"},{index:3,scale:.8,color:"#d1d1d1"},{index:4,scale:.7,color:"#d1d1d1"},{index:5,scale:1,color:"#d1d1d1"},{index:6,scale:.6,color:"#d1d1d1"},{index:7,scale:1,color:"#d1d1d1"},{index:8,scale:1.3,color:"#d1d1d1"},{index:9,scale:1.2,color:"#d1d1d1"},{index:10,scale:1.2,color:"#d1d1d1"},{index:11,scale:.9,color:"#d1d1d1"},{index:12,scale:.8,color:"#d1d1d1"},{index:13,scale:.8,color:"#d1d1d1"},{index:14,scale:.6,color:"#d1d1d1"},{index:15,scale:.8,color:"#d1d1d1"},{index:16,scale:.5,color:"#d1d1d1"},{index:17,scale:.7,color:"#d1d1d1"},{index:18,scale:1.2,color:"#d1d1d1"},{index:19,scale:1.05,color:"#d1d1d1"},{index:20,scale:1.5,color:"#d1d1d1"},{index:21,scale:.85,color:"#d1d1d1"},{index:22,scale:1.1,color:"#d1d1d1"}]},e.prototype.figures_groups={children:[{direction:"side",gestures:[{gesture:"pass",figures:[9,12,21,37,41,42,83,85,94,104,32,95,105,123,126,136,137,174]},{gesture:"kick",figures:[99,25,27,138,139,168,184]},{gesture:"run",figures:[7,8,14,15,22,40,52,64,65,79,81,98,114,115,30,73,179]},{gesture:"stand",figures:[6,16,29,36,50,67,76,106,33,47,135,161]},{gesture:"throwin",figures:[122,167,175]},{gesture:"special",figures:[189,190,191,198,204,205,207,208,209,210,211,212,213,214,215,216,217]},{gesture:"dribbling",figures:[14,39,54,57,66,68,69,80,82,88,89,92,96,108,113,116,53,70,117]}]},{direction:"up",gestures:[{gesture:"pass",figures:[11,32,95,127,131,133,149,150,151,152,153,155,156,166,182]},{gesture:"kick",figures:[46,56,58,99,103,124,133,154,169,185]},{gesture:"run",figures:[13,22,30,72,73,74,143,144,145,158,159,177,180,187]},{gesture:"stand",figures:[20,38,47,48,51,67,106,120,121,129,130,141,147,160,162,163,164,181,188]},{gesture:"throwin",figures:[183]},{gesture:"special",figures:[200,201,202,203,206]},{gesture:"dribbling",figures:[100]}]},{direction:"down",gestures:[{gesture:"pass",figures:[12,34,37,41,49,61,83,84,85,87,97,112,146,165]},{gesture:"kick",figures:[27,118,128,132,134,140,142,148,157,170,176,178,186]},{gesture:"run",figures:[1,4,18,19,24,28,33,62,63,68,93,98,101,102,111,114,115,171]},{gesture:"stand",figures:[3,5,9,10,16,26,31,36,50,55,71,75,78,90,97,172,173]},{gesture:"throwin",figures:[125]},{gesture:"special",figures:[59,192,193,194,195,196,197,199,217,218,219,220,221,222,223,224]},{gesture:"dribbling",figures:[2,17,23,35,39,43,44,45,53,54,57,60,70,77,86,88,89,91,92,107,108,109,110,113,116,119]}]}],players:[{direction:"side",gestures:[{gesture:"pass",figures:[152,133,167,168,169,170,171,191,196,197,198,199,215,218]},{gesture:"kick",figures:[11,128,143,151,64,138,145,149,3,75]},{gesture:"run",figures:[12,135,2,34,42,68,84,1,132,141,144,158]},{gesture:"stand",figures:[150,61,136,18,19,21,49,147,39,20,237,72,159,176,177,180,185,186]},{gesture:"throwin",figures:[13,140,77]},{gesture:"special",figures:[101,103,104,44,90,95,99,123,124,111,112,119,73,100,105,91,92,93,94,98,110,113,115,118,9]},{gesture:"dribbling",figures:[45,81,85,8,86,62]}]},{direction:"up",gestures:[{gesture:"pass",figures:[15,26,32,66,70,204,205,206,207,208,209,210,211,212,221,222,223]},{gesture:"kick",figures:[60,67,70,71,74,83,160]},{gesture:"run",figures:[132,146,30,65,68,69,57,59]},{gesture:"stand",figures:[49,37,53,54,55,61,63,16,23,33,36,51,52,56,161,163,164,165,166,178,179,182,184,194,229,230,231,232,233,234,235,236,237]},{gesture:"throwin",figures:[214]},{gesture:"special",figures:[101,103,104,89,91,95,97,99,121,107,109,117,73,162]},{gesture:"dribbling",figures:[28,59,70,76]}]},{direction:"down",gestures:[{gesture:"pass",figures:[41,126,125,14,153,25,31,50,181,200,201,202,203,216,217,224,225]},{gesture:"kick",figures:[10,137,149,151,4,6,7,154,219,220]},{gesture:"run",figures:[1,12,127,134,135,141,148,29,42,46,5,79,87,9,129]},{gesture:"stand",figures:[41,47,142,24,38,82,130,131,17,22,35,43,155,172,173,174,175,183,187,188,189,190,192,193,226,227,228]},{gesture:"throwin",figures:[80,213]},{gesture:"special",figures:[100,102,105,88,90,94,96,98,120,122,106,108,114,116,40,139,156,157,238,239,240]},{gesture:"dribbling",figures:[45,48,85,27,78]}]}],players_female:[{direction:"side",gestures:[{gesture:"pass",figures:[2,6,28,54,71,93,178]},{gesture:"kick",figures:[8,116,19,46,49,72,86]},{gesture:"run",figures:[104,126,29,43,55,61,7,16,44]},{gesture:"stand",figures:[108,110,118,127,48,56,59,62,63,68,69,97,26,41,143,148,153]},{gesture:"throwin",figures:[27,146,163]},{gesture:"special",figures:[112,113,114,115,122,13,135,137,139,141,21,30,39,45,47,70,76,87,92,40]},{gesture:"dribbling",figures:[124,129,84,85,95,16]}]},{direction:"up",gestures:[{gesture:"pass",figures:[38,88,142,149,160,166,176]},{gesture:"kick",figures:[50,51,147,158,164,170,173]},{gesture:"run",figures:[126,35,44,145,150,155,162,165,168,172]},{gesture:"stand",figures:[108,110,121,127,24,41,58,74,78,79,80,83,98,100,101,154,175]},{gesture:"throwin",figures:[25,152,157,169]},{gesture:"special",figures:[107,119,125]},{gesture:"dribbling",figures:[103,128,32,34,5]}]},{direction:"down",gestures:[{gesture:"pass",figures:[117,120,131,54,65,81,82,94]},{gesture:"kick",figures:[57,65,99,1,10,179]},{gesture:"run",figures:[104,105,130,133,134,18,36,4,43,73]},{gesture:"stand",figures:[11,22,23,26,3,37,42,60,64,66,67,75,89,90,91,96,102,159]},{gesture:"throwin",figures:[111,12,27]},{gesture:"special",figures:[106,109,114,115,123,136,137,138,14,140,15,52]},{gesture:"dribbling",figures:[124,132,17,20,31,33,53,77,9,94]}]}],goalkeepers:[{direction:"side",gestures:[{gesture:"pass",figures:[13,46]},{gesture:"long_pass",figures:[14,32,52,35,99]},{gesture:"run",figures:[120,119,108,100]},{gesture:"stand",figures:[18,33,37,54,17,125,122,93]},{gesture:"goalkeeper",figures:[42,65,66,67,68,69,55,110,103,94]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[44,45,47,49,51,56,125,112,111,97,95]}]},{direction:"up",gestures:[{gesture:"pass",figures:[88,87,86,85,84,82,81,79]},{gesture:"long_pass",figures:[57,58,80,83]},{gesture:"run",figures:[117,116]},{gesture:"stand",figures:[11,15,71,77,73,118,90]},{gesture:"goalkeeper",figures:[19,2,21,23,31,36,39,72]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[115,114,113,105]}]},{direction:"down",gestures:[{gesture:"pass",figures:[59,60,61,62,63,64,72,76]},{gesture:"long_pass",figures:[70,74,78]},{gesture:"run",figures:[106,98]},{gesture:"stand",figures:[16,25,26,27,28,29,53,6,75,92]},{gesture:"goalkeeper",figures:[1,10,12,20,22,24,30,34,38,4,41,5,50,7,8,9,3,121,109,102,101]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[40,43,48,123,107,104,96,91,89]}]}],goalkeepers_female:[{direction:"side",gestures:[{gesture:"pass",figures:[11,13,17,18,22,25,27,28,29,31]},{gesture:"long_pass",figures:[4,21,23,24,26,33,35,36,40]},{gesture:"run",figures:[]},{gesture:"stand",figures:[2]},{gesture:"goalkeeper",figures:[5,6,8]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[]}]},{direction:"up",gestures:[{gesture:"pass",figures:[14,16,32,39]},{gesture:"long_pass",figures:[15,38,40]},{gesture:"run",figures:[]},{gesture:"stand",figures:[]},{gesture:"goalkeeper",figures:[5,7,10]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[]}]},{direction:"down",gestures:[{gesture:"pass",figures:[17,18,19,25,27,28,29,30,31,34,36]},{gesture:"long_pass",figures:[]},{gesture:"run",figures:[]},{gesture:"stand",figures:[2,12,20]},{gesture:"goalkeeper",figures:[1,3,6,9]},{gesture:"special",figures:[]},{gesture:"with_ball",figures:[]}]}],materials:[{direction:"all",gestures:[{gesture:"material.balls",figures:[14,15,16]},{gesture:"materials",figures:[1,10,11,12,13,33,34,35,36,6,7,8,9,71]},{gesture:"material.bose",figures:[67,68,69,70]},{gesture:"material.wall",figures:[72,73,74,75,76,77,78]},{gesture:"material.target",figures:[79,80,81,82,83,84]},{gesture:"material.goals",figures:[28,29,30,31,32,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,54,55,56,57,58,59,60,61,62,63,64,65,66,85]},{gesture:"material.speedladder",figures:[2,3,4,5]},{gesture:"material.speedhurdle",figures:[17,18,19,20,21,22,23,24,25,26,27,86,87]},{gesture:"material.special",figures:[]}]}]}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.loadPalette=function(e,n){void 0===n&&(n="left",t(".direction-selector select",this.$mainElement).val(n),t(".direction-selector span.option.active",this.$mainElement).removeClass("active"),t(".direction-selector span.option[value='"+n+"']",this.$mainElement).addClass("active")),t("ul.figures",this.$mainElement).empty();var i="",r=1,o=0,a=!1,s="";if("players"===e)i="",s="players",o=240;else if("players_female"===e)i="",s="players_female",o=179;else if("futsal"===e)i="",s="futsal",o=135;else if("goalkeepers"===e)i="por",s="goalkeepers",o=125;else if("goalkeepers_female"===e)i="por",s="goalkeepers_female",o=31;else if("preparation"===e)i="",s="preparation",o=308;else if("preparation_female"===e)i="",s="preparation_female",o=15;else if("coaches"===e){i="a";s="coaches";o=26}else if("referees"===e){i="";s="referees";o=28}else if("children"===e){i="";s="children";o=226}else if("players_top"===e){i="";s="players_top";o=13}else if("materials"===e){i="";s="materials";o=87}else if("discs"===e){i="";s="discs";r=0,o=25}else"shapes"===e?this.loadPaletteShapes():"fields_11"===e||"fields_futsal"===e?(this.loadPaletteFields(e.substring(7)),a=!0):"team_players"===e&&this.loadPaletteTeamPlayers();if(this.setBackgroundEditingMode(a),void 0===this.figures_groups[s]){t("ul.figures",this.$mainElement).removeClass("groups"),this.setDirectionSelectorVisible(!1);for(h=r;h<=o;++h){"discs"===s&&0==h&&(s="text"),"text"===s&&h>0&&(s="discs");var l=t("<li></li>");t(l).addClass("figure-preview"),t(l).addClass("palette-preview"),t(l).addClass("category-"+s),t(l).css("background-image","url(' "+this.options.baseUrl+"images/optimized/"+s+"/"+i+h+"_mini.png')");var c={category:s,name:i+h};"discs"===s&&(c.textlabel=""+h,c.width=40),t.merge({},c),t(l).data("yc.editor.figure",c),t("ul.figures",this.$mainElement).append(l),t(l).draggable({appendTo:"body",helper:"clone",revert:"invalid",scroll:!1})}}else{t("ul.figures",this.$mainElement).addClass("groups");var u=this.figures_groups[s];this.setDirectionSelectorVisible(u.length>1);for(var h=0;h<u.length;++h)for(var p=u[h],d=0;d<p.gestures.length;++d){var f=p.gestures[d];if(f.figures.length>0){var g=p.direction;("side"!==g||"right"!==n&&"left"!==n)&&g!==n&&"all"!==g||(g=n,this.createPaletteGroup(this.t(f.gesture),f.figures,s,i,"right"===g?1:0))}}}},e.prototype.setDirectionSelectorVisible=function(e){e?t(".direction-selector",this.$mainElement).is(":visible")||(t(".direction-selector",this.$mainElement).show(),this.recalculateDesignArea(!1)):t(".direction-selector",this.$mainElement).is(":visible")&&(t(".direction-selector",this.$mainElement).hide(),this.recalculateDesignArea(!1))},e.prototype.createPaletteGroup=function(e,n,i,r,o){void 0===o&&(o=0);var a=t("<li></li>");t(a).addClass("figures-group-wrapper");var s=t("<span></span>").html(e);t(s).addClass("figure-group-label"),t(a).append(s);var l=t("<ul></ul>");t(l).addClass("figures-group");for(var c=0;c<n.length;++c){var u=n[c],h=t("<li></li>");t(h).addClass("figure-preview"),t(h).addClass("palette-preview"),t(h).addClass("category-"+i),t(h).css("background-image","url(' "+this.options.baseUrl+"images/optimized/"+i+"/"+r+u+(1===o?"r":"")+"_mini.png')");var p={category:i,name:r+u,flip:""+o};"discs"===i&&(p.textlabel=""+u,p.width=40),t.merge({},p),t(h).data("yc.editor.figure",p),t(h).draggable({appendTo:"body",helper:"clone",revert:"invalid",scroll:!1}),t(l).append(h)}t(a).append(l),t("ul.figures",this.$mainElement).append(a),s.css("top",s.width()+2)},e.prototype.loadPaletteFields=function(e){var n=this.palette_fields;if(void 0!==n[e])for(var i=n[e],r=0;r<i.length;++r){var o=i[r],a=t("<li></li>");t(a).addClass("fields-preview"),t(a).addClass("palette-preview"),t(a).css("background-image","url(' "+this.options.baseUrl+"images/optimized/fields/"+e+"/"+o.index+"_mini.png')"),t(a).data("yc.editor.field",{url:"images/optimized/fields/"+e+"/"+o.index+".svg",color:o.color,scale:o.scale}),t("ul.figures",this.$mainElement).append(a),t(a).draggable({appendTo:"body",helper:"clone",revert:"invalid",scroll:!1})}},e.prototype.loadPaletteShapes=function(){for(var e=[{name:"triangle",vertices:"3",category:"polygon"},{name:"rectangle",vertices:"4",category:"polygon"},{name:"pentagon",vertices:"5",category:"polygon"},{name:"ellipse",vertices:"5",category:"ellipse"},{name:"linear_normal",vertices:"2",category:"line",lineType:"normal",lineInterpolation:"basis"},{name:"quadratic_normal",vertices:"3",category:"line",lineType:"normal",lineInterpolation:"basis"},{name:"cubic_normal",vertices:"4",category:"line",lineType:"normal",lineInterpolation:"basis"},{name:"linear_waves",vertices:"2",category:"line",lineType:"waves",lineInterpolation:"basis"},{name:"quadratic_waves",vertices:"3",category:"line",lineType:"waves",lineInterpolation:"basis"},{name:"cubic_waves",vertices:"4",category:"line",lineType:"waves",lineInterpolation:"basis"},{name:"linear_double",vertices:"2",category:"line",lineType:"double",lineInterpolation:"basis"},{name:"quadratic_double",vertices:"3",category:"line",lineType:"double",lineInterpolation:"basis"},{name:"cubic_double",vertices:"4",category:"line",lineType:"double",lineInterpolation:"basis"}],n=0;n<e.length;++n){var i=e[n],r=t("<li></li>");t(r).addClass("figure-preview"),t(r).addClass("palette-preview"),t(r).addClass("category-polygon"),t(r).css("background-image","url(' "+this.options.baseUrl+"images/optimized/polygons/"+i.name+"_mini.png')"),t(r).data("yc.editor.figure",i),t("ul.figures",this.$mainElement).append(r),t(r).draggable({appendTo:"body",helper:"clone",revert:"invalid",scroll:!1})}},e.prototype.setTeamPlayers=function(e){this.options.team_players=e,"team_players"==t(".palette_content_select",this.$mainElement).val()&&(t("ul.figures",this.$mainElement).html(""),this.loadPaletteTeamPlayers())},e.prototype.loadPaletteTeamPlayers=function(){for(var e=0;e<this.options.team_players.length;++e){var n=this.options.team_players[e],i=t("<li></li>"),r=t("<div></div>");r.addClass("team-player-palette-item");var o=t('<div class="team-player-palette-item-image"/>');if(void 0!==n.image&&null!==n.image){var a=t("<img/>");a.attr("src",n.image),o.append(a)}r.append(o);var s=t("<div></div>");s.addClass("team-player-palette-item-name"),s.append(t("<span/>").html(n.name)),void 0!==n.role&&s.append(t("<span/>").text(n.role)),r.append(s),i.append(r),t(i).addClass("figure-preview"),t(i).addClass("palette-preview"),t(i).addClass("category-team-player"),t(i).data("yc.editor.figure",{category:"team_players",playerName:n.name,playerDisplayName:void 0!==n.displayName?n.displayName:n.name,playerNumber:n.number,playerImage:void 0===n.image?null:n.image,playerUniform:void 0===n.uniform?null:n.uniform,name:"team_player"}),t("ul.figures",this.$mainElement).append(i),t(i).draggable({appendTo:"body",helper:"clone",revert:"invalid",scroll:!1})}},e.prototype.setupPalette=function(){var e=this;t(".palette_content_select",this.$mainElement).selectbox({onChange:function(n,i){t(".palette_content_select").val(n),e.loadPalette(n)}}),t(".direction-selector select",this.$mainElement).Segment(),t(".direction-selector",this.$mainElement).find('[value="left"]').addClass("direction-left"),t(".direction-selector",this.$mainElement).find('[value="up"]').addClass("direction-up"),t(".direction-selector",this.$mainElement).find('[value="down"]').addClass("direction-down"),t(".direction-selector",this.$mainElement).find('[value="right"]').addClass("direction-right"),t(".direction-selector span",this.$mainElement).on("click",function(){e.loadPalette(t(".palette_content_select",this.$mainElement).val(),t(".direction-selector select",this.$mainElement).val())}),this.palette_categories.length>0&&this.palette_categories[0].options.length>0&&this.loadPalette(this.palette_categories[0].options[0].name),this.$element.droppable({accept:".palette-preview",drop:function(n,i){var r=e.$element.offset(),o=n.pageX-r.left,a=n.pageY-r.top,s=t(i.draggable).data("yc.editor.figure"),l=t(i.draggable).data("yc.editor.field");if(void 0!==s)if("team_players"===s.category){var c=e.getLastUsedColorsForFigure(s.category),u={type:"team_player",x:o/e.zoom,y:a/e.zoom,width:0,height:0,playerName:s.playerName,playerDisplayName:s.playerDisplayName,playerNumber:s.playerNumber,playerImage:s.playerImage,playerUniform:s.playerUniform,elementType:s.category,color:c[0]},h=e.loadShape(u),p=e.addElement(h);e.appendUndo({undo:function(){e.removeElement(h)},redo:function(){e.addElementAt(h,p)},name:function(){return"Add player"}})}else if("text"===s.category){c=e.getLastUsedColorsForFigure(s.category),u={type:"text",x:o/e.zoom,y:a/e.zoom,width:0,height:0,text:"Text",elementType:s.category,color:c[0],color2:c[1]},h=e.loadShape(u),p=e.addElement(h);e.appendUndo({undo:function(){e.removeElement(h)},redo:function(){e.addElementAt(h,p)},name:function(){return"Add element"}})}else if("ellipse"===s.category){c=e.getLastUsedColorsForFigure(s.category),u={type:"ellipse",x:o/e.zoom,y:a/e.zoom,rx:100,ry:100,width:0,height:0,points:y,elementType:s.category,color:c[0],color2:c[1]},h=e.loadShape(u),p=e.addElement(h);e.appendUndo({undo:function(){e.removeElement(h)},redo:function(){e.addElementAt(h,p)},name:function(){return"Add element"}})}else if("line"===s.category){var d=parseFloat(s.vertices),f=(c=e.getLastUsedColorsForFigure(s.category),o/e.zoom),g=a/e.zoom,m=100,y=[];if((w=[0,0])[0]=f-100,w[1]=g,y.push(w),4==d){(C=[0,0])[0]=f-50,C[1]=g,y.push(C);var v=[0,0];v[0]=f+50,v[1]=g,y.push(v)}else if(3==d){var C;(C=[0,0])[0]=f,C[1]=g,y.push(C)}var b=[0,0];b[0]=f+100,b[1]=g,y.push(b);u={type:"line",points:y,lineType:s.lineType,lineInterpolation:s.lineInterpolation,elementType:s.category,stroke:4,color:e.getLastUsedColorsForFigure("line")[0]},h=e.loadShape(u),p=e.addElement(h);e.appendUndo({undo:function(){e.removeElement(h)},redo:function(){e.addElementAt(h,p)},name:function(){return"Add element"}})}else if("polygon"===s.category){d=parseFloat(s.vertices),c=e.getLastUsedColorsForFigure(s.category),f=o/e.zoom,g=a/e.zoom,m=100,y=[];var x=0;4!==d&&(x=-90),4===d&&(x=-45);for(var L=x,k=0;k<d;++k){var w;L=x+k*(360/d),(w=[0,0])[0]=f+m*Math.cos(L*(Math.PI/180)),w[1]=g+m*Math.sin(L*(Math.PI/180)),y.push(w)}u={type:"polygon",x:o/e.zoom,y:a/e.zoom,width:0,height:0,points:y,elementType:s.category,color:c[0],color2:c[1]},h=e.loadShape(u),p=e.addElement(h);e.appendUndo({undo:function(){e.removeElement(h)},redo:function(){e.addElementAt(h,p)},name:function(){return"Add element"}})}else{var _=new Image;_.onload=function(){var n=parseFloat(t(e.$element).width())/10;void 0!==s.width&&(n=parseFloat(s.width)*e.zoom);var i=_.width,r=_.height;i>r?(r=n*r/i,i=n):(i=n*i/r,r=n);var l=e.getLastUsedColorsForFigure(s.category),c=e.getLastUsedUniformForFigure(s.category),u="figure";"discs"==s.category&&(u="disc");var h={type:u,x:o/e.zoom,y:a/e.zoom,width:i/e.zoom,height:r/e.zoom,svg:"images/optimized/"+s.category+"/"+s.name+".svg",elementType:s.category,color:l[0],color2:l[1],uniform:c};"string"==typeof l[2]&&(h.skin=l[2]),"string"==typeof l[3]&&(h.hair=l[3]),"materials"==s.category&&t.inArray(parseInt(s.name,10),[10,11,12,13,14,15,16,67,68,69,70])>=0&&(h.width*=.25,h.height*=.25),1!==e.selectedBackgroundFigureScale&&(h.scale=parseFloat(e.selectedBackgroundFigureScale)*(e.selectedBackgroundScale/e.selectedBackgroundBaseScale)),"discs"==s.category&&(h.textlabel=s.textlabel),void 0!==s.flip&&(h.flip=s.flip);var p=e.loadShape(h),d=e.addElement(p);e.appendUndo({undo:function(){e.removeElement(p)},redo:function(){e.addElementAt(p,d)},name:function(){return"Add element"}})},_.src=e.options.baseUrl+"images/optimized/"+s.category+"/"+s.name+".svg"}else if(void 0!==l){var S=e.selectedBackgroundSvg,M=l.url,F=e.selectedBackgroundColor,E=l.color,P=e.selectedBackgroundFigureScale,T=l.scale,A=e.selectedBackgroundScale,z=e.selectedBackgroundPosition;e.setBackgroundSvg(l.url,l.color,T,void 0,void 0,e.selectedColorField,e.selectedColorFieldAreas,e.selectedColorFieldBorder);var B=e.selectedBackgroundScale,N=e.selectedBackgroundPosition;e.appendUndo({oldBackgroundSvg:S,newBackgroundSvg:M,oldBackgroundColor:F,newBackgroundColor:E,oldBackgroundFigureScale:P,newBackgroundFigureScale:T,oldBackgroundScale:A,newBackgroundScale:B,oldBackgroundPosition:z,newBackgroundPosition:N,undo:function(){e.setBackgroundSvg(this.oldBackgroundSvg,this.oldBackgroundColor,this.oldBackgroundFigureScale,this.oldBackgroundPosition,this.oldBackgroundScale)},redo:function(){e.setBackgroundSvg(this.newBackgroundSvg,this.newBackgroundColor,this.newBackgroundFigureScale,this.newBackgroundPosition,this.newBackgroundScale)},name:function(){return"Change Background"}})}}})}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.updatingProperties=!1,e.prototype.commonProperties=[{name:"bgTitleProperty",type:"title",label:"Background Properties"},{name:"color",type:"color",label:""},{name:"color2",type:"color",label:""},{name:"uniform",type:"uniform",label:""},{name:"skin",type:"skin",label:""},{name:"hair",type:"skin",label:""},{name:"opacity",type:"range",label:"Opacity"},{name:"bgOpacity",type:"range",label:"Background Opacity"},{name:"stroke",type:"segment",label:"Stroke",options:[1,2,4,8]},{name:"lineStyle",type:"segment",label:"Line Style",options:["dotted","dashed","solid"]},{name:"arrowStyle",type:"segment",label:"Arrow Style",options:["arrow-left","arrow-left-right","arrow-none","arrow-right"]},{name:"flip",type:"segment",label:"Flip",options:[0,1]},{name:"textlabel",type:"input",label:"Label"},{name:"text",type:"text",label:"Text"},{name:"fontSize",type:"range",label:"Font Size"},{name:"waveFrequency",type:"range",label:"Wave Frequency"},{name:"waveAmplitude",type:"range",label:"Wave Amplitude"},{name:"linesOffset",type:"range",label:"Lines Offset"},{name:"relativeScale",type:"range",label:"Scale"},{name:"bgColor",type:"bgColor",label:"Solid Background"},{name:"colorField",type:"bgColor",label:"Field"},{name:"colorFieldAreas",type:"bgColor",label:"Areas"},{name:"colorFieldBorder",type:"bgColor",label:"Border"},{name:"logoPosition",type:"segment",label:"Logo Position",options:["center","top_left","top_right","bottom_left","bottom_right"]}],e.prototype.colorPalette=[["#000000","#ffffff","#a7194b"],["#fe2712","#fd5308","#fb9902"],["#f9bc02","#fffe32","#d0e92b"],["#66b132","#0291cd","#fbfa25"],["#3e01a4","#8601b0","#666666"],["#77b55f","#E02831","#0060A9"]],e.prototype.elementProperties=function(){return void 0!==this.selectedBackgroundSvg&&this.selectedBackgroundSvg.indexOf("futsal")>0?["bgTitleProperty","bgColor","relativeScale","colorField","colorFieldAreas","colorFieldBorder","logoPosition"]:["bgTitleProperty","bgColor","relativeScale","logoPosition"]},e.prototype.elementProperty=function(t,e){return"titleProperty"==t?null:void 0===e?"bgColor"==t?this.selectedBackgroundColor:"relativeScale"==t?this.selectedBackgroundScale:"colorField"==t?this.selectedColorField:"colorFieldAreas"==t?this.selectedColorFieldAreas:"colorFieldBorder"==t?this.selectedColorFieldBorder:"logoPosition"==t?this.selectedLogoPosition:null:("bgColor"==t&&(this.selectedBackgroundColor=e,this.updateBackground()),"relativeScale"==t&&(this.selectedBackgroundScale=parseFloat(e),this.updateBackground()),"colorField"==t&&(this.selectedColorField=e,this.updateBackground()),"colorFieldAreas"==t&&(this.selectedColorFieldAreas=e,this.updateBackground()),"colorFieldBorder"==t&&(this.selectedColorFieldBorder=e,this.updateBackground()),void("logoPosition"==t&&(this.selectedLogoPosition=e,this.updateLogoPosition())))},e.prototype.setBackgroundEditingMode=function(t){t!==this.editingBackground&&(this.editingBackground=t,this.currentSelection.length>0?this.setSelection([]):this.selectionChanged())},e.prototype.lastUsedColorsForFigure={arrow:["#000000"],players:["#FF0000","#000000","#D3AB9B","#000000"],players_female:["#0A71B4","#B3B3B3","#EDC9B9","#B17F48"],goalkeepers:["#FF0000","#000000","#D3AB9B","#000000"],goalkeepers_female:["#FF0000","#000000","#D3AB9B","#000000"],children:["#F29400","#B3B3B3","#EDC9B9","#000000"],players_top:["#BE0926","#741321","#D3AB9B","#000000"],futsal:["#93117E","#4D4D4D","#D3AB9B","#000000"],preparation:["#FF0000","#000000","#EDC9B9","#000000"],preparation_female:["#0A71B4","#B3B3B3","#EDC9B9","#B17F48"],referees:["#FFED00","#555555","#EDC9B9","#000000"],coaches:["#00632F","#00632F","#D3AB9B","#673B15"],discs:["#ffffff","#369cdb"],pen:["#000000"],polygon:["#000000","#FFFFFF"],materials:["#FFED00","#FFFFFF"]},e.prototype.getDefaultUniformForFigure=function(t){if(void 0!==this.lastUsedColorsForFigure[t]){var e=this.lastUsedColorsForFigure[t];return{type:"f",c1:e[0],c3:"#000000",c2:e[1],c4:e[0]}}return{type:"f",c1:"#FF0000",c3:"#FFFFFF",c2:"#000000",c4:"#FF0000"}},e.prototype.lastUsedUniform={},e.prototype.getLastUsedColorsForFigure=function(t){return void 0!==this.lastUsedColorsForFigure[t]?this.lastUsedColorsForFigure[t]:["#000000","#FFFFFF","#D3AB9B","#000000"]},e.prototype.setLastUsedColorsForFigure=function(t,e){this.lastUsedColorsForFigure[t]=e},e.prototype.getLastUsedUniformForFigure=function(e){return void 0!==this.lastUsedUniform[e]&&this.lastUsedUniform[e].length>0?t.extend({},this.getDefaultUniformForFigure(e),this.lastUsedUniform[e][this.lastUsedUniform[e].length-1]):t.extend({},this.getDefaultUniformForFigure(e))},e.prototype.getLastUsedUniformsForFigure=function(){var t=[];for(var e in this.lastUsedUniform)for(var n=0;n<this.lastUsedUniform[e].length;++n){for(var i=this.lastUsedUniform[e][n],r=!1,o=t.length;o--&&!r;){var a=t[o];this.isEquivalent(a,i)&&(r=!0)}r||t.push(i)}return t},e.prototype.setLastUsedUniformForFigure=function(e,n){void 0===this.lastUsedUniform[e]&&(this.lastUsedUniform[e]=[]);for(var i=this.lastUsedUniform[e].length;i--;){var r=this.lastUsedUniform[e][i];this.isEquivalent(r,n)&&this.lastUsedUniform[e].splice(i,1)}this.lastUsedUniform[e].push(t.extend({},n))},e.prototype.updateLastUsedColorsForFigure=function(){for(var t=0;t<this.currentSelection.length;++t){var e=this.currentSelection[t];if(void 0!==e.elementType){var n=[];n.push(e.elementProperty("color")),n.push(e.elementProperty("color2")),n.push(e.elementProperty("skin")),n.push(e.elementProperty("hair")),this.setLastUsedColorsForFigure(e.elementType,n)}}},e.prototype.updateLastUsedUniformForFigure=function(){for(var t=0;t<this.currentSelection.length;++t){var e=this.currentSelection[t];if(void 0!==e.elementType){var n=e.elementProperty("uniform");n&&this.setLastUsedUniformForFigure(e.elementType,n)}}},e.prototype.getSelectedElementsPropertyValue=function(t){var e={},n=this.currentSelection;this.editingBackground&&0==n.length&&(n=[this]);for(var i=0;i<n.length;++i){var r=n[i];e[r.id]=r.elementProperty(t)}return e},e.prototype.setElementProperty=function(t,e,n,i,r){this.setElementProperties([t],[e],n,i,[r])},e.prototype.setElementProperties=function(e,n,i,r,o){var a=this;void 0===r&&(r=!0);var s=[],l=this.currentSelection;a.editingBackground&&0==l.length&&(l=[a]);for(var c=0;c<l.length;++c)for(var u=l[c],h=0;h<e.length;++h){var p=e[h],d=u.elementProperty(p);void 0!==o&&void 0!==o[h]&&"undefined"!==o[h][u.id]&&(d=o[h][u.id]),"object"==typeof d&&this.isEquivalent(d,n[h])||d!==n[h]&&(s.push({ele_id:u.id,propertyName:p,oldProperty:d,newProperty:n[h]}),u.elementProperty(p,n[h]))}r&&s.length>0&&a.appendUndo({undo:function(){t.each(s,function(t){a.findElement(this.ele_id).elementProperty(this.propertyName,this.oldProperty,!0),a.updatePropertiesPanel()})},redo:function(){t.each(s,function(t){a.findElement(this.ele_id).elementProperty(this.propertyName,this.newProperty,!0),a.updatePropertiesPanel()})},name:function(){return i}})},e.prototype.isEquivalent=function(t,e){var n=Object.getOwnPropertyNames(t),i=Object.getOwnPropertyNames(e);if(n.length!=i.length)return!1;for(var r=0;r<n.length;r++){var o=n[r];if(t[o]!==e[o])return!1}return!0},e.prototype.setupPropertiesPanel=function(){var n=this,i=n.$mainElement;i.find(".properties .segment-select").Segment(),t(".property-stroke .option",i).each(function(e){var n=t(this).attr("value"),i=(t(this).height(),t("<div></div>").addClass("segment-select-stroke").addClass("stroke-"+n));t(this).append(i)}),i.find(".property-stroke span").on("click",function(){var t=i.find(".property-stroke select").val();n.setElementProperty("stroke",t,"Stroke")}),t(".property-lineStyle .option",i).each(function(e){var n=t(this).attr("value"),i=(t(this).height(),t("<div></div>").addClass("segment-select-lineStyle").addClass("line-"+n));t(this).append(i)}),i.find(".property-lineStyle span").on("click",function(){var t=i.find(".property-lineStyle select").val();n.setElementProperty("lineStyle",t,"Line Style")}),t(".property-logoPosition .option",i).each(function(e){var n=t(this).attr("value"),i=(t(this).height(),t("<div></div>").addClass("segment-select-logoPosition").addClass("position-"+n));t(this).append(i)}),i.find(".property-logoPosition span").on("click",function(){var t=i.find(".property-logoPosition select").val();n.setElementProperty("logoPosition",t,"Logo Position")}),t(".property-arrowStyle .option",i).each(function(e){var n=t(this).attr("value"),i=(t(this).height(),t("<div></div>").addClass("segment-select-arrowStyle").addClass(n));t(this).append(i)}),i.find(".property-arrowStyle span").on("click",function(){var t=i.find(".property-arrowStyle select").val();n.setElementProperty("arrowStyle",t,"Arrow Style")}),t(".property-flip .option",i).each(function(e){var n=t(this).attr("value"),i=(t(this).height(),t("<div></div>").addClass("segment-select-flip").addClass("flip-"+n));t(this).append(i)}),i.find(".property-flip span").on("click",function(){var t=i.find(".property-flip select").val();n.setElementProperty("flip",t,"Flip")});var r={};i.find(".property-color input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showPalette:!0,showSelectionPalette:!0,palette:e.prototype.colorPalette,localStorageKey:"youcoach.drilleditor",maxSelectionSize:3,showInitial:!0,showButtons:!1,preferredFormat:"hex",show:function(){r=n.getSelectedElementsPropertyValue("color")},move:function(t){n.setElementProperty("color",t.toHexString(),"Color",!1),n.updateLastUsedColorsForFigure()},hide:function(t){n.lastSelectedColor=t.toHexString(),n.setElementProperty("color",t.toHexString(),"Color",!0,r),r={},n.updateLastUsedColorsForFigure()}});var o={};i.find(".property-color2 input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showPalette:!0,showSelectionPalette:!0,palette:e.prototype.colorPalette,localStorageKey:"youcoach.drilleditor-color2",maxSelectionSize:3,showInitial:!0,showButtons:!1,preferredFormat:"hex",show:function(){o=n.getSelectedElementsPropertyValue("color2")},move:function(t){n.setElementProperty("color2",t.toHexString(),"Color 2",!1),n.updateLastUsedColorsForFigure()},hide:function(t){n.setElementProperty("color2",t.toHexString(),"Color 2",!0,o),o={},n.updateLastUsedColorsForFigure()}});var a={},s={};i.find(".property-skin input").YCSkinChooser({beforeShow:function(){a=n.getSelectedElementsPropertyValue("skin"),s=n.getSelectedElementsPropertyValue("hair")},change:function(t){n.setElementProperties(["skin","hair"],[t.skin,t.hair],"Skin and hair color",!1),n.updateLastUsedColorsForFigure()},beforeHide:function(t){n.setElementProperties(["skin","hair"],[t.skin,t.hair],"Skin and hair color",!0,[a,s]),a={},s={},n.updateLastUsedColorsForFigure()}});var l={};i.find(".property-uniform input").YCUniformChooser({beforeShow:function(){l=n.getSelectedElementsPropertyValue("uniform")},change:function(t){n.setElementProperties(["uniform"],[t],"Uniform",!1)},beforeHide:function(t){n.setElementProperties(["uniform"],[t],"Uniform",!0,[l]),l={},n.updateLastUsedUniformForFigure()},locale:{"T-Shirt":n.t("T-Shirt"),Shorts:n.t("Shorts"),Socks:n.t("Socks"),Stripes:n.t("Stripes")}});var c={};i.find(".property-bgColor input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showInitial:!0,showButtons:!1,allowEmpty:!0,preferredFormat:"hex",showPalette:!0,palette:["#a6c58b","#3389e0","#9f9f9f","#77b55f"],showSelectionPalette:!0,maxSelectionSize:3,show:function(){c=n.getSelectedElementsPropertyValue("bgColor")},move:function(t){n.setElementProperty("bgColor",null!=t?t.toHexString():null,"Background Color",!1)},hide:function(t){n.setElementProperty("bgColor",null!=t?t.toHexString():null,"Background Color",!0,c),c={}}});var u={};i.find(".property-colorField input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showInitial:!0,showButtons:!1,allowEmpty:!0,preferredFormat:"hex",showPalette:!0,palette:["#a6c58b","#3389e0","#9f9f9f","#77b55f","#FF0000","#3B9CCC","#277EA0","#FF9F48"],showSelectionPalette:!0,maxSelectionSize:3,show:function(){u=n.getSelectedElementsPropertyValue("colorField")},move:function(t){n.setElementProperty("colorField",null!=t?t.toHexString():null,"Field",!1)},hide:function(t){n.setElementProperty("colorField",null!=t?t.toHexString():null,"Field",!0,u),u={}}});var h={};i.find(".property-colorFieldAreas input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showInitial:!0,showButtons:!1,allowEmpty:!0,preferredFormat:"hex",showPalette:!0,palette:["#a6c58b","#3389e0","#9f9f9f","#77b55f","#FF0000","#3B9CCC","#277EA0","#FF9F48"],showSelectionPalette:!0,maxSelectionSize:3,show:function(){h=n.getSelectedElementsPropertyValue("colorFieldAreas")},move:function(t){n.setElementProperty("colorFieldAreas",null!=t?t.toHexString():null,"Areas",!1)},hide:function(t){n.setElementProperty("colorFieldAreas",null!=t?t.toHexString():null,"Areas",!0,h),h={}}});var p={};i.find(".property-colorFieldBorder input").spectrum({flat:!1,clickoutFiresChange:!0,showInput:!0,showInitial:!0,showButtons:!1,allowEmpty:!0,preferredFormat:"hex",showPalette:!0,palette:["#a6c58b","#3389e0","#9f9f9f","#77b55f","#FF0000","#3B9CCC","#277EA0","#FF9F48"],showSelectionPalette:!0,maxSelectionSize:3,show:function(){p=n.getSelectedElementsPropertyValue("colorFieldBorder")},move:function(t){n.setElementProperty("colorFieldBorder",null!=t?t.toHexString():null,"Border",!1)},hide:function(t){n.setElementProperty("colorFieldBorder",null!=t?t.toHexString():null,"Border",!0,p),p={}}});var d={};i.find(".property-opacity input").jRange({from:0,to:100,step:5,scale:[0,25,50,75,100],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-opacity input",i).val();n.setElementProperty("opacity",e/100,"Opacity",!1)}},ondragstart:function(){d=n.getSelectedElementsPropertyValue("opacity")},ondragend:function(){var e=t(".property-opacity input",i).val();n.setElementProperty("opacity",e/100,"Opacity",!0,d),d={}}});var f={};i.find(".property-bgOpacity input").jRange({from:0,to:100,step:5,scale:[0,25,50,75,100],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-bgOpacity input",i).val();n.setElementProperty("bgOpacity",e/100,"Background Opacity",!1)}},ondragstart:function(){f=n.getSelectedElementsPropertyValue("bgOpacity")},ondragend:function(){var e=t(".property-bgOpacity input",i).val();n.setElementProperty("bgOpacity",e/100,"Background Opacity",!0,f),f={}}});var g={};i.find(".property-textlabel input").on("focus",function(){g=n.getSelectedElementsPropertyValue("textlabel")}),i.find(".property-textlabel input").on("keyup",function(e){13==e.which&&t(this).blur()}),i.find(".property-textlabel input").on("blur",function(){var t=i.find(".property-textlabel input").val();n.setElementProperty("textlabel",t,"Label",!0,g),g={}});var m={};i.find(".property-text textarea").on("focus",function(){m=n.getSelectedElementsPropertyValue("text")}),i.find(".property-text textarea").on("keyup",function(e){9==e.which&&t(this).blur()}),i.find(".property-text textarea").on("blur",function(){var t=i.find(".property-text textarea").val();n.setElementProperty("text",t,"Text",!0,m),m={}});var y={};i.find(".property-fontSize input").jRange({from:4,to:200,step:2,scale:[2,12,24,75,100],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-fontSize input",i).val();n.setElementProperty("fontSize",e,"Font Size",!1)}},ondragstart:function(){y=n.getSelectedElementsPropertyValue("fontSize")},ondragend:function(){var e=t(".property-fontSize input",i).val();n.setElementProperty("fontSize",e,"Font Size",!0,y),y={}}});var v={};i.find(".property-waveFrequency input").jRange({from:80,to:5,step:2,scale:["Low","Height"],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-waveFrequency input",i).val();n.setElementProperty("waveFrequency",e,"Wave Frequency",!1)}},ondragstart:function(){v=n.getSelectedElementsPropertyValue("waveFrequency")},ondragend:function(){var e=t(".property-waveFrequency input",i).val();n.setElementProperty("waveFrequency",e,"Wave Frequency",!0,v),v={}}});var C={};i.find(".property-waveAmplitude input").jRange({from:0,to:100,step:2,scale:["Auto",25,50,100],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-waveAmplitude input",i).val();e<10&&(e=-1),n.setElementProperty("waveAmplitude",e,"Wave Amplitude",!1)}},ondragstart:function(){C=n.getSelectedElementsPropertyValue("waveAmplitude")},ondragend:function(){var e=t(".property-waveAmplitude input",i).val();n.setElementProperty("waveAmplitude",e,"Wave Amplitude",!0,C),C={}}});var b={};i.find(".property-linesOffset input").jRange({from:10,to:100,step:2,scale:[1,25,50,75,100],format:"%s",width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-linesOffset input",i).val();n.setElementProperty("linesOffset",e,"Lines Offset",!1)}},ondragstart:function(){b=n.getSelectedElementsPropertyValue("linesOffset")},ondragend:function(){var e=t(".property-linesOffset input",i).val();n.setElementProperty("linesOffset",e,"Lines Offset",!0,b),b={}}});var x={};i.find(".property-relativeScale input").jRange({from:.2,to:5,step:.05,scale:["Small","Big"],format:function(t){return parseFloat(t).toFixed(2)},width:190,showLabels:!1,onstatechange:function(){if(!n.updatingProperties){var e=t(".property-relativeScale input",i).val();n.setElementProperty("relativeScale",e,"Scale",!1)}},ondragstart:function(){x=n.getSelectedElementsPropertyValue("relativeScale")},ondragend:function(){var e=t(".property-relativeScale input",i).val();n.setElementProperty("relativeScale",e,"Scale",!0,x),x={}}}),this.updatePropertiesPanel()},e.prototype.updatePropertiesPanel=function(){this.updatingProperties=!0;for(var e=this.$mainElement,n=[],i=0;i<this.commonProperties.length;++i){var r=this.commonProperties[i].name;n.push(r),e.find(".property-"+r).hide()}e.find(".property-colors").hide();var o=this.currentSelection;if(this.editingBackground&&0==o.length&&(o=[this]),0==o.length)n=[];else for(i=0;i<o.length;++i){var a=o[i];n=n.filter(function(t){return-1!=a.elementProperties().indexOf(t)})}for(var s={},l=0;l<n.length;++l)s[n[l]]=null;s.color=o.length<=0?this.lastSelectedColor:null;for(i=0;i<o.length;++i)for(a=o[i],l=0;l<n.length;++l){r=n[l];var c=a.elementProperty(r);null==s[r]&&(s[r]=c)}for(l=0;l<n.length;++l){if(e.find(".property-"+n[l]).show(),"color"===n[l]&&e.find(".property-colors").show(),"color"==n[l]&&(null==s[n[l]]?e.find(".property-color input").spectrum("set","#000000"):e.find(".property-color input").spectrum("set",s[n[l]])),"color2"==n[l]&&(null==s[n[l]]?e.find(".property-color2 input").spectrum("set","#000000"):e.find(".property-color2 input").spectrum("set",s[n[l]])),"opacity"==n[l]){e.find(".property-opacity");var u=100;null!=s[n[l]]&&(u=100*s[n[l]]),e.find(".property-opacity input").val(u),e.find(".property-opacity input").data("plugin_jRange").setValue(u)}if("bgOpacity"==n[l]){e.find(".property-bgOpacity");u=100;null!=s[n[l]]&&(u=100*s[n[l]]),e.find(".property-bgOpacity input").val(u),e.find(".property-bgOpacity input").data("plugin_jRange").setValue(u)}if("stroke"==n[l]){e.find(".property-stroke");u=4;null!=s[n[l]]&&(u=s[n[l]]),t(".property-stroke select",e).val(u),t(".property-stroke span.option.active",e).removeClass("active"),t(".property-stroke span.option[value='"+u+"']",e).addClass("active")}if("lineStyle"==n[l]){e.find(".property-lineStyle");u="solid";null!=s[n[l]]&&(u=s[n[l]]),t(".property-lineStyle select",e).val(u),t(".property-lineStyle span.option.active",e).removeClass("active"),t(".property-lineStyle span.option[value='"+u+"']",e).addClass("active")}if("arrowStyle"==n[l]){e.find(".property-arrowStyle");u="arrow-right";null!=s[n[l]]&&(u=s[n[l]]),t(".property-arrowStyle select",e).val(u),t(".property-arrowStyle span.option.active",e).removeClass("active"),t(".property-arrowStyle span.option[value='"+u+"']",e).addClass("active")}if("textlabel"==n[l]){e.find(".property-textlabel");u="";null!=s[n[l]]&&(u=s[n[l]]),t(".property-textlabel input",e).val(u)}if("text"==n[l]){e.find(".property-text");u="";null!=s[n[l]]&&(u=s[n[l]]),t(".property-text textarea",e).val(u)}if("fontSize"==n[l]){e.find(".property-fontSize");u=12;null!=s[n[l]]&&(u=s[n[l]]),e.find(".property-fontSize input").val(u),e.find(".property-fontSize input").data("plugin_jRange").setValue(u)}if("flip"==n[l]){e.find(".property-flip");u=4;null!=s[n[l]]&&(u=s[n[l]]),t(".property-flip select",e).val(u),t(".property-flip span.option.active",e).removeClass("active"),t(".property-flip span.option[value='"+u+"']",e).addClass("active")}if("waveFrequency"==n[l]){e.find(".property-waveFrequency");u=40;null!=s[n[l]]&&(u=s[n[l]]),e.find(".property-waveFrequency input").val(u),e.find(".property-waveFrequency input").data("plugin_jRange").setValue(u)}if("waveAmplitude"==n[l]){e.find(".property-waveAmplitude");u=-1;null!=s[n[l]]&&(u=s[n[l]]),e.find(".property-waveAmplitude input").val(u),e.find(".property-waveAmplitude input").data("plugin_jRange").setValue(u)}if("linesOffset"==n[l]){e.find(".property-linesOffset");u=1;null!=s[n[l]]&&(u=s[n[l]]),e.find(".property-linesOffset input").val(u),e.find(".property-linesOffset input").data("plugin_jRange").setValue(u)}if("relativeScale"==n[l]){e.find(".property-relativeScale");u=1;null!=s[n[l]]&&(u=s[n[l]]),e.find(".property-relativeScale input").val(u),e.find(".property-relativeScale input").data("plugin_jRange").setValue(u)}if("bgColor"==n[l])void 0!==(u=s[n[l]])&&null!==u&&""!==u||(u=null),e.find(".property-bgColor input").spectrum("set",u);if("colorField"==n[l])void 0!==(u=s[n[l]])&&null!==u&&""!==u||(u=null),e.find(".property-colorField input").spectrum("set",u);if("colorFieldAreas"==n[l])void 0!==(u=s[n[l]])&&null!==u&&""!==u||(u=null),e.find(".property-colorFieldAreas input").spectrum("set",u);if("colorFieldBorder"==n[l])void 0!==(u=s[n[l]])&&null!==u&&""!==u||(u=null),e.find(".property-colorFieldBorder input").spectrum("set",u);if("logoPosition"==n[l]){e.find(".property-logoPosition");u="center";null!=s[n[l]]&&(u=s[n[l]]),t(".property-logoPosition select",e).val(u),t(".property-logoPosition span.option.active",e).removeClass("active"),t(".property-logoPosition span.option[value='"+u+"']",e).addClass("active")}if("skin"==n[l]){var h=void 0===s.skin||null===s.skin?"#D3AB9B":s.skin,p=void 0===s.hair||null===s.hair?"#000000":s.hair;e.find(".property-skin input").YCSkinChooser("setValue",[{skin:h,hair:p}])}if("uniform"==n[l]){var d=void 0===s.uniform||null===s.uniform?{}:s.uniform;e.find(".property-uniform input").YCUniformChooser("setValue",[d]);var f=this.getLastUsedUniformsForFigure().slice(-4).reverse();e.find(".property-uniform input").YCUniformChooser("setPresets",[f]),"coaches"==o[0].elementType||"referees"==o[0].elementType?e.find(".property-uniform input").YCUniformChooser("setMode",["bicolor"]):e.find(".property-uniform input").YCUniformChooser("setMode",["full"])}}this.updateLastUsedColorsForFigure(),e.find(".properties > .edit-property").css({"margin-top":null}),e.find(".properties > .edit-property:visible:first").css({"margin-top":"0px"}),e.find(".properties").css({padding:0===e.find(".properties > .edit-property:not(.properties-container):visible").size()?"0px":"10px"}),this.updatingProperties=!1}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.timelineVisible=!0,e.prototype.initAnimator=function(){this.timeline={max_duration:120,selectedKeyFrameTime:0,currentKeyFrameTime:0,tick_size:25,time_left:10,keyframes:[],total_duration:10,animatedDataFrames:[],animating:!1},this.timeline.totalWidth=this.timeline.max_duration*this.timeline.tick_size+20},e.prototype.createMainUITimeline=function(){var e=this,n=t("<div></div>").addClass("timeline-wrapper"),i=t('<div class="animator-controls"><span class="yceditor-play"></span><span class="yceditor-pause"></span></div>');n.append(i);var r=t("<div></div>").addClass("timeline-container"),o=t('<div class="timeline"><div class="key-frames-background"></div><div class="time-axis"></div><div class="anim-start"></div><div class="anim-end"></div><div class="key-frames"> <div class="key-frame first-frame"></div></div><div class="current-frame"></div></div>');r.append(o),n.append(r),this.$mainElement.append(n),t(".animator-tool",this.$mainElement).on("click",function(){e.toggleTimeline()}),e.toggleTimeline(),e.initTimeline(),t(".yceditor-play",this.$mainElement).on("click",function(){e.playAnimation()}),t(".yceditor-pause",this.$mainElement).on("click",function(t){e.stopAnimation()})},e.prototype.toggleTimeline=function(){this.timelineVisible?(t(".timeline-wrapper",this.$mainElement).slideUp(),this.timelineVisible=!1):(t(".timeline-wrapper",this.$mainElement).slideDown(),this.timelineVisible=!0),this.recalculateDesignArea()},e.prototype.initTimeline=function(){for(var e=this,n=0;n<=this.timeline.max_duration;++n){var i=t('<div class="time-axis-tick">'+n+"</div>");i.css("left",n*this.timeline.tick_size+10),t(".timeline .time-axis",this.$mainElement).append(i)}t(".timeline",this.$mainElement).css("left",0),t(".timeline",this.$mainElement).css("width",this.timeline.totalWidth),t(".timeline",this.$mainElement).on("click",function(){e.timeline.animating&&e.stopAnimation()}),t(".timeline",this.$mainElement).draggable({addClasses:!1,axis:"x",drag:function(n,i){var r=-(e.timeline.totalWidth-t(".timeline-container",e.$mainElement).width());i.position.left>0?i.position.left=0:i.position.left<r&&(i.position.left=r)}}),t(".anim-end",this.$mainElement).draggable({addClasses:!1,axis:"x",grid:[25,0],drag:function(n,i){var r=5*e.timeline.tick_size+10,o=e.timeline.totalWidth-10;i.position.left<r?i.position.left=r:i.position.left>o&&(i.position.left=o),t(".key-frames",e.$mainElement).width(i.position.left-10),t(".key-frames-background",e.$mainElement).width(i.position.left-10),t(".current-frame",e.$mainElement).position().left>i.position.left&&t(".current-frame",e.$mainElement).css("left",i.position.left),e.timeline.currentKeyFrameTime=Math.floor((t(".current-frame",e.$mainElement).position().left-e.timeline.time_left)/e.timeline.tick_size),e.updateSelectedFrame(),e.timeline.total_duration=(i.position.left-10)/e.timeline.tick_size}}),t(".current-frame",this.$mainElement).draggable({addClasses:!1,axis:"x",grid:[25,0],drag:function(n,i){var r=e.timeline.time_left,o=t(".anim-end",e.$mainElement).position().left;i.position.left<r?i.position.left=r:i.position.left>o&&(i.position.left=o);var a=(i.position.left-e.timeline.time_left)/e.timeline.tick_size;e.timeline.currentKeyFrameTime!==a&&(e.timeline.currentKeyFrameTime=a,e.updateSelectedFrame(),e.updateScene(e.timeline.currentKeyFrameTime))}}),this.addKeyframe(0),this.updateSelectedFrame(!0)},e.prototype.updateScene=function(t){for(var e=0;e<this.elements.length;++e)"function"==typeof this.elements[e].setCurrentFrame&&this.elements[e].setCurrentFrame(t);this.updatePropertiesPanel()},e.prototype.addKeyframe=function(e){var n=this;void 0===e&&(e=n.timeline.currentKeyFrameTime);var i=0===e;if(null===this.getTimelineKeyFrameAt(e)){var r=t('<div id="frame_'+e+'" class="key-frame"></div>');if(r.css("left",e*n.timeline.tick_size),t(".key-frames",this.$mainElement).append(r),i)r.addClass("first-frame");else{var o=0;r.draggable({addClasses:!1,grid:[25,1],start:function(e,i){o=t(this).position().left/n.timeline.tick_size},stop:function(e,i){var r=t(this).position().left/n.timeline.tick_size;i.position.top<-n.timeline.time_left||i.position.top>40?(n.removeKeyFrameAtTime(r),n.updateSelectedFrame(),n.updateScene(n.timeline.currentKeyFrameTime)):(t(this).css("top",14),r<0&&t(this).css("left",o*n.timeline.tick_size),r>n.timeline.total_duration&&n.setAnimationTotalDuration(r),n.moveKeyFrameFromTimeTo(o,r),n.updateSelectedFrame(),n.updateScene(n.timeline.currentKeyFrameTime))}})}r.on("click",function(){var e=t(this).position().left/n.timeline.tick_size;n.setCurrentKeyFrameTime(e)}),n.timeline.keyframes.push({time:e,element:r[0]}),n.timeline.keyframes.sort(function(t,e){return parseFloat(t.time)-parseFloat(e.time)}),n.updateSelectedFrame()}},e.prototype.setCurrentKeyFrameTime=function(e){this.timeline.currentKeyFrameTime!==e&&(t(".current-frame",this.$mainElement).css("left",e*this.timeline.tick_size+this.timeline.time_left),this.timeline.currentKeyFrameTime=e,this.updateSelectedFrame(),this.updateScene(this.timeline.currentKeyFrameTime))},e.prototype.getTimelineKeyFrameAt=function(t){for(var e=0;e<this.timeline.keyframes.length;++e)if(this.timeline.keyframes[e].time==t)return this.timeline.keyframes[e];return null},e.prototype.removeKeyFrameAtTime=function(e){if(0!=e){var n=this.getTimelineKeyFrameAt(e);t(n.element).remove();var i=t.inArray(n,this.timeline.keyframes);i>-1&&this.timeline.keyframes.splice(i,1);for(var r=this.currentSelection,o=0;o<r.length;++o){var a=r[o];void 0!==a.keyFrames&&(a.keyFrames.hasOwnProperty(e),1)&&delete a.keyFrames[e]}}},e.prototype.setAnimationTotalDuration=function(e){var n=e*this.timeline.tick_size;t(".key-frames",this.$mainElement).width(n),t(".key-frames-background",this.$mainElement).width(n),t(".anim-end",this.$mainElement).css("left",n+10),this.timeline.total_duration=e},e.prototype.moveKeyFrameFromTimeTo=function(e,n){if(0!==e){for(var i=this.getTimelineKeyFrameAt(e),r=this.currentSelection,o=0;o<r.length;++o){var a=r[o];if(void 0!==a.keyFrames&&(a.keyFrames.hasOwnProperty(e),1)){var s=a.keyFrames[e];if(delete a.keyFrames[e],null!==this.getTimelineKeyFrameAt(n)){t(i.element).remove();var l=t.inArray(i,this.timeline.keyframes);l>-1&&this.timeline.keyframes.splice(l,1)}else i.time=n;a.keyFrames[n]=s}}this.timeline.keyframes.sort(function(t,e){return parseFloat(t.time)-parseFloat(e.time)})}},e.prototype.updateSelectedFrame=function(e){void 0===e&&(e=!1);for(var n=this.timeline.currentKeyFrameTime,i=this.timeline.keyframes.length-1;i>=0;--i)if(this.timeline.keyframes[i].time<=n){(this.timeline.keyframes[i].time!=this.timeline.selectedKeyFrameTime||e)&&(t(".key-frame.current",this.$mainElement).removeClass("current"),t(this.timeline.keyframes[i].element).addClass("current"),this.timeline.selectedKeyFrameTime=this.timeline.keyframes[i].time);break}},e.prototype.playAnimation=function(e){this.stopAnimation(),void 0===e&&(e=!1);var n=this;t(".yceditor-play",this.$mainElement).addClass("active-button"),this.timeline.animating=!0,this.setSelection([]);var i=t(".current-frame",this.$mainElement);i.css("left",this.timeline.time_left);var r=n.timeline.total_duration,o=this.timeline.time_left+r*this.timeline.tick_size;this.timeline.animatedDataFrames=[],i.animate({left:o},{duration:1e3*r*this.options.slowMotion,fail:function(t){},easing:"linear",progress:function(){var t=Math.floor((i.position().left-n.timeline.time_left)/n.timeline.tick_size);n.timeline.currentKeyFrameTime!==t&&(n.timeline.currentKeyFrameTime=t,n.updateSelectedFrame())},complete:function(){n.stopAnimation()}});for(var a=0;a<this.elements.length;++a)this.animateElement(this.elements[a]);e&&setTimeout(function(){n.playAnimation(e)},1e3*r*this.options.slowMotion+500),n.$element.trigger("yceditor.animation.play",[n])},e.prototype.stopAnimation=function(){var e=this;t(".yceditor-play",this.$mainElement).removeClass("active-button"),this.timeline.animating=!1;var n=t(".current-frame",this.$mainElement);n.stop();for(var i=0;i<this.timeline.animatedDataFrames.length;++i)this.timeline.animatedDataFrames[i].transition().duration(0);n.css("left",e.timeline.time_left),e.timeline.currentKeyFrameTime=0,e.updateSelectedFrame(),setTimeout(function(){e.updateScene(e.timeline.currentKeyFrameTime)},40),e.$element.trigger("yceditor.animation.stop",[e])},e.prototype.calculateTransformation=function(t){var e="translate("+t.x+","+t.y+") ";return void 0!==t.scale&&(e+="scale("+t.scale+") "),void 0!==t.rotate&&(e+="rotate("+t.rotate+") "),e},e.prototype.animateElement=function(t,e){if(void 0!==t.keyFrames){var n=[];for(var i in t.keyFrames)n.push(i);n.sort(function(t,e){return parseFloat(t)-parseFloat(e)});for(var r=null,o=0,a=[],s=0;s<n.length;++s){var l=n[s];if(!(l<e))if(null!=r){var c=t.keyFrames[l],u=l-o;a.push({duration:1e3*u*this.options.slowMotion,frameData:c,previousFrameData:r,element:t}),o=l,r=c}else r=t.keyFrames[l],o=l}this.processAnimation(a)}},e.prototype.processAnimation=function(t){var e=this;if(0!=this.timeline.animating&&t.length>0){var n=t[0];t=t.slice(1),void 0!==n.element.animate&&n.element.animate(n.duration,n.previousFrameData,n.frameData),setTimeout(function(){e.processAnimation(t)},n.duration)}},e.prototype.updateTimeline=function(){t(".key-frame").remove(),this.timeline.keyframes=[],this.addKeyframe(0);for(var e=this.currentSelection,n=0;n<e.length;++n){var i=e[n];if(void 0!==i.keyFrames)for(var r in i.keyFrames)this.addKeyframe(r)}this.updateSelectedFrame(!0)},e.prototype.addUndoKeyframe=function(t,e){}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.createMainUI=function(){this.$mainElement.addClass("yc-drill-editor"),"viewer"!=this.options.mode&&this.createMainUIToolbar(),this.createMainUIDesignArea(),"viewer"!=this.options.mode&&this.createMainUISidebar(),"viewer"!=this.options.mode&&this.createMainUITimeline(),this.options.resizable&&this.$mainElement.append(t('<div class="grips ui-resizable-handle ui-resizable-se"></div>'))},e.prototype.createMainUIDesignArea=function(){var e=t("<div></div>").addClass("designer");this.$element=t("<div></div>").addClass("designer-area"),e.append(this.$element),this.$mainElement.append(e)},e.prototype.createMainUIToolbar=function(){this.toolbar=t("<div></div>").addClass("toolbar");var e=t("<ul></ul>").addClass("toolbar-group"),n=t("<li></li>").addClass("designer-tool").addClass("selection-tool").addClass("selected").attr("title",this.t("Selection Tool"));e.append(n);var i=t("<li></li>").addClass("designer-tool").addClass("pen-tool").attr("title",this.t("Free Pen Tool"));e.append(i);var r=t("<li></li>").addClass("designer-tool").addClass("arrow-tool").attr("title",this.t("Arrow Tool"));e.append(r);var o=t("<li></li>").addClass("separator");e.append(o);var a=t("<li></li>").addClass("designer-tool").addClass("move-up-tool").addClass("disabled").attr("title",this.t("Move Up"));e.append(a);var s=t("<li></li>").addClass("designer-tool").addClass("move-down-tool").addClass("disabled").attr("title",this.t("Move Down"));e.append(s),o=t("<li></li>").addClass("separator"),e.append(o),e.append(t("<li></li>").addClass("designer-tool").addClass("editor-cut").addClass("disabled").attr("title",this.t("Cut"))),e.append(t("<li></li>").addClass("designer-tool").addClass("editor-copy").addClass("disabled").attr("title",this.t("Copy"))),e.append(t("<li></li>").addClass("designer-tool").addClass("editor-paste").addClass("disabled").attr("title",this.t("Paste"))),o=t("<li></li>").addClass("separator"),e.append(o),e.append(t("<li></li>").addClass("designer-tool").addClass("trash-tool").addClass("disabled").attr("title",this.t("Delete selected element(s)"))),o=t("<li></li>").addClass("separator"),e.append(o),e.append(t("<li></li>").addClass("designer-tool").addClass("animator-tool").addClass("enabled").attr("title",this.t("Animator"))),this.toolbar.append(e);var l=t("<div></div>").addClass("toolbar-group-2"),c=t("<a></a>").addClass("editor-fullscreen").attr("title",this.t("Enter/Exit Full Screen"));l.append(c),this.toolbar.append(l);var u=t("<div></div>").addClass("toolbar-group-1"),h=t("<a></a>").addClass("editorUndo").addClass("disabled");u.append(h);var p=t("<a></a>").addClass("editorRedo").addClass("disabled");u.append(p),this.toolbar.append(u),this.$mainElement.append(this.toolbar)},e.prototype.createMainUISidebar=function(){for(var e=t("<div></div>").addClass("sidebar"),n=t("<select></select>").attr("name","palette_content_select").addClass("palette_content_select").attr("tabindex","1"),i=this.palette_categories,r=0;r<i.length;++r){for(var o=i[r],a=t("<optgroup></optgroup>").attr("label",this.t(o.label)),s=0,l=0;l<o.options.length;++l){var c=o.options[l];if(!(t.inArray(c.name,this.options.hiddenCategories)>=0)){var u=t("<option></option>").attr("value",c.name).html(this.t(c.label));a.append(u),s++}}s>0&&n.append(a)}e.append(n);for(var h=t("<div></div>").addClass("palette"),p=t("<div></div>").addClass("direction-selector"),d=t("<select></select>").addClass("segment-select").addClass("direction-selector-select"),f=["left","down","up","right"],g=0;g<f.length;++g)d.append(t('<option value="'+f[g]+'">'));p.append(d);var m=t("<ul></ul>").addClass("figures");h.append(m),e.append(p),e.append(h),this.createMainUIProperties(e),this.$mainElement.append(e)},e.prototype.createMainUIProperties=function(e){for(var n=t("<div></div>").addClass("properties"),i=0;i<this.commonProperties.length;++i){var r=this.commonProperties[i],o=r.name,a=t("<div></div>").addClass("edit-property");if("color2"!==o&&("skin"!==o&&"hair"!==o)){if("color"===o?a.addClass("property-colors"):"uniform"===o?a.addClass("property-uniform-and-skin").addClass("properties-container"):a.addClass("property-"+o),""!==r.label){var s=t("<span></span>").addClass("property-label").html(this.t(r.label));a.append(s)}if("uniform"===r.type){var l=t("<div></div>").addClass("property-uniform").css("float","left"),c=t("<input></input").attr("type","text").addClass("yc-uniform-picker").attr("name","uniform");l.append(c),a.append(l);var u=t("<div></div>").addClass("property-skin").css("float","left"),h=t("<input></input").attr("type","text").addClass("yc-skin-picker").attr("name","skin");u.append(h),a.append(u)}else if("color"===r.type){var p=t("<div></div>").addClass("property-color").css("float","left"),d=t("<input></input").attr("type","text").addClass("yc-color-picker").attr("name","color1");p.append(d),a.append(p);var f=t("<div></div>").addClass("property-color2").css("float","left"),g=t("<input></input").attr("type","text").addClass("yc-color-picker").attr("name","color2");f.append(g),a.append(f)}else if("bgColor"===r.type){var m=t("<input></input").attr("type","text").addClass("yc-color-picker").attr("name","bgColor");a.append(m)}else if("range"===r.type){m=t("<input></input").attr("type","hidden").addClass("slider-input").attr("name",o);a.append(m)}else if("segment"===r.type){m=t("<select></select>").addClass("segment-select");for(var y=0;y<r.options.length;++y)m.append(t('<option value="'+r.options[y]+'">'));a.append(m)}else if("title"===r.type){var v=t("<ul></ul>").addClass("toolbar-group"),C=t('<li><span class="l1">'+this.t("Edit Field Position")+'</span><span class="l2">'+this.t("Editing...")+"</span></li>").addClass("designer-tool").addClass("background-move-tool").attr("title",this.t("Click to edit the field position"));v.append(C),a.append(v)}else if("input"===r.type){m=t("<input></input").attr("type","text").addClass("text-input").attr("name",o);a.append(m)}else if("text"===r.type){m=t("<textarea></textarea").attr("type","text").addClass("text-input").attr("name",o);a.append(m)}n.append(a)}}e.append(n)},e.prototype.setupTools=function(){var t=this;this.penTool=new YCEditorPenAction(this),this.arrowTool=new YCEditorArrowAction(this),this.backgroundMoveTool=new YCEditorMoveBackgroundAction(this),this.toolbar.find(".selection-tool").on("click touchstart",function(){t.setSelectedTool(null)}),this.toolbar.find(".trash-tool").on("click touchstart",function(){t.deleteSelectedElements()}),this.toolbar.find(".move-up-tool").on("click touchstart",function(){t.moveUpElements()}),this.toolbar.find(".move-down-tool").on("click touchstart",function(){t.moveDownElements()}),this.toolbar.find(".editor-cut").on("click touchstart",function(e){e.preventDefault(),t.doCutElements()}),this.toolbar.find(".editor-copy").on("click touchstart",function(e){e.preventDefault(),t.doCopyElements()}),this.toolbar.find(".editor-paste").on("click touchstart",function(e){e.preventDefault(),t.doPasteElements()}),this.toolbar.find(".editorUndo").on("click touchstart",function(e){e.preventDefault(),t.doUndo()}),this.toolbar.find(".editorRedo").on("click touchstart",function(e){e.preventDefault(),t.doRedo()}),this.toolbar.find(".editor-fullscreen").on("click touchstart",function(e){e.preventDefault(),t.toggleFullscreen()})}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.translations={},e.prototype.translations.en={"Selection Tool":"Selection Tool","Free Pen Tool":"Free Pen Tool","Arrow Tool":"Arrow Tool","Move Up":"Move Up","Move Down":"Move Down","Delete selected element(s)":"Delete selected element(s)","Enter/Exit Full Screen":"Enter/Exit Full Screen",Players:"Players",Materials:"Materials",Fields:"Fields","Players (Male)":"Players (Male)","Players (Female)":"Players (Female)","Goalkeepers (Male)":"Goalkeepers (Male)","Goalkeepers (Female)":"Goalkeepers (Female)",Futsal:"Futsal",Coaches:"Coaches",Referees:"Referees",Children:"Children","Preparation (Male)":"Preparation (Male)","Preparation (Female)":"Preparation (Female)","Players (from top)":"Players (from top)","Text and Numbers":"Text and Numbers","Arrows and Shapes":"Arrows and Shapes","Fields 11":"Fields 11",Cut:"Cut",Copy:"Copy",Paste:"Paste",pass:"Pass",kick:"Kicking",run:"Running",stand:"Standing",dribbling:"Dribbling",throwin:"Throw In",special:"Special",long_pass:"Long Pass",goalkeeper:"Catch",with_ball:"With Ball","material.balls":"Balls","material.speedladder":"Speed Ladders","material.speedhurdle":"Speed Hurdles","material.goals":"Goals","material.bose":"Bose","material.target":"Target","material.wall":"Wall",Flip:"Flip","T-Shirt":"T-Shirt",Shorts:"Shorts",Socks:"Socks",Stripes:"Stripes"},e.prototype.translations.it={"Selection Tool":"Strumento di selezione","Free Pen Tool":"Strumento disegno libero","Arrow Tool":"Strumento freccia","Move Up":"Porta in primo piano","Move Down":"Porta in secondo piano","Delete selected element(s)":"Elimina gli elementi selezionati","Enter/Exit Full Screen":"Attiva/Disattiva modalitá schermo intero",Players:"Giocatori",Materials:"Materiali",Fields:"Campi","Players (Male)":"Giocatori (Uomini)","Players (Female)":"Giocatrici (Donne)","Goalkeepers (Male)":"Portieri (Uomini)","Goalkeepers (Female)":"Portieri (Donne)",Futsal:"Calcio a 5",Coaches:"Allenatori",Referees:"Arbitri",Children:"Bambini","Preparation (Male)":"Preparazione (Uomini)","Preparation (Female)":"Preparazione (Donne)","Players (from top)":"Giocatori dall'alto","Text and Numbers":"Testo e Numeri","Arrows and Shapes":"Frecce e forme","Fields 11":"Calcio a 11",Cut:"Taglia",Copy:"Copia",Paste:"Incolla",pass:"Passaggio",kick:"Tiro",run:"Corsa",stand:"In posizione",dribbling:"Dribbling",throwin:"Rimessa",special:"Speciale",long_pass:"Pass. Lungo",goalkeeper:"Parata",with_ball:"Con la Palla","Edit Field Position":"Modifica Posizione Campo","Editing position...":"In modifica...","Click to edit the field position":"Clicca per modificare la posizione del campo","Background Properties":"Proprietá dello sfondo","Solid Background":"Sfondo tinta unita",Field:"Campo",Areas:"Aree",Border:"Bordo campo",Scale:"Scala","Logo Position":"Posizione Logo","material.balls":"Palloni","material.speedladder":"Speed Ladder","material.speedhurdle":"Ostacoli","material.goals":"Porte","material.bose":"Medusa","material.target":"Sagoma","material.wall":"Barriera",Flip:"Inverti","T-Shirt":"Maglia",Shorts:"Pantaloncini",Socks:"Calzini",Stripes:"Righe"},e.prototype.translations.ja={"Selection Tool":"ツール選択","Free Pen Tool":"ペン","Arrow Tool":"矢印","Move Up":"手前に持って来る","Move Down":"奥に持っていく","Delete selected element(s)":"選択した箇所を削除する","Enter/Exit Full Screen":"スクリーンを拡縮",Players:"プレイヤー",Materials:"マテリアル",Fields:"ピッチ","Players (Male)":"プレイヤー(男性)","Players (Female)":"プレイヤー(女性)","Goalkeepers (Male)":"ゴールキーパー(男性)","Goalkeepers (Female)":"ゴールキーパー(女性)",Futsal:"フットサル",Coaches:"コーチ",Referees:"レフリー",Children:"子供","Preparation (Male)":"動作(男性)","Preparation (Female)":"動作(女性)","Players (from top)":"プレイヤー(上からの視点)","Text and Numbers":"テキストと数字","Arrows and Shapes":"矢印と図形","Fields 11":"11人制ピッチ",Cut:"カット",Copy:"コピー",Paste:"ペースト",pass:"パス動作",kick:"キック動作",run:"ランニング動作",stand:"スタンディング動作",dribbling:"ドリブル動作",throwin:"スローイン動作",special:"スペシャル",long_pass:"ロングパス",goalkeeper:"ゴールキーパー",with_ball:"ボール付き","Edit Field Position":"フィールドポジション編集","Editing position...":"ポジション編集中","Click to edit the field position":"フィールドポジション編集をする","Background Properties":"フィールドのプロパティ","Solid Background":"フィールドの色",Field:"Field",Areas:"Areas",Border:"Border",Scale:"大きさ","Logo Position":"ロゴポジション","material.balls":"ボール","material.speedladder":"ラダー","material.speedhurdle":"ホールダー","material.goals":"ゴール","material.bose":"バランスボール","material.target":"ターゲット","material.wall":"壁",Flip:"反対にする","T-Shirt":"Tシャツ",Shorts:"ハーフパンツ",Socks:"ソックス",Stripes:"ストライプ"},e.prototype.translations.hu={"Selection Tool":"Kiválasztó eszköz","Free Pen Tool":"Szabadkézi toll eszköz","Arrow Tool":"Nyíl eszköz","Move Up":"Előrehozás","Move Down":"Hátrébb küldés","Delete selected element(s)":"Kiválasztott elem(ek) törlése","Enter/Exit Full Screen":"Teljes képernyős mód BE/KI",Players:"Játékosok",Materials:"Eszközök",Fields:"Pályák","Players (Male)":"Játékosok (Férfiak)","Players (Female)":"Játékosok (Nők)","Goalkeepers (Male)":"Kapusok (Férfiak)","Goalkeepers (Female)":"Kapusok (Nők)",Futsal:"Teremfoci",Coaches:"Edzők",Referees:"Játékvezetők",Children:"Gyermekek","Preparation (Male)":"Felkészítés (Férfiak)","Preparation (Female)":"Felkészítés (Nők)","Players (from top)":"Játékosok (fentről)","Text and Numbers":"Szöveg és számok","Arrows and Shapes":"Nyilak és alakzatok","Fields 11":"Nagypályás foci",Cut:"Kivágás",Copy:"Másolás",Paste:"Beillesztés",pass:"passzolás",kick:"lövés",run:"futás",stand:"állás",dribbling:"cselezés",throwin:"bedobás",special:"speciális",long_pass:"hosszú átadás",goalkeeper:"hárítás",with_ball:"labdával","Edit Field Position":"Pályán elfoglalt hely módosítása","Editing position...":"Módosítás folyamatban…","Click to edit the field position":"Kattints a pályán elfoglalt hely módosításához","Background Properties":"Háttér tulajdonságai","Solid Background":"Egyszínű háttér",Scale:"Méretezés","Logo Position":"Logo helye","material.balls":"Labdák","material.speedladder":"Koordinációs létra","material.speedhurdle":"Gátak","material.goals":"Kapuk","material.bose":"Egyensúlypárna","material.target":"Sorfalbábu","material.wall":"Sorfal",Flip:"Tükrözés","T-Shirt":"Póló",Shorts:"Rövidnadrág",Socks:"Zokni",Stripes:"Csíkok"},e.prototype.translations.es={"Selection Tool":"Instrumento de selección","Free Pen Tool":"Instrumento de dibujo libre","Arrow Tool":"Instrumento flecha","Move Up":"Primer plano","Move Down":"Segundo plano","Delete selected element(s)":"Eliminar los elementos seleccionados","Enter/Exit Full Screen":"Activar/Desactivar pantalla completa",Players:"Jugadores",Materials:"Material",Fields:"Campos","Players (Male)":"Jugadores (Hombres)","Players (Female)":"Jugadoras (Mujeres)","Goalkeepers (Male)":"Porteros (Hombres)","Goalkeepers (Female)":"Porteros (Mujeres)",Futsal:"Fútbol Sala",Coaches:"Entrenadores",Referees:"Arbitros",Children:"Niños","Preparation (Male)":"Preparación (Hombres)","Preparation (Female)":"Preparación (Mujeres)","Players (from top)":"Jugadores vista aérea","Text and Numbers":"Texto y numeros","Arrows and Shapes":"Flechas y figuras","Fields 11":"Fútbol once",Cut:"Cortar",Copy:"Copiar",Paste:"Pegar",pass:"Pase",kick:"Tiro",run:"Carrera",stand:"En posición",dribbling:"Dribbling",throwin:"©",special:"Acrobacia",long_pass:"Pase largo",goalkeeper:"Parada",with_ball:"Con el balón","Edit Field Position":"Modificar posición en el campo","Editing position...":"Modificando posición","Click to edit the field position":"Clicar para modificar la posición del campo","Background Properties":"Propiedad del fondo","Solid Background":"Fondo con tinta unida",Field:"Field",Areas:"Áreas",Border:"Borde",Scale:"Escala","Logo Position":"Posición escudo","material.balls":"Balones","material.speedladder":"Escalera","material.speedhurdle":"Obstáculos","material.goals":"Porterías","material.bose":"Medusa","material.target":"Silueta","material.wall":"Barrera",Flip:"Invertir","T-Shirt":"Camiseta",Shorts:"Pantalones",Socks:"Calcetas",Stripes:"Líneas"},e.prototype.translations.jp=e.prototype.translations.ja,e.prototype.t=function(t,e){void 0===e?e=[]:Array.isArray(e)||(e=[e]);var n=t;void 0!==this.translations[this.options.locale]&&void 0!==this.translations[this.options.locale][t]&&(n=this.translations[this.options.locale][t]);for(var i=0;i<e.length;++i)n=n.replaceAll("{0}",e[i]);return n}}(jQuery,YCEditor),function(t,e){"use strict";e.prototype.plugins.push(function(t){t.animElements=function(){for(var e=t.elements,n=0;n<e.length;++n)e[n].move(100*Math.random(),100*Math.random(),!0,1e3+5e3*Math.random())}})}(jQuery,YCEditor),function(t,e){"use strict";var n=function(e){var n=250;"viewer"===e.options.mode&&(n=0,e.updateLogoPosition(!1)),e.useFigcLogo?(d3.select(".logo-layer",e.logoLayer).attr("opacity",.4),d3.selectAll("#yceditor_yclogo, .special_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",0),0==d3.select("#figc_logo_svg",e.logoLayer).size()&&(e.figcLogoWrapper=e.logoLayer.append("g").attr("transform","translate(0, -200)").attr("id","figc_logo_svg").attr("class","special_logo_svg"),t(e.figcLogoWrapper.node()).prepend(t(e.logoFIGC)),d3.select("#figc_logo_svg",e.logoLayer).attr("opacity",0)),d3.select("#figc_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",1)):(d3.select(".logo-layer",e.logoLayer).attr("opacity",.1),d3.select("#yceditor_yclogo",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",1),d3.selectAll(".special_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",0))},i=function(t){t.logoFIGC='<svg width="100%" height="100%" viewBox="0 0 1080 472" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">\n <path d="M513.46,378.16C519.18,373.53 522.71,370.91 524.03,370.31C525.36,369.71 526.52,369.78 527.51,370.52C528.5,371.26 529.14,372.22 529.41,373.4C529.68,374.58 529.55,377.23 529.02,381.34C528.48,385.45 528.63,387.09 529.45,386.26C530.27,385.43 531.47,384.57 533.05,383.67C534.62,382.78 536.62,381.77 539.04,380.67C541.46,379.56 543.76,378.98 545.96,378.93C548.16,378.88 549.86,379.26 551.07,380.08C552.28,380.9 553.06,381.59 553.42,382.15C553.78,382.7 554.26,383.51 554.87,384.55C555.48,385.6 555.79,386.24 555.81,386.48C555.83,386.72 555.94,387.23 556.15,388C556.35,388.77 556.4,390.08 556.29,391.91C556.17,393.75 555.63,396 554.66,398.66C553.69,401.33 552.1,403.88 549.91,406.31C547.71,408.74 545.8,410.51 544.18,411.62C542.55,412.73 540.8,413.74 538.92,414.66C537.04,415.58 535.07,416.29 533.01,416.78C530.95,417.27 529.29,417.12 528.01,416.34C526.74,415.56 526.03,414.6 525.9,413.48C525.77,412.36 526.01,411.04 526.64,409.54C527.27,408.04 527.92,406.69 528.61,405.49C529.3,404.29 530.5,402.85 532.21,401.15C533.92,399.45 535.75,398.07 537.68,397C539.62,395.94 541.16,395.23 542.3,394.89C543.44,394.55 542.74,395.42 540.2,397.5C537.66,399.58 535.46,401.6 533.6,403.55C531.74,405.5 531.2,406.86 531.99,407.62C532.78,408.38 534.08,408.32 535.9,407.43C537.72,406.55 540.26,404.17 543.54,400.3C546.82,396.43 547.71,393.27 546.22,390.82C544.73,388.37 542.25,387.96 538.78,389.61C535.31,391.26 532.28,393.43 529.69,396.14C527.1,398.85 524.6,404.08 522.18,411.83C519.76,419.58 518.06,425.31 517.07,429.01C516.08,432.71 514.79,437.8 513.19,444.28C511.59,450.76 509.61,457.08 507.26,463.24C504.91,469.4 502.79,472.21 500.92,471.65C499.05,471.09 497.85,470.21 497.33,469.02C496.81,467.83 496.58,466.54 496.63,465.16C496.68,463.78 497.09,462 497.87,459.83C498.65,457.66 499.64,454.08 500.86,449.08C502.08,444.08 504.73,434.43 508.81,420.13C512.9,405.83 515.32,397.35 516.09,394.7C516.86,392.05 517.81,388.16 518.94,383.03C520.08,377.9 520.03,375.62 518.81,376.17C517.58,376.73 514.95,378.33 510.92,380.99C506.88,383.65 507.73,382.7 513.46,378.13L513.46,378.16ZM700.45,358.9C705.54,358.8 707.65,359.89 706.78,362.17C705.91,364.45 705.17,368.37 704.56,373.94C703.94,379.5 703.32,384.22 702.7,388.1C702.07,391.98 701.06,396.1 699.65,400.45C698.24,404.81 697.14,408.18 696.35,410.55C695.56,412.93 694.55,415.61 693.34,418.61C692.12,421.61 690.05,425.89 687.13,431.45C684.21,437.01 680.71,441.88 676.63,446.06C672.55,450.24 669.16,452.83 666.46,453.82C663.76,454.82 660.63,454.85 657.07,453.92C653.51,452.99 651.42,450.49 650.78,446.41C650.15,442.33 654.38,435.21 663.48,425.05C672.58,414.89 673.15,414.49 665.18,423.87C657.22,433.24 653.31,439.55 653.45,442.77C653.59,446 654.49,447.78 656.14,448.11C657.79,448.45 659.39,448.24 660.94,447.48C662.49,446.72 664.55,445.08 667.12,442.55C669.69,440.02 671.82,437.68 673.53,435.53C675.24,433.38 677.24,430.14 679.55,425.81C681.86,421.48 683.88,416.89 685.63,412.05C687.38,407.21 688.56,403.86 689.19,401.98C689.82,400.1 690.91,396.2 692.45,390.28C694,384.36 693.56,382.92 691.14,385.95C688.72,388.99 685.48,392.35 681.43,396.05C677.38,399.75 673.99,402.16 671.27,403.29C668.54,404.42 666.43,404.85 664.92,404.57C663.41,404.29 662.04,403.57 660.8,402.4C659.56,401.23 659.14,398.76 659.53,394.97C659.92,391.18 661.33,386.58 663.75,381.17C666.17,375.76 669.17,371.5 672.76,368.4C676.35,365.3 679.59,363.03 682.5,361.61C685.41,360.19 687.72,359.43 689.43,359.35C691.14,359.27 693.12,359.6 695.35,360.33C697.58,361.06 699.28,360.59 700.44,358.9L700.45,358.9ZM570.01,382.82C571.64,373.1 573.61,368.25 575.92,368.25C578.23,368.25 580.04,369.13 581.37,370.87C582.69,372.61 582.77,374.9 581.61,377.72C580.44,380.54 580.42,381.82 581.53,381.55C582.64,381.28 584.07,380.47 585.81,379.11C587.55,377.75 589.23,376.64 590.84,375.78C592.45,374.92 593.76,374.34 594.77,374.04C595.78,373.75 597.77,373.92 600.76,374.55C603.74,375.18 606.6,376.19 609.34,377.57C612.08,378.95 615.52,378.79 619.68,377.08C623.83,375.37 623.41,375.86 618.41,378.53C613.41,381.21 608.19,382.71 602.74,383.05C597.29,383.39 593.15,384.41 590.3,386.1C587.45,387.8 585.08,389.6 583.18,391.53C581.28,393.45 579.64,396.49 578.24,400.64C576.85,404.79 575.81,408.28 575.12,411.09C574.44,413.9 573.81,416.21 573.25,418.02C572.68,419.83 571.29,420.88 569.08,421.17C566.87,421.47 565.33,420.79 564.46,419.15C563.59,417.5 563.33,416.41 563.66,415.86C563.99,415.31 564.74,412.1 565.91,406.21C567.08,400.32 568.45,392.52 570.01,382.81L570.01,382.82ZM628.41,368.51C629.6,367.17 631.12,366.24 632.97,365.73C634.82,365.22 636.38,365.19 637.66,365.63C638.94,366.07 640.07,366.95 641.04,368.28C642.02,369.61 644.21,370.09 647.62,369.72C651.03,369.35 655.29,369 660.39,368.65C665.49,368.31 664.43,368.55 657.2,369.39C649.97,370.23 645.88,370.88 644.92,371.34C643.96,371.8 643.66,373.05 644.01,375.09C644.36,377.13 644.69,379.28 644.99,381.56C645.29,383.84 645.53,386.39 645.71,389.19C645.89,392 645.86,394.1 645.64,395.5C645.42,396.9 645.03,398.38 644.48,399.94C643.93,401.5 643.06,403.18 641.87,404.97C640.68,406.76 639.18,408.46 637.36,410.07C635.54,411.68 633.84,412.91 632.26,413.77C630.68,414.63 628.91,414.82 626.94,414.34C624.97,413.86 623.32,412.97 622.01,411.67C620.69,410.37 619.61,409.01 618.76,407.56C617.91,406.12 617.37,403.51 617.15,399.75C616.92,395.98 617.07,392.92 617.59,390.57C618.11,388.22 619.01,385.73 620.29,383.1C621.57,380.47 621.92,379.27 621.32,379.5C620.72,379.73 620.56,379.65 620.84,379.28C621.12,378.91 622.17,377.34 623.99,374.56C625.81,371.78 627.29,369.76 628.42,368.49L628.41,368.51ZM723.53,369.38C725.16,359.66 727.13,354.81 729.44,354.81C731.75,354.81 733.56,355.69 734.89,357.43C736.21,359.17 736.29,361.46 735.13,364.28C733.96,367.1 733.94,368.38 735.05,368.11C736.16,367.84 737.59,367.03 739.33,365.67C741.07,364.31 742.75,363.2 744.36,362.34C745.97,361.48 747.28,360.9 748.29,360.6C749.3,360.3 751.29,360.48 754.28,361.11C757.26,361.74 760.12,362.75 762.86,364.13C765.6,365.51 769.04,365.35 773.2,363.64C777.35,361.93 776.93,362.42 771.93,365.09C766.93,367.77 761.71,369.27 756.26,369.61C750.81,369.95 746.67,370.97 743.82,372.66C740.97,374.36 738.6,376.16 736.7,378.09C734.8,380.01 733.16,383.05 731.76,387.2C730.37,391.35 729.33,394.84 728.64,397.65C727.96,400.47 727.33,402.78 726.77,404.58C726.2,406.39 724.82,407.44 722.6,407.73C720.39,408.03 718.85,407.35 717.98,405.71C717.11,404.06 716.85,402.97 717.18,402.42C717.51,401.87 718.26,398.66 719.44,392.77C720.61,386.88 721.98,379.08 723.54,369.37L723.53,369.38ZM634.95,384.16C633.28,382.45 631.45,383.12 629.45,386.19C627.45,389.26 626.36,392.42 626.2,395.67C626.04,398.92 626.4,401.16 627.3,402.39C628.2,403.62 629.08,404.3 629.96,404.43C630.83,404.56 632,403.89 633.45,402.42C634.9,400.95 635.93,397.95 636.54,393.42C637.14,388.89 636.61,385.8 634.95,384.16ZM802.33,348.54C803.87,347.99 805.59,347.77 807.49,347.88C809.39,347.99 810.95,348.44 812.15,349.23C813.36,350.02 814.58,351.67 815.84,354.18C817.09,356.69 816.78,358.47 814.91,359.53C813.04,360.59 811.25,360.44 809.55,359.07C807.85,357.71 806.18,357.54 804.55,358.58C802.92,359.62 801.31,360.67 799.71,361.74C798.12,362.81 796.18,364.44 793.89,366.64C791.6,368.84 789.29,371.59 786.97,374.89C784.64,378.19 783.38,380.28 783.18,381.16C782.98,382.04 783.64,381.86 785.15,380.63C786.66,379.4 788.98,377.52 792.1,375.01C795.22,372.5 799.19,369.86 804.01,367.1C808.83,364.34 811.93,363.15 813.31,363.55C814.69,363.95 815.91,364.79 816.99,366.07C818.07,367.35 818.72,368.49 818.94,369.46C819.16,370.44 819.08,371.24 818.69,371.86C818.3,372.48 817.9,373.84 817.5,375.94C817.1,378.04 817.32,380.02 818.17,381.87C819.02,383.72 820.01,384.96 821.13,385.59C822.25,386.22 823.72,386.29 825.54,385.82C827.36,385.35 829.51,383.75 831.99,381.02C834.47,378.29 834.4,378.88 831.78,382.79C829.16,386.7 827.04,389.23 825.42,390.37C823.8,391.51 822.51,392.11 821.55,392.16C820.59,392.21 819.32,392.01 817.73,391.56C816.14,391.11 814.61,390.33 813.13,389.22C811.65,388.11 810.45,386.7 809.51,384.99C808.57,383.28 807.92,382.01 807.58,381.18C807.23,380.35 806.52,379.47 805.44,378.53C804.36,377.59 803.13,377.48 801.74,378.18C800.36,378.89 797.98,380.7 794.62,383.61C791.26,386.52 788.1,388.95 785.13,390.9C782.17,392.85 779.48,394.25 777.08,395.12C774.68,395.99 773.11,396.35 772.37,396.2C771.63,396.06 770.78,395.36 769.81,394.1C768.84,392.84 768.22,391.43 767.94,389.87C767.67,388.31 767.75,386.7 768.19,385.04C768.63,383.38 770.54,379.98 773.91,374.83C777.28,369.68 780.59,365.41 783.84,362.03C787.09,358.65 790.6,355.7 794.38,353.2C798.15,350.7 800.81,349.14 802.34,348.53L802.33,348.54ZM1035.59,365.878C1035.22,365.357 1034.87,364.804 1034.54,364.22C1033.64,362.61 1033.05,360.36 1032.76,357.45C1032.47,354.55 1032.88,351.33 1033.98,347.79C1035.08,344.25 1036.42,341.27 1038,338.86C1039.58,336.45 1041.79,333.97 1044.63,331.41C1047.47,328.85 1050.8,327 1054.63,325.83L1054.63,325.85C1059.18,325.11 1062.03,325.63 1063.19,327.43C1064.34,329.22 1065.01,331.58 1065.2,334.49C1065.39,337.4 1064.23,339.98 1061.74,342.23C1059.25,344.48 1055.9,346.79 1051.7,349.15C1050.51,349.74 1049.42,350.09 1048.44,350.21C1047.45,350.33 1046.63,350.37 1045.97,350.32C1045.31,350.27 1044.79,350.22 1044.41,350.15C1044.02,350.08 1043.81,350.15 1043.76,350.36C1042.7,352.45 1042.24,354.49 1042.38,356.47C1042.49,358.079 1043.05,359.545 1044.03,360.866C1045.49,359.975 1045.53,360.024 1044.15,361.017C1044.35,361.277 1044.57,361.531 1044.81,361.78C1046.29,363.34 1047.86,364.18 1049.53,364.31C1051.19,364.44 1052.9,364.24 1054.64,363.71C1056.38,363.18 1059.56,361.71 1064.17,359.31C1068.78,356.91 1071.95,354.75 1073.68,352.85C1075.41,350.94 1077.05,349.09 1078.62,347.3C1080.18,345.51 1080.42,345.49 1079.34,347.24C1078.25,348.99 1076.9,351.1 1075.3,353.59C1073.69,356.07 1071.64,358.58 1069.14,361.1C1066.64,363.63 1064.59,365.58 1062.99,366.96C1061.39,368.34 1059.21,369.65 1056.46,370.89C1053.71,372.13 1050.95,372.68 1048.18,372.54C1045.41,372.4 1043.31,371.95 1041.86,371.18C1040.41,370.41 1039.06,369.46 1037.79,368.33C1037.08,367.697 1036.43,366.988 1035.83,366.204C1035.77,366.236 1035.71,366.268 1035.65,366.3C1032.92,367.75 1031,368.84 1029.89,369.59C1028.78,370.34 1027.24,371.05 1025.27,371.7C1023.29,372.36 1021.38,372.32 1019.53,371.58C1017.67,370.85 1015.87,369.85 1014.1,368.59C1012.34,367.33 1010.08,365.19 1007.34,362.16C1004.6,359.13 1002.62,356.87 1001.43,355.39C1000.23,353.91 998.86,353.38 997.31,353.79C995.76,354.2 994.2,355.22 992.62,356.83C991.04,358.45 988.88,360.76 986.15,363.75C983.42,366.74 981.34,369.82 979.93,372.97C978.52,376.13 977.68,378.14 977.41,379.03C977.14,379.92 976.36,381.19 975.06,382.85C973.76,384.51 972.44,385.21 971.11,384.95C969.78,384.69 968.78,384.09 968.11,383.15C967.44,382.21 967.24,380.45 967.49,377.88C967.75,375.31 967.93,372.85 968.03,370.5C968.13,368.15 968.15,365.6 968.08,362.85C968.01,360.1 967.08,358.72 965.29,358.7C963.5,358.69 960.71,360.89 956.93,365.32C953.15,369.75 950.81,373.14 949.92,375.49C949.02,377.84 948.29,379.52 947.73,380.54C947.16,381.56 946.55,382.37 945.88,382.98C945.21,383.59 943.77,383.65 941.56,383.15C939.35,382.66 938.06,381.87 937.69,380.8C937.32,379.73 937.64,377.46 938.64,374C938.649,373.968 938.658,373.936 938.668,373.904C938.03,374.268 937.391,374.62 936.75,374.96C934.02,376.4 932.1,377.5 930.99,378.25C929.88,379 928.34,379.7 926.37,380.36C924.39,381.02 922.48,380.98 920.63,380.24C918.77,379.51 916.97,378.51 915.2,377.25C913.44,375.99 911.18,373.85 908.44,370.82C905.7,367.79 903.72,365.53 902.53,364.05C901.33,362.57 899.96,362.04 898.41,362.45C896.86,362.86 895.3,363.88 893.72,365.49C892.14,367.11 889.98,369.42 887.25,372.41C884.52,375.4 882.44,378.48 881.03,381.63C879.62,384.79 878.78,386.8 878.51,387.69C878.24,388.58 877.46,389.85 876.16,391.51C874.86,393.17 873.54,393.87 872.21,393.61C870.88,393.35 869.88,392.75 869.21,391.81C868.54,390.87 868.34,389.11 868.59,386.54C868.85,383.97 869.03,381.51 869.13,379.16C869.23,376.81 869.25,374.26 869.18,371.51C869.11,368.76 868.18,367.38 866.39,367.36C864.6,367.35 861.81,369.55 858.03,373.98C854.25,378.41 851.91,381.8 851.02,384.15C850.12,386.5 849.39,388.18 848.83,389.2C848.26,390.21 847.65,391.03 846.98,391.64C846.31,392.25 844.87,392.31 842.66,391.81C840.45,391.32 839.16,390.53 838.79,389.46C838.42,388.39 838.74,386.12 839.74,382.66C840.74,379.2 842,373.89 843.51,366.73C845.02,359.57 846.1,355.04 846.76,353.12C847.42,351.2 842.02,355.05 830.57,364.66C819.12,374.27 815.88,376.66 820.86,371.81C825.84,366.97 830.77,362.49 835.65,358.38C840.52,354.27 844.11,350.32 846.39,346.54L846.41,346.55C848.7,342.77 850.67,340.87 852.32,340.87C853.97,340.87 855.09,341.45 855.68,342.64C856.26,343.83 856.78,344.94 857.21,345.97C857.64,347 858.12,348.51 858.64,350.49C859.16,352.48 858.12,356.51 855.51,362.59C852.91,368.67 853.19,369.39 856.37,364.74C859.54,360.09 862.35,357.12 864.79,355.84C867.23,354.56 869.55,354.36 871.76,355.23C873.97,356.11 875.42,357.27 876.1,358.72C876.78,360.18 877.27,361.86 877.57,363.76C877.87,365.66 878.24,366.73 878.68,366.97C879.11,367.21 881.19,364.96 884.91,360.23C888.63,355.5 891.98,352.29 894.97,350.62C897.96,348.95 900.51,348.43 902.63,349.07C904.75,349.71 906.69,351.16 908.43,353.42C910.18,355.68 912.48,358.99 915.34,363.35C918.2,367.72 921.04,370.86 923.86,372.78C926.68,374.7 929.13,375.78 931.22,376.01C932.884,376.193 935.409,375.331 938.806,373.418C939.778,369.956 940.982,364.84 942.41,358.07C943.92,350.91 945,346.38 945.66,344.46C946.32,342.54 940.92,346.39 929.47,356C918.02,365.61 914.78,368 919.76,363.15C924.74,358.31 929.67,353.83 934.55,349.72C939.42,345.61 943.01,341.66 945.29,337.88L945.3,337.89C947.59,334.11 949.56,332.21 951.21,332.21C952.86,332.21 953.98,332.79 954.57,333.98C955.16,335.17 955.67,336.28 956.1,337.31C956.53,338.34 957.01,339.85 957.53,341.83C958.05,343.82 957.01,347.85 954.4,353.93C951.8,360.01 952.08,360.73 955.26,356.08C958.43,351.43 961.24,348.46 963.68,347.18C966.12,345.9 968.44,345.7 970.65,346.57C972.86,347.45 974.31,348.61 974.99,350.07C975.67,351.53 976.16,353.21 976.46,355.11C976.76,357.01 977.13,358.08 977.57,358.32C978,358.56 980.08,356.31 983.8,351.58C987.52,346.85 990.87,343.64 993.86,341.97C996.85,340.3 999.4,339.78 1001.53,340.42C1003.65,341.06 1005.59,342.51 1007.33,344.77C1009.08,347.03 1011.38,350.34 1014.24,354.7C1017.1,359.06 1019.94,362.21 1022.76,364.13C1025.58,366.05 1028.03,367.13 1030.12,367.36C1031.42,367.503 1033.24,367.01 1035.59,365.878ZM690.43,370.73C689.17,369.67 687.43,369.94 685.23,371.55C683.03,373.16 680.62,375.5 677.99,378.59C675.37,381.68 673.24,384.91 671.61,388.29C669.98,391.67 670.94,392.07 674.5,389.48C678.06,386.9 681.23,384.14 684,381.21C686.77,378.28 688.8,375.9 690.09,374.06C691.38,372.23 691.49,371.11 690.42,370.73L690.43,370.73ZM210.83,70.15C193.98,65.47 176.85,61.95 159.57,59.6C142.28,57.24 124.84,56.05 107.36,56.05L107.28,56.05C72.28,56.05 37.44,60.79 3.72,70.15L0.01,71.18L0.01,271.27C0.01,330.42 48.13,378.53 107.27,378.53C166.41,378.53 214.53,330.41 214.53,271.27L214.53,71.17L210.83,70.14L210.83,70.15ZM204.41,271.26C204.41,324.83 160.83,368.41 107.26,368.41C53.69,368.41 10.11,324.83 10.11,271.26L10.11,78.88C41.8,70.43 74.46,66.15 107.27,66.15L107.35,66.15C140.12,66.15 172.76,70.44 204.42,78.88L204.42,271.26L204.41,271.26ZM82.99,177.68L131.53,177.68L131.53,354.87C123.82,357.1 115.67,358.3 107.26,358.3C98.85,358.3 90.7,357.1 82.99,354.87L82.99,177.68ZM194.68,270.89C194.68,307.04 172.63,338.12 141.27,351.42L141.27,177.69L194.68,177.69L194.68,270.89ZM73.26,177.67L73.26,351.41C41.9,338.12 19.85,307.03 19.85,270.88L19.85,177.67L73.26,177.67ZM1055.54,335.07C1055.02,334.63 1053.86,334.98 1052.07,336.1C1050.27,337.22 1049,338.42 1048.25,339.69C1047.5,340.96 1047.42,341.85 1048.02,342.35C1048.61,342.85 1049.76,342.53 1051.45,341.38C1053.14,340.23 1054.47,339.12 1055.44,338.03C1056.41,336.95 1056.45,335.96 1055.54,335.08L1055.54,335.07ZM543.4,240.19C558.97,240.19 569.79,243.87 575.84,251.24C581.89,258.61 583.72,270.74 581.32,287.63C579.04,304.16 574.22,315.88 566.85,322.77C559.48,329.66 548.13,333.1 532.79,333.1C517.45,333.1 506.49,329.45 500.26,322.14C494.03,314.83 492.05,302.79 494.33,286.02C496.73,269.37 501.58,257.57 508.89,250.62C516.2,243.67 527.7,240.2 543.4,240.2L543.4,240.19ZM371.95,312.97L373.39,327.17C364.16,331 351.7,332.92 336.01,332.92C320.32,332.92 309.41,328.94 303.3,320.97C297.19,313 295.21,300.81 297.37,284.4C299.64,267.51 304.38,255.91 311.57,249.62C318.76,243.33 330.62,240.18 347.15,240.18C361.77,240.18 371.62,242.67 376.71,247.64C381.8,252.61 383.69,259.89 382.37,269.48C381.17,278.11 377.82,284.34 372.31,288.17C366.8,292.01 358.35,294.28 346.97,295L319.11,297.34C319.23,304.29 320.91,308.99 324.14,311.45C327.37,313.91 332.29,315.13 338.88,315.13C348.82,315.13 359.85,314.41 371.95,312.97ZM873.36,251.69C880.19,244.86 890.85,241.45 905.35,241.45C919.85,241.45 929.76,245.02 935.09,252.14C940.42,259.27 941.89,271.16 939.49,287.81C937.21,304.34 932.66,316 925.83,322.77C919,329.54 908.4,332.92 894.02,332.92C879.64,332.92 869.46,329.42 864.19,322.41C858.92,315.4 857.42,303.51 859.7,286.74C861.97,270.21 866.53,258.52 873.36,251.69ZM732.46,243.78L720.24,330.76L711.43,330.76L713.23,310.45C697.89,325.43 684.05,332.91 671.71,332.91C663.92,332.91 658.26,330.81 654.73,326.62C651.19,322.43 649.97,316.5 651.05,308.83L660.22,243.77L671.72,243.77L662.73,306.31C661.89,312.18 662.46,316.44 664.44,319.07C666.42,321.71 670.04,323.02 675.31,323.02C680.58,323.02 686.33,321.31 691.84,317.9C697.35,314.49 704.48,308.82 713.23,300.92L721.14,243.77L732.46,243.77L732.46,243.78ZM626.967,204.98L626.97,204.96L626.98,204.98L626.967,204.98L612.41,309.38C611.69,313.69 612.2,316.84 613.94,318.82C615.68,320.8 618.7,321.79 623.02,321.79L632.37,321.79L632.91,330.42C630.03,331.62 625.24,332.22 618.53,332.22C612.18,332.22 607.42,330.36 604.24,326.65C601.06,322.94 599.9,317.73 600.74,311.01L615.66,204.98L626.967,204.98ZM777.75,252.77L769.84,309.38C769.24,313.81 769.78,316.99 771.46,318.91C773.14,320.83 776.19,321.79 780.63,321.79L795.01,321.79L795.55,330.42C790.28,331.62 784.23,332.22 777.4,332.22C770.21,332.22 765.03,330.3 761.85,326.47C758.67,322.64 757.56,317.25 758.53,310.3L766.62,252.79L750.63,252.79L751.71,244.7L767.88,243.8L771.65,217.38L782.79,217.38L779.2,243.8L808.49,243.8L807.05,252.79L777.76,252.79L777.75,252.77ZM462.89,242.7L485.71,242.7C483.07,257.32 478.46,273.37 471.87,290.86C467.2,303.08 462.58,312.31 458.03,318.54C455.15,322.97 452.13,326.12 448.95,327.98C445.77,329.84 441.43,330.77 435.92,330.77L418.13,330.77C414.29,330.77 412.08,328.91 411.48,325.2L395.66,242.71L418.66,242.71L428.9,314.6L431.42,314.6C433.82,314.6 435.76,314.18 437.26,313.34C438.76,312.5 440.34,310.82 442.02,308.31C445.26,303.4 448.91,295.13 452.98,283.51C456.93,272.49 460.23,258.89 462.86,242.71L462.89,242.7ZM980.109,243.79L978.31,263.55C995.08,248.81 1009.46,241.44 1021.44,241.44C1029.11,241.44 1034.74,243.54 1038.33,247.73C1041.92,251.93 1043.18,257.91 1042.1,265.7L1032.75,330.76L1021.43,330.76L1030.24,268.04C1031.08,261.93 1030.57,257.62 1028.71,255.1C1026.85,252.58 1023.35,251.33 1018.2,251.33C1012.69,251.33 1006.97,252.98 1001.04,256.27C995.11,259.57 987.53,264.87 978.31,272.18L970.22,330.77L958.72,330.77L971.12,243.79L980.109,243.79L980.11,243.78L980.11,243.79L980.109,243.79ZM827.53,330.76L816.21,330.76L828.43,243.78L839.75,243.78L827.53,330.76ZM905.35,251.33C894.68,251.33 886.87,253.94 881.9,259.15C876.93,264.36 873.48,273.92 871.57,287.81C869.65,301.35 870.31,310.63 873.55,315.67C876.78,320.7 883.61,323.22 894.04,323.22C904.47,323.22 912.52,320.59 917.49,315.31C922.46,310.04 925.91,300.51 927.82,286.73C929.74,273.19 929.08,263.91 925.84,258.87C922.61,253.84 915.78,251.32 905.35,251.32L905.35,251.33ZM543.22,257.62C534.95,257.62 528.96,259.66 525.25,263.73C521.54,267.8 518.84,275.77 517.16,287.63C515.48,298.65 515.72,306.08 517.88,309.92C520.04,313.76 525.07,315.67 532.98,315.67C540.89,315.67 547.24,313.6 550.95,309.47C554.66,305.34 557.3,297.52 558.86,286.02C560.42,274.76 560.15,267.21 558.05,263.38C555.95,259.55 551.01,257.63 543.22,257.63L543.22,257.62ZM320.37,282.6L345.53,280.44C350.56,280.08 354.25,278.97 356.58,277.12C358.92,275.26 360.38,272.06 360.98,267.51C361.34,262.96 360.44,260.14 358.28,259.06C356.12,257.98 351.51,257.44 344.44,257.44C336.53,257.56 330.96,259.27 327.73,262.56C324.5,265.86 322.04,272.53 320.36,282.6L320.37,282.6ZM836.34,207.12L841.55,207.12C844.18,207.12 845.32,208.44 844.96,211.07L843.52,221.67C843.16,223.95 841.84,225.08 839.57,225.08L834.36,225.08C831.6,225.08 830.41,223.76 830.77,221.13L832.39,210.53C832.51,208.26 833.83,207.12 836.34,207.12ZM94.81,149.86L94.81,169.98L98.82,169.98L98.82,149.86L94.81,149.86ZM92,153.54L92,149.86L82.99,149.86L82.99,169.98L87,169.98L87,160.87L92,160.87L92,157.2L87,157.2L87,153.54L92,153.54ZM108,159.05L108,162.72L111.35,162.72C111.37,163.66 111.22,164.53 110.77,165.21C110.42,165.72 109.95,166.1 109.26,166.24C109.07,166.28 108.86,166.3 108.64,166.3C106.46,166.3 105.46,164.57 105.46,159.91C105.46,155.25 106.54,153.52 108.64,153.52C108.87,153.52 109.08,153.54 109.27,153.59C110.07,153.76 110.55,154.3 110.94,155.04C111.2,155.58 111.36,156.25 111.36,157.06L115.46,157.06C115.23,152.81 112.97,150.14 109.27,149.87C109.07,149.85 108.86,149.85 108.64,149.85C103.77,149.85 101.34,153.89 101.34,159.91C101.34,165.93 103.63,169.96 108.64,169.96C108.85,169.96 109.06,169.96 109.26,169.94C113.11,169.65 115.46,166.65 115.46,162.79L115.46,159.04L108.01,159.04L108,159.05ZM124.8,166.2C122.95,166.2 121.54,164.55 121.54,159.92C121.54,155.29 122.95,153.63 124.8,153.63C126.33,153.63 127.33,154.44 127.43,157.89L131.53,157.89C131.58,153.38 129.19,149.85 124.47,149.85C120.21,149.85 117.42,153.13 117.42,159.91C117.42,166.69 120.21,169.96 124.47,169.96C129.05,169.96 131.5,166.51 131.53,162.07L127.43,162.07C127.33,164.14 126.88,166.18 124.8,166.18L124.8,166.2ZM498.43,169.4L494.27,169.4L494.27,138.81L498.43,138.81L498.43,169.4ZM874.62,169.4L870.46,169.4L870.46,138.81L874.62,138.81L874.62,169.4ZM786.25,165.24L798.69,165.24L798.69,169.4L782.08,169.4L782.08,138.81L786.24,138.81L786.24,165.23L786.25,165.24ZM540.76,165.23L548.45,138.81L552.61,138.81L543.43,169.4L538.04,169.4L528.87,138.81L533.03,138.81L540.76,165.23ZM623.52,165.24L635.97,165.24L635.97,169.4L619.36,169.4L619.36,138.81L623.52,138.81L623.52,165.24ZM583.03,138.81L595.47,160.39L595.47,138.81L599.63,138.81L599.63,169.4L595.47,169.4L583.03,147.1L583.03,169.4L578.86,169.4L578.86,138.81L583.03,138.81ZM611.57,169.4L607.41,169.4L607.41,138.81L611.57,138.81L611.57,169.4ZM453.22,152.79L453.22,156.96L440.78,156.96L440.78,165.24L453.22,165.24L453.22,169.4L436.61,169.4L436.61,138.81L453.22,138.81L453.22,142.98L440.78,142.98L440.78,152.79L453.22,152.79ZM657.93,152.79L657.93,156.96L645.49,156.96L645.49,165.24L657.93,165.24L657.93,169.4L641.32,169.4L641.32,138.81L657.93,138.81L657.93,142.98L645.49,142.98L645.49,152.79L657.93,152.79ZM865.49,138.81L865.49,142.98L858.23,142.98L858.23,169.4L854.06,169.4L854.06,142.98L846.84,142.98L846.84,138.81L865.49,138.81ZM690.69,152.79L690.69,156.96L678.25,156.96L678.25,165.24L690.69,165.24L690.69,169.4L674.08,169.4L674.08,138.81L690.69,138.81L690.69,142.98L678.25,142.98L678.25,152.79L690.69,152.79ZM338.76,152.79L338.76,156.96L326.31,156.96L326.31,165.24L338.76,165.24L338.76,169.4L322.15,169.4L322.15,138.81L338.76,138.81L338.76,142.98L326.31,142.98L326.31,152.79L338.76,152.79ZM476.93,152.79L476.93,156.95L483.14,156.95L483.14,162.14C483.14,164.22 482.12,165.24 480.04,165.24L475.87,165.24C473.79,165.24 472.77,164.22 472.77,162.14L472.77,146.08C472.77,144 473.79,142.98 475.87,142.98L480.04,142.98C482.12,142.98 483.14,144 483.14,146.08L483.14,148.59L487.3,148.59L487.3,146.08C487.3,141.24 484.88,138.82 480.04,138.82L475.87,138.82C471.03,138.82 468.61,141.24 468.61,146.08L468.61,162.14C468.61,166.98 471.03,169.4 475.87,169.4L480.04,169.4C484.89,169.4 487.3,166.98 487.3,162.14L487.3,152.79L476.93,152.79ZM360.3,138.81L360.3,142.98L353.04,142.98L353.04,169.4L348.87,169.4L348.87,142.98L341.65,142.98L341.65,138.81L360.3,138.81ZM421.524,156.95L415.96,156.95L415.96,169.4L411.8,169.4L411.8,138.81L423.23,138.81C428.07,138.81 430.49,141.23 430.49,146.07L430.49,149.68C430.49,154.01 428.87,156.44 425.6,156.86L430.49,169.39L426.32,169.39L421.524,156.95L421.53,156.95L421.52,156.94L421.524,156.95ZM381.28,138.81L381.28,142.98L374.02,142.98L374.02,169.4L369.86,169.4L369.86,142.98L362.64,142.98L362.64,138.81L381.29,138.81L381.28,138.81ZM749.58,148.58L749.58,146.07C749.58,141.23 747.16,138.81 742.32,138.81L738.15,138.81C733.31,138.81 730.89,141.23 730.89,146.07L730.89,162.13C730.89,166.97 733.31,169.39 738.15,169.39L742.32,169.39C747.17,169.39 749.58,166.97 749.58,162.13L749.58,159.67L745.42,159.67L745.42,162.13C745.42,164.21 744.4,165.23 742.32,165.23L738.15,165.23C736.07,165.23 735.05,164.21 735.05,162.13L735.05,146.07C735.05,143.99 736.07,142.97 738.15,142.97L742.32,142.97C744.4,142.97 745.42,143.99 745.42,146.07L745.42,148.58L749.58,148.58ZM900.37,148.58L900.37,146.07C900.37,141.23 897.95,138.81 893.11,138.81L888.94,138.81C884.1,138.81 881.68,141.23 881.68,146.07L881.68,162.13C881.68,166.97 884.1,169.39 888.94,169.39L893.11,169.39C897.96,169.39 900.37,166.97 900.37,162.13L900.37,159.67L896.21,159.67L896.21,162.13C896.21,164.21 895.19,165.23 893.11,165.23L888.94,165.23C886.86,165.23 885.84,164.21 885.84,162.13L885.84,146.07C885.84,143.99 886.86,142.97 888.94,142.97L893.11,142.97C895.19,142.97 896.21,143.99 896.21,146.07L896.21,148.58L900.37,148.58ZM925.82,162.13C925.82,166.98 923.4,169.39 918.56,169.39L913.38,169.39C908.53,169.39 906.12,166.97 906.12,162.13L906.12,146.07C906.12,141.23 908.54,138.81 913.38,138.81L918.56,138.81C923.4,138.81 925.82,141.23 925.82,146.07L925.82,162.13ZM525.15,162.13C525.15,166.98 522.73,169.39 517.89,169.39L512.71,169.39C507.87,169.39 505.45,166.97 505.45,162.13L505.45,146.07C505.45,141.23 507.87,138.81 512.71,138.81L517.89,138.81C522.74,138.81 525.15,141.23 525.15,146.07L525.15,162.13ZM775.03,162.13C775.03,166.98 772.61,169.39 767.77,169.39L762.59,169.39C757.75,169.39 755.33,166.97 755.33,162.13L755.33,146.07C755.33,141.23 757.75,138.81 762.59,138.81L767.77,138.81C772.61,138.81 775.03,141.23 775.03,146.07L775.03,162.13ZM404.74,162.13C404.74,166.98 402.32,169.39 397.48,169.39L392.3,169.39C387.46,169.39 385.04,166.97 385.04,162.13L385.04,146.07C385.04,141.23 387.46,138.81 392.3,138.81L397.48,138.81C402.32,138.81 404.74,141.23 404.74,146.07L404.74,162.13ZM835.977,138.81L835.92,138.81L831.75,138.81C826.91,138.81 824.49,141.23 824.49,146.07L824.49,148.91C824.49,153.76 826.91,156.17 831.75,156.17L835.92,156.17C838,156.17 839.02,157.19 839.02,159.27L839.02,162.12C839.02,164.2 838,165.22 835.92,165.22L831.75,165.22C829.67,165.22 828.65,164.2 828.65,162.12L828.65,159.65L824.49,159.65L824.49,162.12C824.49,166.96 826.91,169.38 831.75,169.38L835.92,169.38C840.76,169.38 843.18,166.96 843.18,162.12L843.18,159.27C843.18,154.43 840.76,152.01 835.92,152.01L831.75,152.01C829.67,152.01 828.65,150.94 828.65,148.9L828.65,146.06C828.65,143.98 829.67,142.91 831.75,142.91L835.92,142.91C838,142.91 839.02,143.97 839.02,146.06L839.02,148.57L843.18,148.57L843.18,146.07C843.18,141.239 840.779,138.829 835.977,138.81ZM308.017,138.81L307.96,138.81L303.79,138.81C298.95,138.81 296.53,141.23 296.53,146.07L296.53,148.91C296.53,153.76 298.95,156.17 303.79,156.17L307.96,156.17C310.04,156.17 311.06,157.19 311.06,159.27L311.06,162.12C311.06,164.2 310.04,165.22 307.96,165.22L303.79,165.22C301.71,165.22 300.69,164.2 300.69,162.12L300.69,159.65L296.53,159.65L296.53,162.12C296.53,166.96 298.95,169.38 303.79,169.38L307.96,169.38C312.8,169.38 315.22,166.96 315.22,162.12L315.22,159.27C315.22,154.43 312.8,152.01 307.96,152.01L303.79,152.01C301.71,152.01 300.69,150.94 300.69,148.9L300.69,146.06C300.69,143.98 301.71,142.91 303.79,142.91L307.96,142.91C310.04,142.91 311.06,143.97 311.06,146.06L311.06,148.57L315.22,148.57L315.22,146.07C315.22,141.239 312.819,138.829 308.017,138.81ZM717.477,138.81L717.42,138.81L713.25,138.81C708.4,138.81 705.99,141.23 705.99,146.07L705.99,148.91C705.99,153.76 708.41,156.17 713.25,156.17L717.42,156.17C719.5,156.17 720.52,157.19 720.52,159.27L720.52,162.12C720.52,164.2 719.5,165.22 717.42,165.22L713.25,165.22C711.17,165.22 710.15,164.2 710.15,162.12L710.15,159.65L705.99,159.65L705.99,162.12C705.99,166.96 708.41,169.38 713.25,169.38L717.42,169.38C722.26,169.38 724.68,166.96 724.68,162.12L724.68,159.27C724.68,154.43 722.26,152.01 717.42,152.01L713.25,152.01C711.17,152.01 710.15,150.94 710.15,148.9L710.15,146.06C710.15,143.98 711.17,142.91 713.25,142.91L717.42,142.91C719.5,142.91 720.52,143.97 720.52,146.06L720.52,148.57L724.68,148.57L724.68,146.07C724.68,141.239 722.279,138.829 717.477,138.81ZM813.65,138.77L808.46,138.77C803.62,138.77 801.2,141.19 801.2,146.03L801.2,169.36L805.32,169.36L805.32,162.09L816.75,162.09L816.75,169.36L820.86,169.36L820.86,146.03C820.86,141.18 818.44,138.77 813.64,138.77L813.65,138.77ZM566.71,138.77L561.53,138.77C556.69,138.77 554.27,141.19 554.27,146.03L554.27,169.36L558.38,169.36L558.38,162.09L569.81,162.09L569.81,169.36L573.93,169.36L573.93,146.03C573.93,141.18 571.51,138.77 566.71,138.77ZM910.27,162.13C910.27,164.21 911.29,165.23 913.37,165.23L918.55,165.23C920.63,165.23 921.65,164.21 921.65,162.13L921.65,146.07C921.65,143.99 920.63,142.97 918.55,142.97L913.37,142.97C911.29,142.97 910.27,143.99 910.27,146.07L910.27,162.13ZM389.19,162.13C389.19,164.21 390.21,165.23 392.29,165.23L397.47,165.23C399.55,165.23 400.57,164.21 400.57,162.13L400.57,146.07C400.57,143.99 399.55,142.97 397.47,142.97L392.29,142.97C390.21,142.97 389.19,143.99 389.19,146.07L389.19,162.13ZM509.61,162.13C509.61,164.21 510.63,165.23 512.71,165.23L517.89,165.23C519.97,165.23 520.99,164.21 520.99,162.13L520.99,146.07C520.99,143.99 519.97,142.97 517.89,142.97L512.71,142.97C510.63,142.97 509.61,143.99 509.61,146.07L509.61,162.13ZM759.48,162.13C759.48,164.21 760.5,165.23 762.58,165.23L767.76,165.23C769.84,165.23 770.86,164.21 770.86,162.13L770.86,146.07C770.86,143.99 769.84,142.97 767.76,142.97L762.58,142.97C760.5,142.97 759.48,143.99 759.48,146.07L759.48,162.13ZM73.26,156.06L19.85,156.06L19.85,163.77L73.26,163.77L73.26,156.06ZM194.68,156.06L141.27,156.06L141.27,163.77L194.68,163.77L194.68,156.06ZM805.32,157.93L805.32,146.03C805.32,143.95 806.38,142.93 808.46,142.93L813.65,142.93C815.69,142.93 816.75,143.95 816.75,146.03L816.75,157.93L805.32,157.93ZM558.38,157.93L558.38,146.03C558.38,143.95 559.44,142.93 561.53,142.93L566.71,142.93C568.75,142.93 569.81,143.95 569.81,146.03L569.81,157.93L558.38,157.93ZM415.96,142.98L415.96,152.79L423.22,152.79C425.26,152.79 426.32,151.77 426.32,149.69L426.32,146.08C426.32,144 425.26,142.98 423.22,142.98L415.96,142.98ZM179.48,88.62L169.36,88.62L154.75,142.15L165.89,142.15L168.49,131.94L180.79,131.94L183.53,142.15L194.68,142.15L179.48,88.62ZM139.04,88.62L139.04,142.15L150.04,142.15L150.04,88.62L139.04,88.62ZM19.85,88.62L19.85,142.15L30.85,142.15L30.85,88.62L19.85,88.62ZM118.41,132.03L118.41,88.62L107.41,88.62L107.41,142.15L132.44,142.15L132.44,132.03L118.41,132.03ZM87,88.62L76.88,88.62L62.27,142.15L73.41,142.15L76.01,131.94L88.31,131.94L91.05,142.15L102.2,142.15L87,88.62ZM37,88.62L37,98.74L45.98,98.74L45.98,142.14L56.98,142.14L56.98,98.74L65.95,98.74L65.95,88.62L37,88.62ZM685.39,102.77L685.39,125.05L679.19,125.05L679.19,119.02L670.91,119.02L670.91,125.05L664.71,125.05L664.71,102.77C664.71,97.17 667.43,94.49 672.99,94.49L677.19,94.49C682.62,94.49 685.38,97.16 685.38,102.77L685.39,102.77ZM512.87,94.49L523.18,112.02L523.18,94.49L529.42,94.49L529.42,125.05L523.18,125.05L512.87,107.48L512.87,125.05L506.67,125.05L506.67,94.49L512.87,94.49ZM956.93,102.77L956.93,125.05L950.73,125.05L950.73,119.02L942.45,119.02L942.45,125.05L936.25,125.05L936.25,102.77C936.25,97.17 938.97,94.49 944.53,94.49L948.73,94.49C954.16,94.49 956.92,97.16 956.92,102.77L956.93,102.77ZM337.98,106.67L337.98,112.91L325.5,112.91L325.5,118.81L337.98,118.81L337.98,125.05L319.35,125.05L319.35,94.49L337.98,94.49L337.98,100.73L325.5,100.73L325.5,106.67L337.98,106.67ZM770.46,104.39L770.46,102.77C770.46,101.37 769.74,100.73 768.42,100.73L762.77,100.73C761.71,100.9 761.2,101.58 761.2,102.77L761.2,116.77C761.2,118.17 761.84,118.81 763.24,118.81L768.42,118.81C769.74,118.81 770.46,118.17 770.46,116.77L770.46,114.65L766.3,114.65L766.3,108.41L776.7,108.41L776.7,116.77C776.7,122.24 773.94,125.05 768.42,125.05L763.24,125.05C757.77,125.05 754.97,122.25 754.97,116.77L754.97,102.77C754.97,101.37 755.18,100.18 755.48,99.21L755.48,99.13C755.82,98.2 756.29,97.35 756.96,96.71C756.96,96.71 757,96.62 757,96.54C757.08,96.54 757.17,96.5 757.17,96.41C757.89,95.81 758.65,95.35 759.59,95.01L759.67,95.01C760.18,94.84 760.73,94.71 761.33,94.63L761.54,94.63C762.13,94.59 762.64,94.5 763.24,94.5L768.42,94.5C773.94,94.5 776.7,97.3 776.7,102.78L776.7,104.39L770.46,104.39ZM697.01,94.49L707.32,112.02L707.32,94.49L713.56,94.49L713.56,125.05L707.32,125.05L697.01,107.48L697.01,125.05L690.81,125.05L690.81,94.49L697.01,94.49ZM387.92,106.67L387.92,112.91L375.44,112.91L375.44,118.81L387.92,118.81L387.92,125.05L369.29,125.05L369.29,94.49L387.92,94.49L387.92,100.73L375.44,100.73L375.44,106.67L387.92,106.67ZM438.11,102.77L438.11,125.05L431.91,125.05L431.91,119.02L423.63,119.02L423.63,125.05L417.43,125.05L417.43,102.77C417.43,97.17 420.15,94.49 425.71,94.49L429.91,94.49C435.34,94.49 438.1,97.16 438.1,102.77L438.11,102.77ZM739.66,102.77L739.66,125.05L733.46,125.05L733.46,119.02L725.18,119.02L725.18,125.05L718.98,125.05L718.98,102.77C718.98,97.17 721.7,94.49 727.26,94.49L731.46,94.49C736.89,94.49 739.65,97.16 739.65,102.77L739.66,102.77ZM968.6,118.81L980.99,118.81L980.99,125.05L962.36,125.05L962.4,94.49L968.6,94.49L968.6,118.81ZM636.47,118.81L648.86,118.81L648.86,125.05L630.23,125.05L630.27,94.49L636.47,94.49L636.47,118.81ZM554.33,106.67L554.33,112.91L541.85,112.91L541.85,118.81L554.33,118.81L554.33,125.05L535.7,125.05L535.7,94.49L554.33,94.49L554.33,100.73L541.85,100.73L541.85,106.67L554.33,106.67ZM462.68,94.49L462.68,100.69L449.69,118.81L462.68,118.81L462.68,125.05L441.97,125.05L441.97,118.81L455.04,100.69L441.97,100.69L441.97,94.49L462.68,94.49ZM1016.93,94.49L1016.93,125.05L1010.69,125.05L1010.69,94.49L1016.93,94.49ZM473.79,94.49L473.79,125.05L467.55,125.05L467.55,94.49L473.79,94.49ZM788.36,94.49L788.36,125.05L782.12,125.05L782.12,94.49L788.36,94.49ZM576.73,94.49L576.73,125.05L570.49,125.05L570.49,94.49L576.73,94.49ZM659.29,94.49L659.29,125.05L653.05,125.05L653.05,94.49L659.29,94.49ZM624.8,102.77L624.8,125.05L618.6,125.05L618.6,119.02L610.32,119.02L610.32,125.05L604.12,125.05L604.12,102.77C604.12,97.17 606.84,94.49 612.4,94.49L616.6,94.49C622.03,94.49 624.79,97.16 624.79,102.77L624.8,102.77ZM355.42,94.49C360.89,94.49 363.7,97.25 363.7,102.77L363.7,116.73C363.7,122.25 360.9,125.05 355.42,125.05L342.94,125.05L342.94,94.49L355.42,94.49ZM601.42,94.49L601.42,100.73L594.16,100.73L594.16,125.05L587.96,125.05L587.96,100.73L580.7,100.73L580.7,94.49L601.42,94.49ZM800.41,94.49L800.41,116.73C800.41,118.13 801.09,118.81 802.49,118.81L806.65,118.81C808.01,118.81 808.69,118.13 808.69,116.73L808.69,94.49L814.93,94.49L814.93,116.73C814.93,122.25 812.17,125.05 806.65,125.05L802.49,125.05C796.97,125.05 794.17,122.25 794.17,116.73L794.17,94.49L800.41,94.49ZM841.74,116.81C841.74,122.33 839.02,125.04 833.51,125.04L828.29,125.04C822.77,125.04 820.06,122.32 820.06,116.81L820.06,102.76C820.06,97.24 822.78,94.48 828.29,94.48L833.51,94.48C839.03,94.48 841.74,97.24 841.74,102.76L841.74,116.81ZM1044.21,116.81C1044.21,122.33 1041.49,125.04 1035.98,125.04L1030.76,125.04C1025.24,125.04 1022.53,122.32 1022.53,116.81L1022.53,102.76C1022.53,97.24 1025.25,94.48 1030.76,94.48L1035.98,94.48C1041.5,94.48 1044.21,97.24 1044.21,102.76L1044.21,116.81ZM894.48,116.81C894.48,122.33 891.76,125.04 886.25,125.04L881.03,125.04C875.51,125.04 872.8,122.32 872.8,116.81L872.8,102.76C872.8,97.24 875.52,94.48 881.03,94.48L886.25,94.48C891.77,94.48 894.48,97.24 894.48,102.76L894.48,116.81ZM312.18,106.66L312.18,112.82L302.67,112.82L302.67,125.04L296.52,125.04L296.52,94.48L315.15,94.48L315.15,100.72L302.67,100.72L302.67,106.66L312.18,106.66ZM501.08,116.81C501.08,122.33 498.36,125.04 492.85,125.04L487.63,125.04C482.11,125.04 479.4,122.32 479.4,116.81L479.4,102.76C479.4,97.24 482.12,94.48 487.63,94.48L492.85,94.48C498.37,94.48 501.08,97.24 501.08,102.76L501.08,116.81ZM405.422,94.48C410.921,94.491 413.67,97.211 413.67,102.76L413.67,106.41C413.67,109.76 412.44,112.14 409.85,113.58L413.67,125.04L407.47,125.04L403.31,114.69L399.2,114.69L399.2,125.04L392.96,125.04L392.96,94.48L405.39,94.48L405.422,94.48ZM851.71,124.66C851.62,124.66 851.58,124.66 851.54,124.53C851.07,124.45 850.74,124.32 850.35,124.15C850.35,124.15 850.31,124.11 850.22,124.11C848.74,123.31 847.72,121.95 847.12,120.21C847.12,120.157 847.107,120.1 847.08,120.04C846.82,119.11 846.66,118.05 846.66,116.81L846.66,102.76C846.66,101.49 846.83,100.38 847.08,99.49L847.12,99.32C847.72,97.49 848.73,96.22 850.22,95.42C850.31,95.38 850.35,95.38 850.35,95.38C850.73,95.21 851.07,95.04 851.54,94.87C851.58,94.87 851.63,94.87 851.71,94.83C852.43,94.66 853.15,94.53 854.04,94.49L861.13,94.49C861.26,94.49 861.39,94.53 861.47,94.53C861.64,94.53 861.85,94.53 862.02,94.61C862.19,94.61 862.32,94.65 862.53,94.65C862.66,94.65 862.79,94.69 862.87,94.69C863.04,94.73 863.17,94.82 863.38,94.82L863.68,94.9C863.85,95.03 864.06,95.07 864.19,95.16C864.27,95.16 864.36,95.2 864.4,95.2C864.57,95.33 864.74,95.37 864.91,95.41C864.95,95.49 865.04,95.49 865.08,95.54L865.59,95.88L865.72,96.01C865.85,96.05 865.97,96.22 866.1,96.35C866.19,96.35 866.19,96.39 866.27,96.39C866.36,96.56 866.53,96.73 866.65,96.81C866.65,96.89 866.69,96.89 866.69,96.94C866.82,97.07 866.99,97.28 867.11,97.45L867.15,97.49C867.28,97.66 867.36,97.83 867.45,98.13C867.45,98.13 867.49,98.13 867.49,98.17C867.53,98.34 867.7,98.59 867.79,98.81L867.83,98.85C867.87,99.06 867.92,99.32 868.04,99.57C868.08,99.87 868.17,100.08 868.21,100.42C868.21,100.72 868.25,100.97 868.34,101.27C868.34,101.78 868.43,102.25 868.43,102.75L868.43,104.32L862.19,104.32L862.19,102.75C862.19,102.58 862.15,102.33 862.15,102.24C862.11,101.98 862.02,101.77 861.98,101.56C861.98,101.56 861.94,101.56 861.94,101.47C861.86,101.3 861.77,101.21 861.56,101.09L861.48,101.05C861.31,100.92 861.22,100.84 860.93,100.75C860.93,100.75 860.89,100.75 860.89,100.71C860.63,100.71 860.42,100.67 860.08,100.67L854.65,100.67C854.59,100.67 854.547,100.683 854.52,100.71C854.22,100.71 854.01,100.75 853.84,100.92L853.8,100.92C853.63,101.05 853.46,101.13 853.33,101.26C853.33,101.3 853.29,101.3 853.29,101.39C853.16,101.47 853.12,101.73 853.08,101.9C853.02,101.927 852.99,101.957 852.99,101.99C852.95,102.25 852.95,102.5 852.95,102.75L852.95,116.8C852.95,117.01 852.95,117.31 852.99,117.52C852.99,117.52 852.99,117.56 853.08,117.56C853.12,117.77 853.17,118.03 853.29,118.11C853.29,118.19 853.33,118.19 853.33,118.19C853.46,118.36 853.63,118.45 853.8,118.53C853.8,118.57 853.84,118.57 853.84,118.57C854.01,118.61 854.22,118.78 854.52,118.78L854.65,118.78C854.74,118.87 854.86,118.87 854.99,118.87L860.08,118.87C860.42,118.87 860.63,118.78 860.89,118.74L860.93,118.74C861.23,118.61 861.31,118.53 861.48,118.44C861.48,118.4 861.56,118.4 861.56,118.4C861.77,118.27 861.86,118.1 861.94,117.89C861.94,117.89 861.98,117.89 861.98,117.85C862.02,117.68 862.11,117.51 862.15,117.3C862.15,117.04 862.19,116.96 862.19,116.79L862.19,115.22L868.43,115.22L868.43,116.79C868.43,117.3 868.34,117.72 868.34,118.19C868.25,118.45 868.21,118.78 868.21,119.08C868.17,119.38 868.08,119.63 868.04,119.85L868.04,119.93C867.91,120.19 867.87,120.44 867.83,120.65L867.79,120.65C867.7,120.95 867.53,121.16 867.49,121.33L867.45,121.37C867.36,121.54 867.28,121.84 867.15,122.01C867.15,122.01 867.11,122.01 867.11,122.05C866.98,122.22 866.81,122.35 866.69,122.56C866.69,122.6 866.65,122.6 866.65,122.6C866.52,122.77 866.35,122.9 866.27,123.07C866.19,123.07 866.19,123.2 866.1,123.2C865.97,123.29 865.84,123.41 865.72,123.54L865.59,123.62C865.38,123.71 865.25,123.79 865.08,123.96L864.91,124C864.74,124.13 864.57,124.17 864.4,124.26C864.36,124.3 864.27,124.3 864.19,124.34C864.06,124.43 863.85,124.47 863.68,124.51C863.55,124.51 863.51,124.64 863.38,124.64C863.17,124.68 863.04,124.77 862.87,124.77C862.78,124.81 862.66,124.81 862.53,124.86C862.32,124.86 862.19,124.94 862.02,124.94C861.85,124.94 861.64,124.98 861.47,124.98C861.38,124.98 861.26,124.98 861.13,125.02L854.04,125.02C853.15,124.98 852.43,124.85 851.71,124.64L851.71,124.66ZM988.92,124.66C988.83,124.66 988.79,124.66 988.75,124.53C988.28,124.45 987.95,124.32 987.56,124.15C987.56,124.15 987.52,124.11 987.43,124.11C985.95,123.31 984.93,121.95 984.33,120.21C984.33,120.157 984.317,120.1 984.29,120.04C984.03,119.11 983.87,118.05 983.87,116.81L983.87,102.76C983.87,101.49 984.04,100.38 984.29,99.49L984.33,99.32C984.93,97.49 985.94,96.22 987.43,95.42C987.52,95.38 987.56,95.38 987.56,95.38C987.94,95.21 988.28,95.04 988.75,94.87C988.79,94.87 988.84,94.87 988.92,94.83C989.64,94.66 990.36,94.53 991.25,94.49L998.34,94.49C998.47,94.49 998.6,94.53 998.68,94.53C998.85,94.53 999.06,94.53 999.23,94.61C999.4,94.61 999.53,94.65 999.74,94.65C999.87,94.65 1000,94.69 1000.08,94.69C1000.25,94.73 1000.38,94.82 1000.59,94.82L1000.89,94.9C1001.06,95.03 1001.27,95.07 1001.4,95.16C1001.48,95.16 1001.57,95.2 1001.61,95.2C1001.78,95.33 1001.95,95.37 1002.12,95.41C1002.16,95.49 1002.25,95.49 1002.29,95.54L1002.8,95.88L1002.93,96.01C1003.06,96.05 1003.18,96.22 1003.31,96.35C1003.4,96.35 1003.4,96.39 1003.48,96.39C1003.57,96.56 1003.74,96.73 1003.86,96.81C1003.86,96.89 1003.9,96.89 1003.9,96.94C1004.03,97.07 1004.2,97.28 1004.32,97.45L1004.36,97.49C1004.49,97.66 1004.57,97.83 1004.66,98.13C1004.66,98.13 1004.7,98.13 1004.7,98.17C1004.74,98.34 1004.91,98.59 1005,98.81L1005.04,98.85C1005.08,99.06 1005.13,99.32 1005.25,99.57C1005.29,99.87 1005.38,100.08 1005.42,100.42C1005.42,100.72 1005.46,100.97 1005.55,101.27C1005.55,101.78 1005.64,102.25 1005.64,102.75L1005.64,104.32L999.4,104.32L999.4,102.75C999.4,102.58 999.36,102.33 999.36,102.24C999.32,101.98 999.23,101.77 999.19,101.56C999.19,101.56 999.15,101.56 999.15,101.47C999.06,101.3 998.98,101.21 998.77,101.09L998.69,101.05C998.52,100.92 998.43,100.84 998.14,100.75C998.14,100.75 998.1,100.75 998.1,100.71C997.84,100.71 997.63,100.67 997.29,100.67L991.86,100.67C991.8,100.67 991.757,100.683 991.73,100.71C991.43,100.71 991.22,100.75 991.05,100.92L991.01,100.92C990.84,101.05 990.67,101.13 990.54,101.26C990.54,101.3 990.5,101.3 990.5,101.39C990.37,101.47 990.33,101.73 990.29,101.9C990.23,101.927 990.2,101.957 990.2,101.99C990.16,102.25 990.16,102.5 990.16,102.75L990.16,116.8C990.16,117.01 990.16,117.31 990.2,117.52C990.2,117.52 990.2,117.56 990.29,117.56C990.33,117.77 990.38,118.03 990.5,118.11C990.5,118.19 990.54,118.19 990.54,118.19C990.67,118.36 990.84,118.45 991.01,118.53C991.01,118.57 991.05,118.57 991.05,118.57C991.22,118.61 991.43,118.78 991.73,118.78L991.86,118.78C991.95,118.87 992.07,118.87 992.2,118.87L997.29,118.87C997.63,118.87 997.84,118.78 998.1,118.74L998.14,118.74C998.44,118.61 998.52,118.53 998.69,118.44C998.69,118.4 998.77,118.4 998.77,118.4C998.98,118.27 999.07,118.1 999.15,117.89C999.15,117.89 999.19,117.89 999.19,117.85C999.23,117.68 999.32,117.51 999.36,117.3C999.36,117.04 999.4,116.96 999.4,116.79L999.4,115.22L1005.64,115.22L1005.64,116.79C1005.64,117.3 1005.55,117.72 1005.55,118.19C1005.46,118.45 1005.42,118.78 1005.42,119.08C1005.38,119.38 1005.29,119.63 1005.25,119.85L1005.25,119.93C1005.12,120.19 1005.08,120.44 1005.04,120.65L1005,120.65C1004.91,120.95 1004.74,121.16 1004.7,121.33L1004.66,121.37C1004.57,121.54 1004.49,121.84 1004.36,122.01C1004.36,122.01 1004.32,122.01 1004.32,122.05C1004.19,122.22 1004.02,122.35 1003.9,122.56C1003.9,122.6 1003.86,122.6 1003.86,122.6C1003.73,122.77 1003.56,122.9 1003.48,123.07C1003.4,123.07 1003.4,123.2 1003.31,123.2C1003.18,123.29 1003.05,123.41 1002.93,123.54L1002.8,123.62C1002.59,123.71 1002.46,123.79 1002.29,123.96L1002.12,124C1001.95,124.13 1001.78,124.17 1001.61,124.26C1001.57,124.3 1001.48,124.3 1001.4,124.34C1001.27,124.43 1001.06,124.47 1000.89,124.51C1000.76,124.51 1000.72,124.64 1000.59,124.64C1000.38,124.68 1000.25,124.77 1000.08,124.77C999.99,124.81 999.87,124.81 999.74,124.86C999.53,124.86 999.4,124.94 999.23,124.94C999.06,124.94 998.85,124.98 998.68,124.98C998.59,124.98 998.47,124.98 998.34,125.02L991.25,125.02C990.36,124.98 989.64,124.85 988.92,124.64L988.92,124.66ZM915.65,124.66C915.56,124.66 915.52,124.66 915.48,124.53C915.01,124.45 914.68,124.32 914.29,124.15C914.29,124.15 914.25,124.11 914.16,124.11C912.68,123.31 911.66,121.95 911.06,120.21C911.06,120.157 911.047,120.1 911.02,120.04C910.76,119.11 910.6,118.05 910.6,116.81L910.6,102.76C910.6,101.49 910.77,100.38 911.02,99.49L911.06,99.32C911.66,97.49 912.67,96.22 914.16,95.42C914.25,95.38 914.29,95.38 914.29,95.38C914.67,95.21 915.01,95.04 915.48,94.87C915.52,94.87 915.57,94.87 915.65,94.83C916.37,94.66 917.09,94.53 917.98,94.49L925.07,94.49C925.2,94.49 925.33,94.53 925.41,94.53C925.58,94.53 925.79,94.53 925.96,94.61C926.13,94.61 926.26,94.65 926.47,94.65C926.6,94.65 926.73,94.69 926.81,94.69C926.98,94.73 927.11,94.82 927.32,94.82L927.62,94.9C927.79,95.03 928,95.07 928.13,95.16C928.21,95.16 928.3,95.2 928.34,95.2C928.51,95.33 928.68,95.37 928.85,95.41C928.89,95.49 928.98,95.49 929.02,95.54L929.53,95.88L929.66,96.01C929.79,96.05 929.91,96.22 930.04,96.35C930.13,96.35 930.13,96.39 930.21,96.39C930.3,96.56 930.47,96.73 930.59,96.81C930.59,96.89 930.63,96.89 930.63,96.94C930.76,97.07 930.93,97.28 931.05,97.45L931.09,97.49C931.22,97.66 931.3,97.83 931.39,98.13C931.39,98.13 931.43,98.13 931.43,98.17C931.47,98.34 931.64,98.59 931.73,98.81L931.77,98.85C931.81,99.06 931.86,99.32 931.98,99.57C932.02,99.87 932.11,100.08 932.15,100.42C932.15,100.72 932.19,100.97 932.28,101.27C932.28,101.78 932.37,102.25 932.37,102.75L932.37,104.32L926.13,104.32L926.13,102.75C926.13,102.58 926.09,102.33 926.09,102.24C926.05,101.98 925.96,101.77 925.92,101.56C925.92,101.56 925.88,101.56 925.88,101.47C925.8,101.3 925.71,101.21 925.5,101.09L925.42,101.05C925.25,100.92 925.16,100.84 924.87,100.75C924.87,100.75 924.83,100.75 924.83,100.71C924.57,100.71 924.36,100.67 924.02,100.67L918.59,100.67C918.53,100.67 918.487,100.683 918.46,100.71C918.16,100.71 917.95,100.75 917.78,100.92L917.74,100.92C917.57,101.05 917.4,101.13 917.27,101.26C917.27,101.3 917.23,101.3 917.23,101.39C917.1,101.47 917.06,101.73 917.02,101.9C916.96,101.927 916.93,101.957 916.93,101.99C916.89,102.25 916.89,102.5 916.89,102.75L916.89,116.8C916.89,117.01 916.89,117.31 916.93,117.52C916.93,117.52 916.93,117.56 917.02,117.56C917.06,117.77 917.11,118.03 917.23,118.11C917.23,118.19 917.27,118.19 917.27,118.19C917.4,118.36 917.57,118.45 917.74,118.53C917.74,118.57 917.78,118.57 917.78,118.57C917.95,118.61 918.16,118.78 918.46,118.78L918.59,118.78C918.68,118.87 918.8,118.87 918.93,118.87L924.02,118.87C924.36,118.87 924.57,118.78 924.83,118.74L924.87,118.74C925.17,118.61 925.25,118.53 925.42,118.44C925.42,118.4 925.5,118.4 925.5,118.4C925.71,118.27 925.8,118.1 925.88,117.89C925.88,117.89 925.92,117.89 925.92,117.85C925.96,117.68 926.05,117.51 926.09,117.3C926.09,117.04 926.13,116.96 926.13,116.79L926.13,115.22L932.37,115.22L932.37,116.79C932.37,117.3 932.28,117.72 932.28,118.19C932.19,118.45 932.15,118.78 932.15,119.08C932.11,119.38 932.02,119.63 931.98,119.85L931.98,119.93C931.85,120.19 931.81,120.44 931.77,120.65L931.73,120.65C931.64,120.95 931.47,121.16 931.43,121.33L931.39,121.37C931.3,121.54 931.22,121.84 931.09,122.01C931.09,122.01 931.05,122.01 931.05,122.05C930.92,122.22 930.75,122.35 930.63,122.56C930.63,122.6 930.59,122.6 930.59,122.6C930.46,122.77 930.29,122.9 930.21,123.07C930.13,123.07 930.13,123.2 930.04,123.2C929.91,123.29 929.78,123.41 929.66,123.54L929.53,123.62C929.32,123.71 929.19,123.79 929.02,123.96L928.85,124C928.68,124.13 928.51,124.17 928.34,124.26C928.3,124.3 928.21,124.3 928.13,124.34C928,124.43 927.79,124.47 927.62,124.51C927.49,124.51 927.45,124.64 927.32,124.64C927.11,124.68 926.98,124.77 926.81,124.77C926.72,124.81 926.6,124.81 926.47,124.86C926.26,124.86 926.13,124.94 925.96,124.94C925.79,124.94 925.58,124.98 925.41,124.98C925.32,124.98 925.2,124.98 925.07,125.02L917.98,125.02C917.09,124.98 916.37,124.85 915.65,124.64L915.65,124.66ZM78.68,121.82L82.08,104.32L85.49,121.82L78.68,121.82ZM171.17,121.82L174.57,104.32L177.97,121.82L171.17,121.82ZM485.59,116.81C485.59,118.17 486.27,118.85 487.63,118.85L492.85,118.85C494.21,118.85 494.89,118.17 494.89,116.81L494.89,102.76C494.89,101.36 494.21,100.64 492.85,100.64L487.63,100.64C486.27,100.64 485.59,101.36 485.59,102.76L485.59,116.81ZM878.99,116.81C878.99,118.17 879.67,118.85 881.03,118.85L886.25,118.85C887.61,118.85 888.29,118.17 888.29,116.81L888.29,102.76C888.29,101.36 887.61,100.64 886.25,100.64L881.03,100.64C879.67,100.64 878.99,101.36 878.99,102.76L878.99,116.81ZM826.25,116.81C826.25,118.17 826.93,118.85 828.29,118.85L833.51,118.85C834.87,118.85 835.55,118.17 835.55,116.81L835.55,102.76C835.55,101.36 834.87,100.64 833.51,100.64L828.29,100.64C826.93,100.64 826.25,101.36 826.25,102.76L826.25,116.81ZM1028.72,116.81C1028.72,118.17 1029.4,118.85 1030.76,118.85L1035.98,118.85C1037.34,118.85 1038.02,118.17 1038.02,116.81L1038.02,102.76C1038.02,101.36 1037.34,100.64 1035.98,100.64L1030.76,100.64C1029.4,100.64 1028.72,101.36 1028.72,102.76L1028.72,116.81ZM357.5,102.77C357.5,101.37 356.78,100.73 355.42,100.73L349.22,100.73L349.22,118.85L355.42,118.85C356.78,118.85 357.5,118.13 357.5,116.73L357.5,102.77ZM425.73,100.65C424.33,100.65 423.65,101.37 423.65,102.77L423.65,112.87L431.92,112.87L431.92,102.77C431.92,101.37 431.16,100.65 429.93,100.65L425.73,100.65ZM944.55,100.65C943.15,100.65 942.47,101.37 942.47,102.77L942.47,112.87L950.74,112.87L950.74,102.77C950.74,101.37 949.98,100.65 948.75,100.65L944.55,100.65ZM727.27,100.65C725.87,100.65 725.19,101.37 725.19,102.77L725.19,112.87L733.46,112.87L733.46,102.77C733.46,101.37 732.7,100.65 731.47,100.65L727.27,100.65ZM673,100.65C671.6,100.65 670.92,101.37 670.92,102.77L670.92,112.87L679.19,112.87L679.19,102.77C679.19,101.37 678.43,100.65 677.2,100.65L673,100.65ZM612.42,100.65C611.02,100.65 610.34,101.37 610.34,102.77L610.34,112.87L618.61,112.87L618.61,102.77C618.61,101.37 617.85,100.65 616.62,100.65L612.42,100.65ZM399.2,100.69L399.2,108.5L405.4,108.5C406.8,108.5 407.48,107.78 407.48,106.42L407.48,102.77C407.48,101.37 406.8,100.69 405.4,100.69L399.2,100.69ZM193.1,41.29L206.33,48.36L203.82,33.57L214.53,23.57L199.71,21.17L199.72,21.19L199.7,21.17L193.1,7.7L193.09,7.7L186.49,21.17L186.47,21.19L186.48,21.17L171.66,23.57L182.37,33.57L179.86,48.36L193.09,41.29L193.1,41.29ZM28.04,21.17L21.43,7.7L14.82,21.17L0,23.57L10.7,33.57L8.19,48.36L21.43,41.29L34.67,48.36L32.16,33.57L42.86,23.57L28.05,21.17L28.05,21.19L28.04,21.17ZM142.48,13.47L135.87,0L129.26,13.47L114.44,15.87L125.15,25.88L122.63,40.66L135.87,33.59L149.11,40.66L146.6,25.88L157.31,15.87L142.49,13.47L142.5,13.49L142.48,13.47ZM85.26,13.47L78.65,0L72.04,13.47L57.22,15.87L67.93,25.88L65.41,40.66L78.65,33.59L91.89,40.66L89.38,25.88L100.08,15.87L85.27,13.47L85.27,13.49L85.26,13.47Z" style="fill:white;fill-rule:nonzero;"/>\n </svg>',t.figc={},t.figc.updateLogo=n;var i=e.prototype.calculateLogoPosition;e.prototype.calculateLogoPosition=function(e){if(!t.useFigcLogo)return i.apply(t,[e]);switch(e){case"top_left":return"translate(20,30) scale(0.2)";case"top_right":return"translate(620,30) scale(0.2)";case"bottom_left":return"translate(20,520) scale(0.2)";case"bottom_right":return"translate(620,520) scale(0.2)";default:return"translate(200,250) scale(0.5)"}}},r=function(t){return{initEditor:function(t){i(t)},initViewer:function(t){i(t)},onLoadModel:function(t,e){void 0!==e.useFigcLogo&&!0===e.useFigcLogo&&(t.useFigcLogo=!0,n(t))}}};e.prototype.plugins.push(r),e.prototype.viewerPlugins.push(r)}(jQuery,YCEditor),function(t,e){"use strict";var n=function(e){var n=250;"viewer"===e.options.mode&&(n=0,e.updateLogoPosition(!1)),e.useInterLogo?(d3.select(".logo-layer",e.logoLayer).attr("opacity",.1),d3.selectAll("#yceditor_yclogo, .special_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",0),0==d3.select("#inter_logo_svg",e.logoLayer).size()&&(e.interLogoWrapper=e.logoLayer.append("g").attr("transform","translate(0, -160)").attr("id","inter_logo_svg").attr("class","special_logo_svg"),t(e.interLogoWrapper.node()).prepend(t(e.logoINTER)),d3.select("#inter_logo_svg",e.logoLayer).attr("opacity",0)),d3.select("#inter_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",1)):(d3.select("#yceditor_yclogo",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",1),d3.selectAll(".special_logo_svg",e.logoLayer).transition().duration(n).ease("cubic-in-out").attr("opacity",0))},i=function(t){t.logoINTER='<svg id="WHITE" xmlns="http://www.w3.org/2000/svg" baseProfile="tiny" version="1.2" viewBox="0 0 1800 1800"><path d="M900,1333.27C567.66,1333.27 297.574,1063.18 297.574,730.844C297.574,398.504 567.66,128.418 900,128.418C1232.34,128.418 1502.43,398.504 1502.43,730.844C1502.43,1063.18 1232.34,1333.27 900,1333.27ZM900,28C511.448,28 197.156,342.292 197.156,730.844C197.156,1119.39 511.448,1433.69 900,1433.69C1288.55,1433.69 1602.84,1119.39 1602.84,730.844C1602.84,342.292 1288.55,28 900,28ZM536.493,1077.26L549.532,927.624C517.411,869.425 498.33,802.082 498.33,730.844C498.33,659.605 525.442,565.151 570.602,500.909L523.374,398.504C445.06,486.836 397.832,603.314 397.832,730.844C397.832,858.373 450.069,986.857 536.414,1077.26L536.493,1077.26ZM1263.51,1077.26C1349.85,986.857 1402.09,865.37 1402.09,730.844C1402.09,596.318 1354.86,486.836 1276.55,398.504L1229.32,500.909C1274.48,565.151 1301.59,645.532 1301.59,730.844C1301.59,816.155 1282.51,869.425 1250.39,927.624L1263.43,1077.26L1263.51,1077.26ZM560.663,360.34L635.957,521.978L582.766,1120.43C612.899,1144.52 643.987,1164.63 678.175,1181.65L720.314,701.665L801.65,876.342L801.65,638.377L643.033,299.04C613.933,317.088 586.821,337.204 560.663,360.261L560.663,360.34ZM998.43,876.421L1079.77,701.744L1121.9,1181.73C1156.01,1164.63 1187.18,1144.6 1217.31,1120.51L1164.12,522.058L1239.42,360.42C1213.34,337.363 1186.23,317.247 1157.05,299.199L998.43,638.536L998.43,876.501L998.43,876.421ZM688.113,275.983L730.252,366.383C766.428,349.289 806.579,337.283 848.718,332.274L848.718,1129.49C808.567,1124.48 771.437,1113.43 736.295,1097.37L727.231,1202.8C780.421,1221.88 838.7,1232.93 899.92,1232.93C961.141,1232.93 1019.42,1221.88 1072.61,1202.8L1063.55,1097.37C1028.4,1113.43 990.241,1124.48 951.123,1129.49L951.123,332.195C993.262,337.204 1033.49,349.289 1069.59,366.303L1111.73,275.903C1047.49,245.77 976.168,228.676 899.841,228.676C823.514,228.676 752.276,245.77 687.954,275.903L688.113,275.983Z" style="fill:white"/><path d="M900.961,1797.37C877.483,1793.49 859.916,1778.66 852.442,1756.4C848.32,1744.12 848.298,1743.6 848.298,1656.67C848.298,1588.84 848.604,1570.38 849.806,1565.91C857.392,1537.72 870.521,1523.63 895.358,1517.01C907.056,1513.89 943.537,1515.68 947.966,1519.59C948.229,1519.83 950.089,1520.53 950.548,1520.53C953.049,1520.53 964.919,1529.12 968.691,1533.67C979.162,1546.27 982.315,1559.7 982.573,1592.8L982.757,1616.33L941.299,1616.33L940.675,1592.8C939.996,1567.19 939.3,1563.95 933.313,1558.5C924.3,1550.3 906.974,1551.76 899.962,1561.3C894.065,1569.33 894.238,1566.44 894.238,1656.67C894.238,1746.9 894.065,1744.01 899.962,1752.04C906.971,1761.58 924.377,1763.05 933.267,1754.84C939.547,1749.05 939.953,1746.76 940.654,1713.26L941.299,1682.44L982.757,1682.44L982.695,1712.13C982.625,1746.26 981.323,1755.53 974.703,1769.02C968.319,1782.03 956.426,1791.43 940.738,1795.87C934.494,1797.64 908.535,1798.62 900.961,1797.37L900.961,1797.37ZM13,1795.06L13,1518.29L58.94,1518.29L58.94,1795.06L13,1795.06ZM81.35,1656.68L81.35,1518.25L126.398,1518.86L127.797,1523.34C128.566,1525.8 130.358,1531.6 131.78,1536.23C135.776,1549.22 143.162,1572.39 144.105,1574.88C144.57,1576.11 146.08,1580.9 147.459,1585.53C148.838,1590.15 150.351,1594.94 150.82,1596.17C151.289,1597.4 153.32,1603.71 155.334,1610.18C159.11,1622.31 162.553,1633.21 168.44,1651.64C170.31,1657.49 172.516,1664.67 173.34,1667.6C174.165,1670.53 175.234,1672.92 175.716,1672.92C176.198,1672.92 176.592,1638.13 176.592,1595.61L176.592,1518.3L215.818,1518.3L215.249,1794.5L175.46,1795.11L173.828,1791.44C172.228,1787.84 164.882,1765.27 163.157,1758.64C162.675,1756.79 159.162,1745.45 155.349,1733.43C151.536,1721.41 145.893,1703.51 142.809,1693.65C139.724,1683.79 136.294,1672.95 135.184,1669.56C134.076,1666.17 131.539,1658.1 129.548,1651.63C123.732,1632.74 122.831,1630.19 121.1,1627.72C119.654,1625.66 119.428,1635.35 119.174,1709.94L118.886,1794.5L81.35,1795.11L81.35,1656.68L81.35,1656.68ZM270.118,1793.66C269.827,1792.89 269.465,1739.06 269.312,1674.05L269.035,1555.83L230.939,1554.71L230.323,1518.3L354.805,1518.3L354.19,1554.71L335.75,1555.02C322.718,1555.24 317.055,1555.73 316.438,1556.7C315.959,1557.46 315.559,1611.39 315.55,1676.57L315.533,1795.06L293.088,1795.06C276.161,1795.06 270.513,1794.71 270.115,1793.66L270.118,1793.66ZM371.184,1794.31C370.772,1793.9 370.437,1731.63 370.437,1655.93L370.437,1518.29L481.364,1518.29L481.364,1555.27L450.27,1555.29C433.169,1555.3 418.54,1555.71 417.761,1556.2C416.656,1556.9 416.41,1565.67 416.641,1596.24L416.936,1635.38L463.491,1635.99L463.183,1654.18L462.876,1672.36L416.936,1673.48L416.642,1714.87C416.412,1747.23 416.656,1756.44 417.762,1757.15C418.54,1757.64 433.169,1758.05 450.27,1758.06L481.364,1758.08L481.364,1795.05L426.647,1795.05C396.552,1795.05 371.593,1794.72 371.182,1794.31L371.184,1794.31ZM501.183,1794.33C500.759,1793.91 500.413,1731.63 500.413,1655.93L500.413,1518.3L541.031,1518.3C587.389,1518.3 591.669,1518.78 606.478,1525.73C616.364,1530.37 624.353,1539.77 628.772,1551.95C635.271,1569.86 635.322,1624.64 628.857,1642.4C624.696,1653.84 613.849,1663.89 601.85,1667.43C598.651,1668.38 596.775,1669.58 596.775,1670.67C596.775,1671.63 598.819,1678.2 601.316,1685.28C603.814,1692.35 606.612,1700.41 607.536,1703.18C608.459,1705.95 609.671,1709.23 610.231,1710.46C610.79,1711.69 612.498,1716.48 614.025,1721.11C615.553,1725.73 618.387,1733.8 620.323,1739.03C622.259,1744.27 624.77,1751.33 625.903,1754.72C627.035,1758.11 630.526,1768.13 633.658,1776.99C636.791,1785.85 639.354,1793.53 639.354,1794.08C639.354,1795.72 592.775,1795.31 591.421,1793.66C590.791,1792.89 588.99,1788.48 587.421,1783.85C585.851,1779.23 579.982,1762.09 574.379,1745.76C568.775,1729.43 562.224,1710.27 559.82,1703.18C557.416,1696.09 554.449,1687.52 553.226,1684.13C547.782,1669.04 548.076,1666.55 547.474,1732.87L546.913,1794.5L524.432,1794.8C512.069,1794.97 501.606,1794.76 501.183,1794.33L501.183,1794.33ZM573.506,1641.04C578.095,1639.13 584.061,1632.7 585.274,1628.37C585.746,1626.68 586.131,1612.95 586.131,1597.85C586.131,1567.38 585.846,1565.98 578.569,1560.48C573.566,1556.71 567.599,1555.29 556.718,1555.28L547.474,1555.27L547.474,1642.67L558.542,1642.67C565.686,1642.67 570.991,1642.09 573.506,1641.04L573.506,1641.04ZM683.056,1792.13C683.056,1790.5 683.533,1787.33 684.117,1785.1C684.701,1782.88 686.242,1775 687.543,1767.61C688.844,1760.21 690.399,1751.89 691,1749.12C691.601,1746.35 696.142,1722.39 701.092,1695.89C706.042,1669.39 711.094,1642.42 712.319,1635.95C713.544,1629.48 714.986,1621.66 715.523,1618.58C716.06,1615.5 717.296,1608.94 718.271,1604.01C719.245,1599.09 720.539,1592.28 721.146,1588.89C721.752,1585.5 723.269,1577.43 724.515,1570.96C725.761,1564.49 727.313,1556.17 727.963,1552.47C728.614,1548.77 729.576,1543.73 730.101,1541.27C731.976,1532.46 733.476,1524.41 733.755,1521.66L734.038,1518.86L787.822,1518.86L788.564,1523.34C789.59,1529.54 791.538,1540.18 792.87,1546.87C793.483,1549.95 794.509,1555.25 795.15,1558.63C795.79,1562.02 796.755,1567.07 797.295,1569.84C797.834,1572.61 798.825,1577.91 799.497,1581.6C800.168,1585.3 801.174,1590.6 801.73,1593.37C803.001,1599.7 804.856,1609.46 806.311,1617.46C807.824,1625.78 809.685,1635.55 810.792,1640.99C811.9,1646.43 813.761,1656.2 815.275,1664.52C816.788,1672.84 818.649,1682.61 819.757,1688.05C820.259,1690.52 821.243,1695.56 821.943,1699.26C822.644,1702.95 823.699,1708.5 824.289,1711.58C824.879,1714.66 825.867,1719.96 826.485,1723.35C827.104,1726.74 828.065,1731.78 828.622,1734.55C829.178,1737.33 830.207,1742.62 830.907,1746.32C831.608,1750.01 832.663,1755.56 833.253,1758.64C833.843,1761.72 834.831,1767.02 835.45,1770.41C836.068,1773.8 837.032,1778.84 837.592,1781.61C838.151,1784.39 838.971,1788.55 839.414,1790.86L840.219,1795.06L816.662,1795.06C791.059,1795.06 791.744,1795.24 791.744,1788.65C791.744,1787.08 791.273,1783.97 790.697,1781.74C790.121,1779.51 789.071,1773.91 788.361,1769.29C787.215,1761.82 785.999,1755.07 784.375,1747.16C783.858,1744.64 783.845,1744.64 760.069,1744.65C746.985,1744.66 735.727,1745.04 735.052,1745.49C734.376,1745.95 733.433,1748.84 732.956,1751.92C732.023,1757.94 731.033,1764.17 729.037,1776.57C728.343,1780.88 727.42,1786.68 726.985,1789.46L726.195,1794.5L683.056,1795.11L683.056,1792.13ZM776.397,1707.16C777.61,1705.95 777.785,1704.47 777.092,1701.28C776.583,1698.94 775.618,1693.49 774.949,1689.17C774.279,1684.86 773.245,1678.43 772.652,1674.89C772.059,1671.35 771.07,1665.42 770.454,1661.72C769.837,1658.03 768.828,1651.97 768.212,1648.28C767.596,1644.58 766.588,1638.53 765.971,1634.83C765.355,1631.13 764.347,1625.08 763.73,1621.38C760.079,1599.48 758.811,1595.53 757.651,1602.47C757.302,1604.55 755.247,1617.1 753.083,1630.35C750.919,1643.6 748.666,1657.21 748.078,1660.6C747.489,1663.99 746.464,1670.04 745.8,1674.05C745.135,1678.05 743.649,1686.88 742.496,1693.66C740.578,1704.94 740.552,1706.1 742.195,1707.38C744.93,1709.52 774.23,1709.33 776.397,1707.16ZM991.194,1794.44C991.194,1794.1 991.656,1791.7 992.222,1789.12C992.788,1786.53 993.821,1781.39 994.517,1777.69C995.214,1774 996.215,1768.7 996.742,1765.93C997.27,1763.16 998.224,1758.11 998.863,1754.73C999.501,1751.34 1000.6,1745.54 1001.31,1741.84C1002.02,1738.14 1003.07,1732.6 1003.65,1729.51C1004.23,1726.43 1005.24,1721.14 1005.89,1717.75C1007.06,1711.72 1008.01,1706.67 1010.34,1694.22C1010.98,1690.83 1011.97,1685.54 1012.55,1682.45C1013.12,1679.37 1014.57,1671.81 1015.76,1665.65C1016.94,1659.48 1018.98,1648.64 1020.28,1641.56C1021.58,1634.47 1023.11,1626.4 1023.67,1623.63C1024.23,1620.85 1025.76,1612.79 1027.07,1605.7C1028.37,1598.61 1032.58,1576.17 1036.42,1555.84L1043.41,1518.86L1069.96,1518.56C1084.57,1518.4 1096.52,1518.67 1096.52,1519.17C1096.52,1519.67 1097.5,1524.85 1098.7,1530.68C1099.9,1536.5 1101.94,1547.07 1103.24,1554.16C1104.53,1561.24 1106.04,1569.06 1106.58,1571.53C1107.13,1573.99 1108.11,1579.03 1108.77,1582.73C1109.89,1589.09 1111.9,1599.71 1116.81,1625.31C1117.99,1631.47 1119.49,1639.54 1120.14,1643.24C1120.79,1646.93 1121.75,1651.98 1122.28,1654.44C1124.12,1663.12 1126.72,1676.73 1129.01,1689.74C1129.71,1693.74 1130.71,1699.04 1131.24,1701.5C1132.38,1706.86 1134.38,1717.31 1135.74,1725.03C1137.03,1732.37 1139.05,1742.95 1140.22,1748.56C1141.12,1752.85 1142.14,1758.19 1144.78,1772.37C1145.44,1775.92 1146.45,1780.64 1147.02,1782.87C1147.59,1785.1 1148.06,1788.75 1148.06,1790.99L1148.06,1795.06L1125.21,1795.06C1099.16,1795.06 1101.53,1796.1 1099.68,1783.86C1099.08,1779.85 1098.17,1774.05 1097.66,1770.97C1097.15,1767.89 1096.19,1762.03 1095.53,1757.94C1094.87,1753.86 1093.83,1749.19 1093.21,1747.58L1092.09,1744.64L1068.04,1744.64C1052.67,1744.64 1043.73,1745.06 1043.27,1745.8C1042.88,1746.44 1042.07,1750.1 1041.48,1753.92C1040.88,1757.75 1039.87,1764.16 1039.23,1768.17C1038.59,1772.18 1037.85,1777.22 1037.58,1779.38C1037.31,1781.53 1036.51,1785.94 1035.81,1789.18L1034.54,1795.06L1012.87,1795.06C1000.95,1795.06 991.194,1794.78 991.194,1794.44ZM1085.73,1703.19C1085.66,1700.41 1084.99,1694.62 1084.24,1690.3C1081.15,1672.27 1079.21,1660.66 1077.61,1650.52C1076.97,1646.52 1075.92,1640.09 1075.28,1636.24C1074.64,1632.38 1073.59,1626.08 1072.94,1622.23C1072.3,1618.38 1071.5,1613.21 1071.17,1610.75C1070.46,1605.41 1068.57,1600.1 1067.4,1600.1C1066.93,1600.1 1066.27,1602.5 1065.92,1605.42C1065.58,1608.35 1064.74,1614.02 1064.05,1618.03C1063.37,1622.03 1062.29,1628.59 1061.65,1632.6C1061.01,1636.6 1060.06,1642.4 1059.55,1645.48C1059.03,1648.56 1058.02,1654.61 1057.31,1658.93C1056.59,1663.24 1055.58,1669.29 1055.06,1672.37C1049.98,1702.62 1049.6,1705.78 1050.9,1707.42C1051.74,1708.49 1056.26,1708.77 1068.95,1708.54L1085.88,1708.23L1085.73,1703.19ZM1163.38,1794.32C1162.96,1793.91 1162.63,1731.64 1162.63,1655.93L1162.63,1518.3L1205.19,1518.3C1233.08,1518.3 1249.6,1518.74 1253.09,1519.57C1281.03,1526.24 1295.25,1541.86 1300.38,1571.53C1301.39,1577.33 1301.64,1600.65 1301.35,1661.16C1300.91,1751.99 1301.24,1747.84 1293.17,1764.38C1285.51,1780.07 1273.4,1788.95 1253.09,1793.79C1247.3,1795.17 1164.71,1795.66 1163.37,1794.32L1163.38,1794.32ZM1242.77,1754.66C1248.77,1751.58 1252.69,1746.76 1254.49,1740.29C1255.19,1737.75 1255.62,1706.5 1255.62,1656.6C1255.63,1568.37 1255.81,1570.7 1248.36,1562.81C1243.25,1557.39 1237.56,1555.89 1222.01,1555.86L1209.13,1555.84L1208.84,1656.05C1208.61,1735.45 1208.85,1756.46 1209.96,1757.22C1210.73,1757.75 1217.18,1758.03 1224.28,1757.85C1235.57,1757.57 1237.9,1757.16 1242.77,1754.66L1242.77,1754.66ZM1323.6,1794.32C1323.19,1793.91 1322.85,1731.64 1322.85,1655.93L1322.85,1518.3L1433.78,1518.3L1433.78,1555.28L1369.96,1555.28L1369.34,1557.8C1369,1559.19 1368.87,1577.21 1369.04,1597.86L1369.35,1635.39L1392.6,1635.7L1415.85,1636L1415.85,1672.93L1392.9,1672.93C1370.04,1672.93 1369.95,1672.94 1369.34,1675.45C1369,1676.84 1368.87,1695.87 1369.04,1717.75L1369.35,1757.53L1433.78,1758.12L1433.78,1795.06L1379.07,1795.06C1348.97,1795.06 1324.01,1794.73 1323.6,1794.32L1323.6,1794.32ZM1453.61,1794.34C1453.18,1793.92 1452.83,1731.63 1452.83,1655.94L1452.83,1518.31L1507.44,1518.31L1508.25,1522.51C1508.69,1524.82 1509.47,1528.73 1509.97,1531.19C1510.48,1533.66 1511.41,1538.45 1512.05,1541.84C1512.68,1545.23 1514.77,1556.07 1516.69,1565.93C1518.62,1575.79 1521.14,1588.9 1522.31,1595.06C1529.74,1634.4 1537,1671.2 1537.43,1671.62C1538.31,1672.51 1540.25,1666.14 1541.42,1658.51C1542.04,1654.42 1543.09,1648.06 1543.74,1644.36C1544.39,1640.66 1545.38,1634.99 1545.94,1631.75C1546.5,1628.52 1547.41,1623.22 1547.97,1619.99C1548.53,1616.75 1549.52,1611.08 1550.17,1607.38C1550.83,1603.68 1551.85,1597.63 1552.46,1593.94C1553.07,1590.24 1554.12,1584.19 1554.8,1580.49C1555.48,1576.79 1556.55,1570.74 1557.19,1567.04C1557.83,1563.35 1558.75,1558.05 1559.24,1555.28C1559.73,1552.51 1560.71,1546.71 1561.42,1542.39C1562.13,1538.08 1563.33,1531.02 1564.08,1526.71L1565.44,1518.86L1624.28,1518.27L1623.71,1794.5L1582.25,1794.5L1581.96,1707.72C1581.79,1655.56 1581.26,1620.51 1580.62,1619.87C1579.47,1618.72 1579.23,1619.62 1577.2,1632.59C1576.49,1637.21 1575.47,1643.26 1574.96,1646.04C1574.44,1648.81 1573.45,1654.36 1572.76,1658.36C1572.07,1662.37 1571.05,1668.17 1570.49,1671.25C1569.55,1676.39 1568.61,1681.76 1565.95,1697.02C1565.42,1700.1 1564.43,1705.9 1563.76,1709.9C1563.09,1713.91 1562.08,1719.71 1561.52,1722.79C1560.96,1725.87 1559.93,1731.67 1559.23,1735.67C1558.05,1742.46 1557.33,1746.58 1554.8,1760.89C1554.25,1763.97 1553.3,1769.26 1552.68,1772.65C1552.07,1776.04 1550.92,1782.47 1550.13,1786.94L1548.71,1795.06L1538.37,1795.06C1532.69,1795.06 1527.78,1794.65 1527.47,1794.14C1527.15,1793.63 1526.32,1789.98 1525.62,1786.02C1524.92,1782.06 1523.88,1776.55 1523.32,1773.77C1522.76,1771 1521.78,1765.96 1521.14,1762.57C1520.5,1759.18 1519.52,1754.13 1518.97,1751.36C1516.62,1739.6 1516.22,1737.55 1512.22,1716.63C1509.18,1700.73 1507.74,1693.38 1506.6,1688.06C1506.08,1685.59 1505.08,1680.3 1504.38,1676.29C1503.68,1672.28 1502.67,1666.99 1502.13,1664.52C1501.6,1662.06 1500.59,1656.76 1499.88,1652.76C1498.17,1643.1 1496.57,1635.17 1495.32,1630.22C1494.75,1627.99 1494.29,1624.84 1494.29,1623.22C1494.29,1621.59 1493.79,1620.27 1493.18,1620.27C1492.45,1620.27 1491.96,1650.6 1491.78,1707.38L1491.49,1794.51L1472.93,1794.81C1462.73,1794.98 1454.03,1794.77 1453.61,1794.35L1453.61,1794.34ZM1690.03,1794.34C1689.6,1793.92 1689.26,1770.18 1689.26,1741.59L1689.26,1689.6L1684.69,1674.34C1682.18,1665.94 1679.47,1657.03 1678.68,1654.52C1677.88,1652.02 1676.12,1646.18 1674.76,1641.56C1673.4,1636.94 1671.89,1631.9 1671.39,1630.36C1670.89,1628.82 1669.34,1623.77 1667.95,1619.15C1666.55,1614.53 1664.54,1607.97 1663.48,1604.58C1662.41,1601.19 1660.9,1596.15 1660.12,1593.38C1659.34,1590.61 1657.83,1585.56 1656.76,1582.17C1655.69,1578.79 1654.18,1573.74 1653.4,1570.97C1652.62,1568.2 1651.1,1563.15 1650.03,1559.77C1648.95,1556.38 1646.96,1549.82 1645.59,1545.2C1641.52,1531.37 1640.81,1529.05 1639.89,1526.71C1639.4,1525.48 1638.71,1523.08 1638.34,1521.39L1637.67,1518.31L1685.85,1518.31L1686.53,1521.39C1686.9,1523.08 1687.47,1525.23 1687.8,1526.15C1688.49,1528.09 1690.1,1533.96 1691.5,1539.6C1692.03,1541.75 1693.04,1545.53 1693.74,1548C1694.44,1550.47 1695.44,1554.25 1695.98,1556.4C1696.51,1558.56 1697.52,1562.34 1698.22,1564.81C1698.92,1567.27 1699.93,1571.05 1700.46,1573.21C1701,1575.37 1701.93,1578.9 1702.55,1581.05C1703.88,1585.71 1707.7,1600.01 1710.34,1610.19C1713.6,1622.79 1715.04,1623.28 1717.65,1612.71C1718.68,1608.55 1720.57,1601.36 1721.85,1596.74C1723.13,1592.12 1725.14,1584.68 1726.32,1580.21C1728.41,1572.33 1730.47,1564.61 1735.27,1546.6C1736.55,1541.82 1738.03,1536.4 1738.56,1534.55C1739.09,1532.7 1739.86,1529.93 1740.27,1528.39C1740.68,1526.85 1741.51,1523.95 1742.11,1521.95L1743.21,1518.31L1787,1518.31L1786.23,1520.83C1785.81,1522.21 1785.04,1524.86 1784.51,1526.71C1783.99,1528.56 1782.47,1533.6 1781.14,1537.91C1779.8,1542.23 1778.29,1547.27 1777.78,1549.12C1777.26,1550.97 1775.75,1556.01 1774.41,1560.33C1773.08,1564.64 1771.57,1569.68 1771.05,1571.53C1770.54,1573.38 1769.02,1578.42 1767.69,1582.74C1766.36,1587.05 1764.86,1592.09 1764.36,1593.94C1763.86,1595.79 1757.47,1616.97 1750.16,1641L1736.88,1684.7L1735.76,1794.51L1713.28,1794.81C1700.91,1794.98 1690.45,1794.77 1690.03,1794.34L1690.03,1794.34Z" style="fill:white"/></svg>',t.inter={},t.inter.updateLogo=n;var i=e.prototype.calculateLogoPosition;e.prototype.calculateLogoPosition=function(e){if(!t.useInterLogo)return i.apply(t,[e]);switch(e){case"top_left":return"translate(-15,50) scale(0.25)";case"top_right":return"translate(600,50) scale(0.25)";case"bottom_left":return"translate(-15,470) scale(0.25)";case"bottom_right":return"translate(600,470) scale(0.25)";default:return"translate(200,250) scale(0.5)"}}},r=function(t){return{initEditor:function(t){i(t)},initViewer:function(t){i(t)},onLoadModel:function(t,e){void 0!==e.useInterLogo&&!0===e.useInterLogo&&(t.useInterLogo=!0,n(t))}}};e.prototype.plugins.push(r),e.prototype.viewerPlugins.push(r)}(jQuery,YCEditor);