/** * Kendo UI v2016.3.914 (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(e,define){define("util/main.min",["kendo.core.min"],e)}(function(){return function(){function e(e){return typeof e!==L}function t(e,t){var n=i(t);return N.round(e*n)/n}function i(e){return e?N.pow(10,e):1}function n(e,t,i){return N.max(N.min(e,i),t)}function o(e){return e*F}function r(e){return e/F}function a(e){return"number"==typeof e&&!isNaN(e)}function s(t,i){return e(t)?t:i}function l(e){return e*e}function c(e){var t,i=[];for(t in e)i.push(t+e[t]);return i.sort().join("")}function u(e){var t,i=2166136261;for(t=0;e.length>t;++t)i+=(i<<1)+(i<<4)+(i<<7)+(i<<8)+(i<<24),i^=e.charCodeAt(t);return i>>>0}function d(e){return u(c(e))}function h(e){var t,i=e.length,n=O,o=R;for(t=0;i>t;t++)o=N.max(o,e[t]),n=N.min(n,e[t]);return{min:n,max:o}}function f(e){return h(e).min}function p(e){return h(e).max}function m(e){return g(e).min}function v(e){return g(e).max}function g(e){var t,i,n,o=O,r=R;for(t=0,i=e.length;i>t;t++)n=e[t],null!==n&&isFinite(n)&&(o=N.min(o,n),r=N.max(r,n));return{min:o===O?void 0:o,max:r===R?void 0:r}}function _(e){return e?e[e.length-1]:void 0}function x(e,t){return e.push.apply(e,t),e}function b(e){return j.template(e,{useWithBlock:!1,paramName:"d"})}function y(t,i){return e(i)&&null!==i?" "+t+"='"+i+"' ":""}function w(e){var t,i="";for(t=0;e.length>t;t++)i+=y(e[t][0],e[t][1]);return i}function A(t){var i,n,o="";for(i=0;t.length>i;i++)n=t[i][1],e(n)&&(o+=t[i][0]+":"+n+";");return""!==o?o:void 0}function S(e){return"string"!=typeof e&&(e+="px"),e}function C(e){var t,i,n=[];if(e)for(t=j.toHyphens(e).split("-"),i=0;t.length>i;i++)n.push("k-pos-"+t[i]);return n.join(" ")}function k(t){return""===t||null===t||"none"===t||"transparent"===t||!e(t)}function D(e){for(var t={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="";e>0;)i[0]>e?i.shift():(n+=t[i[0]],e-=i[0]);return n}function T(e){var t,i,n,o,r;for(e=e.toLowerCase(),t={i:1,v:5,x:10,l:50,c:100,d:500,m:1e3},i=0,n=0,o=0;e.length>o;++o){if(r=t[e.charAt(o)],!r)return null;i+=r,r>n&&(i-=2*n),n=r}return i}function E(e){var t=Object.create(null);return function(){var i,n="";for(i=arguments.length;--i>=0;)n+=":"+arguments[i];return n in t?t[n]:e.apply(this,arguments)}}function M(e){for(var t,i,n=[],o=0,r=e.length;r>o;)t=e.charCodeAt(o++),t>=55296&&56319>=t&&r>o?(i=e.charCodeAt(o++),56320==(64512&i)?n.push(((1023&t)<<10)+(1023&i)+65536):(n.push(t),o--)):n.push(t);return n}function z(e){return e.map(function(e){var t="";return e>65535&&(e-=65536,t+=String.fromCharCode(e>>>10&1023|55296),e=56320|1023&e),t+=String.fromCharCode(e)}).join("")}function U(e,t){function i(e,i){for(var n=[],o=0,r=0,a=0;e.length>o&&i.length>r;)t(e[o],i[r])<=0?n[a++]=e[o++]:n[a++]=i[r++];return e.length>o&&n.push.apply(n,e.slice(o)),i.length>r&&n.push.apply(n,i.slice(r)),n}return 2>e.length?e.slice():function n(e){var t,o,r;return 1>=e.length?e:(t=Math.floor(e.length/2),o=e.slice(0,t),r=e.slice(t),o=n(o),r=n(r),i(o,r))}(e)}var N=Math,j=window.kendo,B=j.deepExtend,F=N.PI/180,O=Number.MAX_VALUE,R=-Number.MAX_VALUE,L="undefined",H=Date.now;H||(H=function(){return(new Date).getTime()}),B(j,{util:{MAX_NUM:O,MIN_NUM:R,append:x,arrayLimits:h,arrayMin:f,arrayMax:p,defined:e,deg:r,hashKey:u,hashObject:d,isNumber:a,isTransparent:k,last:_,limitValue:n,now:H,objectKey:c,round:t,rad:o,renderAttr:y,renderAllAttr:w,renderPos:C,renderSize:S,renderStyle:A,renderTemplate:b,sparseArrayLimits:g,sparseArrayMin:m,sparseArrayMax:v,sqr:l,valueOrDefault:s,romanToArabic:T,arabicToRoman:D,memoize:E,ucs2encode:z,ucs2decode:M,mergeSort:U}}),j.drawing.util=j.util,j.dataviz.util=j.util}(),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,i){(i||t)()}),function(e,define){define("util/text-metrics.min",["kendo.core.min","util/main.min"],e)}(function(){!function(e){function t(){return{width:0,height:0,baseline:0}}function i(e,t,i){return d.current.measure(e,t,i)}function n(e,t){var i=[];if(e.length>0&&document.fonts){try{i=e.map(function(e){return document.fonts.load(e)})}catch(n){r.logToConsole(n)}Promise.all(i).then(t,t)}else t()}var o=document,r=window.kendo,a=r.Class,s=r.util,l=s.defined,c=a.extend({init:function(e){this._size=e,this._length=0,this._map={}},put:function(e,t){var i=this,n=i._map,o={key:e,value:t};n[e]=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(e){var t=this,i=t._map[e];return i?(i===t._head&&i!==t._tail&&(t._head=i.newer,t._head.older=null),i!==t._tail&&(i.older&&(i.older.newer=i.newer,i.newer.older=i.older),i.older=t._tail,i.newer=null,t._tail.newer=i,t._tail=i),i.value):void 0}}),u=e("
")[0],d=a.extend({init:function(e){this._cache=new c(1e3),this._initOptions(e)},options:{baselineMarkerSize:1},measure:function(i,n,r){var a,c,d,h,f,p,m,v;if(!i)return t();if(a=s.objectKey(n),c=s.hashKey(i+a),d=this._cache.get(c),d)return d;h=t(),f=r?r:u,p=this._baselineMarker().cloneNode(!1);for(m in n)v=n[m],l(v)&&(f.style[m]=v);return e(f).text(i),f.appendChild(p),o.body.appendChild(f),(i+"").length&&(h.width=f.offsetWidth-this.options.baselineMarkerSize,h.height=f.offsetHeight,h.baseline=p.offsetTop+this.options.baselineMarkerSize),h.width>0&&h.height>0&&this._cache.put(c,h),f.parentNode.removeChild(f),h},_baselineMarker:function(){return e("")[0]}});d.current=new d,r.util.TextMetrics=d,r.util.LRUCache=c,r.util.loadFonts=n,r.util.measureText=i}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,i){(i||t)()}),function(e,define){define("util/base64.min",["util/main.min"],e)}(function(){return function(){function e(e){var i,n,o,a,s,l,c,u="",d=0;for(e=t(e);e.length>d;)i=e.charCodeAt(d++),n=e.charCodeAt(d++),o=e.charCodeAt(d++),a=i>>2,s=(3&i)<<4|n>>4,l=(15&n)<<2|o>>6,c=63&o,isNaN(n)?l=c=64:isNaN(o)&&(c=64),u=u+r.charAt(a)+r.charAt(s)+r.charAt(l)+r.charAt(c);return u}function t(e){var t,i,n="";for(t=0;e.length>t;t++)i=e.charCodeAt(t),128>i?n+=o(i):2048>i?(n+=o(192|i>>>6),n+=o(128|63&i)):65536>i&&(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:e,encodeUTF8:t})}(),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,i){(i||t)()}),function(e,define){define("mixins/observers.min",["kendo.core.min"],e)}(function(){return function(e){var t=Math,i=window.kendo,n=i.deepExtend,o=e.inArray,r={observers:function(){return this._observers=this._observers||[]},addObserver:function(e){return this._observers?this._observers.push(e):this._observers=[e],this},removeObserver:function(e){var t=this.observers(),i=o(e,t);return-1!=i&&t.splice(i,1),this},trigger:function(e,t){var i,n,o=this._observers;if(o&&!this._suspended)for(n=0;o.length>n;n++)i=o[n],i[e]&&i[e](t);return this},optionsChange:function(e){e=e||{},e.element=this,this.trigger("optionsChange",e)},geometryChange:function(){this.trigger("geometryChange",{element:this})},suspend:function(){return this._suspended=(this._suspended||0)+1,this},resume:function(){return this._suspended=t.max((this._suspended||0)-1,0),this},_observerField:function(e,t){this[e]&&this[e].removeObserver(this),this[e]=t,t.addObserver(this)}};n(i,{mixins:{ObserversMixin:r}})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,i){(i||t)()}),function(e,define){define("kendo.dataviz.stock.min",["kendo.dataviz.chart.min"],e)}(function(){return function(e,t){function i(){}function n(e){return i.prototype=e,new i}var o,r=window.kendo,a=r.Class,s=r.Observable,l=r.deepExtend,c=Math,u=e.proxy,d=r.util,h=d.last,f=d.renderTemplate,p=r.dataviz,m=d.defined,v=p.filterSeriesByType,g=r.template,_=p.ui.Chart,x=p.Selection,b=p.addDuration,y=d.limitValue,w=p.lteDateIndex,A=p.toDate,S=p.toTime,C=28,k="change",D="k-",T="drag",E="dragEnd",M="_navigator",z=M,U=p.EQUALLY_SPACED_SERIES,N=3,j="zoom",B="zoomEnd",F=_.extend({init:function(t,i){e(t).addClass(D+"chart"),_.fn.init.call(this,t,i)},_applyDefaults:function(e,t){var i=this,n=i.element.width()||p.DEFAULT_WIDTH,o={seriesDefaults:{categoryField:e.dateField},axisDefaults:{categoryAxis:{name:"default",majorGridLines:{visible:!1},labels:{step:2},majorTicks:{visible:!1},maxDateGroups:c.floor(n/C)}}};t&&(t=l({},t,o)),O.setup(e,t),_.fn._applyDefaults.call(i,e,t)},setOptions:function(e){this._destroyNavigator(),_.fn.setOptions.call(this,e)},_initDataSource:function(e){var t,i,n=e||{},o=n.dataSource,r=o&&o.serverFiltering,a=[].concat(n.categoryAxis)[0],s=n.navigator||{},c=s.select,u=c&&c.from&&c.to;r&&u&&(t=[].concat(o.filter||[]),i=new p.DateCategoryAxis(l({baseUnit:"fit"},a,{categories:[c.from,c.to]})),o.filter=O.buildFilter(i.range().min,c.to).concat(t)),_.fn._initDataSource.call(this,e)},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 e=this.options.transitions;this.options.transitions=!1,this._fullRedraw(),this.options.transitions=e},_redraw:function(){var e=this,t=e._navigator;!this._dirty()&&t&&t.dataSource?t.redrawSlaves():e._fullRedraw()},_dirty:function(){var t=this.options,i=[].concat(t.series,t.navigator.series),n=e.grep(i,function(e){return e&&e.visible}).length,o=this._seriesCount!==n;return this._seriesCount=n,o},_fullRedraw:function(){var e=this,t=e._navigator;t||(t=e._navigator=e.navigator=new O(e)),t._setRange(),_.fn._redraw.call(e),t._initSelection()},_onDataChanged:function(){var e=this;_.fn._onDataChanged.call(e),e._dataBound=!0},_bindCategoryAxis:function(e,t,i){var n,o=this,r=o.options.categoryAxis,a=r.length;if(_.fn._bindCategoryAxis.apply(this,arguments),e.name===z)for(;a>i;)n=r[i++],n.pane==M&&(n.categories=e.categories)},_trackSharedTooltip:function(e){var t=this,i=t._plotArea,n=i.paneByPoint(e);n&&n.options.name===M?t._unsetActivePoint():_.fn._trackSharedTooltip.call(t,e)},_destroyNavigator:function(){this._navigator.destroy(),this._navigator=null},destroy:function(){this._destroyNavigator(),_.fn.destroy.call(this)}}),O=s.extend({init:function(e){var t=this;t.chart=e,t.options=l({},t.options,e.options.navigator),t._initDataSource(),m(t.options.hint.visible)||(t.options.hint.visible=t.options.visible),e.bind(T,u(t._drag,t)),e.bind(E,u(t._dragEnd,t)),e.bind(j,u(t._zoom,t)),e.bind(B,u(t._zoomEnd,t))},options:{},_initDataSource:function(){var e=this,t=e.options,i=t.autoBind,n=t.dataSource;m(i)||(i=e.chart.options.autoBind),e._dataChangedHandler=u(e._onDataChanged,e),n&&(e.dataSource=r.data.DataSource.create(n).bind(k,e._dataChangedHandler),i&&e.dataSource.fetch())},_onDataChanged:function(){var e,t,i,n,o,r=this,a=r.chart,s=a.options.series,l=s.length,c=a.options.categoryAxis,u=c.length,d=r.dataSource.view();for(e=0;l>e;e++)i=s[e],i.axis==z&&a._isBindable(i)&&(i.data=d);for(t=0;u>t;t++)n=c[t],n.pane==M&&(n.name==z?(a._bindCategoryAxis(n,d,t),o=n.categories):n.categories=o);a._model&&(r.redraw(),r._setRange(),(!a.options.dataSource||a.options.dataSource&&a._dataBound)&&r.redrawSlaves())},destroy:function(){var e=this,t=e.dataSource;t&&t.unbind(k,e._dataChangeHandler),e.selection&&e.selection.destroy()},redraw:function(){this._redrawSelf(),this._initSelection()},_initSelection:function(){var t=this,i=t.chart,r=t.options,a=t.mainAxis(),s=n(a),l=a.range(),c=l.min,u=l.max,h=a.options.categories,f=t.options.select,p=t.selection,m=A(f.from),v=A(f.to);0!==h.length&&(p&&(p.destroy(),p.wrapper.remove()),s.box=a.box,p=t.selection=new x(i,s,{min:c,max:u,from:m||c,to:v||u,selectStart:e.proxy(t._selectStart,t),select:e.proxy(t._select,t),selectEnd:e.proxy(t._selectEnd,t),mousewheel:d.valueOrDefault(f.mousewheel,{zoom:"left"}),visible:r.visible}),r.hint.visible&&(t.hint=new o(i.element,{min:c,max:u,template:r.hint.template,format:r.hint.format})))},_setRange:function(){var e,t=this.chart._createPlotArea(!0),i=t.namedCategoryAxes[z],n=i.datesRange(),o=n.min,r=n.max,a=this.options.select||{},s=A(a.from)||o;o>s&&(s=o),e=A(a.to)||r,e>r&&(e=r),this.options.select=l({},a,{from:s,to:e}),this.filterAxes()},_redrawSelf:function(e){var t=this.chart._plotArea;t&&t.redraw(h(t.panes),e)},redrawSlaves:function(){var e=this,t=e.chart,i=t._plotArea,n=i.panes.slice(0,-1);i.srcSeries=t.options.series,i.redraw(n)},_drag:function(e){var t,i,n,o=this,r=o.chart,a=r._eventCoordinates(e.originalEvent),s=o.mainAxis(),l=s.datesRange(),c=s.pane.box.containsPoint(a),u=r._plotArea.categoryAxis,d=e.axisRanges[u.options.name],h=o.options.select,f=o.selection;d&&!c&&f&&(t=h.from&&h.to?S(h.to)-S(h.from):S(f.options.to)-S(f.options.from),i=A(y(S(d.min),l.min,S(l.max)-t)),n=A(y(S(i)+t,S(l.min)+t,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 e=this;e.filterAxes(),e.filterDataSource(),e.redrawSlaves(),e.hint&&e.hint.hide()},_liveDrag:function(){var e=r.support,t=e.touch,i=e.browser,n=i.mozilla,o=i.msie&&9>i.version;return!t&&!n&&!o},readSelection:function(){var e=this,t=e.selection,i=t.options,n=e.options.select;n.from=i.from,n.to=i.to},filterAxes:function(){var e,t,i=this,n=i.options.select||{},o=i.chart,r=o.options.categoryAxis,a=n.from,s=n.to;for(e=0;r.length>e;e++)t=r[e],t.pane!==M&&(t.min=A(a),t.max=A(s))},filterDataSource:function(){var e,t=this,i=t.options.select||{},n=t.chart,o=n.dataSource,r=o&&o.options.serverFiltering;t.dataSource&&r&&(e=new p.DateCategoryAxis(l({baseUnit:"fit"},n.options.categoryAxis[0],{categories:[i.from,i.to]})).options,o.filter(O.buildFilter(b(e.min,-e.baseUnitStep,e.baseUnit),b(e.max,e.baseUnitStep,e.baseUnit))))},_zoom:function(e){var t,i,n=this,o=n.chart,a=e.delta,s=o._plotArea.categoryAxis,l=n.options.select,u=n.selection,d=n.mainAxis().options.categories;u&&(t=w(u.options.from,d),i=w(u.options.to,d),e.originalEvent.preventDefault(),c.abs(a)>1&&(a*=N),i-t>1?(u.expand(a),n.readSelection()):(s.options.min=l.from,l.from=s.scaleRange(-e.delta).min),r.support.touch||(n.filterAxes(),n.redrawSlaves()),u.set(l.from,l.to),n.showHint(n.options.select.from,n.options.select.to))},_zoomEnd:function(e){this._dragEnd(e)},showHint:function(e,t){var i=this,n=i.chart,o=n._plotArea;i.hint&&i.hint.show(e,t,o.backgroundBox())},_selectStart:function(e){var t=this.chart;t._selectStart.call(t,e)},_select:function(e){var t=this,i=t.chart;t.showHint(e.from,e.to),i._select.call(i,e)},_selectEnd:function(e){var t=this,i=t.chart;t.hint&&t.hint.hide(),t.readSelection(),t.filterAxes(),t.filterDataSource(),t.redrawSlaves(),i._selectEnd.call(i,e)},mainAxis:function(){var e=this.chart._plotArea;return e?e.namedCategoryAxes[z]:t},select:function(e,t){var i=this.options.select;return e&&t&&(i.from=A(e),i.to=A(t),this.filterAxes(),this.filterDataSource(),this.redrawSlaves(),this.selection.set(e,t)),{from:i.from,to:i.to}}});O.setup=function(e,t){if(e=e||{},t=t||{},!e.__navi){e.__navi=!0;var i=l({},t.navigator,e.navigator),n=e.panes=[].concat(e.panes),o=l({},i.pane,{name:M});i.visible||(o.visible=!1,o.height=.1),n.push(o),O.attachAxes(e,i),O.attachSeries(e,i,t)}},O.attachAxes=function(e,t){var i=t.series||[],n=e.categoryAxis=[].concat(e.categoryAxis),o=e.valueAxis=[].concat(e.valueAxis),r=v(i,U),a=0===r.length,s=l({type:"date",pane:M,roundToBaseUnit:!a,justified:a,_collapse:!1,majorTicks:{visible:!0},tooltip:{visible:!1},labels:{step:1},autoBind:!t.dataSource,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]},_overlap:!0}),c=t.categoryAxis;n.push(l({},s,{maxDateGroups:200},c,{name:z,title:null,baseUnit:"fit",baseUnitStep:"auto",labels:{visible:!1},majorTicks:{visible:!1}}),l({},s,c,{name:z+"_labels",maxDateGroups:20,baseUnitStep:"auto",plotBands:[],autoBaseUnitSteps:{minutes:[]}}),l({},s,c,{name:z+"_ticks",maxDateGroups:200,majorTicks:{width:.5},plotBands:[],title:null,labels:{visible:!1,mirror:!0}})),o.push(l({name:z,pane:M,majorGridLines:{visible:!1},visible:!1},t.valueAxis))},O.attachSeries=function(e,t,i){var n,o=e.series=e.series||[],r=[].concat(t.series||[]),a=i.seriesColors,s=t.seriesDefaults;for(n=0;r.length>n;n++)o.push(l({color:a[n%a.length],categoryField:t.dateField,visibleInLegend:!1,tooltip:{visible:!1}},s,r[n],{axis:z,categoryAxis:z,autoBind:!t.dataSource}))},O.buildFilter=function(e,t){return[{field:"Date",operator:"gte",value:A(e)},{field:"Date",operator:"lt",value:A(t)}]},o=a.extend({init:function(t,i){var n=this;n.options=l({},n.options,i),n.container=t,n.chartPadding={top:parseInt(t.css("paddingTop"),10),left:parseInt(t.css("paddingLeft"),10)},n.template=n.template,n.template||(n.template=n.template=f(" ")),n.element=e(n.template()).appendTo(t)},options:{format:"{0:d} - {1:d}",hideDelay:500},show:function(e,t,i){var n,o=this,a=A(S(e)+S(t-e)/2),s=o.options,l=r.format(o.options.format,e,t),c=o.element.find("."+D+"tooltip"),u=o.element.find("."+D+"scroll"),d=.4*i.width(),h=i.center().x-d,f=i.center().x,p=f-h,m=s.max-s.min,v=p/m,_=a-s.min;o._hideTimeout&&clearTimeout(o._hideTimeout),o._visible||(o.element.stop(!1,!0).css("visibility","hidden").show(),o._visible=!0),s.template&&(n=g(s.template),l=n({from:e,to:t})),c.html(l).css({left:i.center().x-c.outerWidth()/2,top:i.y1}),u.css({width:d,left:h+_*v,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 e=this;e._hideTimeout&&clearTimeout(e._hideTimeout),e._hideTimeout=setTimeout(function(){e._visible=!1,e.element.fadeOut("slow")},e.options.hideDelay)}}),p.ui.plugin(F),l(p,{Navigator:O})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t,i){(i||t)()}); //# sourceMappingURL=kendo.dataviz.stock.min.js.map