text: /*
  * Kendo UI v2015.2.902 (http://www.telerik.com/kendo-ui)
  * Copyright 2015 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(["./kendo.dataviz.chart.min"],e)}(function(){return function(e,t){function n(){}function i(e){return n.prototype=e,new n}var o,r=window.kendo,s=r.Class,a=r.Observable,l=r.deepExtend,c=Math,h=e.proxy,d=r.util,u=d.last,f=d.renderTemplate,p=r.dataviz,g=d.defined,m=p.filterSeriesByType,v=r.template,_=p.ui.Chart,w=p.Selection,y=p.addDuration,b=d.limitValue,x=p.lteDateIndex,k=p.toDate,C=p.toTime,S=28,T="change",D="k-",A="drag",P="dragEnd",M="_navigator",E=M,I=p.EQUALLY_SPACED_SERIES,B=3,L="zoom",z="zoomEnd",R=_.extend({init:function(t,n){e(t).addClass(D+"chart"),_.fn.init.call(this,t,n)},_applyDefaults:function(e,t){var n=this,i=n.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(i/S)}}};t&&(t=l({},t,o)),n._navigator||F.setup(e,t),_.fn._applyDefaults.call(n,e,t)},_initDataSource:function(e){var t,n,i=e||{},o=i.dataSource,r=o&&o.serverFiltering,s=[].concat(i.categoryAxis)[0],a=i.navigator||{},c=a.select,h=c&&c.from&&c.to;r&&h&&(t=[].concat(o.filter||[]),n=new p.DateCategoryAxis(l({baseUnit:"fit"},s,{categories:[c.from,c.to]})),o.filter=F.buildFilter(n.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,n=[].concat(t.series,t.navigator.series),i=e.grep(n,function(e){return e&&e.visible}).length,o=this._seriesCount!==i;return this._seriesCount=i,o},_fullRedraw:function(){var e=this,t=e._navigator;t||(t=e._navigator=new F(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,n){var i,o=this,r=o.options.categoryAxis,s=r.length;if(_.fn._bindCategoryAxis.apply(this,arguments),e.name===E)for(;s>n;)i=r[n++],i.pane==M&&(i.categories=e.categories)},_trackSharedTooltip:function(e){var t=this,n=t._plotArea,i=n.paneByPoint(e);i&&i.options.name===M?t._unsetActivePoint():_.fn._trackSharedTooltip.call(t,e)},destroy:function(){var e=this;e._navigator.destroy(),_.fn.destroy.call(e)}}),F=a.extend({init:function(e){var t=this;t.chart=e,t.options=l({},t.options,e.options.navigator),t._initDataSource(),g(t.options.hint.visible)||(t.options.hint.visible=t.options.visible),e.bind(A,h(t._drag,t)),e.bind(P,h(t._dragEnd,t)),e.bind(L,h(t._zoom,t)),e.bind(z,h(t._zoomEnd,t))},options:{},_initDataSource:function(){var e=this,t=e.options,n=t.autoBind,i=t.dataSource;g(n)||(n=e.chart.options.autoBind),e._dataChangedHandler=h(e._onDataChanged,e),i&&(e.dataSource=r.data.DataSource.create(i).bind(T,e._dataChangedHandler),n&&e.dataSource.fetch())},_onDataChanged:function(){var e,t,n,i,o,r=this,s=r.chart,a=s.options.series,l=a.length,c=s.options.categoryAxis,h=c.length,d=r.dataSource.view();for(e=0;l>e;e++)n=a[e],n.axis==E&&s._isBindable(n)&&(n.data=d);for(t=0;h>t;t++)i=c[t],i.pane==M&&(i.name==E?(s._bindCategoryAxis(i,d,t),o=i.categories):i.categories=o);s._model&&(r.redraw(),r.filterAxes(),(!s.options.dataSource||s.options.dataSource&&s._dataBound)&&r.redrawSlaves())},destroy:function(){var e=this,t=e.dataSource;t&&t.unbind(T,e._dataChangeHandler),e.selection&&e.selection.destroy()},redraw:function(){this._redrawSelf(),this._initSelection()},_initSelection:function(){var t=this,n=t.chart,r=t.options,s=t.mainAxis(),a=i(s),l=s.range(),c=l.min,h=l.max,d=s.options.categories,u=t.options.select,f=t.selection,p=k(u.from),g=k(u.to);0!==d.length&&(f&&(f.destroy(),f.wrapper.remove()),a.box=s.box,f=t.selection=new w(n,a,{min:c,max:h,from:p,to:g,selectStart:e.proxy(t._selectStart,t),select:e.proxy(t._select,t),selectEnd:e.proxy(t._selectEnd,t),mousewheel:{zoom:"left"}}),r.hint.visible&&(t.hint=new o(n.element,{min:c,max:h,template:r.hint.template,format:r.hint.format})))},_setRange:function(){var e,t=this.chart._createPlotArea(!0),n=t.namedCategoryAxes[E],i=n.options,o=n.range(),r=o.min,s=y(o.max,i.baseUnitStep,i.baseUnit),a=this.options.select||{},l=k(a.from)||r;r>l&&(l=r),e=k(a.to)||s,e>s&&(e=s),this.options.select={from:l,to:e},this.filterAxes()},_redrawSelf:function(e){var t=this.chart._plotArea;t&&t.redraw(u(t.panes),e)},redrawSlaves:function(){var e=this,t=e.chart,n=t._plotArea,i=n.panes.slice(0,-1);n.srcSeries=t.options.series,n.redraw(i)},_drag:function(e){var t,n,i,o=this,r=o.chart,s=r._eventCoordinates(e.originalEvent),a=o.mainAxis(),l=a.range(),c=a.pane.box.containsPoint(s),h=r._plotArea.categoryAxis,d=e.axisRanges[h.options.name],u=o.options.select,f=o.selection;d&&!c&&f&&(t=u.from&&u.to?C(u.to)-C(u.from):C(f.options.to)-C(f.options.from),n=k(b(C(d.min),l.min,C(l.max)-t)),i=k(b(C(n)+t,C(l.min)+t,l.max)),o.options.select={from:n,to:i},o._liveDrag()&&(o.filterAxes(),o.redrawSlaves()),f.set(n,i),o.showHint(n,i))},_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,n=e.browser,i=n.mozilla,o=n.msie&&9>n.version;return!t&&!i&&!o},readSelection:function(){var e=this,t=e.selection,n=t.options,i=e.options.select;i.from=n.from,i.to=n.to},filterAxes:function(){var e,t,n=this,i=n.options.select||{},o=n.chart,r=o.options.categoryAxis,s=i.from,a=i.to;for(e=0;r.length>e;e++)t=r[e],t.pane!==M&&(t.min=k(s),t.max=k(a))},filterDataSource:function(){var e,t=this,n=t.options.select||{},i=t.chart,o=i.dataSource,r=o&&o.options.serverFiltering;t.dataSource&&r&&(e=new p.DateCategoryAxis(l({baseUnit:"fit"},i.options.categoryAxis[0],{categories:[n.from,n.to]})).options,o.filter(F.buildFilter(y(e.min,-e.baseUnitStep,e.baseUnit),y(e.max,e.baseUnitStep,e.baseUnit))))},_zoom:function(e){var t,n,i=this,o=i.chart,s=e.delta,a=o._plotArea.categoryAxis,l=i.options.select,h=i.selection,d=i.mainAxis().options.categories;h&&(t=x(h.options.from,d),n=x(h.options.to,d),e.originalEvent.preventDefault(),c.abs(s)>1&&(s*=B),n-t>1?(h.expand(s),i.readSelection()):(a.options.min=l.from,l.from=a.scaleRange(-e.delta).min),r.support.touch||(i.filterAxes(),i.redrawSlaves()),h.set(l.from,l.to),i.showHint(i.options.select.from,i.options.select.to))},_zoomEnd:function(e){this._dragEnd(e)},showHint:function(e,t){var n=this,i=n.chart,o=i._plotArea;n.hint&&n.hint.show(e,t,o.backgroundBox())},_selectStart:function(e){var t=this.chart;t._selectStart.call(t,e)},_select:function(e){var t=this,n=t.chart;t.showHint(e.from,e.to),n._select.call(n,e)},_selectEnd:function(e){var t=this,n=t.chart;t.hint&&t.hint.hide(),t.readSelection(),t.filterAxes(),t.filterDataSource(),t.redrawSlaves(),n._selectEnd.call(n,e)},mainAxis:function(){var e=this.chart._plotArea;return e?e.namedCategoryAxes[E]:t}});F.setup=function(e,t){e=e||{},t=t||{};var n=l({},t.navigator,e.navigator),i=e.panes=[].concat(e.panes),o=l({},n.pane,{name:M});n.visible||(o.visible=!1,o.height=.1),i.push(o),F.attachAxes(e,n),F.attachSeries(e,n,t)},F.attachAxes=function(e,t){var n=t.series||[],i=e.categoryAxis=[].concat(e.categoryAxis),o=e.valueAxis=[].concat(e.valueAxis),r=m(n,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:!t.dataSource,autoBaseUnitSteps:{minutes:[1],hours:[1,2],days:[1,2],weeks:[],months:[1],years:[1]},_overlap:!1}),c=t.categoryAxis;i.push(l({},a,{maxDateGroups:200},c,{name:E,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:[],labels:{visible:!1,mirror:!0}})),o.push(l({name:E,pane:M,majorGridLines:{visible:!1},visible:!1},t.valueAxis))},F.attachSeries=function(e,t,n){var i,o=e.series=e.series||[],r=[].concat(t.series||[]),s=n.seriesColors,a=t.seriesDefaults;for(i=0;r.length>i;i++)o.push(l({color:s[i%s.length],categoryField:t.dateField,visibleInLegend:!1,tooltip:{visible:!1}},a,r[i],{axis:E,categoryAxis:E,autoBind:!t.dataSource}))},F.buildFilter=function(e,t){return[{field:"Date",operator:"gte",value:k(e)},{field:"Date",operator:"lt",value:k(t)}]},o=s.extend({init:function(t,n){var i=this;i.options=l({},i.options,n),i.container=t,i.chartPadding={top:parseInt(t.css("paddingTop"),10),left:parseInt(t.css("paddingLeft"),10)},i.template=i.template,i.template||(i.template=i.template=f("<div class='"+D+"navigator-hint' style='display: none; position: absolute; top: 1px; left: 1px;'><div class='"+D+"tooltip "+D+"chart-tooltip'>&nbsp;</div><div class='"+D+"scroll' /></div>")),i.element=e(i.template()).appendTo(t)},options:{format:"{0:d} - {1:d}",hideDelay:500},show:function(e,t,n){var i,o=this,s=k(C(e)+C(t-e)/2),a=o.options,l=r.format(o.options.format,e,t),c=o.element.find("."+D+"tooltip"),h=o.element.find("."+D+"scroll"),d=.4*n.width(),u=n.center().x-d,f=n.center().x,p=f-u,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&&(i=v(a.template),l=i({from:e,to:t})),c.html(l).css({left:n.center().x-c.outerWidth()/2,top:n.y1}),h.css({width:d,left:u+_*m,top:n.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(R),l(p,{Navigator:F})}(window.kendo.jQuery),window.kendo},"function"==typeof define&&define.amd?define:function(e,t){t()});