/** 
 * Kendo UI v2016.3.1118 (http://www.telerik.com/kendo-ui)                                                                                                                                              
 * Copyright 2016 Telerik AD. All rights reserved.                                                                                                                                                      
 *                                                                                                                                                                                                      
 * Kendo UI commercial licenses may be obtained at                                                                                                                                                      
 * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete                                                                                                                                  
 * If you do not own a commercial license, this file shall be governed by the trial license terms.                                                                                                      
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       
                                                                                                                                                                                                       

*/
!function(t,define){define("kendo.core.min",["jquery"],t)}(function(){return function(t,e,i){function n(){}function o(t,e){if(e)return"'"+t.split("'").join("\\'").split('\\"').join('\\\\\\"').replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\t/g,"\\t")+"'";var i=t.charAt(0),n=t.substring(1);return"="===i?"+("+n+")+":":"===i?"+$kendoHtmlEncode("+n+")+":";"+t+";$kendoOutput+="}function r(t,e,i){return t+="",e=e||2,i=e-t.length,i?U[e].substring(0,i)+t:t}function s(t){var e=t.css(vt.support.transitions.css+"box-shadow")||t.css("box-shadow"),i=e?e.match(Pt)||[0,0,0,0,0]:[0,0,0,0,0],n=kt.max(+i[3],+(i[4]||0));return{left:-i[1]+n,right:+i[1]+n,bottom:+i[2]+n}}function a(e,i){var n,o,r,s,a,l,c,h=St.browser,u=vt._outerWidth,d=vt._outerHeight;return e.parent().hasClass("k-animation-container")?(l=e.parent(".k-animation-container"),c=l[0].style,l.is(":hidden")&&l.show(),n=Tt.test(c.width)||Tt.test(c.height),n||l.css({width:u(e),height:d(e),boxSizing:"content-box",mozBoxSizing:"content-box",webkitBoxSizing:"content-box"})):(o=e[0].style.width,r=e[0].style.height,s=Tt.test(o),a=Tt.test(r),n=s||a,!s&&(!i||i&&o)&&(o=u(e)),!a&&(!i||i&&r)&&(r=d(e)),e.wrap(t("<div/>").addClass("k-animation-container").css({width:o,height:r})),n&&e.css({width:"100%",height:"100%",boxSizing:"border-box",mozBoxSizing:"border-box",webkitBoxSizing:"border-box"})),h.msie&&kt.floor(h.version)<=7&&(e.css({zoom:1}),e.children(".k-menu").width(e.width())),e.parent()}function l(t){var e=1,i=arguments.length;for(e=1;e<i;e++)c(t,arguments[e]);return t}function c(t,e){var i,n,o,r,s,a=vt.data.ObservableArray,l=vt.data.LazyObservableArray,h=vt.data.DataSource,u=vt.data.HierarchicalDataSource;for(i in e)n=e[i],o=typeof n,r=o===Bt&&null!==n?n.constructor:null,r&&r!==Array&&r!==a&&r!==l&&r!==h&&r!==u?n instanceof Date?t[i]=new Date(n.getTime()):I(n.clone)?t[i]=n.clone():(s=t[i],t[i]=typeof s===Bt?s||{}:{},c(t[i],n)):o!==Rt&&(t[i]=n);return t}function h(t,e,n){for(var o in e)if(e.hasOwnProperty(o)&&e[o].test(t))return o;return n!==i?n:t}function u(t){return t.replace(/([a-z][A-Z])/g,function(t){return t.charAt(0)+"-"+t.charAt(1).toLowerCase()})}function d(t){return t.replace(/\-(\w)/g,function(t,e){return e.toUpperCase()})}function f(e,i){var n,o={};return document.defaultView&&document.defaultView.getComputedStyle?(n=document.defaultView.getComputedStyle(e,""),i&&t.each(i,function(t,e){o[e]=n.getPropertyValue(e)})):(n=e.currentStyle,i&&t.each(i,function(t,e){o[e]=n[d(e)]})),vt.size(o)||(o=n),o}function p(t){if(t&&t.className&&"string"==typeof t.className&&t.className.indexOf("k-auto-scrollable")>-1)return!0;var e=f(t,["overflow"]).overflow;return"auto"==e||"scroll"==e}function g(e,n){var o,r=St.browser.webkit,s=St.browser.mozilla,a=e instanceof t?e[0]:e;if(e)return o=St.isRtl(e),n===i?o&&r?a.scrollWidth-a.clientWidth-a.scrollLeft:Math.abs(a.scrollLeft):(a.scrollLeft=o&&r?a.scrollWidth-a.clientWidth-n:o&&s?-n:n,i)}function m(t){var e,i=0;for(e in t)t.hasOwnProperty(e)&&"toJSON"!=e&&i++;return i}function v(t,i,n){var o,r,s;return i||(i="offset"),o=t[i](),r={top:o.top,right:o.right,bottom:o.bottom,left:o.left},St.browser.msie&&(St.pointers||St.msPointers)&&!n&&(s=St.isRtl(t)?1:-1,r.top-=e.pageYOffset+s*document.documentElement.scrollTop,r.left-=e.pageXOffset+s*document.documentElement.scrollLeft),r}function _(t){var e={};return yt("string"==typeof t?t.split(" "):t,function(t){e[t]=this}),e}function y(t){return new vt.effects.Element(t)}function w(t,e,i,n){return typeof t===Et&&(I(e)&&(n=e,e=400,i=!1),I(i)&&(n=i,i=!1),typeof e===Lt&&(i=e,e=400),t={effects:t,duration:e,reverse:i,complete:n}),_t({effects:{},duration:400,reverse:!1,init:bt,teardown:bt,hide:!1},t,{completeCallback:t.complete,complete:bt})}function x(e,i,n,o,r){for(var s,a=0,l=e.length;a<l;a++)s=t(e[a]),s.queue(function(){G.promise(s,w(i,n,o,r))});return e}function b(t,e,i,n){return e&&(e=e.split(" "),yt(e,function(e,i){t.toggleClass(i,n)})),t}function k(t){return(""+t).replace(W,"&amp;").replace(q,"&lt;").replace(X,"&gt;").replace($,"&quot;").replace(Y,"&#39;")}function C(t,e){var n;return 0===e.indexOf("data")&&(e=e.substring(4),e=e.charAt(0).toLowerCase()+e.substring(1)),e=e.replace(ot,"-$1"),n=t.getAttribute("data-"+vt.ns+e),null===n?n=i:"null"===n?n=null:"true"===n?n=!0:"false"===n?n=!1:Dt.test(n)?n=parseFloat(n):it.test(n)&&!nt.test(n)&&(n=Function("return ("+n+")")()),n}function S(e,n){var o,r,s={};for(o in n)r=C(e,o),r!==i&&(et.test(o)&&(r=vt.template(t("#"+r).html())),s[o]=r);return s}function T(e,i){return t.contains(e,i)?-1:1}function A(){var e=t(this);return t.inArray(e.attr("data-"+vt.ns+"role"),["slider","rangeslider"])>-1||e.is(":visible")}function P(t,e){var i=t.nodeName.toLowerCase();return(/input|select|textarea|button|object/.test(i)?!t.disabled:"a"===i?t.href||e:e)&&D(t)}function D(e){return t.expr.filters.visible(e)&&!t(e).parents().addBack().filter(function(){return"hidden"===t.css(this,"visibility")}).length}function M(t,e){return new M.fn.init(t,e)}var E,I,B,z,L,R,O,V,F,N,H,U,j,G,W,q,$,Y,X,Q,K,Z,J,tt,et,it,nt,ot,rt,st,at,lt,ct,ht,ut,dt,ft,pt,gt,mt,vt=e.kendo=e.kendo||{cultures:{}},_t=t.extend,yt=t.each,wt=t.isArray,xt=t.proxy,bt=t.noop,kt=Math,Ct=e.JSON||{},St={},Tt=/%/,At=/\{(\d+)(:[^\}]+)?\}/g,Pt=/(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+(?:\.?)\d*)px\s*(\d+)?/i,Dt=/^(\+|-?)\d+(\.?)\d*$/,Mt="function",Et="string",It="number",Bt="object",zt="null",Lt="boolean",Rt="undefined",Ot={},Vt={},Ft=[].slice;vt.version="2016.3.1118".replace(/^\s+|\s+$/g,""),n.extend=function(t){var e,i,n=function(){},o=this,r=t&&t.init?t.init:function(){o.apply(this,arguments)};n.prototype=o.prototype,i=r.fn=r.prototype=new n;for(e in t)i[e]=null!=t[e]&&t[e].constructor===Object?_t(!0,{},n.prototype[e],t[e]):t[e];return i.constructor=r,r.extend=o.extend,r},n.prototype._initOptions=function(t){this.options=l({},this.options,t)},I=vt.isFunction=function(t){return"function"==typeof t},B=function(){this._defaultPrevented=!0},z=function(){return this._defaultPrevented===!0},L=n.extend({init:function(){this._events={}},bind:function(t,e,n){var o,r,s,a,l,c=this,h=typeof t===Et?[t]:t,u=typeof e===Mt;if(e===i){for(o in t)c.bind(o,t[o]);return c}for(o=0,r=h.length;o<r;o++)t=h[o],a=u?e:e[t],a&&(n&&(s=a,a=function(){c.unbind(t,a),s.apply(c,arguments)},a.original=s),l=c._events[t]=c._events[t]||[],l.push(a));return c},one:function(t,e){return this.bind(t,e,!0)},first:function(t,e){var i,n,o,r,s=this,a=typeof t===Et?[t]:t,l=typeof e===Mt;for(i=0,n=a.length;i<n;i++)t=a[i],o=l?e:e[t],o&&(r=s._events[t]=s._events[t]||[],r.unshift(o));return s},trigger:function(t,e){var i,n,o=this,r=o._events[t];if(r){for(e=e||{},e.sender=o,e._defaultPrevented=!1,e.preventDefault=B,e.isDefaultPrevented=z,r=r.slice(),i=0,n=r.length;i<n;i++)r[i].call(o,e);return e._defaultPrevented===!0}return!1},unbind:function(t,e){var n,o=this,r=o._events[t];if(t===i)o._events={};else if(r)if(e)for(n=r.length-1;n>=0;n--)r[n]!==e&&r[n].original!==e||r.splice(n,1);else o._events[t]=[];return o}}),R=/^\w+/,O=/\$\{([^}]*)\}/g,V=/\\\}/g,F=/__CURLY__/g,N=/\\#/g,H=/__SHARP__/g,U=["","0","00","000","0000"],E={paramName:"data",useWithBlock:!0,render:function(t,e){var i,n,o="";for(i=0,n=e.length;i<n;i++)o+=t(e[i]);return o},compile:function(t,e){var i,n,r,s=_t({},this,e),a=s.paramName,l=a.match(R)[0],c=s.useWithBlock,h="var $kendoOutput, $kendoHtmlEncode = kendo.htmlEncode;";if(I(t))return t;for(h+=c?"with("+a+"){":"",h+="$kendoOutput=",n=t.replace(V,"__CURLY__").replace(O,"#=$kendoHtmlEncode($1)#").replace(F,"}").replace(N,"__SHARP__").split("#"),r=0;r<n.length;r++)h+=o(n[r],r%2===0);h+=c?";}":";",h+="return $kendoOutput;",h=h.replace(H,"#");try{return i=Function(l,h),i._slotCount=Math.floor(n.length/2),i}catch(u){throw Error(vt.format("Invalid template:'{0}' Generated code:'{1}'",t,h))}}},function(){function t(t){return s.lastIndex=0,s.test(t)?'"'+t.replace(s,function(t){var e=a[t];return typeof e===Et?e:"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+t+'"'}function e(r,s){var a,c,h,u,d,f,p=i,g=s[r];if(g&&typeof g===Bt&&typeof g.toJSON===Mt&&(g=g.toJSON(r)),typeof o===Mt&&(g=o.call(s,r,g)),f=typeof g,f===Et)return t(g);if(f===It)return isFinite(g)?g+"":zt;if(f===Lt||f===zt)return g+"";if(f===Bt){if(!g)return zt;if(i+=n,d=[],"[object Array]"===l.apply(g)){for(u=g.length,a=0;a<u;a++)d[a]=e(a,g)||zt;return h=0===d.length?"[]":i?"[\n"+i+d.join(",\n"+i)+"\n"+p+"]":"["+d.join(",")+"]",i=p,h}if(o&&typeof o===Bt)for(u=o.length,a=0;a<u;a++)typeof o[a]===Et&&(c=o[a],h=e(c,g),h&&d.push(t(c)+(i?": ":":")+h));else for(c in g)Object.hasOwnProperty.call(g,c)&&(h=e(c,g),h&&d.push(t(c)+(i?": ":":")+h));return h=0===d.length?"{}":i?"{\n"+i+d.join(",\n"+i)+"\n"+p+"}":"{"+d.join(",")+"}",i=p,h}}var i,n,o,s=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,a={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},l={}.toString;typeof Date.prototype.toJSON!==Mt&&(Date.prototype.toJSON=function(){var t=this;return isFinite(t.valueOf())?r(t.getUTCFullYear(),4)+"-"+r(t.getUTCMonth()+1)+"-"+r(t.getUTCDate())+"T"+r(t.getUTCHours())+":"+r(t.getUTCMinutes())+":"+r(t.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(){return this.valueOf()}),typeof Ct.stringify!==Mt&&(Ct.stringify=function(t,r,s){var a;if(i="",n="",typeof s===It)for(a=0;a<s;a+=1)n+=" ";else typeof s===Et&&(n=s);if(o=r,r&&typeof r!==Mt&&(typeof r!==Bt||typeof r.length!==It))throw Error("JSON.stringify");return e("",{"":t})})}(),function(){function e(t){if(t){if(t.numberFormat)return t;if(typeof t===Et){var e=vt.cultures;return e[t]||e[t.split("-")[0]]||null}return null}return null}function n(t){return t&&(t=e(t)),t||vt.cultures.current}function o(t,e,o){o=n(o);var s=o.calendars.standard,a=s.days,l=s.months;return e=s.patterns[e]||e,e.replace(h,function(e){var n,o,c;return"d"===e?o=t.getDate():"dd"===e?o=r(t.getDate()):"ddd"===e?o=a.namesAbbr[t.getDay()]:"dddd"===e?o=a.names[t.getDay()]:"M"===e?o=t.getMonth()+1:"MM"===e?o=r(t.getMonth()+1):"MMM"===e?o=l.namesAbbr[t.getMonth()]:"MMMM"===e?o=l.names[t.getMonth()]:"yy"===e?o=r(t.getFullYear()%100):"yyyy"===e?o=r(t.getFullYear(),4):"h"===e?o=t.getHours()%12||12:"hh"===e?o=r(t.getHours()%12||12):"H"===e?o=t.getHours():"HH"===e?o=r(t.getHours()):"m"===e?o=t.getMinutes():"mm"===e?o=r(t.getMinutes()):"s"===e?o=t.getSeconds():"ss"===e?o=r(t.getSeconds()):"f"===e?o=kt.floor(t.getMilliseconds()/100):"ff"===e?(o=t.getMilliseconds(),o>99&&(o=kt.floor(o/10)),o=r(o)):"fff"===e?o=r(t.getMilliseconds(),3):"tt"===e?o=t.getHours()<12?s.AM[0]:s.PM[0]:"zzz"===e?(n=t.getTimezoneOffset(),c=n<0,o=(""+kt.abs(n/60)).split(".")[0],n=kt.abs(n)-60*o,o=(c?"+":"-")+r(o),o+=":"+r(n)):"zz"!==e&&"z"!==e||(o=t.getTimezoneOffset()/60,c=o<0,o=(""+kt.abs(o)).split(".")[0],o=(c?"+":"-")+("zz"===e?r(o):o)),o!==i?o:e.slice(1,e.length-1)})}function s(t,e,o){o=n(o);var r,s,c,h,w,x,b,k,C,S,T,A,P,D,M,E,I,B,z,L,R,O,V,F=o.numberFormat,N=F[g],H=F.decimals,U=F.pattern[0],j=[],G=t<0,W=p,q=p,$=-1;if(t===i)return p;if(!isFinite(t))return t;if(!e)return o.name.length?t.toLocaleString():""+t;if(w=u.exec(e)){if(e=w[1].toLowerCase(),s="c"===e,c="p"===e,(s||c)&&(F=s?F.currency:F.percent,N=F[g],H=F.decimals,r=F.symbol,U=F.pattern[G?0:1]),h=w[2],h&&(H=+h),"e"===e)return h?t.toExponential(H):t.toExponential();if(c&&(t*=100),t=l(t,H),G=t<0,t=t.split(g),x=t[0],b=t[1],G&&(x=x.substring(1)),q=a(x,0,x.length,F),b&&(q+=N+b),"n"===e&&!G)return q;for(t=p,S=0,T=U.length;S<T;S++)A=U.charAt(S),t+="n"===A?q:"$"===A||"%"===A?r:A;return t}if(G&&(t=-t),(e.indexOf("'")>-1||e.indexOf('"')>-1||e.indexOf("\\")>-1)&&(e=e.replace(d,function(t){var e=t.charAt(0).replace("\\",""),i=t.slice(1).replace(e,"");return j.push(i),y})),e=e.split(";"),G&&e[1])e=e[1],D=!0;else if(0===t){if(e=e[2]||e[0],e.indexOf(v)==-1&&e.indexOf(_)==-1)return e}else e=e[0];if(L=e.indexOf("%"),R=e.indexOf("$"),c=L!=-1,s=R!=-1,c&&(t*=100),s&&"\\"===e[R-1]&&(e=e.split("\\").join(""),s=!1),(s||c)&&(F=s?F.currency:F.percent,N=F[g],H=F.decimals,r=F.symbol),P=e.indexOf(m)>-1,P&&(e=e.replace(f,p)),M=e.indexOf(g),T=e.length,M!=-1?(b=(""+t).split("e"),b=b[1]?l(t,Math.abs(b[1])):b[0],b=b.split(g)[1]||p,I=e.lastIndexOf(_)-M,E=e.lastIndexOf(v)-M,B=I>-1,z=E>-1,S=b.length,B||z||(e=e.substring(0,M)+e.substring(M+1),T=e.length,M=-1,S=0),B&&I>E?S=I:E>I&&(z&&S>E?S=E:B&&S<I&&(S=I)),S>-1&&(t=l(t,S))):t=l(t),E=e.indexOf(v),O=I=e.indexOf(_),$=E==-1&&I!=-1?I:E!=-1&&I==-1?E:E>I?I:E,E=e.lastIndexOf(v),I=e.lastIndexOf(_),V=E==-1&&I!=-1?I:E!=-1&&I==-1?E:E>I?E:I,$==T&&(V=$),$!=-1){for(q=(""+t).split(g),x=q[0],b=q[1]||p,k=x.length,C=b.length,G&&t*-1>=0&&(G=!1),t=e.substring(0,$),G&&!D&&(t+="-"),S=$;S<T;S++){if(A=e.charAt(S),M==-1){if(V-S<k){t+=x;break}}else if(I!=-1&&I<S&&(W=p),M-S<=k&&M-S>-1&&(t+=x,S=M),M===S){t+=(b?N:p)+b,S+=V-M+1;continue}A===_?(t+=A,W=A):A===v&&(t+=W)}if(P&&(t=a(t,$+(G?1:0),Math.max(V,k+$),F)),V>=$&&(t+=e.substring(V+1)),s||c){for(q=p,S=0,T=t.length;S<T;S++)A=t.charAt(S),q+="$"===A||"%"===A?r:A;t=q}if(T=j.length)for(S=0;S<T;S++)t=t.replace(y,j[S])}return t}var a,l,c,h=/dddd|ddd|dd|d|MMMM|MMM|MM|M|yyyy|yy|HH|H|hh|h|mm|m|fff|ff|f|tt|ss|s|zzz|zz|z|"[^"]*"|'[^']*'/g,u=/^(n|c|p|e)(\d*)$/i,d=/(\\.)|(['][^']*[']?)|(["][^"]*["]?)/g,f=/\,/g,p="",g=".",m=",",v="#",_="0",y="??",w="en-US",x={}.toString;vt.cultures["en-US"]={name:w,numberFormat:{pattern:["-n"],decimals:2,",":",",".":".",groupSize:[3],percent:{pattern:["-n %","n %"],decimals:2,",":",",".":".",groupSize:[3],symbol:"%"},currency:{name:"US Dollar",abbr:"USD",pattern:["($n)","$n"],decimals:2,",":",",".":".",groupSize:[3],symbol:"$"}},calendars:{standard:{days:{names:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],namesAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],namesShort:["Su","Mo","Tu","We","Th","Fr","Sa"]},months:{names:["January","February","March","April","May","June","July","August","September","October","November","December"],namesAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]},AM:["AM","am","AM"],PM:["PM","pm","PM"],patterns:{d:"M/d/yyyy",D:"dddd, MMMM dd, yyyy",F:"dddd, MMMM dd, yyyy h:mm:ss tt",g:"M/d/yyyy h:mm tt",G:"M/d/yyyy h:mm:ss tt",m:"MMMM dd",M:"MMMM dd",s:"yyyy'-'MM'-'ddTHH':'mm':'ss",t:"h:mm tt",T:"h:mm:ss tt",u:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",y:"MMMM, yyyy",Y:"MMMM, yyyy"},"/":"/",":":":",firstDay:0,twoDigitYearMax:2029}}},vt.culture=function(t){var n,o=vt.cultures;return t===i?o.current:(n=e(t)||o[w],n.calendar=n.calendars.standard,o.current=n,i)},vt.findCulture=e,vt.getCulture=n,vt.culture(w),a=function(t,e,n,o){var r,s,a,l,c,h,u=t.indexOf(o[g]),d=o.groupSize.slice(),f=d.shift();if(n=u!==-1?u:n+1,r=t.substring(e,n),s=r.length,s>=f){for(a=s,l=[];a>-1;)if(c=r.substring(a-f,a),c&&l.push(c),a-=f,h=d.shift(),f=h!==i?h:f,0===f){l.push(r.substring(0,a));break}r=l.reverse().join(o[m]),t=t.substring(0,e)+r+t.substring(n)}return t},l=function(t,e){return e=e||0,t=(""+t).split("e"),t=Math.round(+(t[0]+"e"+(t[1]?+t[1]+e:e))),t=(""+t).split("e"),t=+(t[0]+"e"+(t[1]?+t[1]-e:-e)),t.toFixed(Math.min(e,20))},c=function(t,e,n){if(e){if("[object Date]"===x.call(t))return o(t,e,n);if(typeof t===It)return s(t,e,n)}return t!==i?t:""},vt.format=function(t){var e=arguments;return t.replace(At,function(t,i,n){var o=e[parseInt(i,10)+1];return c(o,n?n.substring(1):"")})},vt._extractFormat=function(t){return"{0:"===t.slice(0,3)&&(t=t.slice(3,t.length-1)),t},vt._activeElement=function(){try{return document.activeElement}catch(t){return document.documentElement.activeElement}},vt._round=l,vt._outerWidth=function(e,i){return t(e).outerWidth(i||!1)||0},vt._outerHeight=function(e,i){return t(e).outerHeight(i||!1)||0},vt.toString=c}(),function(){function e(t,e,i){return!(t>=e&&t<=i)}function n(t){return t.charAt(0)}function o(e){return t.map(e,n)}function r(t,e){e||23!==t.getHours()||t.setHours(t.getHours()+2)}function s(t){for(var e=0,i=t.length,n=[];e<i;e++)n[e]=(t[e]+"").toLowerCase();return n}function a(t){var e,i={};for(e in t)i[e]=s(t[e]);return i}function l(t,n,s){if(!t)return null;var l,c,h,u,d,g,m,v,_,w,x,b,k,C=function(t){for(var e=0;n[R]===t;)e++,R++;return e>0&&(R-=1),e},S=function(e){var i=y[e]||RegExp("^\\d{1,"+e+"}"),n=t.substr(O,e).match(i);return n?(n=n[0],O+=n.length,parseInt(n,10)):null},T=function(e,i){for(var n,o,r,s=0,a=e.length,l=0,c=0;s<a;s++)n=e[s],o=n.length,r=t.substr(O,o),i&&(r=r.toLowerCase()),r==n&&o>l&&(l=o,c=s);return l?(O+=l,c+1):null},A=function(){var e=!1;return t.charAt(O)===n[R]&&(O++,e=!0),e},P=s.calendars.standard,D=null,M=null,E=null,I=null,B=null,z=null,L=null,R=0,O=0,V=!1,F=new Date,N=P.twoDigitYearMax||2029,H=F.getFullYear();for(n||(n="d"),u=P.patterns[n],u&&(n=u),n=n.split(""),h=n.length;R<h;R++)if(l=n[R],V)"'"===l?V=!1:A();else if("d"===l){if(c=C("d"),P._lowerDays||(P._lowerDays=a(P.days)),null!==E&&c>2)continue;if(E=c<3?S(2):T(P._lowerDays[3==c?"namesAbbr":"names"],!0),null===E||e(E,1,31))return null}else if("M"===l){if(c=C("M"),P._lowerMonths||(P._lowerMonths=a(P.months)),M=c<3?S(2):T(P._lowerMonths[3==c?"namesAbbr":"names"],!0),null===M||e(M,1,12))return null;M-=1}else if("y"===l){if(c=C("y"),D=S(c),null===D)return null;2==c&&("string"==typeof N&&(N=H+parseInt(N,10)),D=H-H%100+D,D>N&&(D-=100))}else if("h"===l){if(C("h"),I=S(2),12==I&&(I=0),null===I||e(I,0,11))return null}else if("H"===l){if(C("H"),I=S(2),null===I||e(I,0,23))return null}else if("m"===l){if(C("m"),B=S(2),null===B||e(B,0,59))return null}else if("s"===l){if(C("s"),z=S(2),null===z||e(z,0,59))return null}else if("f"===l){if(c=C("f"),k=t.substr(O,c).match(y[3]),L=S(c),null!==L&&(L=parseFloat("0."+k[0],10),L=vt._round(L,3),L*=1e3),null===L||e(L,0,999))return null}else if("t"===l){if(c=C("t"),v=P.AM,_=P.PM,1===c&&(v=o(v),_=o(_)),d=T(_),!d&&!T(v))return null}else if("z"===l){if(g=!0,c=C("z"),"Z"===t.substr(O,1)){A();continue}if(m=t.substr(O,6).match(c>2?p:f),!m)return null;if(m=m[0].split(":"),w=m[0],x=m[1],!x&&w.length>3&&(O=w.length-2,x=w.substring(O),w=w.substring(0,O)),w=parseInt(w,10),e(w,-12,13))return null;if(c>2&&(x=parseInt(x,10),isNaN(x)||e(x,0,59)))return null}else if("'"===l)V=!0,A();else if(!A())return null;return b=null!==I||null!==B||z||null,null===D&&null===M&&null===E&&b?(D=H,M=F.getMonth(),E=F.getDate()):(null===D&&(D=H),null===E&&(E=1)),d&&I<12&&(I+=12),g?(w&&(I+=-w),x&&(B+=-x),t=new Date(Date.UTC(D,M,E,I,B,z,L))):(t=new Date(D,M,E,I,B,z,L),r(t,I)),D<100&&t.setFullYear(D),t.getDate()!==E&&g===i?null:t}function c(t){var e="-"===t.substr(0,1)?-1:1;return t=t.substring(1),t=60*parseInt(t.substr(0,2),10)+parseInt(t.substring(2),10),e*t}function h(t){var e,i,n,o=kt.max(v.length,_.length),r=t.calendar.patterns,s=[];for(n=0;n<o;n++){for(e=v[n],i=0;i<e.length;i++)s.push(r[e[i]]);s=s.concat(_[n])}return s}var u=/\u00A0/g,d=/[eE][\-+]?[0-9]+/,f=/[+|\-]\d{1,2}/,p=/[+|\-]\d{1,2}:?\d{2}/,g=/^\/Date\((.*?)\)\/$/,m=/[+-]\d*/,v=[[],["G","g","F"],["D","d","y","m","T","t"]],_=[["yyyy-MM-ddTHH:mm:ss.fffffffzzz","yyyy-MM-ddTHH:mm:ss.fffffff","yyyy-MM-ddTHH:mm:ss.fffzzz","yyyy-MM-ddTHH:mm:ss.fff","ddd MMM dd yyyy HH:mm:ss","yyyy-MM-ddTHH:mm:sszzz","yyyy-MM-ddTHH:mmzzz","yyyy-MM-ddTHH:mmzz","yyyy-MM-ddTHH:mm:ss","yyyy-MM-dd HH:mm:ss","yyyy/MM/dd HH:mm:ss"],["yyyy-MM-ddTHH:mm","yyyy-MM-dd HH:mm","yyyy/MM/dd HH:mm"],["yyyy/MM/dd","yyyy-MM-dd","HH:mm:ss","HH:mm"]],y={2:/^\d{1,2}/,3:/^\d{1,3}/,4:/^\d{4}/},w={}.toString;vt.parseDate=function(t,e,i){var n,o,r,s;if("[object Date]"===w.call(t))return t;if(n=0,o=null,t&&0===t.indexOf("/D")&&(o=g.exec(t)))return o=o[1],s=m.exec(o.substring(1)),o=new Date(parseInt(o,10)),s&&(s=c(s[0]),o=vt.timezone.apply(o,0),o=vt.timezone.convert(o,0,-1*s)),o;for(i=vt.getCulture(i),e||(e=h(i)),e=wt(e)?e:[e],r=e.length;n<r;n++)if(o=l(t,e[n],i))return o;return o},vt.parseInt=function(t,e){var i=vt.parseFloat(t,e);return i&&(i=0|i),i},vt.parseFloat=function(t,e,i){if(!t&&0!==t)return null;if(typeof t===It)return t;t=""+t,e=vt.getCulture(e);var n,o,r=e.numberFormat,s=r.percent,a=r.currency,l=a.symbol,c=s.symbol,h=t.indexOf("-");return d.test(t)?(t=parseFloat(t.replace(r["."],".")),isNaN(t)&&(t=null),t):h>0?null:(h=h>-1,t.indexOf(l)>-1||i&&i.toLowerCase().indexOf("c")>-1?(r=a,n=r.pattern[0].replace("$",l).split("n"),t.indexOf(n[0])>-1&&t.indexOf(n[1])>-1&&(t=t.replace(n[0],"").replace(n[1],""),h=!0)):t.indexOf(c)>-1&&(o=!0,r=s,l=c),t=t.replace("-","").replace(l,"").replace(u," ").split(r[","].replace(u," ")).join("").replace(r["."],"."),t=parseFloat(t),isNaN(t)?t=null:h&&(t*=-1),t&&o&&(t/=100),t)}}(),function(){var n,o,r,s,a,l,c;St._scrollbar=i,St.scrollbar=function(t){if(isNaN(St._scrollbar)||t){var e,i=document.createElement("div");return i.style.cssText="overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block",i.innerHTML="&nbsp;",document.body.appendChild(i),St._scrollbar=e=i.offsetWidth-i.scrollWidth,document.body.removeChild(i),e}return St._scrollbar},St.isRtl=function(e){return t(e).closest(".k-rtl").length>0},n=document.createElement("table");try{n.innerHTML="<tr><td></td></tr>",St.tbodyInnerHtml=!0}catch(u){St.tbodyInnerHtml=!1}St.touch="ontouchstart"in e,St.msPointers=e.MSPointerEvent,St.pointers=e.PointerEvent,o=St.transitions=!1,r=St.transforms=!1,s="HTMLElement"in e?HTMLElement.prototype:[],St.hasHW3D="WebKitCSSMatrix"in e&&"m11"in new e.WebKitCSSMatrix||"MozPerspective"in document.documentElement.style||"msPerspective"in document.documentElement.style,yt(["Moz","webkit","O","ms"],function(){var t,e=""+this,i=typeof n.style[e+"Transition"]===Et;if(i||typeof n.style[e+"Transform"]===Et)return t=e.toLowerCase(),r={css:"ms"!=t?"-"+t+"-":"",prefix:e,event:"o"===t||"webkit"===t?t:""},i&&(o=r,o.event=o.event?o.event+"TransitionEnd":"transitionend"),!1}),n=null,St.transforms=r,St.transitions=o,St.devicePixelRatio=e.devicePixelRatio===i?1:e.devicePixelRatio;try{St.screenWidth=e.outerWidth||e.screen?e.screen.availWidth:e.innerWidth,St.screenHeight=e.outerHeight||e.screen?e.screen.availHeight:e.innerHeight}catch(u){St.screenWidth=e.screen.availWidth,St.screenHeight=e.screen.availHeight}St.detectOS=function(t){var i,n,o=!1,r=[],s=!/mobile safari/i.test(t),a={wp:/(Windows Phone(?: OS)?)\s(\d+)\.(\d+(\.\d+)?)/,fire:/(Silk)\/(\d+)\.(\d+(\.\d+)?)/,android:/(Android|Android.*(?:Opera|Firefox).*?\/)\s*(\d+)\.(\d+(\.\d+)?)/,iphone:/(iPhone|iPod).*OS\s+(\d+)[\._]([\d\._]+)/,ipad:/(iPad).*OS\s+(\d+)[\._]([\d_]+)/,meego:/(MeeGo).+NokiaBrowser\/(\d+)\.([\d\._]+)/,webos:/(webOS)\/(\d+)\.(\d+(\.\d+)?)/,blackberry:/(BlackBerry|BB10).*?Version\/(\d+)\.(\d+(\.\d+)?)/,playbook:/(PlayBook).*?Tablet\s*OS\s*(\d+)\.(\d+(\.\d+)?)/,windows:/(MSIE)\s+(\d+)\.(\d+(\.\d+)?)/,tizen:/(tizen).*?Version\/(\d+)\.(\d+(\.\d+)?)/i,sailfish:/(sailfish).*rv:(\d+)\.(\d+(\.\d+)?).*firefox/i,ffos:/(Mobile).*rv:(\d+)\.(\d+(\.\d+)?).*Firefox/},l={ios:/^i(phone|pad|pod)$/i,android:/^android|fire$/i,blackberry:/^blackberry|playbook/i,windows:/windows/,wp:/wp/,flat:/sailfish|ffos|tizen/i,meego:/meego/},c={tablet:/playbook|ipad|fire/i},u={omini:/Opera\sMini/i,omobile:/Opera\sMobi/i,firefox:/Firefox|Fennec/i,mobilesafari:/version\/.*safari/i,ie:/MSIE|Windows\sPhone/i,chrome:/chrome|crios/i,webkit:/webkit/i};for(n in a)if(a.hasOwnProperty(n)&&(r=t.match(a[n]))){if("windows"==n&&"plugins"in navigator)return!1;o={},o.device=n,o.tablet=h(n,c,!1),o.browser=h(t,u,"default"),o.name=h(n,l),o[o.name]=!0,o.majorVersion=r[2],o.minorVersion=r[3].replace("_","."),i=o.minorVersion.replace(".","").substr(0,2),o.flatVersion=o.majorVersion+i+Array(3-(i.length<3?i.length:2)).join("0"),o.cordova=typeof e.PhoneGap!==Rt||typeof e.cordova!==Rt,o.appMode=e.navigator.standalone||/file|local|wmapp/.test(e.location.protocol)||o.cordova,o.android&&(St.devicePixelRatio<1.5&&o.flatVersion<400||s)&&(St.screenWidth>800||St.screenHeight>800)&&(o.tablet=n);break}return o},a=St.mobileOS=St.detectOS(navigator.userAgent),St.wpDevicePixelRatio=a.wp?screen.width/320:0,St.kineticScrollNeeded=a&&(St.touch||St.msPointers||St.pointers),St.hasNativeScrolling=!1,(a.ios||a.android&&a.majorVersion>2||a.wp)&&(St.hasNativeScrolling=a),St.delayedClick=function(){if(St.touch){if(a.ios)return!0;if(a.android)return!St.browser.chrome||!(St.browser.version<32)&&!(t("meta[name=viewport]").attr("content")||"").match(/user-scalable=no/i)}return!1},St.mouseAndTouchPresent=St.touch&&!(St.mobileOS.ios||St.mobileOS.android),St.detectBrowser=function(t){var e,i=!1,n=[],o={edge:/(edge)[ \/]([\w.]+)/i,webkit:/(chrome)[ \/]([\w.]+)/i,safari:/(webkit)[ \/]([\w.]+)/i,opera:/(opera)(?:.*version|)[ \/]([\w.]+)/i,msie:/(msie\s|trident.*? rv:)([\w.]+)/i,mozilla:/(mozilla)(?:.*? rv:([\w.]+)|)/i};for(e in o)if(o.hasOwnProperty(e)&&(n=t.match(o[e]))){i={},i[e]=!0,i[n[1].toLowerCase().split(" ")[0].split("/")[0]]=!0,i.version=parseInt(document.documentMode||n[2],10);break}return i},St.browser=St.detectBrowser(navigator.userAgent),St.detectClipboardAccess=function(){var t={copy:!!document.queryCommandSupported&&document.queryCommandSupported("copy"),cut:!!document.queryCommandSupported&&document.queryCommandSupported("cut"),paste:!!document.queryCommandSupported&&document.queryCommandSupported("paste")};return St.browser.chrome&&(t.paste=!1,St.browser.version>=43&&(t.copy=!0,t.cut=!0)),t},St.clipboard=St.detectClipboardAccess(),St.zoomLevel=function(){var t,i,n;try{return t=St.browser,i=0,n=document.documentElement,t.msie&&11==t.version&&n.scrollHeight>n.clientHeight&&!St.touch&&(i=St.scrollbar()),St.touch?n.clientWidth/e.innerWidth:t.msie&&t.version>=10?((top||e).document.documentElement.offsetWidth+i)/(top||e).innerWidth:1}catch(o){return 1}},St.cssBorderSpacing=i!==document.documentElement.style.borderSpacing&&!(St.browser.msie&&St.browser.version<8),function(e){var i="",n=t(document.documentElement),o=parseInt(e.version,10);e.msie?i="ie":e.mozilla?i="ff":e.safari?i="safari":e.webkit?i="webkit":e.opera?i="opera":e.edge&&(i="edge"),i&&(i="k-"+i+" k-"+i+o),St.mobileOS&&(i+=" k-mobile"),n.addClass(i)}(St.browser),St.eventCapture=document.documentElement.addEventListener,l=document.createElement("input"),St.placeholder="placeholder"in l,St.propertyChangeEvent="onpropertychange"in l,St.input=function(){for(var t,e=["number","date","time","month","week","datetime","datetime-local"],i=e.length,n="test",o={},r=0;r<i;r++)t=e[r],l.setAttribute("type",t),l.value=n,o[t.replace("-","")]="text"!==l.type&&l.value!==n;return o}(),l.style.cssText="float:left;",St.cssFloat=!!l.style.cssFloat,l=null,St.stableSort=function(){var t,e=513,i=[{index:0,field:"b"}];for(t=1;t<e;t++)i.push({index:t,field:"a"});return i.sort(function(t,e){return t.field>e.field?1:t.field<e.field?-1:0}),1===i[0].index}(),St.matchesSelector=s.webkitMatchesSelector||s.mozMatchesSelector||s.msMatchesSelector||s.oMatchesSelector||s.matchesSelector||s.matches||function(e){for(var i=document.querySelectorAll?(this.parentNode||document).querySelectorAll(e)||[]:t(e),n=i.length;n--;)if(i[n]==this)return!0;return!1},St.pushState=e.history&&e.history.pushState,c=document.documentMode,St.hashChange="onhashchange"in e&&!(St.browser.msie&&(!c||c<=8)),St.customElements="registerElement"in e.document}(),j={left:{reverse:"right"},right:{reverse:"left"},down:{reverse:"up"},up:{reverse:"down"},top:{reverse:"bottom"},bottom:{reverse:"top"},"in":{reverse:"out"},out:{reverse:"in"}},G={},t.extend(G,{enabled:!0,Element:function(e){this.element=t(e)},promise:function(t,e){t.is(":visible")||t.css({display:t.data("olddisplay")||"block"}).css("display"),e.hide&&t.data("olddisplay",t.css("display")).hide(),e.init&&e.init(),e.completeCallback&&e.completeCallback(t),t.dequeue()},disable:function(){this.enabled=!1,this.promise=this.promiseShim},enable:function(){this.enabled=!0,this.promise=this.animatedPromise}}),G.promiseShim=G.promise,"kendoAnimate"in t.fn||_t(t.fn,{kendoStop:function(t,e){return this.stop(t,e)},kendoAnimate:function(t,e,i,n){return x(this,t,e,i,n)},kendoAddClass:function(t,e){return vt.toggleClass(this,t,e,!0)},kendoRemoveClass:function(t,e){return vt.toggleClass(this,t,e,!1)},kendoToggleClass:function(t,e,i){return vt.toggleClass(this,t,e,i)}}),W=/&/g,q=/</g,$=/"/g,Y=/'/g,X=/>/g,Q=function(t){return t.target},St.touch&&(Q=function(t){var e="originalEvent"in t?t.originalEvent.changedTouches:"changedTouches"in t?t.changedTouches:null;return e?document.elementFromPoint(e[0].clientX,e[0].clientY):t.target},yt(["swipe","swipeLeft","swipeRight","swipeUp","swipeDown","doubleTap","tap"],function(e,i){t.fn[i]=function(t){return this.bind(i,t)}})),St.touch?St.mobileOS?(St.mousedown="touchstart",St.mouseup="touchend",St.mousemove="touchmove",St.mousecancel="touchcancel",St.click="touchend",St.resize="orientationchange"):(St.mousedown="mousedown touchstart",St.mouseup="mouseup touchend",St.mousemove="mousemove touchmove",St.mousecancel="mouseleave touchcancel",St.click="click",St.resize="resize"):St.pointers?(St.mousemove="pointermove",St.mousedown="pointerdown",St.mouseup="pointerup",St.mousecancel="pointercancel",St.click="pointerup",St.resize="orientationchange resize"):St.msPointers?(St.mousemove="MSPointerMove",St.mousedown="MSPointerDown",St.mouseup="MSPointerUp",St.mousecancel="MSPointerCancel",St.click="MSPointerUp",St.resize="orientationchange resize"):(St.mousemove="mousemove",St.mousedown="mousedown",St.mouseup="mouseup",St.mousecancel="mouseleave",St.click="click",St.resize="resize"),K=function(t,e){var i,n,o,r,s=e||"d",a=1;for(n=0,o=t.length;n<o;n++)r=t[n],""!==r&&(i=r.indexOf("["),0!==i&&(i==-1?r="."+r:(a++,r="."+r.substring(0,i)+" || {})"+r.substring(i))),a++,s+=r+(n<o-1?" || {})":")"));return Array(a).join("(")+s},Z=/^([a-z]+:)?\/\//i,_t(vt,{widgets:[],_widgetRegisteredCallbacks:[],ui:vt.ui||{},fx:vt.fx||y,effects:vt.effects||G,mobile:vt.mobile||{},data:vt.data||{},dataviz:vt.dataviz||{},drawing:vt.drawing||{},spreadsheet:{messages:{}},keys:{INSERT:45,DELETE:46,BACKSPACE:8,TAB:9,ENTER:13,ESC:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,END:35,HOME:36,SPACEBAR:32,PAGEUP:33,PAGEDOWN:34,F2:113,F10:121,F12:123,NUMPAD_PLUS:107,NUMPAD_MINUS:109,NUMPAD_DOT:110},support:vt.support||St,animate:vt.animate||x,ns:"",attr:function(t){return"data-"+vt.ns+t},getShadows:s,wrap:a,deepExtend:l,getComputedStyles:f,webComponents:vt.webComponents||[],isScrollable:p,scrollLeft:g,size:m,toCamelCase:d,toHyphens:u,getOffset:vt.getOffset||v,parseEffects:vt.parseEffects||_,toggleClass:vt.toggleClass||b,directions:vt.directions||j,Observable:L,Class:n,Template:E,template:xt(E.compile,E),render:xt(E.render,E),stringify:xt(Ct.stringify,Ct),eventTarget:Q,htmlEncode:k,isLocalUrl:function(t){return t&&!Z.test(t)},expr:function(t,e,i){return t=t||"",typeof e==Et&&(i=e,e=!1),i=i||"d",t&&"["!==t.charAt(0)&&(t="."+t),e?(t=t.replace(/"([^.]*)\.([^"]*)"/g,'"$1_$DOT$_$2"'),t=t.replace(/'([^.]*)\.([^']*)'/g,"'$1_$DOT$_$2'"),t=K(t.split("."),i),t=t.replace(/_\$DOT\$_/g,".")):t=i+t,t},getter:function(t,e){var i=t+e;return Ot[i]=Ot[i]||Function("d","return "+vt.expr(t,e))},setter:function(t){return Vt[t]=Vt[t]||Function("d,value",vt.expr(t)+"=value")},accessor:function(t){return{get:vt.getter(t),set:vt.setter(t)}},guid:function(){var t,e,i="";for(t=0;t<32;t++)e=16*kt.random()|0,8!=t&&12!=t&&16!=t&&20!=t||(i+="-"),i+=(12==t?4:16==t?3&e|8:e).toString(16);return i},roleSelector:function(t){return t.replace(/(\S+)/g,"["+vt.attr("role")+"=$1],").slice(0,-1)},directiveSelector:function(t){var e,i=t.split(" ");if(i)for(e=0;e<i.length;e++)"view"!=i[e]&&(i[e]=i[e].replace(/(\w*)(view|bar|strip|over)$/,"$1-$2"));return i.join(" ").replace(/(\S+)/g,"kendo-mobile-$1,").slice(0,-1)},triggeredByInput:function(t){return/^(label|input|textarea|select)$/i.test(t.target.tagName)},onWidgetRegistered:function(t){for(var e=0,i=vt.widgets.length;e<i;e++)t(vt.widgets[e]);vt._widgetRegisteredCallbacks.push(t)},logToConsole:function(t,n){var o=e.console;!vt.suppressLog&&i!==o&&o.log&&o[n||"log"](t)}}),J=L.extend({init:function(t,e){var i,n=this;n.element=vt.jQuery(t).handler(n),n.angular("init",e),L.fn.init.call(n),i=e?e.dataSource:null,i&&(e=_t({},e,{dataSource:{}})),e=n.options=_t(!0,{},n.options,e),i&&(e.dataSource=i),
n.element.attr(vt.attr("role"))||n.element.attr(vt.attr("role"),(e.name||"").toLowerCase()),n.element.data("kendo"+e.prefix+e.name,n),n.bind(n.events,e)},events:[],options:{prefix:""},_hasBindingTarget:function(){return!!this.element[0].kendoBindingTarget},_tabindex:function(t){t=t||this.wrapper;var e=this.element,i="tabindex",n=t.attr(i)||e.attr(i);e.removeAttr(i),t.attr(i,isNaN(n)?0:n)},setOptions:function(e){this._setEvents(e),t.extend(this.options,e)},_setEvents:function(t){for(var e,i=this,n=0,o=i.events.length;n<o;n++)e=i.events[n],i.options[e]&&t[e]&&i.unbind(e,i.options[e]);i.bind(i.events,t)},resize:function(t){var e=this.getSize(),i=this._size;(t||(e.width>0||e.height>0)&&(!i||e.width!==i.width||e.height!==i.height))&&(this._size=e,this._resize(e,t),this.trigger("resize",e))},getSize:function(){return vt.dimensions(this.element)},size:function(t){return t?(this.setSize(t),i):this.getSize()},setSize:t.noop,_resize:t.noop,destroy:function(){var t=this;t.element.removeData("kendo"+t.options.prefix+t.options.name),t.element.removeData("handler"),t.unbind()},_destroy:function(){this.destroy()},angular:function(){},_muteAngularRebind:function(t){this._muteRebind=!0,t.call(this),this._muteRebind=!1}}),tt=J.extend({dataItems:function(){return this.dataSource.flatView()},_angularItems:function(e){var i=this;i.angular(e,function(){return{elements:i.items(),data:t.map(i.dataItems(),function(t){return{dataItem:t}})}})}}),vt.dimensions=function(t,e){var i=t[0];return e&&t.css(e),{width:i.offsetWidth,height:i.offsetHeight}},vt.notify=bt,et=/template$/i,it=/^\s*(?:\{(?:.|\r\n|\n)*\}|\[(?:.|\r\n|\n)*\])\s*$/,nt=/^\{(\d+)(:[^\}]+)?\}|^\[[A-Za-z_]*\]$/,ot=/([A-Z])/g,vt.initWidget=function(n,o,r){var s,a,l,c,h,u,d,f,p,g,m,v,_;if(r?r.roles&&(r=r.roles):r=vt.ui.roles,n=n.nodeType?n:n[0],u=n.getAttribute("data-"+vt.ns+"role")){p=u.indexOf(".")===-1,l=p?r[u]:vt.getter(u)(e),m=t(n).data(),v=l?"kendo"+l.fn.options.prefix+l.fn.options.name:"",g=p?RegExp("^kendo.*"+u+"$","i"):RegExp("^"+v+"$","i");for(_ in m)if(_.match(g)){if(_!==v)return m[_];s=m[_]}if(l){for(f=C(n,"dataSource"),o=t.extend({},S(n,l.fn.options),o),f&&(o.dataSource=typeof f===Et?vt.getter(f)(e):f),c=0,h=l.fn.events.length;c<h;c++)a=l.fn.events[c],d=C(n,a),d!==i&&(o[a]=vt.getter(d)(e));return s?t.isEmptyObject(o)||s.setOptions(o):s=new l(n,o),s}}},vt.rolesFromNamespaces=function(t){var e,i,n=[];for(t[0]||(t=[vt.ui,vt.dataviz.ui]),e=0,i=t.length;e<i;e++)n[e]=t[e].roles;return _t.apply(null,[{}].concat(n.reverse()))},vt.init=function(e){var i=vt.rolesFromNamespaces(Ft.call(arguments,1));t(e).find("[data-"+vt.ns+"role]").addBack().each(function(){vt.initWidget(this,{},i)})},vt.destroy=function(e){t(e).find("[data-"+vt.ns+"role]").addBack().each(function(){var e,i=t(this).data();for(e in i)0===e.indexOf("kendo")&&typeof i[e].destroy===Mt&&i[e].destroy()})},vt.resize=function(e,i){var n,o=t(e).find("[data-"+vt.ns+"role]").addBack().filter(A);o.length&&(n=t.makeArray(o),n.sort(T),t.each(n,function(){var e=vt.widgetInstance(t(this));e&&e.resize(i)}))},vt.parseOptions=S,_t(vt.ui,{Widget:J,DataBoundWidget:tt,roles:{},progress:function(e,i){var n,o,r,s,a=e.find(".k-loading-mask"),l=vt.support,c=l.browser;i?a.length||(n=l.isRtl(e),o=n?"right":"left",s=e.scrollLeft(),r=c.webkit&&n?e[0].scrollWidth-e.width()-2*s:0,a=t("<div class='k-loading-mask'><span class='k-loading-text'>"+vt.ui.progress.messages.loading+"</span><div class='k-loading-image'/><div class='k-loading-color'/></div>").width("100%").height("100%").css("top",e.scrollTop()).css(o,Math.abs(s)+r).prependTo(e)):a&&a.remove()},plugin:function(e,n,o){var r,s,a,l,c=e.fn.options.name;for(n=n||vt.ui,o=o||"",n[c]=e,n.roles[c.toLowerCase()]=e,r="getKendo"+o+c,c="kendo"+o+c,s={name:c,widget:e,prefix:o||""},vt.widgets.push(s),a=0,l=vt._widgetRegisteredCallbacks.length;a<l;a++)vt._widgetRegisteredCallbacks[a](s);t.fn[c]=function(n){var o,r=this;return typeof n===Et?(o=Ft.call(arguments,1),this.each(function(){var e,s,a=t.data(this,c);if(!a)throw Error(vt.format("Cannot call method '{0}' of {1} before it is initialized",n,c));if(e=a[n],typeof e!==Mt)throw Error(vt.format("Cannot find method '{0}' of {1}",n,c));if(s=e.apply(a,o),s!==i)return r=s,!1})):this.each(function(){return new e(this,n)}),r},t.fn[c].widget=e,t.fn[r]=function(){return this.data(c)}}}),vt.ui.progress.messages={loading:"Loading..."},rt={bind:function(){return this},nullObject:!0,options:{}},st=J.extend({init:function(t,e){J.fn.init.call(this,t,e),this.element.autoApplyNS(),this.wrapper=this.element,this.element.addClass("km-widget")},destroy:function(){J.fn.destroy.call(this),this.element.kendoDestroy()},options:{prefix:"Mobile"},events:[],view:function(){var t=this.element.closest(vt.roleSelector("view splitview modalview drawer"));return vt.widgetInstance(t,vt.mobile.ui)||rt},viewHasNativeScrolling:function(){var t=this.view();return t&&t.options.useNativeScrolling},container:function(){var t=this.element.closest(vt.roleSelector("view layout modalview drawer splitview"));return vt.widgetInstance(t.eq(0),vt.mobile.ui)||rt}}),_t(vt.mobile,{init:function(t){vt.init(t,vt.mobile.ui,vt.ui,vt.dataviz.ui)},appLevelNativeScrolling:function(){return vt.mobile.application&&vt.mobile.application.options&&vt.mobile.application.options.useNativeScrolling},roles:{},ui:{Widget:st,DataBoundWidget:tt.extend(st.prototype),roles:{},plugin:function(t){vt.ui.plugin(t,vt.mobile.ui,"Mobile")}}}),l(vt.dataviz,{init:function(t){vt.init(t,vt.dataviz.ui)},ui:{roles:{},themes:{},views:[],plugin:function(t){vt.ui.plugin(t,vt.dataviz.ui)}},roles:{}}),vt.touchScroller=function(e,i){return i||(i={}),i.useNative=!0,t(e).map(function(e,n){return n=t(n),!(!St.kineticScrollNeeded||!vt.mobile.ui.Scroller||n.data("kendoMobileScroller"))&&(n.kendoMobileScroller(i),n.data("kendoMobileScroller"))})[0]},vt.preventDefault=function(t){t.preventDefault()},vt.widgetInstance=function(t,i){var n,o,r,s,a=t.data(vt.ns+"role"),l=[];if(a){if("content"===a&&(a="scroller"),i)if(i[0])for(n=0,o=i.length;n<o;n++)l.push(i[n].roles[a]);else l.push(i.roles[a]);else l=[vt.ui.roles[a],vt.dataviz.ui.roles[a],vt.mobile.ui.roles[a]];for(a.indexOf(".")>=0&&(l=[vt.getter(a)(e)]),n=0,o=l.length;n<o;n++)if(r=l[n],r&&(s=t.data("kendo"+r.fn.options.prefix+r.fn.options.name)))return s}},vt.onResize=function(i){var n=i;return St.mobileOS.android&&(n=function(){setTimeout(i,600)}),t(e).on(St.resize,n),n},vt.unbindResize=function(i){t(e).off(St.resize,i)},vt.attrValue=function(t,e){return t.data(vt.ns+e)},vt.days={Sunday:0,Monday:1,Tuesday:2,Wednesday:3,Thursday:4,Friday:5,Saturday:6},t.extend(t.expr[":"],{kendoFocusable:function(e){var i=t.attr(e,"tabindex");return P(e,!isNaN(i)&&i>-1)}}),at=["mousedown","mousemove","mouseenter","mouseleave","mouseover","mouseout","mouseup","click"],lt="label, input, [data-rel=external]",ct={setupMouseMute:function(){var e,i=0,n=at.length,o=document.documentElement;if(!ct.mouseTrap&&St.eventCapture)for(ct.mouseTrap=!0,ct.bustClick=!1,ct.captureMouse=!1,e=function(e){ct.captureMouse&&("click"===e.type?ct.bustClick&&!t(e.target).is(lt)&&(e.preventDefault(),e.stopPropagation()):e.stopPropagation())};i<n;i++)o.addEventListener(at[i],e,!0)},muteMouse:function(t){ct.captureMouse=!0,t.data.bustClick&&(ct.bustClick=!0),clearTimeout(ct.mouseTrapTimeoutID)},unMuteMouse:function(){clearTimeout(ct.mouseTrapTimeoutID),ct.mouseTrapTimeoutID=setTimeout(function(){ct.captureMouse=!1,ct.bustClick=!1},400)}},ht={down:"touchstart mousedown",move:"mousemove touchmove",up:"mouseup touchend touchcancel",cancel:"mouseleave touchcancel"},St.touch&&(St.mobileOS.ios||St.mobileOS.android)?ht={down:"touchstart",move:"touchmove",up:"touchend touchcancel",cancel:"touchcancel"}:St.pointers?ht={down:"pointerdown",move:"pointermove",up:"pointerup",cancel:"pointercancel pointerleave"}:St.msPointers&&(ht={down:"MSPointerDown",move:"MSPointerMove",up:"MSPointerUp",cancel:"MSPointerCancel MSPointerLeave"}),!St.msPointers||"onmspointerenter"in e||t.each({MSPointerEnter:"MSPointerOver",MSPointerLeave:"MSPointerOut"},function(e,i){t.event.special[e]={delegateType:i,bindType:i,handle:function(e){var n,o=this,r=e.relatedTarget,s=e.handleObj;return r&&(r===o||t.contains(o,r))||(e.type=s.origType,n=s.handler.apply(this,arguments),e.type=i),n}}}),ut=function(t){return ht[t]||t},dt=/([^ ]+)/g,vt.applyEventMap=function(t,e){return t=t.replace(dt,ut),e&&(t=t.replace(dt,"$1."+e)),t},ft=t.fn.on,_t(!0,M,t),M.fn=M.prototype=new t,M.fn.constructor=M,M.fn.init=function(e,i){return i&&i instanceof t&&!(i instanceof M)&&(i=M(i)),t.fn.init.call(this,e,i,pt)},M.fn.init.prototype=M.fn,pt=M(document),_t(M.fn,{handler:function(t){return this.data("handler",t),this},autoApplyNS:function(t){return this.data("kendoNS",t||vt.guid()),this},on:function(){var t,e,i,n,o,r,s=this,a=s.data("kendoNS");return 1===arguments.length?ft.call(s,arguments[0]):(t=s,e=Ft.call(arguments),typeof e[e.length-1]===Rt&&e.pop(),i=e[e.length-1],n=vt.applyEventMap(e[0],a),St.mouseAndTouchPresent&&n.search(/mouse|click/)>-1&&this[0]!==document.documentElement&&(ct.setupMouseMute(),o=2===e.length?null:e[1],r=n.indexOf("click")>-1&&n.indexOf("touchend")>-1,ft.call(this,{touchstart:ct.muteMouse,touchend:ct.unMuteMouse},o,{bustClick:r})),typeof i===Et&&(t=s.data("handler"),i=t[i],e[e.length-1]=function(e){i.call(t,e)}),e[0]=n,ft.apply(s,e),s)},kendoDestroy:function(t){return t=t||this.data("kendoNS"),t&&this.off("."+t),this}}),vt.jQuery=M,vt.eventMap=ht,vt.timezone=function(){function t(t,e){var i,n,o,r=e[3],s=e[4],a=e[5],l=e[8];return l||(e[8]=l={}),l[t]?l[t]:(isNaN(s)?0===s.indexOf("last")?(i=new Date(Date.UTC(t,h[r]+1,1,a[0]-24,a[1],a[2],0)),n=u[s.substr(4,3)],o=i.getUTCDay(),i.setUTCDate(i.getUTCDate()+n-o-(n>o?7:0))):s.indexOf(">=")>=0&&(i=new Date(Date.UTC(t,h[r],s.substr(5),a[0],a[1],a[2],0)),n=u[s.substr(0,3)],o=i.getUTCDay(),i.setUTCDate(i.getUTCDate()+n-o+(n<o?7:0))):i=new Date(Date.UTC(t,h[r],s,a[0],a[1],a[2],0)),l[t]=i)}function e(e,i,n){var o,r,s,a;return(i=i[n])?(s=new Date(e).getUTCFullYear(),i=jQuery.grep(i,function(t){var e=t[0],i=t[1];return e<=s&&(i>=s||e==s&&"only"==i||"max"==i)}),i.push(e),i.sort(function(e,i){return"number"!=typeof e&&(e=+t(s,e)),"number"!=typeof i&&(i=+t(s,i)),e-i}),a=i[jQuery.inArray(e,i)-1]||i[i.length-1],isNaN(a)?a:null):(o=n.split(":"),r=0,o.length>1&&(r=60*o[0]+ +o[1]),[-1e6,"max","-","Jan",1,[0,0,0],r,"-"])}function i(t,e,i){var n,o,r,s=e[i];if("string"==typeof s&&(s=e[s]),!s)throw Error('Timezone "'+i+'" is either incorrect, or kendo.timezones.min.js is not included.');for(n=s.length-1;n>=0&&(o=s[n][3],!(o&&t>o));n--);if(r=s[n+1],!r)throw Error('Timezone "'+i+'" not found on '+t+".");return r}function n(t,n,o,r){typeof t!=It&&(t=Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));var s=i(t,n,r);return{zone:s,rule:e(t,o,s[1])}}function o(t,e){var i,o,r;return"Etc/UTC"==e||"Etc/GMT"==e?0:(i=n(t,this.zones,this.rules,e),o=i.zone,r=i.rule,vt.parseFloat(r?o[0]-r[6]:o[0]))}function r(t,e){var i=n(t,this.zones,this.rules,e),o=i.zone,r=i.rule,s=o[2];return s.indexOf("/")>=0?s.split("/")[r&&+r[6]?1:0]:s.indexOf("%s")>=0?s.replace("%s",r&&"-"!=r[7]?r[7]:""):s}function s(t,e,i){var n,o;return typeof e==Et&&(e=this.offset(t,e)),typeof i==Et&&(i=this.offset(t,i)),n=t.getTimezoneOffset(),t=new Date(t.getTime()+6e4*(e-i)),o=t.getTimezoneOffset(),new Date(t.getTime()+6e4*(o-n))}function a(t,e){return this.convert(t,t.getTimezoneOffset(),e)}function l(t,e){return this.convert(t,e,t.getTimezoneOffset())}function c(t){return this.apply(new Date(t),"Etc/UTC")}var h={Jan:0,Feb:1,Mar:2,Apr:3,May:4,Jun:5,Jul:6,Aug:7,Sep:8,Oct:9,Nov:10,Dec:11},u={Sun:0,Mon:1,Tue:2,Wed:3,Thu:4,Fri:5,Sat:6};return{zones:{},rules:{},offset:o,convert:s,apply:a,remove:l,abbr:r,toLocalDate:c}}(),vt.date=function(){function t(t,e){return 0===e&&23===t.getHours()&&(t.setHours(t.getHours()+2),!0)}function e(e,i,n){var o=e.getHours();n=n||1,i=(i-e.getDay()+7*n)%7,e.setDate(e.getDate()+i),t(e,o)}function i(t,i,n){return t=new Date(t),e(t,i,n),t}function n(t){return new Date(t.getFullYear(),t.getMonth(),1)}function o(t){var e=new Date(t.getFullYear(),t.getMonth()+1,0),i=n(t),o=Math.abs(e.getTimezoneOffset()-i.getTimezoneOffset());return o&&e.setHours(i.getHours()+o/60),e}function r(e){return e=new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0),t(e,0),e}function s(t){return Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds())}function a(t){return t.getTime()-r(t)}function l(t,e,i){var n,o=a(e),r=a(i);return!t||o==r||(e>=i&&(i+=v),n=a(t),o>n&&(n+=v),r<o&&(r+=v),n>=o&&n<=r)}function c(t,e,i){var n,o=e.getTime(),r=i.getTime();return o>=r&&(r+=v),n=t.getTime(),n>=o&&n<=r}function h(e,i){var n=e.getHours();return e=new Date(e),u(e,i*v),t(e,n),e}function u(t,e,i){var n,o=t.getTimezoneOffset();t.setTime(t.getTime()+e),i||(n=t.getTimezoneOffset()-o,t.setTime(t.getTime()+n*m))}function d(e,i){return e=new Date(vt.date.getDate(e).getTime()+vt.date.getMilliseconds(i)),t(e,i.getHours()),e}function f(){return r(new Date)}function p(t){return r(t).getTime()==f().getTime()}function g(t){var e=new Date(1980,1,1,0,0,0);return t&&e.setHours(t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()),e}var m=6e4,v=864e5;return{adjustDST:t,dayOfWeek:i,setDayOfWeek:e,getDate:r,isInDateRange:c,isInTimeRange:l,isToday:p,nextDay:function(t){return h(t,1)},previousDay:function(t){return h(t,-1)},toUtcTime:s,MS_PER_DAY:v,MS_PER_HOUR:60*m,MS_PER_MINUTE:m,setTime:u,setHours:d,addDays:h,today:f,toInvariantTime:g,firstDayOfMonth:n,lastDayOfMonth:o,getMilliseconds:a}}(),vt.stripWhitespace=function(t){var e,i,n;if(document.createNodeIterator)for(e=document.createNodeIterator(t,NodeFilter.SHOW_TEXT,function(e){return e.parentNode==t?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_REJECT},!1);e.nextNode();)e.referenceNode&&!e.referenceNode.textContent.trim()&&e.referenceNode.parentNode.removeChild(e.referenceNode);else for(i=0;i<t.childNodes.length;i++)n=t.childNodes[i],3!=n.nodeType||/\S/.test(n.nodeValue)||(t.removeChild(n),i--),1==n.nodeType&&vt.stripWhitespace(n)},gt=e.requestAnimationFrame||e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.oRequestAnimationFrame||e.msRequestAnimationFrame||function(t){setTimeout(t,1e3/60)},vt.animationFrame=function(t){gt.call(e,t)},mt=[],vt.queueAnimation=function(t){mt[mt.length]=t,1===mt.length&&vt.runNextAnimation()},vt.runNextAnimation=function(){vt.animationFrame(function(){mt[0]&&(mt.shift()(),mt[0]&&vt.runNextAnimation())})},vt.parseQueryStringParams=function(t){for(var e=t.split("?")[1]||"",i={},n=e.split(/&|=/),o=n.length,r=0;r<o;r+=2)""!==n[r]&&(i[decodeURIComponent(n[r])]=decodeURIComponent(n[r+1]));return i},vt.elementUnderCursor=function(t){if(i!==t.x.client)return document.elementFromPoint(t.x.client,t.y.client)},vt.wheelDeltaY=function(t){var e,n=t.originalEvent,o=n.wheelDeltaY;return n.wheelDelta?(o===i||o)&&(e=n.wheelDelta):n.detail&&n.axis===n.VERTICAL_AXIS&&(e=10*-n.detail),e},vt.throttle=function(t,e){var n,o,r=0;return!e||e<=0?t:(o=function(){function o(){t.apply(s,l),r=+new Date}var s=this,a=+new Date-r,l=arguments;return r?(n&&clearTimeout(n),a>e?o():n=setTimeout(o,e-a),i):o()},o.cancel=function(){clearTimeout(n)},o)},vt.caret=function(e,n,o){var r,s,a,l,c=n!==i;if(o===i&&(o=n),e[0]&&(e=e[0]),!c||!e.disabled){try{e.selectionStart!==i?c?(e.focus(),e.setSelectionRange(n,o)):n=[e.selectionStart,e.selectionEnd]:document.selection&&(t(e).is(":visible")&&e.focus(),r=e.createTextRange(),c?(r.collapse(!0),r.moveStart("character",n),r.moveEnd("character",o-n),r.select()):(s=r.duplicate(),r.moveToBookmark(document.selection.createRange().getBookmark()),s.setEndPoint("EndToStart",r),a=s.text.length,l=a+r.text.length,n=[a,l]))}catch(h){n=[]}return n}},vt.compileMobileDirective=function(t,i){var n=e.angular;return t.attr("data-"+vt.ns+"role",t[0].tagName.toLowerCase().replace("kendo-mobile-","").replace("-","")),n.element(t).injector().invoke(["$compile",function(e){e(t)(i),/^\$(digest|apply)$/.test(i.$$phase)||i.$digest()}]),vt.widgetInstance(t,vt.mobile.ui)},vt.antiForgeryTokens=function(){var e={},n=t("meta[name=csrf-token],meta[name=_csrf]").attr("content"),o=t("meta[name=csrf-param],meta[name=_csrf_header]").attr("content");return t("input[name^='__RequestVerificationToken']").each(function(){e[this.name]=this.value}),o!==i&&n!==i&&(e[o]=n),e},vt.cycleForm=function(t){function e(t){var e=vt.widgetInstance(t);e&&e.focus?e.focus():t.focus()}var i=t.find("input, .k-widget").first(),n=t.find("button, .k-button").last();n.on("keydown",function(t){t.keyCode!=vt.keys.TAB||t.shiftKey||(t.preventDefault(),e(i))}),i.on("keydown",function(t){t.keyCode==vt.keys.TAB&&t.shiftKey&&(t.preventDefault(),e(n))})},function(){function i(e,i,n,o){var r,s,a=t("<form>").attr({action:n,method:"POST",target:o}),l=vt.antiForgeryTokens();l.fileName=i,r=e.split(";base64,"),l.contentType=r[0].replace("data:",""),l.base64=r[1];for(s in l)l.hasOwnProperty(s)&&t("<input>").attr({value:l[s],name:s,type:"hidden"}).appendTo(a);a.appendTo("body").submit().remove()}function n(t,e){var i,n,o,r,s,a=t;if("string"==typeof t){for(i=t.split(";base64,"),n=i[0],o=atob(i[1]),r=new Uint8Array(o.length),s=0;s<o.length;s++)r[s]=o.charCodeAt(s);a=new Blob([r.buffer],{type:n})}navigator.msSaveBlob(a,e)}function o(t,i){e.Blob&&t instanceof Blob&&(t=URL.createObjectURL(t)),r.download=i,r.href=t;var n=document.createEvent("MouseEvents");n.initMouseEvent("click",!0,!1,e,0,0,0,0,0,!1,!1,!1,!1,0,null),r.dispatchEvent(n),setTimeout(function(){URL.revokeObjectURL(t)})}var r=document.createElement("a"),s="download"in r&&!vt.support.browser.edge;vt.saveAs=function(t){var e=i;t.forceProxy||(s?e=o:navigator.msSaveBlob&&(e=n)),e(t.dataURI,t.fileName,t.proxyURL,t.proxyTarget)}}(),vt.proxyModelSetters=function(t){var e={};return Object.keys(t||{}).forEach(function(i){Object.defineProperty(e,i,{get:function(){return t[i]},set:function(e){t[i]=e,t.dirty=!0}})}),e}}(jQuery,window),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.fx.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(t){return parseInt(t,10)}function n(t,e){return i(t.css(e))}function o(t){var e,i=[];for(e in t)i.push(e);return i}function r(t){for(var e in t)U.indexOf(e)!=-1&&j.indexOf(e)==-1&&delete t[e];return t}function s(t,e){var i,n,o,r,s=[],a={};for(n in e)i=n.toLowerCase(),r=E&&U.indexOf(i)!=-1,!D.hasHW3D&&r&&j.indexOf(i)==-1?delete e[n]:(o=e[n],r?s.push(n+"("+o+")"):a[n]=o);return s.length&&(a[at]=s.join(" ")),a}function a(t,e){var n,o,r;return E?(n=t.css(at),n==X?"scale"==e?1:0:(o=n.match(RegExp(e+"\\s*\\(([\\d\\w\\.]+)")),r=0,o?r=i(o[1]):(o=n.match(R)||[0,0,0,0,0],e=e.toLowerCase(),V.test(e)?r=parseFloat(o[3]/o[2]):"translatey"==e?r=parseFloat(o[4]/o[2]):"scale"==e?r=parseFloat(o[2]):"rotate"==e&&(r=parseFloat(Math.atan2(o[2],o[1])))),r)):parseFloat(t.css(e))}function l(t){return t.charAt(0).toUpperCase()+t.substring(1)}function c(t,e){var i=p.extend(e),n=i.prototype.directions;S[l(t)]=i,S.Element.prototype[t]=function(t,e,n,o){return new i(this.element,t,e,n,o)},T(n,function(e,n){S.Element.prototype[t+l(n)]=function(t,e,o){return new i(this.element,n,t,e,o)}})}function h(t,i,n,o){c(t,{directions:m,startValue:function(t){return this._startValue=t,this},endValue:function(t){return this._endValue=t,this},shouldHide:function(){return this._shouldHide},prepare:function(t,r){var s,a,l=this,c="out"===this._direction,h=l.element.data(i),u=!(isNaN(h)||h==n);s=u?h:e!==this._startValue?this._startValue:c?n:o,a=e!==this._endValue?this._endValue:c?o:n,this._reverse?(t[i]=a,r[i]=s):(t[i]=s,r[i]=a),l._shouldHide=r[i]===o}})}function u(t,e){var i=C.directions[e].vertical,n=t[i?Z:K]()/2+"px";return _[e].replace("$size",n)}var d,f,p,g,m,v,_,y,w,x,b,k,C=window.kendo,S=C.effects,T=t.each,A=t.extend,P=t.proxy,D=C.support,M=D.browser,E=D.transforms,I=D.transitions,B={scale:0,scalex:0,scaley:0,scale3d:0},z={translate:0,translatex:0,translatey:0,translate3d:0},L=e!==document.documentElement.style.zoom&&!E,R=/matrix3?d?\s*\(.*,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?,\s*([\d\.\-]+)\w*?/i,O=/^(-?[\d\.\-]+)?[\w\s]*,?\s*(-?[\d\.\-]+)?[\w\s]*/i,V=/translatex?$/i,F=/(zoom|fade|expand)(\w+)/,N=/(zoom|fade|expand)/,H=/[xy]$/i,U=["perspective","rotate","rotatex","rotatey","rotatez","rotate3d","scale","scalex","scaley","scalez","scale3d","skew","skewx","skewy","translate","translatex","translatey","translatez","translate3d","matrix","matrix3d"],j=["rotate","scale","scalex","scaley","skew","skewx","skewy","translate","translatex","translatey","matrix"],G={rotate:"deg",scale:"",skew:"px",translate:"px"},W=E.css,q=Math.round,$="",Y="px",X="none",Q="auto",K="width",Z="height",J="hidden",tt="origin",et="abortId",it="overflow",nt="translate",ot="position",rt="completeCallback",st=W+"transition",at=W+"transform",lt=W+"backface-visibility",ct=W+"perspective",ht="1500px",ut="perspective("+ht+")",dt={left:{reverse:"right",property:"left",transition:"translatex",vertical:!1,modifier:-1},right:{reverse:"left",property:"left",transition:"translatex",vertical:!1,modifier:1},down:{reverse:"up",property:"top",transition:"translatey",vertical:!0,modifier:1},up:{reverse:"down",property:"top",transition:"translatey",vertical:!0,modifier:-1},top:{reverse:"bottom"},bottom:{reverse:"top"},"in":{reverse:"out",modifier:-1},out:{reverse:"in",modifier:1},vertical:{reverse:"vertical"},horizontal:{reverse:"horizontal"}};C.directions=dt,A(t.fn,{kendoStop:function(t,e){return I?S.stopQueue(this,t||!1,e||!1):this.stop(t,e)}}),E&&!I&&(T(j,function(i,n){t.fn[n]=function(i){if(e===i)return a(this,n);var o=t(this)[0],r=n+"("+i+G[n.replace(H,"")]+")";return o.style.cssText.indexOf(at)==-1?t(this).css(at,r):o.style.cssText=o.style.cssText.replace(RegExp(n+"\\(.*?\\)","i"),r),this},t.fx.step[n]=function(e){t(e.elem)[n](e.now)}}),d=t.fx.prototype.cur,t.fx.prototype.cur=function(){return j.indexOf(this.prop)!=-1?parseFloat(t(this.elem)[this.prop]()):d.apply(this,arguments)}),C.toggleClass=function(t,e,i,n){return e&&(e=e.split(" "),I&&(i=A({exclusive:"all",duration:400,ease:"ease-out"},i),t.css(st,i.exclusive+" "+i.duration+"ms "+i.ease),setTimeout(function(){t.css(st,"").css(Z)},i.duration)),T(e,function(e,i){t.toggleClass(i,n)})),t},C.parseEffects=function(t,e){var i={};return"string"==typeof t?T(t.split(" "),function(t,n){var o=!N.test(n),r=n.replace(F,function(t,e,i){return e+":"+i.toLowerCase()}),s=r.split(":"),a=s[1],l={};s.length>1&&(l.direction=e&&o?dt[a].reverse:a),i[s[0]]=l}):T(t,function(t){var n=this.direction;n&&e&&!N.test(t)&&(this.direction=dt[n].reverse),i[t]=this}),i},I&&A(S,{transition:function(e,i,n){var r,a,l,c,h=0,u=e.data("keys")||[];n=A({duration:200,ease:"ease-out",complete:null,exclusive:"all"},n),l=!1,c=function(){l||(l=!0,a&&(clearTimeout(a),a=null),e.removeData(et).dequeue().css(st,"").css(st),n.complete.call(e))},n.duration=t.fx?t.fx.speeds[n.duration]||n.duration:n.duration,r=s(e,i),t.merge(u,o(r)),e.data("keys",t.unique(u)).height(),e.css(st,n.exclusive+" "+n.duration+"ms "+n.ease).css(st),e.css(r).css(at),I.event&&(e.one(I.event,c),0!==n.duration&&(h=500)),a=setTimeout(c,n.duration+h),e.data(et,a),e.data(rt,c)},stopQueue:function(t,e,i){var n,o=t.data("keys"),r=!i&&o,s=t.data(rt);return r&&(n=C.getComputedStyles(t[0],o)),s&&s(),r&&t.css(n),t.removeData("keys").stop(e)}}),f=C.Class.extend({init:function(t,e){var i=this;i.element=t,i.effects=[],i.options=e,i.restore=[]},run:function(e){var i,n,o,a,l,c,h,u=this,d=e.length,f=u.element,p=u.options,g=t.Deferred(),m={},v={};for(u.effects=e,g.then(t.proxy(u,"complete")),f.data("animating",!0),n=0;n<d;n++)for(i=e[n],i.setReverse(p.reverse),i.setOptions(p),u.addRestoreProperties(i.restore),i.prepare(m,v),l=i.children(),o=0,c=l.length;o<c;o++)l[o].duration(p.duration).run();for(h in p.effects)A(v,p.effects[h].properties);for(f.is(":visible")||A(m,{display:f.data("olddisplay")||"block"}),E&&!p.reset&&(a=f.data("targetTransform"),a&&(m=A(a,m))),m=s(f,m),E&&!I&&(m=r(m)),f.css(m).css(at),n=0;n<d;n++)e[n].setup();return p.init&&p.init(),f.data("targetTransform",v),S.animate(f,v,A({},p,{complete:g.resolve})),g.promise()},stop:function(){t(this.element).kendoStop(!0,!0)},addRestoreProperties:function(t){for(var e,i=this.element,n=0,o=t.length;n<o;n++)e=t[n],this.restore.push(e),i.data(e)||i.data(e,i.css(e))},restoreCallback:function(){var t,e,i,n=this.element;for(t=0,e=this.restore.length;t<e;t++)i=this.restore[t],n.css(i,n.data(i))},complete:function(){var e=this,i=0,n=e.element,o=e.options,r=e.effects,s=r.length;for(n.removeData("animating").dequeue(),o.hide&&n.data("olddisplay",n.css("display")).hide(),this.restoreCallback(),L&&!E&&setTimeout(t.proxy(this,"restoreCallback"),0);i<s;i++)r[i].teardown();o.completeCallback&&o.completeCallback(n)}}),S.promise=function(t,e){var i,n,o,r=[],s=new f(t,e),a=C.parseEffects(e.effects);e.effects=a;for(o in a)i=S[l(o)],i&&(n=new i(t,a[o].direction),r.push(n));r[0]?s.run(r):(t.is(":visible")||t.css({display:t.data("olddisplay")||"block"}).css("display"),e.init&&e.init(),t.dequeue(),s.complete())},A(S,{animate:function(i,o,s){var a=s.transition!==!1;delete s.transition,I&&"transition"in S&&a?S.transition(i,o,s):E?i.animate(r(o),{queue:!1,show:!1,hide:!1,duration:s.duration,complete:s.complete}):i.each(function(){var i=t(this),r={};T(U,function(t,s){var a,l,c,h,u,d,f,p=o?o[s]+" ":null;p&&(l=o,s in B&&o[s]!==e?(a=p.match(O),E&&A(l,{scale:+a[0]})):s in z&&o[s]!==e&&(c=i.css(ot),h="absolute"==c||"fixed"==c,i.data(nt)||(h?i.data(nt,{top:n(i,"top")||0,left:n(i,"left")||0,bottom:n(i,"bottom"),right:n(i,"right")}):i.data(nt,{top:n(i,"marginTop")||0,left:n(i,"marginLeft")||0})),u=i.data(nt),a=p.match(O),a&&(d=s==nt+"y"?0:+a[1],f=s==nt+"y"?+a[1]:+a[2],h?(isNaN(u.right)?isNaN(d)||A(l,{left:u.left+d}):isNaN(d)||A(l,{right:u.right-d}),isNaN(u.bottom)?isNaN(f)||A(l,{top:u.top+f}):isNaN(f)||A(l,{bottom:u.bottom-f})):(isNaN(d)||A(l,{marginLeft:u.left+d}),isNaN(f)||A(l,{marginTop:u.top+f})))),!E&&"scale"!=s&&s in l&&delete l[s],l&&A(r,l))}),M.msie&&delete r.scale,i.animate(r,{queue:!1,show:!1,hide:!1,duration:s.duration,complete:s.complete})})}}),S.animatedPromise=S.promise,p=C.Class.extend({init:function(t,e){var i=this;i.element=t,i._direction=e,i.options={},i._additionalEffects=[],i.restore||(i.restore=[])},reverse:function(){return this._reverse=!0,this.run()},play:function(){return this._reverse=!1,this.run()},add:function(t){return this._additionalEffects.push(t),this},direction:function(t){return this._direction=t,this},duration:function(t){return this._duration=t,this},compositeRun:function(){var t=this,e=new f(t.element,{reverse:t._reverse,duration:t._duration}),i=t._additionalEffects.concat([t]);return e.run(i)},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();var e,i,n=this,o=n.element,a=0,l=n.restore,c=l.length,h=t.Deferred(),u={},d={},f=n.children(),p=f.length;for(h.then(t.proxy(n,"_complete")),o.data("animating",!0),a=0;a<c;a++)e=l[a],o.data(e)||o.data(e,o.css(e));for(a=0;a<p;a++)f[a].duration(n._duration).run();return n.prepare(u,d),o.is(":visible")||A(u,{display:o.data("olddisplay")||"block"}),E&&(i=o.data("targetTransform"),i&&(u=A(i,u))),u=s(o,u),E&&!I&&(u=r(u)),o.css(u).css(at),n.setup(),o.data("targetTransform",d),S.animate(o,d,{duration:n._duration,complete:h.resolve}),h.promise()},stop:function(){var e=0,i=this.children(),n=i.length;for(e=0;e<n;e++)i[e].stop();return t(this.element).kendoStop(!0,!0),this},restoreCallback:function(){var t,e,i,n=this.element;for(t=0,e=this.restore.length;t<e;t++)i=this.restore[t],n.css(i,n.data(i))},_complete:function(){var e=this,i=e.element;i.removeData("animating").dequeue(),e.restoreCallback(),e.shouldHide()&&i.data("olddisplay",i.css("display")).hide(),L&&!E&&setTimeout(t.proxy(e,"restoreCallback"),0),e.teardown()},setOptions:function(t){A(!0,this.options,t)},children:function(){return[]},shouldHide:t.noop,setup:t.noop,prepare:t.noop,teardown:t.noop,directions:[],setReverse:function(t){return this._reverse=t,this}}),g=["left","right","up","down"],m=["in","out"],c("slideIn",{directions:g,divisor:function(t){return this.options.divisor=t,this},prepare:function(t,e){var i,n=this,o=n.element,r=C._outerWidth,s=C._outerHeight,a=dt[n._direction],l=-a.modifier*(a.vertical?s(o):r(o)),c=l/(n.options&&n.options.divisor||1)+Y,h="0px";n._reverse&&(i=t,t=e,e=i),E?(t[a.transition]=c,e[a.transition]=h):(t[a.property]=c,e[a.property]=h)}}),c("tile",{directions:g,init:function(t,e,i){p.prototype.init.call(this,t,e),this.options={previous:i}},previousDivisor:function(t){return this.options.previousDivisor=t,this},children:function(){var t=this,e=t._reverse,i=t.options.previous,n=t.options.previousDivisor||1,o=t._direction,r=[C.fx(t.element).slideIn(o).setReverse(e)];return i&&r.push(C.fx(i).slideIn(dt[o].reverse).divisor(n).setReverse(!e)),r}}),h("fade","opacity",1,0),h("zoom","scale",1,.01),c("slideMargin",{prepare:function(t,e){var i,n=this,o=n.element,r=n.options,s=o.data(tt),a=r.offset,l=n._reverse;l||null!==s||o.data(tt,parseFloat(o.css("margin-"+r.axis))),i=o.data(tt)||0,e["margin-"+r.axis]=l?i:i+a}}),c("slideTo",{prepare:function(t,e){var i=this,n=i.element,o=i.options,r=o.offset.split(","),s=i._reverse;E?(e.translatex=s?0:r[0],e.translatey=s?0:r[1]):(e.left=s?0:r[0],e.top=s?0:r[1]),n.css("left")}}),c("expand",{directions:["horizontal","vertical"],restore:[it],prepare:function(t,i){var n=this,o=n.element,r=n.options,s=n._reverse,a="vertical"===n._direction?Z:K,l=o[0].style[a],c=o.data(a),h=parseFloat(c||l),u=q(o.css(a,Q)[a]());t.overflow=J,h=r&&r.reset?u||h:h||u,i[a]=(s?0:h)+Y,t[a]=(s?h:0)+Y,c===e&&o.data(a,l)},shouldHide:function(){return this._reverse},teardown:function(){var t=this,e=t.element,i="vertical"===t._direction?Z:K,n=e.data(i);n!=Q&&n!==$||setTimeout(function(){e.css(i,Q).css(i)},0)}}),v={position:"absolute",marginLeft:0,marginTop:0,scale:1},c("transfer",{init:function(t,e){this.element=t,this.options={target:e},this.restore=[]},setup:function(){this.element.appendTo(document.body)},prepare:function(t,e){var i=this,n=i.element,o=S.box(n),r=S.box(i.options.target),s=a(n,"scale"),l=S.fillScale(r,o),c=S.transformOrigin(r,o);A(t,v),e.scale=1,n.css(at,"scale(1)").css(at),n.css(at,"scale("+s+")"),t.top=o.top,t.left=o.left,t.transformOrigin=c.x+Y+" "+c.y+Y,i._reverse?t.scale=l:e.scale=l}}),_={top:"rect(auto auto $size auto)",bottom:"rect($size auto auto auto)",left:"rect(auto $size auto auto)",right:"rect(auto auto auto $size)"},y={top:{start:"rotatex(0deg)",end:"rotatex(180deg)"},bottom:{start:"rotatex(-180deg)",end:"rotatex(0deg)"},left:{start:"rotatey(0deg)",end:"rotatey(-180deg)"},right:{start:"rotatey(180deg)",end:"rotatey(0deg)"}},c("turningPage",{directions:g,init:function(t,e,i){p.prototype.init.call(this,t,e),this._container=i},prepare:function(t,e){var i=this,n=i._reverse,o=n?dt[i._direction].reverse:i._direction,r=y[o];t.zIndex=1,i._clipInHalf&&(t.clip=u(i._container,C.directions[o].reverse)),t[lt]=J,e[at]=ut+(n?r.start:r.end),t[at]=ut+(n?r.end:r.start)},setup:function(){this._container.append(this.element)},face:function(t){return this._face=t,this},shouldHide:function(){var t=this,e=t._reverse,i=t._face;return e&&!i||!e&&i},clipInHalf:function(t){return this._clipInHalf=t,this},temporary:function(){return this.element.addClass("temp-page"),this}}),c("staticPage",{directions:g,init:function(t,e,i){p.prototype.init.call(this,t,e),this._container=i},restore:["clip"],prepare:function(t,e){var i=this,n=i._reverse?dt[i._direction].reverse:i._direction;t.clip=u(i._container,n),t.opacity=.999,e.opacity=1},shouldHide:function(){var t=this,e=t._reverse,i=t._face;return e&&!i||!e&&i},face:function(t){return this._face=t,this}}),c("pageturn",{directions:["horizontal","vertical"],init:function(t,e,i,n){p.prototype.init.call(this,t,e),this.options={},this.options.face=i,this.options.back=n},children:function(){
var t,e=this,i=e.options,n="horizontal"===e._direction?"left":"top",o=C.directions[n].reverse,r=e._reverse,s=i.face.clone(!0).removeAttr("id"),a=i.back.clone(!0).removeAttr("id"),l=e.element;return r&&(t=n,n=o,o=t),[C.fx(i.face).staticPage(n,l).face(!0).setReverse(r),C.fx(i.back).staticPage(o,l).setReverse(r),C.fx(s).turningPage(n,l).face(!0).clipInHalf(!0).temporary().setReverse(r),C.fx(a).turningPage(o,l).clipInHalf(!0).temporary().setReverse(r)]},prepare:function(t,e){t[ct]=ht,t.transformStyle="preserve-3d",t.opacity=.999,e.opacity=1},teardown:function(){this.element.find(".temp-page").remove()}}),c("flip",{directions:["horizontal","vertical"],init:function(t,e,i,n){p.prototype.init.call(this,t,e),this.options={},this.options.face=i,this.options.back=n},children:function(){var t,e=this,i=e.options,n="horizontal"===e._direction?"left":"top",o=C.directions[n].reverse,r=e._reverse,s=e.element;return r&&(t=n,n=o,o=t),[C.fx(i.face).turningPage(n,s).face(!0).setReverse(r),C.fx(i.back).turningPage(o,s).setReverse(r)]},prepare:function(t){t[ct]=ht,t.transformStyle="preserve-3d"}}),w=!D.mobileOS.android,x=".km-touch-scrollbar, .km-actionsheet-wrapper",c("replace",{_before:t.noop,_after:t.noop,init:function(e,i,n){p.prototype.init.call(this,e),this._previous=t(i),this._transitionClass=n},duration:function(){throw Error("The replace effect does not support duration setting; the effect duration may be customized through the transition class rule")},beforeTransition:function(t){return this._before=t,this},afterTransition:function(t){return this._after=t,this},_both:function(){return t().add(this._element).add(this._previous)},_containerClass:function(){var t=this._direction,e="k-fx k-fx-start k-fx-"+this._transitionClass;return t&&(e+=" k-fx-"+t),this._reverse&&(e+=" k-fx-reverse"),e},complete:function(e){if(!(!this.deferred||e&&t(e.target).is(x))){var i=this.container;i.removeClass("k-fx-end").removeClass(this._containerClass()).off(I.event,this.completeProxy),this._previous.hide().removeClass("k-fx-current"),this.element.removeClass("k-fx-next"),w&&i.css(it,""),this.isAbsolute||this._both().css(ot,""),this.deferred.resolve(),delete this.deferred}},run:function(){if(this._additionalEffects&&this._additionalEffects[0])return this.compositeRun();var e,i=this,n=i.element,o=i._previous,r=n.parents().filter(o.parents()).first(),s=i._both(),a=t.Deferred(),l=n.css(ot);return r.length||(r=n.parent()),this.container=r,this.deferred=a,this.isAbsolute="absolute"==l,this.isAbsolute||s.css(ot,"absolute"),w&&(e=r.css(it),r.css(it,"hidden")),I?(n.addClass("k-fx-hidden"),r.addClass(this._containerClass()),this.completeProxy=t.proxy(this,"complete"),r.on(I.event,this.completeProxy),C.animationFrame(function(){n.removeClass("k-fx-hidden").addClass("k-fx-next"),o.css("display","").addClass("k-fx-current"),i._before(o,n),C.animationFrame(function(){r.removeClass("k-fx-start").addClass("k-fx-end"),i._after(o,n)})})):this.complete(),a.promise()},stop:function(){this.complete()}}),b=C.Class.extend({init:function(){var t=this;t._tickProxy=P(t._tick,t),t._started=!1},tick:t.noop,done:t.noop,onEnd:t.noop,onCancel:t.noop,start:function(){this.enabled()&&(this.done()?this.onEnd():(this._started=!0,C.animationFrame(this._tickProxy)))},enabled:function(){return!0},cancel:function(){this._started=!1,this.onCancel()},_tick:function(){var t=this;t._started&&(t.tick(),t.done()?(t._started=!1,t.onEnd()):C.animationFrame(t._tickProxy))}}),k=b.extend({init:function(t){var e=this;A(e,t),b.fn.init.call(e)},done:function(){return this.timePassed()>=this.duration},timePassed:function(){return Math.min(this.duration,new Date-this.startDate)},moveTo:function(t){var e=this,i=e.movable;e.initial=i[e.axis],e.delta=t.location-e.initial,e.duration="number"==typeof t.duration?t.duration:300,e.tick=e._easeProxy(t.ease),e.startDate=new Date,e.start()},_easeProxy:function(t){var e=this;return function(){e.movable.moveAxis(e.axis,t(e.timePassed(),e.initial,e.delta,e.duration))}}}),A(k,{easeOutExpo:function(t,e,i,n){return t==n?e+i:i*(-Math.pow(2,-10*t/n)+1)+e},easeOutBack:function(t,e,i,n,o){return o=1.70158,i*((t=t/n-1)*t*((o+1)*t+o)+1)+e}}),S.Animation=b,S.Transition=k,S.createEffect=c,S.box=function(e){e=t(e);var i=e.offset();return i.width=C._outerWidth(e),i.height=C._outerHeight(e),i},S.transformOrigin=function(t,e){var i=(t.left-e.left)*e.width/(e.width-t.width),n=(t.top-e.top)*e.height/(e.height-t.height);return{x:isNaN(i)?0:i,y:isNaN(n)?0:n}},S.fillScale=function(t,e){return Math.min(t.width/e.width,t.height/e.height)},S.fitScale=function(t,e){return Math.max(t.width/e.width,t.height/e.height)}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.router.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(t,e){if(!e)return t;t+"/"===e&&(t=e);var i=RegExp("^"+e,"i");return i.test(t)||(t=e+"/"+t),f.protocol+"//"+(f.host+"/"+t).replace(/\/\/+/g,"/")}function n(t){return t?"#!":"#"}function o(t){var e=f.href;return"#!"===t&&e.indexOf("#")>-1&&e.indexOf("#!")<0?null:e.split(t)[1]||""}function r(t,e){return 0===e.indexOf(t)?e.substr(t.length).replace(/\/\//g,"/"):e}function s(t){return t.replace(/^(#)?/,"#")}function a(t){return t.replace(/^(#(!)?)?/,"#!")}var l=window.kendo,c="change",h="back",u="same",d=l.support,f=window.location,p=window.history,g=50,m=l.support.browser.msie,v=/^#*/,_=window.document,y=l.Class.extend({back:function(){m?setTimeout(function(){p.back()}):p.back()},forward:function(){m?setTimeout(function(){p.forward()}):p.forward()},length:function(){return p.length},replaceLocation:function(t){f.replace(t)}}),w=y.extend({init:function(t){this.root=t},navigate:function(t){p.pushState({},_.title,i(t,this.root))},replace:function(t){p.replaceState({},_.title,i(t,this.root))},normalize:function(t){return r(this.root,t)},current:function(){var t=f.pathname;return f.search&&(t+=f.search),r(this.root,t)},change:function(e){t(window).bind("popstate.kendo",e)},stop:function(){t(window).unbind("popstate.kendo")},normalizeCurrent:function(t){var e,r=t.root,s=f.pathname,a=o(n(t.hashBang));r===s+"/"&&(e=r),r===s&&a&&(e=i(a.replace(v,""),r)),e&&p.pushState({},_.title,e)}}),x=y.extend({init:function(t){this._id=l.guid(),this.prefix=n(t),this.fix=t?a:s},navigate:function(t){f.hash=this.fix(t)},replace:function(t){this.replaceLocation(this.fix(t))},normalize:function(t){return t.indexOf(this.prefix)<0?t:t.split(this.prefix)[1]},change:function(e){d.hashChange?t(window).on("hashchange."+this._id,e):this._interval=setInterval(e,g)},stop:function(){t(window).off("hashchange."+this._id),clearInterval(this._interval)},current:function(){return o(this.prefix)},normalizeCurrent:function(t){var e=f.pathname,i=t.root;return!(!t.pushState||i===e)&&(this.replaceLocation(i+this.prefix+r(i,e)),!0)}}),b=l.Observable.extend({start:function(e){if(e=e||{},this.bind([c,h,u],e),!this._started){this._started=!0,e.root=e.root||"/";var i,n=this.createAdapter(e);n.normalizeCurrent(e)||(i=n.current(),t.extend(this,{adapter:n,root:e.root,historyLength:n.length(),current:i,locations:[i]}),n.change(t.proxy(this,"_checkUrl")))}},createAdapter:function(t){return d.pushState&&t.pushState?new w(t.root):new x(t.hashBang)},stop:function(){this._started&&(this.adapter.stop(),this.unbind(c),this._started=!1)},change:function(t){this.bind(c,t)},replace:function(t,e){this._navigate(t,e,function(e){e.replace(t),this.locations[this.locations.length-1]=this.current})},navigate:function(t,i){return"#:back"===t?(this.backCalled=!0,this.adapter.back(),e):(this._navigate(t,i,function(e){e.navigate(t),this.locations.push(this.current)}),e)},_navigate:function(t,i,n){var o=this.adapter;return t=o.normalize(t),this.current===t||this.current===decodeURIComponent(t)?(this.trigger(u),e):(!i&&this.trigger(c,{url:t,decode:!1})||(this.current=t,n.call(this,o),this.historyLength=o.length()),e)},_checkUrl:function(){var t=this.adapter,i=t.current(),n=t.length(),o=this.historyLength===n,r=i===this.locations[this.locations.length-2]&&o,s=this.backCalled,a=this.current;return null===i||this.current===i||this.current===decodeURIComponent(i)||(this.historyLength=n,this.backCalled=!1,this.current=i,r&&this.trigger("back",{url:a,to:i})?(t.forward(),this.current=a,e):this.trigger(c,{url:i,backButtonPressed:!s})?(r?t.forward():(t.back(),this.historyLength--),this.current=a,e):(r?this.locations.pop():this.locations.push(i),e))}});l.History=b,l.History.HistoryAdapter=y,l.History.HashAdapter=x,l.History.PushStateAdapter=w,l.absoluteURL=i,l.history=new b}(window.kendo.jQuery),function(){function t(t,e){return e?t:"([^/]+)"}function e(e,i){return RegExp("^"+e.replace(p,"\\$&").replace(u,"(?:$1)?").replace(d,t).replace(f,"(.*?)")+"$",i?"i":"")}function i(t){return t.replace(/(\?.*)|(#.*)/g,"")}var n=window.kendo,o=n.history,r=n.Observable,s="init",a="routeMissing",l="change",c="back",h="same",u=/\((.*?)\)/g,d=/(\(\?)?:\w+/g,f=/\*\w+/g,p=/[\-{}\[\]+?.,\\\^$|#\s]/g,g=n.Class.extend({init:function(t,i,n){t instanceof RegExp||(t=e(t,n)),this.route=t,this._callback=i},callback:function(t,e,o){var r,s,a=0,l=n.parseQueryStringParams(t);if(l._back=e,t=i(t),r=this.route.exec(t).slice(1),s=r.length,o)for(;a<s;a++)void 0!==r[a]&&(r[a]=decodeURIComponent(r[a]));r.push(l),this._callback.apply(null,r)},worksWith:function(t,e,n){return!!this.route.test(i(t))&&(this.callback(t,e,n),!0)}}),m=r.extend({init:function(t){t||(t={}),r.fn.init.call(this),this.routes=[],this.pushState=t.pushState,this.hashBang=t.hashBang,this.root=t.root,this.ignoreCase=t.ignoreCase!==!1,this.bind([s,a,l,h],t)},destroy:function(){o.unbind(l,this._urlChangedProxy),o.unbind(h,this._sameProxy),o.unbind(c,this._backProxy),this.unbind()},start:function(){var t,e=this,i=function(){e._same()},n=function(t){e._back(t)},r=function(t){e._urlChanged(t)};o.start({same:i,change:r,back:n,pushState:e.pushState,hashBang:e.hashBang,root:e.root}),t={url:o.current||"/",preventDefault:$.noop},e.trigger(s,t)||e._urlChanged(t),this._urlChangedProxy=r,this._backProxy=n},route:function(t,e){this.routes.push(new g(t,e,this.ignoreCase))},navigate:function(t,e){n.history.navigate(t,e)},replace:function(t,e){n.history.replace(t,e)},_back:function(t){this.trigger(c,{url:t.url,to:t.to})&&t.preventDefault()},_same:function(){this.trigger(h)},_urlChanged:function(t){var e,i,o,r,s=t.url,c=void 0===t.decode,h=t.backButtonPressed;if(s||(s="/"),this.trigger(l,{url:t.url,params:n.parseQueryStringParams(t.url),backButtonPressed:h}))return void t.preventDefault();for(e=0,i=this.routes,r=i.length;e<r;e++)if(o=i[e],o.worksWith(s,h,c))return;this.trigger(a,{url:s,params:n.parseQueryStringParams(s),backButtonPressed:h})&&t.preventDefault()}});n.Router=m}(),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.data.odata.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(n,r){var l,c,h,u,d,f,p,g,m=[],v=n.logic||"and",_=n.filters;for(l=0,c=_.length;l<c;l++)n=_[l],h=n.field,p=n.value,f=n.operator,n.filters?n=i(n,r):(g=n.ignoreCase,h=h.replace(/\./g,"/"),n=s[f],r&&(n=a[f]),"isnull"===f||"isnotnull"===f?n=o.format("{0} {1} null",h,n):"isempty"===f||"isnotempty"===f?n=o.format("{0} {1} ''",h,n):n&&p!==e&&(u=t.type(p),"string"===u?(d="'{1}'",p=p.replace(/'/g,"''"),g===!0&&(h="tolower("+h+")")):"date"===u?r?(d="{1:yyyy-MM-ddTHH:mm:ss+00:00}",p=o.timezone.apply(p,"Etc/UTC")):d="datetime'{1:yyyy-MM-ddTHH:mm:ss}'":d="{1}",n.length>3?"substringof"!==n?d="{0}({2},"+d+")":(d="{0}("+d+",{2})","doesnotcontain"===f&&(r?(d="{0}({2},'{1}') eq -1",n="indexof"):d+=" eq false")):d="{2} {0} "+d,n=o.format(d,n,p,h))),m.push(n);return n=m.join(" "+v+" "),m.length>1&&(n="("+n+")"),n}function n(t){for(var e in t)0===e.indexOf("@odata")&&delete t[e]}var o=window.kendo,r=t.extend,s={eq:"eq",neq:"ne",gt:"gt",gte:"ge",lt:"lt",lte:"le",contains:"substringof",doesnotcontain:"substringof",endswith:"endswith",startswith:"startswith",isnull:"eq",isnotnull:"ne",isempty:"eq",isnotempty:"ne"},a=r({},s,{contains:"contains"}),l={pageSize:t.noop,page:t.noop,filter:function(t,e,n){e&&(e=i(e,n),e&&(t.$filter=e))},sort:function(e,i){var n=t.map(i,function(t){var e=t.field.replace(/\./g,"/");return"desc"===t.dir&&(e+=" desc"),e}).join(",");n&&(e.$orderby=n)},skip:function(t,e){e&&(t.$skip=e)},take:function(t,e){e&&(t.$top=e)}},c={read:{dataType:"jsonp"}};r(!0,o.data,{schemas:{odata:{type:"json",data:function(t){return t.d.results||[t.d]},total:"d.__count"}},transports:{odata:{read:{cache:!0,dataType:"jsonp",jsonp:"$callback"},update:{cache:!0,dataType:"json",contentType:"application/json",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(t,e,i){var n,r,s,a;if(t=t||{},e=e||"read",a=(this.options||c)[e],a=a?a.dataType:"json","read"===e){n={$inlinecount:"allpages"},"json"!=a&&(n.$format="json");for(s in t)l[s]?l[s](n,t[s],i):n[s]=t[s]}else{if("json"!==a)throw Error("Only json dataType can be used for "+e+" operation.");if("destroy"!==e){for(s in t)r=t[s],"number"==typeof r&&(t[s]=r+"");n=o.stringify(t)}}return n}}}}),r(!0,o.data,{schemas:{"odata-v4":{type:"json",data:function(e){return e=t.extend({},e),n(e),e.value?e.value:[e]},total:function(t){return t["@odata.count"]}}},transports:{"odata-v4":{read:{cache:!0,dataType:"json"},update:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"PUT"},create:{cache:!0,dataType:"json",contentType:"application/json;IEEE754Compatible=true",type:"POST"},destroy:{cache:!0,dataType:"json",type:"DELETE"},parameterMap:function(t,e){var i=o.data.transports.odata.parameterMap(t,e,!0);return"read"==e&&(i.$count=!0,delete i.$inlinecount),i}}}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.data.xml.min",["kendo.core.min"],t)}(function(){return function(t,e){var i=window.kendo,n=t.isArray,o=t.isPlainObject,r=t.map,s=t.each,a=t.extend,l=i.getter,c=i.Class,h=c.extend({init:function(e){var l,c,h,u,d=this,f=e.total,p=e.model,g=e.parse,m=e.errors,v=e.serialize,_=e.data;p&&(o(p)&&(l=e.modelBase||i.data.Model,p.fields&&s(p.fields,function(e,i){o(i)&&i.field?t.isFunction(i.field)||(i=a(i,{field:d.getter(i.field)})):i={field:d.getter(i)},p.fields[e]=i}),c=p.id,c&&(h={},h[d.xpathToMember(c,!0)]={field:d.getter(c)},p.fields=a(h,p.fields),p.id=d.xpathToMember(c)),p=l.define(p)),d.model=p),f&&("string"==typeof f?(f=d.getter(f),d.total=function(t){return parseInt(f(t),10)}):"function"==typeof f&&(d.total=f)),m&&("string"==typeof m?(m=d.getter(m),d.errors=function(t){return m(t)||null}):"function"==typeof m&&(d.errors=m)),_&&("string"==typeof _?(_=d.xpathToMember(_),d.data=function(t){var e,i=d.evaluate(t,_);return i=n(i)?i:[i],d.model&&p.fields?(e=new d.model,r(i,function(t){if(t){var i,n={};for(i in p.fields)n[i]=e._parse(i,p.fields[i].field(t));return n}})):i}):"function"==typeof _&&(d.data=_)),"function"==typeof g&&(u=d.parse,d.parse=function(t){var e=g.call(d,t);return u.call(d,e)}),"function"==typeof v&&(d.serialize=v)},total:function(t){return this.data(t).length},errors:function(t){return t?t.errors:null},serialize:function(t){return t},parseDOM:function(t){var i,o,r,s,a,l,c,h={},u=t.attributes,d=u.length;for(c=0;c<d;c++)l=u[c],h["@"+l.nodeName]=l.nodeValue;for(o=t.firstChild;o;o=o.nextSibling)r=o.nodeType,3===r||4===r?h["#text"]=o.nodeValue:1===r&&(i=this.parseDOM(o),s=o.nodeName,a=h[s],n(a)?a.push(i):a=a!==e?[a,i]:i,h[s]=a);return h},evaluate:function(t,e){for(var i,o,r,s,a,l=e.split(".");i=l.shift();)if(t=t[i],n(t)){for(o=[],e=l.join("."),a=0,r=t.length;a<r;a++)s=this.evaluate(t[a],e),s=n(s)?s:[s],o.push.apply(o,s);return o}return t},parse:function(e){var i,n,o={};return i=e.documentElement||t.parseXML(e).documentElement,n=this.parseDOM(i),o[i.nodeName]=n,o},xpathToMember:function(t,e){return t?(t=t.replace(/^\//,"").replace(/\//g,"."),t.indexOf("@")>=0?t.replace(/\.?(@.*)/,e?"$1":'["$1"]'):t.indexOf("text()")>=0?t.replace(/(\.?text\(\))/,e?"#text":'["#text"]'):t):""},getter:function(t){return l(this.xpathToMember(t),!0)}});t.extend(!0,i.data,{XmlDataReader:h,readers:{xml:h}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.data.min",["kendo.core.min","kendo.data.odata.min","kendo.data.xml.min"],t)}(function(){return function(t,e){function i(t,e,i,n){return function(o){var r,s={};for(r in o)s[r]=o[r];s.field=n?i+"."+o.field:i,e==Pt&&t._notifyChange&&t._notifyChange(s),t.trigger(e,s)}}function n(e,i){if(e===i)return!0;var o,r=t.type(e),s=t.type(i);if(r!==s)return!1;if("date"===r)return e.getTime()===i.getTime();if("object"!==r&&"array"!==r)return!1;for(o in e)if(!n(e[o],i[o]))return!1;return!0}function o(t,e){var i,n;for(n in t){if(i=t[n],ut(i)&&i.field&&i.field===e)return i;if(i===e)return i}return null}function r(t){this.data=t||[]}function s(t,i){if(t){var n=typeof t===bt?{field:t,dir:i}:t,o=ft(n)?n:n!==e?[n]:[];return pt(o,function(t){return!!t.dir})}}function a(t){var e,i,n,o,r=t.filters;if(r)for(e=0,i=r.length;e<i;e++)n=r[e],o=n.operator,o&&typeof o===bt&&(n.operator=K[o.toLowerCase()]||o),a(n)}function l(t){if(t&&!dt(t))return!ft(t)&&t.filters||(t={logic:"and",filters:ft(t)?t:[t]}),a(t),t}function c(t,e){return!t.logic&&!e.logic&&(t.field===e.field&&t.value===e.value&&t.operator===e.operator)}function h(t){return t=t||{},dt(t)?{logic:"and",filters:[]}:l(t)}function u(t,e){return e.logic||t.field>e.field?1:t.field<e.field?-1:0}function d(t,e){var i,n,o,r,s;if(t=h(t),e=h(e),t.logic!==e.logic)return!1;if(o=(t.filters||[]).slice(),r=(e.filters||[]).slice(),o.length!==r.length)return!1;for(o=o.sort(u),r=r.sort(u),s=0;s<o.length;s++)if(i=o[s],n=r[s],i.logic&&n.logic){if(!d(i,n))return!1}else if(!c(i,n))return!1;return!0}function f(t){return ft(t)?t:[t]}function p(t,i){var n=typeof t===bt?{field:t,dir:i}:t,o=ft(n)?n:n!==e?[n]:[];return U(o,function(t){return{field:t.field,dir:t.dir||"asc",aggregates:t.aggregates}})}function g(t,e){return t&&t.getTime&&e&&e.getTime?t.getTime()===e.getTime():t===e}function m(t,e,i,n,o,r){var s,a,l,c,h;for(e=e||[],c=e.length,s=0;s<c;s++)a=e[s],l=a.aggregate,h=a.field,t[h]=t[h]||{},r[h]=r[h]||{},r[h][l]=r[h][l]||{},t[h][l]=Z[l.toLowerCase()](t[h][l],i,_t.accessor(h),n,o,r[h][l])}function v(t){return"number"==typeof t&&!isNaN(t)}function _(t){return t&&t.getTime}function y(t){var e,i=t.length,n=Array(i);for(e=0;e<i;e++)n[e]=t[e].toJSON();return n}function w(t,e,i,n,o){var r,s,a,l,c,h={};for(l=0,c=t.length;l<c;l++){r=t[l];for(s in e)a=o[s],a&&a!==s&&(h[a]||(h[a]=_t.setter(a)),h[a](r,e[s](r)),delete r[s])}}function x(t,e,i,n,o){var r,s,a,l,c;for(l=0,c=t.length;l<c;l++){r=t[l];for(s in e)r[s]=i._parse(s,e[s](r)),a=o[s],a&&a!==s&&delete r[a]}}function b(t,e,i,n,o){var r,s,a,l;for(s=0,l=t.length;s<l;s++)r=t[s],a=n[r.field],a&&a!=r.field&&(r.field=a),r.value=i._parse(r.field,r.value),r.hasSubgroups?b(r.items,e,i,n,o):x(r.items,e,i,n,o)}function k(t,e,i,n,o,r){return function(s){return s=t(s),s&&!dt(n)&&("[object Array]"===$t.call(s)||s instanceof Zt||(s=[s]),i(s,n,new e,o,r)),s||[]}}function C(t,e,i,n){for(var o,r,s,a=0;e.length&&n&&(o=e[a],r=o.items,s=r.length,t&&t.field===o.field&&t.value===o.value?(t.hasSubgroups&&t.items.length?C(t.items[t.items.length-1],o.items,i,n):(r=r.slice(i,i+n),t.items=t.items.concat(r)),e.splice(a--,1)):o.hasSubgroups&&r.length?(C(o,r,i,n),o.items.length||e.splice(a--,1)):(r=r.slice(i,i+n),o.items=r,o.items.length||e.splice(a--,1)),0===r.length?i-=s:(i=0,n-=r.length),!(++a>=e.length)););a<e.length&&e.splice(a,e.length-a)}function S(t){var e,i,n,o,r,s=[];for(e=0,i=t.length;e<i;e++)if(r=t.at(e),r.hasSubgroups)s=s.concat(S(r.items));else for(n=r.items,o=0;o<n.length;o++)s.push(n.at(o));return s}function T(t,e){var i,n,o;if(e)for(i=0,n=t.length;i<n;i++)o=t.at(i),o.hasSubgroups?T(o.items,e):o.items=new j(o.items,e)}function A(t,e){for(var i=0,n=t.length;i<n;i++)if(t[i].hasSubgroups){if(A(t[i].items,e))return!0}else if(e(t[i].items,t[i]))return!0}function P(t,e,i,n){for(var o=0;o<t.length&&t[o].data!==e&&!D(t[o].data,i,n);o++);}function D(t,e,i){for(var n=0,o=t.length;n<o;n++){if(t[n]&&t[n].hasSubgroups)return D(t[n].items,e,i);if(t[n]===e||t[n]===i)return t[n]=i,!0}}function M(t,i,n,o,r){var s,a,l,c;for(s=0,a=t.length;s<a;s++)if(l=t[s],l&&!(l instanceof o))if(l.hasSubgroups===e||r){for(c=0;c<i.length;c++)if(i[c]===l){t[s]=i.at(c),P(n,i,l,t[s]);break}}else M(l.items,i,n,o,r)}function E(t,e){var i,n,o;for(i=0,n=t.length;i<n;i++)if(o=t.at(i),o.uid==e.uid)return t.splice(i,1),o}function I(t,e){return e?z(t,function(t){return t.uid&&t.uid==e.uid||t[e.idField]===e.id&&e.id!==e._defaultId}):-1}function B(t,e){return e?z(t,function(t){return t.uid==e.uid}):-1}function z(t,e){var i,n;for(i=0,n=t.length;i<n;i++)if(e(t[i]))return i;return-1}function L(t,e){var i,n;return t&&!dt(t)?(i=t[e],n=ut(i)?i.from||i.field||e:t[e]||e,yt(n)?e:n):e}function R(t,e){var i,n,o,r={};for(o in t)"filters"!==o&&(r[o]=t[o]);if(t.filters)for(r.filters=[],i=0,n=t.filters.length;i<n;i++)r.filters[i]=R(t.filters[i],e);else r.field=L(e.fields,r.field);return r}function O(t,e){var i,n,o,r,s,a=[];for(i=0,n=t.length;i<n;i++){o={},r=t[i];for(s in r)o[s]=r[s];o.field=L(e.fields,o.field),o.aggregates&&ft(o.aggregates)&&(o.aggregates=O(o.aggregates,e)),a.push(o)}return a}function V(e,i){var n,o,r,s,a,l,c,h,u,d;for(e=t(e)[0],n=e.options,o=i[0],r=i[1],s=[],a=0,l=n.length;a<l;a++)u={},h=n[a],c=h.parentNode,c===e&&(c=null),h.disabled||c&&c.disabled||(c&&(u.optgroup=c.label),u[o.field]=h.text,d=h.attributes.value,d=d&&d.specified?h.value:h.text,u[r.field]=d,s.push(u));return s}function F(e,i){var n,o,r,s,a,l,c,h=t(e)[0].tBodies[0],u=h?h.rows:[],d=i.length,f=[];for(n=0,o=u.length;n<o;n++){for(a={},c=!0,s=u[n].cells,r=0;r<d;r++)l=s[r],"th"!==l.nodeName.toLowerCase()&&(c=!1,a[i[r].field]=l.innerHTML);c||f.push(a)}return f}function N(t){return function(){var e=this._data,i=nt.fn[t].apply(this,Wt.call(arguments));return this._data!=e&&this._attachBubbleHandlers(),i}}function H(e,i){function n(t,e){return t.filter(e).add(t.find(e))}var o,r,s,a,l,c,h,u,d=t(e).children(),f=[],p=i[0].field,g=i[1]&&i[1].field,m=i[2]&&i[2].field,v=i[3]&&i[3].field;for(o=0,r=d.length;o<r;o++)s={_loaded:!0},a=d.eq(o),c=a[0].firstChild,u=a.children(),e=u.filter("ul"),u=u.filter(":not(ul)"),l=a.attr("data-id"),l&&(s.id=l),c&&(s[p]=3==c.nodeType?c.nodeValue:u.text()),g&&(s[g]=n(u,"a").attr("href")),v&&(s[v]=n(u,"img").attr("src")),m&&(h=n(u,".k-sprite").prop("className"),s[m]=h&&t.trim(h.replace("k-sprite",""))),e.length&&(s.items=H(e.eq(0),i)),"true"==a.attr("data-hasChildren")&&(s.hasChildren=!0),f.push(s);return f}var U,j,G,W,q,$,Y,X,Q,K,Z,J,tt,et,it,nt,ot,rt,st,at,lt,ct=t.extend,ht=t.proxy,ut=t.isPlainObject,dt=t.isEmptyObject,ft=t.isArray,pt=t.grep,gt=t.ajax,mt=t.each,vt=t.noop,_t=window.kendo,yt=_t.isFunction,wt=_t.Observable,xt=_t.Class,bt="string",kt="function",Ct="create",St="read",Tt="update",At="destroy",Pt="change",Dt="sync",Mt="get",Et="error",It="requestStart",Bt="progress",zt="requestEnd",Lt=[Ct,St,Tt,At],Rt=function(t){return t},Ot=_t.getter,Vt=_t.stringify,Ft=Math,Nt=[].push,Ht=[].join,Ut=[].pop,jt=[].splice,Gt=[].shift,Wt=[].slice,qt=[].unshift,$t={}.toString,Yt=_t.support.stableSort,Xt=/^\/Date\((.*?)\)\/$/,Qt=/(\r+|\n+)/g,Kt=/(?=['\\])/g,Zt=wt.extend({init:function(t,e){var i=this;i.type=e||G,wt.fn.init.call(i),i.length=t.length,i.wrapAll(t,i)},at:function(t){return this[t]},toJSON:function(){var t,e,i=this.length,n=Array(i);for(t=0;t<i;t++)e=this[t],e instanceof G&&(e=e.toJSON()),n[t]=e;return n},parent:vt,wrapAll:function(t,e){var i,n,o=this,r=function(){return o};for(e=e||[],i=0,n=t.length;i<n;i++)e[i]=o.wrap(t[i],r);return e},wrap:function(t,e){var i,n=this;return null!==t&&"[object Object]"===$t.call(t)&&(i=t instanceof n.type||t instanceof $,i||(t=t instanceof G?t.toJSON():t,t=new n.type(t)),t.parent=e,t.bind(Pt,function(t){n.trigger(Pt,{field:t.field,node:t.node,index:t.index,items:t.items||[this],action:t.node?t.action||"itemloaded":"itemchange"})})),t},push:function(){var t,e=this.length,i=this.wrapAll(arguments);return t=Nt.apply(this,i),this.trigger(Pt,{action:"add",index:e,items:i}),t},slice:Wt,sort:[].sort,join:Ht,pop:function(){var t=this.length,e=Ut.apply(this);return t&&this.trigger(Pt,{action:"remove",index:t-1,items:[e]}),e},splice:function(t,e,i){var n,o,r,s=this.wrapAll(Wt.call(arguments,2));if(n=jt.apply(this,[t,e].concat(s)),n.length)for(this.trigger(Pt,{action:"remove",index:t,items:n}),o=0,r=n.length;o<r;o++)n[o]&&n[o].children&&n[o].unbind(Pt);return i&&this.trigger(Pt,{action:"add",index:t,items:s}),n},shift:function(){var t=this.length,e=Gt.apply(this);return t&&this.trigger(Pt,{action:"remove",index:0,items:[e]}),e},unshift:function(){var t,e=this.wrapAll(arguments);return t=qt.apply(this,e),this.trigger(Pt,{action:"add",index:0,items:e}),t},indexOf:function(t){var e,i,n=this;for(e=0,i=n.length;e<i;e++)if(n[e]===t)return e;return-1},forEach:function(t){for(var e=0,i=this.length;e<i;e++)t(this[e],e,this)},map:function(t){for(var e=0,i=[],n=this.length;e<n;e++)i[e]=t(this[e],e,this);return i},reduce:function(t){var e,i=0,n=this.length;for(2==arguments.length?e=arguments[1]:i<n&&(e=this[i++]);i<n;i++)e=t(e,this[i],i,this);return e},reduceRight:function(t){var e,i=this.length-1;for(2==arguments.length?e=arguments[1]:i>0&&(e=this[i--]);i>=0;i--)e=t(e,this[i],i,this);return e},filter:function(t){for(var e,i=0,n=[],o=this.length;i<o;i++)e=this[i],t(e,i,this)&&(n[n.length]=e);return n},find:function(t){for(var e,i=0,n=this.length;i<n;i++)if(e=this[i],t(e,i,this))return e},every:function(t){for(var e,i=0,n=this.length;i<n;i++)if(e=this[i],!t(e,i,this))return!1;return!0},some:function(t){for(var e,i=0,n=this.length;i<n;i++)if(e=this[i],t(e,i,this))return!0;return!1},remove:function(t){var e=this.indexOf(t);e!==-1&&this.splice(e,1)},empty:function(){this.splice(0,this.length)}});"undefined"!=typeof Symbol&&Symbol.iterator&&!Zt.prototype[Symbol.iterator]&&(Zt.prototype[Symbol.iterator]=[][Symbol.iterator]),j=Zt.extend({init:function(t,e){wt.fn.init.call(this),this.type=e||G;for(var i=0;i<t.length;i++)this[i]=t[i];this.length=i,this._parent=ht(function(){return this},this)},at:function(t){var e=this[t];return e instanceof this.type?e.parent=this._parent:e=this[t]=this.wrap(e,this._parent),e}}),G=wt.extend({init:function(t){var e,i,n=this,o=function(){return n};wt.fn.init.call(this),this._handlers={};for(i in t)e=t[i],"object"==typeof e&&e&&!e.getTime&&"_"!=i.charAt(0)&&(e=n.wrap(e,i,o)),n[i]=e;n.uid=_t.guid()},shouldSerialize:function(t){return this.hasOwnProperty(t)&&"_handlers"!==t&&"_events"!==t&&typeof this[t]!==kt&&"uid"!==t},forEach:function(t){for(var e in this)this.shouldSerialize(e)&&t(this[e],e)},toJSON:function(){var t,e,i={};for(e in this)this.shouldSerialize(e)&&(t=this[e],(t instanceof G||t instanceof Zt)&&(t=t.toJSON()),i[e]=t);return i},get:function(t){var e,i=this;return i.trigger(Mt,{field:t}),e="this"===t?i:_t.getter(t,!0)(i)},_set:function(t,e){var i,n,o,r=this,s=t.indexOf(".")>=0;if(s)for(i=t.split("."),n="";i.length>1;){if(n+=i.shift(),o=_t.getter(n,!0)(r),o instanceof G)return o.set(i.join("."),e),s;n+="."}return _t.setter(t)(r,e),s},set:function(t,e){var i=this,n=!1,o=t.indexOf(".")>=0,r=_t.getter(t,!0)(i);return r!==e&&(r instanceof wt&&this._handlers[t]&&(this._handlers[t].get&&r.unbind(Mt,this._handlers[t].get),r.unbind(Pt,this._handlers[t].change)),n=i.trigger("set",{field:t,value:e}),n||(o||(e=i.wrap(e,t,function(){return i})),(!i._set(t,e)||t.indexOf("(")>=0||t.indexOf("[")>=0)&&i.trigger(Pt,{field:t}))),n},parent:vt,wrap:function(t,e,n){var o,r,s,a,l=this,c=$t.call(t);return null==t||"[object Object]"!==c&&"[object Array]"!==c||(s=t instanceof Zt,a=t instanceof nt,"[object Object]"!==c||a||s?("[object Array]"===c||s||a)&&(s||a||(t=new Zt(t)),r=i(l,Pt,e,!1),t.bind(Pt,r),l._handlers[e]={change:r}):(t instanceof G||(t=new G(t)),o=i(l,Mt,e,!0),t.bind(Mt,o),r=i(l,Pt,e,!0),t.bind(Pt,r),l._handlers[e]={get:o,change:r}),t.parent=n),t}}),W={number:function(t){return _t.parseFloat(t)},date:function(t){return _t.parseDate(t)},"boolean":function(t){return typeof t===bt?"true"===t.toLowerCase():null!=t?!!t:t},string:function(t){return null!=t?t+"":t},"default":function(t){return t}},q={string:"",number:0,date:new Date,"boolean":!1,"default":""},$=G.extend({init:function(i){var n,o,r=this;if((!i||t.isEmptyObject(i))&&(i=t.extend({},r.defaults,i),r._initializers))for(n=0;n<r._initializers.length;n++)o=r._initializers[n],i[o]=r.defaults[o]();G.fn.init.call(r,i),r.dirty=!1,r.idField&&(r.id=r.get(r.idField),r.id===e&&(r.id=r._defaultId))},shouldSerialize:function(t){return G.fn.shouldSerialize.call(this,t)&&"uid"!==t&&!("id"!==this.idField&&"id"===t)&&"dirty"!==t&&"_accessors"!==t},_parse:function(t,e){var i,n=this,r=t,s=n.fields||{};return t=s[t],t||(t=o(s,r)),t&&(i=t.parse,!i&&t.type&&(i=W[t.type.toLowerCase()])),i?i(e):e},_notifyChange:function(t){var e=t.action;"add"!=e&&"remove"!=e||(this.dirty=!0)},editable:function(t){return t=(this.fields||{})[t],!t||t.editable!==!1},set:function(t,e,i){var o=this,r=o.dirty;o.editable(t)&&(e=o._parse(t,e),n(e,o.get(t))||(o.dirty=!0,G.fn.set.call(o,t,e,i)&&!r&&(o.dirty=r)))},accept:function(t){var e,i,n=this,o=function(){return n};for(e in t)i=t[e],"_"!=e.charAt(0)&&(i=n.wrap(t[e],e,o)),n._set(e,i);n.idField&&(n.id=n.get(n.idField)),n.dirty=!1},isNew:function(){return this.id===this._defaultId}}),$.define=function(t,i){i===e&&(i=t,t=$);var n,o,r,s,a,l,c,h,u=ct({defaults:{}},i),d={},f=u.id,p=[];if(f&&(u.idField=f),u.id&&delete u.id,f&&(u.defaults[f]=u._defaultId=""),"[object Array]"===$t.call(u.fields)){for(l=0,c=u.fields.length;l<c;l++)r=u.fields[l],typeof r===bt?d[r]={}:r.field&&(d[r.field]=r);u.fields=d}for(o in u.fields)r=u.fields[o],s=r.type||"default",a=null,h=o,o=typeof r.field===bt?r.field:o,r.nullable||(a=u.defaults[h!==o?h:o]=r.defaultValue!==e?r.defaultValue:q[s.toLowerCase()],"function"==typeof a&&p.push(o)),i.id===o&&(u._defaultId=a),u.defaults[h!==o?h:o]=a,r.parse=r.parse||W[s];return p.length>0&&(u._initializers=p),n=t.extend(u),n.define=function(t){return $.define(n,t)},u.fields&&(n.fields=u.fields,n.idField=u.idField),n},Y={selector:function(t){return yt(t)?t:Ot(t)},compare:function(t){var e=this.selector(t);return function(t,i){return t=e(t),i=e(i),null==t&&null==i?0:null==t?-1:null==i?1:t.localeCompare?t.localeCompare(i):t>i?1:t<i?-1:0}},create:function(t){var e=t.compare||this.compare(t.field);return"desc"==t.dir?function(t,i){return e(i,t,!0)}:e},combine:function(t){return function(e,i){var n,o,r=t[0](e,i);for(n=1,o=t.length;n<o;n++)r=r||t[n](e,i);return r}}},X=ct({},Y,{asc:function(t){var e=this.selector(t);return function(t,i){var n=e(t),o=e(i);return n&&n.getTime&&o&&o.getTime&&(n=n.getTime(),o=o.getTime()),n===o?t.__position-i.__position:null==n?-1:null==o?1:n.localeCompare?n.localeCompare(o):n>o?1:-1}},desc:function(t){var e=this.selector(t);return function(t,i){var n=e(t),o=e(i);return n&&n.getTime&&o&&o.getTime&&(n=n.getTime(),o=o.getTime()),n===o?t.__position-i.__position:null==n?1:null==o?-1:o.localeCompare?o.localeCompare(n):n<o?1:-1}},create:function(t){return this[t.dir](t.field)}}),U=function(t,e){var i,n=t.length,o=Array(n);for(i=0;i<n;i++)o[i]=e(t[i],i,t);return o},Q=function(){function t(t){return t.replace(Kt,"\\").replace(Qt,"")}function e(e,i,n,o){var r;return null!=n&&(typeof n===bt&&(n=t(n),r=Xt.exec(n),r?n=new Date((+r[1])):o?(n="'"+n.toLowerCase()+"'",i="(("+i+" || '')+'').toLowerCase()"):n="'"+n+"'"),n.getTime&&(i="("+i+"&&"+i+".getTime?"+i+".getTime():"+i+")",n=n.getTime())),i+" "+e+" "+n}return{quote:function(e){return e&&e.getTime?"new Date("+e.getTime()+")":"string"==typeof e?"'"+t(e)+"'":""+e},eq:function(t,i,n){return e("==",t,i,n)},neq:function(t,i,n){return e("!=",t,i,n)},gt:function(t,i,n){return e(">",t,i,n)},gte:function(t,i,n){return e(">=",t,i,n);
},lt:function(t,i,n){return e("<",t,i,n)},lte:function(t,i,n){return e("<=",t,i,n)},startswith:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".lastIndexOf('"+i+"', 0) == 0"},doesnotstartwith:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".lastIndexOf('"+i+"', 0) == -1"},endswith:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".indexOf('"+i+"', "+e+".length - "+(i||"").length+") >= 0"},doesnotendwith:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".indexOf('"+i+"', "+e+".length - "+(i||"").length+") < 0"},contains:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".indexOf('"+i+"') >= 0"},doesnotcontain:function(e,i,n){return n&&(e="("+e+" || '').toLowerCase()",i&&(i=i.toLowerCase())),i&&(i=t(i)),e+".indexOf('"+i+"') == -1"},isempty:function(t){return t+" === ''"},isnotempty:function(t){return t+" !== ''"},isnull:function(t){return"("+t+" === null || "+t+" === undefined)"},isnotnull:function(t){return"("+t+" !== null && "+t+" !== undefined)"}}}(),r.filterExpr=function(t){var i,n,o,s,a,l,c=[],h={and:" && ",or:" || "},u=[],d=[],f=t.filters;for(i=0,n=f.length;i<n;i++)o=f[i],a=o.field,l=o.operator,o.filters?(s=r.filterExpr(o),o=s.expression.replace(/__o\[(\d+)\]/g,function(t,e){return e=+e,"__o["+(d.length+e)+"]"}).replace(/__f\[(\d+)\]/g,function(t,e){return e=+e,"__f["+(u.length+e)+"]"}),d.push.apply(d,s.operators),u.push.apply(u,s.fields)):(typeof a===kt?(s="__f["+u.length+"](d)",u.push(a)):s=_t.expr(a),typeof l===kt?(o="__o["+d.length+"]("+s+", "+Q.quote(o.value)+")",d.push(l)):o=Q[(l||"eq").toLowerCase()](s,o.value,o.ignoreCase===e||o.ignoreCase)),c.push(o);return{expression:"("+c.join(h[t.logic])+")",fields:u,operators:d}},K={"==":"eq",equals:"eq",isequalto:"eq",equalto:"eq",equal:"eq","!=":"neq",ne:"neq",notequals:"neq",isnotequalto:"neq",notequalto:"neq",notequal:"neq","<":"lt",islessthan:"lt",lessthan:"lt",less:"lt","<=":"lte",le:"lte",islessthanorequalto:"lte",lessthanequal:"lte",">":"gt",isgreaterthan:"gt",greaterthan:"gt",greater:"gt",">=":"gte",isgreaterthanorequalto:"gte",greaterthanequal:"gte",ge:"gte",notsubstringof:"doesnotcontain",isnull:"isnull",isempty:"isempty",isnotempty:"isnotempty"},r.normalizeFilter=l,r.compareFilters=d,r.prototype={toArray:function(){return this.data},range:function(t,e){return new r(this.data.slice(t,t+e))},skip:function(t){return new r(this.data.slice(t))},take:function(t){return new r(this.data.slice(0,t))},select:function(t){return new r(U(this.data,t))},order:function(t,e){var i={dir:e};return t&&(t.compare?i.compare=t.compare:i.field=t),new r(this.data.slice(0).sort(Y.create(i)))},orderBy:function(t){return this.order(t,"asc")},orderByDescending:function(t){return this.order(t,"desc")},sort:function(t,e,i){var n,o,r=s(t,e),a=[];if(i=i||Y,r.length){for(n=0,o=r.length;n<o;n++)a.push(i.create(r[n]));return this.orderBy({compare:i.combine(a)})}return this},filter:function(t){var e,i,n,o,s,a,c,h,u=this.data,d=[];if(t=l(t),!t||0===t.filters.length)return this;for(o=r.filterExpr(t),a=o.fields,c=o.operators,s=h=Function("d, __f, __o","return "+o.expression),(a.length||c.length)&&(h=function(t){return s(t,a,c)}),e=0,n=u.length;e<n;e++)i=u[e],h(i)&&d.push(i);return new r(d)},group:function(t,e){t=p(t||[]),e=e||this.data;var i,n=this,o=new r(n.data);return t.length>0&&(i=t[0],o=o.groupBy(i).select(function(n){var o=new r(e).filter([{field:n.field,operator:"eq",value:n.value,ignoreCase:!1}]);return{field:n.field,value:n.value,items:t.length>1?new r(n.items).group(t.slice(1),o.toArray()).toArray():n.items,hasSubgroups:t.length>1,aggregates:o.aggregate(i.aggregates)}})),o},groupBy:function(t){if(dt(t)||!this.data.length)return new r([]);var e,i,n,o,s=t.field,a=this._sortForGrouping(s,t.dir||"asc"),l=_t.accessor(s),c=l.get(a[0],s),h={field:s,value:c,items:[]},u=[h];for(n=0,o=a.length;n<o;n++)e=a[n],i=l.get(e,s),g(c,i)||(c=i,h={field:s,value:c,items:[]},u.push(h)),h.items.push(e);return new r(u)},_sortForGrouping:function(t,e){var i,n,o=this.data;if(!Yt){for(i=0,n=o.length;i<n;i++)o[i].__position=i;for(o=new r(o).sort(t,e,X).toArray(),i=0,n=o.length;i<n;i++)delete o[i].__position;return o}return this.sort(t,e).toArray()},aggregate:function(t){var e,i,n={},o={};if(t&&t.length)for(e=0,i=this.data.length;e<i;e++)m(n,t,this.data[e],e,i,o);return n}},Z={sum:function(t,e,i){var n=i.get(e);return v(t)?v(n)&&(t+=n):t=n,t},count:function(t){return(t||0)+1},average:function(t,i,n,o,r,s){var a=n.get(i);return s.count===e&&(s.count=0),v(t)?v(a)&&(t+=a):t=a,v(a)&&s.count++,o==r-1&&v(t)&&(t/=s.count),t},max:function(t,e,i){var n=i.get(e);return v(t)||_(t)||(t=n),t<n&&(v(n)||_(n))&&(t=n),t},min:function(t,e,i){var n=i.get(e);return v(t)||_(t)||(t=n),t>n&&(v(n)||_(n))&&(t=n),t}},r.process=function(t,i){i=i||{};var n,o=new r(t),a=i.group,l=p(a||[]).concat(s(i.sort||[])),c=i.filterCallback,h=i.filter,u=i.skip,d=i.take;return h&&(o=o.filter(h),c&&(o=c(o)),n=o.toArray().length),l&&(o=o.sort(l),a&&(t=o.toArray())),u!==e&&d!==e&&(o=o.range(u,d)),a&&(o=o.group(a,t)),{total:n,data:o.toArray()}},J=xt.extend({init:function(t){this.data=t.data},read:function(t){t.success(this.data)},update:function(t){t.success(t.data)},create:function(t){t.success(t.data)},destroy:function(t){t.success(t.data)}}),tt=xt.extend({init:function(t){var e,i=this;t=i.options=ct({},i.options,t),mt(Lt,function(e,i){typeof t[i]===bt&&(t[i]={url:t[i]})}),i.cache=t.cache?et.create(t.cache):{find:vt,add:vt},e=t.parameterMap,yt(t.push)&&(i.push=t.push),i.push||(i.push=Rt),i.parameterMap=yt(e)?e:function(t){var i={};return mt(t,function(t,n){t in e&&(t=e[t],ut(t)&&(n=t.value(n),t=t.key)),i[t]=n}),i}},options:{parameterMap:Rt},create:function(t){return gt(this.setup(t,Ct))},read:function(i){var n,o,r,s=this,a=s.cache;i=s.setup(i,St),n=i.success||vt,o=i.error||vt,r=a.find(i.data),r!==e?n(r):(i.success=function(t){a.add(i.data,t),n(t)},t.ajax(i))},update:function(t){return gt(this.setup(t,Tt))},destroy:function(t){return gt(this.setup(t,At))},setup:function(t,e){t=t||{};var i,n=this,o=n.options[e],r=yt(o.data)?o.data(t.data):o.data;return t=ct(!0,{},o,t),i=ct(!0,{},r,t.data),t.data=n.parameterMap(i,e),yt(t.url)&&(t.url=t.url(i)),t}}),et=xt.extend({init:function(){this._store={}},add:function(t,i){t!==e&&(this._store[Vt(t)]=i)},find:function(t){return this._store[Vt(t)]},clear:function(){this._store={}},remove:function(t){delete this._store[Vt(t)]}}),et.create=function(t){var e={inmemory:function(){return new et}};return ut(t)&&yt(t.find)?t:t===!0?new et:e[t]()},it=xt.extend({init:function(t){var e,i,n,o,r,s,a,l,c,h,u,d,f,p=this;t=t||{};for(e in t)i=t[e],p[e]=typeof i===bt?Ot(i):i;o=t.modelBase||$,ut(p.model)&&(p.model=n=o.define(p.model)),r=ht(p.data,p),p._dataAccessFunction=r,p.model&&(s=ht(p.groups,p),a=ht(p.serialize,p),l={},c={},h={},u={},d=!1,n=p.model,n.fields&&(mt(n.fields,function(t,e){var i;f=t,ut(e)&&e.field?f=e.field:typeof e===bt&&(f=e),ut(e)&&e.from&&(i=e.from),d=d||i&&i!==t||f!==t,c[t]=Ot(i||f),h[t]=Ot(t),l[i||f]=t,u[t]=i||f}),!t.serialize&&d&&(p.serialize=k(a,n,w,h,l,u))),p._dataAccessFunction=r,p.data=k(r,n,x,c,l,u),p.groups=k(s,n,b,c,l,u))},errors:function(t){return t?t.errors:null},parse:Rt,data:Rt,total:function(t){return t.length},groups:Rt,aggregates:function(){return{}},serialize:function(t){return t}}),nt=wt.extend({init:function(t){var i,n,o,r=this;t&&(n=t.data),t=r.options=ct({},r.options,t),r._map={},r._prefetch={},r._data=[],r._pristineData=[],r._ranges=[],r._view=[],r._pristineTotal=0,r._destroyed=[],r._pageSize=t.pageSize,r._page=t.page||(t.pageSize?1:e),r._sort=s(t.sort),r._filter=l(t.filter),r._group=p(t.group),r._aggregate=t.aggregate,r._total=t.total,r._shouldDetachObservableParents=!0,wt.fn.init.call(r),r.transport=ot.create(t,n,r),yt(r.transport.push)&&r.transport.push({pushCreate:ht(r._pushCreate,r),pushUpdate:ht(r._pushUpdate,r),pushDestroy:ht(r._pushDestroy,r)}),null!=t.offlineStorage&&("string"==typeof t.offlineStorage?(o=t.offlineStorage,r._storage={getItem:function(){return JSON.parse(localStorage.getItem(o))},setItem:function(t){localStorage.setItem(o,Vt(r.reader.serialize(t)))}}):r._storage=t.offlineStorage),r.reader=new _t.data.readers[t.schema.type||"json"](t.schema),i=r.reader.model||{},r._detachObservableParents(),r._data=r._observe(r._data),r._online=!0,r.bind(["push",Et,Pt,It,Dt,zt,Bt],t)},options:{data:null,schema:{modelBase:$},offlineStorage:null,serverSorting:!1,serverPaging:!1,serverFiltering:!1,serverGrouping:!1,serverAggregates:!1,batch:!1},clone:function(){return this},online:function(i){return i!==e?this._online!=i&&(this._online=i,i)?this.sync():t.Deferred().resolve().promise():this._online},offlineData:function(t){return null==this.options.offlineStorage?null:t!==e?this._storage.setItem(t):this._storage.getItem()||[]},_isServerGrouped:function(){var t=this.group()||[];return this.options.serverGrouping&&t.length},_pushCreate:function(t){this._push(t,"pushCreate")},_pushUpdate:function(t){this._push(t,"pushUpdate")},_pushDestroy:function(t){this._push(t,"pushDestroy")},_push:function(t,e){var i=this._readData(t);i||(i=t),this[e](i)},_flatData:function(t,e){if(t){if(this._isServerGrouped())return S(t);if(!e)for(var i=0;i<t.length;i++)t.at(i)}return t},parent:vt,get:function(t){var e,i,n=this._flatData(this._data);for(e=0,i=n.length;e<i;e++)if(n[e].id==t)return n[e]},getByUid:function(t){var e,i,n=this._flatData(this._data);if(n)for(e=0,i=n.length;e<i;e++)if(n[e].uid==t)return n[e]},indexOf:function(t){return B(this._data,t)},at:function(t){return this._data.at(t)},data:function(t){var i,n=this;if(t===e){if(n._data)for(i=0;i<n._data.length;i++)n._data.at(i);return n._data}n._detachObservableParents(),n._data=this._observe(t),n._pristineData=t.slice(0),n._storeData(),n._ranges=[],n.trigger("reset"),n._addRange(n._data),n._total=n._data.length,n._pristineTotal=n._total,n._process(n._data)},view:function(t){return t===e?this._view:(this._view=this._observeView(t),e)},_observeView:function(t){var e,i=this;return M(t,i._data,i._ranges,i.reader.model||G,i._isServerGrouped()),e=new j(t,i.reader.model),e.parent=function(){return i.parent()},e},flatView:function(){var t=this.group()||[];return t.length?S(this._view):this._view},add:function(t){return this.insert(this._data.length,t)},_createNewModel:function(t){return this.reader.model?new this.reader.model(t):t instanceof G?t:new G(t)},insert:function(t,e){return e||(e=t,t=0),e instanceof $||(e=this._createNewModel(e)),this._isServerGrouped()?this._data.splice(t,0,this._wrapInEmptyGroup(e)):this._data.splice(t,0,e),e},pushCreate:function(t){var e,i,n,o,r,s;ft(t)||(t=[t]),e=[],i=this.options.autoSync,this.options.autoSync=!1;try{for(n=0;n<t.length;n++)o=t[n],r=this.add(o),e.push(r),s=r.toJSON(),this._isServerGrouped()&&(s=this._wrapInEmptyGroup(s)),this._pristineData.push(s)}finally{this.options.autoSync=i}e.length&&this.trigger("push",{type:"create",items:e})},pushUpdate:function(t){var e,i,n,o,r;for(ft(t)||(t=[t]),e=[],i=0;i<t.length;i++)n=t[i],o=this._createNewModel(n),r=this.get(o.id),r?(e.push(r),r.accept(n),r.trigger(Pt),this._updatePristineForModel(r,n)):this.pushCreate(n);e.length&&this.trigger("push",{type:"update",items:e})},pushDestroy:function(t){var e=this._removeItems(t);e.length&&this.trigger("push",{type:"destroy",items:e})},_removeItems:function(t){var e,i,n,o,r,s;ft(t)||(t=[t]),e=[],i=this.options.autoSync,this.options.autoSync=!1;try{for(n=0;n<t.length;n++)o=t[n],r=this._createNewModel(o),s=!1,this._eachItem(this._data,function(t){var i,n;for(i=0;i<t.length;i++)if(n=t.at(i),n.id===r.id){e.push(n),t.splice(i,1),s=!0;break}}),s&&(this._removePristineForModel(r),this._destroyed.pop())}finally{this.options.autoSync=i}return e},remove:function(t){var e,i=this,n=i._isServerGrouped();return this._eachItem(i._data,function(o){if(e=E(o,t),e&&n)return e.isNew&&e.isNew()||i._destroyed.push(e),!0}),this._removeModelFromRanges(t),this._updateRangesLength(),t},destroyed:function(){return this._destroyed},created:function(){var t,e,i=[],n=this._flatData(this._data);for(t=0,e=n.length;t<e;t++)n[t].isNew&&n[t].isNew()&&i.push(n[t]);return i},updated:function(){var t,e,i=[],n=this._flatData(this._data);for(t=0,e=n.length;t<e;t++)n[t].isNew&&!n[t].isNew()&&n[t].dirty&&i.push(n[t]);return i},sync:function(){var e,i=this,n=[],o=[],r=i._destroyed,s=t.Deferred().resolve().promise();if(i.online()){if(!i.reader.model)return s;n=i.created(),o=i.updated(),e=[],i.options.batch&&i.transport.submit?e=i._sendSubmit(n,o,r):(e.push.apply(e,i._send("create",n)),e.push.apply(e,i._send("update",o)),e.push.apply(e,i._send("destroy",r))),s=t.when.apply(null,e).then(function(){var t,e;for(t=0,e=arguments.length;t<e;t++)arguments[t]&&i._accept(arguments[t]);i._storeData(!0),i._change({action:"sync"}),i.trigger(Dt)})}else i._storeData(!0),i._change({action:"sync"});return s},cancelChanges:function(t){var e=this;t instanceof _t.data.Model?e._cancelModel(t):(e._destroyed=[],e._detachObservableParents(),e._data=e._observe(e._pristineData),e.options.serverPaging&&(e._total=e._pristineTotal),e._ranges=[],e._addRange(e._data),e._change(),e._markOfflineUpdatesAsDirty())},_markOfflineUpdatesAsDirty:function(){var t=this;null!=t.options.offlineStorage&&t._eachItem(t._data,function(t){var e,i;for(e=0;e<t.length;e++)i=t.at(e),"update"!=i.__state__&&"create"!=i.__state__||(i.dirty=!0)})},hasChanges:function(){var t,e,i=this._flatData(this._data);if(this._destroyed.length)return!0;for(t=0,e=i.length;t<e;t++)if(i[t].isNew&&i[t].isNew()||i[t].dirty)return!0;return!1},_accept:function(e){var i,n=this,o=e.models,r=e.response,s=0,a=n._isServerGrouped(),l=n._pristineData,c=e.type;if(n.trigger(zt,{response:r,type:c}),r&&!dt(r)){if(r=n.reader.parse(r),n._handleCustomErrors(r))return;r=n.reader.data(r),ft(r)||(r=[r])}else r=t.map(o,function(t){return t.toJSON()});for("destroy"===c&&(n._destroyed=[]),s=0,i=o.length;s<i;s++)"destroy"!==c?(o[s].accept(r[s]),"create"===c?l.push(a?n._wrapInEmptyGroup(o[s]):r[s]):"update"===c&&n._updatePristineForModel(o[s],r[s])):n._removePristineForModel(o[s])},_updatePristineForModel:function(t,e){this._executeOnPristineForModel(t,function(t,i){_t.deepExtend(i[t],e)})},_executeOnPristineForModel:function(t,e){this._eachPristineItem(function(i){var n=I(i,t);if(n>-1)return e(n,i),!0})},_removePristineForModel:function(t){this._executeOnPristineForModel(t,function(t,e){e.splice(t,1)})},_readData:function(t){var e=this._isServerGrouped()?this.reader.groups:this.reader.data;return e.call(this.reader,t)},_eachPristineItem:function(t){this._eachItem(this._pristineData,t)},_eachItem:function(t,e){t&&t.length&&(this._isServerGrouped()?A(t,e):e(t))},_pristineForModel:function(t){var e,i,n=function(n){if(i=I(n,t),i>-1)return e=n[i],!0};return this._eachPristineItem(n),e},_cancelModel:function(t){var e=this._pristineForModel(t);this._eachItem(this._data,function(i){var n=B(i,t);n>=0&&(!e||t.isNew()&&!e.__state__?i.splice(n,1):(i[n].accept(e),"update"==e.__state__&&(i[n].dirty=!0)))})},_submit:function(e,i){var n=this;n.trigger(It,{type:"submit"}),n.transport.submit(ct({success:function(i,n){var o=t.grep(e,function(t){return t.type==n})[0];o&&o.resolve({response:i,models:o.models,type:n})},error:function(t,i,o){for(var r=0;r<e.length;r++)e[r].reject(t);n.error(t,i,o)}},i))},_sendSubmit:function(e,i,n){var o=this,r=[];return o.options.batch&&(e.length&&r.push(t.Deferred(function(t){t.type="create",t.models=e})),i.length&&r.push(t.Deferred(function(t){t.type="update",t.models=i})),n.length&&r.push(t.Deferred(function(t){t.type="destroy",t.models=n})),o._submit(r,{data:{created:o.reader.serialize(y(e)),updated:o.reader.serialize(y(i)),destroyed:o.reader.serialize(y(n))}})),r},_promise:function(e,i,n){var o=this;return t.Deferred(function(t){o.trigger(It,{type:n}),o.transport[n].call(o.transport,ct({success:function(e){t.resolve({response:e,models:i,type:n})},error:function(e,i,n){t.reject(e),o.error(e,i,n)}},e))}).promise()},_send:function(t,e){var i,n,o=this,r=[],s=o.reader.serialize(y(e));if(o.options.batch)e.length&&r.push(o._promise({data:{models:s}},e,t));else for(i=0,n=e.length;i<n;i++)r.push(o._promise({data:s[i]},[e[i]],t));return r},read:function(e){var i=this,n=i._params(e),o=t.Deferred();return i._queueRequest(n,function(){var t=i.trigger(It,{type:"read"});t?(i._dequeueRequest(),o.resolve(t)):(i.trigger(Bt),i._ranges=[],i.trigger("reset"),i.online()?i.transport.read({data:n,success:function(t){i._ranges=[],i.success(t,n),o.resolve()},error:function(){var t=Wt.call(arguments);i.error.apply(i,t),o.reject.apply(o,t)}}):null!=i.options.offlineStorage&&(i.success(i.offlineData(),n),o.resolve()))}),o.promise()},_readAggregates:function(t){return this.reader.aggregates(t)},success:function(t){var i,n,o,r,s,a,l,c,h=this,u=h.options;if(h.trigger(zt,{response:t,type:"read"}),h.online()){if(t=h.reader.parse(t),h._handleCustomErrors(t))return h._dequeueRequest(),e;h._total=h.reader.total(t),h._aggregate&&u.serverAggregates&&(h._aggregateResult=h._readAggregates(t)),t=h._readData(t),h._destroyed=[]}else{for(t=h._readData(t),i=[],n={},o=h.reader.model,r=o?o.idField:"id",s=0;s<this._destroyed.length;s++)a=this._destroyed[s][r],n[a]=a;for(s=0;s<t.length;s++)l=t[s],c=l.__state__,"destroy"==c?n[l[r]]||this._destroyed.push(this._createNewModel(l)):i.push(l);t=i,h._total=t.length}h._pristineTotal=h._total,h._pristineData=t.slice(0),h._detachObservableParents(),h._data=h._observe(t),h._markOfflineUpdatesAsDirty(),h._storeData(),h._addRange(h._data),h._process(h._data),h._dequeueRequest()},_detachObservableParents:function(){if(this._data&&this._shouldDetachObservableParents)for(var t=0;t<this._data.length;t++)this._data[t].parent&&(this._data[t].parent=vt)},_storeData:function(t){function e(t){var i,n,o,r=[];for(i=0;i<t.length;i++)n=t.at(i),o=n.toJSON(),s&&n.items?o.items=e(n.items):(o.uid=n.uid,a&&(n.isNew()?o.__state__="create":n.dirty&&(o.__state__="update"))),r.push(o);return r}var i,n,o,r,s=this._isServerGrouped(),a=this.reader.model;if(null!=this.options.offlineStorage){for(i=e(this._data),n=[],o=0;o<this._destroyed.length;o++)r=this._destroyed[o].toJSON(),r.__state__="destroy",n.push(r);this.offlineData(i.concat(n)),t&&(this._pristineData=this._readData(i))}},_addRange:function(t){var e=this,i=e._skip||0,n=i+e._flatData(t,!0).length;e._ranges.push({start:i,end:n,data:t,timestamp:(new Date).getTime()}),e._ranges.sort(function(t,e){return t.start-e.start})},error:function(t,e,i){this._dequeueRequest(),this.trigger(zt,{}),this.trigger(Et,{xhr:t,status:e,errorThrown:i})},_params:function(t){var e=this,i=ct({take:e.take(),skip:e.skip(),page:e.page(),pageSize:e.pageSize(),sort:e._sort,filter:e._filter,group:e._group,aggregate:e._aggregate},t);return e.options.serverPaging||(delete i.take,delete i.skip,delete i.page,delete i.pageSize),e.options.serverGrouping?e.reader.model&&i.group&&(i.group=O(i.group,e.reader.model)):delete i.group,e.options.serverFiltering?e.reader.model&&i.filter&&(i.filter=R(i.filter,e.reader.model)):delete i.filter,e.options.serverSorting?e.reader.model&&i.sort&&(i.sort=O(i.sort,e.reader.model)):delete i.sort,e.options.serverAggregates?e.reader.model&&i.aggregate&&(i.aggregate=O(i.aggregate,e.reader.model)):delete i.aggregate,i},_queueRequest:function(t,i){var n=this;n._requestInProgress?n._pending={callback:ht(i,n),options:t}:(n._requestInProgress=!0,n._pending=e,i())},_dequeueRequest:function(){var t=this;t._requestInProgress=!1,t._pending&&t._queueRequest(t._pending.options,t._pending.callback)},_handleCustomErrors:function(t){if(this.reader.errors){var e=this.reader.errors(t);if(e)return this.trigger(Et,{xhr:null,status:"customerror",errorThrown:"custom error",errors:e}),!0}return!1},_shouldWrap:function(t){var e=this.reader.model;return!(!e||!t.length)&&!(t[0]instanceof e)},_observe:function(t){var e,i=this,n=i.reader.model;return i._shouldDetachObservableParents=!0,t instanceof Zt?(i._shouldDetachObservableParents=!1,i._shouldWrap(t)&&(t.type=i.reader.model,t.wrapAll(t,t))):(e=i.pageSize()&&!i.options.serverPaging?j:Zt,t=new e(t,i.reader.model),t.parent=function(){return i.parent()}),i._isServerGrouped()&&T(t,n),i._changeHandler&&i._data&&i._data instanceof Zt?i._data.unbind(Pt,i._changeHandler):i._changeHandler=ht(i._change,i),t.bind(Pt,i._changeHandler)},_updateTotalForAction:function(t,e){var i=this,n=parseInt(i._total,10);v(i._total)||(n=parseInt(i._pristineTotal,10)),"add"===t?n+=e.length:"remove"===t?n-=e.length:"itemchange"===t||"sync"===t||i.options.serverPaging?"sync"===t&&(n=i._pristineTotal=parseInt(i._total,10)):n=i._pristineTotal,i._total=n},_change:function(t){var e,i,n,o=this,r=t?t.action:"";if("remove"===r)for(e=0,i=t.items.length;e<i;e++)t.items[e].isNew&&t.items[e].isNew()||o._destroyed.push(t.items[e]);!o.options.autoSync||"add"!==r&&"remove"!==r&&"itemchange"!==r?(o._updateTotalForAction(r,t?t.items:[]),o._process(o._data,t)):(n=function(e){"sync"===e.action&&(o.unbind("change",n),o._updateTotalForAction(r,t.items))},o.first("change",n),o.sync())},_calculateAggregates:function(t,e){e=e||{};var i=new r(t),n=e.aggregate,o=e.filter;return o&&(i=i.filter(o)),i.aggregate(n)},_process:function(t,i){var n,o=this,r={};o.options.serverPaging!==!0&&(r.skip=o._skip,r.take=o._take||o._pageSize,r.skip===e&&o._page!==e&&o._pageSize!==e&&(r.skip=(o._page-1)*o._pageSize)),o.options.serverSorting!==!0&&(r.sort=o._sort),o.options.serverFiltering!==!0&&(r.filter=o._filter),o.options.serverGrouping!==!0&&(r.group=o._group),o.options.serverAggregates!==!0&&(r.aggregate=o._aggregate,o._aggregateResult=o._calculateAggregates(t,r)),n=o._queryProcess(t,r),o.view(n.data),n.total===e||o.options.serverFiltering||(o._total=n.total),i=i||{},i.items=i.items||o._view,o.trigger(Pt,i)},_queryProcess:function(t,e){return r.process(t,e)},_mergeState:function(t){var i=this;return t!==e&&(i._pageSize=t.pageSize,i._page=t.page,i._sort=t.sort,i._filter=t.filter,i._group=t.group,i._aggregate=t.aggregate,i._skip=i._currentRangeStart=t.skip,i._take=t.take,i._skip===e&&(i._skip=i._currentRangeStart=i.skip(),t.skip=i.skip()),i._take===e&&i._pageSize!==e&&(i._take=i._pageSize,t.take=i._take),t.sort&&(i._sort=t.sort=s(t.sort)),t.filter&&(i._filter=t.filter=l(t.filter)),t.group&&(i._group=t.group=p(t.group)),t.aggregate&&(i._aggregate=t.aggregate=f(t.aggregate))),t},query:function(i){var n,o,r=this.options.serverSorting||this.options.serverPaging||this.options.serverFiltering||this.options.serverGrouping||this.options.serverAggregates;return r||(this._data===e||0===this._data.length)&&!this._destroyed.length?this.read(this._mergeState(i)):(o=this.trigger(It,{type:"read"}),o||(this.trigger(Bt),n=this._queryProcess(this._data,this._mergeState(i)),this.options.serverFiltering||(this._total=n.total!==e?n.total:this._data.length),this._aggregateResult=this._calculateAggregates(this._data,i),this.view(n.data),this.trigger(zt,{type:"read"}),this.trigger(Pt,{items:n.data})),t.Deferred().resolve(o).promise())},fetch:function(t){var e=this,i=function(i){i!==!0&&yt(t)&&t.call(e)};return this._query().then(i)},_query:function(t){var e=this;return e.query(ct({},{page:e.page(),pageSize:e.pageSize(),sort:e.sort(),filter:e.filter(),group:e.group(),aggregate:e.aggregate()},t))},next:function(t){var e=this,i=e.page(),n=e.total();if(t=t||{},i&&!(n&&i+1>e.totalPages()))return e._skip=e._currentRangeStart=i*e.take(),i+=1,t.page=i,e._query(t),i},prev:function(t){var e=this,i=e.page();if(t=t||{},i&&1!==i)return e._skip=e._currentRangeStart=e._skip-e.take(),i-=1,t.page=i,e._query(t),i},page:function(t){var i,n=this;return t!==e?(t=Ft.max(Ft.min(Ft.max(t,1),n.totalPages()),1),n._query({page:t}),e):(i=n.skip(),i!==e?Ft.round((i||0)/(n.take()||1))+1:e)},pageSize:function(t){var i=this;return t!==e?(i._query({pageSize:t,page:1}),e):i.take()},sort:function(t){var i=this;return t!==e?(i._query({sort:t}),e):i._sort},filter:function(t){var i=this;return t===e?i._filter:(i.trigger("reset"),i._query({filter:t,page:1}),e)},group:function(t){var i=this;return t!==e?(i._query({group:t}),e):i._group},total:function(){return parseInt(this._total||0,10)},aggregate:function(t){var i=this;return t!==e?(i._query({aggregate:t}),e):i._aggregate},aggregates:function(){var t=this._aggregateResult;return dt(t)&&(t=this._emptyAggregates(this.aggregate())),t},_emptyAggregates:function(t){var e,i,n={};if(!dt(t))for(e={},ft(t)||(t=[t]),i=0;i<t.length;i++)e[t[i].aggregate]=0,n[t[i].field]=e;return n},_wrapInEmptyGroup:function(t){var e,i,n,o,r=this.group();for(n=r.length-1,o=0;n>=o;n--)i=r[n],e={value:t.get(i.field),field:i.field,items:e?[e]:[t],hasSubgroups:!!e,aggregates:this._emptyAggregates(i.aggregates)};return e},totalPages:function(){var t=this,e=t.pageSize()||t.total();return Ft.ceil((t.total()||0)/e)},inRange:function(t,e){var i=this,n=Ft.min(t+e,i.total());return!i.options.serverPaging&&i._data.length>0||i._findRange(t,n).length>0},lastRange:function(){var t=this._ranges;return t[t.length-1]||{start:0,end:0,data:[]}},firstItemUid:function(){var t=this._ranges;return t.length&&t[0].data.length&&t[0].data[0].uid},enableRequestsInProgress:function(){this._skipRequestsInProgress=!1},_timeStamp:function(){return(new Date).getTime()},range:function(t,i){var n,o,r,s,a,l,c,h;if(this._currentRequestTimeStamp=this._timeStamp(),this._skipRequestsInProgress=!0,t=Ft.min(t||0,this.total()),n=this,o=Ft.max(Ft.floor(t/i),0)*i,r=Ft.min(o+i,n.total()),s=n._findRange(t,Ft.min(t+i,n.total())),s.length){n._pending=e,n._skip=t>n.skip()?Ft.min(r,(n.totalPages()-1)*n.take()):o,n._currentRangeStart=t,n._take=i,a=n.options.serverPaging,l=n.options.serverSorting,c=n.options.serverFiltering,h=n.options.serverAggregates;try{n.options.serverPaging=!0,n._isServerGrouped()||n.group()&&n.group().length||(n.options.serverSorting=!0),n.options.serverFiltering=!0,n.options.serverPaging=!0,n.options.serverAggregates=!0,a&&(n._detachObservableParents(),n._data=s=n._observe(s)),n._process(s)}finally{n.options.serverPaging=a,n.options.serverSorting=l,n.options.serverFiltering=c,n.options.serverAggregates=h}}else i!==e&&(n._rangeExists(o,r)?o<t&&n.prefetch(r,i,function(){n.range(t,i)}):n.prefetch(o,i,function(){t>o&&r<n.total()&&!n._rangeExists(r,Ft.min(r+i,n.total()))?n.prefetch(r,i,function(){n.range(t,i)}):n.range(t,i)}))},_findRange:function(t,i){var n,o,r,a,l,c,h,u,d,f,g,m,v=this,_=v._ranges,y=[],w=v.options,x=w.serverSorting||w.serverPaging||w.serverFiltering||w.serverGrouping||w.serverAggregates;for(o=0,g=_.length;o<g;o++)if(n=_[o],t>=n.start&&t<=n.end){for(f=0,r=o;r<g;r++)if(n=_[r],d=v._flatData(n.data,!0),d.length&&t+f>=n.start&&(c=n.data,h=n.end,x||(m=p(v.group()||[]).concat(s(v.sort()||[])),u=v._queryProcess(n.data,{sort:m,filter:v.filter()}),d=c=u.data,u.total!==e&&(h=u.total)),a=0,t+f>n.start&&(a=t+f-n.start),l=d.length,h>i&&(l-=h-i),f+=l-a,y=v._mergeGroups(y,c,a,l),i<=n.end&&f==i-t))return y;break}return[]},_mergeGroups:function(t,e,i,n){if(this._isServerGrouped()){var o,r=e.toJSON();return t.length&&(o=t[t.length-1]),C(o,r,i,n),t.concat(r)}return t.concat(e.slice(i,n))},skip:function(){var t=this;return t._skip===e?t._page!==e?(t._page-1)*(t.take()||1):e:t._skip},currentRangeStart:function(){return this._currentRangeStart||0},take:function(){return this._take||this._pageSize},_prefetchSuccessHandler:function(t,e,i,n){var o=this,r=o._timeStamp();return function(s){var a,l,c,h=!1,u={start:t,end:e,data:[],timestamp:o._timeStamp()};if(o._dequeueRequest(),o.trigger(zt,{response:s,type:"read"}),s=o.reader.parse(s),c=o._readData(s),c.length){for(a=0,l=o._ranges.length;a<l;a++)if(o._ranges[a].start===t){h=!0,u=o._ranges[a];break}h||o._ranges.push(u)}u.data=o._observe(c),u.end=u.start+o._flatData(u.data,!0).length,o._ranges.sort(function(t,e){return t.start-e.start}),o._total=o.reader.total(s),(n||r>=o._currentRequestTimeStamp||!o._skipRequestsInProgress)&&(i&&c.length?i():o.trigger(Pt,{}))}},prefetch:function(t,e,i){var n=this,o=Ft.min(t+e,n.total()),r={take:e,skip:t,page:t/e+1,pageSize:e,sort:n._sort,filter:n._filter,group:n._group,aggregate:n._aggregate};n._rangeExists(t,o)?i&&i():(clearTimeout(n._timeout),n._timeout=setTimeout(function(){n._queueRequest(r,function(){n.trigger(It,{type:"read"})?n._dequeueRequest():n.transport.read({data:n._params(r),success:n._prefetchSuccessHandler(t,o,i),error:function(){var t=Wt.call(arguments);n.error.apply(n,t)}})})},100))},_multiplePrefetch:function(t,e,i){var n=this,o=Ft.min(t+e,n.total()),r={take:e,skip:t,page:t/e+1,pageSize:e,sort:n._sort,filter:n._filter,group:n._group,aggregate:n._aggregate};n._rangeExists(t,o)?i&&i():n.trigger(It,{type:"read"})||n.transport.read({data:n._params(r),success:n._prefetchSuccessHandler(t,o,i,!0)})},_rangeExists:function(t,e){var i,n,o=this,r=o._ranges;for(i=0,n=r.length;i<n;i++)if(r[i].start<=t&&r[i].end>=e)return!0;return!1},_removeModelFromRanges:function(t){var e,i,n,o,r;for(o=0,r=this._ranges.length;o<r&&(n=this._ranges[o],this._eachItem(n.data,function(n){e=E(n,t),e&&(i=!0)}),!i);o++);},_updateRangesLength:function(){var t,e,i,n,o=0;for(i=0,n=this._ranges.length;i<n;i++)t=this._ranges[i],t.start=t.start-o,e=this._flatData(t.data,!0).length,o=t.end-e,t.end=t.start+e}}),ot={},ot.create=function(e,i,n){var o,r=e.transport?t.extend({},e.transport):null;return r?(r.read=typeof r.read===bt?{url:r.read}:r.read,"jsdo"===e.type&&(r.dataSource=n),e.type&&(_t.data.transports=_t.data.transports||{},_t.data.schemas=_t.data.schemas||{},_t.data.transports[e.type]?ut(_t.data.transports[e.type])?r=ct(!0,{},_t.data.transports[e.type],r):o=new _t.data.transports[e.type](ct(r,{data:i})):_t.logToConsole("Unknown DataSource transport type '"+e.type+"'.\nVerify that registration scripts for this type are included after Kendo UI on the page.","warn"),e.schema=ct(!0,{},_t.data.schemas[e.type],e.schema)),o||(o=yt(r.read)?r:new tt(r))):o=new J({data:e.data||[]}),o},nt.create=function(t){(ft(t)||t instanceof Zt)&&(t={data:t});var i,n,o,r=t||{},s=r.data,a=r.fields,l=r.table,c=r.select,h={};if(s||!a||r.transport||(l?s=F(l,a):c&&(s=V(c,a),r.group===e&&s[0]&&s[0].optgroup!==e&&(r.group="optgroup"))),_t.data.Model&&a&&(!r.schema||!r.schema.model)){for(i=0,n=a.length;i<n;i++)o=a[i],o.type&&(h[o.field]=o);dt(h)||(r.schema=ct(!0,r.schema,{model:{fields:h}}))}return r.data=s,c=null,r.select=null,l=null,r.table=null,r instanceof nt?r:new nt(r)},rt=$.define({idField:"id",init:function(t){var e=this,i=e.hasChildren||t&&t.hasChildren,n="items",o={};_t.data.Model.fn.init.call(e,t),typeof e.children===bt&&(n=e.children),o={schema:{data:n,model:{hasChildren:i,id:e.idField,fields:e.fields}}},typeof e.children!==bt&&ct(o,e.children),o.data=t,i||(i=o.schema.data),typeof i===bt&&(i=_t.getter(i)),yt(i)&&(e.hasChildren=!!i.call(e,e)),e._childrenOptions=o,e.hasChildren&&e._initChildren(),e._loaded=!(!t||!t._loaded)},_initChildren:function(){var t,e,i,n=this;n.children instanceof st||(t=n.children=new st(n._childrenOptions),e=t.transport,i=e.parameterMap,e.parameterMap=function(t,e){return t[n.idField||"id"]=n.id,i&&(t=i(t,e)),t},t.parent=function(){return n},t.bind(Pt,function(t){t.node=t.node||n,n.trigger(Pt,t)}),t.bind(Et,function(t){var e=n.parent();e&&(t.node=t.node||n,e.trigger(Et,t))}),n._updateChildrenField())},append:function(t){this._initChildren(),this.loaded(!0),this.children.add(t)},hasChildren:!1,level:function(){for(var t=this.parentNode(),e=0;t&&t.parentNode;)e++,t=t.parentNode?t.parentNode():null;return e},_updateChildrenField:function(){var t=this._childrenOptions.schema.data;this[t||"items"]=this.children.data()},_childrenLoaded:function(){this._loaded=!0,this._updateChildrenField()},load:function(){var i,n,o={},r="_query";return this.hasChildren?(this._initChildren(),i=this.children,o[this.idField||"id"]=this.id,this._loaded||(i._data=e,r="read"),i.one(Pt,ht(this._childrenLoaded,this)),n=i[r](o)):this.loaded(!0),n||t.Deferred().resolve().promise();
},parentNode:function(){var t=this.parent();return t.parent()},loaded:function(t){return t===e?this._loaded:(this._loaded=t,e)},shouldSerialize:function(t){return $.fn.shouldSerialize.call(this,t)&&"children"!==t&&"_loaded"!==t&&"hasChildren"!==t&&"_childrenOptions"!==t}}),st=nt.extend({init:function(t){var e=rt.define({children:t});nt.fn.init.call(this,ct(!0,{},{schema:{modelBase:e,model:e}},t)),this._attachBubbleHandlers()},_attachBubbleHandlers:function(){var t=this;t._data.bind(Et,function(e){t.trigger(Et,e)})},remove:function(t){var e,i=t.parentNode(),n=this;return i&&i._initChildren&&(n=i.children),e=nt.fn.remove.call(n,t),i&&!n.data().length&&(i.hasChildren=!1),e},success:N("success"),data:N("data"),insert:function(t,e){var i=this.parent();return i&&i._initChildren&&(i.hasChildren=!0,i._initChildren()),nt.fn.insert.call(this,t,e)},_find:function(t,e){var i,n,o,r,s=this._data;if(s){if(o=nt.fn[t].call(this,e))return o;for(s=this._flatData(this._data),i=0,n=s.length;i<n;i++)if(r=s[i].children,r instanceof st&&(o=r[t](e)))return o}},get:function(t){return this._find("get",t)},getByUid:function(t){return this._find("getByUid",t)}}),st.create=function(t){t=t&&t.push?{data:t}:t;var e=t||{},i=e.data,n=e.fields,o=e.list;return i&&i._dataSource?i._dataSource:(i||!n||e.transport||o&&(i=H(o,n)),e.data=i,e instanceof st?e:new st(e))},at=_t.Observable.extend({init:function(t,e,i){_t.Observable.fn.init.call(this),this._prefetching=!1,this.dataSource=t,this.prefetch=!i;var n=this;t.bind("change",function(){n._change()}),t.bind("reset",function(){n._reset()}),this._syncWithDataSource(),this.setViewSize(e)},setViewSize:function(t){this.viewSize=t,this._recalculate()},at:function(t){var i=this.pageSize,n=!0;return t>=this.total()?(this.trigger("endreached",{index:t}),null):this.useRanges?this.useRanges?((t<this.dataOffset||t>=this.skip+i)&&(n=this.range(Math.floor(t/i)*i)),t===this.prefetchThreshold&&this._prefetch(),t===this.midPageThreshold?this.range(this.nextMidRange,!0):t===this.nextPageThreshold?this.range(this.nextFullRange):t===this.pullBackThreshold&&this.range(this.offset===this.skip?this.previousMidRange:this.previousFullRange),n?this.dataSource.at(t-this.dataOffset):(this.trigger("endreached",{index:t}),null)):e:this.dataSource.view()[t]},indexOf:function(t){return this.dataSource.data().indexOf(t)+this.dataOffset},total:function(){return parseInt(this.dataSource.total(),10)},next:function(){var t=this,e=t.pageSize,i=t.skip-t.viewSize+e,n=Ft.max(Ft.floor(i/e),0)*e;this.offset=i,this.dataSource.prefetch(n,e,function(){t._goToRange(i,!0)})},range:function(t,e){if(this.offset===t)return!0;var i=this,n=this.pageSize,o=Ft.max(Ft.floor(t/n),0)*n,r=this.dataSource;return e&&(o+=n),r.inRange(t,n)?(this.offset=t,this._recalculate(),this._goToRange(t),!0):!this.prefetch||(r.prefetch(o,n,function(){i.offset=t,i._recalculate(),i._goToRange(t,!0)}),!1)},syncDataSource:function(){var t=this.offset;this.offset=null,this.range(t)},destroy:function(){this.unbind()},_prefetch:function(){var t=this,e=this.pageSize,i=this.skip+e,n=this.dataSource;n.inRange(i,e)||this._prefetching||!this.prefetch||(this._prefetching=!0,this.trigger("prefetching",{skip:i,take:e}),n.prefetch(i,e,function(){t._prefetching=!1,t.trigger("prefetched",{skip:i,take:e})}))},_goToRange:function(t,e){this.offset===t&&(this.dataOffset=t,this._expanding=e,this.dataSource.range(t,this.pageSize),this.dataSource.enableRequestsInProgress())},_reset:function(){this._syncPending=!0},_change:function(){var t=this.dataSource;this.length=this.useRanges?t.lastRange().end:t.view().length,this._syncPending&&(this._syncWithDataSource(),this._recalculate(),this._syncPending=!1,this.trigger("reset",{offset:this.offset})),this.trigger("resize"),this._expanding&&this.trigger("expand"),delete this._expanding},_syncWithDataSource:function(){var t=this.dataSource;this._firstItemUid=t.firstItemUid(),this.dataOffset=this.offset=t.skip()||0,this.pageSize=t.pageSize(),this.useRanges=t.options.serverPaging},_recalculate:function(){var t=this.pageSize,e=this.offset,i=this.viewSize,n=Math.ceil(e/t)*t;this.skip=n,this.midPageThreshold=n+t-1,this.nextPageThreshold=n+i-1,this.prefetchThreshold=n+Math.floor(t/3*2),this.pullBackThreshold=this.offset-1,this.nextMidRange=n+t-i,this.nextFullRange=n,this.previousMidRange=e-i,this.previousFullRange=n-t}}),lt=_t.Observable.extend({init:function(t,e){var i=this;_t.Observable.fn.init.call(i),this.dataSource=t,this.batchSize=e,this._total=0,this.buffer=new at(t,3*e),this.buffer.bind({endreached:function(t){i.trigger("endreached",{index:t.index})},prefetching:function(t){i.trigger("prefetching",{skip:t.skip,take:t.take})},prefetched:function(t){i.trigger("prefetched",{skip:t.skip,take:t.take})},reset:function(){i._total=0,i.trigger("reset")},resize:function(){i._total=Math.ceil(this.length/i.batchSize),i.trigger("resize",{total:i.total(),offset:this.offset})}})},syncDataSource:function(){this.buffer.syncDataSource()},at:function(t){var e,i,n=this.buffer,o=t*this.batchSize,r=this.batchSize,s=[];for(n.offset>o&&n.at(n.offset-1),i=0;i<r&&(e=n.at(o+i),null!==e);i++)s.push(e);return s},total:function(){return this._total},destroy:function(){this.buffer.destroy(),this.unbind()}}),ct(!0,_t.data,{readers:{json:it},Query:r,DataSource:nt,HierarchicalDataSource:st,Node:rt,ObservableObject:G,ObservableArray:Zt,LazyObservableArray:j,LocalTransport:J,RemoteTransport:tt,Cache:et,DataReader:it,Model:$,Buffer:at,BatchBuffer:lt})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.binder.min",["kendo.core.min","kendo.data.min"],t)}(function(){return function(t,e){function i(e,i,n){return v.extend({init:function(t,e,i){var n=this;v.fn.init.call(n,t.element[0],e,i),n.widget=t,n._dataBinding=E(n.dataBinding,n),n._dataBound=E(n.dataBound,n),n._itemChange=E(n.itemChange,n)},itemChange:function(t){s(t.item[0],t.data,this._ns(t.ns),[t.data].concat(this.bindings[e]._parents()))},dataBinding:function(t){var e,i,n=this.widget,o=t.removedItems||n.items();for(e=0,i=o.length;e<i;e++)c(o[e],!1)},_ns:function(e){e=e||C.ui;var i=[C.ui,C.dataviz.ui,C.mobile.ui];return i.splice(t.inArray(e,i),1),i.unshift(e),C.rolesFromNamespaces(i)},dataBound:function(t){var n,o,r,a,l=this.widget,c=t.addedItems||l.items(),h=l[i],u=C.data.HierarchicalDataSource;if(!(u&&h instanceof u)&&c.length)for(r=t.addedDataItems||h.flatView(),a=this.bindings[e]._parents(),n=0,o=r.length;n<o;n++)s(c[n],r[n],this._ns(t.ns),[r[n]].concat(a))},refresh:function(t){var o,r,s,a=this,l=a.widget;t=t||{},t.action||(a.destroy(),l.bind("dataBinding",a._dataBinding),l.bind("dataBound",a._dataBound),l.bind("itemChange",a._itemChange),o=a.bindings[e].get(),l[i]instanceof C.data.DataSource&&l[i]!=o&&(o instanceof C.data.DataSource?l[n](o):o&&o._dataSource?l[n](o._dataSource):(l[i].data(o),r=C.ui.Select&&l instanceof C.ui.Select,s=C.ui.MultiSelect&&l instanceof C.ui.MultiSelect,a.bindings.value&&(r||s)&&l.value(f(a.bindings.value.get(),l.options.dataValueField)))))},destroy:function(){var t=this.widget;t.unbind("dataBinding",this._dataBinding),t.unbind("dataBound",this._dataBound),t.unbind("itemChange",this._itemChange)}})}function n(t,e){var i=C.initWidget(t,{},e);if(i)return new x(i)}function o(t){var e,i,n,r,s,a,l,c={};for(l=t.match(b),e=0,i=l.length;e<i;e++)n=l[e],r=n.indexOf(":"),s=n.substring(0,r),a=n.substring(r+1),"{"==a.charAt(0)&&(a=o(a)),c[s]=a;return c}function r(t,e,i){var n,o={};for(n in t)o[n]=new i(e,t[n]);return o}function s(t,e,i,a){var c,h,u,d,f=t.getAttribute("data-"+C.ns+"role"),v=t.getAttribute("data-"+C.ns+"bind"),_=[],y=!0,x={};if(a=a||[e],(f||v)&&l(t,!1),f&&(u=n(t,i)),v&&(v=o(v.replace(k,"")),u||(x=C.parseOptions(t,{textField:"",valueField:"",template:"",valueUpdate:F,valuePrimitive:!1,autoBind:!0}),x.roles=i,u=new w(t,x)),u.source=e,h=r(v,a,p),x.template&&(h.template=new m(a,"",x.template)),h.click&&(v.events=v.events||{},v.events.click=v.click,h.click.destroy(),delete h.click),h.source&&(y=!1),v.attr&&(h.attr=r(v.attr,a,p)),v.style&&(h.style=r(v.style,a,p)),v.events&&(h.events=r(v.events,a,g)),v.css&&(h.css=r(v.css,a,p)),u.bind(h)),u&&(t.kendoBindingTarget=u),d=t.children,y&&d){for(c=0;c<d.length;c++)_[c]=d[c];for(c=0;c<_.length;c++)s(_[c],e,i,a)}}function a(e,i){var n,o,r,a=C.rolesFromNamespaces([].slice.call(arguments,2));for(i=C.observable(i),e=t(e),n=0,o=e.length;n<o;n++)r=e[n],1===r.nodeType&&s(r,i,a)}function l(e,i){var n,o=e.kendoBindingTarget;o&&(o.destroy(),O?delete e.kendoBindingTarget:e.removeAttribute?e.removeAttribute("kendoBindingTarget"):e.kendoBindingTarget=null),i&&(n=C.widgetInstance(t(e)),n&&typeof n.destroy===V&&n.destroy())}function c(t,e){l(t,e),h(t,e)}function h(t,e){var i,n,o=t.children;if(o)for(i=0,n=o.length;i<n;i++)c(o[i],e)}function u(e){var i,n;for(e=t(e),i=0,n=e.length;i<n;i++)c(e[i],!1)}function d(t,e){var i=t.element,n=i[0].kendoBindingTarget;n&&a(i,n.source,e)}function f(t,e){var i,n,o=[],r=0;if(!e)return t;if(t instanceof A){for(i=t.length;r<i;r++)n=t[r],o[r]=n.get?n.get(e):n[e];t=o}else t instanceof T&&(t=t.get(e));return t}var p,g,m,v,_,y,w,x,b,k,C=window.kendo,S=C.Observable,T=C.data.ObservableObject,A=C.data.ObservableArray,P={}.toString,D={},M=C.Class,E=t.proxy,I="value",B="source",z="events",L="checked",R="css",O=!0,V="function",F="change";!function(){var t=document.createElement("a");try{delete t.test}catch(e){O=!1}}(),p=S.extend({init:function(t,e){var i=this;S.fn.init.call(i),i.source=t[0],i.parents=t,i.path=e,i.dependencies={},i.dependencies[e]=!0,i.observable=i.source instanceof S,i._access=function(t){i.dependencies[t.field]=!0},i.observable&&(i._change=function(t){i.change(t)},i.source.bind(F,i._change))},_parents:function(){var e,i=this.parents,n=this.get();return n&&"function"==typeof n.parent&&(e=n.parent(),t.inArray(e,i)<0&&(i=[e].concat(i))),i},change:function(t){var e,i,n=t.field,o=this;if("this"===o.path)o.trigger(F,t);else for(e in o.dependencies)if(0===e.indexOf(n)&&(i=e.charAt(n.length),!i||"."===i||"["===i)){o.trigger(F,t);break}},start:function(t){t.bind("get",this._access)},stop:function(t){t.unbind("get",this._access)},get:function(){var t=this,i=t.source,n=0,o=t.path,r=i;if(!t.observable)return r;for(t.start(t.source),r=i.get(o);r===e&&i;)i=t.parents[++n],i instanceof T&&(r=i.get(o));if(r===e)for(i=t.source;r===e&&i;)i=i.parent(),i instanceof T&&(r=i.get(o));return"function"==typeof r&&(n=o.lastIndexOf("."),n>0&&(i=i.get(o.substring(0,n))),t.start(i),r=i!==t.source?r.call(i,t.source):r.call(i),t.stop(i)),i&&i!==t.source&&(t.currentSource=i,i.unbind(F,t._change).bind(F,t._change)),t.stop(t.source),r},set:function(t){var e=this.currentSource||this.source,i=C.getter(this.path)(e);"function"==typeof i?e!==this.source?i.call(e,this.source,t):i.call(e,t):e.set(this.path,t)},destroy:function(){this.observable&&(this.source.unbind(F,this._change),this.currentSource&&this.currentSource.unbind(F,this._change)),this.unbind()}}),g=p.extend({get:function(){var t,e=this.source,i=this.path,n=0;for(t=e.get(i);!t&&e;)e=this.parents[++n],e instanceof T&&(t=e.get(i));return E(t,e)}}),m=p.extend({init:function(t,e,i){var n=this;p.fn.init.call(n,t,e),n.template=i},render:function(t){var e;return this.start(this.source),e=C.render(this.template,t),this.stop(this.source),e}}),v=M.extend({init:function(t,e,i){this.element=t,this.bindings=e,this.options=i},bind:function(t,e){var i=this;t=e?t[e]:t,t.bind(F,function(t){i.refresh(e||t)}),i.refresh(e)},destroy:function(){}}),_=v.extend({dataType:function(){var t=this.element.getAttribute("data-type")||this.element.type||"text";return t.toLowerCase()},parsedValue:function(){return this._parseValue(this.element.value,this.dataType())},_parseValue:function(t,e){return"date"==e?t=C.parseDate(t,"yyyy-MM-dd"):"datetime-local"==e?t=C.parseDate(t,["yyyy-MM-ddTHH:mm:ss","yyyy-MM-ddTHH:mm"]):"number"==e?t=C.parseFloat(t):"boolean"==e&&(t=t.toLowerCase(),t=null!==C.parseFloat(t)?!!C.parseFloat(t):"true"===t.toLowerCase()),t}}),D.attr=v.extend({refresh:function(t){this.element.setAttribute(t,this.bindings.attr[t].get())}}),D.css=v.extend({init:function(t,e,i){v.fn.init.call(this,t,e,i),this.classes={}},refresh:function(e){var i=t(this.element),n=this.bindings.css[e],o=this.classes[e]=n.get();o?i.addClass(e):i.removeClass(e)}}),D.style=v.extend({refresh:function(t){this.element.style[t]=this.bindings.style[t].get()||""}}),D.enabled=v.extend({refresh:function(){this.bindings.enabled.get()?this.element.removeAttribute("disabled"):this.element.setAttribute("disabled","disabled")}}),D.readonly=v.extend({refresh:function(){this.bindings.readonly.get()?this.element.setAttribute("readonly","readonly"):this.element.removeAttribute("readonly")}}),D.disabled=v.extend({refresh:function(){this.bindings.disabled.get()?this.element.setAttribute("disabled","disabled"):this.element.removeAttribute("disabled")}}),D.events=v.extend({init:function(t,e,i){v.fn.init.call(this,t,e,i),this.handlers={}},refresh:function(e){var i=t(this.element),n=this.bindings.events[e],o=this.handlers[e];o&&i.off(e,o),o=this.handlers[e]=n.get(),i.on(e,n.source,o)},destroy:function(){var e,i=t(this.element);for(e in this.handlers)i.off(e,this.handlers[e])}}),D.text=v.extend({refresh:function(){var e=this.bindings.text.get(),i=this.element.getAttribute("data-format")||"";null==e&&(e=""),t(this.element).text(C.toString(e,i))}}),D.visible=v.extend({refresh:function(){this.element.style.display=this.bindings.visible.get()?"":"none"}}),D.invisible=v.extend({refresh:function(){this.element.style.display=this.bindings.invisible.get()?"none":""}}),D.html=v.extend({refresh:function(){this.element.innerHTML=this.bindings.html.get()}}),D.value=_.extend({init:function(e,i,n){_.fn.init.call(this,e,i,n),this._change=E(this.change,this),this.eventName=n.valueUpdate||F,t(this.element).on(this.eventName,this._change),this._initChange=!1},change:function(){this._initChange=this.eventName!=F,this.bindings[I].set(this.parsedValue()),this._initChange=!1},refresh:function(){var t,e;this._initChange||(t=this.bindings[I].get(),null==t&&(t=""),e=this.dataType(),"date"==e?t=C.toString(t,"yyyy-MM-dd"):"datetime-local"==e&&(t=C.toString(t,"yyyy-MM-ddTHH:mm:ss")),this.element.value=t),this._initChange=!1},destroy:function(){t(this.element).off(this.eventName,this._change)}}),D.source=v.extend({init:function(t,e,i){v.fn.init.call(this,t,e,i);var n=this.bindings.source.get();n instanceof C.data.DataSource&&i.autoBind!==!1&&n.fetch()},refresh:function(t){var e=this,i=e.bindings.source.get();i instanceof A||i instanceof C.data.DataSource?(t=t||{},"add"==t.action?e.add(t.index,t.items):"remove"==t.action?e.remove(t.index,t.items):"itemchange"!=t.action&&e.render()):e.render()},container:function(){var t=this.element;return"table"==t.nodeName.toLowerCase()&&(t.tBodies[0]||t.appendChild(document.createElement("tbody")),t=t.tBodies[0]),t},template:function(){var t=this.options,e=t.template,i=this.container().nodeName.toLowerCase();return e||(e="select"==i?t.valueField||t.textField?C.format('<option value="#:{0}#">#:{1}#</option>',t.valueField||t.textField,t.textField||t.valueField):"<option>#:data#</option>":"tbody"==i?"<tr><td>#:data#</td></tr>":"ul"==i||"ol"==i?"<li>#:data#</li>":"#:data#",e=C.template(e)),e},add:function(e,i){var n,o,r,a,l=this.container(),c=l.cloneNode(!1),h=l.children[e];if(t(c).html(C.render(this.template(),i)),c.children.length)for(n=this.bindings.source._parents(),o=0,r=i.length;o<r;o++)a=c.children[0],l.insertBefore(a,h||null),s(a,i[o],this.options.roles,[i[o]].concat(n))},remove:function(t,e){var i,n,o=this.container();for(i=0;i<e.length;i++)n=o.children[t],c(n,!0),n.parentNode==o&&o.removeChild(n)},render:function(){var e,i,n,o=this.bindings.source.get(),r=this.container(),a=this.template();if(null!=o)if(o instanceof C.data.DataSource&&(o=o.view()),o instanceof A||"[object Array]"===P.call(o)||(o=[o]),this.bindings.template){if(h(r,!0),t(r).html(this.bindings.template.render(o)),r.children.length)for(e=this.bindings.source._parents(),i=0,n=o.length;i<n;i++)s(r.children[i],o[i],this.options.roles,[o[i]].concat(e))}else t(r).html(C.render(a,o))}}),D.input={checked:_.extend({init:function(e,i,n){_.fn.init.call(this,e,i,n),this._change=E(this.change,this),t(this.element).change(this._change)},change:function(){var t,e,i,n=this.element,o=this.value();if("radio"==n.type)o=this.parsedValue(),this.bindings[L].set(o);else if("checkbox"==n.type)if(t=this.bindings[L].get(),t instanceof A){if(o=this.parsedValue(),o instanceof Date){for(i=0;i<t.length;i++)if(t[i]instanceof Date&&+t[i]===+o){e=i;break}}else e=t.indexOf(o);e>-1?t.splice(e,1):t.push(o)}else this.bindings[L].set(o)},refresh:function(){var t,e,i=this.bindings[L].get(),n=i,o=this.dataType(),r=this.element;if("checkbox"==r.type)if(n instanceof A){if(t=-1,i=this.parsedValue(),i instanceof Date){for(e=0;e<n.length;e++)if(n[e]instanceof Date&&+n[e]===+i){t=e;break}}else t=n.indexOf(i);r.checked=t>=0}else r.checked=n;else"radio"==r.type&&null!=i&&("date"==o?i=C.toString(i,"yyyy-MM-dd"):"datetime-local"==o&&(i=C.toString(i,"yyyy-MM-ddTHH:mm:ss")),r.checked=r.value===""+i)},value:function(){var t=this.element,e=t.value;return"checkbox"==t.type&&(e=t.checked),e},destroy:function(){t(this.element).off(F,this._change)}})},D.select={source:D.source.extend({refresh:function(i){var n,o=this,r=o.bindings.source.get();r instanceof A||r instanceof C.data.DataSource?(i=i||{},"add"==i.action?o.add(i.index,i.items):"remove"==i.action?o.remove(i.index,i.items):"itemchange"!=i.action&&i.action!==e||(o.render(),o.bindings.value&&o.bindings.value&&(n=f(o.bindings.value.get(),t(o.element).data("valueField")),null===n?o.element.selectedIndex=-1:o.element.value=n))):o.render()}}),value:_.extend({init:function(e,i,n){_.fn.init.call(this,e,i,n),this._change=E(this.change,this),t(this.element).change(this._change)},parsedValue:function(){var t,e,i,n,o=this.dataType(),r=[];for(i=0,n=this.element.options.length;i<n;i++)e=this.element.options[i],e.selected&&(t=e.attributes.value,t=t&&t.specified?e.value:e.text,r.push(this._parseValue(t,o)));return r},change:function(){var t,i,n,o,r,s,a,l,c=[],h=this.element,u=this.options.valueField||this.options.textField,d=this.options.valuePrimitive;for(r=0,s=h.options.length;r<s;r++)i=h.options[r],i.selected&&(o=i.attributes.value,o=o&&o.specified?i.value:i.text,c.push(u?o:this._parseValue(o,this.dataType())));if(u)for(t=this.bindings.source.get(),t instanceof C.data.DataSource&&(t=t.view()),n=0;n<c.length;n++)for(r=0,s=t.length;r<s;r++)if(a=t[r].get(u),l=a+""===c[n]){c[n]=t[r];break}o=this.bindings[I].get(),o instanceof A?o.splice.apply(o,[0,o.length].concat(c)):this.bindings[I].set(d||!(o instanceof T||null===o||o===e)&&u?c[0].get(u):c[0])},refresh:function(){var t,e,i,n=this.element,o=n.options,r=this.bindings[I].get(),s=r,a=this.options.valueField||this.options.textField,l=!1,c=this.dataType();for(s instanceof A||(s=new A([r])),n.selectedIndex=-1,i=0;i<s.length;i++)for(r=s[i],a&&r instanceof T&&(r=r.get(a)),"date"==c?r=C.toString(s[i],"yyyy-MM-dd"):"datetime-local"==c&&(r=C.toString(s[i],"yyyy-MM-ddTHH:mm:ss")),t=0;t<o.length;t++)e=o[t].value,""===e&&""!==r&&(e=o[t].text),null!=r&&e==""+r&&(o[t].selected=!0,l=!0)},destroy:function(){t(this.element).off(F,this._change)}})},D.widget={events:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t,this.handlers={}},refresh:function(t){var e=this.bindings.events[t],i=this.handlers[t];i&&this.widget.unbind(t,i),i=e.get(),this.handlers[t]=function(t){t.data=e.source,i(t),t.data===e.source&&delete t.data},this.widget.bind(t,this.handlers[t])},destroy:function(){var t;for(t in this.handlers)this.widget.unbind(t,this.handlers[t])}}),checked:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t,this._change=E(this.change,this),this.widget.bind(F,this._change)},change:function(){this.bindings[L].set(this.value())},refresh:function(){this.widget.check(this.bindings[L].get()===!0)},value:function(){var t=this.element,e=t.value;return"on"!=e&&"off"!=e||(e=t.checked),e},destroy:function(){this.widget.unbind(F,this._change)}}),visible:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t},refresh:function(){var t=this.bindings.visible.get();this.widget.wrapper[0].style.display=t?"":"none"}}),invisible:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t},refresh:function(){var t=this.bindings.invisible.get();this.widget.wrapper[0].style.display=t?"none":""}}),enabled:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t},refresh:function(){this.widget.enable&&this.widget.enable(this.bindings.enabled.get())}}),disabled:v.extend({init:function(t,e,i){v.fn.init.call(this,t.element[0],e,i),this.widget=t},refresh:function(){this.widget.enable&&this.widget.enable(!this.bindings.disabled.get())}}),source:i("source","dataSource","setDataSource"),value:v.extend({init:function(e,i,n){v.fn.init.call(this,e.element[0],i,n),this.widget=e,this._change=t.proxy(this.change,this),this.widget.first(F,this._change);var o=this.bindings.value.get();this._valueIsObservableObject=!n.valuePrimitive&&(null==o||o instanceof T),this._valueIsObservableArray=o instanceof A,this._initChange=!1},_source:function(){var t;return this.widget.dataItem&&(t=this.widget.dataItem(),t&&t instanceof T)?[t]:(this.bindings.source&&(t=this.bindings.source.get()),(!t||t instanceof C.data.DataSource)&&(t=this.widget.dataSource.flatView()),t)},change:function(){var t,e,i,n,o,r,s,a=this.widget.value(),l=this.options.dataValueField||this.options.dataTextField,c="[object Array]"===P.call(a),h=this._valueIsObservableObject,u=[];if(this._initChange=!0,l)if(""===a&&(h||this.options.valuePrimitive))a=null;else{for(s=this._source(),c&&(e=a.length,u=a.slice(0)),o=0,r=s.length;o<r;o++)if(i=s[o],n=i.get(l),c){for(t=0;t<e;t++)if(n==u[t]){u[t]=i;break}}else if(n==a){a=h?i:n;break}u[0]&&(a=this._valueIsObservableArray?u:h||!l?u[0]:u[0].get(l))}this.bindings.value.set(a),this._initChange=!1},refresh:function(){var t,i,n,o,r,s,a,l,c;if(!this._initChange){if(t=this.widget,i=t.options,n=i.dataTextField,o=i.dataValueField||n,r=this.bindings.value.get(),s=i.text||"",a=0,c=[],r===e&&(r=null),o)if(r instanceof A){for(l=r.length;a<l;a++)c[a]=r[a].get(o);r=c}else r instanceof T&&(s=r.get(n),r=r.get(o));i.autoBind!==!1||i.cascadeFrom||!t.listView||t.listView.bound()?t.value(r):(n!==o||s||(s=r),s||!r&&0!==r||!i.valuePrimitive?t._preselect(r,s):t.value(r))}this._initChange=!1},destroy:function(){this.widget.unbind(F,this._change)}}),gantt:{dependencies:i("dependencies","dependencies","setDependenciesDataSource")},multiselect:{value:v.extend({init:function(e,i,n){v.fn.init.call(this,e.element[0],i,n),this.widget=e,this._change=t.proxy(this.change,this),this.widget.first(F,this._change),this._initChange=!1},change:function(){var t,i,n,o,r,s,a,l,c,h=this,u=h.bindings[I].get(),d=h.options.valuePrimitive,f=d?h.widget.value():h.widget.dataItems(),p=this.options.dataValueField||this.options.dataTextField;if(f=f.slice(0),h._initChange=!0,u instanceof A){for(t=[],i=f.length,n=0,o=0,r=u[n],s=!1;r!==e;){for(c=!1,o=0;o<i;o++)if(d?s=f[o]==r:(l=f[o],l=l.get?l.get(p):l,s=l==(r.get?r.get(p):r)),s){f.splice(o,1),i-=1,c=!0;break}c?n+=1:(t.push(r),y(u,n,1),a=n),r=u[n]}y(u,u.length,0,f),t.length&&u.trigger("change",{action:"remove",items:t,index:a}),f.length&&u.trigger("change",{action:"add",items:f,index:u.length-1})}else h.bindings[I].set(f);h._initChange=!1},refresh:function(){if(!this._initChange){var t,i,n=this.options,o=this.widget,r=n.dataValueField||n.dataTextField,s=this.bindings.value.get(),a=s,l=0,c=[];if(s===e&&(s=null),r)if(s instanceof A){for(t=s.length;l<t;l++)i=s[l],c[l]=i.get?i.get(r):i;s=c}else s instanceof T&&(s=s.get(r));n.autoBind!==!1||n.valuePrimitive===!0||o._isBound()?o.value(s):o._preselect(a,s)}},destroy:function(){this.widget.unbind(F,this._change)}})},scheduler:{source:i("source","dataSource","setDataSource").extend({dataBound:function(t){var e,i,n,o,r=this.widget,a=t.addedItems||r.items();if(a.length)for(n=t.addedDataItems||r.dataItems(),o=this.bindings.source._parents(),e=0,i=n.length;e<i;e++)s(a[e],n[e],this._ns(t.ns),[n[e]].concat(o))}})}},y=function(t,e,i,n){var o,r,s,a,l;if(n=n||[],i=i||0,o=n.length,r=t.length,s=[].slice.call(t,e+i),a=s.length,o){for(o=e+o,l=0;e<o;e++)t[e]=n[l],l++;t.length=o}else if(i)for(t.length=e,i+=e;e<i;)delete t[--i];if(a){for(a=e+a,l=0;e<a;e++)t[e]=s[l],l++;t.length=a}for(e=t.length;e<r;)delete t[e],e++},w=M.extend({init:function(t,e){this.target=t,this.options=e,this.toDestroy=[]},bind:function(t){var e,i,n,o,r,s,a=this instanceof x,l=this.binders();for(e in t)e==I?i=!0:e==B?n=!0:e!=z||a?e==L?r=!0:e==R?s=!0:this.applyBinding(e,t,l):o=!0;n&&this.applyBinding(B,t,l),i&&this.applyBinding(I,t,l),r&&this.applyBinding(L,t,l),o&&!a&&this.applyBinding(z,t,l),s&&!a&&this.applyBinding(R,t,l)},binders:function(){return D[this.target.nodeName.toLowerCase()]||{}},applyBinding:function(t,e,i){var n,o=i[t]||D[t],r=this.toDestroy,s=e[t];if(o)if(o=new o(this.target,e,this.options),r.push(o),s instanceof p)o.bind(s),r.push(s);else for(n in s)o.bind(s,n),r.push(s[n]);else if("template"!==t)throw Error("The "+t+" binding is not supported by the "+this.target.nodeName.toLowerCase()+" element")},destroy:function(){var t,e,i=this.toDestroy;for(t=0,e=i.length;t<e;t++)i[t].destroy()}}),x=w.extend({binders:function(){return D.widget[this.target.options.name.toLowerCase()]||{}},applyBinding:function(t,e,i){var n,o=i[t]||D.widget[t],r=this.toDestroy,s=e[t];if(!o)throw Error("The "+t+" binding is not supported by the "+this.target.options.name+" widget");if(o=new o(this.target,e,this.target.options),r.push(o),s instanceof p)o.bind(s),r.push(s);else for(n in s)o.bind(s,n),r.push(s[n])}}),b=/[A-Za-z0-9_\-]+:(\{([^}]*)\}|[^,}]+)/g,k=/\s/g,C.unbind=u,C.bind=a,C.data.binders=D,C.data.Binder=v,C.notify=d,C.observable=function(t){return t instanceof T||(t=new T(t)),t},C.observableHierarchy=function(t){function e(t){var i,n;for(i=0;i<t.length;i++)t[i]._initChildren(),n=t[i].children,n.fetch(),t[i].items=n.data(),e(t[i].items)}var i=C.data.HierarchicalDataSource.create(t);return i.fetch(),e(i.data()),i._data._dataSource=i,i._data}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.view.min",["kendo.core.min","kendo.binder.min","kendo.fx.min"],t)}(function(){return function(t,e){function i(t){if(!t)return{};var e=t.match(_)||[];return{type:e[1],direction:e[3],reverse:"reverse"===e[5]}}var n=window.kendo,o=n.Observable,r="SCRIPT",s="init",a="show",l="hide",c="transitionStart",h="transitionEnd",u="attach",d="detach",f=/unrecognized expression/,p=o.extend({init:function(t,e){var i=this;e=e||{},o.fn.init.call(i),i.content=t,i.id=n.guid(),i.tagName=e.tagName||"div",i.model=e.model,i._wrap=e.wrap!==!1,this._evalTemplate=e.evalTemplate||!1,i._fragments={},i.bind([s,a,l,c,h],e)},render:function(e){var i=this,o=!i.element;return o&&(i.element=i._createElement()),e&&t(e).append(i.element),o&&(n.bind(i.element,i.model),i.trigger(s)),e&&(i._eachFragment(u),i.trigger(a)),i.element},clone:function(){return new g(this)},triggerBeforeShow:function(){return!0},triggerBeforeHide:function(){return!0},showStart:function(){this.element.css("display","")},showEnd:function(){},hideEnd:function(){this.hide()},beforeTransition:function(t){this.trigger(c,{type:t})},afterTransition:function(t){this.trigger(h,{type:t})},hide:function(){this._eachFragment(d),this.element.detach(),this.trigger(l)},destroy:function(){var t=this.element;t&&(n.unbind(t),n.destroy(t),t.remove())},fragments:function(e){t.extend(this._fragments,e)},_eachFragment:function(t){for(var e in this._fragments)this._fragments[e][t](this,e)},_createElement:function(){var e,i,o,s=this,a="<"+s.tagName+" />";try{i=t(document.getElementById(s.content)||s.content),i[0].tagName===r&&(i=i.html())}catch(l){f.test(l.message)&&(i=s.content)}return"string"==typeof i?(i=i.replace(/^\s+|\s+$/g,""),s._evalTemplate&&(i=n.template(i)(s.model||{})),e=t(a).append(i),s._wrap||(e=e.contents())):(e=i,s._evalTemplate&&(o=t(n.template(t("<div />").append(e.clone(!0)).html())(s.model||{})),t.contains(document,e[0])&&e.replaceWith(o),e=o),s._wrap&&(e=e.wrapAll(a).parent())),e}}),g=n.Class.extend({init:function(e){t.extend(this,{element:e.element.clone(!0),transition:e.transition,id:e.id}),e.element.parent().append(this.element)},hideEnd:function(){this.element.remove()},beforeTransition:t.noop,afterTransition:t.noop}),m=p.extend({init:function(t,e){p.fn.init.call(this,t,e),this.containers={}},container:function(t){var e=this.containers[t];return e||(e=this._createContainer(t),this.containers[t]=e),e},showIn:function(t,e,i){this.container(t).show(e,i)},_createContainer:function(t){var e,i=this.render(),n=i.find(t);if(!n.length&&i.is(t)){if(!i.is(t))throw Error("can't find a container with the specified "+t+" selector");n=i}return e=new y(n),e.bind("accepted",function(t){t.view.render(n)}),e}}),v=p.extend({attach:function(t,e){t.element.find(e).replaceWith(this.render())},detach:function(){}}),_=/^(\w+)(:(\w+))?( (\w+))?$/,y=o.extend({init:function(t){o.fn.init.call(this),this.container=t,this.history=[],this.view=null,this.running=!1},after:function(){this.running=!1,this.trigger("complete",{view:this.view}),this.trigger("after")},end:function(){this.view.showEnd(),this.previous.hideEnd(),this.after()},show:function(t,e,o){if(!t.triggerBeforeShow()||this.view&&!this.view.triggerBeforeHide())return this.trigger("after"),!1;o=o||t.id;var r=this,s=t===r.view?t.clone():r.view,a=r.history,l=a[a.length-2]||{},c=l.id===o,h=e||(c?a[a.length-1].transition:t.transition),u=i(h);return r.running&&r.effect.stop(),"none"===h&&(h=null),r.trigger("accepted",{view:t}),r.view=t,r.previous=s,r.running=!0,c?a.pop():a.push({id:o,transition:h}),s?(h&&n.effects.enabled?(t.element.addClass("k-fx-hidden"),t.showStart(),c&&!e&&(u.reverse=!u.reverse),r.effect=n.fx(t.element).replace(s.element,u.type).beforeTransition(function(){t.beforeTransition("show"),s.beforeTransition("hide")}).afterTransition(function(){t.afterTransition("show"),s.afterTransition("hide")}).direction(u.direction).setReverse(u.reverse),r.effect.run().then(function(){r.end()})):(t.showStart(),r.end()),!0):(t.showStart(),t.showEnd(),r.after(),!0)}});n.ViewContainer=y,n.Fragment=v,n.Layout=m,n.View=p,n.ViewClone=g}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.data.signalr.min",["kendo.data.min"],t)}(function(){return function(t){var e=kendo.data.RemoteTransport.extend({init:function(t){var e,i=t&&t.signalr?t.signalr:{},n=i.promise;if(!n)throw Error('The "promise" option must be set.');if("function"!=typeof n.done||"function"!=typeof n.fail)throw Error('The "promise" option must be a Promise.');if(this.promise=n,e=i.hub,!e)throw Error('The "hub" option must be set.');if("function"!=typeof e.on||"function"!=typeof e.invoke)throw Error('The "hub" option is not a valid SignalR hub proxy.');this.hub=e,kendo.data.RemoteTransport.fn.init.call(this,t)},push:function(t){var e=this.options.signalr.client||{};e.create&&this.hub.on(e.create,t.pushCreate),e.update&&this.hub.on(e.update,t.pushUpdate),e.destroy&&this.hub.on(e.destroy,t.pushDestroy)},_crud:function(e,i){var n,o,r=this.hub,s=this.options.signalr.server;if(!s||!s[i])throw Error(kendo.format('The "server.{0}" option must be set.',i));n=[s[i]],o=this.parameterMap(e.data,i),t.isEmptyObject(o)||n.push(o),this.promise.done(function(){r.invoke.apply(r,n).done(e.success).fail(e.error)})},read:function(t){this._crud(t,"read")},create:function(t){this._crud(t,"create")},update:function(t){this._crud(t,"update")},destroy:function(t){this._crud(t,"destroy")}});t.extend(!0,kendo.data,{transports:{signalr:e}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){
(i||e)()}),function(t,define){define("kendo.userevents.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(t,e){var i=t.x.location,n=t.y.location,o=e.x.location,r=e.y.location,s=i-o,a=n-r;return{center:{x:(i+o)/2,y:(n+r)/2},distance:Math.sqrt(s*s+a*a)}}function n(t){var e,i,n,o=[],r=t.originalEvent,a=t.currentTarget,l=0;if(t.api)o.push({id:2,event:t,target:t.target,currentTarget:t.target,location:t,type:"api"});else if(t.type.match(/touch/))for(i=r?r.changedTouches:[],e=i.length;l<e;l++)n=i[l],o.push({location:n,event:t,target:n.target,currentTarget:a,id:n.identifier,type:"touch"});else o.push(s.pointers||s.msPointers?{location:r,event:t,target:t.target,currentTarget:a,id:r.pointerId,type:"pointer"}:{id:1,event:t,target:t.target,currentTarget:a,location:t,type:"mouse"});return o}function o(t){for(var e=r.eventMap.up.split(" "),i=0,n=e.length;i<n;i++)t(e[i])}var r=window.kendo,s=r.support,a=r.Class,l=r.Observable,c=t.now,h=t.extend,u=s.mobileOS,d=u&&u.android,f=800,p=s.browser.msie?5:0,g="press",m="hold",v="select",_="start",y="move",w="end",x="cancel",b="tap",k="release",C="gesturestart",S="gesturechange",T="gestureend",A="gesturetap",P={api:0,touch:0,mouse:9,pointer:9},D=!s.touch||s.mouseAndTouchPresent,M=a.extend({init:function(t,e){var i=this;i.axis=t,i._updateLocationData(e),i.startLocation=i.location,i.velocity=i.delta=0,i.timeStamp=c()},move:function(t){var e=this,i=t["page"+e.axis],n=c(),o=n-e.timeStamp||1;!i&&d||(e.delta=i-e.location,e._updateLocationData(t),e.initialDelta=i-e.startLocation,e.velocity=e.delta/o,e.timeStamp=n)},_updateLocationData:function(t){var e=this,i=e.axis;e.location=t["page"+i],e.client=t["client"+i],e.screen=t["screen"+i]}}),E=a.extend({init:function(t,e,i){h(this,{x:new M("X",i.location),y:new M("Y",i.location),type:i.type,useClickAsTap:t.useClickAsTap,threshold:t.threshold||P[i.type],userEvents:t,target:e,currentTarget:i.currentTarget,initialTouch:i.target,id:i.id,pressEvent:i,_moved:!1,_finished:!1})},press:function(){this._holdTimeout=setTimeout(t.proxy(this,"_hold"),this.userEvents.minHold),this._trigger(g,this.pressEvent)},_hold:function(){this._trigger(m,this.pressEvent)},move:function(t){var e=this;if(!e._finished){if(e.x.move(t.location),e.y.move(t.location),!e._moved){if(e._withinIgnoreThreshold())return;if(I.current&&I.current!==e.userEvents)return e.dispose();e._start(t)}e._finished||e._trigger(y,t)}},end:function(t){this.endTime=c(),this._finished||(this._finished=!0,this._trigger(k,t),this._moved?this._trigger(w,t):this.useClickAsTap||this._trigger(b,t),clearTimeout(this._holdTimeout),this.dispose())},dispose:function(){var e=this.userEvents,i=e.touches;this._finished=!0,this.pressEvent=null,clearTimeout(this._holdTimeout),i.splice(t.inArray(this,i),1)},skip:function(){this.dispose()},cancel:function(){this.dispose()},isMoved:function(){return this._moved},_start:function(t){clearTimeout(this._holdTimeout),this.startTime=c(),this._moved=!0,this._trigger(_,t)},_trigger:function(t,e){var i=this,n=e.event,o={touch:i,x:i.x,y:i.y,target:i.target,event:n};i.userEvents.notify(t,o)&&n.preventDefault()},_withinIgnoreThreshold:function(){var t=this.x.initialDelta,e=this.y.initialDelta;return Math.sqrt(t*t+e*e)<=this.threshold}}),I=l.extend({init:function(e,i){var n,a,c,u=this,d=r.guid();i=i||{},n=u.filter=i.filter,u.threshold=i.threshold||p,u.minHold=i.minHold||f,u.touches=[],u._maxTouches=i.multiTouch?2:1,u.allowSelection=i.allowSelection,u.captureUpIfMoved=i.captureUpIfMoved,u.useClickAsTap=!i.fastTap&&!s.delayedClick(),u.eventNS=d,e=t(e).handler(u),l.fn.init.call(u),h(u,{element:e,surface:t(i.global&&D?e[0].ownerDocument.documentElement:i.surface||e),stopPropagation:i.stopPropagation,pressed:!1}),u.surface.handler(u).on(r.applyEventMap("move",d),"_move").on(r.applyEventMap("up cancel",d),"_end"),e.on(r.applyEventMap("down",d),n,"_start"),u.useClickAsTap&&e.on(r.applyEventMap("click",d),n,"_click"),(s.pointers||s.msPointers)&&(s.browser.version<11?e.css("-ms-touch-action","pinch-zoom double-tap-zoom"):e.css("touch-action",i.touchAction||"none")),i.preventDragEvent&&e.on(r.applyEventMap("dragstart",d),r.preventDefault),e.on(r.applyEventMap("mousedown",d),n,{root:e},"_select"),u.captureUpIfMoved&&s.eventCapture&&(a=u.surface[0],c=t.proxy(u.preventIfMoving,u),o(function(t){a.addEventListener(t,c,!0)})),u.bind([g,m,b,_,y,w,k,x,C,S,T,A,v],i)},preventIfMoving:function(t){this._isMoved()&&t.preventDefault()},destroy:function(){var t,e=this;e._destroyed||(e._destroyed=!0,e.captureUpIfMoved&&s.eventCapture&&(t=e.surface[0],o(function(i){t.removeEventListener(i,e.preventIfMoving)})),e.element.kendoDestroy(e.eventNS),e.surface.kendoDestroy(e.eventNS),e.element.removeData("handler"),e.surface.removeData("handler"),e._disposeAll(),e.unbind(),delete e.surface,delete e.element,delete e.currentTarget)},capture:function(){I.current=this},cancel:function(){this._disposeAll(),this.trigger(x)},notify:function(t,e){var n=this,o=n.touches;if(this._isMultiTouch()){switch(t){case y:t=S;break;case w:t=T;break;case b:t=A}h(e,{touches:o},i(o[0],o[1]))}return this.trigger(t,h(e,{type:t}))},press:function(t,e,i){this._apiCall("_start",t,e,i)},move:function(t,e){this._apiCall("_move",t,e)},end:function(t,e){this._apiCall("_end",t,e)},_isMultiTouch:function(){return this.touches.length>1},_maxTouchesReached:function(){return this.touches.length>=this._maxTouches},_disposeAll:function(){for(var t=this.touches;t.length>0;)t.pop().dispose()},_isMoved:function(){return t.grep(this.touches,function(t){return t.isMoved()}).length},_select:function(t){this.allowSelection&&!this.trigger(v,{event:t})||t.preventDefault()},_start:function(e){var i,o,r=this,s=0,a=r.filter,l=n(e),c=l.length,h=e.which;if(!(h&&h>1||r._maxTouchesReached()))for(I.current=null,r.currentTarget=e.currentTarget,r.stopPropagation&&e.stopPropagation();s<c&&!r._maxTouchesReached();s++)o=l[s],i=a?t(o.currentTarget):r.element,i.length&&(o=new E(r,i,o),r.touches.push(o),o.press(),r._isMultiTouch()&&r.notify("gesturestart",{}))},_move:function(t){this._eachTouch("move",t)},_end:function(t){this._eachTouch("end",t)},_click:function(e){var i={touch:{initialTouch:e.target,target:t(e.currentTarget),endTime:c(),x:{location:e.pageX,client:e.clientX},y:{location:e.pageY,client:e.clientY}},x:e.pageX,y:e.pageY,target:t(e.currentTarget),event:e,type:"tap"};this.trigger("tap",i)&&e.preventDefault()},_eachTouch:function(t,e){var i,o,r,s,a=this,l={},c=n(e),h=a.touches;for(i=0;i<h.length;i++)o=h[i],l[o.id]=o;for(i=0;i<c.length;i++)r=c[i],s=l[r.id],s&&s[t](r)},_apiCall:function(e,i,n,o){this[e]({api:!0,pageX:i,pageY:n,clientX:i,clientY:n,target:t(o||this.element)[0],stopPropagation:t.noop,preventDefault:t.noop})}});I.defaultThreshold=function(t){p=t},I.minHold=function(t){f=t},r.getTouches=n,r.touchDelta=i,r.UserEvents=I}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.draganddrop.min",["kendo.core.min","kendo.userevents.min"],t)}(function(){return function(t,e){function i(e,i){try{return t.contains(e,i)||e==i}catch(n){return!1}}function n(t,e){return parseInt(t.css(e),10)||0}function o(t,e){return Math.min(Math.max(t,e.min),e.max)}function r(t,e){var i=P(t),o=_._outerWidth,r=_._outerHeight,s=i.left+n(t,"borderLeftWidth")+n(t,"paddingLeft"),a=i.top+n(t,"borderTopWidth")+n(t,"paddingTop"),l=s+t.width()-o(e,!0),c=a+t.height()-r(e,!0);return{x:{min:s,max:l},y:{min:a,max:c}}}function s(i,n,o){for(var r,s,a=0,l=n&&n.length,c=o&&o.length;i&&i.parentNode;){for(a=0;a<l;a++)if(r=n[a],r.element[0]===i)return{target:r,targetElement:i};for(a=0;a<c;a++)if(s=o[a],t.contains(s.element[0],i)&&y.matchesSelector.call(i,s.options.filter))return{target:s,targetElement:i};i=i.parentNode}return e}function a(t,e){var i,n=e.options.group,o=t[n];if(k.fn.destroy.call(e),o.length>1){for(i=0;i<o.length;i++)if(o[i]==e){o.splice(i,1);break}}else o.length=0,delete t[n]}function l(t){var e,i,n,o=c()[0];return t[0]===o?(i=o.scrollTop,n=o.scrollLeft,{top:i,left:n,bottom:i+x.height(),right:n+x.width()}):(e=t.offset(),e.bottom=e.top+t.height(),e.right=e.left+t.width(),e)}function c(){return t(_.support.browser.chrome?w.body:w.documentElement)}function h(e){var i,n=c();if(!e||e===w.body||e===w.documentElement)return n;for(i=t(e)[0];i&&!_.isScrollable(i)&&i!==w.body;)i=i.parentNode;return i===w.body?n:t(i)}function u(t,e,i){var n={x:0,y:0},o=50;return t-i.left<o?n.x=-(o-(t-i.left)):i.right-t<o&&(n.x=o-(i.right-t)),e-i.top<o?n.y=-(o-(e-i.top)):i.bottom-e<o&&(n.y=o-(i.bottom-e)),n}var d,f,p,g,m,v,_=window.kendo,y=_.support,w=window.document,x=t(window),b=_.Class,k=_.ui.Widget,C=_.Observable,S=_.UserEvents,T=t.proxy,A=t.extend,P=_.getOffset,D={},M={},E={},I=_.elementUnderCursor,B="keyup",z="change",L="dragstart",R="hold",O="drag",V="dragend",F="dragcancel",N="hintDestroyed",H="dragenter",U="dragleave",j="drop",G=C.extend({init:function(e,i){var n=this,o=e[0];n.capture=!1,o.addEventListener?(t.each(_.eventMap.down.split(" "),function(){o.addEventListener(this,T(n._press,n),!0)}),t.each(_.eventMap.up.split(" "),function(){o.addEventListener(this,T(n._release,n),!0)})):(t.each(_.eventMap.down.split(" "),function(){o.attachEvent(this,T(n._press,n))}),t.each(_.eventMap.up.split(" "),function(){o.attachEvent(this,T(n._release,n))})),C.fn.init.call(n),n.bind(["press","release"],i||{})},captureNext:function(){this.capture=!0},cancelCapture:function(){this.capture=!1},_press:function(t){var e=this;e.trigger("press"),e.capture&&t.preventDefault()},_release:function(t){var e=this;e.trigger("release"),e.capture&&(t.preventDefault(),e.cancelCapture())}}),W=C.extend({init:function(e){var i=this;C.fn.init.call(i),i.forcedEnabled=!1,t.extend(i,e),i.scale=1,i.horizontal?(i.measure="offsetWidth",i.scrollSize="scrollWidth",i.axis="x"):(i.measure="offsetHeight",i.scrollSize="scrollHeight",i.axis="y")},makeVirtual:function(){t.extend(this,{virtual:!0,forcedEnabled:!0,_virtualMin:0,_virtualMax:0})},virtualSize:function(t,e){this._virtualMin===t&&this._virtualMax===e||(this._virtualMin=t,this._virtualMax=e,this.update())},outOfBounds:function(t){return t>this.max||t<this.min},forceEnabled:function(){this.forcedEnabled=!0},getSize:function(){return this.container[0][this.measure]},getTotal:function(){return this.element[0][this.scrollSize]},rescale:function(t){this.scale=t},update:function(t){var e=this,i=e.virtual?e._virtualMax:e.getTotal(),n=i*e.scale,o=e.getSize();(0!==i||e.forcedEnabled)&&(e.max=e.virtual?-e._virtualMin:0,e.size=o,e.total=n,e.min=Math.min(e.max,o-n),e.minScale=o/i,e.centerOffset=(n-o)/2,e.enabled=e.forcedEnabled||n>o,t||e.trigger(z,e))}}),q=C.extend({init:function(t){var e=this;C.fn.init.call(e),e.x=new W(A({horizontal:!0},t)),e.y=new W(A({horizontal:!1},t)),e.container=t.container,e.forcedMinScale=t.minScale,e.maxScale=t.maxScale||100,e.bind(z,t)},rescale:function(t){this.x.rescale(t),this.y.rescale(t),this.refresh()},centerCoordinates:function(){return{x:Math.min(0,-this.x.centerOffset),y:Math.min(0,-this.y.centerOffset)}},refresh:function(){var t=this;t.x.update(),t.y.update(),t.enabled=t.x.enabled||t.y.enabled,t.minScale=t.forcedMinScale||Math.min(t.x.minScale,t.y.minScale),t.fitScale=Math.max(t.x.minScale,t.y.minScale),t.trigger(z)}}),$=C.extend({init:function(t){var e=this;A(e,t),C.fn.init.call(e)},outOfBounds:function(){return this.dimension.outOfBounds(this.movable[this.axis])},dragMove:function(t){var e=this,i=e.dimension,n=e.axis,o=e.movable,r=o[n]+t;i.enabled&&((r<i.min&&t<0||r>i.max&&t>0)&&(t*=e.resistance),o.translateAxis(n,t),e.trigger(z,e))}}),Y=b.extend({init:function(e){var i,n,o,r,s=this;A(s,{elastic:!0},e),o=s.elastic?.5:0,r=s.movable,s.x=i=new $({axis:"x",dimension:s.dimensions.x,resistance:o,movable:r}),s.y=n=new $({axis:"y",dimension:s.dimensions.y,resistance:o,movable:r}),s.userEvents.bind(["press","move","end","gesturestart","gesturechange"],{gesturestart:function(t){s.gesture=t,s.offset=s.dimensions.container.offset()},press:function(e){t(e.event.target).closest("a").is("[data-navigate-on-press=true]")&&e.sender.cancel()},gesturechange:function(t){var e,o,a,l=s.gesture,c=l.center,h=t.center,u=t.distance/l.distance,d=s.dimensions.minScale,f=s.dimensions.maxScale;r.scale<=d&&u<1&&(u+=.8*(1-u)),r.scale*u>=f&&(u=f/r.scale),o=r.x+s.offset.left,a=r.y+s.offset.top,e={x:(o-c.x)*u+h.x-o,y:(a-c.y)*u+h.y-a},r.scaleWith(u),i.dragMove(e.x),n.dragMove(e.y),s.dimensions.rescale(r.scale),s.gesture=t,t.preventDefault()},move:function(t){t.event.target.tagName.match(/textarea|input/i)||(i.dimension.enabled||n.dimension.enabled?(i.dragMove(t.x.delta),n.dragMove(t.y.delta),t.preventDefault()):t.touch.skip())},end:function(t){t.preventDefault()}})}}),X=y.transitions.prefix+"Transform";f=y.hasHW3D?function(t,e,i){return"translate3d("+t+"px,"+e+"px,0) scale("+i+")"}:function(t,e,i){return"translate("+t+"px,"+e+"px) scale("+i+")"},p=C.extend({init:function(e){var i=this;C.fn.init.call(i),i.element=t(e),i.element[0].style.webkitTransformOrigin="left top",i.x=0,i.y=0,i.scale=1,i._saveCoordinates(f(i.x,i.y,i.scale))},translateAxis:function(t,e){this[t]+=e,this.refresh()},scaleTo:function(t){this.scale=t,this.refresh()},scaleWith:function(t){this.scale*=t,this.refresh()},translate:function(t){this.x+=t.x,this.y+=t.y,this.refresh()},moveAxis:function(t,e){this[t]=e,this.refresh()},moveTo:function(t){A(this,t),this.refresh()},refresh:function(){var t,e=this,i=e.x,n=e.y;e.round&&(i=Math.round(i),n=Math.round(n)),t=f(i,n,e.scale),t!=e.coordinates&&(_.support.browser.msie&&_.support.browser.version<10?(e.element[0].style.position="absolute",e.element[0].style.left=e.x+"px",e.element[0].style.top=e.y+"px"):e.element[0].style[X]=t,e._saveCoordinates(t),e.trigger(z))},_saveCoordinates:function(t){this.coordinates=t}}),g=k.extend({init:function(t,e){var i,n=this;k.fn.init.call(n,t,e),i=n.options.group,i in M?M[i].push(n):M[i]=[n]},events:[H,U,j],options:{name:"DropTarget",group:"default"},destroy:function(){a(M,this)},_trigger:function(t,e){var i=this,n=D[i.options.group];if(n)return i.trigger(t,A({},e.event,{draggable:n,dropTarget:e.dropTarget}))},_over:function(t){this._trigger(H,t)},_out:function(t){this._trigger(U,t)},_drop:function(t){var e=this,i=D[e.options.group];i&&(i.dropped=!e._trigger(j,t))}}),g.destroyGroup=function(t){var e,i=M[t]||E[t];if(i){for(e=0;e<i.length;e++)k.fn.destroy.call(i[e]);i.length=0,delete M[t],delete E[t]}},g._cache=M,m=g.extend({init:function(t,e){var i,n=this;k.fn.init.call(n,t,e),i=n.options.group,i in E?E[i].push(n):E[i]=[n]},destroy:function(){a(E,this)},options:{name:"DropTargetArea",group:"default",filter:null}}),v=k.extend({init:function(t,e){var i=this;k.fn.init.call(i,t,e),i._activated=!1,i.userEvents=new S(i.element,{global:!0,allowSelection:!0,filter:i.options.filter,threshold:i.options.distance,start:T(i._start,i),hold:T(i._hold,i),move:T(i._drag,i),end:T(i._end,i),cancel:T(i._cancel,i),select:T(i._select,i)}),i._afterEndHandler=T(i._afterEnd,i),i._captureEscape=T(i._captureEscape,i)},events:[R,L,O,V,F,N],options:{name:"Draggable",distance:_.support.touch?0:5,group:"default",cursorOffset:null,axis:null,container:null,filter:null,ignore:null,holdToDrag:!1,autoScroll:!1,dropped:!1},cancelHold:function(){this._activated=!1},_captureEscape:function(t){var e=this;t.keyCode===_.keys.ESC&&(e._trigger(F,{event:t}),e.userEvents.cancel())},_updateHint:function(e){var i,n=this,r=n.options,s=n.boundaries,a=r.axis,l=n.options.cursorOffset;l?i={left:e.x.location+l.left,top:e.y.location+l.top}:(n.hintOffset.left+=e.x.delta,n.hintOffset.top+=e.y.delta,i=t.extend({},n.hintOffset)),s&&(i.top=o(i.top,s.y),i.left=o(i.left,s.x)),"x"===a?delete i.top:"y"===a&&delete i.left,n.hint.css(i)},_shouldIgnoreTarget:function(e){var i=this.options.ignore;return i&&t(e).is(i)},_select:function(t){this._shouldIgnoreTarget(t.event.target)||t.preventDefault()},_start:function(i){var n,o=this,s=o.options,a=s.container,l=s.hint;return this._shouldIgnoreTarget(i.touch.initialTouch)||s.holdToDrag&&!o._activated?(o.userEvents.cancel(),e):(o.currentTarget=i.target,o.currentTargetOffset=P(o.currentTarget),l&&(o.hint&&o.hint.stop(!0,!0).remove(),o.hint=_.isFunction(l)?t(l.call(o,o.currentTarget)):l,n=P(o.currentTarget),o.hintOffset=n,o.hint.css({position:"absolute",zIndex:2e4,left:n.left,top:n.top}).appendTo(w.body),o.angular("compile",function(){o.hint.removeAttr("ng-repeat");for(var e=t(i.target);!e.data("$$kendoScope")&&e.length;)e=e.parent();return{elements:o.hint.get(),scopeFrom:e.data("$$kendoScope")}})),D[s.group]=o,o.dropped=!1,a&&(o.boundaries=r(a,o.hint)),t(w).on(B,o._captureEscape),o._trigger(L,i)&&(o.userEvents.cancel(),o._afterEnd()),o.userEvents.capture(),e)},_hold:function(t){this.currentTarget=t.target,this._trigger(R,t)?this.userEvents.cancel():this._activated=!0},_drag:function(e){var i,n;e.preventDefault(),i=this._elementUnderCursor(e),this.options.autoScroll&&this._cursorElement!==i&&(this._scrollableParent=h(i),this._cursorElement=i),this._lastEvent=e,this._processMovement(e,i),this.options.autoScroll&&this._scrollableParent[0]&&(n=u(e.x.location,e.y.location,l(this._scrollableParent)),this._scrollCompenstation=t.extend({},this.hintOffset),this._scrollVelocity=n,0===n.y&&0===n.x?(clearInterval(this._scrollInterval),this._scrollInterval=null):this._scrollInterval||(this._scrollInterval=setInterval(t.proxy(this,"_autoScroll"),50))),this.hint&&this._updateHint(e)},_processMovement:function(i,n){this._withDropTarget(n,function(n,o){if(!n)return d&&(d._trigger(U,A(i,{dropTarget:t(d.targetElement)})),d=null),e;if(d){if(o===d.targetElement)return;d._trigger(U,A(i,{dropTarget:t(d.targetElement)}))}n._trigger(H,A(i,{dropTarget:t(o)})),d=A(n,{targetElement:o})}),this._trigger(O,A(i,{dropTarget:d,elementUnderCursor:n}))},_autoScroll:function(){var t,e,i,n,o,r,s,a,l=this._scrollableParent[0],h=this._scrollVelocity,u=this._scrollCompenstation;l&&(t=this._elementUnderCursor(this._lastEvent),this._processMovement(this._lastEvent,t),n=l===c()[0],n?(e=w.body.scrollHeight>x.height(),i=w.body.scrollWidth>x.width()):(e=l.offsetHeight<=l.scrollHeight,i=l.offsetWidth<=l.scrollWidth),o=l.scrollTop+h.y,r=e&&o>0&&o<l.scrollHeight,s=l.scrollLeft+h.x,a=i&&s>0&&s<l.scrollWidth,r&&(l.scrollTop+=h.y),a&&(l.scrollLeft+=h.x),n&&(a||r)&&(r&&(u.top+=h.y),a&&(u.left+=h.x),this.hint.css(u)))},_end:function(e){this._withDropTarget(this._elementUnderCursor(e),function(i,n){i&&(i._drop(A({},e,{dropTarget:t(n)})),d=null)}),this._cancel(this._trigger(V,e))},_cancel:function(t){var e=this;e._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),e._activated=!1,e.hint&&!e.dropped?setTimeout(function(){e.hint.stop(!0,!0),t?e._afterEndHandler():e.hint.animate(e.currentTargetOffset,"fast",e._afterEndHandler)},0):e._afterEnd()},_trigger:function(t,e){var i=this;return i.trigger(t,A({},e.event,{x:e.x,y:e.y,currentTarget:i.currentTarget,initialTarget:e.touch?e.touch.initialTouch:null,dropTarget:e.dropTarget,elementUnderCursor:e.elementUnderCursor}))},_elementUnderCursor:function(t){var e=I(t),n=this.hint;return n&&i(n[0],e)&&(n.hide(),e=I(t),e||(e=I(t)),n.show()),e},_withDropTarget:function(t,e){var i,n=this.options.group,o=M[n],r=E[n];(o&&o.length||r&&r.length)&&(i=s(t,o,r),i?e(i.target,i.targetElement):e())},destroy:function(){var t=this;k.fn.destroy.call(t),t._afterEnd(),t.userEvents.destroy(),this._scrollableParent=null,this._cursorElement=null,clearInterval(this._scrollInterval),t.currentTarget=null},_afterEnd:function(){var e=this;e.hint&&e.hint.remove(),delete D[e.options.group],e.trigger("destroy"),e.trigger(N),t(w).off(B,e._captureEscape)}}),_.ui.plugin(g),_.ui.plugin(m),_.ui.plugin(v),_.TapCapture=G,_.containerBoundaries=r,A(_.ui,{Pane:Y,PaneDimensions:q,Movable:p}),_.ui.Draggable.utils={autoScrollVelocity:u,scrollableViewPort:l,findScrollableParent:h}}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.mobile.scroller.min",["kendo.fx.min","kendo.draganddrop.min"],t)}(function(){return function(t,e){var i=window.kendo,n=i.mobile,o=i.effects,r=n.ui,s=t.proxy,a=t.extend,l=r.Widget,c=i.Class,h=i.ui.Movable,u=i.ui.Pane,d=i.ui.PaneDimensions,f=o.Transition,p=o.Animation,g=Math.abs,m=500,v=.7,_=.96,y=10,w=55,x=.5,b=5,k="km-scroller-release",C="km-scroller-refresh",S="pull",T="change",A="resize",P="scroll",D=2,M=p.extend({init:function(t){var e=this;p.fn.init.call(e),a(e,t),e.userEvents.bind("gestureend",s(e.start,e)),e.tapCapture.bind("press",s(e.cancel,e))},enabled:function(){return this.movable.scale<this.dimensions.minScale},done:function(){return this.dimensions.minScale-this.movable.scale<.01},tick:function(){var t=this.movable;t.scaleWith(1.1),this.dimensions.rescale(t.scale)},onEnd:function(){var t=this.movable;t.scaleTo(this.dimensions.minScale),this.dimensions.rescale(t.scale)}}),E=p.extend({init:function(t){var e=this;p.fn.init.call(e),a(e,t,{transition:new f({axis:t.axis,movable:t.movable,onEnd:function(){e._end()}})}),e.tapCapture.bind("press",function(){e.cancel()}),e.userEvents.bind("end",s(e.start,e)),e.userEvents.bind("gestureend",s(e.start,e)),e.userEvents.bind("tap",s(e.onEnd,e))},onCancel:function(){this.transition.cancel()},freeze:function(t){var e=this;e.cancel(),e._moveTo(t)},onEnd:function(){var t=this;t.paneAxis.outOfBounds()?t._snapBack():t._end()},done:function(){return g(this.velocity)<1},start:function(t){var e,i=this;i.dimension.enabled&&(i.paneAxis.outOfBounds()?i._snapBack():(e=t.touch.id===D?0:t.touch[i.axis].velocity,i.velocity=Math.max(Math.min(e*i.velocityMultiplier,w),-w),i.tapCapture.captureNext(),p.fn.start.call(i)))},tick:function(){var t=this,e=t.dimension,i=t.paneAxis.outOfBounds()?x:t.friction,n=t.velocity*=i,o=t.movable[t.axis]+n;!t.elastic&&e.outOfBounds(o)&&(o=Math.max(Math.min(o,e.max),e.min),t.velocity=0),t.movable.moveAxis(t.axis,o)},_end:function(){this.tapCapture.cancelCapture(),this.end()},_snapBack:function(){var t=this,e=t.dimension,i=t.movable[t.axis]>e.max?e.max:e.min;t._moveTo(i)},_moveTo:function(t){this.transition.moveTo({location:t,duration:m,ease:f.easeOutExpo})}}),I=p.extend({init:function(t){var e=this;i.effects.Animation.fn.init.call(this),a(e,t,{origin:{},destination:{},offset:{}})},tick:function(){this._updateCoordinates(),this.moveTo(this.origin)},done:function(){return g(this.offset.y)<b&&g(this.offset.x)<b},onEnd:function(){this.moveTo(this.destination),this.callback&&this.callback.call()},setCoordinates:function(t,e){this.offset={},this.origin=t,this.destination=e},setCallback:function(t){t&&i.isFunction(t)?this.callback=t:t=e},_updateCoordinates:function(){this.offset={x:(this.destination.x-this.origin.x)/4,y:(this.destination.y-this.origin.y)/4},this.origin={y:this.origin.y+this.offset.y,x:this.origin.x+this.offset.x}}}),B=c.extend({init:function(e){var i=this,n="x"===e.axis,o=t('<div class="km-touch-scrollbar km-'+(n?"horizontal":"vertical")+'-scrollbar" />');a(i,e,{element:o,elementSize:0,movable:new h(o),scrollMovable:e.movable,alwaysVisible:e.alwaysVisible,size:n?"width":"height"}),i.scrollMovable.bind(T,s(i.refresh,i)),i.container.append(o),e.alwaysVisible&&i.show()},refresh:function(){var t=this,e=t.axis,i=t.dimension,n=i.size,o=t.scrollMovable,r=n/i.total,s=Math.round(-o[e]*r),a=Math.round(n*r);r>=1?this.element.css("display","none"):this.element.css("display",""),s+a>n?a=n-s:s<0&&(a+=s,s=0),t.elementSize!=a&&(t.element.css(t.size,a+"px"),t.elementSize=a),t.movable.moveAxis(e,s)},show:function(){this.element.css({opacity:v,visibility:"visible"})},hide:function(){this.alwaysVisible||this.element.css({opacity:0})}}),z=l.extend({init:function(n,o){var r,c,f,p,m,v,_,y,w,x=this;return l.fn.init.call(x,n,o),n=x.element,(x._native=x.options.useNative&&i.support.hasNativeScrolling)?(n.addClass("km-native-scroller").prepend('<div class="km-scroll-header"/>'),a(x,{scrollElement:n,fixedContainer:n.children().first()}),e):(n.css("overflow","hidden").addClass("km-scroll-wrapper").wrapInner('<div class="km-scroll-container"/>').prepend('<div class="km-scroll-header"/>'),r=n.children().eq(1),c=new i.TapCapture(n),f=new h(r),p=new d({element:r,container:n,forcedEnabled:x.options.zoom}),m=this.options.avoidScrolling,v=new i.UserEvents(n,{touchAction:"pan-y",fastTap:!0,allowSelection:!0,preventDragEvent:!0,captureUpIfMoved:!0,multiTouch:x.options.zoom,start:function(e){p.refresh();var i=g(e.x.velocity),n=g(e.y.velocity),o=2*i>=n,r=t.contains(x.fixedContainer[0],e.event.target),s=2*n>=i;!r&&!m(e)&&x.enabled&&(p.x.enabled&&o||p.y.enabled&&s)?v.capture():v.cancel()}}),_=new u({movable:f,dimensions:p,userEvents:v,elastic:x.options.elastic}),y=new M({movable:f,dimensions:p,userEvents:v,tapCapture:c}),w=new I({moveTo:function(t){x.scrollTo(t.x,t.y)}}),f.bind(T,function(){x.scrollTop=-f.y,x.scrollLeft=-f.x,x.trigger(P,{scrollTop:x.scrollTop,scrollLeft:x.scrollLeft})}),x.options.mousewheelScrolling&&n.on("DOMMouseScroll mousewheel",s(this,"_wheelScroll")),a(x,{movable:f,dimensions:p,zoomSnapBack:y,animatedScroller:w,userEvents:v,pane:_,tapCapture:c,pulled:!1,enabled:!0,scrollElement:r,scrollTop:0,scrollLeft:0,fixedContainer:n.children().first()}),x._initAxis("x"),x._initAxis("y"),x._wheelEnd=function(){x._wheel=!1,x.userEvents.end(0,x._wheelY)},p.refresh(),x.options.pullToRefresh&&x._initPullToRefresh(),e)},_wheelScroll:function(t){this._wheel||(this._wheel=!0,this._wheelY=0,this.userEvents.press(0,this._wheelY)),clearTimeout(this._wheelTimeout),this._wheelTimeout=setTimeout(this._wheelEnd,50);var e=i.wheelDeltaY(t);e&&(this._wheelY+=e,this.userEvents.move(0,this._wheelY)),t.preventDefault()},makeVirtual:function(){this.dimensions.y.makeVirtual()},virtualSize:function(t,e){this.dimensions.y.virtualSize(t,e)},height:function(){return this.dimensions.y.size},scrollHeight:function(){return this.scrollElement[0].scrollHeight},scrollWidth:function(){return this.scrollElement[0].scrollWidth},options:{name:"Scroller",zoom:!1,pullOffset:140,visibleScrollHints:!1,elastic:!0,useNative:!1,mousewheelScrolling:!0,avoidScrolling:function(){return!1},pullToRefresh:!1,messages:{pullTemplate:"Pull to refresh",releaseTemplate:"Release to refresh",refreshTemplate:"Refreshing"}},events:[S,P,A],_resize:function(){this._native||this.contentResized()},setOptions:function(t){var e=this;l.fn.setOptions.call(e,t),t.pullToRefresh&&e._initPullToRefresh()},reset:function(){this._native?this.scrollElement.scrollTop(0):(this.movable.moveTo({x:0,y:0}),this._scale(1))},contentResized:function(){this.dimensions.refresh(),this.pane.x.outOfBounds()&&this.movable.moveAxis("x",this.dimensions.x.min),this.pane.y.outOfBounds()&&this.movable.moveAxis("y",this.dimensions.y.min)},zoomOut:function(){var t=this.dimensions;t.refresh(),this._scale(t.fitScale),this.movable.moveTo(t.centerCoordinates())},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},scrollTo:function(t,e){this._native?(this.scrollElement.scrollLeft(g(t)),this.scrollElement.scrollTop(g(e))):(this.dimensions.refresh(),this.movable.moveTo({x:t,y:e}))},animatedScrollTo:function(t,e,i){var n,o;this._native?this.scrollTo(t,e):(n={x:this.movable.x,y:this.movable.y},o={x:t,y:e},this.animatedScroller.setCoordinates(n,o),this.animatedScroller.setCallback(i),this.animatedScroller.start())},pullHandled:function(){var t=this;t.refreshHint.removeClass(C),t.hintContainer.html(t.pullTemplate({})),t.yinertia.onEnd(),t.xinertia.onEnd(),t.userEvents.cancel()},destroy:function(){l.fn.destroy.call(this),this.userEvents&&this.userEvents.destroy()},_scale:function(t){this.dimensions.rescale(t),this.movable.scaleTo(t)},_initPullToRefresh:function(){var t=this;t.dimensions.y.forceEnabled(),t.pullTemplate=i.template(t.options.messages.pullTemplate),t.releaseTemplate=i.template(t.options.messages.releaseTemplate),t.refreshTemplate=i.template(t.options.messages.refreshTemplate),t.scrollElement.prepend('<span class="km-scroller-pull"><span class="km-icon"></span><span class="km-loading-left"></span><span class="km-loading-right"></span><span class="km-template">'+t.pullTemplate({})+"</span></span>"),t.refreshHint=t.scrollElement.children().first(),t.hintContainer=t.refreshHint.children(".km-template"),t.pane.y.bind("change",s(t._paneChange,t)),t.userEvents.bind("end",s(t._dragEnd,t))},_dragEnd:function(){var t=this;t.pulled&&(t.pulled=!1,t.refreshHint.removeClass(k).addClass(C),t.hintContainer.html(t.refreshTemplate({})),t.yinertia.freeze(t.options.pullOffset/2),t.trigger("pull"))},_paneChange:function(){var t=this;t.movable.y/x>t.options.pullOffset?t.pulled||(t.pulled=!0,t.refreshHint.removeClass(C).addClass(k),t.hintContainer.html(t.releaseTemplate({}))):t.pulled&&(t.pulled=!1,t.refreshHint.removeClass(k),t.hintContainer.html(t.pullTemplate({})))},_initAxis:function(t){var e=this,i=e.movable,n=e.dimensions[t],o=e.tapCapture,r=e.pane[t],s=new B({axis:t,movable:i,dimension:n,container:e.element,alwaysVisible:e.options.visibleScrollHints});n.bind(T,function(){s.refresh()}),r.bind(T,function(){s.show()}),e[t+"inertia"]=new E({axis:t,paneAxis:r,movable:i,tapCapture:o,userEvents:e.userEvents,dimension:n,elastic:e.options.elastic,friction:e.options.friction||_,velocityMultiplier:e.options.velocityMultiplier||y,end:function(){s.hide(),e.trigger("scrollEnd",{axis:t,scrollTop:e.scrollTop,scrollLeft:e.scrollLeft})}})}});r.plugin(z)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.popup.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(e,i){return!(!e||!i)&&(e===i||t.contains(e,i))}var n=window.kendo,o=n.ui,r=o.Widget,s=n.support,a=n.getOffset,l=n._outerWidth,c=n._outerHeight,h="open",u="close",d="deactivate",f="activate",p="center",g="left",m="right",v="top",_="bottom",y="absolute",w="hidden",x="body",b="location",k="position",C="visible",S="effects",T="k-state-active",A="k-state-border",P=/k-state-border-(\w+)/,D=".k-picker-wrap, .k-dropdown-wrap, .k-link",M="down",E=t(document.documentElement),I=t(window),B="scroll",z=s.transitions.css,L=z+"transform",R=t.extend,O=".kendoPopup",V=["font-size","font-family","font-stretch","font-style","font-weight","line-height"],F=r.extend({init:function(e,i){var o,a=this;i=i||{},i.isRtl&&(i.origin=i.origin||_+" "+m,i.position=i.position||v+" "+m),r.fn.init.call(a,e,i),e=a.element,i=a.options,a.collisions=i.collision?i.collision.split(" "):[],a.downEvent=n.applyEventMap(M,n.guid()),1===a.collisions.length&&a.collisions.push(a.collisions[0]),o=t(a.options.anchor).closest(".k-popup,.k-group").filter(":not([class^=km-])"),i.appendTo=t(t(i.appendTo)[0]||o[0]||x),a.element.hide().addClass("k-popup k-group k-reset").toggleClass("k-rtl",!!i.isRtl).css({position:y}).appendTo(i.appendTo).on("mouseenter"+O,function(){a._hovered=!0}).on("mouseleave"+O,function(){a._hovered=!1}),a.wrapper=t(),i.animation===!1&&(i.animation={open:{effects:{}},close:{hide:!0,effects:{}}}),R(i.animation.open,{complete:function(){a.wrapper.css({overflow:C}),a._activated=!0,a._trigger(f)}}),R(i.animation.close,{complete:function(){a._animationClose()}}),a._mousedownProxy=function(t){a._mousedown(t)},a._resizeProxy=s.mobileOS.android?function(t){setTimeout(function(){a._resize(t)},600)}:function(t){a._resize(t)},i.toggleTarget&&t(i.toggleTarget).on(i.toggleEvent+O,t.proxy(a.toggle,a))},events:[h,f,u,d],options:{name:"Popup",toggleEvent:"click",origin:_+" "+g,position:v+" "+g,anchor:x,appendTo:null,collision:"flip fit",viewport:window,copyAnchorStyles:!0,autosize:!1,modal:!1,adjustSize:{width:0,height:0},animation:{open:{effects:"slideIn:down",transition:!0,duration:200},close:{duration:100,hide:!0}}},_animationClose:function(){var t=this,e=t.wrapper.data(b);t.wrapper.hide(),e&&t.wrapper.css(e),t.options.anchor!=x&&t._hideDirClass(),t._closing=!1,t._trigger(d)},destroy:function(){var e,i=this,o=i.options,s=i.element.off(O);r.fn.destroy.call(i),o.toggleTarget&&t(o.toggleTarget).off(O),o.modal||(E.unbind(i.downEvent,i._mousedownProxy),i._toggleResize(!1)),n.destroy(i.element.children()),
s.removeData(),o.appendTo[0]===document.body&&(e=s.parent(".k-animation-container"),e[0]?e.remove():s.remove())},open:function(e,i){var o,r,a=this,l={isFixed:!isNaN(parseInt(i,10)),x:e,y:i},c=a.element,u=a.options,d=t(u.anchor),f=c[0]&&c.hasClass("km-widget");if(!a.visible()){if(u.copyAnchorStyles&&(f&&"font-size"==V[0]&&V.shift(),c.css(n.getComputedStyles(d[0],V))),c.data("animating")||a._trigger(h))return;a._activated=!1,u.modal||(E.unbind(a.downEvent,a._mousedownProxy).bind(a.downEvent,a._mousedownProxy),a._toggleResize(!1),a._toggleResize(!0)),a.wrapper=r=n.wrap(c,u.autosize).css({overflow:w,display:"block",position:y}),s.mobileOS.android&&r.css(L,"translatez(0)"),r.css(k),t(u.appendTo)[0]==document.body&&r.css(v,"-10000px"),a.flipped=a._position(l),o=a._openAnimation(),u.anchor!=x&&a._showDirClass(o),c.data(S,o.effects).kendoStop(!0).kendoAnimate(o)}},_openAnimation:function(){var t=R(!0,{},this.options.animation.open);return t.effects=n.parseEffects(t.effects,this.flipped),t},_hideDirClass:function(){var e=t(this.options.anchor),i=((e.attr("class")||"").match(P)||["","down"])[1],o=A+"-"+i;e.removeClass(o).children(D).removeClass(T).removeClass(o),this.element.removeClass(A+"-"+n.directions[i].reverse)},_showDirClass:function(e){var i=e.effects.slideIn?e.effects.slideIn.direction:"down",o=A+"-"+i;t(this.options.anchor).addClass(o).children(D).addClass(T).addClass(o),this.element.addClass(A+"-"+n.directions[i].reverse)},position:function(){this.visible()&&(this.flipped=this._position())},toggle:function(){var t=this;t[t.visible()?u:h]()},visible:function(){return this.element.is(":"+C)},close:function(i){var o,r,s,a,l=this,c=l.options;if(l.visible()){if(o=l.wrapper[0]?l.wrapper:n.wrap(l.element).hide(),l._toggleResize(!1),l._closing||l._trigger(u))return l._toggleResize(!0),e;l.element.find(".k-popup").each(function(){var e=t(this),n=e.data("kendoPopup");n&&n.close(i)}),E.unbind(l.downEvent,l._mousedownProxy),i?r={hide:!0,effects:{}}:(r=R(!0,{},c.animation.close),s=l.element.data(S),a=r.effects,!a&&!n.size(a)&&s&&n.size(s)&&(r.effects=s,r.reverse=!0),l._closing=!0),l.element.kendoStop(!0),o.css({overflow:w}),l.element.kendoAnimate(r),i&&l._animationClose()}},_trigger:function(t){return this.trigger(t,{type:t})},_resize:function(t){var e=this;s.resize.indexOf(t.type)!==-1?(clearTimeout(e._resizeTimeout),e._resizeTimeout=setTimeout(function(){e._position(),e._resizeTimeout=null},50)):(!e._hovered||e._activated&&e.element.hasClass("k-list-container"))&&e.close()},_toggleResize:function(t){var e=t?"on":"off",i=s.resize;s.mobileOS.ios||s.mobileOS.android||(i+=" "+B),this._scrollableParents()[e](B,this._resizeProxy),I[e](i,this._resizeProxy)},_mousedown:function(e){var o=this,r=o.element[0],s=o.options,a=t(s.anchor)[0],l=s.toggleTarget,c=n.eventTarget(e),h=t(c).closest(".k-popup"),u=h.parent().parent(".km-shim").length;h=h[0],!u&&h&&h!==o.element[0]||"popover"!==t(e.target).closest("a").data("rel")&&(i(r,c)||i(a,c)||l&&i(t(l)[0],c)||o.close())},_fit:function(t,e,i){var n=0;return t+e>i&&(n=i-(t+e)),t<0&&(n=-t),n},_flip:function(t,e,i,n,o,r,s){var a=0;return s=s||e,r!==o&&r!==p&&o!==p&&(t+s>n&&(a+=-(i+e)),t+a<0&&(a+=i+e)),a},_scrollableParents:function(){return t(this.options.anchor).parentsUntil("body").filter(function(t,e){return n.isScrollable(e)})},_position:function(e){var i,o,r,h,u,d,f,p,g,m,v,_,w,x,C,S,T=this,A=T.element,P=T.wrapper,D=T.options,M=t(D.viewport),E=s.zoomLevel(),I=!!(M[0]==window&&window.innerWidth&&E<=1.02),B=t(D.anchor),z=D.origin.toLowerCase().split(" "),L=D.position.toLowerCase().split(" "),O=T.collisions,V=10002,F=0,N=document.documentElement;if(u=D.viewport===window?{top:window.pageYOffset||document.documentElement.scrollTop||0,left:window.pageXOffset||document.documentElement.scrollLeft||0}:M.offset(),I?(d=window.innerWidth,f=window.innerHeight):(d=M.width(),f=M.height()),I&&N.scrollHeight-N.clientHeight>0&&(d-=n.support.scrollbar()),i=B.parents().filter(P.siblings()),i[0])if(r=Math.max(+i.css("zIndex"),0))V=r+10;else for(o=B.parentsUntil(i),h=o.length;F<h;F++)r=+t(o[F]).css("zIndex"),r&&V<r&&(V=r+10);return P.css("zIndex",V),P.css(e&&e.isFixed?{left:e.x,top:e.y}:T._align(z,L)),p=a(P,k,B[0]===P.offsetParent()[0]),g=a(P),m=B.offsetParent().parent(".k-animation-container,.k-popup,.k-group"),m.length&&(p=a(P,k,!0),g=a(P)),g.top-=u.top,g.left-=u.left,T.wrapper.data(b)||P.data(b,R({},p)),v=R({},g),_=R({},p),w=D.adjustSize,"fit"===O[0]&&(_.top+=T._fit(v.top,c(P)+w.height,f/E)),"fit"===O[1]&&(_.left+=T._fit(v.left,l(P)+w.width,d/E)),x=R({},_),C=c(A),S=c(P),!P.height()&&C&&(S+=C),"flip"===O[0]&&(_.top+=T._flip(v.top,C,c(B),f/E,z[0],L[0],S)),"flip"===O[1]&&(_.left+=T._flip(v.left,l(A),l(B),d/E,z[1],L[1],l(P))),A.css(k,y),P.css(_),_.left!=x.left||_.top!=x.top},_align:function(e,i){var n,o=this,r=o.wrapper,s=t(o.options.anchor),h=e[0],u=e[1],d=i[0],f=i[1],g=a(s),v=t(o.options.appendTo),y=l(r),w=c(r),x=l(s),b=c(s),k=g.top,C=g.left,S=Math.round;return v[0]!=document.body&&(n=a(v),k-=n.top,C-=n.left),h===_&&(k+=b),h===p&&(k+=S(b/2)),d===_&&(k-=w),d===p&&(k-=S(w/2)),u===m&&(C+=x),u===p&&(C+=S(x/2)),f===m&&(C-=y),f===p&&(C-=S(y/2)),{top:k,left:C}}});o.plugin(F)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.tooltip.min",["kendo.core.min","kendo.popup.min"],t)}(function(){return function(t,e){function i(t){for(;t.length;)n(t),t=t.parent()}function n(t){var e=t.data(s.ns+"title");e&&(t.attr("title",e),t.removeData(s.ns+"title"))}function o(t){var e=t.attr("title");e&&(t.data(s.ns+"title",e),t.attr("title",""))}function r(t){for(;t.length&&!t.is("body");)o(t),t=t.parent()}var s=window.kendo,a=s.ui.Widget,l=s.ui.Popup,c=s.isFunction,h=t.isPlainObject,u=t.extend,d=t.proxy,f=t(document),p=s.isLocalUrl,g="_tt_active",m="aria-describedby",v="show",_="hide",y="error",w="contentLoad",x="requestStart",b="k-content-frame",k='<div role="tooltip" class="k-widget k-tooltip#if (!autoHide) {# k-tooltip-closable#}#">#if (!autoHide) {# <div class="k-tooltip-button"><a href="\\#" class="k-icon k-i-close">close</a></div> #}#<div class="k-tooltip-content"></div>#if (callout){ #<div class="k-callout k-callout-#=dir#"></div>#}#</div>',C=s.template("<iframe frameborder='0' class='"+b+"' src='#= content.url #'>This page requires frames in order to show content</iframe>"),S=".kendoTooltip",T={bottom:{origin:"bottom center",position:"top center"},top:{origin:"top center",position:"bottom center"},left:{origin:"center left",position:"center right",collision:"fit flip"},right:{origin:"center right",position:"center left",collision:"fit flip"},center:{position:"center center",origin:"center center"}},A={top:"bottom",bottom:"top",left:"right",right:"left",center:"center"},P={bottom:"n",top:"s",left:"e",right:"w",center:"n"},D={horizontal:{offset:"top",size:"outerHeight"},vertical:{offset:"left",size:"outerWidth"}},M=function(t){return t.target.data(s.ns+"title")},E=a.extend({init:function(t,e){var i,n=this;a.fn.init.call(n,t,e),i=n.options.position.match(/left|right/)?"horizontal":"vertical",n.dimensions=D[i],n._documentKeyDownHandler=d(n._documentKeyDown,n),n.element.on(n.options.showOn+S,n.options.filter,d(n._showOn,n)).on("mouseenter"+S,n.options.filter,d(n._mouseenter,n)),this.options.autoHide&&n.element.on("mouseleave"+S,n.options.filter,d(n._mouseleave,n))},options:{name:"Tooltip",filter:"",content:M,showAfter:100,callout:!0,position:"bottom",showOn:"mouseenter",autoHide:!0,width:null,height:null,animation:{open:{effects:"fade:in",duration:0},close:{effects:"fade:out",duration:40,hide:!0}}},events:[v,_,w,y,x],_mouseenter:function(e){r(t(e.currentTarget))},_showOn:function(e){var i=this,n=t(e.currentTarget);i.options.showOn&&i.options.showOn.match(/click|focus/)?i._show(n):(clearTimeout(i.timeout),i.timeout=setTimeout(function(){i._show(n)},i.options.showAfter))},_appendContent:function(t){var e,i=this,n=i.options.content,o=i.content,r=i.options.iframe;h(n)&&n.url?("iframe"in i.options||(r=!p(n.url)),i.trigger(x,{options:n,target:t}),r?(o.hide(),e=o.find("."+b)[0],e?e.src=n.url||e.src:o.html(C({content:n})),o.find("."+b).off("load"+S).on("load"+S,function(){i.trigger(w),o.show()})):(o.empty(),s.ui.progress(o,!0),i._ajaxRequest(n))):n&&c(n)?(n=n({sender:this,target:t}),o.html(n||"")):o.html(n),i.angular("compile",function(){return{elements:o}})},_ajaxRequest:function(t){var e=this;jQuery.ajax(u({type:"GET",dataType:"html",cache:!1,error:function(t,i){s.ui.progress(e.content,!1),e.trigger(y,{status:i,xhr:t})},success:d(function(t){s.ui.progress(e.content,!1),e.content.html(t),e.trigger(w)},e)},t))},_documentKeyDown:function(t){t.keyCode===s.keys.ESC&&this.hide()},refresh:function(){var t=this,e=t.popup;e&&e.options.anchor&&t._appendContent(e.options.anchor)},hide:function(){this.popup&&this.popup.close()},show:function(t){t=t||this.element,r(t),this._show(t)},_show:function(t){var e=this,n=e.target();e.popup||e._initPopup(),n&&n[0]!=t[0]&&(e.popup.close(),e.popup.element.kendoStop(!0,!0)),n&&n[0]==t[0]||(e._appendContent(t),e.popup.options.anchor=t),e.popup.one("deactivate",function(){i(t),t.removeAttr(m),this.element.removeAttr("id").attr("aria-hidden",!0),f.off("keydown"+S,e._documentKeyDownHandler)}),e.popup.open()},_initPopup:function(){var e=this,i=e.options,n=t(s.template(k)({callout:i.callout&&"center"!==i.position,dir:P[i.position],autoHide:i.autoHide}));e.popup=new l(n,u({activate:function(){var t=this.options.anchor,n=t[0].id||e.element[0].id;n&&(t.attr(m,n+g),this.element.attr("id",n+g)),i.callout&&e._positionCallout(),this.element.removeAttr("aria-hidden"),f.on("keydown"+S,e._documentKeyDownHandler),e.trigger(v)},close:function(){e.trigger(_)},copyAnchorStyles:!1,animation:i.animation},T[i.position])),n.css({width:i.width,height:i.height}),e.content=n.find(".k-tooltip-content"),e.arrow=n.find(".k-callout"),i.autoHide?n.on("mouseleave"+S,d(e._mouseleave,e)):n.on("click"+S,".k-tooltip-button",d(e._closeButtonClick,e))},_closeButtonClick:function(t){t.preventDefault(),this.hide()},_mouseleave:function(e){if(this.popup){var n=t(e.currentTarget),o=n.offset(),r=e.pageX,a=e.pageY;if(o.right=o.left+s._outerWidth(n),o.bottom=o.top+s._outerHeight(n),r>o.left&&r<o.right&&a>o.top&&a<o.bottom)return;this.popup.close()}else i(t(e.currentTarget));clearTimeout(this.timeout)},_positionCallout:function(){var e=this,i=e.options.position,n=e.dimensions,o=n.offset,r=e.popup,s=r.options.anchor,a=t(s).offset(),l=parseInt(e.arrow.css("border-top-width"),10),c=t(r.element).offset(),h=P[r.flipped?A[i]:i],u=a[o]-c[o]+t(s)[n.size]()/2-l;e.arrow.removeClass("k-callout-n k-callout-s k-callout-w k-callout-e").addClass("k-callout-"+h).css(o,u)},target:function(){return this.popup?this.popup.options.anchor:null},destroy:function(){var t=this.popup;t&&(t.element.off(S),t.destroy()),clearTimeout(this.timeout),this.element.off(S),f.off("keydown"+S,this._documentKeyDownHandler),a.fn.destroy.call(this)}});s.ui.plugin(E)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.color.min",["kendo.core.min"],t)}(function(){!function(t,e,i){function n(t,o){var r,a;if(null==t||"none"==t)return null;if(t instanceof l)return t;if(t=t.toLowerCase(),r=s.exec(t))return t="transparent"==r[1]?new c(1,1,1,0):n(f.namedColors[r[1]],o),t.match=[r[1]],t;if((r=/^#?([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})\b/i.exec(t))?a=new h(i(r[1],16),i(r[2],16),i(r[3],16),1):(r=/^#?([0-9a-f])([0-9a-f])([0-9a-f])\b/i.exec(t))?a=new h(i(r[1]+r[1],16),i(r[2]+r[2],16),i(r[3]+r[3],16),1):(r=/^rgb\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*\)/.exec(t))?a=new h(i(r[1],10),i(r[2],10),i(r[3],10),1):(r=/^rgba\(\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9.]+)\s*\)/.exec(t))?a=new h(i(r[1],10),i(r[2],10),i(r[3],10),e(r[4])):(r=/^rgb\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*\)/.exec(t))?a=new c(e(r[1])/100,e(r[2])/100,e(r[3])/100,1):(r=/^rgba\(\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9]*\.?[0-9]+)%\s*,\s*([0-9.]+)\s*\)/.exec(t))&&(a=new c(e(r[1])/100,e(r[2])/100,e(r[3])/100,e(r[4]))),a)a.match=r;else if(!o)throw Error("Cannot parse color: "+t);return a}function o(t,e,i){for(i||(i="0"),t=t.toString(16);e>t.length;)t="0"+t;return t}function r(t,e,i){return i<0&&(i+=1),i>1&&(i-=1),i<1/6?t+6*(e-t)*i:i<.5?e:i<2/3?t+(e-t)*(2/3-i)*6:t}var s,a,l,c,h,u,d,f=function(t){var e,i,n,o,r,s=this,a=f.formats;if(1===arguments.length)for(t=s.resolveColor(t),o=0;o<a.length;o++)e=a[o].re,i=a[o].process,n=e.exec(t),n&&(r=i(n),s.r=r[0],s.g=r[1],s.b=r[2]);else s.r=arguments[0],s.g=arguments[1],s.b=arguments[2];s.r=s.normalizeByte(s.r),s.g=s.normalizeByte(s.g),s.b=s.normalizeByte(s.b)};f.prototype={toHex:function(){var t=this,e=t.padDigit,i=t.r.toString(16),n=t.g.toString(16),o=t.b.toString(16);return"#"+e(i)+e(n)+e(o)},resolveColor:function(t){return t=t||"black","#"==t.charAt(0)&&(t=t.substr(1,6)),t=t.replace(/ /g,""),t=t.toLowerCase(),t=f.namedColors[t]||t},normalizeByte:function(t){return t<0||isNaN(t)?0:t>255?255:t},padDigit:function(t){return 1===t.length?"0"+t:t},brightness:function(t){var e=this,i=Math.round;return e.r=i(e.normalizeByte(e.r*t)),e.g=i(e.normalizeByte(e.g*t)),e.b=i(e.normalizeByte(e.b*t)),e},percBrightness:function(){var t=this;return Math.sqrt(.241*t.r*t.r+.691*t.g*t.g+.068*t.b*t.b)}},f.formats=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,process:function(t){return[i(t[1],10),i(t[2],10),i(t[3],10)]}},{re:/^(\w{2})(\w{2})(\w{2})$/,process:function(t){return[i(t[1],16),i(t[2],16),i(t[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,process:function(t){return[i(t[1]+t[1],16),i(t[2]+t[2],16),i(t[3]+t[3],16)]}}],f.namedColors={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgrey:"a9a9a9",darkgreen:"006400",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:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",grey:"808080",green:"008000",greenyellow:"adff2f",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",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"778899",lightslategrey:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",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:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",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:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"},s=["transparent"];for(a in f.namedColors)f.namedColors.hasOwnProperty(a)&&s.push(a);s=RegExp("^("+s.join("|")+")(\\W|$)","i"),l=kendo.Class.extend({toHSV:function(){return this},toRGB:function(){return this},toHex:function(){return this.toBytes().toHex()},toBytes:function(){return this},toCss:function(){return"#"+this.toHex()},toCssRgba:function(){var t=this.toBytes();return"rgba("+t.r+", "+t.g+", "+t.b+", "+e((+this.a).toFixed(3))+")"},toDisplay:function(){return kendo.support.browser.msie&&kendo.support.browser.version<9?this.toCss():this.toCssRgba()},equals:function(t){return t===this||null!==t&&this.toCssRgba()==n(t).toCssRgba()},diff:function(t){if(null==t)return NaN;var e=this.toBytes();return t=t.toBytes(),Math.sqrt(Math.pow(.3*(e.r-t.r),2)+Math.pow(.59*(e.g-t.g),2)+Math.pow(.11*(e.b-t.b),2))},clone:function(){var t=this.toBytes();return t===this&&(t=new h(t.r,t.g,t.b,t.a)),t}}),c=l.extend({init:function(t,e,i,n){this.r=t,this.g=e,this.b=i,this.a=n},toHSV:function(){var t,e,i=this.r,n=this.g,o=this.b,r=Math.min(i,n,o),s=Math.max(i,n,o),a=s,l=s-r;return 0===l?new u(0,0,a,this.a):(0!==s?(e=l/s,t=i==s?(n-o)/l:n==s?2+(o-i)/l:4+(i-n)/l,t*=60,t<0&&(t+=360)):(e=0,t=-1),new u(t,e,a,this.a))},toHSL:function(){var t,e,i,n=this.r,o=this.g,r=this.b,s=Math.max(n,o,r),a=Math.min(n,o,r),l=(s+a)/2;if(s==a)t=e=0;else{switch(i=s-a,e=l>.5?i/(2-s-a):i/(s+a),s){case n:t=(o-r)/i+(o<r?6:0);break;case o:t=(r-n)/i+2;break;case r:t=(n-o)/i+4}t*=60,e*=100,l*=100}return new d(t,e,l,this.a)},toBytes:function(){return new h(255*this.r,255*this.g,255*this.b,this.a)}}),h=c.extend({init:function(t,e,i,n){this.r=Math.round(t),this.g=Math.round(e),this.b=Math.round(i),this.a=n},toRGB:function(){return new c(this.r/255,this.g/255,this.b/255,this.a)},toHSV:function(){return this.toRGB().toHSV()},toHSL:function(){return this.toRGB().toHSL()},toHex:function(){return o(this.r,2)+o(this.g,2)+o(this.b,2)},toBytes:function(){return this}}),u=l.extend({init:function(t,e,i,n){this.h=t,this.s=e,this.v=i,this.a=n},toRGB:function(){var t,e,i,n,o,r,s,a,l=this.h,h=this.s,u=this.v;if(0===h)e=i=n=u;else switch(l/=60,t=Math.floor(l),o=l-t,r=u*(1-h),s=u*(1-h*o),a=u*(1-h*(1-o)),t){case 0:e=u,i=a,n=r;break;case 1:e=s,i=u,n=r;break;case 2:e=r,i=u,n=a;break;case 3:e=r,i=s,n=u;break;case 4:e=a,i=r,n=u;break;default:e=u,i=r,n=s}return new c(e,i,n,this.a)},toHSL:function(){return this.toRGB().toHSL()},toBytes:function(){return this.toRGB().toBytes()}}),d=l.extend({init:function(t,e,i,n){this.h=t,this.s=e,this.l=i,this.a=n},toRGB:function(){var t,e,i,n,o,s=this.h,a=this.s,l=this.l;return 0===a?t=e=i=l:(s/=360,a/=100,l/=100,n=l<.5?l*(1+a):l+a-l*a,o=2*l-n,t=r(o,n,s+1/3),e=r(o,n,s),i=r(o,n,s-1/3)),new c(t,e,i,this.a)},toHSV:function(){return this.toRGB().toHSV()},toBytes:function(){return this.toRGB().toBytes()}}),f.fromBytes=function(t,e,i,n){return new h(t,e,i,null!=n?n:1)},f.fromRGB=function(t,e,i,n){return new c(t,e,i,null!=n?n:1)},f.fromHSV=function(t,e,i,n){return new u(t,e,i,null!=n?n:1)},f.fromHSL=function(t,e,i,n){return new d(t,e,i,null!=n?n:1)},kendo.Color=f,kendo.parseColor=n}(window.kendo.jQuery,parseFloat,parseInt)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("util/main.min",["kendo.core.min"],t)}(function(){return function(){function t(t){return typeof t!==F}function e(t,e){var n=i(e);return B.round(t*n)/n}function i(t){return t?B.pow(10,t):1}function n(t,e,i){return B.max(B.min(t,i),e)}function o(t){return t*R}function r(t){return t/R}function s(t){return"number"==typeof t&&!isNaN(t)}function a(e,i){return t(e)?e:i}function l(t){return t*t}function c(t){var e,i=[];for(e in t)i.push(e+t[e]);return i.sort().join("")}function h(t){var e,i=2166136261;for(e=0;e<t.length;++e)i+=(i<<1)+(i<<4)+(i<<7)+(i<<8)+(i<<24),i^=t.charCodeAt(e);return i>>>0}function u(t){return h(c(t))}function d(t){var e,i=t.length,n=O,o=V;for(e=0;e<i;e++)o=B.max(o,t[e]),n=B.min(n,t[e]);return{min:n,max:o}}function f(t){return d(t).min}function p(t){return d(t).max}function g(t){return v(t).min}function m(t){return v(t).max}function v(t){var e,i,n,o=O,r=V;for(e=0,i=t.length;e<i;e++)n=t[e],null!==n&&isFinite(n)&&(o=B.min(o,n),r=B.max(r,n));return{min:o===O?void 0:o,max:r===V?void 0:r}}function _(t){if(t)return t[t.length-1]}function y(t,e){return t.push.apply(t,e),t}function w(t){return z.template(t,{useWithBlock:!1,paramName:"d"})}function x(e,i){return t(i)&&null!==i?" "+e+"='"+i+"' ":""}function b(t){var e,i="";for(e=0;e<t.length;e++)i+=x(t[e][0],t[e][1]);return i}function k(e){var i,n,o="";for(i=0;i<e.length;i++)n=e[i][1],t(n)&&(o+=e[i][0]+":"+n+";");if(""!==o)return o}function C(t){return"string"!=typeof t&&(t+="px"),t}function S(t){var e,i,n=[];if(t)for(e=z.toHyphens(t).split("-"),i=0;i<e.length;i++)n.push("k-pos-"+e[i]);return n.join(" ")}function T(e){return""===e||null===e||"none"===e||"transparent"===e||!t(e)}function A(t){for(var e={1:"i",10:"x",100:"c",2:"ii",20:"xx",200:"cc",3:"iii",30:"xxx",300:"ccc",4:"iv",40:"xl",400:"cd",5:"v",50:"l",500:"d",6:"vi",60:"lx",600:"dc",7:"vii",70:"lxx",700:"dcc",8:"viii",80:"lxxx",800:"dccc",9:"ix",90:"xc",900:"cm",1e3:"m"},i=[1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],n="";t>0;)t<i[0]?i.shift():(n+=e[i[0]],t-=i[0]);return n}function P(t){var e,i,n,o,r;for(t=t.toLowerCase(),e={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3},i=0,n=0,o=0;o<t.length;++o){if(r=e[t.charAt(o)],!r)return null;i+=r,r>n&&(i-=2*n),n=r}return i}function D(t){var e=Object.create(null);return function(){var i,n="";for(i=arguments.length;--i>=0;)n+=":"+arguments[i];return n in e?e[n]:e[n]=t.apply(this,arguments)}}function M(t){for(var e,i,n=[],o=0,r=t.length;o<r;)e=t.charCodeAt(o++),e>=55296&&e<=56319&&o<r?(i=t.charCodeAt(o++),56320==(64512&i)?n.push(((1023&e)<<10)+(1023&i)+65536):(n.push(e),o--)):n.push(e);return n}function E(t){return t.map(function(t){var e="";return t>65535&&(t-=65536,e+=String.fromCharCode(t>>>10&1023|55296),t=56320|1023&t),e+=String.fromCharCode(t)}).join("")}function I(t,e){function i(t,i){for(var n=[],o=0,r=0,s=0;o<t.length&&r<i.length;)e(t[o],i[r])<=0?n[s++]=t[o++]:n[s++]=i[r++];return o<t.length&&n.push.apply(n,t.slice(o)),r<i.length&&n.push.apply(n,i.slice(r)),n}return t.length<2?t.slice():function n(t){var e,o,r;return t.length<=1?t:(e=Math.floor(t.length/2),o=t.slice(0,e),r=t.slice(e),o=n(o),r=n(r),i(o,r))}(t)}var B=Math,z=window.kendo,L=z.deepExtend,R=B.PI/180,O=Number.MAX_VALUE,V=-Number.MAX_VALUE,F="undefined",N=Date.now;N||(N=function(){return(new Date).getTime()}),L(z,{util:{MAX_NUM:O,MIN_NUM:V,append:y,arrayLimits:d,arrayMin:f,arrayMax:p,defined:t,deg:r,hashKey:h,hashObject:u,isNumber:s,isTransparent:T,last:_,limitValue:n,now:N,objectKey:c,round:e,rad:o,renderAttr:x,renderAllAttr:b,renderPos:S,renderSize:C,renderStyle:k,renderTemplate:w,sparseArrayLimits:v,sparseArrayMin:g,sparseArrayMax:m,sqr:l,valueOrDefault:a,romanToArabic:P,arabicToRoman:A,memoize:D,ucs2encode:E,ucs2decode:M,mergeSort:I}}),z.drawing.util=z.util,z.dataviz.util=z.util}(),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("util/text-metrics.min",["kendo.core.min","util/main.min"],t)}(function(){!function(t){function e(){return{width:0,height:0,baseline:0}}function i(t,e,i){return u.current.measure(t,e,i)}function n(t,e){var i=[];if(t.length>0&&document.fonts){try{i=t.map(function(t){return document.fonts.load(t)})}catch(n){r.logToConsole(n)}Promise.all(i).then(e,e)}else e()}var o=document,r=window.kendo,s=r.Class,a=r.util,l=a.defined,c=s.extend({init:function(t){this._size=t,this._length=0,this._map={}},put:function(t,e){var i=this,n=i._map,o={key:t,value:e};n[t]=o,i._head?(i._tail.newer=o,o.older=i._tail,i._tail=o):i._head=i._tail=o,i._length>=i._size?(n[i._head.key]=null,i._head=i._head.newer,i._head.older=null):i._length++},get:function(t){var e=this,i=e._map[t];if(i)return i===e._head&&i!==e._tail&&(e._head=i.newer,e._head.older=null),i!==e._tail&&(i.older&&(i.older.newer=i.newer,i.newer.older=i.older),i.older=e._tail,i.newer=null,e._tail.newer=i,e._tail=i),i.value}}),h=t("<div style='position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;padding: 0 !important; margin: 0 !important; border: 0 !important;line-height: normal !important; visibility: hidden !important; white-space: nowrap!important;' />")[0],u=s.extend({init:function(t){this._cache=new c(1e3),this._initOptions(t)},options:{baselineMarkerSize:1},measure:function(i,n,r){var s,c,u,d,f,p,g,m;if(!i)return e();if(s=a.objectKey(n),c=a.hashKey(i+s),u=this._cache.get(c),u)return u;d=e(),f=r?r:h,p=this._baselineMarker().cloneNode(!1);for(g in n)m=n[g],l(m)&&(f.style[g]=m);return t(f).text(i),f.appendChild(p),o.body.appendChild(f),(i+"").length&&(d.width=f.offsetWidth-this.options.baselineMarkerSize,d.height=f.offsetHeight,d.baseline=p.offsetTop+this.options.baselineMarkerSize),d.width>0&&d.height>0&&this._cache.put(c,d),f.parentNode.removeChild(f),d},_baselineMarker:function(){return t("<div class='k-baseline-marker' style='display: inline-block; vertical-align: baseline;width: "+this.options.baselineMarkerSize+"px; height: "+this.options.baselineMarkerSize+"px;overflow: hidden;' />")[0]}});u.current=new u,r.util.TextMetrics=u,r.util.LRUCache=c,r.util.loadFonts=n,r.util.measureText=i}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("util/base64.min",["util/main.min"],t)}(function(){return function(){function t(t){var i,n,o,s,a,l,c,h="",u=0;for(t=e(t);u<t.length;)i=t.charCodeAt(u++),n=t.charCodeAt(u++),o=t.charCodeAt(u++),s=i>>2,a=(3&i)<<4|n>>4,l=(15&n)<<2|o>>6,c=63&o,isNaN(n)?l=c=64:isNaN(o)&&(c=64),h=h+r.charAt(s)+r.charAt(a)+r.charAt(l)+r.charAt(c);return h}function e(t){var e,i,n="";for(e=0;e<t.length;e++)i=t.charCodeAt(e),i<128?n+=o(i):i<2048?(n+=o(192|i>>>6),n+=o(128|63&i)):i<65536&&(n+=o(224|i>>>12),n+=o(128|i>>>6&63),n+=o(128|63&i));return n}var i=window.kendo,n=i.deepExtend,o=String.fromCharCode,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";n(i.util,{encodeBase64:t,encodeUTF8:e})}(),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("mixins/observers.min",["kendo.core.min"],t)}(function(){return function(t){var e=Math,i=window.kendo,n=i.deepExtend,o=t.inArray,r={observers:function(){return this._observers=this._observers||[]},addObserver:function(t){return this._observers?this._observers.push(t):this._observers=[t],this},removeObserver:function(t){var e=this.observers(),i=o(t,e);return i!=-1&&e.splice(i,1),this},trigger:function(t,e){var i,n,o=this._observers;if(o&&!this._suspended)for(n=0;n<o.length;n++)i=o[n],i[t]&&i[t](e);return this},optionsChange:function(t){t=t||{},t.element=this,this.trigger("optionsChange",t)},geometryChange:function(){this.trigger("geometryChange",{element:this})},suspend:function(){return this._suspended=(this._suspended||0)+1,this},resume:function(){return this._suspended=e.max((this._suspended||0)-1,0),this},_observerField:function(t,e){this[t]&&this[t].removeObserver(this),this[t]=e,e.addObserver(this)}};n(i,{mixins:{ObserversMixin:r}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/geometry.min",["util/main.min","mixins/observers.min"],t)}(function(){return function(){function t(t){return null===t?null:t instanceof A?t:new A(t)}function e(t){return t&&E.isFunction(t.matrix)?t.matrix():t}function i(t,e,i,n){var o=0,r=0;return n&&(o=D.atan2(n.c*i,n.a*e),0!==n.b&&(r=D.atan2(n.d*i,n.b*e))),{x:o,y:r}}function n(t,e){for(;t<e;)t+=90;return t}function o(t,e){var i,n,o;for(i=0;i<e.length;i++)n=e[i],o=n.charAt(0).toUpperCase()+n.substring(1,n.length),t["set"+o]=r(n),t["get"+o]=s(n)}function r(t){return function(e){return this[t]!==e&&(this[t]=e,this.geometryChange()),this}}function s(t){return function(){return this[t]}}function a(t,e,i){t>e&&(e+=360);var n=D.abs(e-t);return i||(n=360-n),n}function l(t,e,i,n,o,r){var s=F((o-t)/i,3),a=F((r-e)/n,3);return F(V(D.atan2(a,s)))}function c(t,e,i,n,o,r,s,c){var h,u,d,f,p,g,m,v,_,y,w,x,b,k,C,S,T,A;if(e!==n)_=i-t,y=n-e,w=M(o,2),x=M(r,2),b=(x*_*(t+i)+w*y*(e+n))/(2*w*y),k=b-n,C=-(_*x)/(w*y),p=1/w+M(C,2)/x,g=2*(C*k/x-i/w),m=M(i,2)/w+M(k,2)/x-1,v=D.sqrt(M(g,2)-4*p*m),h=(-g-v)/(2*p),u=b+C*h,d=(-g+v)/(2*p),f=b+C*d;else{if(t===i)return!1;g=-2*n,m=M((i-t)*r/(2*o),2)+M(n,2)-M(r,2),v=D.sqrt(M(g,2)-4*m),h=d=(t+i)/2,u=(-g-v)/2,f=(-g+v)/2}return S=l(h,u,o,r,t,e),T=l(h,u,o,r,i,n),A=a(S,T,c),(s&&A<=180||!s&&A>180)&&(h=d,u=f,S=l(h,u,o,r,t,e),T=l(h,u,o,r,i,n)),{center:new G(h,u),startAngle:S,endAngle:T}}function h(t,e,i,n){if(0===t)return x(e,i,n);var o,r,s,a,l,c,h,u=(3*t*i-D.pow(e,2))/(3*D.pow(t,2)),d=(2*D.pow(e,3)-9*t*e*i+27*D.pow(t,2)*n)/(27*D.pow(t,3)),f=D.pow(u/3,3)+D.pow(d/2,2),p=new P(0,1),g=-e/(3*t),m=[];return f<0?(o=new P(-d/2,D.sqrt(-f)).nthRoot(3),r=new P(-d/2,(-D.sqrt(-f))).nthRoot(3)):(o=-d/2+D.sqrt(f),o=new P(_(o)*D.pow(D.abs(o),1/3)),r=-d/2-D.sqrt(f),r=new P(_(r)*D.pow(D.abs(r),1/3))),s=o.add(r),c=o.add(r).multiplyConstant(-.5),h=o.add(r.negate()).multiplyConstant(D.sqrt(3)/2),a=c.add(p.multiply(h)),l=c.add(p.negate().multiply(h)),s.isReal()&&m.push(F(s.real+g,j)),a.isReal()&&m.push(F(a.real+g,j)),l.isReal()&&m.push(F(l.real+g,j)),m}function u(t,e){return[-t[0][e]+3*t[1][e]-3*t[2][e]+t[3][e],3*(t[0][e]-2*t[1][e]+t[2][e]),3*(-t[0][e]+t[1][e]),t[0][e]]}function d(t,e,i){var n=1-t;return D.pow(n,3)*i[0][e]+3*D.pow(n,2)*t*i[1][e]+3*D.pow(t,2)*n*i[2][e]+D.pow(t,3)*i[3][e]}function f(t,e,i){var n,o,r,s=u(t,"x"),a=h(s[0],s[1],s[2],s[3]-e.x),l=0;for(r=0;r<a.length;r++)n=d(a[r],"y",t),o=m(n,e.y)||n>e.y,o&&((0===a[r]||1===a[r])&&i.bottomRight().x>e.x||0<a[r]&&a[r]<1)&&l++;return l}function p(t,e,i){var n,o,r,s,a,l;return t.x!=e.x&&(o=D.min(t.x,e.x),r=D.max(t.x,e.x),s=D.min(t.y,e.y),a=D.max(t.y,e.y),l=o<=i.x&&i.x<r,n=s==a?i.y<=s&&l:l&&(a-s)*((t.x-e.x)*(t.y-e.y)>0?i.x-o:r-i.x)/(r-o)+s-i.y>=0),n?1:0}function g(t,e,i,n){var o=e.x-t.x,r=n.x-i.x,s=e.y-t.y,a=n.y-i.y,l=t.x-i.x,c=t.y-i.y,h=o*a-r*s,u=(o*c-s*l)/h,d=(r*c-a*l)/h;if(u>=0&&u<=1&&d>=0&&d<=1)return new G(t.x+d*o,t.y+d*s)}function m(t,e,i){return 0===F(D.abs(t-e),i||j)}function v(t,e,i){return t<e||m(t,e,i)}function _(t){return t<0?-1:1}function y(e,i,n){var o=L.deg(D.atan2(i.y-e.y,i.x-e.x)),r=n.transformCopy(t().rotate(-o,e));return r.x<e.x}function w(t,e,i,n,o){var r,s,a=u(t,n),l=h(a[0],a[1],a[2],a[3]-e[n]);for(s=0;s<l.length;s++)if(0<=l[s]&&l[s]<=1&&(r=d(l[s],i,t),D.abs(r-e[i])<=o))return!0}function x(t,e,i){var n=D.sqrt(D.pow(e,2)-4*t*i);return[(-e+n)/(2*t),(-e-n)/(2*t)]}var b,k,C,S,T,A,P,D=Math,M=D.pow,E=window.kendo,I=E.Class,B=E.deepExtend,z=E.mixins.ObserversMixin,L=E.util,R=L.defined,O=L.rad,V=L.deg,F=L.round,N=D.PI/2,H=L.MIN_NUM,U=L.MAX_NUM,j=10,G=I.extend({init:function(t,e){this.x=t||0,this.y=e||0},equals:function(t){return t&&t.x===this.x&&t.y===this.y},clone:function(){return new G(this.x,this.y)},rotate:function(e,i){return this.transform(t().rotate(e,i))},translate:function(t,e){return this.x+=t,this.y+=e,this.geometryChange(),this},translateWith:function(t){return this.translate(t.x,t.y)},move:function(t,e){return this.x=this.y=0,this.translate(t,e)},scale:function(t,e){return R(e)||(e=t),this.x*=t,this.y*=e,this.geometryChange(),this},scaleCopy:function(t,e){return this.clone().scale(t,e)},transform:function(t){var i=e(t),n=this.x,o=this.y;return this.x=i.a*n+i.c*o+i.e,this.y=i.b*n+i.d*o+i.f,this.geometryChange(),
this},transformCopy:function(t){var e=this.clone();return t&&e.transform(t),e},distanceTo:function(t){var e=this.x-t.x,i=this.y-t.y;return D.sqrt(e*e+i*i)},round:function(t){return this.x=F(this.x,t),this.y=F(this.y,t),this.geometryChange(),this},toArray:function(t){var e=R(t),i=e?F(this.x,t):this.x,n=e?F(this.y,t):this.y;return[i,n]}});o(G.fn,["x","y"]),B(G.fn,z),G.fn.toString=function(t,e){var i=this.x,n=this.y;return R(t)&&(i=F(i,t),n=F(n,t)),e=e||" ",i+e+n},G.create=function(t,e){if(R(t))return t instanceof G?t:1===arguments.length&&2===t.length?new G(t[0],t[1]):new G(t,e)},G.min=function(){var t,e,i=L.MAX_NUM,n=L.MAX_NUM;for(t=0;t<arguments.length;t++)e=arguments[t],i=D.min(e.x,i),n=D.min(e.y,n);return new G(i,n)},G.max=function(){var t,e,i=L.MIN_NUM,n=L.MIN_NUM;for(t=0;t<arguments.length;t++)e=arguments[t],i=D.max(e.x,i),n=D.max(e.y,n);return new G(i,n)},G.minPoint=function(){return new G(H,H)},G.maxPoint=function(){return new G(U,U)},G.ZERO=new G(0,0),b=I.extend({init:function(t,e){this.width=t||0,this.height=e||0},equals:function(t){return t&&t.width===this.width&&t.height===this.height},clone:function(){return new b(this.width,this.height)},toArray:function(t){var e=R(t),i=e?F(this.width,t):this.width,n=e?F(this.height,t):this.height;return[i,n]}}),o(b.fn,["width","height"]),B(b.fn,z),b.create=function(t,e){if(R(t))return t instanceof b?t:1===arguments.length&&2===t.length?new b(t[0],t[1]):new b(t,e)},b.ZERO=new b(0,0),k=I.extend({init:function(t,e){this.setOrigin(t||new G),this.setSize(e||new b)},clone:function(){return new k(this.origin.clone(),this.size.clone())},equals:function(t){return t&&t.origin.equals(this.origin)&&t.size.equals(this.size)},setOrigin:function(t){return this._observerField("origin",G.create(t)),this.geometryChange(),this},getOrigin:function(){return this.origin},setSize:function(t){return this._observerField("size",b.create(t)),this.geometryChange(),this},getSize:function(){return this.size},width:function(){return this.size.width},height:function(){return this.size.height},topLeft:function(){return this.origin.clone()},bottomRight:function(){return this.origin.clone().translate(this.width(),this.height())},topRight:function(){return this.origin.clone().translate(this.width(),0)},bottomLeft:function(){return this.origin.clone().translate(0,this.height())},center:function(){return this.origin.clone().translate(this.width()/2,this.height()/2)},bbox:function(t){var e=this.topLeft().transformCopy(t),i=this.topRight().transformCopy(t),n=this.bottomRight().transformCopy(t),o=this.bottomLeft().transformCopy(t);return k.fromPoints(e,i,n,o)},transformCopy:function(t){return k.fromPoints(this.topLeft().transform(t),this.bottomRight().transform(t))},expand:function(t,e){return R(e)||(e=t),this.size.width+=2*t,this.size.height+=2*e,this.origin.translate(-t,-e),this},expandCopy:function(t,e){return this.clone().expand(t,e)},containsPoint:function(t){var e=this.origin,i=this.bottomRight();return!(t.x<e.x||t.y<e.y||i.x<t.x||i.y<t.y)},_isOnPath:function(t,e){var i=this.expandCopy(e,e),n=this.expandCopy(-e,-e);return i.containsPoint(t)&&!n.containsPoint(t)}}),B(k.fn,z),k.fromPoints=function(){var t=G.min.apply(this,arguments),e=G.max.apply(this,arguments),i=new b(e.x-t.x,e.y-t.y);return new k(t,i)},k.union=function(t,e){return k.fromPoints(G.min(t.topLeft(),e.topLeft()),G.max(t.bottomRight(),e.bottomRight()))},k.intersect=function(t,e){if(t={left:t.topLeft().x,top:t.topLeft().y,right:t.bottomRight().x,bottom:t.bottomRight().y},e={left:e.topLeft().x,top:e.topLeft().y,right:e.bottomRight().x,bottom:e.bottomRight().y},t.left<=e.right&&e.left<=t.right&&t.top<=e.bottom&&e.top<=t.bottom)return k.fromPoints(new G(D.max(t.left,e.left),D.max(t.top,e.top)),new G(D.min(t.right,e.right),D.min(t.bottom,e.bottom)))},C=I.extend({init:function(t,e){this.setCenter(t||new G),this.setRadius(e||0)},setCenter:function(t){return this._observerField("center",G.create(t)),this.geometryChange(),this},getCenter:function(){return this.center},equals:function(t){return t&&t.center.equals(this.center)&&t.radius===this.radius},clone:function(){return new C(this.center.clone(),this.radius)},pointAt:function(t){return this._pointAt(O(t))},bbox:function(t){var e,n,o,r,s=G.maxPoint(),a=G.minPoint(),l=i(this.center,this.radius,this.radius,t);for(e=0;e<4;e++)n=this._pointAt(l.x+e*N).transformCopy(t),o=this._pointAt(l.y+e*N).transformCopy(t),r=new G(n.x,o.y),s=G.min(s,r),a=G.max(a,r);return k.fromPoints(s,a)},_pointAt:function(t){var e=this.center,i=this.radius;return new G(e.x-i*D.cos(t),e.y-i*D.sin(t))},containsPoint:function(t){var e=this.center,i=D.pow(t.x-e.x,2)+D.pow(t.y-e.y,2)<=D.pow(this.radius,2);return i},_isOnPath:function(t,e){var i=this.center,n=this.radius,o=i.distanceTo(t);return n-e<=o&&o<=n+e}}),o(C.fn,["radius"]),B(C.fn,z),S=I.extend({init:function(t,e){this.setCenter(t||new G),e=e||{},this.radiusX=e.radiusX,this.radiusY=e.radiusY||e.radiusX,this.startAngle=e.startAngle,this.endAngle=e.endAngle,this.anticlockwise=e.anticlockwise||!1},clone:function(){return new S(this.center,{radiusX:this.radiusX,radiusY:this.radiusY,startAngle:this.startAngle,endAngle:this.endAngle,anticlockwise:this.anticlockwise})},setCenter:function(t){return this._observerField("center",G.create(t)),this.geometryChange(),this},getCenter:function(){return this.center},MAX_INTERVAL:45,pointAt:function(t){var e=this.center,i=O(t);return new G(e.x+this.radiusX*D.cos(i),e.y+this.radiusY*D.sin(i))},curvePoints:function(){var t,e,i,n=this.startAngle,o=this.anticlockwise?-1:1,r=[this.pointAt(n)],s=n,a=this._arcInterval(),l=a.endAngle-a.startAngle,c=D.ceil(l/this.MAX_INTERVAL),h=l/c;for(t=1;t<=c;t++)e=s+o*h,i=this._intervalCurvePoints(s,e),r.push(i.cp1,i.cp2,i.p2),s=e;return r},bbox:function(t){for(var e,o,r=this,s=r._arcInterval(),a=s.startAngle,l=s.endAngle,c=i(this.center,this.radiusX,this.radiusY,t),h=V(c.x),u=V(c.y),d=r.pointAt(a).transformCopy(t),f=r.pointAt(l).transformCopy(t),p=G.min(d,f),g=G.max(d,f),m=n(h,a),v=n(u,a);m<l||v<l;)m<l&&(e=r.pointAt(m).transformCopy(t),m+=90),v<l&&(o=r.pointAt(v).transformCopy(t),v+=90),d=new G(e.x,o.y),p=G.min(p,d),g=G.max(g,d);return k.fromPoints(p,g)},_arcInterval:function(){var t,e=this.startAngle,i=this.endAngle,n=this.anticlockwise;return n&&(t=e,e=i,i=t),(e>i||n&&e===i)&&(i+=360),{startAngle:e,endAngle:i}},_intervalCurvePoints:function(t,e){var i=this,n=i.pointAt(t),o=i.pointAt(e),r=i._derivativeAt(t),s=i._derivativeAt(e),a=(O(e)-O(t))/3,l=new G(n.x+a*r.x,n.y+a*r.y),c=new G(o.x-a*s.x,o.y-a*s.y);return{p1:n,cp1:l,cp2:c,p2:o}},_derivativeAt:function(t){var e=this,i=O(t);return new G(-e.radiusX*D.sin(i),e.radiusY*D.cos(i))},containsPoint:function(t){var e,i,n,o=this._arcInterval(),r=o.endAngle-o.startAngle,s=this.center,a=s.distanceTo(t),c=D.atan2(t.y-s.y,t.x-s.x),h=this.radiusX*this.radiusY/D.sqrt(D.pow(this.radiusX,2)*D.pow(D.sin(c),2)+D.pow(this.radiusY,2)*D.pow(D.cos(c),2)),u=this.pointAt(this.startAngle).round(j),d=this.pointAt(this.endAngle).round(j),f=g(s,t.round(j),u,d);return r<180?e=f&&v(s.distanceTo(f),a)&&v(a,h):(i=l(s.x,s.y,this.radiusX,this.radiusY,t.x,t.y),360!=i&&(i=(360+i)%360),n=o.startAngle<=i&&i<=o.endAngle,e=n&&v(a,h)||!n&&(!f||f.equals(t))),e},_isOnPath:function(t,e){var i,n=this._arcInterval(),o=this.center,r=l(o.x,o.y,this.radiusX,this.radiusY,t.x,t.y);return 360!=r&&(r=(360+r)%360),i=n.startAngle<=r&&r<=n.endAngle,i&&this.pointAt(r).distanceTo(t)<=e}}),o(S.fn,["radiusX","radiusY","startAngle","endAngle","anticlockwise"]),B(S.fn,z),S.fromPoints=function(t,e,i,n,o,r){var s=c(t.x,t.y,e.x,e.y,i,n,o,r);return new S(s.center,{startAngle:s.startAngle,endAngle:s.endAngle,radiusX:i,radiusY:n,anticlockwise:0===r})},T=I.extend({init:function(t,e,i,n,o,r){this.a=t||0,this.b=e||0,this.c=i||0,this.d=n||0,this.e=o||0,this.f=r||0},multiplyCopy:function(t){return new T(this.a*t.a+this.c*t.b,this.b*t.a+this.d*t.b,this.a*t.c+this.c*t.d,this.b*t.c+this.d*t.d,this.a*t.e+this.c*t.f+this.e,this.b*t.e+this.d*t.f+this.f)},invert:function(){var t=this.a,e=this.b,i=this.c,n=this.d,o=this.e,r=this.f,s=t*n-e*i;return 0===s?null:new T(n/s,-e/s,-i/s,t/s,(i*r-n*o)/s,(e*o-t*r)/s)},clone:function(){return new T(this.a,this.b,this.c,this.d,this.e,this.f)},equals:function(t){return!!t&&(this.a===t.a&&this.b===t.b&&this.c===t.c&&this.d===t.d&&this.e===t.e&&this.f===t.f)},round:function(t){return this.a=F(this.a,t),this.b=F(this.b,t),this.c=F(this.c,t),this.d=F(this.d,t),this.e=F(this.e,t),this.f=F(this.f,t),this},toArray:function(t){var e,i=[this.a,this.b,this.c,this.d,this.e,this.f];if(R(t))for(e=0;e<i.length;e++)i[e]=F(i[e],t);return i}}),T.fn.toString=function(t,e){return this.toArray(t).join(e||",")},T.translate=function(t,e){return new T(1,0,0,1,t,e)},T.unit=function(){return new T(1,0,0,1,0,0)},T.rotate=function(t,e,i){var n=new T;return n.a=D.cos(O(t)),n.b=D.sin(O(t)),n.c=-n.b,n.d=n.a,n.e=e-e*n.a+i*n.b||0,n.f=i-i*n.a-e*n.b||0,n},T.scale=function(t,e){return new T(t,0,0,e,0,0)},T.IDENTITY=T.unit(),A=I.extend({init:function(t){this._matrix=t||T.unit()},clone:function(){return new A(this._matrix.clone())},equals:function(t){return t&&t._matrix.equals(this._matrix)},_optionsChange:function(){this.optionsChange({field:"transform",value:this})},translate:function(t,e){return this._matrix=this._matrix.multiplyCopy(T.translate(t,e)),this._optionsChange(),this},scale:function(t,e,i){return R(e)||(e=t),i&&(i=G.create(i),this._matrix=this._matrix.multiplyCopy(T.translate(i.x,i.y))),this._matrix=this._matrix.multiplyCopy(T.scale(t,e)),i&&(this._matrix=this._matrix.multiplyCopy(T.translate(-i.x,-i.y))),this._optionsChange(),this},rotate:function(t,e){return e=G.create(e)||G.ZERO,this._matrix=this._matrix.multiplyCopy(T.rotate(t,e.x,e.y)),this._optionsChange(),this},multiply:function(t){var i=e(t);return this._matrix=this._matrix.multiplyCopy(i),this._optionsChange(),this},matrix:function(t){return t?(this._matrix=t,this._optionsChange(),this):this._matrix}}),B(A.fn,z),P=function(t,e){this.real=t||0,this.img=e||0},P.fn=P.prototype={add:function(t){return new P(F(this.real+t.real,j),F(this.img+t.img,j))},addConstant:function(t){return new P(this.real+t,this.img)},negate:function(){return new P((-this.real),(-this.img))},multiply:function(t){return new P(this.real*t.real-this.img*t.img,this.real*t.img+this.img*t.real)},multiplyConstant:function(t){return new P(this.real*t,this.img*t)},nthRoot:function(t){var e=D.atan2(this.img,this.real),i=D.sqrt(D.pow(this.img,2)+D.pow(this.real,2)),n=D.pow(i,1/t);return new P(n*D.cos(e/t),n*D.sin(e/t))},equals:function(t){return this.real===t.real&&this.img===t.img},isReal:function(){return 0===this.img}},B(E,{geometry:{Arc:S,Circle:C,curveIntersectionsCount:f,lineIntersectionsCount:p,Matrix:T,Point:G,Rect:k,Size:b,Transformation:A,transform:t,toMatrix:e,isOutOfEndPoint:y,hasRootsInRange:w}}),E.dataviz.geometry=E.geometry}(),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/core.min",["drawing/geometry.min","kendo.popup.min"],t)}(function(){!function(t){function e(t){var e,i;return t.touch?(e=t.x.location,i=t.y.location):(e=t.pageX||t.clientX||0,i=t.pageY||t.clientY||0),{x:e,y:i}}var i,n,o,r,s=t.noop,a=Object.prototype.toString,l=window.kendo,c=l._outerWidth,h=l._outerHeight,u=l.Class,d=l.ui.Widget,f=l.deepExtend,p=l.util,g=p.defined,m=p.limitValue,v=l.geometry,_=t.proxy,y=".kendo",w='<div class="k-tooltip"><div class="k-tooltip-content"></div></div>',x='<div class="k-tooltip-button"><a href="\\#" class="k-icon k-i-close">close</a></div>',b=d.extend({init:function(t,e){this.options=f({},this.options,e),d.fn.init.call(this,t,this.options),this._click=this._handler("click"),this._mouseenter=this._handler("mouseenter"),this._mouseleave=this._handler("mouseleave"),this._mousemove=this._handler("mousemove"),this._visual=new l.drawing.Group,this.options.width&&this.element.css("width",this.options.width),this.options.height&&this.element.css("height",this.options.height),this._enableTracking()},options:{name:"Surface",tooltip:{}},events:["click","mouseenter","mouseleave","mousemove","resize","tooltipOpen","tooltipClose"],draw:function(t){this._visual.children.push(t)},clear:function(){this._visual.children=[],this.hideTooltip()},destroy:function(){this._visual=null,this._tooltip&&(this._tooltip.destroy(),delete this._tooltip),d.fn.destroy.call(this)},exportVisual:function(){return this._visual},getSize:function(){return{width:this.element.width(),height:this.element.height()}},setSize:function(t){this.element.css({width:t.width,height:t.height}),this._size=t,this._resize()},eventTarget:function(e){for(var i,n=t(e.touch?e.touch.initialTouch:e.target);!i&&n.length>0&&(i=n[0]._kendoNode,!n.is(this.element)&&0!==n.length);)n=n.parent();if(i)return i.srcElement},showTooltip:function(t,e){this._tooltip&&this._tooltip.show(t,e)},hideTooltip:function(){this._tooltip&&this._tooltip.hide()},suspendTracking:function(){this._suspendedTracking=!0,this.hideTooltip()},resumeTracking:function(){this._suspendedTracking=!1},_resize:s,_handler:function(t){var e=this;return function(i){var n=e.eventTarget(i);n&&!e._suspendedTracking&&e.trigger(t,{element:n,originalEvent:i,type:t})}},_enableTracking:function(){l.ui.Popup&&(this._tooltip=new r(this,this.options.tooltip||{}))},_elementOffset:function(){var t=this.element,e=t.offset(),i=parseInt(t.css("paddingLeft"),10),n=parseInt(t.css("paddingTop"),10);return{left:e.left+i,top:e.top+n}},_surfacePoint:function(t){var i=this._elementOffset(),n=e(t),o=n.x-i.left,r=n.y-i.top;return new v.Point(o,r)}});l.ui.plugin(b),b.create=function(t,e){return o.current.create(t,e)},i=u.extend({init:function(t){this.childNodes=[],this.parent=null,t&&(this.srcElement=t,this.observe())},destroy:function(){var t,e;for(this.srcElement&&this.srcElement.removeObserver(this),t=this.childNodes,e=0;e<t.length;e++)this.childNodes[e].destroy();this.parent=null},load:s,observe:function(){this.srcElement&&this.srcElement.addObserver(this)},append:function(t){this.childNodes.push(t),t.parent=this},insertAt:function(t,e){this.childNodes.splice(e,0,t),t.parent=this},remove:function(t,e){var i,n=t+e;for(i=t;i<n;i++)this.childNodes[i].removeSelf();this.childNodes.splice(t,e)},removeSelf:function(){this.clear(),this.destroy()},clear:function(){this.remove(0,this.childNodes.length)},invalidate:function(){this.parent&&this.parent.invalidate()},geometryChange:function(){this.invalidate()},optionsChange:function(){this.invalidate()},childrenChange:function(t){"add"===t.action?this.load(t.items,t.index):"remove"===t.action&&this.remove(t.index,t.items.length),this.invalidate()}}),n=u.extend({init:function(t,e){var i,n;this.prefix=e||"";for(i in t)n=t[i],n=this._wrap(n,i),this[i]=n},get:function(t){return l.getter(t,!0)(this)},set:function(t,e){var i,n=l.getter(t,!0)(this);n!==e&&(i=this._set(t,this._wrap(e,t)),i||this.optionsChange({field:this.prefix+t,value:e}))},_set:function(t,e){var i,o,r,s=t.indexOf(".")>=0;if(s)for(i=t.split("."),o="";i.length>1;){if(o+=i.shift(),r=l.getter(o,!0)(this),r||(r=new n({},o+"."),r.addObserver(this),this[o]=r),r instanceof n)return r.set(i.join("."),e),s;o+="."}return this._clear(t),l.setter(t)(this,e),s},_clear:function(t){var e=l.getter(t,!0)(this);e&&e.removeObserver&&e.removeObserver(this)},_wrap:function(t,e){var i=a.call(t);return null!==t&&g(t)&&"[object Object]"===i&&(t instanceof n||t instanceof u||(t=new n(t,this.prefix+e+".")),t.addObserver(this)),t}}),f(n.fn,l.mixins.ObserversMixin),o=function(){this._items=[]},o.prototype={register:function(t,e,i){var n=this._items,o=n[0],r={name:t,type:e,order:i};!o||i<o.order?n.unshift(r):n.push(r)},create:function(t,e){var i,n,o=this._items,r=o[0];if(e&&e.type)for(i=e.type.toLowerCase(),n=0;n<o.length;n++)if(o[n].name===i){r=o[n];break}return r?new r.type(t,e):void l.logToConsole("Warning: Unable to create Kendo UI Drawing Surface. Possible causes:\n- The browser does not support SVG, VML and Canvas. User agent: "+navigator.userAgent+"\n- The Kendo UI scripts are not fully loaded")}},o.current=new o,r=u.extend({init:function(e,i){this.element=t(w),this.content=this.element.children(".k-tooltip-content"),i=i||{},this.options=f({},this.options,this._tooltipOptions(i)),this.popup=new l.ui.Popup(this.element,{appendTo:i.appendTo,animation:i.animation,copyAnchorStyles:!1,collision:"fit fit"}),this._openPopupHandler=t.proxy(this._openPopup,this),this.surface=e,this._bindEvents()},options:{position:"top",showOn:"mouseenter",offset:7,autoHide:!0,hideDelay:0,showAfter:100},_bindEvents:function(){this._showHandler=_(this._showEvent,this),this._surfaceLeaveHandler=_(this._surfaceLeave,this),this._mouseleaveHandler=_(this._mouseleave,this),this._mousemoveHandler=_(this._mousemove,this),this.surface.bind("click",this._showHandler),this.surface.bind("mouseenter",this._showHandler),this.surface.bind("mouseleave",this._mouseleaveHandler),this.surface.bind("mousemove",this._mousemoveHandler),this.surface.element.on("mouseleave"+y,this._surfaceLeaveHandler),this.element.on("click"+y,".k-tooltip-button",_(this._hideClick,this))},destroy:function(){var t=this.popup;this.surface.unbind("click",this._showHandler),this.surface.unbind("mouseenter",this._showHandler),this.surface.unbind("mouseleave",this._mouseleaveHandler),this.surface.unbind("mousemove",this._mousemoveHandler),this.surface.element.off("mouseleave"+y,this._surfaceLeaveHandler),this.element.off("click"+y),t&&(t.destroy(),delete this.popup),clearTimeout(this._timeout),delete this.popup,delete this.element,delete this.content,delete this.surface},_tooltipOptions:function(t){return t=t||{},{position:t.position,showOn:t.showOn,offset:t.offset,autoHide:t.autoHide,width:t.width,height:t.height,content:t.content,shared:t.shared,hideDelay:t.hideDelay,showAfter:t.showAfter}},_tooltipShape:function(t){for(;t&&!t.options.tooltip;)t=t.parent;return t},_updateContent:function(t,e,i){var n=i.content;if(l.isFunction(n)&&(n=n({element:e,target:t})),n)return this.content.html(n),!0},_position:function(t,i,n,o){var r,s=i.position,a=i.offset||0,l=this.surface,c=l._elementOffset(),h=l.getSize(),u=l._offset,d=t.bbox(),f=n.width,p=n.height,g=0,v=0;return d.origin.translate(c.left,c.top),u&&d.origin.translate(-u.x,-u.y),"cursor"==s&&o?(r=e(o),g=r.x-f/2,v=r.y-p-a):"left"==s?(g=d.origin.x-f-a,v=d.center().y-p/2):"right"==s?(g=d.bottomRight().x+a,v=d.center().y-p/2):"bottom"==s?(g=d.center().x-f/2,v=d.bottomRight().y+a):(g=d.center().x-f/2,v=d.origin.y-p-a),{left:m(g,c.left,c.left+h.width),top:m(v,c.top,c.top+h.height)}},show:function(t,e){this._show(t,t,f({},this.options,this._tooltipOptions(t.options.tooltip),e))},hide:function(){var t=this._current;delete this._current,clearTimeout(this._showTimeout),this.popup.visible()&&t&&!this.surface.trigger("tooltipClose",{element:t.shape,target:t.target,popup:this.popup})&&this.popup.close()},_hideClick:function(t){t.preventDefault(),this.hide()},_show:function(t,e,i,n,o){var r,s,a=this._current;clearTimeout(this._timeout),a&&(a.shape===e&&i.shared||a.target===t)||(clearTimeout(this._showTimeout),!this.surface.trigger("tooltipOpen",{element:e,target:t,popup:this.popup})&&this._updateContent(t,e,i)&&(this._autoHide(i),r=this._measure(i),s=this.popup,s.visible()&&s.close(!0),this._current={options:i,elementSize:r,shape:e,target:t,position:this._position(i.shared?e:t,i,r,n)},o?this._showTimeout=setTimeout(this._openPopupHandler,i.showAfter||0):this._openPopup()))},_openPopup:function(){var t=this._current,e=t.position;this.popup.open(e.left,e.top)},_autoHide:function(e){e.autoHide&&this._closeButton&&(this.element.removeClass("k-tooltip-closable"),this._closeButton.remove(),delete this._closeButton),e.autoHide||this._closeButton||(this.element.addClass("k-tooltip-closable"),this._closeButton=t(x).prependTo(this.element))},_showEvent:function(t){var e,i=this._tooltipShape(t.element);i&&(e=f({},this.options,this._tooltipOptions(i.options.tooltip)),e&&e.showOn==t.type&&this._show(t.element,i,e,t.originalEvent,!0))},_measure:function(t){var e,i,n;return this.element.css({width:"auto",height:"auto"}),n=this.popup.visible(),n||this.popup.wrapper.show(),this.element.css({width:g(t.width)?t.width:"auto",height:g(t.height)?t.height:"auto"}),e=c(this.element),i=h(this.element),n||this.popup.wrapper.hide(),{width:e,height:i}},_mouseleave:function(t){var e,i;this._popupRelatedTarget(t.originalEvent)||(e=this,i=e._current,i&&i.options.autoHide&&(e._timeout=setTimeout(function(){clearTimeout(e._showTimeout),e.hide()},i.options.hideDelay||0)))},_mousemove:function(t){var e,i,n=this._current;n&&t.element&&(e=n.options,"cursor"==e.position&&(i=this._position(t.element,e,n.elementSize,t.originalEvent),n.position=i,this.popup.wrapper.css({left:i.left,top:i.top})))},_surfaceLeave:function(t){this._popupRelatedTarget(t)||(clearTimeout(this._showTimeout),this.hide())},_popupRelatedTarget:function(e){return e.relatedTarget&&t(e.relatedTarget).closest(this.popup.wrapper).length}}),f(l,{drawing:{DASH_ARRAYS:{dot:[1.5,3.5],dash:[4,3.5],longdash:[8,3.5],dashdot:[3.5,3.5,1.5,3.5],longdashdot:[8,3.5,1.5,3.5],longdashdotdot:[8,3.5,1.5,3.5,1.5,3.5]},Color:l.Color,BaseNode:i,OptionsStore:n,Surface:b,SurfaceFactory:o,SurfaceTooltip:r}}),l.dataviz.drawing=l.drawing}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/mixins.min",["drawing/core.min"],t)}(function(){!function(){var t=window.kendo,e=t.deepExtend,i=t.util.defined,n=t.geometry,o="gradient",r=""+n.Matrix.IDENTITY,s={extend:function(t){t.fill=this.fill,t.stroke=this.stroke},fill:function(t,e){var n,r=this.options;return i(t)?(t&&t.nodeType!=o?(n={color:t},i(e)&&(n.opacity=e),r.set("fill",n)):r.set("fill",t),this):r.get("fill")},stroke:function(t,e,n){return i(t)?(this.options.set("stroke.color",t),i(e)&&this.options.set("stroke.width",e),i(n)&&this.options.set("stroke.opacity",n),this):this.options.get("stroke")}},a={extend:function(t,e){t.traverse=function(t){var i,n,o=this[e];for(i=0;i<o.length;i++)n=o[i],n.traverse?n.traverse(t):t(n);return this}}},l={extend:function(t){t.bbox=this.bbox,t.geometryChange=this.geometryChange},bbox:function(t){var e,i,o=n.toMatrix(this.currentTransform(t)),s=o?""+o:r;return this._bboxCache&&this._matrixHash==s?e=this._bboxCache.clone():(e=this._bbox(o),this._bboxCache=e?e.clone():null,this._matrixHash=s),i=this.options.get("stroke.width"),i&&e&&e.expand(i/2),e},geometryChange:function(){delete this._bboxCache,this.trigger("geometryChange",{element:this})}};e(t.drawing,{mixins:{Paintable:s,Traversable:a,Measurable:l}})}()},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/shapes.min",["drawing/core.min","drawing/mixins.min","util/text-metrics.min","mixins/observers.min"],t)}(function(){!function(t){function e(t,e,i){var n,o,r,s;for(o=0;o<t.length;o++)r=t[o],r.visible()&&(s=e?r.bbox(i):r.rawBBox(),s&&(n=n?W.Rect.union(n,s):s));return n}function i(t,e){var i,n,o,r;for(n=0;n<t.length;n++)o=t[n],o.visible()&&(r=o.clippedBBox(e),r&&(i=i?W.Rect.union(i,r):r));return i}function n(t,e){for(var i=0;i<e.length;i++)t[e[i]]=o(e[i])}function o(t){var e="_"+t;return function(t){return nt(t)?(this._observerField(e,t),this.geometryChange(),this):this[e]}}function r(t,e){for(var i=0;i<e.length;i++)t[e[i]]=s(e[i])}function s(t){var e="_"+t;return function(t){return nt(t)?(this._observerField(e,q.create(t)),this.geometryChange(),this):this[e]}}function a(t,e){for(var i=0;i<e.length;i++)t[e[i]]=l(e[i])}function l(t){return function(e){return nt(e)?(this.options.set(t,e),this):this.options.get(t)}}function c(){return"kdef"+pt++}function h(t,e,i){x(t,e,i,"x","width")}function u(t,e,i){x(t,e,i,"y","height")}function d(t){w(y(t),"x","y","width")}function f(t){w(y(t),"y","x","height")}function p(t,e){return m(t,e,"x","y","width")}function g(t,e){return m(t,e,"y","x","height")}function m(t,e,i,n,o){var r,s,a,l,c=[],h=_(t,e,o),u=e.origin.clone();for(l=0;l<h.length;l++)for(a=h[l],r=a[0],u[n]=r.bbox.origin[n],C(u,r.bbox,r.element),r.bbox.origin[i]=u[i],w(a,i,n,o),c.push([]),s=0;s<a.length;s++)c[l].push(a[s].element);return c}function v(t,e){var i,n,o=t.clippedBBox(),r=o.size,s=e.size;(s.width<r.width||s.height<r.height)&&(i=Z.min(s.width/r.width,s.height/r.height),n=t.transform()||W.transform(),n.scale(i,i),t.transform(n))}function _(t,e,i){var n,o,r,s,a=e.size[i],l=0,c=[],h=[],u=function(){h.push({element:n,bbox:r})};for(s=0;s<t.length;s++)n=t[s],r=n.clippedBBox(),r&&(o=r.size[i],l+o>a?h.length?(c.push(h),h=[],u(),l=o):(u(),c.push(h),h=[],l=0):(u(),l+=o));return h.length&&c.push(h),c}function y(t){var e,i,n,o=[];for(n=0;n<t.length;n++)e=t[n],i=e.clippedBBox(),i&&o.push({element:e,bbox:i});return o}function w(t,e,i,n){var o,r,s,a,l;if(t.length>1)for(o=t[0].bbox,r=new q,l=1;l<t.length;l++)s=t[l].element,a=t[l].bbox,r[e]=o.origin[e]+o.size[n],r[i]=a.origin[i],C(r,a,s),a.origin[e]=r[e],o=a}function x(t,e,i,n,o){var r,s,a;for(i=i||"start",a=0;a<t.length;a++)r=t[a].clippedBBox(),r&&(s=r.origin.clone(),s[n]=b(r.size[o],e,i,n,o),C(s,r,t[a]))}function b(t,e,i,n,o){var r;return r=i==gt?e.origin[n]:i==mt?e.origin[n]+e.size[o]-t:e.origin[n]+(e.size[o]-t)/2}function k(t,e,i){var n=i.transform()||W.transform(),o=n.matrix();o.e+=t,o.f+=e,n.matrix(o),i.transform(n)}function C(t,e,i){k(t.x-e.origin.x,t.y-e.origin.y,i)}var S,T,A,P,D,M,E,I,B,z,L,R,O,V,F,N,H,U=window.kendo,j=U.Class,G=U.deepExtend,W=U.geometry,q=W.Point,$=W.Size,Y=W.Matrix,X=W.toMatrix,Q=U.drawing,K=Q.OptionsStore,Z=Math,J=Z.pow,tt=U.util,et=tt.append,it=tt.arrayLimits,nt=tt.defined,ot=tt.last,rt=tt.valueOrDefault,st=U.mixins.ObserversMixin,at=t.inArray,lt=[].push,ct=[].pop,ht=[].splice,ut=[].shift,dt=[].slice,ft=[].unshift,pt=1,gt="start",mt="end",vt="horizontal",_t=j.extend({nodeType:"Element",init:function(t){this._initOptions(t)},_initOptions:function(t){var e,i;t=t||{},e=t.transform,i=t.clip,e&&(t.transform=W.transform(e)),i&&!i.id&&(i.id=c()),this.options=new K(t),this.options.addObserver(this)},transform:function(t){return nt(t)?void this.options.set("transform",W.transform(t)):this.options.get("transform")},parentTransform:function(){for(var t,e,i=this;i.parent;)i=i.parent,t=i.transform(),t&&(e=t.matrix().multiplyCopy(e||Y.unit()));if(e)return W.transform(e)},currentTransform:function(t){var e,i,n=this.transform(),o=X(n);if(nt(t)||(t=this.parentTransform()),e=X(t),i=o&&e?e.multiplyCopy(o):o||e)return W.transform(i)},visible:function(t){return nt(t)?(this.options.set("visible",t),this):this.options.get("visible")!==!1},clip:function(t){var e=this.options;return nt(t)?(t&&!t.id&&(t.id=c()),e.set("clip",t),this):e.get("clip")},opacity:function(t){return nt(t)?(this.options.set("opacity",t),this):rt(this.options.get("opacity"),1)},clippedBBox:function(t){var e,i=this._clippedBBox(t);if(i)return e=this.clip(),e?W.Rect.intersect(i,e.bbox(t)):i},containsPoint:function(t,e){if(this.visible()){var i=this.currentTransform(e);return i&&(t=t.transformCopy(i.matrix().invert())),this._hasFill()&&this._containsPoint(t)||this._isOnPath&&this._hasStroke()&&this._isOnPath(t)}return!1},_hasFill:function(){var t=this.options.fill;return t&&!tt.isTransparent(t.color)},_hasStroke:function(){var t=this.options.stroke;return t&&t.width>0&&!tt.isTransparent(t.color)},_clippedBBox:function(t){return this.bbox(t)}});G(_t.fn,st),S=j.extend({init:function(t){t=t||[],this.length=0,this._splice(0,t.length,t)},elements:function(t){return t?(this._splice(0,this.length,t),this._change(),this):this.slice(0)},push:function(){var t=arguments,e=lt.apply(this,t);return this._add(t),e},slice:dt,pop:function(){var t=this.length,e=ct.apply(this);return t&&this._remove([e]),e},splice:function(t,e){var i=dt.call(arguments,2),n=this._splice(t,e,i);return this._change(),n},shift:function(){var t=this.length,e=ut.apply(this);return t&&this._remove([e]),e},unshift:function(){var t=arguments,e=ft.apply(this,t);return this._add(t),e},indexOf:function(t){var e,i,n=this;for(e=0,i=n.length;e<i;e++)if(n[e]===t)return e;return-1},_splice:function(t,e,i){var n=ht.apply(this,[t,e].concat(i));return this._clearObserver(n),this._setObserver(i),n},_add:function(t){this._setObserver(t),this._change()},_remove:function(t){this._clearObserver(t),this._change()},_setObserver:function(t){for(var e=0;e<t.length;e++)t[e].addObserver(this)},_clearObserver:function(t){for(var e=0;e<t.length;e++)t[e].removeObserver(this)},_change:function(){}}),G(S.fn,st),T=_t.extend({nodeType:"Group",init:function(t){_t.fn.init.call(this,t),this.children=[]},childrenChange:function(t,e,i){this.trigger("childrenChange",{action:t,items:e,index:i})},append:function(){return et(this.children,arguments),this._reparent(arguments,this),this.childrenChange("add",arguments),this},insert:function(t,e){return this.children.splice(t,0,e),e.parent=this,this.childrenChange("add",[e],t),this},insertAt:function(t,e){return this.insert(e,t)},remove:function(t){var e=at(t,this.children);return e>=0&&(this.children.splice(e,1),t.parent=null,this.childrenChange("remove",[t],e)),this},removeAt:function(t){if(0<=t&&t<this.children.length){var e=this.children[t];this.children.splice(t,1),e.parent=null,this.childrenChange("remove",[e],t)}return this},clear:function(){var t=this.children;return this.children=[],this._reparent(t,null),this.childrenChange("remove",t,0),this},bbox:function(t){return e(this.children,!0,this.currentTransform(t))},rawBBox:function(){return e(this.children,!1)},_clippedBBox:function(t){return i(this.children,this.currentTransform(t))},currentTransform:function(t){return _t.fn.currentTransform.call(this,t)||null},containsPoint:function(t,e){var i,n,o;if(this.visible())for(i=this.children,n=this.currentTransform(e),o=0;o<i.length;o++)if(i[o].containsPoint(t,n))return!0;return!1},_reparent:function(t,e){var i,n,o;for(i=0;i<t.length;i++)n=t[i],o=n.parent,o&&o!=this&&o.remove&&o.remove(n),n.parent=e}}),Q.mixins.Traversable.extend(T.fn,"children"),A=_t.extend({nodeType:"Text",init:function(t,e,i){_t.fn.init.call(this,i),this.content(t),this.position(e||new W.Point),this.options.font||(this.options.font="12px sans-serif"),nt(this.options.fill)||this.fill("#000")},content:function(t){return nt(t)?(this.options.set("content",t),this):this.options.get("content")},measure:function(){var t=tt.measureText(this.content(),{font:this.options.get("font")});return t},rect:function(){var t=this.measure(),e=this.position().clone();return new W.Rect(e,[t.width,t.height])},bbox:function(t){var e=X(this.currentTransform(t));return this.rect().bbox(e)},rawBBox:function(){return this.rect().bbox()},_containsPoint:function(t){return this.rect().containsPoint(t)}}),Q.mixins.Paintable.extend(A.fn),r(A.fn,["position"]),P=_t.extend({nodeType:"Circle",init:function(t,e){_t.fn.init.call(this,e),this.geometry(t||new W.Circle),nt(this.options.stroke)||this.stroke("#000")},_bbox:function(t){return this._geometry.bbox(t)},rawBBox:function(){return this._geometry.bbox()},_containsPoint:function(t){return this.geometry().containsPoint(t)},_isOnPath:function(t){return this.geometry()._isOnPath(t,this.options.stroke.width/2)}}),Q.mixins.Paintable.extend(P.fn),Q.mixins.Measurable.extend(P.fn),n(P.fn,["geometry"]),D=_t.extend({nodeType:"Arc",init:function(t,e){_t.fn.init.call(this,e),this.geometry(t||new W.Arc),nt(this.options.stroke)||this.stroke("#000")},_bbox:function(t){return this._geometry.bbox(t)},rawBBox:function(){return this.geometry().bbox()},toPath:function(){var t,e=new I,i=this.geometry().curvePoints();if(i.length>0)for(e.moveTo(i[0].x,i[0].y),t=1;t<i.length;t+=3)e.curveTo(i[t],i[t+1],i[t+2]);return e},_containsPoint:function(t){return this.geometry().containsPoint(t)},_isOnPath:function(t){return this.geometry()._isOnPath(t,this.options.stroke.width/2)}}),Q.mixins.Paintable.extend(D.fn),Q.mixins.Measurable.extend(D.fn),n(D.fn,["geometry"]),M=S.extend({_change:function(){this.geometryChange()}}),E=j.extend({init:function(t,e,i){this.anchor(t||new q),this.controlIn(e),this.controlOut(i)},bboxTo:function(t,e){
var i,n=this.anchor().transformCopy(e),o=t.anchor().transformCopy(e);return i=this.controlOut()&&t.controlIn()?this._curveBoundingBox(n,this.controlOut().transformCopy(e),t.controlIn().transformCopy(e),o):this._lineBoundingBox(n,o)},_lineBoundingBox:function(t,e){return W.Rect.fromPoints(t,e)},_curveBoundingBox:function(t,e,i,n){var o=[t,e,i,n],r=this._curveExtremesFor(o,"x"),s=this._curveExtremesFor(o,"y"),a=it([r.min,r.max,t.x,n.x]),l=it([s.min,s.max,t.y,n.y]);return W.Rect.fromPoints(new q(a.min,l.min),new q(a.max,l.max))},_curveExtremesFor:function(t,e){var i=this._curveExtremes(t[0][e],t[1][e],t[2][e],t[3][e]);return{min:this._calculateCurveAt(i.min,e,t),max:this._calculateCurveAt(i.max,e,t)}},_calculateCurveAt:function(t,e,i){var n=1-t;return J(n,3)*i[0][e]+3*J(n,2)*t*i[1][e]+3*J(t,2)*n*i[2][e]+J(t,3)*i[3][e]},_curveExtremes:function(t,e,i,n){var o,r,s=t-3*e+3*i-n,a=-2*(t-2*e+i),l=t-e,c=Z.sqrt(a*a-4*s*l),h=0,u=1;return 0===s?0!==a&&(h=u=-l/a):isNaN(c)||(h=(-a+c)/(2*s),u=(-a-c)/(2*s)),o=Z.max(Z.min(h,u),0),(o<0||o>1)&&(o=0),r=Z.min(Z.max(h,u),1),(r>1||r<0)&&(r=1),{min:o,max:r}},_intersectionsTo:function(t,e){var i;return i=this.controlOut()&&t.controlIn()?W.curveIntersectionsCount([this.anchor(),this.controlOut(),t.controlIn(),t.anchor()],e,this.bboxTo(t)):W.lineIntersectionsCount(this.anchor(),t.anchor(),e)},_isOnCurveTo:function(t,e,i,n){var o,r,s,a,l,c,h,u,d=this.bboxTo(t).expand(i,i);if(d.containsPoint(e))return o=this.anchor(),r=this.controlOut(),s=t.controlIn(),a=t.anchor(),"start"==n&&o.distanceTo(e)<=i?!W.isOutOfEndPoint(o,r,e):"end"==n&&a.distanceTo(e)<=i?!W.isOutOfEndPoint(a,s,e):(l=W.hasRootsInRange,c=[o,r,s,a],!(!l(c,e,"x","y",i)&&!l(c,e,"y","x",i))||(h=W.transform().rotate(45,e),u=[o.transformCopy(h),r.transformCopy(h),s.transformCopy(h),a.transformCopy(h)],l(u,e,"x","y",i)||l(u,e,"y","x",i)))},_isOnLineTo:function(t,e,i){var n=this.anchor(),o=t.anchor(),r=tt.deg(Z.atan2(o.y-n.y,o.x-n.x)),s=new W.Rect([n.x,n.y-i/2],[n.distanceTo(o),i]);return s.containsPoint(e.transformCopy(W.transform().rotate(-r,n)))},_isOnPathTo:function(t,e,i,n){var o;return o=this.controlOut()&&t.controlIn()?this._isOnCurveTo(t,e,i/2,n):this._isOnLineTo(t,e,i)}}),r(E.fn,["anchor","controlIn","controlOut"]),G(E.fn,st),I=_t.extend({nodeType:"Path",init:function(t){_t.fn.init.call(this,t),this.segments=new M,this.segments.addObserver(this),nt(this.options.stroke)||(this.stroke("#000"),nt(this.options.stroke.lineJoin)||this.options.set("stroke.lineJoin","miter"))},moveTo:function(t,e){return this.suspend(),this.segments.elements([]),this.resume(),this.lineTo(t,e),this},lineTo:function(t,e){var i=nt(e)?new q(t,e):t,n=new E(i);return this.segments.push(n),this},curveTo:function(t,e,i){var n,o;return this.segments.length>0&&(n=ot(this.segments),o=new E(i,e),this.suspend(),n.controlOut(t),this.resume(),this.segments.push(o)),this},arc:function(t,e,i,n,o){var r,s,a,l,c;return this.segments.length>0&&(r=ot(this.segments),s=r.anchor(),a=tt.rad(t),l=new q(s.x-i*Z.cos(a),s.y-n*Z.sin(a)),c=new W.Arc(l,{startAngle:t,endAngle:e,radiusX:i,radiusY:n,anticlockwise:o}),this._addArcSegments(c)),this},arcTo:function(t,e,i,n,o){var r,s,a;return this.segments.length>0&&(r=ot(this.segments),s=r.anchor(),a=W.Arc.fromPoints(s,t,e,i,n,o),this._addArcSegments(a)),this},_addArcSegments:function(t){var e,i;for(this.suspend(),e=t.curvePoints(),i=1;i<e.length;i+=3)this.curveTo(e[i],e[i+1],e[i+2]);this.resume(),this.geometryChange()},close:function(){return this.options.closed=!0,this.geometryChange(),this},rawBBox:function(){return this._bbox()},_containsPoint:function(t){var e,i,n,o=this.segments,r=o.length,s=0;for(n=1;n<r;n++)e=o[n-1],i=o[n],s+=e._intersectionsTo(i,t);return!this.options.closed&&o[0].anchor().equals(o[r-1].anchor())||(s+=W.lineIntersectionsCount(o[0].anchor(),o[r-1].anchor(),t)),s%2!==0},_isOnPath:function(t,e){var i,n=this.segments,o=n.length;if(e=e||this.options.stroke.width,o>1){if(n[0]._isOnPathTo(n[1],t,e,"start"))return!0;for(i=2;i<=o-2;i++)if(n[i-1]._isOnPathTo(n[i],t,e))return!0;if(n[o-2]._isOnPathTo(n[o-1],t,e,"end"))return!0}return!1},_bbox:function(t){var e,i,n,o,r=this.segments,s=r.length;if(1===s)i=r[0].anchor().transformCopy(t),e=new W.Rect(i,$.ZERO);else if(s>0)for(n=1;n<s;n++)o=r[n-1].bboxTo(r[n],t),e=e?W.Rect.union(e,o):o;return e}}),Q.mixins.Paintable.extend(I.fn),Q.mixins.Measurable.extend(I.fn),I.fromRect=function(t,e){return new I(e).moveTo(t.topLeft()).lineTo(t.topRight()).lineTo(t.bottomRight()).lineTo(t.bottomLeft()).close()},I.fromPoints=function(t,e){var i,n,o;if(t){for(i=new I(e),n=0;n<t.length;n++)o=q.create(t[n]),o&&(0===n?i.moveTo(o):i.lineTo(o));return i}},I.fromArc=function(t,e){var i=new I(e),n=t.startAngle,o=t.pointAt(n);return i.moveTo(o.x,o.y),i.arc(n,t.endAngle,t.radiusX,t.radiusY,t.anticlockwise),i},B=_t.extend({nodeType:"MultiPath",init:function(t){_t.fn.init.call(this,t),this.paths=new M,this.paths.addObserver(this),nt(this.options.stroke)||this.stroke("#000")},moveTo:function(t,e){var i=new I;return i.moveTo(t,e),this.paths.push(i),this},lineTo:function(t,e){return this.paths.length>0&&ot(this.paths).lineTo(t,e),this},curveTo:function(t,e,i){return this.paths.length>0&&ot(this.paths).curveTo(t,e,i),this},arc:function(t,e,i,n,o){return this.paths.length>0&&ot(this.paths).arc(t,e,i,n,o),this},arcTo:function(t,e,i,n,o){return this.paths.length>0&&ot(this.paths).arcTo(t,e,i,n,o),this},close:function(){return this.paths.length>0&&ot(this.paths).close(),this},_bbox:function(t){return e(this.paths,!0,t)},rawBBox:function(){return e(this.paths,!1)},_containsPoint:function(t){var e,i=this.paths;for(e=0;e<i.length;e++)if(i[e]._containsPoint(t))return!0;return!1},_isOnPath:function(t){var e,i=this.paths,n=this.options.stroke.width;for(e=0;e<i.length;e++)if(i[e]._isOnPath(t,n))return!0;return!1},_clippedBBox:function(t){return i(this.paths,this.currentTransform(t))}}),Q.mixins.Paintable.extend(B.fn),Q.mixins.Measurable.extend(B.fn),z=_t.extend({nodeType:"Image",init:function(t,e,i){_t.fn.init.call(this,i),this.src(t),this.rect(e||new W.Rect)},src:function(t){return nt(t)?(this.options.set("src",t),this):this.options.get("src")},bbox:function(t){var e=X(this.currentTransform(t));return this._rect.bbox(e)},rawBBox:function(){return this._rect.bbox()},_containsPoint:function(t){return this._rect.containsPoint(t)},_hasFill:function(){return this.src()}}),n(z.fn,["rect"]),L=j.extend({init:function(t,e,i){this.options=new K({offset:t,color:e,opacity:nt(i)?i:1}),this.options.addObserver(this)}}),a(L.fn,["offset","color","opacity"]),G(L.fn,st),L.create=function(t){if(nt(t)){var e;return e=t instanceof L?t:t.length>1?new L(t[0],t[1],t[2]):new L(t.offset,t.color,t.opacity)}},R=S.extend({_change:function(){this.optionsChange({field:"stops"})}}),O=j.extend({nodeType:"gradient",init:function(t){this.stops=new R(this._createStops(t.stops)),this.stops.addObserver(this),this._userSpace=t.userSpace,this.id=c()},userSpace:function(t){return nt(t)?(this._userSpace=t,this.optionsChange(),this):this._userSpace},_createStops:function(t){var e,i=[];for(t=t||[],e=0;e<t.length;e++)i.push(L.create(t[e]));return i},addStop:function(t,e,i){this.stops.push(new L(t,e,i))},removeStop:function(t){var e=this.stops.indexOf(t);e>=0&&this.stops.splice(e,1)}}),G(O.fn,st,{optionsChange:function(t){this.trigger("optionsChange",{field:"gradient"+(t?"."+t.field:""),value:this})},geometryChange:function(){this.optionsChange()}}),V=O.extend({init:function(t){t=t||{},O.fn.init.call(this,t),this.start(t.start||new q),this.end(t.end||new q(1,0))}}),r(V.fn,["start","end"]),F=O.extend({init:function(t){t=t||{},O.fn.init.call(this,t),this.center(t.center||new q),this._radius=nt(t.radius)?t.radius:1,this._fallbackFill=t.fallbackFill},radius:function(t){return nt(t)?(this._radius=t,this.geometryChange(),this):this._radius},fallbackFill:function(t){return nt(t)?(this._fallbackFill=t,this.optionsChange(),this):this._fallbackFill}}),r(F.fn,["center"]),N=_t.extend({nodeType:"Rect",init:function(t,e){_t.fn.init.call(this,e),this.geometry(t||new W.Rect),nt(this.options.stroke)||this.stroke("#000")},_bbox:function(t){return this._geometry.bbox(t)},rawBBox:function(){return this._geometry.bbox()},_containsPoint:function(t){return this._geometry.containsPoint(t)},_isOnPath:function(t){return this.geometry()._isOnPath(t,this.options.stroke.width/2)}}),Q.mixins.Paintable.extend(N.fn),Q.mixins.Measurable.extend(N.fn),n(N.fn,["geometry"]),H=T.extend({init:function(t,e){T.fn.init.call(this,U.deepExtend({},this._defaults,e)),this._rect=t,this._fieldMap={}},_defaults:{alignContent:gt,justifyContent:gt,alignItems:gt,spacing:0,orientation:vt,lineSpacing:0,wrap:!0},rect:function(t){return t?(this._rect=t,this):this._rect},_initMap:function(){var t=this.options,e=this._fieldMap;t.orientation==vt?(e.sizeField="width",e.groupsSizeField="height",e.groupAxis="x",e.groupsAxis="y"):(e.sizeField="height",e.groupsSizeField="width",e.groupAxis="y",e.groupsAxis="x")},reflow:function(){var t,e,i,n,o,r,s,a,l,c,h,u,d,f,p,g,m,v,_,y,w,x,k,S,T,A;if(this._rect&&0!==this.children.length){for(this._initMap(),this.options.transform&&this.transform(null),t=this.options,e=this._fieldMap,i=this._rect,n=this._initGroups(),o=n.groups,r=n.groupsSize,s=e.sizeField,a=e.groupsSizeField,l=e.groupAxis,c=e.groupsAxis,h=b(r,i,t.alignContent,c,a),u=new q,d=new q,f=new W.Size,y=0;y<o.length;y++){for(v=o[y],u[l]=p=b(v.size,i,t.justifyContent,l,s),u[c]=h,f[s]=v.size,f[a]=v.lineSize,_=new W.Rect(u,f),w=0;w<v.bboxes.length;w++)m=v.elements[w],g=v.bboxes[w],d[l]=p,d[c]=b(g.size[a],_,t.alignItems,c,a),C(d,g,m),p+=g.size[s]+t.spacing;h+=v.lineSize+t.lineSpacing}!t.wrap&&v.size>i.size[s]&&(x=i.size[s]/_.size[s],k=_.topLeft().scale(x,x),S=_.size[a]*x,T=b(S,i,t.alignContent,c,a),A=W.transform(),"x"===l?A.translate(i.origin.x-k.x,T-k.y):A.translate(T-k.x,i.origin.y-k.y),A.scale(x,x),this.transform(A))}},_initGroups:function(){var t,e,i,n=this.options,o=this.children,r=n.lineSpacing,s=this._fieldMap.sizeField,a=-r,l=[],c=this._newGroup(),h=function(){l.push(c),a+=c.lineSize+r};for(i=0;i<o.length;i++)e=o[i],t=o[i].clippedBBox(),e.visible()&&t&&(n.wrap&&c.size+t.size[s]+n.spacing>this._rect.size[s]?0===c.bboxes.length?(this._addToGroup(c,t,e),h(),c=this._newGroup()):(h(),c=this._newGroup(),this._addToGroup(c,t,e)):this._addToGroup(c,t,e));return c.bboxes.length&&h(),{groups:l,groupsSize:a}},_addToGroup:function(t,e,i){t.size+=e.size[this._fieldMap.sizeField]+this.options.spacing,t.lineSize=Math.max(e.size[this._fieldMap.groupsSizeField],t.lineSize),t.bboxes.push(e),t.elements.push(i)},_newGroup:function(){return{lineSize:0,size:-this.options.spacing,bboxes:[],elements:[]}}}),G(Q,{align:h,Arc:D,Circle:P,Element:_t,ElementsArray:S,fit:v,Gradient:O,GradientStop:L,Group:T,Image:z,Layout:H,LinearGradient:V,MultiPath:B,Path:I,RadialGradient:F,Rect:N,Segment:E,stack:d,Text:A,vAlign:u,vStack:f,vWrap:g,wrap:p})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/parser.min",["drawing/shapes.min"],t)}(function(){!function(t){function e(t){var e=[];return t.replace(g,function(t,i){e.push(parseFloat(i))}),e}function i(t,e,i){var n,o=e?0:1;for(n=0;n<t.length;n+=2)t.splice(n+o,0,i)}function n(t,e){if(t&&e)return e.scaleCopy(2).translate(-t.x,-t.y)}function o(t,e,i){var n=1/3;return e=e.clone().scale(2/3),{controlOut:e.clone().translateWith(t.scaleCopy(n)),controlIn:e.translateWith(i.scaleCopy(n))}}var r=window.kendo,s=r.drawing,a=r.geometry,l=r.Class,c=a.Point,h=r.deepExtend,u=t.trim,d=r.util,f=d.last,p=/([a-df-z]{1})([^a-df-z]*)(z)?/gi,g=/[,\s]?([+\-]?(?:\d*\.\d+|\d+)(?:[eE][+\-]?\d+)?)/g,m="m",v="z",_=l.extend({parse:function(t,i){var n,o=new s.MultiPath(i),r=new c;return t.replace(p,function(t,i,s,a){var l=i.toLowerCase(),c=l===i,h=e(u(s));if(l===m&&(c?(r.x+=h[0],r.y+=h[1]):(r.x=h[0],r.y=h[1]),o.moveTo(r.x,r.y),h.length>2&&(l="l",h.splice(0,2))),y[l])y[l](o,{parameters:h,position:r,isRelative:c,previousCommand:n}),a&&a.toLowerCase()===v&&o.close();else if(l!==m)throw Error("Error while parsing SVG path. Unsupported command: "+l);n=l}),o}}),y={l:function(t,e){var i,n,o=e.parameters,r=e.position;for(i=0;i<o.length;i+=2)n=new c(o[i],o[i+1]),e.isRelative&&n.translateWith(r),t.lineTo(n.x,n.y),r.x=n.x,r.y=n.y},c:function(t,e){var i,n,o,r,s=e.parameters,a=e.position;for(r=0;r<s.length;r+=6)i=new c(s[r],s[r+1]),n=new c(s[r+2],s[r+3]),o=new c(s[r+4],s[r+5]),e.isRelative&&(n.translateWith(a),i.translateWith(a),o.translateWith(a)),t.curveTo(i,n,o),a.x=o.x,a.y=o.y},v:function(t,e){var n=e.isRelative?0:e.position.x;i(e.parameters,!0,n),this.l(t,e)},h:function(t,e){var n=e.isRelative?0:e.position.y;i(e.parameters,!1,n),this.l(t,e)},a:function(t,e){var i,n,o,r,s,a,l=e.parameters,h=e.position;for(i=0;i<l.length;i+=7)n=l[i],o=l[i+1],r=l[i+3],s=l[i+4],a=new c(l[i+5],l[i+6]),e.isRelative&&a.translateWith(h),t.arcTo(a,n,o,r,s),h.x=a.x,h.y=a.y},s:function(t,e){var i,o,r,s,a,l=e.parameters,h=e.position,u=e.previousCommand;for("s"!=u&&"c"!=u||(s=f(f(t.paths).segments).controlIn()),a=0;a<l.length;a+=4)r=new c(l[a],l[a+1]),o=new c(l[a+2],l[a+3]),e.isRelative&&(r.translateWith(h),o.translateWith(h)),i=s?n(s,h):h.clone(),s=r,t.curveTo(i,r,o),h.x=o.x,h.y=o.y},q:function(t,e){var i,n,r,s,a=e.parameters,l=e.position;for(s=0;s<a.length;s+=4)r=new c(a[s],a[s+1]),n=new c(a[s+2],a[s+3]),e.isRelative&&(r.translateWith(l),n.translateWith(l)),i=o(l,r,n),t.curveTo(i.controlOut,i.controlIn,n),l.x=n.x,l.y=n.y},t:function(t,e){var i,r,s,a,l,h=e.parameters,u=e.position,d=e.previousCommand;for("q"!=d&&"t"!=d||(a=f(f(t.paths).segments),r=a.controlIn().clone().translateWith(u.scaleCopy(-1/3)).scale(1.5)),l=0;l<h.length;l+=2)s=new c(h[l],h[l+1]),e.isRelative&&s.translateWith(u),r=r?n(r,u):u.clone(),i=o(u,r,s),t.curveTo(i.controlOut,i.controlIn,s),u.x=s.x,u.y=s.y}};_.current=new _,s.Path.parse=function(t,e){return _.current.parse(t,e)},h(s,{PathParser:_})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/search.min",["drawing/shapes.min"],t)}(function(){!function(t){function e(t,e){return t._zIndex<e._zIndex?1:t._zIndex>e._zIndex?-1:0}var i=window.kendo,n=i.drawing,o=i.geometry,r=i.Class,s=o.Rect,a=i.deepExtend,l=t.isArray,c=t.inArray,h=Math,u=1e4,d=75,f=r.extend({init:function(){this.shapes=[]},_add:function(t,e){this.shapes.push({bbox:e,shape:t}),t._quadNode=this},pointShapes:function(t){var e,i=this.shapes,n=i.length,o=[];for(e=0;e<n;e++)i[e].bbox.containsPoint(t)&&o.push(i[e].shape);return o},insert:function(t,e){this._add(t,e)},remove:function(t){var e,i=this.shapes,n=i.length;for(e=0;e<n;e++)if(i[e].shape===t){i.splice(e,1);break}}}),p=f.extend({init:function(t){f.fn.init.call(this),this.children=[],this.rect=t},inBounds:function(t){var e=this.rect,i=e.bottomRight(),n=t.bottomRight(),o=e.origin.x<=t.origin.x&&e.origin.y<=t.origin.y&&n.x<=i.x&&n.y<=i.y;return o},pointShapes:function(t){var e,i=this.children,n=i.length,o=f.fn.pointShapes.call(this,t);for(e=0;e<n;e++)o=o.concat(i[e].pointShapes(t));return o},insert:function(t,e){var i,n=!1,o=this.children;if(this.inBounds(e)){if(this.shapes.length<4)this._add(t,e);else{for(o.length||this._initChildren(),i=0;i<o.length;i++)if(o[i].insert(t,e)){n=!0;break}n||this._add(t,e)}n=!0}return n},_initChildren:function(){var t=this.rect,e=this.children,i=t.center(),n=t.width()/2,o=t.height()/2;e.push(new p(new s([t.origin.x,t.origin.y],[n,o])),new p(new s([i.x,t.origin.y],[n,o])),new p(new s([t.origin.x,i.y],[n,o])),new p(new s([i.x,i.y],[n,o])))}}),g=r.extend({ROOT_SIZE:1e3,init:function(){this.initRoots()},initRoots:function(){this.rootMap={},this.root=new f,this.rootElements=[]},clear:function(){var t,e=this,i=e.rootElements;for(t=0;t<i.length;t++)this.remove(i[t]);this.initRoots()},pointShape:function(t){var i,n=this.ROOT_SIZE,o=this.root.pointShapes(t),r=(this.rootMap[h.floor(t.x/n)]||{})[h.floor(t.y/n)];for(r&&(o=o.concat(r.pointShapes(t))),this.assignZindex(o),o.sort(e),i=0;i<o.length;i++)if(o[i].containsPoint(t))return o[i]},assignZindex:function(t){var e,i,n,o,r;for(r=0;r<t.length;r++){for(e=t[r],n=0,i=h.pow(u,d),o=[];e;)o.push(e),e=e.parent;for(;o.length;)e=o.pop(),n+=(c(e,e.parent?e.parent.children:this.rootElements)+1)*i,i/=u;t[r]._zIndex=n}},optionsChange:function(t){"transform"!=t.field&&"stroke.width"!=t.field||this.bboxChange(t.element)},geometryChange:function(t){this.bboxChange(t.element)},bboxChange:function(t){if("Group"===t.nodeType)for(var e=0;e<t.children.length;e++)this.bboxChange(t.children[e]);else t._quadNode&&t._quadNode.remove(t),this._insertShape(t)},add:function(t){var e=l(t)?t.slice(0):[t];this.rootElements.push.apply(this.rootElements,e),this._insert(e)},childrenChange:function(t){if("remove"==t.action)for(var e=0;e<t.items.length;e++)this.remove(t.items[e]);else this._insert(Array.prototype.slice.call(t.items,0))},_insert:function(t){for(var e;t.length>0;)e=t.pop(),e.addObserver(this),"Group"==e.nodeType?t.push.apply(t,e.children):this._insertShape(e)},_insertShape:function(t){var e,i,n,o,r=t.bbox();r&&(e=this.ROOT_SIZE,i=this.getSectors(r),n=i[0][0],o=i[1][0],this.inRoot(i)?this.root.insert(t,r):(this.rootMap[n]||(this.rootMap[n]={}),this.rootMap[n][o]||(this.rootMap[n][o]=new p(new s([n*e,o*e],[e,e]))),this.rootMap[n][o].insert(t,r)))},remove:function(t){var e,i;if(t.removeObserver(this),"Group"==t.nodeType)for(e=t.children,i=0;i<e.length;i++)this.remove(e[i]);else t._quadNode&&(t._quadNode.remove(t),delete t._quadNode)},inRoot:function(t){return t[0].length>1||t[1].length>1},getSectors:function(t){var e,i,n=this.ROOT_SIZE,o=t.bottomRight(),r=h.floor(o.x/n),s=h.floor(o.y/n),a=[[],[]];for(e=h.floor(t.origin.x/n);e<=r;e++)a[0].push(e);for(i=h.floor(t.origin.y/n);i<=s;i++)a[1].push(i);return a}});a(n,{ShapesQuadTree:g,QuadNode:p})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/svg.min",["drawing/shapes.min","util/main.min"],t)}(function(){!function(t){function e(t){var e,i,n,o;try{e=t.getScreenCTM?t.getScreenCTM():null}catch(r){}e&&(i=-e.e%1,n=-e.f%1,o=t.style,0===i&&0===n||(o.left=i+"px",o.top=n+"px"))}function i(){var t=document.getElementsByTagName("base")[0],e="",i=document.location.href,n=i.indexOf("#");return t&&!h.support.browser.msie&&(n!==-1&&(i=i.substring(0,n)),e=i),e}function n(t){return"url("+i()+"#"+t+")"}function o(t){var e,i,n,o=new z,r=t.clippedBBox();return r&&(e=r.getOrigin(),i=new f.Group,i.transform(d.transform().translate(-e.x,-e.y)),i.children.push(t),t=i),o.load([t]),n="<?xml version='1.0' ?><svg xmlns='"+D+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>"+o.render()+"</svg>",o.destroy(),n}function r(e,i){var n=o(e);return i&&i.raw||(n="data:image/svg+xml;base64,"+g.encodeBase64(n)),t.Deferred().resolve(n).promise()}function s(t,e){return"clip"==t||"fill"==t&&(!e||e.nodeType==C)}function a(t){if(!t||!t.indexOf||t.indexOf("&")<0)return t;var e=a._element;return e.innerHTML=t,e.textContent||e.innerText}var l,c=document,h=window.kendo,u=h.deepExtend,d=h.geometry,f=h.drawing,p=f.BaseNode,g=h.util,m=g.defined,v=g.isTransparent,_=g.renderAttr,y=g.renderAllAttr,w=g.renderTemplate,x=t.inArray,b="butt",k=f.DASH_ARRAYS,C="gradient",S="none",T=".kendo",A="solid",P=" ",D="http://www.w3.org/2000/svg",M="transform",E="undefined",I=f.Surface.extend({init:function(t,i){f.Surface.fn.init.call(this,t,i),this._root=new z(this.options),Q(this.element[0],this._template(this)),this._rootElement=this.element[0].firstElementChild,e(this._rootElement),this._root.attachTo(this._rootElement),this.element.on("click"+T,this._click),this.element.on("mouseover"+T,this._mouseenter),this.element.on("mouseout"+T,this._mouseleave),this.element.on("mousemove"+T,this._mousemove),this.resize()},type:"svg",destroy:function(){this._root&&(this._root.destroy(),this._root=null,this._rootElement=null,this.element.off(T)),f.Surface.fn.destroy.call(this)},translate:function(t){var e=h.format("{0} {1} {2} {3}",Math.round(t.x),Math.round(t.y),this._size.width,this._size.height);this._offset=t,this._rootElement.setAttribute("viewBox",e)},draw:function(t){f.Surface.fn.draw.call(this,t),this._root.load([t])},clear:function(){f.Surface.fn.clear.call(this),this._root.clear()},svg:function(){return"<?xml version='1.0' ?>"+this._template(this)},exportVisual:function(){var t,e=this._visual,i=this._offset;return i&&(t=new f.Group,t.children.push(e),t.transform(d.transform().translate(-i.x,-i.y)),e=t),e},_resize:function(){this._offset&&this.translate(this._offset)},_template:w("<svg style='width: 100%; height: 100%; overflow: hidden;' xmlns='"+D+"' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1'>#= d._root.render() #</svg>")}),B=p.extend({init:function(t){p.fn.init.call(this,t),this.definitions={}},destroy:function(){this.element&&(this.element._kendoNode=null,this.element=null),this.clearDefinitions(),p.fn.destroy.call(this)},load:function(t,e){var i,n,o,r,s=this,a=s.element;for(r=0;r<t.length;r++)n=t[r],o=n.children,i=new X[n.nodeType](n),m(e)?s.insertAt(i,e):s.append(i),i.createDefinitions(),o&&o.length>0&&i.load(o),a&&i.attachTo(a,e)},root:function(){for(var t=this;t.parent;)t=t.parent;return t},attachTo:function(t,e){var i,n=c.createElement("div");Q(n,"<svg xmlns='"+D+"' version='1.1'>"+this.render()+"</svg>"),i=n.firstChild.firstChild,i&&(m(e)?t.insertBefore(i,t.childNodes[e]||null):t.appendChild(i),this.setElement(i))},setElement:function(t){var e,i,n=this.childNodes;for(this.element&&(this.element._kendoNode=null),this.element=t,this.element._kendoNode=this,i=0;i<n.length;i++)e=t.childNodes[i],n[i].setElement(e)},clear:function(){var t,e;for(this.clearDefinitions(),this.element&&(this.element.innerHTML=""),t=this.childNodes,e=0;e<t.length;e++)t[e].destroy();this.childNodes=[]},removeSelf:function(){if(this.element){var t=this.element.parentNode;t&&t.removeChild(this.element),this.element=null}p.fn.removeSelf.call(this)},template:w("#= d.renderChildren() #"),render:function(){return this.template(this)},renderChildren:function(){var t,e=this.childNodes,i="";for(t=0;t<e.length;t++)i+=e[t].render();return i},optionsChange:function(t){var e=t.field,i=t.value;"visible"===e?this.css("display",i?"":S):l[e]&&s(e,i)?this.updateDefinition(e,i):"opacity"===e&&this.attr("opacity",i),p.fn.optionsChange.call(this,t)},attr:function(t,e){this.element&&this.element.setAttribute(t,e)},allAttr:function(t){for(var e=0;e<t.length;e++)this.attr(t[e][0],t[e][1])},css:function(t,e){this.element&&(this.element.style[t]=e)},allCss:function(t){for(var e=0;e<t.length;e++)this.css(t[e][0],t[e][1])},removeAttr:function(t){this.element&&this.element.removeAttribute(t)},mapTransform:function(t){var e=[];return t&&e.push([M,"matrix("+t.matrix().toString(6)+")"]),e},renderTransform:function(){return y(this.mapTransform(this.srcElement.transform()))},transformChange:function(t){t?this.allAttr(this.mapTransform(t)):this.removeAttr(M)},mapStyle:function(){var t=this.srcElement.options,e=[["cursor",t.cursor]];return t.visible===!1&&e.push(["display",S]),e},renderStyle:function(){return _("style",g.renderStyle(this.mapStyle(!0)))},renderOpacity:function(){return _("opacity",this.srcElement.options.opacity)},createDefinitions:function(){var t,e,i,n,o=this.srcElement,r=this.definitions;if(o){i=o.options;for(e in l)t=i.get(e),t&&s(e,t)&&(r[e]=t,n=!0);n&&this.definitionChange({action:"add",definitions:r})}},definitionChange:function(t){this.parent&&this.parent.definitionChange(t)},updateDefinition:function(t,e){var i=this.definitions,o=i[t],r=l[t],s={};o&&(s[t]=o,this.definitionChange({action:"remove",definitions:s}),delete i[t]),e?(s[t]=e,this.definitionChange({action:"add",definitions:s}),i[t]=e,this.attr(r,n(e.id))):o&&this.removeAttr(r)},clearDefinitions:function(){var t,e=this.definitions;for(t in e){this.definitionChange({action:"remove",definitions:e}),this.definitions={};break}},renderDefinitions:function(){return y(this.mapDefinitions())},mapDefinitions:function(){var t,e=this.definitions,i=[];for(t in e)i.push([l[t],n(e[t].id)]);return i}}),z=B.extend({init:function(t){B.fn.init.call(this),this.options=t,this.defs=new L},attachTo:function(t){this.element=t,this.defs.attachTo(t.firstElementChild)},clear:function(){p.fn.clear.call(this)},template:w("#=d.defs.render()##= d.renderChildren() #"),definitionChange:function(t){this.defs.definitionChange(t)}}),L=B.extend({init:function(){B.fn.init.call(this),this.definitionMap={}},attachTo:function(t){this.element=t},template:w("<defs>#= d.renderChildren()#</defs>"),definitionChange:function(t){var e=t.definitions,i=t.action;"add"==i?this.addDefinitions(e):"remove"==i&&this.removeDefinitions(e)},createDefinition:function(t,e){var i;return"clip"==t?i=R:"fill"==t&&(e instanceof f.LinearGradient?i=q:e instanceof f.RadialGradient&&(i=$)),new i(e)},addDefinitions:function(t){for(var e in t)this.addDefinition(e,t[e])},addDefinition:function(t,e){var i,n=this.definitionMap,o=e.id,r=this.element,s=n[o];s?s.count++:(i=this.createDefinition(t,e),n[o]={element:i,count:1},this.append(i),r&&i.attachTo(this.element))},removeDefinitions:function(t){for(var e in t)this.removeDefinition(t[e])},removeDefinition:function(t){var e=this.definitionMap,i=t.id,n=e[i];n&&(n.count--,0===n.count&&(this.remove(x(n.element,this.childNodes),1),delete e[i]))}}),R=B.extend({init:function(t){B.fn.init.call(this),this.srcElement=t,this.id=t.id,this.load([t])},template:w("<clipPath id='#=d.id#'>#= d.renderChildren()#</clipPath>")}),O=B.extend({template:w("<g#= d.renderTransform() + d.renderStyle() + d.renderOpacity() + d.renderDefinitions()#>#= d.renderChildren() #</g>"),optionsChange:function(t){t.field==M&&this.transformChange(t.value),B.fn.optionsChange.call(this,t)}}),V=B.extend({geometryChange:function(){this.attr("d",this.renderData()),this.invalidate()},optionsChange:function(t){switch(t.field){case"fill":t.value?this.allAttr(this.mapFill(t.value)):this.removeAttr("fill");break;case"fill.color":this.allAttr(this.mapFill({color:t.value}));break;case"stroke":t.value?this.allAttr(this.mapStroke(t.value)):this.removeAttr("stroke");break;case M:this.transformChange(t.value);break;default:var e=this.attributeMap[t.field];e&&this.attr(e,t.value)}B.fn.optionsChange.call(this,t)},attributeMap:{"fill.opacity":"fill-opacity","stroke.color":"stroke","stroke.width":"stroke-width","stroke.opacity":"stroke-opacity"},content:function(){this.element&&(this.element.textContent=this.srcElement.content())},renderData:function(){return this.printPath(this.srcElement)},printPath:function(t){var e,i,n,o,r,s=t.segments,a=s.length;if(a>0){for(e=[],r=1;r<a;r++)n=this.segmentType(s[r-1],s[r]),n!==o&&(o=n,e.push(n)),e.push("L"===n?this.printPoints(s[r].anchor()):this.printPoints(s[r-1].controlOut(),s[r].controlIn(),s[r].anchor()));return i="M"+this.printPoints(s[0].anchor())+P+e.join(P),t.options.closed&&(i+="Z"),i}},printPoints:function(){var t,e=arguments,i=e.length,n=[];for(t=0;t<i;t++)n.push(e[t].toString(3));return n.join(P)},segmentType:function(t,e){return t.controlOut()&&e.controlIn()?"C":"L"},mapStroke:function(t){var e=[];return t&&!v(t.color)?(e.push(["stroke",t.color]),e.push(["stroke-width",t.width]),e.push(["stroke-linecap",this.renderLinecap(t)]),e.push(["stroke-linejoin",t.lineJoin]),m(t.opacity)&&e.push(["stroke-opacity",t.opacity]),m(t.dashType)&&e.push(["stroke-dasharray",this.renderDashType(t)])):e.push(["stroke",S]),e},renderStroke:function(){return y(this.mapStroke(this.srcElement.options.stroke))},renderDashType:function(t){var e,i,n,o=t.width||1,r=t.dashType;if(r&&r!=A){for(e=k[r.toLowerCase()],i=[],n=0;n<e.length;n++)i.push(e[n]*o);return i.join(" ")}},renderLinecap:function(t){var e=t.dashType,i=t.lineCap;return e&&e!=A?b:i},mapFill:function(t){var e=[];return t&&t.nodeType==C||(t&&!v(t.color)?(e.push(["fill",t.color]),m(t.opacity)&&e.push(["fill-opacity",t.opacity])):e.push(["fill",S])),e},renderFill:function(){return y(this.mapFill(this.srcElement.options.fill))},template:w("<path #= d.renderStyle() # #= d.renderOpacity() # #= kendo.util.renderAttr('d', d.renderData()) # #= d.renderStroke() # #= d.renderFill() # #= d.renderDefinitions() # #= d.renderTransform() #></path>")}),F=V.extend({renderData:function(){return this.printPath(this.srcElement.toPath())}}),N=V.extend({renderData:function(){var t,e,i=this.srcElement.paths;if(i.length>0){for(t=[],e=0;e<i.length;e++)t.push(this.printPath(i[e]));return t.join(" ")}}}),H=V.extend({geometryChange:function(){var t=this.center();this.attr("cx",t.x),this.attr("cy",t.y),this.attr("r",this.radius()),this.invalidate()},center:function(){return this.srcElement.geometry().center},radius:function(){return this.srcElement.geometry().radius},template:w("<circle #= d.renderStyle() # #= d.renderOpacity() # cx='#= d.center().x #' cy='#= d.center().y #' r='#= d.radius() #' #= d.renderStroke() # #= d.renderFill() # #= d.renderDefinitions() # #= d.renderTransform() # ></circle>")}),U=V.extend({geometryChange:function(){var t=this.pos();this.attr("x",t.x),this.attr("y",t.y),this.invalidate()},optionsChange:function(t){"font"===t.field?(this.attr("style",g.renderStyle(this.mapStyle())),this.geometryChange()):"content"===t.field&&V.fn.content.call(this,this.srcElement.content()),V.fn.optionsChange.call(this,t)},mapStyle:function(t){var e=V.fn.mapStyle.call(this,t),i=this.srcElement.options.font;return t&&(i=h.htmlEncode(i)),e.push(["font",i]),e},pos:function(){var t=this.srcElement.position(),e=this.srcElement.measure();return t.clone().setY(t.y+e.baseline)},renderContent:function(){var t=this.srcElement.content();return t=a(t),t=h.htmlEncode(t)},template:w("<text #= d.renderStyle() # #= d.renderOpacity() # x='#= this.pos().x #' y='#= this.pos().y #' #= d.renderStroke() # #= d.renderTransform() # #= d.renderDefinitions() # #= d.renderFill() #>#= d.renderContent() #</text>")}),j=V.extend({geometryChange:function(){this.allAttr(this.mapPosition()),this.invalidate()},optionsChange:function(t){"src"===t.field&&this.allAttr(this.mapSource()),V.fn.optionsChange.call(this,t)},mapPosition:function(){var t=this.srcElement.rect(),e=t.topLeft();return[["x",e.x],["y",e.y],["width",t.width()+"px"],["height",t.height()+"px"]]},renderPosition:function(){return y(this.mapPosition())},mapSource:function(t){var e=this.srcElement.src();return t&&(e=h.htmlEncode(e)),[["xlink:href",e]]},renderSource:function(){return y(this.mapSource(!0))},template:w("<image preserveAspectRatio='none' #= d.renderStyle() # #= d.renderTransform()# #= d.renderOpacity() # #= d.renderPosition() # #= d.renderSource() # #= d.renderDefinitions()#></image>")}),G=B.extend({template:w("<stop #=d.renderOffset()# #=d.renderStyle()# />"),renderOffset:function(){return _("offset",this.srcElement.offset())},mapStyle:function(){var t=this.srcElement;return[["stop-color",t.color()],["stop-opacity",t.opacity()]]},optionsChange:function(t){"offset"==t.field?this.attr(t.field,t.value):"color"!=t.field&&"opacity"!=t.field||this.css("stop-"+t.field,t.value)}}),W=B.extend({init:function(t){B.fn.init.call(this,t),this.id=t.id,this.loadStops()},loadStops:function(){var t,e,i=this.srcElement,n=i.stops,o=this.element;for(e=0;e<n.length;e++)t=new G(n[e]),this.append(t),o&&t.attachTo(o)},optionsChange:function(t){"gradient.stops"==t.field?(p.fn.clear.call(this),this.loadStops()):t.field==C&&this.allAttr(this.mapCoordinates())},renderCoordinates:function(){return y(this.mapCoordinates())},mapSpace:function(){return["gradientUnits",this.srcElement.userSpace()?"userSpaceOnUse":"objectBoundingBox"]}}),q=W.extend({template:w("<linearGradient id='#=d.id#' #=d.renderCoordinates()#>#= d.renderChildren()#</linearGradient>"),mapCoordinates:function(){var t=this.srcElement,e=t.start(),i=t.end(),n=[["x1",e.x],["y1",e.y],["x2",i.x],["y2",i.y],this.mapSpace()];return n}}),$=W.extend({template:w("<radialGradient id='#=d.id#' #=d.renderCoordinates()#>#= d.renderChildren()#</radialGradient>"),mapCoordinates:function(){var t=this.srcElement,e=t.center(),i=t.radius(),n=[["cx",e.x],["cy",e.y],["r",i],this.mapSpace()];
return n}}),Y=V.extend({geometryChange:function(){var t=this.srcElement.geometry();this.attr("x",t.origin.x),this.attr("y",t.origin.y),this.attr("width",t.size.width),this.attr("height",t.size.height),this.invalidate()},size:function(){return this.srcElement.geometry().size},origin:function(){return this.srcElement.geometry().origin},template:w("<rect #= d.renderStyle() # #= d.renderOpacity() # x='#= d.origin().x #' y='#= d.origin().y #' width='#= d.size().width #' height='#= d.size().height #'#= d.renderStroke() # #= d.renderFill() # #= d.renderDefinitions() # #= d.renderTransform() # />")}),X={Group:O,Text:U,Path:V,MultiPath:N,Circle:H,Arc:F,Image:j,Rect:Y},Q=function(t,e){t.innerHTML=e};!function(){var t="<svg xmlns='"+D+"'></svg>",e=c.createElement("div"),i=typeof DOMParser!=E;e.innerHTML=t,i&&e.firstChild.namespaceURI!=D&&(Q=function(t,e){var i=new DOMParser,n=i.parseFromString(e,"text/xml"),o=c.adoptNode(n.documentElement);t.innerHTML="",t.appendChild(o)})}(),a._element=document.createElement("span"),l={clip:"clip-path",fill:"fill"},h.support.svg=function(){return c.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")}(),h.support.svg&&f.SurfaceFactory.current.register("svg",I,10),u(f,{exportSVG:r,svg:{ArcNode:F,CircleNode:H,ClipNode:R,DefinitionNode:L,GradientStopNode:G,GroupNode:O,ImageNode:j,LinearGradientNode:q,MultiPathNode:N,Node:B,PathNode:V,RadialGradientNode:$,RectNode:Y,RootNode:z,Surface:I,TextNode:U,_exportGroup:o}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/canvas.min",["drawing/search.min","kendo.color.min"],t)}(function(){!function(t){function e(e,i){var n,o,r,s,a,l,c={width:"800px",height:"600px",cors:"Anonymous"},h=e.clippedBBox();return h&&(n=h.getOrigin(),o=new x.Group,o.transform(w.transform().translate(-n.x,-n.y)),o.children.push(e),e=o,r=h.getSize(),c.width=r.width+"px",c.height=r.height+"px"),i=p(c,i),s=t("<div />").css({display:"none",width:i.width,height:i.height}).appendTo(document.body),a=new D(s,i),a.suspendTracking(),a.draw(e),l=a.image(),l.always(function(){a.destroy(),s.remove()}),l}function i(t,e){var i,n,o;for(o=0;o<e.length;o++)n=e[o],i=f.parseColor(n.color()),i.a*=n.opacity(),t.addColorStop(n.offset(),i.toCssRgba())}var n,o,r,s,a,l,c,h,u,d=document,f=window.kendo,p=f.deepExtend,g=f.util,m=g.defined,v=g.isTransparent,_=g.renderTemplate,y=g.valueOrDefault,w=f.geometry,x=f.drawing,b=x.BaseNode,k=t.proxy,C="butt",S=x.DASH_ARRAYS,T=1e3/60,A="solid",P=".kendo",D=x.Surface.extend({init:function(e,i){x.Surface.fn.init.call(this,e,i),this.element[0].innerHTML=this._template(this);var o=this.element[0].firstElementChild;o.width=t(e).width(),o.height=t(e).height(),this._rootElement=o,this._root=new n(o)},destroy:function(){x.Surface.fn.destroy.call(this),this._root&&(this._root.destroy(),this._root=null),this._searchTree&&(this._searchTree.clear(),delete this._searchTree),this.element.off(P)},type:"canvas",draw:function(t){x.Surface.fn.draw.call(this,t),this._root.load([t],void 0,this.options.cors),this._searchTree&&this._searchTree.add([t])},clear:function(){x.Surface.fn.clear.call(this),this._root.clear(),this._searchTree&&this._searchTree.clear()},eventTarget:function(t){var e,i;if(this._searchTree)return e=this._surfacePoint(t),i=this._searchTree.pointShape(e)},image:function(){var e,i=this._root,n=this._rootElement,o=[];return i.traverse(function(t){t.loading&&o.push(t.loading)}),e=t.Deferred(),t.when.apply(t,o).done(function(){i._invalidate();try{var t=n.toDataURL();e.resolve(t)}catch(o){e.reject(o)}}).fail(function(t){e.reject(t)}),e.promise()},suspendTracking:function(){x.Surface.fn.suspendTracking.call(this),this._searchTree&&(this._searchTree.clear(),delete this._searchTree)},resumeTracking:function(){var t,e,i;if(x.Surface.fn.resumeTracking.call(this),!this._searchTree){for(this._searchTree=new x.ShapesQuadTree,t=this._root.childNodes,e=[],i=0;i<t.length;i++)e.push(t[i].srcElement);this._searchTree.add(e)}},_resize:function(){this._rootElement.width=this._size.width,this._rootElement.height=this._size.height,this._root.invalidate()},_template:_("<canvas style='width: 100%; height: 100%;'></canvas>"),_enableTracking:function(){this._searchTree=new x.ShapesQuadTree,this._mouseTrackHandler=k(this._trackMouse,this),this.element.on("click"+P,this._mouseTrackHandler),this.element.on("mousemove"+P,this._mouseTrackHandler),x.Surface.fn._enableTracking.call(this)},_trackMouse:function(t){var e,i;this._suspendedTracking||(e=this.eventTarget(t),"click"!=t.type?(i=this._currentShape,i&&i!==e&&this.trigger("mouseleave",{element:i,originalEvent:t,type:"mouseleave"}),e&&i!==e&&this.trigger("mouseenter",{element:e,originalEvent:t,type:"mouseenter"}),this.trigger("mousemove",{element:e,originalEvent:t,type:"mousemove"}),this._currentShape=e):e&&this.trigger("click",{element:e,originalEvent:t,type:"click"}))}}),M=b.extend({init:function(t){b.fn.init.call(this,t),t&&this.initClip()},initClip:function(){var t=this.srcElement.clip();t&&(this.clip=t,t.addObserver(this))},clear:function(){this.srcElement&&this.srcElement.removeObserver(this),this.clearClip(),b.fn.clear.call(this)},clearClip:function(){this.clip&&(this.clip.removeObserver(this),delete this.clip)},setClip:function(t){this.clip&&(t.beginPath(),o.fn.renderPoints(t,this.clip),t.clip())},optionsChange:function(t){"clip"==t.field&&(this.clearClip(),this.initClip()),b.fn.optionsChange.call(this,t)},setTransform:function(t){if(this.srcElement){var e=this.srcElement.transform();e&&t.transform.apply(t,e.matrix().toArray(6))}},loadElements:function(t,e,i){var n,o,r,s,a=this;for(s=0;s<t.length;s++)o=t[s],r=o.children,n=new u[o.nodeType](o,i),r&&r.length>0&&n.load(r,e,i),m(e)?a.insertAt(n,e):a.append(n)},load:function(t,e,i){this.loadElements(t,e,i),this.invalidate()},setOpacity:function(t){if(this.srcElement){var e=this.srcElement.opacity();m(e)&&this.globalAlpha(t,e)}},globalAlpha:function(t,e){e&&t.globalAlpha&&(e*=t.globalAlpha),t.globalAlpha=e},visible:function(){var t=this.srcElement;return!t||t&&t.options.visible!==!1}}),E=M.extend({renderTo:function(t){var e,i,n;if(this.visible()){for(t.save(),this.setTransform(t),this.setClip(t),this.setOpacity(t),e=this.childNodes,i=0;i<e.length;i++)n=e[i],n.visible()&&n.renderTo(t);t.restore()}}});x.mixins.Traversable.extend(E.fn,"childNodes"),n=E.extend({init:function(t){E.fn.init.call(this),this.canvas=t,this.ctx=t.getContext("2d");var e=k(this._invalidate,this);this.invalidate=f.throttle(function(){f.animationFrame(e)},T)},destroy:function(){E.fn.destroy.call(this),this.canvas=null,this.ctx=null},load:function(t,e,i){this.loadElements(t,e,i),this._invalidate()},_invalidate:function(){this.ctx&&(this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.renderTo(this.ctx))}}),x.mixins.Traversable.extend(n.fn,"childNodes"),o=M.extend({renderTo:function(t){t.save(),this.setTransform(t),this.setClip(t),this.setOpacity(t),t.beginPath(),this.renderPoints(t,this.srcElement),this.setLineDash(t),this.setLineCap(t),this.setLineJoin(t),this.setFill(t),this.setStroke(t),t.restore()},setFill:function(t){var e=this.srcElement.options.fill,i=!1;return e&&("gradient"==e.nodeType?(this.setGradientFill(t,e),i=!0):v(e.color)||(t.fillStyle=e.color,t.save(),this.globalAlpha(t,e.opacity),t.fill(),t.restore(),i=!0)),i},setGradientFill:function(t,e){var n,o,r,s,a=this.srcElement.rawBBox();e instanceof x.LinearGradient?(o=e.start(),r=e.end(),n=t.createLinearGradient(o.x,o.y,r.x,r.y)):e instanceof x.RadialGradient&&(s=e.center(),n=t.createRadialGradient(s.x,s.y,0,s.x,s.y,e.radius())),i(n,e.stops),t.save(),e.userSpace()||t.transform(a.width(),0,0,a.height(),a.origin.x,a.origin.y),t.fillStyle=n,t.fill(),t.restore()},setStroke:function(t){var e=this.srcElement.options.stroke;if(e&&!v(e.color)&&e.width>0)return t.strokeStyle=e.color,t.lineWidth=y(e.width,1),t.save(),this.globalAlpha(t,e.opacity),t.stroke(),t.restore(),!0},dashType:function(){var t=this.srcElement.options.stroke;if(t&&t.dashType)return t.dashType.toLowerCase()},setLineDash:function(t){var e,i=this.dashType();i&&i!=A&&(e=S[i],t.setLineDash?t.setLineDash(e):(t.mozDash=e,t.webkitLineDash=e))},setLineCap:function(t){var e=this.dashType(),i=this.srcElement.options.stroke;e&&e!==A?t.lineCap=C:i&&i.lineCap&&(t.lineCap=i.lineCap)},setLineJoin:function(t){var e=this.srcElement.options.stroke;e&&e.lineJoin&&(t.lineJoin=e.lineJoin)},renderPoints:function(t,e){var i,n,o,r,s,a,l=e.segments;if(0!==l.length){for(i=l[0],n=i.anchor(),t.moveTo(n.x,n.y),o=1;o<l.length;o++)i=l[o],n=i.anchor(),r=l[o-1],s=r.controlOut(),a=i.controlIn(),s&&a?t.bezierCurveTo(s.x,s.y,a.x,a.y,n.x,n.y):t.lineTo(n.x,n.y);e.options.closed&&t.closePath()}}}),r=o.extend({renderPoints:function(t){var e,i=this.srcElement.paths;for(e=0;e<i.length;e++)o.fn.renderPoints(t,i[e])}}),s=o.extend({renderPoints:function(t){var e=this.srcElement.geometry(),i=e.center,n=e.radius;t.arc(i.x,i.y,n,0,2*Math.PI)}}),a=o.extend({renderPoints:function(t){var e=this.srcElement.toPath();o.fn.renderPoints.call(this,t,e)}}),l=o.extend({renderTo:function(t){var e=this.srcElement,i=e.position(),n=e.measure();t.save(),this.setTransform(t),this.setClip(t),this.setOpacity(t),t.beginPath(),t.font=e.options.font,this.setFill(t)&&t.fillText(e.content(),i.x,i.y+n.baseline),this.setStroke(t)&&(this.setLineDash(t),t.strokeText(e.content(),i.x,i.y+n.baseline)),t.restore()}}),c=o.extend({init:function(e,i){o.fn.init.call(this,e),this.onLoad=k(this.onLoad,this),this.onError=k(this.onError,this),this.loading=t.Deferred();var n=this.img=new Image;i&&!/^data:/i.test(e.src())&&(n.crossOrigin=i),n.src=e.src(),n.complete?this.onLoad():(n.onload=this.onLoad,n.onerror=this.onError)},renderTo:function(t){"resolved"===this.loading.state()&&(t.save(),this.setTransform(t),this.setClip(t),this.drawImage(t),t.restore())},optionsChange:function(e){"src"===e.field?(this.loading=t.Deferred(),this.img.src=this.srcElement.src()):o.fn.optionsChange.call(this,e)},onLoad:function(){this.loading.resolve(),this.invalidate()},onError:function(){this.loading.reject(Error("Unable to load image '"+this.img.src+"'. Check for connectivity and verify CORS headers."))},drawImage:function(t){var e=this.srcElement.rect(),i=e.topLeft();t.drawImage(this.img,i.x,i.y,e.width(),e.height())}}),h=o.extend({renderPoints:function(t){var e=this.srcElement.geometry(),i=e.origin,n=e.size;t.rect(i.x,i.y,n.width,n.height)}}),u={Group:E,Text:l,Path:o,MultiPath:r,Circle:s,Arc:a,Image:c,Rect:h},f.support.canvas=function(){return!!d.createElement("canvas").getContext}(),f.support.canvas&&x.SurfaceFactory.current.register("canvas",D,20),p(f.drawing,{exportImage:e,canvas:{ArcNode:a,CircleNode:s,GroupNode:E,ImageNode:c,MultiPathNode:r,Node:M,PathNode:o,RectNode:h,RootNode:n,Surface:D,TextNode:l}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/vml.min",["drawing/shapes.min","kendo.color.min"],t)}(function(){!function(t){function e(){if(u.namespaces&&!u.namespaces.kvml){u.namespaces.add("kvml","urn:schemas-microsoft-com:vml");var t=u.styleSheets.length>30?u.styleSheets[0]:u.createStyleSheet();t.addRule(".kvml","behavior:url(#default#VML)")}}function i(t){var e=u.createElement("kvml:"+t);return e.className="kvml",e}function n(t){var e,i=t.length,n=[];for(e=0;e<i;e++)n.push(t[e].scaleCopy(I).toString(0,","));return n.join(" ")}function o(t,e){var i,o,s,a,l,c=t.segments,h=c.length;if(h>0){for(i=[],l=1;l<h;l++)s=r(c[l-1],c[l]),s!==a&&(a=s,i.push(s)),i.push("l"===s?n([c[l].anchor()]):n([c[l-1].controlOut(),c[l].controlIn(),c[l].anchor()]));return o="m "+n([c[0].anchor()])+" "+i.join(" "),t.options.closed&&(o+=" x"),e!==!0&&(o+=" e"),o}}function r(t,e){return t.controlOut()&&e.controlIn()?"c":"l"}function s(t){return 0===t.indexOf("fill")||0===t.indexOf(z)}function a(t,e,i){var n,o=i*D(e.opacity(),1);return n=t?l(t,e.color(),o):l(e.color(),"#fff",1-o)}function l(t,e,i){var n=new k(t),o=new k(e),r=c(n.r,o.r,i),s=c(n.g,o.g,i),a=c(n.b,o.b,i);return new k(r,s,a).toHex()}function c(t,e,i){return d.round(i*e+(1-i)*t)}var h,u=document,d=Math,f=d.atan2,p=d.ceil,g=d.sqrt,m=window.kendo,v=m.deepExtend,_=t.noop,y=m.drawing,w=y.BaseNode,x=m.geometry,b=x.toMatrix,k=m.Color,C=m.util,S=C.isTransparent,T=C.defined,A=C.deg,P=C.round,D=C.valueOrDefault,M="none",E=".kendo",I=100,B=I*I,z="gradient",L=4,R=y.Surface.extend({init:function(t,i){y.Surface.fn.init.call(this,t,i),e(),this.element.empty(),this._root=new V,this._root.attachTo(this.element[0]),this.element.on("click"+E,this._click),this.element.on("mouseover"+E,this._mouseenter),this.element.on("mouseout"+E,this._mouseleave),this.element.on("mousemove"+E,this._mousemove)},type:"vml",destroy:function(){this._root&&(this._root.destroy(),this._root=null,this.element.off(E)),y.Surface.fn.destroy.call(this)},draw:function(t){y.Surface.fn.draw.call(this,t),this._root.load([t],void 0,null)},clear:function(){y.Surface.fn.clear.call(this),this._root.clear()}}),O=w.extend({init:function(t){w.fn.init.call(this,t),this.createElement(),this.attachReference()},observe:_,destroy:function(){this.element&&(this.element._kendoNode=null,this.element=null),w.fn.destroy.call(this)},clear:function(){var t,e;for(this.element&&(this.element.innerHTML=""),t=this.childNodes,e=0;e<t.length;e++)t[e].destroy();this.childNodes=[]},removeSelf:function(){this.element&&(this.element.parentNode.removeChild(this.element),this.element=null),w.fn.removeSelf.call(this)},createElement:function(){this.element=u.createElement("div")},attachReference:function(){this.element._kendoNode=this},load:function(t,e,i,n){var o,r,s,a,l,c;for(n=D(n,1),this.srcElement&&(n*=D(this.srcElement.options.opacity,1)),o=0;o<t.length;o++)r=t[o],s=r.children,a=r.currentTransform(i),l=n*D(r.options.opacity,1),c=new lt[r.nodeType](r,a,l),s&&s.length>0&&c.load(s,e,a,n),T(e)?this.insertAt(c,e):this.append(c),c.attachTo(this.element,e)},attachTo:function(t,e){T(e)?t.insertBefore(this.element,t.children[e]||null):t.appendChild(this.element)},optionsChange:function(t){"visible"==t.field&&this.css("display",t.value!==!1?"":M)},setStyle:function(){this.allCss(this.mapStyle())},mapStyle:function(){var t=[];return this.srcElement&&this.srcElement.options.visible===!1&&t.push(["display",M]),t},mapOpacityTo:function(t,e){var i=D(this.opacity,1);i*=D(e,1),t.push(["opacity",i])},attr:function(t,e){this.element&&(this.element[t]=e)},allAttr:function(t){for(var e=0;e<t.length;e++)this.attr(t[e][0],t[e][1])},css:function(t,e){this.element&&(this.element.style[t]=e)},allCss:function(t){for(var e=0;e<t.length;e++)this.css(t[e][0],t[e][1])}}),V=O.extend({createElement:function(){O.fn.createElement.call(this),this.allCss([["width","100%"],["height","100%"],["position","relative"],["visibility","visible"]])},attachReference:_}),F=m.Class.extend({init:function(t,e){this.srcElement=t,this.observer=e,t.addObserver(this)},geometryChange:function(){this.observer.optionsChange({field:"clip",value:this.srcElement})},clear:function(){this.srcElement.removeObserver(this)}}),N=O.extend({init:function(t){O.fn.init.call(this,t),t&&this.initClip()},observe:function(){w.fn.observe.call(this)},mapStyle:function(){var t=O.fn.mapStyle.call(this);return this.srcElement&&this.srcElement.clip()&&t.push(["clip",this.clipRect()]),t},optionsChange:function(t){"clip"==t.field&&(this.clearClip(),this.initClip(),this.setClip()),O.fn.optionsChange.call(this,t)},clear:function(){this.clearClip(),O.fn.clear.call(this)},initClip:function(){this.srcElement.clip()&&(this.clip=new F(this.srcElement.clip(),this),this.clip.observer=this)},clearClip:function(){this.clip&&(this.clip.clear(),this.clip=null,this.css("clip",this.clipRect()))},setClip:function(){this.clip&&this.css("clip",this.clipRect())},clipRect:function(){var t,e,i,n=h,o=this.srcElement.clip();return o&&(t=this.clipBBox(o),e=t.topLeft(),i=t.bottomRight(),n=m.format("rect({0}px {1}px {2}px {3}px)",e.y,i.x,i.y,e.x)),n},clipBBox:function(t){var e=this.srcElement.rawBBox().topLeft(),i=t.rawBBox();return i.origin.translate(-e.x,-e.y),i}}),H=N.extend({createElement:function(){O.fn.createElement.call(this),this.setStyle()},attachTo:function(t,e){this.css("display",M),O.fn.attachTo.call(this,t,e),this.srcElement.options.visible!==!1&&this.css("display","")},_attachTo:function(t){var e=document.createDocumentFragment();e.appendChild(this.element),t.appendChild(e)},mapStyle:function(){var t=N.fn.mapStyle.call(this);return t.push(["position","absolute"]),t.push(["white-space","nowrap"]),t},optionsChange:function(t){"transform"===t.field&&this.refreshTransform(),"opacity"===t.field&&this.refreshOpacity(),N.fn.optionsChange.call(this,t)},refreshTransform:function(t){var e,i=this.srcElement.currentTransform(t),n=this.childNodes,o=n.length;for(this.setClip(),e=0;e<o;e++)n[e].refreshTransform(i)},currentOpacity:function(){var t=D(this.srcElement.options.opacity,1);return this.parent&&this.parent.currentOpacity&&(t*=this.parent.currentOpacity()),t},refreshOpacity:function(){var t,e=this.childNodes,i=e.length,n=this.currentOpacity();for(t=0;t<i;t++)e[t].refreshOpacity(n)},initClip:function(){if(N.fn.initClip.call(this),this.clip){var t=this.clip.srcElement.bbox(this.srcElement.currentTransform());t&&(this.css("width",t.width()+t.origin.x),this.css("height",t.height()+t.origin.y))}},clipBBox:function(t){return t.bbox(this.srcElement.currentTransform())},clearClip:function(){N.fn.clearClip.call(this)}}),U=O.extend({init:function(t,e){this.opacity=e,O.fn.init.call(this,t)},createElement:function(){this.element=i("stroke"),this.setOpacity()},optionsChange:function(t){0===t.field.indexOf("stroke")&&this.setStroke()},refreshOpacity:function(t){this.opacity=t,this.setStroke()},setStroke:function(){this.allAttr(this.mapStroke())},setOpacity:function(){this.setStroke()},mapStroke:function(){var t,e=this.srcElement.options.stroke,i=[];return e&&!S(e.color)&&0!==e.width?(i.push(["on","true"]),i.push(["color",e.color]),i.push(["weight",(e.width||1)+"px"]),this.mapOpacityTo(i,e.opacity),T(e.dashType)&&i.push(["dashstyle",e.dashType]),T(e.lineJoin)&&i.push(["joinstyle",e.lineJoin]),T(e.lineCap)&&(t=e.lineCap.toLowerCase(),"butt"===t&&(t="butt"===t?"flat":t),i.push(["endcap",t]))):i.push(["on","false"]),i}}),j=O.extend({init:function(t,e,i){this.opacity=i,O.fn.init.call(this,t)},createElement:function(){this.element=i("fill"),this.setFill()},optionsChange:function(t){s(t.field)&&this.setFill()},refreshOpacity:function(t){this.opacity=t,this.setOpacity()},setFill:function(){this.allAttr(this.mapFill())},setOpacity:function(){this.setFill()},attr:function(t,e){var i,n=this.element;if(n){for(i=t.split(".");i.length>1;)n=n[i.shift()];n[i[0]]=e}},mapFill:function(){var t=this.srcElement.fill(),e=[["on","false"]];return t&&(t.nodeType==z?e=this.mapGradient(t):S(t.color)||(e=this.mapFillColor(t))),e},mapFillColor:function(t){var e=[["on","true"],["color",t.color]];return this.mapOpacityTo(e,t.opacity),e},mapGradient:function(t){var e,i=this.srcElement.options,n=i.fallbackFill||t.fallbackFill&&t.fallbackFill();return e=t instanceof y.LinearGradient?this.mapLinearGradient(t):t instanceof y.RadialGradient&&t.supportVML?this.mapRadialGradient(t):n?this.mapFillColor(n):[["on","false"]]},mapLinearGradient:function(t){var e=t.start(),i=t.end(),n=C.deg(f(i.y-e.y,i.x-e.x)),o=[["on","true"],["type",z],["focus",0],["method","none"],["angle",270-n]];return this.addColors(o),o},mapRadialGradient:function(t){var e=this.srcElement.rawBBox(),i=t.center(),n=(i.x-e.origin.x)/e.width(),o=(i.y-e.origin.y)/e.height(),r=[["on","true"],["type","gradienttitle"],["focus","100%"],["focusposition",n+" "+o],["method","none"]];return this.addColors(r),r},addColors:function(t){var e,i,n=this.srcElement.options,o=D(this.opacity,1),r=[],s=n.fill.stops,l=n.baseColor,c=this.element.colors?"colors.value":"colors",h=a(l,s[0],o),u=a(l,s[s.length-1],o);for(i=0;i<s.length;i++)e=s[i],r.push(d.round(100*e.offset())+"% "+a(l,e,o));t.push([c,r.join(",")],["color",h],["color2",u])}}),G=O.extend({init:function(t,e){this.transform=e,O.fn.init.call(this,t)},createElement:function(){this.element=i("skew"),this.setTransform()},optionsChange:function(t){"transform"===t.field&&this.refresh(this.srcElement.currentTransform())},refresh:function(t){this.transform=t,this.setTransform()},transformOrigin:function(){return"-0.5,-0.5"},setTransform:function(){this.allAttr(this.mapTransform())},mapTransform:function(){var t=this.transform,e=[],i=b(t);return i?(i.round(L),e.push(["on","true"],["matrix",[i.a,i.c,i.b,i.d,0,0].join(",")],["offset",i.e+"px,"+i.f+"px"],["origin",this.transformOrigin()])):e.push(["on","false"]),e}}),W=N.extend({init:function(t,e,i){this.fill=this.createFillNode(t,e,i),this.stroke=new U(t,i),this.transform=this.createTransformNode(t,e),N.fn.init.call(this,t)},attachTo:function(t,e){this.fill.attachTo(this.element),this.stroke.attachTo(this.element),this.transform.attachTo(this.element),O.fn.attachTo.call(this,t,e)},createFillNode:function(t,e,i){return new j(t,e,i)},createTransformNode:function(t,e){return new G(t,e)},createElement:function(){this.element=i("shape"),this.setCoordsize(),this.setStyle()},optionsChange:function(t){s(t.field)?this.fill.optionsChange(t):0===t.field.indexOf("stroke")?this.stroke.optionsChange(t):"transform"===t.field?this.transform.optionsChange(t):"opacity"===t.field&&(this.fill.setOpacity(),this.stroke.setOpacity()),N.fn.optionsChange.call(this,t)},refreshTransform:function(t){this.transform.refresh(this.srcElement.currentTransform(t))},refreshOpacity:function(t){t*=D(this.srcElement.options.opacity,1),this.fill.refreshOpacity(t),this.stroke.refreshOpacity(t)},mapStyle:function(t,e){var i,n=N.fn.mapStyle.call(this);return t&&e||(t=e=I),n.push(["position","absolute"],["width",t+"px"],["height",e+"px"]),i=this.srcElement.options.cursor,i&&n.push(["cursor",i]),n},setCoordsize:function(){this.allAttr([["coordorigin","0 0"],["coordsize",B+" "+B]])}}),q=O.extend({createElement:function(){this.element=i("path"),this.setPathData()},geometryChange:function(){this.setPathData()},setPathData:function(){this.attr("v",this.renderData())},renderData:function(){return o(this.srcElement)}}),$=W.extend({init:function(t,e,i){this.pathData=this.createDataNode(t),W.fn.init.call(this,t,e,i)},attachTo:function(t,e){this.pathData.attachTo(this.element),W.fn.attachTo.call(this,t,e)},createDataNode:function(t){return new q(t)},geometryChange:function(){this.pathData.geometryChange(),W.fn.geometryChange.call(this)}}),Y=q.extend({renderData:function(){var t,e,i,n=this.srcElement.paths;if(n.length>0){for(t=[],e=0;e<n.length;e++)i=e<n.length-1,t.push(o(n[e],i));return t.join(" ")}}}),X=$.extend({createDataNode:function(t){return new Y(t)}}),Q=G.extend({transformOrigin:function(){var t=this.srcElement.geometry().bbox(),e=t.center(),i=-p(e.x)/p(t.width()),n=-p(e.y)/p(t.height());return i+","+n}}),K=W.extend({createElement:function(){this.element=i("oval"),this.setStyle()},createTransformNode:function(t,e){return new Q(t,e)},geometryChange:function(){W.fn.geometryChange.call(this),this.setStyle(),this.refreshTransform()},mapStyle:function(){var t=this.srcElement.geometry(),e=t.radius,i=t.center,n=p(2*e),o=W.fn.mapStyle.call(this,n,n);return o.push(["left",p(i.x-e)+"px"],["top",p(i.y-e)+"px"]),o}}),Z=q.extend({renderData:function(){return o(this.srcElement.toPath())}}),J=$.extend({createDataNode:function(t){return new Z(t)}}),tt=q.extend({createElement:function(){q.fn.createElement.call(this),this.attr("textpathok",!0)},renderData:function(){var t=this.srcElement.rect(),e=t.center();return"m "+n([new x.Point(t.topLeft().x,e.y)])+" l "+n([new x.Point(t.bottomRight().x,e.y)])}}),et=O.extend({createElement:function(){this.element=i("textpath"),this.attr("on",!0),this.attr("fitpath",!1),this.setStyle(),this.setString()},optionsChange:function(t){"content"===t.field?this.setString():this.setStyle(),O.fn.optionsChange.call(this,t)},mapStyle:function(){return[["font",this.srcElement.options.font]]},setString:function(){this.attr("string",this.srcElement.content())}}),it=$.extend({init:function(t,e,i){this.path=new et(t),$.fn.init.call(this,t,e,i)},createDataNode:function(t){return new tt(t)},attachTo:function(t,e){this.path.attachTo(this.element),$.fn.attachTo.call(this,t,e)},optionsChange:function(t){"font"!==t.field&&"content"!==t.field||(this.path.optionsChange(t),this.pathData.geometryChange(t)),$.fn.optionsChange.call(this,t)}}),nt=q.extend({renderData:function(){var t=this.srcElement.rect(),e=(new y.Path).moveTo(t.topLeft()).lineTo(t.topRight()).lineTo(t.bottomRight()).lineTo(t.bottomLeft()).close();return o(e)}}),ot=G.extend({init:function(t,e,i){this.opacity=i,G.fn.init.call(this,t,e)},createElement:function(){this.element=i("fill"),this.attr("type","frame"),this.attr("rotate",!0),this.setOpacity(),this.setSrc(),this.setTransform()},optionsChange:function(t){"src"===t.field&&this.setSrc(),G.fn.optionsChange.call(this,t)},geometryChange:function(){this.refresh()},refreshOpacity:function(t){this.opacity=t,this.setOpacity()},setOpacity:function(){var t=[];this.mapOpacityTo(t,this.srcElement.options.opacity),this.allAttr(t)},setSrc:function(){this.attr("src",this.srcElement.src())},mapTransform:function(){var t,e,i,n,o,r,s,a,l=this.srcElement,c=l.rawBBox(),h=c.center(),u=I/2,d=I,p=c.width()/d,m=c.height()/d,v=0,_=this.transform;return _?(i=b(_),n=g(i.a*i.a+i.b*i.b),o=g(i.c*i.c+i.d*i.d),p*=n,m*=o,r=A(f(i.b,i.d)),s=A(f(-i.c,i.a)),v=(r+s)/2,0!==v?(a=l.bbox().center(),t=(a.x-u)/d,e=(a.y-u)/d):(t=(h.x*n+i.e-u)/d,e=(h.y*o+i.f-u)/d)):(t=(h.x-u)/d,e=(h.y-u)/d),p=P(p,L),m=P(m,L),t=P(t,L),e=P(e,L),v=P(v,L),[["size",p+","+m],["position",t+","+e],["angle",v]]}}),rt=$.extend({createFillNode:function(t,e,i){return new ot(t,e,i)},createDataNode:function(t){return new nt(t)},optionsChange:function(t){"src"!==t.field&&"transform"!==t.field||this.fill.optionsChange(t),$.fn.optionsChange.call(this,t)},geometryChange:function(){this.fill.geometryChange(),$.fn.geometryChange.call(this)},refreshTransform:function(t){$.fn.refreshTransform.call(this,t),this.fill.refresh(this.srcElement.currentTransform(t))}}),st=q.extend({renderData:function(){var t=this.srcElement.geometry(),e=["m",n([t.topLeft()]),"l",n([t.topRight(),t.bottomRight(),t.bottomLeft()]),"x e"];return e.join(" ")}}),at=$.extend({createDataNode:function(t){return new st(t)}}),lt={Group:H,Text:it,Path:$,MultiPath:X,Circle:K,Arc:J,Image:rt,Rect:at};m.support.vml=function(){var t=m.support.browser;return t.msie&&t.version<9}(),h="inherit",m.support.browser.msie&&m.support.browser.version<8&&(h="rect(auto auto auto auto)"),m.support.vml&&y.SurfaceFactory.current.register("vml",R,30),v(y,{vml:{ArcDataNode:Z,ArcNode:J,CircleTransformNode:Q,CircleNode:K,FillNode:j,GroupNode:H,ImageNode:rt,ImageFillNode:ot,ImagePathDataNode:nt,MultiPathDataNode:Y,MultiPathNode:X,Node:O,PathDataNode:q,PathNode:$,RectDataNode:st,RectNode:at,RootNode:V,StrokeNode:U,Surface:R,TextNode:it,TextPathNode:et,TextPathDataNode:tt,TransformNode:G}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/html.min",["kendo.color.min","drawing/shapes.min","util/main.min","util/text-metrics.min"],t)}(function(){!function(t,e,i){"use strict";function n(t){return"number"==typeof t?{x:t,y:t}:Array.isArray(t)?{x:t[0],y:t[1]}:{x:t.x,y:t.y}}function o(i,o){function s(e){var i=new lt.Group,n=e.getBoundingClientRect();return I(i,[u.x,0,0,u.y,-n.left*u.x,-n.top*u.y]),mt._clipbox=!1,mt._matrix=ct.Matrix.unit(),mt._stackingContext={element:e,group:i},mt._avoidLinks=o.avoidLinks===!0?"a":o.avoidLinks,t(e).addClass("k-pdf-export"),et(e,i),t(e).removeClass("k-pdf-export"),i}function a(e){if(null!=e)return"string"==typeof e&&(e=kendo.template(e.replace(/^\s+|\s+$/g,""))),"function"==typeof e?function(i){var n=e(i);if(n)return"string"==typeof n&&(n=n.replace(/^\s+|\s+$/g,"")),t(n)[0]}:function(){return t(e).clone()[0]}}function l(e){var i,n,o,r,s=e.cloneNode(!1);if(1==e.nodeType){i=t(e),n=t(s),r=i.data();for(o in r)n.data(o,r[o]);if(/^canvas$/i.test(e.tagName))s.getContext("2d").drawImage(e,0,0);else if(/^input$/i.test(e.tagName))e.removeAttribute("name");else for(o=e.firstChild;o;o=o.nextSibling)s.appendChild(l(o))}return s}function c(i,n,o,r,s,c,h){function u(){function t(){f(S,function(){i({pages:S,container:A})})}var e,n;("-"!=o||s)&&g(T),e=_(),T.parentNode.insertBefore(e,T),e.appendChild(T),k?(n=S.length,S.forEach(function(e,i){var o=k({element:e,pageNum:i+1,totalPages:S.length});o&&(e.appendChild(o),p(o,function(){0===--n&&t()}))})):t()}function d(t){if(h.keepTogether&&t.is(h.keepTogether)&&t.height()<=s-P)return!0;var e=t[0].tagName;return!(/^h[1-6]$/i.test(e)&&t.height()>=s-P)&&(t.data("kendoChart")||/^(?:img|tr|thead|th|tfoot|iframe|svg|object|canvas|input|textarea|select|video|h[1-6])$/i.test(e))}function g(i){var n,r,a,l,c=x(i),h=e(b(c,"padding-bottom")),u=e(b(c,"border-bottom-width")),f=P;for(P+=h+u,n=!0,r=i.firstChild;r;r=r.nextSibling)if(1==r.nodeType){if(n=!1,a=t(r),a.is(o)){v(r);continue}if(!s){g(r);continue}if(!/^(?:static|relative)$/.test(b(x(r),"position")))continue;l=y(r),1==l?v(r):l&&d(a)?v(r):g(r)}else 3==r.nodeType&&s&&(w(r,n),n=!1);P=f}function m(t){var e=t.parentNode,i=e.firstChild;if(t===i)return!0;if(t===e.children[0]){if(7==i.nodeType||8==i.nodeType)return!0;if(3==i.nodeType)return!/\S/.test(i.data)}return!1}function v(e){var i,n,o,r,s,a,l;return 1==e.nodeType&&e!==T&&m(e)?v(e.parentNode):(i=t(e).closest("table"),n=i.find("colgroup:first"),h.repeatHeaders&&(o=i.find("thead:first"),r=t(e).closest('.k-grid[data-role="grid"]'),r[0]&&r[0].querySelector(".k-auto-scrollable")&&(s=r.find(".k-grid-header:first"))),a=_(),l=C.createRange(),l.setStartBefore(T),l.setEndBefore(e),a.appendChild(l.extractContents()),T.parentNode.insertBefore(a,T),i[0]&&(i=t(e).closest("table"),h.repeatHeaders&&o[0]&&o.clone().prependTo(i),n[0]&&n.clone().prependTo(i)),void(h.repeatHeaders&&s&&s[0]&&(r=t(e).closest('.k-grid[data-role="grid"]'),s[0]&&s.clone().prependTo(r))))}function _(){var e=C.createElement("KENDO-PDF-PAGE");return t(e).css({display:"block",boxSizing:"content-box",width:r||"auto",padding:c.top+"px "+c.right+"px "+c.bottom+"px "+c.left+"px",position:"relative",height:s||"auto",overflow:s||r?"hidden":"visible",clear:"both"}),h&&h.pageClassName&&(e.className=h.pageClassName),S.push(e),e}function y(t){var e,i,n=t.getBoundingClientRect();return 0===n.width||0===n.height?0:(e=T.getBoundingClientRect().top,i=s-P,n.height>i?3:n.top-e>i?1:n.bottom-e>i?2:0)}function w(t,e){var i,n,o,r,s;/\S/.test(t.data)&&(i=t.data.length,n=C.createRange(),n.selectNodeContents(t),o=y(n),o&&(r=t,1==o?v(e?t.parentNode:t):(!function a(e,i,o){return n.setEnd(t,i),e==i||i==o?i:y(n)?a(e,e+i>>1,i):a(i,i+o>>1,o)}(0,i>>1,i),!/\S/.test(""+n)&&e?v(t.parentNode):(r=t.splitText(n.endOffset),s=_(),n.setStartBefore(T),s.appendChild(n.extractContents()),T.parentNode.insertBefore(s,T))),w(r)))}var k=a(h.template),C=n.ownerDocument,S=[],T=h._destructive?n:l(n),A=C.createElement("KENDO-PDF-DOCUMENT"),P=0;t(T).find("tfoot").each(function(){this.parentNode.appendChild(this)}),t(T).find("ol").each(function(){t(this).children().each(function(t){this.setAttribute("kendo-split-index",t)})}),t(A).css({display:"block",position:"absolute",boxSizing:"content-box",left:"-10000px",top:"-10000px"}),r&&(t(A).css({width:r,paddingLeft:c.left,paddingRight:c.right}),t(T).css({overflow:"hidden"})),n.parentNode.insertBefore(A,n),A.appendChild(T),h.beforePageBreak?setTimeout(function(){h.beforePageBreak(A,u)},15):setTimeout(u,15)}var h,u;if(o||(o={}),h=t.Deferred(),i=t(i)[0],!i)return h.reject("No element to export");if("function"!=typeof window.getComputedStyle)throw Error("window.getComputedStyle is missing.  You are using an unsupported browser, or running in IE8 compatibility mode.  Drawing HTML is supported in Chrome, Firefox, Safari and IE9+.");return kendo.pdf&&kendo.pdf.defineFont(r(i.ownerDocument)),
u=n(o.scale||1),p(i,function(){var t,e=o&&o.forcePageBreak,n=o&&o.paperSize&&"auto"!=o.paperSize,r=kendo.pdf.getPaperOptions(function(t,e){return"paperSize"==t?n?o[t]:"A4":t in o?o[t]:e}),a=n&&r.paperSize[0],l=n&&r.paperSize[1],d=o.margin&&r.margin,f=!!d;e||l?(d||(d={left:0,top:0,right:0,bottom:0}),a&&(a/=u.x),l&&(l/=u.y),d.left/=u.x,d.right/=u.x,d.top/=u.y,d.bottom/=u.y,t=new lt.Group({pdf:{multiPage:!0,paperSize:n?r.paperSize:"auto",_ignoreMargin:f}}),c(function(e){if(o.progress){var i=!1,n=0;!function r(){if(n<e.pages.length){var a=s(e.pages[n]);t.append(a),o.progress({page:a,pageNum:++n,totalPages:e.pages.length,cancel:function(){i=!0}}),i?e.container.parentNode.removeChild(e.container):setTimeout(r)}else e.container.parentNode.removeChild(e.container),h.resolve(t)}()}else e.pages.forEach(function(e){t.append(s(e))}),e.container.parentNode.removeChild(e.container),h.resolve(t)},i,e,a?a-d.left-d.right:null,l?l-d.top-d.bottom:null,d,o)):h.resolve(s(i))}),h.promise()}function r(t){function e(t){if(t){var e=null;try{e=t.cssRules}catch(i){}e&&n(t,e)}}function i(t){var e,i=b(t.style,"src");return i?rt(i).reduce(function(t,e){var i=st(e);return i&&t.push(i),t},[]):(e=st(t.cssText),e?[e]:[])}function n(t,n){var r,s,a,l,c,h,u;for(r=0;r<n.length;++r)switch(s=n[r],s.type){case 3:e(s.styleSheet);break;case 5:a=s.style,l=rt(b(a,"font-family")),c=/^([56789]00|bold)$/i.test(b(a,"font-weight")),h="italic"==b(a,"font-style"),u=i(s),u.length>0&&o(t,l,c,h,u[0])}}function o(t,e,i,n,o){/^data:/i.test(o)||/^[^\/:]+:\/\//.test(o)||/^\//.test(o)||(o=(t.href+"").replace(/[^\/]*$/,"")+o),e.forEach(function(t){t=t.replace(/^(['"]?)(.*?)\1$/,"$2"),i&&(t+="|bold"),n&&(t+="|italic"),r[t]=o})}var r,s;for(null==t&&(t=document),r={},s=0;s<t.styleSheets.length;++s)e(t.styleSheets[s]);return r}function s(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function a(t){return t="_counter_"+t,mt[t]}function l(t){var e=[],i=mt;for(t="_counter_"+t;i;)s(i,t)&&e.push(i[t]),i=Object.getPrototypeOf(i);return e.reverse()}function c(t,e){var i=mt;for(t="_counter_"+t;i&&!s(i,t);)i=Object.getPrototypeOf(i);i||(i=mt._root),i[t]=(i[t]||0)+(null==e?1:e)}function h(t,e){t="_counter_"+t,mt[t]=null==e?0:e}function u(t,i,n){var o,r,s;for(o=0;o<t.length;)r=t[o++],s=e(t[o]),isNaN(s)?i(r,n):(i(r,s),++o)}function d(t,e){var i=kendo.parseColor(t);return i&&(i=i.toRGB(),e?i=i.toCssRgba():0===i.a&&(i=null)),i}function f(t,e){function i(){--n<=0&&e()}var n=0;t.forEach(function(t){var e,o,r=t.querySelectorAll("img");for(e=0;e<r.length;++e)o=r[e],o.complete||(n++,o.onload=o.onerror=i)}),n||i()}function p(t,e){function i(t){gt[t]||(gt[t]=!0,r.push(t))}function n(){--o<=0&&e()}var o,r=[];!function s(t){/^img$/i.test(t.tagName)&&i(t.src),ot(b(x(t),"background-image")).forEach(function(t){"url"==t.type&&i(t.url)}),t.children&&ht.call(t.children).forEach(s)}(t),o=r.length,0===o&&n(),r.forEach(function(t){var e=gt[t]=new Image;/^data:/i.test(t)||(e.crossOrigin="Anonymous"),e.src=t,e.complete?n():(e.onload=n,e.onerror=function(){gt[t]=null,n()})})}function g(t){var e,n="";do e=t%26,n=String.fromCharCode(97+e)+n,t=i.floor(t/26);while(t>0);return n}function m(t,e,i){var n,o;mt=Object.create(mt),mt[t.tagName.toLowerCase()]={element:t,style:e},n=b(e,"text-decoration"),n&&"none"!=n&&(o=b(e,"color"),n.split(/\s+/g).forEach(function(t){mt[t]||(mt[t]=o)})),w(e)&&(mt._stackingContext={element:t,group:i})}function v(){mt=Object.getPrototypeOf(mt)}function _(t){if(null!=mt._clipbox){var e=t.bbox(mt._matrix);mt._clipbox=mt._clipbox?ct.Rect.intersect(mt._clipbox,e):e}}function y(){var t=mt._clipbox;return null==t||(t?0===t.width()||0===t.height():void 0)}function w(t){function e(e){return b(t,e)}if("none"!=e("transform")||"static"!=e("position")&&"auto"!=e("z-index")||e("opacity")<1)return!0}function x(t,e){return window.getComputedStyle(t,e||null)}function b(t,e){var i=t.getPropertyValue(e);return null!=i&&""!==i||(ut.webkit?i=t.getPropertyValue("-webkit-"+e):ut.mozilla?i=t.getPropertyValue("-moz-"+e):ut.opera?i=t.getPropertyValue("-o-"+e):ut.msie&&(i=t.getPropertyValue("-ms-"+e))),i}function k(t,e,i,n){t.setProperty(e,i,n),ut.webkit?t.setProperty("-webkit-"+e,i,n):ut.mozilla?t.setProperty("-moz-"+e,i,n):ut.opera?t.setProperty("-o-"+e,i,n):ut.msie&&(t.setProperty("-ms-"+e,i,n),e="ms"+e.replace(/(^|-)([a-z])/g,function(t,e,i){return e+i.toUpperCase()}),t[e]=i)}function C(t,i){return i="border-"+i,{width:e(b(t,i+"-width")),style:b(t,i+"-style"),color:d(b(t,i+"-color"),!0)}}function S(t,e){var i=t.style.cssText,n=e();return t.style.cssText=i,n}function T(t,i){var n=b(t,"border-"+i+"-radius").split(/\s+/g).map(e);return 1==n.length&&n.push(n[0]),L({x:n[0],y:n[1]})}function A(t){var e=t.getBoundingClientRect();return e=P(e,"border-*-width",t),e=P(e,"padding-*",t)}function P(t,i,n){var o,r,s,a,l;return"string"==typeof i?(o=x(n),r=e(b(o,i.replace("*","top"))),s=e(b(o,i.replace("*","right"))),a=e(b(o,i.replace("*","bottom"))),l=e(b(o,i.replace("*","left")))):"number"==typeof i&&(r=s=a=l=i),{top:t.top+r,right:t.right-s,bottom:t.bottom-a,left:t.left+l,width:t.right-t.left-s-l,height:t.bottom-t.top-a-r}}function D(t){var i,n,o=b(t,"transform");return"none"==o?null:(i=/^\s*matrix\(\s*(.*?)\s*\)\s*$/.exec(o),i?(n=b(t,"transform-origin"),i=i[1].split(/\s*,\s*/g).map(e),n=n.split(/\s+/g).map(e),{matrix:i,origin:n}):void 0)}function M(t){return 180*t/i.PI%360}function E(t){var n=e(t);return/grad$/.test(t)?i.PI*n/200:/rad$/.test(t)?n:/turn$/.test(t)?i.PI*n*2:/deg$/.test(t)?i.PI*n/180:void 0}function I(t,e){return e=new ct.Matrix(e[0],e[1],e[2],e[3],e[4],e[5]),t.transform(e),e}function B(t,e){t.clip(e)}function z(t,e,i,n){for(var o=new ct.Arc([e,i],n).curvePoints(),r=1;r<o.length;)t.curveTo(o[r++],o[r++],o[r++])}function L(t){return(t.x<=0||t.y<=0)&&(t.x=t.y=0),t}function R(t,e,n,o,r){var s=i.max(0,e.x),a=i.max(0,e.y),l=i.max(0,n.x),c=i.max(0,n.y),h=i.max(0,o.x),u=i.max(0,o.y),d=i.max(0,r.x),f=i.max(0,r.y),p=i.min(t.width/(s+l),t.height/(c+u),t.width/(h+d),t.height/(f+a));return p<1&&(s*=p,a*=p,l*=p,c*=p,h*=p,u*=p,d*=p,f*=p),{tl:{x:s,y:a},tr:{x:l,y:c},br:{x:h,y:u},bl:{x:d,y:f}}}function O(t,i,n){var o,r,s,a,l,c,h,u,d=x(t),f=T(d,"top-left"),p=T(d,"top-right"),g=T(d,"bottom-left"),m=T(d,"bottom-right");return"padding"!=n&&"content"!=n||(o=C(d,"top"),r=C(d,"right"),s=C(d,"bottom"),a=C(d,"left"),f.x-=a.width,f.y-=o.width,p.x-=r.width,p.y-=o.width,m.x-=r.width,m.y-=s.width,g.x-=a.width,g.y-=s.width,"content"==n&&(l=e(b(d,"padding-top")),c=e(b(d,"padding-right")),h=e(b(d,"padding-bottom")),u=e(b(d,"padding-left")),f.x-=u,f.y-=l,p.x-=c,p.y-=l,m.x-=c,m.y-=h,g.x-=u,g.y-=h)),"number"==typeof n&&(f.x-=n,f.y-=n,p.x-=n,p.y-=n,m.x-=n,m.y-=n,g.x-=n,g.y-=n),V(i,f,p,m,g)}function V(t,e,i,n,o){var r=R(t,e,i,n,o),s=r.tl,a=r.tr,l=r.br,c=r.bl,h=new lt.Path({fill:null,stroke:null});return h.moveTo(t.left,t.top+s.y),s.x&&z(h,t.left+s.x,t.top+s.y,{startAngle:-180,endAngle:-90,radiusX:s.x,radiusY:s.y}),h.lineTo(t.right-a.x,t.top),a.x&&z(h,t.right-a.x,t.top+a.y,{startAngle:-90,endAngle:0,radiusX:a.x,radiusY:a.y}),h.lineTo(t.right,t.bottom-l.y),l.x&&z(h,t.right-l.x,t.bottom-l.y,{startAngle:0,endAngle:90,radiusX:l.x,radiusY:l.y}),h.lineTo(t.left+c.x,t.bottom),c.x&&z(h,t.left+c.x,t.bottom-c.y,{startAngle:90,endAngle:180,radiusX:c.x,radiusY:c.y}),h.close()}function F(t,i){var n=e(t)+"";switch(i){case"decimal-leading-zero":return n.length<2&&(n="0"+n),n;case"lower-roman":return dt(t).toLowerCase();case"upper-roman":return dt(t).toUpperCase();case"lower-latin":case"lower-alpha":return g(t-1);case"upper-latin":case"upper-alpha":return g(t-1).toUpperCase();default:return n}}function N(t,e){function i(t,e,i){return i?(i=i.replace(/^\s*(["'])(.*)\1\s*$/,"$2"),l(t).map(function(t){return F(t,e)}).join(i)):F(a(t)||0,e)}var n,o=rt(e,/^\s+/),r=[];return o.forEach(function(e){var o;(n=/^\s*(["'])(.*)\1\s*$/.exec(e))?r.push(n[2].replace(/\\([0-9a-f]{4})/gi,function(t,e){return String.fromCharCode(parseInt(e,16))})):(n=/^\s*counter\((.*?)\)\s*$/.exec(e))?(o=rt(n[1]),r.push(i(o[0],o[1]))):(n=/^\s*counters\((.*?)\)\s*$/.exec(e))?(o=rt(n[1]),r.push(i(o[0],o[2],o[1]))):r.push((n=/^\s*attr\((.*?)\)\s*$/.exec(e))?t.getAttribute(n[1])||"":e)}),r.join("")}function H(t){var e,i;if(t.cssText)return t.cssText;for(e=[],i=0;i<t.length;++i)e.push(t[i]+": "+b(t,t[i]));return e.join(";\n")}function U(t,e){function i(e,i){var o,r=x(t,e);r.content&&"normal"!=r.content&&"none"!=r.content&&"0px"!=r.width&&(o=t.ownerDocument.createElement(pt),o.style.cssText=H(r),o.textContent=N(t,r.content),t.insertBefore(o,i),n.push(o))}var n,o;return t.tagName==pt?void j(t,e):(n=[],i(":before",t.firstChild),i(":after",null),o=t.className,t.className+=" kendo-pdf-hide-pseudo-elements",j(t,e),t.className=o,void n.forEach(function(e){t.removeChild(e)}))}function j(n,o){function r(t){var e,i,o,r,s,a;if(/^td$/i.test(n.tagName)&&(e=mt.table,e&&"collapse"==b(e.style,"border-collapse"))){if(i=C(e.style,"left").width,o=C(e.style,"top").width,0===i&&0===o)return t;if(r=e.element.getBoundingClientRect(),s=e.element.rows[0].cells[0],a=s.getBoundingClientRect(),a.top==r.top||a.left==r.left)return ht.call(t).map(function(t){return{left:t.left+i,top:t.top+o,right:t.right+i,bottom:t.bottom+o,height:t.height,width:t.width}})}return t}function s(t,e,n,r,s,a,l,c){function h(e,o,r){var s=i.PI/2*e/(e+n),a={x:o.x-e,y:o.y-n},l=new lt.Path({fill:{color:t},stroke:null}).moveTo(0,0);I(l,r),z(l,0,o.y,{startAngle:-90,endAngle:-M(s),radiusX:o.x,radiusY:o.y}),a.x>0&&a.y>0?(l.lineTo(a.x*i.cos(s),o.y-a.y*i.sin(s)),z(l,0,o.y,{startAngle:-M(s),endAngle:-90,radiusX:a.x,radiusY:a.y,anticlockwise:!0})):a.x>0?l.lineTo(a.x,n).lineTo(0,n):l.lineTo(a.x,n).lineTo(a.x,0),d.append(l.close())}if(!(n<=0)){var u,d=new lt.Group;I(d,c),o.append(d),L(a),L(l),u=new lt.Path({fill:{color:t},stroke:null}),d.append(u),u.moveTo(a.x?i.max(a.x,r):0,0).lineTo(e-(l.x?i.max(l.x,s):0),0).lineTo(e-i.max(l.x,s),n).lineTo(i.max(a.x,r),n).close(),a.x&&h(r,a,[-1,0,0,1,a.x,0]),l.x&&h(s,l,[1,0,0,1,e-l.x,0])}}function a(e){var i,r,s=new lt.Group;for(B(s,V(e,j,q,X,$)),o.append(s),"A"==n.tagName&&n.href&&!/^#?$/.test(t(n).attr("href"))&&(mt._avoidLinks&&t(n).is(mt._avoidLinks)||(s._pdfLink={url:n.href,top:e.top,right:e.right,bottom:e.bottom,left:e.left})),K&&(i=new lt.Path({fill:{color:K.toCssRgba()},stroke:null}),i.moveTo(e.left,e.top).lineTo(e.right,e.top).lineTo(e.right,e.bottom).lineTo(e.left,e.bottom).close(),s.append(i)),r=u.length;--r>=0;)l(s,e,u[r],f[r%f.length],p[r%p.length],m[r%m.length],v[r%v.length])}function l(t,o,r,s,a,l,c){function h(t,o,r,h,u){function d(){for(;_.origin.x>o.left;)_.origin.x-=r}function f(){for(;_.origin.y>o.top;)_.origin.y-=h}function p(){for(;_.origin.x<o.right;)u(t,_.clone()),_.origin.x+=r}var g,m,v,_,y,w=r/h,x=o;if("content-box"==l?(x=P(x,"border-*-width",n),x=P(x,"padding-*",n)):"padding-box"==l&&(x=P(x,"border-*-width",n)),/^\s*auto(\s+auto)?\s*$/.test(c)||("contain"==c?(g=i.min(x.width/r,x.height/h),r*=g,h*=g):"cover"==c?(g=i.max(x.width/r,x.height/h),r*=g,h*=g):(m=c.split(/\s+/g),r=/%$/.test(m[0])?x.width*e(m[0])/100:e(m[0]),h=1==m.length||"auto"==m[1]?r/w:/%$/.test(m[1])?x.height*e(m[1])/100:e(m[1]))),v=(a+"").split(/\s+/),1==v.length&&(v[1]="50%"),v[0]=/%$/.test(v[0])?e(v[0])/100*(x.width-r):e(v[0]),v[1]=/%$/.test(v[1])?e(v[1])/100*(x.height-h):e(v[1]),_=new ct.Rect([x.left+v[0],x.top+v[1]],[r,h]),"no-repeat"==s)u(t,_);else if("repeat-x"==s)d(),p();else if("repeat-y"==s)for(f();_.origin.y<o.bottom;)u(t,_.clone()),_.origin.y+=h;else if("repeat"==s)for(d(),f(),y=_.origin.clone();_.origin.y<o.bottom;)_.origin.x=y.x,p(),_.origin.y+=h}if(r&&"none"!=r)if("url"==r.type){if(/^url\(\"data:image\/svg/i.test(r.url))return;var u=gt[r.url];u&&u.width>0&&u.height>0&&h(t,o,u.width,u.height,function(t,e){t.append(new lt.Image(r.url,e))})}else{if("linear"!=r.type)return;h(t,o,o.width,o.height,G(r))}}function c(){function t(t){S(n,function(){n.style.position="relative";var e=n.ownerDocument.createElement(pt);e.style.position="absolute",e.style.boxSizing="border-box","outside"==i?(e.style.width="6em",e.style.left="-6.8em",e.style.textAlign="right"):e.style.left="0px",t(e),n.insertBefore(e,n.firstChild),et(e,o),n.removeChild(e)})}function e(t){var e,i=n.parentNode.children,o=n.getAttribute("kendo-split-index");if(null!=o)return t(0|o,i.length);for(e=0;e<i.length;++e)if(i[e]===n)return t(e,i.length)}var i,r=b(E,"list-style-type");if("none"!=r)switch(i=b(E,"list-style-position"),r){case"circle":case"disc":case"square":t(function(t){t.style.fontSize="60%",t.style.lineHeight="200%",t.style.paddingRight="0.5em",t.style.fontFamily="DejaVu Serif",t.innerHTML={disc:"●",circle:"◯",square:"■"}[r]});break;case"decimal":case"decimal-leading-zero":t(function(t){e(function(e){++e,"decimal-leading-zero"==r&&(e+"").length<2&&(e="0"+e),t.innerHTML=e+"."})});break;case"lower-roman":case"upper-roman":t(function(t){e(function(e){e=dt(e+1),"upper-roman"==r&&(e=e.toUpperCase()),t.innerHTML=e+"."})});break;case"lower-latin":case"lower-alpha":case"upper-latin":case"upper-alpha":t(function(t){e(function(e){e=g(e),/^upper/i.test(r)&&(e=e.toUpperCase()),t.innerHTML=e+"."})})}}function h(t,e,i){function r(t){return{x:t.y,y:t.x}}var l,c,h,u,d,f,p,g;if(0!==t.width&&0!==t.height&&(a(t),l=U.width>0&&(e&&"ltr"==Q||i&&"rtl"==Q),c=N.width>0&&(i&&"ltr"==Q||e&&"rtl"==Q),0!==F.width||0!==U.width||0!==N.width||0!==H.width)){if(F.color==N.color&&F.color==H.color&&F.color==U.color&&F.width==N.width&&F.width==H.width&&F.width==U.width&&l&&c)return t=P(t,F.width/2),h=O(n,t,F.width/2),h.options.stroke={color:F.color,width:F.width},void o.append(h);if(0===j.x&&0===q.x&&0===X.x&&0===$.x&&F.width<2&&U.width<2&&N.width<2&&H.width<2)return F.width>0&&o.append(new lt.Path({stroke:{width:F.width,color:F.color}}).moveTo(t.left,t.top+F.width/2).lineTo(t.right,t.top+F.width/2)),H.width>0&&o.append(new lt.Path({stroke:{width:H.width,color:H.color}}).moveTo(t.left,t.bottom-H.width/2).lineTo(t.right,t.bottom-H.width/2)),l&&o.append(new lt.Path({stroke:{width:U.width,color:U.color}}).moveTo(t.left+U.width/2,t.top).lineTo(t.left+U.width/2,t.bottom)),void(c&&o.append(new lt.Path({stroke:{width:N.width,color:N.color}}).moveTo(t.right-N.width/2,t.top).lineTo(t.right-N.width/2,t.bottom)));u=R(t,j,q,X,$),d=u.tl,f=u.tr,p=u.br,g=u.bl,s(F.color,t.width,F.width,U.width,N.width,d,f,[1,0,0,1,t.left,t.top]),s(H.color,t.width,H.width,N.width,U.width,p,g,[-1,0,0,-1,t.right,t.bottom]),s(U.color,t.height,U.width,H.width,F.width,r(g),r(d),[0,-1,1,0,t.left,t.bottom]),s(N.color,t.height,N.width,F.width,H.width,r(f),r(p),[0,1,-1,0,t.right,t.top])}}var u,f,p,m,v,y,w,k,A,D,E=x(n),F=C(E,"top"),N=C(E,"right"),H=C(E,"bottom"),U=C(E,"left"),j=T(E,"top-left"),q=T(E,"top-right"),$=T(E,"bottom-left"),X=T(E,"bottom-right"),Q=b(E,"direction"),K=b(E,"background-color");if(K=d(K),u=ot(b(E,"background-image")),f=rt(b(E,"background-repeat")),p=rt(b(E,"background-position")),m=rt(b(E,"background-origin")),v=rt(b(E,"background-size")),ut.msie&&ut.version<10&&(p=rt(n.currentStyle.backgroundPosition)),y=P(n.getBoundingClientRect(),"border-*-width",n),function(){var t,i,n,r,s,a,l,c=b(E,"clip"),h=/^\s*rect\((.*)\)\s*$/.exec(c);h&&(t=h[1].split(/[ ,]+/g),i="auto"==t[0]?y.top:e(t[0])+y.top,n="auto"==t[1]?y.right:e(t[1])+y.left,r="auto"==t[2]?y.bottom:e(t[2])+y.top,s="auto"==t[3]?y.left:e(t[3])+y.left,a=new lt.Group,l=(new lt.Path).moveTo(s,i).lineTo(n,i).lineTo(n,r).lineTo(s,r).close(),B(a,l),o.append(a),o=a,_(l))}(),D=b(E,"display"),"table-row"==D)for(w=[],k=0,A=n.children;k<A.length;++k)w.push(A[k].getBoundingClientRect());else w=n.getClientRects(),1==w.length&&(w=[n.getBoundingClientRect()]);for(w=r(w),k=0;k<w.length;++k)h(w[k],0===k,k==w.length-1);return w.length>0&&"list-item"==D&&c(w[0]),function(){function t(){var t=O(n,y,"padding"),e=new lt.Group;B(e,t),o.append(e),o=e,_(t)}Y(n)?t():/^(hidden|auto|scroll)/.test(b(E,"overflow"))?t():/^(hidden|auto|scroll)/.test(b(E,"overflow-x"))?t():/^(hidden|auto|scroll)/.test(b(E,"overflow-y"))&&t()}(),W(n,o)||Z(n,o),o}function G(t){return function(n,o){var r,s,a,l,c,h,u,d,f,p,g,m,v,_=o.width(),y=o.height();switch(t.type){case"linear":switch(r=null!=t.angle?t.angle:i.PI,t.to){case"top":r=0;break;case"left":r=-i.PI/2;break;case"bottom":r=i.PI;break;case"right":r=i.PI/2;break;case"top left":case"left top":r=-i.atan2(y,_);break;case"top right":case"right top":r=i.atan2(y,_);break;case"bottom left":case"left bottom":r=i.PI+i.atan2(y,_);break;case"bottom right":case"right bottom":r=i.PI-i.atan2(y,_)}t.reverse&&(r-=i.PI),r%=2*i.PI,r<0&&(r+=2*i.PI),s=i.abs(_*i.sin(r))+i.abs(y*i.cos(r)),a=i.atan(_*i.tan(r)/y),l=i.sin(a),c=i.cos(a),h=i.abs(l)+i.abs(c),u=h/2*l,d=h/2*c,r>i.PI/2&&r<=3*i.PI/2&&(u=-u,d=-d),f=[],p=0,g=t.stops.map(function(i,n){var o,r=i.percent;return r?r=e(r)/100:i.length?r=e(i.length)/s:0===n?r=0:n==t.stops.length-1&&(r=1),o={color:i.color.toCssRgba(),offset:r},null!=r?(p=r,f.forEach(function(t,e){var i=t.stop;i.offset=t.left+(p-t.left)*(e+1)/(f.length+1)}),f=[]):f.push({left:p,stop:o}),o}),m=[.5-u,.5+d],v=[.5+u,.5-d],n.append(lt.Path.fromRect(o).stroke(null).fill(new lt.LinearGradient({start:m,end:v,stops:g,userSpace:!1})));break;case"radial":window.console&&window.console.log&&window.console.log("Radial gradients are not yet supported in HTML renderer")}}}function W(e,i){var n,o,r,s;if(e.getAttribute(kendo.attr("role"))&&(n=kendo.widgetInstance(t(e)),n&&(n.exportDOMVisual||n.exportVisual)))return!!(o=n.exportDOMVisual?n.exportDOMVisual():n.exportVisual())&&(r=new lt.Group,r.children.push(o),s=e.getBoundingClientRect(),r.transform(ct.transform().translate(s.left,s.top)),i.append(r),!0)}function q(t,e,i){var n=A(t),o=new ct.Rect([n.left,n.top],[n.width,n.height]),r=new lt.Image(e,o);B(r,O(t,n,"content")),i.append(r)}function $(t,i){var n=x(t),o=x(i),r=e(b(n,"z-index")),s=e(b(o,"z-index")),a=b(n,"position"),l=b(o,"position");return isNaN(r)&&isNaN(s)?/static|absolute/.test(a)&&/static|absolute/.test(l)?0:"static"==a?-1:"static"==l?1:0:isNaN(r)?0===s?0:s>0?-1:1:isNaN(s)?0===r?0:r>0?1:-1:e(r)-e(s)}function Y(t){return/^(?:textarea|select|input)$/i.test(t.tagName)}function X(t){return t.selectedOptions&&t.selectedOptions.length>0?t.selectedOptions[0]:t.options[t.selectedIndex]}function Q(t,e){var n=x(t),o=b(n,"color"),r=t.getBoundingClientRect();"checkbox"==t.type?(e.append(lt.Path.fromRect(new ct.Rect([r.left+1,r.top+1],[r.width-2,r.height-2])).stroke(o,1)),t.checked&&e.append((new lt.Path).stroke(o,1.2).moveTo(r.left+.22*r.width,r.top+.55*r.height).lineTo(r.left+.45*r.width,r.top+.75*r.height).lineTo(r.left+.78*r.width,r.top+.22*r.width))):(e.append(new lt.Circle(new ct.Circle([(r.left+r.right)/2,(r.top+r.bottom)/2],i.min(r.width-2,r.height-2)/2)).stroke(o,1)),t.checked&&e.append(new lt.Circle(new ct.Circle([(r.left+r.right)/2,(r.top+r.bottom)/2],i.min(r.width-8,r.height-8)/2)).fill(o).stroke(null)))}function K(t,e){var i,n,o,r,s,a=t.tagName.toLowerCase();if("input"==a&&("checkbox"==t.type||"radio"==t.type))return Q(t,e);if(i=t.parentNode,n=t.ownerDocument,o=n.createElement(pt),o.style.cssText=H(x(t)),"input"==a&&(o.style.whiteSpace="pre"),"select"!=a&&"textarea"!=a||(o.style.overflow="auto"),"select"==a)if(t.multiple)for(s=0;s<t.options.length;++s)r=n.createElement(pt),r.style.cssText=H(x(t.options[s])),r.style.display="block",r.textContent=t.options[s].textContent,o.appendChild(r);else r=X(t),r&&(o.textContent=r.textContent);else o.textContent=t.value;i.insertBefore(o,t),o.scrollLeft=t.scrollLeft,o.scrollTop=t.scrollTop,t.style.display="none",Z(o,e),t.style.display="",i.removeChild(o)}function Z(t,e){var i,n,o,r,s,a,l,c,h;switch(mt._stackingContext.element===t&&(mt._stackingContext.group=e),t.tagName.toLowerCase()){case"img":q(t,t.src,e);break;case"canvas":try{q(t,t.toDataURL("image/png"),e)}catch(u){}break;case"textarea":case"input":case"select":K(t,e);break;default:for(i=[],n=[],o=[],r=[],s=t.firstChild;s;s=s.nextSibling)switch(s.nodeType){case 3:/\S/.test(s.data)&&J(t,s,e);break;case 1:a=x(s),l=b(a,"display"),c=b(a,"float"),h=b(a,"position"),"static"!=h?r.push(s):"inline"!=l?"none"!=c?n.push(s):i.push(s):o.push(s)}ft(i,$).forEach(function(t){et(t,e)}),ft(n,$).forEach(function(t){et(t,e)}),ft(o,$).forEach(function(t){et(t,e)}),ft(r,$).forEach(function(t){et(t,e)})}}function J(t,n,o){function r(t){var e,n,o,r;if(ut.msie||ut.chrome){for(e=t.getClientRects(),n={top:+(1/0),right:-(1/0),bottom:-(1/0),left:+(1/0)},o=0;o<e.length;++o)r=e[o],r.width<=1||r.bottom===A||(n.left=i.min(r.left,n.left),n.top=i.min(r.top,n.top),n.right=i.max(r.right,n.right),n.bottom=i.max(r.bottom,n.bottom));return n.width=n.right-n.left,n.height=n.bottom-n.top,n}return t.getBoundingClientRect()}function s(){var t,e,o,s,l,c,f,p=u,g=h.substr(u).search(/\S/);if(u+=g,g<0||u>=d)return!0;if(v.setStart(n,u),v.setEnd(n,u+1),t=r(v),e=!1,w&&(g=h.substr(u).search(/\s/),g>=0&&(v.setEnd(n,u+g),o=r(v),o.bottom==t.bottom&&(t=o,e=!0,u+=g))),!e){if(g=function m(e,i,o){v.setEnd(n,i);var s=r(v);return s.bottom!=t.bottom&&e<i?m(e,e+i>>1,i):s.right!=t.right?(t=s,i<o?m(i,i+o>>1,o):i):i}(u,i.min(d,u+T),d),g==u)return!0;if(u=g,g=(""+v).search(/\s+$/),0===g)return;g>0&&(v.setEnd(n,v.startOffset+g),t=r(v))}if(ut.msie&&(t=v.getClientRects()[0]),s=""+v,/^(?:pre|pre-wrap)$/i.test(k)){if(/\t/.test(s)){for(l=0,g=p;g<v.startOffset;++g)c=h.charCodeAt(g),9==c?l+=8-l%8:10==c||13==c?l=0:l++;for(;(g=s.search("\t"))>=0;)f="        ".substr(0,8-(l+g)%8),s=s.substr(0,g)+f+s.substr(g+1)}}else s=s.replace(/\s+/g," ");e||(A=t.bottom),a(s,t)}function a(t,e){var i,n,r;ut.msie&&!isNaN(p)&&(i=at(g),n=(e.top+e.bottom-i)/2,e={top:n,right:e.right,bottom:n+i,left:e.left,height:i,width:e.right-e.left}),r=new nt(t,new ct.Rect([e.left,e.top],[e.width,e.height]),{font:g,fill:{color:m}}),o.append(r),l(e)}function l(t){function e(e,i){var n,r;e&&(n=f/12,r=new lt.Path({stroke:{width:n,color:e}}),i-=n,r.moveTo(t.left,i).lineTo(t.right,i),o.append(r))}e(mt.underline,t.bottom),e(mt["line-through"],t.bottom-t.height/2.7),e(mt.overline,t.top)}var c,h,u,d,f,p,g,m,v,_,w,k,C,S,T,A;if(!y()&&(c=x(t),!(e(b(c,"text-indent"))<-500)&&(h=n.data,u=0,d=h.search(/\S\s*$/)+1,d&&(f=b(c,"font-size"),p=b(c,"line-height"),g=[b(c,"font-style"),b(c,"font-variant"),b(c,"font-weight"),f,b(c,"font-family")].join(" "),f=e(f),p=e(p),0!==f)))){for(m=b(c,"color"),v=t.ownerDocument.createRange(),_=b(c,"text-align"),w="justify"==_,k=b(c,"white-space"),ut.msie&&(C=c.textOverflow,"ellipsis"==C&&(S=t.style.textOverflow,t.style.textOverflow="clip")),T=t.getBoundingClientRect().width/f*5,0===T&&(T=500),A=null;!s(););ut.msie&&"ellipsis"==C&&(t.style.textOverflow=S)}}function tt(t,i,n){var o,r,s,a,l,c;for("auto"!=n?(o=mt._stackingContext.group,n=e(n)):(o=i,n=0),r=o.children,s=0;s<r.length&&!(null!=r[s]._dom_zIndex&&r[s]._dom_zIndex>n);++s);return a=new lt.Group,o.insertAt(a,s),a._dom_zIndex=n,o!==i&&mt._clipbox&&(l=mt._matrix.invert(),c=mt._clipbox.transformCopy(l),B(a,lt.Path.fromRect(c))),a}function et(t,i){var n,o,r,s,a,l,d,f=x(t),p=b(f,"counter-reset");p&&u(rt(p,/^\s+/),h,0),n=b(f,"counter-increment"),n&&u(rt(n,/^\s+/),c,1),/^(style|script|link|meta|iframe|svg|col|colgroup)$/i.test(t.tagName)||null!=mt._clipbox&&(o=e(b(f,"opacity")),r=b(f,"visibility"),s=b(f,"display"),0!==o&&"hidden"!=r&&"none"!=s&&(a=D(f),d=b(f,"z-index"),(a||o<1)&&"auto"==d&&(d=0),l=tt(t,i,d),o<1&&l.opacity(o*l.opacity()),m(t,f,l),a?S(t,function(){var e,i,n,o;k(t.style,"transform","none","important"),k(t.style,"transition","none","important"),"static"==b(f,"position")&&k(t.style,"position","relative","important"),e=t.getBoundingClientRect(),i=e.left+a.origin[0],n=e.top+a.origin[1],o=[1,0,0,1,-i,-n],o=it(o,a.matrix),o=it(o,[1,0,0,1,i,n]),o=I(l,o),mt._matrix=mt._matrix.multiplyCopy(o),U(t,l)}):U(t,l),v()))}function it(t,e){var i=t[0],n=t[1],o=t[2],r=t[3],s=t[4],a=t[5],l=e[0],c=e[1],h=e[2],u=e[3],d=e[4],f=e[5];return[i*l+n*h,i*c+n*u,o*l+r*h,o*c+r*u,s*l+a*h+d,s*c+a*u+f]}var nt,ot,rt,st,at,lt=kendo.drawing,ct=kendo.geometry,ht=Array.prototype.slice,ut=kendo.support.browser,dt=kendo.util.arabicToRoman,ft=kendo.util.mergeSort,pt="KENDO-PSEUDO-ELEMENT",gt={},mt={};mt._root=mt,nt=lt.Text.extend({nodeType:"Text",init:function(t,e,i){lt.Text.fn.init.call(this,t,e.getOrigin(),i),this._pdfRect=e},rect:function(){return this._pdfRect},rawBBox:function(){return this._pdfRect}}),lt.drawDOM=o,o.getFontFaces=r,ot=function(){function t(t){function p(){var e=a.exec(t);e&&(t=t.substr(e[1].length))}function g(e){p();var i=e.exec(t);if(i)return t=t.substr(i[1].length),i[1]}function m(){var e,o,r=kendo.parseColor(t,!0);if(r)return t=t.substr(r.match[0].length),r=r.toRGB(),(e=g(n))||(o=g(i)),{color:r,length:e,percent:o}}function v(e){var n,s,a,u,d,f,p=[],v=!1;if(g(l)){for(n=g(r),n?(n=E(n),g(h)):(s=g(o),"to"==s?s=g(o):s&&/^-/.test(e)&&(v=!0),a=g(o),g(h)),/-moz-/.test(e)&&null==n&&null==s&&(u=g(i),d=g(i),v=!0,"0%"==u?s="left":"100%"==u&&(s="right"),"0%"==d?a="top":"100%"==d&&(a="bottom"),g(h));t&&!g(c)&&(f=m());)p.push(f),g(h);return{type:"linear",angle:n,to:s&&a?s+" "+a:s?s:a?a:null,stops:p,reverse:v}}}function _(){if(g(l)){var t=g(d);return t=t.replace(/^['"]+|["']+$/g,""),g(c),{type:"url",url:t}}}var y,w=t;return s(f,w)?f[w]:((y=g(e))?y=v(y):(y=g(u))&&(y=_()),f[w]=y||{type:"none"})}var e=/^((-webkit-|-moz-|-o-|-ms-)?linear-gradient\s*)\(/,i=/^([-0-9.]+%)/,n=/^([-0-9.]+px)/,o=/^(left|right|top|bottom|to|center)\W/,r=/^([-0-9.]+(deg|grad|rad|turn))/,a=/^(\s+)/,l=/^(\()/,c=/^(\))/,h=/^(,)/,u=/^(url)\(/,d=/^(.*?)\)/,f={},p={};return function(e){return s(p,e)?p[e]:p[e]=rt(e).map(t)}}(),rt=function(){var t={};return function(e,i){function n(t){return d=t.exec(e.substr(c))}function o(t){return t.replace(/^\s+|\s+$/g,"")}var r,a,l,c,h,u,d;if(i||(i=/^\s*,\s*/),r=e+i,s(t,r))return t[r];for(a=[],l=0,c=0,h=0,u=!1;c<e.length;)!u&&n(/^[\(\[\{]/)?(h++,c++):!u&&n(/^[\)\]\}]/)?(h--,c++):!u&&n(/^[\"\']/)?(u=d[0],c++):"'"==u&&n(/^\\\'/)?c+=2:'"'==u&&n(/^\\\"/)?c+=2:"'"==u&&n(/^\'/)?(u=!1,c++):'"'==u&&n(/^\"/)?(u=!1,c++):n(i)?(!u&&!h&&c>l&&(a.push(o(e.substring(l,c))),l=c+d[0].length),c+=d[0].length):c++;return l<c&&a.push(o(e.substring(l,c))),t[r]=a}}(),st=function(t){return function(e){var i,n=t[e];return n||((i=/url\((['"]?)([^'")]*?)\1\)\s+format\((['"]?)truetype\3\)/.exec(e))?n=t[e]=i[2]:(i=/url\((['"]?)([^'")]*?\.ttf)\1\)/.exec(e))&&(n=t[e]=i[2])),n}}(Object.create(null)),at=function(t){return function(e){var i=t[e];return null==i&&(i=t[e]=kendo.util.measureText("Mapq",{font:e}).height),i}}(Object.create(null))}(window.kendo.jQuery,parseFloat,Math)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("drawing/animation.min",["drawing/geometry.min","drawing/core.min"],t)}(function(){!function(t){var e=t.noop,i=window.kendo,n=i.Class,o=i.util,r=i.animationFrame,s=i.deepExtend,a=n.extend({init:function(t,e){var i=this;i.options=s({},i.options,e),i.element=t},options:{duration:500,easing:"swing"},setup:e,step:e,play:function(){var e=this,i=e.options,n=t.easing[i.easing],s=i.duration,a=i.delay||0,l=o.now()+a,c=l+s;0===s?(e.step(1),e.abort()):setTimeout(function(){var t=function(){var i,a,h,u;e._stopped||(i=o.now(),a=o.limitValue(i-l,0,s),h=a/s,u=n(h,a,0,1,s),e.step(u),i<c?r(t):e.abort())};t()},a)},abort:function(){this._stopped=!0},destroy:function(){this.abort()}}),l=function(){this._items=[]};l.prototype={register:function(t,e){this._items.push({name:t,type:e})},create:function(t,e){var i,n,o,r=this._items;if(e&&e.type)for(n=e.type.toLowerCase(),o=0;o<r.length;o++)if(r[o].name.toLowerCase()===n){i=r[o];break}if(i)return new i.type(t,e)}},l.current=new l,a.create=function(t,e,i){return l.current.create(t,e,i)},s(i.drawing,{Animation:a,AnimationFactory:l})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.drawing.min",["kendo.color.min","util/main.min","util/text-metrics.min","util/base64.min","mixins/observers.min","drawing/geometry.min","drawing/core.min","drawing/mixins.min","drawing/shapes.min","drawing/parser.min","drawing/search.min","drawing/svg.min","drawing/canvas.min","drawing/vml.min","drawing/html.min","drawing/animation.min"],t)}(function(){},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.core.min",["kendo.core.min","kendo.drawing.min"],t)}(function(){return function(t,e){function i(t,e){var i={top:0,right:0,bottom:0,left:0};return e=e||0,"number"==typeof t?i[Ft]=i[Vt]=i[ut]=i[Pt]=t:(i[Ft]=t[Ft]||e,i[Vt]=t[Vt]||e,i[ut]=t[ut]||e,i[Pt]=t[Pt]||e),i}function n(t,e){var i=t.tickX,n=t.tickY,o=t.position,r=new J.Path({stroke:{width:e.width,color:e.color}});return t.vertical?r.moveTo(i,o).lineTo(i+e.size,o):r.moveTo(o,n).lineTo(o,n+e.size),x(r),r}function o(t,e){var i=t.lineStart,n=t.lineEnd,o=t.position,r=new J.Path({stroke:{width:e.width,color:e.color,dashType:e.dashType}});return t.vertical?r.moveTo(i,o).lineTo(n,o):r.moveTo(o,i).lineTo(o,n),x(r),r}function r(t,e){var i,n,o,r=u(e-t,wt-1);if(0===r){if(0===e)return.1;r=at.abs(e)}return i=at.pow(10,at.floor(at.log(r)/at.log(10))),n=u(r/i,wt),o=1,o=n<1.904762?.2:n<4.761904?.5:n<9.523809?1:2,u(i*o,wt)}function s(t,e,i,n,o){var r=o*bt;return new qt(i+(t-i)*at.cos(r)+(e-n)*at.sin(r),n-(t-i)*at.sin(r)+(e-n)*at.cos(r))}function a(e,i){if(e.x1==i.x1&&e.y1==i.y1&&e.x2==i.x2&&e.y2==i.y2)return i;var n=at.min(e.x1,i.x1),o=at.max(e.x1,i.x1),r=at.min(e.x2,i.x2),s=at.max(e.x2,i.x2),a=at.min(e.y1,i.y1),l=at.max(e.y1,i.y1),c=at.min(e.y2,i.y2),h=at.max(e.y2,i.y2),u=[];return u[0]=T(o,a,r,l),u[1]=T(n,l,o,c),u[2]=T(r,l,s,c),u[3]=T(o,c,r,h),e.x1==n&&e.y1==a||i.x1==n&&i.y1==a?(u[4]=T(n,a,o,l),u[5]=T(r,c,s,h)):(u[4]=T(r,a,s,l),u[5]=T(n,c,o,h)),t.grep(u,function(t){return t.height()>0&&t.width()>0})[0]}function l(t,e){return ot(t,e)!=-1}function c(t,e){return u(at.ceil(t/e)*e,wt)}function h(t,e){return u(at.floor(t/e)*e,wt)}function u(t,e){var i=at.pow(10,e||0);return at.round(t*i)/i}function d(t,e){return at.log(t)/at.log(e)}function f(t,e,i){var n=u(at.abs(t%e),wt),o=e*(1-i);return 0===n||n>o}function p(t,e,i){return u(t+(e-t)*i,ft)}function g(t,e){return t-e}function m(t,e){return t.match(kt)?W.format.apply(this,arguments):W.toString(e,t)}function v(t,e){return-t.x*e.y+t.y*e.x<0}function _(t,e){return t&&e?t.getTime()-e.getTime():-1}function y(t){var e=t.originalEvent,i=0;return e.wheelDelta&&(i=-e.wheelDelta/120,i=i>0?at.ceil(i):at.floor(i)),e.detail&&(i=u(e.detail/3)),i}function w(t){if(!t||!t.indexOf||t.indexOf("&")<0)return t;var e=w._element;return e.innerHTML=t,e.textContent||e.innerText}function x(t){var e,i;if(!W.support.vml)for(e=.5,t.options.stroke&&Y(t.options.stroke.width)&&t.options.stroke.width%2===0&&(e=0),i=0;i<t.segments.length;i++)t.segments[i].anchor().round(0).translate(e,e);return t}function b(t){var e,i,n=t.stops,o=t.innerRadius/t.radius*100,r=n.length,s=[];for(e=0;e<r;e++)i=lt({},n[e]),i.offset=(i.offset*(100-o)+o)/100,s.push(i);return s}function k(t){var e=t.origin,i=t.bottomRight();return new T(e.x,e.y,i.x,i.y)}function C(e){e=e||{};var i=t(e.touch?e.touch.initialTouch:e.target);return i}function S(t){return at.max(at.min(t,St),-St)}var T,A,P,D,M,E,I,B,z,L,R,O,V,F,N,H,U,j,G,W=window.kendo,q=W.util,$=q.append,Y=q.defined,X=q.last,Q=q.valueOrDefault,K=W.dataviz,Z=K.geometry,J=K.drawing,tt=J.util.measureText,et=W.Class,it=W.template,nt=t.noop,ot=t.inArray,rt=t.isPlainObject,st=t.trim,at=Math,lt=W.deepExtend,ct="axisLabelClick",ht="#000",ut="bottom",dt="center",ft=3,pt="clip",gt="circle",mt="cross",vt="12px sans-serif",_t=400,yt=7,wt=10,xt=600,bt=at.PI/180,kt=/\{\d+:?/,Ct="height",St=W.support.vml?1e5:3e5,Tt=600,At="inside",Pt="left",Dt="linear",Mt=Number.MAX_VALUE,Et=-Number.MAX_VALUE,It=Math.pow(10,-wt+1),Bt="none",zt="noteClick",Lt="noteHover",Rt="outside",Ot="radial",Vt="right",Ft="top",Nt="triangle",Ht="width",Ut="#fff",jt="x",Gt="y",Wt=.2,qt=function(t,i){var n=this;return n instanceof qt?(n.x=t||0,n.y=i||0,e):new qt(t,i)};qt.fn=qt.prototype={clone:function(){var t=this;return new qt(t.x,t.y)},equals:function(t){return t&&t.x===this.x&&t.y===this.y},rotate:function(t,e){var i=this,n=e*bt,o=at.cos(n),r=at.sin(n),s=t.x,a=t.y,l=i.x,c=i.y;return i.x=u(s+(l-s)*o+(c-a)*r,ft),i.y=u(a+(c-a)*o-(l-s)*r,ft),
i},multiply:function(t){var e=this;return e.x*=t,e.y*=t,e},distanceTo:function(t){var e=this.x-t.x,i=this.y-t.y;return at.sqrt(e*e+i*i)}},qt.onCircle=function(t,e,i){return e*=bt,new qt(t.x-i*at.cos(e),t.y-i*at.sin(e))},T=function(t,i,n,o){var r=this;return r instanceof T?(r.x1=t||0,r.x2=n||0,r.y1=i||0,r.y2=o||0,e):new T(t,i,n,o)},T.fn=T.prototype={width:function(){return this.x2-this.x1},height:function(){return this.y2-this.y1},translate:function(t,e){var i=this;return i.x1+=t,i.x2+=t,i.y1+=e,i.y2+=e,i},move:function(t,e){var i=this,n=i.height(),o=i.width();return Y(t)&&(i.x1=t,i.x2=i.x1+o),Y(e)&&(i.y1=e,i.y2=i.y1+n),i},wrap:function(t){var e=this;return e.x1=at.min(e.x1,t.x1),e.y1=at.min(e.y1,t.y1),e.x2=at.max(e.x2,t.x2),e.y2=at.max(e.y2,t.y2),e},wrapPoint:function(t){return this.wrap(new T(t.x,t.y,t.x,t.y)),this},snapTo:function(t,e){var i=this;return e!=jt&&e||(i.x1=t.x1,i.x2=t.x2),e!=Gt&&e||(i.y1=t.y1,i.y2=t.y2),i},alignTo:function(t,e){var i,n,o=this,r=o.height(),s=o.width(),a=e==Ft||e==ut?Gt:jt,l=a==Gt?r:s;return e===dt?(i=t.center(),n=o.center(),o.x1+=i.x-n.x,o.y1+=i.y-n.y):o[a+1]=e===Ft||e===Pt?t[a+1]-l:t[a+2],o.x2=o.x1+s,o.y2=o.y1+r,o},shrink:function(t,e){var i=this;return i.x2-=t,i.y2-=e,i},expand:function(t,e){return this.shrink(-t,-e),this},pad:function(t){var e=this,n=i(t);return e.x1-=n.left,e.x2+=n.right,e.y1-=n.top,e.y2+=n.bottom,e},unpad:function(t){var e=this,n=i(t);return n.left=-n.left,n.top=-n.top,n.right=-n.right,n.bottom=-n.bottom,e.pad(n)},clone:function(){var t=this;return new T(t.x1,t.y1,t.x2,t.y2)},center:function(){var t=this;return new qt(t.x1+t.width()/2,t.y1+t.height()/2)},containsPoint:function(t){var e=this;return t.x>=e.x1&&t.x<=e.x2&&t.y>=e.y1&&t.y<=e.y2},points:function(){var t=this;return[new qt(t.x1,t.y1),new qt(t.x2,t.y1),new qt(t.x2,t.y2),new qt(t.x1,t.y2)]},getHash:function(){var t=this;return[t.x1,t.y1,t.x2,t.y2].join(",")},overlaps:function(t){return!(t.y2<this.y1||this.y2<t.y1||t.x2<this.x1||this.x2<t.x1)},rotate:function(t){var e=this,i=e.width(),n=e.height(),o=e.center(),r=o.x,a=o.y,l=s(0,0,r,a,t),c=s(i,0,r,a,t),h=s(i,n,r,a,t),u=s(0,n,r,a,t);return i=at.max(l.x,c.x,h.x,u.x)-at.min(l.x,c.x,h.x,u.x),n=at.max(l.y,c.y,h.y,u.y)-at.min(l.y,c.y,h.y,u.y),e.x2=e.x1+i,e.y2=e.y1+n,e},toRect:function(){return new Z.Rect([this.x1,this.y1],[this.width(),this.height()])},hasSize:function(){return 0!==this.width()&&0!==this.height()},align:function(t,e,i){var n=this,o=e+1,r=e+2,s=e===jt?Ht:Ct,a=n[s]();l(i,[Pt,Ft])?(n[o]=t[o],n[r]=n[o]+a):l(i,[Vt,ut])?(n[r]=t[r],n[o]=n[r]-a):i==dt&&(n[o]=t[o]+(t[s]()-a)/2,n[r]=n[o]+a)}},A=et.extend({init:function(t,e,i,n,o){var r=this;r.c=t,r.ir=e,r.r=i,r.startAngle=n,r.angle=o},clone:function(){var t=this;return new A(t.c,t.ir,t.r,t.startAngle,t.angle)},middle:function(){return this.startAngle+this.angle/2},radius:function(t,e){var i=this;return e?i.ir=t:i.r=t,i},point:function(t,e){var i=this,n=t*bt,o=at.cos(n),r=at.sin(n),s=e?i.ir:i.r,a=u(i.c.x-o*s,ft),l=u(i.c.y-r*s,ft);return new qt(a,l)},adjacentBox:function(t,e,i){var n=this.clone().expand(t),o=n.middle(),r=n.point(o),s=e/2,a=i/2,l=r.x-s,c=r.y-a,h=at.sin(o*bt),u=at.cos(o*bt);return at.abs(h)<.9&&(l+=s*-u/at.abs(u)),at.abs(u)<.9&&(c+=a*-h/at.abs(h)),new T(l,c,l+e,c+i)},containsPoint:function(t){var e=this,i=e.c,n=e.ir,o=e.r,r=e.startAngle,s=e.startAngle+e.angle,a=t.x-i.x,l=t.y-i.y,c=new qt(a,l),h=e.point(r),d=new qt(h.x-i.x,h.y-i.y),f=e.point(s),p=new qt(f.x-i.x,f.y-i.y),g=u(a*a+l*l,ft);return(d.equals(c)||v(d,c))&&!v(p,c)&&g>=n*n&&g<=o*o},getBBox:function(){var t,e,i,n=this,o=new T(Mt,Mt,Et,Et),r=u(n.startAngle%360),s=u((r+n.angle)%360),a=n.ir,l=[0,90,180,270,r,s].sort(g),c=ot(r,l),h=ot(s,l);for(t=r==s?l:c<h?l.slice(c,h+1):[].concat(l.slice(0,h+1),l.slice(c,l.length)),e=0;e<t.length;e++)i=n.point(t[e]),o.wrapPoint(i),o.wrapPoint(i,a);return a||o.wrapPoint(n.c),o},expand:function(t){return this.r+=t,this}}),P=A.extend({init:function(t,e,i,n){A.fn.init.call(this,t,0,e,i,n)},expand:function(t){return A.fn.expand.call(this,t)},clone:function(){var t=this;return new P(t.c,t.r,t.startAngle,t.angle)},radius:function(t){return A.fn.radius.call(this,t)},point:function(t){return A.fn.point.call(this,t)}}),D=function(){},D.fn=D.prototype={createRing:function(t,e){var i,n=t.startAngle+180,o=t.angle+n,r=new Z.Point(t.c.x,t.c.y),s=at.max(t.r,0),a=at.max(t.ir,0),l=new Z.Arc(r,{startAngle:n,endAngle:o,radiusX:s,radiusY:s}),c=J.Path.fromArc(l,e).close();return a?(l.radiusX=l.radiusY=a,i=l.pointAt(o),c.lineTo(i.x,i.y),c.arc(o,n,a,a,!0)):c.lineTo(r.x,r.y),c}},D.current=new D,M=et.extend({init:function(t){var e=this;e.children=[],e.options=lt({},e.options,t)},reflow:function(t){var e,i,n,o=this,r=o.children;for(i=0;i<r.length;i++)n=r[i],n.reflow(t),e=e?e.wrap(n.box):n.box.clone();o.box=e||t},destroy:function(){var t,e=this,i=e.children;for(this.animation&&this.animation.destroy(),t=0;t<i.length;t++)i[t].destroy()},getRoot:function(){var t=this.parent;return t?t.getRoot():null},getChart:function(){var t=this.getRoot();if(t)return t.chart},translateChildren:function(t,e){var i,n=this,o=n.children,r=o.length;for(i=0;i<r;i++)o[i].box.translate(t,e)},append:function(){$(this.children,arguments);for(var t=0;t<arguments.length;t++)arguments[t].parent=this},renderVisual:function(){this.options.visible!==!1&&(this.createVisual(),this.addVisual(),this.renderChildren(),this.createAnimation(),this.renderComplete())},addVisual:function(){this.visual&&(this.visual.chartElement=this,this.parent&&this.parent.appendVisual(this.visual))},renderChildren:function(){var t,e=this.children;for(t=0;t<e.length;t++)e[t].renderVisual()},createVisual:function(){this.visual=new K.drawing.Group({zIndex:this.options.zIndex,visible:Q(this.options.visible,!0)})},createAnimation:function(){this.visual&&(this.animation=J.Animation.create(this.visual,this.options.animation))},appendVisual:function(t){t.chartElement||(t.chartElement=this),t.options.noclip?this.clipRoot().visual.append(t):Y(t.options.zIndex)?this.stackRoot().stackVisual(t):this.visual?this.visual.append(t):this.parent.appendVisual(t)},clipRoot:function(){return this.parent?this.parent.clipRoot():this},stackRoot:function(){return this.parent?this.parent.stackRoot():this},stackVisual:function(t){var e,i,n,o=t.options.zIndex||0,r=this.visual.children;for(e=0;e<r.length&&(i=r[e],n=Q(i.options.zIndex,0),!(n>o));e++);this.visual.insertAt(t,e)},traverse:function(t){var e,i,n=this.children;for(e=0;e<n.length;e++)i=n[e],t(i),i.traverse&&i.traverse(t)},closest:function(t){for(var e=this,i=!1;e&&!i;)i=t(e),i||(e=e.parent);if(i)return e},renderComplete:t.noop,hasHighlight:function(){var t=(this.options||{}).highlight;return!(!this.createHighlight||t&&t.visible===!1)},toggleHighlight:function(e){var i,n=this,o=n._highlight,r=(n.options||{}).highlight,s=(r||{}).visual;if(!o){if(i={fill:{color:Ut,opacity:.2},stroke:{color:Ut,width:1,opacity:.2}},s){if(o=n._highlight=s(t.extend(n.highlightVisualArgs(),{createVisual:function(){return n.createHighlight(i)},sender:n.getChart(),series:n.series,dataItem:n.dataItem,category:n.category,value:n.value,stackValue:n.stackValue,percentage:n.percentage,runningTotal:n.runningTotal,total:n.total})),!o)return}else o=n._highlight=n.createHighlight(i);o.options.zIndex=n.options.zIndex,n.appendVisual(o)}o.visible(e)},createGradientOverlay:function(t,e,i){var n=new J.Path(lt({stroke:{color:Bt},fill:this.createGradient(i),closed:t.options.closed},e));return n.segments.elements(t.segments.elements()),n},createGradient:function(t){if(this.parent)return this.parent.createGradient(t)}}),E=M.extend({init:function(t){var e=this;e.gradients={},M.fn.init.call(e,t)},options:{width:xt,height:_t,background:Ut,border:{color:ht,width:0},margin:i(5),zIndex:-2},reflow:function(){var t,e=this,i=e.options,n=e.children,o=new T(0,0,i.width,i.height);for(e.box=o.unpad(i.margin),t=0;t<n.length;t++)n[t].reflow(o),o=a(o,n[t].box)||T()},createVisual:function(){this.visual=new J.Group,this.createBackground()},createBackground:function(){var t=this.options,e=t.border||{},i=this.box.clone().pad(t.margin).unpad(e.width),n=J.Path.fromRect(i.toRect(),{stroke:{color:e.width?e.color:"",width:e.width,dashType:e.dashType},fill:{color:t.background,opacity:t.opacity},zIndex:-10});this.visual.append(n)},getRoot:function(){return this},createGradient:function(t){var e,i,n=this.gradients,o=q.objectKey(t),r=K.Gradients[t.gradient];return n[o]?e=n[o]:(i=lt({},r,t),"linear"==r.type?e=new J.LinearGradient(i):(t.innerRadius&&(i.stops=b(i)),e=new J.RadialGradient(i),e.supportVML=r.supportVML!==!1),n[o]=e),e}}),I=M.extend({options:{align:Pt,vAlign:Ft,margin:{},padding:{},border:{color:ht,width:0},background:"",shrinkToFit:!1,width:0,height:0,visible:!0},reflow:function(t){function e(){a.align(t,jt,l.align),a.align(t,Gt,l.vAlign),a.paddingBox=n.clone().unpad(f).unpad(g)}var n,o,r,s,a=this,l=a.options,c=l.width,h=l.height,u=c&&h,d=l.shrinkToFit,f=i(l.margin),p=i(l.padding),g=l.border.width,m=a.children;for(o=t.clone(),u&&(o.x2=o.x1+c,o.y2=o.y1+h),d&&o.unpad(f).unpad(g).unpad(p),M.fn.reflow.call(a,o),n=u?a.box=T(0,0,c,h):a.box,d&&u?(e(),o=a.contentBox=a.paddingBox.clone().unpad(p)):(o=a.contentBox=n.clone(),n.pad(p).pad(g).pad(f),e()),a.translateChildren(n.x1-o.x1+f.left+g+p.left,n.y1-o.y1+f.top+g+p.top),r=0;r<m.length;r++)s=m[r],s.reflow(s.box)},align:function(t,e,i){this.box.align(t,e,i)},hasBox:function(){var t=this.options;return t.border.width||t.background},createVisual:function(){M.fn.createVisual.call(this);var t=this.options;t.visible&&this.hasBox()&&this.visual.append(J.Path.fromRect(this.paddingBox.toRect(),this.visualStyle()))},visualStyle:function(){var t=this,e=t.options,i=e.border||{};return{stroke:{width:i.width,color:i.color,opacity:Q(i.opacity,e.opacity),dashType:i.dashType},fill:{color:e.background,opacity:e.opacity},cursor:e.cursor}}}),B=M.extend({init:function(t,e){var i=this;M.fn.init.call(i,e),i.content=t,i.reflow(T())},options:{font:vt,color:ht,align:Pt,vAlign:""},reflow:function(t){var e,i=this,n=i.options;e=n.size=tt(i.content,{font:n.font}),i.baseline=e.baseline,i.box=T(t.x1,t.y1,t.x1+e.width,t.y1+e.height)},createVisual:function(){var t=this.options;this.visual=new J.Text(this.content,this.box.toRect().topLeft(),{font:t.font,fill:{color:t.color,opacity:t.opacity},cursor:t.cursor})}}),z=M.extend({init:function(t){M.fn.init.call(this,t),this._initDirection()},_initDirection:function(){var t=this.options;t.vertical?(this.groupAxis=jt,this.elementAxis=Gt,this.groupSizeField=Ht,this.elementSizeField=Ct,this.groupSpacing=t.spacing,this.elementSpacing=t.vSpacing):(this.groupAxis=Gt,this.elementAxis=jt,this.groupSizeField=Ct,this.elementSizeField=Ht,this.groupSpacing=t.vSpacing,this.elementSpacing=t.spacing)},options:{vertical:!0,wrap:!0,vSpacing:0,spacing:0},reflow:function(t){this.box=t.clone(),this.reflowChildren()},reflowChildren:function(){var t,e,i,n,o,r,s,a,l,c,h=this,u=h.box,d=h.elementAxis,f=h.groupAxis,p=h.elementSizeField,g=h.groupSizeField,m=h.groupOptions(),v=m.groups,_=v.length,y=u[f+1]+h.alignStart(m.groupsSize,u[g]()),w=y;if(_){for(s=0;s<_;s++){for(i=v[s],n=i.groupElements,o=n.length,t=u[d+1],r=0;r<o;r++)a=n[r],c=h.elementSize(a),e=w+h.alignStart(c[g],i.groupSize),l=T(),l[f+1]=e,l[f+2]=e+c[g],l[d+1]=t,l[d+2]=t+c[p],a.reflow(l),t+=c[p]+h.elementSpacing;w+=i.groupSize+h.groupSpacing}u[f+1]=y,u[f+2]=y+m.groupsSize,u[d+2]=u[d+1]+m.maxGroupElementsSize}},alignStart:function(t,e){var i=0,n=this.options.align;return n==Vt||n==ut?i=e-t:n==dt&&(i=(e-t)/2),i},groupOptions:function(){var t,e,i=this,n=i.box,o=i.children,r=o.length,s=this.elementSizeField,a=this.groupSizeField,l=this.elementSpacing,c=this.groupSpacing,h=u(n[s]()),d=0,f=0,p=0,g=0,m=[],v=[],_=0;for(d=0;d<r;d++)e=o[d],e.box||e.reflow(n),t=this.elementSize(e),i.options.wrap&&u(p+l+t[s])>h&&(m.push({groupElements:v,groupSize:f,groupElementsSize:p}),_=at.max(_,p),g+=c+f,f=0,p=0,v=[]),f=at.max(f,t[a]),p>0&&(p+=l),p+=t[s],v.push(e);return m.push({groupElements:v,groupSize:f,groupElementsSize:p}),_=at.max(_,p),g+=f,{groups:m,groupsSize:g,maxGroupElementsSize:_}},elementSize:function(t){return{width:t.box.width(),height:t.box.height()}},createVisual:nt}),L=I.extend({ROWS_SPLIT_REGEX:/\n|\\n/m,init:function(t,e){var i=this;i.content=t,I.fn.init.call(i,e),i._initContainer(),i.reflow(T())},_initContainer:function(){var t,e,i=this,n=i.options,o=(i.content+"").split(i.ROWS_SPLIT_REGEX),r=new z({vertical:!0,align:n.align,wrap:!1}),s=lt({},n,{opacity:1,animation:null});for(i.container=r,i.append(r),e=0;e<o.length;e++)t=new B(st(o[e]),s),r.append(t)},reflow:function(t){var e,n,o,r=this.options,s=r.visual;this.container.options.align=r.align,s&&!this._boxReflow?(t.hasSize()||(this._boxReflow=!0,this.reflow(t),this._boxReflow=!1,t=this.box),this.visual=s(this.visualContext(t)),e=t,this.visual&&(e=k(this.visual.clippedBBox()||new Z.Rect),this.visual.options.zIndex=r.zIndex,this.visual.options.noclip=r.noclip),this.box=this.contentBox=this.paddingBox=e):(I.fn.reflow.call(this,t),r.rotation&&(n=i(r.margin),o=this.box.unpad(n),this.targetBox=t,this.normalBox=o.clone(),o=this.rotate(),o.translate(n.left-n.right,n.top-n.bottom),this.rotatedBox=o.clone(),o.pad(n)))},createVisual:function(){var t,e=this.options;e.visible&&(this.visual=new K.drawing.Group({transform:this.rotationTransform(),zIndex:e.zIndex,noclip:e.noclip}),this.hasBox()&&(t=J.Path.fromRect(this.paddingBox.toRect(),this.visualStyle()),this.visual.append(t)))},renderVisual:function(){this.options.visual?(this.addVisual(),this.createAnimation()):I.fn.renderVisual.call(this)},visualOptions:function(){var t=this.options;return{background:t.background,border:t.border,color:t.color,font:t.font,margin:t.margin,padding:t.padding,visible:t.visible}},visualContext:function(t){var e=this;return{text:e.content,rect:t.toRect(),sender:this.getChart(),options:e.visualOptions(),createVisual:function(){return e._boxReflow=!0,e.reflow(t),e._boxReflow=!1,e.getDefaultVisual()}}},getDefaultVisual:function(){this.createVisual(),this.renderChildren();var t=this.visual;return delete this.visual,t},rotate:function(){var t=this.options;return this.box.rotate(t.rotation),this.align(this.targetBox,jt,t.align),this.align(this.targetBox,Gt,t.vAlign),this.box},rotationTransform:function(){var t,e,i,n,o=this.options.rotation;return o?(t=this.normalBox.center(),e=t.x,i=t.y,n=this.rotatedBox.center(),Z.transform().translate(n.x-e,n.y-i).rotate(o,[e,i])):null}}),R=M.extend({init:function(t){var e=this;M.fn.init.call(e,t),t=e.options,e.append(new L(t.text,lt({},t,{vAlign:t.position})))},options:{color:ht,position:Ft,align:dt,margin:i(5),padding:i(5)},reflow:function(t){var e=this;M.fn.reflow.call(e,t),e.box.snapTo(t,jt)}}),R.buildTitle=function(t,e,i){var n;return"string"==typeof t&&(t={text:t}),t=lt({visible:!0},i,t),t&&t.visible&&t.text&&(n=new R(t),e.append(n)),n},O=L.extend({init:function(t,e,i,n,o){var r=this;r.text=e,r.value=t,r.index=i,r.dataItem=n,L.fn.init.call(r,e,o)},visualContext:function(t){var e=L.fn.visualContext.call(this,t);return e.value=this.value,e.dataItem=this.dataItem,e.format=this.options.format,e.culture=this.options.culture,e},click:function(t,e){var i=this;t.trigger(ct,{element:C(e),value:i.value,text:i.text,index:i.index,dataItem:i.dataItem,axis:i.parent.options})},rotate:function(){var t,e;return this.options.alignRotation!=dt?(t=this.normalBox.toRect(),e=this.rotationTransform(),this.box=k(t.bbox(e.matrix()))):L.fn.rotate.call(this),this.box},rotationTransform:function(){var t,e,i,n,o,r,s,a,l,c,h,d,f,p,g,m,v,_,y=this.options,w=y.rotation;return w?y.alignRotation==dt?L.fn.rotationTransform.call(this):(t=Z.transform().rotate(w).matrix(),e=this.normalBox.toRect(),i=this.targetBox.toRect(),n=y.rotationOrigin||Ft,o=n==Ft||n==ut?jt:Gt,r=n==Ft||n==ut?Gt:jt,s=n==Ft||n==Pt?i.origin:i.bottomRight(),a=e.topLeft().transformCopy(t),l=e.topRight().transformCopy(t),c=e.bottomRight().transformCopy(t),h=e.bottomLeft().transformCopy(t),d=Z.Rect.fromPoints(a,l,c,h),f={},f[r]=i.origin[r]-d.origin[r],p=at.abs(a[r]+f[r]-s[r]),g=at.abs(l[r]+f[r]-s[r]),u(p,wt)===u(g,wt)?(m=a,v=l):g<p?(m=l,v=c):(m=a,v=h),_=m[o]+(v[o]-m[o])/2,f[o]=i.center()[o]-_,Z.transform().translate(f.x,f.y).rotate(w)):null}}),V=M.extend({init:function(t){var e=this;M.fn.init.call(e,t),e.options.visible||(e.options=lt({},e.options,{labels:{visible:!1},line:{visible:!1},margin:0,majorTickSize:0,minorTickSize:0})),e.options.minorTicks=lt({},{color:e.options.line.color,width:e.options.line.width,visible:e.options.minorTickType!=Bt},e.options.minorTicks,{size:e.options.minorTickSize,align:e.options.minorTickType}),e.options.majorTicks=lt({},{color:e.options.line.color,width:e.options.line.width,visible:e.options.majorTickType!=Bt},e.options.majorTicks,{size:e.options.majorTickSize,align:e.options.majorTickType}),this.options._deferLabels||e.createLabels(),e.createTitle(),e.createNotes()},options:{labels:{visible:!0,rotation:0,mirror:!1,step:1,skip:0},line:{width:1,color:ht,visible:!0},title:{visible:!0,position:dt},majorTicks:{align:Rt,size:4,skip:0,step:1},minorTicks:{align:Rt,size:3,skip:0,step:1},axisCrossingValue:0,majorTickType:Rt,minorTickType:Bt,majorGridLines:{skip:0,step:1},minorGridLines:{visible:!1,width:1,color:ht,skip:0,step:1},margin:5,visible:!0,reverse:!1,justified:!0,notes:{label:{text:""}},_alignLines:!0,_deferLabels:!1},labelsRange:function(){return{min:this.options.labels.skip,max:this.labelsCount()}},createLabels:function(){var e,i,n,o,r=this,s=r.options,a=s.vertical?Vt:dt,l=lt({},s.labels,{align:a,zIndex:s.zIndex}),c=at.max(1,l.step);if(r.children=t.grep(r.children,function(t){return!(t instanceof O)}),r.labels=[],l.visible)for(e=r.labelsRange(),i=l.rotation,rt(i)&&(l.alignRotation=i.align,l.rotation=i.angle),"auto"==l.rotation&&(l.rotation=0,s.autoRotateLabels=!0),o=e.min;o<e.max;o+=c)n=r.createAxisLabel(o,l),n&&(r.append(n),r.labels.push(n))},lineBox:function(){var t=this,e=t.options,i=t.box,n=e.vertical,o=e.labels.mirror,r=o?i.x1:i.x2,s=o?i.y2:i.y1,a=e.line.width||0;return n?T(r,i.y1,r,i.y2-a):T(i.x1,s,i.x2-a,s)},createTitle:function(){var t,e=this,i=e.options,n=lt({rotation:i.vertical?-90:0,text:"",zIndex:1,visualSize:!0},i.title);n.visible&&n.text&&(t=new L(n.text,n),e.append(t),e.title=t)},createNotes:function(){var t,e,i,n=this,o=n.options,r=o.notes,s=r.data||[];for(n.notes=[],t=0;t<s.length;t++)e=lt({},r,s[t]),e.value=n.parseNoteValue(e.value),i=new F(e.value,e.label.text,e,null,null,e),i.options.visible&&(Y(i.options.position)?o.vertical&&!l(i.options.position,[Pt,Vt])?i.options.position=o.reverse?Pt:Vt:o.vertical||l(i.options.position,[Ft,ut])||(i.options.position=o.reverse?ut:Ft):i.options.position=o.vertical?o.reverse?Pt:Vt:o.reverse?ut:Ft,n.append(i),n.notes.push(i))},parseNoteValue:function(t){return t},renderVisual:function(){M.fn.renderVisual.call(this),this.createPlotBands()},createVisual:function(){M.fn.createVisual.call(this),this.createBackground(),this.createLine()},gridLinesVisual:function(){var t=this._gridLines;return t||(t=this._gridLines=new J.Group({zIndex:-2}),this.appendVisual(this._gridLines)),t},createTicks:function(t){function e(e,i,o){var a,c=e.length,h=at.max(1,i.step);if(i.visible)for(a=i.skip;a<c;a+=h)Y(o)&&a%o===0||(l.tickX=s?r.x2:r.x2-i.size,l.tickY=s?r.y1-i.size:r.y1,l.position=e[a],t.append(n(l,i)))}var i=this,o=i.options,r=i.lineBox(),s=o.labels.mirror,a=o.majorTicks.visible?o.majorUnit:0,l={vertical:o.vertical};e(i.getMajorTickPositions(),o.majorTicks),e(i.getMinorTickPositions(),o.minorTicks,a/o.minorUnit)},createLine:function(){var t,e,i=this,n=i.options,o=n.line,r=i.lineBox();o.width>0&&o.visible&&(t=new J.Path({stroke:{width:o.width,color:o.color,dashType:o.dashType}}),t.moveTo(r.x1,r.y1).lineTo(r.x2,r.y2),n._alignLines&&x(t),e=this._lineGroup=new J.Group,e.append(t),this.visual.append(e),this.createTicks(e))},getActualTickSize:function(){var t=this,e=t.options,i=0;return e.majorTicks.visible&&e.minorTicks.visible?i=at.max(e.majorTicks.size,e.minorTicks.size):e.majorTicks.visible?i=e.majorTicks.size:e.minorTicks.visible&&(i=e.minorTicks.size),i},createBackground:function(){var t=this,e=t.options,i=e.background,n=t.box;i&&(t._backgroundPath=J.Path.fromRect(n.toRect(),{fill:{color:i},stroke:null}),this.visual.append(t._backgroundPath))},createPlotBands:function(){var e,i,n,o,r,s,a=this,l=a.options,c=l.plotBands||[],h=l.vertical,u=a.plotArea;0!==c.length&&(r=this._plotbandGroup=new J.Group({zIndex:-1}),s=t.grep(a.pane.axes,function(t){return t.options.vertical!==a.options.vertical})[0],t.each(c,function(t,l){var c,d;n=Q(l.from,Et),o=Q(l.to,Mt),h?(e=(s||u.axisX).lineBox(),i=a.getSlot(l.from,l.to,!0)):(e=a.getSlot(l.from,l.to,!0),i=(s||u.axisY).lineBox()),0!==e.width()&&0!==i.height()&&(c=new Z.Rect([e.x1,i.y1],[e.width(),i.height()]),d=J.Path.fromRect(c,{fill:{color:l.color,opacity:l.opacity},stroke:null}),r.append(d))}),a.appendVisual(r))},createGridLines:function(t){function e(t,e,n){var r,a=t.length,c=at.max(1,e.step);if(e.visible)for(r=e.skip;r<a;r+=c)i=u(t[r]),l(i,g)||r%n===0||s&&f===i||(p.position=i,m.append(o(p,e)),g.push(i))}var i,n=this,r=n.options,s=t.options.line.visible,a=r.majorGridLines,c=a.visible?r.majorUnit:0,h=r.vertical,d=t.lineBox(),f=d[h?"y1":"x1"],p={lineStart:d[h?"x1":"y1"],lineEnd:d[h?"x2":"y2"],vertical:h},g=[],m=this.gridLinesVisual();return e(n.getMajorTickPositions(),r.majorGridLines),e(n.getMinorTickPositions(),r.minorGridLines,c/r.minorUnit),m.children},reflow:function(t){var e,i,n=this,o=n.options,r=o.vertical,s=n.labels,a=s.length,l=n.title,c=r?Ht:Ct,h=l?l.box[c]():0,u=n.getActualTickSize()+o.margin+h,d=0,f=(this.getRoot()||{}).box||t,p=f[c]();for(i=0;i<a;i++)e=s[i].box[c](),e+u<=p&&(d=at.max(d,e));n.box=r?T(t.x1,t.y1,t.x1+d+u,t.y2):T(t.x1,t.y1,t.x2,t.y1+d+u),n.arrangeTitle(),n.arrangeLabels(),n.arrangeNotes()},getLabelsTickPositions:function(){return this.getMajorTickPositions()},labelTickIndex:function(t){return t.index},arrangeLabels:function(){var t,e,i,n,o,r,s,a,l,c,h,u=this,d=u.options,f=u.labels,p=!d.justified,g=d.vertical,m=u.lineBox(),v=d.labels.mirror,_=u.getLabelsTickPositions(),y=u.getActualTickSize()+d.margin;for(i=0;i<f.length;i++)n=f[i],o=u.labelTickIndex(n),r=g?n.box.height():n.box.width(),s=_[o]-r/2,g?(p&&(a=_[o],l=_[o+1],c=a+(l-a)/2,s=c-r/2),h=m.x2,v?(h+=y,n.options.rotationOrigin=Pt):(h-=y+n.box.width(),n.options.rotationOrigin=Vt),t=n.box.move(h,s)):(p?(a=_[o],l=_[o+1]):(a=s,l=s+r),e=m.y1,v?(e-=y+n.box.height(),n.options.rotationOrigin=ut):(e+=y,n.options.rotationOrigin=Ft),t=T(a,e,l,e+n.box.height())),n.reflow(t)},autoRotateLabels:function(){var t,e,i,n,o,r;if(this.options.autoRotateLabels&&!this.options.vertical){for(t=this.getMajorTickPositions(),e=this.labels,r=0;r<e.length;r++)if(o=t[r+1]-t[r],i=e[r].box,i.width()>o){if(i.height()>o){n=-90;break}n=-45}if(n){for(r=0;r<e.length;r++)e[r].options.rotation=n,e[r].reflow(T());return!0}}},arrangeTitle:function(){var t=this,e=t.options,i=e.labels.mirror,n=e.vertical,o=t.title;o&&(n?(o.options.align=i?Vt:Pt,o.options.vAlign=o.options.position):(o.options.align=o.options.position,o.options.vAlign=i?Ft:ut),o.reflow(t.box))},arrangeNotes:function(){var t,e,i,n,o=this;for(t=0;t<o.notes.length;t++)e=o.notes[t],n=e.options.value,Y(n)?(o.shouldRenderNote(n)?e.show():e.hide(),i=o.getSlot(n)):e.hide(),e.reflow(i||o.lineBox())},alignTo:function(t){var e=this,i=t.lineBox(),n=e.options.vertical,o=n?Gt:jt;e.box.snapTo(i,o),n?e.box.shrink(0,e.lineBox().height()-i.height()):e.box.shrink(e.lineBox().width()-i.width(),0),e.box[o+1]-=e.lineBox()[o+1]-i[o+1],e.box[o+2]-=e.lineBox()[o+2]-i[o+2]},axisLabelText:function(t,e,i){var n,o=t;return i.template?(n=it(i.template),o=n({value:t,dataItem:e,format:i.format,culture:i.culture})):i.format&&(o=i.format.match(kt)?W.format(i.format,t):W.toString(t,i.format,i.culture)),o},slot:function(t,e,i){var n=this.getSlot(t,e,i);if(n)return n.toRect()},contentBox:function(){var t=this.box.clone(),e=this.labels;return e.length&&(e[0].options.visible&&t.wrap(e[0].box),X(e).options.visible&&t.wrap(X(e).box)),t},limitRange:function(t,e,i,n,o){var r,s=this.options;if(!(t<i&&o<0&&(!Y(s.min)||s.min<=i)||n<e&&o>0&&(!Y(s.max)||n<=s.max)))return e<i&&o>0||n<t&&o<0?{min:t,max:e}:(r=e-t,t<i?(t=q.limitValue(t,i,n),e=q.limitValue(t+r,i+r,n)):e>n&&(e=q.limitValue(e,i,n),t=q.limitValue(e-r,i,n-r)),{min:t,max:e})},valueRange:function(){return{min:this.seriesMin,max:this.seriesMax}}}),F=I.extend({init:function(t,e,i,n,o,r){var s=this;I.fn.init.call(s,r),s.value=t,s.text=e,s.dataItem=i,s.category=n,s.series=o,s.render()},options:{icon:{visible:!0,type:gt},label:{position:At,visible:!0,align:dt,vAlign:dt},line:{visible:!0},visible:!0,position:Ft,zIndex:2},hide:function(){this.options.visible=!1},show:function(){this.options.visible=!0},render:function(){var t,e,i,n,o=this,r=o.options,s=r.label,a=o.text,l=r.icon,c=l.size,h=T();r.visible&&(Y(s)&&s.visible&&(s.template?(n=it(s.template),a=n({dataItem:o.dataItem,category:o.category,value:o.value,text:a,series:o.series})):s.format&&(a=m(s.format,a)),o.label=new L(a,lt({},s)),s.position!==At||Y(c)||(l.type===gt?c=at.max(o.label.box.width(),o.label.box.height()):(e=o.label.box.width(),i=o.label.box.height()),h.wrap(o.label.box))),l.width=e||c||yt,l.height=i||c||yt,t=new N(lt({},l)),o.marker=t,o.append(t),o.label&&o.append(o.label),t.reflow(T()),o.wrapperBox=h.wrap(t.box))},reflow:function(t){var e,i,n,o=this,r=o.options,s=t.center(),a=o.wrapperBox,c=r.line.length,h=r.position,u=o.label,d=o.marker;r.visible&&(l(h,[Pt,Vt])?h===Pt?(n=a.alignTo(t,h).translate(-c,t.center().y-a.center().y),r.line.visible&&(e=[t.x1,s.y],o.linePoints=[e,[n.x2,s.y]],i=n.clone().wrapPoint(e))):(n=a.alignTo(t,h).translate(c,t.center().y-a.center().y),r.line.visible&&(e=[t.x2,s.y],o.linePoints=[e,[n.x1,s.y]],i=n.clone().wrapPoint(e))):h===ut?(n=a.alignTo(t,h).translate(t.center().x-a.center().x,c),r.line.visible&&(e=[s.x,t.y2],o.linePoints=[e,[s.x,n.y1]],i=n.clone().wrapPoint(e))):(n=a.alignTo(t,h).translate(t.center().x-a.center().x,-c),r.line.visible&&(e=[s.x,t.y1],o.linePoints=[e,[s.x,n.y2]],i=n.clone().wrapPoint(e))),d&&d.reflow(n),u&&(u.reflow(n),d&&(r.label.position===Rt&&u.box.alignTo(d.box,h),u.reflow(u.box))),o.contentBox=n,o.targetBox=t,o.box=i||n)},createVisual:function(){I.fn.createVisual.call(this),this.visual.options.noclip=this.options.noclip,this.options.visible&&this.createLine()},renderVisual:function(){var t=this,e=t.options,i=e.visual;e.visible&&i?(t.visual=i({dataItem:t.dataItem,category:t.category,value:t.value,text:t.text,sender:t.getChart(),series:t.series,rect:t.targetBox.toRect(),options:{background:e.background,border:e.background,icon:e.icon,label:e.label,line:e.line,position:e.position,visible:e.visible},createVisual:function(){t.createVisual(),t.renderChildren();var e=t.visual;return delete t.visual,e}}),t.addVisual()):I.fn.renderVisual.call(t)},createLine:function(){var t,e=this.options.line;this.linePoints&&(t=J.Path.fromPoints(this.linePoints,{stroke:{color:e.color,width:e.width,dashType:e.dashType}}),x(t),this.visual.append(t))},click:function(t,e){var i=this.eventArgs(e);t.trigger(zt,i)||e.preventDefault()},hover:function(t,e){var i=this.eventArgs(e);t.trigger(Lt,i)||e.preventDefault()},leave:function(t){t._unsetActivePoint()},eventArgs:function(t){var e=this,i=e.options;return{element:C(t),text:Y(i.label)?i.label.text:"",dataItem:e.dataItem,series:e.series,value:e.value,category:e.category,visual:e.visual}}}),N=I.extend({init:function(t,e){this.pointData=e,I.fn.init.call(this,t)},options:{type:gt,align:dt,vAlign:dt},getElement:function(){var t,e,i=this,n=i.options,o=n.type,r=n.rotation,s=i.paddingBox,a=s.center(),l=s.width()/2;if(n.visible&&i.hasBox())return e=i.visualStyle(),o===gt?t=new J.Circle(new Z.Circle([u(s.x1+l,ft),u(s.y1+s.height()/2,ft)],l),e):o===Nt?t=J.Path.fromPoints([[s.x1+l,s.y1],[s.x1,s.y2],[s.x2,s.y2]],e).close():o===mt?(t=new J.MultiPath(e),t.moveTo(s.x1,s.y1).lineTo(s.x2,s.y2),t.moveTo(s.x1,s.y2).lineTo(s.x2,s.y1)):t=J.Path.fromRect(s.toRect(),e),r&&t.transform(Z.transform().rotate(-r,[a.x,a.y])),t.options.zIndex=this.options.zIndex,t},createElement:function(){var t,e=this,i=e.options.visual,n=e.pointData||{};return t=i?i({value:n.value,dataItem:n.dataItem,sender:e.getChart(),series:n.series,category:n.category,rect:e.paddingBox.toRect(),options:e.visualOptions(),createVisual:function(){return e.getElement()}}):e.getElement()},visualOptions:function(){var t=this.options;return{background:t.background,border:t.border,margin:t.margin,padding:t.padding,type:t.type,size:t.width,visible:t.visible}},createVisual:function(){this.visual=this.createElement()}}),H=V.extend({init:function(t,e,i){var n=this,o=n.initDefaults(t,e,i);this.seriesMin=t,this.seriesMax=e,V.fn.init.call(n,o)},startValue:function(){return 0},options:{type:"numeric",min:0,max:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:ht},labels:{format:"#.####################"},zIndex:1},initDefaults:function(t,e,i){var n,o=this,s=i.narrowRange,a=o.autoAxisMin(t,e,s),l=o.autoAxisMax(t,e,s),u=r(a,l),d={majorUnit:u};return i.roundToMajorUnit!==!1&&(a<0&&f(a,u,1/3)&&(a-=u),l>0&&f(l,u,1/3)&&(l+=u)),d.min=h(a,u),d.max=c(l,u),this.totalMin=Y(i.min)?at.min(d.min,i.min):d.min,this.totalMax=Y(i.max)?at.max(d.max,i.max):d.max,this.totalMajorUnit=u,i&&(n=Y(i.min)||Y(i.max),n&&i.min===i.max&&(i.min>0?i.min=0:i.max=1),i.majorUnit?(d.min=h(d.min,i.majorUnit),d.max=c(d.max,i.majorUnit)):n&&(i=lt(d,i),d.majorUnit=r(i.min,i.max))),d.minorUnit=(i.majorUnit||d.majorUnit)/5,lt(d,i)},range:function(){var t=this.options;return{min:t.min,max:t.max}},autoAxisMax:function(t,e,i){var n,o;if(!t&&!e)return 1;if(t<=0&&e<=0){if(e=t==e?0:e,o=at.abs((e-t)/e),i===!1||!i&&o>Wt)return 0;n=at.min(0,e-(t-e)/2)}else t=t==e?0:t,n=e;return n},autoAxisMin:function(t,e,i){var n,o;if(!t&&!e)return 0;if(t>=0&&e>=0){if(t=t==e?0:t,o=(e-t)/e,i===!1||!i&&o>Wt)return 0;n=at.max(0,t-(e-t)/2)}else e=t==e?0:e,n=t;return n},getDivisions:function(t){if(0===t)return 1;var e=this.options,i=e.max-e.min;return at.floor(u(i/t,ft))+1},getTickPositions:function(t,e){var i,n=this,o=n.options,r=o.vertical,s=o.reverse,a=n.lineBox(),l=r?a.height():a.width(),c=o.max-o.min,h=l/c,d=t*h,f=0,p=n.getDivisions(t),g=(r?-1:1)*(s?-1:1),m=1===g?1:2,v=a[(r?Gt:jt)+m],_=[];for(e&&(f=e/t),i=0;i<p;i++)i%f!==0&&_.push(u(v,ft)),v+=d*g;return _},getMajorTickPositions:function(){var t=this;return t.getTickPositions(t.options.majorUnit)},getMinorTickPositions:function(){var t=this;return t.getTickPositions(t.options.minorUnit)},getSlot:function(t,e,i){var n,o,r=this,s=r.options,a=s.reverse,l=s.vertical,c=l?Gt:jt,h=r.lineBox(),u=h[c+(a?2:1)],d=l?h.height():h.width(),f=a?-1:1,p=f*(d/(s.max-s.min)),g=new T(h.x1,h.y1,h.x1,h.y1);return Y(t)||(t=e||0),Y(e)||(e=t||0),i&&(t=at.max(at.min(t,s.max),s.min),e=at.max(at.min(e,s.max),s.min)),l?(n=s.max-at.max(t,e),o=s.max-at.min(t,e)):(n=at.min(t,e)-s.min,o=at.max(t,e)-s.min),g[c+1]=S(u+p*(a?o:n)),g[c+2]=S(u+p*(a?n:o)),g},getValue:function(t){var e,i=this,n=i.options,o=n.reverse,r=n.vertical,s=1*n.max,a=1*n.min,l=r?Gt:jt,c=i.lineBox(),h=c[l+(o?2:1)],d=r?c.height():c.width(),f=o?-1:1,p=f*(t[l]-h),g=(s-a)/d,m=p*g;return p<0||p>d?null:(e=r?s-m:a+m,u(e,wt))},translateRange:function(t){var e=this,i=e.options,n=e.lineBox(),o=i.vertical,r=i.reverse,s=o?n.height():n.width(),a=i.max-i.min,l=s/a,c=u(t/l,wt);return!o&&!r||o&&r||(c=-c),{min:i.min+c,max:i.max+c}},scaleRange:function(t){var e=this,i=e.options,n=-t*i.majorUnit;return{min:i.min-n,max:i.max+n}},labelsCount:function(){return this.getDivisions(this.options.majorUnit)},createAxisLabel:function(t,e){var i=this,n=i.options,o=u(n.min+t*n.majorUnit,wt),r=i.axisLabelText(o,null,e);return new O(o,r,t,null,e)},shouldRenderNote:function(t){var e=this.range();return e.min<=t&&t<=e.max},pan:function(t){var e=this.translateRange(t);return this.limitRange(e.min,e.max,this.totalMin,this.totalMax)},pointsRange:function(t,e){var i=this.getValue(t),n=this.getValue(e),o=at.min(i,n),r=at.max(i,n);if(this.isValidRange(o,r))return{min:o,max:r}},zoomRange:function(t){
var e=this.scaleRange(t),i=this.totalMax,n=this.totalMin,o=q.limitValue(e.min,n,i),r=q.limitValue(e.max,n,i);if(this.isValidRange(o,r))return{min:o,max:r}},isValidRange:function(t,e){return e-t>It}}),U=V.extend({init:function(t,e,i){this.options=this._initOptions(t,e,i),this.seriesMin=t,this.seriesMax=e,V.fn.init.call(this,i)},startValue:function(){return this.options.min},options:{type:"log",majorUnit:10,minorUnit:1,axisCrossingValue:1,vertical:!0,majorGridLines:{visible:!0,width:1,color:ht},zIndex:1},getSlot:function(t,e,i){var n,o,r=this,s=r.options,a=s.reverse,l=s.vertical,c=l?Gt:jt,h=r.lineBox(),u=h[c+(a?2:1)],f=l?h.height():h.width(),p=a?-1:1,g=s.majorUnit,m=r.logMin,v=r.logMax,_=p*(f/(v-m)),y=new T(h.x1,h.y1,h.x1,h.y1);if(Y(t)||(t=e||1),Y(e)||(e=t||1),!(t<=0||e<=0))return i&&(t=at.max(at.min(t,s.max),s.min),e=at.max(at.min(e,s.max),s.min)),t=d(t,g),e=d(e,g),l?(n=v-at.max(t,e),o=v-at.min(t,e)):(n=at.min(t,e)-m,o=at.max(t,e)-m),y[c+1]=S(u+_*(a?o:n)),y[c+2]=S(u+_*(a?n:o)),y},getValue:function(t){var e,i=this,n=i.options,o=n.reverse,r=n.vertical,s=i.lineBox(),a=n.majorUnit,l=i.logMin,c=i.logMax,h=r===o?1:-1,d=1===h?1:2,f=r?s.height():s.width(),p=(c-l)/f,g=r?Gt:jt,m=s[g+d],v=h*(t[g]-m),_=v*p;return v<0||v>f?null:(e=l+_,u(at.pow(a,e),wt))},range:function(){var t=this.options;return{min:t.min,max:t.max}},scaleRange:function(t){var e=this,i=e.options,n=i.majorUnit,o=-t;return{min:at.pow(n,e.logMin-o),max:at.pow(n,e.logMax+o)}},translateRange:function(t){var e=this,i=e.options,n=i.majorUnit,o=e.lineBox(),r=i.vertical,s=i.reverse,a=r?o.height():o.width(),l=a/(e.logMax-e.logMin),c=u(t/l,wt);return!r&&!s||r&&s||(c=-c),{min:at.pow(n,e.logMin+c),max:at.pow(n,e.logMax+c)}},labelsCount:function(){var t=this,e=at.floor(t.logMax),i=at.floor(e-t.logMin)+1;return i},getMajorTickPositions:function(){var t=this,e=[];return t.traverseMajorTicksPositions(function(t){e.push(t)},{step:1,skip:0}),e},createTicks:function(t){function e(e,i){h.tickX=a?s.x2:s.x2-i.size,h.tickY=a?s.y1-i.size:s.y1,h.position=e,t.append(n(h,i))}var i=this,o=[],r=i.options,s=i.lineBox(),a=r.labels.mirror,l=r.majorTicks,c=r.minorTicks,h={vertical:r.vertical};return l.visible&&i.traverseMajorTicksPositions(e,l),c.visible&&i.traverseMinorTicksPositions(e,c),o},createGridLines:function(t){function e(t,e){l(t,u)||(h.position=t,d.append(o(h,e)),u.push(t))}var i=this,n=i.options,r=n.majorGridLines,s=n.minorGridLines,a=n.vertical,c=t.lineBox(),h={lineStart:c[a?"x1":"y1"],lineEnd:c[a?"x2":"y2"],vertical:a},u=[],d=this.gridLinesVisual();return r.visible&&i.traverseMajorTicksPositions(e,r),s.visible&&i.traverseMinorTicksPositions(e,s),d.children},traverseMajorTicksPositions:function(t,e){var i,n,o=this,r=o._lineOptions(),s=r.lineStart,a=r.step,l=o.logMin,c=o.logMax;for(i=at.ceil(l)+e.skip;i<=c;i+=e.step)n=u(s+a*(i-l),wt),t(n,e)},traverseMinorTicksPositions:function(t,e){var i,n,o,r,s,a=this,l=a.options,c=a._lineOptions(),h=c.lineStart,f=c.step,p=l.majorUnit,g=a.logMin,m=a.logMax,v=at.floor(g),_=l.max,y=l.min,w=l.minorUnit;for(i=v;i<m;i++)for(r=a._minorIntervalOptions(i),s=e.skip;s<w&&(n=r.value+s*r.minorStep,!(n>_));s+=e.step)n>=y&&(o=u(h+f*(d(n,p)-g),wt),t(o,e))},createAxisLabel:function(t,e){var i=this,n=i.options,o=at.ceil(i.logMin+t),r=Math.pow(n.majorUnit,o),s=i.axisLabelText(r,null,e);return new O(r,s,t,null,e)},shouldRenderNote:function(t){var e=this.range();return e.min<=t&&t<=e.max},_throwNegativeValuesError:function(){throw Error("Non positive values cannot be used for a logarithmic axis")},_initOptions:function(t,e,i){var n=this,o=lt({},n.options,{min:t,max:e},i),r=o.min,s=o.max,a=o.majorUnit,l=this._autoMax(e,a),c=this._autoMin(t,e,o);return o.axisCrossingValue<=0&&n._throwNegativeValuesError(),Y(i.max)?i.max<=0&&n._throwNegativeValuesError():s=l,Y(i.min)?i.min<=0&&n._throwNegativeValuesError():r=c,this.totalMin=Y(i.min)?at.min(c,i.min):c,this.totalMax=Y(i.max)?at.max(l,i.max):l,n.logMin=u(d(r,a),wt),n.logMax=u(d(s,a),wt),o.max=s,o.min=r,o.minorUnit=i.minorUnit||u(a-1,wt),o},_autoMin:function(t,e,i){var n=t,o=i.majorUnit;return t<=0?n=e<=1?at.pow(o,-2):1:i.narrowRange||(n=at.pow(o,at.floor(d(t,o)))),n},_autoMax:function(t,e){var i,n=u(d(t,e),wt)%1;return i=t<=0?e:0!==n&&(n<.3||n>.9)?at.pow(e,d(t,e)+.2):at.pow(e,at.ceil(d(t,e)))},pan:function(t){var e=this.translateRange(t);return this.limitRange(e.min,e.max,this.totalMin,this.totalMax,-t)},pointsRange:function(t,e){var i=this.getValue(t),n=this.getValue(e),o=at.min(i,n),r=at.max(i,n);return{min:o,max:r}},zoomRange:function(t){var e=this.options,i=this.scaleRange(t),n=this.totalMax,o=this.totalMin,r=q.limitValue(i.min,o,n),s=q.limitValue(i.max,o,n),a=e.majorUnit,l=s>r&&e.min&&e.max&&u(d(e.max,a)-d(e.min,a),wt)<1,c=!(e.min===o&&e.max===n)&&u(d(s,a)-d(r,a),wt)>=1;if(l||c)return{min:r,max:s}},_minorIntervalOptions:function(t){var e=this.options.majorUnit,i=at.pow(e,t),n=at.pow(e,t+1),o=n-i,r=o/this.options.minorUnit;return{value:i,minorStep:r}},_lineOptions:function(){var t=this,e=t.options,i=e.reverse,n=e.vertical,o=n?Gt:jt,r=t.lineBox(),s=n===i?1:-1,a=1===s?1:2,l=n?r.height():r.width(),c=s*(l/(t.logMax-t.logMin)),h=r[o+a];return{step:c,lineStart:h,lineBox:r}}}),K.Gradients={glass:{type:Dt,rotation:0,stops:[{offset:0,color:Ut,opacity:0},{offset:.25,color:Ut,opacity:.3},{offset:1,color:Ut,opacity:0}]},sharpBevel:{type:Ot,stops:[{offset:0,color:Ut,opacity:.55},{offset:.65,color:Ut,opacity:0},{offset:.95,color:Ut,opacity:.25}]},roundedBevel:{type:Ot,stops:[{offset:.33,color:Ut,opacity:.06},{offset:.83,color:Ut,opacity:.2},{offset:.95,color:Ut,opacity:0}]},roundedGlass:{type:Ot,supportVML:!1,stops:[{offset:0,color:Ut,opacity:0},{offset:.5,color:Ut,opacity:.3},{offset:.99,color:Ut,opacity:0}]},sharpGlass:{type:Ot,supportVML:!1,stops:[{offset:0,color:Ut,opacity:.2},{offset:.15,color:Ut,opacity:.15},{offset:.17,color:Ut,opacity:.35},{offset:.85,color:Ut,opacity:.05},{offset:.87,color:Ut,opacity:.15},{offset:.99,color:Ut,opacity:0}]}},j={extend:function(t,e){if(!t.exportVisual)throw Error("Mixin target has no exportVisual method defined.");t.exportSVG=this.exportSVG,t.exportImage=this.exportImage,t.exportPDF=this.exportPDF,e||(t.svg=this.svg,t.imageDataURL=this.imageDataURL)},exportSVG:function(t){return J.exportSVG(this.exportVisual(),t)},exportImage:function(t){return J.exportImage(this.exportVisual(t),t)},exportPDF:function(t){return J.exportPDF(this.exportVisual(),t)},svg:function(){if(J.svg.Surface)return J.svg._exportGroup(this.exportVisual());throw Error("SVG Export failed. Unable to export instantiate kendo.drawing.svg.Surface")},imageDataURL:function(){var e,i,n;if(!W.support.canvas)return null;if(J.canvas.Surface)return e=t("<div />").css({display:"none",width:this.element.width(),height:this.element.height()}).appendTo(document.body),i=new J.canvas.Surface(e),i.draw(this.exportVisual()),n=i._rootElement.toDataURL(),i.destroy(),e.remove(),n;throw Error("Image Export failed. Unable to export instantiate kendo.drawing.canvas.Surface")}},G=function(t){this.closed=t},G.prototype=G.fn={WEIGHT:.333,EXTREMUM_ALLOWED_DEVIATION:.01,process:function(t){var e,i,n,o,r,s,a,l,c,h,u=this,d=u.closed,f=t.slice(0),p=f.length,g=[];if(p>2&&(u.removeDuplicates(0,f),p=f.length),p<2||2==p&&f[0].equals(f[1]))return g;for(e=f[0],i=f[1],n=f[2],g.push(new J.Segment(e));e.equals(f[p-1]);)d=!0,f.pop(),p--;if(2==p)return a=u.tangent(e,i,jt,Gt),X(g).controlOut(u.firstControlPoint(a,e,i,jt,Gt)),g.push(new J.Segment(i,u.secondControlPoint(a,e,i,jt,Gt))),g;for(d?(e=f[p-1],i=f[0],n=f[1],o=u.controlPoints(e,i,n),r=o[1],s=o[0]):(a=u.tangent(e,i,jt,Gt),r=u.firstControlPoint(a,e,i,jt,Gt)),l=r,c=0;c<=p-3;c++)u.removeDuplicates(c,f),p=f.length,c+3<=p&&(e=f[c],i=f[c+1],n=f[c+2],o=u.controlPoints(e,i,n),X(g).controlOut(l),l=o[1],h=o[0],g.push(new J.Segment(i,h)));return d?(e=f[p-2],i=f[p-1],n=f[0],o=u.controlPoints(e,i,n),X(g).controlOut(l),g.push(new J.Segment(i,o[0])),X(g).controlOut(o[1]),g.push(new J.Segment(n,s))):(a=u.tangent(i,n,jt,Gt),X(g).controlOut(l),g.push(new J.Segment(n,u.secondControlPoint(a,i,n,jt,Gt)))),g},removeDuplicates:function(t,e){for(;e[t+1]&&(e[t].equals(e[t+1])||e[t+1].equals(e[t+2]));)e.splice(t+1,1)},invertAxis:function(t,e,i){var n,o,r=this,s=!1;return t.x===e.x?s=!0:e.x===i.x?(e.y<i.y&&t.y<=e.y||i.y<e.y&&e.y<=t.y)&&(s=!0):(n=r.lineFunction(t,e),o=r.calculateFunction(n,i.x),t.y<=e.y&&i.y<=o||e.y<=t.y&&i.y>=o||(s=!0)),s},isLine:function(t,e,i){var n=this,o=n.lineFunction(t,e),r=n.calculateFunction(o,i.x);return t.x==e.x&&e.x==i.x||u(r,1)===u(i.y,1)},lineFunction:function(t,e){var i=(e.y-t.y)/(e.x-t.x),n=t.y-i*t.x;return[n,i]},controlPoints:function(t,e,i){var n,o,r,s,a,l,c=this,h=jt,u=Gt,d=!1,f=!1,p=c.EXTREMUM_ALLOWED_DEVIATION;return c.isLine(t,e,i)?n=c.tangent(t,e,jt,Gt):(o={x:c.isMonotonicByField(t,e,i,jt),y:c.isMonotonicByField(t,e,i,Gt)},o.x&&o.y?(n=c.tangent(t,i,jt,Gt),d=!0):(c.invertAxis(t,e,i)&&(h=Gt,u=jt),o[h]?n=0:(a=i[u]<t[u]&&t[u]<=e[u]||t[u]<i[u]&&e[u]<=t[u]?c.sign((i[u]-t[u])*(e[h]-t[h])):-c.sign((i[h]-t[h])*(e[u]-t[u])),n=p*a,f=!0))),s=c.secondControlPoint(n,t,e,h,u),f&&(l=h,h=u,u=l),r=c.firstControlPoint(n,e,i,h,u),d&&(c.restrictControlPoint(t,e,s,n),c.restrictControlPoint(e,i,r,n)),[s,r]},sign:function(t){return t<=0?-1:1},restrictControlPoint:function(t,e,i,n){t.y<e.y?e.y<i.y?(i.x=t.x+(e.y-t.y)/n,i.y=e.y):i.y<t.y&&(i.x=e.x-(e.y-t.y)/n,i.y=t.y):i.y<e.y?(i.x=t.x-(t.y-e.y)/n,i.y=e.y):t.y<i.y&&(i.x=e.x+(t.y-e.y)/n,i.y=t.y)},tangent:function(t,e,i,n){var o,r=e[i]-t[i],s=e[n]-t[n];return o=0===r?0:s/r},isMonotonicByField:function(t,e,i,n){return i[n]>e[n]&&e[n]>t[n]||i[n]<e[n]&&e[n]<t[n]},firstControlPoint:function(t,e,i,n,o){var r=this,s=e[n],a=i[n],l=(a-s)*r.WEIGHT;return r.point(s+l,e[o]+l*t,n,o)},secondControlPoint:function(t,e,i,n,o){var r=this,s=e[n],a=i[n],l=(a-s)*r.WEIGHT;return r.point(a-l,i[o]-l*t,n,o)},point:function(t,e,i,n){var o=new Z.Point;return o[i]=t,o[n]=e,o},calculateFunction:function(t,e){var i,n=0,o=t.length;for(i=0;i<o;i++)n+=Math.pow(e,i)*t[i];return n}},w._element=document.createElement("span"),lt(W.dataviz,{AXIS_LABEL_CLICK:ct,COORD_PRECISION:ft,DEFAULT_PRECISION:wt,DEFAULT_WIDTH:xt,DEFAULT_HEIGHT:_t,DEFAULT_FONT:vt,INITIAL_ANIMATION_DURATION:Tt,NOTE_CLICK:zt,NOTE_HOVER:Lt,CLIP:pt,Axis:V,AxisLabel:O,Box2D:T,BoxElement:I,ChartElement:M,CurveProcessor:G,ExportMixin:j,FloatElement:z,LogarithmicAxis:U,Note:F,NumericAxis:H,Point2D:qt,Ring:A,RootElement:E,Sector:P,ShapeBuilder:D,ShapeElement:N,Text:B,TextBox:L,Title:R,alignPathToPixel:x,autoFormat:m,autoMajorUnit:r,boxDiff:a,dateComparer:_,decodeEntities:w,eventTargetElement:C,getSpacing:i,inArray:l,interpolateValue:p,mwDelta:y,rectToBox:k,rotatePoint:s,round:u,ceil:c,floor:h})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.themes.min",["kendo.dataviz.core.min"],t)}(function(){return function(t){function e(e,i){return t.map(e,function(t,e){return[[t,i[e]]]})}var i=window.kendo,n=i.dataviz.ui,o=i.deepExtend,r=1.5,s=.4,a="#000",l="Arial,Helvetica,sans-serif",c="11px "+l,h="12px "+l,u="16px "+l,d="#fff",f={title:{font:u},legend:{labels:{font:h}},seriesDefaults:{visible:!0,labels:{font:c},donut:{margin:1},line:{width:2},vericalLine:{width:2},scatterLine:{width:1},area:{opacity:.4,markers:{visible:!1,size:6},highlight:{markers:{border:{color:"#fff",opacity:1,width:1}}},line:{opacity:1,width:0}},verticalArea:{opacity:.4,markers:{visible:!1,size:6},line:{opacity:1,width:0}},radarLine:{width:2,markers:{visible:!1}},radarArea:{opacity:.5,markers:{visible:!1,size:6},line:{opacity:1,width:0}},candlestick:{line:{width:1,color:a},border:{width:1,_brightness:.8},gap:1,spacing:.3,downColor:d,highlight:{line:{width:2},border:{width:2,opacity:1}}},ohlc:{line:{width:1},gap:1,spacing:.3,highlight:{line:{width:3,opacity:1}}},bubble:{opacity:.6,border:{width:0},labels:{background:"transparent"}},bar:{gap:r,spacing:s},column:{gap:r,spacing:s},rangeColumn:{gap:r,spacing:s},rangeBar:{gap:r,spacing:s},waterfall:{gap:.5,spacing:s,line:{width:1,color:a}},horizontalWaterfall:{gap:.5,spacing:s,line:{width:1,color:a}},bullet:{gap:r,spacing:s,target:{color:"#ff0000"}},verticalBullet:{gap:r,spacing:s,target:{color:"#ff0000"}},boxPlot:{outliersField:"",meanField:"",whiskers:{width:1,color:a},mean:{width:1,color:a},median:{width:1,color:a},border:{width:1,_brightness:.8},gap:1,spacing:.3,downColor:d,highlight:{whiskers:{width:2},border:{width:2,opacity:1}}},funnel:{labels:{color:"",background:""}},notes:{icon:{border:{width:1}},label:{padding:3,font:h},line:{length:10,width:1},visible:!0}},categoryAxis:{majorGridLines:{visible:!0}},axisDefaults:{labels:{font:h},title:{font:u,margin:5},crosshair:{tooltip:{font:h}},notes:{icon:{size:7,border:{width:1}},label:{padding:3,font:h},line:{length:10,width:1},visible:!0}},tooltip:{font:h},navigator:{pane:{height:90,margin:{top:10}}}},p={scale:{labels:{font:h}}},g={shapeDefaults:{hover:{opacity:.2},stroke:{width:0}},editable:{resize:{handles:{width:7,height:7}}},selectable:{stroke:{width:1,dashType:"dot"}},connectionDefaults:{stroke:{width:2},selection:{handles:{width:8,height:8}},editable:{tools:["edit","delete"]}}},m=n.themes,v=n.registerTheme=function(t,e){var i,n={};n.chart=o({},f,e.chart),n.gauge=o({},p,e.gauge),n.diagram=o({},g,e.diagram),n.treeMap=o({},e.treeMap),i=n.chart.seriesDefaults,i.verticalLine=o({},i.line),i.verticalArea=o({},i.area),i.verticalBoxPlot=o({},i.boxPlot),i.polarArea=o({},i.radarArea),i.polarLine=o({},i.radarLine),m[t]=n};v("black",{chart:{title:{color:d},legend:{labels:{color:d},inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}},seriesDefaults:{labels:{color:d},errorBars:{color:d},notes:{icon:{background:"#3b3b3b",border:{color:"#8e8e8e"}},label:{color:d},line:{color:"#8e8e8e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#3d3d3d"}},scatter:{markers:{background:"#3d3d3d"}},scatterLine:{markers:{background:"#3d3d3d"}},waterfall:{line:{color:"#8e8e8e"}},horizontalWaterfall:{line:{color:"#8e8e8e"}},candlestick:{downColor:"#555",line:{color:d},border:{_brightness:1.5,opacity:1},highlight:{border:{color:d,opacity:.2}}},ohlc:{line:{color:d}}},chartArea:{background:"#3d3d3d"},seriesColors:["#0081da","#3aafff","#99c900","#ffeb3d","#b20753","#ff4195"],axisDefaults:{line:{color:"#8e8e8e"},labels:{color:d},majorGridLines:{color:"#545454"},minorGridLines:{color:"#454545"},title:{color:d},crosshair:{color:"#8e8e8e"},notes:{icon:{background:"#3b3b3b",border:{color:"#8e8e8e"}},label:{color:d},line:{color:"#8e8e8e"}}}},gauge:{pointer:{color:"#0070e4"},scale:{rangePlaceholderColor:"#1d1d1d",labels:{color:d},minorTicks:{color:d},majorTicks:{color:d},line:{color:d}}},diagram:{shapeDefaults:{fill:{color:"#0066cc"},connectorDefaults:{fill:{color:d},stroke:{color:"#384049"},hover:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}},content:{color:d}},editable:{resize:{handles:{fill:{color:"#3d3d3d"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:d}}}},rotate:{thumb:{stroke:{color:d},fill:{color:d}}}},selectable:{stroke:{color:d}},connectionDefaults:{stroke:{color:d},content:{color:d},selection:{handles:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}}}},treeMap:{colors:[["#0081da","#314b5c"],["#3aafff","#3c5464"],["#99c900","#4f5931"],["#ffeb3d","#64603d"],["#b20753","#543241"],["#ff4195","#643e4f"]]}}),v("blueopal",{chart:{title:{color:"#293135"},legend:{labels:{color:"#293135"},inactiveItems:{labels:{color:"#27A5BA"},markers:{color:"#27A5BA"}}},seriesDefaults:{labels:{color:a,background:d,opacity:.5},errorBars:{color:"#293135"},candlestick:{downColor:"#c4d0d5",line:{color:"#9aabb2"}},waterfall:{line:{color:"#9aabb2"}},horizontalWaterfall:{line:{color:"#9aabb2"}},notes:{icon:{background:"transparent",border:{color:"#9aabb2"}},label:{color:"#293135"},line:{color:"#9aabb2"}}},seriesColors:["#0069a5","#0098ee","#7bd2f6","#ffb800","#ff8517","#e34a00"],axisDefaults:{line:{color:"#9aabb2"},labels:{color:"#293135"},majorGridLines:{color:"#c4d0d5"},minorGridLines:{color:"#edf1f2"},title:{color:"#293135"},crosshair:{color:"#9aabb2"},notes:{icon:{background:"transparent",border:{color:"#9aabb2"}},label:{color:"#293135"},line:{color:"#9aabb2"}}}},gauge:{pointer:{color:"#005c83"},scale:{rangePlaceholderColor:"#daecf4",labels:{color:"#293135"},minorTicks:{color:"#293135"},majorTicks:{color:"#293135"},line:{color:"#293135"}}},diagram:{shapeDefaults:{fill:{color:"#7ec6e3"},connectorDefaults:{fill:{color:"#003f59"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#003f59"}}},content:{color:"#293135"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#003f59"},hover:{fill:{color:"#003f59"},stroke:{color:"#003f59"}}}},rotate:{thumb:{stroke:{color:"#003f59"},fill:{color:"#003f59"}}}},selectable:{stroke:{color:"#003f59"}},connectionDefaults:{stroke:{color:"#003f59"},content:{color:"#293135"},selection:{handles:{fill:{color:"#3d3d3d"},stroke:{color:"#efefef"}}}}},treeMap:{colors:[["#0069a5","#bad7e7"],["#0098ee","#b9e0f5"],["#7bd2f6","#ceeaf6"],["#ffb800","#e6e3c4"],["#ff8517","#e4d8c8"],["#e34a00","#ddccc2"]]}}),v("highcontrast",{chart:{title:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#66465B"},markers:{color:"#66465B"}}},seriesDefaults:{labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#ffffff"}},label:{color:"#ffffff"},line:{color:"#ffffff"}},pie:{overlay:{gradient:"sharpGlass"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#2c232b"}},scatter:{markers:{background:"#2c232b"}},scatterLine:{markers:{background:"#2c232b"}},area:{opacity:.5},waterfall:{line:{color:"#ffffff"}},horizontalWaterfall:{line:{color:"#ffffff"}},candlestick:{downColor:"#664e62",line:{color:"#ffffff"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#ffffff",opacity:1}}},ohlc:{line:{color:"#ffffff"}}},chartArea:{background:"#2c232b"},seriesColors:["#a7008f","#ffb800","#3aafff","#99c900","#b20753","#ff4195"],axisDefaults:{line:{color:"#ffffff"},labels:{color:"#ffffff"},majorGridLines:{color:"#664e62"},minorGridLines:{color:"#4f394b"},title:{color:"#ffffff"},crosshair:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#ffffff"}},label:{color:"#ffffff"},line:{color:"#ffffff"}}}},gauge:{pointer:{color:"#a7008f"},scale:{rangePlaceholderColor:"#2c232b",labels:{color:"#ffffff"},minorTicks:{color:"#2c232b"},majorTicks:{color:"#664e62"},line:{color:"#ffffff"}}},diagram:{shapeDefaults:{fill:{color:"#a7018f"},connectorDefaults:{fill:{color:d},stroke:{color:"#2c232b"},hover:{fill:{color:"#2c232b"},stroke:{color:d}}},content:{color:d}},editable:{resize:{handles:{fill:{color:"#2c232b"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:d}}}},rotate:{thumb:{stroke:{color:d},fill:{color:d}}}},selectable:{stroke:{color:d}},connectionDefaults:{stroke:{color:d},content:{color:d},selection:{handles:{fill:{color:"#2c232b"},stroke:{color:d}}}}},treeMap:{colors:[["#a7008f","#451c3f"],["#ffb800","#564122"],["#3aafff","#2f3f55"],["#99c900","#424422"],["#b20753","#471d33"],["#ff4195","#562940"]]}}),v("default",{chart:{title:{color:"#8e8e8e"},legend:{labels:{color:"#232323"},inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}},seriesDefaults:{labels:{color:a,background:d,opacity:.5},errorBars:{color:"#232323"},candlestick:{downColor:"#dedede",line:{color:"#8d8d8d"}},waterfall:{line:{color:"#8e8e8e"}},horizontalWaterfall:{line:{color:"#8e8e8e"}},notes:{icon:{background:"transparent",border:{color:"#8e8e8e"}},label:{color:"#232323"},line:{color:"#8e8e8e"}}},seriesColors:["#ff6800","#a0a700","#ff8d00","#678900","#ffb53c","#396000"],axisDefaults:{line:{color:"#8e8e8e"},labels:{color:"#232323"},minorGridLines:{color:"#f0f0f0"},majorGridLines:{color:"#dfdfdf"},title:{color:"#232323"},crosshair:{color:"#8e8e8e"},notes:{icon:{background:"transparent",border:{color:"#8e8e8e"}},label:{color:"#232323"},line:{color:"#8e8e8e"}}}},gauge:{pointer:{color:"#ea7001"},scale:{rangePlaceholderColor:"#dedede",labels:{color:"#2e2e2e"},minorTicks:{color:"#2e2e2e"},majorTicks:{color:"#2e2e2e"},line:{color:"#2e2e2e"}}},diagram:{shapeDefaults:{fill:{color:"#e15613"},connectorDefaults:{fill:{color:"#282828"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#282828"}}},content:{color:"#2e2e2e"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#282828"},hover:{fill:{color:"#282828"},stroke:{color:"#282828"}}}},rotate:{thumb:{stroke:{color:"#282828"},fill:{color:"#282828"}}}},selectable:{stroke:{color:"#a7018f"}},connectionDefaults:{stroke:{color:"#282828"},content:{color:"#2e2e2e"},selection:{handles:{fill:{color:d},stroke:{color:"#282828"}}}}},treeMap:{colors:[["#ff6800","#edcfba"],["#a0a700","#dadcba"],["#ff8d00","#edd7ba"],["#678900","#cfd6ba"],["#ffb53c","#eddfc6"],["#396000","#c6ceba"]]}}),v("silver",{chart:{title:{color:"#4e5968"},legend:{labels:{color:"#4e5968"},inactiveItems:{labels:{color:"#B1BCC8"},markers:{color:"#B1BCC8"}}},seriesDefaults:{labels:{color:"#293135",background:"#eaeaec",opacity:.5},errorBars:{color:"#4e5968"},notes:{icon:{background:"transparent",border:{color:"#4e5968"}},label:{color:"#4e5968"},line:{color:"#4e5968"}},line:{markers:{background:"#eaeaec"}},scatter:{markers:{background:"#eaeaec"}},scatterLine:{markers:{background:"#eaeaec"}},pie:{connectors:{color:"#A6B1C0"}},donut:{connectors:{color:"#A6B1C0"}},waterfall:{line:{color:"#a6b1c0"}},horizontalWaterfall:{line:{color:"#a6b1c0"}},candlestick:{downColor:"#a6afbe"}},chartArea:{background:"#eaeaec"},seriesColors:["#007bc3","#76b800","#ffae00","#ef4c00","#a419b7","#430B62"],axisDefaults:{line:{color:"#a6b1c0"},labels:{color:"#4e5968"},majorGridLines:{color:"#dcdcdf"},minorGridLines:{color:"#eeeeef"},title:{color:"#4e5968"},crosshair:{color:"#a6b1c0"},notes:{icon:{background:"transparent",border:{color:"#4e5968"}},label:{color:"#4e5968"},line:{color:"#4e5968"}}}},gauge:{pointer:{color:"#0879c0"},scale:{rangePlaceholderColor:"#f3f3f4",labels:{color:"#515967"},minorTicks:{color:"#515967"},majorTicks:{color:"#515967"},line:{color:"#515967"}}},diagram:{shapeDefaults:{fill:{color:"#1c82c2"},connectorDefaults:{fill:{color:"#515967"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#282828"}}},content:{color:"#515967"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#515967"},hover:{fill:{color:"#515967"},stroke:{color:"#515967"}}}},rotate:{thumb:{stroke:{color:"#515967"},fill:{color:"#515967"}}}},selectable:{stroke:{color:"#515967"}},connectionDefaults:{stroke:{color:"#515967"},content:{color:"#515967"},selection:{handles:{fill:{color:d},stroke:{color:"#515967"}}}}},treeMap:{colors:[["#007bc3","#c2dbea"],["#76b800","#dae7c3"],["#ffae00","#f5e5c3"],["#ef4c00","#f2d2c3"],["#a419b7","#e3c7e8"],["#430b62","#d0c5d7"]]}}),v("metro",{chart:{title:{color:"#777777"},legend:{labels:{color:"#777777"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:a},errorBars:{color:"#777777"},notes:{icon:{background:"transparent",border:{color:"#777777"}},label:{color:"#777777"},line:{color:"#777777"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},waterfall:{line:{color:"#c7c7c7"}},horizontalWaterfall:{line:{color:"#c7c7c7"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#8ebc00","#309b46","#25a0da","#ff6900","#e61e26","#d8e404","#16aba9","#7e51a1","#313131","#ed1691"],axisDefaults:{line:{color:"#c7c7c7"},labels:{color:"#777777"},minorGridLines:{color:"#c7c7c7"},majorGridLines:{color:"#c7c7c7"},title:{color:"#777777"},crosshair:{color:"#c7c7c7"},notes:{icon:{background:"transparent",border:{color:"#777777"}},label:{color:"#777777"},line:{color:"#777777"}}}},gauge:{pointer:{color:"#8ebc00"},scale:{rangePlaceholderColor:"#e6e6e6",labels:{color:"#777"},minorTicks:{color:"#777"},majorTicks:{color:"#777"},line:{color:"#777"}}},diagram:{shapeDefaults:{fill:{color:"#8ebc00"},connectorDefaults:{fill:{color:a},stroke:{color:d},hover:{fill:{color:d},stroke:{color:a}}},content:{color:"#777"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#787878"},hover:{fill:{color:"#787878"},stroke:{color:"#787878"}}}},rotate:{thumb:{stroke:{color:"#787878"},fill:{color:"#787878"}}}},selectable:{stroke:{color:"#515967"}},connectionDefaults:{stroke:{color:"#787878"},content:{color:"#777"},selection:{handles:{fill:{color:d},stroke:{color:"#787878"}}}}},treeMap:{colors:[["#8ebc00","#e8f2cc"],["#309b46","#d6ebda"],["#25a0da","#d3ecf8"],["#ff6900","#ffe1cc"],["#e61e26","#fad2d4"],["#d8e404","#f7facd"],["#16aba9","#d0eeee"],["#7e51a1","#e5dcec"],["#313131","#d6d6d6"],["#ed1691","#fbd0e9"]]}}),v("metroblack",{chart:{title:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#797979"},markers:{color:"#797979"}}},seriesDefaults:{border:{_brightness:1},labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#cecece"}},label:{color:"#ffffff"},line:{color:"#cecece"}},line:{markers:{background:"#0e0e0e"}},bubble:{opacity:.6},scatter:{markers:{background:"#0e0e0e"}},scatterLine:{markers:{background:"#0e0e0e"}},candlestick:{downColor:"#828282",line:{color:"#ffffff"}},waterfall:{line:{color:"#cecece"}},horizontalWaterfall:{line:{color:"#cecece"}},overlay:{gradient:"none"}},chartArea:{background:"#0e0e0e"},seriesColors:["#00aba9","#309b46","#8ebc00","#ff6900","#e61e26","#d8e404","#25a0da","#7e51a1","#313131","#ed1691"],axisDefaults:{line:{color:"#cecece"},labels:{color:"#ffffff"},minorGridLines:{color:"#2d2d2d"},majorGridLines:{color:"#333333"},title:{color:"#ffffff"},crosshair:{color:"#cecece"},notes:{icon:{background:"transparent",border:{color:"#cecece"}},label:{color:"#ffffff"},line:{color:"#cecece"}}}},gauge:{pointer:{color:"#00aba9"},scale:{rangePlaceholderColor:"#2d2d2d",labels:{color:"#ffffff"},minorTicks:{color:"#333333"},majorTicks:{color:"#cecece"},line:{color:"#cecece"}}},diagram:{shapeDefaults:{fill:{color:"#00aba9"},connectorDefaults:{fill:{color:d},stroke:{color:"#0e0e0e"},hover:{fill:{color:"#0e0e0e"},stroke:{color:d}}},content:{color:d}},editable:{resize:{handles:{fill:{color:"#0e0e0e"},stroke:{color:"#787878"},hover:{fill:{color:"#787878"},stroke:{color:"#787878"}}}},rotate:{thumb:{stroke:{color:d},fill:{color:d}}}},selectable:{stroke:{color:"#787878"}},connectionDefaults:{stroke:{color:d},content:{color:d},selection:{handles:{fill:{color:"#0e0e0e"},stroke:{color:d}}}}},treeMap:{colors:[["#00aba9","#0b2d2d"],["#309b46","#152a19"],["#8ebc00","#28310b"],["#ff6900","#3e200b"],["#e61e26","#391113"],["#d8e404","#36390c"],["#25a0da","#132b37"],["#7e51a1","#241b2b"],["#313131","#151515"],["#ed1691","#3b1028"]]}}),v("moonlight",{chart:{title:{color:"#ffffff"},legend:{labels:{color:"#ffffff"},inactiveItems:{labels:{color:"#A1A7AB"},markers:{color:"#A1A7AB"}}},seriesDefaults:{labels:{color:"#ffffff"},errorBars:{color:"#ffffff"},notes:{icon:{background:"transparent",border:{color:"#8c909e"}},label:{color:"#ffffff"},line:{color:"#8c909e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#212a33"}},bubble:{opacity:.6},scatter:{markers:{background:"#212a33"}},scatterLine:{markers:{background:"#212a33"}},area:{opacity:.3},candlestick:{downColor:"#757d87",line:{color:"#ea9d06"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:d,opacity:.2}}},waterfall:{line:{color:"#8c909e"}},horizontalWaterfall:{line:{color:"#8c909e"}},ohlc:{line:{color:"#ea9d06"}}},chartArea:{background:"#212a33"},seriesColors:["#ffca08","#ff710f","#ed2e24","#ff9f03","#e13c02","#a00201"],axisDefaults:{line:{color:"#8c909e"},minorTicks:{color:"#8c909e"},majorTicks:{color:"#8c909e"},labels:{color:"#ffffff"},majorGridLines:{color:"#3e424d"},minorGridLines:{color:"#2f3640"},title:{color:"#ffffff"},crosshair:{color:"#8c909e"},notes:{icon:{background:"transparent",border:{color:"#8c909e"}},label:{color:"#ffffff"},line:{color:"#8c909e"}}}},gauge:{pointer:{color:"#f4af03"},scale:{rangePlaceholderColor:"#2f3640",labels:{color:d},minorTicks:{color:"#8c909e"},majorTicks:{color:"#8c909e"},line:{color:"#8c909e"}}},diagram:{shapeDefaults:{fill:{color:"#f3ae03"},connectorDefaults:{fill:{color:d},stroke:{color:"#414550"},hover:{fill:{color:"#414550"},stroke:{color:d}}},content:{color:d}},editable:{resize:{handles:{fill:{color:"#414550"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:d}}}},rotate:{thumb:{stroke:{color:d},fill:{color:d}}}},selectable:{stroke:{color:d}},connectionDefaults:{stroke:{color:d},content:{color:d},selection:{handles:{fill:{color:"#414550"},stroke:{color:d}}}}},treeMap:{colors:[["#ffca08","#4e4b2b"],["#ff710f","#4e392d"],["#ed2e24","#4b2c31"],["#ff9f03","#4e422a"],["#e13c02","#482e2a"],["#a00201","#3b232a"]]}}),v("uniform",{chart:{title:{color:"#686868"},legend:{labels:{color:"#686868"},inactiveItems:{labels:{color:"#B6B6B6"},markers:{color:"#B6B6B6"}}},seriesDefaults:{labels:{color:"#686868"},errorBars:{color:"#686868"},notes:{icon:{background:"transparent",border:{color:"#9e9e9e"}},label:{color:"#686868"},line:{color:"#9e9e9e"}},pie:{overlay:{gradient:"sharpBevel"}},donut:{overlay:{gradient:"sharpGlass"}},line:{markers:{background:"#ffffff"}},bubble:{opacity:.6},scatter:{markers:{background:"#ffffff"}},scatterLine:{markers:{background:"#ffffff"}},area:{opacity:.3},candlestick:{downColor:"#cccccc",line:{color:"#cccccc"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#cccccc",opacity:.2}}},waterfall:{line:{color:"#9e9e9e"}},horizontalWaterfall:{line:{color:"#9e9e9e"}},ohlc:{line:{color:"#cccccc"}}},chartArea:{background:"#ffffff"},seriesColors:["#527aa3","#6f91b3","#8ca7c2","#a8bdd1","#c5d3e0","#e2e9f0"],axisDefaults:{line:{color:"#9e9e9e"},minorTicks:{color:"#aaaaaa"},majorTicks:{color:"#888888"},labels:{color:"#686868"},majorGridLines:{color:"#dadada"},minorGridLines:{color:"#e7e7e7"},title:{color:"#686868"},crosshair:{color:"#9e9e9e"},notes:{icon:{background:"transparent",border:{color:"#9e9e9e"}},label:{color:"#686868"},line:{color:"#9e9e9e"}}}},gauge:{pointer:{color:"#527aa3"},scale:{rangePlaceholderColor:"#e7e7e7",labels:{color:"#686868"},minorTicks:{color:"#aaaaaa"},majorTicks:{color:"#888888"},line:{color:"#9e9e9e"}}},diagram:{shapeDefaults:{fill:{color:"#d1d1d1"},connectorDefaults:{fill:{color:"#686868"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#686868"}}},content:{color:"#686868"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#686868"},hover:{fill:{color:"#686868"},stroke:{color:"#686868"}}}},rotate:{thumb:{stroke:{color:"#686868"},fill:{color:"#686868"}}}},selectable:{stroke:{color:"#686868"}},connectionDefaults:{stroke:{color:"#686868"},content:{color:"#686868"},selection:{handles:{fill:{color:d},stroke:{color:"#686868"}}}}},treeMap:{colors:[["#527aa3","#d0d8e1"],["#6f91b3","#d6dde4"],["#8ca7c2","#dce1e7"],["#a8bdd1","#e2e6ea"],["#c5d3e0","#e7eaed"],["#e2e9f0","#edeff0"]]}}),v("bootstrap",{chart:{title:{color:"#333333"},legend:{labels:{color:"#333333"},inactiveItems:{labels:{color:"#999999"},markers:{color:"#9A9A9A"}}},seriesDefaults:{labels:{color:"#333333"},overlay:{gradient:"none"},errorBars:{color:"#343434"},notes:{icon:{background:"#000000",border:{color:"#000000"}},label:{color:"#333333"},line:{color:"#000000"}},pie:{overlay:{gradient:"none"}},donut:{overlay:{gradient:"none"}},line:{markers:{background:"#ffffff"}},bubble:{opacity:.6},scatter:{markers:{background:"#ffffff"}},scatterLine:{markers:{background:"#ffffff"}},area:{opacity:.8},candlestick:{downColor:"#d0d0d0",line:{color:"#333333"},border:{_brightness:1.5,opacity:1},highlight:{border:{color:"#b8b8b8",opacity:.2}}},waterfall:{line:{color:"#cccccc"}},horizontalWaterfall:{line:{color:"#cccccc"}},ohlc:{line:{color:"#333333"}}},chartArea:{background:"#ffffff"},seriesColors:["#428bca","#5bc0de","#5cb85c","#f2b661","#e67d4a","#da3b36"],axisDefaults:{line:{color:"#cccccc"},minorTicks:{color:"#ebebeb"},majorTicks:{color:"#cccccc"},labels:{color:"#333333"},majorGridLines:{color:"#cccccc"},minorGridLines:{
color:"#ebebeb"},title:{color:"#333333"},crosshair:{color:"#000000"},notes:{icon:{background:"#000000",border:{color:"#000000"}},label:{color:"#ffffff"},line:{color:"#000000"}}}},gauge:{pointer:{color:"#428bca"},scale:{rangePlaceholderColor:"#cccccc",labels:{color:"#333333"},minorTicks:{color:"#ebebeb"},majorTicks:{color:"#cccccc"},line:{color:"#cccccc"}}},diagram:{shapeDefaults:{fill:{color:"#428bca"},connectorDefaults:{fill:{color:"#333333"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#333333"}}},content:{color:"#333333"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#333333"},hover:{fill:{color:"#333333"},stroke:{color:"#333333"}}}},rotate:{thumb:{stroke:{color:"#333333"},fill:{color:"#333333"}}}},selectable:{stroke:{color:"#333333"}},connectionDefaults:{stroke:{color:"#c4c4c4"},content:{color:"#333333"},selection:{handles:{fill:{color:d},stroke:{color:"#333333"}},stroke:{color:"#333333"}}}},treeMap:{colors:[["#428bca","#d1e0ec"],["#5bc0de","#d6eaf0"],["#5cb85c","#d6e9d6"],["#5cb85c","#f4e8d7"],["#e67d4a","#f2ddd3"],["#da3b36","#f0d0cf"]]}}),v("flat",{chart:{title:{color:"#4c5356"},legend:{labels:{color:"#4c5356"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#4c5356"},errorBars:{color:"#4c5356"},notes:{icon:{background:"transparent",border:{color:"#cdcdcd"}},label:{color:"#4c5356"},line:{color:"#cdcdcd"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#cdcdcd"}},horizontalWaterfall:{line:{color:"#cdcdcd"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#10c4b2","#ff7663","#ffb74f","#a2df53","#1c9ec4","#ff63a5","#1cc47b"],axisDefaults:{line:{color:"#cdcdcd"},labels:{color:"#4c5356"},minorGridLines:{color:"#cdcdcd"},majorGridLines:{color:"#cdcdcd"},title:{color:"#4c5356"},crosshair:{color:"#cdcdcd"},notes:{icon:{background:"transparent",border:{color:"#cdcdcd"}},label:{color:"#4c5356"},line:{color:"#cdcdcd"}}}},gauge:{pointer:{color:"#10c4b2"},scale:{rangePlaceholderColor:"#cdcdcd",labels:{color:"#4c5356"},minorTicks:{color:"#4c5356"},majorTicks:{color:"#4c5356"},line:{color:"#4c5356"}}},diagram:{shapeDefaults:{fill:{color:"#10c4b2"},connectorDefaults:{fill:{color:"#363940"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#363940"}}},content:{color:"#4c5356"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#363940"},hover:{fill:{color:"#363940"},stroke:{color:"#363940"}}}},rotate:{thumb:{stroke:{color:"#363940"},fill:{color:"#363940"}}}},selectable:{stroke:{color:"#363940"}},connectionDefaults:{stroke:{color:"#cdcdcd"},content:{color:"#4c5356"},selection:{handles:{fill:{color:d},stroke:{color:"#363940"}},stroke:{color:"#363940"}}}},treeMap:{colors:[["#10c4b2","#cff3f0"],["#ff7663","#ffe4e0"],["#ffb74f","#fff1dc"],["#a2df53","#ecf9dd"],["#1c9ec4","#d2ecf3"],["#ff63a5","#ffe0ed"],["#1cc47b","#d2f3e5"]]}}),v("material",{chart:{title:{color:"#444444"},legend:{labels:{color:"#444444"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#444444"},errorBars:{color:"#444444"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#444444"},line:{color:"#e5e5e5"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#e5e5e5"}},horizontalWaterfall:{line:{color:"#e5e5e5"}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#ff9800","#ff5722"],axisDefaults:{line:{color:"#e5e5e5"},labels:{color:"#444444"},minorGridLines:{color:"#e5e5e5"},majorGridLines:{color:"#e5e5e5"},title:{color:"#444444"},crosshair:{color:"#7f7f7f"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#444444"},line:{color:"#e5e5e5"}}}},gauge:{pointer:{color:"#3f51b5"},scale:{rangePlaceholderColor:"#e5e5e5",labels:{color:"#444444"},minorTicks:{color:"#444444"},majorTicks:{color:"#444444"},line:{color:"#444444"}}},diagram:{shapeDefaults:{fill:{color:"#3f51b5"},connectorDefaults:{fill:{color:"#7f7f7f"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#7f7f7f"}}},content:{color:"#444444"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#444444"},hover:{fill:{color:"#444444"},stroke:{color:"#444444"}}}},rotate:{thumb:{stroke:{color:"#444444"},fill:{color:"#444444"}}}},selectable:{stroke:{color:"#444444"}},connectionDefaults:{stroke:{color:"#7f7f7f"},content:{color:"#444444"},selection:{handles:{fill:{color:d},stroke:{color:"#444444"}},stroke:{color:"#444444"}}}},treeMap:{colors:[["#3f51b5","#cff3f0"],["#03a9f4","#e5f6fe"],["#4caf50","#edf7ed"],["#f9ce1d","#fefae8"],["#ff9800","#fff4e5"],["#ff5722","#ffeee8"]]}}),v("materialblack",{chart:{title:{color:"#fff"},legend:{labels:{color:"#fff"},inactiveItems:{labels:{color:"#CBCBCB"},markers:{color:"#CBCBCB"}}},seriesDefaults:{labels:{color:"#fff"},errorBars:{color:"#fff"},notes:{icon:{background:"transparent",border:{color:"#e5e5e5"}},label:{color:"#fff"},line:{color:"#e5e5e5"}},candlestick:{downColor:"#c7c7c7",line:{color:"#787878"}},area:{opacity:.9},waterfall:{line:{color:"#4d4d4d"}},horizontalWaterfall:{line:{color:"#4d4d4d"}},overlay:{gradient:"none"},border:{_brightness:1}},chartArea:{background:"#1c1c1c"},seriesColors:["#3f51b5","#03a9f4","#4caf50","#f9ce1d","#ff9800","#ff5722"],axisDefaults:{line:{color:"#4d4d4d"},labels:{color:"#fff"},minorGridLines:{color:"#4d4d4d"},majorGridLines:{color:"#4d4d4d"},title:{color:"#fff"},crosshair:{color:"#7f7f7f"},notes:{icon:{background:"transparent",border:{color:"#4d4d4d"}},label:{color:"#fff"},line:{color:"#4d4d4d"}}}},gauge:{pointer:{color:"#3f51b5"},scale:{rangePlaceholderColor:"#4d4d4d",labels:{color:"#fff"},minorTicks:{color:"#fff"},majorTicks:{color:"#fff"},line:{color:"#fff"}}},diagram:{shapeDefaults:{fill:{color:"#3f51b5"},connectorDefaults:{fill:{color:"#7f7f7f"},stroke:{color:d},hover:{fill:{color:d},stroke:{color:"#7f7f7f"}}},content:{color:"#fff"}},editable:{resize:{handles:{fill:{color:d},stroke:{color:"#fff"},hover:{fill:{color:"#fff"},stroke:{color:"#fff"}}}},rotate:{thumb:{stroke:{color:"#fff"},fill:{color:"#fff"}}}},selectable:{stroke:{color:"#fff"}},connectionDefaults:{stroke:{color:"#7f7f7f"},content:{color:"#fff"},selection:{handles:{fill:{color:d},stroke:{color:"#fff"}},stroke:{color:"#fff"}}}},treeMap:{colors:[["#3f51b5","#cff3f0"],["#03a9f4","#e5f6fe"],["#4caf50","#edf7ed"],["#f9ce1d","#fefae8"],["#ff9800","#fff4e5"],["#ff5722","#ffeee8"]]}}),function(){function t(){return{icon:{background:"#007cc0",border:{color:"#007cc0"}},label:{color:"#ffffff"},line:{color:r}}}var i="#333333",n="#7f7f7f",o="#bdbdbd",r="#c8c8c8",s="#dddddd",a=["#008fd3","#99d101","#f39b02","#f05662","#c03c53","#acacac"],l=["#cbe8f5","#eaf5cb","#fceacc","#fbdcdf","#f2d7dc","#eeeeee"],c=a[0],h=d;v("fiori",{chart:{title:{color:i},legend:{labels:{color:i},inactiveItems:{labels:{color:n},markers:{color:n}}},seriesDefaults:{labels:{color:i},errorBars:{color:i},notes:t(),candlestick:{downColor:r,line:{color:o}},area:{opacity:.8},waterfall:{line:{color:r}},horizontalWaterfall:{line:{color:r}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:a,axisDefaults:{line:{color:r},labels:{color:i},minorGridLines:{color:s},majorGridLines:{color:r},title:{color:i},crosshair:{color:n},notes:t()}},gauge:{pointer:{color:c},scale:{rangePlaceholderColor:r,labels:{color:i},minorTicks:{color:i},majorTicks:{color:i},line:{color:i}}},diagram:{shapeDefaults:{fill:{color:c},connectorDefaults:{fill:{color:i},stroke:{color:h},hover:{fill:{color:h},stroke:{color:i}}},content:{color:i}},editable:{resize:{handles:{fill:{color:h},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:h},stroke:{color:o}},stroke:{color:o}}}},treeMap:{colors:e(a,l)}})}(),function(){function t(){return{icon:{background:"#00b0ff",border:{color:"#00b0ff"}},label:{color:"#ffffff"},line:{color:r}}}var i="#4e4e4e",n="#7f7f7f",o="#bdbdbd",r="#c8c8c8",s="#e5e5e5",a=["#0072c6","#5db2ff","#008a17","#82ba00","#ff8f32","#ac193d"],l=["#cbe2f3","#deeffe","#cbe7d0","#e5f0cb","#fee8d5","#eed0d7"],c=a[0],h=d;v("office365",{chart:{title:{color:i},legend:{labels:{color:i},inactiveItems:{labels:{color:n},markers:{color:n}}},seriesDefaults:{labels:{color:i},errorBars:{color:i},notes:t(),candlestick:{downColor:r,line:{color:o}},area:{opacity:.8},waterfall:{line:{color:r}},horizontalWaterfall:{line:{color:r}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:a,axisDefaults:{line:{color:r},labels:{color:i},minorGridLines:{color:s},majorGridLines:{color:r},title:{color:i},crosshair:{color:n},notes:t()}},gauge:{pointer:{color:c},scale:{rangePlaceholderColor:r,labels:{color:i},minorTicks:{color:i},majorTicks:{color:i},line:{color:i}}},diagram:{shapeDefaults:{fill:{color:c},connectorDefaults:{fill:{color:i},stroke:{color:h},hover:{fill:{color:h},stroke:{color:i}}},content:{color:i}},editable:{resize:{handles:{fill:{color:h},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:h},stroke:{color:o}},stroke:{color:o}}}},treeMap:{colors:e(a,l)}})}(),function(){function t(){return{icon:{background:"#007cc0",border:{color:"#007cc0"}},label:{color:"#ffffff"},line:{color:r}}}var i="#32364c",n="#7f7f7f",o="#bdbdbd",r="#dfe0e1",s="#dfe0e1",a=["#ff4350","#ff9ea5","#00acc1","#80deea","#ffbf46","#ffd78c"],l=["#ffd9dc","#ffeced","#cceef3","#e6f8fb","#fff2da","#fff7e8"],c=a[0],h=d;v("nova",{chart:{title:{color:i},legend:{labels:{color:i},inactiveItems:{labels:{color:n},markers:{color:n}}},seriesDefaults:{labels:{color:i},errorBars:{color:i},notes:t(),candlestick:{downColor:r,line:{color:o}},area:{opacity:.8},waterfall:{line:{color:r}},horizontalWaterfall:{line:{color:r}},overlay:{gradient:"none"},border:{_brightness:1}},seriesColors:a,axisDefaults:{line:{color:r},labels:{color:i},minorGridLines:{color:s},majorGridLines:{color:r},title:{color:i},crosshair:{color:i},notes:t()}},gauge:{pointer:{color:c},scale:{rangePlaceholderColor:r,labels:{color:i},minorTicks:{color:i},majorTicks:{color:i},line:{color:i}}},diagram:{shapeDefaults:{fill:{color:c},connectorDefaults:{fill:{color:i},stroke:{color:h},hover:{fill:{color:h},stroke:{color:i}}},content:{color:i}},editable:{resize:{handles:{fill:{color:h},stroke:{color:o},hover:{fill:{color:o},stroke:{color:o}}}},rotate:{thumb:{stroke:{color:o},fill:{color:o}}}},selectable:{stroke:{color:o}},connectionDefaults:{stroke:{color:o},content:{color:o},selection:{handles:{fill:{color:h},stroke:{color:o}},stroke:{color:o}}}},treeMap:{colors:e(a,l)}})}()}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.chart.min",["kendo.color.min","kendo.data.min","kendo.dataviz.core.min","kendo.dataviz.themes.min","kendo.drawing.min","kendo.userevents.min"],t)}(function(){return function(t,e){function i(){return this}function n(){this._defaults={}}function o(t,e,i,n){var o,r,s=(n.x-i.x)*(t.y-i.y)-(n.y-i.y)*(t.x-i.x),a=(n.y-i.y)*(e.x-t.x)-(n.x-i.x)*(e.y-t.y);return 0!==a&&(r=s/a,o=new ui(t.x+r*(e.x-t.x),t.y+r*(e.y-t.y))),o}function r(t,e){var i,n,o,r=t.series,a=r.length,l=t.seriesDefaults,c=$e({},t.seriesDefaults),h=e?$e({},e.seriesDefaults):{},u=$e({},h);for(s(c),s(u),i=0;i<a;i++)n=r[i].type||t.seriesDefaults.type,o=$e({data:[]},u,h[n],{tooltip:t.tooltip},c,l[n]),r[i]._defaults=o,r[i]=$e({},o,r[i])}function s(t){delete t.bar,delete t.column,delete t.rangeColumn,delete t.line,delete t.verticalLine,delete t.pie,delete t.donut,delete t.area,delete t.verticalArea,delete t.scatter,delete t.scatterLine,delete t.bubble,delete t.candlestick,delete t.ohlc,delete t.boxPlot,delete t.bullet,delete t.verticalBullet,delete t.polarArea,delete t.polarLine,delete t.radarArea,delete t.radarLine,delete t.waterfall}function a(t){var e,i,n,o,r=t.series,s=t.seriesColors||[];for(e=0;e<r.length;e++)i=r[e],n=s[e%s.length],i.color=i.color||n,o=i._defaults,o&&(o.color=o.color||n)}function l(t){var e;ze([nn,hr,_r,yr],function(){e=this+"Axes",t[e]&&(t[this+"Axis"]=t[e],delete t[e])})}function c(e,i){var n=(i||{}).axisDefaults||{};ze([nn,hr,_r,yr],function(){var i=this+"Axis",o=[].concat(e[i]),r=e.axisDefaults||{};o=t.map(o,function(t){var e=(t||{}).color,o=$e({},n,n[i],r,r[i],{line:{color:e},labels:{color:e},title:{color:e}},t);return delete o[i],o}),e[i]=o.length>1?o:o[0]})}function h(t){var e,i=t.length,n=0;for(e=0;e<i;e++)n=Ve.max(n,t[e].data.length);return n}function u(t){return t*t}function d(t,e){if(null===e)return e;var i=Ye(t,!0);return i(e)}function f(t,e){if(null===e)return e;var i="_date_"+t,n=e[i];return n||(n=p(Ye(t,!0)(e)),e[i]=n),n}function p(t){var e,i;if(t instanceof Date)e=t;else if(typeof t===qo)e=Ue.parseDate(t)||new Date(t);else if(t)if(Le(t))for(e=[],i=0;i<t.length;i++)e.push(p(t[i]));else e=new Date(t);return e}function g(t){return Le(t)?Oe(t,g):t?p(t).getTime():e}function m(t,e,i,n){var o,r=t;return t&&(t=p(t),o=t.getHours(),i===wr?(r=new Date(t.getFullYear()+e,0,1),Ue.date.adjustDST(r,0)):i===ao?(r=new Date(t.getFullYear(),t.getMonth()+e,1),Ue.date.adjustDST(r,o)):i===mr?(r=m(v(t,n),7*e,vn),Ue.date.adjustDST(r,o)):i===vn?(r=new Date(t.getFullYear(),t.getMonth(),t.getDate()+e),Ue.date.adjustDST(r,o)):i===Hn?(t=new Date(t),t.setUTCMinutes(0,0,0),r=b(t,e*Ko)):i===so?(r=b(t,e*Qo),r.getSeconds()>0&&r.setSeconds(0)):i===zo?r=b(t,e*Xo):i===Lo&&(r=b(t,e)),i!==Lo&&r.getMilliseconds()>0&&r.setMilliseconds(0)),r}function v(t,e){var i=t.getDay(),n=0;if(!isNaN(i))for(e=e||0;i!==e;)0===i?i=6:i--,n++;return b(t,-n*Zo)}function _(t,e,i){return t=p(t),m(t,0,e,i)}function y(t,e,i){return t=p(t),t&&_(t,e,i).getTime()===t.getTime()?t:m(t,1,e,i)}function w(t,e){return t.getTime()-e}function x(t,e){var i=t.getTime()-e,n=t.getTimezoneOffset()-e.getTimezoneOffset();return i-n*Qo}function b(t,e){return new Date(t.getTime()+e)}function k(t,e,i){var n;return n=i===wr?e.getFullYear()-t.getFullYear():i===ao?12*k(t,e,wr)+e.getMonth()-t.getMonth():Ve.floor(i===vn?w(e,t)/Zo:w(e,t)/ir[i])}function C(t,e,i,n){var o,r=p(t),s=p(e);return o=i==ao?r.getMonth()-s.getMonth()+12*(r.getFullYear()-s.getFullYear())+S(r,new Date(r.getFullYear(),r.getMonth()),vn)/new Date(r.getFullYear(),r.getMonth()+1,0).getDate():i==wr?r.getFullYear()-s.getFullYear()+C(r,new Date(r.getFullYear(),0),ao,1)/12:i==vn||i==mr?S(r,s,i):w(r,e)/ir[i],o/n}function S(t,e,i){return x(t,e)/ir[i]}function T(t){return 1===t.length?t[0]:t}function A(t){var e,i,n,o=t.length;if(o>0)for(i=0;i<o;i++)n=t[i].contentBox(),e?e.wrap(n):e=n.clone();return e||ii()}function P(t,e){return t&&e?t.toLowerCase()===e.toLowerCase():t===e}function D(t,e){return t&&e?g(t)===g(e):t===e}function M(t,e){null!==e&&t.push(e)}function E(t,e){for(var i,n,o=0,r=e.length-1;o<=r;)if(i=Ve.floor((o+r)/2),n=e[i],n<t)o=i+1;else{if(!(n>t)){for(;D(e[i-1],t);)i--;return i}r=i-1}return e[i]<=t?i:i-1}function I(t){return"number"==typeof t&&!isNaN(t)}function B(t){var e,i,n=t.length,o=0;for(e=0;e<n;e++)i=t[e],I(i)&&o++;return o}function z(t){return B(t)===t.length}function L(t){var e,i,n,o={};for(e=0;e<t.length;e++)i=t[e],n=i.options.name,n&&(o[n]=i.range());return o}function R(t,e,i,n){var o,r,s,a,l,c=!1;if(i=i||{},s=i.excluded=i.excluded||[],a=i.defaults=i.defaults||{},l=i.depth=i.depth||0,!(l>eo)){for(o in t)!ki(o,i.excluded)&&t.hasOwnProperty(o)&&(r=t[o],Xe(r)?(c=!0,n||(t[o]=Ri(r(e),a[o]))):typeof r===_o&&(n||(i.defaults=a[o]),i.depth++,c=R(r,e,i,n)||c,i.depth--));return c}}function O(t,i){var n,o,r,s=[],a=t.groupNameTemplate,l=i.length;if(0===l)return r=$e({},t),r.visibleInLegend=!1,[r];for(Di(a)?(Ue.logToConsole("'groupNameTemplate' is obsolete and will be removed in future versions. Specify the group name template as 'series.name'"),a&&(n=Qe(a))):(n=Qe(t.name||""),0===n._slotCount&&(n=Qe(Di(t.name)?"#= group.value #: #= series.name #":"#= group.value #"))),o=0;o<l;o++)r=$e({},t),Xe(r.color)||(r.color=e),r._groupIx=o,r._groupValue=i[o].value,s.push(r),n&&(r.name=n({series:r,group:i[o]}));return s}function V(t,e){var i,n,o=[];for(e=[].concat(e),i=0;i<t.length;i++)n=t[i],ki(n.type,e)&&o.push(n);return o}function F(e,i){if(e instanceof Date){for(var n=0,o=i.length;n<o;n++)if(D(i[n],e))return n;return-1}return t.inArray(e,i)}function N(t,e){e=e||wi;for(var i=1,n=t.length;i<n;i++)if(e(t[i],t[i-1])<0){t.sort(e);break}return t}function H(t,e){var i,n=N(t,e),o=n.length,r=o>0?[n[0]]:[];for(e=e||wi,i=1;i<o;i++)0!==e(n[i],Mi(r))&&r.push(n[i]);return r}function U(t,e){var i=t.type,n=e instanceof Date;return!i&&n||P(i,mn)}function j(t){var e,i,n,o,r=[],s=t.length;for(e=0;e<s;e++)for(i=t[e],o=i.length,n=0;n<o;n++)r[n]=r[n]||[],r[n].push(i[n]);return r}function G(t,e){if(t.indexOf(".")>-1)for(var i,n=t.split("."),o="";n.length>1;)o+=n.shift(),i=Ue.getter(o)(e)||{},Ue.setter(o)(e,i),o+="."}function W(t){var e,i,n,o=t.data,r=0;for(e=0;e<o.length;e++)i=ot.current.bindPoint(t,e),n=i.valueFields.value,typeof n===qo&&(n=parseFloat(n)),I(n)&&i.fields.visible!==!1&&(r+=Ve.abs(n));return r}function q(t){var e=t.overlay;return e&&e.gradient&&"none"!=e.gradient}function $(t){for(var e=0;e<t.length;e++)if(Di(t[e].zIndex))return!0}function Y(){this._defaultPrevented=!0}function X(t,e){if(t)for(var i=0;i<t.length;i++)if(t[i].category===e)return[t[i]]}function Q(t){return Di(t)&&null!==t}function K(t){var e,i,n={};for(i=0;i<t.length;i++)e=t[i],e.axis.options.name&&(n[e.axis.options.name]={min:e.range.min,max:e.range.max});return n}function Z(t,e){var i=(e||"").toLowerCase(),n="none"==i&&!(t.ctrlKey||t.shiftKey||t.altKey)||t[i+"Key"];return n}function J(t,e){var i=[];tt(t,i),Ue.util.loadFonts(i,e)}function tt(t,e,i){var n=5;i=i||{depth:0},!t||i.depth>n||!document.fonts||Object.keys(t).forEach(function(n){var o=t[n];"dataSource"!==n&&"$"!==n[0]&&o&&("font"===n?e.push(o):"object"==typeof o&&(i.depth++,tt(o,e,i),i.depth--))})}function et(t,e){var i,n,o,r;for(o in e)i=e[o],n=t[o],Di(n)&&(r=null===i,r||!Di(i)?(delete t[o],r&&delete e[o]):n&&Re(i)&&Re(i)&&et(n,i))}function it(t,e){var i,n;for(i=0;i<t.length;i++)if(n=t[i],n&&n.pane===e)return n}var nt,ot,rt,st,at,lt,ct,ht,ut,dt,ft,pt,gt,mt,vt,_t,yt,wt,xt,bt,kt,Ct,St,Tt,At,Pt,Dt,Mt,Et,It,Bt,zt,Lt,Rt,Ot,Vt,Ft,Nt,Ht,Ut,jt,Gt,Wt,qt,$t,Yt,Xt,Qt,Kt,Zt,Jt,te,ee,ie,ne,oe,re,se,ae,le,ce,he,ue,de,fe,pe,ge,me,ve,_e,ye,we,xe,be,ke,Ce,Se,Te,Ae,Pe,De,Me,Ee,Ie,Be,ze=t.each,Le=t.isArray,Re=t.isPlainObject,Oe=t.map,Ve=Math,Fe=t.noop,Ne=t.extend,He=t.proxy,Ue=window.kendo,je=Ue.Class,Ge=Ue.Observable,We=Ue.data.DataSource,qe=Ue.ui.Widget,$e=Ue.deepExtend,Ye=Ue.getter,Xe=Ue.isFunction,Qe=Ue.template,Ke=Ue._outerWidth,Ze=Ue._outerHeight,Je=Ue.dataviz,ti=Je.Axis,ei=Je.AxisLabel,ii=Je.Box2D,ni=Je.BoxElement,oi=Je.ChartElement,ri=Ue.drawing.Color,si=Je.CurveProcessor,ai=Je.FloatElement,li=Je.Note,ci=Je.LogarithmicAxis,hi=Je.NumericAxis,ui=Je.Point2D,di=Je.RootElement,fi=Je.Ring,pi=Je.ShapeElement,gi=Je.ShapeBuilder,mi=Je.TextBox,vi=Je.Title,_i=Je.alignPathToPixel,yi=Je.autoFormat,wi=Je.dateComparer,xi=Je.eventTargetElement,bi=Je.getSpacing,ki=Je.inArray,Ci=Je.interpolateValue,Si=Je.mwDelta,Ti=Je.round,Ai=Ue.util,Pi=Ai.append,Di=Ai.defined,Mi=Ai.last,Ei=Ai.limitValue,Ii=Ai.sparseArrayLimits,Bi=Ai.sparseArrayMin,zi=Ai.sparseArrayMax,Li=Ai.renderTemplate,Ri=Ai.valueOrDefault,Oi=Je.geometry,Vi=Je.drawing,Fi=".kendoChart",Ni="above",Hi="area",Ui="auto",ji="fit",Gi=Je.AXIS_LABEL_CLICK,Wi="bar",qi=6,$i=.8,Yi="below",Xi="#000",Qi="both",Ki="bottom",Zi="boxPlot",Ji="bubble",tn="bullet",en="candlestick",nn="category",on="center",rn="change",sn="circle",an="contextmenu"+Fi,ln=Je.CLIP,cn="color",hn="column",un=Je.COORD_PRECISION,dn="cross",fn="k-",pn="custom",gn="dataBound",mn="date",vn="days",_n=Je.DEFAULT_FONT,yn=Je.DEFAULT_HEIGHT,wn=Je.DEFAULT_PRECISION,xn=Je.DEFAULT_WIDTH,bn=4,kn="donut",Cn=50,Sn="drag",Tn="dragEnd",An="dragStart",Pn="errorLow",Dn="errorHigh",Mn="xErrorLow",En="xErrorHigh",In="yErrorLow",Bn="yErrorHigh",zn="fadeIn",Ln="first",Rn="from",On="funnel",Vn="glass",Fn="horizontal",Nn="horizontalWaterfall",Hn="hours",Un=Je.INITIAL_ANIMATION_DURATION,jn="insideBase",Gn="insideEnd",Wn="interpolate",qn="leave",$n="left",Yn="legendItemClick",Xn="legendItemHover",Qn="line",Kn=8,Zn="linear",Jn="log",to="max",eo=5,io=Number.MAX_VALUE,no="min",oo=.01,ro=-Number.MAX_VALUE,so="minutes",ao="months",lo="mouseleave"+Fi,co="mousemove.tracking",ho="mousemove"+Fi,uo=20,fo=150,po="DOMMouseScroll"+Fi+" mousewheel"+Fi,go=Je.NOTE_CLICK,mo=Je.NOTE_HOVER,vo="noteText",_o="object",yo="ohlc",wo="outsideEnd",xo="pie",bo=70,ko="plotAreaClick",Co="plotAreaHover",So="pointer",To="rangeBar",Ao="rangeColumn",Po="render",Do="right",Mo="roundedBevel",Eo="roundedGlass",Io="scatter",Bo="scatterLine",zo="seconds",Lo="milliseconds",Ro="selectStart",Oo="select",Vo="selectEnd",Fo="seriesClick",No="seriesHover",Ho=Ue.support.browser.msie&&10===Ue.support.browser.version?.001:0,Uo="step",jo="smooth",Go="stderr",Wo="stddev",qo="string",$o="summary",Yo=1,Xo=1e3*Yo,Qo=60*Xo,Ko=60*Qo,Zo=24*Ko,Jo=7*Zo,tr=31*Zo,er=365*Zo,ir={years:er,months:tr,weeks:Jo,days:Zo,hours:Ko,minutes:Qo,seconds:Xo,milliseconds:Yo},nr="to",or="top",rr=150,sr=5,ar=100,lr=100,cr="chart-tooltip-inverse",hr="value",ur="verticalArea",dr="verticalBoxPlot",fr="verticalBullet",pr="verticalLine",gr="waterfall",mr="weeks",vr="#fff",_r="x",yr="y",wr="years",xr="zero",br=3,kr="zoomStart",Cr="zoom",Sr="zoomEnd",Tr=[Lo,zo,so,Hn,vn,mr,ao,wr],Ar=[Wi,hn,yo,en,Zi,dr,tn,Ao,To,gr,Nn],Pr={milliseconds:"HH:mm:ss.fff",seconds:"HH:mm:ss",minutes:"HH:mm",hours:"HH:mm",days:"M/d",weeks:"M/d",months:"MMM 'yy",years:"yyyy"},Dr=qe.extend({init:function(t,i){var n,o,r=this;Ue.destroy(t),qe.fn.init.call(r,t),r.element.addClass(fn+this.options.name.toLowerCase()).css("position","relative"),i&&(o=i.dataSource,i.dataSource=e),n=$e({},r.options,i),r._originalOptions=$e({},n),r._initTheme(n),r._initSurface(),r.bind(r.events,r.options),r.wrapper=r.element,i&&(i.dataSource=o),r._initDataSource(i),Ue.notify(r,Je.ui)},_initTheme:function(i){var n,o=this,r=Je.ui.themes||{},s=i.theme,c=r[s]||r[s.toLowerCase()],h=s&&c?c.chart:{},u=[],d=i.series||[];for(n=0;n<d.length;n++)u.push(t.extend({},d[n]));i.series=u,l(i),o._applyDefaults(i,h),null===i.seriesColors&&(i.seriesColors=e),o.options=$e({},h,i),a(o.options)},_initDataSource:function(t){var e=this,i=(t||{}).dataSource;e._dataChangeHandler=He(e._onDataChanged,e),e.dataSource=We.create(i).bind(rn,e._dataChangeHandler),e._bindCategories(),i&&(e._hasDataSource=!0),J(t,function(){e._redraw(),e._attachEvents()}),i&&e.options.autoBind&&e.dataSource.fetch()},setDataSource:function(t){var e=this;e.dataSource.unbind(rn,e._dataChangeHandler),e.dataSource=t=We.create(t),e._hasDataSource=!0,e._hasData=!1,t.bind(rn,e._dataChangeHandler),e.options.autoBind&&t.fetch()},events:[gn,Fo,No,Gi,Yn,Xn,ko,Co,An,Sn,Tn,kr,Cr,Sr,Ro,Oo,Vo,go,mo,Po],items:function(){return t()},options:{name:"Chart",renderAs:"",theme:"default",chartArea:{},legend:{visible:!0,labels:{}},categoryAxis:{},autoBind:!0,seriesDefaults:{type:hn,data:[],highlight:{visible:!0},labels:{},negativeValues:{visible:!1}},series:[],seriesColors:null,tooltip:{visible:!1},transitions:!0,valueAxis:{},plotArea:{},title:{},xAxis:{},yAxis:{},panes:[{}],pannable:!1,zoomable:!1},refresh:function(){var t=this;t._applyDefaults(t.options),a(t.options),t._bindSeries(),t._bindCategories(),t.trigger(gn),t._redraw()},getSize:function(){return Ue.dimensions(this.element)},_resize:function(){var t=this.options.transitions;this.options.transitions=!1,this._redraw(),this.options.transitions=t},redraw:function(t){var e,i,n=this;n._applyDefaults(n.options),a(n.options),t?(i=n._model._plotArea,e=i.findPane(t),i.redraw(e)):n._redraw()},getAxis:function(t){var e,i=this._plotArea.axes;for(e=0;e<i.length;e++)if(i[e].options.name===t)return new Ie(i[e])},findAxisByName:function(t){return this.getAxis(t)},plotArea:function(){return new Me(this._plotArea)},findPaneByName:function(t){var e,i=this._plotArea.panes;for(e=0;e<i.length;e++)if(i[e].options.name===t)return new Ee(this,i[e])},findPaneByIndex:function(t){var e=this._plotArea.panes;if(e[t])return new Ee(this,e[t])},findSeries:function(t){var e,i=this._plotArea,n=i.srcSeries||i.series;for(e=0;e<n.length;e++)if(t(n[e]))return new Be(this,n[e])},findSeriesByName:function(t){return this._createSeries({name:t})},findSeriesByIndex:function(t){return this._createSeries({index:t})},_createSeries:function(t){var e=this._seriesOptions(t);if(e)return new Be(this,e)},_seriesOptions:function(t){var e,i,n=this._plotArea,o=n.srcSeries||n.series;if(Di(t.index))e=o[t.index];else if(Di(t.name))for(i=0;i<o.length;i++)if(o[i].name===t.name){e=o[i];break}return e},toggleHighlight:function(t,e){var i,n,o,r=this._plotArea,s=(r.srcSeries||r.series||[])[0];Ue.isFunction(e)?o=r.filterPoints(e):(Re(e)?(i=e.series,n=e.category):i=n=e,o=s.type===kn?X(r.pointsBySeriesName(i),n):s.type===xo||s.type===On?X((r.charts[0]||{}).points,n):r.pointsBySeriesName(i)),o&&this._togglePointsHighlight(t,o)},_togglePointsHighlight:function(t,e){var i,n=this._highlight;for(i=0;i<e.length;i++)n.togglePointHighlight(e[i],t)},showTooltip:function(t){var e,i,n,o=this._sharedTooltip(),r=this._tooltip,s=this._plotArea;Ue.isFunction(t)?(e=s.findPoint(t),e&&o&&(i=e.categoryIx)):o&&Di(t)&&(i=s.categoryAxis.categoryIndex(t)),o?i>=0&&(n=this._plotArea.pointsByCategoryIndex(i),r.showAt(n)):e&&r.show(e)},hideTooltip:function(){this._tooltip.hide()},_initSurface:function(){var t=this.surface,e=this._surfaceWrap(),i=this.options.chartArea;i.width&&e.css("width",i.width),i.height&&e.css("height",i.height),t&&t.options.type===this.options.renderAs?(this.surface.clear(),this.surface.resize()):(t&&t.destroy(),this.surface=Vi.Surface.create(e,{type:this.options.renderAs}))},_surfaceWrap:function(){return this.element},_redraw:function(){var t,e=this,i=e._getModel();e._destroyView(),e._model=i,e._plotArea=i._plotArea,i.renderVisual(),this.options.transitions!==!1&&i.traverse(function(t){t.animation&&t.animation.setup()}),e._initSurface(),e.surface.draw(i.visual),this.options.transitions!==!1&&i.traverse(function(t){t.animation&&t.animation.play()}),e._tooltip=e._createTooltip(),e._highlight=new _e(t),e._setupSelection(),e._createPannable(),e._createZoomSelection(),e._createMousewheelZoom(),e._hasDataSource&&!e._hasData&&e.options.autoBind||e.trigger(Po)},exportVisual:function(t){var e,i,n,o;return t&&(t.width||t.height)?(i=this.options.chartArea,n=this._originalOptions.chartArea,$e(i,t),o=this._getModel(),i.width=n.width,i.height=n.height,o.renderVisual(),e=o.visual):e=this.surface.exportVisual(),e},_sharedTooltip:function(){var t=this,e=t.options;return t._plotArea instanceof ue&&e.tooltip.shared},_createPannable:function(){var t=this.options;t.pannable!==!1&&(this._pannable=new Te(this._plotArea,t.pannable))},_createZoomSelection:function(){var t=this.options.zoomable,e=(t||{}).selection;t!==!1&&e!==!1&&(this._zoomSelection=new Ae(this,e))},_createMousewheelZoom:function(){var t=this.options.zoomable,e=(t||{}).mousewheel;t!==!1&&e!==!1&&(this._mousewheelZoom=new Pe(this,e))},_createTooltip:function(){var t,e=this,i=e.options,n=e.element;return t=e._sharedTooltip()?new xe(n,e._plotArea,i.tooltip):new we(n,i.tooltip),t.bind(qn,He(e._tooltipleave,e)),t},_tooltipleave:function(){var t=this,e=t._plotArea,i=t._highlight;e.hideCrosshairs(),i.hide()},_applyDefaults:function(t,e){c(t,e),r(t,e)},_getModel:function(){var t,e=this,i=e.options,n=new di(e._modelOptions());return n.chart=e,vi.buildTitle(i.title,n),t=n._plotArea=e._createPlotArea(),i.legend.visible&&n.append(new lt(t.options.legend)),n.append(t),n.reflow(),n},_modelOptions:function(){var t=this,e=t.options,i=t.element,n=Ve.floor(i.height()),o=Ve.floor(i.width());return t._size=null,$e({width:o||xn,height:n||yn,transitions:e.transitions},e.chartArea)},_createPlotArea:function(t){var e=this,i=e.options;return nt.current.create(t?[]:i.series,i)},_setupSelection:function(){var t,e,i,n,o,r,s=this,a=s._plotArea,l=a.axes,c=s._selections=[];for(s._selectStartHandler||(s._selectStartHandler=He(s._selectStart,s),s._selectHandler=He(s._select,s),s._selectEndHandler=He(s._selectEnd,s)),e=0;e<l.length;e++)i=l[e],r=i.options,i instanceof ct&&r.select&&!r.vertical&&(n=0,o=r.categories.length-1,i instanceof ht&&(n=r.categories[n],o=r.categories[o]),r.justified||(i instanceof ht?o=m(o,1,r.baseUnit,r.weekStartDay):o++),t=new Se(s,i,$e({min:n,max:o},r.select)),t.bind(Ro,s._selectStartHandler),t.bind(Oo,s._selectHandler),t.bind(Vo,s._selectEndHandler),c.push(t))},_selectStart:function(t){return this.trigger(Ro,t)},_select:function(t){return this.trigger(Oo,t)},_selectEnd:function(t){return this.trigger(Vo,t)},_attachEvents:function(){var t=this,e=t.element,i=t.surface;i.bind("mouseenter",He(t._mouseover,t)),i.bind("mouseleave",He(t._mouseout,t)),e.on(an,He(t._click,t)),e.on(po,He(t._mousewheel,t)),e.on(lo,He(t._mouseleave,t)),t._mousemove=Ue.throttle(He(t._mousemove,t),uo),t._shouldAttachMouseMove()&&e.on(ho,t._mousemove),Ue.UserEvents&&(t._userEvents=new Ue.UserEvents(e,{global:!0,multiTouch:!0,fastTap:!0,tap:He(t._tap,t),start:He(t._start,t),move:He(t._move,t),end:He(t._end,t),gesturestart:He(t._gesturestart,t),gesturechange:He(t._gesturechange,t),gestureend:He(t._gestureend,t)}))},_gesturestart:function(t){this._mousewheelZoom&&(this._gestureDistance=t.distance,this._unsetActivePoint(),this.surface.suspendTracking())},_gestureend:function(){this._zooming&&(this.surface&&this.surface.resumeTracking(),this._zooming=!1,this.trigger(Sr,{}))},_gesturechange:function(t){var e,i,n,o,r=this,s=r._mousewheelZoom;s&&(t.preventDefault(),e=r._gestureDistance,i=-t.distance/e+1,Ve.abs(i)>=.1&&(i=Ve.round(10*i),r._gestureDistance=t.distance,n={delta:i,axisRanges:L(r._plotArea.axes),originalEvent:t},!r._zooming&&r.trigger(kr,n)||(r._zooming||(r._zooming=!0),o=n.axisRanges=s.updateRanges(i),o&&!r.trigger(Cr,n)&&s.zoom())))},_mouseout:function(t){if(t.element){var e=this._drawingChartElement(t.element,t);e&&e.leave&&e.leave(this,t.originalEvent)}},_start:function(t){var e=this,i=e._events,n=e._eventCoordinates(t);e._plotArea.backgroundContainsPoint(n)&&(Di(i[An]||i[Sn]||i[Tn])&&e._startNavigation(t,n,An),e._pannable&&e._pannable.start(t)&&(this.surface.suspendTracking(),this._unsetActivePoint()),e._zoomSelection&&e._zoomSelection.start(t)&&this.trigger(kr,{axisRanges:L(this._plotArea.axes),originalEvent:t}))},_move:function(t){var e,i,n,o,r,s,a=this,l=a._navState,c=a._pannable,h={};if(c)t.preventDefault(),h=c.move(t),h&&!a.trigger(Sn,{axisRanges:h,originalEvent:t})&&c.pan();else if(l){for(t.preventDefault(),e=l.axes,i=0;i<e.length;i++)n=e[i],o=n.options.name,o&&(r=n.options.vertical?t.y:t.x,s=r.startLocation-r.location,0!==s&&(h[n.options.name]=n.translateRange(s)));l.axisRanges=h,a.trigger(Sn,{axisRanges:h,originalEvent:t})}a._zoomSelection&&a._zoomSelection.move(t)},_end:function(t){var e,i=this._pannable;i&&i.end(t)?(this.surface.resumeTracking(),this.trigger(Tn,{axisRanges:L(this._plotArea.axes),originalEvent:t})):this._endNavigation(t,Tn),this._zoomSelection&&(e=this._zoomSelection.end(t),e&&!this.trigger(Cr,{axisRanges:e,originalEvent:t})&&(this._zoomSelection.zoom(),this.trigger(Sr,{axisRanges:e,originalEvent:t})))},_mousewheel:function(t){var e,i,n,o,r,s,a,l=this,c=t.originalEvent,h=Si(t),u=l._navState,d={},f=l._mousewheelZoom,p=l._eventCoordinates(c);if(l._plotArea.backgroundContainsPoint(p))if(f)a={delta:h,axisRanges:L(this._plotArea.axes),originalEvent:t},!l._zooming&&l.trigger(kr,a)||(t.preventDefault(),l._zooming||(l._unsetActivePoint(),l.surface.suspendTracking(),l._zooming=!0),l._mwTimeout&&clearTimeout(l._mwTimeout),a.axisRanges=d=f.updateRanges(h),d&&!l.trigger(Cr,a)&&f.zoom(),l._mwTimeout=setTimeout(function(){l.trigger(Sr,a),l._zooming=!1,l.surface&&l.surface.resumeTracking();
},fo));else if(u||(e=l._startNavigation(c,p,kr),e||(u=l._navState)),u){for(i=u.totalDelta||h,u.totalDelta=i+h,n=l._navState.axes,o=0;o<n.length;o++)r=n[o],s=r.options.name,s&&(d[s]=r.scaleRange(-i));l.trigger(Cr,{delta:h,axisRanges:d,originalEvent:t}),l._mwTimeout&&clearTimeout(l._mwTimeout),l._mwTimeout=setTimeout(function(){l._endNavigation(t,Sr)},fo)}},_startNavigation:function(t,e,i){var n,o,r=this,s=r._model._plotArea,a=s.findPointPane(e),l=s.axes.slice(0);a&&(o=L(l),n=r.trigger(i,{axisRanges:o,originalEvent:t}),n?r._userEvents.cancel():(r._suppressHover=!0,r._unsetActivePoint(),r._navState={axisRanges:o,pane:a,axes:l}))},_endNavigation:function(t,e){var i=this;i._navState&&(i.trigger(e,{axisRanges:i._navState.axisRanges,originalEvent:t}),i._suppressHover=!1,i._navState=null)},_getChartElement:function(t,e){var i=this.surface.eventTarget(t);if(i)return this._drawingChartElement(i,t,e)},_drawingChartElement:function(t,e,i){for(var n;t&&!n;)n=t.chartElement,t=t.parent;if(n)return n.aliasFor&&(n=n.aliasFor(e,this._eventCoordinates(e))),i&&(n=n.closest(i)),n},_eventCoordinates:function(t){var e=this,i=Di((t.x||{}).client),n=i?t.x.client:t.clientX,o=i?t.y.client:t.clientY;return e._toModelCoordinates(n,o)},_toModelCoordinates:function(e,i){var n=this.element,o=n.offset(),r=parseInt(n.css("paddingLeft"),10),s=parseInt(n.css("paddingTop"),10),a=t(window);return new ui(e-o.left-r+a.scrollLeft(),i-o.top-s+a.scrollTop())},_tap:function(t){var e=this,i=e.surface.eventTarget(t),n=e._drawingChartElement(i,t);e._activePoint===n?e._propagateClick(n,t):(e._startHover(i,t)||e._unsetActivePoint(),e._propagateClick(n,t)),e._supressMouseleave=!0,setTimeout(function(){e._supressMouseleave=!1},0)},_click:function(t){var e=this,i=e._getChartElement(t);e._propagateClick(i,t)},_propagateClick:function(t,e){for(;t;)t.click&&t.click(this,e),t=t.parent},_startHover:function(t,i){var n,o=this,r=o._drawingChartElement(t,i),s=o._tooltip,a=o._highlight,l=o.options.tooltip;if(!o._suppressHover&&a&&!a.isHighlighted(r)&&!o._sharedTooltip())return n=o._drawingChartElement(t,i,function(t){return t.hover&&!(t instanceof ce)}),n&&!n.hover(o,i)?(o._activePoint=n,l=$e({},l,n.options.tooltip),l.visible&&s.show(n),a.show(n),n):e},_mouseover:function(e){var i=this,n=i._startHover(e.element,e.originalEvent);n&&n.tooltipTracking&&t(document).on(co,He(i._mouseMoveTracking,i))},_mouseMoveTracking:function(e){var i,n,o=this,r=o.options,s=o._tooltip,a=o._highlight,l=o._eventCoordinates(e),c=o._activePoint;o._plotArea.box.containsPoint(l)?c&&c.tooltipTracking&&c.series&&c.parent.getNearestPoint&&(n=c.parent.getNearestPoint(l.x,l.y,c.seriesIx),n&&n!=c&&(n.hover(o,e),o._activePoint=n,i=$e({},r.tooltip,c.options.tooltip),i.visible&&s.show(n),a.show(n))):(t(document).off(co),o._unsetActivePoint())},_mousemove:function(t){var e=this._eventCoordinates(t);this._trackCrosshairs(e),this._plotArea.hover&&this._plotArea.hover(this,t),this._sharedTooltip()&&this._trackSharedTooltip(e,t)},_trackCrosshairs:function(t){var e,i,n=this._plotArea.crosshairs;for(e=0;e<n.length;e++)i=n[e],i.box.containsPoint(t)?i.showAt(t):i.hide()},_trackSharedTooltip:function(e,i){var n,o,r,s,a=this,l=a.options,c=a._plotArea,h=c.categoryAxis,u=a._tooltip,d=l.tooltip,f=a._highlight;c.box.containsPoint(e)&&(n=h.pointCategoryIndex(e),n!==a._tooltipCategoryIx&&(o=c.pointsByCategoryIndex(n),r=t.map(o,function(t){return t.eventArgs(i)}),s=r[0]||{},s.categoryPoints=r,o.length>0&&!this.trigger(No,s)?(d.visible&&u.showAt(o,e),f.show(o)):u.hide(),a._tooltipCategoryIx=n))},_mouseleave:function(e){var i=this,n=i._plotArea,o=i._tooltip,r=i._highlight,s=e.relatedTarget;s&&t(s).closest(o.element).length||i._supressMouseleave||(i._mousemove.cancel(),n.hideCrosshairs(),r.hide(),setTimeout(He(o.hide,o),lr),i._tooltipCategoryIx=null)},_unsetActivePoint:function(){var t=this,e=t._tooltip,i=t._highlight;t._activePoint=null,e&&e.hide(),i&&i.hide()},_onDataChanged:function(t){var e,i,n=this,o=n.options,r=n._sourceSeries||o.series,s=r.length,l=n.dataSource.view(),c=(n.dataSource.group()||[]).length>0,h=[];for(e=0;e<s;e++)i=r[e],n._isBindable(i)&&c?(Pi(h,O(i,l)),this._applyGroupVisibleState(h,t)):h.push(i||[]);n._sourceSeries=r,o.series=h,a(n.options),n._bindSeries(),n._bindCategories(),n._hasData=!0,n._deferRedraw()},_applyGroupVisibleState:function(t,e){var i,n;if(e&&e.action)for(i=this._groupVisibleState=this._groupVisibleState||{},n=0;n<t.length;n++)i[t[n]._groupValue]===!1&&(t[n].visible=!1);else delete this._groupVisibleState},_saveGroupVisibleState:function(t){Di(t._groupValue)&&(this._groupVisibleState||(this._groupVisibleState={}),this._groupVisibleState[t._groupValue]=t.visible)},_deferRedraw:function(){var t=this;Ue.support.vml?(t._clearRedrawTimeout(),t._redrawTimeout=setTimeout(function(){t.surface&&(t.trigger(gn),t._redraw())},0)):(t.trigger(gn),t._redraw())},_clearRedrawTimeout:function(){this._redrawTimeout&&(clearInterval(this._redrawTimeout),this._redrawTimeout=null)},_bindSeries:function(){var t,e,i,n,o=this,r=o.dataSource.view(),s=o.options.series,a=s.length;for(t=0;t<a;t++)e=s[t],o._isBindable(e)&&(i=e._groupIx,n=Di(i)?(r[i]||{}).items:r,e.autoBind!==!1&&(e.data=n))},_bindCategories:function(){var t,e,i=this,n=i.dataSource.view()||[],o=(i.dataSource.group()||[]).length>0,r=n,s=i.options,a=[].concat(s.categoryAxis);for(o&&n.length&&(r=n[0].items),t=0;t<a.length;t++)e=a[t],e.autoBind!==!1&&i._bindCategoryAxis(e,r,t)},_bindCategoryAxis:function(t,e,i){var n,o,r,s=(e||[]).length;if(t.field)for(t.categories=[],n=0;n<s;n++)r=e[n],o=d(t.field,r),0===n?(t.categories=[o],t.dataItems=[r]):(t.categories.push(o),t.dataItems.push(r));else this._bindCategoryAxisFromSeries(t,i)},_bindCategoryAxisFromSeries:function(t,e){var i,n,o,r,s,a,l,c,h,u,p,g=this,m=[],v=g.options.series,_=v.length,y={};for(n=0;n<_;n++)if(o=v[n],r=o.categoryAxis===t.name||!o.categoryAxis&&0===e,s=o.data,l=s.length,o.categoryField&&r&&l>0)for(p=U(t,d(o.categoryField,s[0])),u=p?f:d,a=0;a<l;a++)c=s[a],h=u(o.categoryField,c),!p&&y[h]||(m.push([h,c]),p||(y[h]=!0));m.length>0&&(p&&(m=H(m,function(t,e){return wi(t[0],e[0])})),i=j(m),t.categories=i[0],t.dataItems=i[1])},_isBindable:function(t){var e,i,n=ot.current.valueFields(t),o=!0;for(i=0;i<n.length;i++)if(e=n[i],e===hr?e="field":e+="Field",!Di(t[e])){o=!1;break}return o},_legendItemClick:function(t,e){var i,n,o=this,r=o._plotArea,s=(r.srcSeries||r.series)[t];ki(s.type,[xo,kn,On])?(n=s.data[e],i=!!Di(n.visible)&&!n.visible,n.visible=i):(s.visible=!s.visible,this._saveGroupVisibleState(s)),this._noTransitionsRedraw()},_noTransitionsRedraw:function(){var t,e=this.options;e.transitions&&(e.transitions=!1,t=!0),this.redraw(),t&&(e.transitions=!0)},_legendItemHover:function(t,e){var i,n=this,o=n._plotArea,r=n._highlight,s=(o.srcSeries||o.series)[t];i=ki(s.type,[xo,kn,On])?o.findPoint(function(i){return i.series.index===t&&i.index===e}):o.pointsBySeriesIndex(t),r.show(i)},_shouldAttachMouseMove:function(){var t=this,e=t._events;return t._plotArea.crosshairs.length||t._tooltip&&t._sharedTooltip()||Di(e[Co])},setOptions:function(i){var n=this,o=i.dataSource;i.dataSource=e,et(n._originalOptions,i),n._originalOptions=$e(n._originalOptions,i),n.options=$e({},n._originalOptions),n._sourceSeries=null,t(document).off(ho),qe.fn._setEvents.call(n,i),n._initTheme(n.options),o&&n.setDataSource(o),n._hasDataSource?n._onDataChanged():(n._bindCategories(),n.redraw()),n._shouldAttachMouseMove()&&n.element.on(ho,n._mousemove)},destroy:function(){var e=this,i=e.dataSource;e.element.off(Fi),i&&i.unbind(rn,e._dataChangeHandler),t(document).off(co),e._userEvents&&e._userEvents.destroy(),e._destroyView(),e.surface.destroy(),e.surface=null,e._clearRedrawTimeout(),qe.fn.destroy.call(e)},_destroyView:function(){var t=this,e=t._model,i=t._selections;if(e&&(e.destroy(),t._model=null),i)for(;i.length>0;)i.shift().destroy();t._unsetActivePoint(),t._tooltip&&t._tooltip.destroy(),t._highlight&&t._highlight.destroy(),t._zoomSelection&&(t._zoomSelection.destroy(),delete t._zoomSelection),t._pannable&&(t._pannable.destroy(),delete t._pannable),t._mousewheelZoom&&(t._mousewheelZoom.destroy(),delete t._mousewheelZoom)}});Je.ExportMixin.extend(Dr.fn),Ue.PDFMixin&&Ue.PDFMixin.extend(Dr.fn),nt=je.extend({init:function(){this._registry=[]},register:function(t,e){this._registry.push({type:t,seriesTypes:e})},create:function(t,e){var i,n,o,r=this._registry,s=r[0];for(i=0;i<r.length;i++)if(n=r[i],o=V(t,n.seriesTypes),o.length>0){s=n;break}return new s.type(o,e)}}),nt.current=new nt,ot=je.extend({init:function(){this._valueFields={},this._otherFields={},this._nullValue={},this._undefinedValue={}},register:function(t,i,n){var o,r,s=this;for(i=i||[hr],o=0;o<t.length;o++)r=t[o],s._valueFields[r]=i,s._otherFields[r]=n,s._nullValue[r]=s._makeValue(i,null),s._undefinedValue[r]=s._makeValue(i,e)},canonicalFields:function(t){return this.valueFields(t).concat(this.otherFields(t))},valueFields:function(t){return this._valueFields[t.type]||[hr]},otherFields:function(t){return this._otherFields[t.type]||[hr]},bindPoint:function(t,e,i){var n,o,r,s,a,l=this,c=t.data,h=Di(i)?i:c[e],u={valueFields:{value:h}},d=l.valueFields(t),f=l._otherFields[t.type];return null===h?a=l._nullValue[t.type]:Di(h)?Le(h)?(o=h.slice(d.length),a=l._bindFromArray(h,d),n=l._bindFromArray(o,f)):typeof h===_o&&(r=l.sourceFields(t,d),s=l.sourceFields(t,f),a=l._bindFromObject(h,d,r),n=l._bindFromObject(h,f,s)):a=l._undefinedValue[t.type],Di(a)&&(1===d.length?u.valueFields.value=a[d[0]]:u.valueFields=a),u.fields=n||{},u},_makeValue:function(t,e){var i,n,o={},r=t.length;for(i=0;i<r;i++)n=t[i],o[n]=e;return o},_bindFromArray:function(t,e){var i,n,o={};if(e)for(n=Ve.min(e.length,t.length),i=0;i<n;i++)o[e[i]]=t[i];return o},_bindFromObject:function(t,e,i){var n,o,r,s,a={};if(e)for(o=e.length,i=i||e,n=0;n<o;n++)r=e[n],s=i[n],a[r]=d(s,t);return a},sourceFields:function(t,e){var i,n,o,r,s;if(e)for(n=e.length,r=[],i=0;i<n;i++)o=e[i],s=o===hr?"field":o+"Field",r.push(t[s]||o);return r}}),ot.current=new ot,rt=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),this.textBox=new mi(t,i.options),i.append(this.textBox)},options:{position:wo,margin:bi(3),padding:bi(4),color:Xi,background:"",border:{width:1,color:""},aboveAxis:!0,vertical:!1,animation:{type:zn,delay:Un},zIndex:2},createVisual:function(){this.textBox.options.noclip=this.options.noclip},reflow:function(t){var e=this,i=e.options,n=i.vertical,o=i.aboveAxis,r=e.children[0],s=r.box,a=r.options.padding;r.options.align=n?on:$n,r.options.vAlign=n?or:on,i.position==Gn?n?(r.options.vAlign=or,!o&&s.height()<t.height()&&(r.options.vAlign=Ki)):r.options.align=o?Do:$n:i.position==on?(r.options.vAlign=on,r.options.align=on):i.position==jn?n?r.options.vAlign=o?Ki:or:r.options.align=o?$n:Do:i.position==wo&&(n?t=o?new ii(t.x1,t.y1-s.height(),t.x2,t.y1):new ii(t.x1,t.y2,t.x2,t.y2+s.height()):(r.options.align=on,t=o?new ii(t.x2,t.y1,t.x2+s.width(),t.y2):new ii(t.x1-s.width(),t.y1,t.x1,t.y2))),i.rotation||(n?a.left=a.right=(t.width()-r.contentBox.width())/2:a.top=a.bottom=(t.height()-r.contentBox.height())/2),r.reflow(t)},alignToClipBox:function(t){var e,i=this,n=i.options.vertical,o=n?yr:_r,r=o+"1",s=o+"2",a=i.children[0],l=i.parent.box;(l[r]<t[r]||t[s]<l[s])&&(e=a.paddingBox.clone(),e[r]=Ve.max(l[r],t[r]),e[s]=Ve.min(l[s],t[s]),this.reflow(e))}}),st=ni.extend({init:function(t){var e=this;ni.fn.init.call(e,t),e.createContainer(),e.createMarker(),e.createLabel()},createContainer:function(){var t=this;t.container=new ai({vertical:!1,wrap:!1,align:on}),t.append(t.container)},createMarker:function(){this.container.append(new pi(this.markerOptions()))},markerOptions:function(){var t=this.options,e=t.markerColor;return $e({},t.markers,{background:e,border:{color:e}})},createLabel:function(){var t=this,e=t.options,i=$e({},e.labels);t.container.append(new mi(e.text,i))},renderComplete:function(){var t,e;oi.fn.renderComplete.call(this),t=this.options.cursor||{},e=this._itemOverlay=Vi.Path.fromRect(this.container.box.toRect(),{fill:{color:vr,opacity:0},stroke:null,cursor:t.style||t}),this.appendVisual(e)},click:function(t,e){var i=this.eventArgs(e);t.trigger(Yn,i)||(e.preventDefault(),t._legendItemClick(i.seriesIndex,i.pointIndex))},hover:function(t,e){var i=this.eventArgs(e);return t.trigger(Xn,i)||(e.preventDefault(),t._legendItemHover(i.seriesIndex,i.pointIndex)),!0},leave:function(t){t._unsetActivePoint()},eventArgs:function(t){var e=this.options;return{element:xi(t),text:e.text,series:e.series,seriesIndex:e.series.index,pointIndex:e.pointIndex}},renderVisual:function(){var t=this,e=t.options,i=e.visual;i?(t.visual=i({active:e.active,series:e.series,pointIndex:e.pointIndex,options:{markers:t.markerOptions(),labels:e.labels},createVisual:function(){t.createVisual(),t.renderChildren(),t.renderComplete();var e=t.visual;return delete t.visual,e}}),this.addVisual()):oi.fn.renderVisual.call(t)}}),at=oi.extend({render:function(){var t,e,i=this.children,n=this.options,o=n.vertical;for(this.visual=new Vi.Layout(null,{spacing:o?0:n.spacing,lineSpacing:o?n.spacing:0,orientation:o?"vertical":"horizontal"}),e=0;e<i.length;e++)t=i[e],t.reflow(new ii),t.renderVisual()},reflow:function(t){this.visual.rect(t.toRect()),this.visual.reflow();var e=this.visual.clippedBBox();this.box=e?Je.rectToBox(e):new ii},renderVisual:function(){this.addVisual()},createVisual:Fe}),lt=oi.extend({init:function(t){var e=this;oi.fn.init.call(e,t),ki(e.options.position,[or,Do,Ki,$n,pn])||(e.options.position=Do),e.createContainer(),e.createItems()},options:{position:Do,items:[],labels:{margin:{left:6}},offsetX:0,offsetY:0,margin:bi(5),padding:bi(5),border:{color:Xi,width:0},item:{cursor:So},spacing:6,background:"",zIndex:1,markers:{border:{width:1},width:7,height:7,type:"rect",align:$n,vAlign:on}},createContainer:function(){var t=this,e=t.options,i=e.align,n=e.position,o=n,r=on;n==pn?o=$n:ki(n,[or,Ki])?(o="start"==i?$n:"end"==i?Do:on,r=n):i&&("start"==i?r=or:"end"==i&&(r=Ki)),t.container=new ni({margin:e.margin,padding:e.padding,background:e.background,border:e.border,vAlign:r,align:o,zIndex:e.zIndex,shrinkToFit:!0}),t.append(t.container)},createItems:function(){var t,e,i,n=this,o=n.options,r=o.items,s=r.length,a=n.isVertical();for(t=new at({vertical:a,spacing:o.spacing}),o.reverse&&(r=r.slice(0).reverse()),e=0;e<s;e++)i=r[e],t.append(new st($e({},{markers:o.markers,labels:o.labels},o.item,i)));t.render(),n.container.append(t)},isVertical:function(){var t=this,e=t.options,i=e.orientation,n=e.position,o=n==pn&&i!=Fn||(Di(i)?i!=Fn:ki(n,[$n,Do]));return o},hasItems:function(){return this.container.children[0].children.length>0},reflow:function(t){var i=this,n=i.options;return t=t.clone(),i.hasItems()?(n.position===pn?(i.containerCustomReflow(t),i.box=t):i.containerReflow(t),e):(i.box=t,e)},containerReflow:function(t){var e,i=this,n=i.options,o=n.position,r=o==or||o==Ki?_r:yr,s=t.clone(),a=i.container,l=n.width,c=n.height,h=i.isVertical(),u=t.clone();o!=$n&&o!=Do||(s.y1=u.y1=0),h&&c?(s.y2=s.y1+c,s.align(u,yr,a.options.vAlign)):!h&&l&&(s.x2=s.x1+l,s.align(u,_r,a.options.align)),a.reflow(s),s=a.box,e=s.clone(),(n.offsetX||n.offsetY)&&(s.translate(n.offsetX,n.offsetY),i.container.reflow(s)),e[r+1]=t[r+1],e[r+2]=t[r+2],i.box=e},containerCustomReflow:function(t){var e=this,i=e.options,n=i.offsetX,o=i.offsetY,r=e.container,s=i.width,a=i.height,l=e.isVertical(),c=t.clone();l&&a?c.y2=c.y1+a:!l&&s&&(c.x2=c.x1+s),r.reflow(c),c=r.box,r.reflow(ii(n,o,n+c.width(),o+c.height()))},renderVisual:function(){this.hasItems()&&oi.fn.renderVisual.call(this)}}),ct=ti.extend({init:function(t){var e=this;t=t||{},this._initFields(),this._initCategories(t),ti.fn.init.call(e,t)},_initFields:function(){this._ticks={},this.outOfRangeMin=0,this.outOfRangeMax=0},_initCategories:function(t){var e,i,n=(t.categories||[]).slice(0),o=Di(t.min),r=Di(t.max);t.categories=n,(o||r)&&n.length&&(t.srcCategories=t.categories,e=o?Ve.floor(t.min):0,i=r?t.justified?Ve.floor(t.max)+1:Ve.ceil(t.max):n.length,t.categories=t.categories.slice(e,i))},options:{type:nn,categories:[],vertical:!1,majorGridLines:{visible:!1,width:1,color:Xi},labels:{zIndex:1},justified:!1},rangeIndices:function(){var t,e=this.options,i=e.categories.length||1,n=I(e.min)?e.min%1:0;return t=I(e.max)&&e.max%1!==0&&e.max<this.totalRange().max?i-(1-e.max%1):i-(e.justified?1:0),{min:n,max:t}},totalRangeIndices:function(t){var e,i,n=this.options,o=I(n.min)?n.min:0;return e=I(n.max)?n.max:I(n.min)?o+n.categories.length:(n.srcCategories||n.categories).length-(n.justified?1:0)||1,t&&(i=this.totalRange(),o=Ei(o,0,i.max),e=Ei(e,0,i.max)),{min:o,max:e}},range:function(){var t=this.options;return{min:I(t.min)?t.min:0,max:I(t.max)?t.max:t.categories.length}},totalRange:function(){var t=this.options;return{min:0,max:Ve.max(this._seriesMax||0,(t.srcCategories||t.categories).length)-(t.justified?1:0)}},getScale:function(){var t=this.rangeIndices(),e=t.min,i=t.max,n=this.lineBox(),o=this.options.vertical?n.height():n.width(),r=o/(i-e||1);return r*(this.options.reverse?-1:1)},getTickPositions:function(t){for(var e=this,i=e.options,n=i.vertical,o=e.lineBox(),r=i.reverse,s=e.getScale(),a=e.rangeIndices(),l=a.min,c=a.max,h=l%1!==0?Ve.floor(l/1)+t:l,u=o[(n?yr:_r)+(r?2:1)],d=[];h<=c;)d.push(u+Ti(s*(h-l),un)),h+=t;return d},getLabelsTickPositions:function(){var t=this.getMajorTickPositions().slice(0),e=this.rangeIndices(),i=this.getScale(),n=this.lineBox(),o=this.options,r=o.vertical?yr:_r,s=o.reverse?2:1,a=o.reverse?1:2;return e.min%1!==0&&t.unshift(n[r+s]-i*(e.min%1)),e.max%1!==0&&t.push(n[r+a]+i*(1-e.max%1)),t},labelTickIndex:function(t){var e=t.index,i=this.rangeIndices();return i.min>0&&(e-=Ve.floor(i.min)),e},arrangeLabels:function(){ti.fn.arrangeLabels.call(this),this.hideOutOfRangeLabels()},hideOutOfRangeLabels:function(){var t=this.box,e=this.labels,i=this.options.vertical?yr:_r,n=t[i+1],o=t[i+2],r=e[0],s=Mi(e);e.length&&((r.box[i+1]>o||r.box[i+2]<n)&&(r.options.visible=!1),(s.box[i+1]>o||s.box[i+2]<n)&&(s.options.visible=!1))},getMajorTickPositions:function(){return this.getTicks().majorTicks},getMinorTickPositions:function(){return this.getTicks().minorTicks},getTicks:function(){var t,e=this,i=e._ticks,n=e.options,o=e.rangeIndices(),r=n.reverse,s=n.justified,a=e.lineBox();return t=a.getHash()+o.min+","+o.max+r+s,i._hash!==t&&(i._hash=t,i.majorTicks=e.getTickPositions(1),i.minorTicks=e.getTickPositions(.5)),i},getSlot:function(t,e,i){var n,o,r=this,s=r.options,a=s.reverse,l=s.justified,c=s.vertical?yr:_r,h=r.lineBox(),u=r.rangeIndices(),d=u.min,f=this.getScale(),p=h[c+(a?2:1)],g=h.clone(),m=!Di(e);return t=Ri(t,0),e=Ri(e,t),e=Ve.max(e-1,t),e=Ve.max(t,e),n=p+(t-d)*f,o=p+(e+1-d)*f,m&&l&&(o=n),i&&(n=Ei(n,h[c+1],h[c+2]),o=Ei(o,h[c+1],h[c+2])),g[c+1]=a?o:n,g[c+2]=a?n:o,g},slot:function(t,e,i){return"string"==typeof t&&(t=this.categoryIndex(t)),"string"==typeof e&&(e=this.categoryIndex(e)),ti.fn.slot.call(this,t,e,i)},pointCategoryIndex:function(t){var e,i,n,o=this,r=o.options,s=r.reverse,a=r.justified,l=r.vertical?yr:_r,c=o.lineBox(),h=o.rangeIndices(),u=s?h.max:h.min,d=this.getScale(),f=c[l+1],p=c[l+2],g=t[l];return g<f||g>p?null:(e=g-f,i=e/d,i=u+i,n=i%1,a?i=Ve.round(i):0===n&&i>0&&i--,Ve.floor(i))},getCategory:function(t){var e=this.pointCategoryIndex(t);return null===e?null:this.options.categories[e]},categoryIndex:function(t){var e=this.options,i=F(t,e.srcCategories||e.categories);return i-Ve.floor(e.min||0)},translateRange:function(t){var e=this,i=e.options,n=e.lineBox(),o=i.vertical?n.height():n.width(),r=i.categories.length,s=o/r,a=Ti(t/s,wn);return{min:a,max:r+a}},zoomRange:function(t){var e=this.totalRangeIndices(),i=this.totalRange(),n=i.max,o=i.min,r=Ei(e.min+t,o,n),s=Ei(e.max-t,o,n);if(s-r>0)return{min:r,max:s}},scaleRange:function(t){var e=this,i=e.options,n=i.categories.length,o=t*n;return{min:-o,max:n+o}},labelsCount:function(){var t=this.labelsRange();return t.max-t.min},labelsRange:function(){var t,e=this.options,i=e.labels,n=e.justified,o=this.totalRangeIndices(!0),r=o.min,s=o.max,a=Ve.floor(r);return n?(r=Ve.ceil(r),s=Ve.floor(s)):(r=Ve.floor(r),s=Ve.ceil(s)),t=r>i.skip?i.skip+i.step*Ve.ceil((r-i.skip)/i.step):i.skip,{min:t-a,max:(e.categories.length?s+(n?1:0):0)-a}},createAxisLabel:function(t,e){var i=this,n=i.options,o=n.dataItems?n.dataItems[t]:null,r=Ri(n.categories[t],""),s=i.axisLabelText(r,o,e);return new ei(r,s,t,o,e)},shouldRenderNote:function(t){var e=this.options.categories;return e.length&&e.length>t&&t>=0},pan:function(t){var e=this.totalRangeIndices(!0),i=this.getScale(),n=Ti(t/i,wn),o=this.totalRange(),r=e.min+n,s=e.max+n;return this.limitRange(r,s,0,o.max,n)},pointsRange:function(t,e){var i=this,n=i.options,o=n.reverse,r=n.vertical?yr:_r,s=i.lineBox(),a=i.totalRangeIndices(!0),l=this.getScale(),c=s[r+(o?2:1)],h=t[r]-c,u=e[r]-c,d=a.min+h/l,f=a.min+u/l,p=Ve.min(d,f),g=Ve.max(d,f);if(g-p>=oo)return{min:p,max:g}},valueRange:function(){return this.range()}}),ht=ct.extend({init:function(t){var e,i,n=this;t=t||{},t=$e({roundToBaseUnit:!0},t,{categories:p(t.categories),min:p(t.min),max:p(t.max)}),t.userSetBaseUnit=t.userSetBaseUnit||t.baseUnit,t.userSetBaseUnitStep=t.userSetBaseUnitStep||t.baseUnitStep,t.categories&&t.categories.length>0?(e=(t.baseUnit||"").toLowerCase(),i=e!==ji&&!ki(e,Tr),i&&(t.baseUnit=n.defaultBaseUnit(t)),e!==ji&&t.baseUnitStep!==Ui||n.autoBaseUnit(t),this._groupsStart=m(t.categories[0],0,t.baseUnit,t.weekStartDay),n.groupCategories(t)):t.baseUnit=t.baseUnit||vn,this._initFields(),ti.fn.init.call(n,t)},options:{type:mn,labels:{dateFormats:Pr},autoBaseUnitSteps:{milliseconds:[1,10,100],seconds:[1,2,5,15,30],minutes:[1,2,5,15,30],hours:[1,2,3],days:[1,2,3],weeks:[1,2],months:[1,2,3,6],years:[1,2,3,5,10,25,50]},maxDateGroups:10},shouldRenderNote:function(t){var e=this,i=e.range(),n=e.options.categories||[];return wi(t,i.min)>=0&&wi(t,i.max)<=0&&n.length},parseNoteValue:function(t){return p(t)},translateRange:function(t){var e,i,n=this,o=n.options,r=o.baseUnit,s=o.weekStartDay,a=n.lineBox(),l=o.vertical?a.height():a.width(),c=n.range(),h=l/(c.max-c.min),u=Ti(t/h,wn);return c.min&&c.max&&(e=b(o.min||c.min,u),i=b(o.max||c.max,u),c={min:m(e,0,r,s),max:m(i,0,r,s)}),c},scaleRange:function(t){var e,i=this,n=Ve.abs(t),o=i.range(),r=o.min,s=o.max;if(o.min&&o.max){for(;n--;)o=w(r,s),e=Ve.round(.1*o),t<0?(r=b(r,e),s=b(s,-e)):(r=b(r,-e),s=b(s,e));o={min:r,max:s}}return o},defaultBaseUnit:function(t){var e,i,n,o,r,s=t.categories,a=Di(s)?s.length:0,l=io;for(e=0;e<a;e++)i=s[e],i&&o&&(n=x(i,o),n>0&&(l=Ve.min(l,n),r=l>=er?wr:l>=tr-3*Zo?ao:l>=Jo?mr:l>=Zo?vn:l>=Ko?Hn:l>=Qo?so:zo)),o=i;return r||vn},_categoryRange:function(t){var e=t._range;return e||(e=t._range=Ii(t)),e},totalRange:function(){return{min:0,max:this.options.categories.length}},rangeIndices:function(){var t=this.options,e=t.baseUnit,i=t.baseUnitStep||1,n=t.categories,o=this.categoriesRange(),r=p(t.min||o.min),s=p(t.max||o.max),a=0,l=0;return n.length&&(a=C(r,n[0],e,i),l=C(s,n[0],e,i),t.roundToBaseUnit&&(a=Ve.floor(a),l=t.justified?Ve.floor(l):Ve.ceil(l))),{min:a,max:l}},labelsRange:function(){var t=this.options,e=t.labels,i=this.rangeIndices(),n=Ve.floor(i.min),o=Ve.ceil(i.max);return{min:n+e.skip,max:t.categories.length?o+(t.justified?1:0):0}},categoriesRange:function(){var t=this.options,e=this._categoryRange(t.srcCategories||t.categories),i=p(e.max);return!t.justified&&D(i,this._roundToTotalStep(i,t,!1))&&(i=this._roundToTotalStep(i,t,!0,!0)),{min:p(e.min),max:i}},currentRange:function(){var t=this.options,e=t.roundToBaseUnit!==!1,i=this.categoriesRange(),n=t.min,o=t.max;return n||(n=e?this._roundToTotalStep(i.min,t,!1):i.min),o||(o=e?this._roundToTotalStep(i.max,t,!t.justified):i.max),{min:n,max:o}},datesRange:function(){var t=this._categoryRange(this.options.srcCategories||this.options.categories);return{min:p(t.min),max:p(t.max)}},pan:function(t){var e,i,n,o=this,r=o.options,s=r.baseUnit,a=o.lineBox(),l=r.vertical?a.height():a.width(),c=this.currentRange(),h=this.totalLimits(),u=c.min,d=c.max,f=l/(d-u),m=Ti(t/f,wn);if(i=b(u,m),n=b(d,m),e=this.limitRange(g(i),g(n),g(h.min),g(h.max),m))return e.min=p(e.min),e.max=p(e.max),e.baseUnit=s,e.baseUnitStep=r.baseUnitStep||1,e.userSetBaseUnit=r.userSetBaseUnit,e.userSetBaseUnitStep=r.userSetBaseUnitStep,e},pointsRange:function(t,e){var i=ct.fn.pointsRange.call(this,t,e),n=this.currentRange(),o=this.rangeIndices(),r=w(n.max,n.min)/(o.max-o.min),s=this.options,a=b(n.min,i.min*r),l=b(n.min,i.max*r);return{min:a,max:l,baseUnit:s.userSetBaseUnit,baseUnitStep:s.userSetBaseUnitStep}},zoomRange:function(t){var e,i,n,o,r,s,a,l,c,h=this.options,u=this.totalLimits(),d=this.currentRange(),f=h.baseUnit,g=h.baseUnitStep||1,v=h.weekStartDay,_=d.max,y=d.min,x=m(y,t*g,f,v),k=m(_,-t*g,f,v);if(h.userSetBaseUnit==ji)if(e=h.autoBaseUnitSteps,i=h.maxDateGroups,n=F(f,Tr),r=w(k,x),s=Mi(e[f])*i*ir[f],a=w(_,y),r<ir[f]&&f!==Lo)f=Tr[n-1],o=Mi(e[f]),l=(a-(i-1)*o*ir[f])/2,x=b(y,l),k=b(_,-l);else if(r>s&&f!==wr){c=0;do{n++,f=Tr[n],c=0,l=2*ir[f];do o=e[f][c],c++;while(c<e[f].length&&l*o<a)}while(f!==wr&&l*o<a);l=(l*o-a)/2,l>0&&(x=b(y,-l),k=b(_,l),x=b(x,Ei(k,u.min,u.max)-k),k=b(k,Ei(x,u.min,u.max)-x))}if(x=p(Ei(x,u.min,u.max)),k=p(Ei(k,u.min,u.max)),x&&k&&w(k,x)>0)return{min:x,max:k,baseUnit:h.userSetBaseUnit,baseUnitStep:h.userSetBaseUnitStep}},totalLimits:function(){var t=this.options,e=this.datesRange(),i=this._roundToTotalStep(p(e.min),t,!1),n=e.max;return t.justified||(n=this._roundToTotalStep(n,t,!0,D(n,this._roundToTotalStep(n,t,!1)))),{min:i,max:n}},range:function(t){t=t||this.options;var e=t.categories,i=t.baseUnit===ji,n=i?Tr[0]:t.baseUnit,o=t.baseUnitStep||1,r={baseUnit:n,baseUnitStep:o,weekStartDay:t.weekStartDay},s=this._categoryRange(e),a=p(t.min||s.min),l=p(t.max||s.max);return{min:this._roundToTotalStep(a,r,!1),max:this._roundToTotalStep(l,r,!0,!0)}},autoBaseUnit:function(t){for(var e,i,n,o=this,r=this._categoryRange(t.categories),s=p(t.min||r.min),a=p(t.max||r.max),l=t.baseUnit===ji,c=0,h=l?Tr[c++]:t.baseUnit,u=a-s,d=u/ir[h],f=d,g=t.maxDateGroups||o.options.maxDateGroups,m=$e({},o.options.autoBaseUnitSteps,t.autoBaseUnitSteps);!i||d>=g;)if(e=e||m[h].slice(0),n=e.shift())i=n,d=f/i;else{if(h===Mi(Tr)){i=Ve.ceil(f/g);break}if(!l){d>g&&(i=Ve.ceil(f/g));break}h=Tr[c++]||Mi(Tr),f=u/ir[h],e=null}t.baseUnitStep=i,t.baseUnit=h},_timeScale:function(){var t,e,i,n=this,o=n.range(),r=n.options,s=n.lineBox(),a=r.vertical,l=a?s.height():s.width();return r.justified&&r._collapse!==!1?(e=this._categoryRange(r.categories),i=g(e.max),t=p(i)-o.min):t=o.max-o.min,l/t},groupCategories:function(t){var e,i,n=this,o=t.categories,r=p(zi(o)),s=t.baseUnit,a=t.baseUnitStep||1,l=n.range(t),c=l.max,h=[];for(e=l.min;e<c&&(h.push(e),i=m(e,a,s,t.weekStartDay),!(i>r)||t.max);e=i);t.srcCategories=o,t.categories=h},_roundToTotalStep:function(t,e,i,n){var o,r,s,a,l;return e=e||this.options,o=e.baseUnit,r=e.baseUnitStep||1,s=this._groupsStart,s?(a=C(t,s,o,r),l=i?Ve.ceil(a):Ve.floor(a),n&&l++,m(s,l*r,o,e.weekStartDay)):m(t,i?r:0,o,e.weekStartDay)},createAxisLabel:function(t,e){var i,n,o=this.options,r=o.dataItems?o.dataItems[t]:null,s=o.categories[t],a=o.baseUnit,l=!0,c=e.dateFormats[a];if(o.justified?(i=_(s,a,o.weekStartDay),l=D(i,s)):o.roundToBaseUnit||(l=!D(this.range().max,s)),l&&(e.format=e.format||c,n=this.axisLabelText(s,r,e)))return new ei(s,n,t,r,e)},categoryIndex:function(t){var e=this,i=e.options,n=i.categories,o=-1;return n.length&&(o=Ve.floor(C(p(t),n[0],i.baseUnit,i.baseUnitStep||1))),o},getSlot:function(t,e,i){var n=this;return typeof t===_o&&(t=n.categoryIndex(t)),typeof e===_o&&(e=n.categoryIndex(e)),ct.fn.getSlot.call(n,t,e,i)},valueRange:function(){var t=this.options,e=this._categoryRange(t.srcCategories||t.categories);return{min:p(e.min),max:p(e.max)}}}),ut=ti.extend({init:function(t,e,i){var n=this;i=i||{},$e(i,{min:p(i.min),max:p(i.max),axisCrossingValue:p(i.axisCrossingValues||i.axisCrossingValue)}),this.seriesMin=p(t),this.seriesMax=p(e),i=n.applyDefaults(this.seriesMin,this.seriesMax,i),ti.fn.init.call(n,i)},options:{type:mn,majorGridLines:{visible:!0,width:1,color:Xi},labels:{dateFormats:Pr}},applyDefaults:function(t,i,n){var o=this,r=n.min||t,s=n.max||i,a=n.baseUnit||(s&&r?o.timeUnits(x(s,r)):Hn),l=ir[a],c=_(g(r)-1,a)||p(s),h=y(g(s)+1,a),u=n.majorUnit?n.majorUnit:e,d=u||Je.ceil(Je.autoMajorUnit(c.getTime(),h.getTime()),l)/l,f=k(c,h,a),v=Je.ceil(f,d),w=v-f,b=Ve.floor(w/2),C=w-b;return n.baseUnit||delete n.baseUnit,n.baseUnit=n.baseUnit||a,n.min=n.min||m(c,-b,a),n.max=n.max||m(h,C,a),n.minorUnit=n.minorUnit||d/5,n.majorUnit=d,this.totalMin=g(_(g(t)-1,a)),this.totalMax=g(y(g(i)+1,a)),n},range:function(){var t=this.options;return{min:t.min,max:t.max}},getDivisions:function(t){var e=this.options;return Ve.floor(k(e.min,e.max,e.baseUnit)/t+1)},getTickPositions:function(t){var e,i,n,o=this.options,r=o.vertical,s=o.reverse,a=this.lineBox(),l=(r?-1:1)*(s?-1:1),c=1===l?1:2,h=a[(r?yr:_r)+c],u=this.getDivisions(t),d=w(o.max,o.min),f=r?a.height():a.width(),p=f/d,g=[h];for(e=1;e<u;e++)i=m(o.min,e*t,o.baseUnit),n=h+w(i,o.min)*p*l,g.push(Ti(n,un));return g},getMajorTickPositions:function(){var t=this;return t.getTickPositions(t.options.majorUnit)},getMinorTickPositions:function(){var t=this;return t.getTickPositions(t.options.minorUnit)},getSlot:function(t,e,i){return hi.fn.getSlot.call(this,p(t),p(e),i)},getValue:function(t){var e=hi.fn.getValue.call(this,t);return null!==e?p(e):null},labelsCount:function(){return this.getDivisions(this.options.majorUnit)},createAxisLabel:function(t,e){var i,n,o=this.options,r=t*o.majorUnit,s=o.min;return r>0&&(s=m(s,r,o.baseUnit)),i=e.dateFormats[o.baseUnit],e.format=e.format||i,n=this.axisLabelText(s,null,e),new ei(s,n,t,null,e)},timeUnits:function(t){var e=Hn;return t>=er?e=wr:t>=tr?e=ao:t>=Jo?e=mr:t>=Zo&&(e=vn),e},translateRange:function(t,e){var i=this,n=i.options,o=n.baseUnit,r=n.weekStartDay,s=i.lineBox(),a=n.vertical?s.height():s.width(),l=i.range(),c=a/w(l.max,l.min),h=Ti(t/c,wn),u=b(n.min,h),d=b(n.max,h);return e||(u=m(u,0,o,r),d=m(d,0,o,r)),{min:u,max:d}},scaleRange:function(t){for(var e,i,n=this,o=n.options,r=Ve.abs(t),s=o.min,a=o.max;r--;)e=w(s,a),i=Ve.round(.1*e),t<0?(s=b(s,i),a=b(a,-i)):(s=b(s,-i),a=b(a,i));return{min:s,max:a}},shouldRenderNote:function(t){var e=this.range();return wi(t,e.min)>=0&&wi(t,e.max)<=0},pan:function(t){var e=this.translateRange(t,!0),i=this.limitRange(g(e.min),g(e.max),this.totalMin,this.totalMax);if(i)return{min:p(i.min),max:p(i.max)}},pointsRange:function(t,e){var i=this.getValue(t),n=this.getValue(e),o=Ve.min(i,n),r=Ve.max(i,n);return{min:p(o),max:p(r)}},zoomRange:function(t){var e=this.scaleRange(t),i=p(Ei(g(e.min),this.totalMin,this.totalMax)),n=p(Ei(g(e.max),this.totalMin,this.totalMax));return{min:i,max:n}}}),dt=oi.extend({options:{vertical:!1,gap:0,spacing:0},reflow:function(t){var e,i,n=this,o=n.options,r=o.vertical,s=r?yr:_r,a=n.children,l=o.gap,c=o.spacing,h=a.length,u=h+l+c*(h-1),d=(r?t.height():t.width())/u,f=t[s+1]+d*(l/2);for(i=0;i<h;i++)e=(a[i].box||t).clone(),e[s+1]=f,e[s+2]=f+d,a[i].reflow(e),i<h-1&&(f+=d*c),f+=d}}),ft=oi.extend({options:{vertical:!0},reflow:function(t){var e,i,n,o=this.options,r=o.vertical,s=r?_r:yr,a=this.children,l=this.box=new ii,c=a.length;for(e=0;e<c;e++)i=a[e],i.visible!==!1&&(n=i.box.clone(),n.snapTo(t,s),0===e&&(l=this.box=n.clone()),i.reflow(n),l.wrap(n))}}),pt={click:function(t,e){return t.trigger(Fo,this.eventArgs(e))},hover:function(t,e){return t.trigger(No,this.eventArgs(e))},eventArgs:function(t){return{value:this.value,percentage:this.percentage,stackValue:this.stackValue,category:this.category,series:this.series,dataItem:this.dataItem,runningTotal:this.runningTotal,total:this.total,element:xi(t),originalEvent:t,point:this}}},gt={createNote:function(){var t=this,e=t.options.notes,i=t.noteText||e.label.text;e.visible!==!1&&Di(i)&&null!==i&&(t.note=new li(t.value,i,t.dataItem,t.category,t.series,t.options.notes),t.append(t.note))}},mt=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i),i.options=e,i.color=e.color||vr,i.aboveAxis=Ri(i.options.aboveAxis,!0),
i.value=t},defaults:{border:{width:1},vertical:!0,overlay:{gradient:Vn},labels:{visible:!1,format:"{0}"},opacity:1,notes:{label:{}}},render:function(){this._rendered||(this._rendered=!0,this.createLabel(),this.createNote(),this.errorBar&&this.append(this.errorBar))},createLabel:function(){var t,e,i=this.options,n=i.labels;n.visible&&(n.template?(e=Qe(n.template),t=e({dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,stackValue:this.stackValue,runningTotal:this.runningTotal,total:this.total,series:this.series})):t=this.formatValue(n.format),this.label=new rt(t,$e({vertical:i.vertical},i.labels)),this.append(this.label))},formatValue:function(t){return this.owner.formatPointValue(this,t)},reflow:function(t){var e,i,n;if(this.render(),e=this,i=e.label,e.box=t,i&&(i.options.aboveAxis=e.aboveAxis,i.reflow(t)),e.note&&e.note.reflow(t),e.errorBars)for(n=0;n<e.errorBars.length;n++)e.errorBars[n].reflow(t)},createVisual:function(){var t,e=this,i=e.box,n=e.options,o=n.visual;e.visible!==!1&&(oi.fn.createVisual.call(e),o?(t=this.rectVisual=o({category:e.category,dataItem:e.dataItem,value:e.value,sender:e.getChart(),series:e.series,percentage:e.percentage,stackValue:this.stackValue,runningTotal:e.runningTotal,total:e.total,rect:i.toRect(),createVisual:function(){var t=new Vi.Group;return e.createRect(t),t},options:n}),t&&e.visual.append(t)):i.width()>0&&i.height()>0&&e.createRect(e.visual))},createRect:function(t){var i,n,o,r,s=this.options,a=s.border,l=Di(a.opacity)?a.opacity:s.opacity,c=this.box.toRect();c.size.width=Math.round(c.size.width),i=this.rectVisual=Vi.Path.fromRect(c,{fill:{color:this.color,opacity:s.opacity},stroke:{color:this.getBorderColor(),width:a.width,opacity:l,dashType:a.dashType}}),n=this.box.width(),o=this.box.height(),r=s.vertical?n:o,r>qi&&(_i(i),(n<1||o<1)&&(i.options.stroke.lineJoin="round")),t.append(i),q(s)&&t.append(this.createGradientOverlay(i,{baseColor:this.color},$e({end:s.vertical?e:[0,1]},s.overlay)))},createHighlight:function(t){var e=Vi.Path.fromRect(this.box.toRect(),t);return _i(e)},highlightVisual:function(){return this.rectVisual},highlightVisualArgs:function(){return{options:this.options,rect:this.box.toRect(),visual:this.rectVisual}},getBorderColor:function(){var t=this,e=t.options,i=t.color,n=e.border,o=n.color,r=n._brightness||$i;return Di(o)||(o=new ri(i).brightness(r).toHex()),o},tooltipAnchor:function(t,e){var i,n,o,r,s=this,a=s.options,l=s.box,c=a.vertical,h=s.aboveAxis,u=s.owner.pane.clipBox()||l;return c?(i=Ve.min(l.x2,u.x2)+sr,n=h?Ve.max(l.y1,u.y1):Ve.min(l.y2,u.y2)-e):(o=Ve.max(l.x1,u.x1),r=Ve.min(l.x2,u.x2),a.isStacked?(i=h?r-t:o,n=Ve.max(l.y1,u.y1)-e-sr):(i=h?r+sr:o-t-sr,n=Ve.max(l.y1,u.y1))),new ui(i,n)},overlapsBox:function(t){return this.box.overlaps(t)}}),$e(mt.fn,pt),$e(mt.fn,gt),vt=Vi.Animation.extend({options:{duration:Un},setup:function(){var t,e,i=this.element,n=this.options,o=i.bbox();o?(this.origin=n.origin,t=n.vertical?yr:_r,e=this.fromScale=new Oi.Point(1,1),e[t]=Ho,i.transform(Oi.transform().scale(e.x,e.y))):this.abort()},step:function(t){var e=Ci(this.fromScale.x,1,t),i=Ci(this.fromScale.y,1,t);this.element.transform(Oi.transform().scale(e,i,this.origin))},abort:function(){Vi.Animation.fn.abort.call(this),this.element.transform(null)}}),Vi.AnimationFactory.current.register(Wi,vt),_t=Vi.Animation.extend({options:{duration:200,easing:Zn},setup:function(){this.fadeTo=this.element.opacity(),this.element.opacity(0)},step:function(t){this.element.opacity(t*this.fadeTo)}}),Vi.AnimationFactory.current.register(zn,_t),yt=function(t,e,i){var n=this;n.initGlobalRanges(t,e,i)},yt.prototype=yt.fn={percentRegex:/percent(?:\w*)\((\d+)\)/,standardDeviationRegex:RegExp("^"+Wo+"(?:\\((\\d+(?:\\.\\d+)?)\\))?$"),initGlobalRanges:function(t,e,i){var n,o,r,s,a,l=this,c=e.data,h=l.standardDeviationRegex.exec(t);h?(l.valueGetter=l.createValueGetter(e,i),n=l.getAverage(c),o=l.getStandardDeviation(c,n,!1),r=h[1]?parseFloat(h[1]):1,s={low:n.value-o*r,high:n.value+o*r},l.globalRange=function(){return s}):t.indexOf&&t.indexOf(Go)>=0&&(l.valueGetter=l.createValueGetter(e,i),a=l.getStandardError(c,l.getAverage(c)),l.globalRange=function(t){return{low:t-a,high:t+a}})},createValueGetter:function(t,e){var i,n,o,r=t.data,s=ot.current,a=s.valueFields(t),l=Di(r[0])?r[0]:{};return Le(l)?(i=e?F(e,a):0,o=Ye("["+i+"]")):I(l)?o=Ye():typeof l===_o&&(n=s.sourceFields(t,a),o=Ye(n[F(e,a)])),o},getErrorRange:function(t,e){var i,n,o,r,s=this;if(Di(e)){if(s.globalRange)return s.globalRange(t);if(Le(e))i=t-e[0],n=t+e[1];else if(I(o=parseFloat(e)))i=t-o,n=t+o;else{if(!(o=s.percentRegex.exec(e)))throw Error("Invalid ErrorBar value: "+e);r=t*(parseFloat(o[1])/100),i=t-Ve.abs(r),n=t+Ve.abs(r)}return{low:i,high:n}}},getStandardError:function(t,e){return this.getStandardDeviation(t,e,!0)/Ve.sqrt(e.count)},getStandardDeviation:function(t,e,i){var n,o,r=0,s=t.length,a=i?e.count-1:e.count;for(o=0;o<s;o++)n=this.valueGetter(t[o]),I(n)&&(r+=Ve.pow(n-e.value,2));return Ve.sqrt(r/a)},getAverage:function(t){var e,i,n=0,o=0,r=t.length;for(i=0;i<r;i++)e=this.valueGetter(t[i]),I(e)&&(n+=e,o++);return{value:n/o,count:o}}},wt=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.plotArea=t,i.categoryAxis=t.seriesCategoryAxis(e.series[0]),i.valueAxisRanges={},i.points=[],i.categoryPoints=[],i.seriesPoints=[],i.seriesOptions=[],i._evalSeries=[],i.render()},options:{series:[],invertAxes:!1,isStacked:!1,clip:!0},render:function(){var t=this;t.traverseDataPoints(He(t.addValue,t))},pointOptions:function(t,e){var i,n=this.seriesOptions[e];return n||(i=this.pointType().fn.defaults,this.seriesOptions[e]=n=$e({},i,{vertical:!this.options.invertAxes},t)),n},plotValue:function(t){var e,i,n,o,r,s,a,l;if(!t)return 0;if(this.options.isStacked100&&I(t.value)){for(e=t.categoryIx,i=this.categoryPoints[e],n=0,o=[],r=0;r<i.length;r++)if(s=i[r]){if(a=t.series.stack,l=s.series.stack,a&&l&&a.group!==l.group)continue;I(s.value)&&(n+=Ve.abs(s.value),o.push(Ve.abs(s.value)))}if(n>0)return t.value/n}return t.value},plotRange:function(t,e){var i,n,o,r,s,a,l,c,h,u,d,f,p=t.categoryIx,g=this.categoryPoints[p];if(this.options.isStacked){for(e=e||0,i=this.plotValue(t),n=i>=0,o=e,r=!1,s=0;s<g.length&&(a=g[s],t!==a);s++){if(l=t.series.stack,c=a.series.stack,l&&c){if(typeof l===qo&&l!==c)continue;if(l.group&&l.group!==c.group)continue}h=this.plotValue(a),(h>=0&&n||h<0&&!n)&&(o+=h,i+=h,r=!0,this.options.isStacked100&&(i=Ve.min(i,1)))}return r&&(o-=e),[o,i]}return u=t.series,d=this.seriesValueAxis(u),f=this.categoryAxisCrossingValue(d),[f,t.value||f]},stackLimits:function(t,e){var i,n,o,r,s,a=io,l=ro;for(i=0;i<this.categoryPoints.length;i++)if(n=this.categoryPoints[i])for(o=0;o<n.length;o++)r=n[o],r&&(r.series.stack!==e&&r.series.axis!==t||(s=this.plotRange(r,0)[1],Di(s)&&isFinite(s)&&(l=Ve.max(l,s),a=Ve.min(a,s))));return{min:a,max:l}},updateStackRange:function(){var t,e,i,n,o,r,s=this,a=s.options.series,l=s.options.isStacked,c={};if(l)for(e=0;e<a.length;e++)i=a[e],n=i.axis,o=n+i.stack,t=c[o],t||(t=s.stackLimits(n,i.stack),r=s.errorTotals,r&&(r.negative.length&&(t.min=Ve.min(t.min,Bi(r.negative))),r.positive.length&&(t.max=Ve.max(t.max,zi(r.positive)))),t.min!==io||t.max!==ro?c[o]=t:t=null),t&&(s.valueAxisRanges[n]=t)},addErrorBar:function(t,e,i){var n,o=this,r=t.value,s=t.series,a=t.seriesIx,l=t.options.errorBars,c=e.fields[Pn],h=e.fields[Dn];I(c)&&I(h)?n={low:c,high:h}:l&&Di(l.value)&&(o.seriesErrorRanges=o.seriesErrorRanges||[],o.seriesErrorRanges[a]=o.seriesErrorRanges[a]||new yt(l.value,s,hr),n=o.seriesErrorRanges[a].getErrorRange(r,l.value)),n&&(t.low=n.low,t.high=n.high,o.addPointErrorBar(t,i))},addPointErrorBar:function(t,e){var i,n,o,r=this,s=t.series,a=t.low,l=t.high,c=!r.options.invertAxes,h=t.options.errorBars;r.options.isStacked?(n=r.stackedErrorRange(t,e),a=n.low,l=n.high):(o={categoryIx:e,series:s},r.updateRange({value:a},o),r.updateRange({value:l},o)),i=new Pt(a,l,c,r,s,h),t.errorBars=[i],t.append(i)},stackedErrorRange:function(t,e){var i=this,n=i.plotRange(t,0)[1]-t.value,o=t.low+n,r=t.high+n;return i.errorTotals=i.errorTotals||{positive:[],negative:[]},o<0&&(i.errorTotals.negative[e]=Ve.min(i.errorTotals.negative[e]||0,o)),r>0&&(i.errorTotals.positive[e]=Ve.max(i.errorTotals.positive[e]||0,r)),{low:o,high:r}},addValue:function(e,i){var n,o,r=this,s=i.categoryIx,a=i.series,l=i.seriesIx,c=r.categoryPoints[s];c||(r.categoryPoints[s]=c=[]),n=r.seriesPoints[l],n||(r.seriesPoints[l]=n=[]),o=r.createPoint(e,i),o&&(t.extend(o,i),o.owner=r,o.dataItem=a.data[s],o.noteText=e.fields.noteText,r.addErrorBar(o,e,s)),r.points.push(o),n.push(o),c.push(o),r.updateRange(e.valueFields,i)},evalPointOptions:function(t,e,i,n,o,r){var s={defaults:o._defaults,excluded:["data","aggregate","_events","tooltip","template","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint"]},a=this._evalSeries[r];return Di(a)||(this._evalSeries[r]=a=R(t,{},s,!0)),a&&(t=$e({},t),R(t,{value:e,category:i,index:n,series:o,dataItem:o.data[n]},s)),t},updateRange:function(t,e){var i=this,n=e.series.axis,o=t.value,r=i.valueAxisRanges[n];isFinite(o)&&null!==o&&(r=i.valueAxisRanges[n]=r||{min:io,max:ro},r.min=Ve.min(r.min,o),r.max=Ve.max(r.max,o))},seriesValueAxis:function(t){var e=this.plotArea,i=t.axis,n=i?e.namedValueAxes[i]:e.valueAxis;if(!n)throw Error("Unable to locate value axis with name "+i);return n},reflow:function(t){var e,i,n,o=this,r=0,s=o.categorySlots=[],a=o.points,l=o.categoryAxis;o.traverseDataPoints(function(t,c){var h,u,d,f,p=c.categoryIx,g=c.series;e=o.pointValue(t),i=o.seriesValueAxis(g),n=a[r++],h=s[p],h||(s[p]=h=o.categorySlot(l,p,i)),n&&(u=o.plotRange(n,i.startValue()),d=i.getSlot(u[0],u[1],!o.options.clip),d?(f=o.pointSlot(h,d),n.aboveAxis=o.aboveAxis(n,i),n.stackValue=u[1],o.options.isStacked100&&(n.percentage=o.plotValue(n)),o.reflowPoint(n,f)):n.visible=!1)}),o.reflowCategories(s),o.box=t},aboveAxis:function(t,e){var i=this.categoryAxisCrossingValue(e),n=t.value;return e.options.reverse?n<i:n>=i},categoryAxisCrossingValue:function(t){var e=this.categoryAxis,i=t.options,n=[].concat(i.axisCrossingValues||i.axisCrossingValue);return n[e.axisIndex||0]||0},reflowPoint:function(t,e){t.reflow(e)},reflowCategories:function(){},pointSlot:function(t,e){var i=this,n=i.options,o=n.invertAxes,r=o?e:t,s=o?t:e;return new ii(r.x1,s.y1,r.x2,s.y2)},categorySlot:function(t,e){return t.getSlot(e)},traverseDataPoints:function(t){var e,i,n,o,r,s=this,a=s.options,l=a.series,c=s.categoryAxis.options.categories||[],u=h(l),d=l.length;for(i=0;i<d;i++)this._outOfRangeCallback(l[i],"_outOfRangeMinPoint",i,t);for(e=0;e<u;e++)for(i=0;i<d;i++)r=l[i],o=c[e],n=this._bindPoint(r,i,e),t(n,{category:o,categoryIx:e,series:r,seriesIx:i});for(i=0;i<d;i++)this._outOfRangeCallback(l[i],"_outOfRangeMaxPoint",i,t)},_outOfRangeCallback:function(t,e,i,n){var o,r,s=t[e];s&&(o=s.categoryIx,r=this._bindPoint(t,i,o,s.item),n(r,{category:s.category,categoryIx:o,series:t,seriesIx:i}))},_bindPoint:function(t,e,i,n){var o,r;return this._bindCache||(this._bindCache=[]),o=this._bindCache[e],o||(o=this._bindCache[e]=[]),r=o[i],r||(r=o[i]=ot.current.bindPoint(t,i,n)),r},formatPointValue:function(t,e){return null===t.value?"":yi(e,t.value)},pointValue:function(t){return t.valueFields.value}}),xt=wt.extend({options:{animation:{type:Wi}},render:function(){var t=this;wt.fn.render.apply(t),t.updateStackRange()},pointType:function(){return mt},clusterType:function(){return dt},stackType:function(){return ft},stackLimits:function(t,e){var i=wt.fn.stackLimits.call(this,t,e);return i},createPoint:function(t,e){var i,n,o,r,s=this,a=e.categoryIx,l=e.category,c=e.series,h=e.seriesIx,u=s.pointValue(t),d=s.options,f=s.children,p=s.options.isStacked,g=s.pointType(),m=s.clusterType(),v=this.pointOptions(c,h),_=v.labels;return p&&_.position==wo&&(_.position=Gn),v.isStacked=p,o=t.fields.color||c.color,u<0&&v.negativeColor&&(o=v.negativeColor),v=s.evalPointOptions(v,u,l,a,c,h),Ue.isFunction(c.color)&&(o=v.color),i=new g(u,v),i.color=o,n=f[a],n||(n=new m({vertical:d.invertAxes,gap:d.gap,spacing:d.spacing}),s.append(n)),p?(r=s.getStackWrap(c,n),r.append(i)):n.append(i),i},getStackWrap:function(t,e){var i,n,o,r=t.stack,s=r?r.group||r:r,a=e.children;if(typeof s===qo){for(n=0;n<a.length;n++)if(a[n]._stackGroup===s){i=a[n];break}}else i=a[0];return i||(o=this.stackType(),i=new o({vertical:!this.options.invertAxes}),i._stackGroup=s,e.append(i)),i},categorySlot:function(t,e,i){var n,o,r=this,s=r.options,a=t.getSlot(e),l=i.startValue();return s.isStacked&&(o=i.getSlot(l,l,!0),n=s.invertAxes?_r:yr,a[n+1]=a[n+2]=o[n+1]),a},reflowCategories:function(t){var e,i=this,n=i.children,o=n.length;for(e=0;e<o;e++)n[e].reflow(t[e])},createAnimation:function(){this._setAnimationOptions(),oi.fn.createAnimation.call(this),$(this.options.series)&&this._setChildrenAnimation()},_setChildrenAnimation:function(){var t,e,i,n=this.points;for(i=0;i<n.length;i++)t=n[i],e=t.visual,e&&Di(e.options.zIndex)&&(t.options.animation=this.options.animation,t.createAnimation())},_setAnimationOptions:function(){var t,e,i=this.options,n=i.animation||{};this.options.isStacked?(e=this.seriesValueAxis(i.series[0]),t=e.getSlot(e.startValue())):t=this.categoryAxis.getSlot(0),n.origin=new Oi.Point(t.x1,t.y1),n.vertical=!i.invertAxes}}),bt=mt.extend({defaults:{labels:{format:"{0} - {1}"},tooltip:{format:"{1}"}},createLabel:function(){var t=this.options.labels,e=$e({},t,t.from),i=$e({},t,t.to);e.visible&&(this.labelFrom=this._createLabel(e),this.append(this.labelFrom)),i.visible&&(this.labelTo=this._createLabel(i),this.append(this.labelTo))},_createLabel:function(t){var e,i;return t.template?(i=Qe(t.template),e=i({dataItem:this.dataItem,category:this.category,value:this.value,percentage:this.percentage,runningTotal:this.runningTotal,total:this.total,series:this.series})):e=this.formatValue(t.format),new rt(e,$e({vertical:this.options.vertical},t))},reflow:function(t){this.render();var e=this,i=e.labelFrom,n=e.labelTo;e.box=t,i&&(i.options.aboveAxis=e.value.from>e.value.to,i.reflow(t)),n&&(n.options.aboveAxis=e.value.to>e.value.from,n.reflow(t)),e.note&&e.note.reflow(t)}}),kt=xt.extend({pointType:function(){return bt},pointValue:function(t){return t.valueFields},formatPointValue:function(t,e){return null===t.value.from&&null===t.value.to?"":yi(e,t.value.from,t.value.to)},plotLimits:wt.fn.plotLimits,plotRange:function(t){return t?[t.value.from,t.value.to]:0},updateRange:function(t,e){var i=this,n=e.series.axis,o=t.from,r=t.to,s=i.valueAxisRanges[n];null!==t&&I(o)&&I(r)&&(s=i.valueAxisRanges[n]=s||{min:io,max:ro},s.min=Ve.min(s.min,o),s.max=Ve.max(s.max,o),s.min=Ve.min(s.min,r),s.max=Ve.max(s.max,r))},aboveAxis:function(t){var e=t.value;return e.from<e.to}}),Ct=wt.extend({init:function(t,e){var i=this;i.wrapData(e),wt.fn.init.call(i,t,e)},options:{animation:{type:Wi}},wrapData:function(t){var e,i,n,o=t.series;for(e=0;e<o.length;e++)n=o[e],i=n.data,i&&!Le(i[0])&&typeof i[0]!=_o&&(n.data=[i])},reflowCategories:function(t){var e,i=this,n=i.children,o=n.length;for(e=0;e<o;e++)n[e].reflow(t[e])},plotRange:function(t){var e=t.series,i=this.seriesValueAxis(e),n=this.categoryAxisCrossingValue(i);return[n,t.value.current||n]},createPoint:function(t,e){var i,n,o=this,r=e.categoryIx,s=e.category,a=e.series,l=e.seriesIx,c=t.valueFields,h=o.options,u=o.children,d=$e({vertical:!h.invertAxes,overlay:a.overlay,categoryIx:r,invertAxes:h.invertAxes},a),f=t.fields.color||a.color;return d=o.evalPointOptions(d,c,s,r,a,l),Ue.isFunction(a.color)&&(f=d.color),i=new St(c,d),i.color=f,n=u[r],n||(n=new dt({vertical:h.invertAxes,gap:h.gap,spacing:h.spacing}),o.append(n)),n.append(i),i},updateRange:function(t,e){var i=this,n=e.series.axis,o=t.current,r=t.target,s=i.valueAxisRanges[n];Di(o)&&!isNaN(o)&&Di(r&&!isNaN(r))&&(s=i.valueAxisRanges[n]=s||{min:io,max:ro},s.min=Ve.min.apply(Ve,[s.min,o,r]),s.max=Ve.max.apply(Ve,[s.max,o,r]))},formatPointValue:function(t,e){return yi(e,t.value.current,t.value.target)},pointValue:function(t){return t.valueFields.current},aboveAxis:function(t){var e=t.value.current;return e>0},createAnimation:function(){var t,e,i=this.points;for(this._setAnimationOptions(),e=0;e<i.length;e++)t=i[e],t.options.animation=this.options.animation,t.createAnimation()},_setAnimationOptions:xt.fn._setAnimationOptions}),St=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.aboveAxis=i.options.aboveAxis,i.color=e.color||vr,i.value=t},options:{border:{width:1},vertical:!1,opacity:1,target:{shape:"",border:{width:0,color:"green"},line:{width:2}},tooltip:{format:"Current: {0}</br>Target: {1}"}},render:function(){var t=this,e=t.options;t._rendered||(t._rendered=!0,Di(t.value.target)&&(t.target=new Tt({type:e.target.shape,background:e.target.color||t.color,opacity:e.opacity,zIndex:e.zIndex,border:e.target.border,vAlign:or,align:Do}),t.target.value=this.value,t.target.dataItem=this.dataItem,t.target.series=this.series,t.append(t.target)),t.createNote())},reflow:function(t){this.render();var e,i=this,n=i.options,o=i.owner,r=i.target,s=n.invertAxes,a=o.seriesValueAxis(i.options),l=o.categorySlot(o.categoryAxis,n.categoryIx,a),c=a.getSlot(i.value.target),h=s?c:l,u=s?l:c;r&&(e=new ii(h.x1,u.y1,h.x2,u.y2),r.options.height=s?e.height():n.target.line.width,r.options.width=s?n.target.line.width:e.width(),r.reflow(e)),i.note&&i.note.reflow(t),i.box=t},createVisual:function(){var t,e;oi.fn.createVisual.call(this),t=this.options,e=Vi.Path.fromRect(this.box.toRect(),{fill:{color:this.color,opacity:t.opacity},stroke:null}),t.border.width>0&&e.options.set("stroke",{color:t.border.color||this.color,width:t.border.width,dashType:t.border.dashType,opacity:Ri(t.border.opacity,t.opacity)}),this.bodyVisual=e,_i(e),this.visual.append(e)},createAnimation:function(){this.bodyVisual&&(this.animation=Vi.Animation.create(this.bodyVisual,this.options.animation))},tooltipAnchor:mt.fn.tooltipAnchor,createHighlight:function(t){return Vi.Path.fromRect(this.box.toRect(),t)},highlightVisual:function(){return this.bodyVisual},highlightVisualArgs:function(){return{rect:this.box.toRect(),visual:this.bodyVisual,options:this.options}},formatValue:function(t){var e=this;return e.owner.formatPointValue(e,t)}}),$e(St.fn,pt),$e(St.fn,gt),Tt=pi.extend(),$e(Tt.fn,pt),At=oi.extend({init:function(t,e,i,n,o,r){var s=this;s.low=t,s.high=e,s.isVertical=i,s.chart=n,s.series=o,oi.fn.init.call(s,r)},options:{animation:{type:zn,delay:Un},endCaps:!0,line:{width:1},zIndex:1},getAxis:function(){},reflow:function(t){var e,i=this,n=i.options.endCaps,o=i.isVertical,r=i.getAxis(),s=r.getSlot(i.low,i.high),a=t.center(),l=i.getCapsWidth(t,o),c=o?a.x:a.y,h=c-l,u=c+l;o?(e=[ui(a.x,s.y1),ui(a.x,s.y2)],n&&e.push(ui(h,s.y1),ui(u,s.y1),ui(h,s.y2),ui(u,s.y2)),i.box=ii(h,s.y1,u,s.y2)):(e=[ui(s.x1,a.y),ui(s.x2,a.y)],n&&e.push(ui(s.x1,h),ui(s.x1,u),ui(s.x2,h),ui(s.x2,u)),i.box=ii(s.x1,h,s.x2,u)),i.linePoints=e},getCapsWidth:function(t,e){var i=e?t.width():t.height(),n=Ve.min(Ve.floor(i/2),bn)||bn;return n},createVisual:function(){var t=this,e=t.options,i=e.visual;i?t.visual=i({low:t.low,high:t.high,rect:t.box.toRect(),sender:t.getChart(),options:{endCaps:e.endCaps,color:e.color,line:e.line},createVisual:function(){t.createDefaultVisual();var e=t.visual;return delete t.visual,e}}):t.createDefaultVisual()},createDefaultVisual:function(){var t,e,i=this,n=i.options,o={stroke:{color:n.color,width:n.line.width,dashType:n.line.dashType}},r=i.linePoints;for(oi.fn.createVisual.call(this),t=0;t<r.length;t+=2)e=new Vi.Path(o).moveTo(r[t].x,r[t].y).lineTo(r[t+1].x,r[t+1].y),this.visual.append(e)}}),Pt=At.extend({getAxis:function(){var t=this,e=t.chart,i=t.series,n=e.seriesValueAxis(i);return n}}),Dt=At.extend({getAxis:function(){var t=this,e=t.chart,i=t.series,n=e.seriesAxes(i),o=t.isVertical?n.y:n.x;return o}}),Mt=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i),i.value=t,i.options=e,i.aboveAxis=Ri(i.options.aboveAxis,!0),i.tooltipTracking=!0},defaults:{vertical:!0,markers:{visible:!0,background:vr,size:Kn,type:sn,border:{width:2},opacity:1},labels:{visible:!1,position:Ni,margin:bi(3),padding:bi(4),animation:{type:zn,delay:Un}},notes:{label:{}},highlight:{markers:{border:{}}}},render:function(){var t,e=this,i=e.options,n=i.markers,o=i.labels,r=e.value;e._rendered||(e._rendered=!0,n.visible&&n.size&&(e.marker=e.createMarker(),e.append(e.marker)),o.visible&&(o.template?(t=Qe(o.template),r=t({dataItem:e.dataItem,category:e.category,value:e.value,percentage:e.percentage,stackValue:this.stackValue,series:e.series})):o.format&&(r=e.formatValue(o.format)),e.label=new mi(r,$e({align:on,vAlign:on,margin:{left:5,right:5},zIndex:Ri(o.zIndex,this.series.zIndex)},o)),e.append(e.label)),e.createNote(),e.errorBar&&e.append(e.errorBar))},markerBorder:function(){var t=this.options.markers,e=t.background,i=$e({color:this.color},t.border);return Di(i.color)||(i.color=new ri(e).brightness($i).toHex()),i},createVisual:Fe,createMarker:function(){var t=this.options.markers,e=new pi({type:t.type,width:t.size,height:t.size,rotation:t.rotation,background:t.background,border:this.markerBorder(),opacity:t.opacity,zIndex:Ri(t.zIndex,this.series.zIndex),animation:t.animation,visual:t.visual},{dataItem:this.dataItem,value:this.value,series:this.series,category:this.category});return e},markerBox:function(){return this.marker||(this.marker=this.createMarker(),this.marker.reflow(this._childBox)),this.marker.box},reflow:function(t){var e,i,n,o,r=this,s=r.options,a=s.vertical,l=r.aboveAxis;if(r.render(),r.box=t,e=t.clone(),a?l?e.y1-=e.height():e.y2+=e.height():l?e.x1+=e.width():e.x2-=e.width(),r._childBox=e,r.marker&&r.marker.reflow(e),r.reflowLabel(e),r.errorBars)for(n=0;n<r.errorBars.length;n++)r.errorBars[n].reflow(e);r.note&&(o=r.markerBox(),s.markers.visible&&s.markers.size||(i=o.center(),o=ii(i.x,i.y,i.x,i.y)),r.note.reflow(o))},reflowLabel:function(t){var e=this,i=e.options,n=e.label,o=i.labels.position;n&&(o=o===Ni?or:o,o=o===Yi?Ki:o,n.reflow(t),n.box.alignTo(e.markerBox(),o),n.reflow(n.box))},createHighlight:function(){var t=this.options.highlight,e=t.markers,i=this.markerBorder().color,n=this.options.markers,o=new pi({type:n.type,width:n.size,height:n.size,rotation:n.rotation,background:e.color||i,border:{color:e.border.color,width:e.border.width,opacity:Ri(e.border.opacity,1)},opacity:Ri(e.opacity,1)});return o.reflow(this._childBox),o.getElement()},highlightVisual:function(){return(this.marker||{}).visual},highlightVisualArgs:function(){var t,e,i,n,o,r=this.marker;return r?(e=r.paddingBox.toRect(),t=r.visual):(i=this.options.markers.size,n=i/2,o=this.box.center(),e=new Oi.Rect([o.x-n,o.y-n],[i,i])),{options:this.options,rect:e,visual:t}},tooltipAnchor:function(t,e){var i=this,n=i.markerBox(),o=i.aboveAxis,r=n.x2+sr,s=o?n.y1-e:n.y2,a=i.owner.pane.clipBox(),l=!a||a.overlaps(n);if(l)return ui(r,s)},formatValue:function(t){var e=this;return e.owner.formatPointValue(e,t)},overlapsBox:function(t){var e=this.markerBox();return e.overlaps(t)}}),$e(Mt.fn,pt),$e(Mt.fn,gt),Et=Mt.extend({init:function(t,e){var i=this;Mt.fn.init.call(i,t,e),i.category=t.category},defaults:{labels:{position:on},highlight:{opacity:1,border:{width:1,opacity:1}}},createHighlight:function(){var t=this.options.highlight,e=t.border,i=this.options.markers,n=this.box.center(),o=i.size/2-e.width/2,r=new Vi.Circle(new Oi.Circle([n.x,n.y],o),{stroke:{color:e.color||new ri(i.background).brightness($i).toHex(),width:e.width,opacity:e.opacity},fill:{color:i.background,opacity:t.opacity}});return r}}),It=oi.extend({init:function(t,e,i){var n=this;oi.fn.init.call(n),n.linePoints=t,n.series=e,n.seriesIx=i},options:{closed:!1},points:function(t){var e,i,n=this,o=n.linePoints.concat(t||[]),r=[];for(e=0,i=o.length;e<i;e++)o[e].visible!==!1&&r.push(o[e]._childBox.toRect().center());return r},createVisual:function(){var t,e=this.options,i=this.series,n=i._defaults,o=i.color;Xe(o)&&n&&(o=n.color),t=Vi.Path.fromPoints(this.points(),{stroke:{color:o,width:i.width,opacity:i.opacity,dashType:i.dashType},zIndex:i.zIndex}),e.closed&&t.close(),this.visual=t},aliasFor:function(t,e){var i=this,n=i.seriesIx;return i.parent.getNearestPoint(e.x,e.y,n)}}),Bt={renderSegments:function(){var t,e,i,n,o,r,s,a,l=this,c=l.options,h=c.series,u=l.seriesPoints,d=u.length;for(this._segments=[],e=0;e<d;e++){for(t=h[e],i=l.sortPoints(u[e]),s=i.length,n=[],r=0;r<s;r++)o=i[r],o?n.push(o):l.seriesMissingValues(t)!==Wn&&(n.length>1&&(a=l.createSegment(n,t,e,a),this._addSegment(a)),n=[]);n.length>1&&(a=l.createSegment(n,t,e,a),this._addSegment(a))}this.children.unshift.apply(this.children,this._segments)},_addSegment:function(t){this._segments.push(t),t.parent=this},sortPoints:function(t){return t},seriesMissingValues:function(t){var e=t.missingValues,i=!e&&this.options.isStacked;return i?xr:e||Wn},getNearestPoint:function(t,e,i){var n,o,r,s,a,l=new ui(t,e),c=this.seriesPoints[i],h=io;for(o=0;o<c.length;o++)r=c[o],r&&Di(r.value)&&null!==r.value&&r.visible!==!1&&(s=r.box,a=s.center().distanceTo(l),a<h&&(n=r,h=a));return n}},zt={createAnimation:function(){var t,e,i=this.getRoot();i&&(i.options||{}).transitions!==!1&&(t=i.box,e=Vi.Path.fromRect(t.toRect()),this.visual.clip(e),this.animation=new Rt(e,{box:t}),$(this.options.series)&&this._setChildrenAnimation(e))},_setChildrenAnimation:function(t){var e,i,n=this.animationPoints();for(i=0;i<n.length;i++)e=n[i],e&&e.visual&&Di(e.visual.options.zIndex)&&e.visual.clip(t)}},Lt=wt.extend({render:function(){var t=this;wt.fn.render.apply(t),t.updateStackRange(),t.renderSegments()},pointType:function(){return Mt},createPoint:function(t,e){var i,n,o,r=this,s=e.categoryIx,a=e.category,l=e.series,c=e.seriesIx,h=t.valueFields.value,u=r.seriesMissingValues(l);if(!Di(h)||null===h){if(u!==xr)return null;h=0}return n=this.pointOptions(l,c),n=r.evalPointOptions(n,h,a,s,l,c),o=t.fields.color||l.color,Ue.isFunction(l.color)&&(o=n.color),i=new Mt(h,n),i.color=o,r.append(i),i},plotRange:function(t){var e,i,n,o,r=this.plotValue(t);if(this.options.isStacked)for(e=t.categoryIx,i=this.categoryPoints[e],n=0;n<i.length&&(o=i[n],t!==o);n++)r+=this.plotValue(o),this.options.isStacked100&&(r=Ve.min(r,1));return[r,r]},createSegment:function(t,e,i){var n,o=e.style;return new(n=o===Uo?Ot:o===jo?Vt:It)(t,e,i)},animationPoints:function(){var t,e=this.points,i=[];for(t=0;t<e.length;t++)i.push((e[t]||{}).marker);return i.concat(this._segments)}}),$e(Lt.fn,Bt,zt),Rt=Vi.Animation.extend({options:{duration:Un},setup:function(){this._setEnd(this.options.box.x1)},step:function(t){var e=this.options.box;this._setEnd(Ci(e.x1,e.x2,t))},_setEnd:function(t){var e=this.element,i=e.segments,n=i[1].anchor(),o=i[2].anchor();e.suspend(),n.setX(t),e.resume(),o.setX(t)}}),Vi.AnimationFactory.current.register(ln,Rt),Ot=It.extend({points:function(t){var e,i=this;return e=i.calculateStepPoints(i.linePoints),t&&t.length&&(e=e.concat(i.calculateStepPoints(t).reverse())),e},calculateStepPoints:function(t){var e,i,n,o,r,s=this,a=s.parent,l=a.plotArea,c=l.seriesCategoryAxis(s.series),h=a.seriesMissingValues(s.series)===Wn,u=t.length,d=c.options.reverse,f=c.options.vertical,p=d?2:1,g=d?1:2,m=[];for(n=1;n<u;n++)e=t[n-1],i=t[n],o=e.markerBox().center(),r=i.markerBox().center(),c.options.justified?(m.push(new Oi.Point(o.x,o.y)),m.push(f?new Oi.Point(o.x,r.y):new Oi.Point(r.x,o.y)),m.push(new Oi.Point(r.x,r.y))):f?(m.push(new Oi.Point(o.x,e.box[yr+p])),m.push(new Oi.Point(o.x,e.box[yr+g])),h&&m.push(new Oi.Point(o.x,i.box[yr+p])),m.push(new Oi.Point(r.x,i.box[yr+p])),m.push(new Oi.Point(r.x,i.box[yr+g]))):(m.push(new Oi.Point(e.box[_r+p],o.y)),m.push(new Oi.Point(e.box[_r+g],o.y)),h&&m.push(new Oi.Point(i.box[_r+p],o.y)),m.push(new Oi.Point(i.box[_r+p],r.y)),m.push(new Oi.Point(i.box[_r+g],r.y)));return m||[]}}),Vt=It.extend({createVisual:function(){var t,e,i,n=this.series,o=n._defaults,r=n.color;Xe(r)&&o&&(r=o.color),t=new si(this.options.closed),e=t.process(this.points()),i=new Vi.Path({stroke:{color:r,width:n.width,opacity:n.opacity,dashType:n.dashType},zIndex:n.zIndex}),i.segments.push.apply(i.segments,e),this.visual=i}}),Ft={points:function(){var t,e,i=this,n=i.parent,o=n.plotArea,r=n.options.invertAxes,s=n.seriesValueAxis(i.series),a=s.lineBox(),l=o.seriesCategoryAxis(i.series),c=l.lineBox(),h=r?c.x1:c.y1,u=i.stackPoints,d=i._linePoints(u),f=r?_r:yr;return h=Ei(h,a[f+1],a[f+2]),!i.stackPoints&&d.length>1&&(t=d[0],e=Mi(d),r?(d.unshift(new Oi.Point(h,t.y)),d.push(new Oi.Point(h,e.y))):(d.unshift(new Oi.Point(t.x,h)),d.push(new Oi.Point(e.x,h)))),d},createVisual:function(){var t=this.series,e=t._defaults,i=t.color;Xe(i)&&e&&(i=e.color),this.visual=new Vi.Group({zIndex:t.zIndex}),this.createArea(i),this.createLine(i)},createLine:function(t){var e,i=this.series,n=$e({color:t,opacity:i.opacity},i.line);n.visible!==!1&&n.width>0&&(e=Vi.Path.fromPoints(this._linePoints(),{stroke:{color:n.color,width:n.width,opacity:n.opacity,dashType:n.dashType,lineCap:"butt"}}),this.visual.append(e))},createArea:function(t){var e=this.series,i=Vi.Path.fromPoints(this.points(),{fill:{color:t,opacity:e.opacity},stroke:null});this.visual.append(i)}},Nt=It.extend({init:function(t,e,i,n){var o=this;o.stackPoints=e,It.fn.init.call(o,t,i,n)},_linePoints:It.fn.points}),$e(Nt.fn,Ft),Ht=Lt.extend({createSegment:function(t,e,i,n){var o,r,s,a=this,l=a.options,c=l.isStacked,h=(e.line||{}).style;return c&&i>0&&n&&(s=this.seriesMissingValues(e),o="gap"!=s?n.linePoints:this._gapStackPoints(t,i,h),h!==Uo&&(o=o.slice(0).reverse())),h===jo?new Ut(t,n,c,e,i):new(r=h===Uo?jt:Nt)(t,o,e,i)},reflow:function(t){var e,i,n,o;if(Lt.fn.reflow.call(this,t),e=this._stackPoints)for(o=0;o<e.length;o++)i=e[o],n=this.categoryAxis.getSlot(i.categoryIx),i.reflow(n)},_gapStackPoints:function(t,e,i){var n,o,r,s,a=this.seriesPoints,l=t[0].categoryIx,c=l+t.length,h=[];for(this._stackPoints=this._stackPoints||[],s=l;s<c;s++){n=e;do n--,o=a[n][s];while(n>0&&!o);o?(i!==Uo&&s>l&&!a[n][s-1]&&h.push(this._previousSegmentPoint(s,s-1,n)),h.push(o),i!==Uo&&s+1<c&&!a[n][s+1]&&h.push(this._previousSegmentPoint(s,s+1,n))):(r=this._createGapStackPoint(s),this._stackPoints.push(r),h.push(r))}return h},_previousSegmentPoint:function(t,e,i){for(var n,o=this.seriesPoints;i>0&&!n;)i--,n=o[i][e];return n?n=o[i][t]:(n=this._createGapStackPoint(t),this._stackPoints.push(n)),n},_createGapStackPoint:function(t){var e=this.pointOptions({},0),i=new Mt(0,e);return i.categoryIx=t,i.series={},i},seriesMissingValues:function(t){return t.missingValues||xr}}),Ut=Nt.extend({init:function(t,e,i,n,o){var r=this;r.prevSegment=e,r.isStacked=i,It.fn.init.call(r,t,n,o)},strokeSegments:function(){var t,e,i=this._strokeSegments;return i||(t=new si(this.options.closed),e=It.fn.points.call(this),i=this._strokeSegments=t.process(e)),i},createVisual:function(){var t=this.series,e=t._defaults,i=t.color;Xe(i)&&e&&(i=e.color),this.visual=new Vi.Group({zIndex:t.zIndex}),this.createFill({fill:{color:i,opacity:t.opacity},stroke:null}),this.createStroke({stroke:$e({color:i,opacity:t.opacity,lineCap:"butt"},t.line)})},createFill:function(e){var i,n,o,r,s,a=this.strokeSegments(),l=a.slice(0),c=this.prevSegment;this.isStacked&&c&&(i=c.strokeSegments(),n=Mi(i).anchor(),l.push(new Vi.Segment(n,n,Mi(a).anchor())),o=t.map(i,function(t){return new Vi.Segment(t.anchor(),t.controlOut(),t.controlIn())}).reverse(),Pi(l,o),r=l[0].anchor(),l.push(new Vi.Segment(r,r,Mi(o).anchor()))),s=new Vi.Path(e),s.segments.push.apply(s.segments,l),this.closeFill(s),this.visual.append(s)},closeFill:function(t){var e=this,i=e.parent,n=e.prevSegment,o=i.plotArea,r=i.options.invertAxes,s=i.seriesValueAxis(e.series),a=s.lineBox(),l=o.seriesCategoryAxis(e.series),c=l.lineBox(),h=r?c.x1:c.y1,u=r?_r:yr,d=e.strokeSegments(),f=d[0].anchor(),p=Mi(d).anchor();h=Ei(h,a[u+1],a[u+2]),i.options.isStacked&&n||!(d.length>1)||(r?t.lineTo(h,p.y).lineTo(h,f.y):t.lineTo(p.x,h).lineTo(f.x,h))},createStroke:function(t){if(t.stroke.width>0){var e=new Vi.Path(t);e.segments.push.apply(e.segments,this.strokeSegments()),this.visual.append(e)}}}),jt=Ot.extend({init:function(t,e,i,n){
var o=this;o.stackPoints=e,Ot.fn.init.call(o,t,i,n)},_linePoints:Ot.fn.points}),$e(jt.fn,Ft),Gt=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.plotArea=t,i.xAxisRanges={},i.yAxisRanges={},i.points=[],i.seriesPoints=[],i.seriesOptions=[],i._evalSeries=[],i.render()},options:{series:[],tooltip:{format:"{0}, {1}"},labels:{format:"{0}, {1}"},clip:!0},render:function(){var t=this;t.traverseDataPoints(He(t.addValue,t))},addErrorBar:function(t,e,i){var n,o=this,r=t.value[e],s=e+"Value",a=e+"ErrorLow",l=e+"ErrorHigh",c=i.seriesIx,h=i.series,u=t.options.errorBars,d=i[a],f=i[l];I(r)&&(I(d)&&I(f)&&(n={low:d,high:f}),u&&Di(u[s])&&(o.seriesErrorRanges=o.seriesErrorRanges||{x:[],y:[]},o.seriesErrorRanges[e][c]=o.seriesErrorRanges[e][c]||new yt(u[s],h,e),n=o.seriesErrorRanges[e][c].getErrorRange(r,u[s])),n&&o.addPointErrorBar(n,t,e))},addPointErrorBar:function(t,e,i){var n,o=this,r=t.low,s=t.high,a=e.series,l=i===yr,c=e.options.errorBars,h={};e[i+"Low"]=r,e[i+"High"]=s,e.errorBars=e.errorBars||[],n=new Dt(r,s,l,o,a,c),e.errorBars.push(n),e.append(n),h[i]=r,o.updateRange(h,a),h[i]=s,o.updateRange(h,a)},addValue:function(t,e){var i,n=this,o=t.x,r=t.y,s=e.seriesIx,a=this.options.series[s],l=this.seriesMissingValues(a),c=n.seriesPoints[s];Q(o)&&Q(r)||(t=this.createMissingValue(t,l)),t&&(i=n.createPoint(t,e),i&&(Ne(i,e),n.addErrorBar(i,_r,e),n.addErrorBar(i,yr,e)),n.updateRange(t,e.series)),n.points.push(i),c.push(i)},seriesMissingValues:function(t){return t.missingValues},createMissingValue:Fe,updateRange:function(t,e){var i=this,n=t.x,o=t.y,r=e.xAxis,s=e.yAxis,a=i.xAxisRanges[r],l=i.yAxisRanges[s];Q(n)&&(a=i.xAxisRanges[r]=a||{min:io,max:ro},typeof n===qo&&(n=p(n)),a.min=Ve.min(a.min,n),a.max=Ve.max(a.max,n)),Q(o)&&(l=i.yAxisRanges[s]=l||{min:io,max:ro},typeof o===qo&&(o=p(o)),l.min=Ve.min(l.min,o),l.max=Ve.max(l.max,o))},evalPointOptions:function(t,e,i){var n=i.series,o=i.seriesIx,r={defaults:n._defaults,excluded:["data","tooltip","tempate","visual","toggle","_outOfRangeMinPoint","_outOfRangeMaxPoint"]},s=this._evalSeries[o];return Di(s)||(this._evalSeries[o]=s=R(t,{},r,!0)),s&&(t=$e({},t),R(t,{value:e,series:n,dataItem:i.dataItem},r)),t},pointType:function(){return Mt},pointOptions:function(t,e){var i,n=this.seriesOptions[e];return n||(i=this.pointType().fn.defaults,this.seriesOptions[e]=n=$e({},i,{markers:{opacity:t.opacity},tooltip:{format:this.options.tooltip.format},labels:{format:this.options.labels.format}},t)),n},createPoint:function(t,e){var i,n=this,o=e.series,r=this.pointOptions(o,e.seriesIx),s=e.color||o.color;return r=n.evalPointOptions(r,t,e),Ue.isFunction(o.color)&&(s=r.color),i=new Mt(t,r),i.color=s,n.append(i),i},seriesAxes:function(t){var e=this.plotArea,i=t.xAxis,n=i?e.namedXAxes[i]:e.axisX,o=t.yAxis,r=o?e.namedYAxes[o]:e.axisY;if(!n)throw Error("Unable to locate X axis with name "+i);if(!r)throw Error("Unable to locate Y axis with name "+o);return{x:n,y:r}},reflow:function(t){var e,i,n=this,o=n.points,r=0,s=!n.options.clip;n.traverseDataPoints(function(t,a){e=o[r++],i=n.seriesAxes(a.series);var l,c=i.x.getSlot(t.x,t.x,s),h=i.y.getSlot(t.y,t.y,s);e&&(c&&h?(l=n.pointSlot(c,h),e.reflow(l)):e.visible=!1)}),n.box=t},pointSlot:function(t,e){return new ii(t.x1,e.y1,t.x2,e.y2)},traverseDataPoints:function(t){var e,i,n,o,r,s,a,l=this,c=l.options,h=c.series,u=l.seriesPoints;for(i=0;i<h.length;i++)for(n=h[i],o=u[i],o||(u[i]=[]),e=0;e<n.data.length;e++)r=this._bindPoint(n,i,e),s=r.valueFields,a=r.fields,t(s,$e({pointIx:e,series:n,seriesIx:i,dataItem:n.data[e],owner:l},a))},_bindPoint:wt.fn._bindPoint,formatPointValue:function(t,e){var i=t.value;return yi(e,i.x,i.y)},animationPoints:function(){var t,e=this.points,i=[];for(t=0;t<e.length;t++)i.push((e[t]||{}).marker);return i}}),$e(Gt.fn,zt),Wt=Gt.extend({render:function(){var t=this;Gt.fn.render.call(t),t.renderSegments()},createSegment:function(t,e,i){var n,o=e.style;return new(n=o===jo?Vt:It)(t,e,i)},animationPoints:function(){var t=Gt.fn.animationPoints.call(this);return t.concat(this._segments)},createMissingValue:function(t,e){if(e===xr){var i={x:t.x,y:t.y};return Q(i.x)||(i.x=0),Q(i.y)||(i.y=0),i}}}),$e(Wt.fn,Bt),qt=Gt.extend({init:function(t,e){this._maxSize=ro,Gt.fn.init.call(this,t,e)},options:{tooltip:{format:"{3}"},labels:{format:"{3}"}},addValue:function(t,e){null!==t.size&&(t.size>0||t.size<0&&e.series.negativeValues.visible)?(this._maxSize=Ve.max(this._maxSize,Ve.abs(t.size)),Gt.fn.addValue.call(this,t,e)):(this.points.push(null),this.seriesPoints[e.seriesIx].push(null))},reflow:function(t){var e=this;e.updateBubblesSize(t),Gt.fn.reflow.call(e,t)},pointType:function(){return Et},createPoint:function(t,e){var i,n,o=this,r=e.series,s=r.data.length,a=e.pointIx*(Un/s),l={delay:a,duration:Un-a,type:Ji},c=e.color||r.color;return t.size<0&&r.negativeValues.visible&&(c=Ri(r.negativeValues.color,c)),n=$e({labels:{animation:{delay:a,duration:Un-a}}},this.pointOptions(r,e.seriesIx),{markers:{type:sn,border:r.border,opacity:r.opacity,animation:l}}),n=o.evalPointOptions(n,t,e),Ue.isFunction(r.color)&&(c=n.color),n.markers.background=c,i=new Et(t,n),i.color=c,o.append(i),i},updateBubblesSize:function(t){var e,i,n,o,r,s,a,l,c,h,u,d,f,p,g,m,v,_=this,y=_.options,w=y.series,x=Ve.min(t.width(),t.height());for(e=0;e<w.length;e++)for(n=w[e],o=_.seriesPoints[e],r=n.minSize||Ve.max(.02*x,10),s=n.maxSize||.2*x,a=r/2,l=s/2,c=Ve.PI*a*a,h=Ve.PI*l*l,u=h-c,d=u/_._maxSize,i=0;i<o.length;i++)f=o[i],f&&(p=Ve.abs(f.value.size)*d,g=Ve.sqrt((c+p)/Ve.PI),m=Ri(f.options.zIndex,0),v=m+(1-g/l),$e(f.options,{zIndex:v,markers:{size:2*g,zIndex:v},labels:{zIndex:v+1}}))},formatPointValue:function(t,e){var i=t.value;return yi(e,i.x,i.y,i.size,t.category)},createAnimation:Fe,createVisual:Fe}),$t=oi.extend({init:function(t,e){oi.fn.init.call(this,e),this.value=t},options:{vertical:!0,border:{_brightness:.8},line:{width:2},overlay:{gradient:Vn},tooltip:{format:"<table style='text-align: left;'><th colspan='2'>{4:d}</th><tr><td>Open:</td><td>{0:C}</td></tr><tr><td>High:</td><td>{1:C}</td></tr><tr><td>Low:</td><td>{2:C}</td></tr><tr><td>Close:</td><td>{3:C}</td></tr></table>"},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}}},reflow:function(t){var e,i,n,o=this,r=o.options,s=o.owner,a=o.value,l=s.seriesValueAxis(r),c=[];i=l.getSlot(a.open,a.close),n=l.getSlot(a.low,a.high),i.x1=n.x1=t.x1,i.x2=n.x2=t.x2,o.realBody=i,e=n.center().x,c.push([[e,n.y1],[e,i.y1]]),c.push([[e,i.y2],[e,n.y2]]),o.lines=c,o.box=n.clone().wrap(i),o._rendered||(o._rendered=!0,o.createNote()),o.reflowNote()},reflowNote:function(){var t=this;t.note&&t.note.reflow(t.box)},createVisual:function(){oi.fn.createVisual.call(this),this._mainVisual=this.mainVisual(this.options),this.visual.append(this._mainVisual),this.createOverlay()},mainVisual:function(t){var e=new Vi.Group;return this.createBody(e,t),this.createLines(e,t),e},createBody:function(t,i){var n=Vi.Path.fromRect(this.realBody.toRect(),{fill:{color:this.color,opacity:i.opacity},stroke:null});i.border.width>0&&n.options.set("stroke",{color:this.getBorderColor(),width:i.border.width,dashType:i.border.dashType,opacity:Ri(i.border.opacity,i.opacity)}),_i(n),t.append(n),q(i)&&t.append(this.createGradientOverlay(n,{baseColor:this.color},$e({end:i.vertical?e:[0,1]},i.overlay)))},createLines:function(t,e){this.drawLines(t,e,this.lines,e.line)},drawLines:function(t,e,i,n){var o,r,s;if(i)for(o={stroke:{color:n.color||this.color,opacity:Ri(n.opacity,e.opacity),width:n.width,dashType:n.dashType,lineCap:"butt"}},r=0;r<i.length;r++)s=Vi.Path.fromPoints(i[r],o),_i(s),t.append(s)},getBorderColor:function(){var t=this,e=t.options,i=e.border,n=i.color;return Di(n)||(n=new ri(t.color).brightness(i._brightness).toHex()),n},createOverlay:function(){var t=Vi.Path.fromRect(this.box.toRect(),{fill:{color:vr,opacity:0},stroke:null});this.visual.append(t)},createHighlight:function(){var t,e=this.options.highlight,i=this.color;return this.color=e.color||this.color,t=this.mainVisual($e({},this.options,{line:{color:this.getBorderColor()}},e)),this.color=i,t},highlightVisual:function(){return this._mainVisual},highlightVisualArgs:function(){return{options:this.options,rect:this.box.toRect(),visual:this._mainVisual}},tooltipAnchor:function(){var t=this,e=t.box,i=t.owner.pane.clipBox()||e;return new ui(e.x2+sr,Ve.max(e.y1,i.y1)+sr)},formatValue:function(t){var e=this;return e.owner.formatPointValue(e,t)},overlapsBox:function(t){return this.box.overlaps(t)}}),$e($t.fn,pt),$e($t.fn,gt),Yt=wt.extend({options:{},reflowCategories:function(t){var e,i=this,n=i.children,o=n.length;for(e=0;e<o;e++)n[e].reflow(t[e])},addValue:function(t,e){var i,n,o=this,r=e.categoryIx,s=e.category,a=e.series,l=e.seriesIx,c=o.options,h=t.valueFields,u=o.children,d=o.splitValue(h),f=z(d),p=o.categoryPoints[r],g=a.data[r];p||(o.categoryPoints[r]=p=[]),f&&(i=o.createPoint(t,e)),n=u[r],n||(n=new dt({vertical:c.invertAxes,gap:c.gap,spacing:c.spacing}),o.append(n)),i&&(o.updateRange(h,e),n.append(i),i.categoryIx=r,i.category=s,i.series=a,i.seriesIx=l,i.owner=o,i.dataItem=g,i.noteText=t.fields.noteText),o.points.push(i),p.push(i)},pointType:function(){return $t},createPoint:function(t,e){var i,n=this,o=e.categoryIx,r=e.category,s=e.series,a=e.seriesIx,l=t.valueFields,c=$e({},s),h=n.pointType(),u=t.fields.color||s.color;return c=n.evalPointOptions(c,l,r,o,s,a),s.type==en&&l.open>l.close&&(u=t.fields.downColor||s.downColor||s.color),Ue.isFunction(s.color)&&(u=c.color),c.vertical=!n.options.invertAxes,i=new h(l,c),i.color=u,i},splitValue:function(t){return[t.low,t.open,t.close,t.high]},updateRange:function(t,e){var i=this,n=e.series.axis,o=i.valueAxisRanges[n],r=i.splitValue(t);o=i.valueAxisRanges[n]=o||{min:io,max:ro},o=i.valueAxisRanges[n]={min:Ve.min.apply(Ve,r.concat([o.min])),max:Ve.max.apply(Ve,r.concat([o.max]))}},formatPointValue:function(t,e){var i=t.value;return yi(e,i.open,i.high,i.low,i.close,t.category)},animationPoints:function(){return this.points}}),$e(Yt.fn,zt),Xt=$t.extend({reflow:function(t){var e,i,n,o,r=this,s=r.options,a=r.owner,l=r.value,c=a.seriesValueAxis(s),h=[],u=[],d=[];o=c.getSlot(l.low,l.high),i=c.getSlot(l.open,l.open),n=c.getSlot(l.close,l.close),i.x1=n.x1=o.x1=t.x1,i.x2=n.x2=o.x2=t.x2,e=o.center().x,h.push([i.x1,i.y1]),h.push([e,i.y1]),u.push([e,n.y1]),u.push([n.x2,n.y1]),d.push([e,o.y1]),d.push([e,o.y2]),r.lines=[h,u,d],r.box=o.clone().wrap(i.clone().wrap(n)),r.reflowNote()},createBody:t.noop}),Qt=Yt.extend({pointType:function(){return Xt}}),Kt=Yt.extend({addValue:function(t,e){var i,n,o=this,r=e.categoryIx,s=e.category,a=e.series,l=e.seriesIx,c=o.options,h=o.children,u=t.valueFields,d=o.splitValue(u),f=z(d),p=o.categoryPoints[r],g=a.data[r];p||(o.categoryPoints[r]=p=[]),f&&(i=o.createPoint(t,e)),n=h[r],n||(n=new dt({vertical:c.invertAxes,gap:c.gap,spacing:c.spacing}),o.append(n)),i&&(o.updateRange(u,e),n.append(i),i.categoryIx=r,i.category=s,i.series=a,i.seriesIx=l,i.owner=o,i.dataItem=g),o.points.push(i),p.push(i)},pointType:function(){return this.options.invertAxes?Jt:Zt},splitValue:function(t){return[t.lower,t.q1,t.median,t.q3,t.upper]},updateRange:function(t,e){var i=this,n=e.series.axis,o=i.valueAxisRanges[n],r=i.splitValue(t).concat(i.filterOutliers(t.outliers));Di(t.mean)&&(r=r.concat(t.mean)),o=i.valueAxisRanges[n]=o||{min:io,max:ro},o=i.valueAxisRanges[n]={min:Ve.min.apply(Ve,r.concat([o.min])),max:Ve.max.apply(Ve,r.concat([o.max]))}},formatPointValue:function(t,e){var i=t.value;return yi(e,i.lower,i.q1,i.median,i.q3,i.upper,i.mean,t.category)},filterOutliers:function(t){var e,i,n=(t||[]).length,o=[];for(e=0;e<n;e++)i=t[e],Di(i)&&M(o,i);return o}}),Zt=$t.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.value=t,i.createNote()},options:{border:{_brightness:.8},line:{width:2},mean:{width:2,dashType:"dash"},overlay:{gradient:Vn},tooltip:{format:"<table style='text-align: left;'><th colspan='2'>{6:d}</th><tr><td>Lower:</td><td>{0:C}</td></tr><tr><td>Q1:</td><td>{1:C}</td></tr><tr><td>Median:</td><td>{2:C}</td></tr><tr><td>Mean:</td><td>{5:C}</td></tr><tr><td>Q3:</td><td>{3:C}</td></tr><tr><td>Upper:</td><td>{4:C}</td></tr></table>"},highlight:{opacity:1,border:{width:1,opacity:1},line:{width:1,opacity:1}},notes:{visible:!0,label:{}},outliers:{visible:!0,size:Kn,type:dn,background:vr,border:{width:2,opacity:1},opacity:0},extremes:{visible:!0,size:Kn,type:sn,background:vr,border:{width:2,opacity:1},opacity:0}},reflow:function(t){var e,i,n,o,r=this,s=r.options,a=r.owner,l=r.value,c=a.seriesValueAxis(s);r.boxSlot=i=c.getSlot(l.q1,l.q3),r.realBody=i,r.reflowBoxSlot(t),r.whiskerSlot=e=c.getSlot(l.lower,l.upper),r.reflowWhiskerSlot(t),n=c.getSlot(l.median),l.mean&&(o=c.getSlot(l.mean),r.meanPoints=r.calcMeanPoints(t,o)),r.whiskerPoints=r.calcWhiskerPoints(i,e),r.medianPoints=r.calcMedianPoints(t,n),r.box=e.clone().wrap(i),r.reflowNote()},reflowBoxSlot:function(t){this.boxSlot.x1=t.x1,this.boxSlot.x2=t.x2},reflowWhiskerSlot:function(t){this.whiskerSlot.x1=t.x1,this.whiskerSlot.x2=t.x2},calcMeanPoints:function(t,e){return[[[t.x1,e.y1],[t.x2,e.y1]]]},calcWhiskerPoints:function(t,e){var i=e.center().x;return[[[i-5,e.y1],[i+5,e.y1],[i,e.y1],[i,t.y1]],[[i-5,e.y2],[i+5,e.y2],[i,e.y2],[i,t.y2]]]},calcMedianPoints:function(t,e){return[[[t.x1,e.y1],[t.x2,e.y1]]]},renderOutliers:function(t){var e,i,n,o,r=this,s=t.markers||{},a=r.value,l=a.outliers||[],c=3*Ve.abs(a.q3-a.q1),h=[];for(o=0;o<l.length;o++)n=l[o],s=n<a.q3+c&&n>a.q1-c?t.outliers:t.extremes,e=$e({},s.border),Di(e.color)||(e.color=Di(r.color)?r.color:new ri(s.background).brightness($i).toHex()),i=new pi({type:s.type,width:s.size,height:s.size,rotation:s.rotation,background:s.background,border:e,opacity:s.opacity}),i.value=n,h.push(i);return this.reflowOutliers(h),h},reflowOutliers:function(t){var i,n,o,r=this.owner.seriesValueAxis(this.options),s=this.box.center();for(i=0;i<t.length;i++)n=t[i].value,o=r.getSlot(n),this.options.vertical?o.move(s.x):o.move(e,s.y),this.box=this.box.wrap(o),t[i].reflow(o)},mainVisual:function(t){var e,i,n=$t.fn.mainVisual.call(this,t),o=this.renderOutliers(t);for(e=0;e<o.length;e++)i=o[e].getElement(),i&&n.append(i);return n},createLines:function(t,e){this.drawLines(t,e,this.whiskerPoints,e.line),this.drawLines(t,e,this.medianPoints,e.median),this.drawLines(t,e,this.meanPoints,e.mean)},getBorderColor:function(){return this.color?this.color:$t.getBorderColor.call(this)}}),$e(Zt.fn,pt),Jt=Zt.extend({reflowBoxSlot:function(t){this.boxSlot.y1=t.y1,this.boxSlot.y2=t.y2},reflowWhiskerSlot:function(t){this.whiskerSlot.y1=t.y1,this.whiskerSlot.y2=t.y2},calcMeanPoints:function(t,e){return[[[e.x1,t.y1],[e.x1,t.y2]]]},calcWhiskerPoints:function(t,e){var i=e.center().y;return[[[e.x1,i-5],[e.x1,i+5],[e.x1,i],[t.x1,i]],[[e.x2,i-5],[e.x2,i+5],[e.x2,i],[t.x2,i]]]},calcMedianPoints:function(t,e){return[[[e.x1,t.y1],[e.x1,t.y2]]]}}),te=oi.extend({init:function(t,e,i){var n=this;n.value=t,n.sector=e,oi.fn.init.call(n,i)},options:{color:vr,overlay:{gradient:Mo},border:{width:.5},labels:{visible:!1,distance:35,font:_n,margin:bi(.5),align:sn,zIndex:1,position:wo},animation:{type:xo},highlight:{visible:!0,border:{width:1}},visible:!0},render:function(){var t,e=this,i=e.options,n=i.labels,o=e.value;e._rendered||e.visible===!1||(e._rendered=!0,n.template?(t=Qe(n.template),o=t({dataItem:e.dataItem,category:e.category,value:e.value,series:e.series,percentage:e.percentage})):n.format&&(o=yi(n.format,o)),n.visible&&o&&(e.label=new mi(o,$e({},n,{align:on,vAlign:"",animation:{type:zn,delay:e.animationDelay}})),e.append(e.label)))},reflow:function(t){var e=this;e.render(),e.box=t,e.reflowLabel()},reflowLabel:function(){var t,e,i,n,o=this,r=o.sector.clone(),s=o.options,a=o.label,l=s.labels,c=l.distance,h=r.middle();a&&(n=a.box.height(),i=a.box.width(),l.position==on?(r.r=Ve.abs((r.r-n)/2)+n,t=r.point(h),a.reflow(ii(t.x,t.y-n/2,t.x,t.y))):l.position==Gn?(r.r=r.r-n/2,t=r.point(h),a.reflow(ii(t.x,t.y-n/2,t.x,t.y))):(t=r.clone().expand(c).point(h),t.x>=r.c.x?(e=t.x+i,a.orientation=Do):(e=t.x-i,a.orientation=$n),a.reflow(ii(e,t.y-n,t.x,t.y))))},createVisual:function(){var t,e,i=this,n=i.sector,o=i.options;oi.fn.createVisual.call(this),i.value&&(o.visual?(t=(n.startAngle+180)%360,e=o.visual({category:i.category,dataItem:i.dataItem,value:i.value,series:i.series,percentage:i.percentage,center:new Oi.Point(n.c.x,n.c.y),radius:n.r,innerRadius:n.ir,startAngle:t,endAngle:t+n.angle,options:o,createVisual:function(){var t=new Vi.Group;return i.createSegmentVisual(t),t}}),e&&i.visual.append(e)):i.createSegmentVisual(i.visual))},createSegmentVisual:function(t){var e,i=this,n=i.sector,o=i.options,r=o.border||{},s=r.width>0?{stroke:{color:r.color,width:r.width,opacity:r.opacity,dashType:r.dashType}}:{},a=o.color,l={color:a,opacity:o.opacity};e=i.createSegment(n,$e({fill:l,stroke:{opacity:o.opacity},zIndex:o.zIndex},s)),t.append(e),q(o)&&t.append(this.createGradientOverlay(e,{baseColor:a,fallbackFill:l},$e({center:[n.c.x,n.c.y],innerRadius:n.ir,radius:n.r,userSpace:!0},o.overlay)))},createSegment:function(t,e){return e.singleSegment?new Vi.Circle(new Oi.Circle(new Oi.Point(t.c.x,t.c.y),t.r),e):gi.current.createRing(t,e)},createAnimation:function(){var t=this.options,e=this.sector.c;$e(t,{animation:{center:[e.x,e.y],delay:this.animationDelay}}),oi.fn.createAnimation.call(this)},createHighlight:function(t){var e=this,i=e.options.highlight||{},n=i.border||{};return e.createSegment(e.sector,$e({},t,{fill:{color:i.color,opacity:i.opacity},stroke:{opacity:n.opacity,width:n.width,color:n.color}}))},highlightVisual:function(){return this.visual.children[0]},highlightVisualArgs:function(){var t=this.sector;return{options:this.options,radius:t.r,innerRadius:t.ir,center:new Oi.Point(t.c.x,t.c.y),startAngle:t.startAngle,endAngle:t.angle+t.startAngle,visual:this.visual}},tooltipAnchor:function(t,e){var i=this,n=i.sector.adjacentBox(sr,t,e);return new ui(n.x1,n.y1)},formatValue:function(t){var e=this;return e.owner.formatPointValue(e,t)}}),$e(te.fn,pt),ee={createLegendItem:function(t,e,i){var n,o,r,s,a,l=this,c=l.options.legend||{},h=c.labels||{},u=c.inactiveItems||{},d=u.labels||{};i&&i.visibleInLegend!==!1&&(a=i.visible!==!1,n=i.category||"",o=a?h.template:d.template||h.template,o&&(n=Qe(o)({text:n,series:i.series,dataItem:i.dataItem,percentage:i.percentage,value:t})),a?(s={},r=e.color):(s={color:d.color,font:d.font},r=(u.markers||{}).color),n&&l.legendItems.push({pointIndex:i.index,text:n,series:i.series,markerColor:r,labels:s}))}},ie=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.plotArea=t,i.points=[],i.legendItems=[],i.render()},options:{startAngle:90,connectors:{width:1,color:"#939393",padding:4},inactiveItems:{markers:{},labels:{}}},render:function(){var t=this;t.traverseDataPoints(He(t.addValue,t))},traverseDataPoints:function(t){var e,i,n,o,r,s,a,l,c,h,u,d,f,p=this,g=p.options,m=p.plotArea.options.seriesColors||[],v=m.length,_=g.series,y=_.length,w=0;for(o=0;o<y;o++){for(e=_[o],s=e.data,u=W(e),a=360/u,d=Di(e.startAngle)?e.startAngle:g.startAngle,o!=y-1&&e.labels.position==wo&&(e.labels.position=on),f=0;f<s.length;f++)i=ot.current.bindPoint(e,f),l=i.valueFields.value,c=Ve.abs(l),n=i.fields,r=c*a,h=1!=s.length&&!!n.explode,Xe(e.color)||(e.color=n.color||m[f%v]),t(l,new fi(null,0,0,d,r),{owner:p,category:n.category||"",index:w,series:e,seriesIx:o,dataItem:s[f],percentage:0!==u?c/u:0,explode:h,visibleInLegend:n.visibleInLegend,visible:n.visible,zIndex:y-o,animationDelay:p.animationDelay(f,o,y)}),i.fields.visible!==!1&&(d+=r),w++;w=0}},evalSegmentOptions:function(t,e,i){var n=i.series;R(t,{value:e,series:n,dataItem:i.dataItem,category:i.category,percentage:i.percentage},{defaults:n._defaults,excluded:["data","template","visual","toggle"]})},addValue:function(t,e,i){var n,o=this,r=$e({},i.series,{index:i.index});o.evalSegmentOptions(r,t,i),o.createLegendItem(t,r,i),i.visible!==!1&&(n=new te(t,e,r),Ne(n,i),o.append(n),o.points.push(n))},reflow:function(t){var e,i,n,o,r,s,a,l,c=this,h=c.options,u=t.clone(),d=5,f=Ve.min(u.width(),u.height()),p=f/2,g=f-.85*f,m=Ri(h.padding,g),v=ii(u.x1,u.y1,u.x1+f,u.y1+f),_=v.center(),y=c.seriesConfigs||[],w=u.center(),x=c.points,b=x.length,k=h.series.length,C=[],S=[];for(m=m>p-d?p-d:m,v.translate(w.x-_.x,w.y-_.y),s=p-m,l=ui(s+v.x1+m,s+v.y1+m),a=0;a<b;a++)o=x[a],r=o.sector,r.r=s,r.c=l,i=o.seriesIx,y.length&&(e=y[i],r.ir=e.ir,r.r=e.r),i==k-1&&o.explode&&(r.c=r.clone().radius(.15*r.r).point(r.middle())),o.reflow(v),n=o.label,n&&n.options.position===wo&&i==k-1&&(n.orientation===Do?S.push(n):C.push(n));C.length>0&&(C.sort(c.labelComparator(!0)),c.leftLabelsReflow(C)),S.length>0&&(S.sort(c.labelComparator(!1)),c.rightLabelsReflow(S)),c.box=v},leftLabelsReflow:function(t){var e=this,i=e.distanceBetweenLabels(t);e.distributeLabels(i,t)},rightLabelsReflow:function(t){var e=this,i=e.distanceBetweenLabels(t);e.distributeLabels(i,t)},distanceBetweenLabels:function(t){var e,i,n,o=this,r=o.points,s=r[r.length-1],a=s.sector,l=t[0].box,c=t.length-1,h=a.r+s.options.labels.distance,u=[];for(i=Ti(l.y1-(a.c.y-h-l.height()-l.height()/2)),u.push(i),n=0;n<c;n++)l=t[n].box,e=t[n+1].box,i=Ti(e.y1-l.y2),u.push(i);return i=Ti(a.c.y+h-t[c].box.y2-t[c].box.height()/2),u.push(i),u},distributeLabels:function(t,e){var i,n,o,r,s=this,a=t.length;for(r=0;r<a;r++)for(n=o=r,i=-t[r];i>0&&(n>=0||o<a);)i=s._takeDistance(t,r,--n,i),i=s._takeDistance(t,r,++o,i);s.reflowLabels(t,e)},_takeDistance:function(t,e,i,n){if(t[i]>0){var o=Ve.min(t[i],n);n-=o,t[i]-=o,t[e]+=o}return n},reflowLabels:function(t,e){var i,n,o,r,s=this,a=s.points,l=a[a.length-1],c=l.sector,h=e.length,u=l.options.labels,d=u.distance,f=c.c.y-(c.r+d)-e[0].box.height();for(t[0]+=2,r=0;r<h;r++)i=e[r],f+=t[r],o=i.box,n=s.hAlignLabel(o.x2,c.clone().expand(d),f,f+o.height(),i.orientation==Do),i.orientation==Do?(u.align!==sn&&(n=c.r+c.c.x+d),i.reflow(ii(n+o.width(),f,n,f))):(u.align!==sn&&(n=c.c.x-c.r-d),i.reflow(ii(n-o.width(),f,n,f))),f+=o.height()},createVisual:function(){var t,e,i,n,r,s,a,l,c,h,u,d,f,p,g,m=this,v=m.options,_=v.connectors,y=m.points,w=y.length,x=4;for(oi.fn.createVisual.call(this),this._connectorLines=[],l=0;l<w;l++)r=y[l],i=r.sector,n=i.middle(),a=r.label,s={seriesId:r.seriesIx},e=(r.options.connectors||{}).color||_.color,a&&(t=new Vi.Path({stroke:{color:e,width:_.width},animation:{type:zn,delay:r.animationDelay}}),a.options.position===wo&&0!==r.value&&(c=a.box,h=i.c,u=i.point(n),d=ui(c.x1,c.center().y),u=i.clone().expand(_.padding).point(n),t.moveTo(u.x,u.y),a.orientation==Do?(p=ui(c.x1-_.padding,c.center().y),g=o(h,u,d,p),d=ui(p.x-x,p.y),g=g||d,g.x=Ve.min(g.x,d.x),m.pointInCircle(g,i.c,i.r+x)||g.x<i.c.x?(f=i.c.x+i.r+x,r.options.labels.align!==hn?f<d.x?t.lineTo(f,u.y):t.lineTo(u.x+2*x,u.y):t.lineTo(f,u.y),t.lineTo(d.x,p.y)):(g.y=p.y,t.lineTo(g.x,g.y))):(p=ui(c.x2+_.padding,c.center().y),g=o(h,u,d,p),d=ui(p.x+x,p.y),g=g||d,g.x=Ve.max(g.x,d.x),m.pointInCircle(g,i.c,i.r+x)||g.x>i.c.x?(f=i.c.x-i.r-x,r.options.labels.align!==hn?f>d.x?t.lineTo(f,u.y):t.lineTo(u.x-2*x,u.y):t.lineTo(f,u.y),t.lineTo(d.x,p.y)):(g.y=p.y,t.lineTo(g.x,g.y))),t.lineTo(p.x,p.y),this._connectorLines.push(t),this.visual.append(t)))},labelComparator:function(t){return t=t?-1:1,function(e,i){return e=(e.parent.sector.middle()+270)%360,i=(i.parent.sector.middle()+270)%360,(e-i)*t}},hAlignLabel:function(t,e,i,n,o){var r=e.c.x,s=e.c.y,a=e.r,l=Ve.min(Ve.abs(s-i),Ve.abs(s-n));return l>a?t:r+Ve.sqrt(a*a-l*l)*(o?1:-1)},pointInCircle:function(t,e,i){return u(e.x-t.x)+u(e.y-t.y)<u(i)},formatPointValue:function(t,e){return yi(e,t.value)},animationDelay:function(t){return t*bo}}),$e(ie.fn,ee),ne=te.extend({options:{overlay:{gradient:Eo},labels:{position:on},animation:{type:xo}},reflowLabel:function(){var t,e,i=this,n=i.sector.clone(),o=i.options,r=i.label,s=o.labels,a=n.middle();r&&(e=r.box.height(),s.position==on?(n.r-=(n.r-n.ir)/2,t=n.point(a),r.reflow(new ii(t.x,t.y-e/2,t.x,t.y))):te.fn.reflowLabel.call(i))},createSegment:function(t,e){return gi.current.createRing(t,e)}}),$e(ne.fn,pt),oe=ie.extend({options:{startAngle:90,connectors:{width:1,color:"#939393",padding:4}},addValue:function(t,e,i){var n,o=this,r=$e({},i.series,{index:i.index});o.evalSegmentOptions(r,t,i),o.createLegendItem(t,r,i),t&&i.visible!==!1&&(n=new ne(t,e,r),Ne(n,i),o.append(n),o.points.push(n))},reflow:function(t){var e,i,n,o,r,s,a=this,l=a.options,c=t.clone(),h=5,u=Ve.min(c.width(),c.height()),d=u/2,f=u-.85*u,p=Ri(l.padding,f),g=l.series,m=g.length,v=0,_=0,y=0,w=0;for(a.seriesConfigs=[],p=p>d-h?d-h:p,n=d-p,r=0;r<m;r++)e=g[r],0===r&&Di(e.holeSize)&&(i=e.holeSize,n-=e.holeSize),Di(e.size)?n-=e.size:v++,Di(e.margin)&&r!=m-1&&(n-=e.margin);for(Di(i)||(w=(d-p)/(m+.75),i=.75*w,n-=i),y=i,r=0;r<m;r++)e=g[r],o=Ri(e.size,n/v),y+=_,s=y+o,a.seriesConfigs.push({ir:y,r:s}),_=e.margin||0,y=s;ie.fn.reflow.call(a,t)},animationDelay:function(t,e,i){return t*Cn+Un*(e+1)/(i+1)}}),re=xt.extend({render:function(){xt.fn.render.call(this),this.createSegments()},traverseDataPoints:function(t){var e,i,n,o,r,s,a,l,c,u,d=this.options.series,f=this.categoryAxis.options.categories||[],p=h(d),g=!this.options.invertAxes;for(e=0;e<d.length;e++)for(i=d[e],n=0,o=0,r=0;r<p;r++)s=ot.current.bindPoint(i,r),a=s.valueFields.value,l=s.fields.summary,c=n,l?"total"===l.toLowerCase()?(s.valueFields.value=n,c=0,u=n):(s.valueFields.value=o,u=c-o,o=0):I(a)&&(o+=a,n+=a,u=n),t(s,{category:f[r],categoryIx:r,series:i,seriesIx:e,total:n,runningTotal:o,from:c,to:u,isVertical:g})},updateRange:function(t,e){xt.fn.updateRange.call(this,{value:e.to},e)},aboveAxis:function(t){return t.value>=0},plotRange:function(t){return[t.from,t.to]},createSegments:function(){var t,e,i,n,o,r,s,a=this.options.series,l=this.seriesPoints,c=this.segments=[];for(t=0;t<a.length;t++)if(e=a[t],i=l[t])for(o=0;o<i.length;o++)r=i[o],r&&n&&(s=new se(n,r,e),c.push(s),this.append(s)),n=r}}),se=oi.extend({init:function(t,e,i){var n=this;oi.fn.init.call(n),n.from=t,n.to=e,n.series=i},options:{animation:{type:zn,delay:Un}},linePoints:function(){var t,e,i=[],n=this.from,o=n.box,r=this.to.box;return n.isVertical?(t=n.aboveAxis?o.y1:o.y2,i.push([o.x1,t],[r.x2,t])):(e=n.aboveAxis?o.x2:o.x1,i.push([e,o.y1],[e,r.y2])),i},createVisual:function(){var t,e;oi.fn.createVisual.call(this),t=this.series.line||{},e=Vi.Path.fromPoints(this.linePoints(),{stroke:{color:t.color,width:t.width,opacity:t.opacity,dashType:t.dashType}}),_i(e),this.visual.append(e)}}),ae=ni.extend({init:function(t){var e=this;ni.fn.init.call(e,t),t=e.options,e.id=Ue.guid(),e.createTitle(),e.content=new oi,e.chartContainer=new le({},e),e.append(e.content),e.axes=[],e.charts=[]},options:{zIndex:-1,shrinkToFit:!0,title:{align:$n},visible:!0},createTitle:function(){var t=this,e=t.options.title;typeof e===_o&&(e=$e({},e,{align:e.position,position:or})),t.title=vi.buildTitle(e,t,ae.fn.options.title)},appendAxis:function(t){var e=this;e.content.append(t),e.axes.push(t),t.pane=e},appendChart:function(t){var e=this;e.chartContainer.parent!==e.content&&e.content.append(e.chartContainer),e.charts.push(t),e.chartContainer.append(t),t.pane=e},empty:function(){var t,e=this,i=e.parent;if(i){for(t=0;t<e.axes.length;t++)i.removeAxis(e.axes[t]);for(t=0;t<e.charts.length;t++)i.removeChart(e.charts[t])}e.axes=[],e.charts=[],e.content.destroy(),e.content.children=[],e.chartContainer.children=[]},reflow:function(t){var e,i=this;Mi(i.children)===i.content&&(e=i.children.pop()),ni.fn.reflow.call(i,t),e&&i.children.push(e),i.title&&(i.contentBox.y1+=i.title.box.height())},visualStyle:function(){var t=ni.fn.visualStyle.call(this);return t.zIndex=-10,t},renderComplete:function(){this.options.visible&&this.createGridLines()},stackRoot:i,clipRoot:i,createGridLines:function(){var t,e,i,n,o,r,s=this,a=s.axes,l=a.concat(s.parent.axes),c=[],h=[];for(e=0;e<a.length;e++)for(n=a[e],o=n.options.vertical,t=o?c:h,i=0;i<l.length;i++)0===t.length&&(r=l[i],o!==r.options.vertical&&Pi(t,n.createGridLines(r)))},refresh:function(){this.visual.clear(),this.content.parent=null,this.content.createGradient=t.proxy(this.createGradient,this),this.content.renderVisual(),this.content.parent=this,this.title&&this.visual.append(this.title.visual),this.visual.append(this.content.visual),this.renderComplete()},chartsBox:function(){var t,e,i,n,o,r=this.axes,s=r.length,a=new ii;for(n=0;n<s;n++)i=r[n],t=i.options.vertical?yr:_r,e=i.lineBox(),a[t+1]=e[t+1],a[t+2]=e[t+2];if(0===a.x2)for(o=this.parent.axes,s=o.length,n=0;n<s;n++)i=o[n],i.options.vertical||(e=i.lineBox(),a.x1=e.x1,a.x2=e.x2);return a},clipBox:function(){return this.chartContainer.clipBox}}),le=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,t),i.pane=e},shouldClip:function(){var t,e=this,i=e.children,n=i.length;for(t=0;t<n;t++)if(i[t].options.clip===!0)return!0;return!1},_clipBox:function(){return this.pane.chartsBox()},createVisual:function(){var t,e,i;this.visual=new Vi.Group({zIndex:0}),this.shouldClip()&&(t=this.clipBox=this._clipBox(),e=t.toRect(),i=Vi.Path.fromRect(e),this.visual.clip(i),this.unclipLabels())},stackRoot:i,unclipLabels:function(){var t,e,i,n,o,r,s,a=this,l=a.children,c=a.clipBox;for(i=0;i<l.length;i++)for(t=l[i].points||{},o=t.length,n=0;n<o;n++)e=t[n],e&&e.overlapsBox&&e.overlapsBox(c)&&(r=e.label,s=e.note,r&&r.options.visible&&(r.alignToClipBox&&r.alignToClipBox(c),r.options.noclip=!0),s&&s.options.visible&&(s.options.noclip=!0))},destroy:function(){oi.fn.destroy.call(this),delete this.parent}}),ce=oi.extend({init:function(t,e){var i=this;oi.fn.init.call(i,e),i.series=t,i.initSeries(),i.charts=[],i.options.legend.items=[],i.axes=[],i.crosshairs=[],i.createPanes(),i.render(),i.createCrosshairs()},options:{series:[],plotArea:{margin:{}},background:"",border:{color:Xi,width:0},legend:{inactiveItems:{labels:{color:"#919191"},markers:{color:"#919191"}}}},initSeries:function(){var t,e,i=this.series;for(t=0;t<i.length;t++)e=i[t],e.index=t},createPanes:function(){function t(t,e){"string"==typeof t.title&&(t.title={text:t.title}),t.title=$e({},e.title,t.title)}var e,i,n,o=this,r={title:{color:(o.options.title||{}).color}},s=[],a=o.options.panes||[],l=Ve.max(a.length,1);for(e=0;e<l;e++)n=a[e]||{},t(n,r),i=new ae(n),i.paneIndex=e,s.push(i),o.append(i);o.panes=s},createCrosshairs:function(t){var e,i,n,o,r,s=this;for(t=t||s.panes,e=0;e<t.length;e++)for(n=t[e],i=0;i<n.axes.length;i++)o=n.axes[i],o.options.crosshair&&o.options.crosshair.visible&&(r=new be(o,o.options.crosshair),s.crosshairs.push(r),n.content.append(r))},removeCrosshairs:function(t){var e,i,n=this,o=n.crosshairs,r=t.axes;for(e=o.length-1;e>=0;e--)for(i=0;i<r.length;i++)if(o[e].axis===r[i]){o.splice(e,1);break}},hideCrosshairs:function(){var t,e=this.crosshairs;for(t=0;t<e.length;t++)e[t].hide()},findPane:function(t){var e,i,n=this,o=n.panes;for(e=0;e<o.length;e++)if(o[e].options.name===t){i=o[e];break}return i||o[0]},findPointPane:function(t){var e,i,n=this,o=n.panes;for(e=0;e<o.length;e++)if(o[e].box.containsPoint(t)){i=o[e];break}return i},appendAxis:function(t){var e=this,i=e.findPane(t.options.pane);i.appendAxis(t),e.axes.push(t),t.plotArea=e},removeAxis:function(t){var e,i,n=this,o=[];for(e=0;e<n.axes.length;e++)i=n.axes[e],t!==i?o.push(i):i.destroy();n.axes=o},appendChart:function(t,e){var i=this;i.charts.push(t),e?e.appendChart(t):i.append(t)},removeChart:function(t){var e,i,n=this,o=[];for(e=0;e<n.charts.length;e++)i=n.charts[e],i!==t?o.push(i):i.destroy();n.charts=o},addToLegend:function(t){var e,i,n,o,r,s,a,l,c,h=t.length,u=[],d=this.options.legend,f=d.labels||{},p=d.inactiveItems||{},g=p.labels||{};for(e=0;e<h;e++)i=t[e],l=i.visible!==!1,i.visibleInLegend!==!1&&(n=i.name||"",c=l?f.template:g.template||f.template,c&&(n=Qe(c)({text:n,series:i})),o=i.color,a=i._defaults,Xe(o)&&a&&(o=a.color),l?(r={},s=o):(r={color:g.color,font:g.font},s=p.markers.color),n&&u.push({text:n,labels:r,markerColor:s,series:i,active:l}));Pi(d.items,u)},groupAxes:function(t){var e,i,n,o,r=[],s=[];for(n=0;n<t.length;n++)for(e=t[n].axes,o=0;o<e.length;o++)i=e[o],i.options.vertical?s.push(i):r.push(i);return{x:r,y:s,any:r.concat(s)}},groupSeriesByPane:function(){
var t,e,i,n=this,o=n.series,r={};for(t=0;t<o.length;t++)i=o[t],e=n.seriesPaneName(i),r[e]?r[e].push(i):r[e]=[i];return r},filterVisibleSeries:function(t){var e,i,n=[];for(e=0;e<t.length;e++)i=t[e],i.visible!==!1&&n.push(i);return n},reflow:function(t){var e=this,i=e.options.plotArea,n=e.panes,o=bi(i.margin);e.box=t.clone().unpad(o),e.reflowPanes(),e.reflowAxes(n),e.reflowCharts(n)},redraw:function(t){var e,i=this;for(t=[].concat(t),this.initSeries(),e=0;e<t.length;e++)i.removeCrosshairs(t[e]),t[e].empty();for(i.render(t),i.reflowAxes(i.panes),i.reflowCharts(t),i.createCrosshairs(t),e=0;e<t.length;e++)t[e].refresh()},axisCrossingValues:function(t,e){var i,n=t.options,o=[].concat(n.axisCrossingValues||n.axisCrossingValue),r=e.length-o.length,s=o[0]||0;for(i=0;i<r;i++)o.push(s);return o},alignAxisTo:function(t,e,i,n){var o=t.getSlot(i,i,!0),r=t.options.reverse?2:1,s=e.getSlot(n,n,!0),a=e.options.reverse?2:1,l=t.box.translate(s[_r+a]-o[_r+r],s[yr+a]-o[yr+r]);t.pane!==e.pane&&l.translate(0,t.pane.box.y1-e.pane.box.y1),t.reflow(l)},alignAxes:function(t,e){var i,n,o,r,s,a,l=this,c=t[0],h=e[0],u=l.axisCrossingValues(c,e),d=l.axisCrossingValues(h,t),f={},p={},g={},m={};for(a=0;a<e.length;a++)s=e[a],o=s.pane,r=o.id,i=it(t,o)||c,n=u,i!==c&&(n=l.axisCrossingValues(i,e)),l.alignAxisTo(s,i,d[a],n[a]),s.options._overlap||(Ti(s.lineBox().x1)===Ti(i.lineBox().x1)&&(f[r]&&s.reflow(s.box.alignTo(f[r].box,$n).translate(-s.options.margin,0)),f[r]=s),Ti(s.lineBox().x2)===Ti(i.lineBox().x2)&&(s._mirrored||(s.options.labels.mirror=!s.options.labels.mirror,s._mirrored=!0),l.alignAxisTo(s,i,d[a],n[a]),p[r]&&s.reflow(s.box.alignTo(p[r].box,Do).translate(s.options.margin,0)),p[r]=s),0!==a&&h.pane===s.pane&&(s.alignTo(h),s.reflow(s.box)));for(a=0;a<t.length;a++)s=t[a],o=s.pane,r=o.id,i=it(e,o)||h,n=d,i!==h&&(n=l.axisCrossingValues(i,t)),l.alignAxisTo(s,i,u[a],n[a]),s.options._overlap||(Ti(s.lineBox().y1)===Ti(i.lineBox().y1)&&(s._mirrored||(s.options.labels.mirror=!s.options.labels.mirror,s._mirrored=!0),l.alignAxisTo(s,i,u[a],n[a]),g[r]&&s.reflow(s.box.alignTo(g[r].box,or).translate(0,-s.options.margin)),g[r]=s),Ti(s.lineBox().y2,un)===Ti(i.lineBox().y2,un)&&(m[r]&&s.reflow(s.box.alignTo(m[r].box,Ki).translate(0,s.options.margin)),m[r]=s),0!==a&&(s.alignTo(c),s.reflow(s.box)))},shrinkAxisWidth:function(t){var e,i,n,o=this,r=o.groupAxes(t).any,s=A(r),a=0;for(e=0;e<t.length;e++)i=t[e],i.axes.length>0&&(a=Ve.max(a,s.width()-i.contentBox.width()));if(0!==a)for(e=0;e<r.length;e++)n=r[e],n.options.vertical||n.reflow(n.box.shrink(a,0))},shrinkAxisHeight:function(t){var e,i,n,o,r,s,a;for(e=0;e<t.length;e++)if(i=t[e],n=i.axes,o=Ve.max(0,A(n).height()-i.contentBox.height()),0!==o){for(r=0;r<n.length;r++)s=n[r],s.options.vertical&&s.reflow(s.box.shrink(0,o));a=!0}return a},fitAxes:function(t){var e,i,n,o,r,s,a,l,c=this,h=c.groupAxes(t).any,u=0;for(a=0;a<t.length;a++)if(r=t[a],e=r.axes,i=r.contentBox,e.length>0)for(n=A(e),u=Ve.max(u,i.x1-n.x1),o=Ve.max(i.y1-n.y1,i.y2-n.y2),l=0;l<e.length;l++)s=e[l],s.reflow(s.box.translate(0,o));for(a=0;a<h.length;a++)s=h[a],s.reflow(s.box.translate(u,0))},reflowAxes:function(t){var e,i=this,n=i.groupAxes(t);for(e=0;e<t.length;e++)i.reflowPaneAxes(t[e]);n.x.length>0&&n.y.length>0&&(i.alignAxes(n.x,n.y),i.shrinkAxisWidth(t),i.autoRotateAxisLabels(n),i.alignAxes(n.x,n.y),i.shrinkAxisWidth(t)&&i.alignAxes(n.x,n.y),i.shrinkAxisHeight(t),i.alignAxes(n.x,n.y),i.shrinkAxisHeight(t)&&i.alignAxes(n.x,n.y),i.fitAxes(t))},autoRotateAxisLabels:function(t){var e,i,n,o=this.axes,r=this.panes;for(i=0;i<o.length;i++)e=o[i],e.autoRotateLabels()&&(n=!0);if(n){for(i=0;i<r.length;i++)this.reflowPaneAxes(r[i]);t.x.length>0&&t.y.length>0&&(this.alignAxes(t.x,t.y),this.shrinkAxisWidth(r))}},reflowPaneAxes:function(t){var e,i=t.axes,n=i.length;if(n>0)for(e=0;e<n;e++)i[e].reflow(t.contentBox)},reflowCharts:function(t){var e,i,n=this,o=n.charts,r=o.length,s=n.box;for(i=0;i<r;i++)e=o[i].pane,e&&!ki(e,t)||o[i].reflow(s)},reflowPanes:function(){var t,e,i,n,o,r=this,s=r.box,a=r.panes,l=a.length,c=s.height(),h=l,u=0,d=s.y1;for(t=0;t<l;t++)e=a[t],n=e.options.height,e.options.width=s.width(),e.options.height?(n.indexOf&&n.indexOf("%")&&(o=parseInt(n,10)/100,e.options.height=o*s.height()),e.reflow(s.clone()),c-=e.options.height):u++;for(t=0;t<l;t++)e=a[t],e.options.height||(e.options.height=c/u);for(t=0;t<l;t++)e=a[t],i=s.clone().move(s.x1,d),e.reflow(i),h--,d+=e.options.height},backgroundBox:function(){var t,e,i,n,o,r,s=this,a=s.axes,l=a.length;for(i=0;i<l;i++)for(o=a[i],n=0;n<l;n++)r=a[n],o.options.vertical!==r.options.vertical&&(t=o.lineBox().clone().wrap(r.lineBox()),e=e?e.wrap(t):t);return e||s.box},chartsBoxes:function(){var t,e=this.panes,i=[];for(t=0;t<e.length;t++)i.push(e[t].chartsBox());return i},addBackgroundPaths:function(t){var e,i=this.chartsBoxes();for(e=0;e<i.length;e++)t.paths.push(Vi.Path.fromRect(i[e].toRect()))},backgroundContainsPoint:function(t){var e,i=this.chartsBoxes();for(e=0;e<i.length;e++)if(i[e].containsPoint(t))return!0},createVisual:function(){var t,e,i,n,o;oi.fn.createVisual.call(this),t=this.options.plotArea,e=t.border||{},i=t.background,n=t.opacity,Ai.isTransparent(i)&&(i=vr,n=0),o=this._bgVisual=new Vi.MultiPath({fill:{color:i,opacity:n},stroke:{color:e.width?e.color:"",width:e.width,dashType:e.dashType},zIndex:-1}),this.addBackgroundPaths(o),this.appendVisual(o)},pointsByCategoryIndex:function(t){var e,i,n,o,r,s=this.charts,a=[];if(null!==t)for(e=0;e<s.length;e++)if(r=s[e],"_navigator"!==r.pane.options.name&&(n=s[e].categoryPoints[t],n&&n.length))for(i=0;i<n.length;i++)o=n[i],o&&Di(o.value)&&null!==o.value&&a.push(o);return a},pointsBySeriesIndex:function(t){return this.filterPoints(function(e){return e.series.index===t})},pointsBySeriesName:function(t){return this.filterPoints(function(e){return e.series.name===t})},filterPoints:function(t){var e,i,n,o,r,s=this.charts,a=[];for(n=0;n<s.length;n++)for(r=s[n],e=r.points,o=0;o<e.length;o++)i=e[o],i&&t(i)&&a.push(i);return a},findPoint:function(t){var e,i,n,o,r,s=this.charts;for(n=0;n<s.length;n++)for(r=s[n],e=r.points,o=0;o<e.length;o++)if(i=e[o],i&&t(i))return i},paneByPoint:function(t){var e,i,n=this,o=n.panes;for(i=0;i<o.length;i++)if(e=o[i],e.box.containsPoint(t))return e}}),he={hover:function(t,e){this._dispatchEvent(t,e,Co)},click:function(t,e){this._dispatchEvent(t,e,ko)}},ue=ce.extend({init:function(t,e){var i,n,o=this;if(o.namedCategoryAxes={},o.namedValueAxes={},o.valueAxisRangeTracker=new de,t.length>0)for(o.invertAxes=ki(t[0].type,[Wi,tn,pr,ur,To,Nn,dr]),i=0;i<t.length;i++)if(n=t[i].stack,n&&"100%"===n.type){o.stack100=!0;break}ce.fn.init.call(o,t,e)},options:{categoryAxis:{categories:[]},valueAxis:{}},render:function(t){var e=this;t=t||e.panes,e.createCategoryAxes(t),e.aggregateCategories(t),e.createCategoryAxesLabels(t),e.createCharts(t),e.createValueAxes(t)},removeAxis:function(t){var e=this,i=t.options.name;ce.fn.removeAxis.call(e,t),t instanceof ct?delete e.namedCategoryAxes[i]:(e.valueAxisRangeTracker.reset(i),delete e.namedValueAxes[i]),t===e.categoryAxis&&delete e.categoryAxis,t===e.valueAxis&&delete e.valueAxis},createCharts:function(t){var e,i,n,o,r,s,a=this.groupSeriesByPane();for(e=0;e<t.length;e++)if(i=t[e],n=a[i.options.name||"default"]||[],this.addToLegend(n),o=this.filterVisibleSeries(n))for(r=this.groupSeriesByCategoryAxis(o),s=0;s<r.length;s++)this.createChartGroup(r[s],i)},createChartGroup:function(t,e){this.createAreaChart(V(t,[Hi,ur]),e),this.createBarChart(V(t,[hn,Wi]),e),this.createRangeBarChart(V(t,[Ao,To]),e),this.createBulletChart(V(t,[tn,fr]),e),this.createCandlestickChart(V(t,en),e),this.createBoxPlotChart(V(t,[Zi,dr]),e),this.createOHLCChart(V(t,yo),e),this.createWaterfallChart(V(t,[gr,Nn]),e),this.createLineChart(V(t,[Qn,pr]),e)},aggregateCategories:function(t){var e,i,n,o,r,s=this,a=s.srcSeries||s.series,l=[];for(e=0;e<a.length;e++)i=a[e],n=s.seriesCategoryAxis(i),o=s.findPane(n.options.pane),r=P(n.options.type,mn),(r||i.categoryField)&&ki(o,t)?i=s.aggregateSeries(i,n):(I(n.options.min)||I(n.options.max))&&(i=s.filterSeries(i,n)),l.push(i);s.srcSeries=a,s.series=l},filterSeries:function(t,e){var i,n,o,r=e.totalRangeIndices(),s=e.options.justified,a=ki(t.type,[Qn,pr,Hi,ur]);return r.min=I(e.options.min)?Ve.floor(r.min):0,r.max=I(e.options.max)?s?Ve.floor(r.max)+1:Ve.ceil(r.max):t.data.length,t=$e({},t),a&&(n=r.min-1,o=e.options.srcCategories||[],n>=0&&n<t.data.length&&(i=n,t._outOfRangeMinPoint={item:t.data[i],category:o[i],categoryIx:-1}),r.max<t.data.length&&(i=r.max,t._outOfRangeMaxPoint={item:t.data[i],category:o[i],categoryIx:r.max-r.min})),e._seriesMax=Ve.max(e._seriesMax||0,t.data.length),t.data=(t.data||[]).slice(r.min,r.max),t},aggregateSeries:function(t,e){var i,o,r,s,a,l,c,h=e.options,u=P(e.options.type,mn),p=h.categories,g=h.srcCategories||p,m=t.data,v=[],_=$e({},t),y=$e({},t),w=h.dataItems||[],x=d,b=Ai.MIN_NUM,k=Ai.MAX_NUM,C=ki(t.type,[Qn,pr,Hi,ur]);for(_.data=s=[],u&&(x=f),i=0;i<m.length;i++)o=t.categoryField?x(t.categoryField,m[i]):g[i],Di(o)&&(r=e.categoryIndex(o),0<=r&&r<p.length?(v[r]=v[r]||[],v[r].push(i)):C&&(r<0?r==b?l.points.push(i):r>b&&(b=r,l={category:o,points:[i]}):r>=p.length&&(r==k?c.points.push(i):r<k&&(k=r,c={category:o,points:[i]}))));for(a=new De(y,ot.current,n.current),i=0;i<p.length;i++)s[i]=a.aggregatePoints(v[i],p[i]),v[i]&&(w[i]=s[i]);return l&&s.length&&(_._outOfRangeMinPoint={item:a.aggregatePoints(l.points,l.category),categoryIx:b,category:l.category}),c&&s.length&&(_._outOfRangeMaxPoint={item:a.aggregatePoints(c.points,c.category),categoryIx:k,category:c.category}),e.options.dataItems=w,_},appendChart:function(t,e){for(var i=this,n=t.options.series,o=i.seriesCategoryAxis(n[0]),r=o.options.categories,s=Ve.max(0,h(n)-r.length);s--;)r.push("");i.valueAxisRangeTracker.update(t.valueAxisRanges),ce.fn.appendChart.call(i,t,e)},seriesPaneName:function(e){var i=this,n=i.options,o=e.axis,r=[].concat(n.valueAxis),s=t.grep(r,function(t){return t.name===o})[0],a=n.panes||[{}],l=(a[0]||{}).name||"default",c=(s||{}).pane||l;return c},seriesCategoryAxis:function(t){var e=this,i=t.categoryAxis,n=i?e.namedCategoryAxes[i]:e.categoryAxis;if(!n)throw Error("Unable to locate category axis with name "+i);return n},stackableChartOptions:function(t,e){var i=t.stack,n=i&&"100%"===i.type,o=e.options.clip;return{isStacked:i,isStacked100:n,clip:o}},groupSeriesByCategoryAxis:function(e){function i(i,n){return t.grep(e,function(t){return 0===n&&!t.categoryAxis||t.categoryAxis==i})}var n,o,r,s={},a=t.map(e,function(t){var e=t.categoryAxis||"$$default$$";if(!s.hasOwnProperty(e))return s[e]=!0,e}),l=[];for(n=0;n<a.length;n++)o=a[n],r=i(o,n),0!==r.length&&l.push(r);return l},createBarChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new xt(i,Ne({series:t,invertAxes:i.invertAxes,gap:n.gap,spacing:n.spacing},i.stackableChartOptions(n,e)));i.appendChart(o,e)}},createRangeBarChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new kt(i,{series:t,invertAxes:i.invertAxes,gap:n.gap,spacing:n.spacing});i.appendChart(o,e)}},createBulletChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Ct(i,{series:t,invertAxes:i.invertAxes,gap:n.gap,spacing:n.spacing,clip:e.options.clip});i.appendChart(o,e)}},createLineChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Lt(i,Ne({invertAxes:i.invertAxes,series:t},i.stackableChartOptions(n,e)));i.appendChart(o,e)}},createAreaChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Ht(i,Ne({invertAxes:i.invertAxes,series:t},i.stackableChartOptions(n,e)));i.appendChart(o,e)}},createOHLCChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Qt(i,{invertAxes:i.invertAxes,gap:n.gap,series:t,spacing:n.spacing,clip:e.options.clip});i.appendChart(o,e)}},createCandlestickChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Yt(i,{invertAxes:i.invertAxes,gap:n.gap,series:t,spacing:n.spacing,clip:e.options.clip});i.appendChart(o,e)}},createBoxPlotChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new Kt(i,{invertAxes:i.invertAxes,gap:n.gap,series:t,spacing:n.spacing,clip:e.options.clip});i.appendChart(o,e)}},createWaterfallChart:function(t,e){if(0!==t.length){var i=this,n=t[0],o=new re(i,{series:t,invertAxes:i.invertAxes,gap:n.gap,spacing:n.spacing});i.appendChart(o,e)}},axisRequiresRounding:function(t,e){var i,n,o,r,s=this,a=V(s.series,Ar);for(i=0;i<s.series.length;i++)o=s.series[i],o.type!==Qn&&o.type!==Hi||(r=o.line,r&&r.style===Uo&&a.push(o));for(i=0;i<a.length;i++)if(n=a[i].categoryAxis||"",n===t||!n&&0===e)return!0},aggregatedAxis:function(t,e){var i,n,o=this,r=o.series;for(i=0;i<r.length;i++)if(n=r[i].categoryAxis||"",(n===t||!n&&0===e)&&r[i].categoryField)return!0},createCategoryAxesLabels:function(){var t,e=this.axes;for(t=0;t<e.length;t++)e[t]instanceof ct&&e[t].createLabels()},createCategoryAxes:function(t){var e,i,n,o,r,s,a,l,c=this,h=c.invertAxes,u=[].concat(c.options.categoryAxis),d=[];for(e=0;e<u.length;e++)if(i=u[e],n=c.findPane(i.pane),ki(n,t)){if(s=i.name,o=i.categories||[],r=i.type||"",i=$e({vertical:h,axisCrossingValue:h?io:0,_deferLabels:!0},i),Di(i.justified)||(i.justified=c.isJustified()),c.axisRequiresRounding(s,e)&&(i.justified=!1),a=U(i,o[0])?new ht(i):new ct(i),s){if(c.namedCategoryAxes[s])throw Error("Category axis with name "+s+" is already defined");c.namedCategoryAxes[s]=a}a.axisIndex=e,d.push(a),c.appendAxis(a)}l=c.categoryAxis||d[0],c.categoryAxis=l,h?c.axisY=l:c.axisX=l},isJustified:function(){var t,e,i=this,n=i.series;for(t=0;t<n.length;t++)if(e=n[t],!ki(e.type,[Hi,ur]))return!1;return!0},createValueAxes:function(t){var e,i,n,o,r,s,a,l,c,h=this,u=h.valueAxisRangeTracker,d=u.query(),f=[].concat(h.options.valueAxis),p=h.invertAxes,g={vertical:!p},m=[];for(h.stack100&&(g.roundToMajorUnit=!1,g.labels={format:"P0"}),c=0;c<f.length;c++)if(e=f[c],i=h.findPane(e.pane),ki(i,t)){if(l=e.name,a=P(e.type,Jn)?{min:.1,max:1}:{min:0,max:1},r=u.query(l)||d||a,0===c&&r&&d&&(r.min=Ve.min(r.min,d.min),r.max=Ve.max(r.max,d.max)),s=P(e.type,Jn)?ci:hi,n=new s(r.min,r.max,$e({},g,e)),l){if(h.namedValueAxes[l])throw Error("Value axis with name "+l+" is already defined");h.namedValueAxes[l]=n}n.axisIndex=c,m.push(n),h.appendAxis(n)}o=h.valueAxis||m[0],h.valueAxis=o,p?h.axisX=o:h.axisY=o},_dispatchEvent:function(t,e,i){var n,o,r,s=this,a=t._eventCoordinates(e),l=new ui(a.x,a.y),c=s.pointPane(l),h=[],u=[];if(c){for(n=c.axes,o=0;o<n.length;o++)r=n[o],r.getValue?M(u,r.getValue(l)):M(h,r.getCategory(l));0===h.length&&M(h,s.categoryAxis.getCategory(l)),h.length>0&&u.length>0&&t.trigger(i,{element:xi(e),originalEvent:e,category:T(h),value:T(u)})}},pointPane:function(t){var e,i,n=this,o=n.panes;for(i=0;i<o.length;i++)if(e=o[i],e.contentBox.containsPoint(t))return e},updateAxisOptions:function(t,e){var i=[].concat(t instanceof ct?this.options.categoryAxis:this.options.valueAxis);$e(i[t.axisIndex],e)}}),$e(ue.fn,he),de=je.extend({init:function(){var t=this;t.axisRanges={}},update:function(t){var e,i,n,o=this,r=o.axisRanges;for(n in t)e=r[n],i=t[n],r[n]=e=e||{min:io,max:ro},e.min=Ve.min(e.min,i.min),e.max=Ve.max(e.max,i.max)},reset:function(t){this.axisRanges[t]=e},query:function(t){return this.axisRanges[t]}}),fe=ce.extend({init:function(t,e){var i=this;i.namedXAxes={},i.namedYAxes={},i.xAxisRangeTracker=new de,i.yAxisRangeTracker=new de,ce.fn.init.call(i,t,e)},options:{xAxis:{},yAxis:{}},render:function(t){var e,i,n,o,r=this,s=r.groupSeriesByPane();for(t=t||r.panes,e=0;e<t.length;e++)i=t[e],n=s[i.options.name||"default"]||[],r.addToLegend(n),o=r.filterVisibleSeries(n),o&&(r.createScatterChart(V(o,Io),i),r.createScatterLineChart(V(o,Bo),i),r.createBubbleChart(V(o,Ji),i));r.createAxes(t)},appendChart:function(t,e){var i=this;i.xAxisRangeTracker.update(t.xAxisRanges),i.yAxisRangeTracker.update(t.yAxisRanges),ce.fn.appendChart.call(i,t,e)},removeAxis:function(t){var e=this,i=t.options.name;ce.fn.removeAxis.call(e,t),t.options.vertical?(e.yAxisRangeTracker.reset(i),delete e.namedYAxes[i]):(e.xAxisRangeTracker.reset(i),delete e.namedXAxes[i]),t===e.axisX&&delete e.axisX,t===e.axisY&&delete e.axisY},seriesPaneName:function(e){var i=this,n=i.options,o=e.xAxis,r=[].concat(n.xAxis),s=t.grep(r,function(t){return t.name===o})[0],a=e.yAxis,l=[].concat(n.yAxis),c=t.grep(l,function(t){return t.name===a})[0],h=n.panes||[{}],u=h[0].name||"default",d=(s||{}).pane||(c||{}).pane||u;return d},createScatterChart:function(t,e){var i=this;t.length>0&&i.appendChart(new Gt(i,{series:t,clip:e.options.clip}),e)},createScatterLineChart:function(t,e){var i=this;t.length>0&&i.appendChart(new Wt(i,{series:t,clip:e.options.clip}),e)},createBubbleChart:function(t,e){var i=this;t.length>0&&i.appendChart(new qt(i,{series:t,clip:e.options.clip}),e)},createXYAxis:function(t,e,i){var n,o,r,s,a,l,c,h,u=this,d=t.name,f=e?u.namedYAxes:u.namedXAxes,p=e?u.yAxisRangeTracker:u.xAxisRangeTracker,g=$e({},t,{vertical:e}),m=P(g.type,Jn),v=p.query(),_=m?{min:.1,max:1}:{min:0,max:1},y=p.query(d)||v||_,w=u.series,x=[g.min,g.max];for(r=0;r<w.length;r++)if(s=w[r],a=s[e?"yAxis":"xAxis"],a==g.name||0===i&&!a){l=ot.current.bindPoint(s,0).valueFields,x.push(l[e?"y":"x"]);break}for(0===i&&v&&(y.min=Ve.min(y.min,v.min),y.max=Ve.max(y.max,v.max)),h=0;h<x.length;h++)if(x[h]instanceof Date){c=!0;break}if(o=P(g.type,mn)||!g.type&&c?ut:m?ci:hi,n=new o(y.min,y.max,g),d){if(f[d])throw Error((e?"Y":"X")+" axis with name "+d+" is already defined");f[d]=n}return u.appendAxis(n),n},createAxes:function(t){var e,i=this,n=i.options,o=[].concat(n.xAxis),r=[],s=[].concat(n.yAxis),a=[];ze(o,function(n){e=i.findPane(this.pane),ki(e,t)&&r.push(i.createXYAxis(this,!1,n))}),ze(s,function(n){e=i.findPane(this.pane),ki(e,t)&&a.push(i.createXYAxis(this,!0,n))}),i.axisX=i.axisX||r[0],i.axisY=i.axisY||a[0]},_dispatchEvent:function(t,e,i){var n,o,r,s,a=this,l=t._eventCoordinates(e),c=new ui(l.x,l.y),h=a.axes,u=h.length,d=[],f=[];for(n=0;n<u;n++)o=h[n],s=o.options.vertical?f:d,r=o.getValue(c),null!==r&&s.push(r);d.length>0&&f.length>0&&t.trigger(i,{element:xi(e),originalEvent:e,x:T(d),y:T(f)})},updateAxisOptions:function(t,e){var i=t.options.vertical,n=this.groupAxes(this.panes),o=F(t,i?n.y:n.x),r=[].concat(i?this.options.yAxis:this.options.xAxis)[o];$e(r,e)}}),$e(fe.fn,he),pe=ce.extend({render:function(){var t=this,e=t.series;t.createPieChart(e)},createPieChart:function(t){var e=this,i=t[0],n=new ie(e,{series:t,padding:i.padding,startAngle:i.startAngle,connectors:i.connectors,legend:e.options.legend});e.appendChart(n)},appendChart:function(t,e){ce.fn.appendChart.call(this,t,e),Pi(this.options.legend.items,t.legendItems)}}),ge=pe.extend({render:function(){var t=this,e=t.series;t.createDonutChart(e)},createDonutChart:function(t){var e=this,i=t[0],n=new oe(e,{series:t,padding:i.padding,connectors:i.connectors,legend:e.options.legend});e.appendChart(n)}}),me=Vi.Animation.extend({options:{easing:"easeOutElastic",duration:Un},setup:function(){this.element.transform(Oi.transform().scale(Ho,Ho,this.options.center))},step:function(t){this.element.transform(Oi.transform().scale(t,t,this.options.center))}}),Vi.AnimationFactory.current.register(xo,me),ve=Vi.Animation.extend({options:{easing:"easeOutElastic"},setup:function(){var t=this.center=this.element.bbox().center();this.element.transform(Oi.transform().scale(Ho,Ho,t))},step:function(t){this.element.transform(Oi.transform().scale(t,t,this.center))}}),Vi.AnimationFactory.current.register(Ji,ve),_e=je.extend({init:function(){this._points=[]},destroy:function(){this._points=[]},show:function(t){var e,i;for(t=[].concat(t),this.hide(),e=0;e<t.length;e++)i=t[e],i&&i.toggleHighlight&&i.hasHighlight()&&(this.togglePointHighlight(i,!0),this._points.push(i))},togglePointHighlight:function(t,e){var i,n=(t.options.highlight||{}).toggle;n?(i={category:t.category,series:t.series,dataItem:t.dataItem,value:t.value,stackValue:t.stackValue,preventDefault:Y,visual:t.highlightVisual(),show:e},n(i),i._defaultPrevented||t.toggleHighlight(e)):t.toggleHighlight(e)},hide:function(){for(var t=this._points;t.length;)this.togglePointHighlight(t.pop(),!1)},isHighlighted:function(t){var e,i,n=this._points;for(e=0;e<n.length;e++)if(i=n[e],t==i)return!0;return!1}}),ye=Ge.extend({init:function(e,i){var n,o,r=this;Ge.fn.init.call(r),r.options=$e({},r.options,i),r.chartElement=e,r.template=ye.template,r.template||(r.template=ye.template=Li("<div class='"+fn+"tooltip "+fn+"chart-tooltip' style='display:none; position: absolute; font: #= d.font #;border: #= d.border.width #px solid;opacity: #= d.opacity #; filter: alpha(opacity=#= d.opacity * 100 #);'></div>")),n=bi(r.options.padding||{},"auto"),r.element=t(r.template(r.options)).css({"padding-top":n.top,"padding-right":n.right,"padding-bottom":n.bottom,"padding-left":n.left}),r.move=He(r.move,r),r._mouseleave=He(r._mouseleave,r),o=Ue.format("[{0}='content'],[{0}='scroller']",Ue.attr("role")),r._mobileScroller=e.closest(o).data("kendoMobileScroller")},destroy:function(){this._clearShowTimeout(),this.element&&(this.element.off(lo).remove(),this.element=null)},options:{border:{width:1},opacity:1,animation:{duration:rr}},move:function(){var t,e=this,i=e.options,n=e.element;e.anchor&&e.element&&(t=e._offset(),e.visible||n.css({top:t.top,left:t.left}),e.visible=!0,e._ensureElement(document.body),n.stop(!0,!0).show().animate({left:t.left,top:t.top},i.animation.duration))},_clearShowTimeout:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=null)},_padding:function(){if(!this._chartPadding){var t=this.chartElement;this._chartPadding={top:parseInt(t.css("paddingTop"),10),left:parseInt(t.css("paddingLeft"),10)}}return this._chartPadding},_offset:function(){var e,i,n=this,o=n._measure(),r=n.anchor,s=n._padding(),a=n.chartElement.offset(),l=Ti(r.y+s.top+a.top),c=Ti(r.x+s.left+a.left),h=Ue.support.zoomLevel(),u=t(window),d=window.pageYOffset||document.documentElement.scrollTop||0,f=window.pageXOffset||document.documentElement.scrollLeft||0,p=(this._mobileScroller||{}).movable;return p&&1!==p.scale?(e=Oi.transform().scale(p.scale,p.scale,[p.x,p.y]),i=new Oi.Point(c,l).transform(e),c=i.x,l=i.y):(l+=n._fit(l-d,o.height,Ze(u)/h),c+=n._fit(c-f,o.width,Ke(u)/h)),{top:l,left:c}},setStyle:function(t,e){var i,n,o=t.background,r=t.border.color;e&&(i=e.color||e.options.color,o=Ri(o,i),r=Ri(r,i)),Di(t.color)||(n=new ri(o).percBrightness(),this.element.toggleClass(fn+cr,n>180)),this.element.css({backgroundColor:o,borderColor:r,font:t.font,color:t.color,opacity:t.opacity,borderWidth:t.border.width})},show:function(){this._clearShowTimeout(),this.showTimeout=setTimeout(this.move,ar)},hide:function(){var t=this;clearTimeout(t.showTimeout),t._hideElement(),t.visible&&(t.point=null,t.visible=!1,t.index=null)},_measure:function(){this._ensureElement();var t={width:Ke(this.element),height:Ze(this.element)};return t},_ensureElement:function(){this.element&&this.element.appendTo(document.body).on(lo,this._mouseleave)},_mouseleave:function(e){var i=e.relatedTarget,n=this.chartElement[0];i&&i!==n&&!t.contains(n,i)&&(this.trigger(qn),this.hide())},_hideElement:function(){var t=this,e=this.element;e&&e.fadeOut({always:function(){t.visible||e.off(lo).remove()}})},_pointContent:function(t){var e,i,n=this,o=$e({},n.options,t.options.tooltip);return Di(t.value)&&(e=""+t.value),o.template?(i=Qe(o.template),e=i({value:t.value,category:t.category,series:t.series,dataItem:t.dataItem,percentage:t.percentage,runningTotal:t.runningTotal,total:t.total,low:t.low,high:t.high,xLow:t.xLow,xHigh:t.xHigh,yLow:t.yLow,yHigh:t.yHigh})):o.format&&(e=t.formatValue(o.format)),e},_pointAnchor:function(t){var e=this._measure();return t.tooltipAnchor(e.width,e.height)},_fit:function(t,e,i){var n=0;return t+e>i&&(n=i-(t+e)),t<0&&(n=-t),n}}),we=ye.extend({show:function(t){var e=this,i=$e({},e.options,t.options.tooltip);t&&t.tooltipAnchor&&e.element&&(e.element.html(e._pointContent(t)),e.anchor=e._pointAnchor(t),e.anchor?(e.setStyle(i,t),ye.fn.show.call(e,t)):e.hide())}}),xe=ye.extend({init:function(t,e,i){var n=this;ye.fn.init.call(n,t,i),n.plotArea=e},options:{sharedTemplate:"<table><th colspan='2'>#= categoryText #</th># for(var i = 0; i < points.length; i++) { ## var point = points[i]; #<tr># if(point.series.name) { # <td> #= point.series.name #:</td># } #<td>#= content(point) #</td></tr># } #</table>",categoryFormat:"{0:d}"},showAt:function(e,i){var n,o,r;e=t.grep(e,function(t){var e=t.series.tooltip,i=e&&e.visible===!1;return!i}),e.length>0&&(n=e[0],o=this.plotArea.categoryAxis.getSlot(n.categoryIx),r=this._content(e,n.category),this.element.html(r),this.anchor=i?this._slotAnchor(i,o):this._defaultAnchor(n,o),this.setStyle(this.options,n),ye.fn.show.call(this))},_slotAnchor:function(t,e){var i,n=this,o=n.plotArea,r=o.categoryAxis,s=this._measure(),a=t.y-s.height/2;return i=r.options.vertical?ui(t.x,a):ui(e.center().x,a)},_defaultAnchor:function(t,e){var i,n=t.owner.pane.chartsBox(),o=this.plotArea.categoryAxis.options.vertical,r=n.center(),s=e.center(),a=this._measure();return i=o?new ui(r.x,s.y):new ui(s.x,r.y),i.x-=a.width/2,i.y-=a.height/2,i},_content:function(t,e){var i,n,o=this;return i=Ue.template(o.options.sharedTemplate),n=i({points:t,category:e,categoryText:yi(o.options.categoryFormat,e),content:o._pointContent})}}),be=oi.extend({init:function(t,e){oi.fn.init.call(this,e),this.axis=t,this.stickyMode=t instanceof ct},options:{color:Xi,width:1,zIndex:-1,tooltip:{visible:!1}},showAt:function(t){this.point=t,this.moveLine(),this.line.visible(!0);var e=this.options.tooltip;e.visible&&(this.tooltip||(this.tooltip=new ke(this,$e({},e,{stickyMode:this.stickyMode}))),this.tooltip.showAt(t))},hide:function(){this.line.visible(!1),this.tooltip&&this.tooltip.hide()},moveLine:function(){var t,e,i,n=this,o=n.axis,r=o.options.vertical,s=n.getBox(),a=n.point,l=r?yr:_r;e=new Oi.Point(s.x1,s.y1),i=r?new Oi.Point(s.x2,s.y1):new Oi.Point(s.x1,s.y2),a&&(n.stickyMode?(t=o.getSlot(o.pointCategoryIndex(a)),e[l]=i[l]=t.center()[l]):e[l]=i[l]=a[l]),n.box=s,this.line.moveTo(e).lineTo(i)},getBox:function(){var t,e,i,n=this,o=n.axis,r=o.pane.axes,s=r.length,a=o.options.vertical,l=o.lineBox().clone(),c=a?_r:yr;for(i=0;i<s;i++)e=r[i],e.options.vertical!=a&&(t?t.wrap(e.lineBox()):t=e.lineBox().clone());return l[c+1]=t[c+1],l[c+2]=t[c+2],l},createVisual:function(){oi.fn.createVisual.call(this);var t=this.options;this.line=new Vi.Path({stroke:{color:t.color,width:t.width,opacity:t.opacity,dashType:t.dashType},visible:!1}),this.moveLine(),this.visual.append(this.line)},destroy:function(){var t=this;t.tooltip&&t.tooltip.destroy(),oi.fn.destroy.call(t)}}),ke=ye.extend({init:function(t,e){var i=this,n=t.axis.getRoot().chart.element;i.crosshair=t,ye.fn.init.call(i,n,$e({},i.options,{background:t.axis.plotArea.options.seriesColors[0]},e)),i.setStyle(i.options)},options:{padding:10},showAt:function(t){var e=this,i=e.element;i&&(e.point=t,e.element.html(e.content(t)),e.anchor=e.getAnchor(),e.move())},move:function(){var t=this,e=t.element,i=t._offset();t._ensureElement(),e.css({top:i.top,left:i.left}).show()},content:function(t){var e,i,n,o=this,r=o.options,s=o.crosshair.axis,a=s.options;return i=e=s[r.stickyMode?"getCategory":"getValue"](t),r.template?(n=Qe(r.template),e=n({value:i})):r.format?e=yi(r.format,i):a.type===mn&&(e=yi(a.labels.dateFormats[a.baseUnit],i)),e},getAnchor:function(){var t,e=this,i=e.options,n=i.position,o=this.crosshair,r=!o.axis.options.vertical,s=o.line.bbox(),a=this._measure(),l=a.width/2,c=a.height/2,h=i.padding;return t=r?n===Ki?s.bottomLeft().translate(-l,h):s.topLeft().translate(-l,-a.height-h):n===$n?s.topLeft().translate(-a.width-h,-c):s.topRight().translate(h,-c)},hide:function(){this.element.hide(),this.point=null},destroy:function(){ye.fn.destroy.call(this),this.point=null}}),Ce={min:function(t){var e,i,n=io,o=t.length;for(e=0;e<o;e++)i=t[e],I(i)&&(n=Ve.min(n,i));return n===io?t[0]:n},max:function(t){var e,i,n=ro,o=t.length;for(e=0;e<o;e++)i=t[e],I(i)&&(n=Ve.max(n,i));return n===ro?t[0]:n},sum:function(t){var e,i,n=t.length,o=0;for(e=0;e<n;e++)i=t[e],I(i)&&(o+=i);return o},sumOrNull:function(t){var e=null;return B(t)&&(e=Ce.sum(t)),e},count:function(t){var e,i,n=t.length,o=0;for(e=0;e<n;e++)i=t[e],null!==i&&Di(i)&&o++;return o},avg:function(t){var e=t[0],i=B(t);return i>0&&(e=Ce.sum(t)/i),e},first:function(t){var e,i,n=t.length;for(e=0;e<n;e++)if(i=t[e],null!==i&&Di(i))return i;return t[0]}},n.prototype={register:function(t,e){for(var i=0;i<t.length;i++)this._defaults[t[i]]=e},query:function(t){return this._defaults[t]}},n.current=new n,Se=Ge.extend({init:function(e,i,n){var o,r,s=this,a=e.element,l=i.lineBox(),c=s.getValueAxis(i),h=c.lineBox(),u="."+fn;Ge.fn.init.call(s),s.options=$e({},s.options,n),n=s.options,s.chart=e,s.chartElement=a,s.categoryAxis=i,s._dateAxis=s.categoryAxis instanceof ht,s.valueAxis=c,s._dateAxis&&$e(n,{min:p(n.min),max:p(n.max),from:p(n.from),to:p(n.to)}),s.template=Se.template,s.template||(s.template=Se.template=Li("<div class='"+fn+"selector' style='width: #= d.width #px; height: #= d.height #px; top: #= d.offset.top #px; left: #= d.offset.left #px;'><div class='"+fn+"mask'></div><div class='"+fn+"mask'></div><div class='"+fn+"selection'><div class='"+fn+"selection-bg'></div><div class='"+fn+"handle "+fn+"leftHandle'><div></div></div><div class='"+fn+"handle "+fn+"rightHandle'><div></div></div></div></div>")),r={left:parseInt(a.css("paddingLeft"),10),right:parseInt(a.css("paddingTop"),10)},s.options=$e({},{width:l.width(),height:h.height(),padding:r,offset:{left:h.x2+r.left,top:h.y1+r.right},from:n.min,to:n.max},n),s.options.visible&&(s.wrapper=o=t(s.template(s.options)).appendTo(a),s.selection=o.find(u+"selection"),s.leftMask=o.find(u+"mask").first(),s.rightMask=o.find(u+"mask").last(),s.leftHandle=o.find(u+"leftHandle"),s.rightHandle=o.find(u+"rightHandle"),s.options.selection={border:{left:parseFloat(s.selection.css("border-left-width"),10),right:parseFloat(s.selection.css("border-right-width"),10)}},s.leftHandle.css("top",(s.selection.height()-s.leftHandle.height())/2),s.rightHandle.css("top",(s.selection.height()-s.rightHandle.height())/2),s.set(s._index(n.from),s._index(n.to)),s.bind(s.events,s.options),s.wrapper[0].style.cssText=s.wrapper[0].style.cssText,s.options.mousewheel!==!1?s.wrapper.on(po,He(s._mousewheel,s)):s.wrapper.on(po,function(t){t.stopPropagation()}),Ue.UserEvents?s.userEvents=new Ue.UserEvents(s.wrapper,{global:!0,stopPropagation:!0,multiTouch:!0,fastTap:!0,press:He(s._press,s),start:He(s._start,s),move:He(s._move,s),end:He(s._end,s),tap:He(s._tap,s),gesturestart:He(s._gesturechange,s),gesturechange:He(s._gesturechange,s)}):s.leftHandle.add(s.rightHandle).removeClass(fn+"handle"))},events:[Ro,Oo,Vo],options:{visible:!0,mousewheel:{zoom:Qi},min:ro,max:io},destroy:function(){var t=this,e=t.userEvents;e&&e.destroy(),clearTimeout(t._mwTimeout),t._state=null,t.wrapper&&t.wrapper.remove()},_rangeEventArgs:function(t){var e=this;return{axis:e.categoryAxis.options,from:e._value(t.from),to:e._value(t.to)}},_start:function(e){var i,n=this,o=n.options,r=t(e.event.target);!n._state&&r&&(n.chart._unsetActivePoint(),n._state={moveTarget:r.parents(".k-handle").add(r).first(),startLocation:e.x?e.x.location:0,range:{from:n._index(o.from),to:n._index(o.to)}},i=n._rangeEventArgs({from:n._index(o.from),to:n._index(o.to)}),n.trigger(Ro,i)&&(n.userEvents.cancel(),n._state=null))},_press:function(e){var i,n;this._state?i=this._state.moveTarget:(n=t(e.event.target),i=n.parents(".k-handle").add(n).first()),i.addClass("k-handle-active")},_move:function(t){if(this._state){var e=this,i=e._state,n=e.options,o=e.categoryAxis.options.categories,r=e._index(n.from),s=e._index(n.to),a=e._index(n.min),l=e._index(n.max),c=i.startLocation-t.x.location,h=i.range,u={from:h.from,to:h.to},d=h.to-h.from,f=i.moveTarget,p=e.wrapper.width()/(o.length-1),g=Ve.round(c/p);f&&(t.preventDefault(),f.is(".k-selection, .k-selection-bg")?(h.from=Ve.min(Ve.max(a,r-g),l-d),h.to=Ve.min(h.from+d,l)):f.is(".k-leftHandle")?(h.from=Ve.min(Ve.max(a,r-g),l-1),h.to=Ve.max(h.from+1,h.to)):f.is(".k-rightHandle")&&(h.to=Ve.min(Ve.max(a+1,s-g),l),
h.from=Ve.min(h.to-1,h.from)),h.from===u.from&&h.to===u.to||(e.move(h.from,h.to),e.trigger(Oo,e._rangeEventArgs(h))))}},_end:function(){var t,e=this._state.range;this._state&&(t=this._state.moveTarget,t&&t.removeClass("k-handle-active"),delete this._state),this.set(e.from,e.to),this.trigger(Vo,this._rangeEventArgs(e))},_gesturechange:function(t){if(this._state){var e=this,i=e.chart,n=e._state,o=e.options,r=e.categoryAxis,s=n.range,a=i._toModelCoordinates(t.touches[0].x.location).x,l=i._toModelCoordinates(t.touches[1].x.location).x,c=Ve.min(a,l),h=Ve.max(a,l);t.preventDefault(),n.moveTarget=null,s.from=r.pointCategoryIndex(new Je.Point2D(c))||o.min,s.to=r.pointCategoryIndex(new Je.Point2D(h))||o.max,e.move(s.from,s.to)}},_tap:function(t){var e=this,i=e.options,n=e.chart._eventCoordinates(t),o=e.categoryAxis,r=o.pointCategoryIndex(new Je.Point2D(n.x,o.box.y1)),s=e._index(i.from),a=e._index(i.to),l=e._index(i.min),c=e._index(i.max),h=a-s,u=s+h/2,d=Ve.round(u-r),f={},p=3===t.event.which;e._state||p||(t.preventDefault(),e.chart._unsetActivePoint(),o.options.justified||d--,f.from=Ve.min(Ve.max(l,s-d),c-h),f.to=Ve.min(f.from+h,c),e._start(t),e._state&&(e._state.range=f,e.trigger(Oo,e._rangeEventArgs(f)),e._end()))},_mousewheel:function(t){var e,i=this,n=i.options,o=Si(t);i._start({event:{target:i.selection}}),i._state&&(e=i._state.range,t.preventDefault(),t.stopPropagation(),Ve.abs(o)>1&&(o*=br),n.mousewheel.reverse&&(o*=-1),i.expand(o)&&i.trigger(Oo,{axis:i.categoryAxis.options,delta:o,originalEvent:t,from:i._value(e.from),to:i._value(e.to)}),i._mwTimeout&&clearTimeout(i._mwTimeout),i._mwTimeout=setTimeout(function(){i._end()},fo))},_index:function(t){var e=t;return t instanceof Date&&(e=this.categoryAxis.categoryIndex(t)),e},_value:function(t){var e=this.categoryAxis.options.categories,i=t;return this._dateAxis&&(i=t>e.length-1?this.options.max:e[Ve.ceil(t)]),i},_slot:function(t){var e=this.categoryAxis,i=this._index(t);return e.getSlot(i,i,!0)},move:function(t,e){var i,n,o,r,s=this,a=s.options,l=a.offset,c=a.padding,h=a.selection.border;o=s._slot(t),i=Ti(o.x1-l.left+c.left),s.leftMask.width(i),s.selection.css("left",i),o=s._slot(e),n=Ti(a.width-(o.x1-l.left+c.left)),s.rightMask.width(n),r=a.width-n,r!=a.width&&(r+=h.right),s.rightMask.css("left",r),s.selection.width(Ve.max(a.width-(i+n)-h.right,0))},set:function(t,e){var i=this,n=i.options,o=i._index(n.min),r=i._index(n.max);t=Ei(i._index(t),o,r),e=Ei(i._index(e),t+1,r),n.visible&&i.move(t,e),n.from=i._value(t),n.to=i._value(e)},expand:function(t){var e=this,i=e.options,n=e._index(i.min),o=e._index(i.max),r=i.mousewheel.zoom,s=e._index(i.from),a=e._index(i.to),l={from:s,to:a},c=$e({},l);if(e._state&&(l=e._state.range),r!==Do&&(l.from=Ei(Ei(s-t,0,a-1),n,o)),r!==$n&&(l.to=Ei(Ei(a+t,l.from+1,o),n,o)),l.from!==c.from||l.to!==c.to)return e.set(l.from,l.to),!0},getValueAxis:function(t){var e,i,n=t.pane.axes,o=n.length;for(e=0;e<o;e++)if(i=n[e],i.options.vertical!==t.options.vertical)return i}}),Te=je.extend({init:function(t,e){this.plotArea=t,this.options=$e({},this.options,e)},options:{key:"none",lock:"none"},start:function(t){return this._active=Z(t.event,this.options.key)},move:function(t){if(this._active){var e=this.axisRanges=this._panAxes(t,_r).concat(this._panAxes(t,yr));if(e.length)return this.axisRanges=e,K(e)}},end:function(){var t=this._active;return this._active=!1,t},pan:function(){var t,e,i=this.plotArea,n=this.axisRanges;if(n.length){for(e=0;e<n.length;e++)t=n[e],i.updateAxisOptions(t.axis,t.range);i.redraw(i.panes)}},destroy:function(){delete this.plotArea},_panAxes:function(t,e){var i,n,o,r,s=this.plotArea,a=-t[e].delta,l=(this.options.lock||"").toLowerCase(),c=[];if(0!==a&&(l||"").toLowerCase()!=e)for(i=s.axes,r=0;r<i.length;r++)n=i[r],(e==_r&&!n.options.vertical||e==yr&&n.options.vertical)&&(o=n.pan(a),o&&(o.limitRange=!0,c.push({axis:n,range:o})));return c}}),Ae=je.extend({init:function(e,i){this.chart=e,this.options=$e({},this.options,i),this._marquee=t("<div class='k-marquee'><div class='k-marquee-color'></div></div>")},options:{key:"shift",lock:"none"},start:function(t){var e,i,n,o,r;return!!(Z(t.event,this.options.key)&&(e=this.chart,i=e._toModelCoordinates(t.x.client,t.y.client),n=this._zoomPane=e._plotArea.paneByPoint(i),n&&n.clipBox()))&&(o=n.clipBox().clone(),r=this._elementOffset(),o.translate(r.left,r.top),this._zoomPaneClipBox=o,this._marquee.appendTo(document.body).css({left:t.x.client+1,top:t.y.client+1,width:0,height:0}),!0)},_elementOffset:function(){var t=this.chart.element,e=t.offset();return{left:parseInt(t.css("paddingTop"),10)+e.left,top:parseInt(t.css("paddingLeft"),10)+e.top}},move:function(t){var e,i=this._zoomPane;i&&(e=this._selectionPosition(t),this._marquee.css(e))},end:function(t){var e,i,n,o,r=this._zoomPane;if(r)return e=this._elementOffset(),i=this._selectionPosition(t),i.left-=e.left,i.top-=e.top,n={x:i.left,y:i.top},o={x:i.left+i.width,y:i.top+i.height},this._updateAxisRanges(n,o),this._marquee.remove(),delete this._zoomPane,K(this.axisRanges)},zoom:function(){var t,e,i,n=this.axisRanges;if(n&&n.length){for(t=this.chart._plotArea,i=0;i<n.length;i++)e=n[i],t.updateAxisOptions(e.axis,e.range);t.redraw(t.panes)}},destroy:function(){this._marquee.remove(),delete this._marquee,delete this.chart},_updateAxisRanges:function(t,e){var i,n,o,r,s=(this.options.lock||"").toLowerCase(),a=[],l=this._zoomPane.axes;for(o=0;o<l.length;o++)i=l[o],n=i.options.vertical,s==_r&&!n||s===yr&&n||(r=i.pointsRange(t,e),r&&a.push({axis:i,range:r}));this.axisRanges=a},_selectionPosition:function(t){var e=(this.options.lock||"").toLowerCase(),i=Ve.min(t.x.startLocation,t.x.location),n=Ve.min(t.y.startLocation,t.y.location),o=Ve.abs(t.x.initialDelta),r=Ve.abs(t.y.initialDelta),s=this._zoomPaneClipBox;return e==_r&&(i=s.x1,o=s.width()),e==yr&&(n=s.y1,r=s.height()),t.x.location>s.x2&&(o=s.x2-t.x.startLocation),t.x.location<s.x1&&(o=t.x.startLocation-s.x1),t.y.location>s.y2&&(r=s.y2-t.y.startLocation),t.y.location<s.y1&&(r=t.y.startLocation-s.y1),{left:Ve.max(i,s.x1),top:Ve.max(n,s.y1),width:o,height:r}}}),Pe=je.extend({init:function(t,e){this.chart=t,this.options=$e({},this.options,e)},updateRanges:function(t){var e,i,n,o,r=(this.options.lock||"").toLowerCase(),s=[],a=this.chart._plotArea.axes;for(n=0;n<a.length;n++)e=a[n],i=e.options.vertical,r==_r&&!i||r===yr&&i||(o=e.zoomRange(-t),o&&s.push({axis:e,range:o}));return this.axisRanges=s,K(s)},zoom:function(){var t,e,i,n=this.axisRanges;if(n&&n.length){for(t=this.chart._plotArea,i=0;i<n.length;i++)e=n[i],t.updateAxisOptions(e.axis,e.range);t.redraw(t.panes)}},destroy:function(){delete this.chart}}),De=function(t,e,i){var n,o,r,s=this,a=e.canonicalFields(t),l=e.valueFields(t),c=e.sourceFields(t,a),h=s._seriesFields=[],u=i.query(t.type),d=t.aggregate||u;for(s._series=t,s._binder=e,n=0;n<a.length;n++){if(o=a[n],typeof d===_o)r=d[o];else{if(0!==n&&!ki(o,l))break;r=d}r&&h.push({canonicalName:o,name:c[n],transform:Xe(r)?r:Ce[r]})}},De.prototype={aggregatePoints:function(t,e){var i,n,o,r,s,a=this,l=a._bindPoints(t||[]),c=a._series,h=a._seriesFields,u=l.dataItems[0],d={};for(!u||I(u)||Le(u)||(s=function(){},s.prototype=u,d=new s),i=0;i<h.length;i++){if(n=h[i],o=a._bindField(l.values,n.canonicalName),r=n.transform(o,c,l.dataItems,e),!(null===r||typeof r!==_o||Di(r.length)||r instanceof Date)){d=r;break}Di(r)&&(G(n.name,d),Ue.setter(n.name)(d,r))}return d},_bindPoints:function(t){var e,i,n=this,o=n._binder,r=n._series,s=[],a=[];for(e=0;e<t.length;e++)i=t[e],s.push(o.bindPoint(r,i)),a.push(r.data[i]);return{values:s,dataItems:a}},_bindField:function(t,e){var i,n,o,r,s=[],a=t.length;for(i=0;i<a;i++)n=t[i],r=n.valueFields,o=Di(r[e])?r[e]:n.fields[e],s.push(o);return s}},Me=je.extend({init:function(t){this._plotArea=t,this.visual=t.visual,this.backgroundVisual=t._bgVisual}}),Ee=je.extend({init:function(t,e){this._chart=t,this._pane=e,this.visual=e.visual,this.chartsVisual=e.chartContainer.visual,this.name=e.options.name},series:function(){var t,e=this._chart,i=e._plotArea.groupSeriesByPane(),n=i[this.name||"default"],o=[];if(n)for(t=0;t<n.length;t++)o.push(new Be(e,n[t]));return o}}),Ie=je.extend({init:function(t){this._axis=t,this.options=t.options},value:function(t){var e=this._axis,i=e.getCategory?e.getCategory(t):e.getValue(t);return i},slot:function(t,e,i){return Di(i)||(i=!0),this._axis.slot(t,e,i)},range:function(){return this._axis.range()},valueRange:function(){return this._axis.valueRange()}}),Be=je.extend({init:function(t,e){this._chart=t,this._options=e},points:function(t){var e,i,n=this._points;return n||(e=this._seriesOptions(),i=this._chart._plotArea,this._points=n=i.pointsBySeriesIndex(e.index)),Ue.isFunction(t)&&(n=this._filterPoints(n,t)),n},data:function(t){var e,i,n,o,r=this._seriesOptions();return t&&(e=this._chart,i=e._plotArea,r.data=t,r.categoryField&&(n=i.seriesCategoryAxis(r),o=[].concat(e.options.categoryAxis),e._bindCategoryAxisFromSeries(o[n.axisIndex],n.axisIndex)),e._noTransitionsRedraw(),this._clearFields()),r.data},findPoint:function(t){var e,i=this.points();for(e=0;e<i.length;e++)if(t(i[e]))return i[e]},toggleHighlight:function(t,e){e=e?Ue.isFunction(e)?this.points(e):Le(e)?e:[e]:this.points(),this._chart._togglePointsHighlight(t,e)},toggleVisibility:function(t,e){var i,n,o=this._chart,r=this._seriesOptions(),s=Ue.isFunction(e);if(s)if(ki(r.type,[xo,kn,On]))for(i=this._filterData(e),n=0;n<i.length;n++)i[n].visible=t;else r.visible=function(i){return!e(i.dataItem)||t};else r.visible=t,o._saveGroupVisibleState(r);o._noTransitionsRedraw(),this._clearFields()},_filterData:function(t){var e,i=this._seriesOptions().data,n=i.length,o=[];for(e=0;e<n;e++)t(i[e])&&o.push(i[e]);return o},_filterPoints:function(t,e){var i,n=[],o=t.length;for(i=0;i<o;i++)e(t[i])&&n.push(t[i]);return n},_seriesOptions:function(){var t=this._series;return t||(t=this._series=this._chart._seriesOptions(this._options)),t},_clearFields:function(){delete this._points,delete this._series}}),Ne(t.easing,{easeOutElastic:function(t,e,i,n){var o=1.70158,r=0,s=n;return 0===t?i:1===t?i+n:(r||(r=.5),s<Ve.abs(n)?(s=n,o=r/4):o=r/(2*Ve.PI)*Ve.asin(n/s),s*Ve.pow(2,-10*t)*Ve.sin((1*t-o)*(1.1*Ve.PI)/r)+n+i)}}),Je.ui.plugin(Dr),nt.current.register(ue,[Wi,hn,Qn,pr,Hi,ur,en,yo,tn,fr,Zi,dr,Ao,To,gr,Nn]),nt.current.register(fe,[Io,Bo,Ji]),nt.current.register(pe,[xo]),nt.current.register(ge,[kn]),ot.current.register([Wi,hn,Qn,pr,Hi,ur],[hr],[nn,cn,vo,Pn,Dn]),ot.current.register([Ao,To],[Rn,nr],[nn,cn,vo]),ot.current.register([gr,Nn],[hr],[nn,cn,vo,$o]),n.current.register([Wi,hn,Qn,pr,Hi,ur,gr,Nn],{value:to,color:Ln,noteText:Ln,errorLow:no,errorHigh:to}),n.current.register([Ao,To],{from:no,to:to,color:Ln,noteText:Ln}),ot.current.register([Io,Bo,Ji],[_r,yr],[cn,vo,Mn,En,In,Bn]),ot.current.register([Ji],[_r,yr,"size"],[cn,nn,vo]),ot.current.register([en,yo],["open","high","low","close"],[nn,cn,"downColor",vo]),n.current.register([en,yo],{open:to,high:to,low:no,close:to,color:Ln,downColor:Ln,noteText:Ln}),ot.current.register([Zi,dr],["lower","q1","median","q3","upper","mean","outliers"],[nn,cn,vo]),n.current.register([Zi,dr],{lower:to,q1:to,median:to,q3:to,upper:to,mean:to,outliers:Ln,color:Ln,noteText:Ln}),ot.current.register([tn,fr],["current","target"],[nn,cn,"visibleInLegend",vo]),n.current.register([tn,fr],{current:to,target:to,color:Ln,noteText:Ln}),ot.current.register([xo,kn],[hr],[nn,cn,"explode","visibleInLegend","visible"]),$e(Je,{EQUALLY_SPACED_SERIES:Ar,Aggregates:Ce,AreaChart:Ht,AreaSegment:Nt,AxisGroupRangeTracker:de,Bar:mt,BarChart:xt,BarLabel:rt,BubbleChart:qt,Bullet:St,BulletChart:Ct,CandlestickChart:Yt,Candlestick:$t,CategoricalChart:wt,CategoricalErrorBar:Pt,CategoricalPlotArea:ue,CategoryAxis:ct,ChartAxis:Ie,ChartContainer:le,ChartPane:Ee,ChartPlotArea:Me,ChartSeries:Be,ClipAnimation:Rt,ClusterLayout:dt,Crosshair:be,CrosshairTooltip:ke,DateCategoryAxis:ht,DateValueAxis:ut,DefaultAggregates:n,DonutChart:oe,DonutPlotArea:ge,DonutSegment:ne,ErrorBarBase:At,ErrorRangeCalculator:yt,Highlight:_e,SharedTooltip:xe,Legend:lt,LegendItem:st,LegendLayout:at,LineChart:Lt,LinePoint:Mt,LineSegment:It,Pane:ae,PieAnimation:me,PieChart:ie,PieChartMixin:ee,PiePlotArea:pe,PieSegment:te,PlotAreaBase:ce,PlotAreaEventsMixin:he,PlotAreaFactory:nt,PointEventsMixin:pt,RangeBar:bt,RangeBarChart:kt,ScatterChart:Gt,ScatterErrorBar:Dt,ScatterLineChart:Wt,Selection:Se,SeriesAggregator:De,SeriesBinder:ot,ShapeElement:pi,SplineSegment:Vt,SplineAreaSegment:Ut,StackWrap:ft,Tooltip:we,OHLCChart:Qt,OHLCPoint:Xt,WaterfallChart:re,WaterfallSegment:se,XYPlotArea:fe,MousewheelZoom:Pe,ZoomSelection:Ae,Pannable:Te,addDuration:m,areNumbers:z,axisGroupBox:A,categoriesCount:h,ceilDate:y,countNumbers:B,duration:k,ensureTree:G,indexOf:F,isNumber:I,floorDate:_,filterSeriesByType:V,hasValue:Q,lteDateIndex:E,evalOptions:R,seriesTotal:W,singleItemOrArray:T,sortDates:N,startOfWeek:v,transpose:j,toDate:p,toTime:g,uniqueDates:H})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.chart.polar.min",["kendo.dataviz.chart.min","kendo.drawing.min"],t)}(function(){return function(t,e){function i(t,e){return t.value.x-e.value.x}function n(t,e){return 180-C.abs(C.abs(t-e)-180)}var o,r,s,a,l,c,h,u,d,f,p,g,m,v,_,y,w,x,b,k,C=Math,S=window.kendo,T=S.deepExtend,A=S.util,P=A.append,D=S.drawing,M=S.geometry,E=S.dataviz,I=E.AreaSegment,B=E.Axis,z=E.AxisGroupRangeTracker,L=E.BarChart,R=E.Box2D,O=E.CategoryAxis,V=E.CategoricalChart,F=E.CategoricalPlotArea,N=E.ChartElement,H=E.CurveProcessor,U=E.DonutSegment,j=E.LineChart,G=E.LineSegment,W=E.LogarithmicAxis,q=E.NumericAxis,$=E.PlotAreaBase,Y=E.PlotAreaEventsMixin,X=E.PlotAreaFactory,Q=E.Point2D,K=E.Ring,Z=E.ScatterChart,J=E.ScatterLineChart,tt=E.SeriesBinder,et=E.ShapeBuilder,it=E.SplineSegment,nt=E.SplineAreaSegment,ot=E.eventTargetElement,rt=E.getSpacing,st=E.filterSeriesByType,at=A.limitValue,lt=E.round,ct="arc",ht="#000",ut=E.COORD_PRECISION,dt=.15,ft=C.PI/180,pt="gap",gt="interpolate",mt="log",vt="polarArea",_t="polarLine",yt="polarScatter",wt="radarArea",xt="radarColumn",bt="radarLine",kt="smooth",Ct="x",St="y",Tt="zero",At=[vt,_t,yt],Pt=[wt,xt,bt],Dt={createGridLines:function(t){var e,i,n=this,o=n.options,r=C.abs(n.box.center().y-t.lineBox().y1),s=!1,a=[];return o.majorGridLines.visible&&(e=n.majorGridLineAngles(t),s=!0,a=n.renderMajorGridLines(e,r,o.majorGridLines)),o.minorGridLines.visible&&(i=n.minorGridLineAngles(t,s),P(a,n.renderMinorGridLines(i,r,o.minorGridLines,t,s))),a},renderMajorGridLines:function(t,e,i){return this.renderGridLines(t,e,i)},renderMinorGridLines:function(t,e,i,n,o){var r=this.radiusCallback&&this.radiusCallback(e,n,o);return this.renderGridLines(t,e,i,r)},renderGridLines:function(t,e,i,n){var o,r,s={stroke:{width:i.width,color:i.color,dashType:i.dashType}},a=this.box.center(),l=new M.Circle([a.x,a.y],e),c=this.gridLinesVisual();for(o=0;o<t.length;o++)r=new D.Path(s),n&&(l.radius=n(t[o])),r.moveTo(l.center).lineTo(l.pointAt(t[o])),c.append(r);return c.children},gridLineAngles:function(e,i,n,o,r){var s=this,a=s.intervals(i,n,o,r),l=e.options,c=l.visible&&(l.line||{}).visible!==!1;return t.map(a,function(t){var e=s.intervalAngle(t);if(!c||90!==e)return e})}},Mt=O.extend({options:{startAngle:90,labels:{margin:rt(10)},majorGridLines:{visible:!0},justified:!0},range:function(){return{min:0,max:this.options.categories.length}},reflow:function(t){this.box=t,this.reflowLabels()},lineBox:function(){return this.box},reflowLabels:function(){var t,e,i=this,n=i.options.labels,o=n.skip||0,r=n.step||1,s=new R,a=i.labels;for(e=0;e<a.length;e++)a[e].reflow(s),t=a[e].box,a[e].reflow(i.getSlot(o+e*r).adjacentBox(0,t.width(),t.height()))},intervals:function(t,e,i,n){var o,r=this,s=r.options,a=s.categories.length,l=0,c=a/t||1,h=360/c,u=[];for(e=e||0,i=i||1,o=e;o<c;o+=i)l=s.reverse?360-o*h:o*h,l=lt(l,ut)%360,n&&E.inArray(l,n)||u.push(l);return u},majorIntervals:function(){return this.intervals(1)},minorIntervals:function(){return this.intervals(.5)},intervalAngle:function(t){return(360+t+this.options.startAngle)%360},majorAngles:function(){return t.map(this.majorIntervals(),t.proxy(this.intervalAngle,this))},createLine:function(){return[]},majorGridLineAngles:function(t){var e=this.options.majorGridLines;return this.gridLineAngles(t,1,e.skip,e.step)},minorGridLineAngles:function(t,e){var i=this.options,n=i.minorGridLines,o=i.majorGridLines,r=e?this.intervals(1,o.skip,o.step):null;return this.gridLineAngles(t,.5,n.skip,n.step,r)},radiusCallback:function(t,e,i){var n,o,r,s;if(e.options.type!==ct)return n=360/(2*this.options.categories.length),o=C.cos(n*ft)*t,r=this.majorAngles(),s=function(e){return!i&&E.inArray(e,r)?t:o}},createPlotBands:function(){var t,e,i,n,o,r,s,a=this,l=a.options,c=l.plotBands||[],h=this._plotbandGroup=new D.Group({zIndex:-1});for(t=0;t<c.length;t++)e=c[t],i=a.plotBandSlot(e),n=a.getSlot(e.from),o=e.from-C.floor(e.from),i.startAngle+=o*n.angle,r=C.ceil(e.to)-e.to,i.angle-=(r+o)*n.angle,s=et.current.createRing(i,{fill:{color:e.color,opacity:e.opacity},stroke:{opacity:e.opacity}}),h.append(s);a.appendVisual(h)},plotBandSlot:function(t){return this.getSlot(t.from,t.to-1)},getSlot:function(t,e){var i,n,o,r=this,s=r.options,a=s.justified,l=r.box,c=r.majorAngles(),h=c.length,u=360/h;return s.reverse&&!a&&(t=(t+1)%h),t=at(C.floor(t),0,h-1),n=c[t],a&&(n-=u/2,n<0&&(n+=360)),e=at(C.ceil(e||t),t,h-1),i=e-t+1,o=u*i,new K(l.center(),0,l.height()/2,n,o)},slot:function(t,e){var i=this.getSlot(t,e),n=i.startAngle+180,o=n+i.angle;return new M.Arc([i.c.x,i.c.y],{startAngle:n,endAngle:o,radiusX:i.r,radiusY:i.r})},pointCategoryIndex:function(t){var e,i,n=this,o=null,r=n.options.categories.length;for(e=0;e<r;e++)if(i=n.getSlot(e),i.containsPoint(t)){o=e;break}return o}});T(Mt.fn,Dt),o={options:{majorGridLines:{visible:!0}},createPlotBands:function(){var t,e,i,n,o,r,s=this,a=s.options,l=a.plotBands||[],c=a.majorGridLines.type,h=s.plotArea.polarAxis,u=h.majorAngles(),d=h.box.center(),f=this._plotbandGroup=new D.Group({zIndex:-1});for(t=0;t<l.length;t++)e=l[t],i={fill:{color:e.color,opacity:e.opacity},stroke:{opacity:e.opacity}},n=s.getSlot(e.from,e.to,!0),o=new K(d,d.y-n.y2,d.y-n.y1,0,360),r=c===ct?et.current.createRing(o,i):D.Path.fromPoints(s.plotBandPoints(o,u),i).close(),f.append(r);s.appendVisual(f)},plotBandPoints:function(t,e){var i,n=[],o=[],r=[t.c.x,t.c.y],s=new M.Circle(r,t.ir),a=new M.Circle(r,t.r);for(i=0;i<e.length;i++)n.push(s.pointAt(e[i])),o.push(a.pointAt(e[i]));return n.reverse(),n.push(n[0]),o.push(o[0]),o.concat(n)},createGridLines:function(t){var e,i=this,n=i.options,o=i.radarMajorGridLinePositions(),r=t.majorAngles(),s=t.box.center(),a=[];return n.majorGridLines.visible&&(a=i.renderGridLines(s,o,r,n.majorGridLines)),n.minorGridLines.visible&&(e=i.radarMinorGridLinePositions(),P(a,i.renderGridLines(s,e,r,n.minorGridLines))),a},renderGridLines:function(t,e,i,n){var o,r,s,a,l,c={stroke:{width:n.width,color:n.color,dashType:n.dashType}},h=n.skip||0,u=n.step||1,d=this.gridLinesVisual();for(r=h;r<e.length;r+=u)if(o=t.y-e[r],o>0)if(a=new M.Circle([t.x,t.y],o),n.type===ct)d.append(new D.Circle(a,c));else{for(l=new D.Path(c),s=0;s<i.length;s++)l.lineTo(a.pointAt(i[s]));l.close(),d.append(l)}return d.children},getValue:function(t){var e,i,o,r,s,a,l,c=this,h=c.options,u=c.lineBox(),d=c.plotArea.polarAxis,f=d.majorAngles(),p=d.box.center(),g=t.distanceTo(p),m=g;return h.majorGridLines.type!==ct&&f.length>1&&(e=t.x-p.x,i=t.y-p.y,o=(C.atan2(i,e)/ft+540)%360,f.sort(function(t,e){return n(t,o)-n(e,o)}),r=n(f[0],f[1])/2,s=n(o,f[0]),a=90-r,l=180-s-a,m=g*(C.sin(l*ft)/C.sin(a*ft))),c.axisType().fn.getValue.call(c,new Q(u.x1,u.y2-m))}},r=q.extend({radarMajorGridLinePositions:function(){return this.getTickPositions(this.options.majorUnit)},radarMinorGridLinePositions:function(){var t=this,e=t.options,i=0;return e.majorGridLines.visible&&(i=e.majorUnit),t.getTickPositions(e.minorUnit,i)},axisType:function(){return q}}),T(r.fn,o),s=W.extend({radarMajorGridLinePositions:function(){var t=this,e=[];return t.traverseMajorTicksPositions(function(t){e.push(t)},t.options.majorGridLines),e},radarMinorGridLinePositions:function(){var t=this,e=[];return t.traverseMinorTicksPositions(function(t){e.push(t)},t.options.minorGridLines),e},axisType:function(){return W}}),T(s.fn,o),a=B.extend({init:function(t){var e=this;B.fn.init.call(e,t),t=e.options,t.minorUnit=t.minorUnit||e.options.majorUnit/2},options:{type:"polar",startAngle:0,reverse:!1,majorUnit:60,min:0,max:360,labels:{margin:rt(10)},majorGridLines:{color:ht,visible:!0,width:1},minorGridLines:{color:"#aaa"}},getDivisions:function(t){return q.fn.getDivisions.call(this,t)-1},reflow:function(t){this.box=t,this.reflowLabels()},reflowLabels:function(){var t,e,i=this,n=i.options,o=n.labels,r=o.skip||0,s=o.step||1,a=new R,l=i.intervals(n.majorUnit,r,s),c=i.labels;for(e=0;e<c.length;e++)c[e].reflow(a),t=c[e].box,c[e].reflow(i.getSlot(l[e]).adjacentBox(0,t.width(),t.height()))},lineBox:function(){return this.box},intervals:function(t,e,i,n){var o,r,s=this,a=s.options,l=s.getDivisions(t),c=a.min,h=[];for(e=e||0,i=i||1,r=e;r<l;r+=i)o=(360+c+r*t)%360,n&&E.inArray(o,n)||h.push(o);return h},majorIntervals:function(){return this.intervals(this.options.majorUnit)},minorIntervals:function(){return this.intervals(this.options.minorUnit)},intervalAngle:function(t){return(540-t-this.options.startAngle)%360},majorAngles:Mt.fn.majorAngles,createLine:function(){return[]},majorGridLineAngles:function(t){var e=this.options.majorGridLines;return this.gridLineAngles(t,this.options.majorUnit,e.skip,e.step)},minorGridLineAngles:function(t,e){var i=this.options,n=i.minorGridLines,o=i.majorGridLines,r=e?this.intervals(i.majorUnit,o.skip,o.step):null;return this.gridLineAngles(t,this.options.minorUnit,n.skip,n.step,r)},createPlotBands:Mt.fn.createPlotBands,plotBandSlot:function(t){return this.getSlot(t.from,t.to)},getSlot:function(t,e){var i,n=this,o=n.options,r=o.startAngle,s=n.box;return t=at(t,o.min,o.max),e=at(e||t,t,o.max),o.reverse&&(t*=-1,e*=-1),t=(540-t-r)%360,e=(540-e-r)%360,e<t&&(i=t,t=e,e=i),new K(s.center(),0,s.height()/2,t,e-t)},slot:function(t,e){var i,n,o,r,s=this.options,a=360-s.startAngle,l=this.getSlot(t,e);return E.util.defined(e)||(e=t),o=C.min(t,e),r=C.max(t,e),s.reverse?(i=o,n=r):(i=360-r,n=360-o),i=(i+a)%360,n=(n+a)%360,new M.Arc([l.c.x,l.c.y],{startAngle:i,endAngle:n,radiusX:l.r,radiusY:l.r})},getValue:function(t){var e=this,i=e.options,n=e.box.center(),o=t.x-n.x,r=t.y-n.y,s=C.round(C.atan2(r,o)/ft),a=i.startAngle;return i.reverse||(s*=-1,a*=-1),(s+a+360)%360},valueRange:function(){return{min:0,max:2*C.PI}},range:q.fn.range,labelsCount:q.fn.labelsCount,createAxisLabel:q.fn.createAxisLabel}),T(a.fn,Dt),l=N.extend({options:{gap:1,spacing:0},reflow:function(t){var e,i,n=this,o=n.options,r=n.children,s=o.gap,a=o.spacing,l=r.length,c=l+s+a*(l-1),h=t.angle/c,u=t.startAngle+h*(s/2);for(i=0;i<l;i++)e=t.clone(),e.startAngle=u,e.angle=h,r[i].sector&&(e.r=r[i].sector.r),r[i].reflow(e),r[i].sector=e,u+=h+h*a}}),c=N.extend({reflow:function(t){var e,i,n=this,o=n.options.isReversed,r=n.children,s=r.length,a=o?s-1:0,l=o?-1:1;for(n.box=new R,i=a;i>=0&&i<s;i+=l)e=r[i].sector,e.startAngle=t.startAngle,e.angle=t.angle}}),h=U.extend({init:function(t,e){U.fn.init.call(this,t,null,e)},options:{overlay:{gradient:null},labels:{distance:10}}}),u=L.extend({pointType:function(){return h},clusterType:function(){return l},stackType:function(){return c},categorySlot:function(t,e){return t.getSlot(e)},pointSlot:function(t,e){var i=t.clone(),n=t.c.y;return i.r=n-e.y1,i.ir=n-e.y2,i},reflow:V.fn.reflow,reflowPoint:function(t,e){t.sector=e,t.reflow()},options:{clip:!1,animation:{type:"pie"}},createAnimation:function(){this.options.animation.center=this.box.toRect().center(),L.fn.createAnimation.call(this)}}),d=j.extend({options:{clip:!1},pointSlot:function(t,e){var i=t.c.y-e.y1,n=Q.onCircle(t.c,t.middle(),i);return new R(n.x,n.y,n.x,n.y)},createSegment:function(t,e,i){var n,o,r=e.style;return o=r==kt?it:G,n=new o(t,e,i),t.length===e.data.length&&(n.options.closed=!0),n}}),f=I.extend({points:function(){return G.fn.points.call(this,this.stackPoints)}}),p=nt.extend({closeFill:t.noop}),g=d.extend({createSegment:function(t,e,i,n){var o,r,s=this,a=s.options,l=a.isStacked,c=(e.line||{}).style;return c===kt?(r=new p(t,n,l,e,i),r.options.closed=!0):(l&&i>0&&n&&(o=n.linePoints.slice(0).reverse()),t.push(t[0]),r=new f(t,o,e,i)),r},seriesMissingValues:function(t){return t.missingValues||Tt}}),m=Z.extend({pointSlot:function(t,e){var i=t.c.y-e.y1,n=Q.onCircle(t.c,t.startAngle,i);return new R(n.x,n.y,n.x,n.y)},options:{clip:!1}}),v=J.extend({pointSlot:m.fn.pointSlot,options:{clip:!1}}),_=I.extend({points:function(){var t=this,e=t.parent,i=e.plotArea,n=i.polarAxis,o=n.box.center(),r=t.stackPoints,s=G.fn.points.call(t,r);return s.unshift([o.x,o.y]),s.push([o.x,o.y]),s}}),y=nt.extend({closeFill:function(t){var e=this._polarAxisCenter();t.lineTo(e.x,e.y)},_polarAxisCenter:function(){var t=this.parent,e=t.plotArea,i=e.polarAxis,n=i.box.center();return n},strokeSegments:function(){var t,e,i,n=this._strokeSegments;return n||(t=this._polarAxisCenter(),e=new H((!1)),i=G.fn.points.call(this),i.push(t),n=this._strokeSegments=e.process(i),n.pop()),n}}),w=v.extend({createSegment:function(t,e,i){var n,o=(e.line||{}).style;return n=o==kt?new y(t,null,(!1),e,i):new _(t,[],e,i)},createMissingValue:function(t,e){var i;return E.hasValue(t.x)&&e!=gt&&(i={x:t.x,y:t.y},e==Tt&&(i.y=0)),i},seriesMissingValues:function(t){return t.missingValues||Tt},_hasMissingValuesGap:function(){var t,e=this.options.series;for(t=0;t<e.length;t++)if(this.seriesMissingValues(e[t])===pt)return!0},sortPoints:function(t){var e,n,o;if(t.sort(i),this._hasMissingValuesGap())for(o=0;o<t.length;o++)n=t[o],n&&(e=n.value,E.hasValue(e.y)||this.seriesMissingValues(n.series)!==pt||delete t[o]);return t}}),x=$.extend({init:function(t,e){var i=this;i.valueAxisRangeTracker=new z,$.fn.init.call(i,t,e)},render:function(){var t=this;t.addToLegend(t.series),t.createPolarAxis(),t.createCharts(),t.createValueAxis()},alignAxes:function(){var t=this.valueAxis,e=t.range(),i=t.options.reverse?e.max:e.min,n=t.getSlot(i),o=this.polarAxis.getSlot(0).c,r=t.box.translate(o.x-n.x1,o.y-n.y1);t.reflow(r)},createValueAxis:function(){var t,e,i,n,o=this,a=o.valueAxisRangeTracker,l=a.query(),c=o.valueAxisOptions({roundToMajorUnit:!1,zIndex:-1});c.type===mt?(i=s,n={min:.1,max:1}):(i=r,n={min:0,max:1}),t=a.query(name)||l||n,t&&l&&(t.min=C.min(t.min,l.min),t.max=C.max(t.max,l.max)),e=new i(t.min,t.max,c),o.valueAxis=e,o.appendAxis(e)},reflowAxes:function(){var t,e=this,i=e.options.plotArea,n=e.valueAxis,o=e.polarAxis,r=e.box,s=C.min(r.width(),r.height())*dt,a=rt(i.padding||{},s),l=r.clone().unpad(a),c=l.clone().shrink(0,l.height()/2);o.reflow(l),n.reflow(c),t=n.lineBox().height()-n.box.height(),n.reflow(n.box.unpad({top:t})),e.axisBox=l,e.alignAxes(l)},backgroundBox:function(){return this.box}}),b=x.extend({options:{categoryAxis:{categories:[]},valueAxis:{}},createPolarAxis:function(){var t,e=this;t=new Mt(e.options.categoryAxis),e.polarAxis=t,e.categoryAxis=t,e.appendAxis(t),e.aggregateCategories()},valueAxisOptions:function(t){var e=this;return e._hasBarCharts&&T(t,{majorGridLines:{type:ct},minorGridLines:{type:ct}}),e._isStacked100&&T(t,{roundToMajorUnit:!1,labels:{format:"P0"}}),T(t,e.options.valueAxis)},appendChart:F.fn.appendChart,aggregateSeries:F.fn.aggregateSeries,aggregateCategories:function(){F.fn.aggregateCategories.call(this,this.panes)},filterSeries:function(t){return t},createCharts:function(){var t=this,e=t.filterVisibleSeries(t.series),i=t.panes[0];t.createAreaChart(st(e,[wt]),i),t.createLineChart(st(e,[bt]),i),t.createBarChart(st(e,[xt]),i)},chartOptions:function(t){var e,i,n={series:t},o=t[0];return o&&(e=this.filterVisibleSeries(t),i=o.stack,n.isStacked=i&&e.length>1,n.isStacked100=i&&"100%"===i.type&&e.length>1,n.isStacked100&&(this._isStacked100=!0)),n},createAreaChart:function(t,e){if(0!==t.length){var i=new g(this,this.chartOptions(t));this.appendChart(i,e)}},createLineChart:function(t,e){if(0!==t.length){var i=new d(this,this.chartOptions(t));this.appendChart(i,e)}},createBarChart:function(t,e){var i,n,o;0!==t.length&&(i=t[0],n=this.chartOptions(t),n.gap=i.gap,n.spacing=i.spacing,o=new u(this,n),this.appendChart(o,e),this._hasBarCharts=!0)},seriesCategoryAxis:function(){return this.categoryAxis},_dispatchEvent:function(t,e,i){var n,o,r=this,s=t._eventCoordinates(e),a=new Q(s.x,s.y);n=r.categoryAxis.getCategory(a),o=r.valueAxis.getValue(a),null!==n&&null!==o&&t.trigger(i,{element:ot(e),category:n,value:o})},createCrosshairs:t.noop}),T(b.fn,Y),k=x.extend({options:{xAxis:{},yAxis:{}},createPolarAxis:function(){var t,e=this;t=new a(e.options.xAxis),e.polarAxis=t,e.axisX=t,e.appendAxis(t)},valueAxisOptions:function(t){var e=this;return T(t,{majorGridLines:{type:ct},minorGridLines:{type:ct}},e.options.yAxis)},createValueAxis:function(){var t=this;x.fn.createValueAxis.call(t),t.axisY=t.valueAxis},appendChart:function(t,e){var i=this;i.valueAxisRangeTracker.update(t.yAxisRanges),$.fn.appendChart.call(i,t,e)},createCharts:function(){var t=this,e=t.filterVisibleSeries(t.series),i=t.panes[0];t.createLineChart(st(e,[_t]),i),t.createScatterChart(st(e,[yt]),i),t.createAreaChart(st(e,[vt]),i)},createLineChart:function(t,e){if(0!==t.length){var i=this,n=new v(i,{series:t});i.appendChart(n,e)}},createScatterChart:function(t,e){if(0!==t.length){var i=this,n=new m(i,{series:t});i.appendChart(n,e)}},createAreaChart:function(t,e){if(0!==t.length){var i=this,n=new w(i,{series:t});i.appendChart(n,e)}},_dispatchEvent:function(t,e,i){var n,o,r=this,s=t._eventCoordinates(e),a=new Q(s.x,s.y);n=r.axisX.getValue(a),o=r.axisY.getValue(a),null!==n&&null!==o&&t.trigger(i,{element:ot(e),x:n,y:o})},createCrosshairs:t.noop}),T(k.fn,Y),X.current.register(k,At),X.current.register(b,Pt),tt.current.register(At,[Ct,St],["color"]),tt.current.register(Pt,["value"],["color"]),E.DefaultAggregates.current.register(Pt,{value:"max",color:"first"}),T(E,{PolarAreaChart:w,PolarAxis:a,PolarLineChart:v,PolarPlotArea:k,RadarAreaChart:g,RadarBarChart:u,RadarCategoryAxis:Mt,RadarClusterLayout:l,RadarLineChart:d,RadarNumericAxis:r,RadarPlotArea:b,SplinePolarAreaSegment:y,SplineRadarAreaSegment:p,RadarStackLayout:c})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.chart.funnel.min",["kendo.dataviz.chart.min","kendo.drawing.min"],t)}(function(){return function(t,e){var i,n=window.kendo,o=n.deepExtend,r=t.extend,s=n.isFunction,a=n.template,l=n.util,c=l.append,h=n.drawing,u=n.geometry,d=n.dataviz,f=n.drawing.Color,p=d.ChartElement,g=d.PieChartMixin,m=d.PlotAreaBase,v=d.PlotAreaFactory,_=d.Point2D,y=d.Box2D,w=d.SeriesBinder,x=d.TextBox,b=d.autoFormat,k=d.evalOptions,C=l.limitValue,S=d.seriesTotal,T="category",A="color",P="funnel",D="value",M="black",E="white",I=m.extend({render:function(){var t=this,e=t.series;t.createFunnelChart(e)},createFunnelChart:function(t){var e=this,i=t[0],n=new B(e,{series:t,legend:e.options.legend,neckRatio:i.neckRatio,dynamicHeight:i.dynamicHeight,dynamicSlope:i.dynamicSlope,segmentSpacing:i.segmentSpacing,highlight:i.highlight});e.appendChart(n)},appendChart:function(t,e){m.fn.appendChart.call(this,t,e),c(this.options.legend.items,t.legendItems)}}),B=p.extend({init:function(t,e){var i=this;p.fn.init.call(i,e),i.plotArea=t,i.points=[],i.labels=[],i.legendItems=[],i.render()},options:{neckRatio:.3,width:300,dynamicSlope:!1,dynamicHeight:!0,segmentSpacing:0,labels:{visible:!1,align:"center",position:"center"}},formatPointValue:function(t,e){return b(e,t.value)},render:function(){var t,i,n,r,a,l,c,h=this,u=h.options,d=h.plotArea.options.seriesColors||[],f=d.length,p=u.series[0],g=p.data;if(g)for(n=S(p),a=0;a<g.length;a++)t=w.current.bindPoint(p,a),r=t.valueFields.value,null!==r&&r!==e&&(i=t.fields,s(p.color)||(p.color=i.color||d[a%f]),i=o({index:a,
owner:h,series:p,category:i.category,dataItem:g[a],percentage:Math.abs(r)/n,visibleInLegend:i.visibleInLegend,visible:i.visible},i),l=h.createSegment(r,i),c=h.createLabel(r,i),l&&c&&l.append(c))},evalSegmentOptions:function(t,e,i){var n=i.series;k(t,{value:e,series:n,dataItem:i.dataItem,index:i.index},{defaults:n._defaults,excluded:["data","toggle","visual"]})},createSegment:function(t,e){var n,s=this,a=o({},e.series);if(s.evalSegmentOptions(a,t,e),s.createLegendItem(t,a,e),e.visible!==!1)return n=new i(t,a,e),r(n,e),s.append(n),s.points.push(n),n},createLabel:function(t,e){var i,n,r,s=this,l=e.series,c=e.dataItem,h=o({},s.options.labels,l.labels),u=t;if(h.visible)return h.template?(n=a(h.template),u=n({dataItem:c,value:t,percentage:e.percentage,category:e.category,series:l})):h.format&&(u=b(h.format,u)),h.color||"center"!==h.align||(r=new f(l.color).percBrightness(),h.color=r>180?M:E),s.evalSegmentOptions(h,t,e),i=new x(u,o({vAlign:h.position},h)),s.labels.push(i),i},labelPadding:function(){var t,e,i,n,o=this.labels,r={left:0,right:0};for(n=0;n<o.length;n++)t=o[n],e=t.options.align,"center"!==e&&(i=o[n].box.width(),"left"===e?r.left=Math.max(r.left,i):r.right=Math.max(r.right,i));return r},reflow:function(e){var i,n,o,r,s,a,l,c,h,d,f,p,g=this,m=g.options,v=g.points,_=v.length,y=m.neckRatio<=1,w=e.clone().unpad(g.labelPadding()),x=w.width(),b=0,k=y?0:(x-x/m.neckRatio)/2,S=m.segmentSpacing,T=m.dynamicSlope,A=w.height()-S*(_-1),P=y?m.neckRatio*x:x;if(_){if(T)for(l=v[0],c=l,t.each(v,function(t,e){e.percentage>c.percentage&&(c=e)}),o=l.percentage/c.percentage*x,k=(x-o)/2,i=0;i<_;i++)s=v[i].percentage,h=v[i+1],d=h?h.percentage:s,r=v[i].points=[],n=m.dynamicHeight?A*s:A/_,a=s?(x-o*(d/s))/2:d?0:x/2,a=C(a,0,x),r.push(new u.Point(w.x1+k,w.y1+b)),r.push(new u.Point(w.x1+x-k,w.y1+b)),r.push(new u.Point(w.x1+x-a,w.y1+n+b)),r.push(new u.Point(w.x1+a,w.y1+n+b)),k=a,b+=n+S,o=C(x-2*a,0,x);else for(f=y?x:x-2*k,p=(f-P)/2,i=0;i<_;i++)r=v[i].points=[],s=v[i].percentage,a=m.dynamicHeight?p*s:p/_,n=m.dynamicHeight?A*s:A/_,r.push(new u.Point(w.x1+k,w.y1+b)),r.push(new u.Point(w.x1+x-k,w.y1+b)),r.push(new u.Point(w.x1+x-k-a,w.y1+n+b)),r.push(new u.Point(w.x1+k+a,w.y1+n+b)),k+=a,b+=n+S;for(i=0;i<_;i++)v[i].reflow(e)}}});o(B.fn,g),i=p.extend({init:function(t,e,i){var n=this;p.fn.init.call(n,e),n.value=t,n.options.index=i.index},options:{color:E,border:{width:1}},reflow:function(t){var e=this,i=e.points,n=e.children[0];e.box=new y(i[0].x,i[0].y,i[1].x,i[2].y),n&&n.reflow(new y(t.x1,i[0].y,t.x2,i[2].y))},createVisual:function(){var t,e=this,i=e.options;p.fn.createVisual.call(this),t=i.visual?i.visual({category:e.category,dataItem:e.dataItem,value:e.value,series:e.series,percentage:e.percentage,points:e.points,options:i,createVisual:function(){return e.createPath()}}):e.createPath(),t&&this.visual.append(t)},createPath:function(){var t=this.options,e=t.border,i=h.Path.fromPoints(this.points,{fill:{color:t.color,opacity:t.opacity},stroke:{color:e.color,opacity:e.opacity,width:e.width}}).close();return i},createHighlight:function(t){return h.Path.fromPoints(this.points,t)},highlightVisual:function(){return this.visual.children[0]},highlightVisualArgs:function(){var t=h.Path.fromPoints(this.points).close();return{options:this.options,path:t}},highlightOverlay:function(t,e){var i,n,o,s=this.options,a=s.highlight||{};if(a.visible!==!1)return i=a.border||{},n=r({},e,{fill:a.color,stroke:i.color,strokeOpacity:i.opacity,strokeWidth:i.width,fillOpacity:a.opacity}),o=t.createPolyline(this.points,!0,n)},tooltipAnchor:function(t){var e=this.box;return new _(e.center().x-t/2,e.y1)},formatValue:function(t){var e=this;return e.owner.formatPointValue(e,t)}}),o(i.fn,d.PointEventsMixin),v.current.register(I,[P]),w.current.register([P],[D],[T,A,"visibleInLegend","visible"]),o(d,{FunnelChart:B,FunnelSegment:i})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.gauge.min",["kendo.dataviz.core.min","kendo.drawing.min","kendo.dataviz.themes.min"],t)}(function(){return function(t,e){function i(t,e){var i=t.box,n=t.children[0].box,r=e.border||{},s=e.background||"",a=new P,l=D.fromRect(new M([i.x1,i.y1],[i.width(),i.height()]),{stroke:{}}),c=new E(t.text,new A(n.x1,n.y1),{font:e.font,fill:{color:e.color}}),h=o(c.bbox().clone(),e.padding),u=D.fromRect(h,{stroke:{color:r.width?r.color:"",width:r.width,dashType:r.dashType,lineJoin:"round",lineCap:"round"},fill:{color:s}});return a.append(l),a.append(u),a.append(c),a}function n(t,e,i){var n=w(t.from)?t.from:H,o=w(t.to)?t.to:N;return t.from=l.max(l.min(o,n),e),t.to=l.min(l.max(o,n),i),t}function o(t,e){var i=t.getOrigin(),n=t.getSize(),o=k(e);return t.setOrigin([i.x-o.left,i.y-o.top]),t.setSize([n.width+(o.left+o.right),n.height+(o.top+o.bottom)]),t}function r(t,e){var i=k(e);return i.left=-i.left,i.top=-i.top,i.right=-i.right,i.bottom=-i.bottom,o(t,i)}var s,a,l=Math,c=window.kendo,h=c.util,u=c.ui.Widget,d=c.deepExtend,f=c.dataviz,p=f.autoMajorUnit,g=f.ChartElement,m=f.NumericAxis,v=f.Axis,_=f.Box2D,y=c.Class,w=h.defined,x=h.isNumber,b=f.interpolateValue,k=f.getSpacing,C=f.round,S=f.geometry,T=f.drawing,A=S.Point,P=T.Group,D=T.Path,M=S.Rect,E=T.Text,I=150,B=250,z="arrow",L="arrowPointer",R="barPointer",O="#000",V=.05,F=f.COORD_PRECISION,N=Number.MAX_VALUE,H=-Number.MAX_VALUE,U=200,j=.5,G=200,W=60,q=60,$=5,Y=l.PI/180,X=180,Q="inside",K="linear",Z="needle",J="outside",tt="radialPointer",et="x",it="y",nt=y.extend({init:function(t,e){var i=this,n=t.options;g.fn.init.call(i,e),e=i.options,e.fill=e.color,i.scale=t,e.value=w(e.value)?l.min(l.max(e.value,n.min),n.max):n.min},options:{color:O},value:function(t){var i=this,n=i.options,o=n.value,r=i.scale.options;return 0===arguments.length?o:(n._oldValue=n._oldValue!==e?n.value:r.min,n.value=l.min(l.max(t,r.min),r.max),i.elements&&i.repaint(),e)}}),ot=nt.extend({options:{shape:Z,cap:{size:V},arrow:{width:16,height:14},animation:{type:tt,duration:I}},setRadius:function(t){var e=this;t&&(e.elements.clear(),e.render(e.parent,e.center,t))},setAngle:function(t){this.elements.transform(S.transform().rotate(t,this.center))},repaint:function(){var t=this,e=t.scale,i=t.options,n=e.slotAngle(i._oldValue),o=e.slotAngle(i.value);i.animation.transitions===!1?t.setAngle(o):new ft(t.elements,d(i.animation,{oldAngle:n,newAngle:o})).play()},render:function(){var t=this,e=t.scale,i=e.arc.center,n=t.options,o=new P;return n.animation!==!1&&d(n.animation,{startAngle:0,center:i,reverse:e.options.reverse}),n.shape===Z?o.append(t._renderNeedle(),t._renderCap()):o.append(t._renderArrow()),t.elements=o,t.setAngle(Y),o},reflow:function(t){var e=this,i=e.center=t.center,n=e.radius=t.getRadiusX(),o=e.capSize=Math.round(n*e.options.cap.size);e.bbox=M.fromPoints(new A(i.x-o,i.y-o),new A(i.x+o,i.y+o))},_renderNeedle:function(){var t=this,e=t.options,i=t.scale.options.minorTicks.size,n=t.center,o=e.color,r=new D({fill:{color:o},stroke:{color:o,width:j}});return r.moveTo(n.x+t.radius-i,n.y).lineTo(n.x,n.y-t.capSize/2).lineTo(n.x,n.y+t.capSize/2).close(),r},_renderCap:function(){var t=this,e=t.options,i=e.cap.color||e.color,n=new S.Circle(t.center,t.capSize),o=new T.Circle(n,{fill:{color:i},stroke:{color:i}});return o}}),rt=m.extend({init:function(t){var e=this;e.options=d({},e.options,t),e.options.majorUnit=e.options.majorUnit||p(e.options.min,e.options.max),e.options.minorUnit=e.options.minorUnit||e.options.majorUnit/10,v.fn.init.call(e,e.options)},options:{min:0,max:100,majorTicks:{size:15,align:Q,color:O,width:j,visible:!0},minorTicks:{size:10,align:Q,color:O,width:j,visible:!0},startAngle:-30,endAngle:210,labels:{position:Q,padding:2}},render:function(t,e){var i=this,n=i.renderArc(t,e);i.bbox=n.bbox(),i.labelElements=i.renderLabels(),i.ticks=i.renderTicks(),i.ranges=i.renderRanges()},reflow:function(t){var i=this,n=t.center(),o=l.min(t.height(),t.width())/2;return i.bbox===e?i.render(n,o):(i.bbox=i.arc.bbox(),i.radius(i.arc.getRadiusX()),i.repositionRanges(),i.renderLabels(),e)},slotAngle:function(t){var e,i=this.options,n=i.startAngle,o=i.reverse,r=i.endAngle-n,s=i.min,a=i.max;return e=o?i.endAngle-(t-s)/(a-s)*r:(t-s)/(a-s)*r+n,e+X},renderLabels:function(){var t,n,o,r,s,a,c,h,u,d,p,g,m,v,_=this,y=_.options,w=y.majorTicks.size,x=_.arc.clone(),b=x.getRadiusX(),k=_.tickAngles(x,y.majorUnit),C=_.labels,T=C.length,D=y.labels,E=D.padding,I=.05*b,B=y.rangeSize=y.rangeSize||.1*b,z=y.ranges||[],L=new P;for(_.options.rangeDistance!==e?I=_.options.rangeDistance:_.options.rangeDistance=I,D.position===Q&&(b-=w,z.length&&_.labelElements===e&&(b-=B+I),x.setRadiusX(b).setRadiusY(b)),c=0;c<T;c++)s=C[c],t=s.box.width()/2,n=s.box.height()/2,r=k[c],o=(r-X)*Y,d=D.position===Q,a=x.pointAt(r),h=a.x+l.cos(o)*(t+E)*(d?1:-1),u=a.y+l.sin(o)*(n+E)*(d?1:-1),s.reflow(new f.Box2D(h-t,u-n,h+t,u+n)),g=new A(s.box.x1,s.box.y1),_.labelElements===e?(p=i(s,y.labels),L.append(p)):(p=_.labelElements.children[c],m=p.bbox().origin,v=p.transform()||S.transform(),v.translate(g.x-m.x,g.y-m.y),p.transform(v)),_.bbox=M.union(_.bbox,p.bbox());return L},repositionRanges:function(){var t,e,i,n=this,o=n.ranges.children,r=n.options.rangeSize,s=n.options.rangeDistance;if(o.length>0){for(t=n.getRangeRadius(),n.options.labels.position===Q&&(t+=r+s),e=t+r/2,i=0;i<o.length;i++)o[i]._geometry.setRadiusX(e).setRadiusY(e);n.bbox=M.union(n.bbox,n.ranges.bbox())}},renderRanges:function(){var t,e,i,n,o,r,s=this,a=s.arc,l=new P,c=s.rangeSegments(),h=c.length,u=s.options.reverse,d=s.options.rangeSize,f=s.options.rangeDistance;if(h)for(n=s.getRangeRadius(),s.radius(s.radius()-d-f),r=0;r<h;r++)i=c[r],t=s.slotAngle(i[u?"to":"from"]),e=s.slotAngle(i[u?"from":"to"]),e-t!==0&&(o=new S.Arc(a.center,{radiusX:n+d/2,radiusY:n+d/2,startAngle:t,endAngle:e}),l.append(new T.Arc(o,{stroke:{width:d,color:i.color,opacity:i.opacity}})));return l},rangeSegments:function(){function t(t,e,i,n){return{from:t,to:e,color:i,opacity:n}}var e,i,o,r,s,a=this,l=a.options,c=l.ranges||[],h=c.length,u=l.rangePlaceholderColor,d=[],f=l.min,p=l.max;if(h)for(d.push(t(f,p,u)),r=0;r<h;r++)for(e=n(c[r],f,p),i=d.length,s=0;s<i;s++)if(o=d[s],o.from<=e.from&&e.from<=o.to){d.push(t(e.from,e.to,e.color,e.opacity)),o.from<=e.to&&e.to<=o.to&&d.push(t(e.to,o.to,u,e.opacity)),o.to=e.from;break}return d},getRangeRadius:function(){var t,e=this,i=e.options,n=i.majorTicks.size,o=i.rangeSize,r=i.rangeDistance,s=e.arc;return t=i.labels.position===J?s.getRadiusX()-n-r-o:s.getRadiusX()-o},renderArc:function(t,e){var i=this,n=i.options,o=i.arc=new S.Arc(t,{radiusX:e,radiusY:e,startAngle:n.startAngle+X,endAngle:n.endAngle+X});return o},renderTicks:function(){function t(t,e,i,n){var o,r,s,a=new P,l=t.center,c=t.getRadiusX(),h=n.visible;if(h)for(o=0;o<e.length;o++)r=t.pointAt(e[o]),s=new A(l.x+c-n.size,l.y).rotate(e[o],l),a.append(new D({stroke:{color:n.color,width:n.width}}).moveTo(r).lineTo(s));return a}var e=this,i=e.arc,n=e.options,o=n.labels.position,r=new P,s=n.majorTicks.size,a=n.minorTicks.size,l=i.clone(),c=l.getRadiusX();return e.majorTickAngles=e.tickAngles(i,n.majorUnit),e.majorTicks=t(l,e.majorTickAngles,n.majorUnit,n.majorTicks),r.append(e.majorTicks),e._tickDifference=s-a,o===J&&l.setRadiusX(c-s+a).setRadiusY(c-s+a),e.minorTickAngles=e.normalizeTickAngles(e.tickAngles(i,n.minorUnit)),e.minorTicks=t(l,e.minorTickAngles,n.minorUnit,n.minorTicks,n.majorUnit),r.append(e.minorTicks),r},normalizeTickAngles:function(t){var e,i=this,n=i.options,o=n.majorUnit/n.minorUnit;for(e=t.length-1;e>=0;e--)e%o===0&&t.splice(e,1);return t},tickAngles:function(t,e){var i,n=this,o=n.options,r=o.reverse,s=o.max-o.min,a=t.endAngle-t.startAngle,l=t.startAngle,c=s/e,h=a/c,u=[];for(r&&(l+=a,h=-h),i=0;i<c;i++)u.push(C(l,F)),l+=h;return C(l)<=t.endAngle&&u.push(l),u},radius:function(t){var i=this;return t?(i.arc.setRadiusX(t).setRadiusY(t),i.repositionTicks(i.majorTicks.children,i.majorTickAngles),i.repositionTicks(i.minorTicks.children,i.minorTickAngles,!0),e):i.arc.getRadiusX()},repositionTicks:function(t,e,i){var n,o,r,s,a,l=this,c=i?l._tickDifference||0:0,h=l.arc,u=h.getRadiusX();for(i&&l.options.labels.position===J&&0!==c&&(h=l.arc.clone(),h.setRadiusX(u-c).setRadiusY(u-c)),n=0;n<t.length;n++)o=h.pointAt(e[n]),r=t[n].segments,s=o.x-r[0].anchor().x,a=o.y-r[0].anchor().y,t[n].transform((new S.Transformation).translate(s,a))}}),st=u.extend({init:function(e,i){var n,o,r,s,a,l=this,h=f.ui.themes||{};if(c.destroy(e),t(e).empty(),u.fn.init.call(l,e),l.wrapper=l.element,l._originalOptions=d({},i),n=d({},l.options,i),r=n.theme,s=h[r]||h[r.toLowerCase()],o=r&&s?s.gauge:{},l.options=d({},o,n),t.isArray(n.pointer))for(a=0;a<n.pointer.length;a++)l.options.pointer[a]=d({},o.pointer,n.pointer[a]);l.element.addClass("k-gauge"),l.surface=l._createSurface(),l.redraw()},options:{plotArea:{},theme:"default",renderAs:"",pointer:{},scale:{},gaugeArea:{}},destroy:function(){this.surface.destroy(),u.fn.destroy.call(this)},value:function(t){var i=this,n=i.pointers[0];return 0===arguments.length?n.value():(n.value(t),i._setValueOptions(t),e)},_draw:function(){var t=this.surface;t.clear(),t.draw(this._visuals)},exportVisual:function(){return this._visuals},allValues:function(e){var i,n=this,o=n.pointers,r=[];if(0===arguments.length){for(i=0;i<o.length;i++)r.push(o[i].value());return r}if(t.isArray(e))for(i=0;i<e.length;i++)x(e[i])&&o[i].value(e[i]);n._setValueOptions(e)},_setValueOptions:function(t){var e,i=[].concat(this.options.pointer);for(t=[].concat(t),e=0;e<t.length;e++)i[e].value=t[e]},_resize:function(){var t,e=this,i=e.options.transitions;for(e.options.transitions=!1,t=0;t<e.pointers.length;t++)e.pointers[t].options.animation.transitions=!1;for(e.redraw(),e.options.transitions=i,t=0;t<e.pointers.length;t++)e.pointers[t].options.animation.transitions=i},redraw:function(){var t,e=this,i=d(e._getSize(),e.options.gaugeArea),n=new M([0,0],[i.width,i.height]);e.surface.clear(),e.gaugeArea=e._createGaugeArea(),e.surface.element.css({width:i.width,height:i.height}),e._createModel(),t=r(n.bbox(),e._gaugeAreaMargin),e.reflow(t)},_createGaugeArea:function(){var t,e=this,i=e.options.gaugeArea,n=e.surface.size(),o=i.border||{},s=new M([0,0],[n.width,n.height]);return e._gaugeAreaMargin=i.margin||$,o.width>0&&(s=r(s,o.width)),t=D.fromRect(s,{stroke:{color:o.width?o.color:"",width:o.width,dashType:o.dashType,lineJoin:"round",lineCap:"round"},fill:{color:i.background}})},_createSurface:function(){var e,i=this,n=i.options,o=i._getSize();return o=n.gaugeArea?d(o,n.gaugeArea):o,e=t("<div></div>").appendTo(i.element).css({width:o.width,height:o.height}),new T.Surface.create(e,{type:n.renderAs})},getSize:function(){return this._getSize()},_getSize:function(){var t=this,e=t.element,i=e.width(),n=e.height();return i||(i=G),n||(n=U),{width:i,height:n}}}),at=st.extend({init:function(t,e){var i=this;st.fn.init.call(i,t,e),c.notify(i,f.ui)},options:{name:"RadialGauge",transitions:!0,gaugeArea:{background:""}},reflow:function(t){var e,i=this,n=i.pointers;for(i.scale.reflow(t),i._initialPlotArea=i.scale.bbox,e=0;e<n.length;e++)n[e].reflow(i.scale.arc),i._initialPlotArea=M.union(i._initialPlotArea,n[e].bbox);i.fitScale(t),i.alignScale(t),i._buildVisual(i.gaugeArea,n,i.scale),i._draw()},_buildVisual:function(t,e,i){var n,o,r=new P;for(r.append(t),r.append(i.ticks),r.append(i.ranges),o=0;o<e.length;o++)n=e[o],n.render(),r.append(n.elements),n.value(n.options.value);r.append(i.labelElements),this._visuals=r},fitScale:function(t){for(var e,i,n,o,r,s=this,a=s.scale,c=a.arc,h=s._initialPlotArea,u=l.abs(s.getDiff(h,t)),d=C(u,F),f=C(-u,F),p=0,g=0;!(!(g++<100)||(p=r===n?p+1:0,p>5)||d!=o&&(e=s.getPlotBox(d,t,c),0<=e&&e<=2)||f!=o&&(n=s.getPlotBox(f,t,c),0<=n&&n<=2)||(o=e>0&&n>0?2*d:e<0&&n<0?2*f:C((d+f)/2||1,F),i=s.getPlotBox(o,t,c),0<=i&&i<=2));)r=n,i>0?(f=o,n=i):(d=o,e=i)},getPlotBox:function(t,e,i){var n,o=this,r=o.scale,s=o.pointers,a=i.getRadiusX();for(i=i.clone(),i.setRadiusX(a+t).setRadiusY(a+t),r.arc=i,r.reflow(e),o.plotBbox=r.bbox,n=0;n<s.length;n++)s[n].reflow(i),o.plotBbox=M.union(o.plotBbox,s[n].bbox);return o.getDiff(o.plotBbox,e)},getDiff:function(t,e){return l.min(e.width()-t.width(),e.height()-t.height())},alignScale:function(t){var e,i=this,n=i.plotBbox.center(),o=t.center(),r=n.x-o.x,s=n.y-o.y,a=i.scale,l=i.pointers;for(a.arc.center.x-=r,a.arc.center.y-=s,a.reflow(t),e=0;e<l.length;e++)l[e].reflow(a.arc),i.plotBbox=M.union(a.bbox,l[e].bbox)},_createModel:function(){var e,i,n=this,o=n.options,r=o.pointer,s=n.scale=new rt(o.scale);for(n.pointers=[],r=t.isArray(r)?r:[r],i=0;i<r.length;i++)e=new ot(s,d({},r[i],{animation:{transitions:o.transitions}})),n.pointers.push(e)}}),lt=st.extend({init:function(t,e){var i=this;st.fn.init.call(i,t,e),c.notify(i,f.ui)},options:{name:"LinearGauge",transitions:!0,gaugeArea:{background:""},scale:{vertical:!0}},reflow:function(t){var e,i=this,n=i.pointers,o=t.origin.x,r=t.origin.y,s=new f.Box2D(o,r,o+t.width(),r+t.height());for(i.scale.reflow(s),e=0;e<n.length;e++)n[e].reflow();i.bbox=i._getBox(s),i._alignElements(),i._shrinkElements(),i._buildVisual(),i._draw()},_buildVisual:function(){var t,e,i=this,n=new P,o=i.scale.render(),r=i.pointers;for(n.append(i.gaugeArea),n.append(o),e=0;e<r.length;e++)t=r[e],n.append(t.render()),t.value(t.options.value);i._visuals=n},_createModel:function(){var e,i,n,o=this,r=o.options,s=r.pointer,a=o.scale=new ct(r.scale);for(o.pointers=[],s=t.isArray(s)?s:[s],n=0;n<s.length;n++)i=d({},s[n],{animation:{transitions:r.transitions}}),e=i.shape===z?new ut(a,i):new dt(a,i),o.pointers.push(e)},_getSize:function(){var t=this,e=t.element,i=e.width(),n=e.height(),o=t.options.scale.vertical;return i||(i=o?W:G),n||(n=o?U:q),{width:i,height:n}},_getBox:function(t){var e,i,n=this,o=n.scale,r=n.pointers,s=t.center(),a=r[0].box.clone().wrap(o.box);for(i=0;i<r.length;i++)a.wrap(r[i].box.clone());return o.options.vertical?(e=a.width()/2,a=new _(s.x-e,t.y1,s.x+e,t.y2)):(e=a.height()/2,a=new _(t.x1,s.y-e,t.x2,s.y+e)),a},_alignElements:function(){var t,e,i=this,n=i.scale,o=i.pointers,r=n.box,s=o[0].box.clone().wrap(n.box),a=i.bbox;for(e=0;e<o.length;e++)s.wrap(o[e].box.clone());for(n.options.vertical?(t=a.center().x-s.center().x,n.reflow(new _(r.x1+t,a.y1,r.x2+t,a.y2))):(t=a.center().y-s.center().y,n.reflow(new _(a.x1,r.y1+t,a.x2,r.y2+t))),e=0;e<o.length;e++)o[e].reflow(i.bbox)},_shrinkElements:function(){var t,e=this,i=e.scale,n=e.pointers,o=i.box.clone(),r=i.options.vertical?"y":"x",s=n[0].box;for(t=0;t<n.length;t++)s.wrap(n[t].box.clone());for(o[r+1]+=l.max(o[r+1]-s[r+1],0),o[r+2]-=l.max(s[r+2]-o[r+2],0),i.reflow(o),t=0;t<n.length;t++)n[t].reflow(e.bbox)}}),ct=m.extend({init:function(t){var e=this;e.options=d({},e.options,t),e.options=d({},e.options,{labels:{mirror:e.options.mirror}}),e.options.majorUnit=e.options.majorUnit||p(e.options.min,e.options.max),v.fn.init.call(e,e.options),e.options.minorUnit=e.options.minorUnit||e.options.majorUnit/10},options:{min:0,max:50,majorTicks:{size:15,align:Q,color:O,width:j,visible:!0},minorTicks:{size:10,align:Q,color:O,width:j,visible:!0},line:{width:j},labels:{position:Q,padding:2},mirror:!1,_alignLines:!1},render:function(){var t=this,e=t.elements=new P,i=t.renderLabels(),n=t.renderLine(),o=t.renderTicks(),r=t.renderRanges();return e.append(n,i,o,r),e},renderRanges:function(){var t,e,i,o,r,s=this,a=s.options,l=a.min,c=a.max,h=a.ranges||[],u=a.vertical,d=a.labels.mirror,f=new P,p=h.length,g=a.rangeSize||a.minorTicks.size/2;if(p)for(r=0;r<p;r++)t=n(h[r],l,c),e=s.getSlot(t.from,t.to),i=u?s.lineBox():e,o=u?e:s.lineBox(),u?i.x1-=g*(d?-1:1):o.y2+=g*(d?-1:1),f.append(D.fromRect(new M([i.x1,o.y1],[i.x2-i.x1,o.y2-o.y1]),{fill:{color:t.color,opacity:t.opacity},stroke:{}}));return f},renderLabels:function(){var t,e=this,n=e.options,o=e.labels,r=new P;for(t=0;t<o.length;t++)r.append(i(o[t],n.labels));return r},renderLine:function(){var t,e=this,i=e.options,n=i.line,o=e.lineBox(),r=new P;return n.width>0&&n.visible&&(t=new D({stroke:{color:n.color,dashType:n.dashType,width:n.width}}),t.moveTo(o.x1,o.y1).lineTo(o.x2,o.y2),r.append(t)),r},renderTicks:function(){function t(t,n){var s,l=t.length;if(n.visible)for(s=n.skip;s<l;s+=n.step)s%n.skipUnit!==0&&(a.tickX=r?o.x2:o.x2-n.size,a.tickY=r?o.y1-n.size:o.y1,a.position=t[s],i.append(e.renderAxisTick(a,n)))}var e=this,i=new P,n=e.options,o=e.lineBox(),r=n.labels.mirror,s=n.majorTicks.visible?n.majorUnit:0,a={_alignLines:n._alignLines,vertical:n.vertical};return t(e.getMajorTickPositions(),n.majorTicks),t(e.getMinorTickPositions(),d({},{skipUnit:s/n.minorUnit},n.minorTicks)),i},renderAxisTick:function(t,e){var i,n,o,r=t.tickX,s=t.tickY,a=t.position;return t.vertical?(i=new A(r,a),n=new A(r+e.size,a)):(i=new A(a,s),n=new A(a,s+e.size)),o=new D({stroke:{color:e.color,width:e.width}}).moveTo(i).lineTo(n)}}),ht=nt.extend({init:function(t,e){var i=this;nt.fn.init.call(i,t,e),i.options=d({track:{visible:w(e.track)}},i.options)},options:{shape:R,track:{border:{width:1}},color:O,border:{width:1},opacity:1,margin:k(3),animation:{type:R},visible:!0},reflow:function(){var t,e,i,n=this,o=n.options,r=n.scale,s=r.lineBox(),a=o.track.size||o.size,l=o.size/2,c=r.options.mirror,h=k(o.margin),u=r.options.vertical,d=u?h[c?"left":"right"]:h[c?"bottom":"top"];d=c?-d:d,u?(i=new _(s.x1+d,s.y1,s.x1+d,s.y2),c?i.x1-=a:i.x2+=a,o.shape!==R&&(e=new _(s.x2+d,s.y1-l,s.x2+d,s.y2+l),t=e)):(i=new _(s.x1,s.y1-d,s.x2,s.y1-d),c?i.y2+=a:i.y1-=a,o.shape!==R&&(e=new _(s.x1-l,s.y1-d,s.x2+l,s.y1-d),t=e)),n.trackBox=i,n.pointerRangeBox=e,n.box=t||i.clone().pad(o.border.width)},getElementOptions:function(){var t=this.options;return{fill:{color:t.color,opacity:t.opacity},stroke:w(t.border)?{color:t.border.width?t.border.color||t.color:"",width:t.border.width,dashType:t.border.dashType,opacity:t.opacity}:null}},_margin:function(){var t=this,e=t.options,i=t.scale,n=i.options.mirror,o=k(e.margin),r=i.options.vertical,s=r?o[n?"left":"right"]:o[n?"bottom":"top"];return s}}),ut=ht.extend({init:function(t,i){ht.fn.init.call(this,t,i),this.options.size===e&&(this.options.size=.6*this.scale.options.majorTicks.size)},pointerShape:function(){var t,e,i=this,n=i.options,o=i.scale,r=n.size,s=o.options.vertical,a=r/2,l=o.options.mirror?-1:1,c=o.options.reverse;return s?(t=c?"y2":"y1",e=[new A(0,0-a),new A(0-l*r,0),new A(0,0+a)]):(t=c?"x1":"x2",e=[new A(0-a,0),new A(0,0+l*r),new A(0+a,0)]),e},repaint:function(){var t=this,e=t.scale,i=t.options,n=new s(t.elements,d(i.animation,{vertical:e.options.vertical,mirror:e.options.mirror,margin:t._margin(i.margin),from:e.getSlot(i._oldValue),to:e.getSlot(i.value)}));i.animation.transitions===!1&&(n.options.duration=0),n.setup(),n.play()},render:function(){var t,e=this,i=e.options,n=new P,o=e.scale,r=e.getElementOptions(),s=e.pointerShape(i.value);return i.animation.type=L,n=new D({stroke:r.stroke,fill:r.fill}).moveTo(s[0]).lineTo(s[1]).lineTo(s[2]).close(),t=o.getSlot(i.value),n.transform(S.transform().translate(t.x1,t.y1)),e.elements=n,n}}),dt=ht.extend({init:function(t,i){ht.fn.init.call(this,t,i),this.options.size===e&&(this.options.size=.3*this.scale.options.majorTicks.size)},pointerShape:function(t){var e,i,n,o=this,r=o.options,s=o.scale,a=s.options.vertical,l=s.options.mirror,c=l==a?-1:1,h=r.size*c,u=s.getSlot(s.options.min),d=s.getSlot(t),f=a?it:et,p=a?et:it,g=o._margin()*c,m=new A;return m[f]=u[f+"1"],m[p]=u[p+"1"],e=new A,e[f]=d[f+"1"],e[p]=d[p+"1"],a?(m.translate(g,0),e.translate(g,0)):(m.translate(0,g),e.translate(0,g)),i=e.clone(),n=m.clone(),a?(i.translate(h,0),n.translate(h,0)):(i.translate(0,h),n.translate(0,h)),[m,e,i,n]},repaint:function(){var t,e=this,i=e.scale,n=e.options,o=e.pointerShape(n.value),r=e.elements.children[0],s=e.pointerShape(n._oldValue);r.moveTo(o[0]).lineTo(o[1]).lineTo(o[2]).lineTo(o[3]).close(),t=new a(r,d(n.animation,{reverse:i.options.reverse,vertical:i.options.vertical,oldPoints:[s[1],s[2]],newPoints:[o[1],o[2]]})),n.animation.transitions===!1&&(t.options.duration=0),t.setup(),t.play()},render:function(){var t=this,e=new P,i=t.getElementOptions(),n=new D({stroke:i.stroke,fill:i.fill});return e.append(n),t.elements=e,e}}),ft=T.Animation.extend({init:function(t,e){T.Animation.fn.init.call(this,t,e),e=this.options,e.duration=l.max(l.abs(e.newAngle-e.oldAngle)/e.duration*1e3,1)},options:{easing:K,duration:I},step:function(t){var e=this,i=e.options,n=b(i.oldAngle,i.newAngle,t);e.element.transform(S.transform().rotate(n,i.center))}});T.AnimationFactory.current.register(tt,ft),s=T.Animation.extend({options:{easing:K,duration:B},setup:function(){var t,e,i=this.options,n=i.margin,o=i.from,r=i.to,s=i.vertical?"x1":"y1";i.mirror==i.vertical?(o[s]-=n,r[s]-=n):(o[s]+=n,r[s]+=n),t=this.fromScale=new A(o.x1,o.y1),e=this.toScale=new A(r.x1,r.y1),0!==i.duration&&(i.duration=l.max(t.distanceTo(e)/i.duration*1e3,1))},step:function(t){var e=b(this.fromScale.x,this.toScale.x,t),i=b(this.fromScale.y,this.toScale.y,t);this.element.transform(S.transform().translate(e,i))}}),T.AnimationFactory.current.register(L,s),a=T.Animation.extend({options:{easing:K,speed:B},setup:function(){var t=this.options,e=t.newPoints,i=t.oldPoints,n=this.axis=t.vertical?it:et,o=this.to=e[0][n],r=this.from=i[0][n];0!==t.duration&&(t.duration=l.max(l.abs(o-r)/t.speed*1e3,1)),this._set(r)},step:function(t){var e=b(this.from,this.to,t);this._set(e)},_set:function(t){var e="set"+this.axis.toUpperCase(),i=this.options.newPoints;i[0][e](t),i[1][e](t)}}),T.AnimationFactory.current.register(R,a),f.ui.plugin(at),f.ui.plugin(lt),f.ExportMixin.extend(st.fn),d(f,{Gauge:st,RadialPointer:ot,LinearPointer:ht,ArrowLinearPointer:ut,BarLinearPointer:dt,LinearScale:ct,RadialScale:rt,LinearGauge:lt,RadialGauge:at})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.barcode.min",["kendo.dataviz.core.min","kendo.drawing.min"],t)}(function(){return function(t,e){function i(t,e,i){return t.substring(e,e+i)}var n,o,r,s,a,l,c=window.kendo,h=c.ui.Widget,u=t.extend,d=c.deepExtend,f=t.inArray,p=t.isPlainObject,g=c.drawing,m=c.geometry,v=c.util,_=v.defined,y=c.dataviz,w=y.Box2D,x=y.TextBox,b=300,k=100,C=10,S=/^\d+$/,T=/^[a-z0-9]+$/i,A="Character '{0}' is not valid for symbology {1}",P=c.Class.extend({init:function(t){this.setOptions(t)},setOptions:function(t){var e=this;e.options=u({},e.options,t),e.quietZoneLength=e.options.addQuietZone?2*e.options.quietZoneLength:0},encode:function(t,e,i){var n=this;return _(t)&&(t+=""),n.initValue(t,e,i),n.options.addQuietZone&&n.addQuietZone(),n.addData(),n.options.addQuietZone&&n.addQuietZone(),{baseUnit:n.baseUnit,pattern:n.pattern}},options:{quietZoneLength:C,addQuietZone:!0,addCheckSum:!0},initValue:function(){},addQuietZone:function(){this.pattern.push(this.options.quietZoneLength||C)},addData:function(){},invalidCharacterError:function(t){throw Error(c.format(A,t,this.name))}}),D={},M=P.extend({minBaseUnitLength:.7,addData:function(){var t,e=this,i=e.value;for(e.addStart(),t=0;t<i.length;t++)e.addCharacter(i.charAt(t));e.options.addCheckSum&&e.pushCheckSum(),e.addStop(),e.prepareValues()},addCharacter:function(t){var e=this,i=e.characterMap[t];i||e.invalidCharacterError(t),e.addBase(i)},addBase:function(){}}),E={addCharacter:function(t){var e=this;e.characterMap[t]?e.addBase(e.characterMap[t]):t.charCodeAt(0)>127?e.invalidCharacterError(t):e.addExtended(t.charCodeAt(0))},addExtended:function(t){var i,n,o,r=this;for(n=0;n<r.extendedMappings.length;n++)if(i=r.extendedMappings[n].call(r,t)){for(o=0;o<i.length;o++)r.addBase(i[o]);return r.dataLength+=i.length-1,e}},extendedMappings:[function(t){if(97<=t&&t<=122){var e=this;return[e.characterMap[e.shiftCharacters[0]],e.characterMap[String.fromCharCode(t-32)]]}},function(t){if(33<=t&&t<=58){var e=this;return[e.characterMap[e.shiftCharacters[1]],e.characterMap[String.fromCharCode(t+32)]]}},function(t){if(1<=t&&t<=26){var e=this;return[e.characterMap[e.shiftCharacters[2]],e.characterMap[String.fromCharCode(t+64)]]}},function(t){var e,i,n,o=this;if(o.specialAsciiCodes[t])for(e=[],n=0;n<o.specialAsciiCodes[t].length;n++)e.push(o.characterMap[o.shiftCharacters[3]]),e.push(o.characterMap[o.specialAsciiCodes[t][n]]);else i=6*Math.floor(t/32)+(t-27)%32+64,e=[o.characterMap[o.shiftCharacters[3]],o.characterMap[String.fromCharCode(i)]];return e}],specialAsciiCodes:{0:["U"],64:["V"],96:["W"],127:["T","X","Y","Z"]},shiftValuesAsciiCodes:{39:36,40:47,41:43,42:37},characterMap:{"+":!1,"/":!1,$:!1,"%":!1},shiftCharacters:["SHIFT0","SHIFT1","SHIFT2","SHIFT3"]};D.code39=M.extend({name:"Code 39",checkSumMod:43,minRatio:2.5,maxRatio:3,gapWidth:1,splitCharacter:"|",initValue:function(t,e,i){var n=this;n.width=e,n.height=i,n.value=t,n.dataLength=t.length,n.pattern=[],n.patternString=""},prepareValues:function(){var t,e,i=this,n=i.minBaseUnitLength,o=i.maxRatio,r=i.minRatio,s=Math.max(.15*i.width,24);if(i.height<s)throw Error("Insufficient Height. The minimum height for value: "+i.value+" is: "+s);for(;(t=i.getBaseUnit(o))<n&&o>r;)o=parseFloat((o-.1).toFixed(1));if(t<n)throw e=Math.ceil(i.getBaseWidth(r)*n),Error("Insufficient width. The minimum width for value: "+i.value+" is: "+e);i.ratio=o,i.baseUnit=t,i.patternString=i.patternString.substring(0,i.patternString.length-1),i.pattern=i.pattern.concat(i.patternString.replace(/ratio/g,o).split(i.splitCharacter))},getBaseUnit:function(t){return this.width/this.getBaseWidth(t)},getBaseWidth:function(t){var e=this,i=3*(t+2);return e.quietZoneLength+i*(e.dataLength+2)+e.gapWidth*(e.dataLength+1)},addStart:function(){var t=this;t.addPattern(t.characterMap.START.pattern),t.addCharacterGap()},addBase:function(t){this.addPattern(t.pattern),this.addCharacterGap()},addStop:function(){this.addPattern(this.characterMap.START.pattern)},addPattern:function(t){for(var e=0;e<t.length;e++)this.patternString+=this.patternMappings[t.charAt(e)]},addCharacterGap:function(){var t=this;t.patternString+=t.gapWidth+t.splitCharacter},patternMappings:{b:"1|",w:"1|",B:"ratio|",W:"ratio|"},characterMap:{0:{pattern:"bwbWBwBwb",value:0},1:{pattern:"BwbWbwbwB",value:1},2:{pattern:"bwBWbwbwB",value:2},3:{pattern:"BwBWbwbwb",value:3},4:{pattern:"bwbWBwbwB",value:4},5:{pattern:"BwbWBwbwb",value:5},6:{pattern:"bwBWBwbwb",value:6},7:{pattern:"bwbWbwBwB",value:7},8:{pattern:"BwbWbwBwb",value:8},9:{pattern:"bwBWbwBwb",value:9},A:{pattern:"BwbwbWbwB",value:10},B:{pattern:"bwBwbWbwB",value:11},C:{pattern:"BwBwbWbwb",value:12},D:{pattern:"bwbwBWbwB",value:13},E:{pattern:"BwbwBWbwb",value:14},F:{pattern:"bwBwBWbwb",value:15},G:{pattern:"bwbwbWBwB",value:16},H:{pattern:"BwbwbWBwb",value:17},I:{pattern:"bwBwbWBwb",value:18},J:{pattern:"bwbwBWBwb",value:19},K:{pattern:"BwbwbwbWB",value:20},L:{pattern:"bwBwbwbWB",value:21},M:{pattern:"BwBwbwbWb",value:22},N:{pattern:"bwbwBwbWB",value:23},O:{pattern:"BwbwBwbWb",value:24},P:{pattern:"bwBwBwbWb",value:25},Q:{pattern:"bwbwbwBWB",value:26},R:{pattern:"BwbwbwBWb",value:27},S:{pattern:"bwBwbwBWb",value:28},T:{pattern:"bwbwBwBWb",value:29},U:{pattern:"BWbwbwbwB",value:30},V:{pattern:"bWBwbwbwB",value:31},W:{pattern:"BWBwbwbwb",value:32},X:{pattern:"bWbwBwbwB",value:33},Y:{pattern:"BWbwBwbwb",value:34},Z:{pattern:"bWBwBwbwb",value:35},"-":{pattern:"bWbwbwBwB",value:36},".":{pattern:"BWbwbwBwb",value:37}," ":{pattern:"bWBwbwBwb",value:38},$:{pattern:"bWbWbWbwb",value:39},"/":{pattern:"bWbWbwbWb",value:40},"+":{pattern:"bWbwbWbWb",value:41},"%":{pattern:"bwbWbWbWb",value:42},START:{pattern:"bWbwBwBwb"}},options:{addCheckSum:!1}}),D.code39extended=D.code39.extend(d({},E,{name:"Code 39 extended",characterMap:{SHIFT0:{pattern:"bWbwbWbWb",value:41},SHIFT1:{pattern:"bWbWbwbWb",value:40},SHIFT2:{pattern:"bWbWbWbwb",value:39},SHIFT3:{pattern:"bwbWbWbWb",value:42}}})),D.code93=M.extend({name:"Code 93",cCheckSumTotal:20,kCheckSumTotal:15,checkSumMod:47,initValue:function(t,e,i){var n=this;n.value=t,n.width=e,n.height=i,n.pattern=[],n.values=[],n.dataLength=t.length},prepareValues:function(){var t=this,e=Math.max(.15*t.width,24);if(t.height<e)throw Error("Insufficient Height");if(t.setBaseUnit(),t.baseUnit<t.minBaseUnitLength)throw Error("Insufficient Width");
},setBaseUnit:function(){var t=this,e=2;t.baseUnit=t.width/(9*(t.dataLength+2+e)+t.quietZoneLength+1)},addStart:function(){var t=this.characterMap.START.pattern;this.addPattern(t)},addStop:function(){var t=this;t.addStart(),t.pattern.push(t.characterMap.TERMINATION_BAR)},addBase:function(t){this.addPattern(t.pattern),this.values.push(t.value)},pushCheckSum:function(){var t,e,i=this,n=i._getCheckValues();for(i.checksum=n.join(""),e=0;e<n.length;e++)t=i.characterMap[i._findCharacterByValue(n[e])],i.addPattern(t.pattern)},_getCheckValues:function(){var t,e,i,n=this,o=n.values,r=o.length,s=0;for(i=r-1;i>=0;i--)s+=n.weightedValue(o[i],r-i,n.cCheckSumTotal);for(t=s%n.checkSumMod,s=n.weightedValue(t,1,n.kCheckSumTotal),i=r-1;i>=0;i--)s+=n.weightedValue(o[i],r-i+1,n.kCheckSumTotal);return e=s%n.checkSumMod,[t,e]},_findCharacterByValue:function(t){for(var e in this.characterMap)if(this.characterMap[e].value===t)return e},weightedValue:function(t,e,i){return(e%i||i)*t},addPattern:function(t){var e,i;for(i=0;i<t.length;i++)e=parseInt(t.charAt(i),10),this.pattern.push(e)},characterMap:{0:{pattern:"131112",value:0},1:{pattern:"111213",value:1},2:{pattern:"111312",value:2},3:{pattern:"111411",value:3},4:{pattern:"121113",value:4},5:{pattern:"121212",value:5},6:{pattern:"121311",value:6},7:{pattern:"111114",value:7},8:{pattern:"131211",value:8},9:{pattern:"141111",value:9},A:{pattern:"211113",value:10},B:{pattern:"211212",value:11},C:{pattern:"211311",value:12},D:{pattern:"221112",value:13},E:{pattern:"221211",value:14},F:{pattern:"231111",value:15},G:{pattern:"112113",value:16},H:{pattern:"112212",value:17},I:{pattern:"112311",value:18},J:{pattern:"122112",value:19},K:{pattern:"132111",value:20},L:{pattern:"111123",value:21},M:{pattern:"111222",value:22},N:{pattern:"111321",value:23},O:{pattern:"121122",value:24},P:{pattern:"131121",value:25},Q:{pattern:"212112",value:26},R:{pattern:"212211",value:27},S:{pattern:"211122",value:28},T:{pattern:"211221",value:29},U:{pattern:"221121",value:30},V:{pattern:"222111",value:31},W:{pattern:"112122",value:32},X:{pattern:"112221",value:33},Y:{pattern:"122121",value:34},Z:{pattern:"123111",value:35},"-":{pattern:"121131",value:36},".":{pattern:"311112",value:37}," ":{pattern:"311211",value:38},$:{pattern:"321111",value:39},"/":{pattern:"112131",value:40},"+":{pattern:"113121",value:41},"%":{pattern:"211131",value:42},SHIFT0:{pattern:"122211",value:46},SHIFT1:{pattern:"311121",value:45},SHIFT2:{pattern:"121221",value:43},SHIFT3:{pattern:"312111",value:44},START:{pattern:"111141"},TERMINATION_BAR:"1"}}),D.code93extended=D.code93.extend(d({},E,{name:"Code 93 extended",pushCheckSum:function(){var t,e,i=this,n=i._getCheckValues();for(i.checksum=n.join(""),e=0;e<n.length;e++)t=n[e],i.shiftValuesAsciiCodes[t]?i.addExtended(i.shiftValuesAsciiCodes[t]):i.addPattern(i.characterMap[i._findCharacterByValue(t)].pattern)}})),n=c.Class.extend({init:function(t){this.encoding=t},addStart:function(){},is:function(){},move:function(){},pushState:function(){}}),o=n.extend({FNC4:"FNC4",init:function(t,e){var i=this;i.encoding=t,i.states=e,i._initMoves(e)},addStart:function(){this.encoding.addPattern(this.START)},is:function(t,e){var i=t.charCodeAt(e);return this.isCode(i)},move:function(t){for(var e=this,i=0;!e._moves[i].call(e,t)&&i<e._moves.length;)i++},pushState:function(t){var e,i,n=this,o=n.states,r=t.value,s=r.length;for(f("C",o)>=0&&(i=r.substr(t.index).match(/\d{4,}/g),i&&(s=r.indexOf(i[0],t.index)));(e=t.value.charCodeAt(t.index))>=0&&n.isCode(e)&&t.index<s;)n.encoding.addPattern(n.getValue(e)),t.index++},_initMoves:function(t){var e=this;e._moves=[],f(e.FNC4,t)>=0&&e._moves.push(e._moveFNC),f(e.shiftKey,t)>=0&&e._moves.push(e._shiftState),e._moves.push(e._moveState)},_moveFNC:function(t){if(t.fnc)return t.fnc=!1,t.previousState==this.key},_shiftState:function(t){var e=this;if(t.previousState==e.shiftKey&&(t.index+1>=t.value.length||e.encoding[e.shiftKey].is(t.value,t.index+1)))return e.encoding.addPattern(e.SHIFT),t.shifted=!0,!0},_moveState:function(){return this.encoding.addPattern(this.MOVE),!0},SHIFT:98}),r={},r.A=o.extend({key:"A",shiftKey:"B",isCode:function(t){return 0<=t&&t<96},getValue:function(t){return t<32?t+64:t-32},MOVE:101,START:103}),r.B=o.extend({key:"B",shiftKey:"A",isCode:function(t){return 32<=t&&t<128},getValue:function(t){return t-32},MOVE:100,START:104}),r.C=n.extend({key:"C",addStart:function(){this.encoding.addPattern(this.START)},is:function(t,e){var n=i(t,e,4);return(e+4<=t.length||2==t.length)&&S.test(n)},move:function(){this.encoding.addPattern(this.MOVE)},pushState:function(t){for(var e;(e=i(t.value,t.index,2))&&S.test(e)&&2==e.length;)this.encoding.addPattern(parseInt(e,10)),t.index+=2},getValue:function(t){return t},MOVE:99,START:105}),r.FNC4=n.extend({key:"FNC4",dependentStates:["A","B"],init:function(t,e){this.encoding=t,this._initSubStates(e)},addStart:function(t){var e=t.value.charCodeAt(0)-128,i=this._getSubState(e);this.encoding[i].addStart()},is:function(t,e){var i=t.charCodeAt(e);return this.isCode(i)},isCode:function(t){return 128<=t&&t<256},pushState:function(t){var e,i=this,n=i._initSubState(t),o=i.encoding,r=n.value.length;if(t.index+=r,r<3)for(;n.index<r;n.index++)e=n.value.charCodeAt(n.index),n.state=i._getSubState(e),n.previousState!=n.state&&(n.previousState=n.state,o[n.state].move(n)),o.addPattern(o[n.state].MOVE),o.addPattern(o[n.state].getValue(e));else n.state!=n.previousState&&o[n.state].move(n),i._pushStart(n),o.pushData(n,i.subStates),t.index<t.value.length&&i._pushStart(n);t.fnc=!0,t.state=n.state},_pushStart:function(t){var e=this;e.encoding.addPattern(e.encoding[t.state].MOVE),e.encoding.addPattern(e.encoding[t.state].MOVE)},_initSubState:function(t){var e=this,i={value:e._getAll(t.value,t.index),index:0};return i.state=e._getSubState(i.value.charCodeAt(0)),i.previousState=t.previousState==e.key?i.state:t.previousState,i},_initSubStates:function(t){var e,i=this;for(i.subStates=[],e=0;e<t.length;e++)f(t[e],i.dependentStates)>=0&&i.subStates.push(t[e])},_getSubState:function(t){var e,i=this;for(e=0;e<i.subStates.length;e++)if(i.encoding[i.subStates[e]].isCode(t))return i.subStates[e]},_getAll:function(t,e){for(var i,n="";(i=t.charCodeAt(e++))&&this.isCode(i);)n+=String.fromCharCode(i-128);return n}}),r.FNC1=n.extend({key:"FNC1",startState:"C",dependentStates:["C","B"],startAI:"(",endAI:")",init:function(t,e){this.encoding=t,this.states=e},addStart:function(){this.encoding[this.startState].addStart()},is:function(){return f(this.key,this.states)>=0},pushState:function(t){var e,i,n,o=this,r=o.encoding,s=t.value.replace(/\s/g,""),a=RegExp("["+o.startAI+o.endAI+"]","g"),l=t.index,c={state:o.startState};for(r.addPattern(o.START);;){if(c.index=0,n=s.charAt(l)===o.startAI?2:0,e=n>0?o.getBySeparator(s,l):o.getByLength(s,l),e.ai.length)i=l+n+e.id.length+e.ai.length;else if(i=s.indexOf(o.startAI,l+1),i<0){if(l+e.ai.max+e.id.length+n<s.length)throw Error("Separators are required after variable length identifiers");i=s.length}if(c.value=s.substring(l,i).replace(a,""),o.validate(e,c.value),r.pushData(c,o.dependentStates),i>=s.length)break;l=i,c.state!=o.startState&&(r[o.startState].move(c),c.state=o.startState),e.ai.length||r.addPattern(o.START)}t.index=t.value.length},validate:function(t,e){var i=e.substr(t.id.length),n=t.ai;if(!n.type&&!S.test(i))throw Error("Application identifier "+t.id+" is numeric only but contains non numeric character(s).");if("alphanumeric"==n.type&&!T.test(i))throw Error("Application identifier "+t.id+" is alphanumeric only but contains non alphanumeric character(s).");if(n.length&&n.length!==i.length)throw Error("Application identifier "+t.id+" must be "+n.length+" characters long.");if(n.min&&n.min>i.length)throw Error("Application identifier "+t.id+" must be at least "+n.min+" characters long.");if(n.max&&n.max<i.length)throw Error("Application identifier "+t.id+" must be at most "+n.max+" characters long.")},getByLength:function(t,e){var n,o,r,s=this;for(r=2;r<=4;r++)if(n=i(t,e,r),o=s.getAI(n)||s.getAI(n.substring(0,n.length-1)))return{id:n,ai:o};s.unsupportedAIError(n)},unsupportedAIError:function(t){throw Error(c.format("'{0}' is not a supported Application Identifier"),t)},getBySeparator:function(t,e){var i=this,n=t.indexOf(i.startAI,e),o=t.indexOf(i.endAI,n),r=t.substring(n+1,o),s=i.getAI(r)||i.getAI(r.substr(r.length-1));return s||i.unsupportedAIError(r),{ai:s,id:r}},getAI:function(t){var e,i,n,o=this.applicationIdentifiers,r=o.multiKey;if(o[t])return o[t];for(e=0;e<r.length;e++){if(r[e].ids&&f(t,r[e].ids)>=0)return r[e].type;if(r[e].ranges)for(i=r[e].ranges,n=0;n<i.length;n++)if(i[n][0]<=t&&t<=i[n][1])return r[e].type}},applicationIdentifiers:{22:{max:29,type:"alphanumeric"},402:{length:17},7004:{max:4,type:"alphanumeric"},242:{max:6,type:"alphanumeric"},8020:{max:25,type:"alphanumeric"},703:{min:3,max:30,type:"alphanumeric"},8008:{min:8,max:12,type:"alphanumeric"},253:{min:13,max:17,type:"alphanumeric"},8003:{min:14,max:30,type:"alphanumeric"},multiKey:[{ids:["15","17","8005","8100"],ranges:[[11,13],[310,316],[320,336],[340,369]],type:{length:6}},{ids:["240","241","250","251","400","401","403","7002","8004","8007","8110"],ranges:[[-9]],type:{max:30,type:"alphanumeric"}},{ids:["7001"],ranges:[[410,414]],type:{length:13}},{ids:["10","21","254","420","8002"],type:{max:20,type:"alphanumeric"}},{ids:["00","8006","8017","8018"],type:{length:18}},{ids:["01","02","8001"],type:{length:14}},{ids:["422"],ranges:[[424,426]],type:{length:3}},{ids:["20","8102"],type:{length:2}},{ids:["30","37"],type:{max:8,type:"alphanumeric"}},{ids:["390","392"],type:{max:15,type:"alphanumeric"}},{ids:["421","423"],type:{min:3,max:15,type:"alphanumeric"}},{ids:["391","393"],type:{min:3,max:18,type:"alphanumeric"}},{ids:["7003","8101"],type:{length:10}}]},START:102}),s=P.extend({init:function(t){P.fn.init.call(this,t),this._initStates()},_initStates:function(){var t,e=this;for(t=0;t<e.states.length;t++)e[e.states[t]]=new r[e.states[t]](e,e.states)},initValue:function(t,e,i){var n=this;n.pattern=[],n.value=t,n.width=e,n.height=i,n.checkSum=0,n.totalUnits=0,n.index=0,n.position=1},addData:function(){var t=this,e={value:t.value,index:0,state:""};0!==t.value.length&&(e.state=e.previousState=t.getNextState(e,t.states),t.addStart(e),t.pushData(e,t.states),t.addCheckSum(),t.addStop(),t.setBaseUnit())},pushData:function(t,e){for(var i,n=this;;){if(n[t.state].pushState(t),t.index>=t.value.length)break;t.shifted?(i=t.state,t.state=t.previousState,t.previousState=i,t.shifted=!1):(t.previousState=t.state,t.state=n.getNextState(t,e),n[t.state].move(t))}},addStart:function(t){this[t.state].addStart(t),this.position=1},addCheckSum:function(){var t=this;t.checksum=t.checkSum%103,t.addPattern(t.checksum)},addStop:function(){this.addPattern(this.STOP)},setBaseUnit:function(){var t=this;t.baseUnit=t.width/(t.totalUnits+t.quietZoneLength)},addPattern:function(t){var e,i,n=this,o=""+n.characterMap[t];for(i=0;i<o.length;i++)e=parseInt(o.charAt(i),10),n.pattern.push(e),n.totalUnits+=e;n.checkSum+=t*n.position++},getNextState:function(t,e){for(var i=0;i<e.length;i++)if(this[e[i]].is(t.value,t.index))return e[i];this.invalidCharacterError(t.value.charAt(t.index))},characterMap:[212222,222122,222221,121223,121322,131222,122213,122312,132212,221213,221312,231212,112232,122132,122231,113222,123122,123221,223211,221132,221231,213212,223112,312131,311222,321122,321221,312212,322112,322211,212123,212321,232121,111323,131123,131321,112313,132113,132311,211313,231113,231311,112133,112331,132131,113123,113321,133121,313121,211331,231131,213113,213311,213131,311123,311321,331121,312113,312311,332111,314111,221411,431111,111224,111422,121124,121421,141122,141221,112214,112412,122114,122411,142112,142211,241211,221114,413111,241112,134111,111242,121142,121241,114212,124112,124211,411212,421112,421211,212141,214121,412121,111143,111341,131141,114113,114311,411113,411311,113141,114131,311141,411131,211412,211214,211232,2331112],STOP:106}),D.code128a=s.extend({name:"Code 128 A",states:["A"]}),D.code128b=s.extend({name:"Code 128 B",states:["B"]}),D.code128c=s.extend({name:"Code 128 C",states:["C"]}),D.code128=s.extend({name:"Code 128",states:["C","B","A","FNC4"]}),D["gs1-128"]=s.extend({name:"Code GS1-128",states:["FNC1","C","B"]}),a=P.extend({initValue:function(t,e){var i=this;i.pattern=[],i.value=t,i.checkSumLength=0,i.width=e},setBaseUnit:function(){var t=this,e=7;t.baseUnit=t.width/(12*(t.value.length+t.checkSumLength)+t.quietZoneLength+e)},addData:function(){var t,e=this,i=e.value;for(e.addPattern(e.START),t=0;t<i.length;t++)e.addCharacter(i.charAt(t));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.STOP),e.setBaseUnit()},addCharacter:function(t){var e=this,i=e.characterMap[t];i||e.invalidCharacterError(t),e.addPattern(i)},addPattern:function(t){for(var e=0;e<t.length;e++)this.pattern.push(parseInt(t.charAt(e),10))},addCheckSum:function(){var t,e=this,i=e.checkSums[e.checkSumType],n=i.call(e.checkSums,e.value);for(e.checksum=n.join(""),t=0;t<n.length;t++)e.checkSumLength++,e.addPattern(e.characterMap[n[t]])},checkSums:{Modulo10:function(t){var e,i,n,o=[0,""],r=t.length%2;for(e=0;e<t.length;e++)o[(e+r)%2]+=parseInt(t.charAt(e),10);for(n=o[0],i=""+2*o[1],e=0;e<i.length;e++)n+=parseInt(i.charAt(e),10);return[(10-n%10)%10]},Modulo11:function(t){var e,i,n,o=0,r=11,s=t.length;for(n=0;n<s;n++)e=((s-n)%6||6)+1,o+=e*t.charAt(n);return i=(r-o%r)%r,10!=i?[i]:[1,0]},Modulo11Modulo10:function(t){var e,i=this.Modulo11(t);return e=t+i[0],i.concat(this.Modulo10(e))},Modulo10Modulo10:function(t){var e,i=this.Modulo10(t);return e=t+i[0],i.concat(this.Modulo10(e))}},characterMap:["12121212","12121221","12122112","12122121","12211212","12211221","12212112","12212121","21121212","21121221"],START:"21",STOP:"121",checkSumType:""}),D.msimod10=a.extend({name:"MSI Modulo10",checkSumType:"Modulo10"}),D.msimod11=a.extend({name:"MSI Modulo11",checkSumType:"Modulo11"}),D.msimod1110=a.extend({name:"MSI Modulo11 Modulo10",checkSumType:"Modulo11Modulo10"}),D.msimod1010=a.extend({name:"MSI Modulo10 Modulo10",checkSumType:"Modulo10Modulo10"}),D.code11=P.extend({name:"Code 11",cCheckSumTotal:10,kCheckSumTotal:9,kCheckSumMinLength:10,checkSumMod:11,DASH_VALUE:10,DASH:"-",START:"112211",STOP:"11221",initValue:function(t,e){var i=this;i.pattern=[],i.value=t,i.width=e,i.totalUnits=0},addData:function(){var t,e=this,i=e.value;for(e.addPattern(e.START),t=0;t<i.length;t++)e.addCharacter(i.charAt(t));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.STOP),e.setBaseUnit()},setBaseUnit:function(){var t=this;t.baseUnit=t.width/(t.totalUnits+t.quietZoneLength)},addCheckSum:function(){var t,e=this,i=e.value,n=i.length,o=e.getWeightedSum(i,n,e.cCheckSumTotal)%e.checkSumMod;e.checksum=o+"",e.addPattern(e.characterMap[o]),n++,n>=e.kCheckSumMinLength&&(t=(o+e.getWeightedSum(i,n,e.kCheckSumTotal))%e.checkSumMod,e.checksum+=t,e.addPattern(e.characterMap[t]))},getWeightedSum:function(t,e,i){var n,o=0;for(n=0;n<t.length;n++)o+=this.weightedValue(this.getValue(t.charAt(n)),e,n,i);return o},weightedValue:function(t,e,i,n){var o=(e-i)%n||n;return o*t},getValue:function(t){var e=this;return isNaN(t)?(t!==e.DASH&&e.invalidCharacterError(t),e.DASH_VALUE):parseInt(t,10)},addCharacter:function(t){var e=this,i=e.getValue(t),n=e.characterMap[i];e.addPattern(n)},addPattern:function(t){var e,i;for(i=0;i<t.length;i++)e=parseInt(t.charAt(i),10),this.pattern.push(e),this.totalUnits+=e},characterMap:["111121","211121","121121","221111","112121","212111","122111","111221","211211","211111","112111"],options:{addCheckSum:!0}}),D.postnet=P.extend({name:"Postnet",START:"2",VALID_CODE_LENGTHS:[5,9,11],DIGIT_SEPARATOR:"-",initValue:function(t,e,i){var n=this;n.height=i,n.width=e,n.baseHeight=i/2,n.value=t.replace(RegExp(n.DIGIT_SEPARATOR,"g"),""),n.pattern=[],n.validate(n.value),n.checkSum=0,n.setBaseUnit()},addData:function(){var t,e=this,i=e.value;for(e.addPattern(e.START),t=0;t<i.length;t++)e.addCharacter(i.charAt(t));e.options.addCheckSum&&e.addCheckSum(),e.addPattern(e.START),e.pattern.pop()},addCharacter:function(t){var e=this,i=e.characterMap[t];e.checkSum+=parseInt(t,10),e.addPattern(i)},addCheckSum:function(){var t=this;t.checksum=(10-t.checkSum%10)%10,t.addCharacter(t.checksum)},setBaseUnit:function(){var t=this,e=3;t.baseUnit=t.width/(10*(t.value.length+1)+e+t.quietZoneLength)},validate:function(t){var e=this;if(S.test(t)||e.invalidCharacterError(t.match(/[^0-9]/)[0]),f(t.length,e.VALID_CODE_LENGTHS)<0)throw Error("Invalid value length. Valid lengths for the Postnet symbology are "+e.VALID_CODE_LENGTHS.join(","))},addPattern:function(t){var e,i,n=this;for(i=0;i<t.length;i++)e=n.height-n.baseHeight*t.charAt(i),n.pattern.push({width:1,y1:e,y2:n.height}),n.pattern.push(1)},characterMap:["22111","11122","11212","11221","12112","12121","12211","21112","21121","21211"]}),D.ean13=P.extend({initValue:function(t,e,i){if(t+="",12!=t.length||/\D/.test(t))throw Error('The value of the "EAN13" encoding should be 12 symbols');var n=this;n.pattern=[],n.options.height=i,n.baseUnit=e/(95+n.quietZoneLength),n.value=t,n.checksum=n.calculateChecksum(),n.leftKey=t[0],n.leftPart=t.substr(1,6),n.rightPart=t.substr(7)+n.checksum},addData:function(){var t=this;t.addPieces(t.characterMap.start),t.addSide(t.leftPart,t.leftKey),t.addPieces(t.characterMap.middle),t.addSide(t.rightPart),t.addPieces(t.characterMap.start)},addSide:function(t,e){var i,n=this;for(i=0;i<t.length;i++)e&&parseInt(n.keyTable[e].charAt(i),10)?n.addPieces(Array.prototype.slice.call(n.characterMap.digits[t.charAt(i)]).reverse(),!0):n.addPieces(n.characterMap.digits[t.charAt(i)],!0)},addPieces:function(t,e){var i,n=this;for(i=0;i<t.length;i++)n.pattern.push(e?{y1:0,y2:.95*n.options.height,width:t[i]}:t[i])},calculateChecksum:function(){var t,e,i=0,n=0,o=this.value.split("").reverse().join("");for(t=0;t<o.length;t++)t%2?n+=parseInt(o.charAt(t),10):i+=parseInt(o.charAt(t),10);return e=(10-(3*i+n)%10)%10},keyTable:["000000","001011","001101","001110","010011","011001","011100","010101","010110","011010"],characterMap:{digits:[[3,2,1,1],[2,2,2,1],[2,1,2,2],[1,4,1,1],[1,1,3,2],[1,2,3,1],[1,1,1,4],[1,3,1,2],[1,2,1,3],[3,1,1,2]],start:[1,1,1],middle:[1,1,1,1,1]}}),D.ean8=D.ean13.extend({initValue:function(t,e,i){var n=this;if(7!=t.length||/\D/.test(t))throw Error("Invalid value provided");n.value=t,n.options.height=i,n.checksum=n.calculateChecksum(n.value),n.leftPart=n.value.substr(0,4),n.rightPart=n.value.substr(4)+n.checksum,n.pattern=[],n.baseUnit=e/(67+n.quietZoneLength)}}),l=h.extend({init:function(e,i){var n=this;h.fn.init.call(n,e,i),n.element=t(e),n.wrapper=n.element,n.element.addClass("k-barcode").css("display","block"),n.surfaceWrap=t("<div />").css("position","relative").appendTo(this.element),n.surface=g.Surface.create(n.surfaceWrap,{type:n.options.renderAs}),n.setOptions(i)},setOptions:function(t){var e=this;if(e.type=(t.type||e.options.type).toLowerCase(),"upca"==e.type&&(e.type="ean13",t.value="0"+t.value),"upce"==e.type&&(e.type="ean8",t.value="0"+t.value),!D[e.type])throw Error("Encoding "+e.type+"is not supported.");e.encoding=new D[e.type],e.options=u(!0,e.options,t),_(t.value)&&e.redraw()},redraw:function(){var t=this._getSize();this.surface.clear(),this.surface.setSize({width:t.width,height:t.height}),this.createVisual(),this.surface.draw(this.visual)},getSize:function(){return c.dimensions(this.element)},_resize:function(){this.redraw()},createVisual:function(){this.visual=this._render()},_render:function(){var t,e,i,n=this,o=n.options,r=o.value,s=o.text,a=y.getSpacing(s.margin),l=n._getSize(),c=o.border||{},h=n.encoding,u=w(0,0,l.width,l.height).unpad(c.width).unpad(o.padding),d=u.height(),f=new g.Group;return n.contentBox=u,f.append(n._getBackground(l)),s.visible&&(i=g.util.measureText(r,{font:s.font}).height,d-=i+a.top+a.bottom),t=h.encode(r,u.width(),d),s.visible&&(e=r,o.checksum&&_(h.checksum)&&(e+=" "+h.checksum),f.append(n._getText(e))),n.barHeight=d,this._bandsGroup=this._getBands(t.pattern,t.baseUnit),f.append(this._bandsGroup),f},exportVisual:function(){return this._render()},_getSize:function(){var t=this,e=t.element,i=new m.Size(b,k);return e.width()>0&&(i.width=e.width()),e.height()>0&&(i.height=e.height()),t.options.width&&(i.width=t.options.width),t.options.height&&(i.height=t.options.height),i},value:function(t){var i=this;return _(t)?(i.options.value=t+"",i.redraw(),e):i.options.value},_getBands:function(t,e){var i,n,o,r,s,a=this,l=a.contentBox,c=l.x1,h=new g.Group;for(o=0;o<t.length;o++)n=p(t[o])?t[o]:{width:t[o],y1:0,y2:a.barHeight},i=n.width*e,o%2&&(r=m.Rect.fromPoints(new m.Point(c,n.y1+l.y1),new m.Point(c+i,n.y2+l.y1)),s=g.Path.fromRect(r,{fill:{color:a.options.color},stroke:null}),h.append(s)),c+=i;return h},_getBackground:function(t){var e=this,i=e.options,n=i.border||{},o=w(0,0,t.width,t.height).unpad(n.width/2),r=g.Path.fromRect(o.toRect(),{fill:{color:i.background},stroke:{color:n.width?n.color:"",width:n.width,dashType:n.dashType}});return r},_getText:function(t){var e=this,i=e.options.text,n=e._textbox=new x(t,{font:i.font,color:i.color,align:"center",vAlign:"bottom",margin:i.margin});return n.reflow(e.contentBox),n.renderVisual(),n.visual},options:{name:"Barcode",renderAs:"svg",value:"",type:"code39",checksum:!1,width:0,height:0,color:"black",background:"white",text:{visible:!0,font:"16px Consolas, Monaco, Sans Mono, monospace, sans-serif",color:"black",margin:{top:0,bottom:0,left:0,right:0}},border:{width:0,dashType:"solid",color:"black"},padding:{top:0,bottom:0,left:0,right:0}}}),y.ExportMixin.extend(l.fn),y.ui.plugin(l),c.deepExtend(y,{encodings:D,Encoding:P})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.qrcode.min",["kendo.dataviz.core.min","kendo.drawing.min"],t)}(function(){return function(t,e){function i(t){return parseInt(t,2)}function n(t,e){var i=(+t).toString(2);return i.length<e&&(i=Array(e-i.length+1).join(0)+i),i}function o(t,e){for(var i=[],n=0;n<t.length;)i.push(t.substring(n,n+e)),n+=e;return i}function r(t,e,i,n){for(var o=0;o<t.length;o++)t[o][i][n]=e}function s(t,e,i,n){for(var o=0;o<vt.length;o++)t[o][i][n]=vt[o](i,n)?1^e:parseInt(e,10)}function a(){var t,e;for(e=1;e<255;e++)t=2*rt[e-1],t>255&&(t=285^t),rt[e]=t,ot[t]=e;t=2*rt[e-1]^285,rt[e]=t,rt[-1]=0}function l(){var t,e,i,n=68;for(t=2;t<=n;t++)e=st[t-1],i=[t,0],st[t]=w(e,i)}function c(t,i){var n=[],o=t.length-1;do n[o]=rt[(t[o]+i)%255],o--;while(t[o]!==e);return n}function h(t,e){return parseInt(t.charAt(e),10)}function u(t,e,i,n,o){e[t][n]=(e[t][n]<<1^o)%128,e[t][n]==mt&&(i[t]+=40)}function d(t,e,i,n,o,r){i[t][r]==n?o[t][r]++:(i[t][r]=n,o[t][r]>=5&&(e[t]+=3+o[t][r]-5),o[t][r]=1)}function f(t,e){var i=Math.floor(t/e*100),n=i%5,o=Math.abs(i-n-50),r=Math.abs(i+5-n-50),s=10*Math.min(o/5,r/5);return s}var p,g,m,v,_,y,w,x,b,k,C,S,T,A,P,D,M,E,I,B,z,L,R,O,V,F,N,H,U,j,G,W,q,$,Y=window.kendo,X=t.extend,Q=Y.drawing,K=Y.dataviz,Z=Y.ui.Widget,J=K.Box2D,tt="0000",et="numeric",it="alphanumeric",nt="byte",ot={1:0},rt={0:1},st=[[1,0],[1,25,0]],at={15:20,16:20,18:24,19:24,22:20,24:22,26:24,28:20,30:20,31:24,32:28,33:24,36:18,37:22,39:20,40:24},lt=[{L:{groups:[[1,19]],totalDataCodewords:19,errorCodewordsPerBlock:7},M:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:10},Q:{groups:[[1,13]],totalDataCodewords:13,errorCodewordsPerBlock:13},H:{groups:[[1,9]],totalDataCodewords:9,errorCodewordsPerBlock:17}},{L:{groups:[[1,34]],totalDataCodewords:34,errorCodewordsPerBlock:10},M:{groups:[[1,28]],totalDataCodewords:28,errorCodewordsPerBlock:16},Q:{groups:[[1,22]],totalDataCodewords:22,errorCodewordsPerBlock:22},H:{groups:[[1,16]],totalDataCodewords:16,errorCodewordsPerBlock:28}},{L:{groups:[[1,55]],totalDataCodewords:55,errorCodewordsPerBlock:15},M:{groups:[[1,44]],totalDataCodewords:44,errorCodewordsPerBlock:26},Q:{groups:[[2,17]],totalDataCodewords:34,errorCodewordsPerBlock:18},H:{groups:[[2,13]],totalDataCodewords:26,errorCodewordsPerBlock:22}},{L:{groups:[[1,80]],totalDataCodewords:80,errorCodewordsPerBlock:20},M:{groups:[[2,32]],totalDataCodewords:64,errorCodewordsPerBlock:18},Q:{groups:[[2,24]],totalDataCodewords:48,errorCodewordsPerBlock:26},H:{groups:[[4,9]],totalDataCodewords:36,errorCodewordsPerBlock:16}},{L:{groups:[[1,108]],totalDataCodewords:108,errorCodewordsPerBlock:26},M:{groups:[[2,43]],totalDataCodewords:86,errorCodewordsPerBlock:24},Q:{groups:[[2,15],[2,16]],totalDataCodewords:62,errorCodewordsPerBlock:18},H:{groups:[[2,11],[2,12]],totalDataCodewords:46,errorCodewordsPerBlock:22}},{L:{groups:[[2,68]],totalDataCodewords:136,errorCodewordsPerBlock:18},M:{groups:[[4,27]],totalDataCodewords:108,errorCodewordsPerBlock:16},Q:{groups:[[4,19]],totalDataCodewords:76,errorCodewordsPerBlock:24},H:{groups:[[4,15]],totalDataCodewords:60,errorCodewordsPerBlock:28}},{L:{groups:[[2,78]],totalDataCodewords:156,errorCodewordsPerBlock:20},M:{groups:[[4,31]],totalDataCodewords:124,errorCodewordsPerBlock:18},Q:{groups:[[2,14],[4,15]],totalDataCodewords:88,errorCodewordsPerBlock:18},H:{groups:[[4,13],[1,14]],totalDataCodewords:66,errorCodewordsPerBlock:26}},{L:{groups:[[2,97]],totalDataCodewords:194,errorCodewordsPerBlock:24},M:{groups:[[2,38],[2,39]],totalDataCodewords:154,errorCodewordsPerBlock:22},Q:{groups:[[4,18],[2,19]],totalDataCodewords:110,errorCodewordsPerBlock:22},H:{groups:[[4,14],[2,15]],totalDataCodewords:86,errorCodewordsPerBlock:26}},{L:{groups:[[2,116]],totalDataCodewords:232,errorCodewordsPerBlock:30},M:{groups:[[3,36],[2,37]],totalDataCodewords:182,errorCodewordsPerBlock:22},Q:{groups:[[4,16],[4,17]],totalDataCodewords:132,errorCodewordsPerBlock:20},H:{groups:[[4,12],[4,13]],totalDataCodewords:100,errorCodewordsPerBlock:24}},{L:{groups:[[2,68],[2,69]],totalDataCodewords:274,errorCodewordsPerBlock:18},M:{groups:[[4,43],[1,44]],totalDataCodewords:216,errorCodewordsPerBlock:26},Q:{groups:[[6,19],[2,20]],totalDataCodewords:154,errorCodewordsPerBlock:24},H:{groups:[[6,15],[2,16]],totalDataCodewords:122,errorCodewordsPerBlock:28}},{L:{groups:[[4,81]],totalDataCodewords:324,errorCodewordsPerBlock:20},M:{groups:[[1,50],[4,51]],totalDataCodewords:254,errorCodewordsPerBlock:30},Q:{groups:[[4,22],[4,23]],totalDataCodewords:180,errorCodewordsPerBlock:28},H:{groups:[[3,12],[8,13]],totalDataCodewords:140,errorCodewordsPerBlock:24}},{L:{groups:[[2,92],[2,93]],totalDataCodewords:370,errorCodewordsPerBlock:24},M:{groups:[[6,36],[2,37]],totalDataCodewords:290,errorCodewordsPerBlock:22},Q:{groups:[[4,20],[6,21]],totalDataCodewords:206,errorCodewordsPerBlock:26},H:{groups:[[7,14],[4,15]],totalDataCodewords:158,errorCodewordsPerBlock:28}},{L:{groups:[[4,107]],totalDataCodewords:428,errorCodewordsPerBlock:26},M:{groups:[[8,37],[1,38]],totalDataCodewords:334,errorCodewordsPerBlock:22},Q:{groups:[[8,20],[4,21]],totalDataCodewords:244,errorCodewordsPerBlock:24},H:{groups:[[12,11],[4,12]],totalDataCodewords:180,errorCodewordsPerBlock:22}},{L:{groups:[[3,115],[1,116]],totalDataCodewords:461,errorCodewordsPerBlock:30},M:{groups:[[4,40],[5,41]],totalDataCodewords:365,errorCodewordsPerBlock:24},Q:{groups:[[11,16],[5,17]],totalDataCodewords:261,errorCodewordsPerBlock:20},H:{groups:[[11,12],[5,13]],totalDataCodewords:197,errorCodewordsPerBlock:24}},{L:{groups:[[5,87],[1,88]],totalDataCodewords:523,errorCodewordsPerBlock:22},M:{groups:[[5,41],[5,42]],totalDataCodewords:415,errorCodewordsPerBlock:24},Q:{groups:[[5,24],[7,25]],totalDataCodewords:295,errorCodewordsPerBlock:30},H:{groups:[[11,12],[7,13]],totalDataCodewords:223,errorCodewordsPerBlock:24}},{L:{groups:[[5,98],[1,99]],totalDataCodewords:589,errorCodewordsPerBlock:24},M:{groups:[[7,45],[3,46]],totalDataCodewords:453,errorCodewordsPerBlock:28},Q:{groups:[[15,19],[2,20]],totalDataCodewords:325,errorCodewordsPerBlock:24},H:{groups:[[3,15],[13,16]],totalDataCodewords:253,errorCodewordsPerBlock:30}},{L:{groups:[[1,107],[5,108]],totalDataCodewords:647,errorCodewordsPerBlock:28},M:{groups:[[10,46],[1,47]],totalDataCodewords:507,errorCodewordsPerBlock:28},Q:{groups:[[1,22],[15,23]],totalDataCodewords:367,errorCodewordsPerBlock:28},H:{groups:[[2,14],[17,15]],totalDataCodewords:283,errorCodewordsPerBlock:28}},{L:{groups:[[5,120],[1,121]],totalDataCodewords:721,errorCodewordsPerBlock:30},M:{groups:[[9,43],[4,44]],totalDataCodewords:563,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[1,23]],totalDataCodewords:397,errorCodewordsPerBlock:28},H:{groups:[[2,14],[19,15]],totalDataCodewords:313,errorCodewordsPerBlock:28}},{L:{groups:[[3,113],[4,114]],totalDataCodewords:795,errorCodewordsPerBlock:28},M:{groups:[[3,44],[11,45]],totalDataCodewords:627,errorCodewordsPerBlock:26},Q:{groups:[[17,21],[4,22]],totalDataCodewords:445,errorCodewordsPerBlock:26},H:{groups:[[9,13],[16,14]],totalDataCodewords:341,errorCodewordsPerBlock:26}},{L:{groups:[[3,107],[5,108]],totalDataCodewords:861,errorCodewordsPerBlock:28},M:{groups:[[3,41],[13,42]],totalDataCodewords:669,errorCodewordsPerBlock:26},Q:{groups:[[15,24],[5,25]],totalDataCodewords:485,errorCodewordsPerBlock:30},H:{groups:[[15,15],[10,16]],totalDataCodewords:385,errorCodewordsPerBlock:28}},{L:{groups:[[4,116],[4,117]],totalDataCodewords:932,errorCodewordsPerBlock:28},M:{groups:[[17,42]],totalDataCodewords:714,errorCodewordsPerBlock:26},Q:{groups:[[17,22],[6,23]],totalDataCodewords:512,errorCodewordsPerBlock:28},H:{groups:[[19,16],[6,17]],totalDataCodewords:406,errorCodewordsPerBlock:30}},{L:{groups:[[2,111],[7,112]],totalDataCodewords:1006,errorCodewordsPerBlock:28},M:{groups:[[17,46]],totalDataCodewords:782,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[16,25]],totalDataCodewords:568,errorCodewordsPerBlock:30},H:{groups:[[34,13]],totalDataCodewords:442,errorCodewordsPerBlock:24}},{L:{groups:[[4,121],[5,122]],totalDataCodewords:1094,errorCodewordsPerBlock:30},M:{groups:[[4,47],[14,48]],totalDataCodewords:860,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[14,25]],totalDataCodewords:614,errorCodewordsPerBlock:30},H:{groups:[[16,15],[14,16]],totalDataCodewords:464,errorCodewordsPerBlock:30}},{L:{groups:[[6,117],[4,118]],totalDataCodewords:1174,errorCodewordsPerBlock:30},M:{groups:[[6,45],[14,46]],totalDataCodewords:914,errorCodewordsPerBlock:28},Q:{groups:[[11,24],[16,25]],totalDataCodewords:664,errorCodewordsPerBlock:30},H:{groups:[[30,16],[2,17]],totalDataCodewords:514,errorCodewordsPerBlock:30}},{L:{groups:[[8,106],[4,107]],totalDataCodewords:1276,errorCodewordsPerBlock:26},M:{groups:[[8,47],[13,48]],totalDataCodewords:1e3,errorCodewordsPerBlock:28},Q:{groups:[[7,24],[22,25]],totalDataCodewords:718,errorCodewordsPerBlock:30},H:{groups:[[22,15],[13,16]],totalDataCodewords:538,errorCodewordsPerBlock:30}},{L:{groups:[[10,114],[2,115]],totalDataCodewords:1370,errorCodewordsPerBlock:28},M:{groups:[[19,46],[4,47]],totalDataCodewords:1062,errorCodewordsPerBlock:28},Q:{groups:[[28,22],[6,23]],totalDataCodewords:754,errorCodewordsPerBlock:28},H:{groups:[[33,16],[4,17]],totalDataCodewords:596,errorCodewordsPerBlock:30}},{L:{groups:[[8,122],[4,123]],totalDataCodewords:1468,errorCodewordsPerBlock:30},M:{groups:[[22,45],[3,46]],totalDataCodewords:1128,errorCodewordsPerBlock:28},Q:{groups:[[8,23],[26,24]],totalDataCodewords:808,errorCodewordsPerBlock:30},H:{groups:[[12,15],[28,16]],totalDataCodewords:628,errorCodewordsPerBlock:30}},{L:{groups:[[3,117],[10,118]],totalDataCodewords:1531,errorCodewordsPerBlock:30},M:{groups:[[3,45],[23,46]],totalDataCodewords:1193,errorCodewordsPerBlock:28},Q:{groups:[[4,24],[31,25]],totalDataCodewords:871,errorCodewordsPerBlock:30},H:{groups:[[11,15],[31,16]],totalDataCodewords:661,errorCodewordsPerBlock:30}},{L:{groups:[[7,116],[7,117]],totalDataCodewords:1631,errorCodewordsPerBlock:30},M:{groups:[[21,45],[7,46]],totalDataCodewords:1267,errorCodewordsPerBlock:28},Q:{groups:[[1,23],[37,24]],totalDataCodewords:911,errorCodewordsPerBlock:30},H:{groups:[[19,15],[26,16]],totalDataCodewords:701,errorCodewordsPerBlock:30}},{L:{groups:[[5,115],[10,116]],totalDataCodewords:1735,errorCodewordsPerBlock:30
},M:{groups:[[19,47],[10,48]],totalDataCodewords:1373,errorCodewordsPerBlock:28},Q:{groups:[[15,24],[25,25]],totalDataCodewords:985,errorCodewordsPerBlock:30},H:{groups:[[23,15],[25,16]],totalDataCodewords:745,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[3,116]],totalDataCodewords:1843,errorCodewordsPerBlock:30},M:{groups:[[2,46],[29,47]],totalDataCodewords:1455,errorCodewordsPerBlock:28},Q:{groups:[[42,24],[1,25]],totalDataCodewords:1033,errorCodewordsPerBlock:30},H:{groups:[[23,15],[28,16]],totalDataCodewords:793,errorCodewordsPerBlock:30}},{L:{groups:[[17,115]],totalDataCodewords:1955,errorCodewordsPerBlock:30},M:{groups:[[10,46],[23,47]],totalDataCodewords:1541,errorCodewordsPerBlock:28},Q:{groups:[[10,24],[35,25]],totalDataCodewords:1115,errorCodewordsPerBlock:30},H:{groups:[[19,15],[35,16]],totalDataCodewords:845,errorCodewordsPerBlock:30}},{L:{groups:[[17,115],[1,116]],totalDataCodewords:2071,errorCodewordsPerBlock:30},M:{groups:[[14,46],[21,47]],totalDataCodewords:1631,errorCodewordsPerBlock:28},Q:{groups:[[29,24],[19,25]],totalDataCodewords:1171,errorCodewordsPerBlock:30},H:{groups:[[11,15],[46,16]],totalDataCodewords:901,errorCodewordsPerBlock:30}},{L:{groups:[[13,115],[6,116]],totalDataCodewords:2191,errorCodewordsPerBlock:30},M:{groups:[[14,46],[23,47]],totalDataCodewords:1725,errorCodewordsPerBlock:28},Q:{groups:[[44,24],[7,25]],totalDataCodewords:1231,errorCodewordsPerBlock:30},H:{groups:[[59,16],[1,17]],totalDataCodewords:961,errorCodewordsPerBlock:30}},{L:{groups:[[12,121],[7,122]],totalDataCodewords:2306,errorCodewordsPerBlock:30},M:{groups:[[12,47],[26,48]],totalDataCodewords:1812,errorCodewordsPerBlock:28},Q:{groups:[[39,24],[14,25]],totalDataCodewords:1286,errorCodewordsPerBlock:30},H:{groups:[[22,15],[41,16]],totalDataCodewords:986,errorCodewordsPerBlock:30}},{L:{groups:[[6,121],[14,122]],totalDataCodewords:2434,errorCodewordsPerBlock:30},M:{groups:[[6,47],[34,48]],totalDataCodewords:1914,errorCodewordsPerBlock:28},Q:{groups:[[46,24],[10,25]],totalDataCodewords:1354,errorCodewordsPerBlock:30},H:{groups:[[2,15],[64,16]],totalDataCodewords:1054,errorCodewordsPerBlock:30}},{L:{groups:[[17,122],[4,123]],totalDataCodewords:2566,errorCodewordsPerBlock:30},M:{groups:[[29,46],[14,47]],totalDataCodewords:1992,errorCodewordsPerBlock:28},Q:{groups:[[49,24],[10,25]],totalDataCodewords:1426,errorCodewordsPerBlock:30},H:{groups:[[24,15],[46,16]],totalDataCodewords:1096,errorCodewordsPerBlock:30}},{L:{groups:[[4,122],[18,123]],totalDataCodewords:2702,errorCodewordsPerBlock:30},M:{groups:[[13,46],[32,47]],totalDataCodewords:2102,errorCodewordsPerBlock:28},Q:{groups:[[48,24],[14,25]],totalDataCodewords:1502,errorCodewordsPerBlock:30},H:{groups:[[42,15],[32,16]],totalDataCodewords:1142,errorCodewordsPerBlock:30}},{L:{groups:[[20,117],[4,118]],totalDataCodewords:2812,errorCodewordsPerBlock:30},M:{groups:[[40,47],[7,48]],totalDataCodewords:2216,errorCodewordsPerBlock:28},Q:{groups:[[43,24],[22,25]],totalDataCodewords:1582,errorCodewordsPerBlock:30},H:{groups:[[10,15],[67,16]],totalDataCodewords:1222,errorCodewordsPerBlock:30}},{L:{groups:[[19,118],[6,119]],totalDataCodewords:2956,errorCodewordsPerBlock:30},M:{groups:[[18,47],[31,48]],totalDataCodewords:2334,errorCodewordsPerBlock:28},Q:{groups:[[34,24],[34,25]],totalDataCodewords:1666,errorCodewordsPerBlock:30},H:{groups:[[20,15],[61,16]],totalDataCodewords:1276,errorCodewordsPerBlock:30}}],ct=[1,0,1,1,1],ht=[1,0,1],ut={L:"01",M:"00",Q:"11",H:"10"},dt="101010000010010",ft="10100110111",pt="1111100100101",gt=["11101100","00010001"],mt=93,vt=[function(t,e){return(t+e)%2===0},function(t){return t%2===0},function(t,e){return e%3===0},function(t,e){return(t+e)%3===0},function(t,e){return(Math.floor(t/2)+Math.floor(e/3))%2===0},function(t,e){return t*e%2+t*e%3===0},function(t,e){return(t*e%2+t*e%3)%2===0},function(t,e){return((t+e)%2+t*e%3)%2===0}],_t=/^\d+/,yt="A-Z0-9 $%*+./:-",wt="A-Z $%*+./:-",xt=RegExp("^["+wt+"]+"),bt=RegExp("^["+yt+"]+"),kt=RegExp("^[^"+yt+"]+"),Ct=8,St=5,Tt=8,At=17,Pt=9,Dt=16,Mt=Math.round,Et=Y.Class.extend({getVersionIndex:function(t){return t<10?0:t>26?2:1},getBitsCharacterCount:function(t){var e=this;return e.bitsInCharacterCount[e.getVersionIndex(t||40)]},getModeCountString:function(t,e){var i=this;return i.modeIndicator+n(t,i.getBitsCharacterCount(e))},encode:function(){},getStringBitsLength:function(){},getValue:function(){},modeIndicator:"",bitsInCharacterCount:[]}),It={};It[et]=Et.extend({bitsInCharacterCount:[10,12,14],modeIndicator:"0001",getValue:function(t){return parseInt(t,10)},encode:function(t,e){var i,r=this,s=o(t,3),a=r.getModeCountString(t.length,e);for(i=0;i<s.length-1;i++)a+=n(s[i],10);return a+n(s[i],1+3*s[i].length)},getStringBitsLength:function(t,e){var i=t%3;return 4+this.getBitsCharacterCount(e)+10*Math.floor(t/3)+3*i+(0===i?0:1)}}),It[it]=Et.extend({characters:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,G:16,H:17,I:18,J:19,K:20,L:21,M:22,N:23,O:24,P:25,Q:26,R:27,S:28,T:29,U:30,V:31,W:32,X:33,Y:34,Z:35," ":36,$:37,"%":38,"*":39,"+":40,"-":41,".":42,"/":43,":":44},bitsInCharacterCount:[9,11,13],modeIndicator:"0010",getValue:function(t){return this.characters[t]},encode:function(t,e){var i,r,s=this,a=o(t,2),l=s.getModeCountString(t.length,e);for(r=0;r<a.length-1;r++)i=45*s.getValue(a[r].charAt(0))+s.getValue(a[r].charAt(1)),l+=n(i,11);return i=2==a[r].length?45*s.getValue(a[r].charAt(0))+s.getValue(a[r].charAt(1)):s.getValue(a[r].charAt(0)),l+n(i,1+5*a[r].length)},getStringBitsLength:function(t,e){return 4+this.getBitsCharacterCount(e)+11*Math.floor(t/2)+6*(t%2)}}),It[nt]=Et.extend({bitsInCharacterCount:[8,16,16],modeIndicator:"0100",getValue:function(t){var e=t.charCodeAt(0);if(e<=127||160<=e&&e<=255)return e;throw Error("Unsupported character: "+t)},encode:function(t,e){var i,o=this,r=o.getModeCountString(t.length,e);for(i=0;i<t.length;i++)r+=n(o.getValue(t.charAt(i)),8);return r},getStringBitsLength:function(t,e){return 4+this.getBitsCharacterCount(e)+8*t}}),p={};for(g in It)p[g]=new It[g];m=function(t){var i=this,n=t.length-1,o=t.length-1,r=o,s=-1,a=0;i.move=function(){n+=s*a,a^=1,o=r-a},i.getNextCell=function(){for(;t[n][o]!==e;)i.move(),(n<0||n>=t.length)&&(s=-s,r-=8!=r?2:3,o=r,n=s<0?t.length-1:0);return{row:n,column:o}},i.getNextRemainderCell=function(){if(i.move(),t[n][o]===e)return{row:n,column:o}}},v=function(t,e){var i,n,o,r,a,l,c=new m(t[0]);for(r=0;r<e.length;r++)for(i=e[r],n=0;i.length>0;){for(a=0;a<i.length;a++)for(l=0;l<8;l++)o=c.getNextCell(),s(t,i[a][n].charAt(l),o.row,o.column);for(n++;i[0]&&n==i[0].length;)i.splice(0,1)}for(;o=c.getNextRemainderCell();)s(t,0,o.row,o.column)},_=function(t,e){for(var i=8*e,n=0,o=0;t.length<i&&n<tt.length;)t+=tt.charAt(n++);for(t.length%8!==0&&(t+=Array(9-t.length%8).join("0"));t.length<i;)t+=gt[o],o^=1;return t},y=function(t,e){var i,n=[],o=t.length-2;for(i=o;i>=0;i--)n[i]=t[i]^e[i];return n},w=function(t,i){var n,o,r=[];for(n=0;n<t.length;n++)for(o=0;o<i.length;o++)r[n+o]=r[n+o]===e?(t[n]+(i[o]>=0?i[o]:0))%255:ot[rt[r[n+o]]^rt[(t[n]+i[o])%255]];return r},a(),l(),x=function(t,e){var i,o,r=st[e-1],s=Array(e).concat(t),a=Array(s.length-r.length).concat(r),l=t.length,h=[];for(o=0;o<l;o++)i=c(a,ot[s[s.length-1]]),a.splice(0,1),s=y(i,s);for(o=s.length-1;o>=0;o--)h[e-1-o]=n(s[o],8);return h},b=function(t,e){var n,o,r,s,a,l,c,h,u=0,d=[],f=[],p=e.groups;for(l=0;l<p.length;l++)for(r=p[l][0],c=0;c<r;c++){for(o=p[l][1],n=[],s=[],h=1;h<=o;h++)a=t.substring(u,u+8),n.push(a),s[o-h]=i(a),u+=8;d.push(n),f.push(x(s,e.errorCodewordsPerBlock))}return[d,f]},k=function(t,e,i,n,o){var r,s,a=_t.exec(t),l=a?a[0]:"",c=xt.exec(t),h=c?c[0]:"",u=bt.exec(t),d=u?u[0]:"";return l&&(l.length>=e||t.length==l.length||l.length>=i&&!bt.test(t.charAt(l.length)))?(r=et,s=l):d&&(t.length==d.length||d.length>=n||o==it)?(r=it,s=l||h):(r=nt,s=d?d+kt.exec(t.substring(d.length))[0]:kt.exec(t)[0]),{mode:r,modeString:s}},C=function(t){var e,i,n=[],o=0;for(n.push(k(t,Ct,St,Tt,e)),e=n[0].mode,t=t.substr(n[0].modeString.length);t.length>0;)i=k(t,At,Pt,Dt,e),i.mode!=e?(e=i.mode,n.push(i),o++):n[o].modeString+=i.modeString,t=t.substr(i.modeString.length);return n},S=function(t){var e,i,n=0;for(i=0;i<t.length;i++)e=p[t[i].mode],n+=e.getStringBitsLength(t[i].modeString.length);return Math.ceil(n/8)},T=function(t,e){var i=0,n=lt.length-1,o=Math.floor(lt.length/2);do t<lt[o][e].totalDataCodewords?n=o:i=o,o=i+Math.floor((n-i)/2);while(n-i>1);return t<=lt[i][e].totalDataCodewords?o+1:n+1},A=function(t,e){var i,n,o="";for(n=0;n<t.length;n++)i=p[t[n].mode],o+=i.encode(t[n].modeString,e);return o},P=function(t){var e,n,o=i(t),r="";if(0===o)return"101010000010010";for(e=D(i(t),ft,15),n=0;n<e.length;n++)r+=e.charAt(n)^dt.charAt(n);return r},D=function(t,e,o){var r=i(e),s=e.length-1,a=t<<s,l=o-s,c=n(t,l),h=M(a,r);return h=c+n(h,s)},M=function(t,e){var i=e.toString(2).length,n=t.toString(2).length;do t^=e<<n-i,n=t.toString(2).length;while(n>=i);return t},E=function(t){var e,i,n=[],o=17+4*t;for(e=0;e<vt.length;e++)for(n[e]=Array(o),i=0;i<o;i++)n[e][i]=Array(o);return n},I=function(t,e){var i,n,o=t[0],s=0,a=e.length;for(i=0,n=8;i<=8;i++)6!==i&&r(t,h(e,a-1-s++),i,n);for(i=8,n=7;n>=0;n--)6!==n&&r(t,h(e,a-1-s++),i,n);for(s=0,n=o.length-1,i=8;n>=o.length-8;n--)r(t,h(e,a-1-s++),i,n);for(r(t,1,o.length-8,8),i=o.length-7,n=8;i<o.length;i++)r(t,h(e,a-1-s++),i,n)},B=function(t){return D(t,pt,18)},z=function(t,e){var i,n,o,s,a=t[0],l=a.length,c=0,u=l-11,d=l-11,f=0;for(s=0;s<e.length;s++)i=Math.floor(s/3),n=s%3,o=h(e,e.length-s-1),r(t,o,c+i,u+n),r(t,o,d+n,f+i)},L=function(t,e,i,n){var o,s,a,l=e.length+2,c=e.length+1;for(s=0;s<e.length;s++)for(a=s;a<l-s;a++)o=e[s],r(t,o,i+a,n+s),r(t,o,i+s,n+a),r(t,o,i+c-a,n+c-s),r(t,o,i+c-s,n+c-a)},R=function(t,e,i,n){var o=i,s=n,a=t[0];do r(t,0,o,n),r(t,0,i,s),o+=e[0],s+=e[1];while(o>=0&&o<a.length)},O=function(t){var e=t[0].length;L(t,ct,0,0),R(t,[-1,-1],7,7),L(t,ct,e-7,0),R(t,[1,-1],e-8,7),L(t,ct,0,e-7),R(t,[-1,1],7,e-8)},V=function(t,i){var n,o,r,s,a,l,c,h,u;if(!(i<2)){for(n=t[0],o=n.length,r=Math.floor(i/7),s=[6],c=0,(a=at[i])?l=(o-13-a)/r:a=l=(o-13)/(r+1),s.push(s[c++]+a);s[c]+l<o;)s.push(s[c++]+l);for(h=0;h<s.length;h++)for(u=0;u<s.length;u++)n[s[h]][s[u]]===e&&L(t,ht,s[h]-2,s[u]-2)}},F=function(t){var e,i=6,n=6,o=1,s=t[0].length;for(e=8;e<s-8;e++)r(t,o,i,e),r(t,o,e,n),o^=1},N=function(t){var e,i,n,o,r,s,a,l=[],c=[],h=[],p=[],g=[],m=0,v=1,_=t[0].length;for(i=0;i<t.length;i++)l[i]=0,h[i]=0,g[i]=[0,0],p[i]=[0,0],c[i]=[];for(i=0;i<_;i++)for(n=0;n<_;n++)for(o=0;o<t.length;o++)e=t[o],h[o]+=parseInt(e[i][n],10),c[o][m]===e[i][n]&&i+1<_&&n-1>=0&&e[i+1][n]==c[o][m]&&e[i+1][n-1]==c[o][m]&&(l[o]+=3),u(o,p,l,m,e[i][n]),u(o,p,l,v,e[n][i]),d(o,l,c,e[i][n],g,m),d(o,l,c,e[n][i],g,v);for(r=_*_,a=Number.MAX_VALUE,i=0;i<l.length;i++)l[i]+=f(h[i],r),l[i]<a&&(a=l[i],s=i);return s},H=function(t,e){this.dataString=t,this.version=e},U=function(){this.getEncodingResult=function(t,e){var i=C(t),n=S(i),o=T(n,e),r=A(i,o);return new H(r,o)}},j=function(){this.mode=p[this.encodingMode]},j.fn=j.prototype={encodingMode:nt,utfBOM:"111011111011101110111111",initialModeCountStringLength:20,getEncodingResult:function(t,e){var i=this,n=i.encode(t),o=i.getDataCodewordsCount(n),r=T(o,e),s=i.mode.getModeCountString(n.length/8,r)+n;return new H(s,r)},getDataCodewordsCount:function(t){var e=this,i=t.length,n=Math.ceil((e.initialModeCountStringLength+i)/8);return n},encode:function(t){var e,i=this,n=i.utfBOM;for(e=0;e<t.length;e++)n+=i.encodeCharacter(t.charCodeAt(e));return n},encodeCharacter:function(t){var e,i,o=this.getBytesCount(t),r=o-1,s="";if(1==o)s=n(t,8);else{for(e=8-o,i=0;i<r;i++)s=n(t>>6*i&63|128,8)+s;s=(t>>6*r|255>>e<<e).toString(2)+s}return s},getBytesCount:function(t){var e,i=this.ranges;for(e=0;e<i.length;e++)if(t<i[e])return e+1},ranges:[128,2048,65536,2097152,67108864]},G=function(t){return t&&t.toLowerCase().indexOf("utf_8")>=0?new j:new U},W=function(t,e,i){var o,r,s,a=new G(i),l=a.getEncodingResult(t,e),c=l.version,h=lt[c-1][e],u=_(l.dataString,h.totalDataCodewords),d=b(u,h),f=E(c);return O(f),V(f,c),F(f),c>=7&&z(f,n(0,18)),I(f,n(0,15)),v(f,d),o=N(f),r=f[o],c>=7&&z([r],B(c)),s=ut[e]+n(o,3),I([r],P(s)),r},q={DEFAULT_SIZE:200,QUIET_ZONE_LENGTH:4,DEFAULT_ERROR_CORRECTION_LEVEL:"L",DEFAULT_BACKGROUND:"#fff",DEFAULT_DARK_MODULE_COLOR:"#000",MIN_BASE_UNIT_SIZE:1},$=Z.extend({init:function(e,i){var n=this;Z.fn.init.call(n,e,i),n.element=t(e),n.wrapper=n.element,n.element.addClass("k-qrcode"),n.surfaceWrap=t("<div />").css("position","relative").appendTo(this.element),n.surface=Q.Surface.create(n.surfaceWrap,{type:n.options.renderAs}),n.setOptions(i)},redraw:function(){var t=this._getSize();this.surfaceWrap.css({width:t,height:t}),this.surface.clear(),this.createVisual(),this.surface.draw(this.visual)},getSize:function(){return Y.dimensions(this.element)},_resize:function(){this.redraw()},createVisual:function(){this.visual=this._render()},exportVisual:function(){return this._render()},_render:function(){var t,e,i,n,o,r,s,a=this,l=a._value,c=a.options.border||{},h=a.options.padding||0,u=c.width||0;return c.width=u,s=new Q.Group,l&&(i=W(l,a.options.errorCorrection,a.options.encoding),n=a._getSize(),r=n-2*(u+h),t=a._calculateBaseUnit(r,i.length),o=i.length*t,e=u+h+(r-o)/2,s.append(a._renderBackground(n,c)),s.append(a._renderMatrix(i,t,e))),s},_getSize:function(){var t,e,i,n=this;return n.options.size?t=parseInt(n.options.size,10):(e=n.element,i=Math.min(e.width(),e.height()),t=i>0?i:q.DEFAULT_SIZE),t},_calculateBaseUnit:function(t,e){var i=Math.floor(t/e);if(i<q.MIN_BASE_UNIT_SIZE)throw Error("Insufficient size.");return i*e>=t&&i-1>=q.MIN_BASE_UNIT_SIZE&&i--,i},_renderMatrix:function(t,e,i){var n,o,r,s,a,l,c,h,u=new Q.MultiPath({fill:{color:this.options.color},stroke:null});for(n=0;n<t.length;n++)for(o=i+n*e,r=0;r<t.length;){for(;0===t[n][r]&&r<t.length;)r++;if(r<t.length){for(s=r;1==t[n][r];)r++;a=Mt(i+s*e),l=Mt(o),c=Mt(i+r*e),h=Mt(o+e),u.moveTo(a,l).lineTo(a,h).lineTo(c,h).lineTo(c,l).close()}}return u},_renderBackground:function(t,e){var i=J(0,0,t,t).unpad(e.width/2);return Q.Path.fromRect(i.toRect(),{fill:{color:this.options.background},stroke:{color:e.color,width:e.width}})},setOptions:function(t){var i=this;t=t||{},i.options=X(i.options,t),t.value!==e&&(i._value=i.options.value+""),i.redraw()},value:function(t){var i=this;return t===e?i._value:(i._value=t+"",i.redraw(),e)},options:{name:"QRCode",renderAs:"svg",encoding:"ISO_8859_1",value:"",errorCorrection:q.DEFAULT_ERROR_CORRECTION_LEVEL,background:q.DEFAULT_BACKGROUND,color:q.DEFAULT_DARK_MODULE_COLOR,size:"",padding:0,border:{color:"",width:0}}}),K.ExportMixin.extend($.fn),K.ui.plugin($),Y.deepExtend(K,{QRCode:$,QRCodeDefaults:q,QRCodeFunctions:{FreeCellVisitor:m,fillData:v,padDataString:_,generateErrorCodewords:x,xorPolynomials:y,getBlocks:b,multiplyPolynomials:w,chooseMode:k,getModes:C,getDataCodewordsCount:S,getVersion:T,getDataString:A,encodeFormatInformation:P,encodeBCH:D,dividePolynomials:M,initMatrices:E,addFormatInformation:I,encodeVersionInformation:B,addVersionInformation:z,addCentricPattern:L,addFinderSeparator:R,addFinderPatterns:O,addAlignmentPatterns:V,addTimingFunctions:F,scoreMaskMatrixes:N,encodeData:W,UTF8Encoder:j},QRCodeFields:{modes:p,powersOfTwo:ot,powersOfTwoResult:rt,generatorPolynomials:st}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.stock.min",["kendo.dataviz.chart.min"],t)}(function(){return function(t,e){function i(){}function n(t){return i.prototype=t,new i}var o,r=window.kendo,s=r.Class,a=r.Observable,l=r.deepExtend,c=Math,h=t.proxy,u=r.util,d=u.last,f=u.renderTemplate,p=r.dataviz,g=u.defined,m=p.filterSeriesByType,v=r.template,_=p.ui.Chart,y=p.Selection,w=p.addDuration,x=u.limitValue,b=p.lteDateIndex,k=p.toDate,C=p.toTime,S=28,T="change",A="k-",P="drag",D="dragEnd",M="_navigator",E=M,I=p.EQUALLY_SPACED_SERIES,B=3,z="zoom",L="zoomEnd",R=_.extend({init:function(e,i){t(e).addClass(A+"chart"),_.fn.init.call(this,e,i)},_applyDefaults:function(t,e){var i=this,n=i.element.width()||p.DEFAULT_WIDTH,o={seriesDefaults:{categoryField:t.dateField},axisDefaults:{categoryAxis:{name:"default",majorGridLines:{visible:!1},labels:{step:2},majorTicks:{visible:!1},maxDateGroups:c.floor(n/S)}}};e&&(e=l({},e,o)),O.setup(t,e),_.fn._applyDefaults.call(i,t,e)},setOptions:function(t){this._destroyNavigator(),_.fn.setOptions.call(this,t)},_initDataSource:function(t){var e,i,n=t||{},o=n.dataSource,r=o&&o.serverFiltering,s=[].concat(n.categoryAxis)[0],a=n.navigator||{},c=a.select,h=c&&c.from&&c.to;r&&h&&(e=[].concat(o.filter||[]),i=new p.DateCategoryAxis(l({baseUnit:"fit"},s,{categories:[c.from,c.to]})),o.filter=O.buildFilter(i.range().min,c.to).concat(e)),_.fn._initDataSource.call(this,t)},options:{name:"StockChart",dateField:"date",axisDefaults:{categoryAxis:{type:"date",baseUnit:"fit",justified:!0},valueAxis:{narrowRange:!0,labels:{format:"C"}}},navigator:{select:{},seriesDefaults:{markers:{visible:!1},tooltip:{visible:!0,template:"#= kendo.toString(category, 'd') #"},line:{width:2}},hint:{},visible:!0},tooltip:{visible:!0},legend:{visible:!1}},_resize:function(){var t=this.options.transitions;this.options.transitions=!1,this._fullRedraw(),this.options.transitions=t},_redraw:function(){var t=this,e=t._navigator;!this._dirty()&&e&&e.dataSource?e.redrawSlaves():t._fullRedraw()},_dirty:function(){var e=this.options,i=[].concat(e.series,e.navigator.series),n=t.grep(i,function(t){return t&&t.visible}).length,o=this._seriesCount!==n;return this._seriesCount=n,o},_fullRedraw:function(){var t=this,e=t._navigator;e||(e=t._navigator=t.navigator=new O(t)),e._setRange(),_.fn._redraw.call(t),e._initSelection()},_onDataChanged:function(){var t=this;_.fn._onDataChanged.call(t),t._dataBound=!0},_bindCategoryAxis:function(t,e,i){var n,o=this,r=o.options.categoryAxis,s=r.length;if(_.fn._bindCategoryAxis.apply(this,arguments),t.name===E)for(;i<s;)n=r[i++],n.pane==M&&(n.categories=t.categories)},_trackSharedTooltip:function(t){var e=this,i=e._plotArea,n=i.paneByPoint(t);n&&n.options.name===M?e._unsetActivePoint():_.fn._trackSharedTooltip.call(e,t)},_destroyNavigator:function(){this._navigator.destroy(),this._navigator=null},destroy:function(){this._destroyNavigator(),_.fn.destroy.call(this)}}),O=a.extend({init:function(t){var e=this;e.chart=t,e.options=l({},e.options,t.options.navigator),e._initDataSource(),g(e.options.hint.visible)||(e.options.hint.visible=e.options.visible),t.bind(P,h(e._drag,e)),t.bind(D,h(e._dragEnd,e)),t.bind(z,h(e._zoom,e)),t.bind(L,h(e._zoomEnd,e))},options:{},_initDataSource:function(){var t=this,e=t.options,i=e.autoBind,n=e.dataSource;g(i)||(i=t.chart.options.autoBind),t._dataChangedHandler=h(t._onDataChanged,t),n&&(t.dataSource=r.data.DataSource.create(n).bind(T,t._dataChangedHandler),i&&t.dataSource.fetch())},_onDataChanged:function(){var t,e,i,n,o,r=this,s=r.chart,a=s.options.series,l=a.length,c=s.options.categoryAxis,h=c.length,u=r.dataSource.view();for(t=0;t<l;t++)i=a[t],i.axis==E&&s._isBindable(i)&&(i.data=u);for(e=0;e<h;e++)n=c[e],n.pane==M&&(n.name==E?(s._bindCategoryAxis(n,u,e),o=n.categories):n.categories=o);s._model&&(r.redraw(),r._setRange(),(!s.options.dataSource||s.options.dataSource&&s._dataBound)&&r.redrawSlaves())},destroy:function(){var t=this,e=t.dataSource;e&&e.unbind(T,t._dataChangeHandler),t.selection&&t.selection.destroy()},redraw:function(){this._redrawSelf(),this._initSelection()},_initSelection:function(){var e=this,i=e.chart,r=e.options,s=e.mainAxis(),a=n(s),l=s.range(),c=l.min,h=l.max,d=s.options.categories,f=e.options.select,p=e.selection,g=k(f.from),m=k(f.to);0!==d.length&&(p&&(p.destroy(),p.wrapper.remove()),a.box=s.box,p=e.selection=new y(i,a,{min:c,max:h,from:g||c,to:m||h,selectStart:t.proxy(e._selectStart,e),select:t.proxy(e._select,e),selectEnd:t.proxy(e._selectEnd,e),mousewheel:u.valueOrDefault(f.mousewheel,{zoom:"left"}),visible:r.visible}),r.hint.visible&&(e.hint=new o(i.element,{min:c,max:h,template:r.hint.template,format:r.hint.format})))},_setRange:function(){var t,e=this.chart._createPlotArea(!0),i=e.namedCategoryAxes[E],n=i.range(),o=n.min,r=n.max,s=this.options.select||{},a=k(s.from)||o;a<o&&(a=o),t=k(s.to)||r,t>r&&(t=r),this.options.select=l({},s,{from:a,to:t}),this.filterAxes()},_redrawSelf:function(t){var e=this.chart._plotArea;e&&e.redraw(d(e.panes),t)},redrawSlaves:function(){var t=this,e=t.chart,i=e._plotArea,n=i.panes.slice(0,-1);i.srcSeries=e.options.series,i.redraw(n)},_drag:function(t){var e,i,n,o=this,r=o.chart,s=r._eventCoordinates(t.originalEvent),a=o.mainAxis(),l=a.datesRange(),c=a.pane.box.containsPoint(s),h=r._plotArea.categoryAxis,u=t.axisRanges[h.options.name],d=o.options.select,f=o.selection;u&&!c&&f&&(e=d.from&&d.to?C(d.to)-C(d.from):C(f.options.to)-C(f.options.from),i=k(x(C(u.min),l.min,C(l.max)-e)),n=k(x(C(i)+e,C(l.min)+e,l.max)),o.options.select={from:i,to:n},o._liveDrag()&&(o.filterAxes(),o.redrawSlaves()),f.set(i,n),o.showHint(i,n))},_dragEnd:function(){var t=this;t.filterAxes(),t.filterDataSource(),t.redrawSlaves(),t.hint&&t.hint.hide()},_liveDrag:function(){var t=r.support,e=t.touch,i=t.browser,n=i.mozilla,o=i.msie&&i.version<9;return!e&&!n&&!o},readSelection:function(){var t=this,e=t.selection,i=e.options,n=t.options.select;n.from=i.from,n.to=i.to},filterAxes:function(){var t,e,i=this,n=i.options.select||{},o=i.chart,r=o.options.categoryAxis,s=n.from,a=n.to;for(t=0;t<r.length;t++)e=r[t],e.pane!==M&&(e.min=k(s),e.max=k(a))},filterDataSource:function(){var t,e=this,i=e.options.select||{},n=e.chart,o=n.dataSource,r=o&&o.options.serverFiltering;e.dataSource&&r&&(t=new p.DateCategoryAxis(l({baseUnit:"fit"},n.options.categoryAxis[0],{categories:[i.from,i.to]})).options,o.filter(O.buildFilter(w(t.min,-t.baseUnitStep,t.baseUnit),w(t.max,t.baseUnitStep,t.baseUnit))))},_zoom:function(t){var e,i,n=this,o=n.chart,s=t.delta,a=o._plotArea.categoryAxis,l=n.options.select,h=n.selection,u=n.mainAxis().options.categories;h&&(e=b(h.options.from,u),i=b(h.options.to,u),t.originalEvent.preventDefault(),c.abs(s)>1&&(s*=B),i-e>1?(h.expand(s),n.readSelection()):(a.options.min=l.from,l.from=a.scaleRange(-t.delta).min),r.support.touch||(n.filterAxes(),n.redrawSlaves()),h.set(l.from,l.to),n.showHint(n.options.select.from,n.options.select.to))},_zoomEnd:function(t){this._dragEnd(t)},showHint:function(t,e){var i=this,n=i.chart,o=n._plotArea;i.hint&&i.hint.show(t,e,o.backgroundBox())},_selectStart:function(t){var e=this.chart;e._selectStart.call(e,t)},_select:function(t){var e=this,i=e.chart;e.showHint(t.from,t.to),i._select.call(i,t)},_selectEnd:function(t){var e=this,i=e.chart;e.hint&&e.hint.hide(),e.readSelection(),e.filterAxes(),e.filterDataSource(),e.redrawSlaves(),i._selectEnd.call(i,t)},mainAxis:function(){var t=this.chart._plotArea;if(t)return t.namedCategoryAxes[E]},select:function(t,e){var i=this.options.select;return t&&e&&(i.from=k(t),i.to=k(e),this.filterAxes(),this.filterDataSource(),this.redrawSlaves(),this.selection.set(t,e)),{from:i.from,to:i.to}}});O.setup=function(t,e){if(t=t||{},e=e||{},!t.__navi){t.__navi=!0;var i=l({},e.navigator,t.navigator),n=t.panes=[].concat(t.panes),o=l({},i.pane,{name:M});i.visible||(o.visible=!1,o.height=.1),n.push(o),O.attachAxes(t,i),O.attachSeries(t,i,e)}},O.attachAxes=function(t,e){var i=e.series||[],n=t.categoryAxis=[].concat(t.categoryAxis),o=t.valueAxis=[].concat(t.valueAxis),r=m(i,I),s=0===r.length,a=l({type:"date",pane:M,roundToBaseUnit:!s,justified:s,_collapse:!1,majorTicks:{visible:!0},tooltip:{visible:!1},labels:{step:1},autoBind:!e.dataSource,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]},_overlap:!0}),c=e.categoryAxis;n.push(l({},a,{maxDateGroups:200},c,{name:E,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),l({},a,c,{name:E+"_labels",maxDateGroups:20,baseUnitStep:"auto",plotBands:[],autoBaseUnitSteps:{minutes:[]}}),l({},a,c,{name:E+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0}})),o.push(l({name:E,pane:M,majorGridLines:{visible:!1},visible:!1},e.valueAxis))},O.attachSeries=function(t,e,i){var n,o=t.series=t.series||[],r=[].concat(e.series||[]),s=i.seriesColors,a=e.seriesDefaults;for(n=0;n<r.length;n++)o.push(l({color:s[n%s.length],categoryField:e.dateField,visibleInLegend:!1,tooltip:{visible:!1}},a,r[n],{axis:E,categoryAxis:E,autoBind:!e.dataSource}))},O.buildFilter=function(t,e){return[{field:"Date",operator:"gte",value:k(t)},{field:"Date",operator:"lt",value:k(e)}]},o=s.extend({init:function(e,i){var n=this;n.options=l({},n.options,i),n.container=e,n.chartPadding={top:parseInt(e.css("paddingTop"),10),left:parseInt(e.css("paddingLeft"),10)},n.template=n.template,n.template||(n.template=n.template=f("<div class='"+A+"navigator-hint' style='display: none; position: absolute; top: 1px; left: 1px;'><div class='"+A+"tooltip "+A+"chart-tooltip'>&nbsp;</div><div class='"+A+"scroll' /></div>")),n.element=t(n.template()).appendTo(e)},options:{format:"{0:d} - {1:d}",hideDelay:500},show:function(t,e,i){var n,o=this,s=k(C(t)+C(e-t)/2),a=o.options,l=r.format(o.options.format,t,e),c=o.element.find("."+A+"tooltip"),h=o.element.find("."+A+"scroll"),u=.4*i.width(),d=i.center().x-u,f=i.center().x,p=f-d,g=a.max-a.min,m=p/g,_=s-a.min;o._hideTimeout&&clearTimeout(o._hideTimeout),o._visible||(o.element.stop(!1,!0).css("visibility","hidden").show(),o._visible=!0),a.template&&(n=v(a.template),l=n({from:t,to:e})),c.html(l).css({left:i.center().x-r._outerWidth(c)/2,top:i.y1}),h.css({width:u,left:d+_*m,top:i.y1+parseInt(c.css("margin-top"),10)+parseInt(c.css("border-top-width"),10)+c.height()/2}),o.element.css("visibility","visible")},hide:function(){var t=this;t._hideTimeout&&clearTimeout(t._hideTimeout),t._hideTimeout=setTimeout(function(){t._visible=!1,t.element.fadeOut("slow")},t.options.hideDelay)}}),p.ui.plugin(R),l(p,{Navigator:O})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.sparkline.min",["kendo.dataviz.chart.min"],t)}(function(){return function(t,e){function i(t){return"number"==typeof t?[t]:t}var n=window.kendo,o=n.dataviz,r=o.ui.Chart,s=n.data.ObservableArray,a=o.SharedTooltip,l=n.deepExtend,c=t.isArray,h=t.proxy,u=o.inArray,d=Math,f="k-",p=150,g=150,m="bar",v="bullet",_="pie",y="leave",w=[m,v],x=r.extend({init:function(e,n){var o=this,a=o.stage=t("<span />"),h=n||{};e=t(e).addClass(f+"sparkline").empty().append(a),o._initialWidth=d.floor(e.width()),h=i(h),(c(h)||h instanceof s)&&(h={seriesDefaults:{data:h}}),h.series||(h.series=[{data:i(h.data)}]),l(h,{seriesDefaults:{type:h.type}}),(u(h.series[0].type,w)||u(h.seriesDefaults.type,w))&&(h=l({},{categoryAxis:{crosshair:{visible:!1}}},h)),r.fn.init.call(o,e,h)},options:{name:"Sparkline",chartArea:{margin:2},axisDefaults:{visible:!1,majorGridLines:{visible:!1},valueAxis:{narrowRange:!0}},seriesDefaults:{type:"line",area:{line:{width:.5}},bar:{stack:!0},padding:2,width:.5,overlay:{gradient:null},highlight:{visible:!1},border:{width:0},markers:{size:2,visible:!1}},tooltip:{visible:!0,shared:!0},categoryAxis:{crosshair:{visible:!0,tooltip:{visible:!1}}},legend:{visible:!1},transitions:!1,pointWidth:5,panes:[{clip:!1}]},_modelOptions:function(){var e,i,n=this,o=n.options,r=n._initialWidth,s=n.stage;return n.stage.children().hide(),i=t("<span>&nbsp;</span>"),n.stage.append(i),e=l({width:r?r:n._autoWidth(),height:s.height(),transitions:o.transitions},o.chartArea,{inline:!0,align:!1}),s.css({width:e.width,height:e.height}),i.remove(),n.stage.children().show(),n.surface.resize(),e},_createTooltip:function(){var t,e=this,i=e.options,n=e.element;return t=e._sharedTooltip()?new b(n,e._plotArea,i.tooltip):r.fn._createTooltip.call(e),t.bind(y,h(e._tooltipleave,e)),t},_surfaceWrap:function(){return this.stage},_autoWidth:function(){var t,e,i,n=this,r=n.options,s=o.getSpacing(r.chartArea.margin),a=r.series,l=n.dataSource.total(),c=0;for(e=0;e<a.length;e++){if(i=a[e],i.type===m)return p;if(i.type===v)return g;if(i.type===_)return n.stage.height();i.data&&(c=d.max(c,i.data.length))}return t=d.max(l,c)*r.pointWidth,t>0&&(t+=s.left+s.right),t}}),b=a.extend({options:{animation:{duration:0}},_anchor:function(t,e){var i=a.fn._anchor.call(this,t,e),n=this._measure();return i.y=-n.height-this.options.offset,i},_hideElement:function(){this.element&&this.element.hide().remove()}});o.ui.plugin(x),l(o,{SparklineSharedTooltip:b})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/location.min",["kendo.drawing.min"],t)}(function(){!function(t,e){var i,n=Math,o=n.abs,r=n.atan,s=n.atan2,a=n.cos,l=n.max,c=n.min,h=n.sin,u=n.tan,d=window.kendo,f=d.Class,p=d.dataviz,g=d.deepExtend,m=d.util,v=m.defined,_=m.deg,y=m.rad,w=m.round,x=m.sqr,b=m.valueOrDefault,k=f.extend({init:function(t,e){1===arguments.length?(this.lat=t[0],this.lng=t[1]):(this.lat=t,this.lng=e)},DISTANCE_ITERATIONS:100,DISTANCE_CONVERGENCE:1e-12,DISTANCE_PRECISION:2,FORMAT:"{0:N6},{1:N6}",toArray:function(){return[this.lat,this.lng]},equals:function(t){return t&&t.lat===this.lat&&t.lng===this.lng},clone:function(){return new k(this.lat,this.lng)},round:function(t){return this.lng=w(this.lng,t),this.lat=w(this.lat,t),this},wrap:function(){return this.lng=this.lng%180,this.lat=this.lat%90,this},distanceTo:function(t,e){return this.greatCircleTo(t,e).distance},destination:function(t,e,i){var o,r,l,c,u;return e=y(e),i=i||p.map.datums.WGS84,o=y(this.lat),r=y(this.lng),l=t/d.dataviz.map.datums.WGS84.a,c=n.asin(h(o)*a(l)+a(o)*h(l)*a(e)),u=r+s(h(e)*h(l)*a(o),a(l)-h(o)*h(c)),new k(_(c),_(u))},greatCircleTo:function(t,e){var i,l,c,d,f,g,m,v,b,C,S,T,A,P,D,M,E,I,B,z,L,R,O,V,F,N,H,U,j;if(t=k.create(t),e=e||p.map.datums.WGS84,!t||this.clone().round(8).equals(t.clone().round(8)))return{distance:0,azimuthFrom:0,azimuthTo:0};for(i=e.a,l=e.b,c=e.f,d=y(t.lng-this.lng),f=r((1-c)*u(y(this.lat))),g=h(f),m=a(f),v=r((1-c)*u(y(t.lat))),b=h(v),C=a(v),S=d,A=this.DISTANCE_ITERATIONS,P=!1;!P&&A-- >0;)D=h(S),M=a(S),E=n.sqrt(x(C*D)+x(m*b-g*C*M)),B=g*b+m*C*M,L=s(E,B),R=m*C*D/E,I=1-x(R),z=0,0!==I&&(z=B-2*g*b/I),T=S,O=c/16*I*(4+c*(4-3*I)),S=d+(1-O)*c*R*(L+O*E*(z+O*B*(-1+2*x(z)))),P=o(S-T)<=this.DISTANCE_CONVERGENCE;return V=I*(x(i)-x(l))/x(l),F=1+V/16384*(4096+V*(-768+V*(320-175*V))),N=V/1024*(256+V*(-128+V*(74-47*V))),H=N*E*(z+N/4*(B*(-1+2*x(z))-N/6*z*(-3+4*x(E))*(-3+4*x(z)))),U=s(C*D,m*b-g*C*M),j=s(m*D,-g*C+m*b*M),{distance:w(l*F*(L-H),this.DISTANCE_PRECISION),azimuthFrom:_(U),azimuthTo:_(j)}}});k.fn.toString=function(){return d.format(this.FORMAT,this.lat,this.lng)},k.fromLngLat=function(t){return new k(t[1],t[0])},k.fromLatLng=function(t){return new k(t[0],t[1])},k.create=function(t,e){if(v(t))return t instanceof k?t.clone():1===arguments.length&&2===t.length?k.fromLatLng(t):new k(t,e)},i=f.extend({init:function(t,e){t=k.create(t),e=k.create(e),t.lng+180>e.lng+180&&t.lat+90<e.lat+90?(this.se=t,this.nw=e):(this.se=e,this.nw=t)},contains:function(t){var e=this.nw,i=this.se,n=b(t.lng,t[1]),o=b(t.lat,t[0]);return t&&n+180>=e.lng+180&&n+180<=i.lng+180&&o+90>=i.lat+90&&o+90<=e.lat+90},center:function(){var t=this.nw,e=this.se,i=t.lng+(e.lng-t.lng)/2,n=t.lat+(e.lat-t.lat)/2;return new k(n,i)},containsAny:function(t){var e,i=!1;for(e=0;e<t.length;e++)i=i||this.contains(t[e]);return i},include:function(t){var e=this.nw,i=this.se,n=b(t.lng,t[1]),o=b(t.lat,t[0]);e.lng=c(e.lng,n),e.lat=l(e.lat,o),i.lng=l(i.lng,n),i.lat=c(i.lat,o)},includeAll:function(t){for(var e=0;e<t.length;e++)this.include(t[e])},edges:function(){var t=this.nw,e=this.se;return{nw:this.nw,ne:new k(t.lat,e.lng),se:this.se,sw:new k(e.lat,t.lng)}},toArray:function(){var t=this.nw,e=this.se;return[t,new k(t.lat,e.lng),e,new k(e.lat,t.lng)]},overlaps:function(t){return this.containsAny(t.toArray())||t.containsAny(this.toArray())}}),i.World=new i([90,-180],[-90,180]),i.create=function(t,n){return t instanceof i?t:t&&n?new i(t,n):t&&4===t.length&&!n?new i([t[0],t[1]],[t[2],t[3]]):e;
},g(p,{map:{Extent:i,Location:k}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/attribution.min",["kendo.drawing.min"],t)}(function(){!function(){var t=window.kendo,e=t.ui.Widget,i=t.template,n=t.util.valueOrDefault,o=t.util.defined,r=e.extend({init:function(t,i){e.fn.init.call(this,t,i),this._initOptions(i),this.items=[],this.element.addClass("k-widget k-attribution")},options:{name:"Attribution",separator:"&nbsp;|&nbsp;",itemTemplate:"#= text #"},filter:function(t,e){this._extent=t,this._zoom=e,this._render()},add:function(t){o(t)&&("string"==typeof t&&(t={text:t}),this.items.push(t),this._render())},remove:function(t){var e,i,n=[];for(e=0;e<this.items.length;e++)i=this.items[e],i.text!==t&&n.push(i);this.items=n,this._render()},clear:function(){this.items=[],this.element.empty()},_render:function(){var t,e,n,o=[],r=i(this.options.itemTemplate);for(t=0;t<this.items.length;t++)e=this.items[t],n=this._itemText(e),""!==n&&o.push(r({text:n}));o.length>0?this.element.empty().append(o.join(this.options.separator)).show():this.element.hide()},_itemText:function(t){var e="",i=this._inZoomLevel(t.minZoom,t.maxZoom),n=this._inArea(t.extent);return i&&n&&(e+=t.text),e},_inZoomLevel:function(t,e){var i=!0;return t=n(t,-Number.MAX_VALUE),e=n(e,Number.MAX_VALUE),i=this._zoom>t&&this._zoom<e},_inArea:function(t){var e=!0;return t&&(e=t.contains(this._extent)),e}});t.dataviz.ui.plugin(r)}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/navigator.min",["kendo.core.min"],t)}(function(){!function(t){function e(t){return i.format('<button class="k-button k-navigator-{0}"><span class="k-icon k-i-arrow-{0}"/></button>',t)}var i=window.kendo,n=i.ui.Widget,o=i.keys,r=t.proxy,s=".kendoNavigator",a=e("n")+e("e")+e("s")+e("w"),l=n.extend({init:function(t,e){n.fn.init.call(this,t,e),this._initOptions(e),this.element.addClass("k-widget k-header k-shadow k-navigator").append(a).on("click"+s,".k-button",r(this,"_click"));var o=this.element.parent().closest("["+i.attr("role")+"]");this._keyroot=o.length>0?o:this.element,this._tabindex(this._keyroot),this._keydown=r(this._keydown,this),this._keyroot.on("keydown",this._keydown)},options:{name:"Navigator",panStep:1},events:["pan"],dispose:function(){this._keyroot.off("keydown",this._keydown)},_pan:function(t,e){var i=this.options.panStep;this.trigger("pan",{x:t*i,y:e*i})},_click:function(e){var i=0,n=0,o=t(e.currentTarget);o.is(".k-navigator-n")?n=1:o.is(".k-navigator-s")?n=-1:o.is(".k-navigator-e")?i=1:o.is(".k-navigator-w")&&(i=-1),this._pan(i,n),e.preventDefault()},_keydown:function(t){switch(t.which){case o.UP:this._pan(0,1),t.preventDefault();break;case o.DOWN:this._pan(0,-1),t.preventDefault();break;case o.RIGHT:this._pan(1,0),t.preventDefault();break;case o.LEFT:this._pan(-1,0),t.preventDefault()}}});i.dataviz.ui.plugin(l)}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/zoom.min",["kendo.core.min"],t)}(function(){!function(t){function e(t,e){return i.format('<button class="k-button k-zoom-{0}" title="zoom-{0}">{1}</button>',t,e)}var i=window.kendo,n=i.ui.Widget,o=i.keys,r=t.proxy,s=".kendoZoomControl",a=e("in","+")+e("out","-"),l=187,c=189,h=61,u=173,d=n.extend({init:function(t,e){n.fn.init.call(this,t,e),this._initOptions(e),this.element.addClass("k-widget k-zoom-control k-button-wrap k-buttons-horizontal").append(a).on("click"+s,".k-button",r(this,"_click"));var o=this.element.parent().closest("["+i.attr("role")+"]");this._keyroot=o.length>0?o:this.element,this._tabindex(this._keyroot),this._keydown=r(this._keydown,this),this._keyroot.on("keydown",this._keydown)},options:{name:"ZoomControl",zoomStep:1},events:["change"],_change:function(t){var e=this.options.zoomStep;this.trigger("change",{delta:t*e})},_click:function(e){var i=t(e.currentTarget),n=1;i.is(".k-zoom-out")&&(n=-1),this._change(n),e.preventDefault()},_keydown:function(t){switch(t.which){case o.NUMPAD_PLUS:case l:case h:this._change(1);break;case o.NUMPAD_MINUS:case c:case u:this._change(-1)}}});i.dataviz.ui.plugin(d)}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/crs.min",["dataviz/map/location.min","kendo.drawing.min"],t)}(function(){!function(t,e){var i=Math,n=i.atan,o=i.exp,r=i.pow,s=i.sin,a=i.log,l=i.tan,c=window.kendo,h=c.Class,u=c.dataviz,d=c.deepExtend,f=c.geometry,p=f.Point,g=u.map,m=g.Location,v=c.util,_=v.rad,y=v.deg,w=v.limitValue,x=i.PI,b=x/2,k=x/4,C=x/180,S={a:6378137,b:6356752.314245179,f:.0033528106647474805,e:.08181919084262149},T=h.extend({init:function(t){this._initOptions(t)},MAX_LNG:180,MAX_LAT:85.0840590501,INVERSE_ITERATIONS:15,INVERSE_CONVERGENCE:1e-12,options:{centralMeridian:0,datum:S},forward:function(t,e){var i=this,n=i.options,o=n.datum,r=o.a,s=n.centralMeridian,a=w(t.lat,-i.MAX_LAT,i.MAX_LAT),l=e?w(t.lng,-i.MAX_LNG,i.MAX_LNG):t.lng,c=_(l-s)*r,h=i._projectLat(a);return new p(c,h)},_projectLat:function(t){var e=this.options.datum,i=e.e,n=e.a,o=_(t),c=l(k+o/2),h=i*s(o),u=r((1-h)/(1+h),i/2);return n*a(c*u)},inverse:function(t,e){var i=this,n=i.options,o=n.datum,r=o.a,s=n.centralMeridian,a=t.x/(C*r)+s,l=w(i._inverseY(t.y),-i.MAX_LAT,i.MAX_LAT);return e&&(a=w(a,-i.MAX_LNG,i.MAX_LNG)),new m(l,a)},_inverseY:function(t){var e,a,l,c,h=this,u=h.options.datum,d=u.a,f=u.e,p=f/2,g=o(-t/d),m=b-2*n(g);for(e=0;e<=h.INVERSE_ITERATIONS&&(a=f*s(m),l=r((1-a)/(1+a),p),c=b-2*n(g*l)-m,m+=c,!(i.abs(c)<=h.INVERSE_CONVERGENCE));e++);return y(m)}}),A=T.extend({MAX_LAT:85.0511287798,_projectLat:function(t){var e=this.options.datum.a,i=_(t),n=l(k+i/2);return e*a(n)},_inverseY:function(t){var e=this.options.datum.a,i=o(-t/e);return y(b-2*n(i))}}),P=h.extend({forward:function(t){return new p(t.lng,t.lat)},inverse:function(t){return new m(t.y,t.x)}}),D=h.extend({init:function(){var t=this,e=t._proj=new A,i=this.c=2*x*e.options.datum.a;this._tm=f.transform().translate(.5,.5).scale(1/i,-1/i),this._itm=f.transform().scale(i,-i).translate(-.5,-.5)},toPoint:function(t,e,i){var n=this._proj.forward(t,i);return n.transform(this._tm).scale(e||1)},toLocation:function(t,e,i){return t=t.clone().scale(1/(e||1)).transform(this._itm),this._proj.inverse(t,i)}}),M=h.extend({init:function(){this._proj=new T},toPoint:function(t){return this._proj.forward(t)},toLocation:function(t){return this._proj.inverse(t)}}),E=h.extend({init:function(){this._proj=new P},toPoint:function(t){return this._proj.forward(t)},toLocation:function(t){return this._proj.inverse(t)}});d(u,{map:{crs:{EPSG3395:M,EPSG3857:D,EPSG4326:E},datums:{WGS84:S},projections:{Equirectangular:P,Mercator:T,SphericalMercator:A}}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/base.min",["kendo.core.min","dataviz/map/location.min"],t)}(function(){!function(t,e){var i=t.proxy,n=window.kendo,o=n.Class,r=n.dataviz,s=n.deepExtend,a=r.map.Extent,l=n.util,c=l.defined,h=o.extend({init:function(e,n){this._initOptions(n),this.map=e,this.element=t("<div class='k-layer'></div>").css({zIndex:this.options.zIndex,opacity:this.options.opacity}).appendTo(e.scrollElement),this._beforeReset=i(this._beforeReset,this),this._reset=i(this._reset,this),this._resize=i(this._resize,this),this._panEnd=i(this._panEnd,this),this._activate(),this._updateAttribution()},destroy:function(){this._deactivate()},show:function(){this.reset(),this._activate(),this._applyExtent(!0)},hide:function(){this._deactivate(),this._setVisibility(!1)},reset:function(){this._beforeReset(),this._reset()},_reset:function(){this._applyExtent()},_beforeReset:t.noop,_resize:t.noop,_panEnd:function(){this._applyExtent()},_applyExtent:function(){var t=this.options,e=this.map.zoom(),i=!c(t.minZoom)||e>=t.minZoom,n=!c(t.maxZoom)||e<=t.maxZoom,o=a.create(t.extent),r=!o||o.overlaps(this.map.extent());this._setVisibility(i&&n&&r)},_setVisibility:function(t){this.element.css("display",t?"":"none")},_activate:function(){var t=this.map;t.bind("beforeReset",this._beforeReset),t.bind("reset",this._reset),t.bind("resize",this._resize),t.bind("panEnd",this._panEnd)},_deactivate:function(){var t=this.map;t.unbind("beforeReset",this._beforeReset),t.unbind("reset",this._reset),t.unbind("resize",this._resize),t.unbind("panEnd",this._panEnd)},_updateAttribution:function(){var t=this.map.attribution;t&&t.add(this.options.attribution)}});s(r,{map:{layers:{Layer:h}}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/shape.min",["dataviz/map/layers/base.min","dataviz/map/location.min"],t)}(function(){!function(t,e){var i=t.proxy,n=window.kendo,o=n.Class,r=n.data.DataSource,s=n.dataviz,a=n.deepExtend,l=n.util.last,c=n.util.defined,h=n.geometry,u=n.drawing,d=u.Group,f=s.map,p=f.Location,g=f.layers.Layer,m=g.extend({init:function(t,e){this._pan=i(this._pan,this),g.fn.init.call(this,t,e),this.surface=u.Surface.create(this.element,{width:t.scrollElement.width(),height:t.scrollElement.height()}),this._initRoot(),this.movable=new n.ui.Movable(this.surface.element),this._markers=[],this._click=this._handler("shapeClick"),this.surface.bind("click",this._click),this._mouseenter=this._handler("shapeMouseEnter"),this.surface.bind("mouseenter",this._mouseenter),this._mouseleave=this._handler("shapeMouseLeave"),this.surface.bind("mouseleave",this._mouseleave),this._initDataSource()},options:{autoBind:!0},destroy:function(){g.fn.destroy.call(this),this.surface.destroy(),this.dataSource.unbind("change",this._dataChange)},setDataSource:function(t){this.dataSource&&this.dataSource.unbind("change",this._dataChange),this.dataSource=n.data.DataSource.create(t),this.dataSource.bind("change",this._dataChange),this.options.autoBind&&this.dataSource.fetch()},_reset:function(){g.fn._reset.call(this),this._translateSurface(),this._data&&this._load(this._data)},_initRoot:function(){this._root=new d,this.surface.draw(this._root)},_beforeReset:function(){this.surface.clear(),this._initRoot()},_resize:function(){this.surface.size(this.map.size())},_initDataSource:function(){var t=this.options.dataSource;this._dataChange=i(this._dataChange,this),this.dataSource=r.create(t).bind("change",this._dataChange),t&&this.options.autoBind&&this.dataSource.fetch()},_dataChange:function(t){this._data=t.sender.view(),this._load(this._data)},_load:function(t){var e,i,n;for(this._clearMarkers(),this._loader||(this._loader=new v(this.map,this.options.style,this)),e=new d,i=0;i<t.length;i++)n=this._loader.parse(t[i]),n&&e.append(n);this._root.clear(),this._root.append(e)},shapeCreated:function(t){var e,i=!1;return t instanceof u.Circle&&(i=c(this._createMarker(t))),i||(e={layer:this,shape:t},i=this.map.trigger("shapeCreated",e)),i},featureCreated:function(t){t.layer=this,this.map.trigger("shapeFeatureCreated",t)},_createMarker:function(t){var e=this.map.markers.bind({location:t.location},t.dataItem);return e&&this._markers.push(e),e},_clearMarkers:function(){for(var t=0;t<this._markers.length;t++)this.map.markers.remove(this._markers[t]);this._markers=[]},_pan:function(){this._panning||(this._panning=!0,this.surface.suspendTracking())},_panEnd:function(t){g.fn._panEnd.call(this,t),this._translateSurface(),this.surface.resumeTracking(),this._panning=!1},_translateSurface:function(){var t=this.map,e=t.locationToView(t.extent().nw);this.surface.translate&&(this.surface.translate(e),this.movable.moveTo({x:e.x,y:e.y}))},_handler:function(t){var e=this;return function(i){if(i.element){var n={layer:e,shape:i.element,originalEvent:i.originalEvent};e.map.trigger(t,n)}}},_activate:function(){g.fn._activate.call(this),this.map.bind("pan",this._pan)},_deactivate:function(){g.fn._deactivate.call(this),this.map.unbind("pan",this._pan)}}),v=o.extend({init:function(t,e,i){this.observer=i,this.locator=t,this.style=e},parse:function(t){var e=new d,i=!0;return"Feature"===t.type?(i=!1,this._loadGeometryTo(e,t.geometry,t),this._featureCreated(e,t)):this._loadGeometryTo(e,t,t),i&&e.children.length<2&&(e=e.children[0]),e},_shapeCreated:function(t){var e=!1;return this.observer&&this.observer.shapeCreated&&(e=this.observer.shapeCreated(t)),e},_featureCreated:function(t,e){this.observer&&this.observer.featureCreated&&this.observer.featureCreated({group:t,dataItem:e,properties:e.properties})},_loadGeometryTo:function(t,e,i){var n,o,r=e.coordinates;switch(e.type){case"LineString":o=this._loadPolygon(t,[r],i),this._setLineFill(o);break;case"MultiLineString":for(n=0;n<r.length;n++)o=this._loadPolygon(t,[r[n]],i),this._setLineFill(o);break;case"Polygon":this._loadPolygon(t,r,i);break;case"MultiPolygon":for(n=0;n<r.length;n++)this._loadPolygon(t,r[n],i);break;case"Point":this._loadPoint(t,r,i);break;case"MultiPoint":for(n=0;n<r.length;n++)this._loadPoint(t,r[n],i)}},_setLineFill:function(t){var e=t.segments;(e.length<4||!e[0].anchor().equals(l(e).anchor()))&&(t.options.fill=null)},_loadShape:function(t,e){return this._shapeCreated(e)||t.append(e),e},_loadPolygon:function(t,e,i){var n=this._buildPolygon(e);return n.dataItem=i,this._loadShape(t,n)},_buildPolygon:function(t){var e,i,n,o=t.length>1?u.MultiPath:u.Path,r=new o(this.style);for(e=0;e<t.length;e++)for(i=0;i<t[e].length;i++)n=this.locator.locationToView(p.fromLngLat(t[e][i])),0===i?r.moveTo(n.x,n.y):r.lineTo(n.x,n.y);return r},_loadPoint:function(t,e,i){var n=p.fromLngLat(e),o=this.locator.locationToView(n),r=new h.Circle(o,10),s=new u.Circle(r,this.style);return s.dataItem=i,s.location=n,this._loadShape(t,s)}});a(n.data,{schemas:{geojson:{type:"json",data:function(t){return"FeatureCollection"===t.type?t.features:"GeometryCollection"===t.type?t.geometries:t}}},transports:{geojson:{read:{dataType:"json"}}}}),a(s,{map:{layers:{shape:m,ShapeLayer:m},GeoJSONLoader:v}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/bubble.min",["dataviz/map/layers/shape.min"],t)}(function(){!function(t,e){var i=window.kendo,n=i.getter,o=i.dataviz,r=i.deepExtend,s=i.util,a=s.defined,l=i.geometry,c=i.drawing,h=o.map,u=h.Location,d=h.layers.ShapeLayer,f=d.extend({options:{autoBind:!0,locationField:"location",valueField:"value",minSize:0,maxSize:100,scale:"sqrt",symbol:"circle"},_load:function(t){var e,i,o,r,s,l,c,h,d,f,p;if(this.surface.clear(),0!==t.length)for(e=this.options,i=n(e.valueField),t=t.slice(0),t.sort(function(t,e){return i(e)-i(t)}),o=this._scaleType(),s=0;s<t.length;s++)l=t[s],c=n(e.locationField)(l),h=n(e.valueField)(l),a(c)&&a(h)&&(r||(r=new o([0,h],[e.minSize,e.maxSize])),c=u.create(c),d=this.map.locationToView(c),f=r.map(h),p=this._createSymbol({center:d,size:f,style:e.style,dataItem:l,location:c}),p.dataItem=l,p.location=c,p.value=h,this._drawSymbol(p))},_scaleType:function(){var t=this.options.scale;return i.isFunction(t)?t:o.map.scales[t]},_createSymbol:function(t){var e=this.options.symbol;return i.isFunction(e)||(e=o.map.symbols[e]),e(t)},_drawSymbol:function(t){var e={layer:this,shape:t},i=this.map.trigger("shapeCreated",e);i||this.surface.draw(t)}}),p=i.Class.extend({init:function(t,e){var i,n;this._domain=t,this._range=e,i=Math.sqrt(t[1])-Math.sqrt(t[0]),n=e[1]-e[0],this._ratio=n/i},map:function(t){var e=(Math.sqrt(t)-Math.sqrt(this._domain[0]))*this._ratio;return this._range[0]+e}}),g={circle:function(t){var e=new l.Circle(t.center,t.size/2);return new c.Circle(e,t.style)},square:function(t){var e=new c.Path(t.style),i=t.size/2,n=t.center;return e.moveTo(n.x-i,n.y-i).lineTo(n.x+i,n.y-i).lineTo(n.x+i,n.y+i).lineTo(n.x-i,n.y+i).close(),e}};r(o,{map:{layers:{bubble:f,BubbleLayer:f},scales:{sqrt:p},symbols:g}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/tile.min",["dataviz/map/layers/base.min","dataviz/map/location.min"],t)}(function(){!function(t,e){function i(t){return new u(p(t.x),p(t.y))}var n=Math,o=t.proxy,r=window.kendo,s=r.Class,a=r.template,l=r.dataviz,c=r.deepExtend,h=r.geometry,u=h.Point,d=l.map.layers.Layer,f=r.util,p=f.round,g=f.renderSize,m=f.limitValue,v=d.extend({init:function(t,e){d.fn.init.call(this,t,e),"string"==typeof this.options.subdomains&&(this.options.subdomains=this.options.subdomains.split(""));var i=this._viewType();this._view=new i(this.element,this.options)},destroy:function(){d.fn.destroy.call(this),this._view.destroy(),this._view=null},_beforeReset:function(){var t=this.map,e=t.locationToLayer(t.extent().nw).round();this._view.viewOrigin(e)},_reset:function(){d.fn._reset.call(this),this._updateView(),this._view.reset()},_viewType:function(){return _},_activate:function(){d.fn._activate.call(this),r.support.mobileOS||(this._pan||(this._pan=r.throttle(o(this._render,this),100)),this.map.bind("pan",this._pan))},_deactivate:function(){d.fn._deactivate.call(this),this._pan&&this.map.unbind("pan",this._pan)},_updateView:function(){var t=this._view,e=this.map,i=e.extent(),n={nw:e.locationToLayer(i.nw).round(),se:e.locationToLayer(i.se).round()};t.center(e.locationToLayer(e.center())),t.extent(n),t.zoom(e.zoom())},_resize:function(){this._render()},_panEnd:function(t){d.fn._panEnd.call(this,t),this._render()},_render:function(){this._updateView(),this._view.render()}}),_=s.extend({init:function(t,e){this.element=t,this._initOptions(e),this.pool=new w},options:{tileSize:256,subdomains:["a","b","c"],urlTemplate:""},center:function(t){this._center=t},extent:function(t){this._extent=t},viewOrigin:function(t){this._viewOrigin=t},zoom:function(t){this._zoom=t},pointToTileIndex:function(t){return new u(n.floor(t.x/this.options.tileSize),n.floor(t.y/this.options.tileSize))},tileCount:function(){var t=this.size(),e=this.pointToTileIndex(this._extent.nw),i=this._extent.nw,o=this.indexToPoint(e).translate(-i.x,-i.y);return{x:n.ceil((n.abs(o.x)+t.width)/this.options.tileSize),y:n.ceil((n.abs(o.y)+t.height)/this.options.tileSize)}},size:function(){var t=this._extent.nw,e=this._extent.se,i=e.clone().translate(-t.x,-t.y);return{width:i.x,height:i.y}},indexToPoint:function(t){var e=t.x,i=t.y;return new u(e*this.options.tileSize,i*this.options.tileSize)},subdomainText:function(){var t=this.options.subdomains;return t[this.subdomainIndex++%t.length]},destroy:function(){this.element.empty(),this.pool.empty()},reset:function(){this.pool.reset(),this.subdomainIndex=0,this.render()},render:function(){var t,e,i,n=this.tileCount(),o=this.pointToTileIndex(this._extent.nw);for(e=0;e<n.x;e++)for(i=0;i<n.y;i++)t=this.createTile({x:o.x+e,y:o.y+i}),t.visible||t.show()},createTile:function(t){var e=this.tileOptions(t),i=this.pool.get(this._center,e);return 0===i.element.parent().length&&this.element.append(i.element),i},tileOptions:function(t){var e=this.wrapIndex(t),n=this.indexToPoint(t),o=this._viewOrigin,r=n.clone().translate(-o.x,-o.y);return{index:e,currentIndex:t,point:n,offset:i(r),zoom:this._zoom,size:this.options.tileSize,subdomain:this.subdomainText(),urlTemplate:this.options.urlTemplate,errorUrlTemplate:this.options.errorUrlTemplate}},wrapIndex:function(t){var e=n.pow(2,this._zoom);return{x:this.wrapValue(t.x,e),y:m(t.y,0,e-1)}},wrapValue:function(t,e){var i=n.abs(t)%e;return t=t>=0?i:e-(0===i?e:i)}}),y=s.extend({init:function(t,e){this.id=t,this.visible=!0,this._initOptions(e),this.createElement(),this.show()},options:{urlTemplate:"",errorUrlTemplate:""},createElement:function(){this.element=t("<img style='position: absolute; display: block;' />").css({width:this.options.size,height:this.options.size}).on("error",o(function(t){this.errorUrl()?t.target.setAttribute("src",this.errorUrl()):t.target.removeAttribute("src")},this))},show:function(){var t,e=this.element[0];e.style.top=g(this.options.offset.y),e.style.left=g(this.options.offset.x),t=this.url(),t&&e.setAttribute("src",t),e.style.visibility="visible",this.visible=!0},hide:function(){this.element[0].style.visibility="hidden",this.visible=!1},url:function(){var t=a(this.options.urlTemplate);return t(this.urlOptions())},errorUrl:function(){var t=a(this.options.errorUrlTemplate);return t(this.urlOptions())},urlOptions:function(){var t=this.options;return{zoom:t.zoom,subdomain:t.subdomain,z:t.zoom,x:t.index.x,y:t.index.y,s:t.subdomain,quadkey:t.quadkey,q:t.quadkey,culture:t.culture,c:t.culture}},destroy:function(){this.element&&(this.element.remove(),this.element=null)}}),w=s.extend({init:function(){this._items=[]},options:{maxSize:100},get:function(t,e){return this._items.length>=this.options.maxSize&&this._remove(t),this._create(e)},empty:function(){var t,e=this._items;for(t=0;t<e.length;t++)e[t].destroy();this._items=[]},reset:function(){var t,e=this._items;for(t=0;t<e.length;t++)e[t].hide()},_create:function(t){var e,i,n=this._items,o=f.hashKey(""+t.point+(""+t.offset)+t.zoom+t.urlTemplate);for(i=0;i<n.length;i++)if(n[i].id===o){e=n[i];break}return e?e.show():(e=new y(o,t),this._items.push(e)),e},_remove:function(t){var e,i,n=this._items,o=-1,r=-1;for(e=0;e<n.length;e++)i=n[e].options.point.distanceTo(t),i>o&&!n[e].visible&&(r=e,o=i);r!==-1&&(n[r].destroy(),n.splice(r,1))}});c(l,{map:{layers:{tile:v,TileLayer:v,ImageTile:y,TilePool:w,TileView:_}}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/bing.min",["dataviz/map/layers/tile.min"],t)}(function(){!function(t,e){var i=window.kendo,n=i.dataviz,o=i.deepExtend,r=i.util.defined,s=n.map.Extent,a=n.map.Location,l=n.map.layers.TileLayer,c=n.map.layers.TileView,h=l.extend({init:function(e,i){this.options.baseUrl=this._scheme()+"://dev.virtualearth.net/REST/v1/Imagery/Metadata/",l.fn.init.call(this,e,i),this._onMetadata=t.proxy(this._onMetadata,this),this._fetchMetadata()},options:{imagerySet:"road"},_fetchMetadata:function(){var e=this.options;if(!e.key)throw Error("Bing tile layer: API key is required");t.ajax({url:e.baseUrl+e.imagerySet,data:{output:"json",include:"ImageryProviders",key:e.key,uriScheme:this._scheme()},type:"get",dataType:"jsonp",jsonp:"jsonp",success:this._onMetadata})},_scheme:function(t){return t=t||window.location.protocol,"https"===t.replace(":","")?"https":"http"},_onMetadata:function(t){var e,i;t&&t.resourceSets.length&&(e=this.resource=t.resourceSets[0].resources[0],o(this._view.options,{urlTemplate:e.imageUrl.replace("{subdomain}","#= subdomain #").replace("{quadkey}","#= quadkey #").replace("{culture}","#= culture #"),subdomains:e.imageUrlSubdomains}),i=this.options,r(i.minZoom)||(i.minZoom=e.zoomMin),r(i.maxZoom)||(i.maxZoom=e.zoomMax),this._addAttribution(),"none"!==this.element.css("display")&&this._reset())},_viewType:function(){return u},_addAttribution:function(){var t,e,i,n,o,r=this.map.attribution;if(r&&(t=this.resource.imageryProviders))for(e=0;e<t.length;e++)for(i=t[e],n=0;n<i.coverageAreas.length;n++)o=i.coverageAreas[n],r.add({text:i.attribution,minZoom:o.zoomMin,maxZoom:o.zoomMax,extent:new s(new a(o.bbox[2],o.bbox[1]),new a(o.bbox[0],o.bbox[3]))})},imagerySet:function(t){return t?(this.options.imagerySet=t,this.map.attribution.clear(),this._fetchMetadata(),e):this.options.imagerySet}}),u=c.extend({options:{culture:"en-US"},tileOptions:function(t){var e=c.fn.tileOptions.call(this,t);return e.culture=this.options.culture,e.quadkey=this.tileQuadKey(this.wrapIndex(t)),e},tileQuadKey:function(t){var e,i,n,o="";for(n=this._zoom;n>0;n--)e=0,i=1<<n-1,0!==(t.x&i)&&e++,0!==(t.y&i)&&(e+=2),o+=e;return o}});o(n,{map:{layers:{bing:h,BingLayer:h,BingView:u}}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/layers/marker.min",["dataviz/map/layers/base.min","dataviz/map/location.min","kendo.data.min","kendo.tooltip.min"],t)}(function(){!function(t,e){var i=document,n=Math,o=t.inArray,r=t.proxy,s=window.kendo,a=s.Class,l=s.data.DataSource,c=s.ui.Tooltip,h=s.dataviz,u=s.deepExtend,d=h.map,f=d.Location,p=d.layers.Layer,g=p.extend({init:function(t,e){p.fn.init.call(this,t,e),this._markerClick=r(this._markerClick,this),this.element.on("click",".k-marker",this._markerClick),this.items=[],this._initDataSource()},destroy:function(){p.fn.destroy.call(this),this.element.off("click",".k-marker",this._markerClick),this.dataSource.unbind("change",this._dataChange),this.clear()},options:{zIndex:1e3,autoBind:!0,dataSource:{},locationField:"location",titleField:"title"},add:function(e){if(!t.isArray(e))return this._addOne(e);for(var i=0;i<e.length;i++)this._addOne(e[i])},remove:function(t){t.destroy();var e=o(t,this.items);e>-1&&this.items.splice(e,1)},clear:function(){for(var t=0;t<this.items.length;t++)this.items[t].destroy();this.items=[]},update:function(t){var e,i=t.location();i&&(t.showAt(this.map.locationToView(i)),e={marker:t,layer:this},this.map.trigger("markerActivate",e))},_reset:function(){var t,e;for(p.fn._reset.call(this),t=this.items,e=0;e<t.length;e++)this.update(t[e])},bind:function(t,e){var i,n,o=d.Marker.create(t,this.options);if(o.dataItem=e,i={marker:o,layer:this},n=this.map.trigger("markerCreated",i),!n)return this.add(o),o},setDataSource:function(t){this.dataSource&&this.dataSource.unbind("change",this._dataChange),this.dataSource=s.data.DataSource.create(t),this.dataSource.bind("change",this._dataChange),this.options.autoBind&&this.dataSource.fetch()},_addOne:function(t){var e=m.create(t,this.options);return e.addTo(this),e},_initDataSource:function(){var t=this.options.dataSource;this._dataChange=r(this._dataChange,this),this.dataSource=l.create(t).bind("change",this._dataChange),t&&this.options.autoBind&&this.dataSource.fetch()},_dataChange:function(t){this._load(t.sender.view())},_load:function(t){var e,i,n,o;for(this._data=t,this.clear(),e=s.getter(this.options.locationField),i=s.getter(this.options.titleField),n=0;n<t.length;n++)o=t[n],this.bind({location:e(o),title:i(o)},o)},_markerClick:function(e){var i={marker:t(e.target).data("kendoMarker"),layer:this};this.map.trigger("markerClick",i)}}),m=a.extend({init:function(t){this.options=t||{}},addTo:function(t){this.layer=t.markers||t,this.layer.items.push(this),this.layer.update(this)},location:function(t){return t?(this.options.location=f.create(t).toArray(),this.layer&&this.layer.update(this),this):f.create(this.options.location)},showAt:function(t){this.render(),this.element.css({left:n.round(t.x),top:n.round(t.y)}),this.tooltip&&this.tooltip.popup&&this.tooltip.popup._position()},hide:function(){this.element&&(this.element.remove(),this.element=null),this.tooltip&&(this.tooltip.destroy(),this.tooltip=null)},destroy:function(){this.layer=null,this.hide()},render:function(){var e,n;this.element||(e=this.options,n=this.layer,this.element=t(i.createElement("span")).addClass("k-marker k-marker-"+s.toHyphens(e.shape||"pin")).attr("title",e.title).attr(e.attributes||{}).data("kendoMarker",this).css("zIndex",e.zIndex),n&&n.element.append(this.element),this.renderTooltip())},renderTooltip:function(){var t,e,i=this,n=i.options.title,o=i.options.tooltip||{};o&&c&&(t=o.template,t&&(e=s.template(t),o.content=function(t){return t.location=i.location(),t.marker=i,e(t)}),(n||o.content||o.contentUrl)&&(this.tooltip=new c(this.element,o),this.tooltip.marker=this))}});m.create=function(t,e){return t instanceof m?t:new m(u({},e,t))},u(h,{map:{layers:{marker:g,MarkerLayer:g},Marker:m}})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/map/main.min",["dataviz/map/crs.min","dataviz/map/location.min"],t)}(function(){!function(t,e){var i=document,n=Math,o=n.min,r=n.pow,s=t.proxy,a=window.kendo,l=a.ui.Widget,c=a.deepExtend,h=a.dataviz,u=h.ui,d=a.geometry,f=d.Point,p=h.map,g=p.Extent,m=p.Location,v=p.crs.EPSG3857,_=a.util,y=_.defined,w=_.limitValue,x=_.renderPos,b=_.valueOrDefault,k="k-",C=.9,S=.93,T="DOMMouseScroll mousewheel",A=5,P=l.extend({init:function(t,e){a.destroy(t),l.fn.init.call(this,t),this._initOptions(e),this.bind(this.events,e),this.crs=new v,this.element.addClass(k+this.options.name.toLowerCase()).css("position","relative").empty().append(i.createElement("div")),this._viewOrigin=this._getOrigin(),this._initScroller(),this._initMarkers(),this._initControls(),this._initLayers(),this._reset(),this._mousewheel=s(this._mousewheel,this),this.element.bind("click",s(this._click,this)),this.element.bind(T,this._mousewheel)},options:{name:"Map",controls:{attribution:!0,navigator:{panStep:100},zoom:!0},layers:[],layerDefaults:{shape:{style:{fill:{color:"#fff"},stroke:{color:"#aaa",width:.5}}},bubble:{style:{fill:{color:"#fff",opacity:.5},stroke:{color:"#aaa",width:.5}}},marker:{shape:"pinTarget",tooltip:{position:"top"}}},center:[0,0],zoom:3,minSize:256,minZoom:1,maxZoom:19,markers:[],markerDefaults:{shape:"pinTarget",tooltip:{position:"top"}},wraparound:!0},events:["beforeReset","click","markerActivate","markerClick","markerCreated","pan","panEnd","reset","shapeClick","shapeCreated","shapeFeatureCreated","shapeMouseEnter","shapeMouseLeave","zoomEnd","zoomStart"],destroy:function(){this.scroller.destroy(),this.navigator&&this.navigator.destroy(),this.attribution&&this.attribution.destroy(),this.zoomControl&&this.zoomControl.destroy(),this.markers.destroy();for(var t=0;t<this.layers.length;t++)this.layers[t].destroy();l.fn.destroy.call(this)},zoom:function(t){var e=this.options;return y(t)?(t=n.round(w(t,e.minZoom,e.maxZoom)),e.zoom!==t&&(e.zoom=t,this._reset()),this):e.zoom},center:function(t){return t?(this.options.center=m.create(t).toArray(),this._reset(),this):m.create(this.options.center)},extent:function(t){return t?(this._setExtent(t),this):this._getExtent()},setOptions:function(t){l.fn.setOptions.call(this,t),this._reset()},locationToLayer:function(t,e){var i=!this.options.wraparound;return t=m.create(t),this.crs.toPoint(t,this._layerSize(e),i)},layerToLocation:function(t,e){var i=!this.options.wraparound;return t=f.create(t),this.crs.toLocation(t,this._layerSize(e),i)},locationToView:function(t){var e,i;return t=m.create(t),e=this.locationToLayer(this._viewOrigin),i=this.locationToLayer(t),i.translateWith(e.scale(-1))},viewToLocation:function(t,e){var i=this.locationToLayer(this._getOrigin(),e);return t=f.create(t),t=t.clone().translateWith(i),this.layerToLocation(t,e)},eventOffset:function(t){var e=this.element.offset(),i=t.originalEvent||t,n=b(i.pageX,i.clientX)-e.left,o=b(i.pageY,i.clientY)-e.top;return new d.Point(n,o)},eventToView:function(t){var e=this.eventOffset(t);return this.locationToView(this.viewToLocation(e))},eventToLayer:function(t){return this.locationToLayer(this.eventToLocation(t))},eventToLocation:function(t){var e=this.eventOffset(t);return this.viewToLocation(e)},viewSize:function(){var t=this.element,e=this._layerSize(),i=t.width();return this.options.wraparound||(i=o(e,i)),{width:i,height:o(e,t.height())}},exportVisual:function(){return this._reset(),!1},_setOrigin:function(t,e){var i,n=this.viewSize();return t=this._origin=m.create(t),i=this.locationToLayer(t,e),i.x+=n.width/2,i.y+=n.height/2,this.options.center=this.layerToLocation(i,e).toArray(),this},_getOrigin:function(t){var e,i=this.viewSize();return!t&&this._origin||(e=this.locationToLayer(this.center()),e.x-=i.width/2,e.y-=i.height/2,this._origin=this.layerToLocation(e)),this._origin},_setExtent:function(t){var e,i,o,r,s,a,l;for(t=g.create(t),this.center(t.center()),e=this.element.width(),i=this.element.height(),o=this.options.maxZoom;o>=this.options.minZoom&&(r=this.locationToLayer(t.nw,o),s=this.locationToLayer(t.se,o),a=n.abs(s.x-r.x),l=n.abs(s.y-r.y),!(a<=e&&l<=i));o--);this.zoom(o)},_getExtent:function(){var t,e=this._getOrigin(),i=this.locationToLayer(e),n=this.viewSize();return i.x+=n.width,i.y+=n.height,t=this.layerToLocation(i),new g(e,t)},_zoomAround:function(t,e){this._setOrigin(this.layerToLocation(t,e),e),this.zoom(e)},_initControls:function(){var t=this.options.controls;u.Attribution&&t.attribution&&this._createAttribution(t.attribution),
a.support.mobileOS||(u.Navigator&&t.navigator&&this._createNavigator(t.navigator),u.ZoomControl&&t.zoom&&this._createZoomControl(t.zoom))},_createControlElement:function(e,i){var n=e.position||i,o="."+x(n).replace(" ","."),r=t(".k-map-controls"+o,this.element);return 0===r.length&&(r=t("<div>").addClass("k-map-controls "+x(n)).appendTo(this.element)),t("<div>").appendTo(r)},_createAttribution:function(t){var e=this._createControlElement(t,"bottomRight");this.attribution=new u.Attribution(e,t)},_createNavigator:function(t){var e=this._createControlElement(t,"topLeft"),i=this.navigator=new u.Navigator(e,t);this._navigatorPan=s(this._navigatorPan,this),i.bind("pan",this._navigatorPan),this._navigatorCenter=s(this._navigatorCenter,this),i.bind("center",this._navigatorCenter)},_navigatorPan:function(t){var e=this,i=e.scroller,n=i.scrollLeft+t.x,o=i.scrollTop-t.y,r=this._virtualSize,s=this.element.height(),a=this.element.width();n=w(n,r.x.min,r.x.max-a),o=w(o,r.y.min,r.y.max-s),e.scroller.one("scroll",function(t){e._scrollEnd(t)}),e.scroller.scrollTo(-n,-o)},_navigatorCenter:function(){this.center(this.options.center)},_createZoomControl:function(t){var e=this._createControlElement(t,"topLeft"),i=this.zoomControl=new u.ZoomControl(e,t);this._zoomControlChange=s(this._zoomControlChange,this),i.bind("change",this._zoomControlChange)},_zoomControlChange:function(t){this.trigger("zoomStart",{originalEvent:t})||(this.zoom(this.zoom()+t.delta),this.trigger("zoomEnd",{originalEvent:t}))},_initScroller:function(){var t=a.support.mobileOS?S:C,e=this.options.zoomable!==!1,i=this.scroller=new a.mobile.ui.Scroller(this.element.children(0),{friction:t,velocityMultiplier:A,zoom:e,mousewheelScrolling:!1});i.bind("scroll",s(this._scroll,this)),i.bind("scrollEnd",s(this._scrollEnd,this)),i.userEvents.bind("gesturestart",s(this._scaleStart,this)),i.userEvents.bind("gestureend",s(this._scale,this)),this.scrollElement=i.scrollElement},_initLayers:function(){var t,e,i,n,o,r=this.options.layers,s=this.layers=[];for(t=0;t<r.length;t++)e=r[t],i=e.type||"shape",n=this.options.layerDefaults[i],o=h.map.layers[i],s.push(new o(this,c({},n,e)))},_initMarkers:function(){this.markers=new p.layers.MarkerLayer(this,this.options.markerDefaults),this.markers.add(this.options.markers)},_scroll:function(t){var e=this.locationToLayer(this._viewOrigin).round(),i=t.sender.movable,n=new d.Point(i.x,i.y).scale(-1).scale(1/i.scale);e.x+=n.x,e.y+=n.y,this._scrollOffset=n,this._setOrigin(this.layerToLocation(e)),this.trigger("pan",{originalEvent:t,origin:this._getOrigin(),center:this.center()})},_scrollEnd:function(t){this._scrollOffset&&this._panComplete()&&(this._scrollOffset=null,this._panEndTS=new Date,this.trigger("panEnd",{originalEvent:t,origin:this._getOrigin(),center:this.center()}))},_panComplete:function(){return new Date-(this._panEndTS||0)>50},_scaleStart:function(t){if(this.trigger("zoomStart",{originalEvent:t})){var e=t.touches[1];e&&e.cancel()}},_scale:function(t){var e=this.scroller.movable.scale,i=this._scaleToZoom(e),n=new d.Point(t.center.x,t.center.y),o=this.viewToLocation(n,i),r=this.locationToLayer(o,i),s=r.translate(-n.x,-n.y);this._zoomAround(s,i),this.trigger("zoomEnd",{originalEvent:t})},_scaleToZoom:function(t){var e=this._layerSize()*t,i=e/this.options.minSize,o=n.log(i)/n.log(2);return n.round(o)},_reset:function(){this.attribution&&this.attribution.filter(this.center(),this.zoom()),this._viewOrigin=this._getOrigin(!0),this._resetScroller(),this.trigger("beforeReset"),this.trigger("reset")},_resetScroller:function(){var t,e,i,n,o=this.scroller,s=o.dimensions.x,a=o.dimensions.y,l=this._layerSize(),c=this.extent().nw,h=this.locationToLayer(c).round();o.movable.round=!0,o.reset(),o.userEvents.cancel(),t=this.zoom(),o.dimensions.forcedMinScale=r(2,this.options.minZoom-t),o.dimensions.maxScale=r(2,this.options.maxZoom-t),e={min:-h.x,max:l-h.x},i={min:-h.y,max:l-h.y},this.options.wraparound&&(e.max=20*l,e.min=-e.max),this.options.pannable===!1&&(n=this.viewSize(),e.min=i.min=0,e.max=n.width,i.max=n.height),s.makeVirtual(),a.makeVirtual(),s.virtualSize(e.min,e.max),a.virtualSize(i.min,i.max),this._virtualSize={x:e,y:i}},_renderLayers:function(){var t,e,i,n,o,r=this.options.layers,s=this.layers=[],a=this.scrollWrap;for(a.empty(),t=0;t<r.length;t++)e=r[t],i=e.type||"shape",n=this.options.layerDefaults[i],o=h.map.layers[i],s.push(new o(this,c({},n,e)))},_layerSize:function(t){return t=b(t,this.options.zoom),this.options.minSize*r(2,t)},_click:function(t){if(this._panComplete()){var e=this.eventOffset(t);this.trigger("click",{originalEvent:t,location:this.viewToLocation(e)})}},_mousewheel:function(t){var e,i,n,o,r,s,a,l;t.preventDefault(),e=h.mwDelta(t)>0?-1:1,i=this.options,n=this.zoom(),o=w(n+e,i.minZoom,i.maxZoom),i.zoomable!==!1&&o!==n&&(this.trigger("zoomStart",{originalEvent:t})||(r=this.eventOffset(t),s=this.viewToLocation(r),a=this.locationToLayer(s,o),l=a.translate(-r.x,-r.y),this._zoomAround(l,o),this.trigger("zoomEnd",{originalEvent:t})))}});h.ui.plugin(P)}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.map.min",["kendo.data.min","kendo.userevents.min","kendo.tooltip.min","kendo.mobile.scroller.min","kendo.draganddrop.min","kendo.dataviz.core.min","dataviz/map/location.min","dataviz/map/attribution.min","dataviz/map/navigator.min","dataviz/map/zoom.min","dataviz/map/crs.min","dataviz/map/layers/base.min","dataviz/map/layers/shape.min","dataviz/map/layers/bubble.min","dataviz/map/layers/tile.min","dataviz/map/layers/bing.min","dataviz/map/layers/marker.min","dataviz/map/main.min"],t)}(function(){return window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/utils.min",["kendo.core.min"],t)}(function(){!function(t,e){function i(t,i,n){function o(t){for(var e=1;t*e%1;)e*=10;return e}var r,s,a,l;if(e===t||e===i)return[];if(n&&u.sign(i-t)!=u.sign(n))throw"The sign of the increment should allow to reach the stop-value.";if(n=n||1,t=t||0,i=i||t,(i-t)/n===1/0)throw"Infinite range defined.";if(r=[],s=-1,l=o(Math.abs(n)),t*=l,i*=l,n*=l,t>i&&n>0&&(n=-n),n<0)for(;(a=t+n*++s)>=i;)r.push(a/l);else for(;(a=t+n*++s)<=i;)r.push(a/l);return r}function n(t,e){if(t==e)return 0;var i=e.x-t.x,n=t.y-e.y,o=Math.atan(i/n);return n>=0?i<0?o+2*Math.PI:o:o+Math.PI}var o,r,s=window.kendo,a=s.dataviz.diagram={},l=s.deepExtend,c=t.isArray,h=1e-6,u={};l(u,{isNearZero:function(t){return Math.abs(t)<h},isDefined:function(t){return e!==t},isUndefined:function(t){return e===t||null===t},isObject:function(t){return t===Object(t)},has:function(t,e){return Object.hasOwnProperty.call(t,e)},isString:function(t){return"[object String]"==Object.prototype.toString.call(t)},isBoolean:function(t){return"[object Boolean]"==Object.prototype.toString.call(t)},isType:function(t,e){return Object.prototype.toString.call(t)=="[object "+e+"]"},isNumber:function(t){return!isNaN(parseFloat(t))&&isFinite(t)},isEmpty:function(t){if(null===t)return!0;if(c(t)||u.isString(t))return 0===t.length;for(var e in t)if(u.has(t,e))return!1;return!0},simpleExtend:function(t,e){if(u.isObject(e))for(var i in e)t[i]=e[i]},initArray:function(t,e){var i,n=[];for(i=0;i<t;++i)n[i]=e;return n},serializePoints:function(t){var e,i,n=[];for(e=0;e<t.length;e++)i=t[e],n.push(i.x+";"+i.y);return n.join(";")},deserializePoints:function(t){var e,i=t.split(";"),n=[];if(i.length%2!==0)throw"Not an array of points.";for(e=0;e<i.length;e+=2)n.push(new a.Point(parseInt(i[e],10),parseInt(i[e+1],10)));return n},randomInteger:function(t,e){return parseInt(Math.floor(Math.random()*e)+t,10)},DFT:function(t,e){var i,n;if(e(t),t.childNodes)for(i=0;i<t.childNodes.length;i++)n=t.childNodes[i],this.DFT(n,e)},getMatrixAngle:function(t){return null===t||0===t.d?0:180*Math.atan2(t.b,t.d)/Math.PI},getMatrixScaling:function(t){var e=Math.sqrt(t.a*t.a+t.c*t.c),i=Math.sqrt(t.b*t.b+t.d*t.d);return[e,i]}}),u.sign=function(t){return t?t<0?-1:1:0},u.findAngle=function(t,e){return 180*n(t,e)/Math.PI},u.forEach=function(t,e,i){for(var n=0;n<t.length;n++)e.call(i,t[n],n,t)},u.any=function(t,e){for(var i=0;i<t.length;++i)if(e(t[i]))return t[i];return null},u.remove=function(t,e){for(var i;(i=u.indexOf(t,e))!==-1;)t.splice(i,1);return t},u.contains=function(t,e){return u.indexOf(t,e)!==-1},u.indexOf=function(e,i){return t.inArray(i,e)},u.fold=function(t,e,i,n){var o,r,s=arguments.length>2;for(o=0;o<t.length;o++)r=t[o],s?i=e.call(n,i,r,o,t):(i=r,s=!0);if(!s)throw"Reduce of empty array with no initial value";return i},u.find=function(t,e,i){var n;return u.any(t,function(t,o,r){return!!e.call(i,t,o,r)&&(n=t,!0)}),n},u.first=function(t,e,i){return 0===t.length?null:u.isUndefined(e)?t[0]:u.find(t,e,i)},u.insert=function(t,e,i){return t.splice(i,0,e),t},u.all=function(t,e,i){var n,o,r=!0;for(o=0;o<t.length&&(n=t[o],r=r&&e.call(i,n,o,t),r);o++);return r},u.clear=function(t){t.splice(0,t.length)},u.bisort=function(t,e,i){if(u.isUndefined(t))throw"First array is not specified.";if(u.isUndefined(e))throw"Second array is not specified.";if(t.length!=e.length)throw"The two arrays should have equal length";var n,o=[];for(n=0;n<t.length;n++)o.push({x:t[n],y:e[n]});for(o.sort(u.isUndefined(i)?function(t,e){return t.x-e.x}:function(t,e){return i(t.x,e.x)}),u.clear(t),u.clear(e),n=0;n<o.length;n++)t.push(o[n].x),e.push(o[n].y)},u.addRange=function(t,e){t.push.apply(t,e)},o={easeInOut:function(t){return-Math.cos(t*Math.PI)/2+.5}},r=s.Class.extend({init:function(){this.adapters=[],this.target=0,this.tick=0,this.interval=20,this.duration=800,this.lastTime=null,this.handlers=[];var t=this;this.transition=o.easeInOut,this.timerDelegate=function(){t.onTimerEvent()}},addAdapter:function(t){this.adapters.push(t)},onComplete:function(t){this.handlers.push(t)},removeHandler:function(e){this.handlers=t.grep(this.handlers,function(t){return t!==e})},trigger:function(){var t=this;this.handlers&&u.forEach(this.handlers,function(e){return e.call(null!==t.caller?t.caller:t)})},onStep:function(){},seekTo:function(t){this.seekFromTo(this.tick,t)},seekFromTo:function(t,e){this.target=Math.max(0,Math.min(1,e)),this.tick=Math.max(0,Math.min(1,t)),this.lastTime=(new Date).getTime(),this.intervalId||(this.intervalId=window.setInterval(this.timerDelegate,this.interval))},stop:function(){this.intervalId&&(window.clearInterval(this.intervalId),this.intervalId=null,this.trigger())},play:function(t){0!==this.adapters.length&&(null!==t&&(this.caller=t),this.initState(),this.seekFromTo(0,1))},reverse:function(){this.seekFromTo(1,0)},initState:function(){if(0!==this.adapters.length)for(var t=0;t<this.adapters.length;t++)this.adapters[t].initState()},propagate:function(){var t,e=this.transition(this.tick);for(t=0;t<this.adapters.length;t++)this.adapters[t].update(e)},onTimerEvent:function(){var t,e=(new Date).getTime(),i=e-this.lastTime;this.lastTime=e,t=i/this.duration*(this.tick<this.target?1:-1),Math.abs(t)>=Math.abs(this.tick-this.target)?this.tick=this.target:this.tick+=t;try{this.propagate()}finally{this.onStep.call(this),this.target==this.tick&&this.stop()}}}),s.deepExtend(a,{init:function(t){s.init(t,a.ui)},Utils:u,Range:i,Ticker:r})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/math.min",["dataviz/diagram/utils.min","kendo.dataviz.core.min"],t)}(function(){!function(t,e){function i(t){return Math.abs(t)<B}function n(t,e,n,o,r){var s,a,l,c,h=(e.x-t.x)*(o.y-n.y)-(e.y-t.y)*(o.x-n.x);if(!i(h)&&(s=(t.y-n.y)*(o.x-n.x)-(t.x-n.x)*(o.y-n.y),a=(t.y-n.y)*(e.x-t.x)-(t.x-n.x)*(e.y-t.y),l=s/h,c=a/h,!r||!(l<0||l>1||c<0||c>1)))return new P(t.x+l*(e.x-t.x),t.y+l*(e.y-t.y))}function o(t,e){var i,n,o;do i=2*Math.random()-1,n=2*Math.random()-1,o=i*i+n*n;while(!o||o>1);return t+e*i*Math.sqrt(-2*Math.log(o)/o)}function r(t){var e,i,n;for(A.isUndefined(t)&&(t=10),e="",i="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",n=t;n>0;--n)e+=i.charAt(Math.round(Math.random()*(i.length-1)));return e}var s,a,l,c,h,u,d,f,p,g,m,v,_,y,w,x,b=window.kendo,k=b.dataviz.diagram,C=b.Class,S=b.deepExtend,T=b.dataviz,A=k.Utils,P=T.Point2D,D=b.isFunction,M=A.contains,E=t.map,I=3,B=1e-6;S(P.fn,{plus:function(t){return new P(this.x+t.x,this.y+t.y)},minus:function(t){return new P(this.x-t.x,this.y-t.y)},offset:function(t){return new P(this.x-t,this.y-t)},times:function(t){return new P(this.x*t,this.y*t)},normalize:function(){return 0===this.length()?new P:this.times(1/this.length())},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},toString:function(){return"("+this.x+","+this.y+")"},lengthSquared:function(){return this.x*this.x+this.y*this.y},middleOf:function(t,e){return new P(e.x-t.x,e.y-t.y).times(.5).plus(t)},toPolar:function(t){var e,i,n,o=1;if(t&&(o=180/Math.PI),e=Math.atan2(Math.abs(this.y),Math.abs(this.x)),i=Math.PI/2,n=this.length(),0===this.x){if(0===this.y)return new u(0,0);if(this.y>0)return new u(n,o*i);if(this.y<0)return new u(n,3*o*i)}else if(this.x>0){if(0===this.y)return new u(n,0);if(this.y>0)return new u(n,o*e);if(this.y<0)return new u(n,o*(4*i-e))}else{if(0===this.y)return new u(n,2*i);if(this.y>0)return new u(n,o*(2*i-e));if(this.y<0)return new u(n,o*(2*i+e))}},isOnLine:function(t,e){var i,n,o,r,s;return t.x>e.x&&(i=e,e=t,t=i),n=new a(t.x,t.y).inflate(I,I),o=new a(e.x,e.y).inflate(I,I),!!n.union(o).contains(this)&&(t.x===e.x||t.y===e.y||(t.y<e.y?(r=n.x+(o.x-n.x)*(this.y-(n.y+n.height))/(o.y+o.height-(n.y+n.height)),s=n.x+n.width+(o.x+o.width-(n.x+n.width))*(this.y-n.y)/(o.y-n.y)):(r=n.x+(o.x-n.x)*(this.y-n.y)/(o.y-n.y),s=n.x+n.width+(o.x+o.width-(n.x+n.width))*(this.y-(n.y+n.height))/(o.y+o.height-(n.y+n.height))),this.x>r&&this.x<s))}}),S(P,{parse:function(t){var e=t.slice(1,t.length-1),i=e.split(","),n=parseInt(i[0],10),o=parseInt(i[1],10);if(!isNaN(n)&&!isNaN(o))return new P(n,o)}}),s=C.extend({init:function(t,e,i){this.point=t,this.left=e,this.right=i}}),a=C.extend({init:function(t,e,i,n){this.x=t||0,this.y=e||0,this.width=i||0,this.height=n||0},contains:function(t){return t.x>=this.x&&t.x<=this.x+this.width&&t.y>=this.y&&t.y<=this.y+this.height},inflate:function(t,i){return i===e&&(i=t),this.x-=t,this.y-=i,this.width+=2*t+1,this.height+=2*i+1,this},offset:function(t,e){var i=t,n=e;return t instanceof P&&(i=t.x,n=t.y),this.x+=i,this.y+=n,this},union:function(t){var e=Math.min(this.x,t.x),i=Math.min(this.y,t.y),n=Math.max(this.x+this.width,t.x+t.width),o=Math.max(this.y+this.height,t.y+t.height);return new a(e,i,n-e,o-i)},center:function(){return new P(this.x+this.width/2,this.y+this.height/2)},top:function(){return new P(this.x+this.width/2,this.y)},right:function(){return new P(this.x+this.width,this.y+this.height/2)},bottom:function(){return new P(this.x+this.width/2,this.y+this.height)},left:function(){return new P(this.x,this.y+this.height/2)},topLeft:function(){return new P(this.x,this.y)},topRight:function(){return new P(this.x+this.width,this.y)},bottomLeft:function(){return new P(this.x,this.y+this.height)},bottomRight:function(){return new P(this.x+this.width,this.y+this.height)},clone:function(){return new a(this.x,this.y,this.width,this.height)},isEmpty:function(){return!this.width&&!this.height},equals:function(t){return this.x===t.x&&this.y===t.y&&this.width===t.width&&this.height===t.height},rotatedBounds:function(t){var e=this.clone(),i=this.rotatedPoints(t),n=i[0],o=i[1],r=i[2],s=i[3];return e.x=Math.min(r.x,n.x,o.x,s.x),e.y=Math.min(r.y,n.y,o.y,s.y),e.width=Math.max(r.x,n.x,o.x,s.x)-e.x,e.height=Math.max(r.y,n.y,o.y,s.y)-e.y,e},rotatedPoints:function(t){var e=this,i=e.center(),n=e.bottomRight().rotate(i,360-t),o=e.topLeft().rotate(i,360-t),r=e.topRight().rotate(i,360-t),s=e.bottomLeft().rotate(i,360-t);return[o,r,n,s]},toString:function(t){return t=t||" ",this.x+t+this.y+t+this.width+t+this.height},scale:function(t,e,i,n,o){var r,s,a,l=this.topLeft(),c=this.center();l.rotate(c,360-o).rotate(n,o),r=i.minus(l),s=new P(r.x*t,r.y*e),a=r.minus(s),l=l.plus(a),l.rotate(n,360-o).rotate(c,o),this.x=l.x,this.y=l.y,this.width*=t,this.height*=e},zoom:function(t){return this.x*=t,this.y*=t,this.width*=t,this.height*=t,this},overlaps:function(t){var e=this.bottomRight(),i=t.bottomRight(),n=!(e.x<t.x||e.y<t.y||i.x<this.x||i.y<this.y);return n}}),l=C.extend({init:function(t,e){this.width=t,this.height=e}}),l.prototype.Empty=new l(0,0),a.toRect=function(t){return t instanceof a||(t=new a(t.x,t.y,t.width,t.height)),t},a.empty=function(){return new a(0,0,0,0)},a.fromPoints=function(t,e){if(isNaN(t.x)||isNaN(t.y)||isNaN(e.x)||isNaN(e.y))throw"Some values are NaN.";return new a(Math.min(t.x,e.x),Math.min(t.y,e.y),Math.abs(t.x-e.x),Math.abs(t.y-e.y))},c={lines:function(t,e,i,o){return n(t,e,i,o)},segments:function(t,e,i,o){return n(t,e,i,o,!0)},rectWithLine:function(t,e,i){return c.segments(e,i,t.topLeft(),t.topRight())||c.segments(e,i,t.topRight(),t.bottomRight())||c.segments(e,i,t.bottomLeft(),t.bottomRight())||c.segments(e,i,t.topLeft(),t.bottomLeft())},rects:function(t,e,i){var n,o,r=e.topLeft(),s=e.topRight(),a=e.bottomLeft(),l=e.bottomRight(),h=e.center();return i&&(r=r.rotate(h,i),s=s.rotate(h,i),a=a.rotate(h,i),l=l.rotate(h,i)),n=t.contains(r)||t.contains(s)||t.contains(a)||t.contains(l)||c.rectWithLine(t,r,s)||c.rectWithLine(t,r,a)||c.rectWithLine(t,s,l)||c.rectWithLine(t,a,l),n||(r=t.topLeft(),s=t.topRight(),a=t.bottomLeft(),l=t.bottomRight(),i&&(o=360-i,r=r.rotate(h,o),s=s.rotate(h,o),a=a.rotate(h,o),l=l.rotate(h,o)),n=e.contains(r)||e.contains(s)||e.contains(a)||e.contains(l)),n}},h=C.extend({init:function(t){this.container=a.toRect(t)},align:function(t,e){var i,n=e.toLowerCase().split(" ");for(i=0;i<n.length;i++)t=this._singleAlign(t,n[i]);return t},_singleAlign:function(t,e){return D(this[e])?this[e](t):t},left:function(t){return this._align(t,this._left)},center:function(t){return this._align(t,this._center)},right:function(t){return this._align(t,this._right)},stretch:function(t){return this._align(t,this._stretch)},top:function(t){return this._align(t,this._top)},middle:function(t){return this._align(t,this._middle)},bottom:function(t){return this._align(t,this._bottom)},_left:function(t,e){e.x=t.x},_center:function(t,e){e.x=(t.width-e.width)/2||0},_right:function(t,e){e.x=t.width-e.width},_top:function(t,e){e.y=t.y},_middle:function(t,e){e.y=(t.height-e.height)/2||0},_bottom:function(t,e){e.y=t.height-e.height},_stretch:function(t,e){e.x=0,e.y=0,e.height=t.height,e.width=t.width},_align:function(t,e){return t=a.toRect(t),e(this.container,t),t}}),u=C.extend({init:function(t,e){this.r=t,this.angle=e}}),d=C.extend({init:function(t,e,i,n,o,r){this.a=t||0,this.b=e||0,this.c=i||0,this.d=n||0,this.e=o||0,this.f=r||0},plus:function(t){this.a+=t.a,this.b+=t.b,this.c+=t.c,this.d+=t.d,this.e+=t.e,this.f+=t.f},minus:function(t){this.a-=t.a,this.b-=t.b,this.c-=t.c,this.d-=t.d,this.e-=t.e,this.f-=t.f},times:function(t){return new d(this.a*t.a+this.c*t.b,this.b*t.a+this.d*t.b,this.a*t.c+this.c*t.d,this.b*t.c+this.d*t.d,this.a*t.e+this.c*t.f+this.e,this.b*t.e+this.d*t.f+this.f)},apply:function(t){return new P(this.a*t.x+this.c*t.y+this.e,this.b*t.x+this.d*t.y+this.f)},applyRect:function(t){return a.fromPoints(this.apply(t.topLeft()),this.apply(t.bottomRight()))},toString:function(){return"matrix("+this.a+" "+this.b+" "+this.c+" "+this.d+" "+this.e+" "+this.f+")"}}),S(d,{fromSVGMatrix:function(t){var e=new d;return e.a=t.a,e.b=t.b,e.c=t.c,e.d=t.d,e.e=t.e,e.f=t.f,e},fromMatrixVector:function(t){var e=new d;return e.a=t.a,e.b=t.b,e.c=t.c,e.d=t.d,e.e=t.e,e.f=t.f,e},fromList:function(t){if(6!==t.length)throw"The given list should consist of six elements.";var e=new d;return e.a=t[0],e.b=t[1],e.c=t[2],e.d=t[3],e.e=t[4],e.f=t[5],e},translation:function(t,e){var i=new d;return i.a=1,i.b=0,i.c=0,i.d=1,i.e=t,i.f=e,i},unit:function(){return new d(1,0,0,1,0,0)},rotation:function(t,e,i){var n=new d;return n.a=Math.cos(t*Math.PI/180),n.b=Math.sin(t*Math.PI/180),n.c=-n.b,n.d=n.a,n.e=e-e*n.a+i*n.b||0,n.f=i-i*n.a-e*n.b||0,n},scaling:function(t,e){var i=new d;return i.a=t,i.b=0,i.c=0,i.d=e,i.e=0,i.f=0,i},parse:function(t){var e,i;if(t){if(t=t.trim(),"matrix"===t.slice(0,6).toLowerCase()){if(i=t.slice(7,t.length-1).trim(),e=i.split(","),6===e.length)return d.fromList(E(e,function(t){return parseFloat(t)}));if(e=i.split(" "),6===e.length)return d.fromList(E(e,function(t){return parseFloat(t)}))}if("("===t.slice(0,1)&&")"===t.slice(t.length-1)&&(t=t.substr(1,t.length-1)),t.indexOf(",")>0&&(e=t.split(","),6===e.length))return d.fromList(E(e,function(t){return parseFloat(t)}));if(t.indexOf(" ")>0&&(e=t.split(" "),6===e.length))return d.fromList(E(e,function(t){return parseFloat(t)}))}return e}}),f=C.extend({init:function(t,e,i,n,o,r){this.a=t||0,this.b=e||0,this.c=i||0,this.d=n||0,this.e=o||0,this.f=r||0},fromMatrix:function(t){var e=new f;return e.a=t.a,e.b=t.b,e.c=t.c,e.d=t.d,e.e=t.e,e.f=t.f,e}}),p={_distanceToLineSquared:function(t,e,i){function n(t,e){return(t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y)}if(e===i)return n(t,e);var o=i.x-e.x,r=i.y-e.y,s=(t.x-e.x)*o+(t.y-e.y)*r;return s<0?n(e,t):(s=(i.x-t.x)*o+(i.y-t.y)*r,s<0?n(i,t):(s=(i.x-t.x)*r-(i.y-t.y)*o,s*s/(o*o+r*r)))},distanceToLine:function(t,e,i){return Math.sqrt(this._distanceToLineSquared(t,e,i))},distanceToPolyline:function(t,e){var i,n,o,r,s=Number.MAX_VALUE;if(A.isUndefined(e)||0===e.length)return Number.MAX_VALUE;for(i=0;i<e.length-1;i++)n=e[i],o=e[i+1],r=this._distanceToLineSquared(t,n,o),r<s&&(s=r);return Math.sqrt(s)}},g=b.Class.extend({init:function(){this._buckets=[],this.length=0},add:function(t,e){var i=this._createGetBucket(t);return A.isDefined(e)&&(i.value=e),i},get:function(t){return this._bucketExists(t)?this._createGetBucket(t):null},set:function(t,e){this.add(t,e)},containsKey:function(t){return this._bucketExists(t)},remove:function(t){if(this._bucketExists(t)){var e=this._hash(t);return delete this._buckets[e],this.length--,t}},forEach:function(t){var e,i,n,o,r=this._hashes();for(e=0,i=r.length;e<i;e++)n=r[e],o=this._buckets[n],A.isUndefined(o)||t(o)},clone:function(){var t,e,i,n,o=new g,r=this._hashes();for(t=0,e=r.length;t<e;t++)i=r[t],n=this._buckets[i],A.isUndefined(n)||o.add(n.key,n.value);return o},_hashes:function(){var t,e=[];for(t in this._buckets)this._buckets.hasOwnProperty(t)&&e.push(t);return e},_bucketExists:function(t){var e=this._hash(t);return A.isDefined(this._buckets[e])},_createGetBucket:function(t){var e=this._hash(t),i=this._buckets[e];return A.isUndefined(i)&&(i={key:t},this._buckets[e]=i,this.length++),i},_hash:function(t){if(A.isNumber(t))return t;if(A.isString(t))return this._hashString(t);if(A.isObject(t))return this._objectHashId(t);throw"Unsupported key type."},_hashString:function(t){var e,i,n=0;if(0===t.length)return n;for(e=0;e<t.length;e++)i=t.charCodeAt(e),n=32*n-n+i;return n},_objectHashId:function(t){var e=t._hashId;return A.isUndefined(e)&&(e=r(),t._hashId=e),e}}),m=b.Observable.extend({init:function(e){var i,n=this;if(b.Observable.fn.init.call(n),this._hashTable=new g,this.length=0,A.isDefined(e))if(t.isArray(e))for(i=0;i<e.length;i++)this.add(e[i]);else e.forEach(function(t,e){this.add(t,e)},this)},add:function(t,e){var i=this._hashTable.get(t);i||(i=this._hashTable.add(t),this.length++,this.trigger("changed")),i.value=e},set:function(t,e){this.add(t,e)},get:function(t){var e=this._hashTable.get(t);if(e)return e.value;throw Error("Cannot find key "+t)},containsKey:function(t){return this._hashTable.containsKey(t)},remove:function(t){if(this.containsKey(t))return this.trigger("changed"),this.length--,this._hashTable.remove(t)},forEach:function(t,e){this._hashTable.forEach(function(i){t.call(e,i.key,i.value)})},forEachValue:function(t,e){this._hashTable.forEach(function(i){t.call(e,i.value)})},forEachKey:function(t,e){this._hashTable.forEach(function(i){t.call(e,i.key)})},keys:function(){var t=[];return this.forEachKey(function(e){t.push(e)}),t}}),v=b.Class.extend({init:function(){this._tail=null,this._head=null,this.length=0},enqueue:function(t){var e={value:t,next:null};this._head?(this._tail.next=e,this._tail=this._tail.next):(this._head=e,this._tail=this._head),this.length++},dequeue:function(){if(this.length<1)throw Error("The queue is empty.");var t=this._head.value;return this._head=this._head.next,this.length--,t},contains:function(t){for(var e=this._head;e;){if(e.value===t)return!0;e=e.next}return!1}}),_=b.Observable.extend({init:function(t){var e=this;b.Observable.fn.init.call(e),this._hashTable=new g,this.length=0,A.isDefined(t)&&(t instanceof g?t.forEach(function(t){this.add(t)}):t instanceof m&&t.forEach(function(t,e){this.add({key:t,value:e})},this))},contains:function(t){return this._hashTable.containsKey(t)},add:function(t){var e=this._hashTable.get(t);e||(this._hashTable.add(t,t),this.length++,this.trigger("changed"))},get:function(t){return this.contains(t)?this._hashTable.get(t).value:null},hash:function(t){return this._hashTable._hash(t)},remove:function(t){this.contains(t)&&(this._hashTable.remove(t),this.length--,this.trigger("changed"))},forEach:function(t,e){this._hashTable.forEach(function(e){t(e.value)},e)},toArray:function(){var t=[];return this.forEach(function(e){t.push(e)}),t}}),y=b.Class.extend({init:function(t,e){if(this.links=[],this.outgoing=[],this.incoming=[],this.weight=1,this.id=A.isDefined(t)?t:r(),A.isDefined(e)){this.associatedShape=e;var i=e.bounds();this.width=i.width,this.height=i.height,this.x=i.x,this.y=i.y}else this.associatedShape=null;this.data=null,this.type="Node",this.shortForm="Node '"+this.id+"'",this.isVirtual=!1},isIsolated:function(){return A.isEmpty(this.links)},bounds:function(t){return A.isDefined(t)?(this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,e):new k.Rect(this.x,this.y,this.width,this.height)},isLinkedTo:function(t){var e=this;return A.any(e.links,function(i){return i.getComplement(e)===t})},getChildren:function(){var t,e,i,n;if(0===this.outgoing.length)return[];for(t=[],e=0,i=this.outgoing.length;e<i;e++)n=this.outgoing[e],t.push(n.getComplement(this));return t},getParents:function(){var t,e,i,n;if(0===this.incoming.length)return[];for(t=[],e=0,i=this.incoming.length;e<i;e++)n=this.incoming[e],t.push(n.getComplement(this));return t},clone:function(){var t=new y;return A.isDefined(this.weight)&&(t.weight=this.weight),A.isDefined(this.balance)&&(t.balance=this.balance),A.isDefined(this.owner)&&(t.owner=this.owner),t.associatedShape=this.associatedShape,t.x=this.x,t.y=this.y,t.width=this.width,t.height=this.height,t},adjacentTo:function(t){return null!==this.isLinkedTo(t)},removeLink:function(t){t.source===this&&(A.remove(this.links,t),A.remove(this.outgoing,t),t.source=null),t.target===this&&(A.remove(this.links,t),A.remove(this.incoming,t),t.target=null)},hasLinkTo:function(t){return A.any(this.outgoing,function(e){return e.target===t})},degree:function(){return this.links.length},incidentWith:function(t){return M(this.links,t)},getLinksWith:function(t){return A.all(this.links,function(e){return e.getComplement(this)===t},this)},getNeighbors:function(){var t=[];return A.forEach(this.incoming,function(e){t.push(e.getComplement(this))},this),A.forEach(this.outgoing,function(e){t.push(e.getComplement(this))},this),t}}),w=b.Class.extend({init:function(t,e,i,n){if(A.isUndefined(t))throw"The source of the new link is not set.";if(A.isUndefined(e))throw"The target of the new link is not set.";var o,s;o=A.isString(t)?new y(t):t,s=A.isString(e)?new y(e):e,this.source=o,this.target=s,this.source.links.push(this),this.target.links.push(this),this.source.outgoing.push(this),this.target.incoming.push(this),this.id=A.isDefined(i)?i:r(),this.associatedConnection=A.isDefined(n)?n:null,this.type="Link",this.shortForm="Link '"+this.source.id+"->"+this.target.id+"'"},getComplement:function(t){if(this.source!==t&&this.target!==t)throw"The given node is not incident with this link.";return this.source===t?this.target:this.source},getCommonNode:function(t){return this.source===t.source||this.source===t.target?this.source:this.target===t.source||this.target===t.target?this.target:null},isBridging:function(t,e){return this.source===t&&this.target===e||this.source===e&&this.target===t},getNodes:function(){return[this.source,this.target]},incidentWith:function(t){return this.source===t||this.target===t},adjacentTo:function(t){return M(this.source.links,t)||M(this.target.links,t)},changeSource:function(t){A.remove(this.source.links,this),A.remove(this.source.outgoing,this),t.links.push(this),t.outgoing.push(this),this.source=t},changeTarget:function(t){A.remove(this.target.links,this),A.remove(this.target.incoming,this),t.links.push(this),t.incoming.push(this),this.target=t},changesNodes:function(t,e){this.source===t?this.changeSource(e):this.target===t&&this.changeTarget(e)},reverse:function(){var t=this.source,e=this.target;return this.source=e,A.remove(t.outgoing,this),this.source.outgoing.push(this),this.target=t,A.remove(e.incoming,this),this.target.incoming.push(this),this},directTo:function(t){if(this.source!==t&&this.target!==t)throw"The given node is not incident with this link.";this.target!==t&&this.reverse()},createReverseEdge:function(){var t=this.clone();return t.reverse(),t.reversed=!0,t},clone:function(){var t=new w(this.source,this.target);return t}}),x=b.Class.extend({init:function(t){this.links=[],this.nodes=[],this._nodeMap=new m,this.diagram=null,this._root=null,A.isDefined(t)?A.isString(t)?this.id=t:(this.diagram=t,this.id=t.id):this.id=r(),this.bounds=new a,this._hasCachedRelationships=!1,this.type="Graph"},cacheRelationships:function(t){var e,i,n;if(A.isUndefined(t)&&(t=!1),!this._hasCachedRelationships||t){for(e=0,i=this.nodes.length;e<i;e++)n=this.nodes[e],n.children=this.getChildren(n),n.parents=this.getParents(n);this._hasCachedRelationships=!0}},assignLevels:function(t,e,i){var n,o,r,s;if(!t)throw"Start node not specified.";for(A.isUndefined(e)&&(e=0),this.cacheRelationships(),A.isUndefined(i)&&(i=new m,A.forEach(this.nodes,function(t){i.add(t,!1)})),i.set(t,!0),t.level=e,n=t.children,o=0,r=n.length;o<r;o++)s=n[o],s&&!i.get(s)&&this.assignLevels(s,e+1,i)},root:function(t){if(A.isUndefined(t)){if(this._root)return this._root;var e=A.first(this.nodes,function(t){return 0===t.incoming.length});return e?e:A.first(this.nodes)}this._root=t},getConnectedComponents:function(){var t,e,i,n,o;for(this.componentIndex=0,this.setItemIndices(),t=A.initArray(this.nodes.length,-1),e=0;e<this.nodes.length;e++)t[e]===-1&&(this._collectConnectedNodes(t,e),this.componentIndex++);for(i=[],n=0;n<this.componentIndex;++n)i[n]=new x;for(n=0;n<t.length;++n)o=i[t[n]],o.addNodeAndOutgoings(this.nodes[n]);return i.sort(function(t,e){return e.nodes.length-t.nodes.length}),i},_collectConnectedNodes:function(t,e){t[e]=this.componentIndex;var i=this.nodes[e];A.forEach(i.links,function(e){var n=e.getComplement(i),o=n.index;t[o]===-1&&this._collectConnectedNodes(t,o)},this)},calcBounds:function(){var t,e,i,n;if(this.isEmpty())return this.bounds=new a;for(t=null,e=0,i=this.nodes.length;e<i;e++)n=this.nodes[e],t=t?t.union(n.bounds()):n.bounds();return this.bounds=t},getSpanningTree:function(t){var e,i,n,o,r,s,a,l,c,h,u,d,f=new x,p=new m;for(f.root=t.clone(),f.root.level=0,f.root.id=t.id,p.add(t,f.root),t.level=0,n=[],o=[],f._addNode(f.root),n.push(t),o.push(t),r=1;o.length>0;)for(s=o.pop(),a=0;a<s.links.length;a++)l=s.links[a],c=l.getComplement(s),M(n,c)||(c.level=s.level+1,r<c.level+1&&(r=c.level+1),M(o,c)||o.push(c),M(n,c)||n.push(c),p.containsKey(s)?e=p.get(s):(e=s.clone(),e.level=s.level,e.id=s.id,p.add(s,e)),p.containsKey(c)?i=p.get(c):(i=c.clone(),i.level=c.level,i.id=c.id,p.add(c,i)),h=new w(e,i),f.addLink(h));for(u=[],d=0;d<r;d++)u.push([]);return A.forEach(f.nodes,function(t){u[t.level].push(t)}),f.treeLevels=u,f.cacheRelationships(),f},takeRandomNode:function(e,i){if(A.isUndefined(e)&&(e=[]),A.isUndefined(i)&&(i=4),0===this.nodes.length)return null;if(1===this.nodes.length)return M(e,this.nodes[0])?null:this.nodes[0];var n=t.grep(this.nodes,function(t){
return!M(e,t)&&t.degree()<=i});return A.isEmpty(n)?null:n[A.randomInteger(0,n.length)]},isEmpty:function(){return A.isEmpty(this.nodes)},isHealthy:function(){return A.all(this.links,function(t){return M(this.nodes,t.source)&&M(this.nodes,t.target)},this)},getParents:function(t){if(!this.hasNode(t))throw"The given node is not part of this graph.";return t.getParents()},getChildren:function(t){if(!this.hasNode(t))throw"The given node is not part of this graph.";return t.getChildren()},addLink:function(t,i,n){var o,r,s;if(A.isUndefined(t))throw"The source of the link is not defined.";if(A.isUndefined(i)){if(A.isDefined(t.type)&&"Link"===t.type)return this.addExistingLink(t),e;throw"The target of the link is not defined."}return o=this.getNode(t),A.isUndefined(o)&&(o=this.addNode(t)),r=this.getNode(i),A.isUndefined(r)&&(r=this.addNode(i)),s=new w(o,r),A.isDefined(n)&&(s.owner=n),this.links.push(s),s},removeAllLinks:function(){for(;this.links.length>0;){var t=this.links[0];this.removeLink(t)}},addExistingLink:function(t){var e,i;this.hasLink(t)||(this.links.push(t),this.hasNode(t.source.id)?(e=this.getNode(t.source.id),t.changeSource(e)):this.addNode(t.source),this.hasNode(t.target.id)?(i=this.getNode(t.target.id),t.changeTarget(i)):this.addNode(t.target))},hasLink:function(t){if(A.isString(t))return A.any(this.links,function(e){return e.id===t});if("Link"===t.type)return M(this.links,t);throw"The given object is neither an identifier nor a Link."},getNode:function(t){var e=t.id||t;if(this._nodeMap.containsKey(e))return this._nodeMap.get(e)},hasNode:function(t){var e=t.id||t;return this._nodeMap.containsKey(e)},_addNode:function(t){this.nodes.push(t),this._nodeMap.add(t.id,t)},_removeNode:function(t){A.remove(this.nodes,t),this._nodeMap.remove(t.id)},removeNode:function(t){var e,i,n,o,r=t;if(A.isString(t)&&(r=this.getNode(t)),!A.isDefined(r))throw"The identifier should be a Node or the Id (string) of a node.";for(e=r.links,r.links=[],i=0,n=e.length;i<n;i++)o=e[i],this.removeLink(o);this._removeNode(r)},areConnected:function(t,e){return A.any(this.links,function(i){return i.source==t&&i.target==e||i.source==e&&i.target==t})},removeLink:function(t){A.remove(this.links,t),A.remove(t.source.outgoing,t),A.remove(t.source.links,t),A.remove(t.target.incoming,t),A.remove(t.target.links,t)},addNode:function(t,e,i){var n=null;if(!A.isDefined(t))throw"No Node or identifier for a new Node is given.";if(A.isString(t)){if(this.hasNode(t))return this.getNode(t);n=new y(t)}else{if(this.hasNode(t))return this.getNode(t);n=t}return A.isDefined(e)&&n.bounds(e),A.isDefined(i)&&(n.owner=i),this._addNode(n),n},addNodeAndOutgoings:function(t){this.hasNode(t)||this._addNode(t);var e=t.outgoing;t.outgoing=[],A.forEach(e,function(t){this.addExistingLink(t)},this)},setItemIndices:function(){var t;for(t=0;t<this.nodes.length;++t)this.nodes[t].index=t;for(t=0;t<this.links.length;++t)this.links[t].index=t},clone:function(t){var e,i=new x,n=A.isDefined(t)&&t===!0;return n&&(i.nodeMap=new m,i.linkMap=new m),e=new m,A.forEach(this.nodes,function(t){var o=t.clone();e.set(t,o),i._addNode(o),n&&i.nodeMap.set(o,t)}),A.forEach(this.links,function(t){if(e.containsKey(t.source)&&e.containsKey(t.target)){var o=i.addLink(e.get(t.source),e.get(t.target));n&&i.linkMap.set(o,t)}}),i},linearize:function(t){return x.Utils.linearize(this,t)},depthFirstTraversal:function(t,e){var i,n;if(A.isUndefined(t))throw"You need to supply a starting node.";if(A.isUndefined(e))throw"You need to supply an action.";if(!this.hasNode(t))throw"The given start-node is not part of this graph";i=this.getNode(t),n=[],this._dftIterator(i,e,n)},_dftIterator:function(t,e,i){var n,o,r,s;for(e(t),i.push(t),n=t.getChildren(),o=0,r=n.length;o<r;o++)s=n[o],M(i,s)||this._dftIterator(s,e,i)},breadthFirstTraversal:function(t,e){var i,n,o,r,s,a,l,c;if(A.isUndefined(t))throw"You need to supply a starting node.";if(A.isUndefined(e))throw"You need to supply an action.";if(!this.hasNode(t))throw"The given start-node is not part of this graph";for(i=this.getNode(t),n=new v,o=[],n.enqueue(i);n.length>0;)for(r=n.dequeue(),e(r),o.push(r),s=r.getChildren(),a=0,l=s.length;a<l;a++)c=s[a],M(o,c)||M(n,c)||n.enqueue(c)},_stronglyConnectedComponents:function(t,e,i,n,o,r,s){var a,l,c,h,u;for(i.add(e,s),n.add(e,s),s++,r.push(e),a=e.getChildren(),c=0,h=a.length;c<h;c++)l=a[c],i.containsKey(l)?M(r,l)&&n.add(e,Math.min(n.get(e),i.get(l))):(this._stronglyConnectedComponents(t,l,i,n,o,r,s),n.add(e,Math.min(n.get(e),n.get(l))));if(n.get(e)===i.get(e)){u=[];do l=r.pop(),u.push(l);while(l!==e);(!t||u.length>1)&&o.push(u)}},findCycles:function(t){var e,i,n,o,r,s,a;for(A.isUndefined(t)&&(t=!0),e=new m,i=new m,n=[],o=[],r=0,s=this.nodes.length;r<s;r++)a=this.nodes[r],e.containsKey(a)||this._stronglyConnectedComponents(t,a,e,i,n,o,0);return n},isAcyclic:function(){return A.isEmpty(this.findCycles())},isSubGraph:function(t){var e=t.linearize(),i=this.linearize();return A.all(e,function(t){return M(i,t)})},makeAcyclic:function(){var t,e,i,n,o,r,s,a,l,c,h,u,d,f,p,g,v,_,y,w,x,b,k,C,S,T,P,D,M,E,I,B;if(this.isEmpty()||this.nodes.length<=1||this.links.length<=1)return[];if(2==this.nodes.length){if(t=[],this.links.length>1)for(e=this.links[0],i=e.source,n=0,o=this.links.length;n<o;n++)r=this.links[n],r.source!=i&&(s=r.reverse(),t.push(s));return t}for(a=this.clone(!0),l=this.nodes.length,c=new m,h=function(t){return 0===t.outgoing.length?2-l:0===t.incoming.length?l-2:t.outgoing.length-t.incoming.length},u=function(t,e){var i=h(t,l);e.containsKey(i)||e.set(i,[]),e.get(i).push(t)},A.forEach(a.nodes,function(t){u(t,c)}),d=[],f=[];a.nodes.length>0;){if(c.containsKey(2-l))for(_=c.get(2-l);_.length>0;){for(g=_.pop(),y=0;y<g.links.length;y++)w=g.links[y],p=w.getComplement(g),v=h(p,l),A.remove(c.get(v),p),p.removeLink(w),u(p,c);a._removeNode(g),f.unshift(g)}if(c.containsKey(l-2))for(x=c.get(l-2);x.length>0;){for(p=x.pop(),b=0;b<p.links.length;b++)k=p.links[b],g=k.getComplement(p),v=h(g,l),A.remove(c.get(v),g),g.removeLink(k),u(g,c);d.push(p),a._removeNode(p)}if(a.nodes.length>0)for(C=l-3;C>2-l;C--)if(c.containsKey(C)&&c.get(C).length>0){for(S=c.get(C),T=S.pop(),P=0;P<T.links.length;P++)D=T.links[P],M=D.getComplement(T),v=h(M,l),A.remove(c.get(v),M),M.removeLink(D),u(M,c);d.push(T),a._removeNode(T);break}}for(d=d.concat(f),E=new m,I=0;I<this.nodes.length;I++)E.set(a.nodeMap.get(d[I]),I);return B=[],A.forEach(this.links,function(t){E.get(t.source)>E.get(t.target)&&(t.reverse(),B.push(t))}),B}}),x.Predefined={EightGraph:function(){return x.Utils.parse(["1->2","2->3","3->4","4->1","3->5","5->6","6->7","7->3"])},Mindmap:function(){return x.Utils.parse(["0->1","0->2","0->3","0->4","0->5","1->6","1->7","7->8","2->9","9->10","9->11","3->12","12->13","13->14","4->15","4->16","15->17","15->18","18->19","18->20","14->21","14->22","5->23","23->24","23->25","6->26"])},ThreeGraph:function(){return x.Utils.parse(["1->2","2->3","3->1"])},BinaryTree:function(t){return A.isUndefined(t)&&(t=5),x.Utils.createBalancedTree(t,2)},Linear:function(t){return A.isUndefined(t)&&(t=10),x.Utils.createBalancedTree(t,1)},Tree:function(t,e){return x.Utils.createBalancedTree(t,e)},Forest:function(t,e,i){return x.Utils.createBalancedForest(t,e,i)},Workflow:function(){return x.Utils.parse(["0->1","1->2","2->3","1->4","4->3","3->5","5->6","6->3","6->7","5->4"])},Grid:function(t,e){var i,n,o,r,s,a=new k.Graph;if(t<=0&&e<=0)return a;for(i=0;i<t+1;i++)for(n=null,o=0;o<e+1;o++)r=new y(""+i+"."+o),a.addNode(r),n&&a.addLink(n,r),i>0&&(s=a.getNode(""+(i-1)+"."+o),a.addLink(s,r)),n=r;return a}},x.Utils={parse:function(t){var e,i,n,o,r,s=new k.Graph,a=t.slice();for(i=0,n=a.length;i<n;i++){if(o=a[i],A.isString(o)){if(o.indexOf("->")<0)throw"The link should be specified as 'a->b'.";if(r=o.split("->"),2!=r.length)throw"The link should be specified as 'a->b'.";e=new w(r[0],r[1]),s.addLink(e)}if(A.isObject(o)){if(!e)throw"Specification found before Link definition.";b.deepExtend(e,o)}}return s},linearize:function(t,e){var i,n,o,r;if(A.isUndefined(t))throw"Expected an instance of a Graph object in slot one.";for(A.isUndefined(e)&&(e=!1),i=[],n=0,o=t.links.length;n<o;n++)r=t.links[n],i.push(r.source.id+"->"+r.target.id),e&&i.push({id:r.id});return i},_addShape:function(t,e,i,n){return A.isUndefined(e)&&(e=new k.Point(0,0)),A.isUndefined(i)&&(i=r()),n=b.deepExtend({width:20,height:20,id:i,radius:10,fill:"#778899",data:"circle",undoable:!1,x:e.x,y:e.y},n),t.addShape(n)},_addConnection:function(t,e,i,n){return t.connect(e,i,n)},createDiagramFromGraph:function(t,e,i,n){var o,r,s,l,c,h,u,d,f,p,g,m,v,_,y,w;if(A.isUndefined(t))throw"The diagram surface is undefined.";if(A.isUndefined(e))throw"No graph specification defined.";for(A.isUndefined(i)&&(i=!0),A.isUndefined(n)&&(n=!1),o=t.element.clientWidth||200,r=t.element.clientHeight||200,s=[],h=0,u=e.nodes.length;h<u;h++)l=e.nodes[h],d=l.position,A.isUndefined(d)&&(d=A.isDefined(l.x)&&A.isDefined(l.y)?new P(l.x,l.y):new P(A.randomInteger(10,o-20),A.randomInteger(10,r-20))),f={},"0"===l.id||n&&b.deepExtend(f,{width:150*Math.random()+20,height:80*Math.random()+50,data:"rectangle",fill:{color:"#778899"}}),c=this._addShape(t,d,l.id,f),p=c.bounds(),A.isDefined(p)&&(l.x=p.x,l.y=p.y,l.width=p.width,l.height=p.height),s[l.id]=c;for(g=0;g<e.links.length;g++)m=e.links[g],v=s[m.source.id],A.isUndefined(v)||(_=s[m.target.id],A.isUndefined(_)||this._addConnection(t,v,_,{id:m.id}));if(i)for(y=new t.SpringLayout(t),y.layoutGraph(e,{limitToView:!1}),w=0;w<e.nodes.length;w++)l=e.nodes[w],c=s[l.id],c.bounds(new a(l.x,l.y,l.width,l.height))},createBalancedTree:function(t,e){var i,n,o,r,s,a,l,c,h,u;if(A.isUndefined(t)&&(t=3),A.isUndefined(e)&&(e=3),i=new k.Graph,n=-1,o=[],t<=0||e<=0)return i;for(s=new y(""+ ++n),i.addNode(s),i.root=s,o.push(s),a=0;a<t;a++){for(r=[],l=0;l<o.length;l++)for(c=o[l],h=0;h<e;h++)u=new y(""+ ++n),i.addLink(c,u),r.push(u);o=r}return i},createBalancedForest:function(t,e,i){var n,o,r,s,a,l,c,h,u,d,f;if(A.isUndefined(t)&&(t=3),A.isUndefined(e)&&(e=3),A.isUndefined(i)&&(i=5),n=new k.Graph,o=-1,r=[],t<=0||e<=0||i<=0)return n;for(a=0;a<i;a++)for(l=new y(""+ ++o),n.addNode(l),r=[l],c=0;c<t;c++){for(s=[],h=0;h<r.length;h++)for(u=r[h],d=0;d<e;d++)f=new y(""+ ++o),n.addLink(u,f),s.push(f);r=s}return n},createRandomConnectedGraph:function(t,e,i){var n,o,r,s,a,l,c,h,u,d;if(A.isUndefined(t)&&(t=40),A.isUndefined(e)&&(e=4),A.isUndefined(i)&&(i=!1),n=new k.Graph,o=-1,t<=0)return n;if(r=new y(""+ ++o),n.addNode(r),1===t)return n;if(t>1){for(s=1;s<t&&(a=n.takeRandomNode([],e),a);s++)l=n.addNode(""+s),n.addLink(a,l);if(!i&&t>1)for(c=A.randomInteger(1,t),h=0;h<c;h++)u=n.takeRandomNode([],e),d=n.takeRandomNode([],e),u&&d&&!n.areConnected(u,d)&&n.addLink(u,d);return n}},randomDiagram:function(t,e,i,n,o){var r=b.dataviz.diagram.Graph.Utils.createRandomConnectedGraph(e,i,n);x.Utils.createDiagramFromGraph(t,r,!1,o)}},b.deepExtend(k,{init:function(t){b.init(t,k.ui)},Point:P,Intersect:c,Geometry:p,Rect:a,Size:l,RectAlign:h,Matrix:d,MatrixVector:f,normalVariable:o,randomId:r,Dictionary:m,HashTable:g,Queue:v,Set:_,Node:y,Link:w,Graph:x,PathDefiner:s})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/svg.min",["kendo.drawing.min","dataviz/diagram/math.min"],t)}(function(){!function(t,e){function i(t,e){var i,n,o,r=this.options,s=!1;for(o=0;o<e.length;o++)n=e[o],i=t[n],V(i)&&r[n]!==i&&(r[n]=i,s=!0);return s}function n(t){return{x:t.x||0,y:t.y||0,width:t.width||0,height:t.height||0}}function o(t){if(t){var e=t;return F(e)&&(e={color:e}),e.color&&(e.color=r(e.color)),e}}function r(t){var e;return e=t!=W?new U.Color(t).toHex():t}function s(t,e){var i=e.x-t.x,n=e.y-t.y,o=M.util.deg(Math.atan2(n,i));return o}function a(t,e){return new U.Segment(new H.Point(t,e))}function l(t){if(t)return new H.Rect([t.x,t.y],[t.width,t.height])}var c,h,u,d,f,p,g,m,v,_,y,w,x,b,k,C,S,T,A,P,D,M=window.kendo,E=M.dataviz.diagram,I=M.Class,B=M.deepExtend,z=E.Point,L=E.Rect,R=E.Matrix,O=E.Utils,V=O.isNumber,F=O.isString,N=E.MatrixVector,H=M.geometry,U=M.drawing,j=M.util.defined,G=t.inArray,W="transparent",q={none:"none",arrowStart:"ArrowStart",filledCircle:"FilledCircle",arrowEnd:"ArrowEnd"},$=360,Y="start",X="end",Q="width",K="height",Z="x",J="y";E.Markers=q,c=I.extend({init:function(t,e){this.x=t,this.y=e},toMatrix:function(){return R.scaling(this.x,this.y)},toString:function(){return M.format("scale({0},{1})",this.x,this.y)},invert:function(){return new c(1/this.x,1/this.y)}}),h=I.extend({init:function(t,e){this.x=t,this.y=e},toMatrixVector:function(){return new N(0,0,0,0,this.x,this.y)},toMatrix:function(){return R.translation(this.x,this.y)},toString:function(){return M.format("translate({0},{1})",this.x,this.y)},plus:function(t){this.x+=t.x,this.y+=t.y},times:function(t){this.x*=t,this.y*=t},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},normalize:function(){0!==this.Length&&this.times(1/this.length())},invert:function(){return new h((-this.x),(-this.y))}}),u=I.extend({init:function(t,e,i){this.x=e||0,this.y=i||0,this.angle=t},toString:function(){return this.x&&this.y?M.format("rotate({0},{1},{2})",this.angle,this.x,this.y):M.format("rotate({0})",this.angle)},toMatrix:function(){return R.rotation(this.angle,this.x,this.y)},center:function(){return new z(this.x,this.y)},invert:function(){return new u($-this.angle,this.x,this.y)}}),u.ZERO=new u(0),u.create=function(t){return new u(t.angle,t.x,t.y)},u.parse=function(t){var e=t.slice(1,t.length-1).split(","),i=e[0],n=e[1],o=e[2],r=new u(i,n,o);return r},d=I.extend({init:function(t,i,n,o,r,s){this.translate=new h(t,i),n!==e&&o!==e&&(this.scale=new c(n,o)),r!==e&&(this.rotate=s?new u(r,s.x,s.y):new u(r))},toString:function(){var t=function(t){return t?""+t:""};return t(this.translate)+t(this.rotate)+t(this.scale)},render:function(t){t._transform=this,t._renderTransform()},toMatrix:function(){var t=R.unit();return this.translate&&(t=t.times(this.translate.toMatrix())),this.rotate&&(t=t.times(this.rotate.toMatrix())),this.scale&&(t=t.times(this.scale.toMatrix())),t},invert:function(){var t,i,n=this.rotate?this.rotate.invert():e,o=n?n.toMatrix():R.unit(),r=this.scale?this.scale.invert():e,s=r?r.toMatrix():R.unit(),a=new z((-this.translate.x),(-this.translate.y));return a=o.times(s).apply(a),t=new h(a.x,a.y),i=new d,i.translate=t,i.rotate=n,i.scale=r,i}}),f={_setScale:function(){var t=this.options,e=this._originWidth,i=this._originHeight,n=t.width/e,o=t.height/i;V(n)||(n=1),V(o)||(o=1),this._transform.scale=new c(n,o)},_setTranslate:function(){var t=this.options,e=t.x||0,i=t.y||0;this._transform.translate=new h(e,i)},_initSize:function(){var t=this.options,e=!1;t.autoSize!==!1&&(j(t.width)||j(t.height))&&(this._measure(!0),this._setScale(),e=!0),(j(t.x)||j(t.y))&&(this._setTranslate(),e=!0),e&&this._renderTransform()},_updateSize:function(t){var e=!1;return this.options.autoSize!==!1&&this._diffNumericOptions(t,[Q,K])&&(e=!0,this._measure(!0),this._setScale()),this._diffNumericOptions(t,[Z,J])&&(e=!0,this._setTranslate()),e&&this._renderTransform(),e}},p=I.extend({init:function(t){var e=this;e.options=B({},e.options,t),e.id=e.options.id,e._originSize=L.empty(),e._transform=new d},visible:function(t){return this.drawingContainer().visible(t)},redraw:function(t){t&&t.id&&(this.id=t.id)},position:function(t,i){var n=this.options;return j(t)?(j(i)?(n.x=t,n.y=i):t instanceof z&&(n.x=t.x,n.y=t.y),this._transform.translate=new h(n.x,n.y),this._renderTransform(),e):new z(n.x,n.y)},rotate:function(t,e){return j(t)&&(this._transform.rotate=new u(t,e.x,e.y),this._renderTransform()),this._transform.rotate||u.ZERO},drawingContainer:function(){return this.drawingElement},_renderTransform:function(){var t=this._transform.toMatrix();this.drawingContainer().transform(new H.Matrix(t.a,t.b,t.c,t.d,t.e,t.f))},_hover:function(){},_diffNumericOptions:i,_measure:function(t){var e,i,n;return!this._measured||t?(i=this._boundingBox()||new H.Rect,n=i.topLeft(),e=new L(n.x,n.y,i.width(),i.height()),this._originSize=e,this._originWidth=e.width,this._originHeight=e.height,this._measured=!0):e=this._originSize,e},_boundingBox:function(){return this.drawingElement.rawBBox()}}),g=p.extend({init:function(t){p.fn.init.call(this,t),t=this.options,t.fill=o(t.fill),t.stroke=o(t.stroke)},options:{stroke:{color:"gray",width:1},fill:{color:W}},fill:function(t,e){this._fill({color:r(t),opacity:e})},stroke:function(t,e,i){this._stroke({color:r(t),width:e,opacity:i})},redraw:function(t){var e,i;t&&(e=t.stroke,i=t.fill,e&&this._stroke(o(e)),i&&this._fill(o(i)),p.fn.redraw.call(this,t))},_hover:function(t){var e,i=this.drawingElement,n=this.options,r=n.hover;r&&r.fill&&(e=t?o(r.fill):n.fill,i.fill(e.color,e.opacity))},_stroke:function(t){var e,i=this.options;B(i,{stroke:t}),t=i.stroke,e=null,t.width>0&&(e={color:t.color,width:t.width,opacity:t.opacity,dashType:t.dashType}),this.drawingElement.options.set("stroke",e)},_fill:function(t){var e,i,n,o=this.options;B(o,{fill:t||{}}),e=o.fill,e.gradient?(i=e.gradient,n="radial"===i.type?U.RadialGradient:U.LinearGradient,this.drawingElement.fill(new n(i))):this.drawingElement.fill(e.color,e.opacity)}}),m=g.extend({init:function(t){t=this._textColor(t),g.fn.init.call(this,t),this._font(),this._initText(),this._initSize()},options:{fontSize:15,fontFamily:"sans-serif",stroke:{width:0},fill:{color:"black"},autoSize:!0},_initText:function(){var t=this.options;this.drawingElement=new U.Text(j(t.text)?t.text:"",new H.Point,{font:t.font}),this._fill(),this._stroke()},_textColor:function(t){return t&&t.color&&(t=B({},t,{fill:{color:t.color}})),t},_font:function(){var t,e=this.options;e.fontFamily&&j(e.fontSize)?(t=[],e.fontStyle&&t.push(e.fontStyle),e.fontWeight&&t.push(e.fontWeight),t.push(e.fontSize+(V(e.fontSize)?"px":"")),t.push(e.fontFamily),e.font=t.join(" ")):delete e.font},content:function(t){return this.drawingElement.content(t)},redraw:function(t){var e,i;t&&(e=!1,i=this.options,t=this._textColor(t),g.fn.redraw.call(this,t),(t.fontFamily||j(t.fontSize)||t.fontStyle||t.fontWeight)&&(B(i,{fontFamily:t.fontFamily,fontSize:t.fontSize,fontStyle:t.fontStyle,fontWeight:t.fontWeight}),this._font(),this.drawingElement.options.set("font",i.font),e=!0),t.text&&(this.content(t.text),e=!0),!this._updateSize(t)&&e&&this._initSize())}}),B(m.fn,f),v=g.extend({init:function(t){g.fn.init.call(this,t),this._initPath(),this._setPosition()},_setPosition:function(){var t=this.options,e=t.x,i=t.y;(j(e)||j(i))&&this.position(e||0,i||0)},redraw:function(t){t&&(g.fn.redraw.call(this,t),this._diffNumericOptions(t,[Q,K])&&this._drawPath(),this._diffNumericOptions(t,[Z,J])&&this._setPosition())},_initPath:function(){var t=this.options;this.drawingElement=new U.Path({stroke:t.stroke,closed:!0}),this._fill(),this._drawPath()},_drawPath:function(){var t=this.drawingElement,e=n(this.options),i=e.width,o=e.height;t.segments.elements([a(0,0),a(i,0),a(i,o),a(0,o)])}}),_=g.extend({init:function(t){g.fn.init.call(this,t);var e=this.options.anchor;this.anchor=new H.Point(e.x,e.y),this.createElement()},options:{stroke:{color:W,width:0},fill:{color:"black"}},_transformToPath:function(t,e){var i=e.transform();return t&&i&&(t=t.transformCopy(i)),t},redraw:function(t){t&&(t.position&&(this.options.position=t.position),g.fn.redraw.call(this,t))}}),y=_.extend({options:{radius:4,anchor:{x:0,y:0}},createElement:function(){var t=this.options;this.drawingElement=new U.Circle(new H.Circle(this.anchor,t.radius),{fill:t.fill,stroke:t.stroke})},positionMarker:function(t){var e,i,n=this.options,o=n.position,r=t.segments;e=o==Y?r[0]:r[r.length-1],e&&(i=this._transformToPath(e.anchor(),t),this.drawingElement.transform(H.transform().translate(i.x,i.y)))}}),w=_.extend({options:{path:"M 0 0 L 10 5 L 0 10 L 3 5 z",anchor:{x:10,y:5}},createElement:function(){var t=this.options;this.drawingElement=U.Path.parse(t.path,{fill:t.fill,stroke:t.stroke})},positionMarker:function(t){var e,i,n=this._linePoints(t),o=n.start,r=n.end,a=H.transform();o&&a.rotate(s(o,r),r),r&&(e=this.anchor,i=r.clone().translate(-e.x,-e.y),a.translate(i.x,i.y)),this.drawingElement.transform(a)},_linePoints:function(t){var e,i,n,o,r,s=this.options,a=t.segments;if(s.position==Y?(n=a[0],n&&(i=n.anchor(),e=n.controlOut(),o=a[1],!e&&o&&(e=o.anchor()))):(n=a[a.length-1],n&&(i=n.anchor(),e=n.controlIn(),r=a[a.length-2],!e&&r&&(e=r.anchor()))),i)return{start:this._transformToPath(e,t),end:this._transformToPath(i,t)}}}),x={_getPath:function(t){var e=this.drawingElement;if(e instanceof U.MultiPath&&(e=t==Y?e.paths[0]:e.paths[e.paths.length-1]),e&&e.segments.length)return e},_normalizeMarkerOptions:function(t){var e=t.startCap,i=t.endCap;F(e)&&(t.startCap={type:e}),F(i)&&(t.endCap={type:i})},_removeMarker:function(t){var e=this._markers[t];e&&(this.drawingContainer().remove(e.drawingElement),delete this._markers[t])},_createMarkers:function(){var t=this.options;this._normalizeMarkerOptions(t),this._markers={},this._markers[Y]=this._createMarker(t.startCap,Y),this._markers[X]=this._createMarker(t.endCap,X)},_createMarker:function(t,i){var n,o,r=(t||{}).type,s=this._getPath(i);return s?(r==q.filledCircle?n=y:r==q.arrowStart||r==q.arrowEnd?n=w:this._removeMarker(i),n?(o=new n(B({},t,{position:i})),o.positionMarker(s),this.drawingContainer().append(o.drawingElement),o):e):(this._removeMarker(i),e)},_positionMarker:function(t){var e,i=this._markers[t];i&&(e=this._getPath(t),e?i.positionMarker(e):this._removeMarker(t))},_capMap:{start:"startCap",end:"endCap"},_redrawMarker:function(t,e,i){var n,o,r,s,a;return this._normalizeMarkerOptions(i),n=this.options,o=this._capMap[e],r=(n[o]||{}).type,s=i[o],a=!1,s?(n[o]=B({},n[o],s),s.type&&r!=s.type?(this._removeMarker(e),this._markers[e]=this._createMarker(n[o],e),a=!0):this._markers[e]&&this._markers[e].redraw(s)):t&&!this._markers[e]&&n[o]&&(this._markers[e]=this._createMarker(n[o],e),a=!0),a},_redrawMarkers:function(t,e){!this._redrawMarker(t,Y,e)&&t&&this._positionMarker(Y),!this._redrawMarker(t,X,e)&&t&&this._positionMarker(X)}},b=g.extend({init:function(t){g.fn.init.call(this,t),this.container=new U.Group,this._createElements(),this._initSize()},options:{autoSize:!0},drawingContainer:function(){return this.container},data:function(t){var i=this.options;return t?(i.data!=t&&(i.data=t,this._setData(t),this._initSize(),this._redrawMarkers(!0,{})),e):i.data},redraw:function(t){var e,i;t&&(g.fn.redraw.call(this,t),e=this.options,i=t.data,j(i)&&e.data!=i?(e.data=i,this._setData(i),this._updateSize(t)||this._initSize(),this._redrawMarkers(!0,t)):(this._updateSize(t),this._redrawMarkers(!1,t)))},_createElements:function(){var t=this.options;this.drawingElement=U.Path.parse(t.data||"",{stroke:t.stroke}),this._fill(),this.container.append(this.drawingElement),this._createMarkers()},_setData:function(t){var e=this.drawingElement,i=U.Path.parse(t||""),n=i.paths.slice(0);i.paths.elements([]),e.paths.elements(n)}}),B(b.fn,f),B(b.fn,x),k=g.extend({init:function(t){g.fn.init.call(this,t),this.container=new U.Group,this._initPath(),this._createMarkers()},drawingContainer:function(){return this.container},redraw:function(t){var e,i;t&&(t=t||{},e=t.from,i=t.to,e&&(this.options.from=e),i&&(this.options.to=i),e||i?(this._drawPath(),this._redrawMarkers(!0,t)):this._redrawMarkers(!1,t),g.fn.redraw.call(this,t))},_initPath:function(){var t=this.options,e=this.drawingElement=new U.Path({stroke:t.stroke});this._fill(),this._drawPath(),this.container.append(e)},_drawPath:function(){var t=this.options,e=this.drawingElement,i=t.from||new z,n=t.to||new z;e.segments.elements([a(i.x,i.y),a(n.x,n.y)])}}),B(k.fn,x),C=g.extend({init:function(t){g.fn.init.call(this,t),this.container=new U.Group,this._initPath(),this._createMarkers()},drawingContainer:function(){return this.container},points:function(t){var i=this.options;return t?(i.points=t,this._updatePath(),e):i.points},redraw:function(t){if(t){var e=t.points;g.fn.redraw.call(this,t),e&&this._pointsDiffer(e)?(this.points(e),this._redrawMarkers(!0,t)):this._redrawMarkers(!1,t)}},_initPath:function(){var t=this.options;this.drawingElement=new U.Path({stroke:t.stroke}),this._fill(),this.container.append(this.drawingElement),t.points&&this._updatePath()},_pointsDiffer:function(t){var e,i=this.options.points,n=i.length!==t.length;if(!n)for(e=0;e<t.length;e++)if(i[e].x!==t[e].x||i[e].y!==t[e].y){n=!0;break}return n},_updatePath:function(){var t,e,i=this.drawingElement,n=this.options,o=n.points,r=[];for(e=0;e<o.length;e++)t=o[e],r.push(a(t.x,t.y));i.segments.elements(r)},options:{points:[]}}),B(C.fn,x),S=p.extend({init:function(t){p.fn.init.call(this,t),this._initImage()},redraw:function(t){t&&(t.source&&this.drawingElement.src(t.source),this._diffNumericOptions(t,[Q,K,Z,J])&&this.drawingElement.rect(this._rect()),p.fn.redraw.call(this,t))},_initImage:function(){var t=this.options,e=this._rect();this.drawingElement=new U.Image(t.source,e,{})},_rect:function(){var t=n(this.options),e=new H.Point(t.x,t.y),i=new H.Size(t.width,t.height);return new H.Rect(e,i)}}),T=p.extend({init:function(t){this.children=[],p.fn.init.call(this,t),this.drawingElement=new U.Group,this._initSize()},options:{autoSize:!1},append:function(t){this.drawingElement.append(t.drawingContainer()),this.children.push(t),this._childrenChange=!0},remove:function(t){this._remove(t)&&(this._childrenChange=!0)},_remove:function(t){var e=G(t,this.children);if(e>=0)return this.drawingElement.removeAt(e),this.children.splice(e,1),!0},clear:function(){this.drawingElement.clear(),this.children=[],this._childrenChange=!0},toFront:function(t){var e,i;for(i=0;i<t.length;i++)e=t[i],this._remove(e)&&this.append(e)},toBack:function(t){this._reorderChildren(t,0)},toIndex:function(t,e){this._reorderChildren(t,e)},_reorderChildren:function(t,e){var i,n,o,r,s,a=this.drawingElement,l=a.children.slice(0),c=this.children,h=V(e);for(i=0;i<t.length;i++)s=t[i],r=s.drawingContainer(),n=G(s,c),n>=0&&(l.splice(n,1),c.splice(n,1),o=h?e:e[i],l.splice(o,0,r),c.splice(o,0,s));a.clear(),a.append.apply(a,l)},redraw:function(t){t&&(this._childrenChange?(this._childrenChange=!1,this._updateSize(t)||this._initSize()):this._updateSize(t),p.fn.redraw.call(this,t))},_boundingBox:function(){var t,e,i,n,o=this.children;for(n=0;n<o.length;n++)e=o[n],e.visible()&&e._includeInBBox!==!1&&(i=e.drawingContainer().clippedBBox(null),i&&(t=t?H.Rect.union(t,i):i));return t}}),B(T.fn,f),A=T.extend({init:function(t,e){this.children=[],p.fn.init.call(this,e),this.drawingElement=new U.Layout(l(t),e),this._initSize()},rect:function(t){if(t)this.drawingElement.rect(l(t));else{var e=this.drawingElement.rect();if(e)return new L(e.origin.x,e.origin.y,e.size.width,e.size.height)}},reflow:function(){this.drawingElement.reflow()},redraw:function(t){M.deepExtend(this.drawingElement.options,t),T.fn.redraw.call(this,t)}}),P=g.extend({init:function(t){g.fn.init.call(this,t),this._initCircle(),this._initSize()},redraw:function(t){if(t){var e=this.options;t.center&&(B(e,{center:t.center}),this._center.move(e.center.x,e.center.y)),this._diffNumericOptions(t,["radius"])&&this._circle.setRadius(e.radius),this._updateSize(t),g.fn.redraw.call(this,t)}},_initCircle:function(){var t,e=this.options,i=e.width,n=e.height,o=e.radius;j(o)||(j(i)||(i=n),j(n)||(n=i),e.radius=o=Math.min(i,n)/2),t=e.center||{x:o,y:o},this._center=new H.Point(t.x,t.y),this._circle=new H.Circle(this._center,o),this.drawingElement=new U.Circle(this._circle,{stroke:e.stroke}),this._fill()}}),B(P.fn,f),D=I.extend({init:function(t,e){e=e||{},this.element=t,this.surface=U.Surface.create(t,e),M.isFunction(this.surface.translate)&&(this.translate=this._translate),this.drawingElement=new U.Group,this._viewBox=new L(0,0,e.width,e.height),this.size(this._viewBox)},bounds:function(){var t=this.drawingElement.clippedBBox();return new L(0,0,t.width(),t.height())},size:function(t){var e=this._viewBox;return j(t)&&(e.width=t.width,e.height=t.height,this.surface.setSize(t)),{width:e.width,height:e.height}},_translate:function(t,e){var i=this._viewBox;return j(t)&&j(e)&&(i.x=t,i.y=e,this.surface.translate({x:t,y:e})),{x:i.x,y:i.y}},draw:function(){this.surface.draw(this.drawingElement)},append:function(t){return this.drawingElement.append(t.drawingContainer()),this},remove:function(t){this.drawingElement.remove(t.drawingContainer())},insertBefore:function(){},clear:function(){this.drawingElement.clear()},destroy:function(e){this.surface.destroy(),e&&t(this.element).remove()}}),M.deepExtend(E,{init:function(t){M.init(t,E.ui)},diffNumericOptions:i,Element:p,Scale:c,Translation:h,Rotation:u,Circle:P,Group:T,Rectangle:v,Canvas:D,Path:b,Layout:A,Line:k,MarkerBase:_,ArrowMarker:w,CircleMarker:y,Polyline:C,CompositeTransform:d,TextBlock:m,Image:S,VisualBase:g})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/services.min",["kendo.drawing.min","dataviz/diagram/svg.min"],t)}(function(){!function(t,e){function i(t,e){return e.charCodeAt(0)==t||e.toUpperCase().charCodeAt(0)==t}function n(t,e){var i;return t.x==-1&&t.y==-1?i=e.bottomRight():1==t.x&&1==t.y?i=e.topLeft():t.x==-1&&1==t.y?i=e.topRight():1==t.x&&t.y==-1?i=e.bottomLeft():0===t.x&&t.y==-1?i=e.bottom():0===t.x&&1==t.y?i=e.top():1==t.x&&0===t.y?i=e.left():t.x==-1&&0===t.y&&(i=e.right()),i}function o(t){var e=t.options.editable;return e&&e.drag!==!1}function r(t,e){var i,n,o,r;for(r=0;r<t.connectors.length;r++)if(i=t.connectors[r],n=i.position(),o=new G(n.x,n.y),o.inflate(ot,ot),o.contains(e))return i}function s(t){return t.ctrlKey===!1&&t.altKey===!1&&t.shiftKey===!1}var a,l,c,h,u,d,f,p,g,m,v,_,y,w,x,b,k,C,S,T,A,P,D,M,E,I,B,z,L,R,O,V,F=window.kendo,N=F.dataviz,H=N.diagram,U=F.Class,j=H.Group,G=H.Rect,W=H.Rectangle,q=H.Utils,$=q.isUndefined,Y=H.Point,X=H.Circle,Q=H.Ticker,K=F.deepExtend,Z=F.ui.Movable,J=F.support.browser,tt=F.util.defined,et=t.inArray,it=t.proxy,nt={arrow:"default",grip:"pointer",cross:"pointer",add:"pointer",move:"move",select:"pointer",south:"s-resize",east:"e-resize",west:"w-resize",north:"n-resize",rowresize:"row-resize",colresize:"col-resize"},ot=10,rt="Auto",st="Top",at="Right",lt="Left",ct="Bottom",ht=10,ut=10,dt="dragStart",ft="drag",pt="dragEnd",gt="itemRotate",mt="itemBoundsChange",vt=5,_t=5,yt="mouseEnter",wt="mouseLeave",xt="zoomStart",bt="zoomEnd",kt=-2e4,Ct=2e4,St=.9,Tt=.93,At=5,Pt="transparent",Dt="pan",Mt="rotated",Et="source",It="target",Bt={"-1":Et,1:It};H.Cursors=nt,a=F.Class.extend({init:function(t){this.layoutState=t,this.diagram=t.diagram},initState:function(){function t(t,e){var i=this.diagram.getShapeById(t);i&&(this.subjects.push(i),this.froms.push(i.bounds().topLeft()),this.tos.push(e.topLeft()))}this.froms=[],this.tos=[],this.subjects=[],this.layoutState.nodeMap.forEach(t,this)},update:function(t){if(!(this.subjects.length<=0))for(var e=0;e<this.subjects.length;e++)this.subjects[e].position(new Y(this.froms[e].x+(this.tos[e].x-this.froms[e].x)*t,this.froms[e].y+(this.tos[e].y-this.froms[e].y)*t))}}),l=U.extend({init:function(t,e,i){this.animate=!$(i)&&i,this._initialState=t,this._finalState=e,this.title="Diagram layout"},undo:function(){this.setState(this._initialState)},redo:function(){this.setState(this._finalState)},setState:function(t){var e,i=t.diagram;this.animate?(t.linkMap.forEach(function(t,e){var n=i.getShapeById(t);n.visible(!1),n&&n.points(e)}),e=new Q,e.addAdapter(new a(t)),e.onComplete(function(){t.linkMap.forEach(function(t){var e=i.getShapeById(t);e.visible(!0)})}),e.play()):(t.nodeMap.forEach(function(t,e){var n=i.getShapeById(t);n&&n.position(e.topLeft())}),t.linkMap.forEach(function(t,e){var n=i.getShapeById(t);n&&n.points(e)}))}}),c=U.extend({init:function(t){this.units=[],this.title="Composite unit",t!==e&&this.units.push(t)},add:function(t){this.units.push(t)},undo:function(){for(var t=0;t<this.units.length;t++)this.units[t].undo()},redo:function(){for(var t=0;t<this.units.length;t++)this.units[t].redo()}}),h=U.extend({init:function(t,e,i){this.item=t,
this._redoSource=e,this._redoTarget=i,tt(e)&&(this._undoSource=t.source()),tt(i)&&(this._undoTarget=t.target()),this.title="Connection Editing"},undo:function(){this._undoSource!==e&&this.item._updateConnector(this._undoSource,"source"),this._undoTarget!==e&&this.item._updateConnector(this._undoTarget,"target"),this.item.updateModel()},redo:function(){this._redoSource!==e&&this.item._updateConnector(this._redoSource,"source"),this._redoTarget!==e&&this.item._updateConnector(this._redoTarget,"target"),this.item.updateModel()}}),u=U.extend({init:function(t,e,i){this.item=t,this._undoSource=e,this._undoTarget=i,this._redoSource=t.source(),this._redoTarget=t.target(),this.title="Connection Editing"},undo:function(){this.item._updateConnector(this._undoSource,"source"),this.item._updateConnector(this._undoTarget,"target"),this.item.updateModel()},redo:function(){this.item._updateConnector(this._redoSource,"source"),this.item._updateConnector(this._redoTarget,"target"),this.item.updateModel()}}),d=U.extend({init:function(t){this.connection=t,this.diagram=t.diagram,this.targetConnector=t.targetConnector,this.title="Delete connection"},undo:function(){this.diagram._addConnection(this.connection,!1)},redo:function(){this.diagram.remove(this.connection,!1)}}),f=U.extend({init:function(t){this.shape=t,this.diagram=t.diagram,this.title="Deletion"},undo:function(){this.diagram._addShape(this.shape,!1),this.shape.select(!1)},redo:function(){this.shape.select(!1),this.diagram.remove(this.shape,!1)}}),p=U.extend({init:function(t,e,i){var n,o;for(this.shapes=t,this.undoStates=e,this.title="Transformation",this.redoStates=[],this.adorner=i,n=0;n<this.shapes.length;n++)o=this.shapes[n],this.redoStates.push(o.bounds())},undo:function(){var t,e;for(t=0;t<this.shapes.length;t++)e=this.shapes[t],e.bounds(this.undoStates[t]),e.hasOwnProperty("layout")&&e.layout(e,this.redoStates[t],this.undoStates[t]),e.updateModel();this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())},redo:function(){var t,e;for(t=0;t<this.shapes.length;t++)e=this.shapes[t],e.bounds(this.redoStates[t]),e.hasOwnProperty("layout")&&e.layout(e,this.undoStates[t],this.redoStates[t]),e.updateModel();this.adorner&&(this.adorner.refreshBounds(),this.adorner.refresh())}}),g=U.extend({init:function(t,e){this.connection=t,this.diagram=e,this.title="New connection"},undo:function(){this.diagram.remove(this.connection,!1)},redo:function(){this.diagram._addConnection(this.connection,!1)}}),m=U.extend({init:function(t,e){this.shape=t,this.diagram=e,this.title="New shape"},undo:function(){this.diagram.deselect(),this.diagram.remove(this.shape,!1)},redo:function(){this.diagram._addShape(this.shape,!1)}}),v=U.extend({init:function(t,e,i){this.initial=t,this.finalPos=e,this.diagram=i,this.title="Pan Unit"},undo:function(){this.diagram.pan(this.initial)},redo:function(){this.diagram.pan(this.finalPos)}}),_=U.extend({init:function(t,e,i){var n,o;for(this.shapes=e,this.undoRotates=i,this.title="Rotation",this.redoRotates=[],this.redoAngle=t._angle,this.adorner=t,this.center=t._innerBounds.center(),n=0;n<this.shapes.length;n++)o=this.shapes[n],this.redoRotates.push(o.rotate().angle)},undo:function(){var t,e;for(t=0;t<this.shapes.length;t++)e=this.shapes[t],e.rotate(this.undoRotates[t],this.center,!1),e.hasOwnProperty("layout")&&e.layout(e),e.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())},redo:function(){var t,e;for(t=0;t<this.shapes.length;t++)e=this.shapes[t],e.rotate(this.redoRotates[t],this.center,!1),e.hasOwnProperty("layout")&&e.layout(e),e.updateModel();this.adorner&&(this.adorner._initialize(),this.adorner.refresh())}}),y=U.extend({init:function(t,e,i){this.diagram=t,this.indices=i,this.items=e,this.title="Rotate Unit"},undo:function(){this.diagram._toIndex(this.items,this.indices)},redo:function(){this.diagram.toFront(this.items,!1)}}),w=U.extend({init:function(t,e,i){this.diagram=t,this.indices=i,this.items=e,this.title="Rotate Unit"},undo:function(){this.diagram._toIndex(this.items,this.indices)},redo:function(){this.diagram.toBack(this.items,!1)}}),x=F.Observable.extend({init:function(t){F.Observable.fn.init.call(this,t),this.bind(this.events,t),this.stack=[],this.index=0,this.capacity=100},events:["undone","redone"],begin:function(){this.composite=new c},cancel:function(){this.composite=e},commit:function(t){this.composite.units.length>0&&this._restart(this.composite,t),this.composite=e},addCompositeItem:function(t){this.composite?this.composite.add(t):this.add(t)},add:function(t,e){this._restart(t,e)},pop:function(){this.index>0&&(this.stack.pop(),this.index--)},count:function(){return this.stack.length},undo:function(){this.index>0&&(this.index--,this.stack[this.index].undo(),this.trigger("undone"))},redo:function(){this.stack.length>0&&this.index<this.stack.length&&(this.stack[this.index].redo(),this.index++,this.trigger("redone"))},_restart:function(t,e){this.stack.splice(this.index,this.stack.length-this.index),this.stack.push(t),e!==!1?this.redo():this.index++,this.stack.length>this.capacity&&(this.stack.splice(0,this.stack.length-this.capacity),this.index=this.capacity)},clear:function(){this.stack=[],this.index=0}}),b=U.extend({init:function(t){this.toolService=t},start:function(){},move:function(){},end:function(){},tryActivate:function(){return!1},getCursor:function(){return nt.arrow}}),k=b.extend({init:function(e){var i,n,o,r,s=this,a=F.support.mobileOS?Tt:St;b.fn.init.call(s,e),i=s.toolService.diagram,n=i.canvas,o=i.scroller=s.scroller=t(i.scrollable).kendoMobileScroller({friction:a,velocityMultiplier:At,mousewheelScrolling:!1,zoom:!1,scroll:it(s._move,s)}).data("kendoMobileScroller"),n.translate&&(s.movableCanvas=new Z(n.element)),r=function(t,e,i){t.makeVirtual(),t.virtualSize(e||kt,i||Ct)},r(o.dimensions.x),r(o.dimensions.y),o.disable()},tryActivate:function(t,e){var i=this.toolService,n=i.diagram.options.pannable,o=e.ctrlKey;return tt(n.key)&&(o=n.key&&"none"!=n.key?e[n.key+"Key"]:s(e)&&!tt(i.hoveredItem)),n!==!1&&o&&!tt(i.hoveredAdorner)&&!tt(i._hoveredConnector)},start:function(){this.scroller.enable()},move:function(){},_move:function(t){var e=this,i=e.toolService.diagram,n=i.canvas,o=new Y(t.scrollLeft,t.scrollTop);n.translate?(i._storePan(o.times(-1)),e.movableCanvas.moveTo(o),n.translate(o.x,o.y)):o=o.plus(i._pan.times(-1)),i.trigger(Dt,{pan:o})},end:function(){this.scroller.disable()},getCursor:function(){return nt.move}}),C=U.extend({init:function(t){this.toolService=t},tryActivate:function(){return!0},start:function(t,e){var i=this.toolService,n=i.diagram,o=i.hoveredItem;o&&(i.selectSingle(o,e),o.adorner&&(this.adorner=o.adorner,this.handle=this.adorner._hitTest(t))),this.handle||(this.handle=n._resizingAdorner._hitTest(t),this.handle&&(this.adorner=n._resizingAdorner)),this.adorner&&(this.adorner.isDragHandle(this.handle)&&n.trigger(dt,{shapes:this.adorner.shapes,connections:[]})?(i.startPoint=t,i.end(t)):this.adorner.start(t))},move:function(t){this.adorner&&(this.adorner.move(this.handle,t),this.adorner.isDragHandle(this.handle)&&this.toolService.diagram.trigger(ft,{shapes:this.adorner.shapes,connections:[]}))},end:function(){var t,i=this.toolService.diagram,n=this.adorner;n&&(n.isDragHandle(this.handle)&&i.trigger(pt,{shapes:n.shapes,connections:[]})?n.cancel():(t=n.stop(),t&&i.undoRedoService.add(t,!1))),this.adorner=e,this.handle=e},getCursor:function(t){return this.toolService.hoveredItem?this.toolService.hoveredItem._getCursor(t):nt.arrow}}),S=U.extend({init:function(t){this.toolService=t},tryActivate:function(t,e){var i=this.toolService,n=i.diagram.options.selectable,o=n&&n.multiple!==!1;return o&&(o=n.key&&"none"!=n.key?e[n.key+"Key"]:s(e)),o&&!tt(i.hoveredItem)&&!tt(i.hoveredAdorner)},start:function(t){var e=this.toolService.diagram;e.deselect(),e.selector.start(t)},move:function(t){var e=this.toolService.diagram;e.selector.move(t)},end:function(t,e){var i=this.toolService.diagram,n=this.toolService.hoveredItem,o=i.selector.bounds();n&&n.isSelected||e.ctrlKey||i.deselect(),o.isEmpty()||i.selectArea(o),i.selector.end()},getCursor:function(){return nt.arrow}}),T=U.extend({init:function(t){this.toolService=t,this.type="ConnectionTool"},tryActivate:function(){return this.toolService._hoveredConnector},start:function(t,e){var i=this.toolService,n=i.diagram,r=i._hoveredConnector,s=n._createConnection({},r._c,t);o(s)&&!n.trigger(dt,{shapes:[],connections:[s],connectionHandle:It})&&n._addConnection(s)?(i._connectionManipulation(s,r._c.shape,!0),i._removeHover(),i.selectSingle(i.activeConnection,e),"touchmove"==e.type&&(n._cachedTouchTarget=r.visual)):(s.source(null),i.end(t))},move:function(t){var e=this.toolService,i=e.activeConnection;return i.target(t),e.diagram.trigger(ft,{shapes:[],connections:[i],connectionHandle:It}),!0},end:function(t){var e,i=this.toolService,n=i.diagram,o=i.activeConnection,r=i.hoveredItem,s=i._hoveredConnector,a=n._cachedTouchTarget;o&&(e=s&&s._c!=o.sourceConnector?s._c:r&&r instanceof H.Shape?r.getConnector(rt)||r.getConnector(t):t,o.target(e),n.trigger(pt,{shapes:[],connections:[o],connectionHandle:It})?(n.remove(o,!1),n.undoRedoService.pop()):(o.updateModel(),n._syncConnectionChanges()),i._connectionManipulation(),a&&(n._connectorsAdorner.visual.remove(a),n._cachedTouchTarget=null))},getCursor:function(){return nt.arrow}}),A=U.extend({init:function(t){this.toolService=t,this.type="ConnectionTool"},tryActivate:function(t,e){var i=this.toolService,n=i.diagram,o=n.options.selectable,r=i.hoveredItem,s=o!==!1&&r&&r.path&&!(r.isSelected&&e.ctrlKey);return s&&(this._c=r),s},start:function(t,e){var i,n,r,s=this.toolService,a=this._c;s.selectSingle(a,e),i=a.adorner,i&&(n=i._hitTest(t),r=Bt[n]),o(a)&&i&&!s.diagram.trigger(dt,{shapes:[],connections:[a],connectionHandle:r})?(this.handle=n,this.handleName=r,i.start(t)):(s.startPoint=t,s.end(t))},move:function(t){var e=this._c.adorner;if(o(this._c)&&e)return e.move(this.handle,t),this.toolService.diagram.trigger(ft,{shapes:[],connections:[this._c],connectionHandle:this.handleName}),!0},end:function(t){var e,i=this._c,n=i.adorner,r=this.toolService,s=r.diagram;n&&o(i)&&(e=n.stop(t),s.trigger(pt,{shapes:[],connections:[i],connectionHandle:this.handleName})?e.undo():(s.undoRedoService.add(e,!1),i.updateModel(),s._syncConnectionChanges()))},getCursor:function(){return nt.move}}),P=U.extend({init:function(t){this.diagram=t,this.tools=[new k(this),new A(this),new T(this),new S(this),new C(this)],this.activeTool=e},start:function(t,e){return e=K({},e),this.activeTool&&this.activeTool.end(t,e),this._updateHoveredItem(t),this._activateTool(t,e),this.activeTool.start(t,e),this._updateCursor(t),this.diagram.focus(),this.diagram.canvas.surface.suspendTracking(),this.startPoint=t,!0},move:function(t,e){e=K({},e);var i=!0;return this.activeTool&&(i=this.activeTool.move(t,e)),i&&this._updateHoveredItem(t),this._updateCursor(t),!0},end:function(t,i){return i=K({},i),this.activeTool&&this.activeTool.end(t,i),this.diagram.canvas.surface.resumeTracking(),this.activeTool=e,this._updateCursor(t),!0},keyDown:function(t,e){var n,o=this.diagram;if(e=K({ctrlKey:!1,metaKey:!1,altKey:!1},e),!e.ctrlKey&&!e.metaKey||e.altKey){if(46===t||8===t)return n=this.diagram._triggerRemove(o.select()),n.length&&(this.diagram.remove(n,!0),this.diagram._syncChanges(),this.diagram._destroyToolBar()),!0;if(27===t)return this._discardNewConnection(),o.deselect(),o._destroyToolBar(),!0}else{if(i(t,"a"))return o.selectAll(),o._destroyToolBar(),!0;if(i(t,"z"))return o.undo(),o._destroyToolBar(),!0;if(i(t,"y"))return o.redo(),o._destroyToolBar(),!0;i(t,"c")?(o.copy(),o._destroyToolBar()):i(t,"x")?(o.cut(),o._destroyToolBar()):i(t,"v")?(o.paste(),o._destroyToolBar()):i(t,"l")?(o.layout(),o._destroyToolBar()):i(t,"d")&&(o._destroyToolBar(),o.copy(),o.paste())}},wheel:function(t,e){var i=this.diagram,n=e.delta,o=i.zoom(),r=i.options,s=r.zoomRate,a={point:t,meta:e,zoom:o};if(!i.trigger(xt,a))return n<0?o+=s:o-=s,o=F.dataviz.round(Math.max(r.zoomMin,Math.min(r.zoomMax,o)),2),a.zoom=o,i.zoom(o,a),i.trigger(bt,a),!0},setTool:function(t,e){t.toolService=this,this.tools[e]=t},selectSingle:function(t,e){var i,n=this.diagram,o=n.options.selectable;o&&!t.isSelected&&t.options.selectable!==!1&&(i=e.ctrlKey&&o.multiple!==!1,n.select(t,{addToSelection:i}))},_discardNewConnection:function(){this.newConnection&&(this.diagram.remove(this.newConnection),this.newConnection=e)},_activateTool:function(t,e){var i,n;for(i=0;i<this.tools.length;i++)if(n=this.tools[i],n.tryActivate(t,e)){this.activeTool=n;break}},_updateCursor:function(t){var e=this.diagram.element,i=this.activeTool?this.activeTool.getCursor(t):this.hoveredAdorner?this.hoveredAdorner._getCursor(t):this.hoveredItem?this.hoveredItem._getCursor(t):nt.arrow;e.css({cursor:i}),J.msie&&7==J.version&&(e[0].style.cssText=e[0].style.cssText)},_connectionManipulation:function(t,i,n){this.activeConnection=t,this.disabledShape=i,this.newConnection=n?this.activeConnection:e},_updateHoveredItem:function(t){var i=this._hitTest(t),n=this.diagram;i==this.hoveredItem||this.disabledShape&&i==this.disabledShape||(this.hoveredItem&&(n.trigger(wt,{item:this.hoveredItem}),this.hoveredItem._hover(!1)),i&&i.options.enable?(n.trigger(yt,{item:i}),this.hoveredItem=i,this.hoveredItem._hover(!0)):this.hoveredItem=e)},_removeHover:function(){this.hoveredItem&&(this.hoveredItem._hover(!1),this.hoveredItem=e)},_hitTest:function(t){var i,n,o,r,s=this.diagram;if(this._hoveredConnector&&(this._hoveredConnector._hover(!1),this._hoveredConnector=e),s._connectorsAdorner._visible&&(i=s._connectorsAdorner._hitTest(t)))return i;if(i=this.diagram._resizingAdorner._hitTest(t)){if(this.hoveredAdorner=s._resizingAdorner,0!==i.x||0!==i.y)return;i=e}else this.hoveredAdorner=e;if(!this.activeTool||"ConnectionTool"!==this.activeTool.type){for(r=[],o=0;o<s._selectedItems.length;o++)n=s._selectedItems[o],n instanceof H.Connection&&r.push(n);i=this._hitTestItems(r,t)}return i||this._hitTestElements(t)},_hitTestElements:function(t){var e,i,n,o,s=this.diagram,a=this._hitTestItems(s.shapes,t),l=this._hitTestItems(s.connections,t);return this.activeTool&&"ConnectionTool"==this.activeTool.type||!a||!l||r(a,t)||(i=s.mainLayer,n=et(a.visual,i.children),o=et(l.visual,i.children),e=n>o?a:l),e||a||l},_hitTestItems:function(t,e){var i,n,o;for(i=t.length-1;i>=0;i--)if(n=t[i],o=n._hitTest(e))return o}}),D=F.Class.extend({init:function(){}}),M=D.extend({init:function(t){var e=this;D.fn.init.call(e),this.connection=t},hitTest:function(t){var e=this.getBounds().inflate(ot);return!!e.contains(t)&&H.Geometry.distanceToPolyline(t,this.connection.allPoints())<ot},getBounds:function(){var t,e=this.connection.allPoints(),i=e[0],n=e[e.length-1],o=Math.max(i.x,n.x),r=Math.min(i.x,n.x),s=Math.min(i.y,n.y),a=Math.max(i.y,n.y);for(t=1;t<e.length-1;++t)o=Math.max(o,e[t].x),r=Math.min(r,e[t].x),s=Math.min(s,e[t].y),a=Math.max(a,e[t].y);return new G(r,s,o-r,a-s)}}),E=M.extend({init:function(t){var e=this;M.fn.init.call(e),this.connection=t},route:function(){}}),I=M.extend({SAME_SIDE_DISTANCE_RATIO:5,init:function(t){var e=this;M.fn.init.call(e),this.connection=t},routePoints:function(t,e,i,n){var o;return o=i&&n?this._connectorPoints(t,e,i,n):this._floatingPoints(t,e,i)},route:function(){var t=this.connection._resolvedSourceConnector,e=this.connection._resolvedTargetConnector,i=this.connection.sourcePoint(),n=this.connection.targetPoint(),o=this.routePoints(i,n,t,e);this.connection.points(o)},_connectorSides:[{name:"Top",axis:"y",boundsPoint:"topLeft",secondarySign:1},{name:"Left",axis:"x",boundsPoint:"topLeft",secondarySign:1},{name:"Bottom",axis:"y",boundsPoint:"bottomRight",secondarySign:-1},{name:"Right",axis:"x",boundsPoint:"bottomRight",secondarySign:-1}],_connectorSide:function(t,e){var i,n,o,r,s,a=t.position(),l=t.shape.bounds(Mt),c={topLeft:l.topLeft(),bottomRight:l.bottomRight()},h=this._connectorSides,u=F.util.MAX_NUM;for(s=0;s<h.length;s++)r=h[s],o=r.axis,i=Math.round(Math.abs(a[o]-c[r.boundsPoint][o])),i<u?(u=i,n=r):i===u&&(a[o]-e[o])*r.secondarySign>(a[n.axis]-e[n.axis])*n.secondarySign&&(n=r);return n.name},_sameSideDistance:function(t){var e=t.shape.bounds(Mt);return Math.min(e.width,e.height)/this.SAME_SIDE_DISTANCE_RATIO},_connectorPoints:function(t,e,i,n){var o,r,s=this._connectorSide(i,e),a=this._connectorSide(n,t),l=e.x-t.x,c=e.y-t.y,h=this._sameSideDistance(i),u=[];return s===st||s==ct?a==st||a==ct?s==a?(r=s==st?Math.min(t.y,e.y)-h:Math.max(t.y,e.y)+h,u=[new Y(t.x,r),new Y(e.x,r)]):u=[new Y(t.x,t.y+c/2),new Y(e.x,t.y+c/2)]:u=[new Y(t.x,e.y)]:a==lt||a==at?s==a?(o=s==lt?Math.min(t.x,e.x)-h:Math.max(t.x,e.x)+h,u=[new Y(o,t.y),new Y(o,e.y)]):u=[new Y(t.x+l/2,t.y),new Y(t.x+l/2,t.y+c)]:u=[new Y(e.x,t.y)],u},_floatingPoints:function(t,e,i){var n,o,r,s=i?this._connectorSide(i,e):null,a=this._startHorizontal(t,e,s),l=[t,t,e,e],c=e.x-t.x,h=e.y-t.y,u=l.length;for(r=1;r<u-1;++r)a?r%2!==0?(n=c/(u/2),o=0):(n=0,o=h/((u-1)/2)):r%2!==0?(n=0,o=h/(u/2)):(n=c/((u-1)/2),o=0),l[r]=new Y(l[r-1].x+n,l[r-1].y+o);return r--,l[u-2]=a&&r%2!==0||!a&&r%2===0?new Y(l[u-1].x,l[u-2].y):new Y(l[u-2].x,l[u-1].y),[l[1],l[2]]},_startHorizontal:function(t,e,i){var n;return n=null!==i&&(i===at||i===lt)||Math.abs(t.x-e.x)>Math.abs(t.y-e.y)}}),B=U.extend({init:function(t,e){var i=this;i.diagram=t,i.options=K({},i.options,e),i.visual=new j,i.diagram._adorners.push(i)},refresh:function(){}}),z=B.extend({init:function(t,e){var i,n,o,r=this;r.connection=t,i=r.connection.diagram,r._ts=i.toolService,B.fn.init.call(r,i,e),n=r.connection.sourcePoint(),o=r.connection.targetPoint(),r.spVisual=new X(K(r.options.handles,{center:n})),r.epVisual=new X(K(r.options.handles,{center:o})),r.visual.append(r.spVisual),r.visual.append(r.epVisual)},options:{handles:{}},_getCursor:function(){return nt.move},start:function(t){switch(this.handle=this._hitTest(t),this.startPoint=t,this._initialSource=this.connection.source(),this._initialTarget=this.connection.target(),this.handle){case-1:this.connection.targetConnector&&this._ts._connectionManipulation(this.connection,this.connection.targetConnector.shape);break;case 1:this.connection.sourceConnector&&this._ts._connectionManipulation(this.connection,this.connection.sourceConnector.shape)}},move:function(t,e){switch(t){case-1:this.connection.source(e);break;case 1:this.connection.target(e);break;default:var i=e.minus(this.startPoint);this.startPoint=e,this.connection.sourceConnector||this.connection.source(this.connection.sourcePoint().plus(i)),this.connection.targetConnector||this.connection.target(this.connection.targetPoint().plus(i))}return this.refresh(),!0},stop:function(t){var i,n=this.diagram.toolService,o=n.hoveredItem;return i=n._hoveredConnector?n._hoveredConnector._c:o&&o instanceof H.Shape?o.getConnector(rt)||o.getConnector(t):t,this.handle===-1?this.connection.source(i):1===this.handle&&this.connection.target(i),this.handle=e,this._ts._connectionManipulation(),new u(this.connection,this._initialSource,this._initialTarget)},_hitTest:function(t){var e=this.connection.sourcePoint(),i=this.connection.targetPoint(),n=this.options.handles.width/2+ot,o=this.options.handles.height/2+ot,r=e.distanceTo(t),s=i.distanceTo(t),a=new G(e.x,e.y).inflate(n,o).contains(t),l=new G(i.x,i.y).inflate(n,o).contains(t),c=0;return a&&(!l||r<s)?c=-1:l&&(!a||s<r)&&(c=1),c},refresh:function(){this.spVisual.redraw({center:this.diagram.modelToLayer(this.connection.sourcePoint())}),this.epVisual.redraw({center:this.diagram.modelToLayer(this.connection.targetPoint())})}}),L=B.extend({init:function(t,e){var i=this;B.fn.init.call(i,t,e),i._refreshHandler=function(t){t.item==i.shape&&i.refresh()}},show:function(t){var e,i,n,o=this;for(o._visible=!0,o.shape=t,o.diagram.bind(mt,o._refreshHandler),e=t.connectors.length,o.connectors=[],o._clearVisual(),i=0;i<e;i++)n=new V(t.connectors[i]),o.connectors.push(n),o.visual.append(n.visual);o.visual.visible(!0),o.refresh()},_clearVisual:function(){var t=this;t.diagram._cachedTouchTarget?t._keepCachedTouchTarget():t.visual.clear()},_keepCachedTouchTarget:function(){var t,e=this,i=e.visual.children,n=i.length,o=et(e.diagram._cachedTouchTarget,i);for(t=n-1;t>=0;t--)t!=o&&e.visual.remove(i[t])},destroy:function(){var t=this;t.diagram.unbind(mt,t._refreshHandler),t.shape=e,t._visible=e,t.visual.visible(!1)},_hitTest:function(t){var e,i;for(i=0;i<this.connectors.length;i++)if(e=this.connectors[i],e._hitTest(t)){e._hover(!0),this.diagram.toolService._hoveredConnector=e;break}},refresh:function(){if(this.shape){var e=this.shape.bounds();e=this.diagram.modelToLayer(e),this.visual.position(e.topLeft()),t.each(this.connectors,function(){this.refresh()})}}}),R=B.extend({init:function(t,e){var i=this;B.fn.init.call(i,t,e),i._manipulating=!1,i.map=[],i.shapes=[],i._initSelection(),i._createHandles(),i.redraw(),i.diagram.bind("select",function(t){i._initialize(t.selected)}),i._refreshHandler=function(){i._internalChange||(i.refreshBounds(),i.refresh())},i._rotatedHandler=function(){1==i.shapes.length&&(i._angle=i.shapes[0].rotate().angle),i._refreshHandler()},i.diagram.bind(mt,i._refreshHandler).bind(gt,i._rotatedHandler),i.refreshBounds(),i.refresh()},options:{handles:{fill:{color:"#fff"},stroke:{color:"#282828"},height:7,width:7,hover:{fill:{color:"#282828"},stroke:{color:"#282828"}}},selectable:{stroke:{color:"#778899",width:1,dashType:"dash"},fill:{color:Pt}},offset:10},_initSelection:function(){var t=this,e=t.diagram,i=e.options.selectable,n=K({},t.options.selectable,i);t.rect=new W(n),t.visual.append(t.rect)},_resizable:function(){return this.options.editable&&this.options.editable.resize!==!1},_handleOptions:function(){return(this.options.editable.resize||{}).handles||this.options.handles},_createHandles:function(){var t,e,i,n;if(this._resizable())for(t=this._handleOptions(),n=-1;n<=1;n++)for(i=-1;i<=1;i++)0===n&&0===i||(e=new W(t),e.drawingElement._hover=it(this._hover,this),this.map.push({x:n,y:i,visual:e}),this.visual.append(e))},bounds:function(t){return t?(this._innerBounds=t.clone(),this._bounds=this.diagram.modelToLayer(t).inflate(this.options.offset,this.options.offset),e):this._bounds},_hitTest:function(t){var e,i,n,o,r=this.diagram.modelToLayer(t),s=this.map.length;if(this._angle&&(r=r.clone().rotate(this._bounds.center(),this._angle)),this._resizable())for(e=0;e<s;e++)if(o=this.map[e],i=new Y(o.x,o.y),n=this._getHandleBounds(i),n.offset(this._bounds.x,this._bounds.y),n.contains(r))return i;if(this._bounds.contains(r))return new Y(0,0)},_getHandleBounds:function(t){if(this._resizable()){var e=this._handleOptions(),i=e.width,n=e.height,o=new G(0,0,i,n);return t.x<0?o.x=-i/2:0===t.x?o.x=Math.floor(this._bounds.width/2)-i/2:t.x>0&&(o.x=this._bounds.width+1-i/2),t.y<0?o.y=-n/2:0===t.y?o.y=Math.floor(this._bounds.height/2)-n/2:t.y>0&&(o.y=this._bounds.height+1-n/2),o}},_getCursor:function(t){var e,i=this._hitTest(t);if(i&&i.x>=-1&&i.x<=1&&i.y>=-1&&i.y<=1&&this._resizable()){if(e=this._angle,e&&(e=360-e,i.rotate(new Y(0,0),e),i=new Y(Math.round(i.x),Math.round(i.y))),i.x==-1&&i.y==-1)return"nw-resize";if(1==i.x&&1==i.y)return"se-resize";if(i.x==-1&&1==i.y)return"sw-resize";if(1==i.x&&i.y==-1)return"ne-resize";if(0===i.x&&i.y==-1)return"n-resize";if(0===i.x&&1==i.y)return"s-resize";if(1==i.x&&0===i.y)return"e-resize";if(i.x==-1&&0===i.y)return"w-resize"}return this._manipulating?nt.move:nt.select},_initialize:function(){var t,e,i=this,n=i.diagram.select();for(i.shapes=[],t=0;t<n.length;t++)e=n[t],e instanceof H.Shape&&(i.shapes.push(e),e._rotationOffset=new Y);i._angle=1==i.shapes.length?i.shapes[0].rotate().angle:0,i._startAngle=i._angle,i._rotates(),i._positions(),i.refreshBounds(),i.refresh(),i.redraw()},_rotates:function(){var t,e,i=this;for(i.initialRotates=[],t=0;t<i.shapes.length;t++)e=i.shapes[t],i.initialRotates.push(e.rotate().angle)},_positions:function(){var t,e,i=this;for(i.initialStates=[],t=0;t<i.shapes.length;t++)e=i.shapes[t],i.initialStates.push(e.bounds())},_hover:function(t,e){if(this._resizable()){var i=this._handleOptions(),n=i.hover,o=i.stroke,r=i.fill;t&&q.isDefined(n.stroke)&&(o=K({},o,n.stroke)),t&&q.isDefined(n.fill)&&(r=n.fill),e.stroke(o.color,o.width,o.opacity),e.fill(r.color,r.opacity)}},start:function(t){var e,i;for(this._sp=t,this._cp=t,this._lp=t,this._manipulating=!0,this._internalChange=!0,this.shapeStates=[],e=0;e<this.shapes.length;e++)i=this.shapes[e],this.shapeStates.push(i.bounds())},redraw:function(){var t,e,i=this._resizable();for(t=0;t<this.map.length;t++)e=this.map[t],e.visual.visible(i)},angle:function(t){return tt(t)&&(this._angle=t),this._angle},rotate:function(){var t,e,i=this._innerBounds.center(),n=this.angle();for(this._internalChange=!0,t=0;t<this.shapes.length;t++)e=this.shapes[t],n=(n+this.initialRotates[t]-this._startAngle)%360,e.rotate(n,i);this.refresh()},move:function(t,i){var r,s,a,l,c,h,u,d,f,p,g,m,v,_,y=new Y,w=new Y,x=0;if(t.y===-2&&t.x===-1){for(l=this._innerBounds.center(),this._angle=this._truncateAngle(q.findAngle(l,i)),h=0;h<this.shapes.length;h++)c=this.shapes[h],u=(this._angle+this.initialRotates[h]-this._startAngle)%360,c.rotate(u,l),c.hasOwnProperty("layout")&&c.layout(c),this._rotating=!0;this.refresh()}else{if(this.shouldSnap()){if(m=this._truncateDistance(i.minus(this._lp)),0===m.x&&0===m.y)return this._cp=i,e;r=m,this._lp=new Y(this._lp.x+m.x,this._lp.y+m.y)}else r=i.minus(this._cp);for(this.isDragHandle(t)?(w=y=r,s=!0):(this._angle&&r.rotate(new Y(0,0),this._angle),t.x==-1?y.x=r.x:1==t.x&&(w.x=r.x),t.y==-1?y.y=r.y:1==t.y&&(w.y=r.y)),s||(f=n(t,this._innerBounds),p=(this._innerBounds.width+r.x*t.x)/this._innerBounds.width,g=(this._innerBounds.height+r.y*t.y)/this._innerBounds.height),h=0;h<this.shapes.length;h++){if(c=this.shapes[h],a=c.bounds(),s){if(!o(c))continue;d=this._displaceBounds(a,y,w,s)}else d=a.clone(),d.scale(p,g,f,this._innerBounds.center(),c.rotate().angle),v=d.center(),v.rotate(a.center(),-this._angle),d=new G(v.x-d.width/2,v.y-d.height/2,d.width,d.height);d.width>=c.options.minWidth&&d.height>=c.options.minHeight&&(_=a,c.bounds(d),c.hasOwnProperty("layout")&&c.layout(c,_,d),_.width===d.width&&_.height===d.height||c.rotate(c.rotate().angle),x+=1)}x&&(x==h?(d=this._displaceBounds(this._innerBounds,y,w,s),this.bounds(d)):this.refreshBounds(),this.refresh()),this._positions()}this._cp=i},isDragHandle:function(t){return 0===t.x&&0===t.y},cancel:function(){var t,i=this.shapes,n=this.shapeStates;for(t=0;t<i.length;t++)i[t].bounds(n[t]);this.refreshBounds(),this.refresh(),this._manipulating=e,this._internalChange=e,this._rotating=e},_truncatePositionToGuides:function(t){return this.diagram.ruler?this.diagram.ruler.truncatePositionToGuides(t):t},_truncateSizeToGuides:function(t){return this.diagram.ruler?this.diagram.ruler.truncateSizeToGuides(t):t},_truncateAngle:function(t){var e=this.snapOptions(),i=Math.max(e.angle||ut,_t);return e?Math.floor(t%360/i)*i:t%360},_truncateDistance:function(t){var e,i;return t instanceof H.Point?new H.Point(this._truncateDistance(t.x),this._truncateDistance(t.y)):(e=this.snapOptions()||{},i=Math.max(e.size||ht,vt),e?Math.floor(t/i)*i:t)},snapOptions:function(){var t=this.diagram.options.editable,e=((t||{}).drag||{}).snap||{};return e},shouldSnap:function(){var t=this.diagram.options.editable,e=(t||{}).drag,i=(e||{}).snap;return t!==!1&&e!==!1&&i!==!1},_displaceBounds:function(t,e,i,n){var o,r=t.topLeft().plus(e),s=t.bottomRight().plus(i),a=G.fromPoints(r,s);return n||(o=a.center(),o.rotate(t.center(),-this._angle),a=new G(o.x-a.width/2,o.y-a.height/2,a.width,a.height)),a},stop:function(){var t,i,n,o;if(this._cp!=this._sp)if(this._rotating)t=new _(this,this.shapes,this.initialRotates),this._rotating=!1;else if(this._diffStates()){if(this.diagram.ruler)for(i=0;i<this.shapes.length;i++)n=this.shapes[i],o=n.bounds(),o=this._truncateSizeToGuides(this._truncatePositionToGuides(o)),n.bounds(o),this.refreshBounds(),this.refresh();for(i=0;i<this.shapes.length;i++)n=this.shapes[i],n.updateModel();t=new p(this.shapes,this.shapeStates,this),this.diagram._syncShapeChanges()}return this._manipulating=e,this._internalChange=e,this._rotating=e,t},_diffStates:function(){var t,e=this.shapes,i=this.shapeStates;for(t=0;t<e.length;t++)if(!e[t].bounds().equals(i[t]))return!0;return!1},refreshBounds:function(){var t=1==this.shapes.length?this.shapes[0].bounds().clone():this.diagram.boundingBox(this.shapes,!0);this.bounds(t)},refresh:function(){var e,i,n,o,r=this;this.shapes.length>0?(i=this.bounds(),this.visual.visible(!0),this.visual.position(i.topLeft()),t.each(this.map,function(){e=r._getHandleBounds(new Y(this.x,this.y)),this.visual.position(e.topLeft())}),this.visual.position(i.topLeft()),n=new Y(i.width/2,i.height/2),this.visual.rotate(this._angle,n),this.rect.redraw({width:i.width,height:i.height}),this.rotationThumb&&(o=this.options.editable.rotate.thumb,this._rotationThumbBounds=new G(i.center().x,i.y+o.y,0,0).inflate(o.width),this.rotationThumb.redraw({x:i.width/2-o.width/2}))):this.visual.visible(!1)}}),O=U.extend({init:function(t){var e=t.options.selectable;this.options=K({},this.options,e),this.visual=new W(this.options),this.diagram=t},options:{stroke:{color:"#778899",width:1,dashType:"dash"},fill:{color:Pt}},start:function(t){this._sp=this._ep=t,this.refresh(),this.diagram._adorn(this,!0)},end:function(){this._sp=this._ep=e,this.diagram._adorn(this,!1)},bounds:function(t){return t&&(this._bounds=t),this._bounds},move:function(t){this._ep=t,this.refresh()},refresh:function(){if(this._sp){var t=G.fromPoints(this.diagram.modelToLayer(this._sp),this.diagram.modelToLayer(this._ep));this.bounds(G.fromPoints(this._sp,this._ep)),this.visual.position(t.topLeft()),this.visual.redraw({height:t.height+1,width:t.width+1})}}}),V=U.extend({init:function(t){this.options=K({},t.options),this._c=t,this.visual=new X(this.options),this.refresh()},_hover:function(t){var e=this.options,i=e.hover,n=e.stroke,o=e.fill;t&&q.isDefined(i.stroke)&&(n=K({},n,i.stroke)),t&&q.isDefined(i.fill)&&(o=i.fill),this.visual.redraw({stroke:n,fill:o})},refresh:function(){var t=this._c.shape.diagram.modelToView(this._c.position()),e=t.minus(this._c.shape.bounds("transformed").topLeft()),i=new G(t.x,t.y,0,0);i.inflate(this.options.width/2,this.options.height/2),this._visualBounds=i,this.visual.redraw({center:new Y(e.x,e.y)})},_hitTest:function(t){var e=this._c.shape.diagram.modelToView(t);return this._visualBounds.contains(e)}}),K(H,{CompositeUnit:c,TransformUnit:p,PanUndoUnit:v,AddShapeUnit:m,AddConnectionUnit:g,DeleteShapeUnit:f,DeleteConnectionUnit:d,ConnectionEditAdorner:z,ConnectionTool:T,ConnectorVisual:V,UndoRedoService:x,ResizingAdorner:R,Selector:O,ToolService:P,ConnectorsAdorner:L,LayoutUndoUnit:l,ConnectionEditUnit:h,ToFrontUnit:y,ToBackUnit:w,ConnectionRouterBase:D,PolylineRouter:E,CascadingRouter:I,SelectionTool:S,ScrollerTool:k,PointerTool:C,ConnectionEditTool:A,RotateUnit:_})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/layout.min",["dataviz/diagram/math.min"],t)}(function(){!function(t,e){var i=window.kendo,n=i.dataviz.diagram,o=n.Graph,r=n.Node,s=n.Link,a=i.deepExtend,l=n.Size,c=n.Rect,h=n.Dictionary,u=n.Set,d=n.Graph,f=n.Utils,p=n.Point,g=1e-6,m=Math.PI/180,v=f.contains,_=t.grep,y=i.Class.extend({defaultOptions:{type:"Tree",subtype:"Down",roots:null,animate:!1,limitToView:!1,friction:.9,nodeDistance:50,iterations:300,horizontalSeparation:90,verticalSeparation:50,underneathVerticalTopOffset:15,underneathHorizontalOffset:15,underneathVerticalSeparation:15,grid:{width:1500,offsetX:50,offsetY:50,componentSpacingX:20,componentSpacingY:20},layerSeparation:50,layeredIterations:2,startRadialAngle:0,endRadialAngle:360,radialSeparation:150,radialFirstLevelSeparation:200,keepComponentsInOneRadialLayout:!1,ignoreContainers:!0,layoutContainerChildren:!1,ignoreInvisible:!0,animateTransitions:!1},init:function(){},gridLayoutComponents:function(t){var e,i,n,o,r,s,a,l,c,h,u,d,g,m,v;if(!t)throw"No components supplied.";for(f.forEach(t,function(t){
t.calcBounds()}),t.sort(function(t,e){return e.bounds.width-t.bounds.width}),e=this.options.grid.width,i=this.options.grid.componentSpacingX,n=this.options.grid.componentSpacingY,o=0,r=this.options.grid.offsetX,s=this.options.grid.offsetY,a=r,l=s,h=[],u=[];t.length>0;){for(a>=e&&(a=r,l+=o+n,o=0),d=t.pop(),this.moveToOffset(d,new p(a,l)),c=0;c<d.nodes.length;c++)u.push(d.nodes[c]);for(c=0;c<d.links.length;c++)h.push(d.links[c]);g=d.bounds,m=g.height,(m<=0||isNaN(m))&&(m=0),v=g.width,(v<=0||isNaN(v))&&(v=0),m>=o&&(o=m),a+=v+i}return{nodes:u,links:h}},moveToOffset:function(t,e){var i,n,o,r,s,a,l,h,u=t.bounds,d=e.x-u.x,f=e.y-u.y;for(i=0;i<t.nodes.length;i++)o=t.nodes[i],r=o.bounds(),0===r.width&&0===r.height&&0===r.x&&0===r.y&&(r=new c(0,0,0,0)),r.x+=d,r.y+=f,o.bounds(r);for(i=0;i<t.links.length;i++)if(s=t.links[i],s.points){for(a=[],l=s.points,n=0;n<l.length;n++)h=l[n],h.x+=d,h.y+=f,a.push(h);s.points=a}return this.currentHorizontalOffset+=u.width+this.options.grid.offsetX,new p(d,f)},transferOptions:function(t){this.options=i.deepExtend({},this.defaultOptions),f.isUndefined(t)||(this.options=i.deepExtend(this.options,t||{}))}}),w=i.Class.extend({init:function(t){this.nodeMap=new h,this.shapeMap=new h,this.nodes=[],this.edges=[],this.edgeMap=new h,this.finalNodes=[],this.finalLinks=[],this.ignoredConnections=[],this.ignoredShapes=[],this.hyperMap=new h,this.hyperTree=new o,this.finalGraph=null,this.diagram=t},convert:function(t){if(f.isUndefined(this.diagram))throw"No diagram to convert.";return this.options=i.deepExtend({ignoreInvisible:!0,ignoreContainers:!0,layoutContainerChildren:!1},t||{}),this.clear(),this._renormalizeShapes(),this._renormalizeConnections(),this.finalNodes=new h(this.nodes),this.finalLinks=new h(this.edges),this.finalGraph=new o,this.finalNodes.forEach(function(t){this.finalGraph.addNode(t)},this),this.finalLinks.forEach(function(t){this.finalGraph.addExistingLink(t)},this),this.finalGraph},mapConnection:function(t){return this.edgeMap.get(t.id)},mapShape:function(t){return this.nodeMap.get(t.id)},getEdge:function(t,e){return f.first(t.links,function(i){return i.getComplement(t)===e})},clear:function(){this.finalGraph=null,this.hyperTree=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new d:null,this.hyperMap=!this.options.ignoreContainers&&this.options.layoutContainerChildren?new h:null,this.nodeMap=new h,this.shapeMap=new h,this.nodes=[],this.edges=[],this.edgeMap=new h,this.ignoredConnections=[],this.ignoredShapes=[],this.finalNodes=[],this.finalLinks=[]},listToRoot:function(t){var e=[],i=t.container;if(!i)return e;for(e.push(i);i.parentContainer;)i=i.parentContainer,e.push(i);return e.reverse(),e},firstNonIgnorableContainer:function(t){return t.isContainer&&!this._isIgnorableItem(t)?t:t.parentContainer?this.firstNonIgnorableContainer(t.parentContainer):null},isContainerConnection:function(t,e){return!(!t.isContainer||!this.isDescendantOf(t,e))||e.isContainer&&this.isDescendantOf(e,t)},isDescendantOf:function(t,e){var i,n,o,r;if(!t.isContainer)throw"Expecting a container.";if(t===e)return!1;if(v(t.children,e))return!0;for(i=[],n=0,o=t.children.length;n<o;n++)r=t.children[n],r.isContainer&&this.isDescendantOf(r,e)&&i.push(r);return i.length>0},isIgnorableItem:function(t){return this.options.ignoreInvisible?(!t.isCollapsed||!this._isVisible(t))&&!(!t.isCollapsed&&this._isVisible(t)):t.isCollapsed&&!this._isTop(t)},isShapeMapped:function(t){return t.isCollapsed&&!this._isVisible(t)&&!this._isTop(t)},leastCommonAncestor:function(t,e){var i,n,o,r,s,a;if(!t)throw"Parameter should not be null.";if(!e)throw"Parameter should not be null.";if(!this.hyperTree)throw"No hypertree available.";if(i=this.listToRoot(t),n=this.listToRoot(e),o=null,f.isEmpty(i)||f.isEmpty(n))return this.hyperTree.root.data;for(r=i[0],s=n[0],a=0;r===s&&(o=i[a],a++,!(a>=i.length||a>=n.length));)r=i[a],s=n[a];return o?_(this.hyperTree.nodes,function(t){return t.data.container===o}):this.hyperTree.root.data},_isTop:function(t){return!t.parentContainer},_isVisible:function(t){return!!t.visible()&&(t.parentContainer?this._isVisible(t.parentContainer):t.visible())},_isCollapsed:function(t){return!(!t.isContainer||!t.isCollapsed)||t.parentContainer&&this._isCollapsed(t.parentContainer)},_renormalizeShapes:function(){var t,e,i,n;if(!this.options.ignoreContainers)throw"Containers are not supported yet, but stay tuned.";for(t=0,e=this.diagram.shapes.length;t<e;t++)i=this.diagram.shapes[t],this.options.ignoreInvisible&&!this._isVisible(i)||i.isContainer?this.ignoredShapes.push(i):(n=new r(i.id,i),n.isVirtual=!1,this.nodeMap.add(i.id,n),this.nodes.push(n))},_renormalizeConnections:function(){var t,e,i,n,o,r,a,l;if(0!==this.diagram.connections.length)for(t=0,e=this.diagram.connections.length;t<e;t++)if(i=this.diagram.connections[t],this.isIgnorableItem(i))this.ignoredConnections.push(i);else if(n=i.sourceConnector?i.sourceConnector.shape:null,o=i.targetConnector?i.targetConnector.shape:null,n&&o)if(!v(this.ignoredShapes,n)||this.shapeMap.containsKey(n))if(!v(this.ignoredShapes,o)||this.shapeMap.containsKey(o))if(this.shapeMap.containsKey(n)&&(n=this.shapeMap[n]),this.shapeMap.containsKey(o)&&(o=this.shapeMap[o]),r=this.mapShape(n),a=this.mapShape(o),r===a||this.areConnectedAlready(r,a))this.ignoredConnections.push(i);else{if(null===r||null===a)throw"A shape was not mapped to a node.";if(!this.options.ignoreContainers)throw"Containers are not supported yet, but stay tuned.";r.isVirtual||a.isVirtual?this.ignoredConnections.push(i):(l=new s(r,a,i.id,i),this.edgeMap.add(i.id,l),this.edges.push(l))}else this.ignoredConnections.push(i);else this.ignoredConnections.push(i);else this.ignoredConnections.push(i)},areConnectedAlready:function(t,e){return f.any(this.edges,function(i){return i.source===t&&i.target===e||i.source===e&&i.target===t})}}),x=y.extend({init:function(t){var e=this;if(y.fn.init.call(e),f.isUndefined(t))throw"Diagram is not specified.";this.diagram=t},layout:function(t){var e,i,o,r,s,a;if(this.transferOptions(t),e=new w(this.diagram),i=e.convert(t),!i.isEmpty()&&(o=i.getConnectedComponents(),!f.isEmpty(o))){for(r=0;r<o.length;r++)s=o[r],this.layoutGraph(s,t);return a=this.gridLayoutComponents(o),new n.LayoutState(this.diagram,a)}},layoutGraph:function(t,e){var i,n,o;for(f.isDefined(e)&&this.transferOptions(e),this.graph=t,i=9*this.options.nodeDistance,this.temperature=i,n=this._expectedBounds(),this.width=n.width,this.height=n.height,o=0;o<this.options.iterations;o++)this.refineStage=o>=5*this.options.iterations/6,this.tick(),this.temperature=this.refineStage?i/30:i*(1-o/(2*this.options.iterations))},tick:function(){var t,e,i;for(t=0;t<this.graph.nodes.length;t++)this._repulsion(this.graph.nodes[t]);for(t=0;t<this.graph.links.length;t++)this._attraction(this.graph.links[t]);for(t=0;t<this.graph.nodes.length;t++){if(e=this.graph.nodes[t],i=Math.sqrt(e.dx*e.dx+e.dy*e.dy),0===i)return;e.x+=Math.min(i,this.temperature)*e.dx/i,e.y+=Math.min(i,this.temperature)*e.dy/i,this.options.limitToView&&(e.x=Math.min(this.width,Math.max(e.width/2,e.x)),e.y=Math.min(this.height,Math.max(e.height/2,e.y)))}},_shake:function(t){var e=Math.random()*this.options.nodeDistance/4,i=2*Math.random()*Math.PI;t.x+=e*Math.cos(i),t.y-=e*Math.sin(i)},_InverseSquareForce:function(t,e,i){var n,o,r,s,a,l,c;return this.refineStage?(o=e.x-i.x,r=e.y-i.y,s=e.width/2,a=e.height/2,l=i.width/2,c=i.height/2,n=Math.pow(o,2)/Math.pow(s+l+this.options.nodeDistance,2)+Math.pow(r,2)/Math.pow(a+c+this.options.nodeDistance,2)):n=Math.pow(t,2)/Math.pow(this.options.nodeDistance,2),4*n/3},_SquareForce:function(t,e,i){return 1/this._InverseSquareForce(t,e,i)},_repulsion:function(t){t.dx=0,t.dy=0,f.forEach(this.graph.nodes,function(e){var i,n,o,r;if(e!==t){for(;t.x===e.x&&t.y===e.y;)this._shake(e);i=t.x-e.x,n=t.y-e.y,o=Math.sqrt(i*i+n*n),r=2*this._SquareForce(o,t,e),t.dx+=i/o*r,t.dy+=n/o*r}},this)},_attraction:function(t){var e,i,n,o,r,s,a=t.target,l=t.source;if(l!==a){for(;l.x===a.x&&l.y===a.y;)this._shake(a);e=l.x-a.x,i=l.y-a.y,n=Math.sqrt(e*e+i*i),o=5*this._InverseSquareForce(n,l,a),r=e/n*o,s=i/n*o,a.dx+=r,a.dy+=s,l.dx-=r,l.dy-=s}},_expectedBounds:function(){var t,e,i,n,o,r=this.graph.nodes.length,s=1.5,a=4;return 0===r?t:(t=f.fold(this.graph.nodes,function(t,e){var i=e.width*e.height;return i>0?t+=Math.sqrt(i):0},0,this),e=t/r,i=e*Math.ceil(Math.sqrt(r)),n=i*Math.sqrt(s),o=i/Math.sqrt(s),{width:n*a,height:o*a})}}),b=i.Class.extend({init:function(t){this.center=null,this.options=t},layout:function(t,e){if(this.graph=t,this.graph.nodes&&0!==this.graph.nodes.length){if(!v(this.graph.nodes,e))throw"The given root is not in the graph.";this.center=e,this.graph.cacheRelationships(),this.layoutSwitch()}},layoutLeft:function(t){var e,i,n,o,r,s,a,c;for(this.setChildrenDirection(this.center,"Left",!1),this.setChildrenLayout(this.center,"Default",!1),e=0,i=0,o=0;o<t.length;o++)r=t[o],r.TreeDirection="Left",s=this.measure(r,l.Empty),i=Math.max(i,s.Width),e+=s.height+this.options.verticalSeparation;for(e-=this.options.verticalSeparation,a=this.center.x-this.options.horizontalSeparation,n=this.center.y+(this.center.height-e)/2,o=0;o<t.length;o++)r=t[o],c=new p(a-r.Size.width,n),this.arrange(r,c),n+=r.Size.height+this.options.verticalSeparation},layoutRight:function(t){var e,i,n,o,r,s,a,c;for(this.setChildrenDirection(this.center,"Right",!1),this.setChildrenLayout(this.center,"Default",!1),e=0,i=0,o=0;o<t.length;o++)r=t[o],r.TreeDirection="Right",s=this.measure(r,l.Empty),i=Math.max(i,s.Width),e+=s.height+this.options.verticalSeparation;for(e-=this.options.verticalSeparation,a=this.center.x+this.options.horizontalSeparation+this.center.width,n=this.center.y+(this.center.height-e)/2,o=0;o<t.length;o++)r=t[o],c=new p(a,n),this.arrange(r,c),n+=r.Size.height+this.options.verticalSeparation},layoutUp:function(t){var e,i,n,o,r,s,a;for(this.setChildrenDirection(this.center,"Up",!1),this.setChildrenLayout(this.center,"Default",!1),e=0,o=0;o<t.length;o++)n=t[o],n.TreeDirection="Up",r=this.measure(n,l.Empty),e+=r.width+this.options.horizontalSeparation;for(e-=this.options.horizontalSeparation,s=this.center.x+this.center.width/2-e/2,o=0;o<t.length;o++)n=t[o],i=this.center.y-this.options.verticalSeparation-n.Size.height,a=new p(s,i),this.arrange(n,a),s+=n.Size.width+this.options.horizontalSeparation},layoutDown:function(t){var e,i,n,o,r,s,a;for(this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1),n=0,i=0;i<t.length;i++)e=t[i],e.treeDirection="Down",r=this.measure(e,l.Empty),n+=r.width+this.options.horizontalSeparation;for(n-=this.options.horizontalSeparation,s=this.center.x+this.center.width/2-n/2,o=this.center.y+this.options.verticalSeparation+this.center.height,i=0;i<t.length;i++)e=t[i],a=new p(s,o),this.arrange(e,a),s+=e.Size.width+this.options.horizontalSeparation},layoutRadialTree:function(){var t,e;if(this.setChildrenDirection(this.center,"Radial",!1),this.setChildrenLayout(this.center,"Default",!1),this.previousRoot=null,t=this.options.startRadialAngle*m,e=this.options.endRadialAngle*m,e<=t)throw"Final angle should not be less than the start angle.";this.maxDepth=0,this.origin=new p(this.center.x,this.center.y),this.calculateAngularWidth(this.center,0),this.maxDepth>0&&this.radialLayout(this.center,this.options.radialFirstLevelSeparation,t,e),this.center.Angle=e-t},tipOverTree:function(t,e){var i,n,o,r,s,a,c;for(f.isUndefined(e)&&(e=0),this.setChildrenDirection(this.center,"Down",!1),this.setChildrenLayout(this.center,"Default",!1),this.setChildrenLayout(this.center,"Underneath",!1,e),i=0,r=0;r<t.length;r++)o=t[r],o.TreeDirection="Down",s=this.measure(o,l.Empty),i+=s.width+this.options.horizontalSeparation;for(i-=this.options.horizontalSeparation,i-=t[t.length-1].width,i+=t[t.length-1].associatedShape.bounds().width,a=this.center.x+this.center.width/2-i/2,n=this.center.y+this.options.verticalSeparation+this.center.height,r=0;r<t.length;r++)o=t[r],c=new p(a,n),this.arrange(o,c),a+=o.Size.width+this.options.horizontalSeparation},calculateAngularWidth:function(t,e){var i,n,o,r,s,a,l;if(e>this.maxDepth&&(this.maxDepth=e),i=0,n=1e3,o=1e3,r=0===e?0:Math.sqrt(n*n+o*o)/e,t.children.length>0){for(s=0,a=t.children.length;s<a;s++)l=t.children[s],i+=this.calculateAngularWidth(l,e+1);i=Math.max(r,i)}else i=r;return t.sectorAngle=i,i},sortChildren:function(t){var e,i,n,o,r,s,a,l,c,h,u,d=0;if(t.parents.length>1)throw"Node is not part of a tree.";if(i=t.parents[0],i&&(n=new p(i.x,i.y),o=new p(t.x,t.y),d=this.normalizeAngle(Math.atan2(n.y-o.y,n.x-o.x))),r=t.children.length,0===r)return null;for(s=[],a=[],e=0;e<r;++e)l=t.children[e],c=new p(l.x,l.y),a[e]=e,s[e]=this.normalizeAngle(-d+Math.atan2(c.y-c.y,c.x-c.x));for(f.bisort(s,a),h=[],u=t.children,e=0;e<r;++e)h.push(u[a[e]]);return h},normalizeAngle:function(t){for(;t>2*Math.PI;)t-=2*Math.PI;for(;t<0;)t+=2*Math.PI;return t},radialLayout:function(t,e,i,n){var o,r,s,a,l,c=n-i,h=c/2,u=t.sectorAngle,d=0,f=this.sortChildren(t);for(o=0,r=f.length;o<r;o++)s=f[o],a=s,l=a.sectorAngle/u,s.children.length>0&&this.radialLayout(s,e+this.options.radialSeparation,i+d*c,i+(d+l)*c),this.setPolarLocation(s,e,i+d*c+l*h),a.angle=l*c,d+=l},setPolarLocation:function(t,e,i){t.x=this.origin.x+e*Math.cos(i),t.y=this.origin.y+e*Math.sin(i),t.BoundingRectangle=new c(t.x,t.y,t.width,t.height)},setChildrenDirection:function(t,e,i){var n=t.treeDirection;this.graph.depthFirstTraversal(t,function(t){t.treeDirection=e}),i||(t.treeDirection=n)},setChildrenLayout:function(t,e,i,n){f.isUndefined(n)&&(n=0);var o=t.childrenLayout;n>0?(this.graph.assignLevels(t),this.graph.depthFirstTraversal(t,function(t){t.level>=n+1&&(t.childrenLayout=e)})):(this.graph.depthFirstTraversal(t,function(t){t.childrenLayout=e}),i||(t.childrenLayout=o))},measure:function(t,e){var i,n,o,r,s,a,c,h=0,u=0,d=new l(0,0);if(!t)throw"";if(n=t.associatedShape.bounds(),o=n.width,r=n.height,1!==t.parents.length)throw"Node not in a spanning tree.";if(s=t.parents[0],"Undefined"===t.treeDirection&&(t.treeDirection=s.treeDirection),f.isEmpty(t.children))d=new l(Math.abs(o)<g?50:o,Math.abs(r)<g?25:r);else if(1===t.children.length){switch(t.treeDirection){case"Radial":i=this.measure(t.children[0],e),h=o+this.options.radialSeparation*Math.cos(t.AngleToParent)+i.width,u=r+Math.abs(this.options.radialSeparation*Math.sin(t.AngleToParent))+i.height;break;case"Left":case"Right":switch(t.childrenLayout){case"TopAlignedWithParent":break;case"BottomAlignedWithParent":break;case"Underneath":i=this.measure(t.children[0],e),h=o+i.width+this.options.underneathHorizontalOffset,u=r+this.options.underneathVerticalTopOffset+i.height;break;case"Default":i=this.measure(t.children[0],e),h=o+this.options.horizontalSeparation+i.width,u=Math.max(r,i.height);break;default:throw"Unhandled TreeDirection in the Radial layout measuring."}break;case"Up":case"Down":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":i=this.measure(t.children[0],e),h=Math.max(o,i.width+this.options.underneathHorizontalOffset),u=r+this.options.underneathVerticalTopOffset+i.height;break;case"Default":i=this.measure(t.children[0],e),u=r+this.options.verticalSeparation+i.height,h=Math.max(o,i.width);break;default:throw"Unhandled TreeDirection in the Down layout measuring."}break;default:throw"Unhandled TreeDirection in the layout measuring."}d=new l(h,u)}else{switch(t.treeDirection){case"Left":case"Right":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=o,u=r+this.options.underneathVerticalTopOffset,a=0;a<t.children.length;a++)c=t.children[a],i=this.measure(c,e),h=Math.max(h,i.width+this.options.underneathHorizontalOffset),u+=i.height+this.options.underneathVerticalSeparation;u-=this.options.underneathVerticalSeparation;break;case"Default":for(h=o,u=0,a=0;a<t.children.length;a++)c=t.children[a],i=this.measure(c,e),h=Math.max(h,o+this.options.horizontalSeparation+i.width),u+=i.height+this.options.verticalSeparation;u-=this.options.verticalSeparation;break;default:throw"Unhandled TreeDirection in the Right layout measuring."}break;case"Up":case"Down":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=o,u=r+this.options.underneathVerticalTopOffset,a=0;a<t.children.length;a++)c=t.children[a],i=this.measure(c,e),h=Math.max(h,i.width+this.options.underneathHorizontalOffset),u+=i.height+this.options.underneathVerticalSeparation;u-=this.options.underneathVerticalSeparation;break;case"Default":for(h=0,u=0,a=0;a<t.children.length;a++)c=t.children[a],i=this.measure(c,e),h+=i.width+this.options.horizontalSeparation,u=Math.max(u,i.height+this.options.verticalSeparation+r);h-=this.options.horizontalSeparation;break;default:throw"Unhandled TreeDirection in the Down layout measuring."}break;default:throw"Unhandled TreeDirection in the layout measuring."}d=new l(h,u)}return t.SectorAngle=Math.sqrt(h*h/4+u*u/4),t.Size=d,d},arrange:function(t,e){var i,n,o,r,s,a,l,h,u=t.associatedShape.bounds(),d=u.width,m=u.height;if(f.isEmpty(t.children))t.x=e.x,t.y=e.y,t.BoundingRectangle=new c(e.x,e.y,d,m);else switch(t.treeDirection){case"Left":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=e,t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),l=e.y+m+this.options.underneathVerticalTopOffset,i=0;i<r.children.length;i++)r=r.children[i],a=h.x-r.associatedShape.width-this.options.underneathHorizontalOffset,n=new p(a,l),this.arrange(r,n),l+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(h=new p(e.x+t.Size.width-d,e.y+(t.Size.height-m)/2),t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),a=h.x-this.options.horizontalSeparation,l=e.y,i=0;i<t.children.length;i++)r=t.children[i],n=new p(a-r.Size.width,l),this.arrange(r,n),l+=r.Size.height+this.options.verticalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"Right":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=e,t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),a=e.x+d+this.options.underneathHorizontalOffset,l=e.y+m+this.options.underneathVerticalTopOffset,i=0;i<t.children.length;i++)r=t.children[i],n=new p(a,l),this.arrange(r,n),l+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":for(h=new p(e.x,e.y+(t.Size.height-m)/2),t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),a=e.x+d+this.options.horizontalSeparation,l=e.y,i=0;i<t.children.length;i++)r=t.children[i],n=new p(a,l),this.arrange(r,n),l+=r.Size.height+this.options.verticalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"Up":if(h=new p(e.x+(t.Size.width-d)/2,e.y+t.Size.height-m),t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),Math.abs(h.x-e.x)<g){for(s=0,i=0;i<t.children.length;i++)o=t.children[i],s+=o.Size.width+this.options.horizontalSeparation;s-=this.options.horizontalSeparation,a=e.x+(d-s)/2}else a=e.x;for(i=0;i<t.children.length;i++)r=t.children[i],l=h.y-this.options.verticalSeparation-r.Size.height,n=new p(a,l),this.arrange(r,n),a+=r.Size.width+this.options.horizontalSeparation;break;case"Down":switch(t.childrenLayout){case"TopAlignedWithParent":case"BottomAlignedWithParent":break;case"Underneath":for(h=e,t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),a=e.x+this.options.underneathHorizontalOffset,l=e.y+m+this.options.underneathVerticalTopOffset,i=0;i<t.children.length;i++)r=t.children[i],n=new p(a,l),this.arrange(r,n),l+=r.Size.height+this.options.underneathVerticalSeparation;break;case"Default":if(h=new p(e.x+(t.Size.width-d)/2,e.y),t.x=h.x,t.y=h.y,t.BoundingRectangle=new c(t.x,t.y,t.width,t.height),Math.abs(h.x-e.x)<g){for(s=0,i=0;i<t.children.length;i++)o=t.children[i],s+=o.Size.width+this.options.horizontalSeparation;s-=this.options.horizontalSeparation,a=e.x+(d-s)/2}else a=e.x;for(i=0;i<t.children.length;i++)r=t.children[i],l=h.y+this.options.verticalSeparation+m,n=new p(a,l),this.arrange(r,n),a+=r.Size.width+this.options.horizontalSeparation;break;default:throw"Unsupported TreeDirection"}break;case"None":break;default:throw"Unsupported TreeDirection"}},layoutSwitch:function(){var t,e,i,n,o,r;if(this.center&&!f.isEmpty(this.center.children))switch(t=this.options.subtype,f.isUndefined(t)&&(t="Down"),r=this.center.children,t.toLowerCase()){case"radial":case"radialtree":this.layoutRadialTree();break;case"mindmaphorizontal":case"mindmap":e=this.center.children,1===this.center.children.length?this.layoutRight(e):(o=r.length/2,i=_(this.center.children,function(t){return f.indexOf(r,t)<o}),n=_(this.center.children,function(t){return f.indexOf(r,t)>=o}),this.layoutLeft(i),this.layoutRight(n));break;case"mindmapvertical":e=this.center.children,1===this.center.children.length?this.layoutDown(e):(o=r.length/2,i=_(this.center.children,function(t){return f.indexOf(r,t)<o}),n=_(this.center.children,function(t){return f.indexOf(r,t)>=o}),this.layoutUp(i),this.layoutDown(n));break;case"right":this.layoutRight(this.center.children);break;case"left":this.layoutLeft(this.center.children);break;case"up":case"bottom":this.layoutUp(this.center.children);break;case"down":case"top":this.layoutDown(this.center.children);break;case"tipover":case"tipovertree":if(this.options.tipOverTreeStartLevel<0)throw"The tip-over level should be a positive integer.";this.tipOverTree(this.center.children,this.options.tipOverTreeStartLevel);break;case"undefined":case"none":}}}),k=y.extend({init:function(t){var e=this;if(y.fn.init.call(e),f.isUndefined(t))throw"No diagram specified.";this.diagram=t},layout:function(t){var e,i;return this.transferOptions(t),e=new w(this.diagram),this.graph=e.convert(),i=this.layoutComponents(),new n.LayoutState(this.diagram,i)},layoutComponents:function(){var t,e,i,n,o,r,s,a;if(!this.graph.isEmpty()&&(t=this.graph.getConnectedComponents(),!f.isEmpty(t))){for(e=new b(this.options),i=[],n=0;n<t.length;n++){if(o=t[n],r=this.getTree(o),!r)throw"Failed to find a spanning tree for the component.";s=r.root,a=r.tree,e.layout(a,s),i.push(a)}return this.gridLayoutComponents(i)}},getTree:function(t){var e,i,n,o,r,s=null;if(this.options.roots&&this.options.roots.length>0)for(e=0,i=t.nodes.length;e<i;e++)for(n=t.nodes[e],o=0;o<this.options.roots.length;o++)if(r=this.options.roots[o],r===n.associatedShape){s=n;break}if(!s&&(s=t.root(),!s))throw"Unable to find a root for the tree.";return this.getTreeForRoot(t,s)},getTreeForRoot:function(t,e){var i=t.getSpanningTree(e);return f.isUndefined(i)||i.isEmpty()?null:{tree:i,root:i.root}}}),C=y.extend({init:function(t){var e=this;if(y.fn.init.call(e),f.isUndefined(t))throw"Diagram is not specified.";this.diagram=t},layout:function(t){var e,i,o,r,s,a;if(this.transferOptions(t),e=new w(this.diagram),i=e.convert(t),!i.isEmpty()&&(o=i.getConnectedComponents(),!f.isEmpty(o))){for(r=0;r<o.length;r++)s=o[r],this.layoutGraph(s,t);return a=this.gridLayoutComponents(o),new n.LayoutState(this.diagram,a)}},_initRuntimeProperties:function(){var t,e;for(t=0;t<this.graph.nodes.length;t++)e=this.graph.nodes[t],e.layer=-1,e.downstreamLinkCount=0,e.upstreamLinkCount=0,e.isVirtual=!1,e.uBaryCenter=0,e.dBaryCenter=0,e.upstreamPriority=0,e.downstreamPriority=0,e.gridPosition=0},_prepare:function(t){var e,i,n,o,r,s,a,l,c,u,d,p=[],g=new h,m=0;for(f.forEach(t.nodes,function(t){0===t.incoming.length&&(g.set(t,0),p.push(t))});p.length>0;)for(r=p.shift(),e=0;e<r.outgoing.length;e++)n=r.outgoing[e],s=n.target,o=g.containsKey(s)?Math.max(g.get(r)+1,g.get(s)):g.get(r)+1,g.set(s,o),o>m&&(m=o),v(p,s)||p.push(s);for(a=g.keys(),a.sort(function(t,e){var i=g.get(t),n=g.get(e);return f.sign(n-i)}),l=0;l<a.length;++l)if(c=a[l],u=Number.MAX_VALUE,0!==c.outgoing.length){for(i=0;i<c.outgoing.length;++i)n=c.outgoing[i],u=Math.min(u,g.get(n.target));u>1&&g.set(c,u-1)}for(this.layers=[],e=0;e<m+1;e++)d=[],d.linksTo={},this.layers.push(d);for(g.forEach(function(t,e){t.layer=e,this.layers[e].push(t)},this),i=0;i<this.layers.length;i++)for(d=this.layers[i],e=0;e<d.length;e++)d[e].gridPosition=e},layoutGraph:function(t,e){if(f.isUndefined(t))throw"No graph given or graph analysis of the diagram failed.";f.isDefined(e)&&this.transferOptions(e),this.graph=t,t.setItemIndices();var i=t.makeAcyclic();this._initRuntimeProperties(),this._prepare(t,e),this._dummify(),this._optimizeCrossings(),this._swapPairs(),this.arrangeNodes(),this._moveThingsAround(),this._dedummify(),f.forEach(i,function(t){t.points&&t.points.reverse()})},setMinDist:function(t,e,i){var n=t.layer,o=t.layerIndex;this.minDistances[n][o]=i},getMinDist:function(t,e){var i,n=0,o=t.layerIndex,r=e.layerIndex,s=t.layer,a=Math.min(o,r),l=Math.max(o,r);for(i=a;i<l;++i)n+=this.minDistances[s][i];return n},placeLeftToRight:function(t){var e,i,n,o,r,s,a,l,c,u,d=new h;for(n=0;n<this.layers.length;++n)if(o=t[n]){for(e=0;e<o.length;e++)i=o[e],d.containsKey(i)||this.placeLeft(i,d,n);for(r=Number.POSITIVE_INFINITY,e=0;e<o.length;e++)i=o[e],s=this.rightSibling(i),s&&this.nodeLeftClass.get(s)!==n&&(r=Math.min(r,d.get(s)-d.get(i)-this.getMinDist(i,s)));if(r===Number.POSITIVE_INFINITY){for(a=[],e=0;e<o.length;e++)for(i=o[e],l=[],f.addRange(l,this.upNodes.get(i)),f.addRange(l,this.downNodes.get(i)),c=0;c<l.length;c++)u=l[c],this.nodeLeftClass.get(u)<n&&a.push(d.get(u)-d.get(i));a.sort(),r=0===a.length?0:a.length%2===1?a[this.intDiv(a.length,2)]:(a[this.intDiv(a.length,2)-1]+a[this.intDiv(a.length,2)])/2}for(e=0;e<o.length;e++)i=o[e],d.set(i,d.get(i)+r)}return d},placeRightToLeft:function(t){var e,i,n,o,r,s,a,l,c,u,d=new h;for(n=0;n<this.layers.length;++n)if(o=t[n]){for(e=0;e<o.length;e++)i=o[e],d.containsKey(i)||this.placeRight(i,d,n);for(r=Number.NEGATIVE_INFINITY,e=0;e<o.length;e++)i=o[e],s=this.leftSibling(i),s&&this.nodeRightClass.get(s)!==n&&(r=Math.max(r,d.get(s)-d.get(i)+this.getMinDist(s,i)));if(r===Number.NEGATIVE_INFINITY){for(a=[],e=0;e<o.length;e++)for(i=o[e],l=[],f.addRange(l,this.upNodes.get(i)),f.addRange(l,this.downNodes.get(i)),c=0;c<l.length;c++)u=l[c],this.nodeRightClass.get(u)<n&&a.push(d.get(i)-d.get(u));a.sort(),r=0===a.length?0:a.length%2===1?a[this.intDiv(a.length,2)]:(a[this.intDiv(a.length,2)-1]+a[this.intDiv(a.length,2)])/2}for(e=0;e<o.length;e++)i=o[e],d.set(i,d.get(i)+r)}return d},_getLeftWing:function(){var t={value:null},e=this.computeClasses(t,1);return this.nodeLeftClass=t.value,e},_getRightWing:function(){var t={value:null},e=this.computeClasses(t,-1);return this.nodeRightClass=t.value,e},computeClasses:function(t,e){var i,n,o,r,s,a,l,c,u,d=0,f=t.value=new h;for(i=0;i<this.layers.length;++i)for(d=i,n=this.layers[i],o=1===e?0:n.length-1;0<=o&&o<n.length;o+=e)if(r=n[o],f.containsKey(r))d=f.get(r);else if(f.set(r,d),r.isVirtual)for(s=this._nodesInLink(r),a=0;a<s.length;a++)l=s[a],f.set(l,d);for(c=[],u=0;u<this.layers.length;u++)c.push(null);return f.forEach(function(t,e){null===c[e]&&(c[e]=[]),c[e].push(t)}),c},_isVerticalLayout:function(){return"up"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()||"vertical"===this.options.subtype.toLowerCase()},_isHorizontalLayout:function(){return"right"===this.options.subtype.toLowerCase()||"left"===this.options.subtype.toLowerCase()||"horizontal"===this.options.subtype.toLowerCase()},_isIncreasingLayout:function(){return"right"===this.options.subtype.toLowerCase()||"down"===this.options.subtype.toLowerCase()},_moveThingsAround:function(){function t(t,e){var i,n,o=Number.MIN_VALUE;for(i=0;i<t.length;++i)n=t[i],o=e._isVerticalLayout()?Math.max(o,n.height):Math.max(o,n.width);return o}var e,i,n,o,r,s,a,l,c,u,d,p,g,m,v,_,y,w,x,b,k,C,S,T,A,P,D;for(i=0;i<this.layers.length;++i)o=this.layers[i],o.sort(this._gridPositionComparer);for(this.minDistances=[],i=0;i<this.layers.length;++i)for(o=this.layers[i],this.minDistances[i]=[],r=0;r<o.length;++r)n=o[r],n.layerIndex=r,this.minDistances[i][r]=this.options.nodeDistance,r<o.length-1&&(this.minDistances[i][r]+=this._isVerticalLayout()?(n.width+o[r+1].width)/2:(n.height+o[r+1].height)/2);for(this.downNodes=new h,this.upNodes=new h,f.forEach(this.graph.nodes,function(t){this.downNodes.set(t,[]),this.upNodes.set(t,[])},this),f.forEach(this.graph.links,function(t){var e=t.source,i=t.target,n=null,o=null;e.layer>i.layer?(n=t.source,o=t.target):(o=t.source,n=t.target),this.downNodes.get(o).push(n),this.upNodes.get(n).push(o)},this),this.downNodes.forEachValue(function(t){t.sort(this._gridPositionComparer)},this),this.upNodes.forEachValue(function(t){t.sort(this._gridPositionComparer)},this),i=0;i<this.layers.length-1;++i)for(o=this.layers[i],s=0;s<o.length-1;s++)if(a=o[s],a.isVirtual&&(l=this.downNodes.get(a)[0],l.isVirtual))for(r=s+1;r<o.length;++r)n=o[r],n.isVirtual&&(c=this.downNodes.get(n)[0],c.isVirtual&&l.gridPosition>c.gridPosition&&(u=l.gridPosition,l.gridPosition=c.gridPosition,c.gridPosition=u,d=l.layerIndex,p=c.layerIndex,this.layers[i+1][d]=c,this.layers[i+1][p]=l,l.layerIndex=p,c.layerIndex=d));for(g=this._getLeftWing(),m=this._getRightWing(),v=this.placeLeftToRight(g),_=this.placeRightToLeft(m),y=new h,f.forEach(this.graph.nodes,function(t){y.set(t,(v.get(t)+_.get(t))/2)}),w=new h,x=new h,i=0;i<this.layers.length;++i)for(o=this.layers[i],b=-1,k=-1,r=0;r<o.length;++r)n=o[r],w.set(n,0),x.set(n,!1),n.isVirtual&&(b===-1?b=r:b===r-1?b=r:(k=r,w.set(o[b],0),y.get(n)-y.get(o[b])===this.getMinDist(o[b],n)?x.set(o[b],!0):x.set(o[b],!1),b=r));for(C=[1,-1],f.forEach(C,function(t){var i,n,o,r,s,a,l,c=1===t?0:this.layers.length-1;for(i=c;0<=i&&i<this.layers.length;i+=t){if(n=this.layers[i],o=this._firstVirtualNode(n),r=null,s=null,o!==-1)for(r=n[o],s=[],e=0;e<o;e++)s.push(n[e]);else r=null,s=n;if(s.length>0){for(this._sequencer(y,null,r,t,s),e=0;e<s.length-1;++e)this.setMinDist(s[e],s[e+1],y.get(s[e+1])-y.get(s[e]));r&&this.setMinDist(s[s.length-1],r,y.get(r)-y.get(s[s.length-1]))}for(;r;){if(a=this.nextVirtualNode(n,r)){if(w.get(r)===t){for(o=r.layerIndex,l=a.layerIndex,s=[],e=o+1;e<l;e++)s.push(n[e]);s.length>0&&this._sequencer(y,r,a,t,s),x.set(r,!0)}}else{for(o=r.layerIndex,s=[],e=o+1;e<n.length;e++)s.push(n[e]);if(s.length>0){for(this._sequencer(y,r,null,t,s),e=0;e<s.length-1;++e)this.setMinDist(s[e],s[e+1],y.get(s[e+1])-y.get(s[e]));this.setMinDist(r,s[0],y.get(s[0])-y.get(r))}}r=a}this.adjustDirections(i,t,w,x)}},this),S=this._isIncreasingLayout()?0:this.layers.length-1,T=function(t,e){return e._isIncreasingLayout()?t<e.layers.length:t>=0},A=this._isIncreasingLayout()?1:-1,P=0,e=S;T(e,this);e+=A){for(o=this.layers[e],D=t(o,this),r=0;r<o.length;++r)n=o[r],this._isVerticalLayout()?(n.x=y.get(n),n.y=P+D/2):(n.x=P+D/2,n.y=y.get(n));P+=this.options.layerSeparation+D}},adjustDirections:function(t,e,i,n){var o,r,s,a,l,c,h,u,d,f,p,g,m,v;if(!(t+e<0||t+e>=this.layers.length))for(o=null,r=null,s=this.layers[t+e],a=0;a<s.length;++a)if(l=s[a],l.isVirtual&&(c=this.getNeighborOnLayer(l,t),c.isVirtual)){if(o){for(h=n.get(r),u=this.layers[t],d=r.layerIndex,f=c.layerIndex,p=d+1;p<f;++p)u[p].isVirtual&&(h=h&&n.get(u[p]));if(h)for(i.set(o,e),g=o.layerIndex,m=l.layerIndex,v=g+1;v<m;++v)s[v].isVirtual&&i.set(s[v],e)}o=l,r=c}},getNeighborOnLayer:function(t,e){var i=this.upNodes.get(t)[0];return i.layer===e?i:(i=this.downNodes.get(t)[0],i.layer===e?i:null)},_sequencer:function(t,e,i,n,o){if(1===o.length&&this._sequenceSingle(t,e,i,n,o[0]),o.length>1){var r=o.length,s=this.intDiv(r,2);this._sequencer(t,e,i,n,o.slice(0,s)),this._sequencer(t,e,i,n,o.slice(s)),this.combineSequences(t,e,i,n,o)}},_sequenceSingle:function(t,e,i,n,o){var r=n===-1?this.downNodes.get(o):this.upNodes.get(o),s=r.length;0!==s&&(s%2===1?t.set(o,t.get(r[this.intDiv(s,2)])):t.set(o,(t.get(r[this.intDiv(s,2)-1])+t.get(r[this.intDiv(s,2)]))/2),e&&t.set(o,Math.max(t.get(o),t.get(e)+this.getMinDist(e,o))),i&&t.set(o,Math.min(t.get(o),t.get(i)-this.getMinDist(o,i))))},combineSequences:function(t,e,i,n,o){var r,s,a,l,c,h,u,d,f,p,g=o.length,m=this.intDiv(g,2),v=[];
for(r=0;r<m;++r){for(s=0,l=n===-1?this.downNodes.get(o[r]):this.upNodes.get(o[r]),a=0;a<l.length;++a)c=l[a],t.get(c)>=t.get(o[r])?s++:(s--,v.push({k:t.get(c)+this.getMinDist(o[r],o[m-1]),v:2}));v.push({k:t.get(o[r])+this.getMinDist(o[r],o[m-1]),v:s})}for(e&&v.push({k:t.get(e)+this.getMinDist(e,o[m-1]),v:Number.MAX_VALUE}),v.sort(this._positionDescendingComparer),u=[],r=m;r<g;++r){for(s=0,l=n===-1?this.downNodes.get(o[r]):this.upNodes.get(o[r]),a=0;a<l.length;++a)c=l[a],t.get(c)<=t.get(o[r])?s++:(s--,u.push({k:t.get(c)-this.getMinDist(o[r],o[m]),v:2}));u.push({k:t.get(o[r])-this.getMinDist(o[r],o[m]),v:s})}for(i&&u.push({k:t.get(i)-this.getMinDist(i,o[m]),v:Number.MAX_VALUE}),u.sort(this._positionAscendingComparer),d=0,f=0,p=this.getMinDist(o[m-1],o[m]);t.get(o[m])-t.get(o[m-1])<p;)if(d<f){if(0===v.length){t.set(o[m-1],t.get(o[m])-p);break}h=v.shift(),d+=h.v,t.set(o[m-1],h.k),t.set(o[m-1],Math.max(t.get(o[m-1]),t.get(o[m])-p))}else{if(0===u.length){t.set(o[m],t.get(o[m-1])+p);break}h=u.shift(),f+=h.v,t.set(o[m],h.k),t.set(o[m],Math.min(t.get(o[m]),t.get(o[m-1])+p))}for(r=m-2;r>=0;r--)t.set(o[r],Math.min(t.get(o[r]),t.get(o[m-1])-this.getMinDist(o[r],o[m-1])));for(r=m+1;r<g;r++)t.set(o[r],Math.max(t.get(o[r]),t.get(o[m])+this.getMinDist(o[r],o[m])))},placeLeft:function(t,e,i){var n=Number.NEGATIVE_INFINITY;f.forEach(this._getComposite(t),function(t){var o=this.leftSibling(t);o&&this.nodeLeftClass.get(o)===this.nodeLeftClass.get(t)&&(e.containsKey(o)||this.placeLeft(o,e,i),n=Math.max(n,e.get(o)+this.getMinDist(o,t)))},this),n===Number.NEGATIVE_INFINITY&&(n=0),f.forEach(this._getComposite(t),function(t){e.set(t,n)})},placeRight:function(t,e,i){var n=Number.POSITIVE_INFINITY;f.forEach(this._getComposite(t),function(t){var o=this.rightSibling(t);o&&this.nodeRightClass.get(o)===this.nodeRightClass.get(t)&&(e.containsKey(o)||this.placeRight(o,e,i),n=Math.min(n,e.get(o)-this.getMinDist(t,o)))},this),n===Number.POSITIVE_INFINITY&&(n=0),f.forEach(this._getComposite(t),function(t){e.set(t,n)})},leftSibling:function(t){var e=this.layers[t.layer],i=t.layerIndex;return 0===i?null:e[i-1]},rightSibling:function(t){var e=this.layers[t.layer],i=t.layerIndex;return i===e.length-1?null:e[i+1]},_getComposite:function(t){return t.isVirtual?this._nodesInLink(t):[t]},arrangeNodes:function(){var t,e,i,n,o,r,s,a;for(e=0;e<this.layers.length;e++)for(n=this.layers[e],i=0;i<n.length;i++)o=n[i],o.upstreamPriority=o.upstreamLinkCount,o.downstreamPriority=o.downstreamLinkCount;for(r=2,s=0;s<r;s++){for(t=this.layers.length-1;t>=1;t--)this.layoutLayer(!1,t);for(t=0;t<this.layers.length-1;t++)this.layoutLayer(!0,t)}for(a=Number.MAX_VALUE,e=0;e<this.layers.length;e++)for(n=this.layers[e],i=0;i<n.length;i++)o=n[i],a=Math.min(a,o.gridPosition);if(a<0)for(e=0;e<this.layers.length;e++)for(n=this.layers[e],i=0;i<n.length;i++)o=n[i],o.gridPosition=o.gridPosition-a},layoutLayer:function(t,e){var i,n,o,r;for(n=t?this.layers[i=e+1]:this.layers[i=e-1],o=[],r=0;r<n.length;r++)o.push(n[r]);o.sort(function(t,e){var i=(t.upstreamPriority+t.downstreamPriority)/2,n=(e.upstreamPriority+e.downstreamPriority)/2;return Math.abs(i-n)<1e-4?0:i<n?1:-1}),f.forEach(o,function(t){var e=t.gridPosition,i=this.calcBaryCenter(t),o=(t.upstreamPriority+t.downstreamPriority)/2;if(!(Math.abs(e-i)<1e-4||Math.abs(e-i)<.2501))if(e<i)for(;e<i&&this.moveRight(t,n,o);)e=t.gridPosition;else for(;e>i&&this.moveLeft(t,n,o);)e=t.gridPosition},this),i>0&&this.calcDownData(i-1),i<this.layers.length-1&&this.calcUpData(i+1)},moveRight:function(t,e,i){var n,o,r=f.indexOf(e,t);return r===e.length-1?(t.gridPosition=t.gridPosition+.5,!0):(n=e[r+1],o=(n.upstreamPriority+n.downstreamPriority)/2,n.gridPosition>t.gridPosition+1?(t.gridPosition=t.gridPosition+.5,!0):!(o>i||Math.abs(o-i)<1e-4)&&(!!this.moveRight(n,e,i)&&(t.gridPosition=t.gridPosition+.5,!0)))},moveLeft:function(t,e,i){var n,o,r=f.indexOf(e,t);return 0===r?(t.gridPosition=t.gridPosition-.5,!0):(n=e[r-1],o=(n.upstreamPriority+n.downstreamPriority)/2,n.gridPosition<t.gridPosition-1?(t.gridPosition=t.gridPosition-.5,!0):!(o>i||Math.abs(o-i)<1e-4)&&(!!this.moveLeft(n,e,i)&&(t.gridPosition=t.gridPosition-.5,!0)))},mapVirtualNode:function(t,e){this.nodeToLinkMap.set(t,e),this.linkToNodeMap.containsKey(e)||this.linkToNodeMap.set(e,[]),this.linkToNodeMap.get(e).push(t)},_nodesInLink:function(t){return this.linkToNodeMap.get(this.nodeToLinkMap.get(t))},_dummify:function(){var t,e,i,n,o,a,l,c,u,d,p,g,m,v,_,y,w,x,b,k;for(this.linkToNodeMap=new h,this.nodeToLinkMap=new h,u=this.graph.links.slice(0),d=this.layers,p=function(t,e,i){d[t].linksTo[e]=d[t].linksTo[e]||[],d[t].linksTo[e].push(i)},c=0;c<u.length;c++)if(g=u[c],m=g.source,v=g.target,_=m.layer,y=v.layer,w=m.gridPosition,x=v.gridPosition,b=(x-w)/Math.abs(y-_),k=m,_-y>1){for(l=_-1;l>y;l--){for(i=new r,i.x=m.x,i.y=m.y,i.width=m.width/100,i.height=m.height/100,t=d[l],e=(l-y)*b+w,e>t.length&&(e=t.length),w>=d[_].length-1&&x>=d[y].length-1?e=t.length:0===w&&0===x&&(e=0),i.layer=l,i.uBaryCenter=0,i.dBaryCenter=0,i.upstreamLinkCount=0,i.downstreamLinkCount=0,i.gridPosition=e,i.isVirtual=!0,f.insert(t,i,e),o=e+1;o<t.length;o++)n=t[o],n.gridPosition=n.gridPosition+1;a=new s(k,i),a.depthOfDumminess=0,p(l-1,l,a),k=i,this.graph._addNode(i),this.graph.addLink(a),i.index=this.graph.nodes.length-1,this.mapVirtualNode(i,g)}p(y-1,y,a),g.changeSource(k),g.depthOfDumminess=_-y-1}else if(_-y<-1){for(l=_+1;l<y;l++){for(i=new r,i.x=m.x,i.y=m.y,i.width=m.width/100,i.height=m.height/100,t=d[l],e=(l-_)*b+w,e>t.length&&(e=t.length),w>=d[_].length-1&&x>=d[y].length-1?e=t.length:0===w&&0===x&&(e=0),i.layer=l,i.uBaryCenter=0,i.dBaryCenter=0,i.upstreamLinkCount=0,i.downstreamLinkCount=0,i.gridPosition=e,i.isVirtual=!0,e&=e,f.insert(t,i,e),o=e+1;o<t.length;o++)n=t[o],n.gridPosition=n.gridPosition+1;a=new s(k,i),a.depthOfDumminess=0,p(l-1,l,a),k=i,this.graph._addNode(i),this.graph.addLink(a),i.index=this.graph.nodes.length-1,this.mapVirtualNode(i,g)}p(y-1,y,g),g.changeSource(k),g.depthOfDumminess=y-_-1}else p(_,y,g)},_dedummify:function(){for(var t,e,i,n,o,r,s,a,l=!0;l;)for(l=!1,t=0;t<this.graph.links.length;t++)if(e=this.graph.links[t],e.depthOfDumminess){for(i=[],i.unshift({x:e.target.x,y:e.target.y}),i.unshift({x:e.source.x,y:e.source.y}),n=e,o=e.depthOfDumminess,r=0;r<o;r++)s=n.source,a=s.incoming[0],i.unshift({x:a.source.x,y:a.source.y}),n=a;e.changeSource(n.source),e.depthOfDumminess=0,i.length>2?(i.splice(0,1),i.splice(i.length-1),e.points=i):e.points=[],l=!0;break}},_optimizeCrossings:function(){for(var t,e=-1,i=3,n=0;0!==e&&!(n++>i);){for(e=0,t=this.layers.length-1;t>=1;t--)e+=this.optimizeLayerCrossings(!1,t);for(t=0;t<this.layers.length-1;t++)e+=this.optimizeLayerCrossings(!0,t)}},calcUpData:function(t){var e,i,n,o,r,s,a,l,c;if(0!==t){for(e=this.layers[t],r=new u,s=this.layers[t-1],i=0;i<s.length;i++)r.add(s[i]);for(i=0;i<e.length;i++){for(a=e[i],l=0,c=0,n=0;n<a.incoming.length;n++)o=a.incoming[n],r.contains(o.source)&&(c++,l+=o.source.gridPosition);for(n=0;n<a.outgoing.length;n++)o=a.outgoing[n],r.contains(o.target)&&(c++,l+=o.target.gridPosition);c>0?(a.uBaryCenter=l/c,a.upstreamLinkCount=c):(a.uBaryCenter=i,a.upstreamLinkCount=0)}}},calcDownData:function(t){var e,i,n,o,r,s,a,l,c;if(t!==this.layers.length-1){for(e=this.layers[t],r=new u,s=this.layers[t+1],i=0;i<s.length;i++)r.add(s[i]);for(i=0;i<e.length;i++){for(a=e[i],l=0,c=0,n=0;n<a.incoming.length;n++)o=a.incoming[n],r.contains(o.source)&&(c++,l+=o.source.gridPosition);for(n=0;n<a.outgoing.length;n++)o=a.outgoing[n],r.contains(o.target)&&(c++,l+=o.target.gridPosition);c>0?(a.dBaryCenter=l/c,a.downstreamLinkCount=c):(a.dBaryCenter=i,a.downstreamLinkCount=0)}}},optimizeLayerCrossings:function(t,e){var i,n,o,r,s,a,l,c;for(n=t?this.layers[i=e+1]:this.layers[i=e-1],o=n.slice(0),t?this.calcUpData(i):this.calcDownData(i),r=this,n.sort(function(t,e){var i,n=r.calcBaryCenter(t),o=r.calcBaryCenter(e);return Math.abs(n-o)<1e-4?t.degree()===e.degree()?r.compareByIndex(t,e):t.degree()<e.degree()?1:-1:(i=1e3*(o-n),i>0?-1:i<0?1:r.compareByIndex(t,e))}),a=0,s=0;s<n.length;s++)n[s]!==o[s]&&a++;if(a>0)for(l=0,s=0;s<n.length;s++)c=n[s],c.gridPosition=l++;return a},_swapPairs:function(){for(var t,e,i,n,o,r,s,a,l,c,h,u,d,f,p,g,m,v=this.options.layeredIterations,_=0;;){if(_++>v)break;for(t=_%4<=1,e=_%4===1,i=t?0:this.layers.length-1;t?i<=this.layers.length-1:i>=0;i+=t?1:-1){for(n=this.layers[i],o=!1,r=!0,s=0,a=0;a<n.length-1;a++)l=0,c=0,h=0,r?(0!==i&&(l=this.countLinksCrossingBetweenTwoLayers(i-1,i)),i!==this.layers.length-1&&(c=this.countLinksCrossingBetweenTwoLayers(i,i+1)),t?l*=2:c*=2,h=l+c):h=s,0!==h&&(u=n[a],d=n[a+1],f=u.gridPosition,p=d.gridPosition,n[a]=d,n[a+1]=u,u.gridPosition=p,d.gridPosition=f,l=0,0!==i&&(l=this.countLinksCrossingBetweenTwoLayers(i-1,i)),c=0,i!==this.layers.length-1&&(c=this.countLinksCrossingBetweenTwoLayers(i,i+1)),t?l*=2:c*=2,g=l+c,m=!1,m=e?g>=h:g>h,m?(u=n[a],d=n[a+1],f=u.gridPosition,p=d.gridPosition,n[a]=d,n[a+1]=u,u.gridPosition=p,d.gridPosition=f,s=h,r=!1):(o=!0,r=!0));o&&(i!==this.layers.length-1&&this.calcUpData(i+1),0!==i&&this.calcDownData(i-1))}}},countLinksCrossingBetweenTwoLayers:function(t,e){var i,n,o,r,s,a,l,c,h,u,d,f,p=this.layers[t].linksTo[e],g=0,m=p.length;for(l=0;l<m;l++)for(i=p[l],c=l+1;c<m;c++)n=p[c],i.target.layer===e?(o=i.source,r=i.target):(o=i.target,r=i.source),n.target.layer===e?(s=n.source,a=n.target):(s=n.target,a=n.source),h=o.gridPosition,u=r.gridPosition,d=s.gridPosition,f=a.gridPosition,(h-d)*(u-f)<0&&g++;return g},calcBaryCenter:function(t){var e=t.upstreamLinkCount,i=t.downstreamLinkCount,n=t.uBaryCenter,o=t.dBaryCenter;return e>0&&i>0?(n+o)/2:e>0?n:i>0?o:0},_gridPositionComparer:function(t,e){return t.gridPosition<e.gridPosition?-1:t.gridPosition>e.gridPosition?1:0},_positionAscendingComparer:function(t,e){return t.k<e.k?-1:t.k>e.k?1:0},_positionDescendingComparer:function(t,e){return t.k<e.k?1:t.k>e.k?-1:0},_firstVirtualNode:function(t){for(var e=0;e<t.length;e++)if(t[e].isVirtual)return e;return-1},compareByIndex:function(t,e){var i=t.index,n=e.index;return i<n?1:i>n?-1:0},intDiv:function(t,e){return(t-t%e)/e},nextVirtualNode:function(t,e){var i,n=e.layerIndex;for(i=n+1;i<t.length;++i)if(t[i].isVirtual)return t[i];return null}}),S=i.Class.extend({init:function(t,e){if(f.isUndefined(t))throw"No diagram given";this.diagram=t,this.nodeMap=new h,this.linkMap=new h,this.capture(e?e:t)},capture:function(t){var e,i,o,r,s,a,l,h,u;if(t instanceof n.Graph){for(r=0;r<t.nodes.length;r++)e=t.nodes[r],o=e.associatedShape,this.nodeMap.set(o.visual.id,new c(e.x,e.y,e.width,e.height));for(r=0;r<t.links.length;r++)a=t.links[r],s=a.associatedConnection,this.linkMap.set(s.visual.id,a.points())}else if(t instanceof Array)for(i=t,r=0;r<i.length;r++)e=i[r],o=e.associatedShape,o&&this.nodeMap.set(o.visual.id,new c(e.x,e.y,e.width,e.height));else if(t.hasOwnProperty("links")&&t.hasOwnProperty("nodes")){for(i=t.nodes,l=t.links,r=0;r<i.length;r++)e=i[r],o=e.associatedShape,o&&this.nodeMap.set(o.visual.id,new c(e.x,e.y,e.width,e.height));for(r=0;r<l.length;r++)a=l[r],s=a.associatedConnection,s&&this.linkMap.set(s.visual.id,a.points)}else{for(h=this.diagram.shapes,u=this.diagram.connections,r=0;r<h.length;r++)o=h[r],this.nodeMap.set(o.visual.id,o.bounds());for(r=0;r<u.length;r++)s=u[r],this.linkMap.set(s.visual.id,s.points())}}});a(n,{init:function(t){i.init(t,n.ui)},SpringLayout:x,TreeLayout:k,GraphAdapter:w,LayeredLayout:C,LayoutBase:y,LayoutState:S})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.toolbar.min",["kendo.core.min","kendo.userevents.min","kendo.popup.min"],t)}(function(){return function(t,e){function i(){var t,e=this.options.anchor,i=D(e);k.wrap(this.element).addClass("k-split-wrapper"),t="border-box"!==this.element.css("box-sizing")?i-(D(this.element)-this.element.width()):i,this.element.css({fontFamily:e.css("font-family"),"min-width":t})}function n(t){t.target.is(".k-toggle-button")||t.target.toggleClass(F,"press"==t.type)}function o(e){return e=t(e),e.hasClass("km-actionsheet")?e.closest(".km-popup-wrapper"):e.addClass("km-widget km-actionsheet").wrap('<div class="km-actionsheet-wrapper km-actionsheet-tablet km-widget km-popup"></div>').parent().wrap('<div class="km-popup-wrapper k-popup"></div>').parent()}function r(t){t.preventDefault()}function s(e,i){var n="next"===i?t.fn.next:t.fn.prev,o="next"===i?t.fn.first:t.fn.last,r=n.call(e);return r.is(":kendoFocusable")||!r.length?r:r.find(":kendoFocusable").length?o.call(r.find(":kendoFocusable")):s(r,i)}var a,l,c,h,u,d,f,p,g,m,v,_,y,w,x,b,k=window.kendo,C=k.Class,S=k.ui.Widget,T=t.proxy,A=k.isFunction,P=k.keys,D=k._outerWidth,M="k-toolbar",E="k-button",I="k-overflow-button",B="k-toggle-button",z="k-button-group",L="k-split-button",R="k-separator",O="k-popup",V="k-toolbar-resizable",F="k-state-active",N="k-state-disabled",H="k-state-hidden",U="k-group-start",j="k-group-end",G="k-primary",W="k-icon",q="k-i-",$="k-button-icon",Y="k-button-icontext",X="k-list-container k-split-container",Q="k-split-button-arrow",K="k-overflow-anchor",Z="k-overflow-container",J="k-toolbar-first-visible",tt="k-toolbar-last-visible",et="click",it="toggle",nt="open",ot="close",rt="overflowOpen",st="overflowClose",at="never",lt="auto",ct="always",ht="k-overflow-hidden",ut=k.attr("uid");k.toolbar={},a={overflowAnchor:'<div tabindex="0" class="k-overflow-anchor"></div>',overflowContainer:'<ul class="k-overflow-container k-list-container"></ul>'},k.toolbar.registerComponent=function(t,e,i){a[t]={toolbar:e,overflow:i}},l=k.Class.extend({addOverflowAttr:function(){this.element.attr(k.attr("overflow"),this.options.overflow||lt)},addUidAttr:function(){this.element.attr(ut,this.options.uid)},addIdAttr:function(){this.options.id&&this.element.attr("id",this.options.id)},addOverflowIdAttr:function(){this.options.id&&this.element.attr("id",this.options.id+"_overflow")},attributes:function(){this.options.attributes&&this.element.attr(this.options.attributes)},show:function(){this.element.removeClass(H).show(),this.options.hidden=!1},hide:function(){this.element.addClass(H).hide(),this.options.hidden=!0},remove:function(){this.element.remove()},enable:function(t){t===e&&(t=!0),this.element.toggleClass(N,!t),this.options.enable=t},twin:function(){var t=this.element.attr(ut);return this.overflow?this.toolbar.element.find("["+ut+"='"+t+"']").data(this.options.type):this.toolbar.options.resizable?this.toolbar.popup.element.find("["+ut+"='"+t+"']").data(this.options.type):e}}),k.toolbar.Item=l,c=l.extend({init:function(i,n){var o=t(i.useButtonTag?'<button tabindex="0"></button>':'<a href tabindex="0"></a>');this.element=o,this.options=i,this.toolbar=n,this.attributes(),i.primary&&o.addClass(G),i.togglable&&(o.addClass(B),this.toggle(i.selected)),i.url===e||i.useButtonTag||(o.attr("href",i.url),i.mobile&&o.attr(k.attr("role"),"button")),i.group&&(o.attr(k.attr("group"),i.group),this.group=this.toolbar.addToGroup(this,i.group)),!i.togglable&&i.click&&A(i.click)&&(this.clickHandler=i.click),i.togglable&&i.toggle&&A(i.toggle)&&(this.toggleHandler=i.toggle)},toggle:function(t,e){t=!!t,this.group&&t?this.group.select(this):this.group||this.select(t),e&&this.twin()&&this.twin().toggle(t)},getParentGroup:function(){if(this.options.isChild)return this.element.closest("."+z).data("buttonGroup")},_addGraphics:function(){var e,i,n,o=this.element,r=this.options.icon,s=this.options.spriteCssClass,a=this.options.imageUrl;(s||a||r)&&(e=!0,o.contents().filter(function(){return!t(this).hasClass("k-sprite")&&!t(this).hasClass(W)&&!t(this).hasClass("k-image")}).each(function(i,n){(1==n.nodeType||3==n.nodeType&&t.trim(n.nodeValue).length>0)&&(e=!1)}),o.addClass(e?$:Y)),r?(i=o.children("span."+W).first(),i[0]||(i=t('<span class="'+W+'"></span>').prependTo(o)),i.addClass(q+r)):s?(i=o.children("span.k-sprite").first(),i[0]||(i=t('<span class="k-sprite"></span>').prependTo(o)),i.addClass(s)):a&&(n=o.children("img.k-image").first(),n[0]||(n=t('<img alt="icon" class="k-image" />').prependTo(o)),n.attr("src",a))}}),k.toolbar.Button=c,h=c.extend({init:function(t,e){c.fn.init.call(this,t,e);var i=this.element;i.addClass(E),this.addIdAttr(),t.align&&i.addClass("k-align-"+t.align),"overflow"!=t.showText&&t.text&&i.html(t.mobile?'<span class="km-text">'+t.text+"</span>":t.text),t.hasIcon="overflow"!=t.showIcon&&(t.icon||t.spriteCssClass||t.imageUrl),t.hasIcon&&this._addGraphics(),this.addUidAttr(),this.addOverflowAttr(),this.enable(t.enable),t.hidden&&this.hide(),this.element.data({type:"button",button:this})},select:function(t){t===e&&(t=!1),this.element.toggleClass(F,t),this.options.selected=t}}),k.toolbar.ToolBarButton=h,u=c.extend({init:function(t,e){this.overflow=!0,c.fn.init.call(this,t,e);var i=this.element;"toolbar"!=t.showText&&t.text&&i.html(t.mobile?'<span class="km-text">'+t.text+"</span>":'<span class="k-text">'+t.text+"</span>"),t.hasIcon="toolbar"!=t.showIcon&&(t.icon||t.spriteCssClass||t.imageUrl),t.hasIcon&&this._addGraphics(),t.isChild||this._wrap(),this.addOverflowIdAttr(),this.attributes(),this.addUidAttr(),this.addOverflowAttr(),this.enable(t.enable),i.addClass(I+" "+E),t.hidden&&this.hide(),this.element.data({type:"button",button:this})},_wrap:function(){this.element=this.element.wrap("<li></li>").parent()},overflowHidden:function(){this.element.addClass(ht)},select:function(t){t===e&&(t=!1),this.options.isChild?this.element.toggleClass(F,t):this.element.find(".k-button").toggleClass(F,t),this.options.selected=t}}),k.toolbar.OverflowButton=u,k.toolbar.registerComponent("button",h,u),d=l.extend({createButtons:function(e){var i,n,o=this.options,r=o.buttons||[];for(n=0;n<r.length;n++)r[n].uid||(r[n].uid=k.guid()),i=new e(t.extend({mobile:o.mobile,isChild:!0,type:"button"},r[n]),this.toolbar),i.element.appendTo(this.element)},refresh:function(){this.element.children().filter(":not('."+H+"'):first").addClass(U),this.element.children().filter(":not('."+H+"'):last").addClass(j)}}),k.toolbar.ButtonGroup=d,f=d.extend({init:function(e,i){var n=this.element=t("<div></div>");this.options=e,this.toolbar=i,this.addIdAttr(),e.align&&n.addClass("k-align-"+e.align),this.createButtons(h),this.attributes(),this.addUidAttr(),this.addOverflowAttr(),this.refresh(),n.addClass(z),this.element.data({type:"buttonGroup",buttonGroup:this})}}),k.toolbar.ToolBarButtonGroup=f,p=d.extend({init:function(e,i){var n=this.element=t("<li></li>");this.options=e,this.toolbar=i,this.overflow=!0,this.addOverflowIdAttr(),this.createButtons(u),this.attributes(),this.addUidAttr(),this.addOverflowAttr(),this.refresh(),n.addClass((e.mobile?"":z)+" k-overflow-group"),this.element.data({type:"buttonGroup",buttonGroup:this})},overflowHidden:function(){this.element.addClass(ht)}}),k.toolbar.OverflowButtonGroup=p,k.toolbar.registerComponent("buttonGroup",f,p),g=l.extend({init:function(e,i){var n=this.element=t('<div class="'+L+'" tabindex="0"></div>');this.options=e,this.toolbar=i,this.mainButton=new h(t.extend({},e,{hidden:!1}),i),this.arrowButton=t('<a class="'+E+" "+Q+'"><span class="'+(e.mobile?"km-icon km-arrowdown":"k-icon k-i-arrow-s")+'"></span></a>'),this.popupElement=t('<ul class="'+X+'"></ul>'),this.mainButton.element.removeAttr("href tabindex").appendTo(n),this.arrowButton.appendTo(n),this.popupElement.appendTo(n),e.align&&n.addClass("k-align-"+e.align),e.id||(e.id=e.uid),n.attr("id",e.id+"_wrapper"),this.addOverflowAttr(),this.addUidAttr(),this.createMenuButtons(),this.createPopup(),this._navigatable(),this.mainButton.main=!0,this.enable(e.enable),e.hidden&&this.hide(),n.data({type:"splitButton",splitButton:this,kendoPopup:this.popup})},_navigatable:function(){var e=this;e.popupElement.on("keydown","."+E,function(i){var n=t(i.target).parent();i.preventDefault(),i.keyCode===P.ESC||i.keyCode===P.TAB||i.altKey&&i.keyCode===P.UP?(e.toggle(),e.focus()):i.keyCode===P.DOWN?s(n,"next").focus():i.keyCode===P.UP?s(n,"prev").focus():i.keyCode!==P.SPACEBAR&&i.keyCode!==P.ENTER||e.toolbar.userEvents.trigger("tap",{target:t(i.target)})})},createMenuButtons:function(){var e,i,n=this.options,o=n.menuButtons;for(i=0;i<o.length;i++)e=new h(t.extend({mobile:n.mobile,type:"button",click:n.click},o[i]),this.toolbar),e.element.wrap("<li></li>").parent().appendTo(this.popupElement)},createPopup:function(){var e=this.options,n=this.element;this.popupElement.attr("id",e.id+"_optionlist").attr(ut,e.rootUid),e.mobile&&(this.popupElement=o(this.popupElement)),this.popup=this.popupElement.kendoPopup({appendTo:e.mobile?t(e.mobile).children(".km-pane"):null,anchor:n,isRtl:this.toolbar._isRtl,copyAnchorStyles:!1,animation:e.animation,open:i,activate:function(){this.element.find(":kendoFocusable").first().focus()},close:function(){n.focus()}}).data("kendoPopup"),this.popup.element.on(et,"a.k-button",r)},remove:function(){this.popup.element.off(et,"a.k-button"),this.popup.destroy(),this.element.remove()},toggle:function(){this.popup.toggle()},enable:function(t){t===e&&(t=!0),this.mainButton.enable(t),this.options.enable=t},focus:function(){this.element.focus()},hide:function(){this.popup&&this.popup.close(),this.element.addClass(H).hide(),this.options.hidden=!0},show:function(){this.element.removeClass(H).hide(),this.options.hidden=!1}}),k.toolbar.ToolBarSplitButton=g,m=l.extend({init:function(e,i){var n,o,r=this.element=t('<li class="'+L+'"></li>'),s=e.menuButtons;for(this.options=e,this.toolbar=i,this.overflow=!0,this.mainButton=new u(t.extend({isChild:!0},e)),this.mainButton.element.appendTo(r),o=0;o<s.length;o++)n=new u(t.extend({mobile:e.mobile,isChild:!0},s[o]),this.toolbar),n.element.appendTo(r);this.addUidAttr(),this.addOverflowAttr(),this.mainButton.main=!0,r.data({type:"splitButton",splitButton:this})},overflowHidden:function(){this.element.addClass(ht)}}),k.toolbar.OverflowSplitButton=m,k.toolbar.registerComponent("splitButton",g,m),v=l.extend({init:function(e,i){var n=this.element=t("<div>&nbsp;</div>");this.element=n,this.options=e,this.toolbar=i,this.attributes(),this.addIdAttr(),this.addUidAttr(),this.addOverflowAttr(),n.addClass(R),n.data({type:"separator",separator:this})}}),_=l.extend({init:function(e,i){var n=this.element=t("<li>&nbsp;</li>");this.element=n,this.options=e,this.toolbar=i,this.overflow=!0,this.attributes(),this.addUidAttr(),this.addOverflowIdAttr(),n.addClass(R),n.data({type:"separator",separator:this})},overflowHidden:function(){this.element.addClass(ht)}}),k.toolbar.registerComponent("separator",v,_),y=l.extend({init:function(e,i,n){var o=A(e)?e(i):e;o=o instanceof jQuery?o.wrap("<div></div>").parent():t("<div></div>").html(o),this.element=o,this.options=i,this.options.type="template",this.toolbar=n,this.attributes(),this.addUidAttr(),this.addIdAttr(),this.addOverflowAttr(),o.data({type:"template",template:this})}}),k.toolbar.TemplateItem=y,w=l.extend({init:function(e,i,n){var o=t(A(e)?e(i):e);o=o instanceof jQuery?o.wrap("<li></li>").parent():t("<li></li>").html(o),this.element=o,this.options=i,this.options.type="template",this.toolbar=n,this.overflow=!0,this.attributes(),this.addUidAttr(),this.addOverflowIdAttr(),this.addOverflowAttr(),o.data({type:"template",template:this})},overflowHidden:function(){this.element.addClass(ht)}}),k.toolbar.OverflowTemplateItem=w,x=C.extend({init:function(t){this.name=t,this.buttons=[]},add:function(t){this.buttons[this.buttons.length]=t},remove:function(e){var i=t.inArray(e,this.buttons);this.buttons.splice(i,1)},select:function(t){var e,i;for(i=0;i<this.buttons.length;i++)e=this.buttons[i],e.select(!1);t.select(!0),t.twin()&&t.twin().select(!0)}}),b=S.extend({init:function(e,i){var o,s=this;if(S.fn.init.call(s,e,i),i=s.options,e=s.wrapper=s.element,e.addClass(M+" k-widget"),this.uid=k.guid(),this._isRtl=k.support.isRtl(e),this._groups={},e.attr(ut,this.uid),s.isMobile="boolean"==typeof i.mobile?i.mobile:s.element.closest(".km-root")[0],s.animation=s.isMobile?{open:{effects:"fade"}}:{},s.isMobile&&(e.addClass("km-widget"),W="km-icon",q="km-",E="km-button",z="km-buttongroup km-widget",F="km-state-active",N="km-state-disabled"),i.resizable?(s._renderOverflow(),e.addClass(V),s.overflowUserEvents=new k.UserEvents(s.element,{threshold:5,allowSelection:!0,filter:"."+K,tap:T(s._toggleOverflow,s)}),s._resizeHandler=k.onResize(function(){s.resize()})):s.popup={element:t([])},i.items&&i.items.length)for(o=0;o<i.items.length;o++)s.add(i.items[o]);s.userEvents=new k.UserEvents(document,{threshold:5,allowSelection:!0,filter:"["+ut+"="+this.uid+"] a."+E+", ["+ut+"="+this.uid+"] ."+I,tap:T(s._buttonClick,s),press:n,release:n}),s.element.on(et,"a.k-button",r),s._navigatable(),i.resizable&&s.popup.element.on(et,NaN,r),i.resizable&&this._toggleOverflowAnchor(),k.notify(s)},events:[et,it,nt,ot,rt,st],options:{name:"ToolBar",items:[],resizable:!0,mobile:null},addToGroup:function(t,e){var i;return i=this._groups[e]?this._groups[e]:this._groups[e]=new x,i.add(t),i},destroy:function(){var e=this;e.element.find("."+L).each(function(e,i){t(i).data("kendoPopup").destroy()}),e.element.off(et,"a.k-button"),e.userEvents.destroy(),e.options.resizable&&(k.unbindResize(e._resizeHandler),e.overflowUserEvents.destroy(),e.popup.element.off(et,"a.k-button"),e.popup.destroy()),S.fn.destroy.call(e)},add:function(e){var i,n,o,r=a[e.type],s=e.template,l=this,c=l.isMobile?"":"k-item k-state-default",h=e.overflowTemplate;if(t.extend(e,{uid:k.guid(),animation:l.animation,mobile:l.isMobile,rootUid:l.uid}),e.menuButtons)for(o=0;o<e.menuButtons.length;o++)t.extend(e.menuButtons[o],{uid:k.guid()});s&&!h?e.overflow=at:e.overflow||(e.overflow=lt),e.overflow!==at&&l.options.resizable&&(h?n=new w(h,e,l):r&&(n=new r.overflow(e,l),n.element.addClass(c)),n&&(e.overflow===lt&&n.overflowHidden(),n.element.appendTo(l.popup.container),l.angular("compile",function(){return{elements:n.element.get()}}))),e.overflow!==ct&&(s?i=new y(s,e,l):r&&(i=new r.toolbar(e,l)),i&&(l.options.resizable?(i.element.appendTo(l.element).css("visibility","hidden"),l._shrink(l.element.innerWidth()),i.element.css("visibility","visible")):i.element.appendTo(l.element),l.angular("compile",function(){return{elements:i.element.get()}})))},_getItem:function(e){var i,n,o,r,s=this.options.resizable;return i=this.element.find(e),i.length||(i=t(".k-split-container[data-uid="+this.uid+"]").find(e)),r=i.length?i.data("type"):"",n=i.data(r),n?(n.main&&(i=i.parent("."+L),r="splitButton",n=i.data(r)),s&&(o=n.twin())):s&&(i=this.popup.element.find(e),r=i.length?i.data("type"):"",o=i.data(r),o&&o.main&&(i=i.parent("."+L),r="splitButton",o=i.data(r))),{type:r,toolbar:n,overflow:o}},remove:function(t){var e=this._getItem(t);e.toolbar&&e.toolbar.remove(),e.overflow&&e.overflow.remove(),this.resize(!0)},hide:function(t){var e=this._getItem(t);e.toolbar&&("button"===e.toolbar.options.type&&e.toolbar.options.isChild?(e.toolbar.hide(),e.toolbar.getParentGroup().refresh()):e.toolbar.options.hidden||e.toolbar.hide()),e.overflow&&("button"===e.overflow.options.type&&e.overflow.options.isChild?(e.overflow.hide(),e.overflow.getParentGroup().refresh()):e.overflow.options.hidden||e.overflow.hide()),this.resize(!0)},show:function(t){var e=this._getItem(t);e.toolbar&&("button"===e.toolbar.options.type&&e.toolbar.options.isChild?(e.toolbar.show(),e.toolbar.getParentGroup().refresh()):e.toolbar.options.hidden&&e.toolbar.show()),e.overflow&&("button"===e.overflow.options.type&&e.overflow.options.isChild?(e.toolbar.show(),e.overflow.getParentGroup().refresh()):e.overflow.options.hidden&&e.overflow.show()),this.resize(!0)},enable:function(t,i){var n=this._getItem(t);e===i&&(i=!0),n.toolbar&&n.toolbar.enable(i),n.overflow&&n.overflow.enable(i)},getSelectedFromGroup:function(t){return this.element.find("."+B+"[data-group='"+t+"']").filter("."+F)},toggle:function(i,n){var o=t(i),r=o.data("button");r.options.togglable&&(n===e&&(n=!0),r.toggle(n,!0))},_renderOverflow:function(){var e=this,i=a.overflowContainer,n=e._isRtl,r=n?"left":"right";e.overflowAnchor=t(a.overflowAnchor).addClass(E),e.element.append(e.overflowAnchor),e.isMobile?(e.overflowAnchor.append('<span class="km-icon km-more"></span>'),i=o(i)):e.overflowAnchor.append('<span class="k-icon k-i-arrow-s"></span>'),e.popup=new k.ui.Popup(i,{origin:"bottom "+r,position:"top "+r,anchor:e.overflowAnchor,isRtl:n,animation:e.animation,appendTo:e.isMobile?t(e.isMobile).children(".km-pane"):null,copyAnchorStyles:!1,open:function(i){var o=k.wrap(e.popup.element).addClass("k-overflow-wrapper");e.isMobile?e.popup.container.css("max-height",parseFloat(t(".km-content:visible").innerHeight())-15+"px"):o.css("margin-left",(n?-1:1)*((D(o)-o.width())/2+1)),e.trigger(rt)&&i.preventDefault()},activate:function(){this.element.find(":kendoFocusable").first().focus()},close:function(t){e.trigger(st)&&t.preventDefault(),this.element.focus()}}),e.popup.element.on("keydown","."+E,function(i){var n,o=t(i.target),r=o.parent(),a=r.is("."+z)||r.is("."+L);i.preventDefault(),i.keyCode===P.ESC||i.keyCode===P.TAB||i.altKey&&i.keyCode===P.UP?(e._toggleOverflow(),e.overflowAnchor.focus()):i.keyCode===P.DOWN?(n=!a||a&&o.is(":last-child")?r:o,s(n,"next").focus()):i.keyCode===P.UP?(n=!a||a&&o.is(":first-child")?r:o,s(n,"prev").focus()):i.keyCode!==P.SPACEBAR&&i.keyCode!==P.ENTER||e.userEvents.trigger("tap",{target:t(i.target)})}),e.popup.container=e.isMobile?e.popup.element.find("."+Z):e.popup.element,e.popup.container.attr(ut,this.uid)},_toggleOverflowAnchor:function(){var t=!1;t=this.options.mobile?this.popup.element.find("."+Z).children(":not(."+ht+", ."+O+")").length>0:this.popup.element.children(":not(."+ht+", ."+O+")").length>0,this.overflowAnchor.css(t?{visibility:"visible",width:""}:{visibility:"hidden",width:"1px"})},_buttonClick:function(i){var n,o,r,s,a,l,c,h=this,u=i.target.closest("."+Q).length;return i.preventDefault(),u?(h._toggle(i),e):(o=t(i.target).closest("."+E,h.element),o.hasClass(K)||(r=o.data("button"),!r&&h.popup&&(o=t(i.target).closest("."+I,h.popup.container),r=o.parent("li").data("button")),r&&r.options.enable&&(r.options.togglable?(a=A(r.toggleHandler)?r.toggleHandler:null,r.toggle(!r.options.selected,!0),l={target:o,group:r.options.group,checked:r.options.selected,id:r.options.id},a&&a.call(h,l),h.trigger(it,l)):(a=A(r.clickHandler)?r.clickHandler:null,l={sender:h,target:o,id:r.options.id},a&&a.call(h,l),h.trigger(et,l)),r.options.url&&(r.options.attributes&&r.options.attributes.target&&(c=r.options.attributes.target),window.open(r.options.url,c||"_self")),o.hasClass(I)&&h.popup.close(),s=o.closest(".k-split-container"),s[0]&&(n=s.data("kendoPopup"),(n?n:s.parents(".km-popup-wrapper").data("kendoPopup")).close()))),e)},_navigatable:function(){var e=this;e.element.attr("tabindex",0).focus(function(){var e=t(this).find(":kendoFocusable:first");e.is("."+K)&&(e=s(e,"next")),e[0].focus()}).on("keydown",T(e._keydown,e))},_keydown:function(i){var n,o,r,s,a,l,c,h=t(i.target),u=i.keyCode,d=this.element.children(":not(.k-separator):visible");return u===P.TAB&&(n=h.parentsUntil(this.element).last(),o=!1,r=!1,n.length||(n=h),n.is("."+K)&&(i.shiftKey&&i.preventDefault(),d.last().is(":kendoFocusable")?d.last().focus():d.last().find(":kendoFocusable").last().focus()),i.shiftKey||d.index(n)!==d.length-1||(o=!n.is("."+z)||h.is(":last-child")),s=d.index(n)===d.not(".k-overflow-anchor").first().index(),i.shiftKey&&s&&(r=!n.is("."+z)||h.is(":first-child")),o&&this.overflowAnchor&&"hidden"!==this.overflowAnchor.css("visibility")&&(i.preventDefault(),this.overflowAnchor.focus()),r&&(i.preventDefault(),a=this._getPrevFocusable(this.wrapper),a&&a.focus())),i.altKey&&u===P.DOWN?(l=t(document.activeElement).data("splitButton"),c=t(document.activeElement).is("."+K),l?l.toggle():c&&this._toggleOverflow(),e):u!==P.SPACEBAR&&u!==P.ENTER||h.is("input, checkbox")?e:(i.preventDefault(),h.is("."+L)&&(h=h.children().first()),this.userEvents.trigger("tap",{target:h}),e)},_getPrevFocusable:function(i){if(i.is("html"))return i;var n,o,r=i.prevAll();return r.each(function(){return o=t(this),o.is(":kendoFocusable")?(n=o,!1):o.find(":kendoFocusable").length>0?(n=o.find(":kendoFocusable").last(),
!1):e}),n?n:this._getPrevFocusable(i.parent())},_toggle:function(e){var i,n=t(e.target).closest("."+L).data("splitButton");e.preventDefault(),n.options.enable&&(i=n.popup.element.is(":visible")?this.trigger(ot,{target:n.element}):this.trigger(nt,{target:n.element}),i||n.toggle())},_toggleOverflow:function(){this.popup.toggle()},_resize:function(t){var e=t.width;this.options.resizable&&(this.popup.close(),this._shrink(e),this._stretch(e),this._markVisibles(),this._toggleOverflowAnchor())},_childrenWidth:function(){var e=0;return this.element.children(":visible:not('."+H+"')").each(function(){e+=D(t(this),!0)}),Math.ceil(e)},_shrink:function(t){var e,i,n;if(t<this._childrenWidth())for(i=this.element.children(":visible:not([data-overflow='never'], ."+K+")"),n=i.length-1;n>=0&&(e=i.eq(n),!(t>this._childrenWidth()));n--)this._hideItem(e)},_stretch:function(t){var e,i,n;if(t>this._childrenWidth())for(i=this.element.children(":hidden:not('."+H+"')"),n=0;n<i.length&&(e=i.eq(n),!(t<this._childrenWidth())&&this._showItem(e,t));n++);},_hideItem:function(t){t.hide(),this.popup&&this.popup.container.find(">li[data-uid='"+t.data("uid")+"']").removeClass(ht)},_showItem:function(t,e){return!!(t.length&&e>this._childrenWidth()+D(t,!0))&&(t.show(),this.popup&&this.popup.container.find(">li[data-uid='"+t.data("uid")+"']").addClass(ht),!0)},_markVisibles:function(){var t=this.popup.container.children(),e=this.element.children(":not(.k-overflow-anchor)"),i=t.filter(":not(.k-overflow-hidden)"),n=e.filter(":visible");t.add(e).removeClass(J+" "+tt),i.first().add(n.first()).addClass(J),i.last().add(n.last()).addClass(tt)}}),k.ui.plugin(b)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.calendar.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(t,e,i,n){var o,r=t.getFullYear(),s=e.getFullYear(),a=i.getFullYear();return r-=r%n,o=r+(n-1),r<s&&(r=s),o>a&&(o=a),r+"-"+o}function n(t){for(var e,i=0,n=t.min,o=t.max,r=t.start,s=t.setter,l=t.build,c=t.cells||12,h=t.perRow||4,u=t.content||L,d=t.empty||R,f=t.html||'<table tabindex="0" role="grid" class="k-content k-meta-view" cellspacing="0"><tbody><tr role="row">';i<c;i++)i>0&&i%h===0&&(f+='</tr><tr role="row">'),r=new wt(r.getFullYear(),r.getMonth(),r.getDate(),0,0,0),D(r,0),e=l(r,i,t.disableDates),f+=a(r,n,o)?u(e):d(e),s(r,1);return f+"</tr></tbody></table>"}function o(t,e,i){var n=t.getFullYear(),o=e.getFullYear(),r=o,s=0;return i&&(o-=o%i,r=o-o%i+i-1),n>r?s=1:n<o&&(s=-1),s}function r(){var t=new wt;return new wt(t.getFullYear(),t.getMonth(),t.getDate())}function s(t,e,i){var n=r();return t&&(n=new wt((+t))),e>n?n=new wt((+e)):i<n&&(n=new wt((+i))),n}function a(t,e,i){return+t>=+e&&+t<=+i}function l(t,e){return t.slice(e).concat(t.slice(0,e))}function c(t,e,i){e=e instanceof wt?e.getFullYear():t.getFullYear()+i*e,t.setFullYear(e)}function h(e){var i=t(this).hasClass("k-state-disabled");i||t(this).toggleClass(J,ct.indexOf(e.type)>-1||e.type==at)}function u(t){t.preventDefault()}function d(t){return I(t).calendars.standard}function f(t){var i=xt[t.start],n=xt[t.depth],o=I(t.culture);t.format=M(t.format||o.calendars.standard.patterns.d),isNaN(i)&&(i=0,t.start=Y),(n===e||n>i)&&(t.depth=Y),null===t.dates&&(t.dates=[])}function p(t){V&&t.find("*").attr("unselectable","on")}function g(t,e){for(var i=0,n=e.length;i<n;i++)if(t===+e[i])return!0;return!1}function m(t,e){return!!t&&(t.getFullYear()===e.getFullYear()&&t.getMonth()===e.getMonth()&&t.getDate()===e.getDate())}function v(t,e){return!!t&&(t.getFullYear()===e.getFullYear()&&t.getMonth()===e.getMonth())}function _(e){return k.isFunction(e)?e:t.isArray(e)?w(e):t.noop}function y(t){var e,i=[];for(e=0;e<t.length;e++)i.push(t[e].setHours(0,0,0,0));return i}function w(e){var i,n,o,r,s,a=[],l=["su","mo","tu","we","th","fr","sa"],c="if (found) { return true } else {return false}";if(e[0]instanceof wt)a=y(e),i="var found = date && $.inArray(date.setHours(0, 0, 0, 0),["+a+"]) > -1;"+c;else{for(o=0;o<e.length;o++)r=e[o].slice(0,2).toLowerCase(),s=t.inArray(r,l),s>-1&&a.push(s);i="var found = date && $.inArray(date.getDay(),["+a+"]) > -1;"+c}return n=Function("date",i)}function x(t,e){return t instanceof Date&&e instanceof Date&&(t=t.getTime(),e=e.getTime()),t===e}var b,k=window.kendo,C=k.support,S=k.ui,T=S.Widget,A=k.keys,P=k.parseDate,D=k.date.adjustDST,M=k._extractFormat,E=k.template,I=k.getCulture,B=k.support.transitions,z=B?B.css+"transform-origin":"",L=E('<td#=data.cssClass# role="gridcell"><a tabindex="-1" class="k-link" href="\\#" data-#=data.ns#value="#=data.dateString#">#=data.value#</a></td>',{useWithBlock:!1}),R=E('<td role="gridcell">&nbsp;</td>',{useWithBlock:!1}),O=k.support.browser,V=O.msie&&O.version<9,F=k._outerHeight,N=k._outerWidth,H=".kendoCalendar",U="click"+H,j="keydown"+H,G="id",W="min",q="left",$="slideIn",Y="month",X="century",Q="change",K="navigate",Z="value",J="k-state-hover",tt="k-state-disabled",et="k-state-focused",it="k-other-month",nt=' class="'+it+'"',ot="k-nav-today",rt="td:has(.k-link)",st="blur"+H,at="focus",lt=at+H,ct=C.touch?"touchstart":"mouseenter",ht=C.touch?"touchstart"+H:"mouseenter"+H,ut=C.touch?"touchend"+H+" touchmove"+H:"mouseleave"+H,dt=6e4,ft=864e5,pt="_prevArrow",gt="_nextArrow",mt="aria-disabled",vt="aria-selected",_t=t.proxy,yt=t.extend,wt=Date,xt={month:0,year:1,decade:2,century:3},bt=T.extend({init:function(e,i){var n,o,a=this;T.fn.init.call(a,e,i),e=a.wrapper=a.element,i=a.options,i.url=window.unescape(i.url),a.options.disableDates=_(a.options.disableDates),a._templates(),a._header(),a._footer(a.footer),o=e.addClass("k-widget k-calendar").on(ht+" "+ut,rt,h).on(j,"table.k-content",_t(a._move,a)).on(U,rt,function(e){var i=e.currentTarget.firstChild,n=a._toDateObject(i);i.href.indexOf("#")!=-1&&e.preventDefault(),"month"==a._view.name&&a.options.disableDates(n)||a._click(t(i))}).on("mouseup"+H,"table.k-content, .k-footer",function(){a._focusView(a.options.focusOnNav!==!1)}).attr(G),o&&(a._cellID=o+"_cell_selected"),f(i),n=P(i.value,i.format,i.culture),a._index=xt[i.start],a._current=new wt((+s(n,i.min,i.max))),a._addClassProxy=function(){if(a._active=!0,a._cell.hasClass(tt)){var t=a._view.toDateString(r());a._cell=a._cellByDate(t)}a._cell.addClass(et)},a._removeClassProxy=function(){a._active=!1,a._cell.removeClass(et)},a.value(n),k.notify(a)},options:{name:"Calendar",value:null,min:new wt(1900,0,1),max:new wt(2099,11,31),dates:[],url:"",culture:"",footer:"",format:"",month:{},start:Y,depth:Y,animation:{horizontal:{effects:$,reverse:!0,duration:500,divisor:2},vertical:{effects:"zoomIn",duration:400}}},events:[Q,K],setOptions:function(t){var e=this;f(t),t.disableDates=_(t.disableDates),T.fn.setOptions.call(e,t),e._templates(),e._footer(e.footer),e._index=xt[e.options.start],e.navigate()},destroy:function(){var t=this,e=t._today;t.element.off(H),t._title.off(H),t[pt].off(H),t[gt].off(H),k.destroy(t._table),e&&k.destroy(e.off(H)),T.fn.destroy.call(t)},current:function(){return this._current},view:function(){return this._view},focus:function(t){t=t||this._table,this._bindTable(t),t.focus()},min:function(t){return this._option(W,t)},max:function(t){return this._option("max",t)},navigateToPast:function(){this._navigate(pt,-1)},navigateToFuture:function(){this._navigate(gt,1)},navigateUp:function(){var t=this,e=t._index;t._title.hasClass(tt)||t.navigate(t._current,++e)},navigateDown:function(t){var i=this,n=i._index,o=i.options.depth;if(t)return n===xt[o]?(x(i._value,i._current)&&x(i._value,t)||(i.value(t),i.trigger(Q)),e):(i.navigate(t,--n),e)},navigate:function(i,n){var o,r,a,l,c,h,u,d,f,g,m,v,_,y,w,x,k;n=isNaN(n)?xt[n]:n,o=this,r=o.options,a=r.culture,l=r.min,c=r.max,h=o._title,u=o._table,d=o._oldTable,f=o._value,g=o._current,m=i&&+i>+g,v=n!==e&&n!==o._index,i||(i=g),o._current=i=new wt((+s(i,l,c))),n===e?n=o._index:o._index=n,o._view=y=b.views[n],w=y.compare,x=n===xt[X],h.toggleClass(tt,x).attr(mt,x),x=w(i,l)<1,o[pt].toggleClass(tt,x).attr(mt,x),x=w(i,c)>-1,o[gt].toggleClass(tt,x).attr(mt,x),u&&d&&d.data("animating")&&(d.kendoStop(!0,!0),u.kendoStop(!0,!0)),o._oldTable=u,u&&!o._changeView||(h.html(y.title(i,l,c,a)),o._table=_=t(y.content(yt({min:l,max:c,date:i,url:r.url,dates:r.dates,format:r.format,culture:a,disableDates:r.disableDates},o[y.name]))),p(_),k=u&&u.data("start")===_.data("start"),o._animate({from:u,to:_,vertical:v,future:m,replace:k}),o.trigger(K),o._focus(i)),n===xt[r.depth]&&f&&!o.options.disableDates(f)&&o._class("k-state-selected",f),o._class(et,i),!u&&o._cell&&o._cell.removeClass(et),o._changeView=!0},value:function(t){var i=this,n=i._view,o=i.options,r=i._view,s=o.min,l=o.max;return t===e?i._value:(null===t&&(i._current=new Date(i._current.getFullYear(),i._current.getMonth(),i._current.getDate())),t=P(t,o.format,o.culture),null!==t&&(t=new wt((+t)),a(t,s,l)||(t=null)),null!==t&&i.options.disableDates(t)?i._value===e&&(i._value=null):i._value=t,r&&null===t&&i._cell?i._cell.removeClass("k-state-selected"):(i._changeView=!t||n&&0!==n.compare(t,i._current),i.navigate(t)),e)},_move:function(e){var i,n,o,r,l=this,c=l.options,h=e.keyCode,u=l._view,d=l._index,f=l.options.min,p=l.options.max,g=new wt((+l._current)),m=k.support.isRtl(l.wrapper),v=l.options.disableDates;return e.target===l._table[0]&&(l._active=!0),e.ctrlKey?h==A.RIGHT&&!m||h==A.LEFT&&m?(l.navigateToFuture(),n=!0):h==A.LEFT&&!m||h==A.RIGHT&&m?(l.navigateToPast(),n=!0):h==A.UP?(l.navigateUp(),n=!0):h==A.DOWN&&(l._click(t(l._cell[0].firstChild)),n=!0):(h==A.RIGHT&&!m||h==A.LEFT&&m?(i=1,n=!0):h==A.LEFT&&!m||h==A.RIGHT&&m?(i=-1,n=!0):h==A.UP?(i=0===d?-7:-4,n=!0):h==A.DOWN?(i=0===d?7:4,n=!0):h==A.ENTER?(l._click(t(l._cell[0].firstChild)),n=!0):h==A.HOME||h==A.END?(o=h==A.HOME?"first":"last",r=u[o](g),g=new wt(r.getFullYear(),r.getMonth(),r.getDate(),g.getHours(),g.getMinutes(),g.getSeconds(),g.getMilliseconds()),n=!0):h==A.PAGEUP?(n=!0,l.navigateToPast()):h==A.PAGEDOWN&&(n=!0,l.navigateToFuture()),(i||o)&&(o||u.setDate(g,i),v(g)&&(g=l._nextNavigatable(g,i)),a(g,f,p)&&l._focus(s(g,c.min,c.max)))),n&&e.preventDefault(),l._current},_nextNavigatable:function(t,e){var i=this,n=!0,o=i._view,r=i.options.min,s=i.options.max,l=i.options.disableDates,c=new Date(t.getTime());for(o.setDate(c,-e);n;){if(o.setDate(t,e),!a(t,r,s)){t=c;break}n=l(t)}return t},_animate:function(t){var e=this,i=t.from,n=t.to,o=e._active;i?i.parent().data("animating")?(i.off(H),i.parent().kendoStop(!0,!0).remove(),i.remove(),n.insertAfter(e.element[0].firstChild),e._focusView(o)):!i.is(":visible")||e.options.animation===!1||t.replace?(n.insertAfter(i),i.off(H).remove(),e._focusView(o)):e[t.vertical?"_vertical":"_horizontal"](i,n,t.future):(n.insertAfter(e.element[0].firstChild),e._bindTable(n))},_horizontal:function(t,e,i){var n=this,o=n._active,r=n.options.animation.horizontal,s=r.effects,a=N(t);s&&s.indexOf($)!=-1&&(t.add(e).css({width:a}),t.wrap("<div/>"),n._focusView(o,t),t.parent().css({position:"relative",width:2*a,"float":q,"margin-left":i?0:-a}),e[i?"insertAfter":"insertBefore"](t),yt(r,{effects:$+":"+(i?"right":q),complete:function(){t.off(H).remove(),n._oldTable=null,e.unwrap(),n._focusView(o)}}),t.parent().kendoStop(!0,!0).kendoAnimate(r))},_vertical:function(t,e){var i,n,o=this,r=o.options.animation.vertical,s=r.effects,a=o._active;s&&s.indexOf("zoom")!=-1&&(e.css({position:"absolute",top:F(t.prev()),left:0}).insertBefore(t),z&&(i=o._cellByDate(o._view.toDateString(o._current)),n=i.position(),n=n.left+parseInt(i.width()/2,10)+"px "+(n.top+parseInt(i.height()/2,10)+"px"),e.css(z,n)),t.kendoStop(!0,!0).kendoAnimate({effects:"fadeOut",duration:600,complete:function(){t.off(H).remove(),o._oldTable=null,e.css({position:"static",top:0,left:0}),o._focusView(a)}}),e.kendoStop(!0,!0).kendoAnimate(r))},_cellByDate:function(e){return this._table.find("td:not(."+it+")").filter(function(){return t(this.firstChild).attr(k.attr(Z))===e})},_class:function(e,i){var n,o=this,r=o._cellID,s=o._cell,a=o._view.toDateString(i);s&&s.removeAttr(vt).removeAttr("aria-label").removeAttr(G),i&&"month"==o._view.name&&(n=o.options.disableDates(i)),s=o._table.find("td:not(."+it+")").removeClass(e).filter(function(){return t(this.firstChild).attr(k.attr(Z))===a}).attr(vt,!0),(e===et&&!o._active&&o.options.focusOnNav!==!1||n)&&(e=""),s.addClass(e),s[0]&&(o._cell=s),r&&(s.attr(G,r),o._table.removeAttr("aria-activedescendant").attr("aria-activedescendant",r))},_bindTable:function(t){t.on(lt,this._addClassProxy).on(st,this._removeClassProxy)},_click:function(t){var e=this,i=e.options,n=new Date((+e._current)),o=e._toDateObject(t);D(o,0),"month"==e._view.name&&e.options.disableDates(o)&&(o=e._value),e._view.setDate(n,o),e.navigateDown(s(n,i.min,i.max))},_focus:function(t){var e=this,i=e._view;0!==i.compare(t,e._current)?e.navigate(t):(e._current=t,e._class(et,t))},_focusView:function(t,e){t&&this.focus(e)},_footer:function(i){var n=this,o=r(),s=n.element,a=s.find(".k-footer");return i?(a[0]||(a=t('<div class="k-footer"><a href="#" class="k-link k-nav-today"></a></div>').appendTo(s)),n._today=a.show().find(".k-link").html(i(o)).attr("title",k.toString(o,"D",n.options.culture)),n._toggle(),e):(n._toggle(!1),a.hide(),e)},_header:function(){var t,e=this,i=e.element;i.find(".k-header")[0]||i.html('<div class="k-header"><a href="#" role="button" class="k-link k-nav-prev"><span class="k-icon k-i-arrow-w"></span></a><a href="#" role="button" aria-live="assertive" aria-atomic="true" class="k-link k-nav-fast"></a><a href="#" role="button" class="k-link k-nav-next"><span class="k-icon k-i-arrow-e"></span></a></div>'),t=i.find(".k-link").on(ht+" "+ut+" "+lt+" "+st,h).click(!1),e._title=t.eq(1).on(U,function(){e._active=e.options.focusOnNav!==!1,e.navigateUp()}),e[pt]=t.eq(0).on(U,function(){e._active=e.options.focusOnNav!==!1,e.navigateToPast()}),e[gt]=t.eq(2).on(U,function(){e._active=e.options.focusOnNav!==!1,e.navigateToFuture()})},_navigate:function(t,e){var i=this,n=i._index+1,o=new wt((+i._current));t=i[t],t.hasClass(tt)||(n>3?o.setFullYear(o.getFullYear()+100*e):b.views[n].setDate(o,e),i.navigate(o))},_option:function(t,i){var n,o=this,r=o.options,s=o._value||o._current;return i===e?r[t]:(i=P(i,r.format,r.culture),i&&(r[t]=new wt((+i)),n=t===W?i>s:s>i,(n||v(s,i))&&(n&&(o._value=null),o._changeView=!0),o._changeView||(o._changeView=!(!r.month.content&&!r.month.empty)),o.navigate(o._value),o._toggle()),e)},_toggle:function(t){var i=this,n=i.options,o=i.options.disableDates(r()),s=i._today;t===e&&(t=a(r(),n.min,n.max)),s&&(s.off(U),t&&!o?s.addClass(ot).removeClass(tt).on(U,_t(i._todayClick,i)):s.removeClass(ot).addClass(tt).on(U,u))},_todayClick:function(t){var e=this,i=xt[e.options.depth],n=e.options.disableDates,o=r();t.preventDefault(),n(o)||(0===e._view.compare(e._current,o)&&e._index==i&&(e._changeView=!1),e._value=o,e.navigate(o,i),e.trigger(Q))},_toDateObject:function(e){var i=t(e).attr(k.attr(Z)).split("/");return i=new wt(i[0],i[1],i[2])},_templates:function(){var t=this,e=t.options,i=e.footer,n=e.month,o=n.content,r=n.empty;t.month={content:E('<td#=data.cssClass# role="gridcell"><a tabindex="-1" class="k-link#=data.linkClass#" href="#=data.url#" '+k.attr("value")+'="#=data.dateString#" title="#=data.title#">'+(o||"#=data.value#")+"</a></td>",{useWithBlock:!!o}),empty:E('<td role="gridcell">'+(r||"&nbsp;")+"</td>",{useWithBlock:!!r})},t.footer=i!==!1?E(i||'#= kendo.toString(data,"D","'+e.culture+'") #',{useWithBlock:!1}):null}});S.plugin(bt),b={firstDayOfMonth:function(t){return new wt(t.getFullYear(),t.getMonth(),1)},firstVisibleDay:function(t,e){e=e||k.culture().calendar;for(var i=e.firstDay,n=new wt(t.getFullYear(),t.getMonth(),0,t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds());n.getDay()!=i;)b.setTime(n,-1*ft);return n},setTime:function(t,e){var i=t.getTimezoneOffset(),n=new wt(t.getTime()+e),o=n.getTimezoneOffset()-i;t.setTime(n.getTime()+o*dt)},views:[{name:Y,title:function(t,e,i,n){return d(n).months.names[t.getMonth()]+" "+t.getFullYear()},content:function(t){for(var e=this,i=0,o=t.min,r=t.max,s=t.date,a=t.dates,c=t.format,h=t.culture,u=t.url,f=u&&a[0],p=d(h),m=p.firstDay,v=p.days,_=l(v.names,m),y=l(v.namesShort,m),w=b.firstVisibleDay(s,p),x=e.first(s),C=e.last(s),S=e.toDateString,T=new wt,A='<table tabindex="0" role="grid" class="k-content" cellspacing="0" data-start="'+S(w)+'"><thead><tr role="row">';i<7;i++)A+='<th scope="col" title="'+_[i]+'">'+y[i]+"</th>";return T=new wt(T.getFullYear(),T.getMonth(),T.getDate()),D(T,0),T=+T,n({cells:42,perRow:7,html:A+='</tr></thead><tbody><tr role="row">',start:w,min:new wt(o.getFullYear(),o.getMonth(),o.getDate()),max:new wt(r.getFullYear(),r.getMonth(),r.getDate()),content:t.content,empty:t.empty,setter:e.setDate,disableDates:t.disableDates,build:function(t,e,i){var n=[],o=t.getDay(),r="",s="#";return(t<x||t>C)&&n.push(it),i(t)&&n.push(tt),+t===T&&n.push("k-today"),0!==o&&6!==o||n.push("k-weekend"),f&&g(+t,a)&&(s=u.replace("{0}",k.toString(t,c,h)),r=" k-action-link"),{date:t,dates:a,ns:k.ns,title:k.toString(t,"D",h),value:t.getDate(),dateString:S(t),cssClass:n[0]?' class="'+n.join(" ")+'"':"",linkClass:r,url:s}}})},first:function(t){return b.firstDayOfMonth(t)},last:function(t){var e=new wt(t.getFullYear(),t.getMonth()+1,0),i=b.firstDayOfMonth(t),n=Math.abs(e.getTimezoneOffset()-i.getTimezoneOffset());return n&&e.setHours(i.getHours()+n/60),e},compare:function(t,e){var i,n=t.getMonth(),o=t.getFullYear(),r=e.getMonth(),s=e.getFullYear();return i=o>s?1:o<s?-1:n==r?0:n>r?1:-1},setDate:function(t,e){var i=t.getHours();e instanceof wt?t.setFullYear(e.getFullYear(),e.getMonth(),e.getDate()):b.setTime(t,e*ft),D(t,i)},toDateString:function(t){return t.getFullYear()+"/"+t.getMonth()+"/"+t.getDate()}},{name:"year",title:function(t){return t.getFullYear()},content:function(t){var e=d(t.culture).months.namesAbbr,i=this.toDateString,o=t.min,r=t.max;return n({min:new wt(o.getFullYear(),o.getMonth(),1),max:new wt(r.getFullYear(),r.getMonth(),1),start:new wt(t.date.getFullYear(),0,1),setter:this.setDate,build:function(t){return{value:e[t.getMonth()],ns:k.ns,dateString:i(t),cssClass:""}}})},first:function(t){return new wt(t.getFullYear(),0,t.getDate())},last:function(t){return new wt(t.getFullYear(),11,t.getDate())},compare:function(t,e){return o(t,e)},setDate:function(t,e){var i,n=t.getHours();e instanceof wt?(i=e.getMonth(),t.setFullYear(e.getFullYear(),i,t.getDate()),i!==t.getMonth()&&t.setDate(0)):(i=t.getMonth()+e,t.setMonth(i),i>11&&(i-=12),i>0&&t.getMonth()!=i&&t.setDate(0)),D(t,n)},toDateString:function(t){return t.getFullYear()+"/"+t.getMonth()+"/1"}},{name:"decade",title:function(t,e,n){return i(t,e,n,10)},content:function(t){var e=t.date.getFullYear(),i=this.toDateString;return n({start:new wt(e-e%10-1,0,1),min:new wt(t.min.getFullYear(),0,1),max:new wt(t.max.getFullYear(),0,1),setter:this.setDate,build:function(t,e){return{value:t.getFullYear(),ns:k.ns,dateString:i(t),cssClass:0===e||11==e?nt:""}}})},first:function(t){var e=t.getFullYear();return new wt(e-e%10,t.getMonth(),t.getDate())},last:function(t){var e=t.getFullYear();return new wt(e-e%10+9,t.getMonth(),t.getDate())},compare:function(t,e){return o(t,e,10)},setDate:function(t,e){c(t,e,1)},toDateString:function(t){return t.getFullYear()+"/0/1"}},{name:X,title:function(t,e,n){return i(t,e,n,100)},content:function(t){var e=t.date.getFullYear(),i=t.min.getFullYear(),o=t.max.getFullYear(),r=this.toDateString,s=i,a=o;return s-=s%10,a-=a%10,a-s<10&&(a=s+9),n({start:new wt(e-e%100-10,0,1),min:new wt(s,0,1),max:new wt(a,0,1),setter:this.setDate,build:function(t,e){var n=t.getFullYear(),s=n+9;return n<i&&(n=i),s>o&&(s=o),{ns:k.ns,value:n+" - "+s,dateString:r(t),cssClass:0===e||11==e?nt:""}}})},first:function(t){var e=t.getFullYear();return new wt(e-e%100,t.getMonth(),t.getDate())},last:function(t){var e=t.getFullYear();return new wt(e-e%100+99,t.getMonth(),t.getDate())},compare:function(t,e){return o(t,e,100)},setDate:function(t,e){c(t,e,10)},toDateString:function(t){var e=t.getFullYear();return e-e%10+"/0/1"}}]},b.isEqualDatePart=m,b.isEqualDate=x,b.makeUnselectable=p,b.restrictValue=s,b.isInRange=a,b.normalize=f,b.viewsEnum=xt,b.disabled=_,k.calendar=b}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.datepicker.min",["kendo.calendar.min","kendo.popup.min"],t)}(function(){return function(t,e){function i(e){var i=e.parseFormats,n=e.format;L.normalize(e),i=t.isArray(i)?i:[i],i.length||i.push("yyyy-MM-dd"),t.inArray(n,i)===-1&&i.splice(0,0,e.format),e.parseFormats=i}function n(t){t.preventDefault()}var o,r=window.kendo,s=r.ui,a=s.Widget,l=r.parseDate,c=r.keys,h=r.template,u=r._activeElement,d="<div />",f="<span />",p=".kendoDatePicker",g="click"+p,m="open",v="close",_="change",y="disabled",w="readonly",x="k-state-default",b="k-state-focused",k="k-state-selected",C="k-state-disabled",S="k-state-hover",T="mouseenter"+p+" mouseleave"+p,A="mousedown"+p,P="id",D="min",M="max",E="month",I="aria-disabled",B="aria-expanded",z="aria-hidden",L=r.calendar,R=L.isInRange,O=L.restrictValue,V=L.isEqualDatePart,F=t.extend,N=t.proxy,H=Date,U=function(e){var i,n=this,o=document.body,a=t(d).attr(z,"true").addClass("k-calendar-container").appendTo(o);n.options=e=e||{},i=e.id,i&&(i+="_dateview",a.attr(P,i),n._dateViewID=i),n.popup=new s.Popup(a,F(e.popup,e,{name:"Popup",isRtl:r.support.isRtl(e.anchor)})),n.div=a,n.value(e.value)};U.prototype={_calendar:function(){var e,i=this,o=i.calendar,a=i.options;o||(e=t(d).attr(P,r.guid()).appendTo(i.popup.element).on(A,n).on(g,"td:has(.k-link)",N(i._click,i)),i.calendar=o=new s.Calendar(e),i._setOptions(a),r.calendar.makeUnselectable(o.element),o.navigate(i._value||i._current,a.start),i.value(i._value))},_setOptions:function(t){this.calendar.setOptions({focusOnNav:!1,change:t.change,culture:t.culture,dates:t.dates,depth:t.depth,footer:t.footer,format:t.format,max:t.max,min:t.min,month:t.month,start:t.start,disableDates:t.disableDates})},setOptions:function(t){var e=this.options,i=t.disableDates;i&&(t.disableDates=L.disabled(i)),this.options=F(e,t,{change:e.change,close:e.close,open:e.open}),this.calendar&&this._setOptions(this.options)},destroy:function(){this.popup.destroy()},open:function(){var t=this;t._calendar(),t.popup.open()},close:function(){this.popup.close()},min:function(t){this._option(D,t)},max:function(t){this._option(M,t)},toggle:function(){var t=this;t[t.popup.visible()?v:m]()},move:function(t){var e=this,i=t.keyCode,n=e.calendar,o=t.ctrlKey&&i==c.DOWN||i==c.ENTER,r=!1;if(t.altKey)i==c.DOWN?(e.open(),t.preventDefault(),r=!0):i==c.UP&&(e.close(),t.preventDefault(),r=!0);else if(e.popup.visible()){if(i==c.ESC||o&&n._cell.hasClass(k))return e.close(),t.preventDefault(),!0;e._current=n._move(t),r=!0}return r},current:function(t){this._current=t,this.calendar._focus(t)},value:function(t){var e=this,i=e.calendar,n=e.options,o=n.disableDates;o&&o(t)&&(t=null),e._value=t,e._current=new H((+O(t,n.min,n.max))),i&&i.value(t)},_click:function(t){t.currentTarget.className.indexOf(k)!==-1&&this.close()},_option:function(t,e){var i=this,n=i.calendar;i.options[t]=e,n&&n[t](e)}},U.normalize=i,r.DateView=U,o=a.extend({init:function(e,n){var o,s,c=this;a.fn.init.call(c,e,n),e=c.element,n=c.options,n.disableDates=r.calendar.disabled(n.disableDates),n.min=l(e.attr("min"))||l(n.min),n.max=l(e.attr("max"))||l(n.max),i(n),c._initialOptions=F({},n),c._wrapper(),c.dateView=new U(F({},n,{id:e.attr(P),anchor:c.wrapper,change:function(){c._change(this.value()),c.close()},close:function(t){c.trigger(v)?t.preventDefault():(e.attr(B,!1),s.attr(z,!0))},open:function(t){var i,n=c.options;c.trigger(m)?t.preventDefault():(c.element.val()!==c._oldText&&(i=l(e.val(),n.parseFormats,n.culture),c.dateView[i?"current":"value"](i)),e.attr(B,!0),s.attr(z,!1),c._updateARIA(i))}})),s=c.dateView.div,c._icon();try{e[0].setAttribute("type","text")}catch(h){e[0].type="text"}e.addClass("k-input").attr({role:"combobox","aria-expanded":!1,"aria-owns":c.dateView._dateViewID}),c._reset(),c._template(),o=e.is("[disabled]")||t(c.element).parents("fieldset").is(":disabled"),o?c.enable(!1):c.readonly(e.is("[readonly]")),c._old=c._update(n.value||c.element.val()),c._oldText=e.val(),r.notify(c)},events:[m,v,_],options:{name:"DatePicker",value:null,footer:"",format:"",culture:"",parseFormats:[],min:new Date(1900,0,1),max:new Date(2099,11,31),start:E,depth:E,animation:{},month:{},dates:[],ARIATemplate:'Current focused date is #=kendo.toString(data.current, "D")#'},setOptions:function(t){var e=this,n=e._value;a.fn.setOptions.call(e,t),t=e.options,t.min=l(t.min),t.max=l(t.max),i(t),e.dateView.setOptions(t),n&&(e.element.val(r.toString(n,t.format,t.culture)),e._updateARIA(n))},_editable:function(t){var e=this,i=e._dateIcon.off(p),o=e.element.off(p),r=e._inputWrapper.off(p),s=t.readonly,a=t.disable;s||a?(r.addClass(a?C:x).removeClass(a?x:C),o.attr(y,a).attr(w,s).attr(I,a)):(r.addClass(x).removeClass(C).on(T,e._toggleHover),o.removeAttr(y).removeAttr(w).attr(I,!1).on("keydown"+p,N(e._keydown,e)).on("focusout"+p,N(e._blur,e)).on("focus"+p,function(){e._inputWrapper.addClass(b)}),i.on(g,N(e._click,e)).on(A,n))},readonly:function(t){this._editable({readonly:t===e||t,disable:!1})},enable:function(t){this._editable({readonly:!1,disable:!(t=t===e||t)})},destroy:function(){var t=this;a.fn.destroy.call(t),t.dateView.destroy(),t.element.off(p),t._dateIcon.off(p),t._inputWrapper.off(p),t._form&&t._form.off("reset",t._resetHandler)},open:function(){this.dateView.open()},close:function(){this.dateView.close()},min:function(t){return this._option(D,t)},max:function(t){return this._option(M,t)},value:function(t){var i=this;return t===e?i._value:(i._old=i._update(t),null===i._old&&i.element.val(""),i._oldText=i.element.val(),e)},_toggleHover:function(e){t(e.currentTarget).toggleClass(S,"mouseenter"===e.type)},_blur:function(){var t=this,e=t.element.val();t.close(),e!==t._oldText&&t._change(e),t._inputWrapper.removeClass(b)},_click:function(){var t=this,e=t.element;t.dateView.toggle(),r.support.touch||e[0]===u()||e.focus()},_change:function(t){var e,i,n,o=this,s=o.element.val();t=o._update(t),e=!r.calendar.isEqualDate(o._old,t),i=e&&!o._typing,n=s!==o.element.val(),(i||n)&&o.element.trigger(_),e&&(o._old=t,o._oldText=o.element.val(),o.trigger(_)),o._typing=!1},_keydown:function(t){var e=this,i=e.dateView,n=e.element.val(),o=!1;i.popup.visible()||t.keyCode!=c.ENTER||n===e._oldText?(o=i.move(t),e._updateARIA(i._current),o||(e._typing=!0)):e._change(n)},_icon:function(){var e,i=this,n=i.element;e=n.next("span.k-select"),e[0]||(e=t('<span unselectable="on" class="k-select" aria-label="select"><span class="k-icon k-i-calendar"></span></span>').insertAfter(n)),i._dateIcon=e.attr({role:"button","aria-controls":i.dateView._dateViewID})},_option:function(t,i){var n=this,o=n.options;return i===e?o[t]:(i=l(i,o.parseFormats,o.culture),i&&(o[t]=new H((+i)),n.dateView[t](i)),e)},_update:function(t){var e,i=this,n=i.options,o=n.min,s=n.max,a=i._value,c=l(t,n.parseFormats,n.culture),h=null===c&&null===a||c instanceof Date&&a instanceof Date;return n.disableDates(c)&&(c=null,i._old||i.element.val()||(t=null)),+c===+a&&h?(e=r.toString(c,n.format,n.culture),e!==t&&i.element.val(null===c?t:e),c):(null!==c&&V(c,o)?c=O(c,o,s):R(c,o,s)||(c=null),i._value=c,i.dateView.value(c),i.element.val(r.toString(c||t,n.format,n.culture)),i._updateARIA(c),c)},_wrapper:function(){var e,i=this,n=i.element;e=n.parents(".k-datepicker"),e[0]||(e=n.wrap(f).parent().addClass("k-picker-wrap k-state-default"),e=e.wrap(f).parent()),e[0].style.cssText=n[0].style.cssText,n.css({width:"100%",height:n[0].style.height}),i.wrapper=e.addClass("k-widget k-datepicker k-header").addClass(n[0].className),i._inputWrapper=t(e[0].firstChild)},_reset:function(){var e=this,i=e.element,n=i.attr("form"),o=n?t("#"+n):i.closest("form");o[0]&&(e._resetHandler=function(){e.value(i[0].defaultValue),e.max(e._initialOptions.max),e.min(e._initialOptions.min)},e._form=o.on("reset",e._resetHandler))},_template:function(){this._ariaTemplate=h(this.options.ARIATemplate)},_updateARIA:function(t){var e,i=this,n=i.dateView.calendar;i.element.removeAttr("aria-activedescendant"),n&&(e=n._cell,e.attr("aria-label",i._ariaTemplate({current:t||n.current()})),i.element.attr("aria-activedescendant",e.attr("id")))}}),s.plugin(o)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.numerictextbox.min",["kendo.core.min","kendo.userevents.min"],t)}(function(){return function(t,e){function i(t,e){var i="k-i-arrow-"+("increase"===t?"n":"s");return'<span unselectable="on" class="k-link k-link-'+t+'" aria-label="'+e+'" title="'+e+'"><span unselectable="on" class="k-icon '+i+'"></span></span>'}function n(t,e){var i=(""+parseFloat(t,10)).split(A);return i[1]&&(i[1]=i[1].substring(0,e)),i.join(A)}var o=window.kendo,r=o.caret,s=o.keys,a=o.ui,l=a.Widget,c=o._activeElement,h=o._extractFormat,u=o.parseFloat,d=o.support.placeholder,f=o.getCulture,p="change",g="disabled",m="readonly",v="k-input",_="spin",y=".kendoNumericTextBox",w="touchend",x="mouseleave"+y,b="mouseenter"+y+" "+x,k="k-state-default",C="k-state-focused",S="k-state-hover",T="focus",A=".",P="k-state-selected",D="k-state-disabled",M="aria-disabled",E="aria-readonly",I=/^(-)?(\d*)$/,B=null,z=t.proxy,L=t.extend,R=l.extend({init:function(i,n){var r,s,a,c,u,d=this,f=n&&n.step!==e;l.fn.init.call(d,i,n),n=d.options,i=d.element.on("focusout"+y,z(d._focusout,d)).attr("role","spinbutton"),n.placeholder=n.placeholder||i.attr("placeholder"),d._initialOptions=L({},n),r=d.min(i.attr("min")),s=d.max(i.attr("max")),a=d._parse(i.attr("step")),n.min===B&&r!==B&&(n.min=r),n.max===B&&s!==B&&(n.max=s),f||a===B||(n.step=a),d._reset(),d._wrapper(),d._arrows(),d._input(),o.support.mobileOS?d._text.on(w+y+" "+T+y,function(){o.support.browser.edge?d._text.one(T+y,function(){d._toggleText(!1),i.focus()}):(d._toggleText(!1),i.focus())}):d._text.on(T+y,z(d._click,d)),i.attr("aria-valuemin",n.min).attr("aria-valuemax",n.max),n.format=h(n.format),c=n.value,d.value(c!==B?c:i.val()),u=i.is("[disabled]")||t(d.element).parents("fieldset").is(":disabled"),u?d.enable(!1):d.readonly(i.is("[readonly]")),o.notify(d)},options:{name:"NumericTextBox",decimals:B,restrictDecimals:!1,min:B,max:B,value:B,step:1,round:!0,culture:"",format:"n",spinners:!0,placeholder:"",upArrowText:"Increase value",downArrowText:"Decrease value"},events:[p,_],_editable:function(t){var e=this,i=e.element,n=t.disable,o=t.readonly,r=e._text.add(i),s=e._inputWrapper.off(b);e._toggleText(!0),e._upArrowEventHandler.unbind("press"),e._downArrowEventHandler.unbind("press"),i.off("keydown"+y).off("keypress"+y).off("paste"+y),o||n?(s.addClass(n?D:k).removeClass(n?k:D),r.attr(g,n).attr(m,o).attr(M,n).attr(E,o)):(s.addClass(k).removeClass(D).on(b,e._toggleHover),r.removeAttr(g).removeAttr(m).attr(M,!1).attr(E,!1),e._upArrowEventHandler.bind("press",function(t){t.preventDefault(),e._spin(1),e._upArrow.addClass(P)}),e._downArrowEventHandler.bind("press",function(t){t.preventDefault(),e._spin(-1),e._downArrow.addClass(P)}),e.element.on("keydown"+y,z(e._keydown,e)).on("keypress"+y,z(e._keypress,e)).on("paste"+y,z(e._paste,e)))},readonly:function(t){this._editable({readonly:t===e||t,disable:!1})},enable:function(t){this._editable({readonly:!1,disable:!(t=t===e||t)})},destroy:function(){var t=this;t.element.add(t._text).add(t._upArrow).add(t._downArrow).add(t._inputWrapper).off(y),t._upArrowEventHandler.destroy(),t._downArrowEventHandler.destroy(),t._form&&t._form.off("reset",t._resetHandler),l.fn.destroy.call(t)},min:function(t){return this._option("min",t)},max:function(t){return this._option("max",t)},step:function(t){return this._option("step",t)},value:function(t){var i,n=this;return t===e?n._value:(t=n._parse(t),i=n._adjust(t),t===i&&(n._update(t),n._old=n._value),e)},focus:function(){this._focusin()},_adjust:function(t){var e=this,i=e.options,n=i.min,o=i.max;return t===B?t:(n!==B&&t<n?t=n:o!==B&&t>o&&(t=o),
t)},_arrows:function(){var e,n=this,r=function(){clearTimeout(n._spinning),e.removeClass(P)},s=n.options,a=s.spinners,l=n.element;e=l.siblings(".k-icon"),e[0]||(e=t(i("increase",s.upArrowText)+i("decrease",s.downArrowText)).insertAfter(l),e.wrapAll('<span class="k-select"/>')),a||(e.parent().toggle(a),n._inputWrapper.addClass("k-expand-padding")),n._upArrow=e.eq(0),n._upArrowEventHandler=new o.UserEvents(n._upArrow,{release:r}),n._downArrow=e.eq(1),n._downArrowEventHandler=new o.UserEvents(n._downArrow,{release:r})},_blur:function(){var t=this;t._toggleText(!0),t._change(t.element.val())},_click:function(t){var e=this;clearTimeout(e._focusing),e._focusing=setTimeout(function(){var i,n,o,s=t.target,a=r(s)[0],l=s.value.substring(0,a),c=e._format(e.options.format),h=c[","],u=0;h&&(n=RegExp("\\"+h,"g"),o=RegExp("([\\d\\"+h+"]+)(\\"+c[A]+")?(\\d+)?")),o&&(i=o.exec(l)),i&&(u=i[0].replace(n,"").length,l.indexOf("(")!=-1&&e._value<0&&u++),e._focusin(),r(e.element[0],u)})},_change:function(t){var e=this;e._update(t),t=e._value,e._old!=t&&(e._old=t,e._typing||e.element.trigger(p),e.trigger(p)),e._typing=!1},_culture:function(t){return t||f(this.options.culture)},_focusin:function(){var t=this;t._inputWrapper.addClass(C),t._toggleText(!1),t.element[0].focus()},_focusout:function(){var t=this;clearTimeout(t._focusing),t._inputWrapper.removeClass(C).removeClass(S),t._blur()},_format:function(t,e){var i=this._culture(e).numberFormat;return t=t.toLowerCase(),t.indexOf("c")>-1?i=i.currency:t.indexOf("p")>-1&&(i=i.percent),i},_input:function(){var e,i=this,n=i.options,o="k-formatted-value",r=i.element.addClass(v).show()[0],s=r.accessKey,a=i.wrapper;e=a.find(A+o),e[0]||(e=t('<input type="text"/>').insertBefore(r).addClass(o));try{r.setAttribute("type","text")}catch(l){r.type="text"}i._initialTitle=r.title,e[0].title=r.title,e[0].tabIndex=r.tabIndex,e[0].style.cssText=r.style.cssText,e.prop("placeholder",n.placeholder),s&&(e.attr("accesskey",s),r.accessKey=""),i._text=e.addClass(r.className).attr({role:"spinbutton","aria-valuemin":n.min,"aria-valuemax":n.max})},_keydown:function(t){var e=this,i=t.keyCode;e._key=i,i==s.DOWN?e._step(-1):i==s.UP?e._step(1):i==s.ENTER?e._change(e.element.val()):e._typing=!0},_keypress:function(t){var e,i,n,o,a,l,c,h,u,d,f;0===t.which||t.metaKey||t.ctrlKey||t.keyCode===s.BACKSPACE||t.keyCode===s.ENTER||(e=this,i=e.options.min,n=e.element,o=r(n),a=o[0],l=o[1],c=String.fromCharCode(t.which),h=e._format(e.options.format),u=e._key===s.NUMPAD_DOT,d=n.val(),u&&(c=h[A]),d=d.substring(0,a)+c+d.substring(l),f=e._numericRegex(h).test(d),f&&u?(n.val(d),r(n,a+c.length),t.preventDefault()):(null!==i&&i>=0&&"-"===d.charAt(0)||!f)&&t.preventDefault(),e._key=0)},_numericRegex:function(t){var e=this,i=t[A],n=e.options.decimals,o="*";return i===A&&(i="\\"+i),n===B&&(n=t.decimals),0===n?I:(e.options.restrictDecimals&&(o="{0,"+n+"}"),e._separator!==i&&(e._separator=i,e._floatRegExp=RegExp("^(-)?(((\\d+("+i+"\\d"+o+")?)|("+i+"\\d"+o+")))?$")),e._floatRegExp)},_paste:function(t){var e=this,i=t.target,n=i.value,o=e._format(e.options.format);setTimeout(function(){var t=e._parse(i.value),r=e._numericRegex(o).test(i.value);t!==B&&e._adjust(t)===t&&r||e._update(n)})},_option:function(t,i){var n=this,o=n.element,r=n.options;return i===e?r[t]:(i=n._parse(i),(i||"step"!==t)&&(r[t]=i,o.add(n._text).attr("aria-value"+t,i),o.attr(t,i)),e)},_spin:function(t,e){var i=this;e=e||500,clearTimeout(i._spinning),i._spinning=setTimeout(function(){i._spin(t,50)},e),i._step(t)},_step:function(t){var e=this,i=e.element,n=e._parse(i.val())||0;c()!=i[0]&&e._focusin(),n+=e.options.step*t,e._update(e._adjust(n)),e._typing=!1,e.trigger(_)},_toggleHover:function(e){t(e.currentTarget).toggleClass(S,"mouseenter"===e.type)},_toggleText:function(t){var e=this;e._text.toggle(t),e.element.toggle(!t)},_parse:function(t,e){return u(t,this._culture(e),this.options.format)},_round:function(t,e){var i=this.options.round?o._round:n;return i(t,e)},_update:function(t){var e,i=this,n=i.options,r=n.format,s=n.decimals,a=i._culture(),l=i._format(r,a);s===B&&(s=l.decimals),t=i._parse(t,a),e=t!==B,e&&(t=parseFloat(i._round(t,s),10)),i._value=t=i._adjust(t),i._placeholder(o.toString(t,r,a)),e?(t=""+t,t.indexOf("e")!==-1&&(t=i._round(+t,s)),t=t.replace(A,l[A])):t="",i.element.val(t),i.element.add(i._text).attr("aria-valuenow",t)},_placeholder:function(t){var e=this._text;e.val(t),d||t||e.val(this.options.placeholder),e.attr("title",this._initialTitle||e.val()),e.attr("aria-title",this._initialTitle||e.val())},_wrapper:function(){var e,i=this,n=i.element,o=n[0];e=n.parents(".k-numerictextbox"),e.is("span.k-numerictextbox")||(e=n.hide().wrap('<span class="k-numeric-wrap k-state-default" />').parent(),e=e.wrap("<span/>").parent()),e[0].style.cssText=o.style.cssText,o.style.width="",i.wrapper=e.addClass("k-widget k-numerictextbox").addClass(o.className).css("display",""),i._inputWrapper=t(e[0].firstChild)},_reset:function(){var e=this,i=e.element,n=i.attr("form"),o=n?t("#"+n):i.closest("form");o[0]&&(e._resetHandler=function(){setTimeout(function(){e.value(i[0].value),e.max(e._initialOptions.max),e.min(e._initialOptions.min)})},e._form=o.on("reset",e._resetHandler))}});a.plugin(R)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.validator.min",["kendo.core.min"],t)}(function(){return function(t,e){function i(e){var i,n=l.ui.validator.ruleResolvers||{},o={};for(i in n)t.extend(!0,o,n[i].resolve(e));return o}function n(t){return t.replace(/&amp/g,"&amp;").replace(/&quot;/g,'"').replace(/&#39;/g,"'").replace(/&lt;/g,"<").replace(/&gt;/g,">")}function o(t){return t=(t+"").split("."),t.length>1?t[1].length:0}function r(e){return t(t.parseHTML?t.parseHTML(e):e)}function s(e,i){var n,o,r,s,a=t();for(r=0,s=e.length;r<s;r++)n=e[r],d.test(n.className)&&(o=n.getAttribute(l.attr("for")),o===i&&(a=a.add(n)));return a}var a,l=window.kendo,c=l.ui.Widget,h=".kendoValidator",u="k-invalid-msg",d=RegExp(u,"i"),f="k-invalid",p="k-valid",g=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/i,m=/^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,v=":input:not(:button,[type=submit],[type=reset],[disabled],[readonly])",_=":checkbox:not([disabled],[readonly])",y="[type=number],[type=range]",w="blur",x="name",b="form",k="novalidate",C=t.proxy,S=function(t,e){return"string"==typeof e&&(e=RegExp("^(?:"+e+")$")),e.test(t)},T=function(t,e,i){var n=t.val();return!t.filter(e).length||""===n||S(n,i)},A=function(t,e){return!!t.length&&null!=t[0].attributes[e]};l.ui.validator||(l.ui.validator={rules:{},messages:{}}),a=c.extend({init:function(e,n){var o=this,r=i(e),s="["+l.attr("validate")+"!=false]";n=n||{},n.rules=t.extend({},l.ui.validator.rules,r.rules,n.rules),n.messages=t.extend({},l.ui.validator.messages,r.messages,n.messages),c.fn.init.call(o,e,n),o._errorTemplate=l.template(o.options.errorTemplate),o.element.is(b)&&o.element.attr(k,k),o._inputSelector=v+s,o._checkboxSelector=_+s,o._errors={},o._attachEvents(),o._isValidated=!1},events:["validate","change"],options:{name:"Validator",errorTemplate:'<span class="k-widget k-tooltip k-tooltip-validation"><span class="k-icon k-i-warning"> </span> #=message#</span>',messages:{required:"{0} is required",pattern:"{0} is not valid",min:"{0} should be greater than or equal to {1}",max:"{0} should be smaller than or equal to {1}",step:"{0} is not valid",email:"{0} is not valid email",url:"{0} is not valid URL",date:"{0} is not valid date",dateCompare:"End date should be greater than or equal to the start date"},rules:{required:function(t){var e=t.filter("[type=checkbox]").length&&!t.is(":checked"),i=t.val();return!(A(t,"required")&&(!i||""===i||0===i.length||e))},pattern:function(t){return!t.filter("[type=text],[type=email],[type=url],[type=tel],[type=search],[type=password]").filter("[pattern]").length||""===t.val()||S(t.val(),t.attr("pattern"))},min:function(t){if(t.filter(y+",["+l.attr("type")+"=number]").filter("[min]").length&&""!==t.val()){var e=parseFloat(t.attr("min"))||0,i=l.parseFloat(t.val());return e<=i}return!0},max:function(t){if(t.filter(y+",["+l.attr("type")+"=number]").filter("[max]").length&&""!==t.val()){var e=parseFloat(t.attr("max"))||0,i=l.parseFloat(t.val());return e>=i}return!0},step:function(t){if(t.filter(y+",["+l.attr("type")+"=number]").filter("[step]").length&&""!==t.val()){var e,i=parseFloat(t.attr("min"))||0,n=parseFloat(t.attr("step"))||1,r=parseFloat(t.val()),s=o(n);return s?(e=Math.pow(10,s),Math.floor((r-i)*e)%(n*e)/Math.pow(100,s)===0):(r-i)%n===0}return!0},email:function(t){return T(t,"[type=email],["+l.attr("type")+"=email]",g)},url:function(t){return T(t,"[type=url],["+l.attr("type")+"=url]",m)},date:function(t){return!t.filter("[type^=date],["+l.attr("type")+"=date]").length||""===t.val()||null!==l.parseDate(t.val(),t.attr(l.attr("format")))}},validateOnBlur:!0},destroy:function(){c.fn.destroy.call(this),this.element.off(h)},value:function(){return!!this._isValidated&&0===this.errors().length},_submit:function(t){return!!this.validate()||(t.stopPropagation(),t.stopImmediatePropagation(),t.preventDefault(),!1)},_checkElement:function(t){var e=this.value();this.validateInput(t),this.value()!==e&&this.trigger("change")},_attachEvents:function(){var e=this;e.element.is(b)&&e.element.on("submit"+h,C(e._submit,e)),e.options.validateOnBlur&&(e.element.is(v)?(e.element.on(w+h,function(){e._checkElement(e.element)}),e.element.is(_)&&e.element.on("click"+h,function(){e._checkElement(e.element)})):(e.element.on(w+h,e._inputSelector,function(){e._checkElement(t(this))}),e.element.on("click"+h,e._checkboxSelector,function(){e._checkElement(t(this))})))},validate:function(){var t,e,i,n,o=!1,r=this.value();if(this._errors={},this.element.is(v))o=this.validateInput(this.element);else{for(n=!1,t=this.element.find(this._inputSelector),e=0,i=t.length;e<i;e++)this.validateInput(t.eq(e))||(n=!0);o=!n}return this.trigger("validate",{valid:o}),r!==o&&this.trigger("change"),o},validateInput:function(e){var i,o,s,a,c,h,d,g,m,v;return e=t(e),this._isValidated=!0,i=this,o=i._errorTemplate,s=i._checkValidity(e),a=s.valid,c="."+u,h=e.attr(x)||"",d=i._findMessageContainer(h).add(e.next(c).filter(function(){var e=t(this);return!e.filter("["+l.attr("for")+"]").length||e.attr(l.attr("for"))===h})).hide(),e.removeAttr("aria-invalid"),a?delete i._errors[h]:(g=i._extractMessage(e,s.key),i._errors[h]=g,m=r(o({message:n(g)})),v=d.attr("id"),i._decorateMessageContainer(m,h),v&&m.attr("id",v),d.replaceWith(m).length||m.insertAfter(e),m.show(),e.attr("aria-invalid",!0)),e.toggleClass(f,!a),e.toggleClass(p,a),a},hideMessages:function(){var t=this,e="."+u,i=t.element;i.is(v)?i.next(e).hide():i.find(e).hide()},_findMessageContainer:function(e){var i,n,o,r=l.ui.validator.messageLocators,a=t();for(n=0,o=this.element.length;n<o;n++)a=a.add(s(this.element[n].getElementsByTagName("*"),e));for(i in r)a=a.add(r[i].locate(this.element,e));return a},_decorateMessageContainer:function(t,e){var i,n=l.ui.validator.messageLocators;t.addClass(u).attr(l.attr("for"),e||"");for(i in n)n[i].decorate(t,e);t.attr("role","alert")},_extractMessage:function(t,e){var i=this,n=i.options.messages[e],o=t.attr(x);return n=l.isFunction(n)?n(t):n,l.format(t.attr(l.attr(e+"-msg"))||t.attr("validationMessage")||t.attr("title")||n||"",o,t.attr(e)||t.attr(l.attr(e)))},_checkValidity:function(t){var e,i=this.options.rules;for(e in i)if(!i[e].call(this,t))return{valid:!1,key:e};return{valid:!0}},errors:function(){var t,e=[],i=this._errors;for(t in i)e.push(i[t]);return e}}),l.ui.plugin(a)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.editable.min",["kendo.datepicker.min","kendo.numerictextbox.min","kendo.validator.min","kendo.binder.min"],t)}(function(){return function(t,e){function i(e){return e=null!=e?e:"",e.type||t.type(e)||"string"}function n(e){e.find(":input:not(:button, ["+a.attr("role")+"=upload], ["+a.attr("skip")+"], [type=file]), select").each(function(){var e=a.attr("bind"),i=this.getAttribute(e)||"",n="checkbox"===this.type||"radio"===this.type?"checked:":"value:",o=this.name;i.indexOf(n)===-1&&o&&(i+=(i.length?",":"")+n+o,t(this).attr(e,i))})}function o(t){var e,n,o=(t.model.fields||t.model)[t.field],r=i(o),s=o?o.validation:{},l=a.attr("type"),c=a.attr("bind"),h={name:t.field};for(e in s)n=s[e],p(e,_)>=0?h[l]=e:d(n)||(h[e]=f(n)?n.value||e:n),h[a.attr(e+"-msg")]=n.message;return p(r,_)>=0&&(h[l]=r),h[c]=("boolean"===r?"checked:":"value:")+t.field,h}function r(t){var e,i,n,o,r,s;if(t&&t.length)for(s=[],e=0,i=t.length;e<i;e++)n=t[e],r=n.text||n.value||n,o=null==n.value?n.text||n:n.value,s[e]={text:r,value:o};return s}function s(t,e){var i,n,o=t?t.validation||{}:{};for(i in o)n=o[i],f(n)&&n.value&&(n=n.value),d(n)&&(e[i]=n)}var a=window.kendo,l=a.ui,c=l.Widget,h=t.extend,u=a.support.browser.msie&&a.support.browser.version<9,d=a.isFunction,f=t.isPlainObject,p=t.inArray,g=/("|\%|'|\[|\]|\$|\.|\,|\:|\;|\+|\*|\&|\!|\#|\(|\)|<|>|\=|\?|\@|\^|\{|\}|\~|\/|\||`)/g,m='<div class="k-widget k-tooltip k-tooltip-validation" style="margin:0.5em"><span class="k-icon k-i-warning"> </span>#=message#<div class="k-callout k-callout-n"></div></div>',v="change",_=["url","email","number","date","boolean"],y={number:function(e,i){var n=o(i);t('<input type="text"/>').attr(n).appendTo(e).kendoNumericTextBox({format:i.format}),t("<span "+a.attr("for")+'="'+i.field+'" class="k-invalid-msg"/>').hide().appendTo(e)},date:function(e,i){var n=o(i),r=i.format;r&&(r=a._extractFormat(r)),n[a.attr("format")]=r,t('<input type="text"/>').attr(n).appendTo(e).kendoDatePicker({format:i.format}),t("<span "+a.attr("for")+'="'+i.field+'" class="k-invalid-msg"/>').hide().appendTo(e)},string:function(e,i){var n=o(i);t('<input type="text" class="k-input k-textbox"/>').attr(n).appendTo(e)},"boolean":function(e,i){var n=o(i);t('<input type="checkbox" />').attr(n).appendTo(e)},values:function(e,i){var n=o(i),s=a.stringify(r(i.values));t("<select "+a.attr("text-field")+'="text"'+a.attr("value-field")+'="value"'+a.attr("source")+"='"+(s?s.replace(/\'/g,"&apos;"):s)+"'"+a.attr("role")+'="dropdownlist"/>').attr(n).appendTo(e),t("<span "+a.attr("for")+'="'+i.field+'" class="k-invalid-msg"/>').hide().appendTo(e)}},w=c.extend({init:function(e,i){var n=this;i.target&&(i.$angular=i.target.options.$angular),c.fn.init.call(n,e,i),n._validateProxy=t.proxy(n._validate,n),n.refresh()},events:[v],options:{name:"Editable",editors:y,clearContainer:!0,errorTemplate:m},editor:function(t,e){var n=this,o=n.options.editors,r=f(t),s=r?t.field:t,l=n.options.model||{},c=r&&t.values,u=c?"values":i(e),d=r&&t.editor,p=d?t.editor:o[u],m=n.element.find("["+a.attr("container-for")+"="+s.replace(g,"\\$1")+"]");p=p?p:o.string,d&&"string"==typeof t.editor&&(p=function(e){e.append(t.editor)}),m=m.length?m:n.element,p(m,h(!0,{},r?t:{field:s},{model:l}))},_validate:function(e){var i,n=this,o=e.value,r=n._validationEventInProgress,s={},l=a.attr("bind"),c=e.field.replace(g,"\\$1"),h=RegExp("(value|checked)\\s*:\\s*"+c+"\\s*(,|$)");s[e.field]=e.value,i=t(":input["+l+'*="'+c+'"]',n.element).filter("["+a.attr("validate")+"!='false']").filter(function(){return h.test(t(this).attr(l))}),i.length>1&&(i=i.filter(function(){var e=t(this);return!e.is(":radio")||e.val()==o}));try{n._validationEventInProgress=!0,(!n.validatable.validateInput(i)||!r&&n.trigger(v,{values:s}))&&e.preventDefault()}finally{n._validationEventInProgress=!1}},end:function(){return this.validatable.validate()},destroy:function(){var t=this;t.angular("cleanup",function(){return{elements:t.element}}),c.fn.destroy.call(t),t.options.model.unbind("set",t._validateProxy),a.unbind(t.element),t.validatable&&t.validatable.destroy(),a.destroy(t.element),t.element.removeData("kendoValidator"),t.element.is("["+a.attr("role")+"=editable]")&&t.element.removeAttr(a.attr("role"))},refresh:function(){var i,o,r,l,c,h,d,p,g=this,m=g.options.fields||[],v=g.options.clearContainer?g.element.empty():g.element,_=g.options.model||{},y={};for(t.isArray(m)||(m=[m]),i=0,o=m.length;i<o;i++)r=m[i],l=f(r),c=l?r.field:r,h=(_.fields||_)[c],s(h,y),g.editor(r,h);if(g.options.target&&g.angular("compile",function(){return{elements:v,data:v.map(function(){return{dataItem:_}})}}),!o){d=_.fields||_;for(c in d)s(d[c],y)}n(v),g.validatable&&g.validatable.destroy(),a.bind(v,g.options.model),g.options.model.unbind("set",g._validateProxy),g.options.model.bind("set",g._validateProxy),g.validatable=new a.ui.Validator(v,{validateOnBlur:!1,errorTemplate:g.options.errorTemplate||e,rules:y}),p=v.find(":kendoFocusable").eq(0).focus(),u&&p.focus()}});l.plugin(w)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.window.min",["kendo.draganddrop.min"],t)}(function(){return function(t,e){function i(t){return e!==t}function n(t,e,i){return Math.max(Math.min(parseInt(t,10),i===1/0?i:parseInt(i,10)),parseInt(e,10))}function o(){return!this.type||this.type.toLowerCase().indexOf("script")>=0}function r(t){var e=this;e.owner=t,e._preventDragging=!1,e._draggable=new c(t.wrapper,{filter:">"+C,group:t.wrapper.id+"-resizing",dragstart:p(e.dragstart,e),drag:p(e.drag,e),dragend:p(e.dragend,e)}),e._draggable.userEvents.bind("press",p(e.addOverlay,e)),e._draggable.userEvents.bind("release",p(e.removeOverlay,e))}function s(t,e){var i=this;i.owner=t,i._preventDragging=!1,i._draggable=new c(t.wrapper,{filter:e,group:t.wrapper.id+"-moving",dragstart:p(i.dragstart,i),drag:p(i.drag,i),dragend:p(i.dragend,i),dragcancel:p(i.dragcancel,i)}),i._draggable.userEvents.stopPropagation=!1}var a=window.kendo,l=a.ui.Widget,c=a.ui.Draggable,h=t.isPlainObject,u=a._activeElement,d=a._outerWidth,f=a._outerHeight,p=t.proxy,g=t.extend,m=t.each,v=a.template,_="body",y=".kendoWindow",w=".k-window",x=".k-window-title",b=x+"bar",k=".k-window-content",C=".k-resize-handle",S=".k-overlay",T="k-content-frame",A="k-i-loading",P="k-state-hover",D="k-state-focused",M="k-window-maximized",E=":visible",I="hidden",B="cursor",z="open",L="activate",R="deactivate",O="close",V="refresh",F="minimize",N="maximize",H="resizeStart",U="resize",j="resizeEnd",G="dragstart",W="dragend",q="error",$="overflow",Y="zIndex",X=".k-window-actions .k-i-minimize,.k-window-actions .k-i-maximize",Q=".k-i-pin",K=".k-i-unpin",Z=Q+","+K,J=".k-window-titlebar .k-window-action",tt=".k-window-titlebar .k-i-refresh",et=a.isLocalUrl,it=l.extend({init:function(n,r){var s,c,u,d,f,g,m,v=this,_={},C=!1,S=r&&r.actions&&!r.actions.length;l.fn.init.call(v,n,r),r=v.options,d=r.position,n=v.element,f=r.content,S&&(r.actions=[]),v.appendTo=t(r.appendTo),f&&!h(f)&&(f=r.content={url:f}),n.find("script").filter(o).remove(),n.parent().is(v.appendTo)||d.top!==e&&d.left!==e||(n.is(E)?(_=n.offset(),C=!0):(c=n.css("visibility"),u=n.css("display"),n.css({visibility:I,display:""}),_=n.offset(),n.css({visibility:c,display:u})),d.top===e&&(d.top=_.top),d.left===e&&(d.left=_.left)),i(r.visible)&&null!==r.visible||(r.visible=n.is(E)),s=v.wrapper=n.closest(w),n.is(".k-content")&&s[0]||(n.addClass("k-window-content k-content"),v._createWindow(n,r),s=v.wrapper=n.closest(w),v._dimensions()),v._position(),r.pinned&&v.pin(!0),f&&v.refresh(f),r.visible&&v.toFront(),g=s.children(k),v._tabindex(g),r.visible&&r.modal&&v._overlay(s.is(E)).css({opacity:.5}),s.on("mouseenter"+y,J,p(v._buttonEnter,v)).on("mouseleave"+y,J,p(v._buttonLeave,v)).on("click"+y,"> "+J,p(v._windowActionHandler,v)),g.on("keydown"+y,p(v._keydown,v)).on("focus"+y,p(v._focus,v)).on("blur"+y,p(v._blur,v)),this._resizable(),this._draggable(),m=n.attr("id"),m&&(m+="_wnd_title",s.children(b).children(x).attr("id",m),g.attr({role:"dialog","aria-labelledby":m})),s.add(s.children(".k-resize-handle,"+b)).on("mousedown"+y,p(v.toFront,v)),v.touchScroller=a.touchScroller(n),v._resizeHandler=p(v._onDocumentResize,v),v._marker=a.guid().substring(0,8),t(window).on("resize"+y+v._marker,v._resizeHandler),r.visible&&(v.trigger(z),v.trigger(L)),a.notify(v)},_buttonEnter:function(e){t(e.currentTarget).addClass(P)},_buttonLeave:function(e){t(e.currentTarget).removeClass(P)},_focus:function(){this.wrapper.addClass(D)},_blur:function(){this.wrapper.removeClass(D)},_dimensions:function(){var t,e,i=this.wrapper,o=this.options,r=o.width,s=o.height,a=o.maxHeight,l=["minWidth","minHeight","maxWidth","maxHeight"];for(this.title(o.title),t=0;t<l.length;t++)e=o[l[t]]||"",e!=1/0&&i.css(l[t],e);a!=1/0&&this.element.css("maxHeight",a),i.width(r?(""+r).indexOf("%")>0?r:n(r,o.minWidth,o.maxWidth):""),i.height(s?(""+s).indexOf("%")>0?s:n(s,o.minHeight,o.maxHeight):""),o.visible||i.hide()},_position:function(){var t=this.wrapper,e=this.options.position;0===e.top&&(e.top=""+e.top),0===e.left&&(e.left=""+e.left),t.css({top:e.top||"",left:e.left||""})},_animationOptions:function(t){var e=this.options.animation,i={open:{effects:{}},close:{hide:!0,effects:{}}};return e&&e[t]||i[t]},_resize:function(){a.resize(this.element.children())},_resizable:function(){var e=this.options.resizable,i=this.wrapper;this.resizing&&(i.off("dblclick"+y).children(C).remove(),this.resizing.destroy(),this.resizing=null),e&&(i.on("dblclick"+y,b,p(function(e){t(e.target).closest(".k-window-action").length||this.toggleMaximization()},this)),m("n e s w se sw ne nw".split(" "),function(t,e){i.append(nt.resizeHandle(e))}),this.resizing=new r(this)),i=null},_draggable:function(){var t=this.options.draggable;this.dragging&&(this.dragging.destroy(),this.dragging=null),t&&(this.dragging=new s(this,t.dragHandle||b))},_actions:function(){var e=this.options.actions,i=this.wrapper.children(b),n=i.find(".k-window-actions");e=t.map(e,function(t){return{name:t}}),n.html(a.render(nt.action,e))},setOptions:function(t){var i,n;l.fn.setOptions.call(this,t),i=this.options.scrollable!==!1,this.restore(),this._dimensions(),this._position(),this._resizable(),this._draggable(),this._actions(),e!==t.modal&&(n=this.options.visible!==!1,this._overlay(t.modal&&n)),this.element.css($,i?"":"hidden")},events:[z,L,R,O,F,N,V,H,U,j,G,W,q],options:{name:"Window",animation:{open:{effects:{zoom:{direction:"in"},fade:{direction:"in"}},duration:350},close:{effects:{zoom:{direction:"out",properties:{scale:.7}},fade:{direction:"out"}},duration:350,hide:!0}},title:"",actions:["Close"],autoFocus:!0,modal:!1,resizable:!0,draggable:!0,minWidth:90,minHeight:50,maxWidth:1/0,maxHeight:1/0,pinned:!1,scrollable:!0,position:{},content:null,visible:null,height:null,width:null,appendTo:"body",isMaximized:!1,isMinimized:!1},_closable:function(){return t.inArray("close",t.map(this.options.actions,function(t){return t.toLowerCase()}))>-1},_keydown:function(t){var e,i,o,r,s,l,c=this,h=c.options,u=a.keys,d=t.keyCode,f=c.wrapper,p=10,g=c.options.isMaximized;t.target!=t.currentTarget||c._closing||(d==u.ESC&&c._closable()&&c._close(!1),!h.draggable||t.ctrlKey||g||(e=a.getOffset(f),d==u.UP?i=f.css("top",e.top-p):d==u.DOWN?i=f.css("top",e.top+p):d==u.LEFT?i=f.css("left",e.left-p):d==u.RIGHT&&(i=f.css("left",e.left+p))),h.resizable&&t.ctrlKey&&!g&&(d==u.UP?(i=!0,r=f.height()-p):d==u.DOWN&&(i=!0,r=f.height()+p),d==u.LEFT?(i=!0,o=f.width()-p):d==u.RIGHT&&(i=!0,o=f.width()+p),i&&(s=n(o,h.minWidth,h.maxWidth),l=n(r,h.minHeight,h.maxHeight),isNaN(s)||(f.width(s),c.options.width=s+"px"),isNaN(l)||(f.height(l),c.options.height=l+"px"),c.resize())),i&&t.preventDefault())},_overlay:function(e){var i=this.appendTo.children(S),n=this.wrapper;return i.length||(i=t("<div class='k-overlay' />")),i.insertBefore(n[0]).toggle(e).css(Y,parseInt(n.css(Y),10)-1),i},_actionForIcon:function(t){var e=/\bk-i-\w+\b/.exec(t[0].className)[0];return{"k-i-close":"_close","k-i-maximize":"maximize","k-i-minimize":"minimize","k-i-restore":"restore","k-i-refresh":"refresh","k-i-pin":"pin","k-i-unpin":"unpin"}[e]},_windowActionHandler:function(i){var n,o;if(!this._closing)return n=t(i.target).closest(".k-window-action").find(".k-icon"),o=this._actionForIcon(n),o?(i.preventDefault(),this[o](),!1):e},_modals:function(){var e=this,i=t(w).filter(function(){var i=t(this),n=e._object(i),o=n&&n.options;return o&&o.modal&&o.visible&&o.appendTo===e.options.appendTo&&i.is(E)}).sort(function(e,i){return+t(e).css("zIndex")-+t(i).css("zIndex")});return e=null,i},_object:function(t){var i=t.children(k),n=a.widgetInstance(i);return n instanceof it?n:e},center:function(){var e,i,n=this,o=n.options.position,r=n.wrapper,s=t(window),a=0,l=0;return n.options.isMaximized?n:(n.options.pinned||(a=s.scrollTop(),l=s.scrollLeft()),i=l+Math.max(0,(s.width()-r.width())/2),e=a+Math.max(0,(s.height()-r.height()-parseInt(r.css("paddingTop"),10))/2),r.css({left:i,top:e}),o.top=e,o.left=i,n)},title:function(t){var e,i=this,n=i.wrapper,o=i.options,r=n.children(b),s=r.children(x);return arguments.length?(t===!1?(n.addClass("k-window-titleless"),r.remove()):(r.length?s.html(t):(n.prepend(nt.titlebar(o)),i._actions(),r=n.children(b)),e=parseInt(f(r),10),n.css("padding-top",e),r.css("margin-top",-e)),i.options.title=t,i):s.html()},content:function(t,e){var n=this.wrapper.children(k),o=n.children(".km-scroll-container");return n=o[0]?o:n,i(t)?(this.angular("cleanup",function(){return{elements:n.children()}}),a.destroy(this.element.children()),n.empty().html(t),this.angular("compile",function(){var t,i=[];for(t=n.length;--t>=0;)i.push({dataItem:e});return{elements:n.children(),data:i}}),this):n.html()},open:function(){var e,i,n,o=this,r=o.wrapper,s=o.options,l=this._animationOptions("open"),c=r.children(k),h=t(document);return o.trigger(z)||(o._closing&&r.kendoStop(!0,!0),o._closing=!1,o.toFront(),s.autoFocus&&o.element.focus(),s.visible=!0,s.modal&&(i=!!o._modals().length,e=o._overlay(i),e.kendoStop(!0,!0),l.duration&&a.effects.Fade&&!i?(n=a.fx(e).fadeIn(),n.duration(l.duration||0),n.endValue(.5),n.play()):e.css("opacity",.5),e.show()),r.is(E)||(c.css($,I),r.show().kendoStop().kendoAnimate({effects:l.effects,duration:l.duration,complete:p(this._activate,this)}))),s.isMaximized&&(o._documentScrollTop=h.scrollTop(),o._documentScrollLeft=h.scrollLeft(),t("html, body").css($,I)),o},_activate:function(){var t=this.options.scrollable!==!1;this.options.autoFocus&&this.element.focus(),this.element.css($,t?"":"hidden"),a.resize(this.element.children()),this.trigger(L)},_removeOverlay:function(i){var n,o=this._modals(),r=this.options,s=r.modal&&!o.length,l=r.modal?this._overlay(!0):t(e),c=this._animationOptions("close");s?!i&&c.duration&&a.effects.Fade?(n=a.fx(l).fadeOut(),n.duration(c.duration||0),n.startValue(.5),n.play()):this._overlay(!1).remove():o.length&&this._object(o.last())._overlay(!0)},_close:function(e){var i=this,n=i.wrapper,o=i.options,r=this._animationOptions("open"),s=this._animationOptions("close"),a=t(document);if(n.is(E)&&!i.trigger(O,{userTriggered:!e})){if(i._closing)return;i._closing=!0,o.visible=!1,t(w).each(function(e,i){var o=t(i).children(k);i!=n&&o.find("> ."+T).length>0&&o.children(S).remove()}),this._removeOverlay(),n.kendoStop().kendoAnimate({effects:s.effects||r.effects,reverse:s.reverse===!0,duration:s.duration,complete:p(this._deactivate,this)})}i.options.isMaximized&&(t("html, body").css($,""),i._documentScrollTop&&i._documentScrollTop>0&&a.scrollTop(i._documentScrollTop),i._documentScrollLeft&&i._documentScrollLeft>0&&a.scrollLeft(i._documentScrollLeft))},_deactivate:function(){var t,e=this;e.wrapper.hide().css("opacity",""),e.trigger(R),e.options.modal&&(t=e._object(e._modals().last()),t&&t.toFront())},close:function(){return this._close(!0),this},_actionable:function(e){return t(e).is(J+","+J+" .k-icon,:input,a")},_shouldFocus:function(e){var i=u(),n=this.element;return this.options.autoFocus&&!t(i).is(n)&&!this._actionable(e)&&(!n.find(i).length||!n.find(e).length)},toFront:function(e){var i,n,o=this,r=o.wrapper,s=r[0],a=+r.css(Y),l=a,c=e&&e.target||null;return t(w).each(function(e,i){var n=t(i),o=n.css(Y),r=n.children(k);isNaN(o)||(a=Math.max(+o,a)),i!=s&&r.find("> ."+T).length>0&&r.append(nt.overlay)}),(!r[0].style.zIndex||l<a)&&r.css(Y,a+2),o.element.find("> .k-overlay").remove(),o._shouldFocus(c)&&(o.element.focus(),i=t(window).scrollTop(),n=parseInt(r.position().top,10),!o.options.pinned&&n>0&&n<i&&(i>0?t(window).scrollTop(n):r.css("top",i))),r=null,o},toggleMaximization:function(){return this._closing?this:this[this.options.isMaximized?"restore":"maximize"]()},restore:function(){var e=this,i=e.options,n=i.minHeight,o=e.restoreOptions,r=t(document);return i.isMaximized||i.isMinimized?(n&&n!=1/0&&e.wrapper.css("min-height",n),e.wrapper.css({position:i.pinned?"fixed":"absolute",left:o.left,top:o.top,width:o.width,height:o.height}).removeClass(M).find(".k-window-content,.k-resize-handle").show().end().find(".k-window-titlebar .k-i-restore").parent().remove().end().end().find(X).parent().show().end().end().find(Z).parent().show(),e.options.width=o.width,e.options.height=o.height,t("html, body").css($,""),this._documentScrollTop&&this._documentScrollTop>0&&r.scrollTop(this._documentScrollTop),this._documentScrollLeft&&this._documentScrollLeft>0&&r.scrollLeft(this._documentScrollLeft),i.isMaximized=i.isMinimized=!1,e.resize(),e):e},_sizingAction:function(t,e){var i=this,n=i.wrapper,o=n[0].style,r=i.options;return r.isMaximized||r.isMinimized?i:(i.restoreOptions={width:o.width,height:o.height},n.children(C).hide().end().children(b).find(X).parent().hide().eq(0).before(nt.action({name:"Restore"})),e.call(i),i.wrapper.children(b).find(Z).parent().toggle("maximize"!==t),i.trigger(t),i)},maximize:function(){return this._sizingAction("maximize",function(){var e=this,i=e.wrapper,n=i.position(),o=t(document);g(e.restoreOptions,{left:n.left,top:n.top}),i.css({left:0,top:0,position:"fixed"}).addClass(M),this._documentScrollTop=o.scrollTop(),this._documentScrollLeft=o.scrollLeft(),t("html, body").css($,I),e.options.isMaximized=!0,e._onDocumentResize()}),this},isMaximized:function(){return this.options.isMaximized},minimize:function(){return this._sizingAction("minimize",function(){var t=this;t.wrapper.css({height:"",minHeight:""}),t.element.hide(),t.options.isMinimized=!0}),this},isMinimized:function(){return this.options.isMinimized},pin:function(e){var i=this,n=t(window),o=i.wrapper,r=parseInt(o.css("top"),10),s=parseInt(o.css("left"),10);(e||!i.options.pinned&&!i.options.isMaximized)&&(o.css({position:"fixed",top:r-n.scrollTop(),left:s-n.scrollLeft()}),o.children(b).find(Q).addClass("k-i-unpin").removeClass("k-i-pin"),i.options.pinned=!0)},unpin:function(){var e=this,i=t(window),n=e.wrapper,o=parseInt(n.css("top"),10),r=parseInt(n.css("left"),10);e.options.pinned&&!e.options.isMaximized&&(n.css({position:"",top:o+i.scrollTop(),left:r+i.scrollLeft()}),n.children(b).find(K).addClass("k-i-pin").removeClass("k-i-unpin"),e.options.pinned=!1);
},_onDocumentResize:function(){var e,i,n=this,o=n.wrapper,r=t(window),s=a.support.zoomLevel();n.options.isMaximized&&(e=r.width()/s,i=r.height()/s-parseInt(o.css("padding-top"),10),o.css({width:e,height:i}),n.options.width=e,n.options.height=i,n.resize())},refresh:function(e){var n,o,r,s=this,a=s.options,l=t(s.element);return h(e)||(e={url:e}),e=g({},a.content,e),o=i(a.iframe)?a.iframe:e.iframe,r=e.url,r?(i(o)||(o=!et(r)),o?(n=l.find("."+T)[0],n?n.src=r||n.src:l.html(nt.contentFrame(g({},a,{content:e}))),l.find("."+T).unbind("load"+y).on("load"+y,p(this._triggerRefresh,this))):s._ajaxRequest(e)):(e.template&&s.content(v(e.template)({})),s.trigger(V)),l.toggleClass("k-window-iframecontent",!!o),s},_triggerRefresh:function(){this.trigger(V)},_ajaxComplete:function(){clearTimeout(this._loadingIconTimeout),this.wrapper.find(tt).removeClass(A)},_ajaxError:function(t,e){this.trigger(q,{status:e,xhr:t})},_ajaxSuccess:function(t){return function(e){var i=e;t&&(i=v(t)(e||{})),this.content(i,e),this.element.prop("scrollTop",0),this.trigger(V)}},_showLoading:function(){this.wrapper.find(tt).addClass(A)},_ajaxRequest:function(e){this._loadingIconTimeout=setTimeout(p(this._showLoading,this),100),t.ajax(g({type:"GET",dataType:"html",cache:!1,error:p(this._ajaxError,this),complete:p(this._ajaxComplete,this),success:p(this._ajaxSuccess(e.template),this)},e))},_destroy:function(){this.resizing&&this.resizing.destroy(),this.dragging&&this.dragging.destroy(),this.wrapper.off(y).children(k).off(y).end().find(".k-resize-handle,.k-window-titlebar").off(y),t(window).off("resize"+y+this._marker),clearTimeout(this._loadingIconTimeout),l.fn.destroy.call(this),this.unbind(e),a.destroy(this.wrapper),this._removeOverlay(!0)},destroy:function(){this._destroy(),this.wrapper.empty().remove(),this.wrapper=this.appendTo=this.element=t()},_createWindow:function(){var e,i,n=this.element,o=this.options,r=a.support.isRtl(n);o.scrollable===!1&&n.css("overflow","hidden"),i=t(nt.wrapper(o)),e=n.find("iframe:not(.k-content)").map(function(){var t=this.getAttribute("src");return this.src="",t}),i.toggleClass("k-rtl",r).appendTo(this.appendTo).append(n).find("iframe:not(.k-content)").each(function(t){this.src=e[t]}),i.find(".k-window-title").css(r?"left":"right",d(i.find(".k-window-actions"))+10),n.css("visibility","").show(),n.find("[data-role=editor]").each(function(){var e=t(this).data("kendoEditor");e&&e.refresh()}),i=n=null}}),nt={wrapper:v("<div class='k-widget k-window' />"),action:v("<a role='button' href='\\#' class='k-window-action k-link' aria-label='#= name #'><span class='k-icon k-i-#= name.toLowerCase() #'></span></a>"),titlebar:v("<div class='k-window-titlebar k-header'>&nbsp;<span class='k-window-title'>#= title #</span><div class='k-window-actions' /></div>"),overlay:"<div class='k-overlay' />",contentFrame:v("<iframe frameborder='0' title='#= title #' class='"+T+"' src='#= content.url #'>This page requires frames in order to show content</iframe>"),resizeHandle:v("<div class='k-resize-handle k-resize-#= data #'></div>")};r.prototype={addOverlay:function(){this.owner.wrapper.append(nt.overlay)},removeOverlay:function(){this.owner.wrapper.find(S).remove()},dragstart:function(e){var i=this,n=i.owner,o=n.wrapper;i._preventDragging=n.trigger(H),i._preventDragging||(i.elementPadding=parseInt(o.css("padding-top"),10),i.initialPosition=a.getOffset(o,"position"),i.resizeDirection=e.currentTarget.prop("className").replace("k-resize-handle k-resize-",""),i.initialSize={width:o.width(),height:o.height()},i.containerOffset=a.getOffset(n.appendTo,"position"),o.children(C).not(e.currentTarget).hide(),t(_).css(B,e.currentTarget.css(B)))},drag:function(e){var i,o,r,s,a,l,c,h,u,d,f,p,g,m,v;this._preventDragging||(i=this,o=i.owner,r=o.wrapper,s=o.options,a=i.resizeDirection,l=i.containerOffset,c=i.initialPosition,h=i.initialSize,g=Math.max(e.x.location,0),m=Math.max(e.y.location,0),a.indexOf("e")>=0?(u=g-c.left-l.left,r.width(n(u,s.minWidth,s.maxWidth))):a.indexOf("w")>=0&&(p=c.left+h.width+l.left,u=n(p-g,s.minWidth,s.maxWidth),r.css({left:p-u-l.left,width:u})),v=m,o.options.pinned&&(v-=t(window).scrollTop()),a.indexOf("s")>=0?(d=v-c.top-i.elementPadding-l.top,r.height(n(d,s.minHeight,s.maxHeight))):a.indexOf("n")>=0&&(f=c.top+h.height+l.top,d=n(f-v,s.minHeight,s.maxHeight),r.css({top:f-d-l.top,height:d})),u&&(o.options.width=u+"px"),d&&(o.options.height=d+"px"),o.resize())},dragend:function(e){if(!this._preventDragging){var i=this,n=i.owner,o=n.wrapper;return o.children(C).not(e.currentTarget).show(),t(_).css(B,""),n.touchScroller&&n.touchScroller.reset(),27==e.keyCode&&o.css(i.initialPosition).css(i.initialSize),n.trigger(j),!1}},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},s.prototype={dragstart:function(e){var i=this.owner,n=i.element,o=n.find(".k-window-actions"),r=a.getOffset(i.appendTo);this._preventDragging=i.trigger(G),this._preventDragging||(i.initialWindowPosition=a.getOffset(i.wrapper,"position"),i.initialPointerPosition={left:e.x.client,top:e.y.client},i.startPosition={left:e.x.client-i.initialWindowPosition.left,top:e.y.client-i.initialWindowPosition.top},i.minLeftPosition=o.length>0?d(o)+parseInt(o.css("right"),10)-d(n):20-d(n),i.minLeftPosition-=r.left,i.minTopPosition=-r.top,i.wrapper.append(nt.overlay).children(C).hide(),t(_).css(B,e.currentTarget.css(B)))},drag:function(e){var i,n;this._preventDragging||(i=this.owner,n=i.options.position,n.top=Math.max(e.y.client-i.startPosition.top,i.minTopPosition),n.left=Math.max(e.x.client-i.startPosition.left,i.minLeftPosition),a.support.transforms?t(i.wrapper).css("transform","translate("+(e.x.client-i.initialPointerPosition.left)+"px, "+(e.y.client-i.initialPointerPosition.top)+"px)"):t(i.wrapper).css(n))},_finishDrag:function(){var e=this.owner;e.wrapper.children(C).toggle(!e.options.isMinimized).end().find(S).remove(),t(_).css(B,"")},dragcancel:function(t){this._preventDragging||(this._finishDrag(),t.currentTarget.closest(w).css(this.owner.initialWindowPosition))},dragend:function(){if(!this._preventDragging)return t(this.owner.wrapper).css(this.owner.options.position).css("transform",""),this._finishDrag(),this.owner.trigger(W),!1},destroy:function(){this._draggable&&this._draggable.destroy(),this._draggable=this.owner=null}},a.ui.plugin(it)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.list.min",["kendo.data.min","kendo.popup.min"],t)}(function(){return function(t,e){function i(t,i){return t!==e&&""!==t&&null!==t&&("boolean"===i?t=!!t:"number"===i?t=+t:"string"===i&&(t=""+t)),t}function n(t){return t[t.length-1]}function o(t){var e=t.selectedIndex;return e>-1?t.options[e]:{}}function r(t,e){var i,n,o,r,s=e.length,a=t.length,l=[],c=[];if(a)for(o=0;o<a;o++){for(i=t[o],n=!1,r=0;r<s;r++)if(i===e[r]){n=!0,l.push({index:o,item:i});break}n||c.push(i)}return{changed:l,unchanged:c}}function s(e,i){var n,o=!1;return e.filters&&(n=t.grep(e.filters,function(t){return o=s(t,i),t.filters?t.filters.length:t.field!=i}),o||e.filters.length===n.length||(o=!0),e.filters=n),o}var a,l,c=window.kendo,h=c.ui,u=c._outerWidth,d=c._outerHeight,f=h.Widget,p=c.keys,g=c.support,m=c.htmlEncode,v=c._activeElement,_=c.data.ObservableArray,y="id",w="change",x="k-state-focused",b="k-state-hover",k="k-i-loading",C="k-loading-hidden",S="open",T="close",A="cascade",P="select",D="selected",M="requestStart",E="requestEnd",I="width",B=t.extend,z=t.proxy,L=t.isArray,R=g.browser,O=R.msie,V=O&&R.version<9,F=/"/g,N={ComboBox:"DropDownList",DropDownList:"ComboBox"},H=c.ui.DataBoundWidget.extend({init:function(e,i){var n,o=this,r=o.ns;f.fn.init.call(o,e,i),e=o.element,i=o.options,o._isSelect=e.is(P),o._isSelect&&o.element[0].length&&(i.dataSource||(i.dataTextField=i.dataTextField||"text",i.dataValueField=i.dataValueField||"value")),o.ul=t('<ul unselectable="on" class="k-list k-reset"/>').attr({tabIndex:-1,"aria-hidden":!0}),o.list=t("<div class='k-list-container'/>").append(o.ul).on("mousedown"+r,z(o._listMousedown,o)),n=e.attr(y),n&&(o.list.attr(y,n+"-list"),o.ul.attr(y,n+"_listbox")),o._header(),o._noData(),o._footer(),o._accessors(),o._initValue()},options:{valuePrimitive:!1,footerTemplate:"",headerTemplate:"",noDataTemplate:"No data found."},setOptions:function(t){f.fn.setOptions.call(this,t),t&&t.enable!==e&&(t.enabled=t.enable),this._header(),this._noData(),this._footer(),this._renderFooter(),this._renderNoData()},focus:function(){this._focused.focus()},readonly:function(t){this._editable({readonly:t===e||t,disable:!1})},enable:function(t){this._editable({readonly:!1,disable:!(t=t===e||t)})},_listOptions:function(e){var i=this,n=i.options,o=n.virtual,r=z(i._listBound,i);return o="object"==typeof o?o:{},e=t.extend({autoBind:!1,selectable:!0,dataSource:i.dataSource,click:z(i._click,i),change:z(i._listChange,i),activate:z(i._activateItem,i),deactivate:z(i._deactivateItem,i),dataBinding:function(){i.trigger("dataBinding")},dataBound:r,height:n.height,dataValueField:n.dataValueField,dataTextField:n.dataTextField,groupTemplate:n.groupTemplate,fixedGroupTemplate:n.fixedGroupTemplate,template:n.template},e,o),e.template||(e.template="#:"+c.expr(e.dataTextField,"data")+"#"),n.$angular&&(e.$angular=n.$angular),e},_initList:function(){var t=this,e=t._listOptions({selectedItemChange:z(t._listChange,t)});t.listView=t.options.virtual?new c.ui.VirtualList(t.ul,e):new c.ui.StaticList(t.ul,e),t.listView.bind("listBound",z(t._listBound,t)),t._setListValue()},_setListValue:function(t){t=t||this.options.value,t!==e&&this.listView.value(t).done(z(this._updateSelectionState,this))},_updateSelectionState:t.noop,_listMousedown:function(t){this.filterInput&&this.filterInput[0]===t.target||t.preventDefault()},_isFilterEnabled:function(){var t=this.options.filter;return t&&"none"!==t},_hideClear:function(){var t=this;t._clear&&this._clear.addClass(C)},_showClear:function(){var t=this;t._clear&&this._clear.removeClass(C)},_clearValue:function(){this.listView.value([]),this._clearText(),this._accessor(""),this._isFilterEnabled()&&this._filter({word:"",open:!1}),this._change()},_clearText:function(){this.text("")},_clearFilter:function(){this.options.virtual||this.listView.bound(!1),this._filterSource()},_filterSource:function(t,e){var i,n=this,o=n.options,r=n.dataSource,a=B({},r.filter()||{}),l=t||a.filters&&a.filters.length&&!t,c=s(a,o.dataTextField);(t||c)&&n.trigger("filtering",{filter:t})||(a={filters:a.filters||[],logic:"and"},t&&a.filters.push(t),n._cascading&&this.listView.setDSFilter(a),i=B({},{page:l?1:r.page(),pageSize:l?r.options.pageSize:r.pageSize(),sort:r.sort(),filter:r.filter(),group:r.group(),aggregate:r.aggregate()},{filter:a}),r[e?"read":"query"](r._mergeState(i)))},_angularElement:function(t,e){t&&this.angular(e,function(){return{elements:t}})},_noData:function(){var i=t(this.noData),n=this.options.noDataTemplate;return this.angular("cleanup",function(){return{elements:i}}),c.destroy(i),i.remove(),n?(this.noData=t('<div class="k-nodata" style="display:none"><div></div></div>').appendTo(this.list),this.noDataTemplate="function"!=typeof n?c.template(n):n,e):(this.noData=null,e)},_renderNoData:function(){var t=this.noData;t&&(this._angularElement(t,"cleanup"),t.children(":first").html(this.noDataTemplate({instance:this})),this._angularElement(t,"compile"))},_toggleNoData:function(e){t(this.noData).toggle(e)},_footer:function(){var i=t(this.footer),n=this.options.footerTemplate;return this._angularElement(i,"cleanup"),c.destroy(i),i.remove(),n?(this.footer=t('<div class="k-footer"></div>').appendTo(this.list),this.footerTemplate="function"!=typeof n?c.template(n):n,e):(this.footer=null,e)},_renderFooter:function(){var t=this.footer;t&&(this._angularElement(t,"cleanup"),t.html(this.footerTemplate({instance:this})),this._angularElement(t,"compile"))},_header:function(){var i,n=t(this.header),o=this.options.headerTemplate;return this._angularElement(n,"cleanup"),c.destroy(n),n.remove(),o?(i="function"!=typeof o?c.template(o):o,n=t(i({})),this.header=n[0]?n:null,this.list.prepend(n),this._angularElement(this.header,"compile"),e):(this.header=null,e)},_allowOpening:function(){return this.options.noDataTemplate||this.dataSource.flatView().length},_initValue:function(){var t=this,e=t.options.value;null!==e?t.element.val(e):(e=t._accessor(),t.options.value=e),t._old=e},_ignoreCase:function(){var t,e=this,i=e.dataSource.reader.model;i&&i.fields&&(t=i.fields[e.options.dataTextField],t&&t.type&&"string"!==t.type&&(e.options.ignoreCase=!1))},_focus:function(t){return this.listView.focus(t)},_filter:function(t){var e=this,i=e.options,n=i.ignoreCase,o=i.dataTextField,r={value:n?t.word.toLowerCase():t.word,field:o,operator:i.filter,ignoreCase:n};e._open=t.open,e._filterSource(r)},search:function(t){var e=this.options;t="string"==typeof t?t:this._inputValue(),clearTimeout(this._typingTimeout),(!e.enforceMinLength&&!t.length||t.length>=e.minLength)&&(this._state="filter",this._isFilterEnabled()?this._filter({word:t,open:!0}):this._searchByWord(t))},current:function(t){return this._focus(t)},items:function(){return this.ul[0].children},destroy:function(){var t=this,e=t.ns;f.fn.destroy.call(t),t._unbindDataSource(),t.listView.destroy(),t.list.off(e),t.popup.destroy(),t._form&&t._form.off("reset",t._resetHandler)},dataItem:function(i){var n=this;if(i===e)return n.listView.selectedDataItems()[0];if("number"!=typeof i){if(n.options.virtual)return n.dataSource.getByUid(t(i).data("uid"));i=t(n.items()).index(i)}return n.dataSource.flatView()[i]},_activateItem:function(){var t=this.listView.focus();t&&this._focused.add(this.filterInput).attr("aria-activedescendant",t.attr("id"))},_deactivateItem:function(){this._focused.add(this.filterInput).removeAttr("aria-activedescendant")},_accessors:function(){var t=this,e=t.element,i=t.options,n=c.getter,o=e.attr(c.attr("text-field")),r=e.attr(c.attr("value-field"));!i.dataTextField&&o&&(i.dataTextField=o),!i.dataValueField&&r&&(i.dataValueField=r),t._text=n(i.dataTextField),t._value=n(i.dataValueField)},_aria:function(t){var i=this,n=i.options,o=i._focused.add(i.filterInput);n.suggest!==e&&o.attr("aria-autocomplete",n.suggest?"both":"list"),t=t?t+" "+i.ul[0].id:i.ul[0].id,o.attr("aria-owns",t),i.ul.attr("aria-live",i._isFilterEnabled()?"polite":"off")},_blur:function(){var t=this;t._change(),t.close()},_change:function(){var t,n=this,o=n.selectedIndex,r=n.options.value,s=n.value();n._isSelect&&!n.listView.bound()&&r&&(s=r),s!==i(n._old,typeof s)?t=!0:o!==e&&o!==n._oldIndex&&(t=!0),t&&(n._old=s,n._oldIndex=o,n._typing||n.element.trigger(w),n.trigger(w)),n.typing=!1},_data:function(){return this.dataSource.view()},_enable:function(){var t=this,i=t.options,n=t.element.is("[disabled]");i.enable!==e&&(i.enabled=i.enable),!i.enabled||n?t.enable(!1):t.readonly(t.element.is("[readonly]"))},_dataValue:function(t){var i=this._value(t);return i===e&&(i=this._text(t)),i},_offsetHeight:function(){var e=0,i=this.listView.content.prevAll(":visible");return i.each(function(){var i=t(this);e+=d(i.hasClass("k-list-filter")?i.children():i)}),e},_height:function(i){var n,o,r,s=this,a=s.list,l=s.options.height,c=s.popup.visible();if(i||s.options.noDataTemplate){if(o=a.add(a.parent(".k-animation-container")).show(),!a.is(":visible"))return o.hide(),e;l=s.listView.content[0].scrollHeight>l?l:"auto",o.height(l),"auto"!==l&&(n=s._offsetHeight(),r=d(t(s.footer))||0,l=l-n-r),s.listView.content.height(l),c||o.hide()}return l},_adjustListWidth:function(){var t,e,i=this.list,n=i[0].style.width,o=this.wrapper;if(i.data(I)||!n)return t=window.getComputedStyle?window.getComputedStyle(o[0],null):0,e=parseFloat(t&&t.width)||u(o),t&&R.msie&&(e+=parseFloat(t.paddingLeft)+parseFloat(t.paddingRight)+parseFloat(t.borderLeftWidth)+parseFloat(t.borderRightWidth)),n="border-box"!==i.css("box-sizing")?e-(u(i)-i.width()):e,i.css({fontFamily:o.css("font-family"),width:this.options.autoWidth?"auto":n,minWidth:n}).data(I,n),!0},_openHandler:function(t){this._adjustListWidth(),this.trigger(S)?t.preventDefault():(this._focused.attr("aria-expanded",!0),this.ul.attr("aria-hidden",!1))},_closeHandler:function(t){this.trigger(T)?t.preventDefault():(this._focused.attr("aria-expanded",!1),this.ul.attr("aria-hidden",!0))},_focusItem:function(){var t=this.listView,i=!t.focus(),o=n(t.select());o===e&&this.options.highlightFirst&&i&&(o=0),o!==e?t.focus(o):i&&t.scrollToIndex(0)},_calculateGroupPadding:function(t){var e=this.ul.children(".k-first:first"),i=this.listView.content.prev(".k-group-header"),n=0;i[0]&&"none"!==i[0].style.display&&("auto"!==t&&(n=c.support.scrollbar()),n+=parseFloat(e.css("border-right-width"),10)+parseFloat(e.children(".k-group").css("padding-right"),10),i.css("padding-right",n))},_calculatePopupHeight:function(t){var e=this._height(this.dataSource.flatView().length||t);this._calculateGroupPadding(e)},_resizePopup:function(t){this.options.virtual||(this.popup.element.is(":visible")?this._calculatePopupHeight(t):this.popup.one("open",function(t){return z(function(){this._calculatePopupHeight(t)},this)}.call(this,t)))},_popup:function(){var t=this;t.popup=new h.Popup(t.list,B({},t.options.popup,{anchor:t.wrapper,open:z(t._openHandler,t),close:z(t._closeHandler,t),animation:t.options.animation,isRtl:g.isRtl(t.wrapper)}))},_makeUnselectable:function(){V&&this.list.find("*").not(".k-textbox").attr("unselectable","on")},_toggleHover:function(e){t(e.currentTarget).toggleClass(b,"mouseenter"===e.type)},_toggle:function(t,i){var n=this,o=g.mobileOS&&(g.touch||g.MSPointers||g.pointers);t=t!==e?t:!n.popup.visible(),i||o||n._focused[0]===v()||(n._prevent=!0,n._focused.focus(),n._prevent=!1),n[t?S:T]()},_triggerCascade:function(){var t=this;t._cascadeTriggered&&t._old===t.value()&&t._oldIndex===t.selectedIndex||(t._cascadeTriggered=!0,t.trigger(A,{userTriggered:t._userTriggered}))},_triggerChange:function(){this._valueBeforeCascade!==this.value()&&this.trigger(w)},_unbindDataSource:function(){var t=this;t.dataSource.unbind(M,t._requestStartHandler).unbind(E,t._requestEndHandler).unbind("error",t._errorHandler)},requireValueMapper:function(t,e){var i=(t.value instanceof Array?t.value.length:t.value)||(e instanceof Array?e.length:e);if(i&&t.virtual&&"function"!=typeof t.virtual.valueMapper)throw Error("ValueMapper is not provided while the value is being set. See http://docs.telerik.com/kendo-ui/controls/editors/combobox/virtualization#the-valuemapper-function")}});B(H,{inArray:function(t,e){var i,n,o=e.children;if(!t||t.parentNode!==e)return-1;for(i=0,n=o.length;i<n;i++)if(t===o[i])return i;return-1},unifyType:i}),c.ui.List=H,h.Select=H.extend({init:function(t,e){H.fn.init.call(this,t,e),this._initial=this.element.val()},setDataSource:function(t){var e,i=this;i.options.dataSource=t,i._dataSource(),i.listView.bound()&&(i._initialIndex=null),i.listView.setDataSource(i.dataSource),i.options.autoBind&&i.dataSource.fetch(),e=i._parentWidget(),e&&i._cascadeSelect(e)},close:function(){this.popup.close()},select:function(t){var i=this;return t===e?i.selectedIndex:i._select(t).done(function(){i._old=i._accessor(),i._oldIndex=i.selectedIndex})},_accessor:function(t,e){return this[this._isSelect?"_accessorSelect":"_accessorInput"](t,e)},_accessorInput:function(t){var i=this.element[0];return t===e?i.value:(null===t&&(t=""),i.value=t,e)},_accessorSelect:function(t,i){var n,r=this.element[0];return t===e?o(r).value||"":(o(r).selected=!1,i===e&&(i=-1),n=null!==t&&""!==t,n&&i==-1?this._custom(t):t?r.value=t:r.selectedIndex=i,e)},_custom:function(e){var i=this,n=i.element,o=i._customOption;o||(o=t("<option/>"),i._customOption=o,n.append(o)),o.text(e),o[0].selected=!0},_hideBusy:function(){var t=this;clearTimeout(t._busy),t._arrow.removeClass(k),t._focused.attr("aria-busy",!1),t._busy=null,t._showClear()},_showBusy:function(){var t=this;t._request=!0,t._busy||(t._busy=setTimeout(function(){t._arrow&&(t._focused.attr("aria-busy",!0),t._arrow.addClass(k),t._hideClear())},100))},_requestEnd:function(){this._request=!1,this._hideBusy()},_dataSource:function(){var e,i=this,n=i.element,o=i.options,r=o.dataSource||{};r=t.isArray(r)?{data:r}:r,i._isSelect&&(e=n[0].selectedIndex,e>-1&&(o.index=e),r.select=n,r.fields=[{field:o.dataTextField},{field:o.dataValueField}]),i.dataSource?i._unbindDataSource():(i._requestStartHandler=z(i._showBusy,i),i._requestEndHandler=z(i._requestEnd,i),i._errorHandler=z(i._hideBusy,i)),i.dataSource=c.data.DataSource.create(r).bind(M,i._requestStartHandler).bind(E,i._requestEndHandler).bind("error",i._errorHandler)},_firstItem:function(){this.listView.focusFirst()},_lastItem:function(){this.listView.focusLast()},_nextItem:function(){this.listView.focusNext()},_prevItem:function(){this.listView.focusPrev()},_move:function(t){var i,n,o,r,s,a=this,l=a.listView,c=t.keyCode,h=c===p.DOWN;if(c===p.UP||h){if(t.altKey)a.toggle(h);else{if(!l.bound())return a._fetch||(a.dataSource.one(w,function(){a._fetch=!1,a._move(t)}),a._fetch=!0,a._filterSource()),t.preventDefault(),!0;if(o=a._focus(),a._fetch||o&&!o.hasClass("k-state-selected")||(h?(a._nextItem(),a._focus()||a._lastItem()):(a._prevItem(),a._focus()||a._firstItem())),i=l.dataItemByIndex(l.getElementIndex(a._focus())),a.trigger(P,{dataItem:i,item:a._focus()}))return a._focus(o),e;a._select(a._focus(),!0).done(function(){a.popup.visible()||a._blur()})}t.preventDefault(),n=!0}else if(c===p.ENTER||c===p.TAB){if(a.popup.visible()&&t.preventDefault(),o=a._focus(),i=a.dataItem(),a.popup.visible()||i&&a.text()===a._text(i)||(o=null),r=a.filterInput&&a.filterInput[0]===v(),o){if(i=l.dataItemByIndex(l.getElementIndex(o)),a.trigger(P,{dataItem:i,item:o}))return;a._select(o)}else a.input&&(a._accessor(a.input.val()),a.listView.value(a.input.val()));a._focusElement&&a._focusElement(a.wrapper),r&&c===p.TAB?a.wrapper.focusout():a._blur(),a.close(),n=!0}else c===p.ESC?(a.popup.visible()&&t.preventDefault(),a.close(),n=!0):!a.popup.visible()||c!==p.PAGEDOWN&&c!==p.PAGEUP||(t.preventDefault(),s=c===p.PAGEDOWN?1:-1,l.scrollWith(s*l.screenHeight()),n=!0);return n},_fetchData:function(){var t=this,e=!!t.dataSource.view().length;t._request||t.options.cascadeFrom||t.listView.bound()||t._fetch||e||(t._fetch=!0,t.dataSource.fetch().done(function(){t._fetch=!1}))},_options:function(t,i,n){var r,s,a,l,c=this,h=c.element,u=h[0],d=t.length,f="",p=0;for(i&&(f=i);p<d;p++)r="<option",s=t[p],a=c._text(s),l=c._value(s),l!==e&&(l+="",l.indexOf('"')!==-1&&(l=l.replace(F,"&quot;")),r+=' value="'+l+'"'),r+=">",a!==e&&(r+=m(a)),r+="</option>",f+=r;h.html(f),n!==e&&(u.value=n,u.value&&!n&&(u.selectedIndex=-1)),u.selectedIndex!==-1&&(r=o(u),r&&r.setAttribute(D,D))},_reset:function(){var e=this,i=e.element,n=i.attr("form"),o=n?t("#"+n):i.closest("form");o[0]&&(e._resetHandler=function(){setTimeout(function(){e.value(e._initial)})},e._form=o.on("reset",e._resetHandler))},_parentWidget:function(){var e,i,n=this.options.name;if(this.options.cascadeFrom)return e=t("#"+this.options.cascadeFrom),i=e.data("kendo"+n),i||(i=e.data("kendo"+N[n])),i},_cascade:function(){var t,e=this,i=e.options,n=i.cascadeFrom;if(n){if(t=e._parentWidget(),!t)return;e._cascadeHandlerProxy=z(e._cascadeHandler,e),e._cascadeFilterRequests=[],i.autoBind=!1,t.bind("set",function(){e.one("set",function(t){e._selectedValue=t.value})}),t.first(A,e._cascadeHandlerProxy),t.listView.bound()?(e._toggleCascadeOnFocus(),e._cascadeSelect(t)):(t.one("dataBound",function(){e._toggleCascadeOnFocus()}),t.value()||e.enable(!1))}},_toggleCascadeOnFocus:function(){var t=this,e=t._parentWidget(),i=O?"blur":"focusout";e._focused.add(e.filterInput).bind("focus",function(){e.unbind(A,t._cascadeHandlerProxy),e.first(w,t._cascadeHandlerProxy)}),e._focused.add(e.filterInput).bind(i,function(){e.unbind(w,t._cascadeHandlerProxy),e.first(A,t._cascadeHandlerProxy)})},_cascadeHandler:function(t){var e=this._parentWidget(),i=this.value();this._userTriggered=t.userTriggered,this.listView.bound()&&this._clearSelection(e,!0),this._cascadeSelect(e,i)},_cascadeChange:function(t){var e=this,i=e._accessor()||e._selectedValue;e._cascadeFilterRequests.length||(e._selectedValue=null),e._userTriggered?e._clearSelection(t,!0):i?(i!==e.listView.value()[0]&&e.value(i),e.dataSource.view()[0]&&e.selectedIndex!==-1||e._clearSelection(t,!0)):e.dataSource.flatView().length&&e.select(e.options.index),e.enable(),e._triggerCascade(),e._triggerChange(),e._userTriggered=!1},_cascadeSelect:function(t,i){var n,o,r=this,a=t.dataItem(),l=a?t._value(a):null,c=r.options.cascadeFromField||t.options.dataValueField;r._valueBeforeCascade=i!==e?i:r.value(),l||0===l?(n=r.dataSource.filter()||{},s(n,c),o=function(){var e=r._cascadeFilterRequests.shift();e&&r.unbind("dataBound",e),e=r._cascadeFilterRequests[0],e&&r.first("dataBound",e),r._cascadeChange(t)},r._cascadeFilterRequests.push(o),1===r._cascadeFilterRequests.length&&r.first("dataBound",o),r._cascading=!0,r._filterSource({field:c,operator:"eq",value:l}),r._cascading=!1):(r.enable(!1),r._clearSelection(t),r._triggerCascade(),r._triggerChange(),r._userTriggered=!1)}}),a=".StaticList",l=c.ui.DataBoundWidget.extend({init:function(e,i){f.fn.init.call(this,e,i),this.element.attr("role","listbox").on("click"+a,"li",z(this._click,this)).on("mouseenter"+a,"li",function(){t(this).addClass(b)}).on("mouseleave"+a,"li",function(){t(this).removeClass(b)}),this.content=this.element.wrap("<div class='k-list-scroller' unselectable='on'></div>").parent(),this.header=this.content.before('<div class="k-group-header" style="display:none"></div>').prev(),this.bound(!1),this._optionID=c.guid(),this._selectedIndices=[],this._view=[],this._dataItems=[],this._values=[];var n=this.options.value;n&&(this._values=t.isArray(n)?n.slice(0):[n]),this._getter(),this._templates(),this.setDataSource(this.options.dataSource),this._onScroll=z(function(){var t=this;clearTimeout(t._scrollId),t._scrollId=setTimeout(function(){t._renderHeader()},50)},this)},options:{name:"StaticList",dataValueField:null,valuePrimitive:!1,selectable:!0,template:null,groupTemplate:null,fixedGroupTemplate:null},events:["click",w,"activate","deactivate","dataBinding","dataBound","selectedItemChange"],setDataSource:function(e){var i,n=this,o=e||{};o=t.isArray(o)?{data:o}:o,o=c.data.DataSource.create(o),n.dataSource?(n.dataSource.unbind(w,n._refreshHandler),i=n.value(),n.value([]),n.bound(!1),n.value(i)):n._refreshHandler=z(n.refresh,n),n.setDSFilter(o.filter()),n.dataSource=o.bind(w,n._refreshHandler),n._fixedHeader()},skip:function(){return this.dataSource.skip()},setOptions:function(t){f.fn.setOptions.call(this,t),this._getter(),this._templates(),this._render()},destroy:function(){this.element.off(a),this._refreshHandler&&this.dataSource.unbind(w,this._refreshHandler),clearTimeout(this._scrollId),f.fn.destroy.call(this)},dataItemByIndex:function(t){return this.dataSource.flatView()[t]},screenHeight:function(){return this.content[0].clientHeight},scrollToIndex:function(t){var e=this.element[0].children[t];e&&this.scroll(e)},scrollWith:function(t){this.content.scrollTop(this.content.scrollTop()+t)},scroll:function(t){if(t){t[0]&&(t=t[0]);var e=this.content[0],i=t.offsetTop,n=t.offsetHeight,o=e.scrollTop,r=e.clientHeight,s=i+n;o>i?o=i:s>o+r&&(o=s-r),e.scrollTop=o}},selectedDataItems:function(t){return t===e?this._dataItems.slice():(this._dataItems=t,this._values=this._getValues(t),e)},_getValues:function(e){var i=this._valueGetter;return t.map(e,function(t){return i(t)})},focusNext:function(){var t=this.focus();t=t?t.next():0,this.focus(t)},focusPrev:function(){var t=this.focus();t=t?t.prev():this.element[0].children.length-1,this.focus(t)},focusFirst:function(){this.focus(this.element[0].children[0])},focusLast:function(){this.focus(n(this.element[0].children))},focus:function(i){var o,r=this,s=r._optionID;return i===e?r._current:(i=n(r._get(i)),i=t(this.element[0].children[i]),r._current&&(r._current.removeClass(x).removeAttr("aria-selected").removeAttr(y),r.trigger("deactivate")),o=!!i[0],o&&(i.addClass(x),r.scroll(i),i.attr("id",s)),r._current=o?i:null,r.trigger("activate"),e)},focusIndex:function(){return this.focus()?this.focus().index():e},skipUpdate:function(t){this._skipUpdate=t},select:function(i){var o,r,s,a=this,l=a.options.selectable,c="multiple"!==l&&l!==!1,h=a._selectedIndices,u=[],d=[];return i===e?h.slice():(i=a._get(i),1===i.length&&i[0]===-1&&(i=[]),r=t.Deferred().resolve(),s=a.isFiltered(),s&&!c&&a._deselectFiltered(i)?r:c&&!s&&t.inArray(n(i),h)!==-1?(a._dataItems.length&&a._view.length&&(a._dataItems=[a._view[h[0]].item]),r):(o=a._deselect(i),d=o.removed,i=o.indices,i.length&&(c&&(i=[n(i)]),u=a._select(i)),(u.length||d.length)&&(a._valueComparer=null,a.trigger(w,{added:u,removed:d})),r))},removeAt:function(t){return this._selectedIndices.splice(t,1),this._values.splice(t,1),this._valueComparer=null,{position:t,dataItem:this._dataItems.splice(t,1)[0]}},setValue:function(e){e=t.isArray(e)||e instanceof _?e.slice(0):[e],this._values=e,this._valueComparer=null},value:function(i){var n,o=this,r=o._valueDeferred;return i===e?o._values.slice():(o.setValue(i),r&&"resolved"!==r.state()||(o._valueDeferred=r=t.Deferred()),o.bound()&&(n=o._valueIndices(o._values),"multiple"===o.options.selectable&&o.select(-1),o.select(n),r.resolve()),o._skipUpdate=!1,r)},items:function(){return this.element.children(".k-item")},_click:function(e){e.isDefaultPrevented()||this.trigger("click",{item:t(e.currentTarget)})||this.select(e.currentTarget)},_valueExpr:function(t,e){var n,o,r=this,s=0,a=[];if(!r._valueComparer||r._valueType!==t){for(r._valueType=t;s<e.length;s++)a.push(i(e[s],t));n="for (var idx = 0; idx < "+a.length+"; idx++) { if (current === values[idx]) {   return idx; }} return -1;",o=Function("current","values",n),r._valueComparer=function(t){return o(t,a)}}return r._valueComparer},_dataItemPosition:function(t,e){var i=this._valueGetter(t),n=this._valueExpr(typeof i,e);return n(i)},_getter:function(){this._valueGetter=c.getter(this.options.dataValueField)},_deselect:function(e){var i,n,o,r=this,s=r.element[0].children,a=r.options.selectable,l=r._selectedIndices,c=r._dataItems,h=r._values,u=[],d=0,f=0;if(e=e.slice(),a!==!0&&e.length){if("multiple"===a)for(;d<e.length;d++)if(n=e[d],t(s[n]).hasClass("k-state-selected"))for(i=0;i<l.length;i++)if(o=l[i],o===n){t(s[o]).removeClass("k-state-selected"),u.push({position:i+f,dataItem:c.splice(i,1)[0]}),l.splice(i,1),e.splice(d,1),h.splice(i,1),f+=1,d-=1,i-=1;break}}else{for(;d<l.length;d++)t(s[l[d]]).removeClass("k-state-selected"),u.push({position:d,dataItem:c[d]});r._values=[],r._dataItems=[],r._selectedIndices=[]}return{indices:e,removed:u}},_deselectFiltered:function(e){for(var i,n,o,r=this.element[0].children,s=[],a=0;a<e.length;a++)n=e[a],i=this._view[n].item,o=this._dataItemPosition(i,this._values),o>-1&&(s.push(this.removeAt(o)),t(r[n]).removeClass("k-state-selected"));return!!s.length&&(this.trigger(w,{added:[],removed:s}),!0)},_select:function(e){var i,o,r=this,s=r.element[0].children,a=r._view,l=[],c=0;for(n(e)!==-1&&r.focus(e);c<e.length;c++)o=e[c],i=a[o],o!==-1&&i&&(i=i.item,r._selectedIndices.push(o),r._dataItems.push(i),r._values.push(r._valueGetter(i)),t(s[o]).addClass("k-state-selected").attr("aria-selected",!0),l.push({dataItem:i}));return l},getElementIndex:function(e){return t(e).data("offset-index")},_get:function(t){return"number"==typeof t?t=[t]:L(t)||(t=this.getElementIndex(t),t=[t!==e?t:-1]),t},_template:function(){var t=this,e=t.options,i=e.template;return i?(i=c.template(i),i=function(t){return'<li tabindex="-1" role="option" unselectable="on" class="k-item">'+i(t)+"</li>"}):i=c.template('<li tabindex="-1" role="option" unselectable="on" class="k-item">${'+c.expr(e.dataTextField,"data")+"}</li>",{useWithBlock:!1}),i},_templates:function(){var t,e,i=this.options,n={template:i.template,groupTemplate:i.groupTemplate,fixedGroupTemplate:i.fixedGroupTemplate};for(e in n)t=n[e],t&&"function"!=typeof t&&(n[e]=c.template(t));this.templates=n},_normalizeIndices:function(t){
for(var i=[],n=0;n<t.length;n++)t[n]!==e&&i.push(t[n]);return i},_valueIndices:function(t,e){var i,n=this._view,o=0;if(e=e?e.slice():[],!t.length)return[];for(;o<n.length;o++)i=this._dataItemPosition(n[o].item,t),i!==-1&&(e[i]=o);return this._normalizeIndices(e)},_firstVisibleItem:function(){for(var e=this.element[0],i=this.content[0],n=i.scrollTop,o=t(e.children[0]).height(),r=Math.floor(n/o)||0,s=e.children[r]||e.lastChild,a=s.offsetTop<n;s;)if(a){if(s.offsetTop+o>n||!s.nextSibling)break;s=s.nextSibling}else{if(s.offsetTop<=n||!s.previousSibling)break;s=s.previousSibling}return this._view[t(s).data("offset-index")]},_fixedHeader:function(){this.isGrouped()&&this.templates.fixedGroupTemplate?(this.header.show(),this.content.scroll(this._onScroll)):(this.header.hide(),this.content.off("scroll",this._onScroll))},_renderHeader:function(){var t,e=this.templates.fixedGroupTemplate;e&&(t=this._firstVisibleItem(),t&&this.header.html(e(t.group)))},_renderItem:function(t){var e='<li tabindex="-1" role="option" unselectable="on" class="k-item',i=t.item,n=0!==t.index,o=t.selected;return n&&t.newGroup&&(e+=" k-first"),o&&(e+=" k-state-selected"),e+='"'+(o?' aria-selected="true"':"")+' data-offset-index="'+t.index+'">',e+=this.templates.template(i),n&&t.newGroup&&(e+='<div class="k-group">'+this.templates.groupTemplate(t.group)+"</div>"),e+"</li>"},_render:function(){var t,e,i,n,o="",r=0,s=0,a=[],l=this.dataSource.view(),c=this.value(),h=this.isGrouped();if(h)for(r=0;r<l.length;r++)for(e=l[r],i=!0,n=0;n<e.items.length;n++)t={selected:this._selected(e.items[n],c),item:e.items[n],group:e.value,newGroup:i,index:s},a[s]=t,s+=1,o+=this._renderItem(t),i=!1;else for(r=0;r<l.length;r++)t={selected:this._selected(l[r],c),item:l[r],index:r},a[r]=t,o+=this._renderItem(t);this._view=a,this.element[0].innerHTML=o,h&&a.length&&this._renderHeader()},_selected:function(t,e){var i=!this.isFiltered()||"multiple"===this.options.selectable;return i&&this._dataItemPosition(t,e)!==-1},setDSFilter:function(t){this._lastDSFilter=B({},t)},isFiltered:function(){return this._lastDSFilter||this.setDSFilter(this.dataSource.filter()),!c.data.Query.compareFilters(this.dataSource.filter(),this._lastDSFilter)},refresh:function(t){var e,i=this,n=t&&t.action,o=i.options.skipUpdateOnBind,s="itemchange"===n;i.trigger("dataBinding"),i._angularItems("cleanup"),i._fixedHeader(),i._render(),i.bound(!0),s||"remove"===n?(e=r(i._dataItems,t.items),e.changed.length&&(s?i.trigger("selectedItemChange",{items:e.changed}):i.value(i._getValues(e.unchanged)))):i.isFiltered()||i._skipUpdate?(i.focus(0),i._skipUpdate&&(i._skipUpdate=!1,i._selectedIndices=i._valueIndices(i._values,i._selectedIndices))):o||n&&"add"!==n||i.value(i._values),i._valueDeferred&&i._valueDeferred.resolve(),i._angularItems("compile"),i.trigger("dataBound")},bound:function(t){return t===e?this._bound:(this._bound=t,e)},isGrouped:function(){return(this.dataSource.group()||[]).length}}),h.plugin(l)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dropdownlist.min",["kendo.list.min","kendo.mobile.scroller.min"],t)}(function(){return function(t,e){function i(t,e,i){for(var n,o=0,r=e.length-1;o<r;++o)n=e[o],n in t||(t[n]={}),t=t[n];t[e[r]]=i}function n(t,e){return t>=e&&(t-=e),t}function o(t,e){for(var i=0;i<t.length;i++)if(t.charAt(i)!==e)return!1;return!0}var r=window.kendo,s=r.ui,a=s.List,l=s.Select,c=r.support,h=r._activeElement,u=r.data.ObservableObject,d=r.keys,f=".kendoDropDownList",p="disabled",g="readonly",m="change",v="k-state-focused",_="k-state-default",y="k-state-disabled",w="aria-disabled",x="mouseenter"+f+" mouseleave"+f,b="tabindex",k="filter",C="accept",S="The `optionLabel` option is not valid due to missing fields. Define a custom optionLabel as shown here http://docs.telerik.com/kendo-ui/api/javascript/ui/dropdownlist#configuration-optionLabel",T=t.proxy,A=l.extend({init:function(i,n){var o,s,a,c=this,h=n&&n.index;c.ns=f,n=t.isArray(n)?{dataSource:n}:n,l.fn.init.call(c,i,n),n=c.options,i=c.element.on("focus"+f,T(c._focusHandler,c)),c._focusInputHandler=t.proxy(c._focusInput,c),c.optionLabel=t(),c._optionLabel(),c._inputTemplate(),c._reset(),c._prev="",c._word="",c._wrapper(),c._tabindex(),c.wrapper.data(b,c.wrapper.attr(b)),c._span(),c._popup(),c._mobile(),c._dataSource(),c._ignoreCase(),c._filterHeader(),c._aria(),c._enable(),c._oldIndex=c.selectedIndex=-1,h!==e&&(n.index=h),c._initialIndex=n.index,c.requireValueMapper(c.options),c._initList(),c._cascade(),n.autoBind?c.dataSource.fetch():c.selectedIndex===-1&&(s=n.text||"",s||(o=n.optionLabel,o&&0===n.index?s=o:c._isSelect&&(s=i.children(":selected").text())),c._textAccessor(s)),a=t(c.element).parents("fieldset").is(":disabled"),a&&c.enable(!1),c.listView.bind("click",function(t){t.preventDefault()}),r.notify(c)},options:{name:"DropDownList",enabled:!0,autoBind:!0,index:0,text:null,value:null,delay:500,height:200,dataTextField:"",dataValueField:"",optionLabel:"",cascadeFrom:"",cascadeFromField:"",ignoreCase:!0,animation:{},filter:"none",minLength:1,enforceMinLength:!1,virtual:!1,template:null,valueTemplate:null,optionLabelTemplate:null,groupTemplate:"#:data#",fixedGroupTemplate:"#:data#"},events:["open","close",m,"select","filtering","dataBinding","dataBound","cascade","set"],setOptions:function(t){l.fn.setOptions.call(this,t),this.listView.setOptions(this._listOptions(t)),this._optionLabel(),this._inputTemplate(),this._accessors(),this._filterHeader(),this._enable(),this._aria(),!this.value()&&this.hasOptionLabel()&&this.select(0)},destroy:function(){var t=this;l.fn.destroy.call(t),t.wrapper.off(f),t.element.off(f),t._inputWrapper.off(f),t._arrow.off(),t._arrow=null,t.optionLabel.off()},open:function(){var t=this;t.popup.visible()||(t.listView.bound()&&t._state!==C?t._allowOpening()&&(t.popup.one("activate",t._focusInputHandler),t.popup.open(),t._resizeFilterInput(),t._focusItem()):(t._open=!0,t._state="rebind",t.filterInput&&(t.filterInput.val(""),t._prev=""),t.filterInput&&1!==t.options.minLength?(t.refresh(),t.popup.one("activate",t._focusInputHandler),t.popup.open(),t._resizeFilterInput()):t._filterSource()))},_focusInput:function(){this._focusElement(this.filterInput)},_resizeFilterInput:function(){var t,e,i=this.filterInput,n=this._prevent;i&&(t=this.filterInput[0]===h(),e=r.caret(this.filterInput[0])[0],this._prevent=!0,i.css("display","none").css("width",this.popup.element.css("width")).css("display","inline-block"),t&&(i.focus(),r.caret(i[0],e)),this._prevent=n)},_allowOpening:function(){return this.hasOptionLabel()||this.filterInput||l.fn._allowOpening.call(this)},toggle:function(t){this._toggle(t,!0)},current:function(t){var i;return t===e?(i=this.listView.focus(),!i&&0===this.selectedIndex&&this.hasOptionLabel()?this.optionLabel:i):(this._focus(t),e)},dataItem:function(i){var n=this,o=null;if(null===i)return i;if(i===e)o=n.listView.selectedDataItems()[0];else{if("number"!=typeof i){if(n.options.virtual)return n.dataSource.getByUid(t(i).data("uid"));i=i.hasClass("k-list-optionlabel")?-1:t(n.items()).index(i)}else n.hasOptionLabel()&&(i-=1);o=n.dataSource.flatView()[i]}return o||(o=n._optionLabelDataItem()),o},refresh:function(){this.listView.refresh()},text:function(t){var i,n=this,o=n.options.ignoreCase;return t=null===t?"":t,t===e?n._textAccessor():"string"!=typeof t?(n._textAccessor(t),e):(i=o?t.toLowerCase():t,n._select(function(t){return t=n._text(t),o&&(t=(t+"").toLowerCase()),t===i}).done(function(){n._textAccessor(n.dataItem()||t)}),e)},_clearFilter:function(){t(this.filterInput).val(""),l.fn._clearFilter.call(this)},value:function(t){var i=this,n=i.listView,o=i.dataSource;return t===e?(t=i._accessor()||i.listView.value()[0],t===e||null===t?"":t):(i.requireValueMapper(i.options,t),!t&&i.hasOptionLabel()||(i._initialIndex=null),this.trigger("set",{value:t}),i._request&&i.options.cascadeFrom&&i.listView.bound()?(i._valueSetter&&o.unbind(m,i._valueSetter),i._valueSetter=T(function(){i.value(t)},i),o.one(m,i._valueSetter),e):(i._isFilterEnabled()&&n.bound()&&n.isFiltered()?i._clearFilter():i._fetchData(),n.value(t).done(function(){i.selectedIndex===-1&&i.text()&&(i.text(""),i._accessor("",-1)),i._old=i._accessor(),i._oldIndex=i.selectedIndex}),e))},hasOptionLabel:function(){return this.optionLabel&&!!this.optionLabel[0]},_optionLabel:function(){var i=this,n=i.options,o=n.optionLabel,s=n.optionLabelTemplate;return o?(s||(s="#:",s+="string"==typeof o?"data":r.expr(n.dataTextField,"data"),s+="#"),"function"!=typeof s&&(s=r.template(s)),i.optionLabelTemplate=s,i.hasOptionLabel()||(i.optionLabel=t('<div class="k-list-optionlabel"></div>').prependTo(i.list)),i.optionLabel.html(s(o)).off().click(T(i._click,i)).on(x,i._toggleHover),i.angular("compile",function(){return{elements:i.optionLabel,data:[{dataItem:i._optionLabelDataItem()}]}}),e):(i.optionLabel.off().remove(),i.optionLabel=t(),e)},_optionLabelText:function(){var t=this.options.optionLabel;return"string"==typeof t?t:this._text(t)},_optionLabelDataItem:function(){var e=this,i=e.options.optionLabel;return e.hasOptionLabel()?t.isPlainObject(i)?new u(i):e._assignInstance(e._optionLabelText(),""):null},_buildOptions:function(t){var i,n,o,r=this;r._isSelect&&(i=r.listView.value()[0],n=r._optionLabelDataItem(),o=n&&r._value(n),i!==e&&null!==i||(i=""),n&&(o!==e&&null!==o||(o=""),n='<option value="'+o+'">'+r._text(n)+"</option>"),r._options(t,n,i),i!==a.unifyType(r._accessor(),typeof i)&&(r._customOption=null,r._custom(i)))},_listBound:function(){var t,e=this,i=e._initialIndex,n=e._state===k,o=e.dataSource.flatView();e._presetValue=!1,e._renderFooter(),e._renderNoData(),e._toggleNoData(!o.length),e._resizePopup(!0),e.popup.position(),e._buildOptions(o),e._makeUnselectable(),n||(e._open&&e.toggle(e._allowOpening()),e._open=!1,e._fetch||(o.length?(!e.listView.value().length&&i>-1&&null!==i&&e.select(i),e._initialIndex=null,t=e.listView.selectedDataItems()[0],t&&e.text()!==e._text(t)&&e._selectValue(t)):e._textAccessor()!==e._optionLabelText()&&(e.listView.value(""),e._selectValue(null),e._oldIndex=e.selectedIndex))),e._hideBusy(),e.trigger("dataBound")},_listChange:function(){this._selectValue(this.listView.selectedDataItems()[0]),(this._presetValue||this._old&&this._oldIndex===-1)&&(this._oldIndex=this.selectedIndex)},_filterPaste:function(){this._search()},_focusHandler:function(){this.wrapper.focus()},_focusinHandler:function(){this._inputWrapper.addClass(v),this._prevent=!1},_focusoutHandler:function(){var t,e,i=this,n=i._state===k,o=window.self!==window.top,r=i._focus(),s=i._getElementDataItem(r);i._prevent||(clearTimeout(i._typingTimeout),e=function(){c.mobileOS.ios&&o?i._change():i._blur(),i._inputWrapper.removeClass(v),i._prevent=!0,i._open=!1,i.element.blur()},t=!n&&r&&i._value(s)!==i.value(),t&&!i.trigger("select",{dataItem:s,item:r})?i._select(r,!i.dataSource.view().length).done(e):e())},_wrapperMousedown:function(){this._prevent=!!this.filterInput},_wrapperClick:function(t){t.preventDefault(),this.popup.unbind("activate",this._focusInputHandler),this._focused=this.wrapper,this._toggle()},_editable:function(t){var e=this,i=e.element,n=t.disable,o=t.readonly,r=e.wrapper.add(e.filterInput).off(f),s=e._inputWrapper.off(x);o||n?n?(r.removeAttr(b),s.addClass(y).removeClass(_)):(s.addClass(_).removeClass(y),r.on("focusin"+f,T(e._focusinHandler,e)).on("focusout"+f,T(e._focusoutHandler,e))):(i.removeAttr(p).removeAttr(g),s.addClass(_).removeClass(y).on(x,e._toggleHover),r.attr(b,r.data(b)).attr(w,!1).on("keydown"+f,T(e._keydown,e)).on("focusin"+f,T(e._focusinHandler,e)).on("focusout"+f,T(e._focusoutHandler,e)).on("mousedown"+f,T(e._wrapperMousedown,e)).on("paste"+f,T(e._filterPaste,e)),e.wrapper.on("click"+f,T(e._wrapperClick,e)),e.filterInput||r.on("keypress"+f,T(e._keypress,e))),i.attr(p,n).attr(g,o),r.attr(w,n)},_keydown:function(t){var i,n,o,r=this,s=t.keyCode,a=t.altKey,l=r.popup.visible();if(r.filterInput&&(i=r.filterInput[0]===h()),s===d.LEFT?(s=d.UP,n=!0):s===d.RIGHT&&(s=d.DOWN,n=!0),!n||!i){if(t.keyCode=s,(a&&s===d.UP||s===d.ESC)&&r._focusElement(r.wrapper),r._state===k&&s===d.ESC&&r._clearFilter(),s===d.ENTER&&r._typingTimeout&&r.filterInput&&l)return t.preventDefault(),e;if(n=r._move(t),!n){if((!l||!r.filterInput)&&(o=r._focus(),s===d.HOME?(n=!0,r._firstItem()):s===d.END&&(n=!0,r._lastItem()),n)){if(r.trigger("select",{dataItem:r._getElementDataItem(r._focus()),item:r._focus()}))return r._focus(o),e;r._select(r._focus(),!0).done(function(){l||r._blur()})}a||n||!r.filterInput||r._search()}}},_matchText:function(t,i){var n=this.options.ignoreCase;return t!==e&&null!==t&&(t+="",n&&(t=t.toLowerCase()),0===t.indexOf(i))},_shuffleData:function(t,e){var i=this._optionLabelDataItem();return i&&(t=[i].concat(t)),t.slice(e).concat(t.slice(0,e))},_selectNext:function(){var t,e,i,r=this,s=r.dataSource.flatView(),a=s.length+(r.hasOptionLabel()?1:0),l=o(r._word,r._last),c=r.selectedIndex;for(c===-1?c=0:(c+=l?1:0,c=n(c,a)),s=s.toJSON?s.toJSON():s.slice(),s=r._shuffleData(s,c),i=0;i<a&&(e=r._text(s[i]),!l||!r._matchText(e,r._last))&&!r._matchText(e,r._word);i++);i!==a&&(t=r._focus(),r._select(n(c+i,a)).done(function(){var e=function(){r.popup.visible()||r._change()};r.trigger("select",{dataItem:r._getElementDataItem(r._focus()),item:r._focus()})?r._select(t).done(e):e()}))},_keypress:function(t){var e,i=this;0!==t.which&&t.keyCode!==r.keys.ENTER&&(e=String.fromCharCode(t.charCode||t.keyCode),i.options.ignoreCase&&(e=e.toLowerCase())," "===e&&t.preventDefault(),i._word+=e,i._last=e,i._search())},_popupOpen:function(){var t=this.popup;t.wrapper=r.wrap(t.element),t.element.closest(".km-root")[0]&&(t.wrapper.addClass("km-popup km-widget"),this.wrapper.addClass("km-widget"))},_popup:function(){l.fn._popup.call(this),this.popup.one("open",T(this._popupOpen,this))},_getElementDataItem:function(t){return t&&t[0]?t[0]===this.optionLabel[0]?this._optionLabelDataItem():this.listView.dataItemByIndex(this.listView.getElementIndex(t)):null},_click:function(i){var n=this,o=i.item||t(i.currentTarget);return i.preventDefault(),n.trigger("select",{dataItem:n._getElementDataItem(o),item:o})?(n.close(),e):(n._userTriggered=!0,n._select(o).done(function(){n._focusElement(n.wrapper),n._blur()}),e)},_focusElement:function(t){var e=h(),i=this.wrapper,n=this.filterInput,o=t===n?i:n,r=c.mobileOS&&(c.touch||c.MSPointers||c.pointers);n&&n[0]===t[0]&&r||n&&o[0]===e&&(this._prevent=!0,this._focused=t.focus())},_searchByWord:function(t){var e,i;t&&(e=this,i=e.options.ignoreCase,i&&(t=t.toLowerCase()),e._select(function(i){return e._matchText(e._text(i),t)}))},_inputValue:function(){return this.text()},_search:function(){var t=this,i=t.dataSource;if(clearTimeout(t._typingTimeout),t._isFilterEnabled())t._typingTimeout=setTimeout(function(){var e=t.filterInput.val();t._prev!==e&&(t._prev=e,t.search(e),t._resizeFilterInput()),t._typingTimeout=null},t.options.delay);else{if(t._typingTimeout=setTimeout(function(){t._word=""},t.options.delay),!t.listView.bound())return i.fetch().done(function(){t._selectNext()}),e;t._selectNext()}},_get:function(e){var i,n,o,r="function"==typeof e,s=r?t():t(e);if(this.hasOptionLabel()&&("number"==typeof e?e>-1&&(e-=1):s.hasClass("k-list-optionlabel")&&(e=-1)),r){for(i=this.dataSource.flatView(),o=0;o<i.length;o++)if(e(i[o])){e=o,n=!0;break}n||(e=-1)}return e},_firstItem:function(){this.hasOptionLabel()?this._focus(this.optionLabel):this.listView.focusFirst()},_lastItem:function(){this._resetOptionLabel(),this.listView.focusLast()},_nextItem:function(){this.optionLabel.hasClass("k-state-focused")?(this._resetOptionLabel(),this.listView.focusFirst()):this.listView.focusNext()},_prevItem:function(){this.optionLabel.hasClass("k-state-focused")||(this.listView.focusPrev(),this.listView.focus()||this._focus(this.optionLabel))},_focusItem:function(){var t=this.listView,i=t.focus(),n=t.select();n=n[n.length-1],n===e&&this.options.highlightFirst&&!i&&(n=0),n!==e?t.focus(n):this.options.optionLabel?(this._focus(this.optionLabel),this._select(this.optionLabel)):t.scrollToIndex(0)},_resetOptionLabel:function(t){this.optionLabel.removeClass("k-state-focused"+(t||"")).removeAttr("id")},_focus:function(t){var i=this.listView,n=this.optionLabel;return t===e?(t=i.focus(),!t&&n.hasClass("k-state-focused")&&(t=n),t):(this._resetOptionLabel(),t=this._get(t),i.focus(t),t===-1&&(n.addClass("k-state-focused").attr("id",i._optionID),this._focused.add(this.filterInput).removeAttr("aria-activedescendant").attr("aria-activedescendant",i._optionID)),e)},_select:function(t,e){var i=this;return t=i._get(t),i.listView.select(t).done(function(){e||i._state!==k||(i._state=C),t===-1&&i._selectValue(null)})},_selectValue:function(t){var i=this,n=i.options.optionLabel,o=i.listView.select(),r="",s="";o=o[o.length-1],o===e&&(o=-1),this._resetOptionLabel(" k-state-selected"),t?(s=t,r=i._dataValue(t),n&&(o+=1)):n&&(i._focus(i.optionLabel.addClass("k-state-selected")),s=i._optionLabelText(),r="string"==typeof n?"":i._value(n),o=0),i.selectedIndex=o,null===r&&(r=""),i._textAccessor(s),i._accessor(r,o),i._triggerCascade()},_mobile:function(){var t=this,e=t.popup,i=c.mobileOS,n=e.element.parents(".km-root").eq(0);n.length&&i&&(e.options.animation.open.effects=i.android||i.meego?"fadeIn":i.ios||i.wp?"slideIn:up":e.options.animation.open.effects)},_filterHeader:function(){var e;this.filterInput&&(this.filterInput.off(f).parent().remove(),this.filterInput=null),this._isFilterEnabled()&&(e='<span class="k-icon k-i-search"></span>',this.filterInput=t('<input class="k-textbox"/>').attr({placeholder:this.element.attr("placeholder"),title:this.element.attr("title"),role:"listbox","aria-haspopup":!0,"aria-expanded":!1}),this.list.prepend(t('<span class="k-list-filter" />').append(this.filterInput.add(e))))},_span:function(){var e,i=this,n=i.wrapper,o="span.k-input";e=n.find(o),e[0]||(n.append('<span unselectable="on" class="k-dropdown-wrap k-state-default"><span unselectable="on" class="k-input">&nbsp;</span><span unselectable="on" class="k-select" aria-label="select"><span class="k-icon k-i-arrow-s"></span></span></span>').append(i.element),e=n.find(o)),i.span=e,i._inputWrapper=t(n[0].firstChild),i._arrow=n.find(".k-icon")},_wrapper:function(){var t,e=this,i=e.element,n=i[0];t=i.parent(),t.is("span.k-widget")||(t=i.wrap("<span />").parent(),t[0].style.cssText=n.style.cssText,t[0].title=n.title),e._focused=e.wrapper=t.addClass("k-widget k-dropdown k-header").addClass(n.className).css("display","").attr({accesskey:i.attr("accesskey"),unselectable:"on",role:"listbox","aria-haspopup":!0,"aria-expanded":!1}),i.hide().removeAttr("accesskey")},_clearSelection:function(t){this.select(t.value()?0:-1)},_inputTemplate:function(){var e=this,i=e.options.valueTemplate;if(i=i?r.template(i):t.proxy(r.template("#:this._text(data)#",{useWithBlock:!1}),e),e.valueTemplate=i,e.hasOptionLabel()&&!e.options.optionLabelTemplate)try{e.valueTemplate(e._optionLabelDataItem())}catch(n){throw Error(S)}},_textAccessor:function(i){var n,o=null,r=this.valueTemplate,s=this._optionLabelText(),a=this.span;if(i===e)return a.text();t.isPlainObject(i)||i instanceof u?o=i:s&&s===i&&(o=this.options.optionLabel),o||(o=this._assignInstance(i,this._accessor())),this.hasOptionLabel()&&(o!==s&&this._text(o)!==s||(r=this.optionLabelTemplate,"string"!=typeof this.options.optionLabel||this.options.optionLabelTemplate||(o=s))),n=function(){return{elements:a.get(),data:[{dataItem:o}]}},this.angular("cleanup",n);try{a.html(r(o))}catch(l){a.html("")}this.angular("compile",n)},_preselect:function(t,e){t||e||(e=this._optionLabelText()),this._accessor(t),this._textAccessor(e),this._old=this._accessor(),this._oldIndex=this.selectedIndex,this.listView.setValue(t),this._initialIndex=null,this._presetValue=!0},_assignInstance:function(t,e){var n=this.options.dataTextField,o={};return n?(i(o,n.split("."),t),i(o,this.options.dataValueField.split("."),e),o=new u(o)):o=t,o}});s.plugin(A)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("dataviz/diagram/dom.min",["kendo.data.min","kendo.draganddrop.min","kendo.toolbar.min","kendo.editable.min","kendo.window.min","kendo.dropdownlist.min","kendo.dataviz.core.min","kendo.dataviz.themes.min","dataviz/diagram/svg.min","dataviz/diagram/services.min","dataviz/diagram/layout.min"],t)}(function(){!function(t,e){function i(t){var e=t.originalEvent,i=0;return e.wheelDelta?(i=-e.wheelDelta/40,i=i>0?xt.ceil(i):xt.floor(i)):e.detail&&(i=e.detail),i}function n(t){return t.options.name.toLowerCase()===Bt.toLowerCase()}function o(t,e){var i,o,r,s,a=Vt;for(r=0;r<e.length;r++)o=e[r],n(o)||(s=t.distanceTo(o.position()),s<a&&(a=s,i=o));return i}function r(t,e){var i,n,o,r=[],s=t.drawingContainer().children,a=s.length;for(i=0;i<e.length;i++)for(n=e[i],o=0;o<a;o++)if(s[o]==n.drawingContainer()){r.push(o);break}return r}function s(t){var e={};return t=t||{},mt(t.text)&&null!==t.text&&(e.text=t.text),mt(t.x)&&null!==t.x&&(e.x=t.x),mt(t.y)&&null!==t.y&&(e.y=t.y),mt(t.width)&&null!==t.width&&(e.width=t.width),mt(t.height)&&null!==t.height&&(e.height=t.height),mt(t.type)&&null!==t.type&&(e.type=t.type),e}function a(t){var e={};return t=t||{},mt(t.text)&&null!==t.text&&(e.content=t.text),mt(t.type)&&null!==t.type&&(e.type=t.type),mt(t.from)&&null!==t.from&&(e.from=t.from),mt(t.fromConnector)&&null!==t.fromConnector&&(e.fromConnector=t.fromConnector),mt(t.fromX)&&null!==t.fromX&&(e.fromX=t.fromX),mt(t.fromY)&&null!==t.fromY&&(e.fromY=t.fromY),mt(t.to)&&null!==t.to&&(e.to=t.to),mt(t.toConnector)&&null!==t.toConnector&&(e.toConnector=t.toConnector),mt(t.toX)&&null!==t.toX&&(e.toX=t.toX),mt(t.toY)&&null!==t.toY&&(e.toY=t.toY),e}function l(e,i){var n,o=this.dataSource.reader.model;o&&(n=o.fn.fields.text?"text":o.idField,t("<input name='"+i.field+"' />").appendTo(e).kendoDropDownList({dataValueField:o.idField,dataTextField:n,dataSource:this.dataSource.data().toJSON(),optionLabel:" ",valuePrimitive:!0}))}function c(t){this.dataItem=t,this.callbacks=[]}function h(){this.items={}}function u(t){var e=t;return t instanceof kendo.data.Model&&(e=t.toJSON(),e[t.idField]=t._defaultId),e}function d(t){var e,i,n=[],o=[];for(i=0;i<t.length;i++)e=t[i],e instanceof x?o.push(e):n.push(e);return{shapes:o,connections:n}}function f(t,e){return t.reader.model?new t.reader.model(e):new kendo.data.ObservableObject(e)}function p(t,e){mt(e[t])&&e.set(t,null)}function g(t,e,i){var n,o;for(o=0;o<i.length;o++)n=i[o],e&&!mt(e[n])&&(e[n]=t[n])}function m(t){var e=t.drawingContainer().clippedBBox(null);0===e.origin.x&&0===e.origin.y||t.position(-e.origin.x,-e.origin.y)}function v(t){t.preventDefault()}var _,y,w,x,b,k,C,S,T,A,P,D,M=kendo.dataviz,E=kendo.drawing,I=kendo.geometry,B=M.diagram,z=kendo.ui.Widget,L=kendo.Class,R=t.proxy,O=kendo.deepExtend,V=kendo._outerWidth,F=kendo._outerHeight,N=t.extend,H=kendo.data.HierarchicalDataSource,U=B.Canvas,j=B.Group,G=B.Rectangle,W=B.Circle,q=B.CompositeTransform,$=B.Rect,Y=B.Path,X=B.DeleteShapeUnit,Q=B.DeleteConnectionUnit,K=B.TextBlock,Z=B.Image,J=B.Point,tt=B.Intersect,et=B.ConnectionEditAdorner,it=B.UndoRedoService,nt=B.ToolService,ot=B.Selector,rt=B.ResizingAdorner,st=B.ConnectorsAdorner,at=B.Cursors,lt=B.Utils,ct=kendo.Observable,ht=B.ToBackUnit,ut=B.ToFrontUnit,dt=B.PolylineRouter,ft=B.CascadingRouter,pt=lt.isUndefined,gt=lt.isDefined,mt=kendo.util.defined,vt=t.isArray,_t=kendo.isFunction,yt=lt.isString,wt=t.isPlainObject,xt=Math,bt=".kendoDiagram",kt="cascading",Ct="itemBoundsChange",St="change",Tt="click",At="drag",Pt="dragEnd",Dt="dragStart",Mt="mouseEnter",Et="mouseLeave",It="error",Bt="Auto",zt="Top",Lt="Right",Rt="Left",Ot="Bottom",Vt=9007199254740992,Ft="select",Nt="itemRotate",Ht="pan",Ut="zoomStart",jt="zoomEnd",Gt="none",Wt=600,qt=600,$t="rectangle",Yt=100,Xt=100,Qt=20,Kt=20,Zt=0,Jt="Yellow",te=Number.MAX_VALUE,ee=-Number.MAX_VALUE,ie="absolute",ne="transformed",oe="rotated",re="transparent",se="width",ae="height",le="x",ce="y",he="DOMMouseScroll"+bt+" mousewheel"+bt,ue=.05,de=5,fe='<a class="k-button k-button-icontext #=className#" href="\\#"><span class="#=iconClass# #=imageClass#"></span>#=text#</a>',pe=5;B.DefaultConnectors=[{name:zt},{name:Ot},{name:Rt},{name:Lt},{name:Bt,position:function(t){return t.getPosition("center")}}],_={cancel:{text:"Cancel",imageClass:"k-i-cancel",className:"k-diagram-cancel",iconClass:"k-icon"},update:{text:"Update",imageClass:"k-i-update",className:"k-diagram-update",iconClass:"k-icon"}},B.shapeDefaults=function(t){var e={type:$t,path:"",autoSize:!0,visual:null,x:Zt,y:Zt,minWidth:Qt,minHeight:Kt,width:Yt,height:Xt,hover:{},editable:{connect:!0,tools:[]},connectors:B.DefaultConnectors,rotation:{angle:0}};return lt.simpleExtend(e,t),e},y=ct.extend({init:function(t){var e=this;e.dataItem=(t||{}).dataItem,ct.fn.init.call(e),e.options=O({id:B.randomId()},e.options,t),e.isSelected=!1,e.visual=new j({id:e.options.id,autoSize:e.options.autoSize}),e.id=e.options.id,e._template()},options:{hover:{},cursor:at.grip,content:{align:"center middle"},selectable:!0,serializable:!0,enable:!0},_getCursor:function(t){return this.adorner?this.adorner._getCursor(t):this.options.cursor},visible:function(t){return pt(t)?this.visual.visible():(this.visual.visible(t),e)},bounds:function(){},refresh:function(){this.visual.redraw()},position:function(t){this.options.x=t.x,this.options.y=t.y,this.visual.position(t)},toString:function(){return this.options.id},serialize:function(){var t=O({},{options:this.options});return this.dataItem&&(t.dataItem=""+this.dataItem),t},_content:function(t){var i,n,o;return t!==e&&(i=this.options,B.Utils.isString(t)?i.content.text=t:O(i.content,t),n=i.content,o=this._contentVisual,o?this._updateContentVisual(n):this._createContentVisual(n)),this.options.content.text},_createContentVisual:function(t){t.text&&(this._contentVisual=new K(t),this._contentVisual._includeInBBox=!1,this.visual.append(this._contentVisual))},_updateContentVisual:function(t){this._contentVisual.redraw(t)},_hitTest:function(t){var e=this.bounds();return this.visible()&&e.contains(t)&&this.options.enable},_template:function(){var t,e,i=this;i.options.content.template&&(t=i.dataItem||{},e=kendo.template(i.options.content.template,{paramName:"dataItem"}),i.options.content.text=e(t))},_canSelect:function(){return this.options.selectable!==!1},toJSON:function(){return{id:this.options.id}}}),w=L.extend({init:function(t,e){this.options=O({},this.options,e),this.connections=[],this.shape=t},options:{width:7,height:7,fill:{color:Jt},hover:{}},position:function(){return this.options.position?this.options.position(this.shape):this.shape.getPosition(this.options.name)},toJSON:function(){return{shapeId:""+this.shape,connector:this.options.name}}}),w.parse=function(t,e){var i,n,o=e.split(":"),r=o[0],s=o[1]||Bt;for(i=0;i<t.shapes.length;i++)if(n=t.shapes[i],n.options.id==r)return n.getConnector(s.trim())},x=y.extend({init:function(t,e){var i=this;y.fn.init.call(i,t),this.diagram=e,this.updateOptionsFromModel(),t=i.options,i.connectors=[],i.type=t.type,i.createShapeVisual(),i.updateBounds(),i.content(i.content()),i._createConnectors()},options:B.shapeDefaults(),_setOptionsFromModel:function(t){var e=s(t||this.dataItem);this.options=O({},this.options,e),this.redrawVisual()},updateOptionsFromModel:function(t,e){var i,n;this.diagram&&this.diagram._isEditable&&(i=s(t||this.dataItem),t&&e?M.inArray(e,["x","y","width","height"])?(n=this.bounds(),n[e]=t[e],this.bounds(n)):(this.options.visual?this._redrawVisual():i.type&&(this.options=O({},this.options,i),this._redrawVisual()),this.options.content&&(this._template(),this.content(this.options.content))):this.options=O({},this.options,i))},_redrawVisual:function(){this.visual.clear(),this._contentVisual=null,this.options.dataItem=this.dataItem,this.createShapeVisual(),this.updateBounds()},redrawVisual:function(){this._redrawVisual(),this.options.content&&(this._template(),this.content(this.options.content))},updateModel:function(t){var e,i,n=this.diagram;n&&n._isEditable&&(e=this._bounds,i=this.dataItem,i&&(n._suspendModelRefresh(),mt(i.x)&&e.x!==i.x&&i.set("x",e.x),mt(i.y)&&e.y!==i.y&&i.set("y",e.y),mt(i.width)&&e.width!==i.width&&i.set("width",e.width),mt(i.height)&&e.height!==i.height&&i.set("height",e.height),this.dataItem=i,n._resumeModelRefresh(),t&&n._syncShapeChanges()))},updateBounds:function(){var t=this.visual._measure(!0),e=this.options;this.bounds(new $(e.x,e.y,t.width,t.height)),this._rotate(),this._alignContent()},content:function(t){var e=this._content(t);return this._alignContent(),e},_alignContent:function(){var t,e,i,n,o,r=this.options.content||{},s=this._contentVisual;s&&r.align&&(t=this.visual._measure(),e=new B.RectAlign(t),i=s.drawingElement.bbox(null),n=new $(0,0,i.width(),i.height()),o=e.align(n,r.align),s.position(o.topLeft()))},_createConnectors:function(){var t,e,i=this.options,n=i.connectors.length,o=i.connectorDefaults;for(e=0;e<n;e++)t=new w(this,O({},o,i.connectors[e])),this.connectors.push(t)},bounds:function(t){var e,i;if(t)if(yt(t))switch(t){case ne:e=this._transformedBounds();break;case ie:e=this._transformedBounds(),i=this.diagram._pan,e.x+=i.x,e.y+=i.y;break;case oe:e=this._rotatedBounds();break;default:e=this._bounds}else this._setBounds(t),this._triggerBoundsChange(),this.diagram&&this.diagram._layouting||this.refreshConnections();else e=this._bounds;return e},_setBounds:function(t){var e=this.options,i=t.topLeft(),n=e.x=i.x,o=e.y=i.y,r=e.width=xt.max(t.width,e.minWidth),s=e.height=xt.max(t.height,e.minHeight);this._bounds=new $(n,o,r,s),this.visual.redraw({x:n,y:o,width:r,height:s})},position:function(t){return t?(this.bounds(new $(t.x,t.y,this._bounds.width,this._bounds.height)),e):this._bounds.topLeft()},clone:function(){var t=this.serialize();return t.options.id=B.randomId(),this.diagram&&this.diagram._isEditable&&mt(this.dataItem)&&(t.options.dataItem=u(this.dataItem)),new x(t.options)},select:function(t){var e,i,n=this.diagram;if(pt(t)&&(t=!0),this._canSelect()&&this.isSelected!=t)return e=[],i=[],this.isSelected=t,this.isSelected?(n._selectedItems.push(this),e.push(this)):(lt.remove(n._selectedItems,this),i.push(this)),n._internalSelection||n._selectionChanged(e,i),!0},rotate:function(t,i,n){var o,r,s,a,l=this.visual.rotate();return t!==e&&(n!==!1&&this.diagram&&this.diagram.undoRedoService&&t!==l.angle&&this.diagram.undoRedoService.add(new B.RotateUnit(this.diagram._resizingAdorner,[this],[l.angle]),!1),o=this.bounds(),r=new J(o.width/2,o.height/2),i&&(s=t-l.angle,a=o.center().rotate(i,360-s).minus(r),this._rotationOffset=this._rotationOffset.plus(a.minus(o.topLeft())),this.position(a)),this.visual.rotate(t,r),this.options.rotation.angle=t,this.diagram&&this.diagram._connectorsAdorner&&this.diagram._connectorsAdorner.refresh(),this.refreshConnections(),this.diagram&&this.diagram.trigger(Nt,{item:this})),l},connections:function(t){var e,i,n,o,r,s,a,l=[];for(e=0;e<this.connectors.length;e++)for(r=this.connectors[e],o=r.connections,i=0,o;i<o.length;i++)n=o[i],"out"==t?(s=n.source(),s.shape&&s.shape==this&&l.push(n)):"in"==t?(a=n.target(),a.shape&&a.shape==this&&l.push(n)):l.push(n);return l},refreshConnections:function(){t.each(this.connections(),function(){this.refresh()})},getConnector:function(t){var e,i;if(!yt(t))return t instanceof J?o(t,this.connectors):this.connectors.length?this.connectors[0]:null;for(t=t.toLocaleLowerCase(),e=0;e<this.connectors.length;e++)if(i=this.connectors[e],i.options.name.toLocaleLowerCase()==t)return i},getPosition:function(t){var e=this.bounds(),i=t.charAt(0).toLowerCase()+t.slice(1);return _t(e[i])?this._transformPoint(e[i]()):e.center()},redraw:function(t){var e,i;t&&(e=this.options,this.shapeVisual.redraw(this._visualOptions(t)),this._diffNumericOptions(t,[se,ae,le,ce])&&(this.bounds(new $(e.x,e.y,e.width,e.height)),i=!0),t.connectors&&(e.connectors=t.connectors,this._updateConnectors()),e=O(e,t),(t.rotation||i)&&this._rotate(),e.content&&this.content(e.content))},_updateConnectors:function(){var t,e,i,n,o=this.connections();
for(this.connectors=[],this._createConnectors(),n=0;n<o.length;n++)t=o[n],e=t.source(),i=t.target(),e.shape&&e.shape===this?t.source(this.getConnector(e.options.name)||null):i.shape&&i.shape===this&&t.target(this.getConnector(i.options.name)||null),t.updateModel()},_diffNumericOptions:B.diffNumericOptions,_visualOptions:function(t){return{data:t.path,source:t.source,hover:t.hover,fill:t.fill,stroke:t.stroke}},_triggerBoundsChange:function(){this.diagram&&this.diagram.trigger(Ct,{item:this,bounds:this._bounds.clone()})},_transformPoint:function(t){var e=this.rotate(),i=this.bounds(),n=i.topLeft();return e.angle&&t.rotate(e.center().plus(n),360-e.angle),t},_transformedBounds:function(){var t=this.bounds(),e=t.topLeft(),i=t.bottomRight();return $.fromPoints(this.diagram.modelToView(e),this.diagram.modelToView(i))},_rotatedBounds:function(){var t=this.bounds().rotatedBounds(this.rotate().angle),e=t.topLeft(),i=t.bottomRight();return $.fromPoints(e,i)},_rotate:function(){var t=this.options.rotation;t&&t.angle&&this.rotate(t.angle),this._rotationOffset=new J},_hover:function(t){var e=this.options,i=e.hover,n=e.stroke,o=e.fill;t&&gt(i.stroke)&&(n=O({},n,i.stroke)),t&&gt(i.fill)&&(o=i.fill),this.shapeVisual.redraw({stroke:n,fill:o}),e.editable&&e.editable.connect&&this.diagram._showConnectors(this,t)},_hitTest:function(t){if(this.visible()){var e,i=this.bounds(),n=this.rotate().angle;if(t.isEmpty&&!t.isEmpty())return tt.rects(t,i,n?n:0);if(e=t.clone().rotate(i.center(),n),i.contains(e))return this}},toJSON:function(){return{shapeId:this.options.id}},createShapeVisual:function(){var t,e=this.options,i=this._visualOptions(e),n=e.visual,o=(e.type+"").toLocaleLowerCase();i.width=e.width,i.height=e.height,_t(n)?t=n.call(this,e):i.data?(t=new Y(i),m(t)):t="rectangle"==o?new G(i):"circle"==o?new W(i):"text"==o?new K(i):"image"==o?new Z(i):new Y(i),this.shapeVisual=t,this.visual.append(this.shapeVisual)}}),b=y.extend({init:function(t,e,i){var n=this;y.fn.init.call(n,i),this.updateOptionsFromModel(),this._initRouter(),n.path=new B.Polyline(n.options),n.path.fill(re),n.visual.append(n.path),n._sourcePoint=n._targetPoint=new J,n._setSource(t),n._setTarget(e),n.content(n.options.content),n.definers=[],mt(i)&&i.points&&n.points(i.points)},options:{hover:{stroke:{}},startCap:Gt,endCap:Gt,points:[],selectable:!0,fromConnector:Bt,toConenctor:Bt},_setOptionsFromModel:function(t){this.updateOptionsFromModel(t||this.dataItem)},updateOptionsFromModel:function(t){var e,i,n,o;this.diagram&&this.diagram._isEditable&&(e=this.diagram._dataMap,i=a(t||this.dataItem),t?(mt(i.from)?(n=e[i.from],n&&mt(i.fromConnector)&&(n=n.getConnector(i.fromConnector)),this.source(n)):mt(i.fromX)&&mt(i.fromY)&&this.source(new J(i.fromX,i.fromY)),mt(i.to)?(o=e[i.to],o&&mt(i.toConnector)&&(o=o.getConnector(i.toConnector)),this.target(o)):mt(i.toX)&&mt(i.toY)&&this.target(new J(i.toX,i.toY)),mt(i.type)&&this.type()!==i.type&&(this.points([]),this.type(i.type)),this.dataItem=t,this._template(),this.redraw(this.options)):this.options=O({},i,this.options))},updateModel:function(t){if(this.diagram&&this.diagram._isEditable&&this.diagram.connectionsDataSource){var e=this.diagram.connectionsDataSource.getByUid(this.dataItem.uid);e&&(this.diagram._suspendModelRefresh(),mt(this.options.fromX)&&null!==this.options.fromX?(p("from",e),p("fromConnector",e),e.set("fromX",this.options.fromX),e.set("fromY",this.options.fromY)):(e.set("from",this.options.from),mt(e.fromConnector)&&e.set("fromConnector",this.sourceConnector?this.sourceConnector.options.name:null),p("fromX",e),p("fromY",e)),mt(this.options.toX)&&null!==this.options.toX?(p("to",e),p("toConnector",e),e.set("toX",this.options.toX),e.set("toY",this.options.toY)):(e.set("to",this.options.to),mt(e.toConnector)&&e.set("toConnector",this.targetConnector?this.targetConnector.options.name:null),p("toX",e),p("toY",e)),mt(this.options.type)&&mt(e.type)&&e.set("type",this.options.type),this.dataItem=e,this.diagram._resumeModelRefresh(),t&&this.diagram._syncConnectionChanges())}},sourcePoint:function(){return this._resolvedSourceConnector?this._resolvedSourceConnector.position():this._sourcePoint},_setSource:function(t){var i,n=t instanceof x,o=this.options.fromConnector||Bt;n&&!t.getConnector(o)||(t!==e&&(this.from=t),this._removeFromSourceConnector(),null===t?this.sourceConnector&&(this._sourcePoint=(this._resolvedSourceConnector||this.sourceConnector).position(),this._clearSourceConnector(),this._setFromOptions(null,this._sourcePoint)):t instanceof w?(i=t.shape.dataItem,i&&this._setFromOptions(i.id),this.sourceConnector=t,this.sourceConnector.connections.push(this)):t instanceof J?(this._setFromOptions(null,t),this._sourcePoint=t,this.sourceConnector&&this._clearSourceConnector()):n&&(i=t.dataItem,i&&this._setFromOptions(i.id),this.sourceConnector=t.getConnector(o),this.sourceConnector.connections.push(this)))},source:function(t,e){return gt(t)&&(e&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new B.ConnectionEditUnit(this,t)),this._setSource(t),this.refresh()),this.sourceConnector?this.sourceConnector:this._sourcePoint},_setFromOptions:function(t,e){this.options.from=t,e?(this.options.fromX=e.x,this.options.fromY=e.y):(this.options.fromX=null,this.options.fromY=null)},sourceDefiner:function(t){if(!t)return this._sourceDefiner||(this._sourceDefiner=new B.PathDefiner(this.sourcePoint(),null,null)),this._sourceDefiner;if(!(t instanceof B.PathDefiner))throw"The sourceDefiner needs to be a PathDefiner.";t.left=null,this._sourceDefiner=t,this.source(t.point)},targetPoint:function(){return this._resolvedTargetConnector?this._resolvedTargetConnector.position():this._targetPoint},_setTarget:function(t){var i,n=t instanceof x,o=this.options.toConnector||Bt;n&&!t.getConnector(o)||(t!==e&&(this.to=t),this._removeFromTargetConnector(),null===t?this.targetConnector&&(this._targetPoint=(this._resolvedTargetConnector||this.targetConnector).position(),this._clearTargetConnector(),this._setToOptions(null,this._targetPoint)):t instanceof w?(i=t.shape.dataItem,i&&this._setToOptions(i.id),this.targetConnector=t,this.targetConnector.connections.push(this)):t instanceof J?(this._setToOptions(null,t),this._targetPoint=t,this.targetConnector&&this._clearTargetConnector()):n&&(i=t.dataItem,i&&this._setToOptions(i.id),this.targetConnector=t.getConnector(o),this.targetConnector.connections.push(this)))},target:function(t,i){return gt(t)&&(i&&this.diagram&&this.diagram.undoRedoService.addCompositeItem(new B.ConnectionEditUnit(this,e,t)),this._setTarget(t),this.refresh()),this.targetConnector?this.targetConnector:this._targetPoint},_setToOptions:function(t,e){this.options.to=t,e?(this.options.toX=e.x,this.options.toY=e.y):(this.options.toX=null,this.options.toY=null)},targetDefiner:function(t){if(!t)return this._targetDefiner||(this._targetDefiner=new B.PathDefiner(this.targetPoint(),null,null)),this._targetDefiner;if(!(t instanceof B.PathDefiner))throw"The sourceDefiner needs to be a PathDefiner.";t.right=null,this._targetDefiner=t,this.target(t.point)},_updateConnectors:function(){this._updateConnector(this.source(),"source"),this._updateConnector(this.target(),"target")},_updateConnector:function(t,e){var i,n,o,r,s=this,a=s.diagram;t instanceof w&&!a.getShapeById(t.shape.id)?(i=t.shape.dataItem,n=t.options.name,o=function(){var o=a._dataMap[i.id];t=o.getConnector(n),s[e](t,!1),s.updateModel()},a._dataMap[i.id]?o():(r=a._inactiveShapeItems.getByUid(i.uid),r&&a._deferredConnectionUpdates.push(r.onActivate(o)))):s[e](t,!1)},content:function(t){var e=this._content(t);return mt(t)&&this._alignContent(),e},_createContentVisual:function(t){var e;return _t(t.visual)?e=t.visual.call(this,t):t.text&&(e=new K(t)),e&&(this._contentVisual=e,e._includeInBBox=!1,this.visual.append(e)),e},_updateContentVisual:function(t){_t(t.visual)?(this.visual.remove(this._contentVisual),this._createContentVisual(t)):this._contentVisual.redraw(t)},_alignContent:function(){var t,e,i,n,o,r,s,a,l,c,h,u,d,f,p,g;if(this._contentVisual){for(t=pe,e=this.allPoints(),i=xt.floor(e.length/2),n=i-1;n>0&&e[n].equals(e[i]);)n--,i++;o=e[i],r=e[n],s=this._contentVisual._measure(),a=s.width,l=s.height,c=e.length%2===0,h=r.distanceTo(o),c&&e.length>2&&h>0&&(r.y===o.y&&h<a||r.x===o.x&&h<l)&&(c=!1,t=0),c?(d=kendo.util.deg(xt.atan2(o.y-r.y,o.x-r.x)),u=new J((o.x-r.x)/2+r.x,(o.y-r.y)/2+r.y),90===xt.abs(d)?(u.x+=t,u.y-=l/2):d%180===0?(u.x-=a/2,u.y-=l+t):d<-90||0<d&&d<90?u.y-=l:(d<0||d>90)&&(u.x-=a,u.y-=l)):(f=xt.floor(e.length/2),u=e[f].clone(),r=e[f-1],o=e[f+1],p=r.x<=u.x&&o.x<=u.x?t:-s.width-t,g=r.y<=u.y&&o.y<=u.y?t:-s.height-t,u.x+=p,u.y+=g),this._contentVisual.position(u)}},select:function(t){var i,n,o=this.diagram;if(this._canSelect()&&this.isSelected!==t)return this.isSelected=t,i=[],n=[],this.isSelected?(this.adorner=new et(this,this.options.selection),o._adorn(this.adorner,!0),o._selectedItems.push(this),i.push(this)):this.adorner&&(o._adorn(this.adorner,!1),lt.remove(o._selectedItems,this),this.adorner=e,n.push(this)),this.adorner&&this.adorner.refresh(),o._internalSelection||o._selectionChanged(i,n),!0},bounds:function(t){return!t||yt(t)?this._bounds:(this._bounds=t,e)},type:function(t){var i=this.options;return t?(t!==i.type&&(i.type=t,this._initRouter(),this.refresh()),e):i.type},_initRouter:function(){var t=(this.options.type||"").toLowerCase();this._router=t==kt?new ft(this):new dt(this)},points:function(t){var e,i,n,o;if(!t){if(n=[],gt(this.definers))for(o=0;o<this.definers.length;o++)n.push(this.definers[o].point);return n}for(this.definers=[],e=0;e<t.length;e++)if(i=t[e],i instanceof B.Point)this.definers.push(new B.PathDefiner(i));else{if(!i.hasOwnProperty("x")||!i.hasOwnProperty("y"))throw"A Connection point needs to be a Point or an object with x and y properties.";this.definers.push(new B.PathDefiner(new J(i.x,i.y)))}},allPoints:function(){var t,e=[this.sourcePoint()];if(this.definers)for(t=0;t<this.definers.length;t++)e.push(this.definers[t].point);return e.push(this.targetPoint()),e},refresh:function(){this._resolveConnectors(),this._refreshPath(),this._alignContent(),this.adorner&&this.adorner.refresh()},_resolveConnectors:function(){var t,e,i,r,s=this,a=s.source(),l=s.target();a instanceof J?t=a:a instanceof w&&(i=n(a)?a.shape.connectors:[a]),l instanceof J?e=l:l instanceof w&&(r=n(l)?l.shape.connectors:[l]),t?r&&(s._resolvedTargetConnector=o(t,r)):i&&(e?s._resolvedSourceConnector=o(e,i):r&&this._resolveAutoConnectors(i,r))},_resolveAutoConnectors:function(t,e){var i,o,r,s,a,l,c,h,u,d,f,p=Vt,g=Vt;for(u=0;u<t.length;u++)if(c=t[u],!n(c))for(r=c.position(),d=0;d<e.length;d++)h=e[d],n(h)||(s=h.position(),f=xt.round(r.distanceTo(s)),f<p&&this.diagram&&this._testRoutePoints(r,s,c,h)&&(p=f,i=c,o=h),f<g&&(a=c,l=h,g=f));i&&(a=i,l=o),this._resolvedSourceConnector=a,this._resolvedTargetConnector=l},_testRoutePoints:function(t,e,i,n){var o,r,s,a,l,c=this._router,h=!0;if(c instanceof ft)for(o=c.routePoints(t,e,i,n),o.unshift(t),o.push(e),l=1;l<o.length;l++)if(r=o[l-1],s=o[l],a=new $(xt.min(r.x,s.x),xt.min(r.y,s.y),xt.abs(r.x-s.x),xt.abs(r.y-s.y)),a.width>0&&(a.x++,a.width-=2),a.height>0&&(a.y++,a.height-=2),!a.isEmpty()&&this.diagram._shapesQuadTree.hitTestRect(a)){h=!1;break}return h},redraw:function(t){if(t){this.options=O({},this.options,t);var e=this.options.points;mt(e)&&e.length>0&&(this.points(e),this._refreshPath()),(t&&t.content||t.text)&&this.content(t.content),this.path.redraw({fill:t.fill,stroke:t.stroke,startCap:t.startCap,endCap:t.endCap})}},clone:function(){var t=this.serialize();return this.diagram&&this.diagram._isEditable&&mt(this.dataItem)&&(t.options.dataItem=u(this.dataItem)),new b(this.from,this.to,t.options)},serialize:function(){var t=this.from.toJSON?this.from.toJSON:""+this.from,e=this.to.toJSON?this.to.toJSON:""+this.to,i=O({},{options:this.options,from:t,to:e});return mt(this.dataItem)&&(i.dataItem=""+this.dataItem),i.options.points=this.points(),i},_hitTest:function(t){if(this.visible()){var e=new J(t.x,t.y),i=this.sourcePoint(),n=this.targetPoint();if(t.isEmpty&&!t.isEmpty()&&t.contains(i)&&t.contains(n))return this;if(this._router.hitTest(e))return this}},_hover:function(t){var e=(this.options.stroke||{}).color;t&&gt(this.options.hover.stroke.color)&&(e=this.options.hover.stroke.color),this.path.redraw({stroke:{color:e}})},_refreshPath:function(){mt(this.path)&&(this._drawPath(),this.bounds(this._router.getBounds()))},_drawPath:function(){var t,e,i;this._router&&this._router.route(),t=this.sourcePoint(),e=this.targetPoint(),i=this.points(),this.path.redraw({points:[t].concat(i,[e])})},_clearSourceConnector:function(){this.sourceConnector=e,this._resolvedSourceConnector=e},_clearTargetConnector:function(){this.targetConnector=e,this._resolvedTargetConnector=e},_removeFromSourceConnector:function(){this.sourceConnector&&lt.remove(this.sourceConnector.connections,this)},_removeFromTargetConnector:function(){this.targetConnector&&lt.remove(this.targetConnector.connections,this)},toJSON:function(){var t,e,i,n=this;return n.from&&n.from.toJSON?t=n.from.toJSON():(i=n._sourcePoint,t={x:i.x,y:i.y}),n.to&&n.to.toJSON?e=n.to.toJSON():(i=n._targetPoint,e={x:i.x,y:i.y}),{from:t,to:e}}}),k=z.extend({init:function(t,e){var i=this;kendo.destroy(t),z.fn.init.call(i,t,e),i._initTheme(),i._initElements(),i._extendLayoutOptions(i.options),i._initDefaults(e),i._interactionDefaults(),i._initCanvas(),i.mainLayer=new j({id:"main-layer"}),i.canvas.append(i.mainLayer),i._shapesQuadTree=new D(i),i._pan=new J,i._adorners=[],i.adornerLayer=new j({id:"adorner-layer"}),i.canvas.append(i.adornerLayer),i._createHandlers(),i._initialize(),i._resizingAdorner=new rt(i,{editable:i.options.editable}),i._connectorsAdorner=new st(i),i._adorn(i._resizingAdorner,!0),i._adorn(i._connectorsAdorner,!0),i.selector=new ot(i),i._clipboard=[],i.pauseMouseHandlers=!1,i._fetchFreshData(),i._createGlobalToolBar(),i._createOptionElements(),i.zoom(i.options.zoom),i.canvas.draw()},options:{name:"Diagram",theme:"default",layout:"",zoomRate:.1,zoom:1,zoomMin:0,zoomMax:2,dataSource:{},draggable:!0,template:"",autoBind:!0,editable:{rotate:{},resize:{},text:!0,tools:[],drag:{snap:{size:10,angle:10}},remove:!0},pannable:{},selectable:{key:"none"},tooltip:{enabled:!0,format:"{0}"},copy:{enabled:!0,offsetX:20,offsetY:20},shapeDefaults:B.shapeDefaults({undoable:!0}),connectionDefaults:{editable:{tools:[]},type:kt},shapes:[],connections:[]},events:[jt,Ut,Ht,Ft,Nt,Ct,St,Tt,Mt,Et,"toolBarClick","save","cancel","edit","remove","add","dataBound",Dt,At,Pt],items:function(){return t()},_createGlobalToolBar:function(){var t,e=this.options.editable;e&&(t=e.tools,!this._isEditable||t===!1||t&&0!==t.length||(t=["createShape","undo","redo","rotateClockwise","rotateAnticlockwise"]),t&&t.length&&(this.toolBar=new C(this,{tools:t||{},click:R(this._toolBarClick,this),modal:!1}),this.toolBar.element.css({textAlign:"left"}),this.element.prepend(this.toolBar.element),this._resize()))},createShape:function(){var t,e,i,n,o,r;(this.editor&&this.editor.end()||!this.editor)&&(t=this.dataSource,e=t.view()||[],i=e.length,n=f(t,{}),o=this._createShape(n,{}),this.trigger("add",{shape:o})||(t.insert(i,n),r=this._inactiveShapeItems.getByUid(n.uid),r.element=o,this.edit(o)))},_createShape:function(t,e){e=O({},this.options.shapeDefaults,e),e.dataItem=t;var i=new x(e,this);return i},createConnection:function(){var t,e,i,n,o;(this.editor&&this.editor.end()||!this.editor)&&(t=this.connectionsDataSource,e=t.view()||[],i=e.length,n=f(t,{}),o=this._createConnection(n),this.trigger("add",{connection:o})||(this._connectionsDataMap[n.uid]=o,t.insert(i,n),this.addConnection(o,!1),this.edit(o)))},_createConnection:function(t,e,i){var n,o=O({},this.options.connectionDefaults);return o.dataItem=t,n=new b(e||new J,i||new J,o)},editModel:function(t,e){var i,n,o,r;if(this.cancelEdit(),o=this.options.editable,"shape"==e)i=o.shapeEditors,n=o.shapeTemplate;else{if("connection"!=e)return;r=R(l,this),i=O({},{from:r,to:r},o.connectionEditors),n=o.connectionTemplate}this.editor=new T(this.element,{update:R(this._update,this),cancel:R(this._cancel,this),model:t,type:e,target:this,editors:i,template:n}),this.trigger("edit",this._editArgs())},edit:function(t){if(t.dataItem){var e=t instanceof x?"shape":"connection";this.editModel(t.dataItem,e)}},cancelEdit:function(){this.editor&&(this._getEditDataSource().cancelChanges(this.editor.model),this._destroyEditor())},saveEdit:function(){this.editor&&this.editor.end()&&!this.trigger("save",this._editArgs())&&this._getEditDataSource().sync()},_update:function(){this.editor&&this.editor.end()&&!this.trigger("save",this._editArgs())&&(this._getEditDataSource().sync(),this._destroyEditor())},_cancel:function(){var t,e;this.editor&&!this.trigger("cancel",this._editArgs())&&(t=this.editor.model,this._getEditDataSource().cancelChanges(t),e=this._connectionsDataMap[t.uid]||this._dataMap[t.id],e&&e._setOptionsFromModel(t),this._destroyEditor())},_getEditDataSource:function(){return"shape"===this.editor.options.type?this.dataSource:this.connectionsDataSource},_editArgs:function(){var t={container:this.editor.wrapper};return t[this.editor.options.type]=this.editor.model,t},_destroyEditor:function(){this.editor&&(this.editor.close(),this.editor=null)},_initElements:function(){this.wrapper=this.element.empty().css("position","relative").attr("tabindex",0).addClass("k-widget k-diagram"),this.scrollable=t("<div />").appendTo(this.element)},_initDefaults:function(t){var e=this.options,i=e.editable,n=e.shapeDefaults,o=e.connectionDefaults,r=(t||{}).shapeDefaults;i===!1?(n.editable=!1,o.editable=!1):(g(i,n.editable,["drag","remove","connect"]),g(i,o.editable,["drag","remove"])),r&&r.connectors&&(e.shapeDefaults.connectors=r.connectors)},_interactionDefaults:function(){var t=this.options,e=t.selectable,i=t.pannable,n=kendo.support.mobileOS;e&&!mt(e.multiple)&&(t.selectable=O({multiple:!n},t.selectable)),i&&!mt(i.key)&&(t.pannable=O({key:n?"none":"ctrl"},t.pannable))},_initCanvas:function(){var e=t("<div class='k-layer'></div>").appendTo(this.scrollable)[0],i=this.viewport();this.canvas=new U(e,{width:i.width||Wt,height:i.height||qt})},_createHandlers:function(){var t=this,e=t.element;e.on(he,R(t._wheel,t)).on("keydown"+bt,R(t._keydown,t)),t._userEvents=new kendo.UserEvents(this.scrollable,{multiTouch:!0,fastTap:!0,tap:R(t._tap,t),start:R(t._dragStart,t),move:R(t._drag,t),end:R(t._dragEnd,t),gesturestart:R(t._gestureStart,t),gesturechange:R(t._gestureChange,t),gestureend:R(t._gestureEnd,t)}),t.toolService=new nt(t),this.scrollable.on("mouseover"+bt,R(t._mouseover,t)).on("mouseout"+bt,R(t._mouseout,t)).on("mousemove"+bt,R(t._mouseMove,t)).on("mousedown"+bt,R(t._mouseDown,t)).on("mouseup"+bt,R(t._mouseUp,t)),this._syncHandler=R(t._syncChanges,t),t._resizeHandler=R(t.resize,t,!1),kendo.onResize(t._resizeHandler),this.bind(Ut,R(t._destroyToolBar,t)),this.bind(Ht,R(t._destroyToolBar,t))},_dragStart:function(t){var e,i;this._pauseMouseHandlers=!0,e=this._eventPositions(t,!0),i=t.event,this.toolService.start(e,this._meta(i))&&(this._destroyToolBar(),i.preventDefault())},_drag:function(t){var e=this._eventPositions(t),i=t.event;this.toolService.move(e,this._meta(i))&&i.preventDefault()},_dragEnd:function(t){var e,i;this._pauseMouseHandlers=!1,e=this._eventPositions(t),i=t.event,this.toolService.end(e,this._meta(i))&&(this._createToolBar(),i.preventDefault())},_mouseMove:function(t){if(!this._pauseMouseHandlers){var e=this._eventPositions(t);this.toolService._updateHoveredItem(e),this.toolService._updateCursor(e)}},_mouseDown:function(){this._pauseMouseHandlers=!0},_mouseUp:function(){this._pauseMouseHandlers=!1},_tap:function(t){var e,i,n,o=this.toolService,r=this.options.selectable,s=this._eventPositions(t),a=this.focus();o._updateHoveredItem(s),o.hoveredItem?(e=o.hoveredItem,this.trigger("click",{item:e,point:s}),r&&e.options.selectable!==!1&&(i=r.multiple!==!1,n=kendo.support.mobileOS||this._meta(t.event).ctrlKey,e.isSelected?n?(this._destroyToolBar(),e.select(!1)):this._createToolBar(a):(this._destroyToolBar(),this.select(e,{addToSelection:i&&n}),this._createToolBar(a)))):r&&(this._destroyToolBar(),this.deselect())},_keydown:function(t){this.toolService.keyDown(t.keyCode,this._meta(t))&&t.preventDefault()},_wheel:function(t){var e=i(t),n=this._eventPositions(t),o=O(this._meta(t),{delta:e});this.toolService.wheel(n,o)&&t.preventDefault()},_meta:function(t){return{ctrlKey:t.ctrlKey,metaKey:t.metaKey,altKey:t.altKey,shiftKey:t.shiftKey,type:t.type}},_eventPositions:function(t,e){var i,n;return t.touch?(n=e?"startLocation":"location",i=new J(t.x[n],t.y[n])):i=new J(t.pageX,t.pageY),this.documentToModel(i)},_gestureStart:function(t){var e,i;this._destroyToolBar(),this.scroller.disable(),e=this.documentToModel(new J(t.center.x,t.center.y)),i={point:e,zoom:this.zoom()},this.trigger(Ut,i)||(this._gesture=t,this._initialCenter=e)},_gestureChange:function(t){var e,i,n=this._gesture,o=this._initialCenter,r=this.documentToView(new J(t.center.x,t.center.y)),s=t.distance/n.distance,a=this._zoom,l=!1;xt.abs(s-1)>=ue&&(this._zoom=a=this._getValidZoom(a*s),this.options.zoom=a,this._gesture=t,l=!0),e=o.times(a),i=r.minus(e),(l||this._pan.distanceTo(i)>=de)&&(this._panTransform(i),this._updateAdorners()),t.preventDefault()},_gestureEnd:function(){this.options.pannable!==!1&&this.scroller.enable(),this.trigger(jt,{point:this._initialCenter,zoom:this.zoom()})},_resize:function(){var t=this.viewport();this.canvas&&this.canvas.size(t),this.scrollable&&this.toolBar&&this.scrollable.height(t.height)},_mouseover:function(t){var e=t.target._kendoNode;e&&e.srcElement._hover&&e.srcElement._hover(!0,e.srcElement)},_mouseout:function(t){var e=t.target._kendoNode;e&&e.srcElement._hover&&e.srcElement._hover(!1,e.srcElement)},_initTheme:function(){var t=this,e=M.ui.themes||{},i=((t.options||{}).theme||"").toLowerCase(),n=(e[i]||{}).diagram;t.options=O({},n,t.options),t.options.editable===!0&&O(t.options,{editable:(n||{}).editable})},_createOptionElements:function(){var t=this.options,e=t.shapes.length;e&&this._createShapes(),t.connections.length&&this._createConnections(),e&&t.layout&&this.layout(t.layout)},_createShapes:function(){var t,e,i=this,n=i.options,o=n.shapes;for(e=0;e<o.length;e++)t=o[e],i.addShape(t)},_createConnections:function(){var t,e,i,n,o=this,r=o.options,s=r.connectionDefaults,a=r.connections;for(n=0;n<a.length;n++)t=a[n],e=o._findConnectionTarget(t.from),i=o._findConnectionTarget(t.to),o.connect(e,i,O({},s,t))},_findConnectionTarget:function(t){var e,i,n;return t=t||{},e=this,i=yt(t)?t:t.shapeId||t.id,i?(n=e.getShapeById(i),t.connector&&(n=n.getConnector(t.connector))):n=new J(t.x||0,t.y||0),n},destroy:function(){var t=this;z.fn.destroy.call(t),this._userEvents&&this._userEvents.destroy(),kendo.unbindResize(t._resizeHandler),t.clear(),t.element.off(bt),t.scroller.wrapper.off(bt),t.canvas.destroy(!0),t.canvas=e,t._destroyEditor(),t.destroyScroller(),t._destroyGlobalToolBar(),t._destroyToolBar()},destroyScroller:function(){var t=this.scroller;t&&(t.destroy(),t.element.remove(),this.scroller=null)},save:function(){var t,e,i,n={shapes:[],connections:[]};for(t=0;t<this.shapes.length;t++)i=this.shapes[t],i.options.serializable&&n.shapes.push(i.options);for(t=0;t<this.connections.length;t++)e=this.connections[t],n.connections.push(O({},e.options,e.toJSON()));return n},focus:function(){if(!this.element.is(kendo._activeElement())){var t,e=this.element,i=e[0],n=[],o=[],r=document.documentElement;do i=i.parentNode,i.scrollHeight>i.clientHeight&&(n.push(i),o.push(i.scrollTop));while(i!=r);for(e.focus(),t=0;t<n.length;t++)n[t].scrollTop=o[t];return!0}},load:function(t){this.clear(),this.setOptions(t),this._createShapes(),this._createConnections()},setOptions:function(t){O(this.options,t)},clear:function(){var t=this;t.select(!1),t.mainLayer.clear(),t._shapesQuadTree.clear(),t._initialize()},connect:function(t,e,i){var n,o;return this.connectionsDataSource&&this._isEditable?(o=this.connectionsDataSource.add({}),n=this._connectionsDataMap[o.uid],n.source(t),n.target(e),n.redraw(i),n.updateModel()):(n=new b(t,e,O({},this.options.connectionDefaults,i)),this.addConnection(n)),n},connected:function(t,e){var i,n;for(i=0;i<this.connections.length;i++)if(n=this.connections[i],n.from==t&&n.to==e)return!0;return!1},addConnection:function(t,e){return e!==!1&&this.undoRedoService.add(new B.AddConnectionUnit(t,this),!1),t.diagram=this,t._setOptionsFromModel(),t.refresh(),this.mainLayer.append(t.visual),this.connections.push(t),this.trigger(St,{added:[t],removed:[]}),t},_addConnection:function(t,e){var i,n=this.connectionsDataSource;if(n&&this._isEditable){if(i=f(n,u(t.dataItem)),t.dataItem=i,t.updateModel(),!this.trigger("add",{connection:t}))return this._connectionsDataMap[i.uid]=t,n.add(i),this.addConnection(t,e),t._updateConnectors(),t}else if(!this.trigger("add",{connection:t}))return this.addConnection(t,e),t._updateConnectors(),t},addShape:function(t,e){var i,n=this.options.shapeDefaults;if(t instanceof x)i=t;else{if(t instanceof kendo.Class)return;n=O({},n,t||{}),i=new x(n,this)}return e!==!1&&this.undoRedoService.add(new B.AddShapeUnit(i,this),!1),this.shapes.push(i),i.diagram!==this&&(this._shapesQuadTree.insert(i),i.diagram=this),this.mainLayer.append(i.visual),this.trigger(St,{added:[i],removed:[]}),i},_addShape:function(t,e){var i,n,o=this,r=o.dataSource;if(r&&this._isEditable){if(i=f(r,u(t.dataItem)),t.dataItem=i,t.updateModel(),!this.trigger("add",{shape:t}))return this.dataSource.add(i),n=this._inactiveShapeItems.getByUid(i.uid),n.element=t,n.undoable=e,t}else if(!this.trigger("add",{shape:t}))return this.addShape(t,e)},remove:function(t,e){var i,n,o,r;for(t=vt(t)?t.slice(0):[t],i=d(t),n=i.shapes,o=i.connections,mt(e)||(e=!0),e&&this.undoRedoService.begin(),this._suspendModelRefresh(),r=n.length-1;r>=0;r--)this._removeItem(n[r],e,o);for(r=o.length-1;r>=0;r--)this._removeItem(o[r],e);this._resumeModelRefresh(),e&&this.undoRedoService.commit(!1),this.trigger(St,{added:[],removed:t})},_removeShapeDataItem:function(t){this._isEditable&&(this.dataSource.remove(t.dataItem),delete this._dataMap[t.dataItem.id])},_removeConnectionDataItem:function(t){this._isEditable&&(this.connectionsDataSource.remove(t.dataItem),delete this._connectionsDataMap[t.dataItem.uid])},_triggerRemove:function(t){var e,i,n,o,r=[];for(o=0;o<t.length;o++)e=t[o],n=e.options.editable,i=e instanceof x?{shape:e}:{connection:e},n&&n.remove!==!1&&!this.trigger("remove",i)&&r.push(e);return r},undo:function(){this.undoRedoService.undo()},redo:function(){this.undoRedoService.redo()},select:function(t,e){if(!gt(t))return this._selectedItems;e=O({addToSelection:!1},e);var i,n,o=e.addToSelection,r=[],s=[];for(o||this.deselect(),this._internalSelection=!0,t instanceof Array?r=t:t instanceof y&&(r=[t]),i=0;i<r.length;i++)n=r[i],n.select(!0)&&s.push(n);this._selectionChanged(s,[]),this._internalSelection=!1},selectAll:function(){this.select(this.shapes.concat(this.connections))},selectArea:function(t){var e,i,n,o;if(this._internalSelection=!0,o=[],t instanceof $)for(i=this.shapes.concat(this.connections),e=0;e<i.length;e++)n=i[e],t&&!n._hitTest(t)||!n.options.enable||n.select(!0)&&o.push(n);this._selectionChanged(o,[]),this._internalSelection=!1},deselect:function(t){this._internalSelection=!0;var e,i,n=[],o=[];for(t instanceof Array?o=t:t instanceof y?o.push(t):gt(t)||(o=this._selectedItems.slice(0)),i=0;i<o.length;i++)e=o[i],e.select(!1)&&n.push(e);this._selectionChanged([],n),this._internalSelection=!1},toFront:function(t,e){var i,n,o;t||(t=this._selectedItems.slice()),i=this._getDiagramItems(t),!mt(e)||e?(n=r(this.mainLayer,i.visuals),o=new ut(this,t,n),this.undoRedoService.add(o)):(this.mainLayer.toFront(i.visuals),this._fixOrdering(i,!0))},toBack:function(t,e){var i,n,o;t||(t=this._selectedItems.slice()),i=this._getDiagramItems(t),!mt(e)||e?(n=r(this.mainLayer,i.visuals),o=new ht(this,t,n),this.undoRedoService.add(o)):(this.mainLayer.toBack(i.visuals),this._fixOrdering(i,!1))},bringIntoView:function(t,e){var i,n,o,r,s=this.viewport(),a=new B.RectAlign(s);0!==s.width&&0!==s.height&&(e=O({animate:!1,align:"center middle"},e),"none"==e.align&&(e.align="center middle"),t instanceof y?n=t.bounds(ne):vt(t)?n=this.boundingBox(t):t instanceof $&&(n=t.clone()),o=n.clone(),n.zoom(this._zoom),(n.width>s.width||n.height>s.height)&&(this._zoom=this._getValidZoom(xt.min(s.width/o.width,s.height/o.height)),n=o.clone().zoom(this._zoom)),this._zoomMainLayer(),i=n.clone(),a.align(n,e.align),r=n.topLeft().minus(i.topLeft()),this.pan(r.times(-1),e.animate))},alignShapes:function(t){var e,i,n,o,r,s,a;if(pt(t)&&(t="Left"),e=this.select(),0!==e.length){switch(t.toLowerCase()){case"left":case"top":i=te;break;case"right":case"bottom":i=ee}for(o=0;o<e.length;o++)if(n=e[o],n instanceof x)switch(t.toLowerCase()){case"left":i=xt.min(i,n.options.x);break;case"top":i=xt.min(i,n.options.y);break;case"right":i=xt.max(i,n.options.x);break;case"bottom":i=xt.max(i,n.options.y)}for(r=[],s=[],o=0;o<e.length;o++)if(n=e[o],n instanceof x)switch(s.push(n),r.push(n.bounds()),t.toLowerCase()){case"left":case"right":n.position(new J(i,n.options.y));break;case"top":case"bottom":n.position(new J(n.options.x,i))}a=new B.TransformUnit(s,r),this.undoRedoService.add(a,!1)}},zoom:function(t,e){var i,n,o,r;return t&&(i=e?e.point:new B.Point(0,0),t=this._zoom=this._getValidZoom(t),pt(i)||(i=new B.Point(xt.round(i.x),xt.round(i.y)),n=i.times(t),o=this.modelToView(i),r=o.minus(n),this._storePan(new B.Point(xt.round(r.x),xt.round(r.y)))),e&&(e.zoom=t),this._panTransform(),this.canvas.surface.hideTooltip(),this._updateAdorners()),this._zoom},_getPan:function(t){var e=this.canvas;return e.translate||(t=t.plus(this._pan)),t},pan:function(t,i){var n,o;return t instanceof J?(n=this,o=n.scroller,t=n._getPan(t),t=t.times(-1),i?o.animatedScrollTo(t.x,t.y,function(){n._updateAdorners()}):(o.scrollTo(t.x,t.y),n._updateAdorners()),e):this._pan.times(-1)},viewport:function(){var t=this.element,e=t.width(),i=t.height();return this.toolBar&&(i-=F(this.toolBar.element)),new $(0,0,e,i)},copy:function(){var t,e;if(this.options.copy.enabled)for(this._clipboard=[],this._copyOffset=1,t=0;t<this._selectedItems.length;t++)e=this._selectedItems[t],this._clipboard.push(e)},cut:function(){var t,e;if(this.options.copy.enabled){for(this._clipboard=[],this._copyOffset=0,t=0;t<this._selectedItems.length;t++)e=this._selectedItems[t],this._clipboard.push(e);this.remove(this._clipboard,!0)}},paste:function(){var t,e,i,n,o,r,s,a;if(this._clipboard.length>0){for(n={},o=d(this._clipboard),r=o.connections,s=o.shapes,a={x:this._copyOffset*this.options.copy.offsetX,y:this._copyOffset*this.options.copy.offsetY},this.deselect(),i=0;i<s.length;i++)t=s[i],e=t.clone(),n[t.id]=e,e.position(new J(t.options.x+a.x,t.options.y+a.y)),e.diagram=this,e=this._addShape(e),e&&e.select();for(i=0;i<r.length;i++)t=r[i],e=this._addConnection(t.clone()),e&&(this._updateCopiedConnection(e,t,"source",n,a),this._updateCopiedConnection(e,t,"target",n,a),e.select(!0),e.updateModel());this._syncChanges(),this._copyOffset+=1}},_updateCopiedConnection:function(t,e,i,n,o){var r,s,a,l=e[i](),c=this;l instanceof w&&n[l.shape.id]?(a=n[l.shape.id],c.getShapeById(a.id)?t[i](a.getConnector(l.options.name)):(s=c._inactiveShapeItems.getByUid(a.dataItem.uid),s&&(r=function(e){a=c._dataMap[e.id],t[i](a.getConnector(l.options.name)),t.updateModel()},c._deferredConnectionUpdates.push(s.onActivate(r))))):t[i](new J(e[i+"Point"]().x+o.x,e[i+"Point"]().y+o.y))},boundingBox:function(t,e){var i,n,o,r=$.empty(),s=gt(t)?this._getDiagramItems(t):{shapes:this.shapes};if(s.shapes.length>0)for(n=s.shapes[0],r=n.bounds(oe),o=1;o<s.shapes.length;o++)n=s.shapes[o],i=n.bounds(oe),e===!0&&(i.x-=n._rotationOffset.x,i.y-=n._rotationOffset.y),r=r.union(i);return r},_containerOffset:function(){var t=this.element.offset();return this.toolBar&&(t.top+=F(this.toolBar.element)),t},documentToView:function(t){var e=this._containerOffset();return new J(t.x-e.left,t.y-e.top);
},viewToDocument:function(t){var e=this._containerOffset();return new J(t.x+e.left,t.y+e.top)},viewToModel:function(t){return this._transformWithMatrix(t,this._matrixInvert)},modelToView:function(t){return this._transformWithMatrix(t,this._matrix)},modelToLayer:function(t){return this._transformWithMatrix(t,this._layerMatrix)},layerToModel:function(t){return this._transformWithMatrix(t,this._layerMatrixInvert)},documentToModel:function(t){var e=this.documentToView(t);return this.canvas.translate||(e.x=e.x+this.scroller.scrollLeft,e.y=e.y+this.scroller.scrollTop),this.viewToModel(e)},modelToDocument:function(t){return this.viewToDocument(this.modelToView(t))},_transformWithMatrix:function(t,e){var i,n,o=t;return t instanceof J?e&&(o=e.apply(t)):(i=this._transformWithMatrix(t.topLeft(),e),n=this._transformWithMatrix(t.bottomRight(),e),o=$.fromPoints(i,n)),o},setDataSource:function(t){this.options.dataSource=t,this._dataSource(),this.options.autoBind&&this.dataSource.fetch()},setConnectionsDataSource:function(t){this.options.connectionsDataSource=t,this._connectionDataSource(),this.options.autoBind&&this.connectionsDataSource.fetch()},layout:function(t){var e,i,n,o,r;switch(this._layouting=!0,pt(t)&&(t=this.options.layout),e=pt(t)||pt(t.type)?"Tree":t.type,e.toLowerCase()){case"tree":i=new B.TreeLayout(this);break;case"layered":i=new B.LayeredLayout(this);break;case"forcedirected":case"force":case"spring":case"springembedder":i=new B.SpringLayout(this);break;default:throw"Layout algorithm '"+e+"' is not supported."}n=new B.LayoutState(this),o=i.layout(t),o&&(r=new B.LayoutUndoUnit(n,o,t?t.animate:null),this.undoRedoService.add(r)),this._layouting=!1,this._redrawConnections()},getShapeById:function(t){var e;return(e=lt.first(this.shapes,function(e){return e.visual.id===t}))?e:e=lt.first(this.connections,function(e){return e.visual.id===t})},getShapeByModelId:function(t){var e;return e=this._isEditable?this._dataMap[t]:lt.first(this.shapes,function(e){return(e.dataItem||{}).id===t})},getShapeByModelUid:function(t){var e;return e=this._isEditable?lt.first(this.shapes,function(e){return(e.dataItem||{}).uid===t}):this._dataMap[t]},getConnectionByModelId:function(t){var e;return this.connectionsDataSource&&(e=lt.first(this.connections,function(e){return(e.dataItem||{}).id===t})),e},getConnectionByModelUid:function(t){var e;return this.connectionsDataSource&&(e=this._connectionsDataMap[t]),e},_extendLayoutOptions:function(t){t.layout&&(t.layout=O({},B.LayoutBase.fn.defaultOptions||{},t.layout))},_selectionChanged:function(t,e){(t.length||e.length)&&this.trigger(Ft,{selected:t,deselected:e})},_getValidZoom:function(t){return xt.min(xt.max(t,this.options.zoomMin),this.options.zoomMax)},_panTransform:function(t){var e=this,i=t||e._pan;e.canvas.translate?(e.scroller.scrollTo(i.x,i.y),e._zoomMainLayer()):(e._storePan(i),e._transformMainLayer())},_finishPan:function(){this.trigger(Ht,{total:this._pan,delta:Number.NaN})},_storePan:function(t){this._pan=t,this._storeViewMatrix()},_zoomMainLayer:function(){var t=this._zoom,e=new q(0,0,t,t);e.render(this.mainLayer),this._storeLayerMatrix(e),this._storeViewMatrix()},_transformMainLayer:function(){var t=this._pan,e=this._zoom,i=new q(t.x,t.y,e,e);i.render(this.mainLayer),this._storeLayerMatrix(i),this._storeViewMatrix()},_storeLayerMatrix:function(t){this._layerMatrix=t.toMatrix(),this._layerMatrixInvert=t.invert().toMatrix()},_storeViewMatrix:function(){var t=this._pan,e=this._zoom,i=new q(t.x,t.y,e,e);this._matrix=i.toMatrix(),this._matrixInvert=i.invert().toMatrix()},_toIndex:function(t,e){var i=this._getDiagramItems(t);this.mainLayer.toIndex(i.visuals,e),this._fixOrdering(i,!1)},_fixOrdering:function(t,e){var i,n,o=e?this.shapes.length-1:0,r=e?this.connections.length-1:0;for(i=0;i<t.shapes.length;i++)n=t.shapes[i],lt.remove(this.shapes,n),lt.insert(this.shapes,n,o);for(i=0;i<t.cons.length;i++)n=t.cons[i],lt.remove(this.connections,n),lt.insert(this.connections,n,r)},_getDiagramItems:function(t){var e,i,n={},o=t;for(n.visuals=[],n.shapes=[],n.cons=[],t?vt(t)||(o=[t]):o=this._selectedItems.slice(),e=0;e<o.length;e++)i=o[e],i instanceof x?(n.shapes.push(i),n.visuals.push(i.visual)):i instanceof b&&(n.cons.push(i),n.visuals.push(i.visual));return n},_removeItem:function(t,e,i){t.select(!1),t instanceof x?(this._removeShapeDataItem(t),this._removeShape(t,e,i)):t instanceof b&&(this._removeConnectionDataItem(t),this._removeConnection(t,e)),this.mainLayer.remove(t.visual)},_removeShape:function(t,e,i){var n,o,r,s,a=[],l=[];for(this.toolService._removeHover(),e&&this.undoRedoService.addCompositeItem(new X(t)),lt.remove(this.shapes,t),this._shapesQuadTree.remove(t),n=0;n<t.connectors.length;n++)for(r=t.connectors[n],s=0;s<r.connections.length;s++)o=r.connections[s],i&&M.inArray(o,i)||(o.sourceConnector==r?a.push(o):o.targetConnector==r&&l.push(o));for(n=0;n<a.length;n++)a[n].source(null,e),a[n].updateModel();for(n=0;n<l.length;n++)l[n].target(null,e),l[n].updateModel()},_removeConnection:function(t,e){t.sourceConnector&&lt.remove(t.sourceConnector.connections,t),t.targetConnector&&lt.remove(t.targetConnector.connections,t),e&&this.undoRedoService.addCompositeItem(new Q(t)),lt.remove(this.connections,t)},_removeDataItems:function(t,e){var i,n,o,r;for(t=vt(t)?t:[t];t.length;)if(i=t.shift(),o=this._dataMap[i.uid],o&&(this._removeShapeConnections(o),this._removeItem(o,!1),delete this._dataMap[i.uid],e&&i.hasChildren&&i.loaded()))for(n=i.children.data(),r=0;r<n.length;r++)t.push(n[r])},_removeShapeConnections:function(t){var e,i=t.connections();if(i)for(e=0;e<i.length;e++)this._removeItem(i[e],!1)},_addDataItem:function(t,e){var i,n;if(mt(t))return(i=this._dataMap[t.id])?i:(n=O({},this.options.shapeDefaults),n.dataItem=t,i=new x(n,this),this.addShape(i,e!==!1),this._dataMap[t.id]=i,i)},_addDataItemByUid:function(t){var e,i;if(mt(t))return(e=this._dataMap[t.uid])?e:(i=O({},this.options.shapeDefaults),i.dataItem=t,e=new x(i,this),this.addShape(e),this._dataMap[t.uid]=e,e)},_addDataItems:function(t,e){var i,n,o,r,s;for(n=0;n<t.length;n++)i=t[n],o=this._addDataItemByUid(i),r=this._addDataItemByUid(e),r&&!this.connected(r,o)&&(s=this.connect(r,o))},_refreshSource:function(t){var e,i,n=this,o=t.node,r=t.action,s=t.items,a=n.options;if(t.field)for(e=0;e<s.length;e++)this._dataMap[s[e].uid]&&this._dataMap[s[e].uid].redrawVisual();else{if("remove"==r)this._removeDataItems(t.items,!0);else for(r&&"itemloaded"!==r||this._bindingRoots||(this._bindingRoots=!0,i=!0),r||o||n.clear(),this._addDataItems(s,o),e=0;e<s.length;e++)s[e].load();a.layout&&(i||"remove"==r||"add"==r)&&n.layout(a.layout),i&&(this.trigger("dataBound"),this._bindingRoots=!1)}},_addItem:function(t){t instanceof x?this.addShape(t):t instanceof b&&this.addConnection(t)},_createToolBar:function(t){var e,i,n,o,r,s,a,l,c,h=this.toolService.diagram;this.singleToolBar||1!==h.select().length||(e=h.select()[0],e&&e.options.editable!==!1&&(i=e.options.editable,n=i.tools,this._isEditable&&0===n.length&&(e instanceof x?n=["edit","rotateClockwise","rotateAnticlockwise"]:e instanceof b&&(n=["edit"]),i&&i.remove!==!1&&n.push("delete")),n&&n.length&&(o=20,this.singleToolBar=new C(h,{tools:n,click:R(this._toolBarClick,this),modal:!0}),s=V(this.singleToolBar._popup.element),a=F(this.singleToolBar._popup.element),e instanceof x?(l=this.modelToView(e.bounds(oe)),r=J(l.x,l.y).minus(J((s-l.width)/2,a+o))):e instanceof b&&(c=this.modelToView(e.bounds()),r=J(c.x,c.y).minus(J((s-c.width-20)/2,a+o))),r?(this.canvas.translate||(r=r.minus(J(this.scroller.scrollLeft,this.scroller.scrollTop))),r=this.viewToDocument(r),r=J(xt.max(r.x,0),xt.max(r.y,0)),this.singleToolBar.showAt(r),t&&this.singleToolBar._popup.one("close",v)):this._destroyToolBar())))},_toolBarClick:function(t){this.trigger("toolBarClick",t),this._destroyToolBar()},_normalizePointZoom:function(t){return t.times(1/this.zoom())},_initialize:function(){this.shapes=[],this._selectedItems=[],this.connections=[],this._dataMap={},this._connectionsDataMap={},this._inactiveShapeItems=new h,this._deferredConnectionUpdates=[],this.undoRedoService=new it({undone:this._syncHandler,redone:this._syncHandler}),this.id=B.randomId()},_fetchFreshData:function(){var t=this;t._dataSource(),t._isEditable&&t._connectionDataSource(),t.options.autoBind&&(t._isEditable?(this._loadingShapes=!0,this._loadingConnections=!0,t.dataSource.fetch(),t.connectionsDataSource.fetch()):t.dataSource.fetch())},_dataSource:function(){var t,e;mt(this.options.connectionsDataSource)?(this._isEditable=!0,t=this.options.dataSource||{},e=vt(t)?{data:t}:t,this.dataSource&&this._shapesRefreshHandler?this.dataSource.unbind("change",this._shapesRefreshHandler).unbind("requestStart",this._shapesRequestStartHandler).unbind("error",this._shapesErrorHandler):(this._shapesRefreshHandler=R(this._refreshShapes,this),this._shapesRequestStartHandler=R(this._shapesRequestStart,this),this._shapesErrorHandler=R(this._error,this)),this.dataSource=kendo.data.DataSource.create(e).bind("change",this._shapesRefreshHandler).bind("requestStart",this._shapesRequestStartHandler).bind("error",this._shapesErrorHandler)):(this._treeDataSource(),this._isEditable=!1)},_connectionDataSource:function(){var t,e=this.options.connectionsDataSource;e&&(t=vt(e)?{data:e}:e,this.connectionsDataSource&&this._connectionsRefreshHandler?this.connectionsDataSource.unbind("change",this._connectionsRefreshHandler).unbind("requestStart",this._connectionsRequestStartHandler).unbind("error",this._connectionsErrorHandler):(this._connectionsRefreshHandler=R(this._refreshConnections,this),this._connectionsRequestStartHandler=R(this._connectionsRequestStart,this),this._connectionsErrorHandler=R(this._connectionsError,this)),this.connectionsDataSource=kendo.data.DataSource.create(t).bind("change",this._connectionsRefreshHandler).bind("requestStart",this._connectionsRequestStartHandler).bind("error",this._connectionsErrorHandler))},_shapesRequestStart:function(t){"read"==t.type&&(this._loadingShapes=!0)},_connectionsRequestStart:function(t){"read"==t.type&&(this._loadingConnections=!0)},_error:function(){this._loadingShapes=!1},_connectionsError:function(){this._loadingConnections=!1},_refreshShapes:function(t){"remove"===t.action?this._shouldRefresh()&&this._removeShapes(t.items):"itemchange"===t.action?this._shouldRefresh()&&this._updateShapes(t.items,t.field):"add"===t.action?this._inactiveShapeItems.add(t.items):"sync"===t.action?this._syncShapes(t.items):this.refresh()},_shouldRefresh:function(){return!this._suspended},_suspendModelRefresh:function(){this._suspended=(this._suspended||0)+1},_resumeModelRefresh:function(){this._suspended=xt.max((this._suspended||0)-1,0)},refresh:function(){this._loadingShapes=!1,this._loadingConnections||this._rebindShapesAndConnections()},_rebindShapesAndConnections:function(){this.clear(),this._addShapes(this.dataSource.view()),this.connectionsDataSource&&this._addConnections(this.connectionsDataSource.view(),!1),this.options.layout?this.layout(this.options.layout):this._redrawConnections(),this.trigger("dataBound")},refreshConnections:function(){this._loadingConnections=!1,this._loadingShapes||this._rebindShapesAndConnections()},_redrawConnections:function(){var t,e=this.connections;for(t=0;t<e.length;t++)e[t].refresh()},_removeShapes:function(t){var e,i,n=this._dataMap;for(i=0;i<t.length;i++)e=t[i],n[e.id]&&(this.remove(n[e.id],!1),n[e.id]=null)},_syncShapes:function(){var t=this,e=t._inactiveShapeItems;e.forEach(function(i){var n=i.dataItem,o=i.element;n.isNew()||(o?(o._setOptionsFromModel(),t.addShape(o,i.undoable),t._dataMap[n.id]=o):t._addDataItem(n),i.activate(),e.remove(n))})},_updateShapes:function(t,e){var i,n,o;for(i=0;i<t.length;i++)n=t[i],o=this._dataMap[n.id],o&&o.updateOptionsFromModel(n,e)},_addShapes:function(t){for(var e=0;e<t.length;e++)this._addDataItem(t[e],!1)},_refreshConnections:function(t){"remove"===t.action?this._shouldRefresh()&&this._removeConnections(t.items):"add"===t.action?this._addConnections(t.items):"sync"===t.action||("itemchange"===t.action?this._shouldRefresh()&&this._updateConnections(t.items):this.refreshConnections())},_removeConnections:function(t){for(var e=0;e<t.length;e++)this.remove(this._connectionsDataMap[t[e].uid],!1),this._connectionsDataMap[t[e].uid]=null},_updateConnections:function(t){var e,i,n;for(e=0;e<t.length;e++)i=t[e],n=this._connectionsDataMap[i.uid],n.updateOptionsFromModel(i)},_addConnections:function(t,e){var i,n,o=t.length;for(i=0;i<o;i++)n=t[i],this._addConnectionDataItem(n,e)},_addConnectionDataItem:function(t,e){var i,n,o,r;this._connectionsDataMap[t.uid]||(i=this._validateConnector(t.from),mt(i)&&null!==i||(i=new J(t.fromX,t.fromY)),n=this._validateConnector(t.to),mt(n)&&null!==n||(n=new J(t.toX,t.toY)),mt(i)&&mt(n)&&(o=O({},this.options.connectionDefaults),o.dataItem=t,r=new b(i,n,o),this._connectionsDataMap[t.uid]=r,this.addConnection(r,e)))},_validateConnector:function(t){var e;return mt(t)&&null!==t&&(e=this._dataMap[t]),e},_treeDataSource:function(){var t=this,e=t.options,i=e.dataSource;if(i=vt(i)?{data:i}:i,i instanceof kendo.data.DataSource&&!(i instanceof kendo.data.HierarchicalDataSource))throw Error("Incorrect DataSource type. If a single dataSource instance is set to the diagram then it should be a HierarchicalDataSource. You should set only the options instead of an instance or a HierarchicalDataSource instance or supply connectionsDataSource as well.");i.fields||(i.fields=[{field:"text"},{field:"url"},{field:"spriteCssClass"},{field:"imageUrl"}]),t.dataSource&&t._refreshHandler&&t._unbindDataSource(),t._refreshHandler=R(t._refreshSource,t),t._errorHandler=R(t._error,t),t.dataSource=H.create(i).bind(St,t._refreshHandler).bind(It,t._errorHandler)},_unbindDataSource:function(){var t=this;t.dataSource.unbind(St,t._refreshHandler).unbind(It,t._errorHandler)},_adorn:function(t,i){i!==e&&t&&(i?(this._adorners.push(t),this.adornerLayer.append(t.visual)):(lt.remove(this._adorners,t),this.adornerLayer.remove(t.visual)))},_showConnectors:function(t,e){e?this._connectorsAdorner.show(t):this._connectorsAdorner.destroy()},_updateAdorners:function(){var t,e,i=this._adorners;for(t=0;t<i.length;t++)e=i[t],e.refreshBounds&&e.refreshBounds(),e.refresh()},_refresh:function(){for(var t=0;t<this.connections.length;t++)this.connections[t].refresh()},_destroyToolBar:function(){this.singleToolBar&&(this.singleToolBar.hide(),this.singleToolBar.destroy(),this.singleToolBar=null)},_destroyGlobalToolBar:function(){this.toolBar&&(this.toolBar.hide(),this.toolBar.destroy(),this.toolBar=null)},exportDOMVisual:function(){var t=this.canvas._viewBox,e=I.transform().translate(-t.x,-t.y),i=new I.Rect([0,0],[t.width,t.height]),n=E.Path.fromRect(i),o=new E.Group({transform:e}),r=new E.Group({clip:n}),s=this.canvas.drawingElement.children[0];return r.append(o),o.children.push(s),r},exportVisual:function(){var t=I.transform().scale(1/this._zoom),e=new E.Group({transform:t}),i=this.mainLayer.drawingElement;return e.children.push(i),e},_syncChanges:function(){this._syncShapeChanges(),this._syncConnectionChanges()},_syncShapeChanges:function(){this.dataSource&&this._isEditable&&this.dataSource.sync()},_syncConnectionChanges:function(){var e=this;e.connectionsDataSource&&e._isEditable&&(t.when.apply(t,e._deferredConnectionUpdates).then(function(){e.connectionsDataSource.sync()}),e.deferredConnectionUpdates=[])}}),M.ExportMixin.extend(k.fn,!0),kendo.PDFMixin&&kendo.PDFMixin.extend(k.fn),C=kendo.Observable.extend({init:function(t,e){kendo.Observable.fn.init.call(this),this.diagram=t,this.options=O({},this.options,e),this._tools=[],this.createToolBar(),this.createTools(),this.appendTools(),this.options.modal&&this.createPopup(),this.bind(this.events,e)},events:["click"],createPopup:function(){this.container=t("<div/>").append(this.element),this._popup=this.container.kendoPopup({}).getKendoPopup()},appendTools:function(){var t,e;for(t=0;t<this._tools.length;t++)e=this._tools[t],(e.buttons&&e.buttons.length||!mt(e.buttons))&&this._toolBar.add(e)},createToolBar:function(){this.element=t("<div/>"),this._toolBar=this.element.kendoToolBar({click:R(this.click,this),resizable:!1}).getKendoToolBar(),this.element.css("border","none")},createTools:function(){for(var t=0;t<this.options.tools.length;t++)this.createTool(this.options.tools[t])},createTool:function(t){wt(t)||(t={name:t});var e=t.name+"Tool";this[e]?this[e](t):this._tools.push(O({},t,{attributes:this._setAttributes({action:t.name})}))},showAt:function(t){this._popup&&this._popup.open(t.x,t.y)},hide:function(){this._popup&&this._popup.close()},newGroup:function(){return{type:"buttonGroup",buttons:[]}},editTool:function(){this._tools.push({spriteCssClass:"k-icon k-i-pencil",showText:"overflow",type:"button",text:"Edit",attributes:this._setAttributes({action:"edit"})})},deleteTool:function(){this._tools.push({spriteCssClass:"k-icon k-i-close",showText:"overflow",type:"button",text:"Delete",attributes:this._setAttributes({action:"delete"})})},rotateAnticlockwiseTool:function(t){this._appendGroup("rotate"),this._rotateGroup.buttons.push({spriteCssClass:"k-icon k-i-rotateccw",showText:"overflow",text:"RotateAnticlockwise",group:"rotate",attributes:this._setAttributes({action:"rotateAnticlockwise",step:t.step})})},rotateClockwiseTool:function(t){this._appendGroup("rotate"),this._rotateGroup.buttons.push({spriteCssClass:"k-icon k-i-rotatecw",attributes:this._setAttributes({action:"rotateClockwise",step:t.step}),showText:"overflow",text:"RotateClockwise",group:"rotate"})},createShapeTool:function(){this._appendGroup("create"),this._createGroup.buttons.push({spriteCssClass:"k-icon k-i-shape",showText:"overflow",text:"CreateShape",group:"create",attributes:this._setAttributes({action:"createShape"})})},createConnectionTool:function(){this._appendGroup("create"),this._createGroup.buttons.push({spriteCssClass:"k-icon k-i-connector",showText:"overflow",text:"CreateConnection",group:"create",attributes:this._setAttributes({action:"createConnection"})})},undoTool:function(){this._appendGroup("history"),this._historyGroup.buttons.push({spriteCssClass:"k-icon k-i-undo",showText:"overflow",text:"Undo",group:"history",attributes:this._setAttributes({action:"undo"})})},redoTool:function(){this._appendGroup("history"),this._historyGroup.buttons.push({spriteCssClass:"k-icon k-i-redo",showText:"overflow",text:"Redo",group:"history",attributes:this._setAttributes({action:"redo"})})},_appendGroup:function(t){var e="_"+t+"Group";this[e]||(this[e]=this.newGroup(),this._tools.push(this[e]))},_setAttributes:function(t){var e={};return t.action&&(e[kendo.attr("action")]=t.action),t.step&&(e[kendo.attr("step")]=t.step),e},_getAttributes:function(t){var e,i={},n=t.attr(kendo.attr("action"));return n&&(i.action=n),e=t.attr(kendo.attr("step")),e&&(i.step=e),i},click:function(e){var i=this._getAttributes(t(e.target)),n=i.action;n&&this[n]&&this[n](i),this.trigger("click",this.eventData(n,e.target))},eventData:function(t,e){var i,n,o=this.selectedElements(),r=o.length,s=[],a=[];for(n=0;n<r;n++)i=o[n],i instanceof x?s.push(i):a.push(i);return{shapes:s,connections:a,action:t,target:e}},"delete":function(){var t=this.diagram,e=t._triggerRemove(this.selectedElements());e.length&&(this.diagram.remove(e,!0),this.diagram._syncChanges())},edit:function(){var t=this.selectedElements();1===t.length&&this.diagram.edit(t[0])},rotateClockwise:function(t){var e=parseFloat(t.step||90);this._rotate(e)},rotateAnticlockwise:function(t){var e=parseFloat(t.step||90);this._rotate(-e)},_rotate:function(t){var e=this.diagram._resizingAdorner;e.angle(e.angle()+t),e.rotate()},selectedElements:function(){return this.diagram.select()},createShape:function(){this.diagram.createShape()},createConnection:function(){this.diagram.createConnection()},undo:function(){this.diagram.undo()},redo:function(){this.diagram.redo()},destroy:function(){this.diagram=null,this.element=null,this.options=null,this._toolBar&&this._toolBar.destroy(),this._popup&&this._popup.destroy()}}),S=kendo.Observable.extend({init:function(t,e){kendo.Observable.fn.init.call(this),this.options=N(!0,{},this.options,e),this.element=t,this.model=this.options.model,this.fields=this._getFields(),this._initContainer(),this.createEditable()},options:{editors:{}},_initContainer:function(){this.wrapper=this.element},createEditable:function(){var t=this.options;this.editable=new kendo.ui.Editable(this.wrapper,{fields:this.fields,target:t.target,clearContainer:!1,model:this.model})},_isEditable:function(t){return this.model.editable&&this.model.editable(t)},_getFields:function(){var t,e,i,n=[],o=this.model.fields;for(t in o)e={},this._isEditable(t)&&(i=this.options.editors[t],i&&(e.editor=i),e.field=t,n.push(e));return n},end:function(){return this.editable.end()},destroy:function(){this.editable.destroy(),this.editable.element.find("["+kendo.attr("container-for")+"]").empty(),this.model=this.wrapper=this.element=this.columns=this.editable=null}}),T=S.extend({init:function(t,e){S.fn.init.call(this,t,e),this.bind(this.events,this.options),this.open()},events:["update","cancel"],options:{window:{modal:!0,resizable:!1,draggable:!0,title:"Edit",visible:!1}},_initContainer:function(){var e,i=this;this.wrapper=t('<div class="k-popup-edit-form"/>').attr(kendo.attr("uid"),this.model.uid),e="",this.options.template?(e+=this._renderTemplate(),this.fields=[]):e+=this._renderFields(),e+=this._renderButtons(),this.wrapper.append(t('<div class="k-edit-form-container"/>').append(e)),this.window=new kendo.ui.Window(this.wrapper.appendTo(this.element),this.options.window),this.window.bind("close",function(t){t.userTriggered&&(t.sender.element.focus(),i._cancelClick(t))}),this._attachButtonEvents()},_renderTemplate:function(){var t=this.options.template;return"string"==typeof t&&(t=window.unescape(t)),t=kendo.template(t)(this.model)},_renderFields:function(){var t,e,i="";for(t=0;t<this.fields.length;t++)e=this.fields[t],i+='<div class="k-edit-label"><label for="'+e.field+'">'+(e.field||"")+"</label></div>",this._isEditable(e.field)&&(i+="<div "+kendo.attr("container-for")+'="'+e.field+'" class="k-edit-field"></div>');return i},_renderButtons:function(){var t='<div class="k-edit-buttons k-state-default">';return t+=this._createButton("update"),t+=this._createButton("cancel"),t+="</div>"},_createButton:function(t){return kendo.template(fe)(_[t])},_attachButtonEvents:function(){this._cancelClickHandler=R(this._cancelClick,this),this.window.element.on(Tt+bt,"a.k-diagram-cancel",this._cancelClickHandler),this._updateClickHandler=R(this._updateClick,this),this.window.element.on(Tt+bt,"a.k-diagram-update",this._updateClickHandler)},_updateClick:function(t){t.preventDefault(),this.trigger("update")},_cancelClick:function(t){t.preventDefault(),this.trigger("cancel")},open:function(){this.window.center().open()},close:function(){this.window.bind("deactivate",R(this.destroy,this)).close()},destroy:function(){this.window.close().destroy(),this.window.element.off(Tt+bt,"a.k-diagram-cancel",this._cancelClickHandler),this.window.element.off(Tt+bt,"a.k-diagram-update",this._updateClickHandler),this._cancelClickHandler=null,this._editUpdateClickHandler=null,this.window=null,S.fn.destroy.call(this)}}),c.fn=c.prototype={onActivate:function(e){var i=t.Deferred();return this.callbacks.push({callback:e,deferred:i}),i},activate:function(){var t,e,i=this.callbacks;for(e=0;e<i.length;e++)t=this.callbacks[e],t.callback(this.dataItem),t.deferred.resolve();this.callbacks=[]}},h.fn=h.prototype={add:function(t){for(var e=0;e<t.length;e++)this.items[t[e].uid]=new c(t[e])},forEach:function(t){for(var e in this.items)t(this.items[e])},getByUid:function(t){return this.items[t]},remove:function(t){delete this.items[t.uid]}},A=L.extend({init:function(){this.shapes=[]},_add:function(t,e){this.shapes.push({bounds:e,shape:t}),t._quadNode=this},insert:function(t,e){this._add(t,e)},remove:function(t){var e,i=this.shapes,n=i.length;for(e=0;e<n;e++)if(i[e].shape===t){i.splice(e,1);break}},hitTestRect:function(t){var e,i=this.shapes,n=i.length;for(e=0;e<n;e++)if(this._testRect(i[e].shape,t))return!0},_testRect:function(t,e){var i,n=t.rotate().angle,o=t.bounds();return i=n?tt.rects(e,o,-n):o.overlaps(e)}}),P=A.extend({init:function(t){A.fn.init.call(this),this.children=[],this.rect=t},inBounds:function(t){var e=this.rect,i=e.bottomRight(),n=t.bottomRight(),o=e.x<=t.x&&e.y<=t.y&&n.x<=i.x&&n.y<=i.y;return o},overlapsBounds:function(t){return this.rect.overlaps(t)},insert:function(t,e){var i,n=!1,o=this.children,r=o.length;if(this.inBounds(e)){if(!r&&this.shapes.length<4)this._add(t,e);else{for(r||this._initChildren(),i=0;i<o.length;i++)if(o[i].insert(t,e)){n=!0;break}n||this._add(t,e)}n=!0}return n},_initChildren:function(){var t,e,i=this.rect,n=this.children,o=this.shapes,r=i.center(),s=i.width/2,a=i.height/2;for(n.push(new P(new $(i.x,i.y,s,a)),new P(new $(r.x,i.y,s,a)),new P(new $(i.x,r.y,s,a)),new P(new $(r.x,r.y,s,a))),e=o.length-1;e>=0;e--)for(t=0;t<n.length;t++)if(n[t].insert(o[e].shape,o[e].bounds)){o.splice(e,1);break}},hitTestRect:function(t){var e,i=this.children,n=i.length,o=!1;if(this.overlapsBounds(t))if(A.fn.hitTestRect.call(this,t))o=!0;else for(e=0;e<n;e++)if(i[e].hitTestRect(t)){o=!0;break}return o}}),D=L.extend({ROOT_SIZE:1e3,init:function(t){var e=R(this._boundsChange,this);t.bind(Ct,e),t.bind(Nt,e),this.initRoots()},initRoots:function(){this.rootMap={},this.root=new A},clear:function(){this.initRoots()},_boundsChange:function(t){t.item._quadNode&&t.item._quadNode.remove(t.item),this.insert(t.item)},insert:function(t){var e=t.bounds(oe),i=this.ROOT_SIZE,n=this.getSectors(e),o=n[0][0],r=n[1][0];this.inRoot(n)?this.root.insert(t,e):(this.rootMap[o]||(this.rootMap[o]={}),this.rootMap[o][r]||(this.rootMap[o][r]=new P(new $(o*i,r*i,i,i))),this.rootMap[o][r].insert(t,e))},remove:function(t){t._quadNode&&t._quadNode.remove(t)},inRoot:function(t){return t[0].length>1||t[1].length>1},getSectors:function(t){var e,i,n=this.ROOT_SIZE,o=t.bottomRight(),r=xt.floor(o.x/n),s=xt.floor(o.y/n),a=[[],[]];for(e=xt.floor(t.x/n);e<=r;e++)a[0].push(e);for(i=xt.floor(t.y/n);i<=s;i++)a[1].push(i);return a},hitTestRect:function(t){var e,i,n,o,r,s=this.getSectors(t);if(this.root.hitTestRect(t))return!0;for(e=0;e<s[0].length;e++)for(n=s[0][e],i=0;i<s[1].length;i++)if(o=s[1][i],r=(this.rootMap[n]||{})[o],r&&r.hitTestRect(t))return!0;return!1}}),M.ui.plugin(k),O(B,{Shape:x,Connection:b,Connector:w,DiagramToolBar:C,QuadNode:P,QuadRoot:A,ShapesQuadTree:D,PopupEditor:T})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.diagram.min",["kendo.data.min","kendo.draganddrop.min","kendo.userevents.min","kendo.mobile.scroller.min","kendo.drawing.min","dataviz/diagram/utils.min","dataviz/diagram/math.min","dataviz/diagram/svg.min","dataviz/diagram/services.min","dataviz/diagram/layout.min","dataviz/diagram/dom.min"],t)}(function(){return window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.treemap.min",["kendo.data.min","kendo.userevents.min","kendo.dataviz.themes.min"],t)}(function(){return function(t,e){function i(t,e){if(null===e)return e;var i=C(t,!0);return i(e)}function n(t){return typeof t!==B}function o(t,e,i){var n,o,l=a(t),c=a(e),h=u(t)-u(e)<0,d=[];for(d.push(t),n=0;n<i;n++)o={r:r(l.r,c.r,n,i,h),g:r(l.g,c.g,n,i,h),b:r(l.b,c.b,n,i,h)},d.push(s(o));return d.push(e),d}function r(t,e,i,n,o){var r,s=f.min(f.abs(t),f.abs(e)),a=f.max(f.abs(t),f.abs(e)),l=(a-s)/(n+1),c=l*(i+1);return r=o?s+c:a-c}function s(t){return"#"+l(t.r)+l(t.g)+l(t.b)}function a(t){t=t.replace("#","");var e=c(t);return{r:h(e.r),g:h(e.g),b:h(e.b)}}function l(t){var e=f.round(t).toString(16).toUpperCase();return 1===e.length&&(e="0"+e),e}function c(t){var e=t.length,i={};return 3===e?(i.r=t[0],i.g=t[1],i.b=t[2]):(i.r=t.substring(0,2),i.g=t.substring(2,4),i.b=t.substring(4,6)),i}function h(t){return parseInt(t.toString(16),16)}function u(t){var e=0;return t&&(t=a(t),e=f.sqrt(.241*t.r*t.r+.691*t.g*t.g+.068*t.b*t.b)),e}function d(t){var e=f.pow(10,4);return f.round(t*e)/e}var f=Math,p=t.proxy,g=t.isArray,m=window.kendo,v=m._outerHeight,_=m._outerWidth,y=m.Class,w=m.ui.Widget,x=m.template,b=m.deepExtend,k=m.data.HierarchicalDataSource,C=m.getter,S=m.dataviz,T=".kendoTreeMap",A="change",P="dataBound",D="itemCreated",M=Number.MAX_VALUE,E="mouseover"+T,I="mouseleave"+T,B="undefined",z=w.extend({init:function(e,i){m.destroy(e),t(e).empty(),w.fn.init.call(this,e,i),this.wrapper=this.element,this._initTheme(this.options),this.element.addClass("k-widget k-treemap"),this._setLayout(),this._originalOptions=b({},this.options),this._initDataSource(),this._attachEvents(),m.notify(this,S.ui)},options:{name:"TreeMap",theme:"default",autoBind:!0,textField:"text",valueField:"value",colorField:"color"},events:[P,D],_initTheme:function(t){var e=this,i=S.ui.themes||{},n=((t||{}).theme||"").toLowerCase(),o=(i[n]||{}).treeMap;e.options=b({},o,t)},_attachEvents:function(){this.element.on(E,p(this._mouseover,this)).on(I,p(this._mouseleave,this)),this._resizeHandler=p(this.resize,this,!1),m.onResize(this._resizeHandler)},_setLayout:function(){"horizontal"===this.options.type?(this._layout=new O((!1)),this._view=new V(this,this.options)):"vertical"===this.options.type?(this._layout=new O((!0)),this._view=new V(this,this.options)):(this._layout=new L,this._view=new R(this,this.options))},_initDataSource:function(){var t=this,e=t.options,i=e.dataSource;t._dataChangeHandler=p(t._onDataChange,t),t.dataSource=k.create(i).bind(A,t._dataChangeHandler),i&&t.options.autoBind&&t.dataSource.fetch()},setDataSource:function(t){var e=this;e.dataSource.unbind(A,e._dataChangeHandler),e.dataSource=t.bind(A,e._dataChangeHandler),t&&e.options.autoBind&&e.dataSource.fetch()},_onDataChange:function(t){var e,i,n,o,r=t.node,s=t.items,a=this.options;if(r){if(s.length){for(n=this._getByUid(r.uid),n.children=[],s=new m.data.Query(s)._sortForGrouping(a.valueField,"desc"),i=0;i<s.length;i++)e=s[i],n.children.push(this._wrapItem(e));o=this._view.htmlSize(n),this._layout.compute(n.children,n.coord,o),this._setColors(n.children),this._view.render(n)}}else this._cleanItems(),this.element.empty(),e=this._wrapItem(s[0]),this._layout.createRoot(e,_(this.element),v(this.element),"vertical"===this.options.type),this._view.createRoot(e),this._root=e,this._colorIdx=0;for(i=0;i<s.length;i++)s[i].load();r&&this.trigger(P,{node:r})},_cleanItems:function(){var t=this;t.angular("cleanup",function(){return{elements:t.element.find(".k-leaf div,.k-treemap-title,.k-treemap-title-vertical")}})},_setColors:function(t){var e,i,r,s,a=this.options.colors,l=this._colorIdx,c=a[l%a.length];for(g(c)&&(e=o(c[0],c[1],t.length)),r=!1,s=0;s<t.length;s++)i=t[s],n(i.color)||(i.color=e?e[s]:c),i.dataItem.hasChildren||(r=!0);r&&this._colorIdx++},_contentSize:function(t){this.view.renderHeight(t)},_wrapItem:function(t){var e={};return n(this.options.valueField)&&(e.value=i(this.options.valueField,t)),n(this.options.colorField)&&(e.color=i(this.options.colorField,t)),n(this.options.textField)&&(e.text=i(this.options.textField,t)),e.level=t.level(),e.dataItem=t,e},_getByUid:function(t){for(var e,i=[this._root];i.length;){if(e=i.pop(),e.dataItem.uid===t)return e;e.children&&(i=i.concat(e.children))}},dataItem:function(e){var i=t(e).attr(m.attr("uid")),n=this.dataSource;return n&&n.getByUid(i)},findByUid:function(t){return this.element.find(".k-treemap-tile["+m.attr("uid")+"='"+t+"']")},_mouseover:function(e){var i=t(e.target);i.hasClass("k-leaf")&&(this._removeActiveState(),i.removeClass("k-state-hover").addClass("k-state-hover"))},_removeActiveState:function(){this.element.find(".k-state-hover").removeClass("k-state-hover")},_mouseleave:function(){this._removeActiveState()},destroy:function(){w.fn.destroy.call(this),this.element.off(T),this.dataSource&&this.dataSource.unbind(A,this._dataChangeHandler),this._root=null,m.unbindResize(this._resizeHandler),m.destroy(this.element);
},items:function(){return t()},getSize:function(){return m.dimensions(this.element)},_resize:function(){var t,e,i=this._root;i&&(t=this.element,e=t.children(),i.coord.width=_(t),i.coord.height=v(t),e.css({width:i.coord.width,height:i.coord.height}),this._resizeItems(i,e))},_resizeItems:function(t,e){var i,n,o,r;if(t.children&&t.children.length)for(i=e.children(".k-treemap-wrap").children(),this._layout.compute(t.children,t.coord,{text:this._view.titleSize(t,e)}),r=0;r<t.children.length;r++)n=t.children[r],o=i.filter("["+m.attr("uid")+"='"+n.dataItem.uid+"']"),this._view.setItemSize(n,o),this._resizeItems(n,o)},setOptions:function(t){var i=t.dataSource;t.dataSource=e,this._originalOptions=b(this._originalOptions,t),this.options=b({},this._originalOptions),this._setLayout(),this._initTheme(this.options),w.fn._setEvents.call(this,t),i&&this.setDataSource(k.create(i)),this.options.autoBind&&this.dataSource.fetch()}}),L=y.extend({createRoot:function(t,e,i){t.coord={width:e,height:i,top:0,left:0}},leaf:function(t){return!t.children},layoutChildren:function(t,e){var i,n,o,r,s=e.width*e.height,a=0,l=[];for(i=0;i<t.length;i++)l[i]=parseFloat(t[i].value),a+=l[i];for(i=0;i<l.length;i++)t[i].area=s*l[i]/a;n=this.layoutHorizontal()?e.height:e.width,o=[t[0]],r=t.slice(1),this.squarify(r,o,n,e)},squarify:function(t,e,i,n){this.computeDim(t,e,i,n)},computeDim:function(t,i,n,o){var r,s,a;return t.length+i.length==1?(r=1==t.length?t:i,this.layoutLast(r,n,o),e):(t.length>=2&&0===i.length&&(i=[t[0]],t=t.slice(1)),0===t.length?(i.length>0&&this.layoutRow(i,n,o),e):(s=t[0],this.worstAspectRatio(i,n)>=this.worstAspectRatio([s].concat(i),n)?this.computeDim(t.slice(1),i.concat([s]),n,o):(a=this.layoutRow(i,n,o),this.computeDim(t,[],a.dim,a)),e))},layoutLast:function(t,e,i){t[0].coord=i},layoutRow:function(t,e,i){return this.layoutHorizontal()?this.layoutV(t,e,i):this.layoutH(t,e,i)},orientation:"h",layoutVertical:function(){return"v"===this.orientation},layoutHorizontal:function(){return"h"===this.orientation},layoutChange:function(){this.orientation=this.layoutVertical()?"h":"v"},worstAspectRatio:function(t,e){var i,n,o,r,s;if(!t||0===t.length)return M;for(i=0,n=0,o=M,r=0;r<t.length;r++)s=t[r].area,i+=s,o=o<s?o:s,n=n>s?n:s;return f.max(e*e*n/(i*i),i*i/(e*e*o))},compute:function(t,e,i){if(e.width>=e.height&&this.layoutHorizontal()||this.layoutChange(),t&&t.length>0){var n={width:e.width,height:e.height-i.text,top:0,left:0};this.layoutChildren(t,n)}},layoutV:function(t,e,i){var n,o,r,s=this._totalArea(t),a=0;for(e=d(s/e),n=0;n<t.length;n++)o=d(t[n].area/e),t[n].coord={height:o,width:e,top:i.top+a,left:i.left},a+=o;return r={height:i.height,width:i.width-e,top:i.top,left:i.left+e},r.dim=f.min(r.width,r.height),r.dim!=r.height&&this.layoutChange(),r},layoutH:function(t,e,i){var n,o,r=this._totalArea(t),s=d(r/e),a=i.top,l=0;for(n=0;n<t.length;n++)t[n].coord={height:s,width:d(t[n].area/s),top:a,left:i.left+l},l+=t[n].coord.width;return o={height:i.height-s,width:i.width,top:i.top+s,left:i.left},o.dim=f.min(o.width,o.height),o.dim!=o.width&&this.layoutChange(),o},_totalArea:function(t){var e,i=0;for(e=0;e<t.length;e++)i+=t[e].area;return i}}),R=y.extend({init:function(e,i){this.options=b({},this.options,i),this.treeMap=e,this.element=t(e.element),this.offset=0},titleSize:function(t,e){var i=e.children(".k-treemap-title");return i.height()},htmlSize:function(t){var e,i,n=this._getByUid(t.dataItem.uid),o={text:0};return t.children&&(this._clean(n),e=this._getText(t),e&&(i=this._createTitle(t),n.append(i),this._compile(i,t.dataItem),o.text=i.height()),n.append(this._createWrap()),this.offset=(_(n)-n.innerWidth())/2),o},_compile:function(t,e){this.treeMap.angular("compile",function(){return{elements:t,data:[{dataItem:e}]}})},_getByUid:function(t){return this.element.find(".k-treemap-tile["+m.attr("uid")+"='"+t+"']")},render:function(t){var e,i,n,o,r=this._getByUid(t.dataItem.uid),s=t.children;if(s)for(e=r.find(".k-treemap-wrap"),i=0;i<s.length;i++)n=s[i],o=this._createLeaf(n),e.append(o),this._compile(o.children(),n.dataItem),this.treeMap.trigger(D,{element:o})},createRoot:function(t){var e=this._createLeaf(t);this.element.append(e),this._compile(e.children(),t.dataItem),this.treeMap.trigger(D,{element:e})},_clean:function(t){this.treeMap.angular("cleanup",function(){return{elements:t.children(":not(.k-treemap-wrap)")}}),t.css("background-color",""),t.removeClass("k-leaf"),t.removeClass("k-inverse"),t.empty()},_createLeaf:function(e){return this._createTile(e).css("background-color",e.color).addClass("k-leaf").toggleClass("k-inverse",this._tileColorBrightness(e)>180).append(t("<div></div>").html(this._getText(e)))},_createTile:function(e){var i=t("<div class='k-treemap-tile'></div>");return this.setItemSize(e,i),n(e.dataItem)&&n(e.dataItem.uid)&&i.attr(m.attr("uid"),e.dataItem.uid),i},_itemCoordinates:function(t){var e={width:t.coord.width,height:t.coord.height,left:t.coord.left,top:t.coord.top};return e.width+=e.left&&this.offset?2*this.offset:this.offset,e.height+=e.top?2*this.offset:this.offset,e},setItemSize:function(t,e){var i=this._itemCoordinates(t);e.css({width:i.width,height:i.height,left:i.left,top:i.top})},_getText:function(t){var e=t.text;return this.options.template&&(e=this._renderTemplate(t)),e},_renderTemplate:function(t){var e=x(this.options.template);return e({dataItem:t.dataItem,text:t.text})},_createTitle:function(e){return t("<div class='k-treemap-title'></div>").append(t("<div></div>").html(this._getText(e)))},_createWrap:function(){return t("<div class='k-treemap-wrap'></div>")},_tileColorBrightness:function(t){return u(t.color)}}),O=y.extend({createRoot:function(t,e,i,n){t.coord={width:e,height:i,top:0,left:0},t.vertical=n},init:function(t){this.vertical=t,this.quotient=t?1:0},compute:function(t,e,i){var n,o,r;t.length>0&&(n=e.width,o=e.height,this.vertical?o-=i.text:n-=i.text,r={width:n,height:o,top:0,left:0},this.layoutChildren(t,r))},layoutChildren:function(t,e){var i,n,o=e.width*e.height,r=0,s=[];for(i=0;i<t.length;i++)n=t[i],s[i]=parseFloat(t[i].value),r+=s[i],n.vertical=this.vertical;for(i=0;i<s.length;i++)t[i].area=o*s[i]/r;this.sliceAndDice(t,e)},sliceAndDice:function(t,e){var i=this._totalArea(t);t[0].level%2===this.quotient?this.layoutHorizontal(t,e,i):this.layoutVertical(t,e,i)},layoutHorizontal:function(t,e,i){var n,o,r,s=0;for(n=0;n<t.length;n++)o=t[n],r=o.area/(i/e.width),o.coord={height:e.height,width:r,top:e.top,left:e.left+s},s+=r},layoutVertical:function(t,e,i){var n,o,r,s=0;for(n=0;n<t.length;n++)o=t[n],r=o.area/(i/e.height),o.coord={height:r,width:e.width,top:e.top+s,left:e.left},s+=r},_totalArea:function(t){var e,i=0;for(e=0;e<t.length;e++)i+=t[e].area;return i}}),V=R.extend({htmlSize:function(t){var e,i,n=this._getByUid(t.dataItem.uid),o={text:0,offset:0};return t.children&&(this._clean(n),e=this._getText(t),e&&(i=this._createTitle(t),n.append(i),this._compile(i,t.dataItem),o.text=t.vertical?i.height():i.width()),n.append(this._createWrap()),this.offset=(_(n)-n.innerWidth())/2),o},titleSize:function(t,e){var i;return i=t.vertical?e.children(".k-treemap-title").height():e.children(".k-treemap-title-vertical").width()},_createTitle:function(e){var i;return i=t(e.vertical?"<div class='k-treemap-title'></div>":"<div class='k-treemap-title-vertical'></div>"),i.append(t("<div></div>").html(this._getText(e)))}});S.ui.plugin(z)}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.angular.min",["kendo.core.min"],t)}(function(){return function(t,e,i){"use strict";function n(t){var e=T;try{return T=function(t){return t()},t()}finally{T=e}}function o(e,n,o,c,h,m){function v(){var i,m,v,_,y,k,S;return o.kRebind&&(i=t(t(n)[0].cloneNode(!0))),C=r(e,n,o,c,b).options,n.is("select")&&!function(e){if(e.length>0){var i=t(e[0]);!/\S/.test(i.text())&&/^\?/.test(i.val())&&i.remove()}}(n[0].options),m=b.call(n,D=C).data(c),l(m,e,o,c,h),e.$emit("kendoWidgetCreated",m),v=f(e,m),o.kRebind&&g(m,e,n,i,o.kRebind,v,o),o.kNgDisabled&&(_=o.kNgDisabled,y=e.$eval(_),y&&m.enable(!y),s(m,e,n,_)),o.kNgReadonly&&(k=o.kNgReadonly,S=e.$eval(k),S&&m.readonly(S),a(m,e,n,k)),o.kNgModel&&d(m,e,o.kNgModel),w&&u(m,e,n,w,x),m&&p(m,n),m}var _,y,w,x,b,k,C,S,A,P,M,E,I,B;if(!(n instanceof jQuery))throw Error("The Kendo UI directives require jQuery to be available before AngularJS. Please include jquery before angular in the document.");if(_=o.kNgDelay,y=e.$eval(_),m=m||[],w=m[0],x=m[1],b=t(n)[c],!b)return window.console.error("Could not find: "+c),null;if(k=r(e,n,o,c,b),C=k.options,k.unresolved.length){for(S=[],A=0,P=k.unresolved.length;A<P;A++)M=k.unresolved[A],E=t.Deferred(function(t){var n=e.$watch(M.path,function(e){e!==i&&(n(),t.resolve())})}).promise(),S.push(E);return t.when.apply(null,S).then(v),i}return _&&!y?(I=e.$root||e,B=function(){var t=e.$watch(_,function(e){e!==i&&(t(),n.removeAttr(o.$attr.kNgDelay),_=null,T(v))})},/^\$(digest|apply)$/.test(I.$$phase)?B():e.$apply(B),i):v()}function r(n,o,r,s,a){function l(t,o){var r=e.copy(n.$eval(o));r===i?p.push({option:t,path:o}):c[t]=r}var c,h,u,d,f=s.replace(/^kendo/,""),p=[],g=r.kOptions||r.options,m=n.$eval(g);return g&&m===i&&p.push({option:"options",path:g}),c=e.extend({},r.defaultOptions,m),h=a.widget.prototype.options,u=a.widget.prototype.events,t.each(r,function(t,e){var i,n,o,r;"source"!==t&&"kDataSource"!==t&&"kScopeField"!==t&&"scopeField"!==t&&(i="data"+t.charAt(0).toUpperCase()+t.slice(1),0===t.indexOf("on")&&(n=t.replace(/^on./,function(t){return t.charAt(2).toLowerCase()}),u.indexOf(n)>-1&&(c[n]=e)),h.hasOwnProperty(i)?l(i,e):h.hasOwnProperty(t)&&!I[t]?l(t,e):E[t]||(o=t.match(/^k(On)?([A-Z].*)/),o&&(r=o[2].charAt(0).toLowerCase()+o[2].slice(1),o[1]&&"kOnLabel"!=t?c[r]=e:("kOnLabel"==t&&(r="onLabel"),l(r,e)))))}),d=r.kDataSource||r.source,d&&(c.dataSource=M(n,o,f,d)),c.$angular=[n],{options:c,unresolved:p}}function s(t,e,n,o){return kendo.ui.PanelBar&&t instanceof kendo.ui.PanelBar||kendo.ui.Menu&&t instanceof kendo.ui.Menu?(P.warn("k-ng-disabled specified on a widget that does not have the enable() method: "+t.options.name),i):(e.$watch(o,function(e,i){e!=i&&t.enable(!e)}),i)}function a(t,e,n,o){return"function"!=typeof t.readonly?(P.warn("k-ng-readonly specified on a widget that does not have the readonly() method: "+t.options.name),i):(e.$watch(o,function(e,i){e!=i&&t.readonly(e)}),i)}function l(t,e,i,n,o){if(i[o]){var r=S(i[o]).assign;if(!r)throw Error(o+" attribute used but expression in it is not assignable: "+i[n]);r(e,t)}}function c(t){return/checkbox|radio/i.test(t.attr("type"))?t.prop("checked"):t.val()}function h(t){return B.test(t[0].tagName)}function u(t,e,n,o,r){var s,a,l,u,d;t.value&&(a=!1,s=h(n)?function(){return c(n)}:function(){return t.value()},l=function(){var n=o.$viewValue;n===i&&(n=o.$modelValue),n===i&&(n=null),a=!0,setTimeout(function(){if(a=!1,t){var i=e[t.element.attr("k-ng-model")];i&&(n=i),t.options.autoBind!==!1||t.listView.bound()?t.value(n):n&&t.value(n)}},0)},o.$render=l,setTimeout(function(){o.$render!==l&&(o.$render=l)()}),h(n)&&n.on("change",function(){a=!0}),u=function(t){return function(){var i;a||(t&&r&&(i=r.$pristine),o.$setViewValue(s()),t&&(o.$setPristine(),i&&r.$setPristine()),w(e))}},t.first("change",u(!1)),t.first("spin",u(!1)),kendo.ui.AutoComplete&&t instanceof kendo.ui.AutoComplete||t.first("dataBound",u(!0)),d=s(),isNaN(o.$viewValue)||d==o.$viewValue||(o.$isEmpty(o.$viewValue)?null!=d&&""!==d&&d!=o.$viewValue&&o.$setViewValue(d):t.value(o.$viewValue)),o.$setPristine())}function d(e,n,o){var r,s,a,l,c,h,u,d,f,p;return"function"!=typeof e.value?(P.warn("k-ng-model specified on a widget that does not have the value() method: "+e.options.name),i):(r=t(e.element).parents("form"),s=kendo.getter(r.attr("name"),!0)(n),a=S(o),l=a.assign,c=!1,h=kendo.ui.MultiSelect&&e instanceof kendo.ui.MultiSelect,u=function(t){return t&&h?t.length:0},d=u(a(n)),e.$angular_setLogicValue(a(n)),f=function(t,n){t===i&&(t=null),c||t==n&&u(t)==d||(d=u(t),e.$angular_setLogicValue(t))},h?n.$watchCollection(o,f):n.$watch(o,f),p=function(){c=!0,s&&s.$pristine&&s.$setDirty(),w(n,function(){l(n,e.$angular_getLogicValue()),d=u(a(n))}),c=!1},e.first("change",p),e.first("spin",p),i)}function f(t,e){var i=t.$on("$destroy",function(){i(),e&&(kendo.destroy(e.element),e=null)});return i}function p(e,i){function n(){s.disconnect()}function o(){s.observe(t(i)[0],{attributes:!0})}var r,s;window.MutationObserver&&e.wrapper&&(r=[].slice.call(t(i)[0].classList),s=new MutationObserver(function(i){n(),e&&(i.forEach(function(i){var n,o=t(e.wrapper)[0];switch(i.attributeName){case"class":n=[].slice.call(i.target.classList),n.forEach(function(t){r.indexOf(t)<0&&(o.classList.add(t),kendo.ui.ComboBox&&e instanceof kendo.ui.ComboBox&&e.input[0].classList.add(t))}),r.forEach(function(t){n.indexOf(t)<0&&(o.classList.remove(t),kendo.ui.ComboBox&&e instanceof kendo.ui.ComboBox&&e.input[0].classList.remove(t))}),r=n;break;case"disabled":"function"!=typeof e.enable||e.element.attr("readonly")||e.enable(!t(i.target).attr("disabled"));break;case"readonly":"function"!=typeof e.readonly||e.element.attr("disabled")||e.readonly(!!t(i.target).attr("readonly"))}}),o())}),o(),e.first("destroy",n))}function g(e,i,n,o,r,s,a){var l=i.$watch(r,function(r,c){var h,u,d,f,p;e._muteRebind||r===c||(l(),a._cleanUp&&a._cleanUp(),h=V[e.options.name],h&&h.forEach(function(e){var n=i.$eval(a["k"+e]);n&&o.append(t(n).attr(kendo.toHyphens("k"+e),""))}),u=t(e.wrapper)[0],d=t(e.element)[0],f="Upload"===e.options.name,f&&(n=t(d)),p=n.injector().get("$compile"),e._destroy(),s&&s(),e=null,d&&(u&&u.parentNode.replaceChild(d,u),t(n).replaceWith(o)),p(o)(i))},!0);w(i)}function m(t,e){return function(i,n){return t.call(e,i,n)}}function v(t,e){this[t]=kendo.stringify(e)}function _(t,i){function n(t,e){k.directive(t,["directiveFactory",function(i){return i.create(e,t)}])}var o,r,s,a,l=i?"Mobile":"";l+=t.fn.options.name,o=l,r="kendo"+l.charAt(0)+l.substr(1).toLowerCase(),l="kendo"+l,s=l.replace(/([A-Z])/g,"-$1"),L.indexOf(l.replace("kendo",""))==-1&&(a=l===r?[l]:[l,r],e.forEach(a,function(t){k.directive(t,function(){return{restrict:"E",replace:!0,template:function(t,e){var i=z[o]||"div",n=e.kScopeField||e.scopeField;return"<"+i+" "+s+(n?'="'+n+'"':"")+">"+t.html()+"</"+i+">"}}})})),R.indexOf(l.replace("kendo",""))>-1||(n(l,l),r!=l&&n(r,l))}function y(e){return e=t(e),kendo.widgetInstance(e,kendo.ui)||kendo.widgetInstance(e,kendo.mobile.ui)||kendo.widgetInstance(e,kendo.dataviz.ui)}function w(t,e){var i=t.$root||t,n=/^\$(digest|apply)$/.test(i.$$phase);e?n?e():i.$apply(e):n||i.$digest()}function x(e,i){e.$destroy(),i&&t(i).removeData("$scope").removeData("$$kendoScope").removeData("$isolateScope").removeData("$isolateScopeNoTemplate").removeClass("ng-scope")}function b(i,n,o){var r,s,a;if(t.isArray(i))return e.forEach(i,function(t){b(t,n,o)});if("string"==typeof i){for(r=i.split("."),s=kendo;s&&r.length>0;)s=s[r.shift()];if(!s)return O.push([i,n,o]),!1;i=s.prototype}return a=i[n],i[n]=function(){var t=this,e=arguments;return o.apply({self:t,next:function(){return a.apply(t,arguments.length>0?arguments:e)}},e)},!0}var k,C,S,T,A,P,D,M,E,I,B,z,L,R,O,V;e&&e.injector&&(k=e.module("kendo.directives",[]),C=e.injector(["ng"]),S=C.get("$parse"),T=C.get("$timeout"),P=C.get("$log"),M=function(){var t={TreeList:"TreeListDataSource",TreeView:"HierarchicalDataSource",Scheduler:"SchedulerDataSource",PivotGrid:"PivotDataSource",PivotConfigurator:"PivotDataSource",PanelBar:"$PLAIN",Menu:"$PLAIN",ContextMenu:"$PLAIN"},e=function(t,e){return"$PLAIN"==e?t:kendo.data[e].create(t)};return function(i,n,o,r){var s=t[o]||"DataSource",a=i.$eval(r),l=e(a,s);return i.$watch(r,function(t){var i,o=y(n);o&&"function"==typeof o.setDataSource&&t!==a&&(i=e(t,s),o.setDataSource(i),a=t)}),l}}(),E={kDataSource:!0,kOptions:!0,kRebind:!0,kNgModel:!0,kNgDelay:!0},I={name:!0,title:!0,style:!0},B=/^(input|select|textarea)$/i,k.factory("directiveFactory",["$compile",function(e){var i,n,r=!1;return A=e,n=function(e,n){return{restrict:"AC",require:["?ngModel","^?form"],scope:!1,controller:["$scope","$attrs","$element",function(t,e){this.template=m(v,e),e._cleanUp=m(function(){this.template=null,e._cleanUp=null},this)}],link:function(s,a,l,c){var h,u=t(a),d=e.replace(/([A-Z])/g,"-$1");u.attr(d,u.attr("data-"+d)),u[0].removeAttribute("data-"+d),h=o(s,a,l,e,n,c),h&&(i&&clearTimeout(i),i=setTimeout(function(){s.$emit("kendoRendered"),r||(r=!0,t("form").each(function(){var e=t(this).controller("form");e&&e.$setPristine()}))}))}}},{create:n}}]),z={Editor:"textarea",NumericTextBox:"input",DatePicker:"input",DateTimePicker:"input",TimePicker:"input",AutoComplete:"input",ColorPicker:"input",MaskedTextBox:"input",MultiSelect:"input",Upload:"input",Validator:"form",Button:"button",MobileButton:"a",MobileBackButton:"a",MobileDetailButton:"a",ListView:"ul",MobileListView:"ul",TreeView:"ul",Menu:"ul",ContextMenu:"ul",ActionSheet:"ul"},L=["MobileView","MobileDrawer","MobileLayout","MobileSplitView","MobilePane","MobileModalView"],R=["MobileApplication","MobileView","MobileModalView","MobileLayout","MobileActionSheet","MobileDrawer","MobileSplitView","MobilePane","MobileScrollView","MobilePopOver"],e.forEach(["MobileNavBar","MobileButton","MobileBackButton","MobileDetailButton","MobileTabStrip","MobileScrollView","MobileScroller"],function(t){R.push(t),t="kendo"+t,k.directive(t,function(){return{restrict:"A",link:function(e,i,n){o(e,i,n,t,t)}}})}),O=[],kendo.onWidgetRegistered(function(e){O=t.grep(O,function(t){return!b.apply(null,t)}),_(e.widget,"Mobile"==e.prefix)}),b(["ui.Widget","mobile.ui.Widget"],"angular",function(o,r){var s,a=this.self;return"init"==o?(!r&&D&&(r=D),D=null,r&&r.$angular&&(a.$angular_scope=r.$angular[0],a.$angular_init(a.element,r)),i):(s=a.$angular_scope,s&&n(function(){var n,l,c=r(),h=c.elements,u=c.data;if(h.length>0)switch(o){case"cleanup":e.forEach(h,function(e){var i=t(e).data("$$kendoScope");i&&i!==s&&i.$$kendoScope&&x(i,e)});break;case"compile":n=a.element.injector(),l=n?n.get("$compile"):A,e.forEach(h,function(e,n){var o,r;c.scopeFrom?o=c.scopeFrom:(r=u&&u[n],r!==i?(o=t.extend(s.$new(),r),o.$$kendoScope=!0):o=s),t(e).data("$$kendoScope",o),l(e)(o)}),w(s)}}),i)}),b("ui.Widget","$angular_getLogicValue",function(){return this.self.value()}),b("ui.Widget","$angular_setLogicValue",function(t){this.self.value(t)}),b("ui.Select","$angular_getLogicValue",function(){var t=this.self.dataItem(),e=this.self.options.dataValueField;return t?this.self.options.valuePrimitive?e?t[e]:t:t.toJSON():null}),b("ui.Select","$angular_setLogicValue",function(t){var e=this.self,n=e.options,o=n.dataValueField,r=n.text||"";t===i&&(t=""),o&&!n.valuePrimitive&&t&&(r=t[n.dataTextField]||"",t=t[o||n.dataTextField]),e.options.autoBind!==!1||e.listView.bound()?e.value(t):!r&&t&&n.valuePrimitive?e.value(t):e._preselect(t,r)}),b("ui.MultiSelect","$angular_getLogicValue",function(){var e=this.self.dataItems().slice(0),i=this.self.options.dataValueField;return i&&this.self.options.valuePrimitive&&(e=t.map(e,function(t){return t[i]})),e}),b("ui.MultiSelect","$angular_setLogicValue",function(e){var i,n,o,r;null==e&&(e=[]),i=this.self,n=i.options,o=n.dataValueField,r=e,o&&!n.valuePrimitive&&(e=t.map(e,function(t){return t[o]})),n.autoBind!==!1||n.valuePrimitive||i.listView.bound()?i.value(e):i._preselect(r,e)}),b("ui.AutoComplete","$angular_getLogicValue",function(){var t,e,i,n,o,r=this.self.options,s=this.self.value().split(r.separator),a=r.valuePrimitive,l=this.self.listView.selectedDataItems(),c=[];for(t=0,e=l.length;t<e;t++)for(i=l[t],n=r.dataTextField?i[r.dataTextField]:i,o=0;o<s.length;o++)if(n===s[o]){c.push(a?n:i.toJSON());break}return c}),b("ui.AutoComplete","$angular_setLogicValue",function(e){null==e&&(e=[]);var n=this.self,o=n.options.dataTextField;o&&!n.options.valuePrimitive&&(e=e.length!==i?t.map(e,function(t){return t[o]}):e[o]),n.value(e)}),b("ui.Widget","$angular_init",function(e,i){var n,o,r,s,a=this.self;if(i&&!t.isArray(i))for(n=a.$angular_scope,o=a.events.length;--o>=0;)r=a.events[o],s=i[r],s&&"string"==typeof s&&(i[r]=a.$angular_makeEventHandler(r,n,s))}),b("ui.Widget","$angular_makeEventHandler",function(t,e,i){return i=S(i),function(t){w(e,function(){i(e,{kendoEvent:t})})}}),b(["ui.Grid","ui.ListView","ui.TreeView"],"$angular_makeEventHandler",function(t,i,n){return"change"!=t?this.next():(n=S(n),function(t){var o,r,s,a,l,c,h,u,d,f=t.sender,p=f.options,g={kendoEvent:t};for(e.isString(p.selectable)&&(o=p.selectable.indexOf("cell")!==-1,r=p.selectable.indexOf("multiple")!==-1),s=g.selected=this.select(),a=g.data=[],l=g.columns=[],h=0;h<s.length;h++)u=o?s[h].parentNode:s[h],d=f.dataItem(u),o?(e.element.inArray(d,a)<0&&a.push(d),c=e.element(s[h]).index(),e.element.inArray(c,l)<0&&l.push(c)):a.push(d);r||(g.dataItem=g.data=a[0],g.angularDataItem=kendo.proxyModelSetters(g.dataItem),g.selected=s[0]),w(i,function(){n(i,g)})})}),b("ui.Grid","$angular_init",function(n,o){if(this.next(),o.columns){var r=t.extend({},kendo.Template,o.templateSettings);e.forEach(o.columns,function(t){!t.field||t.template||t.format||t.values||t.encoded!==i&&!t.encoded||(t.template="<span ng-bind='"+kendo.expr(t.field,"dataItem")+"'>#: "+kendo.expr(t.field,r.paramName)+"#</span>")})}}),b("mobile.ui.ButtonGroup","value",function(t){var e=this.self;return null!=t&&(e.select(e.element.children("li.km-button").eq(t)),e.trigger("change"),e.trigger("select",{index:e.selectedIndex})),e.selectedIndex}),b("mobile.ui.ButtonGroup","_select",function(){this.next(),this.self.trigger("change")}),k.directive("kendoMobileApplication",function(){return{terminal:!0,link:function(t,e,i){o(t,e,i,"kendoMobileApplication","kendoMobileApplication")}}}).directive("kendoMobileView",function(){return{scope:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,i._instance=o(t,e,i,"kendoMobileView","kendoMobileView")},post:function(t,e,i){i._instance._layout(),i._instance._scroller()}}}}).directive("kendoMobileDrawer",function(){return{scope:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,i._instance=o(t,e,i,"kendoMobileDrawer","kendoMobileDrawer")},post:function(t,e,i){i._instance._layout(),i._instance._scroller()}}}}).directive("kendoMobileModalView",function(){return{scope:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,i._instance=o(t,e,i,"kendoMobileModalView","kendoMobileModalView")},post:function(t,e,i){i._instance._layout(),i._instance._scroller()}}}}).directive("kendoMobileSplitView",function(){return{terminal:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,i._instance=o(t,e,i,"kendoMobileSplitView","kendoMobileSplitView")},post:function(t,e,i){i._instance._layout()}}}}).directive("kendoMobilePane",function(){return{terminal:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,o(t,e,i,"kendoMobilePane","kendoMobilePane")}}}}).directive("kendoMobileLayout",function(){return{link:{pre:function(t,e,i){o(t,e,i,"kendoMobileLayout","kendoMobileLayout")}}}}).directive("kendoMobileActionSheet",function(){return{restrict:"A",link:function(e,i,n){i.find("a[k-action]").each(function(){t(this).attr("data-"+kendo.ns+"action",t(this).attr("k-action"))}),o(e,i,n,"kendoMobileActionSheet","kendoMobileActionSheet")}}}).directive("kendoMobilePopOver",function(){return{terminal:!0,link:{pre:function(t,e,i){i.defaultOptions=t.viewOptions,o(t,e,i,"kendoMobilePopOver","kendoMobilePopOver")}}}}).directive("kendoViewTitle",function(){return{restrict:"E",replace:!0,template:function(t){return"<span data-"+kendo.ns+"role='view-title'>"+t.html()+"</span>"}}}).directive("kendoMobileHeader",function(){return{restrict:"E",link:function(t,e){e.addClass("km-header").attr("data-role","header")}}}).directive("kendoMobileFooter",function(){return{restrict:"E",link:function(t,e){e.addClass("km-footer").attr("data-role","footer")}}}).directive("kendoMobileScrollViewPage",function(){return{restrict:"E",replace:!0,template:function(t){return"<div data-"+kendo.ns+"role='page'>"+t.html()+"</div>"}}}),e.forEach(["align","icon","rel","transition","actionsheetContext"],function(t){var e="k"+t.slice(0,1).toUpperCase()+t.slice(1);k.directive(e,function(){return{restrict:"A",priority:2,link:function(i,n,o){n.attr(kendo.attr(kendo.toHyphens(t)),i.$eval(o[e]))}}})}),V={TreeMap:["Template"],MobileListView:["HeaderTemplate","Template"],MobileScrollView:["EmptyTemplate","Template"],Grid:["AltRowTemplate","DetailTemplate","RowTemplate"],ListView:["EditTemplate","Template","AltTemplate"],Pager:["SelectTemplate","LinkTemplate"],PivotGrid:["ColumnHeaderTemplate","DataCellTemplate","RowHeaderTemplate"],Scheduler:["AllDayEventTemplate","DateHeaderTemplate","EventTemplate","MajorTimeHeaderTemplate","MinorTimeHeaderTemplate"],TreeView:["Template"],Validator:["ErrorTemplate"]},function(){var t={};e.forEach(V,function(i,n){e.forEach(i,function(e){t[e]||(t[e]=[]),t[e].push("?^^kendo"+n)})}),e.forEach(t,function(t,e){var i="k"+e,n=kendo.toHyphens(i);k.directive(i,function(){return{restrict:"A",require:t,terminal:!0,compile:function(e,o){if(""===o[i]){e.removeAttr(n);var r=e[0].outerHTML;return function(e,o,s,a){for(var l;!l&&a.length;)l=a.shift();l?(l.template(i,r),o.remove()):P.warn(n+" without a matching parent widget found. It can be one of the following: "+t.join(", "))}}}}})})}())}(window.kendo.jQuery,window.angular),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.webcomponents.min",["kendo.core.min"],t)}(function(){return function(t,e,i){function n(t,e){var n=t.getAttribute(e);return null===n?n=i:"null"===n?n=null:"true"===n?n=!0:"false"===n?n=!1:p.test(n)?n=parseFloat(n):d.test(n)&&!f.test(n)&&(n=Function("return ("+n+")")()),n}function o(t,e){var i={};return Object.keys(e).concat("dataSource").forEach(function(e){t.hasAttribute(kendo.toHyphens(e))&&(i[e]=n(t,kendo.toHyphens(e)))}),i}function r(t){var e={};return Object.keys(t).forEach(function(i){"_"!=i[0]&&(e[i]=t[i])}),e}function s(t,e){var i=document.createEvent("CustomEvent");i.initCustomEvent(t,!1,!0,r(e)),this.dispatchEvent(i),i.defaultPrevented&&e.preventDefault()}function a(t,e){var i,n=Object.keys(e);for(i=0;i<=n.length;i++)if("function"==typeof e[n[i]])t[n[i]]||(t[n[i]]=e[n[i]].bind(t.widget));else{if("options"===n[i])continue;t[n[i]]=t[n[i]]||e[n[i]]}}function l(e,i){var n=i.prototype.options,r=Object.create(HTMLElement.prototype);Object.defineProperty(r,"options",{get:function(){return this.widget.options},set:function(i){var n,o,r,s=this.widget;i=t.extend(!0,{},s.options,i),n=t(s.wrapper)[0],o=t(s.element)[0],s._destroy(),r=document.createElement(c[e]||"div"),n&&o&&(n.parentNode.replaceChild(o,n),t(o).replaceWith(r)),s.value&&(i.value=s.value()),s.init(r,i),this.bindEvents()}}),r.bindEvents=function(){i.prototype.events.indexOf("init")<0&&i.prototype.events.push("init"),i.prototype.events.forEach(function(t){this.widget.bind(t,s.bind(this,t)),this.hasAttribute(h+t)&&this.bind(t,function(e){window[this.getAttribute(h+t)].call(this,e)}.bind(this))}.bind(this))},r.attachedCallback=function(){var r,s=this,l=document.createElement(c[e]||"div");t(l).append(s.childNodes),t(l).attr("class",t(s).attr("class")),t(l).attr("style",t(s).attr("style")),s.appendChild(l),s.widget=new i(l,o(s,n)),r=s.widget;do a(s,r);while(r=Object.getPrototypeOf(r));this.bindEvents(),s.widget.trigger("init")},r.detachedCallback=function(){kendo.destroy(this.element)},kendo.webComponents.push("kendo-"+e),document.registerElement("kendo-"+e,{prototype:r})}var c,h,u,d,f,p;kendo.support.customElements&&!kendo.webComponents.length&&(e&&(1==e.version.major||e.injector)||(c={editor:"textarea",numerictextbox:"input",datepicker:"input",datetimepicker:"input",timepicker:"input",autocomplete:"input",colorpicker:"input",maskedtextbox:"input",dropdownlist:"select",multiselect:"select",upload:"input",validator:"form",button:"button",mobilebutton:"a",mobilebackbutton:"a",mobiledetailbutton:"a",listview:"ul",mobilelistview:"ul",treeview:"ul",menu:"ul",contextmenu:"ul",actionsheet:"ul"},h="on-",u=[],kendo.onWidgetRegistered(function(t){var e=t.prefix+t.widget.prototype.options.name.toLowerCase();u.indexOf(e)===-1&&(u.push(e),l(e,t.widget))}),d=/^\s*(?:\{(?:.|\r\n|\n)*\}|\[(?:.|\r\n|\n)*\])\s*$/,f=/^\{(\d+)(:[^\}]+)?\}|^\[[A-Za-z_]*\]$/,p=/^(\+|-?)\d+(\.?)\d*$/))}(window.kendo.jQuery,window.angular),window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.angular2.min",["kendo.core.min","kendo.webcomponents.min"],t)}(function(){!function(t,e){var i,n;e&&e.register&&(i=this&&this.__decorate||function(t,e,i,n){if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)return Reflect.decorate(t,e,i,n);switch(arguments.length){case 2:return t.reduceRight(function(t,e){return e&&e(t)||t},e);case 3:return t.reduceRight(function(t,n){return void(n&&n(e,i))},void 0);case 4:return t.reduceRight(function(t,n){return n&&n(e,i,t)||t},n)}},n=this&&this.__metadata||function(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)},e.register("kendo/angular2",["angular2/angular2"],function(e){var o,r;return{setters:[function(t){o=t}],execute:function(){r=function(){function e(t,e){var i=this;this.elementRef=e,this.onChange=function(t){},this.onTouched=function(){},this.element=e.nativeElement,this.element.addEventListener("change",function(){i.onChange(i.element.value())}),this.element.addEventListener("spin",function(){i.onChange(i.element.value())}),t.valueAccessor=this,this.cd=t,t.valueAccessor=this}return e.prototype.writeValue=function(t){this.element.value(t)},e.prototype.registerOnChange=function(t){this.onChange=t},e.prototype.registerOnTouched=function(t){this.onTouched=t},e=i([o.Directive({selector:t.webComponents.join(",")}),n("design:paramtypes",[o.NgControl,o.ElementRef])],e)}(),e("KendoValueAccessor",r)}}}))}(window.kendo,window.System)},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()}),function(t,define){define("kendo.dataviz.min",["kendo.core.min","kendo.fx.min","kendo.router.min","kendo.view.min","kendo.data.odata.min","kendo.data.xml.min","kendo.data.min","kendo.data.signalr.min","kendo.binder.min","kendo.userevents.min","kendo.draganddrop.min","kendo.mobile.scroller.min","kendo.popup.min","kendo.tooltip.min","kendo.drawing.min","kendo.dataviz.core.min","kendo.dataviz.themes.min","kendo.dataviz.chart.min","kendo.dataviz.chart.polar.min","kendo.dataviz.chart.funnel.min","kendo.dataviz.gauge.min","kendo.dataviz.barcode.min","kendo.dataviz.qrcode.min","kendo.dataviz.stock.min","kendo.dataviz.sparkline.min","kendo.dataviz.map.min","kendo.dataviz.diagram.min","kendo.dataviz.treemap.min","kendo.angular.min","kendo.webcomponents.min","kendo.angular2.min"],t)}(function(){"bundle all";return window.kendo},"function"==typeof define&&define.amd?define:function(t,e,i){(i||e)()});
//# sourceMappingURL=kendo.dataviz.min.js.map
