@progress/kendo-ui
Version:
This package is part of the [Kendo UI for jQuery](http://www.telerik.com/kendo-ui) suite.
1 lines • 1.61 kB
JavaScript
module.exports=function(r){var t={};function n(e){if(t[e])return t[e].exports;var o=t[e]={exports:{},id:e,loaded:!1};return r[e].call(o.exports,o,o.exports,n),o.loaded=!0,o.exports}return n.m=r,n.c=t,n.p="",n(0)}({0:function(e,o,r){e.exports=r(1685)},3:function(e,o){e.exports=function(){throw Error("define cannot be used indirect")}},20:function(e,o){e.exports=require("../kendo.core")},1685:function(e,o,r){var t;r(3),r=[r(20)],void 0===(o="function"==typeof(t=function(){var e=kendo,d=e.spreadsheet.RangeRef,p=e.spreadsheet.CellRef,o=e.Class.extend({init:function(e){this._grid=e},rectIsVertical:function(e,o,r,t){var n=this._grid.rectangle(e.toRangeRef());var i=this._grid.rectangle(o.toRangeRef());return Math.abs(i[t]-n[t])>Math.abs(n[r]-i[r])},autoFillDest:function(e,o){var r=e.topLeft;var t=e.bottomRight;var n;var f=o.row>=r.row;var i=o.col>=r.col;if(f)n=i?4:3;else n=i?2:1;var l,c,a,s;if(n===4){l=r;c=t;s=o.row>c.row||o.col>c.col;if(s)o=new p(Math.max(o.row,c.row),Math.max(o.col,c.col));if(this.rectIsVertical(c,o,"right","bottom"))a=new p(o.row,c.col);else a=new p(c.row,o.col)}else if(n===3){var w=new p(r.col,t.row);if(o.row>t.row&&this.rectIsVertical(w,o,"left","bottom")){l=r;a=new p(o.row,t.col)}else{l=t;a=new p(r.row,o.col)}}else if(n===2){var u=new p(r.row,t.col);if(o.col>t.col&&!this.rectIsVertical(u,o,"right","top")){l=r;a=new p(t.row,o.col)}else{l=t;a=new p(o.row,r.col)}}else{l=t;if(this.rectIsVertical(r,o,"left","top"))a=new p(o.row,r.col);else a=new p(r.row,o.col)}return this._grid.normalize(new d(l,a))}});e.spreadsheet.AutoFillCalculator=o})?t.apply(o,r):t)||(e.exports=o)}});